/* Couleurs et polices communes à l'écran et à l'admin.
   Style 2026 : fond neutre, cartes blanches arrondies, une seule couleur d'accent, police Geist. */
:root {
  color-scheme: light;
  --paper: #f2f3f6; --card: #ffffff; --card-2: #f0f1f5; --line: #e3e5eb; --line-2: #d3d6de;
  --ink: #0f1218; --ink-2: #4a5160; --ink-3: #8a909c;
  --accent: #3355ff; --accent-bg: #e9edff; --accent-ink: #ffffff;
  --navy: #0f1218; --navy-ink: #ffffff; --gold: var(--accent);
  --go: #12a150; --go-bg: #e3f6ea;
  --warn: #d97706; --warn-bg: #fff1dc;
  --stop: #e5383b; --stop-bg: #fde6e6;
  --info: #3355ff; --info-bg: #e9edff;
  --shadow: 0 1px 2px rgba(15, 18, 24, 0.04), 0 4px 16px rgba(15, 18, 24, 0.05);
  --shadow-lg: 0 2px 6px rgba(15, 18, 24, 0.06), 0 24px 60px rgba(15, 18, 24, 0.18);
  --display: "Geist", "Segoe UI Variable Display", "Segoe UI", system-ui, sans-serif;
  --body: "Geist", "Segoe UI Variable Text", "Segoe UI", system-ui, sans-serif;
  --mono: "Geist Mono", ui-monospace, "Cascadia Mono", Consolas, monospace;
}
@media (prefers-color-scheme: dark) {
  :root[data-theme="auto"] {
    color-scheme: dark;
    --paper: #0a0c10; --card: #14171e; --card-2: #1b1f28; --line: #252a35; --line-2: #333947;
    --ink: #f3f5f8; --ink-2: #a9b0bd; --ink-3: #6c7382;
    --accent: #6b86ff; --accent-bg: #1a2350; --accent-ink: #ffffff;
    --navy: #f3f5f8; --navy-ink: #0a0c10;
    --go: #34d27b; --go-bg: #10301f; --warn: #ffb13d; --warn-bg: #3a2a0e;
    --stop: #ff6262; --stop-bg: #3d1719; --info: #6b86ff; --info-bg: #1a2350;
    --shadow: 0 1px 2px rgba(0, 0, 0, 0.4); --shadow-lg: 0 24px 60px rgba(0, 0, 0, 0.6);
  }
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --paper: #0a0c10; --card: #14171e; --card-2: #1b1f28; --line: #252a35; --line-2: #333947;
  --ink: #f3f5f8; --ink-2: #a9b0bd; --ink-3: #6c7382;
  --accent: #6b86ff; --accent-bg: #1a2350; --accent-ink: #ffffff;
  --navy: #f3f5f8; --navy-ink: #0a0c10;
  --go: #34d27b; --go-bg: #10301f; --warn: #ffb13d; --warn-bg: #3a2a0e;
  --stop: #ff6262; --stop-bg: #3d1719; --info: #6b86ff; --info-bg: #1a2350;
  --shadow: 0 1px 2px rgba(0, 0, 0, 0.4); --shadow-lg: 0 24px 60px rgba(0, 0, 0, 0.6);
}

/* Couleurs des postes : les teintes du site Pilotage CSPK.
   --rc : couleur vive du poste (pastille, initiales) ; --rb : fond léger ; --rf : texte foncé. */
.r-coord { --rc: #6d5ce8; --rb: #eeecff; --rf: #3c3489; }
.r-charg { --rc: #d6457a; --rb: #fdebf2; --rf: #72243e; }
.r-bl    { --rc: #2b7fd9; --rb: #e7f1fc; --rf: #0c447c; }
.r-of    { --rc: #e2683a; --rb: #fdeee8; --rf: #712b13; }
.r-ofc   { --rc: #9b5de5; --rb: #f3ecfe; --rf: #4c1d95; }
.r-sd    { --rc: #15a3ad; --rb: #e2f6f7; --rf: #0b4f55; }
.r-ret   { --rc: #1fa47a; --rb: #e2f6ef; --rf: #085041; }
.r-rec   { --rc: #c48a1c; --rb: #fbf1dc; --rf: #633806; }
.r-x     { --rc: #6b7280; --rb: #eef0f3; --rf: #2c3348; }
:root[data-theme="dark"] [class*="r-"] { --rb: color-mix(in srgb, var(--rc) 18%, #14171e); --rf: color-mix(in srgb, var(--rc) 45%, #fff); }
@media (prefers-color-scheme: dark) { :root[data-theme="auto"] [class*="r-"] { --rb: color-mix(in srgb, var(--rc) 18%, #14171e); --rf: color-mix(in srgb, var(--rc) 45%, #fff); } }

* { box-sizing: border-box; }
html, body { margin: 0; }
body { background: var(--paper); color: var(--ink); font-family: var(--body); -webkit-font-smoothing: antialiased; font-feature-settings: "ss01", "cv11"; }
button, select, input, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
[hidden] { display: none !important; }

/* Camion qui roule, discret, sur une voie fine. */
.road { position: relative; overflow: hidden; }
.road::after { content: ""; position: absolute; left: 0; right: 0; bottom: 14px; height: 2px; border-radius: 2px;
  background-image: repeating-linear-gradient(90deg, var(--line-2) 0 14px, transparent 14px 26px); }
.rtruck { position: absolute; bottom: 17px; left: -120px; width: 92px; height: 34px; color: var(--ink); animation: roll 22s linear infinite; }
@keyframes roll { 0% { left: -120px; } 100% { left: 100%; } }
.rtruck .wh { transform-box: fill-box; transform-origin: center; animation: spin 0.8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .rtruck, .rtruck .wh { animation: none; } .rtruck { left: 40%; } }
