/* =========================================================
   华体汇网页 · 全站共享样式 /assets/site.css
   纸感清册 + 侧边轨道 + 精密网格
   ========================================================= */

/* ---------- 1. Reset ---------- */
*,
*::before,
*::after { box-sizing: border-box; }

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

body {
  margin: 0;
  padding-left: var(--rail-w);
}

img,
svg,
video {
  display: block;
  max-width: 100%;
}

button {
  font: inherit;
  color: inherit;
  background: none;
  border: 0;
  padding: 0;
}

a { color: inherit; }

h1, h2, h3, h4, h5, h6, p, ul, ol, figure, blockquote { margin: 0; }

ul, ol { padding: 0; list-style: none; }

/* ---------- 2. Tokens ---------- */
:root {
  --c-red: #E8452C;
  --c-red-deep: #B92E1A;
  --c-navy: #12263A;
  --c-ink: #0B1A2A;
  --c-cream: #F6F1E7;
  --c-paper: #FFFDF8;
  --c-amber: #D99A2B;
  --c-sage: #C9D8C5;
  --c-mist: #8A97A6;
  --c-line: #E5E0D6;

  --font-head: "Noto Sans SC", "Source Han Sans SC", "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
  --font-body: "Noto Sans SC", "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
  --font-mono: "IBM Plex Mono", "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

  --rail-w: 88px;
  --rail-w-open: 220px;
  --topbar-h: 60px;
  --content-max: 1320px;
  --gutter: clamp(20px, 4vw, 44px);
  --ease: cubic-bezier(.2, .72, .28, 1);
}

/* ---------- 3. 中文排版基线 ---------- */
body {
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.75;
  font-weight: 400;
  color: var(--c-navy);
  background-color: var(--c-cream);
  background-image:
    linear-gradient(to right, rgba(18, 38, 58, 0.05) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(18, 38, 58, 0.05) 1px, transparent 1px);
  background-size: 64px 64px;
  background-attachment: fixed;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-head);
  font-weight: 900;
  letter-spacing: -0.02em;
  line-height: 1.14;
  color: var(--c-navy);
}

h1 { font-size: clamp(34px, 4.6vw, 56px); }
h2 { font-size: clamp(26px, 3.2vw, 40px); }
h3 { font-size: clamp(20px, 2.2vw, 27px); }
h4 { font-size: clamp(17px, 1.6vw, 20px); }

p { line-height: 1.75; }

a {
  color: var(--c-red-deep);
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

strong, b { font-weight: 700; }

/* ---------- 4. 无障碍与工具 ---------- */
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

.mono {
  font-family: var(--font-mono);
  font-size: 0.76em;
  letter-spacing: 0.06em;
  font-variant-numeric: tabular-nums;
}

.skip-link {
  position: fixed;
  top: 8px;
  left: calc(var(--rail-w) + 8px);
  z-index: 300;
  display: inline-block;
  padding: 10px 18px;
  background: var(--c-navy);
  color: var(--c-paper);
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  border: 1px solid var(--c-amber);
  transform: translateY(-220%);
  transition: transform 0.16s var(--ease);
}

.skip-link:focus,
.skip-link:focus-visible { transform: translateY(0); }

:focus-visible {
  outline: 2px solid var(--c-red);
  outline-offset: 2px;
}

.site-rail :focus-visible,
.site-footer :focus-visible { outline-color: var(--c-amber); }

/* ---------- 5. 布局容器与栅格 ---------- */
.container {
  width: 100%;
  max-width: var(--content-max);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.page-shell {
  padding-block: clamp(28px, 4vw, 48px) clamp(64px, 8vw, 104px);
}

.grid-12 {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: clamp(16px, 2vw, 28px);
}

.col-span-3 { grid-column: span 3; }
.col-span-4 { grid-column: span 4; }
.col-span-5 { grid-column: span 5; }
.col-span-6 { grid-column: span 6; }
.col-span-7 { grid-column: span 7; }
.col-span-8 { grid-column: span 8; }
.col-span-9 { grid-column: span 9; }
.col-span-12 { grid-column: span 12; }

/* ---------- 6. 按钮 ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 22px;
  border: 1px solid transparent;
  border-radius: 0;
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.06em;
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
  transition:
    background-color 0.14s var(--ease),
    color 0.14s var(--ease),
    border-color 0.14s var(--ease),
    transform 0.14s var(--ease);
}

.btn:active { transform: translateY(1px); }

.btn-primary {
  background: var(--c-red);
  color: var(--c-paper);
  border-color: var(--c-red);
}

.btn-primary:hover {
  background: var(--c-red-deep);
  border-color: var(--c-red-deep);
  color: var(--c-paper);
}

.btn-ghost {
  background: transparent;
  color: var(--c-navy);
  border-color: rgba(18, 38, 58, 0.3);
}

.btn-ghost:hover {
  background: var(--c-navy);
  color: var(--c-cream);
  border-color: var(--c-navy);
}

.btn-ghost-light {
  background: transparent;
  color: var(--c-cream);
  border-color: rgba(246, 241, 231, 0.4);
}

.btn-ghost-light:hover {
  background: var(--c-cream);
  color: var(--c-ink);
  border-color: var(--c-cream);
}

/* ---------- 7. 面包屑 ---------- */
.breadcrumb { margin-bottom: 20px; }

.crumb-list {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0 8px;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.08em;
  color: var(--c-mist);
}

.crumb-item { display: inline-flex; align-items: center; }

.crumb-item + .crumb-item::before {
  content: "/";
  margin-right: 8px;
  color: var(--c-line);
}

.crumb-item a {
  color: var(--c-navy);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  padding-bottom: 1px;
  transition: color 0.14s var(--ease), border-color 0.14s var(--ease);
}

.crumb-item a:hover {
  color: var(--c-red-deep);
  border-bottom-color: var(--c-red);
}

.crumb-item[aria-current="page"] { color: var(--c-mist); }

/* ---------- 8. 侧边轨道头部 ---------- */
.site-rail {
  position: fixed;
  inset: 0 auto 0 0;
  z-index: 80;
  display: flex;
  flex-direction: column;
  width: var(--rail-w);
  background: var(--c-navy);
  background-image: linear-gradient(180deg, #14293E 0%, #12263A 44%, #0E1F31 100%);
  color: var(--c-cream);
  border-right: 1px solid rgba(246, 241, 231, 0.14);
  overflow: hidden;
  transition: width 0.22s var(--ease), box-shadow 0.22s var(--ease);
}

.site-rail[data-expanded="true"] {
  width: var(--rail-w-open);
  box-shadow: 28px 0 56px -28px rgba(11, 26, 42, 0.6);
}

.rail-head {
  display: grid;
  grid-template-columns: 1fr;
  justify-items: center;
  align-content: start;
  gap: 12px;
  padding: 20px 10px 16px;
  border-bottom: 1px solid rgba(246, 241, 231, 0.13);
}

.site-rail[data-expanded="true"] .rail-head {
  justify-items: start;
  padding: 20px 18px 16px;
}

.rail-brand {
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--c-cream);
}

.rail-brand-mark {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  background: var(--c-red);
  color: var(--c-paper);
  font-family: var(--font-head);
  font-weight: 900;
  font-size: 19px;
  line-height: 1;
  letter-spacing: 0;
}

.rail-brand-text { display: none; }

.site-rail[data-expanded="true"] .rail-brand-text { display: block; }

.rail-brand-name {
  display: block;
  font-family: var(--font-head);
  font-weight: 900;
  font-size: 16px;
  letter-spacing: -0.01em;
  color: var(--c-paper);
  white-space: nowrap;
}

.rail-brand-tag {
  display: block;
  margin-top: 3px;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.06em;
  line-height: 1.5;
  color: var(--c-mist);
  white-space: nowrap;
}

.rail-toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 10px;
  border: 1px solid rgba(246, 241, 231, 0.3);
  border-radius: 0;
  color: var(--c-cream);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  cursor: pointer;
  transition: border-color 0.14s var(--ease), background-color 0.14s var(--ease), color 0.14s var(--ease);
}

.rail-toggle:hover {
  border-color: var(--c-amber);
  color: var(--c-amber);
  background: rgba(246, 241, 231, 0.06);
}

.rail-bars {
  display: inline-grid;
  gap: 3px;
  width: 14px;
}

.rail-bars i {
  display: block;
  height: 2px;
  background: currentColor;
}

.rail-toggle-label { display: none; }

.site-rail[data-expanded="true"] .rail-toggle-label { display: inline; }

.rail-nav {
  flex: 1 1 auto;
  padding: 8px 0;
  overflow-x: hidden;
  overflow-y: auto;
}

.rail-list { display: flex; flex-direction: column; }

.rail-item { display: block; }

.rail-link {
  position: relative;
  display: grid;
  grid-template-columns: 1fr;
  justify-items: center;
  align-items: center;
  gap: 6px;
  padding: 14px 8px;
  color: rgba(246, 241, 231, 0.66);
  text-decoration: none;
  border-left: 3px solid transparent;
  transition:
    color 0.14s var(--ease),
    background-color 0.14s var(--ease),
    border-color 0.14s var(--ease);
}

.rail-link:hover {
  color: var(--c-paper);
  background: rgba(246, 241, 231, 0.07);
}

.site-rail[data-expanded="true"] .rail-link {
  grid-template-columns: 32px 1fr;
  justify-items: start;
  padding: 12px 16px 12px 13px;
}

.rail-link[aria-current="page"] {
  color: var(--c-paper);
  background: rgba(232, 69, 44, 0.18);
  border-left-color: var(--c-red);
}

.rail-link[aria-current="page"] .rail-num { color: var(--c-amber); }

.rail-num {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.1em;
  text-align: center;
  color: rgba(246, 241, 231, 0.55);
  transition: color 0.14s var(--ease);
}

.site-rail[data-expanded="true"] .rail-num { text-align: left; }

.rail-label {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.02em;
}

.site-rail[data-expanded="true"] .rail-label {
  position: static;
  width: auto;
  height: auto;
  margin: 0;
  overflow: visible;
  clip: auto;
  clip-path: none;
  white-space: normal;
}

.rail-foot {
  display: none;
  padding: 16px 18px 22px;
  border-top: 1px solid rgba(246, 241, 231, 0.13);
}

.site-rail[data-expanded="true"] .rail-foot { display: block; }

.rail-status {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 10px;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  color: rgba(246, 241, 231, 0.66);
}

.rail-dot {
  display: block;
  width: 6px;
  height: 6px;
  background: var(--c-sage);
  box-shadow: 0 0 0 3px rgba(201, 216, 197, 0.18);
}

.rail-fast {
  display: inline-block;
  padding-bottom: 2px;
  font-size: 13px;
  color: var(--c-amber);
  text-decoration: none;
  border-bottom: 1px solid rgba(217, 154, 43, 0.5);
  transition: color 0.14s var(--ease), border-color 0.14s var(--ease);
}

.rail-fast:hover {
  color: var(--c-paper);
  border-bottom-color: var(--c-paper);
}

/* ---------- 9. 页脚 ---------- */
.site-footer {
  position: relative;
  overflow: hidden;
  background: var(--c-ink);
  color: rgba(246, 241, 231, 0.78);
  border-top: 3px solid var(--c-red);
}

.site-footer::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(to right, rgba(246, 241, 231, 0.05) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(246, 241, 231, 0.05) 1px, transparent 1px);
  background-size: 72px 72px;
}

.footer-inner {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: var(--content-max);
  margin-inline: auto;
  padding: clamp(40px, 5vw, 64px) var(--gutter) 26px;
}

.footer-top {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 28px 40px;
  padding-bottom: 30px;
  border-bottom: 1px solid rgba(246, 241, 231, 0.14);
}

.footer-brand { max-width: 40ch; }

.footer-brand-name {
  font-family: var(--font-head);
  font-weight: 900;
  font-size: clamp(24px, 3vw, 32px);
  letter-spacing: -0.02em;
  line-height: 1.1;
  color: var(--c-paper);
  margin-bottom: 10px;
}

.footer-brand-line {
  font-size: 14px;
  line-height: 1.7;
  color: rgba(246, 241, 231, 0.7);
  margin-bottom: 14px;
}

.footer-stamp {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  color: var(--c-amber);
}

.stamp-dot {
  display: block;
  width: 6px;
  height: 6px;
  background: var(--c-sage);
}

.footer-cta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.footer-cols {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 28px 40px;
  padding: 34px 0;
  border-bottom: 1px solid rgba(246, 241, 231, 0.14);
}

.footer-col-title {
  margin-bottom: 14px;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.16em;
  color: var(--c-amber);
}

.footer-links {
  display: grid;
  gap: 10px;
}

.footer-links a {
  display: inline-block;
  padding-bottom: 2px;
  font-size: 14px;
  color: rgba(246, 241, 231, 0.8);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: color 0.14s var(--ease), border-color 0.14s var(--ease);
}

.footer-links a:hover {
  color: var(--c-paper);
  border-bottom-color: var(--c-red);
}

.footer-contact {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 32px;
  padding: 22px 0;
  border-bottom: 1px solid rgba(246, 241, 231, 0.14);
}

.footer-contact-line {
  display: flex;
  align-items: baseline;
  gap: 10px;
  font-size: 13px;
  line-height: 1.7;
  color: rgba(246, 241, 231, 0.7);
}

.footer-contact-label {
  flex: none;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  color: var(--c-mist);
}

.footer-contact-value { color: var(--c-paper); }

.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 24px;
  padding-top: 20px;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  color: rgba(246, 241, 231, 0.55);
}

.footer-copy, .footer-icp { color: inherit; }

/* ---------- 10. 通用组件 ---------- */
.section-head {
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: start;
  gap: 18px;
  padding-bottom: 16px;
  margin-bottom: 28px;
  border-bottom: 1px solid var(--c-line);
}

.section-num {
  padding-top: 9px;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.16em;
  color: var(--c-amber);
}

.section-title {
  margin: 0;
  font-family: var(--font-head);
  font-weight: 900;
  font-size: clamp(24px, 3vw, 34px);
  letter-spacing: -0.02em;
  line-height: 1.16;
  color: var(--c-navy);
}

.section-note {
  margin-top: 8px;
  max-width: 62ch;
  font-size: 14px;
  line-height: 1.7;
  color: var(--c-mist);
}

.panel {
  padding: clamp(18px, 2.4vw, 26px);
  background: var(--c-paper);
  border: 1px solid var(--c-line);
}

.panel-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px 16px;
  padding-bottom: 12px;
  margin-bottom: 16px;
  border-bottom: 1px solid var(--c-line);
}

.panel-title {
  margin: 0;
  font-family: var(--font-head);
  font-weight: 800;
  font-size: 18px;
  letter-spacing: -0.01em;
  color: var(--c-navy);
}

.tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 9px;
  border: 1px solid var(--c-line);
  border-radius: 0;
  background: var(--c-paper);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  line-height: 1.6;
  color: var(--c-navy);
  white-space: nowrap;
}

.tag-amber {
  border-color: rgba(217, 154, 43, 0.7);
  background: rgba(217, 154, 43, 0.12);
  color: #8A5F13;
}

.tag-sage {
  border-color: #A9BDA4;
  background: var(--c-sage);
  color: #3F5A3A;
}

.tag-red {
  border-color: rgba(232, 69, 44, 0.7);
  background: rgba(232, 69, 44, 0.1);
  color: var(--c-red-deep);
}

.stamp {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.08em;
  color: var(--c-mist);
}

.stamp::before {
  content: "";
  display: block;
  width: 6px;
  height: 6px;
  background: var(--c-amber);
}

.rule {
  height: 1px;
  border: 0;
  margin: 0;
  background: var(--c-line);
}

/* 可展开内容组 */
.accordion {
  background: var(--c-paper);
  border: 1px solid var(--c-line);
}

.accordion + .accordion { border-top: 0; }

.accordion-trigger {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  width: 100%;
  padding: 16px 20px;
  font-family: var(--font-head);
  font-size: 16px;
  font-weight: 700;
  letter-spacing: -0.01em;
  text-align: left;
  color: var(--c-navy);
  cursor: pointer;
  transition: background-color 0.14s var(--ease), color 0.14s var(--ease);
}

.accordion-trigger::after {
  content: "+";
  flex: none;
  font-family: var(--font-mono);
  font-size: 18px;
  font-weight: 400;
  color: var(--c-red);
  transition: transform 0.18s var(--ease), color 0.14s var(--ease);
}

.accordion-trigger[aria-expanded="true"]::after {
  content: "−";
  color: var(--c-red-deep);
}

.accordion-trigger:hover { background: rgba(232, 69, 44, 0.05); }

.accordion-panel {
  padding: 0 20px 20px;
  font-size: 15px;
  line-height: 1.8;
  color: rgba(18, 38, 58, 0.82);
  border-top: 1px solid var(--c-line);
  padding-top: 16px;
}

.accordion-panel[hidden] { display: none; }

/* 图片容器基础规则 */
.media-frame {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border: 1px solid var(--c-line);
  background-color: var(--c-line);
  background-image:
    linear-gradient(135deg, rgba(232, 69, 44, 0.16) 0%, rgba(217, 154, 43, 0.1) 45%, rgba(18, 38, 58, 0.12) 100%);
}

.media-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.media-frame--wide { aspect-ratio: 21 / 9; }
.media-frame--tall { aspect-ratio: 4 / 5; }

.media-caption {
  margin-top: 8px;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  color: var(--c-mist);
}

/* JS 注入：滚动进度 */
.scroll-progress {
  position: fixed;
  top: 0;
  left: var(--rail-w);
  right: 0;
  z-index: 200;
  height: 3px;
  pointer-events: none;
  background: rgba(18, 38, 58, 0.08);
}

.scroll-progress > i {
  display: block;
  width: 0;
  height: 100%;
  background: linear-gradient(90deg, var(--c-red) 0%, var(--c-amber) 100%);
}

/* JS 注入：返回顶部 */
.to-top {
  position: fixed;
  right: 22px;
  bottom: 22px;
  z-index: 150;
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border: 0;
  border-radius: 0;
  background: var(--c-navy);
  color: var(--c-cream);
  font-size: 18px;
  line-height: 1;
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  transition:
    opacity 0.16s var(--ease),
    transform 0.16s var(--ease),
    visibility 0s linear 0.16s,
    background-color 0.14s var(--ease);
}

.to-top[data-visible="true"] {
  opacity: 1;
  visibility: visible;
  transform: none;
  transition:
    opacity 0.16s var(--ease),
    transform 0.16s var(--ease),
    background-color 0.14s var(--ease);
}

.to-top:hover { background: var(--c-red); }

/* ---------- 11. 平板 ---------- */
@media (max-width: 1024px) {
  .grid-12 { grid-template-columns: repeat(6, minmax(0, 1fr)); }
  .col-span-3,
  .col-span-4,
  .col-span-5 { grid-column: span 3; }
  .col-span-6,
  .col-span-7,
  .col-span-8,
  .col-span-9,
  .col-span-12 { grid-column: span 6; }

  .section-head { grid-template-columns: 1fr; gap: 6px; }
  .section-num { padding-top: 0; }
}

/* ---------- 12. 移动：轨道转抽屉 ---------- */
@media (max-width: 860px) {
  body {
    padding-left: 0;
    padding-top: var(--topbar-h);
    background-attachment: scroll;
  }

  .skip-link { left: 8px; }

  .site-rail {
    inset: 0 0 auto 0;
    width: 100%;
    height: auto;
    min-height: var(--topbar-h);
    border-right: 0;
    border-bottom: 1px solid rgba(246, 241, 231, 0.16);
    overflow: visible;
  }

  .site-rail[data-expanded="true"] {
    width: 100%;
    box-shadow: none;
  }

  .rail-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    height: var(--topbar-h);
    padding: 0 16px;
    border-bottom: 0;
  }

  .site-rail[data-expanded="true"] .rail-head { padding: 0 16px; }

  .rail-brand-text { display: block; }
  .rail-brand-tag { display: none; }
  .rail-brand-name { font-size: 15px; }
  .rail-brand-mark { width: 30px; height: 30px; font-size: 16px; }

  .rail-toggle-label { display: inline; }
  .site-rail[data-expanded="true"] .rail-toggle-label { display: inline; }

  .rail-nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    max-height: 0;
    padding: 0;
    overflow: hidden;
    visibility: hidden;
    background: var(--c-ink);
    border-bottom: 1px solid rgba(246, 241, 231, 0.16);
    transition: max-height 0.24s var(--ease), visibility 0s linear 0.24s;
  }

  .rail-nav[data-open="true"] {
    max-height: min(74vh, 520px);
    overflow-y: auto;
    visibility: visible;
    transition: max-height 0.24s var(--ease);
  }

  .rail-list { display: block; }

  .rail-link {
    grid-template-columns: 40px 1fr;
    justify-items: start;
    gap: 0;
    padding: 14px 18px;
    border-left: 3px solid transparent;
    border-bottom: 1px solid rgba(246, 241, 231, 0.08);
    text-align: left;
  }

  .site-rail[data-expanded="true"] .rail-link { padding: 14px 18px; }

  .rail-num { text-align: left; }

  .rail-label,
  .site-rail[data-expanded="true"] .rail-label {
    position: static;
    width: auto;
    height: auto;
    margin: 0;
    overflow: visible;
    clip: auto;
    clip-path: none;
    white-space: normal;
  }

  .rail-foot,
  .site-rail[data-expanded="true"] .rail-foot { display: none; }

  .scroll-progress { left: 0; top: var(--topbar-h); }

  .to-top { right: 16px; bottom: 16px; width: 44px; height: 44px; }

  .footer-top { flex-direction: column; }
  .footer-cta { width: 100%; }
  .footer-cta .btn { flex: 1 1 160px; }
}

/* ---------- 13. 手机 ---------- */
@media (max-width: 640px) {
  body { font-size: 16px; }

  .grid-12 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .col-span-3,
  .col-span-4,
  .col-span-5,
  .col-span-6,
  .col-span-7,
  .col-span-8,
  .col-span-9,
  .col-span-12 { grid-column: span 2; }

  .footer-cols { grid-template-columns: 1fr; gap: 24px; }
  .footer-contact { flex-direction: column; gap: 6px; }
  .footer-bottom { flex-direction: column; align-items: flex-start; }
}

/* ---------- 14. 降低动效 ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }

  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }

  .to-top { transform: none; }
}
