/*
 * pn-font.css: the one font for ALL text on every PostNext page (owner, 2026-11-18): General Sans,
 * the font CreatorFlow uses. Headings, body, nav, buttons, forms, tables and code.
 *
 * The site carries ~470 legacy font-family rules naming fonts that no longer exist here. Instead of
 * editing each one, a single !important rule inside a cascade layer sets the font on every element.
 * Layered !important beats every unlayered declaration, !important included, whatever its
 * specificity, so link order does not matter and no legacy rule can win.
 *
 * Only icon fonts keep their own family (the :not() list). Pseudo-elements are not matched, so
 * icons drawn in ::before/::after keep working.
 *
 * Files: the stock Fontshare variable woff2 (ITF Free Font License, /font/GeneralSans-LICENSE.txt),
 * the same files as creatorflow-frontend. The license forbids subsetting or converting them, so they
 * are served as downloaded. font-weight is 200-700: CSS that asks for 800/900 renders at 700.
 *
 * General Sans has no Cyrillic. The family adds the Geist Cyrillic subset (SIL OFL 1.1,
 * /font/Geist-LICENSE.txt) for Cyrillic code points only, so Russian letters render in Geist and no
 * other locale downloads it (the CreatorFlow setup). It is declared after the General Sans faces on
 * purpose: for a character two faces cover, the browser tries the last declared face first.
 *
 * Japanese and Korean (2026-11-19, ja-JP and ko-KR on the roster): General Sans has no CJK glyphs and no webfont is
 * downloaded for them (size). The family keeps General Sans FIRST, so Latin letters and digits stay on brand, and
 * falls back per character to the system CJK fonts of each platform (macOS/iOS, Windows, Android/Linux). Headline
 * tracking (-0.04em on Latin) cramps kana, kanji and hangul, so letter-spacing is 0 on those pages; Japanese breaks
 * lines strictly (no small kana or closing brackets at a line start), Korean keeps words whole (keep-all).
 *
 * Self-hosted on purpose: CSP font-src is 'self'. Linked OUTSIDE every usemin build block; bump ?v=
 * on every link when this file changes (served immutable). Every page template must reach it:
 * tests/pn-font-coverage.test.js. Not linked on mini-sites (customer pages pick their own fonts).
 */
@font-face {
    font-family: "General Sans";
    src: url('../../../font/GeneralSans-Variable.woff2') format('woff2');
    font-weight: 200 700;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: "General Sans";
    src: url('../../../font/GeneralSans-VariableItalic.woff2') format('woff2');
    font-weight: 200 700;
    font-style: italic;
    font-display: swap;
}

@font-face {
    font-family: "General Sans";
    src: url('../../../font/Geist-Variable-cyrillic.woff2') format('woff2');
    font-weight: 200 700;
    font-style: normal;
    font-display: swap;
    unicode-range: U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116;
}

:root {
    --pn-font: "General Sans", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Helvetica, Arial, sans-serif;
}

:root:lang(ja) {
    --pn-font: "General Sans", "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Yu Gothic", "Meiryo", "Noto Sans JP", sans-serif;
}

:root:lang(ko) {
    --pn-font: "General Sans", "Apple SD Gothic Neo", "Malgun Gothic", "Noto Sans KR", sans-serif;
}

@layer pn-font {
    body,
    body *:not(
        .fa,
        .glyphicon,
        [class^="icon-jfi-"], [class*=" icon-jfi-"], [data-icon],
        .video-js, .video-js *
    ) {
        font-family: var(--pn-font) !important;
    }
    :root:lang(ja) body, :root:lang(ja) body *,
    :root:lang(ko) body, :root:lang(ko) body * {
        letter-spacing: 0 !important;
    }
    :root:lang(ja) body { line-break: strict; }
    :root:lang(ko) body { word-break: keep-all; overflow-wrap: anywhere; }
}
