/* Charte et photo de profil : parcours commun borne / administration. */
.rules-dialog {
  max-height: calc(100vh - 24px);
  overflow-y: auto;
}

.safety-charter-card {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr);
  align-items: center;
  gap: 14px;
  width: 100%;
  margin: 14px 0 10px;
  padding: 8px;
  border: 1px solid #c9aa58;
  border-radius: 6px;
  background: #f6f8f4;
  color: var(--ink);
  text-align: left;
  cursor: pointer;
  box-shadow: 0 5px 14px rgba(11, 48, 38, .08);
}

.safety-charter-card img {
  display: block;
  width: 150px;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border-radius: 3px;
}

.safety-charter-card span,
.safety-charter-card strong,
.safety-charter-card small { display: block; }
.safety-charter-card strong { color: var(--pine-deep); font-size: 17px; }
.safety-charter-card small { margin-top: 4px; color: var(--muted); font-size: 12px; }
.safety-charter-card:hover { border-color: #9f792b; transform: translateY(-1px); }

.safety-charter-dialog {
  width: min(1500px, calc(100% - 24px));
  max-height: calc(100vh - 24px);
  padding: 12px;
  overflow: auto;
}

.safety-charter-toolbar {
  position: sticky;
  z-index: 2;
  top: -12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: -12px -12px 10px;
  padding: 10px 14px;
  background: rgba(255, 255, 255, .96);
  border-bottom: 1px solid var(--line);
}

.safety-charter-dialog > img {
  display: block;
  width: 100%;
  height: auto;
  max-height: calc(100vh - 88px);
  object-fit: contain;
}

.profile-photo-capture {
  margin: 14px 0;
  padding: 14px;
  border: 1px solid #c9d7d1;
  border-top: 3px solid var(--gold);
  border-radius: 6px;
  background: #f4f7f5;
}

.profile-photo-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 8px;
}

.profile-photo-heading p,
.profile-photo-heading h3 { margin: 0; }
.profile-photo-heading h3 { margin-top: 2px; }
.profile-photo-copy { margin: 8px 0 12px; color: #52645e; font-size: 13px; }
.profile-photo-badge { padding: 5px 8px; border-radius: 999px; background: #fff0c9; color: #715418; font-size: 11px; font-weight: 800; white-space: nowrap; }
.profile-photo-badge.is-ready { background: #dff1e6; color: #165d42; }

.profile-photo-stage {
  position: relative;
  width: min(100%, 420px);
  aspect-ratio: 4 / 3;
  margin: 0 auto;
  overflow: hidden;
  border: 2px solid #1c5d54;
  border-radius: 6px;
  background: #0b281f;
}

.profile-photo-stage video,
.profile-photo-stage img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.profile-photo-status { margin: 9px 0; color: var(--muted); text-align: center; font-size: 12px; }
.profile-photo-status.is-error { color: #a42d2d; font-weight: 700; }
.profile-photo-consent { margin-top: 10px; font-size: 15px !important; }
.profile-photo-actions { display: flex; justify-content: center; gap: 9px; flex-wrap: wrap; margin-top: 10px; }
.profile-photo-actions .button { min-height: 44px; }

.profile-photo-card {
  display: grid;
  grid-template-columns: 88px minmax(0, 1fr);
  align-items: center;
  gap: 12px;
  padding: 11px;
  border: 1px solid #cfddd6;
  border-radius: 5px;
  background: #f4f7f5;
}

.profile-photo-thumb {
  display: block;
  width: 88px;
  height: 88px;
  padding: 0;
  overflow: hidden;
  border: 2px solid #c9aa58;
  border-radius: 5px;
  background: #e8efeb;
  cursor: pointer;
}

.profile-photo-thumb img { display: block; width: 100%; height: 100%; object-fit: cover; }
.profile-photo-card strong,
.profile-photo-card span { display: block; }
.profile-photo-card span { margin-top: 4px; color: var(--muted); font-size: 12px; }
.profile-photo-empty { color: var(--muted); font-size: 13px; }

.profile-photo-dialog { width: min(720px, calc(100% - 24px)); }
.profile-photo-dialog-image { display: block; width: 100%; max-height: 68vh; object-fit: contain; background: #0b281f; border: 1px solid #173d32; }

@media (max-width: 620px) {
  .safety-charter-card { grid-template-columns: 105px minmax(0, 1fr); }
  .safety-charter-card img { width: 105px; }
  .profile-photo-capture { padding: 11px; }
  .profile-photo-actions { display: grid; grid-template-columns: 1fr; }
  .profile-photo-actions .button { width: 100%; }
}
