/*
 * Design tokens — dark palette canonical from WPF DarkMode.xaml; light values
 * stubbed and unused in Phase 0 (light theme arrives in Phase 2).
 * Single source of truth for color, type, and sizing across all components.
 */

:root,
:root[data-theme="dark"] {
    --bg: #0C0C0E;
    --panel: #131418;
    --card: #1A1B20;
    --card-hover: #1E1208;
    --card-selected: #241408;
    --border: #2A2B32;
    --text-primary: #F2F2F0;
    --text-secondary: #B8B8B0;
    --text-muted: #666660;
    --accent: #EF5A11;
    --accent-strong: #FF7A33;

    /* Link and record-title text. The brand orange is kept for marks that
       carry meaning — button fills, the logo, active indicators, severity —
       but using it for every link and row title turned a dense list page into
       a wall of orange. Text reads in ink; colour is reserved for signal. */
    --link: #D6D6D0;
    --link-hover: #FFFFFF;

    --severity-critical: #FF3B3B;
    --severity-high: #FF7A00;
    --severity-medium: #F5C400;
    --severity-low: #00C896;

    /* Informational notices (notifications at level "info"): a calm blue,
       distinct from the four severities and from the brand orange. */
    --level-info: #4DA3FF;
    /* Text on a filled accent/severity mark (badge, icon disc). */
    --on-accent: #FFFFFF;

    /* Floating surfaces (the notification panel, toasts). */
    --shadow-float: 0 12px 32px rgba(0, 0, 0, 0.55);
    --screen-letterbox: #000000;
    --screen-scrim: rgba(0, 0, 0, 0.8);

    --error-bg: #180808;
    --error-border: #4A1010;
    --error-fg: #FF6B6B;

    /* Search-hit highlight (the <mark> around a matched substring). */
    --highlight-bg: rgba(239, 90, 17, 0.30);
    --highlight-fg: #FFFFFF;

    --font-sans: "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
    --font-mono: "IBM Plex Mono", Consolas, ui-monospace, monospace;

    --radius: 10px;
    --radius-sm: 6px;
    --border-w: 1px;
}

/* Light tokens stubbed for Phase 2 — currently unreachable since templates pin
   data-theme="dark". Do not delete: Phase 2 wires the toggle, not the values. */
:root[data-theme="light"] {
    --bg: #F0F2F5;
    --panel: #FFFFFF;
    --card: #F8F9FA;
    --card-hover: #FFF8F5;
    --card-selected: #FFF3EB;
    --border: #E2E6EA;
    --text-primary: #1A1C20;
    --text-secondary: #4A5568;
    --text-muted: #9AA5B4;
    --accent: #EF5A11;
    --accent-strong: #C04A0E;

    /* Light mode keeps the brand orange for links — it reads as a link against
       a white page, where a grey would just look like disabled text. */
    --link: #EF5A11;
    --link-hover: #C04A0E;

    --severity-critical: #E53E3E;
    --severity-high: #DD6B00;
    --severity-medium: #B7791F;
    --severity-low: #2F855A;

    --level-info: #2B6CB0;
    --on-accent: #FFFFFF;

    --shadow-float: 0 12px 32px rgba(26, 28, 32, 0.18);
    --screen-letterbox: #000000;
    --screen-scrim: rgba(0, 0, 0, 0.8);

    --error-bg: #FFF5F5;
    --error-border: #FED7D7;
    --error-fg: #E53E3E;

    --highlight-bg: rgba(239, 90, 17, 0.20);
    --highlight-fg: #1A1C20;
}
