/* ==============================================================================
 * 本地自托管字体（2026-11-20）
 *
 * 为什么不用 fonts.googleapis.com / fonts.gstatic.com：
 *   国内访问这两个域经常不可达或极慢，浏览器会一直等到连接超时才回退系统字体，
 *   期间文字可能长时间不可见（FOIT），实测能给首屏凭空加 2~5 秒。
 *
 * 许可证（两款均为 SIL Open Font License 1.1，允许商用，要求随分发保留许可证）：
 *   - Plus Jakarta Sans: Copyright 2020 The Plus Jakarta Sans Project Authors
 *     https://github.com/tokotype/PlusJakartaSans  → 见 OFL-PlusJakartaSans.txt
 *   - JetBrains Mono:    Copyright 2020 The JetBrains Mono Project Authors
 *     https://github.com/JetBrains/JetBrainsMono   → 见 OFL-JetBrainsMono.txt
 *   两个 LICENSE 文件就在同目录，部署时一起上传（assets/fonts/*.txt）。
 *
 * 为什么只放 latin 子集：
 *   中文字形只走系统字体栈（微软雅黑/苹方/思源），不下载任何中文字体文件 ——
 *   一个中文字体动辄 3–8MB，子集化又要额外维护，得不偿失。
 *   latin 子集只覆盖英文/数字/标点，两个文件合计约 58KB。
 *
 * 为什么用可变字体一个文件覆盖多个字重：
 *   Google 的 latin 子集是 variable font，400/500/600/700/800 共用一个文件，
 *   所以下面 5 条 @font-face 指向同一个 src，浏览器只下载一次。
 *
 * font-display: swap —— 字体没到之前先用系统字体渲染文字，绝不白屏等字体。
 * ============================================================================ */

/* ---------- Plus Jakarta Sans（正文/界面） ---------- */
@font-face {
  font-family: 'Plus Jakarta Sans';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('/assets/fonts/plus-jakarta-sans-latin-1.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA,
                 U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122,
                 U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Plus Jakarta Sans';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('/assets/fonts/plus-jakarta-sans-latin-1.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA,
                 U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122,
                 U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Plus Jakarta Sans';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('/assets/fonts/plus-jakarta-sans-latin-1.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA,
                 U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122,
                 U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Plus Jakarta Sans';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('/assets/fonts/plus-jakarta-sans-latin-1.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA,
                 U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122,
                 U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Plus Jakarta Sans';
  font-style: normal;
  font-weight: 800;
  font-display: swap;
  src: url('/assets/fonts/plus-jakarta-sans-latin-1.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA,
                 U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122,
                 U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* ---------- JetBrains Mono（等宽：数字/代码/积分） ---------- */
@font-face {
  font-family: 'JetBrains Mono';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('/assets/fonts/jetbrains-mono-latin-1.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA,
                 U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122,
                 U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'JetBrains Mono';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('/assets/fonts/jetbrains-mono-latin-1.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA,
                 U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122,
                 U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
