/* Règles spécifiques à /quizz (nouvelle page 1 question "son signe",
   version sombre noir/or). Charge d'abord css/common.css, dont ce
   fichier surcharge la palette (variables réutilisées partout sur la
   page : .sign-grid/.sign-btn viennent de common.css sans changement
   de leur part, ils héritent juste des nouvelles couleurs ci-dessous). */

:root {
  --bg: #120A14;
  --bg-card: #1D1420;
  --ink: #F2E9DD;
  --ink-soft: #A99C90;
  --line: #332A36;
  --accent: #C9A461;
  --accent-soft: #2E2415;
  --cta: #C9A461;
  --cta-hover: #D9B673;
}

/* .wrapper::before (common.css) est un halo blanc pensé pour le fond
   clair habituel (blanc à 100% qui se fond dans #FFF8FF) : sur un fond
   presque noir, ce même halo devient une tache blanche criarde plutôt
   qu'un effet discret. Neutralisé pour cette page. */
.wrapper::before { background: none; }

/* Le padding-bottom de 96px de common.css est prévu pour des pages avec
   CTA collé en bas ; pas de CTA ici (juste next-step automatique au clic),
   donc ce padding ne fait que pousser la grille de signes vers un scroll
   inutile sur les petits écrans. */
.wrapper { padding-bottom: 24px; }

.quizz-brand {
  text-align: center;
  font-family: var(--font-title);
  font-weight: 600;
  font-size: 13px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin: 32px 0 24px;
}

.quizz-progress-row {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 32px 0 8px;
}

.quizz-category {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
  text-align: center;
}

.quizz-counter {
  position: absolute;
  right: 0;
  font-size: 12px;
  font-weight: 600;
  color: var(--ink-soft);
}

.quizz-back-btn {
  position: absolute;
  left: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: none;
  border: none;
  padding: 0;
  color: var(--ink-soft);
  cursor: pointer;
}

.quizz-back-btn svg { width: 20px; height: 20px; }
.quizz-back-btn:hover { color: var(--accent); }

.quizz-progress-track {
  height: 4px;
  border-radius: 999px;
  background: var(--line);
  overflow: hidden;
  margin-bottom: 28px;
}

.quizz-progress-fill {
  height: 100%;
  background: var(--accent);
  border-radius: 999px;
  transition: width 0.5s ease-out;
}

/* Transition entre étapes reprise à l'identique du quiz Aether (cf.
   components/quiz-flow.tsx + app/globals.css du projet Aether) : montée
   de 18px + fondu + flou qui se dissipe, sans animation de sortie
   (l'ancien contenu disparaît net, seul le nouveau "rise"). Désactive la
   transition CSS générique de .step.active (common.css), qui toucherait
   aussi opacity/transform et entrerait en conflit avec ces keyframes. */
#sign-step.step.active { transition: none; }

@keyframes quizz-rise {
  from { opacity: 0; transform: translateY(18px); filter: blur(3px); }
  to { opacity: 1; transform: translateY(0); filter: blur(0); }
}

#sign-step.rise {
  animation: quizz-rise 0.9s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

@media (prefers-reduced-motion: reduce) {
  #sign-step.rise { animation-duration: 0.01s; }
}

/* ── Questions à choix (radios stylées en boutons pleine largeur) ─
   Écoute sur `change` dans quiz.js, jamais `click` sur le label. */

.choice-list { display: flex; flex-direction: column; gap: 10px; }

.choice-option { position: relative; }

.choice-option input[type="radio"] {
  position: absolute;
  opacity: 0;
  width: 1px;
  height: 1px;
}

.choice-option label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 18px;
  min-height: 44px;
  background: var(--bg-card);
  border: 1px solid var(--line);
  border-radius: 12px;
  font-size: 16px;
  font-weight: 500;
  cursor: pointer;
  transition: border-color 0.15s ease, background 0.15s ease;
}

.choice-option input[type="radio"]:focus-visible + label {
  outline: 2px solid var(--cta);
  outline-offset: 2px;
}

.choice-option label:hover { border-color: var(--accent); }

.choice-option input[type="radio"]:checked + label {
  border-color: var(--cta);
  background: var(--accent-soft);
}

/* Rond de sélection, repris du composant OptionCard d'Aether (16px,
   contour fin, se remplit en plein une fois coché), avec un check
   à l'intérieur plutôt qu'un simple remplissage plat. */
.choice-dot {
  flex: none;
  width: 16px;
  height: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  border: 1px solid var(--ink-soft);
  color: var(--bg);
  transition: border-color 0.15s ease, background-color 0.15s ease;
}

.choice-dot svg {
  width: 10px;
  height: 10px;
  opacity: 0;
  transition: opacity 0.15s ease;
}

.choice-option input[type="radio"]:checked + label .choice-dot {
  border-color: var(--cta);
  background: var(--cta);
}

.choice-option input[type="radio"]:checked + label .choice-dot svg { opacity: 1; }
