/* Self-hosted fonts (latin subsets, public/fonts/, OFL — see LICENSE.txt there).
 * Fallback faces carry metric overrides computed from the actual font tables
 * (fontaine method) so the swap from fallback to webfont causes no layout shift.
 */

@font-face {
  font-family: 'Source Serif 4';
  src: url('/fonts/source-serif-4-latin-var.woff2') format('woff2');
  font-weight: 400 700;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Source Serif 4';
  src: url('/fonts/source-serif-4-latin-var-italic.woff2') format('woff2');
  font-weight: 400 700;
  font-style: italic;
  font-display: swap;
}

@font-face {
  font-family: 'IBM Plex Mono';
  src: url('/fonts/ibm-plex-mono-latin-400.woff2') format('woff2');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'IBM Plex Mono';
  src: url('/fonts/ibm-plex-mono-latin-500.woff2') format('woff2');
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}

/* Metric-compatible fallbacks — tuned against Georgia and Menlo. */

@font-face {
  font-family: 'Source Serif 4 Fallback';
  src: local('Georgia');
  size-adjust: 108.3159%;
  ascent-override: 95.6461%;
  descent-override: 30.928%;
  line-gap-override: 0%;
}

@font-face {
  font-family: 'IBM Plex Mono Fallback';
  src: local('Menlo'), local('Menlo Regular'), local('Consolas');
  size-adjust: 99.6594%;
  ascent-override: 102.8503%;
  descent-override: 27.594%;
  line-gap-override: 0%;
}
