/* Chez Merlin V2 — jetons (02-direction.md, sections 4, 5, 6, 8). Seul fichier où figurent les couleurs et les familles. */

@font-face { font-family: 'Overpass'; font-style: normal; font-weight: 600 900; font-display: swap; src: url(../fonts/overpass-latin-ext.woff2) format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Overpass'; font-style: normal; font-weight: 600 900; font-display: swap; src: url(../fonts/overpass-latin.woff2) format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Public Sans'; font-style: normal; font-weight: 400 600; font-display: swap; src: url(../fonts/public-sans-latin-ext.woff2) format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Public Sans'; font-style: normal; font-weight: 400 600; font-display: swap; src: url(../fonts/public-sans-latin.woff2) format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Public Sans'; font-style: italic; font-weight: 400; font-display: swap; src: url(../fonts/public-sans-italic-latin-ext.woff2) format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Public Sans'; font-style: italic; font-weight: 400; font-display: swap; src: url(../fonts/public-sans-italic-latin.woff2) format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }

:root {
  /* Palette (section 4) — neutres froids, teinte ~210°, chroma <= 20 */
  --color-quai: #EEF1F4;
  --color-surface: #F7F8FA;
  --color-panneau: #E3E7EC;
  --color-filet: #C9CED6;
  --color-encre: #14171C;
  --color-encre-2: #4A505A;
  --color-nuit: #111418;
  --color-surface-nuit: #191D22;
  --color-panneau-nuit: #232830;
  --color-filet-nuit: #2E343C;
  --color-texte-nuit: #E8EBEF;
  --color-texte-2-nuit: #A9B0BA;
  /* Accent unique : jaune signal, « par ici » */
  --color-jaune: #FFD400;
  /* Couleurs de ligne (les quatre rubriques) et leurs variantes de texte de nuit */
  --color-ligne-01: #1B5DA6;
  --color-ligne-02: #5B3FA0;
  --color-ligne-03: #00756A;
  --color-ligne-04: #B0245A;
  --color-ligne-01-nuit: #7FB2F0;
  --color-ligne-02-nuit: #B9A3EC;
  --color-ligne-03-nuit: #5CCFC0;
  --color-ligne-04-nuit: #F28DB0;

  /* Rôles (mode clair) */
  --fond: var(--color-quai);
  --surface: var(--color-surface);
  --panneau: var(--color-panneau);
  --filet: var(--color-filet);
  --texte: var(--color-encre);
  --texte-2: var(--color-encre-2);
  --aide-fond: var(--color-quai);
  --sur-aplat: var(--color-surface);          /* texte posé sur les aplats de ligne */
  --plaque: var(--color-surface);             /* plaque du logo, identique en sombre */
  --info-carre: var(--color-encre);           /* carré « i » */
  --info-lettre: var(--color-surface);
  --attente-fond: var(--color-quai);          /* panneau en attente */
  --attente-trait: var(--color-encre-2);
  --encre-bloc: var(--color-encre);           /* pied de page, lettre du dimanche, 404 */
  --encre-bloc-texte: var(--color-texte-nuit);
  --encre-bloc-texte-2: var(--color-texte-2-nuit);
  --ligne-01-texte: var(--color-ligne-01);
  --ligne-02-texte: var(--color-ligne-02);
  --ligne-03-texte: var(--color-ligne-03);
  --ligne-04-texte: var(--color-ligne-04);

  /* Typographie (section 5) */
  --font-titre: 'Overpass', system-ui, sans-serif;
  --font-texte: 'Public Sans', system-ui, sans-serif;
  --size-display: clamp(2.5rem, 1.4rem + 5vw, 5.5rem);
  --size-geant: clamp(6rem, 3rem + 14vw, 14rem);
  --size-h1: clamp(2.125rem, 1.5rem + 2.8vw, 3.75rem);
  --size-h2: clamp(1.5rem, 1.25rem + 1.1vw, 2.125rem);
  --size-h3: clamp(1.1875rem, 1.1rem + 0.4vw, 1.375rem);
  --size-etape: clamp(2.75rem, 2rem + 3vw, 4rem);
  --size-exemple: clamp(1.25rem, 1.15rem + 0.5vw, 1.5rem);
  --size-corps: clamp(1.125rem, 1.08rem + 0.25vw, 1.25rem);
  --size-interface: 1rem;
  --size-surtitre: 0.9375rem;
  --size-legende: 0.875rem;
  --size-guillemet: 3rem;
  --lh-display: 0.98;
  --lh-geant: 0.85;
  --lh-h1: 1.04;
  --lh-h2: 1.12;
  --lh-h3: 1.25;
  --lh-etape: 1;
  --lh-exemple: 1.4;
  --lh-corps: 1.65;
  --lh-interface: 1.3;
  --lh-legende: 1.5;
  --ls-display: -0.035em;
  --ls-geant: -0.05em;
  --ls-h1: -0.025em;
  --ls-h2: -0.015em;
  --ls-surtitre: 0.04em;
  --mesure: 68ch;

  /* Espacements, rayons, épaisseurs (section 6) */
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.5rem;
  --space-6: 2rem;
  --space-7: 2.5rem;
  --space-8: 3.5rem;
  --space-9: 5rem;
  --radius: 4px;
  --radius-indicatif: 2px;
  --trait-aide: 8px;
  --trait-bande: 8px;
  --trait-protocole: 6px;
  --trait-plan: 4px;
  --trait-signal: 4px;
  --page-max: 1240px;
  --cible: 48px;

  /* Durées (section 8) */
  --tm-duration: .45s;
  --duree-entete: 200ms;
  --duree-fleche: 150ms;
  --duree-sommaire: 200ms;
  --duree-repere: 200ms;
}

@media (prefers-color-scheme: dark) {
  :root {
    --fond: var(--color-nuit);
    --surface: var(--color-surface-nuit);
    --panneau: var(--color-panneau-nuit);
    --filet: var(--color-filet-nuit);
    --texte: var(--color-texte-nuit);
    --texte-2: var(--color-texte-2-nuit);
    --aide-fond: var(--color-panneau-nuit);
    --info-carre: var(--color-texte-nuit);
    --info-lettre: var(--color-nuit);
    --attente-fond: var(--color-panneau-nuit);
    --attente-trait: var(--color-texte-2-nuit);
    --ligne-01-texte: var(--color-ligne-01-nuit);
    --ligne-02-texte: var(--color-ligne-02-nuit);
    --ligne-03-texte: var(--color-ligne-03-nuit);
    --ligne-04-texte: var(--color-ligne-04-nuit);
  }
}

@media (prefers-reduced-motion: reduce) {
  :root {
    --duree-entete: 0s;
    --duree-fleche: 0s;
    --duree-sommaire: 0s;
    --duree-repere: 0s;
  }
}
