/* Self-hosted fonts with metric-matched fallbacks - Tauros Trading Co.
   ---------------------------------------------------------------------
   Two problems with the Google Fonts <link> this file replaces, both
   measured in the Aug 27 Lighthouse run of the live shop:
   - the stylesheet request to fonts.googleapis.com render-blocked ~230ms;
   - the swap from fallback to web font reflowed the product grid, which
     was nearly all of the page's 0.197 CLS (prices in IBM Plex Mono and
     names in Zilla Slab both change width when the real font lands).

   The woff2 files are the latin subsets from Fontsource, served same-
   origin from /fonts/. The three *Fallback faces below are the fix for
   the reflow: each is the metric-compatible system font (Liberation
   metrics, identical to Arial / Times / Courier New) size-adjusted with
   fontTools-computed overrides so fallback text occupies the same box
   the web font will - when the swap happens, nothing moves. The numbers
   are computed, not tuned by eye; recompute them if a font file changes:
     size-adjust = (xAvgCharWidth/upm) of the web font over the fallback,
     ascent/descent-override = hhea values over (upm x size-adjust). */

@font-face { font-family: 'Zilla Slab'; font-style: normal; font-weight: 500; font-display: swap; src: url('/fonts/zilla-slab-latin-500-normal.woff2') format('woff2'); }
@font-face { font-family: 'Zilla Slab'; font-style: normal; font-weight: 600; font-display: swap; src: url('/fonts/zilla-slab-latin-600-normal.woff2') format('woff2'); }
@font-face { font-family: 'Zilla Slab'; font-style: normal; font-weight: 700; font-display: swap; src: url('/fonts/zilla-slab-latin-700-normal.woff2') format('woff2'); }
@font-face { font-family: 'Public Sans'; font-style: normal; font-weight: 400; font-display: swap; src: url('/fonts/public-sans-latin-400-normal.woff2') format('woff2'); }
@font-face { font-family: 'Public Sans'; font-style: normal; font-weight: 500; font-display: swap; src: url('/fonts/public-sans-latin-500-normal.woff2') format('woff2'); }
@font-face { font-family: 'Public Sans'; font-style: normal; font-weight: 600; font-display: swap; src: url('/fonts/public-sans-latin-600-normal.woff2') format('woff2'); }
@font-face { font-family: 'IBM Plex Mono'; font-style: normal; font-weight: 400; font-display: swap; src: url('/fonts/ibm-plex-mono-latin-400-normal.woff2') format('woff2'); }
@font-face { font-family: 'IBM Plex Mono'; font-style: normal; font-weight: 500; font-display: swap; src: url('/fonts/ibm-plex-mono-latin-500-normal.woff2') format('woff2'); }

@font-face {
  font-family: 'Zilla Slab Fallback';
  src: local('Times New Roman');
  size-adjust: 98.76%; ascent-override: 95.59%; descent-override: 25.92%; line-gap-override: 0%;
}
@font-face {
  font-family: 'Public Sans Fallback';
  src: local('Arial');
  size-adjust: 91.19%; ascent-override: 104.18%; descent-override: 24.68%; line-gap-override: 0%;
}
@font-face {
  font-family: 'IBM Plex Mono Fallback';
  src: local('Courier New');
  size-adjust: 99.98%; ascent-override: 102.52%; descent-override: 27.5%; line-gap-override: 0%;
}
