/**
 * Pace v5 fonts (DESIGN.md 6.2). Self-hosted, SIL OFL 1.1 (licences in fonts/).
 * Subset to Latin + Latin-1 plus common typographic punctuation (pyftsubset, see
 * scripts/brand/subset-fonts.sh). Total WOFF2 budget: 110 KB. Preload only the UI file.
 * Import after tokens.css. Paths are relative to this file.
 */

/* Mona Sans: UI, body and display. Variable: weight 400-700, width 100-125. */
@font-face {
  font-family: 'Mona Sans';
  src: url('fonts/mona-sans-var-latin.woff2') format('woff2');
  font-weight: 400 700;
  font-stretch: 100% 125%;
  font-style: normal;
  font-display: swap;
}

/* Monaspace Neon: readouts only (times, money, IDs, tokens). Variable weight 400-600. */
@font-face {
  font-family: 'Monaspace Neon';
  src: url('fonts/monaspace-neon-var-latin.woff2') format('woff2');
  font-weight: 400 600;
  font-style: normal;
  font-display: swap;
}

/* Size-adjusted system fallbacks so the swap does not shift layout (CLS).
   Metrics: frequency-weighted English advance width vs Arial / Courier New (Liberation
   equivalents measured), and the fonts' own ascent, descent and line gap. */
@font-face {
  font-family: 'Mona Sans Fallback';
  src: local('Arial'), local('Liberation Sans');
  size-adjust: 104.64%;
  ascent-override: 104.17%;
  descent-override: 30.58%;
  line-gap-override: 0%;
}

@font-face {
  font-family: 'Monaspace Neon Fallback';
  src: local('Courier New'), local('Liberation Mono');
  size-adjust: 103.32%;
  ascent-override: 91.47%;
  descent-override: 19.36%;
  line-gap-override: 9.68%;
}
