/* ============================================================================
   mon-test-tdah-quiz — styles propres au test, posés par-dessus le main.css VDL.

   La première partie est reprise telle quelle de la partie 2 de la feuille du site Flask
   (octopus/sites/mon-test-tdah.com/src/static/css/main.css) : mêmes noms de classes, que
   quiz.js injecte à la main. Elle s'appuie sur les tokens de vdl-theme-clone (--accent,
   --surface, --line…), donc suit le thème clair/sombre.
   La seconde partie (« Rapport ») remplace le gabarit PDF.
   ============================================================================ */
:root {
  --brand: var(--primary, #1e3a5f);
  --brand-dark: var(--primary-dark, #0f2d4f);
  --wrap-wide: 1080px;
}

/* --- Conteneurs de la landing ---------------------------------------------- */

.section { padding: 56px 18px; }
.section-inner { max-width: var(--wrap-wide); margin: 0 auto; }
.section-inner.narrow { max-width: var(--wrap); }
.section-alt { background: var(--chip); }
.section-dark { background: var(--brand); color: #fff; }
.section-dark h2, .section-dark h3 { color: #fff; }
.text-center { text-align: center; }

.section h2 { font-size: 26px; line-height: 1.2; }
.section-lead { color: var(--muted); font-size: 16.5px; max-width: 620px; margin: 12px auto 0; }
.section-dark .section-lead { color: rgba(255, 255, 255, 0.85); }

/* --- Boutons de conversion -------------------------------------------------
   `.btn` est défini dans la partie 1 (fond `--fg`). Les variantes ci-dessous
   servent les appels à l'action du tunnel, qui doivent porter la couleur de
   marque plutôt que le noir éditorial. */

.btn-primary { background: var(--brand); color: #fff; }
.btn-primary:hover { background: var(--brand-dark); color: #fff; }
.btn-secondary { background: var(--secondary, #00b4d8); color: #06232e; }
.btn-secondary:hover { background: var(--secondary, #00b4d8); filter: brightness(1.08); color: #06232e; }
.btn-lg { font-size: 15.5px; padding: 15px 30px; border-radius: 8px; }

/* Le `site_name` de ce site est un nom de domaine complet (17 caractères) là où le
   reste du parc a un nom court. Sans ça il passe sur deux lignes sous 420 px et
   double la hauteur de l'en-tête collant. */
.brand { min-width: 0; }
.head-actions { flex: none; }
.brand-name { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
@media (max-width: 480px) { .brand-name { font-size: 16px; } }
@media (max-width: 380px) { .brand-name { font-size: 14px; } }

/* Appel à l'action de l'en-tête collant : présent sur toutes les pages. Il tient
   dans la même hauteur que les `.icon-btn` voisins pour ne pas déformer la barre. */
.cta-head {
  display: inline-flex; align-items: center;
  height: 32px; padding: 0 14px;
  border-radius: 999px;
  background: var(--brand); color: #fff;
  font: 600 12.5px var(--sans);
  white-space: nowrap;
}
.cta-head:hover { background: var(--brand-dark); color: #fff; }
/* Sous 420 px la barre est déjà pleine (marque + 2 icônes) : le bouton passe en
   version courte plutôt que de faire déborder l'en-tête. */
@media (max-width: 420px) { .cta-head { padding: 0 11px; font-size: 11.5px; } }

/* --- Pastilles -------------------------------------------------------------- */

.pill {
  display: inline-flex; align-items: center; gap: 6px;
  background: rgba(255, 255, 255, 0.16); color: inherit;
  border-radius: 999px; padding: 6px 15px;
  font: 600 12.5px var(--sans);
  margin-bottom: 18px;
}
.pill-outline { background: var(--accent-soft); color: var(--accent); }

/* --- Héros de la landing ---------------------------------------------------- */

.hero {
  background: linear-gradient(135deg, var(--brand), var(--brand-dark));
  color: #fff;
  padding: 64px 18px;
}
.hero-inner {
  max-width: var(--wrap-wide); margin: 0 auto;
  display: grid; grid-template-columns: 1fr; gap: 36px; align-items: center;
}
.hero-copy h1 { color: #fff; font-size: 32px; line-height: 1.15; letter-spacing: -0.6px; margin: 0 0 16px; }
.hero-lead { font-size: 16.5px; line-height: 1.55; color: rgba(255, 255, 255, 0.92); margin: 0 0 26px; max-width: 560px; }
.hero-trust { margin-top: 16px; font-size: 13px; color: rgba(255, 255, 255, 0.85); }

/* Aperçu de profil : une illustration, pas un vrai résultat. */
.hero-card {
  background: var(--surface); color: var(--fg);
  border-radius: var(--radius-lg);
  padding: 26px;
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.28);
}
.hero-card-emoji { font-size: 40px; text-align: center; margin-bottom: 14px; }
.hero-bar-row { margin-bottom: 13px; }
.hero-bar-label { display: flex; justify-content: space-between; font: 600 12.5px var(--sans); margin-bottom: 5px; }
.hero-bar-bg { background: var(--chip); border-radius: 999px; height: 8px; overflow: hidden; }
.hero-bar-fill { background: var(--accent); height: 100%; border-radius: 999px; }
.hero-card-note { text-align: center; font-size: 11px; color: var(--muted); margin: 12px 0 0; }

/* --- Bandeau de chiffres ---------------------------------------------------- */

.stats-bar { background: var(--surface); border-bottom: 1px solid var(--line); padding: 40px 18px; }
.stats-inner {
  max-width: var(--wrap-wide); margin: 0 auto;
  display: grid; grid-template-columns: 1fr; gap: 26px; text-align: center;
}
.stat-emoji { font-size: 28px; margin-bottom: 6px; }
.stat-value { font-family: var(--serif); font-size: 27px; font-weight: 600; color: var(--accent); }
.stat-label { color: var(--fg); font-size: 14px; font-weight: 500; }
.stat-source { font-family: var(--mono); font-size: 10.5px; color: var(--muted); margin-top: 3px; }

/* --- Grilles de cartes ------------------------------------------------------ */

.cards-3, .cards-2 { display: grid; grid-template-columns: 1fr; gap: 20px; margin-top: 28px; }
.card-icon { font-size: 26px; margin-bottom: 12px; }

/* Étapes « Comment ça marche » (sur fond de marque) */
.step { position: relative; padding-top: 22px; }
.step h3 { font-size: 18px; margin-bottom: 8px; }
.step p { color: rgba(255, 255, 255, 0.85); font-size: 14px; line-height: 1.55; margin: 0; }
.step-num {
  position: absolute; top: -6px; left: 0;
  font-family: var(--serif); font-size: 38px; font-weight: 600;
  color: rgba(255, 255, 255, 0.28); line-height: 1;
}

/* Bandes d'interprétation du score ASRS */
.score-band {
  background: var(--surface);
  border: 1px solid var(--line);
  border-left: 3px solid;
  border-radius: var(--radius);
  padding: 18px;
}
.score-band-low { border-left-color: #34d399; }
.score-band-mid { border-left-color: #fbbf24; }
.score-band-high { border-left-color: #f87171; }
.score-band-range { font-family: var(--mono); font-size: 11px; letter-spacing: 0.5px; text-transform: uppercase; color: var(--muted); margin: 0 0 5px; }
.score-band-label { font: 600 15px var(--sans); margin: 0 0 7px; }
.score-band p:last-child { font-size: 13.5px; line-height: 1.55; color: var(--muted); margin: 0; }

.cta-emoji { font-size: 40px; margin-bottom: 10px; }

/* --- Avertissement médical (composant YMYL) --------------------------------- */

.disclaimer-full {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 24px;
  font-size: 13.5px; line-height: 1.6; color: var(--muted);
}
.disclaimer-full p { margin: 0; }
.disclaimer-full strong { color: var(--fg); }
.disclaimer-sources { border-top: 1px solid var(--line); margin-top: 16px; padding-top: 16px; }
.disclaimer-sources-title {
  font-family: var(--mono); font-size: 11px; font-weight: 600;
  letter-spacing: 0.6px; text-transform: uppercase; color: var(--fg);
  margin: 0 0 8px;
}
.disclaimer-sources ul { margin: 0; padding-left: 18px; font-size: 12.5px; }
.disclaimer-sources li { margin-bottom: 6px; }

/* Petite mention grise (bas de formulaire, page résultats) */
.disclaimer { font-size: 12px; color: var(--muted); margin-top: 12px; }

/* --- Tunnel : quiz ---------------------------------------------------------
   Les classes ci-dessous sont injectées par `static/js/quiz.js` — ne pas les
   renommer sans toucher au JS. */

.quiz-wrap { max-width: 620px; margin: 0 auto; padding: 40px 18px 48px; }
.quiz-progress { background: var(--chip); border-radius: 999px; height: 8px; margin-bottom: 28px; overflow: hidden; }
.quiz-progress-bar { background: var(--accent); height: 100%; border-radius: 999px; transition: width 0.3s; }
.quiz-question-count { font-family: var(--mono); font-size: 11px; letter-spacing: 0.6px; text-transform: uppercase; color: var(--muted); }
.quiz-question h2 { font-size: 21px; line-height: 1.3; margin: 14px 0 22px; }
.quiz-scale { display: flex; flex-direction: column; gap: 10px; }

.scale-btn {
  padding: 14px 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface); color: var(--fg);
  font: 400 15px var(--sans);
  text-align: left; cursor: pointer;
}
.scale-btn:hover { border-color: var(--accent); color: var(--accent); }

.quiz-milestone, .quiz-tip, .quiz-loading { text-align: center; padding: 36px 18px; }
.quiz-tip-icon { font-size: 30px; margin-bottom: 12px; }
.quiz-milestone button, .quiz-tip button, .resultats-upsell button {
  margin-top: 16px;
  border: 0; border-radius: var(--radius);
  background: var(--brand); color: #fff;
  padding: 14px 26px;
  font: 600 15px var(--sans);
  cursor: pointer;
}

dialog#lead-modal {
  border: 1px solid var(--line); border-radius: var(--radius-lg);
  background: var(--surface); color: var(--fg);
  padding: 26px; max-width: 400px;
}
dialog#lead-modal input {
  width: 100%; margin: 8px 0; padding: 12px;
  border: 1px solid var(--line); border-radius: 7px;
  background: var(--bg); color: var(--fg);
  font: 400 14px var(--sans);
}
dialog#lead-modal button { width: 100%; }

/* --- Tunnel : page résultats ------------------------------------------------ */

.resultats-wrap { max-width: 620px; margin: 0 auto; padding: 40px 18px 48px; }
.resultats-hero { text-align: center; margin-bottom: 24px; }
.badge { display: inline-block; color: #fff; font: 600 13px var(--sans); padding: 7px 18px; border-radius: 999px; margin-bottom: 12px; }
.resultats-scores {
  display: flex; justify-content: space-around; text-align: center;
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius-lg); padding: 20px; margin-bottom: 24px;
}
.resultats-scores strong { display: block; font-family: var(--serif); font-size: 22px; color: var(--accent); }
.resultats-scores span { font-size: 12px; color: var(--muted); }
.resultats-upsell {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius-lg); padding: 24px; text-align: center;
}

/* --- Formulaire de contact -------------------------------------------------- */

.contact-form { display: flex; flex-direction: column; gap: 6px; margin: 22px 0; max-width: 460px; }
.contact-form label { font: 600 13.5px var(--sans); margin-top: 10px; }
.contact-form input, .contact-form textarea {
  border: 1px solid var(--line); border-radius: 7px;
  background: var(--bg); color: var(--fg);
  padding: 11px 12px;
  font: 400 14px var(--sans); resize: vertical; outline: none;
}
.contact-form input:focus, .contact-form textarea:focus { border-color: var(--accent); }
.contact-form button { align-self: flex-start; margin-top: 10px; }
.form-success {
  background: var(--accent-soft);
  border-radius: var(--radius); padding: 14px 16px;
  font-size: 14px;
}
.form-error { color: #dc2626; font-size: 13.5px; margin: 4px 0 0; }

/* --- Confort de lecture au-delà du mobile (landing) ------------------------- */

@media (min-width: 700px) {
  .section { padding: 72px 20px; }
  .section h2 { font-size: 30px; }
  .hero-copy h1 { font-size: 42px; }
  .stats-inner { grid-template-columns: repeat(3, 1fr); }
  .cards-3 { grid-template-columns: repeat(3, 1fr); }
  .cards-2 { grid-template-columns: 1fr 1fr; }
}

@media (min-width: 900px) {
  .hero { padding: 88px 20px; }
  .hero-inner { grid-template-columns: 1.1fr 0.9fr; gap: 48px; }
}

/* --- Ajouts WordPress ------------------------------------------------------- */

/* Bloc du questionnaire, juste sous le héros : carte surélevée qui chevauche le bas du héros,
   pour qu'on la voie sans faire défiler. */
.quiz-zone { padding: 0 18px 40px; margin-top: -36px; position: relative; }
.quiz-card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg);
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.12); padding: 28px 22px 30px; text-align: left;
}
.quiz-title { font-size: 24px; text-align: center; margin: 0 0 4px; }
.quiz-sub { text-align: center; color: var(--muted); font-size: 13.5px; margin: 0 0 22px; }
.quiz-card .quiz-milestone { padding: 18px 0 6px; }
.quiz-card .quiz-milestone h2 { font-size: 19px; }
.quiz-card .quiz-milestone button { font-size: 16px; padding: 15px 34px; }
.hero { padding-bottom: 88px; }
html { scroll-behavior: smooth; }
/* Sur mobile, l'illustration repousserait le test sous la ligne de flottaison. */
@media (max-width: 899px) { .hero-card { display: none; } .hero { padding-top: 40px; } }
#quiz { scroll-margin-top: 110px; }

/* quiz.js ne fixe la largeur qu'à la première question : sans ça la barre part pleine. */
.quiz-progress-bar { width: 0; }
.mtt-h1 { font-size: 27px; line-height: 1.2; letter-spacing: -0.4px; margin: 6px 0 10px; }
.mtt .card { margin: 0; }
.mtt-cta .btn-primary { margin-top: 4px; }

/* --- Rapport (ex-PDF) ------------------------------------------------------- */

.rapport { max-width: 860px; margin: 0 auto; padding: 24px 18px 48px; }
.rapport h2 { font-size: 21px; margin: 32px 0 12px; border-left: 4px solid var(--accent); padding-left: 10px; }
.rapport h3 { font-size: 16px; margin: 18px 0 8px; }
.rapport-actions { text-align: right; margin-bottom: 14px; }
.rapport-header {
  display: flex; justify-content: space-between; align-items: center; gap: 12px;
  background: var(--brand); color: #fff; border-radius: var(--radius-lg); padding: 14px 18px;
}
.rapport-logo { display: block; font: 600 17px var(--serif); }
.rapport-sub, .rapport-date { font-size: 12px; color: rgba(255, 255, 255, 0.8); }
.rapport-hero { text-align: center; margin: 22px 0; }
.rapport-hero > p { max-width: 620px; margin: 6px auto 18px; line-height: 1.55; }
.rapport-fiche {
  border: 1.5px dashed var(--accent); border-radius: var(--radius-lg);
  background: var(--accent-soft); padding: 16px 18px; margin: 18px 0;
}
.rapport-fiche h2 { border: 0; padding: 0; margin: 0 0 10px; font-size: 16px; text-align: center; }
.rapport-fiche p { margin: 0 0 6px; font-size: 14px; }
.rapport-note { font-size: 12.5px; font-style: italic; color: var(--muted); }
.rapport-grid { display: grid; grid-template-columns: 1fr; gap: 14px; }
.rapport-card {
  background: var(--surface); border: 1px solid var(--line); border-top: 3px solid var(--accent);
  border-radius: var(--radius); padding: 14px 16px; font-size: 14px; line-height: 1.5;
}
.rapport-card h3 { margin-top: 4px; }
.rapport-card p { margin: 0; color: var(--muted); }
.rapport-card ul { margin: 0; padding-left: 18px; display: flex; flex-direction: column; gap: 6px; }
.rapport-num {
  display: inline-flex; align-items: center; justify-content: center;
  width: 24px; height: 24px; border-radius: 50%; background: var(--brand); color: #fff; font-weight: 600; font-size: 13px;
}
.rapport-context { background: var(--chip); border-radius: var(--radius-lg); padding: 14px 18px; margin-top: 14px; font-size: 14px; line-height: 1.55; }
.rapport-context h3 { margin-top: 0; }
.rapport-context p { margin: 0; }
.rapport-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.rapport-table th { background: var(--brand); color: #fff; text-align: left; padding: 8px; }
.rapport-table td { padding: 8px; border-bottom: 1px solid var(--line); vertical-align: top; }
.rapport-table tr.lvl-elevee td { background: color-mix(in oklab, #e53935 7%, var(--surface)); }
.rapport-table tr.lvl-moderee td { background: color-mix(in oklab, #fb8c00 7%, var(--surface)); }
.lvl { display: inline-block; padding: 2px 7px; border-radius: 4px; font-size: 11.5px; font-weight: 600; white-space: nowrap; }
.lvl-badge-elevee { background: #ffebee; color: #c62828; }
.lvl-badge-moderee { background: #fff3e0; color: #e65100; }
.lvl-badge-faible { background: #e8f5e9; color: #2e7d32; }
.rapport-muted { font-size: 12.5px; color: var(--muted); }
.rapport-note-box { background: #fff8e1; color: #5d4037; border-left: 4px solid #fb8c00; border-radius: 4px; padding: 10px 14px; font-size: 13.5px; }
.rapport-foot { margin: 28px 0 16px; text-align: center; font-style: italic; }

@media (min-width: 700px) {
  .rapport-grid { grid-template-columns: repeat(3, 1fr); }
  .rapport-grid-2 { grid-template-columns: 1fr 1fr; }
}

@media print {
  .site-head, .bottom-nav, .site-footer, .rapport-actions { display: none !important; }
  .rapport { max-width: none; padding: 0; }
  .rapport-header, .rapport-table th { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  .rapport section { break-inside: avoid-page; }
}

/* --- Préparer mon rendez-vous (inc/prep-render.php) -------------------------- */

.prep-hero { padding-bottom: 56px; }
.prep-help { color: var(--muted); font-size: 14.5px; line-height: 1.55; }
.prep-form { margin-top: 18px; }
.prep-progress {
  position: sticky; top: 64px; z-index: 2;
  background: var(--chip); border-radius: 999px; height: 8px; margin-bottom: 22px; overflow: hidden;
}
.prep-progress-bar { background: var(--accent); height: 100%; width: 0; border-radius: 999px; transition: width 0.3s; }
.prep-dimension { margin: 0 0 30px; }
.prep-dimension h3 { font-size: 19px; margin: 26px 0 12px; }
.prep-item {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg);
  padding: 16px 16px 14px; margin: 0 0 14px; min-width: 0;
}
.prep-item legend { float: left; width: 100%; padding: 0; margin: 0 0 12px; font: 500 15.5px/1.45 var(--sans); }
.prep-item legend + * { clear: both; }
.prep-num { font-family: var(--mono); font-size: 11px; letter-spacing: 0.5px; color: var(--muted); margin-right: 4px; }
.prep-answers { display: grid; grid-template-columns: 1fr; gap: 10px; margin-bottom: 10px; }
.prep-group { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; }
.prep-group-label { font: 600 13.5px var(--sans); }
.prep-group-label small { display: block; font-weight: 400; color: var(--muted); font-size: 12px; }
.prep-choices { display: inline-flex; gap: 8px; }
.prep-choice {
  display: inline-flex; align-items: center; gap: 6px;
  border: 1px solid var(--line); border-radius: 999px; padding: 7px 14px;
  font: 500 14px var(--sans); cursor: pointer; background: var(--bg);
}
.prep-choice:has(input:checked) { border-color: var(--accent); background: var(--accent-soft); }
.prep-choice input { accent-color: var(--accent); margin: 0; }
.prep-example-label, .prep-field-label { display: block; font: 600 13px var(--sans); margin: 6px 0 4px; }
.prep-example-label small, .prep-field-label small { font-weight: 400; color: var(--muted); }
.prep-item textarea, .prep-final input[type="text"], .prep-final input[type="email"] {
  width: 100%; box-sizing: border-box; border: 1px solid var(--line); border-radius: 7px;
  background: var(--bg); color: var(--fg); padding: 10px 12px; font: 400 14px var(--sans); resize: vertical;
}
.prep-item textarea:focus, .prep-final input:focus { outline: none; border-color: var(--accent); }
.prep-consent {
  margin: 18px 0; padding: 14px 16px; border: 1px dashed var(--line); border-radius: var(--radius-lg);
  font-size: 13.5px; line-height: 1.55;
}
.prep-consent-intro { margin: 0 0 10px; }
.prep-consent-box { display: flex; gap: 10px; align-items: flex-start; margin-bottom: 8px; }
.prep-consent-box input { margin-top: 4px; flex: none; }
.prep-submit { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; margin-top: 10px; }
.prep-reset { background: none; border: 0; color: var(--muted); text-decoration: underline; cursor: pointer; font: 400 13px var(--sans); }
@media (min-width: 700px) { .prep-answers { grid-template-columns: 1fr 1fr; gap: 18px; } }

/* Synthèse */
.prep-notice {
  margin: 0 0 14px; padding: 8px 12px; text-align: center;
  border: 1.5px solid var(--brand); border-radius: var(--radius);
  font: 600 13px var(--sans); letter-spacing: 0.4px; text-transform: uppercase; color: var(--brand);
}
.prep-actions { display: flex; justify-content: flex-end; flex-wrap: wrap; gap: 10px; }
.prep-delete { margin: 0; }
.prep-status { border-radius: var(--radius); padding: 12px 14px; font-size: 14px; }
.prep-status-ok { background: var(--accent-soft); }
.prep-status-error { background: #fff3e0; color: #7a3b00; }
.prep-keep { text-align: right; }
.prep-table td.prep-cell, .prep-table th.prep-cell { text-align: center; white-space: nowrap; }
.prep-table tfoot td { border-top: 2px solid var(--line); }
.prep-example { min-width: 180px; font-size: 13px; }
.prep-yes { font-weight: 700; }
.prep-no { color: var(--muted); }
.prep-blank { color: var(--muted); }
.prep-mail { margin-top: 30px; padding: 4px 18px 18px; background: var(--chip); border-radius: var(--radius-lg); }
.resultats-prep { margin-top: 18px; }
.resultats-prep .btn { margin-top: 6px; }

@media print {
  .prep-mail, .prep-keep, .prep-status { display: none !important; }
  .prep-synthese section { break-inside: auto; }
  .prep-synthese tr { break-inside: avoid; }
  .prep-synthese .table-scroll { overflow: visible; }
  .prep-notice { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
}
