/* =====================================================================
   STYLES QUIZ  -  antoinepeytavin.com  (mobile-first, charte home)
   ===================================================================== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
:root {
  --dark: #0D0D0D;
  --purple: #7C3AED;
  --purple-dark: #5B21B6;
  --purple-light: #A78BFA;
  --gray: #6B7280;
  --light: #F9FAFB;
  --green: #10B981;
  --white: #ffffff;
  --border: #E5E7EB;
}
html { -webkit-text-size-adjust: 100%; }
body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  background: var(--white);
  color: var(--dark);
  line-height: 1.6;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  -webkit-font-smoothing: antialiased;
}

/* ---------- NAV (identique home) ---------- */
nav { position: sticky; top: 0; z-index: 100; background: rgba(13,13,13,0.95); backdrop-filter: blur(12px); border-bottom: 1px solid rgba(255,255,255,0.06); padding: 0 1.25rem; }
.nav-inner { max-width: 1100px; margin: 0 auto; height: 58px; display: flex; align-items: center; }
.nav-logo { display: flex; align-items: center; gap: 10px; text-decoration: none; }
.nav-logo-icon { width: 32px; height: 32px; background: var(--purple); border-radius: 50%; display: flex; align-items: center; justify-content: center; color: #fff; font-weight: 800; font-size: 13px; flex-shrink: 0; }
.nav-logo-text { color: #fff; font-family: 'Josefin Sans', sans-serif; font-weight: 300; font-size: 14px; letter-spacing: 0.1em; text-transform: uppercase; }
.nav-logo-text span { color: var(--purple-light); font-weight: 600; }

/* ---------- LAYOUT ---------- */
main { flex: 1; width: 100%; max-width: 640px; margin: 0 auto; padding: 28px 20px 64px; display: flex; flex-direction: column; }
.screen { display: none; }
.screen.active { display: block; animation: fade .25s ease; }
@keyframes fade { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

.eyebrow { color: var(--purple); font-size: 12px; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; margin-bottom: 14px; }

/* ---------- ECRAN INTRO ---------- */
.intro-title { font-size: clamp(1.7rem, 6vw, 2.3rem); font-weight: 900; line-height: 1.14; letter-spacing: -0.02em; margin-bottom: 18px; }
.intro-text { font-size: 1.02rem; color: #374151; line-height: 1.75; margin-bottom: 32px; }

/* ---------- PROGRESSION ---------- */
.progress-wrap { position: sticky; top: 58px; background: var(--white); padding: 16px 0 10px; z-index: 20; }
.progress-bar { height: 6px; background: #EDEBF5; border-radius: 999px; overflow: hidden; }
.progress-fill { height: 100%; width: 0; background: var(--purple); border-radius: 999px; transition: width .3s ease; }
.progress-label { font-size: 12px; color: var(--gray); margin-top: 8px; font-weight: 600; }

/* ---------- QUESTION ---------- */
.q-counter { color: var(--purple); font-size: 13px; font-weight: 700; letter-spacing: 0.06em; margin-bottom: 12px; }
.q-text { font-size: clamp(1.25rem, 4.5vw, 1.55rem); font-weight: 800; line-height: 1.35; letter-spacing: -0.01em; margin-bottom: 30px; min-height: 2.4em; }
.answers { display: flex; flex-direction: column; gap: 12px; }
.answer-btn {
  font-family: inherit; font-size: 1.05rem; font-weight: 700; color: var(--dark);
  background: var(--white); border: 2px solid var(--border); border-radius: 14px;
  padding: 18px 22px; text-align: left; cursor: pointer; width: 100%;
  transition: border-color .15s, background .15s, transform .1s;
  display: flex; align-items: center; gap: 14px;
  -webkit-tap-highlight-color: transparent;
}
.answer-btn:hover { border-color: var(--purple-light); }
.answer-btn:active { transform: scale(0.99); }
.answer-btn.selected { border-color: var(--purple); background: rgba(124,58,237,0.06); }
.answer-btn .dot { width: 22px; height: 22px; border-radius: 50%; border: 2px solid var(--border); flex-shrink: 0; transition: all .15s; }
.answer-btn.selected .dot { border-color: var(--purple); background: var(--purple); box-shadow: inset 0 0 0 4px #fff; }

.q-nav { display: flex; justify-content: space-between; align-items: center; margin-top: 26px; }
.btn-back { background: none; border: none; color: var(--gray); font-family: inherit; font-size: 14px; font-weight: 600; cursor: pointer; padding: 8px 4px; }
.btn-back:hover { color: var(--dark); }
.btn-back[hidden] { visibility: hidden; }

/* ---------- FORMULAIRE (prenom + email) ---------- */
.form-title { font-size: clamp(1.5rem, 5vw, 2rem); font-weight: 900; line-height: 1.18; letter-spacing: -0.02em; margin-bottom: 12px; }
.form-sub { color: #374151; font-size: 1rem; margin-bottom: 28px; line-height: 1.7; }
.field { margin-bottom: 18px; }
.field label { display: block; font-size: 13px; font-weight: 700; color: var(--dark); margin-bottom: 7px; }
.field input {
  width: 100%; font-family: inherit; font-size: 16px; color: var(--dark);
  padding: 15px 16px; border: 2px solid var(--border); border-radius: 12px; background: var(--white);
  transition: border-color .15s;
}
.field input:focus { outline: none; border-color: var(--purple); }
.hp-field { position: absolute; left: -9999px; opacity: 0; height: 0; overflow: hidden; }
.consent { display: flex; gap: 10px; align-items: flex-start; margin: 8px 0 26px; }
.consent input { margin-top: 3px; width: 18px; height: 18px; flex-shrink: 0; accent-color: var(--purple); }
.consent label { font-size: 12.5px; color: var(--gray); line-height: 1.6; }
.form-err { color: #B91C1C; font-size: 13px; font-weight: 600; margin-bottom: 14px; display: none; }

/* ---------- BOUTON PRINCIPAL ---------- */
.btn-primary {
  background: var(--purple); color: #fff; padding: 16px 30px; border-radius: 12px;
  font-family: inherit; font-weight: 700; font-size: 16px; text-decoration: none; border: none; cursor: pointer;
  transition: all .2s; display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  -webkit-tap-highlight-color: transparent;
}
.btn-primary:hover { background: var(--purple-dark); transform: translateY(-1px); box-shadow: 0 8px 25px rgba(124,58,237,0.4); }
.btn-primary:disabled { opacity: 0.6; cursor: default; transform: none; box-shadow: none; }
.btn-primary.full { width: 100%; }
.btn-primary.big { padding: 18px 34px; font-size: 17px; }

/* ---------- RESULTAT ---------- */
.score-badge { display: inline-flex; align-items: center; gap: 6px; background: rgba(124,58,237,0.10); color: var(--purple); padding: 7px 18px; border-radius: 999px; font-size: 14px; font-weight: 700; margin-bottom: 26px; }
.verdict-title { font-size: clamp(1.7rem, 5.5vw, 2.4rem); font-weight: 900; line-height: 1.15; letter-spacing: -0.02em; margin-bottom: 20px; }
.verdict-title.safe    { color: #047857; }
.verdict-title.info    { color: var(--purple); }
.verdict-title.strong  { color: var(--purple-dark); }
.verdict-title.warning { color: #EA580C; }
.verdict-title.danger  { color: #B91C1C; }
.verdict-text { font-family: "Spectral", Georgia, "Times New Roman", serif; font-size: 1.12rem; line-height: 1.78; color: #0D0D0D; margin-bottom: 34px; }
.verdict-text p { margin-bottom: 1.15em; }
.verdict-text p:last-child { margin-bottom: 0; }
.verdict-text h3 { font-family: Inter, sans-serif; font-size: 0.95rem; font-weight: 800; text-transform: uppercase; letter-spacing: 0.06em; color: #0D0D0D; line-height: 1.35; margin: 2.1em 0 0.7em; }
.verdict-text strong { font-weight: 700; color: #1F2937; }
.verdict-text u { text-decoration-color: var(--purple-light); text-decoration-thickness: 2px; text-underline-offset: 3px; }
.sci-note { position: relative; font-family: "Spectral", Georgia, serif; font-size: 0.94rem; color: #4B5563; line-height: 1.72; background: var(--light); border: 1px solid var(--border); border-left: 3px solid var(--purple-light); padding: 34px 20px 18px; border-radius: 10px; margin-bottom: 18px; }
.sci-note::before { content: "M\00e9thodologie"; position: absolute; top: 14px; left: 20px; font-family: Inter, sans-serif; font-size: 0.68rem; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--purple); }
.sources { font-size: 12px; color: #9CA3AF; line-height: 1.7; margin-bottom: 40px; }
.sources a { color: var(--gray); }
.cta-box { background: var(--light); border: 1px solid #EEF0F3; border-radius: 18px; padding: 30px 26px; margin-bottom: 34px; }
.cta-box .eyebrow { margin-bottom: 12px; }
.cta-box-title { font-size: 1.18rem; font-weight: 800; color: var(--dark); margin-bottom: 24px; line-height: 1.4; }
.email-note { font-size: 0.85rem; color: #9CA3AF; line-height: 1.6; }
.email-note.ok { color: var(--green); font-weight: 600; }

/* ---------- FOOTER ---------- */
footer { background: var(--dark); padding: 26px 22px; }
.footer-inner { max-width: 640px; margin: 0 auto; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; }
.footer-left { font-size: 12px; color: rgba(255,255,255,0.55); line-height: 1.9; }
.footer-left a { color: rgba(255,255,255,0.55); text-decoration: underline; }
.footer-left a:hover { color: var(--purple-light); }
.footer-icons { display: flex; gap: 18px; }
.footer-icons a { color: rgba(255,255,255,0.6); transition: color .15s; }
.footer-icons a:hover { color: var(--purple-light); }
.icon { width: 20px; height: 20px; display: block; }

/* ---------- DESKTOP ---------- */
@media (min-width: 700px) {
  nav { padding: 0 2rem; }
  main { padding: 44px 24px 80px; }
  .q-text { min-height: 1.8em; }
}


/* ---------- CHAMP SEXE (Homme / Femme) ---------- */
.sex-group { display: flex; gap: 12px; }
.sex-btn { flex: 1; font-family: inherit; font-size: 1rem; font-weight: 700; color: var(--dark); background: var(--white); border: 2px solid var(--border); border-radius: 12px; padding: 14px 16px; display: flex; align-items: center; gap: 12px; cursor: pointer; transition: border-color .15s, background .15s; }
.sex-btn:hover { border-color: var(--purple-light); }
.sex-btn.selected { border-color: var(--purple); background: rgba(124,58,237,0.06); }
.sex-btn .dot { width: 20px; height: 20px; border-radius: 50%; border: 2px solid var(--border); flex-shrink: 0; transition: all .15s; }
.sex-btn.selected .dot { border-color: var(--purple); background: var(--purple); box-shadow: inset 0 0 0 4px #fff; }


/* ---------- JAUGE RESULTAT (compteur) ---------- */
.gauge { text-align: center; margin: 4px 0 26px; }
.gauge-svg { width: 100%; max-width: 340px; height: auto; display: block; margin: 0 auto 2px; }
.gauge-tick { fill: var(--gray); font-family: inherit; font-size: 13px; font-weight: 700; }
.gauge-score { line-height: 1; }
.gauge-num { font-size: 56px; font-weight: 900; letter-spacing: -0.02em; }
.gauge-max { font-size: 17px; font-weight: 700; color: var(--gray); margin-left: 8px; }
