/* =========================================================================
   KAIROS CORP — feuille de style principale
   Palette monochrome + accent ambre. Animations sobres, respect de
   prefers-reduced-motion. Aucune dépendance externe.
   ========================================================================= */

/* ---------------------------------------------------------------- Tokens */
/* [data-theme="dark"] permet de forcer la palette sombre sur un sous-arbre
   (utilisé par styleguide.html pour montrer les deux thèmes côte à côte).
   Le bloc clair vient après : à spécificité égale, c'est lui qui gagne. */
:root,
[data-theme="dark"] {
  color-scheme: dark;

  --bg:            #09090B;
  --bg-2:          #0E0E11;
  --surface:       rgba(255, 255, 255, 0.026);
  --surface-2:     rgba(255, 255, 255, 0.045);
  --line:          rgba(255, 255, 255, 0.10);
  --line-2:        rgba(255, 255, 255, 0.18);
  --btn-surface:   #17171B;     /* fond plein de la pastille fantôme */

  --fg:            #F4F3F0;
  --fg-2:          rgba(244, 243, 240, 0.66);
  --fg-3:          rgba(244, 243, 240, 0.52);

  --accent:        #D8A657;
  --accent-soft:   rgba(216, 166, 87, 0.14);
  --accent-line:   rgba(216, 166, 87, 0.38);
  --on-accent:     #0B0B0D;

  --logo-invert:   0;           /* 0 = logo blanc */
  --shadow:        0 24px 60px -24px rgba(0, 0, 0, 0.7);

  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

  --wrap:      1200px;
  --gutter:    clamp(1.25rem, 4vw, 3rem);
  --section-y: clamp(5.5rem, 11vw, 9.5rem);
  --radius:    14px;

  --ease:      cubic-bezier(0.22, 0.72, 0.24, 1);
  --ease-out:  cubic-bezier(0.16, 1, 0.3, 1);
}

[data-theme="light"] {
  color-scheme: light;

  --bg:          #FBFAF8;
  --bg-2:        #F3F2EE;
  --surface:     rgba(12, 12, 14, 0.022);
  --surface-2:   rgba(12, 12, 14, 0.04);
  --line:        rgba(12, 12, 14, 0.12);
  --line-2:      rgba(12, 12, 14, 0.22);
  --btn-surface: #FFFFFF;

  --fg:          #0C0C0E;
  --fg-2:        rgba(12, 12, 14, 0.66);
  --fg-3:        rgba(12, 12, 14, 0.60);

  --accent:      #8A6218;
  --accent-soft: rgba(138, 98, 24, 0.10);
  --accent-line: rgba(138, 98, 24, 0.40);
  --on-accent:   #FBFAF8;

  --logo-invert: 1;             /* 1 = logo noir */
  --shadow:      0 24px 60px -30px rgba(12, 12, 14, 0.28);
}

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

* { margin: 0; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: 6rem;
}

body {
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font-sans);
  font-size: clamp(0.975rem, 0.94rem + 0.18vw, 1.0625rem);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  transition: background-color 0.5s var(--ease), color 0.5s var(--ease);
}

/* Grain très léger : de la matière, pas du bruit */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 9999;
  pointer-events: none;
  opacity: 0.032;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

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

a { color: inherit; text-decoration: none; }

button, input, textarea, select { font: inherit; color: inherit; }

::selection { background: var(--accent); color: var(--on-accent); }

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

/* ------------------------------------------------------------ Typographie */
h1, h2, h3, h4 {
  font-weight: 600;
  line-height: 1.08;
  letter-spacing: -0.03em;
  text-wrap: balance;
}

.display {
  font-size: clamp(2.6rem, 1.4rem + 5.6vw, 5.75rem);
  letter-spacing: -0.042em;
  line-height: 0.98;
  font-weight: 600;
}

.h2 {
  font-size: clamp(1.85rem, 1.2rem + 2.4vw, 3.15rem);
  letter-spacing: -0.032em;
}

.h3 {
  font-size: clamp(1.05rem, 1rem + 0.3vw, 1.25rem);
  letter-spacing: -0.02em;
  line-height: 1.3;
}

.lead {
  font-size: clamp(1.05rem, 1rem + 0.42vw, 1.3rem);
  line-height: 1.55;
  color: var(--fg-2);
  max-width: 36ch;
  text-wrap: pretty;
}

.muted { color: var(--fg-2); }
.faint { color: var(--fg-3); }

.eyebrow {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--fg-3);
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
}

.eyebrow::before {
  content: "";
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--accent);
  flex: none;
}

/* ---------------------------------------------------------------- Layout */
.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

@media (min-width: 900px) {
  .section-head .lead { max-width: 44ch; padding-bottom: 0.4rem; }
}

.section-head .eyebrow { margin-bottom: 1.15rem; }

/* ---------------------------------------------------------------- Header */
.header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 100;
  border-bottom: 1px solid transparent;
  transition: background-color 0.4s var(--ease), backdrop-filter 0.4s var(--ease),
              border-color 0.4s var(--ease);
}

.header.is-scrolled {
  background: color-mix(in srgb, var(--bg) 78%, transparent);
  -webkit-backdrop-filter: saturate(150%) blur(14px);
  backdrop-filter: saturate(150%) blur(14px);
  border-bottom-color: var(--line);
}

.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  height: 4.75rem;
}

/* Lockup : marque en SVG (currentColor) + wordmark bitmap haute définition */
.brand {
  display: inline-flex;
  align-items: center;
  --mark-h: 26px;
  gap: calc(var(--mark-h) * 0.268);
  color: var(--fg);
  flex: none;
}

.k-mark { overflow: visible; }
.brand__mark { height: var(--mark-h); width: auto; }
.brand__mark rect { fill: currentColor; }

.brand__word {
  height: calc(var(--mark-h) * 0.444);
  width: auto;
  filter: invert(var(--logo-invert));
  transition: filter 0.5s var(--ease);
}

.brand:hover .k-bar { animation: barNudge 0.6s var(--ease); }
.brand:hover .k-bar:nth-child(2) { animation-delay: 0.05s; }
.brand:hover .k-bar:nth-child(3) { animation-delay: 0.1s; }

@keyframes barNudge {
  0%   { transform: translateY(0); }
  40%  { transform: translateY(-16px); }
  100% { transform: translateY(0); }
}

.nav { display: none; }

@media (min-width: 940px) {
  .nav {
    display: flex;
    align-items: center;
    gap: 2.15rem;
    margin-inline-start: auto;
  }
}

.nav__link {
  position: relative;
  font-size: 0.9rem;
  color: var(--fg-2);
  padding-block: 0.35rem;
  transition: color 0.3s var(--ease);
}

.nav__link::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  height: 1px;
  width: 100%;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 0.45s var(--ease-out);
}

.nav__link:hover,
.nav__link.is-active { color: var(--fg); }

.nav__link:hover::after,
.nav__link.is-active::after { transform: scaleX(1); transform-origin: left; }

.header__actions {
  display: flex;
  align-items: center;
  /* la lentille de l'interrupteur déborde de 2 px : un peu plus d'air
     qu'entre deux boutons ordinaires */
  gap: 0.75rem;
  flex: none;
}

/* ------------------------------------------------- Interrupteur de thème
   Piste en pilule + bulle de verre qui coulisse. La bulle déborde de 2 px
   sur les quatre côtés : c'est ce léger relief qui fait lire la lentille.
   Les valeurs d'ombre de la maquette Figma étaient calibrées pour un visuel
   de ~600 px ; elles sont ici ramenées à l'échelle d'un contrôle de 34 px. */
.switch {
  --sw-h:      34px;   /* hauteur de la piste                       */
  --sw-w:      102px;  /* largeur de la piste                       */
  --sw-bubble: 38px;   /* diamètre de la lentille                   */
  --sw-over:   2px;    /* débordement de la lentille                */
  --sw-travel: calc(var(--sw-w) - 2px - var(--sw-bubble) + var(--sw-over) * 2);
  --sw-dur:    600ms;
  /* easeOutBack : le rebond de la référence (0.34, 1.56, 0.64, 1) */
  --sw-ease:   cubic-bezier(0.34, 1.56, 0.64, 1);

  position: relative;
  flex: none;
  width: var(--sw-w);
  height: var(--sw-h);
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 100px;
  cursor: pointer;
  background: linear-gradient(180deg,
    rgba(255, 255, 255, 0.075),
    rgba(255, 255, 255, 0.015));
  box-shadow:
    /* Inner shadow — X 0, Y 2, Blur 10, blanc 25 % (étape 01) */
    inset 0 1px 4px rgba(255, 255, 255, 0.14),
    inset 0 -1px 2px rgba(0, 0, 0, 0.45),
    /* Drop shadow — X -2, Y -4, Blur 4, noir 35 % */
    -1px -2px 3px rgba(0, 0, 0, 0.28),
    /* Drop shadow ambiante — X -20, Y 100, Blur 180, 1E2021 */
    -1px 7px 18px -8px rgba(30, 32, 33, 0.9);
  transition: border-color 0.3s var(--ease), box-shadow 0.4s var(--ease),
              background 0.5s var(--ease);
}

[data-theme="light"] .switch {
  background: linear-gradient(180deg,
    rgba(12, 12, 14, 0.085),
    rgba(12, 12, 14, 0.035));
  box-shadow:
    inset 0 1px 3px rgba(255, 255, 255, 0.9),
    inset 0 -1px 2px rgba(12, 12, 14, 0.09),
    -1px -1px 2px rgba(255, 255, 255, 0.7),
    -1px 6px 14px -8px rgba(12, 12, 14, 0.45);
}

.switch:hover { border-color: var(--line-2); }

/* Libellé de l'état courant : occupe la moitié laissée libre par la bulle */
.switch__text {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  width: calc(var(--sw-w) - var(--sw-bubble) + var(--sw-over) * 2);
  display: grid;
  place-items: center;
  transition: transform var(--sw-dur) var(--sw-ease);
}

[data-theme="light"] .switch__text {
  transform: translateX(calc(var(--sw-bubble) - var(--sw-over) * 2));
}

.switch__word {
  grid-area: 1 / 1;
  font-family: var(--font-mono);
  font-size: 0.6rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--fg-2);
  transition: opacity 0.3s var(--ease), transform 0.45s var(--ease);
}

.switch__word--light { opacity: 0; transform: translateY(5px); }
[data-theme="light"] .switch__word--dark  { opacity: 0; transform: translateY(-5px); }
[data-theme="light"] .switch__word--light { opacity: 1; transform: none; }

/* La lentille de verre.
   Frost = 0 dans la référence : presque pas de flou, on garde la réfraction
   (fond éclairci et saturé) et les arêtes éclairées à -45°. */
.switch__bubble {
  position: absolute;
  top: calc(var(--sw-over) * -1);
  left: calc(var(--sw-over) * -1);
  width: var(--sw-bubble);
  height: var(--sw-bubble);
  border-radius: 50%;
  display: grid;
  place-items: center;
  transform: translateX(var(--sw-travel));
  transition: transform var(--sw-dur) var(--sw-ease);
  background: linear-gradient(145deg,
    rgba(255, 255, 255, 0.15) 0%,
    rgba(255, 255, 255, 0.035) 45%,
    rgba(255, 255, 255, 0.09) 100%);
  -webkit-backdrop-filter: brightness(1.38) saturate(150%) blur(0.5px);
  backdrop-filter: brightness(1.38) saturate(150%) blur(0.5px);
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.13),
    inset 1px 1px 1.5px rgba(255, 255, 255, 0.5),
    inset -1px -1px 1.5px rgba(255, 255, 255, 0.14),
    0 4px 10px -2px rgba(0, 0, 0, 0.5),
    0 1px 2px rgba(0, 0, 0, 0.3);
}

[data-theme="light"] .switch__bubble {
  transform: translateX(0);
  background: linear-gradient(145deg,
    rgba(255, 255, 255, 0.76) 0%,
    rgba(255, 255, 255, 0.36) 48%,
    rgba(255, 255, 255, 0.52) 100%);
  -webkit-backdrop-filter: brightness(1.16) saturate(125%) blur(0.5px);
  backdrop-filter: brightness(1.16) saturate(125%) blur(0.5px);
  box-shadow:
    inset 1px 1px 1.5px rgba(255, 255, 255, 1),
    inset -1px -1px 1.5px rgba(12, 12, 14, 0.05),
    0 0 0 1px rgba(12, 12, 14, 0.05),
    0 4px 10px -3px rgba(12, 12, 14, 0.3),
    0 1px 2px rgba(12, 12, 14, 0.12);
}

/* Éclat spéculaire, source de lumière en haut à gauche (-45°) */
.switch__bubble::before {
  content: "";
  position: absolute;
  inset: 1px;
  border-radius: 50%;
  pointer-events: none;
  background: linear-gradient(147deg,
    rgba(255, 255, 255, 0.36) 0%,
    rgba(255, 255, 255, 0.07) 33%,
    transparent 52%);
}

.switch__icon {
  grid-area: 1 / 1;
  width: 15px;
  height: 15px;
  color: var(--fg);
  transition: opacity 0.35s var(--ease), transform 0.5s var(--ease);
}

.switch__icon--sun { opacity: 0; transform: rotate(-70deg) scale(0.6); }
[data-theme="light"] .switch__icon--moon { opacity: 0; transform: rotate(70deg) scale(0.6); }
[data-theme="light"] .switch__icon--sun  { opacity: 1; transform: none; }

.switch:active .switch__bubble { transform: translateX(var(--sw-travel)) scale(0.94); }
[data-theme="light"] .switch:active .switch__bubble { transform: translateX(0) scale(0.94); }

/* Sans JavaScript l'interrupteur ne fait rien : autant ne pas l'afficher. */
.no-js .switch { display: none; }

@media (max-width: 420px) {
  .switch { --sw-w: 88px; --sw-h: 32px; --sw-bubble: 34px; }
  .switch__word { font-size: 0.55rem; letter-spacing: 0.1em; }
  .switch__icon { width: 13px; height: 13px; }
}

.header .btn { display: none; }
@media (min-width: 640px) { .header .btn { display: inline-flex; } }

.menu.is-open { opacity: 1; visibility: visible; }

.menu.is-open .menu__link {
  opacity: 1;
  transform: none;
  transition-delay: calc(0.08s + var(--i) * 0.055s);
}

/* --------------------------------------------------------------- Boutons */
/* Pastille en relief. Le bouton est lu comme un bourrelet qui fait le tour
   d'un plat central en contrebas : c'est l'ombre que le bourrelet projette
   sur ce plat qui donne la profondeur, pas le liseré.
   Quatre teintes étagées — deux de lumière, deux d'ombre — sont dérivées du
   fond par color-mix, si bien qu'une seule règle habille les deux variantes
   et les deux thèmes.
   Le survol ne touche à aucune couleur : le bouton grossit, c'est tout. */
.btn {
  --btn-fg: var(--bg);
  --btn-bg: var(--fg);
  --btn-l2: color-mix(in srgb, var(--btn-bg) 62%, #FFF);   /* arête éclairée */
  --btn-l1: color-mix(in srgb, var(--btn-bg) 86%, #FFF);
  --btn-o1: color-mix(in srgb, var(--btn-bg) 91%, #000);
  --btn-o2: color-mix(in srgb, var(--btn-bg) 86%, #000);   /* dessous, à l'ombre */
  --btn-anneau: color-mix(in srgb, var(--btn-bg) 94%, var(--btn-fg));
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.78rem 1.4rem;
  border: 0;
  border-radius: 100px;
  /* Le bourrelet : clair au sommet, il s'assombrit en tournant vers le bas.
     La couleur pleine est déclarée à part du dégradé : sinon `background-color`
     est calculé à `transparent` et tout outil qui vérifie les contrastes
     compare le texte au fond du parent. */
  background-color: var(--btn-bg);
  background-image: linear-gradient(180deg, var(--btn-l1) 0%, var(--btn-bg) 48%, var(--btn-o1) 100%);
  color: var(--btn-fg);
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  isolation: isolate;
  box-shadow:
    inset 0 1px 0 var(--btn-l2),
    inset 0 -1px 0 var(--btn-o2),
    0 1px 1px -1px rgba(0, 0, 0, 0.14),
    0 5px 10px -5px rgba(0, 0, 0, 0.2),
    0 16px 26px -14px rgba(0, 0, 0, 0.3);
  transition: transform 0.4s var(--ease);
}

/* Le plat central, en retrait de 4 px. Il reçoit l'ombre du bourrelet en
   haut et sa lumière renvoyée en bas — d'où le creux.
   z-index négatif sous isolation : le plat se pose sur le fond du bouton
   mais reste sous le texte. */
.btn::before {
  content: "";
  position: absolute;
  inset: 4px;
  z-index: -1;
  border-radius: inherit;
  /* Le liseré net marque l'arête du creux ; le dégradé et l'ombre interne
     donnent le fond du creux. Il faut les deux : la ligne seule est plate,
     l'ombre seule est floue. */
  border: 1px solid var(--btn-anneau);
  background-color: var(--btn-bg);
  background-image: linear-gradient(180deg, var(--btn-o1) 0%, var(--btn-l1) 62%);
  /* Les deux couleurs sont fixes à dessein : sur un fond clair c'est le noir
     qui creuse, sur un fond sombre c'est le blanc qui relance. Chaque teinte
     ne prend que sur le fond où elle se voit. */
  box-shadow:
    inset 0 3px 5px -2px rgba(0, 0, 0, 0.09),
    inset 0 1px 2px rgba(0, 0, 0, 0.055),
    inset 0 -1px 0 rgba(255, 255, 255, 0.24);
  pointer-events: none;
}

.btn:hover,
.btn:focus-visible { transform: scale(1.035); }

.btn:active { transform: scale(0.99); }

.btn--ghost {
  --btn-bg: var(--btn-surface);
  --btn-fg: var(--fg);
}

.btn[disabled] { opacity: 0.55; cursor: progress; }

.btn__arrow {
  width: 14px;
  height: 14px;
  transition: transform 0.45s var(--ease-out);
}

.btn:hover .btn__arrow { transform: translateX(3px); }

.arrow-link {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  font-size: 0.9rem;
  color: var(--fg);
  position: relative;
  padding-bottom: 0.3rem;
}

.arrow-link::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 100%;
  height: 1px;
  background: var(--line-2);
  transition: background-color 0.3s var(--ease);
}

.arrow-link:hover::after { background: var(--accent); }
.arrow-link svg { width: 13px; height: 13px; transition: transform 0.45s var(--ease-out); }
.arrow-link:hover svg { transform: translateX(4px); }

@keyframes drift {
  from { transform: translate3d(0, 0, 0) scale(1); }
  to   { transform: translate3d(-4%, 4%, 0) scale(1.08); }
}

/* Entrée animée de la marque */
.k-bar { opacity: 0; transform: translateY(30px); }

.js .k-mark--animate .k-bar {
  animation: barIn 1s var(--ease-out) forwards;
  animation-delay: calc(0.15s + var(--i) * 0.12s);
}

.no-js .k-bar,
.k-mark:not(.k-mark--animate) .k-bar { opacity: 1; transform: none; }

@keyframes barIn {
  from { opacity: 0; transform: translateY(30px); }
  to   { opacity: 1; transform: translateY(0); }
}

@keyframes marquee {
  from { transform: translate3d(0, 0, 0); }
  to   { transform: translate3d(-50%, 0, 0); }
}

/* Formulaire */
.form { display: grid; gap: 1.15rem; }

.field { display: grid; gap: 0.45rem; }

.field label {
  font-family: var(--font-mono);
  font-size: 0.64rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--fg-3);
}

.field input,
.field textarea,
.field select {
  width: 100%;
  background: transparent;
  border: 0;
  border-bottom: 1px solid var(--line);
  padding: 0.7rem 0.1rem;
  font-size: 0.95rem;
  border-radius: 0;
  transition: border-color 0.35s var(--ease);
}

.field textarea { resize: vertical; min-height: 96px; }
.field select { cursor: pointer; }
.field select option { background: var(--bg); color: var(--fg); }

.field input:focus,
.field textarea:focus,
.field select:focus { outline: none; border-bottom-color: var(--accent); }

.field input::placeholder,
.field textarea::placeholder { color: var(--fg-3); }

.form__status { font-size: 0.85rem; color: var(--fg-2); min-height: 1.3em; }
.form__status[data-state="error"] { color: #E0685C; }
.form__status[data-state="ok"]    { color: var(--accent); }

/* Piège à robots */
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* ---------------------------------------------------------------- Footer */
.footer {
  border-top: 1px solid var(--line);
  padding-block: clamp(2.75rem, 6vw, 4rem) 2rem;
}

.footer__brand .brand { --mark-h: 32px; }

.footer__bottom {
  border-top: 1px solid var(--line);
  padding-top: 1.75rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.75rem;
  justify-content: space-between;
  font-family: var(--font-mono);
  font-size: 0.66rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--fg-3);
}

.footer__legal { display: flex; flex-wrap: wrap; gap: 0.5rem 1.5rem; }

/* ----------------------------------------------------------- Pages texte */
.legal {
  padding-top: 8.5rem;
  padding-bottom: clamp(4rem, 9vw, 7rem);
  padding-inline: var(--gutter);
  max-width: var(--wrap);
  margin-inline: auto;
}
.legal__body { max-width: 68ch; }

.legal__body h2 {
  font-size: clamp(1.15rem, 1rem + 0.7vw, 1.45rem);
  letter-spacing: -0.02em;
  margin-top: 2.75rem;
  margin-bottom: 0.85rem;
}

.legal__body h3 { font-size: 1rem; margin-top: 1.75rem; margin-bottom: 0.5rem; }
.legal__body p,
.legal__body li { color: var(--fg-2); font-size: 0.95rem; }
.legal__body p + p { margin-top: 0.9rem; }
.legal__body ul { margin: 0.75rem 0 0; padding-left: 1.15rem; display: grid; gap: 0.4rem; }
.legal__body a { color: var(--fg); text-decoration: underline; text-underline-offset: 3px; text-decoration-color: var(--line-2); }
.legal__body a:hover { text-decoration-color: var(--accent); }
.legal__body strong { color: var(--fg); font-weight: 500; }

.legal__note {
  margin-top: 1.25rem;
  border-left: 2px solid var(--accent-line);
  padding: 0.8rem 0 0.8rem 1.1rem;
  background: var(--accent-soft);
  border-radius: 0 6px 6px 0;
  font-size: 0.88rem;
  color: var(--fg-2);
}

.notfound {
  min-height: 78svh;
  display: grid;
  place-content: center;
  justify-items: center;
  text-align: center;
  gap: 1.5rem;
  padding-block: 8rem 4rem;
}

.notfound .display { font-size: clamp(4rem, 18vw, 9rem); }

/* -------------------------------------------------- Révélation au scroll */
.js [data-reveal] {
  opacity: 0;
  transform: translate3d(0, 22px, 0);
  transition: opacity 0.85s var(--ease-out), transform 0.85s var(--ease-out);
  transition-delay: calc(var(--d, 0) * 90ms);
}

.js [data-reveal].is-in { opacity: 1; transform: none; }

.to-top.is-visible { opacity: 1; transform: none; pointer-events: auto; }

/* Lien d'évitement */
.skip {
  position: absolute;
  left: 1rem;
  top: -100px;
  z-index: 200;
  background: var(--fg);
  color: var(--bg);
  padding: 0.6rem 1rem;
  border-radius: 8px;
  font-size: 0.85rem;
  transition: top 0.25s var(--ease);
}

.skip:focus { top: 1rem; }

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

/* ------------------------------------------------------ Mouvement réduit */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }

  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }

  .js [data-reveal],
  .js [data-reveal].is-in { opacity: 1; transform: none; }
  .k-bar { opacity: 1; transform: none; }
  .marquee__track { animation: none; }
  .hero__glow { animation: none; }
}

/* ------------------------------------------------------------ Impression */
@media print {
  .header, .menu, .to-top, .marquee, .hero__glow, body::after { display: none !important; }
  body { background: #fff; color: #000; }
}
