/* Self-hosted variable fonts (SIL OFL, licenses in ../fonts). Latin covers English; latin-ext adds the Bosnian letters č ć đ š ž. */
@font-face { font-family: "Jost"; font-style: normal; font-display: swap; font-weight: 100 900; src: url(../fonts/jost-latin-ext-wght-normal.woff2) format("woff2-variations"); unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF; }
@font-face { font-family: "Jost"; font-style: normal; font-display: swap; font-weight: 100 900; src: url(../fonts/jost-latin-wght-normal.woff2) format("woff2-variations"); 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: "Cormorant Garamond"; font-style: normal; font-display: swap; font-weight: 300 700; src: url(../fonts/cormorant-garamond-latin-ext-wght-normal.woff2) format("woff2-variations"); unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF; }
@font-face { font-family: "Cormorant Garamond"; font-style: normal; font-display: swap; font-weight: 300 700; src: url(../fonts/cormorant-garamond-latin-wght-normal.woff2) format("woff2-variations"); 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; }

/* Design tokens. --brand-* are written per tenant by MainLayout (primary, secondary, text color on primary, link shades that pass 4.5:1
   on --ea-stone in light and dark, and the direction hover shades mix: away from the text color). Everything else is derived here from those two colors. */
:root {
    color-scheme: light;

    --brand-primary: #1b6ec2;
    --brand-secondary: #6c757d;
    --brand-on-primary: #fff;
    --brand-link-light: #1b6ec2;
    --brand-link-dark: #6ea8fe;
    --brand-toward: black;

    --ea-font-body: Jost, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
    --ea-font-heading: "Cormorant Garamond", Georgia, "Times New Roman", serif;
    --ea-radius: 2px;

    --ea-paper: #faf7f2;
    --ea-surface: #fffdf9;
    --ea-stone: #ece7df;
    --ea-text: #1f1b16;
    --ea-text-muted: #5f574d;
    --ea-rule: #d9d2c7;
    --ea-link: var(--brand-link-light);

    --ea-brand-hover: color-mix(in srgb, var(--brand-primary), var(--brand-toward) 14%);
    --ea-brand-active: color-mix(in srgb, var(--brand-primary), var(--brand-toward) 22%);
    --ea-brand-subtle: color-mix(in srgb, var(--brand-primary) 14%, var(--ea-surface));
    --ea-brand-border: color-mix(in srgb, var(--brand-primary) 40%, var(--ea-surface));

    /* Bootstrap */
    --bs-body-font-family: var(--ea-font-body);
    --bs-body-bg: var(--ea-paper);
    --bs-body-color: var(--ea-text);
    --bs-body-color-rgb: 31, 27, 22; --bs-emphasis-color-rgb: 31, 27, 22; --bs-body-bg-rgb: 250, 247, 242;
    --bs-emphasis-color: var(--ea-text);
    --bs-secondary-color: var(--ea-text-muted);
    --bs-secondary-bg: var(--ea-stone);
    --bs-tertiary-bg: var(--ea-stone);
    --bs-border-color: var(--ea-rule);
    --bs-border-radius: var(--ea-radius);
    --bs-border-radius-sm: var(--ea-radius);
    --bs-border-radius-lg: var(--ea-radius);
    --bs-link-color: var(--ea-link);
    --bs-link-hover-color: var(--ea-link);
    --bs-primary: var(--brand-primary);
    --bs-primary-bg-subtle: var(--ea-brand-subtle);
    --bs-primary-border-subtle: var(--ea-brand-border);
    --bs-primary-text-emphasis: var(--ea-link);
    --bs-focus-ring-color: color-mix(in srgb, var(--ea-link) 35%, transparent);
}

/* theme.js sets data-theme from the saved choice, else the OS setting */
:root[data-theme="dark"] {
        color-scheme: dark;
        --ea-link: var(--brand-link-dark);

        --ea-paper: #17150f;
        --ea-surface: #1f1c16;
        --ea-stone: #2a261f;
        --ea-text: #efe9df;
        --ea-text-muted: #b3aa9c;
        --ea-rule: #3d382f;

        --bs-body-color-rgb: 239, 233, 223; --bs-emphasis-color-rgb: 239, 233, 223; --bs-body-bg-rgb: 23, 21, 15;

        --bs-secondary-text-emphasis: #a7acb1; --bs-secondary-bg-subtle: #161719; --bs-secondary-border-subtle: #41464b;
        --bs-success-text-emphasis: #75b798; --bs-success-bg-subtle: #051b11; --bs-success-border-subtle: #0f5132;
        --bs-info-text-emphasis: #6edff6; --bs-info-bg-subtle: #032830; --bs-info-border-subtle: #087990;
        --bs-warning-text-emphasis: #ffda6a; --bs-warning-bg-subtle: #332701; --bs-warning-border-subtle: #997404;
        --bs-danger-text-emphasis: #ea868f; --bs-danger-bg-subtle: #2c0b0e; --bs-danger-border-subtle: #842029;
}
