/* ==========================================================================
   Finaurio — feuille de style
   --------------------------------------------------------------------------
   L'identité visuelle n'est pas arrêtée : elle fait l'objet d'un lot séparé.
   Tout ce qui relève de la marque est isolé dans la couche « Jetons » (§1),
   sous forme de variables CSS. Reprendre l'identité = réécrire le §1.
   Aucun composant ne référence une couleur, une graisse ou un rayon en dur.
   ========================================================================== */

/* ==========================================================================
   §1. JETONS  —  seule zone à modifier lors de la reprise d'identité
   ========================================================================== */
:root {
  /* -- 1.1 Primitives : la palette brute, neutres froids + un accent -------
     Ces valeurs sont des marqueurs de position. Les remplacer par la palette
     de marque suffit : les jetons sémantiques (1.2) s'y réfèrent. */
  --n-0:   #ffffff;
  --n-25:  #fbfcfd;
  --n-50:  #f4f6f8;
  --n-100: #e9edf1;
  --n-200: #d7dee5;
  --n-300: #b6c1cc;
  --n-400: #8595a5;
  --n-500: #5f7182;
  --n-600: #465767;
  --n-700: #33414e;
  --n-800: #212c36;
  --n-900: #141c23;
  --n-950: #0b1116;

  --a-50:  #eef4fb;
  --a-100: #d9e7f6;
  --a-200: #b3cfec;
  --a-400: #4d86c7;
  --a-500: #2f6aad;
  --a-600: #21568c;
  --a-700: #1a4470;

  --r-50:  #fef3f2;
  --r-200: #fda29b;
  --r-400: #f97066;
  --r-600: #d92d20;
  --r-700: #b42318;
  --g-50:  #ecfdf3;
  --g-200: #75e0a7;
  --g-700: #067647;

  /* -- 1.2 Jetons sémantiques : ce que les composants utilisent ------------ */
  --surface-page:    var(--n-0);
  --surface-sunken:  var(--n-50);
  --surface-raised:  var(--n-0);
  --surface-inverse: var(--n-900);
  --surface-accent:  var(--a-50);

  --text-strong: var(--n-900);
  --text:        var(--n-700);
  --text-muted:  var(--n-500);
  --text-invert: var(--n-0);
  --text-accent: var(--a-700);

  --border:        var(--n-200);
  --border-subtle: var(--n-100);
  --border-strong: var(--n-300);

  --accent:          var(--a-600);
  --accent-hover:    var(--a-700);
  --accent-contrast: var(--n-0);
  --accent-soft:     var(--a-50);
  --accent-line:     var(--a-400);

  --focus-ring: var(--a-500);

  --danger:      var(--r-700);
  --danger-line: var(--r-600);
  --danger-soft: var(--r-50);
  --success:      var(--g-700);
  --success-soft: var(--g-50);

  --accent-active:      var(--accent);
  --accent-active-hover: var(--accent-hover);
  --accent-active-text:  var(--n-0);

  /* -- 1.3 Typographie ----------------------------------------------------
     Pile système : aucune dépendance réseau. Une police de marque se
     substitue ici sans toucher au reste. */
  --font-sans: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto,
               "Helvetica Neue", Arial, sans-serif;
  --font-mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, monospace;

  /* Échelle fluide : chaque pas s'adapte à la largeur, sans media query. */
  --step--1: clamp(0.82rem, 0.80rem + 0.10vw, 0.88rem);
  --step-0:  clamp(1.00rem, 0.97rem + 0.15vw, 1.09rem);
  --step-1:  clamp(1.18rem, 1.10rem + 0.38vw, 1.40rem);
  --step-2:  clamp(1.40rem, 1.24rem + 0.75vw, 1.85rem);
  --step-3:  clamp(1.68rem, 1.38rem + 1.45vw, 2.45rem);
  --step-4:  clamp(2.05rem, 1.50rem + 2.65vw, 3.35rem);

  --weight-normal: 400;
  --weight-medium: 500;
  --weight-semi:   600;
  --weight-bold:   700;

  --leading-tight: 1.15;
  --leading-snug:  1.35;
  --leading-body:  1.68;

  --tracking-tight: -0.022em;
  --tracking-wide:   0.075em;

  /* -- 1.4 Espacement : une seule échelle, utilisée partout ---------------- */
  --space-2xs: 0.25rem;
  --space-xs:  0.5rem;
  --space-sm:  0.75rem;
  --space-md:  1rem;
  --space-lg:  1.5rem;
  --space-xl:  2rem;
  --space-2xl: 3rem;
  --space-3xl: 4.5rem;
  --space-4xl: 7rem;

  /* -- 1.5 Formes, profondeur, mouvement ---------------------------------- */
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  --radius-pill: 999px;

  /* Ombres en couches : une portée courte très légère, une longue diffuse. */
  --shadow-xs: 0 1px 2px rgb(20 28 35 / 0.05);
  --shadow-sm: 0 1px 2px rgb(20 28 35 / 0.05), 0 2px 6px rgb(20 28 35 / 0.05);
  --shadow-md: 0 2px 4px rgb(20 28 35 / 0.05), 0 8px 20px rgb(20 28 35 / 0.07);
  --shadow-lg: 0 4px 8px rgb(20 28 35 / 0.06), 0 18px 40px rgb(20 28 35 / 0.10);

  --ease: cubic-bezier(0.2, 0, 0.1, 1);
  --duration: 180ms;

  /* -- 1.6 Gabarit -------------------------------------------------------- */
  --container: 72rem;   /* largeur maximale de la page */
  --measure:   40rem;   /* longueur de ligne confortable du texte courant */
  --gutter: clamp(1.25rem, 5vw, 3rem);
  --header-height: 4.25rem;
}

/* -- 1.7 Thème sombre : seuls les jetons sémantiques sont redéfinis -------- */
@media (prefers-color-scheme: dark) {
  :root {
    --surface-page:    var(--n-950);
    --surface-sunken:  var(--n-900);
    --surface-raised:  var(--n-800);
    --surface-inverse: var(--n-100);
    --surface-accent:  #16263a;

    --text-strong: var(--n-50);
    --text:        var(--n-200);
    --text-muted:  var(--n-400);
    --text-invert: var(--n-900);
    --text-accent: var(--a-200);

    --border:        #2b3945;
    --border-subtle: #1e2a34;
    --border-strong: #3d4d5b;

    --accent:          var(--a-400);
    --accent-hover:    #6a9fd8;
    --accent-contrast: var(--n-950);
    --accent-soft:     #16263a;
    --accent-line:     var(--a-400);

    --focus-ring: var(--a-200);

    --danger:      var(--r-200);
    --danger-line: var(--r-400);
    --danger-soft: #3a1d1d;
    --success:      var(--g-200);
    --success-soft: #11301f;

    --accent-active:       var(--a-500);
    --accent-active-hover: var(--a-600);

    --shadow-xs: 0 1px 2px rgb(0 0 0 / 0.4);
    --shadow-sm: 0 1px 2px rgb(0 0 0 / 0.4), 0 2px 6px rgb(0 0 0 / 0.3);
    --shadow-md: 0 2px 4px rgb(0 0 0 / 0.4), 0 8px 20px rgb(0 0 0 / 0.35);
    --shadow-lg: 0 4px 8px rgb(0 0 0 / 0.45), 0 18px 40px rgb(0 0 0 / 0.5);
  }
}

/* ==========================================================================
   §2. SOCLE
   ========================================================================== */
*, *::before, *::after { box-sizing: border-box; }

html {
  color-scheme: light dark;
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-height) + var(--space-lg));
}

body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: var(--step-0);
  font-weight: var(--weight-normal);
  line-height: var(--leading-body);
  color: var(--text);
  background: var(--surface-page);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img, svg { max-width: 100%; height: auto; display: block; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}

/* ==========================================================================
   §3. GABARIT
   ========================================================================== */
.wrap {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

/* Bande pleine largeur : le fond déborde, le contenu reste contenu. */
.band { padding-block: var(--space-3xl); }
.band--sunken { background: var(--surface-sunken); }
.band--tight  { padding-block: var(--space-2xl); }

/* Colonne de lecture : tout ce qui est du texte suivi s'y limite. */
.prose > p,
.prose > ul,
.prose > ol { max-width: var(--measure); }
.prose > .grid { max-width: none; }   /* une grille occupe toute la largeur */

/* ==========================================================================
   §4. TYPOGRAPHIE
   ========================================================================== */
h1, h2, h3, h4 {
  margin: 0 0 var(--space-md);
  color: var(--text-strong);
  font-weight: var(--weight-bold);
  line-height: var(--leading-tight);
  letter-spacing: var(--tracking-tight);
  text-wrap: balance;
}
h1 { font-size: var(--step-4); }
h2 { font-size: var(--step-3); }
h3 { font-size: var(--step-1); line-height: var(--leading-snug); }
h4 { font-size: var(--step-0); font-weight: var(--weight-semi); }

/* Rythme vertical : les titres n'ont pas de marge haute — elle serait de trop
   en tête de section, de carte ou d'étape. Quand un titre suit un bloc frère,
   il faut la lui rendre, sinon il colle à ce qui précède : une grille ou une
   liste n'a aucune marge basse propre. Les titres internes à un composant
   (`.card h3`, `.steps h3`) ne sont pas concernés, leur sélecteur étant plus
   spécifique ; `:where()` maintient cette règle à la spécificité d'un titre nu. */
:where(p, ul, ol, dl, table, figure, .grid, .steps, .note, .deliverable, .table-wrap) + :is(h2, h3) {
  margin-top: var(--space-xl);
}

p, ul, ol { margin: 0 0 var(--space-md); }
p:last-child, ul:last-child, ol:last-child { margin-bottom: 0; }

strong { color: var(--text-strong); font-weight: var(--weight-semi); }

a {
  color: var(--text-accent);
  text-decoration-color: color-mix(in srgb, var(--accent) 35%, transparent);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.2em;
  transition: color var(--duration) var(--ease),
              text-decoration-color var(--duration) var(--ease);
}
a:hover { color: var(--accent-hover); text-decoration-color: currentColor; }

/* Le chapô : le message que l'on doit retenir même en lecture diagonale. */
.lede {
  max-width: var(--measure);
  font-size: var(--step-1);
  line-height: var(--leading-snug);
  color: var(--text-muted);
  text-wrap: pretty;
}

/* Surtitre : nom d'activité, catégorie, libellé de section. */
.eyebrow {
  display: inline-block;
  margin-bottom: var(--space-sm);
  font-size: var(--step--1);
  font-weight: var(--weight-semi);
  letter-spacing: var(--tracking-wide);
  text-transform: uppercase;
  color: var(--text-accent);
}

.section-intro { max-width: var(--measure); margin-bottom: var(--space-xl); }

/* Une affirmation qui doit se lire seule, détachée du paragraphe : le constat
   qu'un visiteur pressé doit emporter même s'il ne lit rien d'autre. */
.statement {
  max-width: var(--measure);
  margin-bottom: var(--space-sm);
  font-size: var(--step-1);
  line-height: var(--leading-snug);
  color: var(--text-strong);
  text-wrap: pretty;
}
:is(.statement, .aside) + .statement { margin-top: var(--space-lg); }

/* Énumération d'appui, volontairement en retrait de l'affirmation qu'elle
   illustre : elle éclaire, elle ne se lit pas en premier. */
.aside {
  max-width: var(--measure);
  font-size: var(--step--1);
  color: var(--text-muted);
}

/* Phrase de conclusion d'une section, après une grille ou une liste. */
.section-outro {
  max-width: var(--measure);
  margin-top: var(--space-xl);
  margin-bottom: 0;
}

/* ==========================================================================
   §5. ACCESSIBILITÉ
   ========================================================================== */
.skip {
  position: absolute;
  left: -9999px;
  z-index: 100;
  padding: var(--space-sm) var(--space-md);
  background: var(--accent);
  color: var(--accent-contrast);
  border-radius: var(--radius-sm);
  font-weight: var(--weight-semi);
}
.skip:focus { left: var(--gutter); top: var(--space-sm); }

.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

:focus-visible {
  outline: 2px solid var(--focus-ring);
  outline-offset: 3px;
  border-radius: var(--radius-sm);
}

/* ==========================================================================
   §6. EN-TÊTE
   ========================================================================== */
.site-head {
  position: sticky;
  top: 0;
  z-index: 50;
  background: color-mix(in srgb, var(--surface-page) 82%, transparent);
  backdrop-filter: saturate(1.6) blur(12px);
  -webkit-backdrop-filter: saturate(1.6) blur(12px);
  border-bottom: 1px solid var(--border-subtle);
}
.site-head .wrap {
  display: flex;
  align-items: center;
  gap: var(--space-lg);
  min-height: var(--header-height);
}

.brand {
  margin-right: auto;
  font-size: var(--step-1);
  font-weight: var(--weight-bold);
  letter-spacing: var(--tracking-tight);
  color: var(--text-strong);
  text-decoration: none;
}
.brand:hover { color: var(--accent); }

.site-nav ul {
  display: flex;
  align-items: center;
  gap: var(--space-xs);
  margin: 0;
  padding: 0;
  list-style: none;
}
.site-nav a:not(.btn) {
  display: block;
  padding: var(--space-xs) var(--space-sm);
  border-radius: var(--radius-sm);
  font-size: var(--step--1);
  font-weight: var(--weight-medium);
  color: var(--text-muted);
  text-decoration: none;
}
.site-nav a:not(.btn):hover { color: var(--text-strong); background: var(--surface-sunken); }
.site-nav a:not(.btn)[aria-current="page"] { color: var(--text-strong); font-weight: var(--weight-semi); }

.head-cta {
  margin-left: var(--space-sm);
  flex-shrink: 0;
  white-space: nowrap;
}
.site-nav .btn[aria-current="page"] {
  background: var(--accent-active);
  color: var(--accent-active-text);
}
.site-nav .btn[aria-current="page"]:hover {
  background: var(--accent-active-hover);
  color: var(--accent-active-text);
}

@media (max-width: 47rem) {
  .site-head .wrap { flex-wrap: wrap; padding-block: var(--space-sm); gap: var(--space-xs); }
  .brand { margin-right: 0; width: 100%; }
  .site-nav { width: 100%; overflow-x: auto; }
  .site-nav ul { gap: 0; padding-block: 2px; }
  .site-nav a:not(.btn) { padding-inline: var(--space-xs); white-space: nowrap; }
}

/* ==========================================================================
   §7. HÉROS
   ========================================================================== */
.hero {
  position: relative;
  padding-block: var(--space-4xl) var(--space-3xl);
  background:
    radial-gradient(70rem 32rem at 12% -12%,
      color-mix(in srgb, var(--accent) 9%, transparent), transparent 62%),
    linear-gradient(to bottom, var(--surface-sunken), var(--surface-page));
  border-bottom: 1px solid var(--border-subtle);
}
.hero h1 { max-width: 20ch; }
.hero .lede { margin-top: var(--space-lg); font-size: var(--step-2); color: var(--text); }
.hero--compact { padding-block: var(--space-3xl) var(--space-2xl); }
.hero--compact h1 { max-width: 24ch; }

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-md);
  margin-top: var(--space-xl);
}
.hero-note {
  margin-top: var(--space-md);
  font-size: var(--step--1);
  color: var(--text-muted);
}

/* ==========================================================================
   §8. BOUTONS
   ========================================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  gap: var(--space-xs);
  padding: 0.7em 1.35em;
  border: 1px solid transparent;
  border-radius: var(--radius-md);
  background: var(--accent);
  color: var(--accent-contrast);
  font: inherit;
  font-size: var(--step-0);
  font-weight: var(--weight-semi);
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
  box-shadow: var(--shadow-sm);
  transition: background var(--duration) var(--ease),
              box-shadow var(--duration) var(--ease),
              transform var(--duration) var(--ease);
}
.btn:hover { background: var(--accent-hover); color: var(--accent-contrast); box-shadow: var(--shadow-md); transform: translateY(-1px); }
.btn:active { transform: translateY(0); box-shadow: var(--shadow-xs); }

.btn--ghost {
  background: transparent;
  color: var(--text-strong);
  border-color: var(--border-strong);
  box-shadow: none;
}
.btn--ghost:hover { background: var(--surface-sunken); color: var(--text-strong); border-color: var(--text-muted); box-shadow: var(--shadow-xs); }

.btn--small { padding: 0.5em 1em; font-size: var(--step--1); }

/* Lien d'action discret, avec chevron qui avance au survol. */
.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2xs);
  font-weight: var(--weight-semi);
  text-decoration: none;
}
.link-arrow::after {
  content: "→";
  transition: transform var(--duration) var(--ease);
}
.link-arrow:hover::after { transform: translateX(3px); }

/* ==========================================================================
   §9. GRILLES ET CARTES
   ========================================================================== */
.grid {
  display: grid;
  gap: var(--space-lg);
  grid-template-columns: repeat(auto-fit, minmax(min(19rem, 100%), 1fr));
  padding: 0;
  margin: 0;
  list-style: none;
}
.grid--two { grid-template-columns: repeat(auto-fit, minmax(min(24rem, 100%), 1fr)); }

.card {
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
  height: 100%;
  padding: var(--space-xl);
  background: var(--surface-raised);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-xs);
  text-decoration: none;
  color: inherit;
  transition: border-color var(--duration) var(--ease),
              box-shadow var(--duration) var(--ease),
              transform var(--duration) var(--ease);
}
a.card:hover {
  border-color: var(--accent-line);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}
.card h3 { margin: 0; font-size: var(--step-1); }
.card p { color: var(--text-muted); font-size: var(--step-0); }
.card .eyebrow { margin: 0; }
a.card .card-link {
  margin-top: auto;
  padding-top: var(--space-xs);
  color: var(--text-accent);
  font-size: var(--step--1);
  font-weight: var(--weight-semi);
}
a.card .card-link::after { content: " →"; }

/* ==========================================================================
   §10. LISTES
   ========================================================================== */
.list-marked { list-style: none; padding: 0; }
.list-marked > li {
  position: relative;
  max-width: var(--measure);
  padding-left: var(--space-lg);
  margin-bottom: var(--space-sm);
}
.list-marked > li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.62em;
  width: 7px;
  height: 7px;
  border-radius: var(--radius-pill);
  background: var(--accent-line);
}

/* Liste en deux colonnes quand la place le permet (points d'offre). */
.list-cols {
  columns: 2;
  column-gap: var(--space-2xl);
}
.list-cols > li { break-inside: avoid; }
@media (max-width: 52rem) { .list-cols { columns: 1; } }

/* ==========================================================================
   §11. ÉTAPES (page Méthode, chaîne de prise en charge)
   ========================================================================== */
.steps {
  list-style: none;
  counter-reset: step;
  padding: 0;
  margin: 0;
}
.steps > li {
  counter-increment: step;
  position: relative;
  padding-left: calc(var(--space-2xl) + var(--space-sm));
  padding-bottom: var(--space-2xl);
}
.steps > li:last-child { padding-bottom: 0; }

/* Pastille numérotée */
.steps > li::before {
  content: counter(step);
  position: absolute;
  left: 0;
  top: 0;
  display: grid;
  place-items: center;
  width: 2.5rem;
  height: 2.5rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  background: var(--surface-raised);
  box-shadow: var(--shadow-xs);
  color: var(--text-accent);
  font-size: var(--step--1);
  font-weight: var(--weight-bold);
  font-variant-numeric: tabular-nums;
}
/* Fil reliant les pastilles */
.steps > li::after {
  content: "";
  position: absolute;
  left: 1.25rem;
  top: 2.9rem;
  bottom: var(--space-sm);
  width: 1px;
  background: linear-gradient(to bottom, var(--border), transparent);
}
.steps > li:last-child::after { display: none; }
.steps h3 { margin-top: 0.35rem; }

/* Le livrable : l'information à retenir de chaque étape. */
.deliverable {
  max-width: var(--measure);
  margin-block: var(--space-md);
  padding: var(--space-md) var(--space-lg);
  background: var(--surface-accent);
  border-left: 3px solid var(--accent);
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
}
.deliverable-label {
  display: block;
  margin-bottom: var(--space-2xs);
  font-size: var(--step--1);
  font-weight: var(--weight-semi);
  letter-spacing: var(--tracking-wide);
  text-transform: uppercase;
  color: var(--text-accent);
}
.deliverable ul { margin: 0; }

/* ==========================================================================
   §12. ENCADRÉ DE NUANCE
   ========================================================================== */
.note {
  max-width: var(--measure);
  margin-block: var(--space-lg);
  padding: var(--space-lg);
  background: var(--surface-sunken);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  font-size: var(--step-0);
}
.note strong { color: var(--text-strong); }
.band--sunken .note { background: var(--surface-page); }

/* ==========================================================================
   §13. TABLEAUX
   ========================================================================== */
.table-wrap {
  margin-block: var(--space-lg);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  overflow-x: auto;
  background: var(--surface-raised);
}
table { width: 100%; border-collapse: collapse; font-size: var(--step-0); }
caption {
  padding: var(--space-md) var(--space-lg) 0;
  text-align: left;
  font-size: var(--step--1);
  font-weight: var(--weight-semi);
  letter-spacing: var(--tracking-wide);
  text-transform: uppercase;
  color: var(--text-muted);
}
th, td {
  padding: var(--space-md) var(--space-lg);
  text-align: left;
  vertical-align: top;
  border-bottom: 1px solid var(--border-subtle);
}
thead th {
  font-size: var(--step--1);
  font-weight: var(--weight-semi);
  letter-spacing: var(--tracking-wide);
  text-transform: uppercase;
  color: var(--text-muted);
  background: var(--surface-sunken);
}
tbody th { color: var(--text-strong); font-weight: var(--weight-semi); width: 34%; }
tbody tr:last-child th, tbody tr:last-child td { border-bottom: 0; }
tbody tr:hover td, tbody tr:hover th { background: color-mix(in srgb, var(--surface-sunken) 60%, transparent); }
td > :last-child { margin-bottom: 0; }

/* ==========================================================================
   §14. APPEL À L'ACTION DE BAS DE PAGE
   ========================================================================== */
.cta-panel {
  margin-top: var(--space-3xl);
  padding: var(--space-2xl);
  background: var(--surface-sunken);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  text-align: center;
}
.cta-panel h2 { margin-bottom: var(--space-sm); font-size: var(--step-2); }
.cta-panel p { max-width: 46ch; margin-inline: auto; color: var(--text-muted); }
.cta-panel .btn { margin-top: var(--space-lg); }

/* ==========================================================================
   §15. FORMULAIRE
   ========================================================================== */
.form-card {
  max-width: 34rem;
  padding: var(--space-xl);
  background: var(--surface-raised);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
}
.form-intro {
  margin-bottom: var(--space-lg);
  font-size: var(--step--1);
  color: var(--text-muted);
}
.field { margin: 0 0 var(--space-lg); }
.field label,
.field legend {
  display: block;
  margin-bottom: var(--space-2xs);
  font-weight: var(--weight-semi);
  color: var(--text-strong);
  font-size: var(--step-0);
}
.field .hint {
  display: block;
  margin-top: var(--space-2xs);
  font-weight: var(--weight-normal);
  font-size: var(--step--1);
  color: var(--text-muted);
}
.field .optional {
  font-weight: var(--weight-normal);
  font-size: var(--step--1);
  color: var(--text-muted);
}
.field p.hint { margin: 0 0 var(--space-xs); }

:where(fieldset.field) { min-width: 0; padding: 0; border: 0; }
.field legend { padding: 0; margin-bottom: var(--space-xs); }
.choice {
  display: flex;
  align-items: flex-start;
  gap: var(--space-xs);
  margin-bottom: var(--space-xs);
}
.choice:last-child { margin-bottom: 0; }
.field .choice label {
  margin: 0;
  font-weight: var(--weight-normal);
  color: var(--text);
  cursor: pointer;
}
.choice input {
  flex-shrink: 0;
  width: 1.15rem;
  height: 1.15rem;
  font: inherit;
  margin: calc((1lh - 1.15rem) / 2) 0 0;
  accent-color: var(--accent);
  cursor: pointer;
}

input:not([type="radio"], [type="checkbox"]), select, textarea {
  width: 100%;
  padding: 0.65rem 0.8rem;
  font: inherit;
  color: var(--text-strong);
  background-color: var(--surface-page);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  transition: border-color var(--duration) var(--ease),
              box-shadow var(--duration) var(--ease);
}
input::placeholder, textarea::placeholder { color: var(--text-muted); }
input:not([type="radio"], [type="checkbox"]):hover, select:hover, textarea:hover { border-color: var(--text-muted); }
input:not([type="radio"], [type="checkbox"]):focus, select:focus, textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 18%, transparent);
}
textarea { min-height: 9.5rem; resize: vertical; }

select {
  appearance: none;
  padding-right: 2.5rem;
  background-image:
    linear-gradient(45deg, transparent 50%, var(--text-muted) 50%),
    linear-gradient(135deg, var(--text-muted) 50%, transparent 50%);
  background-position:
    right 1.15rem center,
    right 0.8rem center;
  background-size: 0.35rem 0.35rem;
  background-repeat: no-repeat;
  cursor: pointer;
}
@supports (appearance: base-select) {
  select,
  select::picker(select) { appearance: base-select; }
  select::picker-icon { display: none; }

  select::picker(select) {
    max-block-size: min(20rem, 60vh);
    margin-block: var(--space-2xs);
    padding: 0;
    background: var(--surface-raised);
    border: 1px solid var(--border-strong);
    border-radius: var(--radius-sm);
    box-shadow: var(--shadow-md);
  }
  select option {
    padding: var(--space-xs) var(--space-sm);
    color: var(--text-strong);
    background: var(--surface-raised);
  }
  select option:hover,
  select option:focus-visible {
    outline: none;
    background: var(--surface-sunken);
  }
  select option:checked { font-weight: var(--weight-semi); color: var(--text-accent); }
  select option.option-pinned {
    position: sticky;
    inset-block-start: 0;
    z-index: 1;
    border-block-end: 1px solid var(--border);
  }
  select option.option-pinned:hover,
  select option.option-pinned:focus-visible { background: var(--surface-sunken); }
}

@media (forced-colors: active) {
  select { appearance: auto; background-image: none; padding-right: 0.8rem; }
}
.field--error {
  padding-left: var(--space-md);
  border-left: 3px solid var(--danger-line);
}
.field-error {
  margin: 0 0 var(--space-xs);
  font-size: var(--step--1);
  font-weight: var(--weight-semi);
  color: var(--danger);
}
[aria-invalid="true"]:not([type="radio"]) { border-color: var(--danger-line); }
[aria-invalid="true"]:not([type="radio"]):focus {
  border-color: var(--danger-line);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--danger-line) 22%, transparent);
}

.error-summary {
  margin-bottom: var(--space-xl);
  padding: var(--space-md) var(--space-lg);
  background: var(--danger-soft);
  border: 2px solid var(--danger-line);
  border-radius: var(--radius-md);
}
.error-summary h2 {
  margin: 0 0 var(--space-xs);
  font-size: var(--step-1);
  color: var(--text-strong);
}
.error-summary p { margin-bottom: var(--space-xs); }
.error-summary ul { margin: 0; padding-left: var(--space-lg); }
.error-summary a { color: var(--danger); font-weight: var(--weight-semi); }

.form-status:empty { display: none; }
.form-status {
  margin-bottom: var(--space-md);
  font-size: var(--step--1);
  color: var(--text-muted);
}
.form-status--error {
  padding: var(--space-sm) var(--space-md);
  background: var(--danger-soft);
  border-left: 3px solid var(--danger-line);
  border-radius: var(--radius-sm);
  color: var(--text-strong);
}
.btn[aria-disabled="true"] { opacity: 0.7; cursor: progress; transform: none; box-shadow: none; }

.form-success { border-top: 4px solid var(--success); }
.form-success h2 {
  display: flex;
  align-items: center;
  gap: var(--space-xs);
  margin: 0 0 var(--space-sm);
  font-size: var(--step-2);
  color: var(--text-strong);
}
.form-success h2::before {
  content: "✓" / "";
  display: inline-grid;
  place-items: center;
  flex-shrink: 0;
  width: 1.6em;
  height: 1.6em;
  border-radius: var(--radius-pill);
  background: var(--success-soft);
  color: var(--success);
  font-size: 0.75em;
}
.form-success:focus { outline: none; }
.form-success:focus-visible { outline: 2px solid var(--focus-ring); outline-offset: 3px; }

.honeypot {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.form-legal {
  max-width: 34rem;
  margin-top: var(--space-lg);
  font-size: var(--step--1);
  line-height: 1.55;
  color: var(--text-muted);
}

/* ==========================================================================
   §16. MARQUEURS DE TRAVAIL — à ne plus voir à la mise en ligne
   ========================================================================== */
.todo {
  display: inline-block;
  padding: 0.1em 0.5em;
  border: 1px dashed #b8912f;
  border-radius: var(--radius-sm);
  background: #fff6db;
  color: #6b520a;
  font-size: 0.92em;
  font-style: normal;
}
.todo::before { content: "À COMPLÉTER — "; font-weight: var(--weight-bold); letter-spacing: 0.04em; }
@media (prefers-color-scheme: dark) {
  .todo { background: #3a2f10; color: #f0d998; border-color: #7d6520; }
}

/* ==========================================================================
   §17. PIED DE PAGE
   ========================================================================== */
.site-foot {
  margin-top: var(--space-4xl);
  padding-block: var(--space-2xl);
  background: var(--surface-sunken);
  border-top: 1px solid var(--border-subtle);
  font-size: var(--step--1);
  color: var(--text-muted);
}
.foot-grid {
  display: grid;
  gap: var(--space-xl);
  grid-template-columns: repeat(auto-fit, minmax(min(14rem, 100%), 1fr));
  margin-bottom: var(--space-xl);
}
.foot-grid h2 {
  margin-bottom: var(--space-sm);
  font-size: var(--step--1);
  font-weight: var(--weight-semi);
  letter-spacing: var(--tracking-wide);
  text-transform: uppercase;
  color: var(--text-muted);
}
.foot-grid ul { list-style: none; padding: 0; margin: 0; }
.foot-grid li { margin-bottom: var(--space-xs); }
.foot-grid a { color: var(--text); text-decoration: none; }
.foot-grid a:hover { color: var(--accent); }
.foot-brand p { max-width: 32ch; margin-top: var(--space-xs); }
.foot-brand .brand { font-size: var(--step-1); }
.foot-bottom {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-md);
  justify-content: space-between;
  padding-top: var(--space-lg);
  border-top: 1px solid var(--border-subtle);
}
.foot-bottom p { margin: 0; }
