/* Le Diagnostic Augmenté — parcours et synthèse.
   04_VISUAL_SYSTEM : noir, blanc, excellente typographie, UNE couleur, beaucoup
   d'espace. Le rouge est une marque d'annotation, pas une couleur de marque :
   il ne sert qu'à signaler la progression et ce qui a été choisi.
   Fontes auto-hébergées, hors du budget « front < 100 Ko hors fontes ». */

@font-face {
  font-family: Spectral;
  src: url(/fontes/spectral-400.woff2) format('woff2');
  font-weight: 400; font-style: normal; font-display: swap;
}
@font-face {
  font-family: Spectral;
  src: url(/fontes/spectral-600.woff2) format('woff2');
  font-weight: 600; font-style: normal; font-display: swap;
}
@font-face {
  font-family: Archivo;
  src: url(/fontes/archivo.woff2) format('woff2');
  font-weight: 100 900; font-style: normal; font-display: swap;
}

:root {
  --encre: #15150f;
  --gris: #6d6c62;
  --trait: #ddd9cf;
  --papier: #fcfbf8;
  --creme: #f5f2ec;
  --marque: #a8261b;
  --serif: Spectral, Georgia, 'Times New Roman', serif;
  --sans: Archivo, -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, sans-serif;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--papier);
  color: var(--encre);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.62;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

.page {
  max-width: 33rem;
  margin: 0 auto;
  padding: 3.5rem 1.5rem 5rem;
  min-height: 100vh;
}

/* — Titraille — */
h1, h2 {
  font-family: var(--serif);
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: -0.015em;
  text-wrap: balance;
}
h1 { font-size: 2rem; margin: 0 0 1.15rem; }
h2 { font-size: 1.35rem; margin: 2.75rem 0 1rem; }
p { margin: 0 0 1.1rem; }

.chapeau { font-size: 1.02rem; line-height: 1.65; color: var(--encre); }
.meta { color: var(--gris); font-size: 0.86rem; }
.signature {
  color: var(--gris);
  font-size: 0.84rem;
  line-height: 1.6;
  margin-top: 3.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--trait);
}

/* — Progression : la seule chose qui bouge — */
.avancement {
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--gris);
  margin-bottom: 2.25rem;
}
.jauge { height: 2px; background: var(--trait); margin-top: 0.7rem; }
.jauge span {
  display: block;
  height: 2px;
  background: var(--marque);
  transition: width 0.35s cubic-bezier(0.22, 1, 0.36, 1);
}

/* — Choix : une question par écran, des cibles franches — */
.choix { list-style: none; margin: 0 0 1.75rem; padding: 0; }
.choix li { margin-bottom: 0.7rem; }
.choix button {
  display: block;
  width: 100%;
  text-align: left;
  background: var(--papier);
  border: 1px solid var(--trait);
  color: var(--encre);
  font: inherit;
  font-size: 1.02rem;
  padding: 1.05rem 1.25rem;
  cursor: pointer;
  min-height: 52px;
  transition: border-color 0.12s, background 0.12s, transform 0.12s;
}
.choix button:hover,
.choix button:focus-visible {
  border-color: var(--encre);
  background: var(--creme);
}
.choix button:active { transform: translateY(1px); }
.choix button[aria-pressed='true'] {
  border-color: var(--marque);
  border-left-width: 3px;
  padding-left: calc(1.25rem - 2px);
}

/* — Formulaire — */
label { display: block; margin-bottom: 0.4rem; font-size: 0.88rem; font-weight: 600; letter-spacing: 0.01em; }
label .facultatif { color: var(--gris); font-weight: 400; }
input[type='text'], input[type='email'], input[type='tel'], textarea {
  width: 100%;
  font: inherit;
  font-size: 1.02rem;
  color: var(--encre);
  background: var(--papier);
  border: 1px solid var(--trait);
  padding: 0.85rem 0.95rem;
  margin-bottom: 1.35rem;
  border-radius: 0;
  min-height: 52px;
  transition: border-color 0.12s;
}
input:hover, textarea:hover { border-color: var(--gris); }
input:focus, textarea:focus { outline: 2px solid var(--marque); outline-offset: -2px; border-color: var(--marque); }
textarea { font-family: var(--serif); font-size: 1.08rem; line-height: 1.6; min-height: 7.5rem; resize: vertical; }

.consentement { display: flex; gap: 0.85rem; align-items: flex-start; margin-bottom: 1.25rem; }
.consentement input { margin-top: 0.25rem; width: 22px; height: 22px; flex: 0 0 auto; accent-color: var(--marque); }
.consentement span { font-size: 0.94rem; line-height: 1.55; }

/* — Actions — */
button.principal {
  background: var(--encre);
  color: var(--papier);
  border: 1px solid var(--encre);
  font: inherit;
  font-size: 0.98rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  padding: 1.05rem 1.75rem;
  cursor: pointer;
  min-height: 52px;
  transition: background 0.15s, border-color 0.15s;
}
button.principal:hover:not([disabled]),
button.principal:focus-visible:not([disabled]) { background: var(--marque); border-color: var(--marque); }
button.principal[disabled] { opacity: 0.4; cursor: default; }
button.retour {
  background: none;
  border: none;
  color: var(--gris);
  font: inherit;
  font-size: 0.88rem;
  padding: 0.75rem 0;
  cursor: pointer;
  margin-top: 1.25rem;
  text-decoration: underline;
  text-underline-offset: 0.2em;
}
button.retour:hover, button.retour:focus-visible { color: var(--encre); }

a.bouton {
  display: inline-block;
  background: var(--encre);
  color: var(--papier);
  text-decoration: none;
  font-size: 0.98rem;
  font-weight: 600;
  padding: 1.05rem 1.75rem;
  border: 1px solid var(--encre);
  margin-top: 0.9rem;
  transition: background 0.15s, border-color 0.15s;
}
a.bouton:hover, a.bouton:focus-visible { background: var(--marque); border-color: var(--marque); }

.erreur {
  border-left: 3px solid var(--marque);
  padding: 0.85rem 0 0.85rem 1.1rem;
  margin-bottom: 1.75rem;
  font-size: 0.94rem;
}
.erreur p { margin: 0 0 0.35rem; }
.erreur p:last-child { margin-bottom: 0; }
.mention { color: var(--gris); font-size: 0.82rem; line-height: 1.6; }

/* — Synthèse : le moment où l'on convainc — */
.profil-nom {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--marque);
  margin: 0 0 1.75rem;
}
.situation { font-family: var(--serif); font-size: 1.22rem; line-height: 1.55; margin: 0 0 2.5rem; }

.opportunites { list-style: none; margin: 0 0 2.5rem; padding: 0; counter-reset: o; }
.opportunites li {
  counter-increment: o;
  font-family: var(--serif);
  font-size: 1.12rem;
  line-height: 1.45;
  border-top: 1px solid var(--trait);
  padding: 1.15rem 0 1.15rem 2.5rem;
  position: relative;
}
.opportunites li::before {
  content: counter(o, decimal-leading-zero);
  position: absolute;
  left: 0;
  top: 1.35rem;
  font-family: var(--sans);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  color: var(--marque);
}
.attente { color: var(--gris); font-size: 0.92rem; }

/* — Révélation par blocs : une seule orchestration, à l'arrivée — */
.revele { opacity: 0; transform: translateY(6px); animation: monte 0.45s cubic-bezier(0.22, 1, 0.36, 1) forwards; }
.revele:nth-child(2) { animation-delay: 0.06s; }
.revele:nth-child(3) { animation-delay: 0.12s; }
.revele:nth-child(4) { animation-delay: 0.18s; }
.revele:nth-child(5) { animation-delay: 0.24s; }
.revele:nth-child(6) { animation-delay: 0.3s; }
@keyframes monte { to { opacity: 1; transform: none; } }

.piege { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

@media (max-width: 560px) {
  body { font-size: 16px; }
  .page { padding: 2.5rem 1.15rem 3.5rem; }
  h1 { font-size: 1.65rem; }
  .situation { font-size: 1.1rem; }
  .opportunites li { font-size: 1.04rem; }
  button.principal, a.bouton { width: 100%; text-align: center; }
}
@media (prefers-reduced-motion: reduce) {
  *, .revele { animation: none !important; transition: none !important; opacity: 1 !important; transform: none !important; }
}
