/* ============================================================================
   Apex Minds brand fonts — SELF-HOSTED, Cyrillic-first.

   Four families, and every one of them can set Ukrainian:
     Unbounded  — display (wordmark, hero, titles).      200–900 variable.
     Inter      — text and UI (everything else).          100–900 variable.
     Caveat     — the archive's editorial hand, only.     400–700 variable.
     CMU Serif  — a problem's own text (the math's face).  400/700 + italics.

   Fraunces and DM Sans were REMOVED on 2026-09-20. Both are Latin-only
   upstream, which meant the 59px Ukrainian hero silently rendered in Georgia
   and all Ukrainian body text fell through to an unspecified system face.
   A typeface enters this stack only if it sets «Олімпіадні задачі» in its own
   glyphs — see DESIGN.md, "The Cyrillic Test".

   Declared as variable ranges so one file per subset serves every weight the
   design system asks for; browsers fetch only the subsets a page needs, so a
   Ukrainian page pays for `cyrillic` and nothing else.

   To refresh: re-fetch the css2 + woff2 from Google Fonts and rewrite urls to
   ./files/ with a content hash in the filename.
   ============================================================================ */

/* ── Unbounded — display ─────────────────────────────────────────────── */
/* cyrillic-ext */
@font-face {
  font-family: 'Unbounded';
  font-style: normal;
  font-weight: 200 900;
  font-display: swap;
  src: url(files/unbounded-497409d6.woff2) format('woff2');
  unicode-range: U+0460-052F, U+1C80-1C8A, U+20B4, U+2DE0-2DFF, U+A640-A69F, U+FE2E-FE2F;
}
/* cyrillic */
@font-face {
  font-family: 'Unbounded';
  font-style: normal;
  font-weight: 200 900;
  font-display: swap;
  src: url(files/unbounded-cb504d5f.woff2) format('woff2');
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
/* latin-ext */
@font-face {
  font-family: 'Unbounded';
  font-style: normal;
  font-weight: 200 900;
  font-display: swap;
  src: url(files/unbounded-936fcc0c.woff2) format('woff2');
  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;
}
/* latin */
@font-face {
  font-family: 'Unbounded';
  font-style: normal;
  font-weight: 200 900;
  font-display: swap;
  src: url(files/unbounded-37e64138.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;
}
/* vietnamese */
@font-face {
  font-family: 'Unbounded';
  font-style: normal;
  font-weight: 200 900;
  font-display: swap;
  src: url(files/unbounded-8e12f3a3.woff2) format('woff2');
  unicode-range: U+0102-0103, U+0110-0111, U+0128-0129, U+0168-0169, U+01A0-01A1, U+01AF-01B0, U+0300-0301, U+0303-0304, U+0308-0309, U+0323, U+0329, U+1EA0-1EF9, U+20AB;
}

/* ── Inter — text and UI ─────────────────────────────────────────────── */
/* cyrillic-ext */
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url(files/inter-fccca918.woff2) format('woff2');
  unicode-range: U+0460-052F, U+1C80-1C8A, U+20B4, U+2DE0-2DFF, U+A640-A69F, U+FE2E-FE2F;
}
/* cyrillic */
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url(files/inter-aebf2ab4.woff2) format('woff2');
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
/* latin-ext */
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url(files/inter-a28eb6d3.woff2) format('woff2');
  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;
}
/* latin */
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url(files/inter-c9407645.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;
}

/* ── Caveat — editorial hand (Примітка редакції only) ───────────────── */
/* cyrillic-ext */
@font-face {
  font-family: 'Caveat';
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url(files/caveat-7b25cd3a.woff2) format('woff2');
  unicode-range: U+0460-052F, U+1C80-1C8A, U+20B4, U+2DE0-2DFF, U+A640-A69F, U+FE2E-FE2F;
}
/* cyrillic */
@font-face {
  font-family: 'Caveat';
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url(files/caveat-fe67cd78.woff2) format('woff2');
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
/* latin-ext */
@font-face {
  font-family: 'Caveat';
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url(files/caveat-ed1d4a86.woff2) format('woff2');
  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;
}
/* latin */
@font-face {
  font-family: 'Caveat';
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url(files/caveat-c5e74a40.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;
}

/* ── CMU Serif — problem and solution text ───────────────────────────── */
/* Computer Modern Unicode 0.7.0 (Andrey Panov; CTAN fonts/cm-unicode, SIL OFL
   1.1). The same design KaTeX draws its mathematics in, with full Cyrillic
   (the lh set), so a statement and its formulas are ONE typeface — before
   2026-09-27 the prose was Inter and every number, variable and operator in it
   was Computer Modern. Set only where a problem's own text is (statement,
   answer, solution, editorial note, the featured and result snippets); the
   interface around it stays Inter.

   Subset from the OTFs with fontTools to Latin, Latin-1, Cyrillic (incl. ґ і ї
   є), Greek, general punctuation, № and ₴ — every character the published
   prose uses that the font has (87 of 9.4M prose characters, ≤ ≥ ⇒ and
   subscript digits, fall to KaTeX_Main next in the stack). Kerning, ligatures
   and locl kept. `cmunbx`/`cmunbi` are the Bold Extended cuts — Computer
   Modern's bold, which is what **bold** looks like in the printed books. */
@font-face {
  font-family: 'CMU Serif';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url(files/cmunrm-52b98dfa.woff2) format('woff2');
}
@font-face {
  font-family: 'CMU Serif';
  font-style: italic;
  font-weight: 400;
  font-display: swap;
  src: url(files/cmunti-249a5fe3.woff2) format('woff2');
}
@font-face {
  font-family: 'CMU Serif';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url(files/cmunbx-af18fbdc.woff2) format('woff2');
}
@font-face {
  font-family: 'CMU Serif';
  font-style: italic;
  font-weight: 700;
  font-display: swap;
  src: url(files/cmunbi-f6953bc4.woff2) format('woff2');
}

/* ── Apex Flags — competition flags (js/util/comp-flag.js) ───────────────
   Windows ships no flag emoji: Segoe UI Emoji prints 🇺🇦 as the letters «UA».
   This is the Twemoji Country Flags font (country-flag-emoji-polyfill 0.1.10;
   code MIT, art Twemoji CC-BY 4.0) cut down to the flags comp-flag.js uses,
   3 KB. .cflag names Apple / Noto emoji first, so macOS, iOS and Android keep
   their own flags and only Windows (and bare Linux) draws these.
   To add a country: drop the other ligatures from the package's GSUB, run
   `python3 -m fontTools.subset` with the flags as --text and
   --layout-features='*', and rename by content hash. Pruning GSUB first is the
   step that matters: with all 26 letters kept, the subsetter keeps every flag. */
@font-face {
  font-family: 'Apex Flags';
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url(files/flags-268073c6.woff2) format('woff2');
  unicode-range: U+1F1E6-1F1FF;
}
