/* Typefaces — IBM Plex, self-hosted.
 *
 * Why Plex, and why mono-led.
 *
 * Typepace is a measuring instrument. Every number on screen is a reading
 * taken off someone's hands, and the thing being measured is monospaced text.
 * So monospace is not the "code font" here — it is the subject, and it earns
 * the display role that a sans would normally take. Tabular figures are the
 * practical half of that argument: a WPM counter updating ten times a second
 * in proportional digits jitters, and in mono it does not move at all.
 *
 * Plex specifically, rather than the usual technical monos, because it is a
 * superfamily drawn for an engineering company — the mono and the sans share
 * skeletons, so pairing them is structural rather than coincidental. It reads
 * as laboratory equipment rather than sci-fi cosplay, which is the line this
 * design walks.
 *
 * Self-hosted from the OFL release: no third-party request, no layout shift
 * waiting on a CDN, and the whole family is 76 KB so the PWA still works
 * offline. `font-display: swap` means text is readable from the first frame.
 */

@font-face {
  font-family: "IBM Plex Sans";
  src: url("../assets/fonts/plex-sans-var.woff2") format("woff2-variations"),
       url("../assets/fonts/plex-sans-var.woff2") format("woff2");
  font-weight: 400 600;
  font-style: normal;
  font-display: swap;
}

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

/* --- Optional families, offered on the Appearance page ---------------- */

/* JetBrains Mono: a taller x-height and wider apertures than Plex Mono, which
   some readers find easier to track across a long typing passage. */
@font-face {
  font-family: "JetBrains Mono";
  src: url("../assets/fonts/jetbrains-mono-400.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "JetBrains Mono";
  src: url("../assets/fonts/jetbrains-mono-600.woff2") format("woff2");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}

/* Atkinson Hyperlegible: drawn by the Braille Institute to keep confusable
   letterforms distinct at low vision — the 1/l/I and 0/O pairs in particular.
   It is offered here as a first-class interface choice rather than buried in
   an accessibility toggle, because plenty of people simply read it faster. */
@font-face {
  font-family: "Atkinson Hyperlegible";
  src: url("../assets/fonts/atkinson-400.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Atkinson Hyperlegible";
  src: url("../assets/fonts/atkinson-700.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}
