/*
 * ROAR design tokens (docs/UI-SPEC.md, 5.2 and 5.4). Palette "Ніч і грива", approved 2026-11-16.
 * Light theme: :root. Dark theme: [data-theme="dark"] on <html>; the theme script in
 * console/_theme_head.html resolves "system" to light or dark and remembers the choice.
 * Every text/background pair is checked by core/tools/roar_contrast.py
 * (text >= 4.5:1, control borders and large elements >= 3:1). Keep one value per line:
 * the script reads "--roar-name: #RRGGBB;" lines from the two theme blocks below.
 */

@font-face { font-family: "IBM Plex Sans"; font-style: normal; font-weight: 400; font-display: swap;
  src: url("../vendor/fonts/ibm-plex-sans-cyrillic-400-normal.woff2") format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116; }
@font-face { font-family: "IBM Plex Sans"; font-style: normal; font-weight: 400; font-display: swap;
  src: url("../vendor/fonts/ibm-plex-sans-latin-400-normal.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: "IBM Plex Sans"; font-style: normal; font-weight: 500; font-display: swap;
  src: url("../vendor/fonts/ibm-plex-sans-cyrillic-500-normal.woff2") format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116; }
@font-face { font-family: "IBM Plex Sans"; font-style: normal; font-weight: 500; font-display: swap;
  src: url("../vendor/fonts/ibm-plex-sans-latin-500-normal.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: "IBM Plex Sans"; font-style: normal; font-weight: 600; font-display: swap;
  src: url("../vendor/fonts/ibm-plex-sans-cyrillic-600-normal.woff2") format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116; }
@font-face { font-family: "IBM Plex Sans"; font-style: normal; font-weight: 600; font-display: swap;
  src: url("../vendor/fonts/ibm-plex-sans-latin-600-normal.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: "IBM Plex Mono"; font-style: normal; font-weight: 400; font-display: swap;
  src: url("../vendor/fonts/ibm-plex-mono-cyrillic-400-normal.woff2") format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116; }
@font-face { font-family: "IBM Plex Mono"; font-style: normal; font-weight: 400; font-display: swap;
  src: url("../vendor/fonts/ibm-plex-mono-latin-400-normal.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; }

/* theme: light */
:root {
  color-scheme: light;
  --roar-bg: #F6F5F2;
  --roar-surface: #FFFFFF;
  --roar-surface-2: #FAF8F4;
  --roar-ink: #1A1712;
  --roar-ink-2: #3D372E;
  --roar-mut: #5E574C;
  --roar-line: #E4DFD6;
  --roar-ctl-border: #857D70;
  --roar-mane: #E8A33D;
  --roar-on-mane: #1A1712;
  --roar-acc: #9A5B00;
  --roar-acc-hover: #7A4700;
  --roar-night: #14161C;
  --roar-night-2: #20232C;
  --roar-night-ink: #F1EEE8;
  --roar-night-mut: #B4AEA4;
  --roar-focus-ring: #E8A33D;
  --roar-focus-edge: #1A1712;
  --roar-ok: #15803D;
  --roar-ok-bg: #DCFCE7;
  --roar-warn: #93370D;
  --roar-warn-bg: #FEF0C7;
  --roar-bad: #B42318;
  --roar-bad-bg: #FEE4E2;
  --roar-on-bad: #FFFFFF;
  --roar-info: #1E40AF;
  --roar-info-bg: #DBEAFE;
  /* call and line states (5.4) */
  --roar-st-free: #15803D;
  --roar-st-free-bg: #DCFCE7;
  --roar-st-ring: #B45309;
  --roar-st-ring-bg: #FEF3C7;
  --roar-st-talk: #166534;
  --roar-st-talk-bg: #DCFCE7;
  --roar-st-hold: #6D28D9;
  --roar-st-hold-bg: #EDE9FE;
  --roar-st-break: #475569;
  --roar-st-break-bg: #E2E8F0;
  --roar-st-dnd: #9F1239;
  --roar-st-dnd-bg: #FFE4E6;
  --roar-st-off: #5E574C;
  --roar-st-off-bg: #EEEBE6;
  --roar-st-missed: #B42318;
  --roar-st-missed-bg: #FEE4E2;
  --roar-st-listen: #1E40AF;
  --roar-st-listen-bg: #DBEAFE;
  --roar-shadow: 0 1px 2px rgb(20 22 28 / .08), 0 .375rem 1.25rem rgb(20 22 28 / .10);
  --roar-overlay: rgb(20 22 28 / .55);
}

/* theme: dark */
[data-theme="dark"] {
  color-scheme: dark;
  --roar-bg: #0E0F12;
  --roar-surface: #17191F;
  --roar-surface-2: #1E2129;
  --roar-ink: #ECE8E1;
  --roar-ink-2: #C9C3B8;
  --roar-mut: #A39C90;
  --roar-line: #2A2E38;
  --roar-ctl-border: #77736B;
  --roar-mane: #F2B24C;
  --roar-on-mane: #1A1712;
  --roar-acc: #F2B24C;
  --roar-acc-hover: #FFC870;
  --roar-night: #0A0B0E;
  --roar-night-2: #1A1C23;
  --roar-night-ink: #F1EEE8;
  --roar-night-mut: #B4AEA4;
  --roar-focus-ring: #F2B24C;
  --roar-focus-edge: #0E0F12;
  --roar-ok: #4ADE80;
  --roar-ok-bg: #11281A;
  --roar-warn: #FBBF24;
  --roar-warn-bg: #2B2110;
  --roar-bad: #F87171;
  --roar-bad-bg: #2D1414;
  --roar-on-bad: #0E0F12;
  --roar-info: #93C5FD;
  --roar-info-bg: #13203A;
  --roar-st-free: #4ADE80;
  --roar-st-free-bg: #11281A;
  --roar-st-ring: #F5B544;
  --roar-st-ring-bg: #2B2110;
  --roar-st-talk: #4ADE80;
  --roar-st-talk-bg: #11281A;
  --roar-st-hold: #C4B5FD;
  --roar-st-hold-bg: #221A3A;
  --roar-st-break: #CBD5E1;
  --roar-st-break-bg: #1F252E;
  --roar-st-dnd: #FDA4AF;
  --roar-st-dnd-bg: #2E1219;
  --roar-st-off: #A39C90;
  --roar-st-off-bg: #22242B;
  --roar-st-missed: #F87171;
  --roar-st-missed-bg: #2D1414;
  --roar-st-listen: #93C5FD;
  --roar-st-listen-bg: #13203A;
  --roar-shadow: 0 0 0 1px #2A2E38;
  --roar-overlay: rgb(0 0 0 / .65);
}

/* Theme-independent scale */
:root {
  --roar-font: "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --roar-font-head: "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --roar-font-mono: "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  --roar-fs-xs: .8125rem;
  --roar-fs-sm: .875rem;
  --roar-fs-md: 1rem;
  --roar-fs-lg: 1.25rem;
  --roar-fs-xl: 1.5rem;
  --roar-fs-2xl: 2rem;
  --roar-sp-1: .25rem;
  --roar-sp-2: .5rem;
  --roar-sp-3: .75rem;
  --roar-sp-4: 1rem;
  --roar-sp-6: 1.5rem;
  --roar-sp-8: 2rem;
  --roar-sp-12: 3rem;
  --roar-r: .375rem;
  --roar-r-lg: .75rem;
  --roar-r-island: 1.25rem;
  --roar-ctl-h: 2.375rem;
  --roar-touch: 2.75rem;
  --roar-sidebar-w: 16rem;
  --roar-header-h: 3.5rem;
}

/*
 * Bridge for the core pages (UI-SPEC 5.2): their accent is Tailwind's sky palette and their
 * neutrals are slate; both read theme variables, so remapping them recolors the pages without
 * touching their markup (white text on sky-600 = #9A5B00 is 5.6:1). A brand color set in settings (_brand_style.html) still wins: it is
 * included after this file.
 */
:root {
  /* Fixed light values: core pages have no dark variant, they stay light in both themes. */
  --color-sky-50: #FDF6EA;
  --color-sky-100: #FBEBD0;
  --color-sky-200: #F6D7A3;
  --color-sky-300: #F0BF6E;
  --color-sky-400: #E8A33D;
  --color-sky-500: #9A5B00;
  --color-sky-600: #9A5B00;
  --color-sky-700: #7A4700;
  --color-sky-800: #643A00;
  --color-sky-900: #4F2E00;
}
