:root {
  --bg: #f6f4ef;
  --surface: #ffffff;
  --primary: #1f4d3f;
  --primary-soft: #2c6753;
  --accent: #b45a2b;
  --accent-soft: #c97545;
  --text: #23211e;
  --text-muted: #6b6660;
  --line: #ddd8cf;
  --line-strong: #c8c1b4;
  --radius: 6px;
  --radius-sm: 4px;
  --shadow-hover: 0 6px 18px rgba(31, 77, 63, 0.08);
  --container: 1120px;
  --reading: 760px;
  --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC",
    "Hiragino Sans GB", "Microsoft YaHei", "Source Han Sans SC", "Noto Sans CJK SC",
    Roboto, Helvetica, Arial, sans-serif;
  --font-mono: "SF Mono", "JetBrains Mono", "Cascadia Mono", Consolas,
    "Liberation Mono", Menlo, monospace;
}

/* ==========================================================================
   base — 全站基础
   ========================================================================== */

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background-color: var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.75;
  font-feature-settings: "tnum" 1;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

h1,
h2,
h3,
h4 {
  margin: 0;
  color: var(--text);
  font-weight: 700;
  line-height: 1.35;
}

p {
  margin: 0;
}

ul,
ol {
  margin: 0;
  padding: 0;
  list-style: none;
}

dl,
dd,
dt,
figure,
figcaption {
  margin: 0;
}

img {
  display: block;
  max-width: 100%;
  height: auto;
}

a {
  color: var(--primary);
  text-decoration: none;
  transition: color 0.18s ease, border-color 0.18s ease;
}

a:hover,
a:focus-visible {
  color: var(--accent);
}

a:focus-visible,
button:focus-visible,
summary:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

button {
  font: inherit;
  color: inherit;
  cursor: pointer;
}

time {
  font-variant-numeric: tabular-nums;
}

/* ==========================================================================
   layout — 骨架与容器
   ========================================================================== */

.site-body {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  background-color: var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.75;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background-color: var(--surface);
  border-bottom: 1px solid var(--line);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 14px 24px;
}

.site-main {
  flex: 1 1 auto;
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px 56px;
}

.inner-main {
  padding-top: 20px;
}

.section {
  padding: 40px 0;
  border-top: 1px solid var(--line);
}

.section:first-child {
  border-top: none;
}

.section-title {
  font-size: 22px;
  color: var(--primary);
}

.section-desc,
.section-intro,
.section-lead {
  margin-top: 8px;
  max-width: var(--reading);
  color: var(--text-muted);
  font-size: 15px;
  line-height: 1.8;
}

.section-head {
  margin-bottom: 22px;
}

.site-footer {
  background-color: var(--primary);
  color: #e8e4da;
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 32px 24px 20px;
}

.footer-brand {
  max-width: 420px;
}

.footer-name {
  font-size: 17px;
  font-weight: 700;
  color: #ffffff;
}

.footer-slogan {
  margin-top: 6px;
  font-size: 14px;
  line-height: 1.7;
  color: #c9d6ce;
}

.footer-nav {
  margin-left: auto;
}

.footer-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 22px;
}

.footer-link {
  color: #dbe4de;
  font-size: 14px;
}

.footer-link:hover,
.footer-link:focus-visible {
  color: #ffffff;
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.16);
}

.footer-copy {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 14px 24px 22px;
  font-size: 13px;
  line-height: 1.7;
  color: #b9c8bf;
}

/* ==========================================================================
   components — 通用组件
   ========================================================================== */

/* 品牌标识 */
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
}

.brand:hover,
.brand:focus-visible {
  color: var(--text);
}

.brand-mark {
  display: inline-block;
  width: 26px;
  height: 26px;
  border-radius: var(--radius-sm);
  background-color: var(--primary);
  position: relative;
}

.brand-mark::after {
  content: "";
  position: absolute;
  left: 6px;
  top: 6px;
  width: 14px;
  height: 3px;
  background-color: #f0d9c8;
  box-shadow: 0 5px 0 #f0d9c8, 0 10px 0 #f0d9c8;
}

.brand-name {
  font-size: 19px;
  font-weight: 700;
  letter-spacing: 0;
}

/* 主导航 */
.site-nav {
  display: flex;
  align-items: center;
}

.nav-list {
  display: flex;
  align-items: center;
  gap: 4px;
}

.nav-link {
  display: inline-block;
  padding: 8px 12px;
  color: var(--text);
  font-size: 15px;
  border-bottom: 2px solid transparent;
}

.nav-link:hover,
.nav-link:focus-visible {
  color: var(--accent);
}

.nav-link.is-current {
  color: var(--primary);
  font-weight: 700;
  border-bottom-color: var(--accent);
}

.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  padding: 0 10px;
  background-color: transparent;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
}

.nav-toggle-bar {
  display: block;
  width: 100%;
  height: 2px;
  background-color: var(--text);
}

/* 面包屑 */
.breadcrumb {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  padding: 4px 0 14px;
  font-size: 14px;
  color: var(--text-muted);
}

.breadcrumb a {
  color: var(--text-muted);
}

.breadcrumb a:hover,
.breadcrumb a:focus-visible {
  color: var(--accent);
}

.breadcrumb-sep {
  color: var(--line-strong);
}

.breadcrumb-current {
  color: var(--text);
}

/* 页面标题区 */
.page-header {
  padding: 4px 0 28px;
  border-bottom: 1px solid var(--line);
}

.page-title {
  font-size: 32px;
  font-weight: 700;
  color: var(--primary);
  line-height: 1.3;
}

.page-description {
  margin-top: 12px;
  max-width: var(--reading);
  color: var(--text-muted);
  font-size: 15px;
  line-height: 1.8;
}

/* 文本链接 */
.text-link {
  display: inline-block;
  color: var(--accent);
  font-size: 14px;
  font-weight: 700;
  border-bottom: 1px solid currentColor;
  padding-bottom: 1px;
}

.text-link:hover,
.text-link:focus-visible {
  color: var(--primary);
}

/* 图片容器与说明 */
figure {
  overflow: hidden;
}

figure img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

figcaption {
  margin-top: 10px;
  font-size: 13px;
  line-height: 1.7;
  color: var(--text-muted);
}

.section-media {
  margin: 28px 0;
}

.section-media img {
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: var(--radius);
  border: 1px solid var(--line);
}

/* 相关入口条 */
.related-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 12px;
}

.related-item a,
.related-link {
  display: block;
  padding: 12px 16px;
  background-color: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--text);
  font-size: 15px;
  transition: border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

.related-item a:hover,
.related-item a:focus-visible,
.related-link:hover,
.related-link:focus-visible {
  border-color: var(--primary);
  box-shadow: var(--shadow-hover);
  transform: translateY(-2px);
  color: var(--primary);
}

/* ==========================================================================
   pages — 首页
   ========================================================================== */

.topbar {
  background-color: var(--primary);
}

.topbar-text {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 8px 24px;
  color: #dbe4de;
  font-size: 13px;
  line-height: 1.6;
}

/* 首屏定位区 */
.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  gap: 40px;
  align-items: start;
  padding: 44px 0 48px;
}

.hero-eyebrow {
  margin-bottom: 12px;
  color: var(--accent);
  font-size: 14px;
  font-weight: 700;
}

.hero-title {
  font-size: 32px;
  color: var(--primary);
  line-height: 1.3;
}

.hero-summary {
  margin-top: 16px;
  max-width: 560px;
  color: var(--text-muted);
  font-size: 15px;
  line-height: 1.85;
}

.hero-paths {
  display: grid;
  gap: 10px;
  margin-top: 24px;
}

.hero-path-link {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 14px 16px;
  background-color: var(--surface);
  border: 1px solid var(--line);
  border-left: 3px solid var(--primary);
  border-radius: var(--radius);
  transition: border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

.hero-path-link:hover,
.hero-path-link:focus-visible {
  border-color: var(--primary);
  border-left-color: var(--accent);
  box-shadow: var(--shadow-hover);
  transform: translateY(-2px);
}

.hero-path-name {
  color: var(--text);
  font-size: 16px;
  font-weight: 700;
}

.hero-path-desc {
  color: var(--text-muted);
  font-size: 14px;
  line-height: 1.7;
}

.hero-visual {
  display: grid;
  gap: 16px;
}

.hero-figure {
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background-color: var(--surface);
}

.hero-figure img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}

.hero-figure figcaption {
  padding: 12px 16px 14px;
  margin-top: 0;
}

.hero-notes {
  display: grid;
  gap: 10px;
}

.hero-note {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 10px;
  padding: 12px 14px;
  background-color: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  font-size: 14px;
  line-height: 1.7;
  color: var(--text);
}

.hero-note-label {
  color: var(--accent);
  font-weight: 700;
}

/* 题材方向总览 */
.genre-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

.genre-col {
  display: flex;
  flex-direction: column;
  padding: 18px 18px 20px;
  background-color: var(--surface);
  border: 1px solid var(--line);
  border-top: 3px solid var(--primary);
  border-radius: var(--radius);
}

.genre-name {
  font-size: 17px;
  color: var(--primary);
}

.genre-trait {
  flex: 1 1 auto;
  margin-top: 10px;
  color: var(--text-muted);
  font-size: 14px;
  line-height: 1.75;
}

.genre-entry {
  margin-top: 16px;
  color: var(--accent);
  font-size: 14px;
  font-weight: 700;
}

.genre-entry::after {
  content: " →";
}

.genre-entry:hover,
.genre-entry:focus-visible {
  color: var(--primary);
}

/* 双栏并列区 */
.section-split {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 40px;
  align-items: start;
}

.split-col {
  min-width: 0;
}

/* 封面条目速览 */
.cover-grid {
  display: grid;
  gap: 14px;
}

.cover-card {
  display: grid;
  grid-template-columns: 96px minmax(0, 1fr);
  gap: 16px;
  align-items: center;
  padding: 12px;
  background-color: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  transition: border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

.cover-card:hover,
.cover-card:focus-within {
  border-color: var(--primary);
  box-shadow: var(--shadow-hover);
  transform: translateY(-2px);
}

.cover-figure {
  border-radius: var(--radius-sm);
  border: 1px solid var(--line);
}

.cover-figure img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
}

.cover-meta {
  min-width: 0;
}

.cover-name {
  font-size: 16px;
  color: var(--text);
}

.cover-tag {
  margin-top: 6px;
  color: var(--accent);
  font-size: 13px;
}

.cover-status {
  margin-top: 4px;
  color: var(--text-muted);
  font-size: 13px;
}

/* 最近更新 */
.update-group + .update-group {
  margin-top: 20px;
}

.update-date {
  font-size: 15px;
  color: var(--primary);
  font-variant-numeric: tabular-nums;
}

.update-list {
  margin-top: 10px;
  border-top: 1px solid var(--line);
}

.update-item {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 4px 12px;
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
  font-size: 14px;
}

.update-name {
  flex: 1 1 140px;
  color: var(--text);
  font-weight: 700;
}

.update-type {
  color: var(--accent);
}

.update-genre {
  color: var(--text-muted);
}

.update-more,
.rank-more,
.fields-more {
  margin-top: 16px;
}

/* 位次参考 */
.rank-list {
  border-top: 1px solid var(--line);
}

.rank-item {
  display: flex;
  align-items: baseline;
  gap: 12px;
  padding: 11px 0;
  border-bottom: 1px solid var(--line);
  font-size: 14px;
}

.rank-no {
  flex: 0 0 auto;
  min-width: 26px;
  color: var(--accent);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.rank-name {
  flex: 1 1 auto;
  color: var(--text);
  font-weight: 700;
}

.rank-genre {
  flex: 0 0 auto;
  color: var(--text-muted);
}

/* 字段口径摘要 */
.field-summary {
  border-top: 1px solid var(--line);
}

.field-row {
  display: grid;
  grid-template-columns: 96px minmax(0, 1fr);
  gap: 14px;
  padding: 11px 0;
  border-bottom: 1px solid var(--line);
  font-size: 14px;
}

.field-name {
  color: var(--primary);
  font-weight: 700;
}

.field-desc {
  color: var(--text-muted);
  line-height: 1.75;
}

/* 站内栏目索引 */
.index-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 14px;
}

.index-link {
  display: flex;
  flex-direction: column;
  gap: 6px;
  height: 100%;
  padding: 16px;
  background-color: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  transition: border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

.index-link:hover,
.index-link:focus-visible {
  border-color: var(--primary);
  box-shadow: var(--shadow-hover);
  transform: translateY(-2px);
}

.index-name {
  color: var(--primary);
  font-size: 16px;
  font-weight: 700;
}

.index-desc {
  color: var(--text-muted);
  font-size: 13px;
  line-height: 1.7;
}

/* ==========================================================================
   pages — 题材分类
   ========================================================================== */

.group-note p + p {
  margin-top: 12px;
}

.group-note p {
  max-width: var(--reading);
  color: var(--text-muted);
  font-size: 15px;
  line-height: 1.85;
}

.direction-list {
  display: grid;
  gap: 28px;
}

.direction-group {
  padding: 22px;
  background-color: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.direction-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 6px 14px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--line);
}

.direction-name {
  font-size: 19px;
  color: var(--primary);
}

.direction-trait {
  flex: 1 1 320px;
  color: var(--text-muted);
  font-size: 14px;
  line-height: 1.75;
}

.direction-figure {
  margin: 18px 0;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line);
}

.direction-figure img {
  width: 100%;
  aspect-ratio: 21 / 9;
  object-fit: cover;
}

.direction-caption {
  padding: 0 2px;
}

.entry-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 12px;
}

.entry-card {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 4px 10px;
  padding: 12px 14px;
  background-color: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  font-size: 14px;
}

.entry-name {
  flex: 1 1 110px;
  color: var(--text);
  font-weight: 700;
}

.entry-tag {
  color: var(--accent);
}

.entry-status {
  color: var(--text-muted);
}

.direction-foot {
  margin-top: 16px;
  font-size: 14px;
}

.direction-foot a {
  color: var(--accent);
  font-weight: 700;
}

.direction-foot a:hover,
.direction-foot a:focus-visible {
  color: var(--primary);
}

.direction-updates > p {
  max-width: var(--reading);
  margin-top: 8px;
  color: var(--text-muted);
  font-size: 15px;
  line-height: 1.8;
}

.link-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 12px;
  margin-top: 18px;
}

.link-item a {
  display: block;
  padding: 12px 16px;
  background-color: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--text);
  font-size: 15px;
  transition: border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

.link-item a:hover,
.link-item a:focus-visible {
  border-color: var(--primary);
  box-shadow: var(--shadow-hover);
  transform: translateY(-2px);
  color: var(--primary);
}

.genre-fields > p {
  max-width: var(--reading);
  margin-top: 8px;
  color: var(--text-muted);
  font-size: 15px;
  line-height: 1.85;
}

.genre-figure {
  margin-top: 20px;
  border-radius: var(--radius);
  border: 1px solid var(--line);
}

.genre-figure img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}

.genre-caption {
  padding: 0 2px;
}

/* ==========================================================================
   pages — 最近更新
   ========================================================================== */

.scope-body p {
  max-width: var(--reading);
  color: var(--text-muted);
  font-size: 15px;
  line-height: 1.85;
}

.scope-body p + p {
  margin-top: 12px;
}

.timeline-list {
  display: grid;
  gap: 24px;
  margin-top: 20px;
}

.timeline-group {
  padding-left: 18px;
  border-left: 2px solid var(--line-strong);
}

.timeline-date {
  font-size: 16px;
  color: var(--primary);
}

.timeline-date time {
  font-variant-numeric: tabular-nums;
}

.record-list {
  margin-top: 12px;
  border-top: 1px solid var(--line);
}

.record-item {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 4px 14px;
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
  font-size: 14px;
}

.record-name {
  flex: 1 1 160px;
  color: var(--text);
  font-weight: 700;
}

.record-type {
  color: var(--accent);
}

.record-genre {
  color: var(--text-muted);
}

.legend-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
  margin-top: 20px;
}

.legend-column {
  padding: 18px;
  background-color: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.legend-heading {
  font-size: 16px;
  color: var(--primary);
  padding-bottom: 10px;
  border-bottom: 1px solid var(--line);
}

.legend-list {
  margin-top: 6px;
}

.legend-term {
  margin-top: 12px;
  color: var(--text);
  font-weight: 700;
  font-size: 14px;
}

.legend-desc {
  margin-top: 2px;
  color: var(--text-muted);
  font-size: 14px;
  line-height: 1.75;
}

.path-body p {
  max-width: var(--reading);
  color: var(--text-muted);
  font-size: 15px;
  line-height: 1.85;
}

.path-body p + p {
  margin-top: 12px;
}

.path-body a {
  color: var(--accent);
  font-weight: 700;
}

.path-body a:hover,
.path-body a:focus-visible {
  color: var(--primary);
}

.related-links {
  margin-top: 22px;
}

/* ==========================================================================
   pages — 位次参考
   ========================================================================== */

.method-body p {
  max-width: var(--reading);
  color: var(--text-muted);
  font-size: 15px;
  line-height: 1.85;
}

.method-body p + p {
  margin-top: 12px;
}

.method-figure {
  margin-top: 22px;
  border-radius: var(--radius);
  border: 1px solid var(--line);
}

.method-figure img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}

.ranking-lists .section-intro {
  margin-bottom: 22px;
}

.ranking-group {
  padding: 20px;
  background-color: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.ranking-group + .ranking-group {
  margin-top: 20px;
}

.group-title {
  font-size: 18px;
  color: var(--primary);
}

.group-note {
  margin-top: 6px;
  color: var(--text-muted);
  font-size: 14px;
  line-height: 1.75;
}

.ranking-group .rank-list {
  margin-top: 14px;
}

.ranking-group .rank-item {
  align-items: flex-start;
  gap: 14px;
  padding: 12px 0;
}

.rank-info {
  flex: 1 1 200px;
  min-width: 0;
}

.rank-info .rank-name {
  font-size: 15px;
  color: var(--text);
}

.rank-tag {
  margin-top: 2px;
  color: var(--accent);
  font-size: 13px;
}

.rank-note {
  flex: 1 1 220px;
  min-width: 0;
  color: var(--text-muted);
  font-size: 13px;
  line-height: 1.7;
}

.group-link {
  margin-top: 14px;
  font-size: 14px;
}

.notes-body p {
  max-width: var(--reading);
  color: var(--text-muted);
  font-size: 15px;
  line-height: 1.85;
}

.notes-body p + p {
  margin-top: 12px;
}

.notes-list {
  display: grid;
  gap: 10px;
  margin-top: 18px;
}

.notes-item {
  padding: 12px 16px 12px 34px;
  position: relative;
  background-color: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--text);
  font-size: 14px;
  line-height: 1.75;
}

.notes-item::before {
  content: "";
  position: absolute;
  left: 16px;
  top: 20px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background-color: var(--accent);
}

.path-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 14px;
  margin-top: 20px;
}

.path-card {
  display: flex;
  flex-direction: column;
  padding: 18px;
  background-color: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  transition: border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

.path-card:hover,
.path-card:focus-within {
  border-color: var(--primary);
  box-shadow: var(--shadow-hover);
  transform: translateY(-2px);
}

.path-title {
  font-size: 16px;
  color: var(--primary);
}

.path-desc {
  flex: 1 1 auto;
  margin-top: 8px;
  color: var(--text-muted);
  font-size: 14px;
  line-height: 1.75;
}

.path-link {
  margin-top: 14px;
  color: var(--accent);
  font-size: 14px;
  font-weight: 700;
}

.path-link:hover,
.path-link:focus-visible {
  color: var(--primary);
}

/* ==========================================================================
   pages — 条目字段说明
   ========================================================================== */

.page-layout {
  display: block;
}

.fields-article {
  max-width: 100%;
}

.fields-article .section:first-child {
  padding-top: 32px;
}

.field-list {
  margin-top: 18px;
  border-top: 1px solid var(--line);
}

.field-item {
  display: grid;
  grid-template-columns: 140px minmax(0, 1fr);
  gap: 18px;
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
}

.field-item .field-name {
  color: var(--primary);
  font-size: 15px;
  font-weight: 700;
}

.field-item .field-desc {
  color: var(--text-muted);
  font-size: 14px;
  line-height: 1.8;
}

.media-caption {
  padding: 0 2px;
}

.boundary-columns {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
  margin-top: 18px;
}

.boundary-col {
  padding: 18px;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background-color: var(--surface);
}

.boundary-include {
  border-top: 3px solid var(--primary);
}

.boundary-exclude {
  border-top: 3px solid var(--accent);
}

.boundary-heading {
  font-size: 16px;
  color: var(--text);
}

.boundary-include .boundary-heading {
  color: var(--primary);
}

.boundary-exclude .boundary-heading {
  color: var(--accent);
}

.boundary-list {
  display: grid;
  gap: 8px;
  margin-top: 12px;
}

.boundary-item {
  position: relative;
  padding-left: 18px;
  color: var(--text-muted);
  font-size: 14px;
  line-height: 1.75;
}

.boundary-item::before {
  content: "";
  position: absolute;
  left: 2px;
  top: 9px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background-color: var(--line-strong);
}

.boundary-include .boundary-item::before {
  background-color: var(--primary);
}

.boundary-exclude .boundary-item::before {
  background-color: var(--accent);
}

.relation-steps {
  display: grid;
  gap: 12px;
  margin-top: 18px;
}

.relation-step {
  display: grid;
  grid-template-columns: 40px minmax(0, 1fr);
  gap: 14px;
  align-items: start;
  padding: 14px 16px;
  background-color: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.relation-step .step-index {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background-color: var(--primary);
  color: #ffffff;
  font-size: 14px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.relation-step .step-text {
  color: var(--text-muted);
  font-size: 14px;
  line-height: 1.8;
}

.faq-list {
  display: grid;
  gap: 10px;
  margin-top: 18px;
}

.faq-item {
  background-color: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}

.faq-question {
  padding: 14px 44px 14px 18px;
  color: var(--text);
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  list-style: none;
  position: relative;
}

.faq-question::-webkit-details-marker {
  display: none;
}

.faq-question::after {
  content: "+";
  position: absolute;
  right: 18px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--accent);
  font-size: 18px;
  font-weight: 700;
  line-height: 1;
}

.faq-item[open] .faq-question::after {
  content: "−";
}

.faq-item[open] .faq-question {
  color: var(--primary);
}

.faq-answer {
  padding: 14px 18px 16px;
  color: var(--text-muted);
  font-size: 14px;
  line-height: 1.85;
  border-top: 1px solid var(--line);
}

/* ==========================================================================
   pages — 404
   ========================================================================== */

.error-main {
  display: flex;
  justify-content: center;
  padding-top: 48px;
}

.error-inner {
  width: 100%;
  max-width: 640px;
  text-align: center;
}

.error-code {
  color: var(--accent);
  font-size: 15px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.error-inner h1 {
  margin-top: 10px;
  font-size: 28px;
  color: var(--primary);
  line-height: 1.35;
}

.error-text {
  margin-top: 14px;
  color: var(--text-muted);
  font-size: 15px;
  line-height: 1.85;
}

.error-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  margin-top: 26px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 10px 22px;
  border-radius: var(--radius);
  border: 1px solid transparent;
  font-size: 15px;
  font-weight: 700;
  transition: background-color 0.18s ease, color 0.18s ease, border-color 0.18s ease;
}

.btn-primary {
  background-color: var(--primary);
  color: #ffffff;
}

.btn-primary:hover,
.btn-primary:focus-visible {
  background-color: var(--accent);
  color: #ffffff;
}

.btn-ghost {
  background-color: transparent;
  border-color: var(--line-strong);
  color: var(--text);
}

.btn-ghost:hover,
.btn-ghost:focus-visible {
  border-color: var(--primary);
  color: var(--primary);
}

.error-tips {
  margin-top: 40px;
  padding-top: 28px;
  border-top: 1px solid var(--line);
  text-align: left;
}

.error-tips h2 {
  font-size: 18px;
  color: var(--primary);
}

.error-list {
  display: grid;
  gap: 10px;
  margin-top: 16px;
}

.error-list a {
  display: block;
  padding: 12px 16px;
  background-color: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--text);
  font-size: 15px;
  transition: border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

.error-list a:hover,
.error-list a:focus-visible {
  border-color: var(--primary);
  box-shadow: var(--shadow-hover);
  transform: translateY(-2px);
  color: var(--primary);
}

.error-note {
  margin-top: 18px;
  color: var(--text-muted);
  font-size: 14px;
  line-height: 1.75;
}

/* ==========================================================================
   responsive — 960px / 640px
   ========================================================================== */

@media (max-width: 960px) {
  .header-inner {
    flex-wrap: wrap;
    padding: 12px 20px;
  }

  .nav-toggle {
    display: flex;
  }

  .site-nav {
    flex: 1 1 100%;
  }

  .nav-list {
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    width: 100%;
    margin-top: 8px;
    padding: 6px 0;
    border-top: 1px solid var(--line);
  }

  .nav-list.is-open {
    display: flex;
  }

  .nav-link {
    display: block;
    padding: 12px 4px;
    min-height: 44px;
    border-bottom: 1px solid var(--line);
    border-left: 2px solid transparent;
  }

  .nav-link.is-current {
    border-bottom-color: var(--line);
    border-left-color: var(--accent);
    padding-left: 10px;
  }

  .site-main {
    padding: 0 20px 48px;
  }

  .topbar-text {
    padding: 8px 20px;
  }

  .hero {
    grid-template-columns: minmax(0, 1fr);
    gap: 28px;
    padding: 32px 0 36px;
  }

  .hero-title,
  .page-title {
    font-size: 26px;
  }

  .genre-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .section-split {
    grid-template-columns: minmax(0, 1fr);
    gap: 32px;
  }

  .index-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .footer-inner {
    padding: 28px 20px 18px;
  }

  .footer-nav {
    margin-left: 0;
  }

  .footer-copy {
    padding: 14px 20px 20px;
  }
}

@media (max-width: 640px) {
  body {
    font-size: 15px;
  }

  .header-inner {
    padding: 10px 16px;
    gap: 12px;
  }

  .brand-name {
    font-size: 17px;
  }

  .site-main {
    padding: 0 16px 40px;
  }

  .topbar-text {
    padding: 8px 16px;
    font-size: 12px;
  }

  .section {
    padding: 28px 0;
  }

  .section-title {
    font-size: 19px;
  }

  .page-header {
    padding: 2px 0 22px;
  }

  .hero-title,
  .page-title {
    font-size: 24px;
  }

  .error-inner h1 {
    font-size: 22px;
  }

  .hero {
    padding: 26px 0 30px;
  }

  .genre-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .cover-card {
    grid-template-columns: 80px minmax(0, 1fr);
    gap: 14px;
  }

  .field-row {
    grid-template-columns: minmax(0, 1fr);
    gap: 4px;
  }

  .field-item {
    grid-template-columns: minmax(0, 1fr);
    gap: 6px;
  }

  .index-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .legend-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 16px;
  }

  .boundary-columns {
    grid-template-columns: minmax(0, 1fr);
    gap: 16px;
  }

  .direction-group,
  .ranking-group {
    padding: 16px;
  }

  .entry-list,
  .path-grid,
  .related-list,
  .link-list {
    grid-template-columns: minmax(0, 1fr);
  }

  .update-item,
  .record-item {
    gap: 2px 10px;
  }

  .update-name,
  .record-name {
    flex: 1 1 100%;
  }

  .ranking-group .rank-item {
    flex-wrap: wrap;
    gap: 6px 12px;
  }

  .rank-info,
  .rank-note {
    flex: 1 1 100%;
  }

  .error-actions {
    flex-direction: column;
  }

  .error-actions .btn {
    width: 100%;
  }

  .footer-inner {
    padding: 24px 16px 16px;
  }

  .footer-list {
    gap: 6px 16px;
  }

  .footer-copy {
    padding: 12px 16px 18px;
  }
}
