/* Chronos base tokens. Every colour on screen comes from the active theme: the theme engine
   (ThemeProvider) writes --c-*, --r-*, --font-*, --ease, --dur-*, --depth-* onto :root.
   This file holds only (1) system-colour fallbacks for the instant before a theme is applied,
   (2) the tag palette, which is data colour rather than theme colour, (3) sizes, and
   (4) names older screens still use, all derived from theme tokens (never a second palette). */
:root {
  --c-ground: Canvas; --c-panel: Canvas; --c-panel-hero: Canvas; --c-line: GrayText; --c-line-strong: GrayText;
  --c-text: CanvasText; --c-text-2: CanvasText; --c-text-3: GrayText; --c-muted: GrayText;
  --c-accent: Highlight; --c-accent-hover: Highlight; --c-on-accent: HighlightText; --c-now: Highlight;
  --c-wellness: CanvasText; --c-ok: CanvasText; --c-warn: CanvasText; --c-danger: CanvasText; --c-fixed-block: GrayText; --c-selection: Highlight;
  --r-sm: 8px; --r-md: 10px; --r-lg: 14px; --r-pill: 999px;
  --depth-float: 0 12px 32px rgb(0 0 0 / .25);
  --font-display: system-ui, sans-serif; --font-text: system-ui, sans-serif; --font-num: ui-monospace, Consolas, monospace; --num-variant: tabular-nums;
  --ease: cubic-bezier(.2, 0, 0, 1); --dur-fast: 120ms; --dur-base: 240ms;
  --focus-widget-opacity: .3; --focus-widget-blur: 1px;

  --hit: 44px;
  --dur-instant: 80ms;
  --dur-slow: calc(var(--dur-base) * 1.6);
  --dur-sweep: calc(var(--dur-base) * 2.6);
  --ease-snap: cubic-bezier(.16, 1, .3, 1);
  --ease-in: cubic-bezier(.7, 0, .84, 0);

  /* Derived surfaces (mixes of theme tokens). */
  --surface-2: color-mix(in srgb, var(--c-text) 7%, var(--c-ground));
  --surface-3: color-mix(in srgb, var(--c-text) 13%, var(--c-ground));
  --sunken: color-mix(in srgb, var(--c-text) 4%, var(--c-ground));
  --focus-ring: var(--c-accent-hover);

  /* Names older screens still use. */
  --bg: var(--c-ground); --s1: var(--c-panel); --s2: var(--surface-2); --s3: var(--surface-3);
  --line: var(--c-line); --line-strong: var(--c-line-strong);
  --text: var(--c-text); --text-2: var(--c-text-2); --text-3: var(--c-text-3);
  --inverse: var(--c-accent); --on-inverse: var(--c-on-accent);
  --accent: var(--c-accent); --accent-hover: var(--c-accent-hover); --on-accent: var(--c-on-accent); --accent-text: var(--c-warn);
  --now: var(--c-now); --ring: var(--focus-ring);
  --ok: var(--c-ok); --warn: var(--c-warn); --danger: var(--c-danger);
  --font-sans: var(--font-text); --font-mono: var(--font-num);
  --r: var(--r-md); --pill: var(--r-pill); --cap: 6px;
  --shadow-float: var(--depth-float); --shadow-lift: var(--depth-raised, var(--depth-float));
  --ease-out: var(--ease);
  --brand-ink: var(--c-ink, var(--c-text)); --brand-paper: var(--c-on-ink, var(--c-ground)); --brand-muted: var(--c-text-2);
  color-scheme: light dark;

  /* Tag palette (data colours; picked by tag, readable on both grounds). */
  --tag1: #3A8FD6; --tag2: #1FA97F; --tag3: #D2639C; --tag4: #C79A12; --tag5: #8F78E8; --tag6: #1FA7BD; --tag7: #8A8F97; --tag8: #6DAA3C;
}
:root[data-mode="light"] {
  --tag1: #0B63C5; --tag2: #00796B; --tag3: #A8326F; --tag4: #9A6700; --tag5: #6D4FD8; --tag6: #0E7490; --tag7: #5B6068; --tag8: #3B7D23;
}
:root[data-mode="dark"] {
  --tag1: #56B4E9; --tag2: #2FD3A3; --tag3: #E58FBD; --tag4: #F0C419; --tag5: #B49CFF; --tag6: #4FD6E8; --tag7: #A9ADB3; --tag8: #9BD86B;
}
