/* ==========================================================================
   JOURNEY & WIZARD STYLES - VOTRE ESPACE DV
   ========================================================================== */

/* Contrôle mot de passe avec bouton afficher/masquer */
.password-control {
  position: relative;
  display: flex;
  align-items: center;
}

.password-control input:not([type=hidden]) {
  padding-right: 96px;
}

.password-toggle {
  position: absolute;
  right: 6px;
  top: 50%;
  transform: translateY(-50%);
  padding: 6px 12px;
  border-radius: var(--radius-xs);
  background: var(--surface-subtle);
  color: var(--primary-700);
  font-size: 12px;
  font-weight: 600;
  transition: all 0.2s ease;
}

.password-toggle:hover {
  background: var(--primary-100);
  color: var(--primary-900);
}

.forgot-password {
  margin-top: -6px;
  margin-bottom: 24px;
  text-align: right;
  font-size: 13px;
}

/* Page Récupération de compte */
.recovery-page {
  padding-block: 60px 80px;
}

.recovery-card {
  max-width: 580px;
  margin-inline: auto;
  padding: 44px;
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  background: #ffffff;
}

.recovery-card > h1 {
  font-size: 32px;
  margin: 16px 0 12px;
}

.recovery-card > p {
  color: var(--ink-600);
  font-size: 15px;
  line-height: 1.7;
}

.recovery-tips {
  border-top: 1px solid var(--border-subtle);
  margin-top: 28px;
  padding-top: 24px;
  background: var(--surface-subtle);
  border-radius: var(--radius-sm);
  padding: 20px 24px;
}

.recovery-tips h2 {
  font-size: 16px;
  margin-bottom: 12px;
}

.recovery-tips ul {
  font-size: 13px;
  color: var(--ink-600);
  margin-bottom: 0;
  padding-left: 20px;
}

.recovery-tips li {
  margin-block: 8px;
  line-height: 1.6;
}

/* Checklist de préparation */
.preparation-list {
  list-style: none;
  padding: 0;
  margin: 24px 0;
  background: var(--surface-subtle);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  overflow: hidden;
}

.preparation-list li + li {
  border-top: 1px solid var(--border-subtle);
}

.preparation-list a {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 18px;
  font-size: 14px;
  font-weight: 500;
  color: var(--ink-800);
  transition: all 0.2s ease;
}

.preparation-list a:hover {
  background: #ffffff;
  color: var(--primary-800);
  text-decoration: none;
}

.preparation-list small {
  margin-left: auto;
  font-size: 11px;
  font-weight: 600;
  color: var(--ink-400);
  background: #ffffff;
  padding: 3px 10px;
  border-radius: var(--radius-full);
  border: 1px solid var(--border-subtle);
}

.preparation-list .is-complete small {
  color: var(--success-600);
  background: var(--success-50);
  border-color: var(--success-100);
}

.checklist-mark {
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  flex: none;
  color: var(--ink-400);
  background: #ffffff;
  border: 1.5px solid var(--border-light);
  border-radius: 50%;
  font-size: 12px;
  font-weight: 700;
  transition: all 0.2s ease;
}

.is-complete .checklist-mark {
  color: #ffffff;
  background: var(--success-500);
  border-color: var(--success-500);
}

/* Encart prochaine étape */
.next-step-note {
  background: linear-gradient(135deg, var(--primary-50), #ffffff);
  border: 1px solid var(--primary-100);
  border-left: 4px solid var(--primary-600);
  border-radius: var(--radius-sm);
  padding: 16px 20px;
  margin: 24px 0;
  box-shadow: var(--shadow-xs);
}

.next-step-note .eyebrow {
  margin-bottom: 4px;
}

.next-step-note strong {
  display: block;
  font-size: 18px;
  color: var(--primary-900);
  margin-bottom: 4px;
}

.next-step-note p {
  color: var(--ink-600);
  font-size: 13px;
  margin: 0;
  line-height: 1.6;
}

/* Aide progressive rétractable (details/summary) */
.help-question, .step-help {
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  background: #ffffff;
  margin-bottom: 24px;
  box-shadow: var(--shadow-xs);
  overflow: hidden;
  transition: border-color 0.2s ease;
}

.help-question:hover, .step-help:hover {
  border-color: var(--border-light);
}

.help-question summary, .step-help summary {
  padding: 16px 20px;
  cursor: pointer;
  color: var(--primary-800);
  font-size: 13px;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: space-between;
  list-style: none;
  background: var(--surface-subtle);
  user-select: none;
  transition: background-color 0.2s ease;
}

.help-question summary::-webkit-details-marker,
.step-help summary::-webkit-details-marker {
  display: none;
}

.help-question summary::after,
.step-help summary::after {
  content: '↓';
  font-size: 14px;
  color: var(--primary-600);
  font-weight: 700;
  transition: transform 0.2s ease;
}

.help-question[open] summary::after,
.step-help[open] summary::after {
  transform: rotate(180deg);
}

.help-question p {
  padding: 16px 20px;
  color: var(--ink-600);
  font-size: 13px;
  line-height: 1.7;
  margin: 0;
}

.step-help-content {
  padding: 16px 20px;
}

.step-help-content h2 {
  font-size: 14px;
  margin-top: 12px;
  margin-bottom: 6px;
  color: var(--ink-900);
}

.step-help-content p {
  font-size: 13px;
  line-height: 1.7;
  color: var(--ink-600);
  margin-bottom: 12px;
}

/* Actions de sauvegarde */
.save-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

/* Erreurs de formulaire */
.error-summary a {
  color: var(--danger-600);
  text-decoration: underline;
  text-underline-offset: 3px;
  font-weight: 600;
}

.error-summary ul {
  margin-bottom: 0;
  padding-left: 20px;
}

.error-summary li {
  margin-block: 4px;
}

/* Membres de la famille */
.family-card h2 {
  font-size: 22px;
  margin-bottom: 8px;
}

.member-card {
  background: var(--surface-subtle);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 24px;
  margin-top: 20px;
  position: relative;
}

.member-card h3 {
  font-size: 16px;
  margin-bottom: 18px;
  color: var(--primary-800);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* Galerie et photos avec repères */
.photo-guidance {
  display: flex;
  gap: 28px;
  align-items: center;
  margin: 28px 0;
  background: linear-gradient(135deg, var(--surface-subtle), #ffffff);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 28px;
  box-shadow: var(--shadow-xs);
}

.portrait-guide {
  position: relative;
  width: 100px;
  height: 125px;
  border-radius: 12px;
  background: #ffffff;
  border: 2px dashed var(--primary-400);
  flex-shrink: 0;
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

.portrait-head {
  position: absolute;
  left: 31px;
  top: 24px;
  width: 38px;
  height: 48px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary-300), var(--primary-100));
}

.portrait-shoulders {
  position: absolute;
  left: 10px;
  top: 72px;
  width: 80px;
  height: 70px;
  border-radius: 50% 50% 0 0;
  background: linear-gradient(135deg, var(--primary-400), var(--primary-200));
}

.photo-specs {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}

.photo-specs span {
  background: #ffffff;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-xs);
  padding: 4px 10px;
  font-size: 11px;
  font-weight: 600;
  color: var(--primary-700);
}

.photo-gallery {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
  margin: 20px 0;
}

.photo-gallery figure {
  margin: 0;
  width: 150px;
}

.photo-gallery img {
  width: 150px;
  height: 150px;
  object-fit: cover;
  border-radius: var(--radius-sm);
  border: 2px solid var(--border-subtle);
  box-shadow: var(--shadow-xs);
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.photo-gallery img:hover {
  transform: scale(1.03);
  border-color: var(--primary-600);
}

.labelled-gallery figcaption {
  font-size: 12px;
  font-weight: 600;
  line-height: 1.5;
  margin-top: 10px;
  color: var(--ink-800);
}

.labelled-gallery .pill {
  margin-top: 6px;
  font-size: 10px;
}

/* Zone d'upload */
.upload-block {
  padding: 20px 0;
  border-bottom: 1px solid var(--border-subtle);
}

.upload-block:last-child {
  border-bottom: none;
}

.upload-block input[type=file] {
  border: 2px dashed var(--border-light);
  background: var(--surface-subtle);
  border-radius: var(--radius-sm);
  padding: 16px;
  font-size: 13px;
  cursor: pointer;
  transition: border-color 0.2s ease, background-color 0.2s ease;
}

.upload-block input[type=file]:hover {
  border-color: var(--primary-600);
  background-color: var(--primary-50);
}

.upload-preview {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 14px;
}

.photo-preview-box {
  position: relative;
  width: 140px;
  height: 140px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: 2px solid var(--primary-600);
  box-shadow: var(--shadow-sm);
  background: #000;
}

.photo-preview-box .preview-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.biometric-guide-overlay {
  position: absolute;
  inset: 0;
  pointer-events: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.bio-oval {
  width: 65%;
  height: 75%;
  border: 1.5px dashed rgba(255, 255, 255, 0.85);
  border-radius: 50% 50% 45% 45%;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.4);
}

.bio-eyes-line {
  position: absolute;
  top: 45%;
  left: 20%;
  right: 20%;
  height: 1px;
  border-top: 1.5px dotted rgba(245, 158, 11, 0.9);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
}

.photo-feedback-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 600;
  padding: 6px 12px;
  border-radius: var(--radius-xs);
  width: fit-content;
  line-height: 1.4;
}

.photo-feedback-badge.badge-success {
  background: var(--success-50);
  color: var(--success-600);
  border: 1px solid var(--success-100);
}

.photo-feedback-badge.badge-warning {
  background: var(--amber-50);
  color: var(--amber-700);
  border: 1px solid var(--amber-100);
}

.photo-feedback-badge.badge-error {
  background: var(--danger-50);
  color: var(--danger-600);
  border: 1px solid var(--danger-100);
}

.preview-caption {
  font-size: 12px;
  color: var(--ink-600);
}

.counter-warn {
  color: var(--danger-600) !important;
  font-weight: 700 !important;
}

form.is-submitting button[type=submit] {
  position: relative;
  cursor: wait;
}


/* Récapitulatif Accord & Confirmation */
.consent-card {
  background: linear-gradient(135deg, var(--surface-subtle), #ffffff);
  border: 1.5px solid var(--border-light);
}

.confirmation-card {
  background: linear-gradient(135deg, var(--primary-900), var(--primary-800));
  color: #ffffff;
  padding: 36px;
  border-radius: var(--radius-md);
  margin-bottom: 28px;
  box-shadow: var(--shadow-lg);
}

.confirmation-card h2 {
  color: #ffffff;
  font-size: 32px;
  margin: 14px 0;
  letter-spacing: 2px;
}

.confirmation-card p {
  color: var(--primary-100);
  font-size: 14px;
}

.light-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #ffffff;
  font-size: 13px;
  font-weight: 600;
  margin-top: 16px;
  text-decoration: underline;
  text-underline-offset: 4px;
}

/* Timeline */
.timeline {
  padding: 0;
  list-style: none;
  margin: 20px 0 0;
}

.timeline li {
  border-left: 2px solid var(--border-light);
  padding: 0 0 24px 20px;
  position: relative;
  font-size: 13px;
  color: var(--ink-700);
}

.timeline li::before {
  content: '';
  width: 10px;
  height: 10px;
  position: absolute;
  left: -6px;
  top: 6px;
  background: var(--primary-600);
  border: 2px solid #ffffff;
  box-shadow: 0 0 0 2px var(--primary-100);
  border-radius: 50%;
}

.timeline time {
  display: block;
  font-size: 11px;
  color: var(--ink-400);
  margin-top: 4px;
}

/* Grille Conseiller Queue */
.queue-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}

.queue-grid .card {
  margin-bottom: 0;
}

.filter-form {
  display: flex;
  gap: 16px;
  align-items: center;
  margin: 28px 0;
  background: #ffffff;
  padding: 16px 20px;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-xs);
}

@media (max-width: 768px) {
  .recovery-page {
    padding-block: 32px 48px;
  }
  .recovery-card {
    padding: 28px 20px;
  }
  .preparation-list a {
    font-size: 13px;
    padding: 12px 14px;
  }
  .photo-guidance {
    flex-direction: column;
    align-items: flex-start;
    gap: 18px;
    padding: 20px;
  }
  .photo-gallery figure {
    width: 110px;
  }
  .photo-gallery img {
    width: 110px;
    height: 110px;
  }
  .queue-grid {
    grid-template-columns: 1fr;
  }
  .filter-form {
    flex-direction: column;
    align-items: stretch;
  }
}

