/*
 * Sans mètre — système de design commun
 * Papier crème, encre, fil terracotta, vert sauge. Mobile d'abord, contrastes AA,
 * cibles tactiles ≥ 44 px, focus visibles, mode sombre respecté.
 * Aucune police externe : piles de polices système (aucune requête vers un tiers
 * sur des pages qui manipulent des photos du corps).
 */

/* ------------------------------------------------------------------ jetons */
:root {
  color-scheme: light dark;

  --paper: #faf6ef;
  --paper-2: #f2ebdf;
  --surface: #fffdf9;
  --ink: #1f2230;
  --ink-2: #4a4f5e;
  --ink-3: #62677a;
  --line: #e3d9c9;
  --line-strong: #8c8272;

  --thread: #a8472c;         /* fil terracotta : actions principales */
  --thread-strong: #8e3a22;
  --thread-soft: #f6e4db;
  --on-thread: #ffffff;

  --sage: #4a6650;           /* vert sauge : réussite */
  --sage-soft: #e2ebe2;
  --ochre: #855600;          /* ocre : avertissement */
  --ochre-soft: #f7ebcf;
  --danger: #a12a2a;
  --danger-soft: #f8e1de;
  --on-danger: #ffffff;      /* texte sur fond --danger : 7,3:1 */
  --info: #2f5a8c;
  --info-soft: #e2ebf5;
  --focus: #1d4ed8;

  --tape: #ecd9a4;           /* ruban de couturière (barre de progression) */
  --tape-ink: #5c4a1e;

  --shadow-1: 0 1px 2px rgb(31 34 48 / 6%), 0 2px 10px rgb(31 34 48 / 6%);
  --shadow-2: 0 10px 30px rgb(31 34 48 / 14%);

  --radius-s: 8px;
  --radius: 14px;
  --radius-l: 22px;

  --font-serif: "Iowan Old Style", "Palatino Linotype", Palatino, "Book Antiqua", "URW Palladio L", P052, Georgia, serif;
  --font-sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", "Noto Sans", Arial, sans-serif;
  --font-mono: ui-monospace, "SF Mono", "Cascadia Mono", "Roboto Mono", Menlo, Consolas, monospace;

  --step--1: 0.875rem;
  --step-0: 1.0625rem;
  --step-1: 1.1875rem;
  --step-2: 1.45rem;
  --step-3: clamp(1.7rem, 1.35rem + 1.6vw, 2.3rem);
  --step-4: clamp(2.2rem, 1.5rem + 3.4vw, 3.7rem);

  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.5rem;
  --space-6: 2rem;
  --space-7: 3rem;
  --space-8: 4.5rem;

  --tap: 44px;
  --measure: 38rem;
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
}

@media (prefers-color-scheme: dark) {
  :root {
    --paper: #16171b;
    --paper-2: #1d1f24;
    --surface: #23252b;
    --ink: #f2ece2;
    --ink-2: #cbc4b8;
    --ink-3: #aaa397;
    --line: #34363d;
    --line-strong: #807a6f;

    --thread: #e58e70;
    --thread-strong: #f2a88e;
    --thread-soft: #3a2620;
    --on-thread: #1a1410;

    --sage: #9cc3a3;
    --sage-soft: #1f2b22;
    --ochre: #e6b95e;
    --ochre-soft: #2e2615;
    --danger: #f29387;
    --danger-soft: #3a1f1d;
    --on-danger: #1a1410;    /* texte sombre sur saumon : 8,1:1 (le blanc n'atteignait que 2,26:1) */
    --info: #93b7e6;
    --info-soft: #1b2633;
    --focus: #8ab4ff;

    --tape: #54482a;
    --tape-ink: #f0e2b8;

    --shadow-1: 0 1px 2px rgb(0 0 0 / 30%), 0 2px 10px rgb(0 0 0 / 25%);
    --shadow-2: 0 10px 30px rgb(0 0 0 / 45%);
  }
}

/* ------------------------------------------------------------------ base */
*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}
/* Défilement doux seulement pour les ancres de la page d'accueil : un changement
   d'étape du parcours doit afficher la nouvelle étape instantanément, par son haut. */
html:has(body.home) { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html:has(body.home) { scroll-behavior: auto; } }

body {
  margin: 0;
  min-height: 100vh;
  min-height: 100dvh;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: var(--step-0);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img, svg, video, canvas { display: block; max-width: 100%; }
svg { overflow: visible; }

h1, h2, h3, h4 {
  font-family: var(--font-serif);
  font-weight: 600;
  line-height: 1.15;
  letter-spacing: -0.01em;
  margin: 0 0 var(--space-3);
  text-wrap: balance;
}
h1 { font-size: var(--step-3); }
h2 { font-size: var(--step-2); }
h3 { font-size: var(--step-1); }
p { margin: 0 0 var(--space-4); text-wrap: pretty; }
ul, ol { margin: 0 0 var(--space-4); padding-left: 1.25rem; }
li + li { margin-top: var(--space-1); }
strong { font-weight: 650; }
small { font-size: var(--step--1); }

a {
  color: var(--thread);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
}
a:hover { color: var(--thread-strong); text-decoration-thickness: 2px; }

hr { border: 0; height: 2px; margin: var(--space-6) 0; background: var(--line); }

::selection { background: var(--thread-soft); color: var(--ink); }

:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
  border-radius: 4px;
}
[tabindex="-1"]:focus { outline: none; }

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

/* ------------------------------------------------------------------ utilitaires */
.sr-only {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0);
  white-space: nowrap; border: 0;
}

.skip-link {
  position: absolute;
  left: var(--space-3);
  top: -100px;
  z-index: 1000;
  padding: var(--space-3) var(--space-4);
  background: var(--ink);
  color: var(--paper);
  border-radius: var(--radius-s);
  font-weight: 600;
  text-decoration: none;
}
.skip-link:focus { top: var(--space-3); color: var(--paper); }

[hidden] { display: none !important; }

.container { width: min(100% - 2rem, 72rem); margin-inline: auto; }
.container-narrow { width: min(100% - 2rem, var(--measure)); margin-inline: auto; }

.stack { display: flex; flex-direction: column; gap: var(--space-4); }
.stack-s { display: flex; flex-direction: column; gap: var(--space-2); }
.stack-l { display: flex; flex-direction: column; gap: var(--space-6); }
.stack > *, .stack-s > *, .stack-l > * { margin-block: 0; }
.cluster { display: flex; flex-wrap: wrap; gap: var(--space-3); align-items: center; }
.spread { display: flex; justify-content: space-between; gap: var(--space-3); align-items: center; }

.muted { color: var(--ink-2); }
.subtle { color: var(--ink-3); font-size: var(--step--1); }
.lead { font-size: var(--step-1); color: var(--ink-2); }
.center { text-align: center; }
.nowrap { white-space: nowrap; }
.num { font-variant-numeric: tabular-nums; }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  margin: 0 0 var(--space-2);
  color: var(--thread);
  font-family: var(--font-sans);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

/* Surpiqûre : le motif signature (ligne de points de couture) */
.stitch {
  height: 2px;
  border: 0;
  margin: var(--space-5) 0;
  background: repeating-linear-gradient(90deg, var(--thread) 0 9px, transparent 9px 15px);
  opacity: 0.75;
}
.stitch-box {
  position: relative;
  border-radius: var(--radius);
  outline: 2px dashed color-mix(in srgb, var(--thread) 55%, transparent);
  outline-offset: -8px;
}

/* ------------------------------------------------------------------ icônes */
.icon {
  width: 1.25em;
  height: 1.25em;
  flex: none;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
  vertical-align: -0.25em;
  display: inline-block;
}
.icon-l { width: 1.75rem; height: 1.75rem; }
.icon-xl { width: 2.5rem; height: 2.5rem; stroke-width: 1.5; }

/* ------------------------------------------------------------------ boutons */
.btn {
  --btn-bg: var(--thread);
  --btn-fg: var(--on-thread);
  --btn-border: var(--thread);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  min-height: 50px;
  min-width: var(--tap);
  padding: 0.7rem 1.35rem;
  border: 2px solid var(--btn-border);
  border-radius: 999px;
  background: var(--btn-bg);
  color: var(--btn-fg);
  font: inherit;
  font-weight: 650;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
  transition: background-color 0.15s var(--ease), color 0.15s var(--ease), transform 0.1s var(--ease), box-shadow 0.15s var(--ease);
}
.btn:hover { --btn-bg: var(--thread-strong); --btn-border: var(--thread-strong); color: var(--btn-fg); text-decoration: none; }
.btn:active { transform: translateY(1px) scale(0.99); }
.btn:focus-visible { outline-offset: 3px; border-radius: 999px; }
.btn[disabled], .btn[aria-disabled="true"] { opacity: 0.55; cursor: not-allowed; transform: none; }

.btn-secondary {
  --btn-bg: transparent;
  --btn-fg: var(--ink);
  --btn-border: var(--line-strong);
}
.btn-secondary:hover { --btn-bg: var(--paper-2); --btn-border: var(--ink-2); --btn-fg: var(--ink); }

.btn-ghost {
  --btn-bg: transparent;
  --btn-fg: var(--thread);
  --btn-border: transparent;
  padding-inline: 0.8rem;
}
.btn-ghost:hover { --btn-bg: var(--thread-soft); --btn-border: transparent; --btn-fg: var(--thread-strong); }

.btn-danger { --btn-bg: var(--danger); --btn-border: var(--danger); --btn-fg: var(--on-danger); }
.btn-danger:hover { --btn-bg: var(--danger); filter: brightness(0.92); }

.btn-sm { min-height: var(--tap); padding: 0.45rem 0.95rem; font-size: var(--step--1); }
.btn-block { display: flex; width: 100%; }
.btn-icon { padding: 0; width: var(--tap); height: var(--tap); min-height: var(--tap); border-radius: 50%; }

.actions {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  margin-top: var(--space-5);
}
@media (min-width: 34rem) {
  .actions { flex-direction: row-reverse; justify-content: flex-start; flex-wrap: wrap; }
  .actions .btn { min-width: 11rem; }
}

.link-button {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  min-height: var(--tap);
  padding: 0 var(--space-1);
  border: 0;
  background: none;
  color: var(--thread);
  font: inherit;
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 0.18em;
  cursor: pointer;
}
.link-button:hover { color: var(--thread-strong); }

/* ------------------------------------------------------------------ cartes */
.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: var(--space-5);
  box-shadow: var(--shadow-1);
}
.card > :last-child { margin-bottom: 0; }
.card-flat { box-shadow: none; }
.card-tinted { background: var(--paper-2); border-color: transparent; box-shadow: none; }

/* ------------------------------------------------------------------ messages */
.notice {
  --notice-fg: var(--info);
  --notice-bg: var(--info-soft);
  display: grid;
  grid-template-columns: auto 1fr;
  gap: var(--space-3);
  align-items: start;
  padding: var(--space-4);
  border-radius: var(--radius);
  border: 1px solid color-mix(in srgb, var(--notice-fg) 30%, transparent);
  border-left-width: 5px;
  background: var(--notice-bg);
  color: var(--ink);
}
.notice > .icon { color: var(--notice-fg); width: 1.5rem; height: 1.5rem; margin-top: 0.05rem; }
.notice-title { margin: 0 0 var(--space-1); font-weight: 700; font-family: var(--font-sans); font-size: var(--step-0); }
.notice-body > :last-child { margin-bottom: 0; }
.notice-body ul { margin-bottom: 0; }
.notice-success { --notice-fg: var(--sage); --notice-bg: var(--sage-soft); }
.notice-warning { --notice-fg: var(--ochre); --notice-bg: var(--ochre-soft); }
.notice-error { --notice-fg: var(--danger); --notice-bg: var(--danger-soft); }

.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.15rem 0.6rem;
  border-radius: 999px;
  background: var(--paper-2);
  color: var(--ink-2);
  font-size: var(--step--1);
  font-weight: 600;
}
.badge-success { background: var(--sage-soft); color: var(--sage); }
.badge-warning { background: var(--ochre-soft); color: var(--ochre); }
.badge-error { background: var(--danger-soft); color: var(--danger); }

/* ------------------------------------------------------------------ formulaires */
.field { display: flex; flex-direction: column; gap: var(--space-2); margin: 0; }
.field + .field { margin-top: var(--space-5); }
.label { font-weight: 650; }
.label .optional { font-weight: 400; color: var(--ink-2); }
.help { margin: 0; color: var(--ink-2); font-size: var(--step--1); }
.error-text {
  display: flex;
  gap: var(--space-2);
  align-items: flex-start;
  margin: 0;
  color: var(--danger);
  font-size: var(--step--1);
  font-weight: 600;
}

.input {
  width: 100%;
  min-height: 52px;
  padding: 0.7rem 0.9rem;
  border: 2px solid var(--line-strong);
  border-radius: var(--radius-s);
  background: var(--surface);
  color: var(--ink);
  font: inherit;
  font-size: max(16px, var(--step-0)); /* évite le zoom automatique d'iOS */
  transition: border-color 0.15s var(--ease), box-shadow 0.15s var(--ease);
}
.input:hover { border-color: var(--ink-2); }
.input:focus-visible { outline: none; border-color: var(--focus); box-shadow: 0 0 0 3px color-mix(in srgb, var(--focus) 30%, transparent); }
.input[aria-invalid="true"] { border-color: var(--danger); }

.input-unit { position: relative; display: flex; align-items: center; max-width: 14rem; }
.input-unit .input { padding-right: 3.2rem; font-variant-numeric: tabular-nums; }
.input-unit .unit { position: absolute; right: 0.9rem; color: var(--ink-2); font-weight: 600; pointer-events: none; }

fieldset { border: 0; padding: 0; margin: 0; min-width: 0; }
legend { padding: 0; font-weight: 650; margin-bottom: var(--space-2); }

/* Cases à cocher et boutons radio de grande taille */
.check {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: var(--space-3);
  align-items: start;
  padding: var(--space-3) var(--space-4);
  min-height: var(--tap);
  border: 2px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  cursor: pointer;
  transition: border-color 0.15s var(--ease), background-color 0.15s var(--ease);
}
.check:hover { border-color: var(--line-strong); }
.check:has(input:checked) { border-color: var(--thread); background: color-mix(in srgb, var(--thread-soft) 55%, var(--surface)); }
.check:has(input:focus-visible) { outline: 3px solid var(--focus); outline-offset: 2px; }
.check:has(input[aria-invalid="true"]) { border-color: var(--danger); }
.check + .check { margin-top: var(--space-3); }
.check-text { display: block; }
.check-text small { display: block; color: var(--ink-2); margin-top: 0.15rem; }

.check input[type="checkbox"], .check input[type="radio"],
.choice input[type="radio"] {
  appearance: none;
  -webkit-appearance: none;
  width: 1.6rem;
  height: 1.6rem;
  margin: 0.05rem 0 0;
  border: 2px solid var(--line-strong);
  background: var(--surface);
  display: grid;
  place-content: center;
  cursor: pointer;
  flex: none;
}
.check input[type="checkbox"] { border-radius: 6px; }
.check input[type="radio"], .choice input[type="radio"] { border-radius: 50%; }
.check input[type="checkbox"]::after {
  content: "";
  width: 0.95rem;
  height: 0.55rem;
  border: solid var(--on-thread);
  border-width: 0 0 3px 3px;
  transform: rotate(-45deg) translate(1px, -1px) scale(0);
  transition: transform 0.12s var(--ease);
}
.check input[type="radio"]::after, .choice input[type="radio"]::after {
  content: "";
  width: 0.7rem;
  height: 0.7rem;
  border-radius: 50%;
  background: var(--on-thread);
  transform: scale(0);
  transition: transform 0.12s var(--ease);
}
.check input:checked, .choice input:checked { background: var(--thread); border-color: var(--thread); }
.check input:checked::after, .choice input:checked::after { transform: rotate(-45deg) translate(1px, -1px) scale(1); }
.check input[type="radio"]:checked::after, .choice input[type="radio"]:checked::after { transform: scale(1); }
.check input:focus-visible, .choice input:focus-visible { outline: none; }

/* Cartes de choix (radio) avec illustration */
.choices { display: grid; gap: var(--space-3); grid-template-columns: repeat(auto-fill, minmax(9.5rem, 1fr)); }
.choices-inline { grid-template-columns: repeat(auto-fill, minmax(8.5rem, 1fr)); }
.choice {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-3);
  min-height: var(--tap);
  border: 2px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  text-align: center;
  cursor: pointer;
  transition: border-color 0.15s var(--ease), background-color 0.15s var(--ease);
}
.choice:hover { border-color: var(--line-strong); }
.choice:has(input:checked) { border-color: var(--thread); background: color-mix(in srgb, var(--thread-soft) 55%, var(--surface)); }
.choice:has(input:focus-visible) { outline: 3px solid var(--focus); outline-offset: 2px; }
.choice input[type="radio"] { position: absolute; top: 0.6rem; left: 0.6rem; width: 1.3rem; height: 1.3rem; }
.choice-row { flex-direction: row; justify-content: flex-start; text-align: left; padding-left: 2.6rem; }
.choice-row input[type="radio"] { top: 50%; transform: translateY(-50%); }
.choice-title { font-weight: 650; line-height: 1.25; }
.choice-desc { color: var(--ink-2); font-size: var(--step--1); line-height: 1.35; }
.choice svg.figure { width: 4.5rem; height: 5.5rem; color: var(--ink); }

/* ------------------------------------------------------------------ listes */
.list-plain { list-style: none; padding: 0; margin: 0; }
.list-steps { counter-reset: step; list-style: none; padding: 0; margin: 0; display: grid; gap: var(--space-4); }
.list-steps > li { counter-increment: step; display: grid; grid-template-columns: 2.4rem 1fr; gap: var(--space-3); align-items: start; margin: 0; }
.list-steps > li::before {
  content: counter(step);
  display: grid;
  place-items: center;
  width: 2.4rem;
  height: 2.4rem;
  border-radius: 50%;
  border: 2px dashed var(--thread);
  color: var(--thread);
  font-family: var(--font-serif);
  font-weight: 700;
  font-size: 1.15rem;
}
.list-steps strong { display: block; }

.list-icons { list-style: none; padding: 0; margin: 0; display: grid; gap: var(--space-3); }
.list-icons > li { display: grid; grid-template-columns: auto 1fr; gap: var(--space-3); align-items: start; margin: 0; }
.list-icons > li > .icon { color: var(--thread); margin-top: 0.1rem; width: 1.5rem; height: 1.5rem; }

/* ------------------------------------------------------------------ tableau de mesures */
.measures { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
.measures th, .measures td { padding: 0.7rem 0.25rem; border-bottom: 1px dashed var(--line-strong); text-align: left; vertical-align: baseline; }
.measures th { font-weight: 500; color: var(--ink); }
.measures td { text-align: right; font-weight: 700; white-space: nowrap; font-family: var(--font-serif); font-size: var(--step-1); }
.measures tr:last-child th, .measures tr:last-child td { border-bottom: 0; }

/* ------------------------------------------------------------------ ruban (progression) */
.tape {
  position: relative;
  height: 14px;
  border-radius: 3px;
  background:
    repeating-linear-gradient(90deg, var(--tape-ink) 0 1px, transparent 1px 10px) bottom left / 100% 5px no-repeat,
    repeating-linear-gradient(90deg, var(--tape-ink) 0 1px, transparent 1px 50px) bottom left / 100% 9px no-repeat,
    var(--tape);
  box-shadow: inset 0 -1px 0 rgb(0 0 0 / 8%);
  overflow: hidden;
}
.tape-fill {
  position: absolute;
  inset: 0 auto 0 0;
  width: 0;
  background: color-mix(in srgb, var(--thread) 82%, transparent);
  transition: width 0.45s var(--ease);
}
.tape-fill::after {
  content: "";
  position: absolute;
  right: -1px;
  top: -2px;
  bottom: -2px;
  width: 3px;
  background: var(--ink);
  border-radius: 2px;
}

/* ------------------------------------------------------------------ attente */
.spool {
  width: 3.5rem;
  height: 3.5rem;
  color: var(--thread);
}
.spool .spool-thread { transform-origin: 50% 50%; animation: spool-spin 1.6s linear infinite; }
@keyframes spool-spin { to { transform: rotate(360deg); } }

.spinner {
  display: inline-block;
  width: 1.25em;
  height: 1.25em;
  border: 3px solid color-mix(in srgb, currentColor 25%, transparent);
  border-top-color: currentColor;
  border-radius: 50%;
  animation: spool-spin 0.9s linear infinite;
  vertical-align: -0.25em;
}

.bar {
  height: 10px;
  border-radius: 999px;
  background: var(--paper-2);
  overflow: hidden;
  border: 1px solid var(--line);
}
.bar > span { display: block; height: 100%; width: 0; background: var(--thread); border-radius: inherit; transition: width 0.2s linear; }
.bar-indeterminate > span {
  width: 35%;
  animation: bar-slide 1.4s var(--ease) infinite;
}
@keyframes bar-slide { from { transform: translateX(-100%); } to { transform: translateX(300%); } }

/* ------------------------------------------------------------------ détails / accordéons */
details.disclosure {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}
details.disclosure > summary {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  min-height: var(--tap);
  padding: var(--space-3) var(--space-4);
  cursor: pointer;
  font-weight: 650;
  list-style: none;
}
details.disclosure > summary::-webkit-details-marker { display: none; }
details.disclosure > summary::after {
  content: "";
  margin-left: auto;
  width: 0.55rem;
  height: 0.55rem;
  border: solid currentColor;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
  transition: transform 0.15s var(--ease);
}
details.disclosure[open] > summary::after { transform: rotate(-135deg); }
details.disclosure > .disclosure-body { padding: 0 var(--space-4) var(--space-4); }
details.disclosure > .disclosure-body > :last-child { margin-bottom: 0; }

/* ------------------------------------------------------------------ marque */
.brand {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  color: var(--ink);
  font-family: var(--font-serif);
  font-weight: 700;
  font-size: 1.3rem;
  letter-spacing: 0.01em;
  text-decoration: none;
  white-space: nowrap; /* « Sans mètre » ne se coupe jamais */
}
.brand:hover { color: var(--ink); text-decoration: none; }
.brand svg { width: 1.9rem; height: 1.9rem; }
/* Logo (sprite.svg#logo) : trait = couleur du texte ; découpes = --logo-cut, sinon --paper.
   Sur une carte, les découpes prennent la couleur de la carte. */
.card .logo { --logo-cut: var(--surface); }

.demo-banner {
  display: flex;
  gap: var(--space-2);
  align-items: center;
  justify-content: center;
  padding: var(--space-2) var(--space-4);
  background: var(--ochre-soft);
  color: var(--ink);
  border-bottom: 1px solid color-mix(in srgb, var(--ochre) 40%, transparent);
  font-size: var(--step--1);
  font-weight: 600;
  text-align: center;
}
.demo-banner .icon { color: var(--ochre); }

.toast-region {
  position: fixed;
  left: 50%;
  bottom: max(1rem, env(safe-area-inset-bottom));
  transform: translateX(-50%);
  z-index: 900;
  display: grid;
  gap: var(--space-2);
  width: min(100% - 2rem, 28rem);
  pointer-events: none;
}
.toast {
  padding: var(--space-3) var(--space-4);
  border-radius: var(--radius);
  background: var(--ink);
  color: var(--paper);
  box-shadow: var(--shadow-2);
  font-weight: 600;
  animation: toast-in 0.25s var(--ease);
}
@keyframes toast-in { from { opacity: 0; transform: translateY(8px); } }

/* ------------------------------------------------------------------ texte long (notices) */
.doc h2 { margin-top: var(--space-6); font-size: var(--step-2); }
.doc .notice { margin: var(--space-5) 0; }
.doc li { margin-top: var(--space-2); }
.table-wrap { overflow-x: auto; margin: 0 0 var(--space-4); }
.doc-table { width: 100%; border-collapse: collapse; font-size: var(--step--1); }
.doc-table th, .doc-table td { padding: 0.65rem 0.5rem; border-bottom: 1px dashed var(--line-strong); text-align: left; vertical-align: top; }
.doc-table thead th { border-bottom: 2px solid var(--ink); font-weight: 700; }
.doc-table tbody th { font-weight: 650; width: 40%; }
