/* Font choice shared by Modular IAM, Modular SIEM and Modular PAM (Settings > Themes > Font,
   user menu > Font). The font files are in this folder (faces.css), so nothing is loaded from
   the internet. fonts.js sets <html data-font="…">; without it the classic font is shown.

   Every stack ends in Noto Sans (bundled: Latin, Greek, Cyrillic, Vietnamese) and then the
   operating system's fonts, so names and data in other scripts (Arabic, Chinese, Hindi …) still
   show with the system's own fonts. */
:root {
  --ff-fallback: "Noto Sans Variable", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif;
  --ff-classic-serif: "Cormorant Garamond Variable", "Times New Roman", "Noto Serif", serif;
  --ff-classic: "Montserrat Variable", var(--ff-fallback);
  --ff-inter: "Inter Variable", var(--ff-fallback);
  --ff-plex: "IBM Plex Sans Variable", var(--ff-fallback);
  --ff-source: "Source Sans 3 Variable", var(--ff-fallback);
  --ff-roboto: "Roboto Variable", var(--ff-fallback);
  --ff-noto: "Noto Sans Variable", system-ui, -apple-system, "Segoe UI", sans-serif;
  /* The real macOS / Windows interface fonts where the computer has them (they cannot be bundled),
     else a bundled look-alike: Inter for San Francisco, Open Sans for Segoe UI. */
  --ff-macos: -apple-system, BlinkMacSystemFont, "SF Pro Text", "SF Pro Display", "Helvetica Neue", "Inter Variable", var(--ff-fallback);
  --ff-windows: "Segoe UI Variable Text", "Segoe UI Variable", "Segoe UI", "Open Sans Variable", var(--ff-fallback);
  --ff-system: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Ubuntu, Cantarell, "Helvetica Neue", Arial, "Noto Sans", sans-serif;
  --ff-mono: "JetBrains Mono Variable", ui-monospace, "SF Mono", Menlo, Consolas, "Liberation Mono", monospace;
  --mono: var(--ff-mono);
}

html:not([data-font]), html[data-font="classic"] { --sans: var(--ff-classic); --serif: var(--ff-classic-serif); }
html[data-font="inter"] { --sans: var(--ff-inter); --serif: var(--ff-inter); }
html[data-font="plex"] { --sans: var(--ff-plex); --serif: var(--ff-plex); }
html[data-font="source"] { --sans: var(--ff-source); --serif: var(--ff-source); }
html[data-font="roboto"] { --sans: var(--ff-roboto); --serif: var(--ff-roboto); }
html[data-font="noto"] { --sans: var(--ff-noto); --serif: var(--ff-noto); }
html[data-font="macos"] { --sans: var(--ff-macos); --serif: var(--ff-macos); }
html[data-font="windows"] { --sans: var(--ff-windows); --serif: var(--ff-windows); }
html[data-font="system"] { --sans: var(--ff-system); --serif: var(--ff-system); }
html[data-font="mono"] { --sans: var(--ff-mono); --serif: var(--ff-mono); }

/* The classic font is drawn thin (weight 300); the other fonts read better at their normal weight,
   and their headings a little heavier than the classic serif's. */
html[data-font]:not([data-font="classic"]) body,
html[data-font]:not([data-font="classic"]) input,
html[data-font]:not([data-font="classic"]) select { font-weight: 400; }
html[data-font]:not([data-font="classic"]) h1,
html[data-font]:not([data-font="classic"]) h2,
html[data-font]:not([data-font="classic"]) h3 { font-weight: 600; letter-spacing: -.005em; }

/* The product name in the header is a logo: it keeps the classic letters whatever the font. */
.brand-mark { font-family: var(--ff-classic-serif); }

/* Code, IDs and other fixed-width text. */
pre, code, kbd, samp, textarea, .mono { font-family: var(--mono); }

/* Font cards (Settings > Themes and user menu > Font). */
.font-card .font-sample { font-size: 28px; line-height: 1.15; color: var(--text); font-weight: 400; }
.font-card .font-sample-line { font-size: 13px; line-height: 1.4; color: var(--text-2); font-weight: 400; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
