|
30 | 30 | --color-pink-500: #d6a95a; --color-pink-600: #b98a3f; --color-pink-700: #946b31; --color-pink-800: #74542b; --color-pink-900: #5f4526; --color-pink-950: #352413; |
31 | 31 | --color-fuchsia-300: #e9cb8e; --color-fuchsia-400: #e5c07b; --color-fuchsia-500: #d6a95a; |
32 | 32 |
|
33 | | - --font-sans: "Geist", "Noto Sans SC", "PingFang SC", "Inter", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; |
34 | | - --font-mono: "Geist Mono", "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace; |
| 33 | + /* Geist is self-hosted (src/components/Fonts.astro). Chinese text uses the |
| 34 | + system's CJK font: PingFang on macOS and iOS, Microsoft YaHei on Windows, |
| 35 | + Noto Sans CJK on Linux and Android. */ |
| 36 | + --font-sans: "Geist", "Geist Fallback", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans CJK SC", "Noto Sans SC", "Source Han Sans SC", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; |
| 37 | + --font-mono: "Geist Mono", "Geist Mono Fallback", "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace; |
| 38 | +} |
| 39 | + |
| 40 | +/* ---------- Fallback faces ---------- */ |
| 41 | +/* Until Geist and Geist Mono have loaded, text is set in a local font scaled |
| 42 | + to their metrics, so that swapping them in does not reflow the page. For |
| 43 | + each weight, size-adjust is the ratio of the widths of the English text of |
| 44 | + this site's pages set in Geist and in the local font (Arial for 400 and |
| 45 | + 500, Arial Bold for 600 and 700, Courier New for Geist Mono); the ascent, |
| 46 | + descent and line gap are Geist's, divided by size-adjust. Arial, Liberation |
| 47 | + Sans and Arimo share their metrics, as do Courier New, Liberation Mono and |
| 48 | + Cousine, so one set of figures serves macOS, Windows and Linux. */ |
| 49 | +@font-face { |
| 50 | + font-family: "Geist Fallback"; |
| 51 | + src: local("Arial"), local("ArialMT"), local("Liberation Sans"), local("LiberationSans"), local("Arimo"); |
| 52 | + font-weight: 100 400; |
| 53 | + size-adjust: 102.26%; |
| 54 | + ascent-override: 98.28%; |
| 55 | + descent-override: 28.85%; |
| 56 | + line-gap-override: 0%; |
| 57 | +} |
| 58 | +@font-face { |
| 59 | + font-family: "Geist Fallback"; |
| 60 | + src: local("Arial"), local("ArialMT"), local("Liberation Sans"), local("LiberationSans"), local("Arimo"); |
| 61 | + font-weight: 500; |
| 62 | + size-adjust: 104.69%; |
| 63 | + ascent-override: 96%; |
| 64 | + descent-override: 28.18%; |
| 65 | + line-gap-override: 0%; |
| 66 | +} |
| 67 | +@font-face { |
| 68 | + font-family: "Geist Fallback"; |
| 69 | + src: local("Arial Bold"), local("Arial-BoldMT"), local("Liberation Sans Bold"), local("LiberationSans-Bold"), local("Arimo Bold"), local("Arimo-Bold"); |
| 70 | + font-weight: 600; |
| 71 | + size-adjust: 99.89%; |
| 72 | + ascent-override: 100.61%; |
| 73 | + descent-override: 29.53%; |
| 74 | + line-gap-override: 0%; |
| 75 | +} |
| 76 | +@font-face { |
| 77 | + font-family: "Geist Fallback"; |
| 78 | + src: local("Arial Bold"), local("Arial-BoldMT"), local("Liberation Sans Bold"), local("LiberationSans-Bold"), local("Arimo Bold"), local("Arimo-Bold"); |
| 79 | + font-weight: 700 900; |
| 80 | + size-adjust: 102.13%; |
| 81 | + ascent-override: 98.4%; |
| 82 | + descent-override: 28.88%; |
| 83 | + line-gap-override: 0%; |
| 84 | +} |
| 85 | +@font-face { |
| 86 | + font-family: "Geist Mono Fallback"; |
| 87 | + src: local("Courier New"), local("CourierNewPSMT"), local("Liberation Mono"), local("LiberationMono"), local("Cousine"); |
| 88 | + size-adjust: 99.98%; |
| 89 | + ascent-override: 100.52%; |
| 90 | + descent-override: 29.5%; |
| 91 | + line-gap-override: 0%; |
35 | 92 | } |
36 | 93 |
|
37 | 94 | /* ---------- Base ---------- */ |
|
0 commit comments