/* ============================================================
   DINGBAT — atelier typographique instrumenté
   design system : monochrome phosphore + un seul accent
   ============================================================ */

:root {
  --bg: #0c0b0d;
  --bg-raise: #100f12;
  --ink: #e6dfd8;
  --dim: #97a09a;
  --chrome: #b8b3ae;
  --line: #1e1d20;
  --line-soft: #17161a;

  /* accent unique — corail de la charte */
  --accent: #de0f5a;
  --accent-soft: rgba(222, 15, 90, 0.14);

  /* couleurs de syntaxe (buffer) */
  --kw: #bd5cff;
  --str: #f2f2ea;
  --fn: #6c70e0;
  --ty: #53b1ca;
  --num: #ff5c8a;

  --mono: "IBM Plex Mono", ui-monospace, "SFMono-Regular", monospace;
  --sans: "Archivo", system-ui, sans-serif;
  --matrix: "MatrixType", "IBM Plex Mono", monospace;
  --matrix-display: "MatrixTypeDisplay", "MatrixType", "IBM Plex Mono", monospace;

  --margin: 40px;
  --bar-h: 46px;
  --wide: 1080px;

  /* détails qui suivent le fond (thème clair) */
  --ln-num: #34333a;
  --dot: #3a393f;
  --cell-hover: #131216;
  --grid-gap: #1e1d20;
  --scan: rgba(255, 255, 255, 0.016);
  --vignette: rgba(0, 0, 0, 0.5);
}

[data-theme="bleu"] {
  --accent: #4d4dff;
  --accent-soft: rgba(77, 77, 255, 0.16);
  --num: #8f8fff;
}

/* ---------- kam-dingbat : le thème jour (charte, versions claires) ---------- */
[data-theme="kam-dingbat"] {
  --bg: #f2ede4;
  --bg-raise: #faf7f1;
  --ink: #26242b;
  --dim: #7d766c;
  --chrome: #55515a;
  --line: #c9c0b0;
  --line-soft: #dcd5c8;

  /* accents de la charte, accordés au papier */
  --accent: #c20e4e;
  --accent-soft: rgba(194, 14, 78, 0.10);

  --kw: #7d2be0;
  --str: #26242b;
  --fn: #3a3ac0;
  --ty: #0e6e86;
  --num: #b5124f;

  --ln-num: #b9b1a4;
  --dot: #b9b1a4;
  --cell-hover: #ede7db;
  --grid-gap: #a99e88;
  --scan: rgba(38, 36, 43, 0.02);
  --vignette: rgba(120, 105, 80, 0.14);
}

*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
html { -webkit-text-size-adjust: 100%; }

body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--mono);
  font-size: 14px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

a, button { color: inherit; }
button { font: inherit; }
a { text-decoration: none; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }

/* coupe de ligne gracieuse : pas de mot orphelin, titres équilibrés.
   ignoré par les navigateurs qui ne le connaissent pas. */
p, li, .desc, .lead, .quote { text-wrap: pretty; }
h1, h2, h3, .cell .name, .measure span { text-wrap: balance; }

.sr-only {
  position: absolute; width: 1px; height: 1px; margin: -1px;
  clip-path: inset(50%); overflow: hidden; white-space: nowrap;
}

/* ---------- frame : header ---------- */
.frame-top {
  position: absolute;
  top: 22px; left: var(--margin); right: var(--margin);
  z-index: 8;
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px;
  pointer-events: none;
}
.frame-top > * { pointer-events: auto; }

.brand {
  display: inline-flex; align-items: center; gap: 10px;
  letter-spacing: 0.08em;
}
.brand svg { width: 26px; height: 26px; fill: var(--ink); display: block; }
.brand svg .bang { fill: var(--accent); }
.brand span { font-size: 13px; font-weight: 600; }
.brand:hover svg { fill: var(--accent); }
.brand:hover svg .bang { fill: var(--ink); }

.switch { display: flex; align-items: center; gap: 4px; }
.switch a {
  font-size: 12px; color: var(--chrome);
  padding: 5px 9px; border: 1px solid transparent;
  letter-spacing: 0.04em;
}
.switch a:hover { color: var(--ink); border-color: var(--line); }
.switch a[aria-current="page"] { color: var(--accent); border-color: var(--line); }
.switch .sep { color: var(--line); user-select: none; }

/* ---------- scène plein écran (home) ---------- */
.stage {
  position: relative;
  height: 100svh;
  min-height: 560px;
  overflow: hidden;
}

/* scanlines + vignette, très discrètes */
.stage::after {
  content: "";
  position: absolute; inset: 0; z-index: 7;
  pointer-events: none;
  background:
    repeating-linear-gradient(0deg, var(--scan) 0 1px, transparent 1px 3px),
    radial-gradient(120% 90% at 50% 40%, transparent 60%, var(--vignette) 100%);
}

/* ---------- éditeur ---------- */
.editor {
  position: absolute;
  top: 74px; bottom: calc(var(--bar-h) + 18px);
  left: var(--margin); right: var(--margin);
  z-index: 5;
  display: grid;
  grid-template-rows: auto 1fr;
  border: 1px solid var(--line);
  background: var(--bg-raise);
}

.tabline {
  display: flex; align-items: center; gap: 12px;
  background: none; border: 0; border-bottom: 1px solid var(--line);
  padding: 9px 14px; text-align: left; cursor: pointer;
  color: var(--chrome); font-size: 12px; letter-spacing: 0.05em;
}
.tabline .tab-dir { color: var(--ink); }
.tabline .tab-file { color: var(--dim); }
.tabline .tab-toggle { margin-left: auto; transition: transform 0.25s; }
.tabline[aria-expanded="true"] .tab-toggle { transform: rotate(180deg); }

.wheel {
  display: none;
  border-bottom: 1px solid var(--line);
  padding: 10px 14px;
  max-height: 34vh; overflow: auto;
}
.wheel.open { display: block; }
.wheel a {
  display: flex; justify-content: space-between; gap: 12px;
  padding: 4px 8px; font-size: 13px; color: var(--chrome);
}
.wheel a:hover, .wheel a:focus-visible { color: var(--ink); background: var(--accent-soft); }
.wheel a .hint { color: var(--dim); font-size: 11px; }
.wheel a[aria-current="true"] { color: var(--accent); }

.pane {
  position: relative;
  display: grid;
  grid-template-rows: auto 1fr;
  min-height: 0;
}
.winbar {
  margin: 0;
  padding: 7px 14px;
  font-size: 11px; color: var(--dim); letter-spacing: 0.06em;
  border-bottom: 1px solid var(--line-soft);
  display: flex; gap: 14px;
}
.winbar .dot { width: 7px; height: 7px; border: 1px solid var(--dot); border-radius: 50%; display: inline-block; }
.winbar .dot.on { background: var(--accent); border-color: var(--accent); }

.buffer {
  overflow: auto;
  padding: 26px 30px 56px 62px;
  min-height: 0;
  position: relative;
  counter-reset: ln;
  scrollbar-width: thin;
  scrollbar-color: var(--line) transparent;
}
/* gouttière de numéros de ligne — l'éditeur */
.buffer > * { counter-increment: ln; position: relative; }
.buffer > *::before {
  content: counter(ln, decimal-leading-zero);
  position: absolute; left: -38px; top: 0.25em;
  width: 26px; text-align: right;
  color: var(--ln-num); font-size: 11px; font-weight: 400;
  user-select: none; pointer-events: none;
}
.buffer > .ticker::before, .buffer > .quote::before { left: -38px; }

/* fondu bas : le buffer continue sous la barre */
.pane { position: relative; }
.pane::after {
  content: "";
  position: absolute; left: 1px; right: 9px; bottom: 1px; height: 34px;
  background: linear-gradient(transparent 55%, var(--bg-raise));
  pointer-events: none; z-index: 2;
}
.buffer::-webkit-scrollbar { width: 8px; }
.buffer::-webkit-scrollbar-thumb { background: var(--line); }

/* ancre de l'œil : invisible et fixe, l'œil est peint sur l'overlay, sur toutes les pages */
.eye-host {
  position: fixed;
  top: 84px; right: calc(var(--margin) + 18px);
  width: min(360px, 42vw);
  aspect-ratio: 1.7;
  pointer-events: none;
  z-index: 3;
}

/* overlay plein écran : l'oeil y est dessiné */
.overlay {
  position: fixed; inset: 0;
  width: 100vw; height: 100vh;
  z-index: 9;
  pointer-events: none;
}

/* ---------- contenu du buffer (markdown instrumenté) ---------- */
.buffer h2 {
  font-family: var(--mono);
  font-size: 12px; font-weight: 400; color: var(--kw);
  letter-spacing: 0.12em; text-transform: uppercase;
  margin: 34px 0 10px;
}
.buffer h2:first-child { margin-top: 0; }
.buffer h2 .hash { color: var(--line); margin-right: 8px; }

.buffer p { margin: 10px 0; max-width: 66ch; color: var(--ink); }
.buffer p.lead { font-size: 15px; }
.buffer .dim { color: var(--dim); }
.buffer a { color: var(--accent); text-decoration: none; border-bottom: 1px dotted var(--accent); }
.buffer a:hover { border-bottom-style: solid; }
.buffer .accent { color: var(--accent); }
.buffer .kw { color: var(--kw); }
.buffer .fn { color: var(--fn); }
.buffer .ty { color: var(--ty); }
.buffer .str { color: var(--str); }
.buffer .num { color: var(--num); }

.buffer .quote {
  font-family: var(--matrix); font-style: normal;
  font-size: 18px; line-height: 1.6; color: var(--ink);
  letter-spacing: 0.04em;
  border-left: 1px solid var(--accent);
  padding: 6px 0 6px 22px; margin: 26px 0;
  max-width: 54ch;
}
.buffer .quote .who {
  display: block; margin-top: 10px;
  font-family: var(--mono); font-style: normal;
  font-size: 11px; color: var(--dim); letter-spacing: 0.1em;
}

/* ---------- contact : l'invitation, en avant ---------- */
.buffer .invitation {
  position: relative;
  border: 1px solid var(--line);
  background: var(--bg-raise);
  padding: 28px 30px 24px;
  margin: 24px 0 32px;
  max-width: 680px;
}
.buffer .invitation .invite {
  font-family: var(--matrix-display); font-style: normal;
  font-size: 30px; line-height: 1.45; color: var(--ink);
  letter-spacing: 0.01em; white-space: pre-line;
  margin: 0 0 14px; cursor: pointer;
}
.buffer .invitation .invite::first-letter { color: var(--accent); }
.buffer .invitation .how {
  margin: 0; font-size: 13px; color: var(--chrome); max-width: 56ch;
}
.buffer .invitation .orn {
  position: absolute; top: -10px; left: 20px;
  background: var(--bg); padding: 0 9px;
  color: var(--accent); font-size: 14px; line-height: 1;
}

.buffer ul.tree { list-style: none; padding: 0; margin: 8px 0; max-width: 66ch; }
.buffer ul.tree li { padding: 3px 0 3px 18px; position: relative; color: var(--chrome); }
.buffer ul.tree li::before { content: "├─"; position: absolute; left: 0; color: var(--line); }
.buffer ul.tree li:last-child::before { content: "└─"; }

/* tableau clé-valeur à pointillés */
table.spec { border-collapse: collapse; width: 100%; max-width: 560px; margin: 14px 0; }
table.spec td { padding: 5px 0; vertical-align: bottom; font-size: 13px; }
table.spec td:first-child { color: var(--dim); white-space: nowrap; padding-right: 8px; }
table.spec td.dots { border-bottom: 1px dotted var(--line); }

/* variante menuee : presents mais en retrait (mentions legales) */
table.spec.mini { max-width: 480px; margin: 10px 0 4px; }
table.spec.mini td { font-size: 11px; padding: 3px 0; }
table.spec.mini td:last-child { color: var(--chrome); text-align: left; white-space: normal; }
table.spec.mini td:first-child { color: var(--dim); opacity: 0.8; }
table.spec td:last-child { text-align: right; color: var(--num); white-space: nowrap; padding-left: 8px; }
table.spec tr:hover td:last-child { color: var(--accent); }

/* ticker clients */
.ticker {
  overflow: hidden; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line);
  padding: 10px 0; margin: 22px 0; position: relative;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
          mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}
.ticker .track {
  display: inline-flex; gap: 34px; white-space: nowrap;
  animation: crawl 96s linear infinite;
}
.ticker span { color: var(--chrome); font-size: 12px; letter-spacing: 0.14em; }
.ticker span b { color: var(--accent); font-weight: 400; }
@keyframes crawl { to { transform: translateX(-50%); } }

/* annotation de mesure, façon plan technique */
.measure {
  display: flex; align-items: center; gap: 10px;
  color: var(--dim); font-size: 11px; letter-spacing: 0.08em;
  margin: 18px 0 6px;
}
.measure .rule { flex: 1; border-top: 1px solid var(--line); position: relative; }
.measure .rule::before, .measure .rule::after {
  content: ""; position: absolute; top: -4px; border-left: 1px solid var(--line); height: 9px;
}
.measure .rule::before { left: 0; } .measure .rule::after { right: 0; }

/* ---------- barre d'état ---------- */
.bar {
  position: absolute; left: var(--margin); right: var(--margin); bottom: 18px;
  z-index: 6;
  height: var(--bar-h);
  border: 1px solid var(--line);
  background: var(--bg-raise);
  display: flex; align-items: center; gap: 18px;
  padding: 0 14px;
  font-size: 11px; letter-spacing: 0.06em;
}
.bar-id { margin: 0; display: flex; align-items: baseline; gap: 14px; min-width: 0; }
.bar-title { color: var(--ink); font-weight: 600; letter-spacing: 0.14em; white-space: nowrap; }
.bar-sub { color: var(--dim); white-space: nowrap; overflow: hidden; }
.bar-sub .keys { color: var(--dim); }
.bar-sub kbd {
  font: inherit; color: var(--chrome);
  border: 1px solid var(--line); padding: 1px 5px; margin-right: 4px;
}
.bar-state { display: flex; gap: 22px; margin-left: auto; }
.bar-state .col { margin: 0; display: flex; flex-direction: column; line-height: 1.25; }
.bar-state .label { color: var(--dim); font-size: 9px; letter-spacing: 0.18em; }
.bar-state .value { color: var(--ink); }
.bar-state .value[data-live="1"] { color: var(--num); }

.den {
  width: 30px; height: 30px; flex: none;
  border: 1px solid var(--line); background: none; cursor: pointer;
  display: grid; place-items: center;
  color: var(--dim); font-size: 15px;
}
.den:hover { border-color: var(--accent); color: var(--accent); }
.den[aria-pressed="true"] { color: var(--accent); border-color: var(--accent); background: var(--accent-soft); }

.bar-graph { margin: 0; display: flex; align-items: center; gap: 10px; margin-right: 4px; }
.bar-graph .label { color: var(--dim); font-size: 9px; letter-spacing: 0.18em; }
.bar-graph .value { color: var(--num); font-size: 13px; }
.bar-graph canvas { width: 120px; height: 22px; display: block; }

/* ligne de commande */
.cmdline {
  display: none; align-items: center; gap: 8px;
  color: var(--ink);
}
.cmdline.open { display: inline-flex; }
.cmdline .prompt { color: var(--accent); }
.cmdline input {
  background: none; border: 0; border-bottom: 1px solid var(--accent);
  color: var(--ink); font: inherit; outline: none; width: 22ch;
}
.cmdline .out { color: var(--dim); }

/* ---------- dingbat errant ---------- */
.dingbat-wander {
  position: absolute; z-index: 6;
  left: 0; top: 0;
  font-size: 22px; color: var(--accent);
  pointer-events: auto; cursor: default;
  transition: opacity 0.6s;
  user-select: none;
  text-shadow: 0 0 18px var(--accent-soft);
  animation: breathe 4s ease-in-out infinite;
}
.dingbat-wander.asleep { opacity: 0.12; animation: none; }
@keyframes breathe { 50% { opacity: 0.55; } }

/* ---------- pages documents (intérieures) ---------- */
.doc-stage {
  position: relative;
  min-height: 100svh;
  padding: 74px var(--margin) calc(var(--bar-h) + 40px);
}
.doc {
  max-width: var(--wide);
  margin: 0 auto;
  border: 1px solid var(--line);
  background: var(--bg-raise);
}
.doc .tabline { cursor: default; }
.doc .buffer { padding: 34px 40px 56px 66px; }

/* grille services */
.grid-specs {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 0; background: var(--bg-raise); border: 1px solid var(--grid-gap);
  margin: 18px 0;
}
.grid-specs .cell { background: var(--bg-raise); border: 1px solid var(--grid-gap); padding: 18px 20px; position: relative; }
.grid-specs .cell:hover { background: var(--cell-hover); }
.grid-specs .cell h3 {
  margin: 0 0 8px; font-size: 13px; font-weight: 600; letter-spacing: 0.06em;
  color: var(--ink); padding-right: 96px;
}
.grid-specs .cell h3 .idx { color: var(--accent); font-weight: 400; margin-right: 8px; }
.grid-specs .cell p { margin: 0; font-size: 12.5px; color: var(--chrome); max-width: none; }
.grid-specs .cell .tag {
  position: absolute; top: 14px; right: 14px;
  font-size: 9px; letter-spacing: 0.16em; color: var(--dim);
}
.grid-specs .cell.ai { border-top: 2px solid var(--accent); }

/* cartes références */
.grid-refs {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 0; background: var(--bg-raise); border: 1px solid var(--grid-gap);
  margin: 18px 0;
}
.grid-refs a.cell { background: var(--bg-raise); border: 1px solid var(--grid-gap); padding: 18px 20px; display: block; }
.grid-refs a.cell:hover { background: var(--cell-hover); }
.grid-refs .name { color: var(--ink); font-size: 13px; letter-spacing: 0.05em; }
.grid-refs .desc { color: var(--dim); font-size: 12px; margin-top: 6px; }
.grid-refs .go { color: var(--accent); font-size: 11px; margin-top: 10px; display: inline-block; }

/* formulaire contact */
form.wire { max-width: 560px; margin: 18px 0; }
form.wire label {
  display: block; margin: 16px 0 4px;
  font-size: 11px; letter-spacing: 0.14em; color: var(--dim);
}
form.wire label .req { color: var(--accent); }
form.wire input, form.wire textarea {
  width: 100%; background: none;
  border: 0; border-bottom: 1px solid var(--line);
  color: var(--ink); font: inherit; padding: 8px 2px;
}
form.wire input:focus, form.wire textarea:focus {
  outline: none; border-bottom-color: var(--accent);
}
form.wire textarea { min-height: 110px; resize: vertical; }
form.wire button {
  margin-top: 22px;
  background: none; border: 1px solid var(--accent); color: var(--accent);
  padding: 10px 22px; cursor: pointer;
  font-size: 12px; letter-spacing: 0.14em;
}
form.wire button:hover { background: var(--accent); color: var(--bg); }

/* coordonnées */
.wires { display: flex; flex-wrap: wrap; gap: 26px; margin: 18px 0; }
.wires .wire-col { min-width: 220px; }
.wires .label { font-size: 9px; letter-spacing: 0.18em; color: var(--dim); }
.wires .value { margin-top: 4px; color: var(--ink); }
.wires a:hover { color: var(--accent); }

/* méthode : étapes */
ol.method { list-style: none; counter-reset: m; padding: 0; margin: 14px 0; max-width: 60ch; }
ol.method li {
  counter-increment: m;
  padding: 10px 0 10px 44px; position: relative;
  border-bottom: 1px dotted var(--line);
  color: var(--chrome);
}
ol.method li::before {
  content: "0" counter(m);
  position: absolute; left: 0; top: 11px;
  color: var(--accent); font-size: 12px;
}
ol.method li b { color: var(--ink); font-weight: 600; display: block; letter-spacing: 0.06em; }

/* trio stratégie/concept/exécution */
.trio { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 0; background: var(--bg-raise); border: 1px solid var(--grid-gap); margin: 18px 0; }
.trio .t { background: var(--bg-raise); border: 1px solid var(--grid-gap); padding: 20px; }
.trio .t h3 { margin: 0 0 4px; font-size: 13px; letter-spacing: 0.1em; color: var(--kw); }
.trio .t .sub { color: var(--accent); font-size: 12px; margin: 0 0 10px; }
.trio .t p { margin: 0; font-size: 12.5px; color: var(--chrome); max-width: none; }

/* CTA */
.cta {
  display: inline-flex; align-items: center; gap: 10px;
  border: 1px solid var(--accent); color: var(--accent);
  padding: 10px 20px; font-size: 12px; letter-spacing: 0.12em;
  margin: 14px 0;
}
.cta:hover { background: var(--accent); color: var(--bg); }
.cta .arr { transition: transform 0.2s; }
.cta:hover .arr { transform: translateX(4px); }

/* apparition du buffer */
.fade-in { animation: fadein 0.5s ease both; }
@keyframes fadein { from { opacity: 0; transform: translateY(6px); } }

/* responsive */
@media (max-width: 860px) {
  :root { --margin: 14px; }
  /* l'œil reste visible en mobile : réduit ET descendu sous la tabline
     (la tabline occupe y75–113 ; à top:84 l'œil la recouvrait et ses
     glyphes rendaient l'onglet illisible). Le texte du buffer passe
     sous la lentille : le ressort vis d'eye.js le gère. */
  .eye-host { width: min(120px, 30vw); top: 130px; }
  .bar-state .col:nth-child(1) { display: none; }
  .bar-graph .label { display: none; }
  .switch a { padding: 6px 8px; font-size: 12px; }
  /* le tableau spec ne doit plus déborder : les libellés peuvent passer
     à la ligne, la colonne chiffres reste dans le viewport. Les valeurs
     longues (listes de disciplines) wrappent aussi ; les chiffres sont
     courts, ils ne bougent pas. */
  table.spec td:first-child { white-space: normal; }
  table.spec td:last-child { white-space: normal; }
  table.spec td { font-size: 12px; }
  /* menu déroulable horizontalement sur petit écran :
     pas d'écrasement des liens, ascenseur caché, glissement tactile. */
  .switch {
    flex: 1; min-width: 0;
    overflow-x: auto;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
  }
  /* marge de fuite en fin de contenu : le dernier lien peut passer sous
     la puce de langue quand on déroule jusqu'au bout (sans déplacer la
     puce, ce qu'un padding-right ferait). */
  .switch::after { content: ""; flex: 0 0 44px; }
  .switch::-webkit-scrollbar { display: none; }
  .switch a, .switch .sep { flex: 0 0 auto; white-space: nowrap; }
  /* le lien de langue reste visible à droite pendant le défilement ;
     fondu à sa gauche pour que la coupure se lise comme un dégradé,
     pas comme un mot tronqué. */
  .switch a[lang] {
    position: sticky; right: 0;
    background: var(--bg);
    padding-left: 12px;
  }
  .switch a[lang]::before {
    content: ""; position: absolute; right: 100%; top: 0; bottom: 0;
    width: 22px; pointer-events: none;
    background: linear-gradient(to left, var(--bg), transparent);
  }
  .doc .buffer { padding: 22px 18px 40px 46px; }
  .buffer { padding: 18px 16px 30px 46px; }
  .buffer > *::before { left: -30px; width: 20px; }
}
@media (max-width: 620px) {
  .bar-state { gap: 12px; }
  .bar-graph canvas { width: 60px; }
  .bar-sub .keys { display: none; }
}
@media (max-width: 520px) {
  /* la barre d'état ne rentre plus avec le graphe : title + télémétrie
     + ✻ passent seuls, sans écrasement du bloc identité. */
  .bar-graph { display: none; }
  .bar { gap: 14px; }
}

@media (prefers-reduced-motion: reduce) {
  .ticker .track { animation: none; }
  .dingbat-wander { animation: none; }
  .fade-in { animation: none; }
}

/* ---------- formulaire de contact : pièges et état ---------- */
.wire .piege { position: absolute; left: -9999px; top: -9999px; }
.etat-forme { font-size: 12px; letter-spacing: 0.04em; min-height: 1.3em; margin: 10px 0 0; }
.etat-forme.ok { color: var(--accent); }
.etat-forme.err { color: #d0454c; }
.wire button[type=submit]:disabled { opacity: 0.45; cursor: wait; }

/* ---------- bandeau de consentement (analytics.js) ---------- */
.consent {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 40;
  transition: transform .45s cubic-bezier(.2,.7,.2,1), opacity .45s;
}
.consent.sortie { transform: translateY(102%); opacity: 0; }
.consent .boite {
  max-width: var(--wide); margin: 0 auto;
  padding: 13px var(--margin);
  display: flex; gap: 22px; align-items: center; justify-content: space-between;
  background: var(--bg-raise); border-top: 1px solid var(--line);
  font-family: var(--mono); font-size: 12px; line-height: 1.55; color: var(--chrome);
}
.consent .boite p { margin: 0; max-width: 66ch; text-wrap: pretty; }
.consent .choix { display: flex; gap: 12px; align-items: center; flex: none; }
.consent button {
  font: inherit; letter-spacing: .04em; padding: 7px 15px;
  cursor: pointer; border-radius: 2px; transition: filter .15s;
}
.consent button:hover { filter: brightness(1.15); }
.consent .oui { background: var(--accent); border: 1px solid var(--accent); color: #fff; }
.consent .non { background: transparent; border: 1px solid var(--chrome); color: var(--chrome); }
.consent .choix a { color: var(--chrome); text-decoration: underline dotted; }
@media (max-width: 760px) {
  .consent .boite { flex-direction: column; align-items: flex-start; gap: 12px; }
}
@media (prefers-reduced-motion: reduce) {
  .consent, .consent.sortie { transition: none; }
}
