/* Canonical typography layer. The CJK-capable Noto Sans SC subset is local so
 * Chinese glyphs render consistently across macOS and Windows. */
@import url('./assets/fonts/noto-sans-sc.css');

:root {
  --font-ui: 'Noto Sans SC', 'PingFang SC', 'Microsoft YaHei',
    'Noto Sans CJK SC', system-ui, sans-serif;
  --font-heading: var(--font-ui);
  --font-number: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

/* Keep icon fonts, SVG internals, and explicit code fields intact. */
body {
  font-family: var(--font-ui);
  font-synthesis: none;
  text-rendering: optimizeLegibility;
}

body :where(*):not(svg):not(svg *):not(code):not(pre):not(kbd):not(samp):not([class^='fa']):not([class*=' fa-']):not(.fa):not(.fas):not(.far):not(.fab) {
  font-family: inherit;
  font-synthesis: none;
}

body :where(h1, h2, h3, h4, h5, h6) {
  font-family: var(--font-heading);
}

body :where(button, input, select, textarea) {
  font-family: inherit;
}

body :where(code, pre, kbd, samp, [class*='code'], [class*='Code']) {
  font-family: var(--font-number);
}

/* SVG chart labels are text, not icons, and must use the same UI font. */
body :where(svg text) {
  font-family: var(--font-ui);
  font-synthesis: none;
}
