/*
 * 品牌字体,自己托管(第 8 阶段 Lighthouse 检查,产品负责人 2026-10-19 定)。取代原来的 Google Fonts 样式表:
 *
 * - 隐私:从 fonts.googleapis.com 加载时每次打开页面都把访客 IP 发给 Google,而隐私政策里没写这个第三方
 *   (欧盟有判例认定这违反 GDPR);同源发就没有这回事。
 * - 速度:Google 的样式表挡首帧,字体又是另一个域名;快照先用系统字体画、网页字体后到,
 *   真页面接手时文字略大,Lighthouse 记成一个更晚的 LCP(G4 指南 6.6 s)。同源 + 预加载让字体赶上首帧。
 *
 * 文件是 2026-10-19 从 Google Fonts 下的可变字体(与原来那条 link 同参数:Bricolage Grotesque 的 opsz 轴 +
 * 500–800、Instrument Sans 400–700、JetBrains Mono 400–500),每款只留 latin 与 latin-ext 两个子集
 * (正文都是英文;中文界面本来就落到系统字体)。字重范围、unicode-range 照 Google 当时给的样式表抄,
 * 换字体要连同 OFL.txt 一起换。字族名与 `tailwind.css` 的 `--font-display / --font-body / --font-mono` 对得上。
 *
 * 放在 public 里由页面直接 link,不进 tailwind.css:打包器不碰这里的 url(),dev 与 build 同一份。
 * 预加载的两份(Instrument Sans、Bricolage Grotesque 的 latin)写在 `config/config.ts` 的 `links`。
 */

@font-face {
  font-family: 'Bricolage Grotesque';
  font-style: normal;
  font-weight: 500 800;
  font-display: swap;
  src: url('/brand-fonts/bricolage-grotesque/bricolage-grotesque-latin-ext.woff2') format('woff2');
  unicode-range:
    U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329,
    U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F,
    U+A720-A7FF;
}

@font-face {
  font-family: 'Bricolage Grotesque';
  font-style: normal;
  font-weight: 500 800;
  font-display: swap;
  src: url('/brand-fonts/bricolage-grotesque/bricolage-grotesque-latin.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: 'Instrument Sans';
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url('/brand-fonts/instrument-sans/instrument-sans-latin-ext.woff2') format('woff2');
  unicode-range:
    U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329,
    U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F,
    U+A720-A7FF;
}

@font-face {
  font-family: 'Instrument Sans';
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url('/brand-fonts/instrument-sans/instrument-sans-latin.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;
}

/*
 * 「… Snapshot」:同一个文件、`font-display: block`,只给预渲染快照用(`scripts/prerender/snapshot-fonts.ts`
 * 在 `#tm-prerender` 上把 `--font-display / --font-body` 换成它们;理由见那个文件)。
 * 同一个 URL 浏览器只下一次。没有快照的页面不引用这两个字族,不会去下。
 */

@font-face {
  font-family: 'Bricolage Grotesque Snapshot';
  font-style: normal;
  font-weight: 500 800;
  font-display: block;
  src: url('/brand-fonts/bricolage-grotesque/bricolage-grotesque-latin-ext.woff2') format('woff2');
  unicode-range:
    U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329,
    U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F,
    U+A720-A7FF;
}

@font-face {
  font-family: 'Bricolage Grotesque Snapshot';
  font-style: normal;
  font-weight: 500 800;
  font-display: block;
  src: url('/brand-fonts/bricolage-grotesque/bricolage-grotesque-latin.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: 'Instrument Sans Snapshot';
  font-style: normal;
  font-weight: 400 700;
  font-display: block;
  src: url('/brand-fonts/instrument-sans/instrument-sans-latin-ext.woff2') format('woff2');
  unicode-range:
    U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329,
    U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F,
    U+A720-A7FF;
}

@font-face {
  font-family: 'Instrument Sans Snapshot';
  font-style: normal;
  font-weight: 400 700;
  font-display: block;
  src: url('/brand-fonts/instrument-sans/instrument-sans-latin.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: 400 500;
  font-display: swap;
  src: url('/brand-fonts/jetbrains-mono/jetbrains-mono-latin-ext.woff2') format('woff2');
  unicode-range:
    U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329,
    U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F,
    U+A720-A7FF;
}

@font-face {
  font-family: 'JetBrains Mono';
  font-style: normal;
  font-weight: 400 500;
  font-display: swap;
  src: url('/brand-fonts/jetbrains-mono/jetbrains-mono-latin.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;
}
