/* Self-hosted webfonts + the reduced-motion contract (S7).
   ADR-0001 §внешние зависимости: the mockup pulled Unbounded and Onest from
   Google's font CDN, which is both a red line of this project and, in practice,
   an unreachable host for a share of Russian ISPs — with a remote stylesheet in
   <head> the page renders in a fallback font or not at all.

   Both families ship as VARIABLE fonts (`font-weight: 400 800`). The page uses
   400/500/600/700/800 of Onest and 400/600/700 of Unbounded; ten static files
   would cost far more than two variable ones and would still miss any weight
   added later. Downloaded from Google Fonts as woff2 at build time — Onest v9,
   Unbounded v12 — and copied into assets/fonts/ unchanged.

   Four subsets per family. unicode-range is what makes that cheap: a browser
   fetches a file only when the page actually paints a character from its range,
   so latin-ext (unused today, 134 KB of the 267 KB on disk) costs zero bytes of
   traffic and is kept only so an accented name in a future case study does not
   silently fall back to a system font.

   font-display: swap on every face — text must be readable while the font
   loads, never invisible.

   WHY THE REDUCED-MOTION BLOCK IS IN THIS FILE AND NOT IN site.css: site.css is
   owned by story S2 and is a declared hot file of this epic, closed to S7. The
   rules below are the CSS half of the same promise assets/js/fx.js keeps in JS,
   and they must ship together. If the two files are ever merged, this block
   belongs next to the animations it neutralises. */

/* ---------------------------------------------------------------- Onest */

/* cyrillic-ext */
@font-face {
  font-family: 'Onest';
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url('../fonts/onest-cyrillic-ext.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: 'Onest';
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url('../fonts/onest-cyrillic.woff2') format('woff2');
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
/* latin-ext */
@font-face {
  font-family: 'Onest';
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url('../fonts/onest-latin-ext.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: 'Onest';
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url('../fonts/onest-latin.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;
}

/* ------------------------------------------------------------ Unbounded */

/* cyrillic-ext */
@font-face {
  font-family: 'Unbounded';
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url('../fonts/unbounded-cyrillic-ext.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: 400 800;
  font-display: swap;
  src: url('../fonts/unbounded-cyrillic.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: 400 800;
  font-display: swap;
  src: url('../fonts/unbounded-latin-ext.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: 400 800;
  font-display: swap;
  src: url('../fonts/unbounded-latin.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;
}

/* ------------------------------------------------- prefers-reduced-motion */

/* The blanket rule collapses duration instead of setting `animation: none`, so
   an animation that ends in its final state (the logo mark's `lmin`, which is
   `both`-filled) still gets there and does not vanish. Infinite loops — the two
   marquees, the drifting auras, the pulsing orbs, the caret, the typing dots —
   run their single iteration instantly and settle on their base style.

   .reveal is the exception that needs `animation: none`. It is driven by a
   scroll-driven `animation-timeline: view()` (site.css), and a timeline ignores
   duration entirely — collapsing it would leave every block below the fold at
   opacity 0 forever. This rule is also the reason the page stays readable for a
   reduced-motion visitor with JavaScript disabled, i.e. with no help from
   assets/js/fx.js at all (ADR-0008).

   `scroll-behavior` is neutralised by the universal rule and only by it: this
   file is linked BEFORE site.css, so a plain `html { scroll-behavior: auto }`
   here loses the cascade to `html { scroll-behavior: smooth }` (site.css:29) at
   equal specificity. `!important` on `*` is what actually wins — and `*` does
   match <html>, i.e. the scrolling element. */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    animation-delay: 0ms !important;
    transition-duration: 0.001ms !important;
    transition-delay: 0ms !important;
    scroll-behavior: auto !important;
  }
  .reveal,
  .reveal.revealed {
    animation: none !important;
    opacity: 1 !important;
    transform: none !important;
  }
}
