/* ==========================================================================
   酥小葱 · 个人主页
   纯静态样式表，无构建、无外部依赖。
   字体全部走系统栈（国内网络下不加载 Google Fonts）。
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. 设计令牌
   -------------------------------------------------------------------------- */
:root {
  --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC",
    "Hiragino Sans GB", "Microsoft YaHei", "Source Han Sans SC",
    "Noto Sans CJK SC", sans-serif;
  --font-serif: "Songti SC", "Source Han Serif SC", "Noto Serif CJK SC",
    Georgia, "Times New Roman", serif;
  --font-mono: "SF Mono", SFMono-Regular, Menlo, Consolas,
    "Liberation Mono", monospace;

  --bg:          #fbfaf8;
  --bg-elev:     #ffffff;
  --bg-sunken:   #f4f2ee;
  --text:        #17171a;
  --text-2:      #55555e;
  --text-3:      #6f6f78;
  --border:      #e6e3dd;
  --border-firm: #d4d0c8;
  --accent:      #a8442a;
  --on-accent:   #ffffff;
  --accent-hov:  #8a3620;
  --accent-soft: rgba(168, 68, 42, 0.07);
  --shadow:      0 1px 2px rgba(23, 23, 26, 0.04),
                 0 4px 16px rgba(23, 23, 26, 0.05);

  --measure:  46rem;   /* 正文阅读宽度 */
  --wide:     62rem;   /* 卡片区宽度 */
  --gutter:   1.5rem;
  --radius:   10px;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg:          #121214;
    --bg-elev:     #1a1a1e;
    --bg-sunken:   #0d0d0f;
    --text:        #ececef;
    --text-2:      #a8a8b0;
    --text-3:      #8f8f99;
    --border:      #2c2c32;
    --border-firm: #3c3c44;
    --accent:      #e0836a;
    --on-accent:   #121214;
    --accent-hov:  #f0a189;
    --accent-soft: rgba(224, 131, 106, 0.11);
    --shadow:      0 1px 2px rgba(0, 0, 0, 0.3),
                   0 4px 16px rgba(0, 0, 0, 0.24);
  }
}

:root[data-theme="dark"] {
  --bg:          #121214;
  --bg-elev:     #1a1a1e;
  --bg-sunken:   #0d0d0f;
  --text:        #ececef;
  --text-2:      #a8a8b0;
  --text-3:      #8f8f99;
  --border:      #2c2c32;
  --border-firm: #3c3c44;
  --accent:      #e0836a;
  --on-accent:   #121214;
  --accent-hov:  #f0a189;
  --accent-soft: rgba(224, 131, 106, 0.11);
  --shadow:      0 1px 2px rgba(0, 0, 0, 0.3),
                 0 4px 16px rgba(0, 0, 0, 0.24);
}

/* --------------------------------------------------------------------------
   2. 基础重置与排版
   -------------------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: 5rem;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.75;
  letter-spacing: 0.01em;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

h1, h2, h3, h4 {
  margin: 0;
  line-height: 1.3;
  font-weight: 650;
  letter-spacing: -0.01em;
}

p { margin: 0 0 1.1em; }
p:last-child { margin-bottom: 0; }

a {
  color: var(--accent);
  text-decoration: none;
  text-underline-offset: 0.2em;
  transition: color 0.15s ease;
}
a:hover { color: var(--accent-hov); text-decoration: underline; }

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 3px;
}

img { max-width: 100%; height: auto; display: block; }

code, kbd {
  font-family: var(--font-mono);
  font-size: 0.88em;
  background: var(--bg-sunken);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 0.1em 0.36em;
}

hr {
  border: 0;
  border-top: 1px solid var(--border);
  margin: 3rem 0;
}

::selection { background: var(--accent-soft); }

/* 跳转到主内容（键盘 / 读屏用户） */
.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 100;
  background: var(--accent);
  color: var(--on-accent);
  padding: 0.6rem 1rem;
  border-radius: 0 0 var(--radius) 0;
}
.skip-link:focus { left: 0; }

/* --------------------------------------------------------------------------
   3. 布局容器
   -------------------------------------------------------------------------- */
.wrap {
  width: 100%;
  max-width: var(--measure);
  margin-inline: auto;
  padding-inline: var(--gutter);
}
.wrap--wide { max-width: var(--wide); }

section { padding-block: 3.5rem; }
section + section { border-top: 1px solid var(--border); }

.section-title {
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-3);
  /* 跟在上一段内容后面时需要留出呼吸；作为容器首个元素或紧随页内目录时不需要 */
  margin: 3rem 0 1.75rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}
.section-title:first-child,
.toc + .section-title { margin-top: 0; }
.section-title::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--border);
}

/* --------------------------------------------------------------------------
   4. 顶部导航
   -------------------------------------------------------------------------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: saturate(180%) blur(12px);
  -webkit-backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--border);
}

/* 不支持 color-mix 的浏览器退回不透明底色 */
@supports not (background: color-mix(in srgb, red 50%, transparent)) {
  .site-header { background: var(--bg); }
}

.nav {
  max-width: var(--wide);
  margin-inline: auto;
  padding: 0.75rem var(--gutter);
  display: flex;
  align-items: center;
  gap: 1rem;
}

.nav__brand {
  font-weight: 700;
  font-size: 1rem;
  color: var(--text);
  letter-spacing: 0.02em;
  white-space: nowrap;
}
.nav__brand:hover { color: var(--accent); text-decoration: none; }

.nav__links {
  display: flex;
  gap: 0.25rem;
  margin: 0 0 0 auto;
  padding: 0;
  list-style: none;
  align-items: center;
}

.nav__links a {
  display: block;
  padding: 0.35rem 0.7rem;
  border-radius: 6px;
  font-size: 0.92rem;
  color: var(--text-2);
  white-space: nowrap;
}
.nav__links a:hover {
  background: var(--bg-sunken);
  color: var(--text);
  text-decoration: none;
}
.nav__links a[aria-current="page"] {
  color: var(--accent);
  font-weight: 600;
}

.theme-toggle {
  flex: none;
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: transparent;
  color: var(--text-2);
  cursor: pointer;
  padding: 0;
  transition: background 0.15s ease, color 0.15s ease;
}
.theme-toggle:hover { background: var(--bg-sunken); color: var(--text); }
.theme-toggle svg { width: 17px; height: 17px; }
.theme-toggle .icon-sun  { display: none; }
:root[data-theme="dark"] .theme-toggle .icon-sun  { display: block; }
:root[data-theme="dark"] .theme-toggle .icon-moon { display: none; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .theme-toggle .icon-sun  { display: block; }
  :root:not([data-theme="light"]) .theme-toggle .icon-moon { display: none; }
}

@media (max-width: 34rem) {
  .nav { flex-wrap: wrap; row-gap: 0.4rem; }
  .theme-toggle { margin-left: auto; }

  /* 窄屏下导航改为单行横向滚动，条目不换行也不压缩 */
  .nav__links {
    width: 100%;
    order: 3;
    margin-left: -0.7rem;
    flex-wrap: nowrap;
    overflow-x: auto;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
  }
  .nav__links::-webkit-scrollbar { display: none; }
  .nav__links > li { flex: none; }
}

/* --------------------------------------------------------------------------
   5. Hero
   -------------------------------------------------------------------------- */
.hero { padding-block: 4.5rem 3.5rem; }

/* 栅格区域布局：桌面端头像在右侧跨两行；窄屏时头像仍与姓名并排，
   简介／信息／按钮整行落到下面，而不是被挤成一列后掉到最底部 */
.hero__grid {
  display: grid;
  grid-template-columns: 1fr auto;
  grid-template-areas:
    "head   avatar"
    "hobby  avatar"
    "body   avatar";
  column-gap: 2.5rem;
  row-gap: 0;
  align-items: start;
}
.hero__head   { grid-area: head; }
.hero__avatar { grid-area: avatar; }
.hero__hobby  { grid-area: hobby; }
.hero__body   { grid-area: body; }

.hero__name {
  font-size: clamp(2rem, 5vw, 2.75rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 0.15rem;
}

.hero__hobby {
  font-size: 1rem;
  letter-spacing: 0.06em;
  line-height: 1.8;
  margin-bottom: 1.1rem;
}

.hero__tagline {
  font-size: 1.1rem;
  color: var(--text-2);
  max-width: 34rem;
  margin-bottom: 1.5rem;
}

.hero__affil {
  list-style: none;
  margin: 0 0 1.75rem;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  font-size: 0.94rem;
  color: var(--text-2);
}
.hero__affil li { display: flex; gap: 0.6rem; align-items: baseline; }
.hero__affil .label {
  flex: none;
  width: 4.5em;
  color: var(--text-3);
  font-size: 0.85rem;
}

.hero__avatar {
  width: 156px;
  height: 156px;
  border-radius: 50%;
  object-fit: cover;
  border: 1px solid var(--border);
  /* 图片背景已烘成浅色主题的 --bg，浅色下与页面无缝衔接 */
  background: var(--bg);
}

@media (max-width: 40rem) {
  /* 上内边距收紧，让头像贴近导航下方的分割线 */
  .hero { padding-block: 1.25rem 2.5rem; }
  /* 兴趣行改为独占一行，落在头像／姓名之下、简介之上 */
  .hero__grid {
    grid-template-areas:
      "head  avatar"
      "hobby hobby"
      "body  body";
    column-gap: 1.25rem;
  }
  /* 头像顶部对齐、姓名底部对齐 —— 头像在右上、姓名在左下，两者底边齐平 */
  .hero__avatar { align-self: start; width: 104px; height: 104px; }
  .hero__head { align-self: end; }
  /* 姓名缩一档，保证「苏彦聪｜Yancong Su」在头像旁边不折行 */
  .hero__name { font-size: clamp(1.25rem, 5.6vw, 1.6rem); }
  .hero__hobby { margin: 1rem 0 0; font-size: 0.95rem; }
  .hero__body { margin-top: 1.35rem; }
}

/* --------------------------------------------------------------------------
   6. 按钮 / 徽标
   -------------------------------------------------------------------------- */
.btn-row { display: flex; flex-wrap: wrap; gap: 0.6rem; }

.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.45rem 0.95rem;
  border: 1px solid var(--border-firm);
  border-radius: 7px;
  background: var(--bg-elev);
  color: var(--text-2);
  font-size: 0.9rem;
  font-weight: 500;
  transition: all 0.15s ease;
}
.btn:hover {
  border-color: var(--accent);
  color: var(--accent);
  text-decoration: none;
  transform: translateY(-1px);
}
.btn svg { width: 15px; height: 15px; flex: none; }

.btn--primary {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--on-accent);
}
.btn--primary:hover {
  background: var(--accent-hov);
  border-color: var(--accent-hov);
  color: var(--on-accent);
}

.tag {
  display: inline-block;
  padding: 0.12rem 0.5rem;
  border-radius: 4px;
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  white-space: nowrap;
}
.tag--muted {
  background: var(--bg-sunken);
  color: var(--text-3);
  border: 1px solid var(--border);
}

/* --------------------------------------------------------------------------
   7. 卡片网格（研究方向 / 项目）
   -------------------------------------------------------------------------- */
.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr));
  gap: 1rem;
}

/* 固定两列（研究方向：两行两列），窄屏退回单列 */
.cards--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (max-width: 44rem) {
  .cards--2 { grid-template-columns: 1fr; }
}

.card {
  padding: 1.35rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg-elev);
  /* 弹性列 + 标签行 margin-top:auto，同一行内文字长短不一时标签仍贴底对齐 */
  display: flex;
  flex-direction: column;
  transition: border-color 0.15s ease, transform 0.15s ease,
    box-shadow 0.15s ease;
}
a.card:hover {
  border-color: var(--accent);
  transform: translateY(-2px);
  box-shadow: var(--shadow);
  text-decoration: none;
}

.card__title {
  font-size: 1rem;
  font-weight: 650;
  color: var(--text);
  margin-bottom: 0.5rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.card__body {
  font-size: 0.9rem;
  color: var(--text-2);
  line-height: 1.7;
}

.card__meta {
  margin-top: auto;
  padding-top: 0.75rem;
  border-top: 1px solid var(--border);
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
  font-size: 0.8rem;
  color: var(--text-3);
}

.card__num {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--accent);
  letter-spacing: 0.08em;
}

.pub-list { list-style: none; margin: 0; padding: 0; }

/* 微信二维码浮层：按钮开合，点任意处关闭 */
.qr-overlay {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: grid;
  place-items: center;
  padding: var(--gutter);
  background: rgba(23, 23, 26, 0.55);
  -webkit-backdrop-filter: blur(3px);
  backdrop-filter: blur(3px);
  cursor: pointer;
}
.qr-overlay[hidden] { display: none; }

.qr-card {
  margin: 0;
  padding: 1.1rem 1.1rem 0.9rem;
  background: var(--bg-elev);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.28);
  text-align: center;
}
.qr-card img {
  width: 220px;
  height: 220px;
  display: block;
  border-radius: 4px;
  user-select: none;
}
.qr-card figcaption {
  margin-top: 0.7rem;
  font-size: 0.82rem;
  color: var(--text-3);
}

@media (prefers-reduced-motion: no-preference) {
  .qr-overlay:not([hidden]) .qr-card { animation: qr-in 0.16s ease-out; }
  @keyframes qr-in {
    from { opacity: 0; transform: scale(0.96); }
    to   { opacity: 1; transform: scale(1); }
  }
}

/* --------------------------------------------------------------------------
   8. 论文条目
   -------------------------------------------------------------------------- */
.pub {
  padding: 1.1rem 0;
  border-top: 1px solid var(--border);
  display: grid;
  grid-template-columns: 3.5rem 1fr;
  gap: 1rem;
}
.pub:first-child { border-top: 0; }
.pub:last-child { border-bottom: 1px solid var(--border); }

.pub__type {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: var(--text-3);
  text-transform: uppercase;
  padding-top: 0.35rem;
}

.pub__title {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 0.3rem;
  line-height: 1.5;
}

.pub__authors {
  font-size: 0.88rem;
  color: var(--text-2);
  margin-bottom: 0.2rem;
}
.pub__authors .me { color: var(--text); font-weight: 650; }

.pub__venue {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 0.88rem;
  color: var(--text-2);
  margin-bottom: 0.6rem;
}

.pub__links { display: flex; flex-wrap: wrap; gap: 0.4rem; }

.pub__links a {
  font-size: 0.78rem;
  font-weight: 500;
  padding: 0.12rem 0.5rem;
  border: 1px solid var(--border-firm);
  border-radius: 4px;
  color: var(--text-2);
}
.pub__links a:hover {
  border-color: var(--accent);
  color: var(--accent);
  text-decoration: none;
}

@media (max-width: 34rem) {
  .pub { grid-template-columns: 1fr; gap: 0.35rem; }
  .pub__type { padding-top: 0; }
}

/* --------------------------------------------------------------------------
   9. 时间线（简历 / 动态）
   -------------------------------------------------------------------------- */
.timeline { list-style: none; margin: 0; padding: 0; }

.timeline > li {
  display: grid;
  grid-template-columns: 8rem 1fr;
  gap: 1.25rem;
  padding: 1rem 0;
  border-top: 1px solid var(--border);
}
.timeline > li:first-child { border-top: 0; }
.timeline > li:last-child { border-bottom: 1px solid var(--border); }

.timeline__when {
  font-family: var(--font-mono);
  font-size: 0.82rem;
  color: var(--text-3);
  padding-top: 0.2rem;
  white-space: nowrap;
}

.timeline__what strong {
  display: block;
  font-size: 0.98rem;
  font-weight: 620;
  color: var(--text);
  margin-bottom: 0.15rem;
}

.timeline__what span {
  font-size: 0.89rem;
  color: var(--text-2);
}

@media (max-width: 34rem) {
  .timeline > li { grid-template-columns: 1fr; gap: 0.3rem; }
  .timeline__when { padding-top: 0; }
}

/* --------------------------------------------------------------------------
   10. 页脚
   -------------------------------------------------------------------------- */
.site-footer {
  border-top: 1px solid var(--border);
  padding-block: 2.5rem 3rem;
  margin-top: 2rem;
  font-size: 0.85rem;
  color: var(--text-3);
}
.site-footer .wrap {
  max-width: var(--wide);
  text-align: center;
}
.site-footer p { margin: 0; line-height: 1.9; }
.site-footer p + p { margin-top: 0.3rem; }

.site-footer__updated time { color: var(--text-2); font-weight: 650; }

.site-footer__license { font-size: 0.8rem; }
.site-footer__license a { color: var(--text-2); text-decoration: underline; }
.site-footer__license a:hover { color: var(--accent); }

/* 协作署名：中英两行，比上方再轻一档；人名加粗并提亮一档以便识别 */
.site-footer__credit {
  font-size: 0.78rem;
  color: var(--text-3);
}
.site-footer__credit strong { font-weight: 650; color: var(--text-2); }
.site-footer__credit a { color: inherit; text-decoration: none; }
.site-footer__credit a:hover strong { color: var(--accent); }
.site-footer__credit a:hover { text-decoration: underline; }
.site-footer__credit[lang="en"] {
  letter-spacing: 0.01em;
  opacity: 0.9;
}
.site-footer__credit:first-of-type { margin-top: 0.75rem; }

/* --------------------------------------------------------------------------
   11. 数字概览
   -------------------------------------------------------------------------- */
.stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(8rem, 1fr));
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  margin-top: 2rem;
}
.stats > div {
  background: var(--bg-elev);
  padding: 1.1rem 1rem;
  text-align: center;
}
.stats b {
  display: block;
  font-family: var(--font-mono);
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--accent);
  line-height: 1.2;
  letter-spacing: -0.02em;
}
.stats span {
  font-size: 0.78rem;
  color: var(--text-3);
  letter-spacing: 0.04em;
}

/* --------------------------------------------------------------------------
   12. 编号条目列表（课题 / 竞赛 / 项目）
   -------------------------------------------------------------------------- */
.entries {
  list-style: none;
  margin: 0;
  padding: 0;
  counter-reset: entry;
}

.entries > li {
  counter-increment: entry;
  display: grid;
  grid-template-columns: 2.25rem 1fr;
  gap: 0.9rem;
  padding: 0.85rem 0;
  border-top: 1px solid var(--border);
  font-size: 0.94rem;
}
.entries > li:first-child { border-top: 0; }
.entries > li:last-child { border-bottom: 1px solid var(--border); }

.entries > li::before {
  content: counter(entry);
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-3);
  padding-top: 0.4rem;
  text-align: right;
}

.entry__title {
  color: var(--text);
  font-weight: 550;
  line-height: 1.6;
}

.entry__meta {
  margin-top: 0.2rem;
  font-size: 0.85rem;
  color: var(--text-2);
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 0.7rem;
  align-items: baseline;
}
.entry__meta time,
.entry__meta .fund {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--text-3);
}

.role {
  display: inline-block;
  padding: 0.05rem 0.42rem;
  border-radius: 3px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  background: var(--accent-soft);
  color: var(--accent);
}
.role--minor {
  background: var(--bg-sunken);
  color: var(--text-3);
  border: 1px solid var(--border);
  font-weight: 500;
}

@media (max-width: 34rem) {
  .entries > li { grid-template-columns: 1.5rem 1fr; gap: 0.6rem; }
}

/* --------------------------------------------------------------------------
   13. 课程列表
   -------------------------------------------------------------------------- */
.courses { list-style: none; margin: 0; padding: 0; }
.courses > li {
  padding: 0.5rem 0;
  border-top: 1px dashed var(--border);
  font-size: 0.94rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: baseline;
}
.courses > li:first-child { border-top: 0; }
.courses .years {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--text-3);
  margin-left: auto;
  white-space: nowrap;
}
.courses .current { font-weight: 650; color: var(--text); }

.subhead {
  font-size: 0.95rem;
  font-weight: 650;
  color: var(--text);
  margin: 2rem 0 0.6rem;
  padding-bottom: 0.3rem;
  border-bottom: 2px solid var(--accent-soft);
}
/* 紧跟在章节标题下的三级标题不再另加上边距，间距统一交给章节标题的 margin-bottom */
.subhead:first-of-type,
.section-title + .subhead { margin-top: 0; }

/* --------------------------------------------------------------------------
   14. 简历式紧凑列表
   -------------------------------------------------------------------------- */
.roles { list-style: none; margin: 0; padding: 0; }
.roles > li {
  padding: 0.42rem 0;
  border-top: 1px solid var(--border);
  font-size: 0.92rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem 0.75rem;
  align-items: baseline;
}
.roles > li:first-child { border-top: 0; }
.roles .org { color: var(--text-2); }
.roles .post {
  margin-left: auto;
  font-weight: 620;
  color: var(--text);
  white-space: nowrap;
}

/* 页面级大标题 */
.page-head { margin-bottom: 2.25rem; }
.page-head h1 {
  font-size: clamp(1.7rem, 4vw, 2.1rem);
  margin-bottom: 0.4rem;
}
.page-head p {
  color: var(--text-2);
  font-size: 0.96rem;
  margin: 0;
}

/* 页内锚点导航 */
.toc {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-bottom: 2.25rem;
  padding-bottom: 1.25rem;
  border-bottom: 1px solid var(--border);
}
.toc a {
  font-size: 0.85rem;
  padding: 0.25rem 0.7rem;
  border: 1px solid var(--border-firm);
  border-radius: 999px;
  color: var(--text-2);
}
.toc a:hover {
  border-color: var(--accent);
  color: var(--accent);
  text-decoration: none;
}
