/*
 * theme.css — mapping layer.
 *
 * The brand tokens (colors, surfaces, radii) live in tokens.css, which MUST be
 * linked before this file. Here we only repoint the site's long-standing
 * variable names (--bg-page, --accent, --btn-bg, …) onto those tokens, so every
 * existing page adopts the brand without touching its own CSS.
 *
 * tokens.css makes DARK the :root default and LIGHT opt-in via
 * [data-theme="light"]. Because the mappings below reference the token vars
 * (--bg, --surface, --text, …), they resolve to the correct value in each mode
 * automatically — no per-theme block needed here.
 */

:root {
  /* surfaces & text */
  --bg-page: var(--bg);
  --bg-surface: var(--surface);
  --text-primary: var(--text);
  --text-secondary: var(--text-muted);
  --text-muted: var(--text-muted);
  --border-color: var(--border);
  --border-light: var(--border);

  /* accent — brand lime. --link is lime on dark, dark-ink on light (lime is
     illegible as text on white), exactly as tokens.css intends. Active-state
     FILLS use --isard-green directly (dark label via --on-accent). No blue. */
  --accent: var(--link);
  --btn-bg: var(--isard-green);
  --btn-text: var(--on-accent);
  --btn-hover: color-mix(in srgb, var(--isard-green) 85%, #000);

  --shadow: rgba(0, 0, 0, 0.28);
  --shadow-sm: rgba(0, 0, 0, 0.16);
  --toggle-slider-bg: var(--surface-2);
}

/* Base link colour so unstyled content anchors follow the brand instead of the
   UA default blue (lime on dark, dark-ink on light via --link). More specific
   rules — .nav-link, .privacy-link, .cookie-content a, .rc-btn — still win. */
a {
  color: var(--link);
}

/* The wordmark art is black; invert it to read on the dark canvas (default),
   and leave it as-is in light mode. */
.header-logo img,
.footer-logo {
  filter: invert(1);
}

:root[data-theme="light"] .header-logo img,
:root[data-theme="light"] .footer-logo {
  filter: none;
}
