/* TYPOGRAPHY — the scale, and which face does which job.

   Split out of metrics.css because type is now a design decision rather than a
   measurement. Three faces, and the split between them is the system's clearest
   idea:

     DISPLAY (Source Serif 4)           what the product SAYS      — a regime, a
                                        headline, an invalidation clause
     SANS    (Golos Text)               the interface              — labels, prose,
                                        controls
     MONO    (Atkinson Hyperlegible)    what the product MEASURES  — every figure,
                                        always

   A trader can tell at a glance whether they are reading a claim or a number.
   That is worth more than any amount of colour.

   WHY THESE THREE FACES AND NOT THE PREVIOUS ONES: see tokens/fonts.css. Short
   version — the old set (Instrument Serif, Archivo, Geist Mono) was two named slop
   faces plus a default, and every face here is instead chosen against a stated
   requirement of a trading instrument. Argue with the requirement, not the face.

   BASE TYPE IS 13px, up from 12px. 12px was tuned for "a dense panel read at desk
   distance", but the surface this actually runs on is a second monitor, often
   further away than the primary. The row height is held constant by tightening
   leading from 1.5 to 1.45 and trimming panel padding, so the density survives
   while legibility improves. Measured, not guessed: the journal table shows the
   same number of rows before and after. */

:root {
  /* Fallbacks are deliberate rather than the usual copy-pasted system stack —
     each one is the closest metric match available locally, so the FOUT window
     does not reflow the layout:
       Source Serif 4 → Charter/Georgia (sturdy, low-contrast text serifs)
       Golos Text     → the platform UI face, which is the nearest large-x-height
                        grotesque a machine is guaranteed to have
       Atkinson Mono  → the platform mono */
  --font-display: 'Source Serif 4', Charter, Georgia, serif;
  --font-sans: 'Golos Text', system-ui, 'Segoe UI', sans-serif;
  --font-mono: 'Atkinson Hyperlegible Mono', ui-monospace, SFMono-Regular, Menlo, monospace;

  /* THE FIGURE TREATMENT. Every number in the product gets this, not bare
     `tabular-nums`.

       tabular-nums  every digit the same width, so a column of money reads as a
                     column and a changing price does not reflow its neighbours
       lining-nums   digits at cap height, so they hold a straight top edge —
                     old-style figures with descenders break scanning in a table
       slashed-zero  the last homoglyph the letterforms cannot fix on their own

     Declared as a token so the three stay together. Applied via the mono face,
     which is already the rule for all figures. */
  --figure-variant: tabular-nums lining-nums slashed-zero; /* @kind other */

  /* --- scale ------------------------------------------------------------
     Uneven steps on purpose. The gap from base to md is one pixel because they
     sit side by side in the same panel; the gap from xl to 2xl is six because
     nothing sits between a section head and a page title. */
  --text-2xs: 10px;  /* badges and chips only — the floor */
  --text-xs: 11px;
  --text-sm: 12px;
  --text-base: 13px;
  --text-md: 14px;
  --text-lg: 16px;
  --text-xl: 20px;
  --text-2xl: 26px;
  --text-3xl: 34px;  /* display only */

  --weight-normal: 400;
  --weight-medium: 500;
  --weight-semibold: 600;
  --weight-bold: 700;

  --leading-tight: 1.15;
  --leading-snug: 1.35;
  --leading-normal: 1.45;
  --leading-relaxed: 1.6;

  /* Negative at display sizes, positive only for signage. Large display type set
     at body tracking looks loose; small caps set at display tracking looks
     cramped. The sign flips with size. */
  --tracking-tight: -0.02em;
  --tracking-normal: 0;
  --tracking-wide: 0.04em;
  --tracking-wider: 0.08em;
  /* The wordmark lockup, and nothing else. */
  --tracking-brand: 0.19em;
}
