/* =====================================================================
 * Questionnaire bilan · Jessica Houssin
 * Charte : fond blanc lumineux, noir, mauve-gris du logo, touches rosées très claires,
 * boutons arrondis.
 * Titres : Playfair Display · Textes : Jost (polices hébergées localement,
 * aucun appel à Google Fonts).
 * ===================================================================== */

@font-face { font-family: 'Jost'; font-style: normal; font-weight: 300; font-display: swap;
  src: url('../fonts/jost-latin-300-normal.woff2') format('woff2'); }
@font-face { font-family: 'Jost'; font-style: normal; font-weight: 400; font-display: swap;
  src: url('../fonts/jost-latin-400-normal.woff2') format('woff2'); }
@font-face { font-family: 'Jost'; font-style: normal; font-weight: 500; font-display: swap;
  src: url('../fonts/jost-latin-500-normal.woff2') format('woff2'); }
@font-face { font-family: 'Playfair Display'; font-style: normal; font-weight: 400; font-display: swap;
  src: url('../fonts/playfair-display-latin-400-normal.woff2') format('woff2'); }
@font-face { font-family: 'Playfair Display'; font-style: normal; font-weight: 500; font-display: swap;
  src: url('../fonts/playfair-display-latin-500-normal.woff2') format('woff2'); }
@font-face { font-family: 'Playfair Display'; font-style: italic; font-weight: 400; font-display: swap;
  src: url('../fonts/playfair-display-latin-400-italic.woff2') format('woff2'); }

:root {
  /* Couleurs de marque (modifiables ici) */
  --fond: #ffffff;          /* fond général : blanc */
  --fond-doux: #faf7f8;     /* touche rosée très claire (encadrés) */
  --fond-rose: #f5eff2;     /* rose poudré (sélection, numéros) */
  --encre: #111111;         /* noir des titres et boutons */
  --texte: #2b2729;
  --texte-doux: #6a6268;
  --mauve: #6d636c;         /* couleur du logo */
  --mauve-clair: #ddd4da;
  --ligne: #ece6ea;
  --erreur: #8a2c3b;

  --titre: 'Playfair Display', Georgia, 'Times New Roman', serif;
  --corps: 'Jost', 'Helvetica Neue', Arial, sans-serif;

  --rayon: 16px;
  --rayon-bouton: 999px;
  --largeur: 760px;
  --ombre: 0 1px 2px rgba(17, 17, 17, .03), 0 10px 30px rgba(109, 99, 108, .07);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; background: var(--fond); }
body {
  margin: 0; background: var(--fond); color: var(--texte);
  font-family: var(--corps); font-weight: 400; font-size: 1.0625rem; line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; }
a { color: var(--encre); text-underline-offset: 3px; }
a:hover { color: var(--mauve); }
strong { font-weight: 500; color: var(--encre); }
:focus-visible { outline: 2px solid var(--encre); outline-offset: 3px; border-radius: 6px; }
h1[tabindex="-1"]:focus, main[tabindex="-1"]:focus { outline: none; }
[hidden] { display: none !important; }

.evitement { position: absolute; left: -9999px; top: 0; background: var(--encre); color: #fff; padding: .5rem 1rem; z-index: 10; }
.evitement:focus { left: 1rem; top: 1rem; }

/* ---------- En-tête ---------- */
.entete { display: flex; justify-content: center; padding: 1.25rem 1rem .5rem; }
.entete__logo img { display: block; width: 200px; }
.embarque .entete { display: none; }

/* ---------- Progression ---------- */
.progression { max-width: var(--largeur); margin: .75rem auto 0; padding: 0 1rem; }
.progression__texte { font-size: .8125rem; letter-spacing: .1em; text-transform: uppercase; color: var(--texte-doux); margin-bottom: .45rem; }
.progression__barre { height: 3px; background: var(--ligne); border-radius: 3px; overflow: hidden; }
.progression__barre span { display: block; height: 100%; width: 0; background: var(--mauve); border-radius: 3px; transition: width .35s ease; }

/* ---------- Contenu ---------- */
.contenu { max-width: var(--largeur); margin: 0 auto; padding: 1rem 1rem 2.5rem; outline: none; }
.ecran { animation: apparition .35s ease both; }
@keyframes apparition { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) {
  .ecran { animation: none; }
  .progression__barre span { transition: none; }
}

h1, h2, h3 { font-family: var(--titre); font-weight: 400; color: var(--encre); line-height: 1.22; margin: 0 0 .75rem; }
h1 { font-size: clamp(1.95rem, 6.6vw, 3rem); letter-spacing: -.01em; }
h1 em { font-style: italic; color: var(--mauve); }
h2 { font-size: clamp(1.4rem, 4.4vw, 1.9rem); }
h3 { font-size: 1.25rem; }
p { margin: 0 0 1rem; }

.surtitre {
  display: inline-block; font-size: .78rem; letter-spacing: .14em; text-transform: uppercase;
  color: var(--mauve); margin-bottom: .9rem;
}

/* ---------- Bandeaux (images de respiration) ---------- */
.bandeau { margin: 0 0 1.75rem; border-radius: calc(var(--rayon) + 4px); overflow: hidden; background: var(--fond-doux); aspect-ratio: 16 / 10; }
.bandeau img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: 75% 50%; }
.bandeau--bilan { aspect-ratio: 16 / 8; }
.bandeau--bilan img { object-position: 50% 30%; }

/* ---------- Accueil ---------- */
.accueil { text-align: left; }
.accueil h1 { margin-bottom: 1rem; }
.accueil__duree { display: inline-flex; align-items: center; gap: .55rem; font-size: .95rem; color: var(--texte-doux); margin-bottom: 1.5rem; }
.accueil__duree::before { content: ''; width: 7px; height: 7px; border-radius: 50%; background: var(--mauve); }
.accueil__consigne p { font-size: 1.0625rem; }
.encadre {
  background: var(--fond-doux); border-radius: var(--rayon);
  padding: 1.2rem 1.25rem .3rem; margin: 1.75rem 0; font-size: .95rem; color: var(--texte-doux);
}
.encadre h2 { font-family: var(--corps); font-size: .8rem; letter-spacing: .12em; text-transform: uppercase; font-weight: 500; color: var(--encre); margin-bottom: .7rem; }
.navigation--accueil { border-top: 0; padding-top: 0; justify-content: flex-start; }
.navigation--accueil .bouton:only-child { margin-left: 0; }

/* ---------- Boutons ---------- */
.bouton {
  -webkit-appearance: none; appearance: none;
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  min-height: 52px; padding: .8rem 1.75rem;
  font-family: var(--corps); font-size: .95rem; font-weight: 500; letter-spacing: .08em; text-transform: uppercase;
  border-radius: var(--rayon-bouton); border: 1.5px solid var(--encre);
  background: var(--encre); color: #fff; cursor: pointer; text-decoration: none; text-align: center;
  transition: background .2s ease, color .2s ease, transform .1s ease;
}
.bouton:hover { background: #333; color: #fff; }
.bouton:active { transform: scale(.98); }
.bouton--contour { background: #fff; color: var(--encre); }
.bouton--contour:hover { background: var(--encre); color: #fff; }
.bouton[disabled] { opacity: .4; cursor: not-allowed; }

.bouton-petit {
  -webkit-appearance: none; appearance: none; display: inline-flex; align-items: center; gap: .4rem;
  font: 500 .78rem/1 var(--corps); letter-spacing: .06em; text-transform: uppercase; color: var(--texte-doux);
  background: #fff; border: 1px solid var(--mauve-clair); border-radius: 999px; padding: .5rem .85rem; cursor: pointer;
}
.bouton-petit:hover { color: var(--encre); border-color: var(--encre); }
.icone { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; flex: none; }

.lien-bouton { -webkit-appearance: none; appearance: none; background: none; border: 0; padding: .25rem 0; font: inherit; font-size: .9rem; color: var(--texte-doux); text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.lien-bouton:hover { color: var(--encre); }

/* ---------- Question ---------- */
.question h1 { font-size: clamp(1.45rem, 5vw, 2rem); margin: .5rem 0 .5rem; }
.question__consigne { color: var(--texte-doux); font-size: .92rem; margin-bottom: 1.4rem; }
.question__aide { color: var(--texte-doux); }

.options { display: grid; gap: .6rem; margin: 0; padding: 0; border: 0; }
.options legend { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.option { position: relative; }
.option input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.option label {
  display: flex; align-items: flex-start; gap: .85rem; cursor: pointer;
  background: #fff; border: 1.5px solid var(--ligne); border-radius: var(--rayon);
  padding: .95rem 1.05rem; line-height: 1.5;
  transition: border-color .15s ease, background .15s ease;
}
.option label:hover { border-color: var(--mauve-clair); background: var(--fond-doux); }
.option__marque {
  flex: none; width: 22px; height: 22px; margin-top: .12rem; border: 1.5px solid var(--mauve-clair); border-radius: 6px;
  display: grid; place-items: center; background: #fff; transition: background .15s ease, border-color .15s ease;
}
.option input[type=radio] + label .option__marque { border-radius: 50%; }
.option input:checked + label { border-color: var(--mauve); background: var(--fond-rose); }
.option input:checked + label .option__marque { background: var(--encre); border-color: var(--encre); }
.option input:checked + label .option__marque::after {
  content: ''; width: 10px; height: 6px; border-left: 2px solid #fff; border-bottom: 2px solid #fff; transform: translateY(-1px) rotate(-45deg);
}
.option input[type=radio]:checked + label .option__marque::after { width: 8px; height: 8px; border: 0; border-radius: 50%; background: #fff; transform: none; }
.option input:focus-visible + label { outline: 2px solid var(--encre); outline-offset: 2px; }
.option input:disabled + label { opacity: .45; cursor: not-allowed; }

textarea {
  width: 100%; min-height: 92px; resize: vertical; font: inherit; color: var(--encre);
  background: #fff; border: 1.5px solid var(--ligne); border-radius: var(--rayon); padding: .9rem 1rem;
}
textarea:focus { outline: none; border-color: var(--mauve); }
.q11 textarea { min-height: 200px; }
.aide { color: var(--texte-doux); font-size: .88rem; margin-top: .5rem; }

.message { min-height: 1.5rem; margin: .9rem 0 0; font-size: .95rem; color: var(--erreur); }
.message:empty { min-height: 0; margin: 0; }

.navigation {
  display: flex; justify-content: space-between; align-items: center; gap: .75rem;
  margin-top: 1.75rem; padding-top: 1.25rem; border-top: 1px solid var(--ligne);
}
.navigation .bouton:only-child { margin-left: auto; }

/* ---------- Bilan ---------- */
.bilan .bandeau { margin-bottom: 1rem; }
.bilan__outils { display: flex; justify-content: flex-end; margin: 0 0 .75rem; }
.bilan__entete { margin-bottom: 1.75rem; }
.bilan__entete h1 { font-size: clamp(1.85rem, 6vw, 2.6rem); }
.bilan__resume { color: var(--texte-doux); margin: 0; }
.bilan__logo-impression { display: none; }

/* Accordéon des rubriques */
.accordeon { border-top: 1px solid var(--ligne); }
.rubrique { border-bottom: 1px solid var(--ligne); }
.rubrique > summary {
  list-style: none; cursor: pointer; display: flex; align-items: center; gap: 1rem;
  padding: 1.15rem .25rem; -webkit-tap-highlight-color: transparent;
}
.rubrique > summary::-webkit-details-marker { display: none; }
.rubrique > summary:hover .rubrique__titre { color: var(--mauve); }
.rubrique__num {
  flex: none; width: 2.4rem; height: 2.4rem; border-radius: 50%; display: grid; place-items: center;
  background: var(--fond-rose); color: var(--mauve); font-size: .85rem; font-weight: 500; letter-spacing: .04em;
}
.rubrique__titre { flex: 1; margin: 0; font-size: clamp(1.15rem, 4vw, 1.45rem); transition: color .15s ease; }
.rubrique__chevron { width: 20px; height: 20px; color: var(--mauve); transition: transform .25s ease; }
.rubrique[open] > summary .rubrique__chevron { transform: rotate(180deg); }
.rubrique__contenu { padding: .25rem 0 1.75rem; }
@media (min-width: 720px) { .rubrique__contenu { padding-left: 3.4rem; } }

.partie__intro p { color: var(--texte); }
.module { background: var(--fond-doux); border-radius: var(--rayon); padding: 1.2rem 1.25rem .3rem; margin: 1rem 0; }
.module h3 { font-size: 1.15rem; margin-bottom: .6rem; }
.module--synthese { background: transparent; padding: 0; color: var(--texte-doux); }
.module--ressources, .module--sagesse { background: #fff; border: 1px solid var(--ligne); }
.module--sagesse p:first-child { font-family: var(--titre); font-size: 1.2rem; color: var(--encre); }

.q11__citation {
  font-family: var(--titre); font-style: italic; font-size: 1.2rem; line-height: 1.6; color: var(--encre);
  background: var(--fond-doux); border-left: 3px solid var(--mauve); border-radius: 0 var(--rayon) var(--rayon) 0;
  margin: 1.25rem 0; padding: 1.1rem 1.25rem; white-space: pre-wrap; overflow-wrap: anywhere;
}
.q11__conclusion { font-weight: 500; color: var(--encre); }

/* Présentation de Jessica */
.jessica {
  display: grid; grid-template-columns: 1fr; gap: 1rem; justify-items: start;
  background: var(--fond-doux); border-radius: calc(var(--rayon) + 4px); padding: 1.4rem 1.3rem .5rem; margin: 1.25rem 0 1.5rem;
}
.jessica__photo { width: 96px; height: 96px; border-radius: 50%; object-fit: cover; border: 3px solid #fff; box-shadow: var(--ombre); }
.jessica__nom { font-family: var(--titre); font-size: 1.35rem; color: var(--encre); margin: 0; line-height: 1.2; }
.jessica__activite { font-size: .78rem; letter-spacing: .14em; text-transform: uppercase; color: var(--mauve); margin: .2rem 0 .9rem; }
@media (min-width: 600px) {
  .jessica { grid-template-columns: 120px 1fr; gap: 1.5rem; align-items: start; padding: 1.6rem 1.6rem .6rem; }
  .jessica__photo { width: 120px; height: 120px; }
}

/* Offres */
.offres { display: grid; gap: 1.1rem; margin-top: 1.25rem; }
.offre { background: #fff; border: 1px solid var(--ligne); border-radius: calc(var(--rayon) + 4px); overflow: hidden; box-shadow: var(--ombre); }
.offre__image { background: var(--fond-doux); aspect-ratio: 1 / 1; }
.offre__image img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: 50% 100%; } /* garde le titre du visuel */
.offre__texte { padding: 1.3rem 1.3rem .5rem; }
.offre__mention { font-size: .75rem; letter-spacing: .14em; text-transform: uppercase; color: var(--mauve); margin-bottom: .35rem; }
.offre h3 { font-size: 1.35rem; margin-bottom: .6rem; }
.offre__lien a { font-weight: 500; }
@media (min-width: 600px) {
  .offre--image { display: grid; grid-template-columns: 40% 1fr; }
  .offre--image .offre__image { aspect-ratio: auto; min-height: 100%; }
  .offre__texte { padding: 1.5rem 1.5rem .6rem; }
}

/* Témoignages */
.sous-partie { margin-top: 2.25rem; }
.sous-titre { font-size: 1.3rem; }
.temoignages { display: grid; gap: 1rem; margin-top: 1.1rem; }
@media (min-width: 720px) { .temoignages { grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); } }
.temoignage { position: relative; background: var(--fond-doux); border-radius: var(--rayon); padding: 1.6rem 1.3rem 1.2rem; margin: 0; }
.temoignage__guillemet { display: block; font-family: var(--titre); font-size: 3rem; line-height: .6; color: var(--mauve-clair); margin-bottom: .4rem; }
.temoignage blockquote { margin: 0 0 1rem; font-family: var(--titre); font-style: italic; font-size: 1.05rem; line-height: 1.65; color: var(--encre); white-space: pre-line; }
.temoignage figcaption { display: flex; flex-wrap: wrap; align-items: center; gap: .4rem .75rem; font-size: .92rem; }
.temoignage__signature { font-weight: 500; color: var(--encre); }
.temoignage__type { font-size: .72rem; letter-spacing: .08em; text-transform: uppercase; color: var(--mauve); border: 1px solid var(--mauve-clair); border-radius: 999px; padding: .1rem .6rem; }
.temoignage__lien { display: inline-block; margin-top: .8rem; font-weight: 500; font-size: .95rem; }
.temoignage__mention { color: var(--texte-doux); font-size: .82rem; margin-top: .75rem; }

/* Appel découverte */
.appel { background: var(--fond-rose); border-radius: calc(var(--rayon) + 6px); padding: 1.8rem 1.35rem; margin-top: 2.25rem; text-align: center; }
.appel__texte { text-align: left; }
.appel .bouton { width: 100%; margin-top: .5rem; }

.avertissement { font-size: .85rem; color: var(--texte-doux); margin-top: 2rem; }
.bilan__fin { text-align: center; margin-top: 1rem; }

/* ---------- Pied de page ---------- */
.pied { max-width: var(--largeur); margin: 0 auto; padding: 1.5rem 1rem 2.5rem; font-size: .85rem; color: var(--texte-doux); border-top: 1px solid var(--ligne); }
.pied p { margin: 0 0 .35rem; }
.pied a { color: var(--texte-doux); }
.embarque .pied { border-top: 0; padding-top: .5rem; }

/* ---------- Grands écrans ---------- */
@media (min-width: 720px) {
  .entete { padding-top: 2rem; }
  .entete__logo img { width: 240px; }
  .contenu { padding-top: 1.5rem; }
  .bandeau { aspect-ratio: 16 / 7; }
  .bandeau--bilan { aspect-ratio: 16 / 6; }
  .option label { padding: 1.05rem 1.2rem; }
  .module { padding-left: 1.5rem; padding-right: 1.5rem; }
  .appel { padding: 2.4rem 2.5rem; }
  .appel .bouton { width: auto; }
}

/* ---------- Impression / PDF ---------- */
@page { size: A4; margin: 16mm 15mm 18mm; }
@media print {
  :root { --ombre: none; }
  body { background: #fff; color: #000; font-size: 10.5pt; line-height: 1.5; }
  .entete, .progression, .bilan__outils, .bilan__fin, .navigation, .evitement, .bandeau, .rubrique__chevron { display: none !important; }
  .contenu { max-width: none; padding: 0; }
  .ecran { animation: none; }
  .bilan__logo-impression { display: block; width: 170px; margin-bottom: 8mm; }
  h1 { font-size: 22pt; } h2 { font-size: 16pt; } h3 { font-size: 12.5pt; }
  h2, h3, summary { break-after: avoid; page-break-after: avoid; }
  .accordeon, .rubrique { border: 0; }
  .rubrique > summary { padding: 6mm 0 2mm; }
  .rubrique__contenu { padding: 0 0 2mm; display: block !important; }
  .rubrique__num { background: none; border: 1px solid #bbb; }
  .module, .offre, .temoignage, .appel, .q11__citation, .jessica { break-inside: avoid; page-break-inside: avoid; border: 1px solid #ddd; background: #fff; box-shadow: none; }
  .module--synthese { border: 0; }
  .offre--image { grid-template-columns: 30% 1fr; }
  .appel { text-align: left; }
  .appel .bouton { display: inline; border: 0; background: none; color: #000; padding: 0; min-height: 0; text-transform: none; letter-spacing: 0; font-weight: 500; }
  a[data-url]::after { content: ' : ' attr(data-url); font-weight: 400; font-size: 9pt; color: #444; word-break: break-all; }
  .pied { border-top: 1px solid #ccc; color: #333; max-width: none; padding: 4mm 0 0; break-inside: avoid; }
}
