/* ==========================================================================
   星空体育看台 · /assets/site.css
   夜间看台 + 天文观测舱：深空基底、荧光青坐标、暖橙比分节点、星尘紫光晕
   ========================================================================== */

/* ---------- 1. 设计令牌 ---------- */
:root {
  --c-void: #050812;
  --c-stand: #0B1324;
  --c-panel: #101B2E;
  --c-panel-hi: #16243C;
  --c-mist: #EDF4FF;
  --c-steel: #8A9AB0;
  --c-cyan: #3DF5D4;
  --c-orange: #FF8A3D;
  --c-violet: #8A6CFF;
  --c-green: #7CFFB2;
  --c-red: #FF5F6D;
  --c-line: #243A5A;

  --rail-w: 280px;
  --header-h: 0px;
  --gutter: clamp(18px, 4vw, 56px);
  --content-max: 1180px;

  --r-xl: 34px;
  --r-lg: 22px;
  --r-md: 14px;
  --r-sm: 10px;
  --r-pill: 999px;

  --font-display: "Barlow Condensed", "Noto Sans SC", "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
  --font-body: "Noto Sans SC", "PingFang SC", "Microsoft YaHei", system-ui, -apple-system, sans-serif;
  --font-mono: "JetBrains Mono", "Roboto Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
  --shadow-card: 0 18px 48px -30px rgba(0, 0, 0, 0.92);
}

@media (max-width: 1023px) {
  :root { --header-h: 64px; }
}

/* ---------- 2. 重置 ---------- */
*,
*::before,
*::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 20px);
  scrollbar-width: thin;
  scrollbar-color: var(--c-line) transparent;
}

body {
  margin: 0;
  min-height: 100vh;
  padding-left: var(--rail-w);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.75;
  letter-spacing: 0.01em;
  color: var(--c-mist);
  background-color: var(--c-void);
  background-image:
    radial-gradient(1100px 640px at 92% -10%, rgba(138, 108, 255, 0.20), transparent 62%),
    radial-gradient(900px 560px at 2% 106%, rgba(61, 245, 212, 0.10), transparent 60%),
    linear-gradient(180deg, #050812 0%, #070E1C 48%, #050812 100%);
  background-repeat: no-repeat;
  background-attachment: fixed;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

h1, h2, h3, h4, h5, h6, p, figure, blockquote, dl, dd { margin: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  font-weight: 800;
  line-height: 1.08;
  letter-spacing: -0.02em;
  color: var(--c-mist);
}

a { color: inherit; text-decoration: none; }

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

::selection {
  background: var(--c-cyan);
  color: #04140F;
}

#main-content { outline: none; }

/* ---------- 3. 焦点与可访问性 ---------- */
a:focus-visible,
button:focus-visible,
[tabindex]:focus-visible {
  outline: 2px solid var(--c-cyan);
  outline-offset: 2px;
  box-shadow: 0 0 0 6px rgba(61, 245, 212, 0.16);
}

.skip-link {
  position: fixed;
  top: 10px;
  left: 10px;
  z-index: 200;
  padding: 10px 18px;
  border-radius: var(--r-pill);
  background: var(--c-cyan);
  color: #04140F;
  font-size: 0.84rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  transform: translateY(-180%);
  transition: transform 0.2s var(--ease);
}

.skip-link:focus,
.skip-link:focus-visible {
  transform: translateY(0);
  outline: 2px solid var(--c-mist);
  outline-offset: 3px;
}

/* ---------- 4. 头部：左侧记分牌轨道 ---------- */
.site-header {
  position: fixed;
  inset: 0 auto 0 0;
  width: var(--rail-w);
  z-index: 60;
  display: flex;
  flex-direction: column;
  background:
    radial-gradient(420px 280px at 0% 0%, rgba(138, 108, 255, 0.18), transparent 66%),
    linear-gradient(180deg, #081120 0%, #0B1324 46%, #060B14 100%);
  border-right: 1px solid var(--c-line);
}

.site-header::before {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  width: 1px;
  background: linear-gradient(180deg, transparent, rgba(61, 245, 212, 0.55) 26%, rgba(138, 108, 255, 0.45) 68%, transparent);
  pointer-events: none;
}

.header-rail {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  gap: 22px;
  min-height: 0;
  padding: 26px 20px 22px;
  overflow-y: auto;
}

/* 品牌 */
.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--c-mist);
  transition: opacity 0.18s var(--ease);
}

.brand:hover { opacity: 0.88; }

.brand-mark {
  position: relative;
  flex: none;
  width: 38px;
  height: 38px;
  border-radius: 12px;
  background:
    radial-gradient(circle at 28% 24%, var(--c-cyan) 0%, rgba(61, 245, 212, 0.15) 56%, transparent 72%),
    linear-gradient(150deg, var(--c-violet) 0%, #0A1020 76%);
  box-shadow:
    0 0 0 1px rgba(61, 245, 212, 0.35),
    0 0 20px rgba(61, 245, 212, 0.18);
}

.brand-mark::after {
  content: "";
  position: absolute;
  inset: 11px;
  border: 2px solid rgba(5, 8, 18, 0.85);
  border-radius: 50%;
}

.brand-text {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

.brand-name {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: 1.1rem;
  line-height: 1.1;
  letter-spacing: 0.01em;
  white-space: nowrap;
}

.brand-sub {
  font-size: 0.62rem;
  line-height: 1.45;
  letter-spacing: 0.1em;
  color: var(--c-steel);
}

/* 移动端抽屉按钮 */
.nav-toggle {
  display: none;
  align-items: center;
  gap: 10px;
  padding: 10px 15px;
  border-radius: var(--r-pill);
  background: rgba(16, 27, 46, 0.92);
  border: 1px solid var(--c-line);
  color: var(--c-mist);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  transition: border-color 0.18s var(--ease), background-color 0.18s var(--ease);
}

.nav-toggle:hover {
  border-color: rgba(61, 245, 212, 0.5);
  background: var(--c-panel-hi);
}

.nav-toggle-bars {
  position: relative;
  display: block;
  width: 18px;
  height: 2px;
  border-radius: 2px;
  background: var(--c-cyan);
}

.nav-toggle-bars::before,
.nav-toggle-bars::after {
  content: "";
  position: absolute;
  left: 0;
  width: 18px;
  height: 2px;
  border-radius: 2px;
  background: var(--c-cyan);
  transition: transform 0.2s var(--ease), opacity 0.2s var(--ease);
}

.nav-toggle-bars::before { top: -6px; }
.nav-toggle-bars::after { top: 6px; }

.nav-toggle[aria-expanded="true"] .nav-toggle-bars { background: transparent; }
.nav-toggle[aria-expanded="true"] .nav-toggle-bars::before { transform: translateY(6px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle-bars::after { transform: translateY(-6px) rotate(-45deg); }

/* 主导航 */
.primary-nav {
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-height: 0;
}

.nav-caption {
  display: flex;
  align-items: center;
  gap: 10px;
  padding-left: 14px;
  font-family: var(--font-mono);
  font-size: 0.62rem;
  letter-spacing: 0.22em;
  color: var(--c-steel);
  text-transform: uppercase;
}

.nav-caption::after {
  content: "";
  flex: 1 1 auto;
  height: 1px;
  background: var(--c-line);
}

.nav-list {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.nav-list a {
  position: relative;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 14px;
  border: 1px solid transparent;
  border-radius: var(--r-md);
  color: var(--c-steel);
  font-size: 0.94rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  transition:
    color 0.18s var(--ease),
    background-color 0.18s var(--ease),
    border-color 0.18s var(--ease),
    transform 0.18s var(--ease);
}

.nav-index {
  font-family: var(--font-mono);
  font-size: 0.66rem;
  letter-spacing: 0.08em;
  color: rgba(138, 154, 176, 0.72);
  min-width: 18px;
}

.nav-label { white-space: nowrap; }

.nav-list a:hover {
  color: var(--c-mist);
  background: rgba(16, 27, 46, 0.92);
  border-color: rgba(61, 245, 212, 0.34);
  transform: translateX(2px);
}

.nav-list a:hover .nav-index { color: var(--c-cyan); }

.nav-list a[aria-current="page"] {
  color: #04140F;
  background: var(--c-cyan);
  border-color: var(--c-cyan);
  box-shadow: 0 10px 26px -14px rgba(61, 245, 212, 0.95);
}

.nav-list a[aria-current="page"] .nav-index { color: rgba(4, 20, 15, 0.62); }

.nav-list a[aria-current="page"]:hover {
  color: #04140F;
  background: var(--c-cyan);
  transform: translateX(2px);
}

.nav-cta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 18px;
  border-radius: var(--r-pill);
  background: linear-gradient(120deg, var(--c-orange), #FF6E4A);
  color: #180803;
  font-size: 0.9rem;
  font-weight: 800;
  letter-spacing: 0.02em;
  box-shadow: 0 12px 30px -16px rgba(255, 138, 61, 0.92);
  transition: transform 0.18s var(--ease), filter 0.18s var(--ease), box-shadow 0.18s var(--ease);
}

.nav-cta::after {
  content: "\2192";
  font-family: var(--font-mono);
  font-size: 0.9rem;
  transition: transform 0.18s var(--ease);
}

.nav-cta:hover {
  transform: translateY(-2px);
  filter: brightness(1.06);
  box-shadow: 0 16px 34px -14px rgba(255, 138, 61, 0.95);
}

.nav-cta:hover::after { transform: translateX(3px); }

/* 轨道底部状态 */
.rail-foot {
  margin-top: auto;
  padding-top: 18px;
  border-top: 1px solid var(--c-line);
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.rail-status {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  color: var(--c-steel);
}

.status-dot {
  flex: none;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--c-green);
  box-shadow: 0 0 0 3px rgba(124, 255, 178, 0.16);
}

.rail-coord {
  font-family: var(--font-mono);
  font-size: 0.66rem;
  letter-spacing: 0.1em;
  color: rgba(138, 154, 176, 0.66);
}

/* 滚动进度 */
.rail-progress {
  position: absolute;
  top: 0;
  right: 0;
  width: 2px;
  height: 100%;
  background: rgba(36, 58, 90, 0.5);
  pointer-events: none;
  z-index: 2;
}

.rail-progress-fill {
  display: block;
  width: 100%;
  height: var(--scroll-progress, 0%);
  border-radius: 2px;
  background: linear-gradient(180deg, var(--c-cyan), var(--c-violet) 58%, var(--c-orange));
  transition: height 0.12s linear;
}

/* ---------- 5. 页脚 ---------- */
.site-footer {
  position: relative;
  margin-top: clamp(48px, 8vw, 96px);
  border-top: 1px solid var(--c-line);
  background:
    radial-gradient(720px 340px at 88% 0%, rgba(138, 108, 255, 0.16), transparent 64%),
    radial-gradient(560px 320px at 6% 100%, rgba(61, 245, 212, 0.08), transparent 62%),
    linear-gradient(180deg, #0B1324 0%, #050812 78%);
  color: var(--c-steel);
}

.site-footer::before {
  content: "";
  position: absolute;
  top: -1px;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(61, 245, 212, 0.55) 26%, rgba(255, 138, 61, 0.4) 62%, transparent);
}

.footer-inner {
  max-width: var(--content-max);
  margin-inline: auto;
  padding: clamp(34px, 5vw, 64px) var(--gutter) clamp(20px, 3vw, 30px);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 0.8fr 0.8fr 1.2fr;
  gap: clamp(24px, 4vw, 48px);
}

.footer-brand { min-width: 0; }

.footer-summary {
  margin-top: 16px;
  max-width: 36ch;
  font-size: 0.9rem;
  line-height: 1.8;
  color: var(--c-steel);
}

.footer-stamp {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 14px;
  font-family: var(--font-mono);
  font-size: 0.66rem;
  letter-spacing: 0.12em;
  color: rgba(138, 154, 176, 0.85);
}

.footer-col { min-width: 0; }

.footer-heading {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 16px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--c-line);
  font-family: var(--font-mono);
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--c-cyan);
}

.footer-links {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.footer-links a {
  display: inline-block;
  padding: 6px 0;
  font-size: 0.9rem;
  color: var(--c-steel);
  transition: color 0.18s var(--ease), transform 0.18s var(--ease);
}

.footer-links a:hover {
  color: var(--c-mist);
  transform: translateX(3px);
}

.footer-contact {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 10px;
}

.copy-chip {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  max-width: 100%;
  padding: 8px 12px;
  border: 1px solid var(--c-line);
  border-radius: var(--r-sm);
  background: rgba(16, 27, 46, 0.86);
  color: var(--c-mist);
  font-family: var(--font-mono);
  font-size: 0.76rem;
  line-height: 1.4;
  text-align: left;
  transition: border-color 0.18s var(--ease), background-color 0.18s var(--ease);
}

.copy-chip:hover {
  border-color: rgba(61, 245, 212, 0.5);
  background: var(--c-panel-hi);
}

.copy-value { overflow-wrap: anywhere; }

.copy-hint {
  flex: none;
  font-family: var(--font-body);
  font-size: 0.64rem;
  letter-spacing: 0.14em;
  color: var(--c-cyan);
}

.copy-chip[data-copied] {
  border-color: rgba(124, 255, 178, 0.55);
}

.copy-chip[data-copied] .copy-hint { color: var(--c-green); }

.contact-address {
  font-size: 0.86rem;
  line-height: 1.7;
  color: var(--c-steel);
}

.contact-note {
  padding-left: 10px;
  border-left: 2px solid var(--c-line);
  font-size: 0.76rem;
  line-height: 1.7;
  color: rgba(138, 154, 176, 0.8);
}

.footer-base {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: clamp(28px, 4vw, 44px);
  padding-top: 18px;
  border-top: 1px solid var(--c-line);
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  color: rgba(138, 154, 176, 0.82);
}

.footer-copy { color: rgba(237, 244, 255, 0.78); }
.footer-icp { color: rgba(138, 154, 176, 0.72); }

/* ---------- 6. 通用容器与排版组件 ---------- */
.wrap {
  width: 100%;
  max-width: var(--content-max);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.display {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(3rem, 8vw, 7rem);
  line-height: 0.95;
  letter-spacing: -0.03em;
  margin: 0;
}

.chapter-num {
  display: block;
  font-family: var(--font-mono);
  font-size: clamp(2.4rem, 6vw, 4.2rem);
  font-weight: 700;
  line-height: 0.9;
  letter-spacing: -0.04em;
  color: rgba(61, 245, 212, 0.42);
  -webkit-text-stroke: 1px rgba(61, 245, 212, 0.7);
}

.eyebrow {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--c-steel);
}

.eyebrow::after {
  content: "";
  flex: 1 1 auto;
  height: 1px;
  background: var(--c-line);
}

/* 面包屑 */
.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  padding-block: 18px;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  color: var(--c-steel);
}

.breadcrumb li {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.breadcrumb li + li::before {
  content: "/";
  color: var(--c-line);
}

.breadcrumb a {
  color: var(--c-steel);
  border-bottom: 1px solid transparent;
  transition: color 0.18s var(--ease), border-color 0.18s var(--ease);
}

.breadcrumb a:hover {
  color: var(--c-cyan);
  border-bottom-color: rgba(61, 245, 212, 0.5);
}

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

/* 按钮 */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 13px 24px;
  border: 1px solid transparent;
  border-radius: var(--r-pill);
  font-family: var(--font-body);
  font-size: 0.92rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  cursor: pointer;
  transition:
    transform 0.18s var(--ease),
    background-color 0.18s var(--ease),
    border-color 0.18s var(--ease),
    color 0.18s var(--ease),
    box-shadow 0.18s var(--ease);
}

.btn:hover { transform: translateY(-2px); }

.btn--primary {
  background: linear-gradient(120deg, var(--c-orange), #FF6E4A);
  color: #180803;
  box-shadow: 0 14px 34px -18px rgba(255, 138, 61, 0.95);
}

.btn--primary:hover { filter: brightness(1.06); }

.btn--ghost {
  background: rgba(16, 27, 46, 0.72);
  border-color: var(--c-line);
  color: var(--c-mist);
}

.btn--ghost:hover {
  border-color: rgba(61, 245, 212, 0.55);
  background: var(--c-panel-hi);
}

.btn--quiet {
  background: transparent;
  border-color: rgba(61, 245, 212, 0.42);
  color: var(--c-cyan);
}

.btn--quiet:hover {
  border-color: var(--c-cyan);
  background: rgba(61, 245, 212, 0.1);
}

/* 卡片 */
.card {
  position: relative;
  padding: clamp(18px, 2.4vw, 26px);
  border: 1px solid var(--c-line);
  border-radius: var(--r-lg);
  background: var(--c-panel);
  box-shadow: var(--shadow-card);
  transition:
    transform 0.18s var(--ease),
    border-color 0.18s var(--ease),
    background-color 0.18s var(--ease),
    box-shadow 0.18s var(--ease);
}

.card:hover {
  transform: translateY(-2px);
  border-color: rgba(61, 245, 212, 0.45);
  background: var(--c-panel-hi);
  box-shadow: 0 24px 56px -30px rgba(0, 0, 0, 0.95);
}

/* 标签 */
.tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 12px;
  border: 1px solid var(--c-line);
  border-radius: var(--r-pill);
  background: rgba(16, 27, 46, 0.72);
  font-family: var(--font-mono);
  font-size: 0.64rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--c-steel);
}

.tag--cyan {
  color: var(--c-cyan);
  border-color: rgba(61, 245, 212, 0.4);
  background: rgba(61, 245, 212, 0.08);
}

.tag--orange {
  color: var(--c-orange);
  border-color: rgba(255, 138, 61, 0.42);
  background: rgba(255, 138, 61, 0.1);
}

.tag--violet {
  color: #C0B1FF;
  border-color: rgba(138, 108, 255, 0.45);
  background: rgba(138, 108, 255, 0.12);
}

.tag--green {
  color: var(--c-green);
  border-color: rgba(124, 255, 178, 0.4);
  background: rgba(124, 255, 178, 0.09);
}

.tag--red {
  color: var(--c-red);
  border-color: rgba(255, 95, 109, 0.42);
  background: rgba(255, 95, 109, 0.1);
}

/* 网格 */
.grid {
  display: grid;
  gap: clamp(14px, 2vw, 24px);
}

.grid--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid--4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }

/* 图片容器基础规则 */
.media {
  position: relative;
  overflow: hidden;
  display: block;
  aspect-ratio: 16 / 9;
  border: 1px solid var(--c-line);
  border-radius: var(--r-lg);
  background:
    radial-gradient(520px 260px at 78% 8%, rgba(138, 108, 255, 0.22), transparent 62%),
    linear-gradient(150deg, var(--c-panel) 0%, var(--c-void) 100%);
}

.media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: contrast(1.06) saturate(0.94) brightness(0.96);
}

.media::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  box-shadow: inset 0 0 0 1px rgba(61, 245, 212, 0.14);
  pointer-events: none;
}

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

.media__caption {
  position: absolute;
  inset: auto 0 0 0;
  z-index: 1;
  padding: 10px 14px;
  background: linear-gradient(180deg, transparent, rgba(5, 8, 18, 0.94));
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  color: var(--c-steel);
}

/* ---------- 7. 响应式 ---------- */
@media (max-width: 1200px) {
  .footer-grid { grid-template-columns: 1.3fr 0.9fr 0.9fr; }
  .footer-contact { grid-column: 1 / -1; }
}

@media (max-width: 1023px) {
  body {
    padding-left: 0;
    padding-top: var(--header-h);
  }

  .site-header {
    inset: 0 0 auto 0;
    width: auto;
    min-height: var(--header-h);
    flex-direction: row;
    border-right: 0;
    border-bottom: 1px solid var(--c-line);
    background: linear-gradient(180deg, rgba(11, 19, 36, 0.97), rgba(5, 8, 18, 0.94));
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
  }

  .site-header::before {
    top: auto;
    bottom: 0;
    left: 0;
    right: 0;
    width: auto;
    height: 1px;
    background: linear-gradient(90deg, rgba(61, 245, 212, 0.45), rgba(138, 108, 255, 0.35) 60%, transparent);
  }

  .header-rail {
    flex: 1 1 auto;
    flex-direction: row;
    align-items: center;
    gap: 14px;
    width: 100%;
    max-width: var(--content-max);
    margin-inline: auto;
    padding: 12px var(--gutter);
    overflow: visible;
  }

  .site-header .brand-sub { display: none; }

  .brand-mark {
    width: 34px;
    height: 34px;
    border-radius: 10px;
  }

  .brand-mark::after { inset: 10px; }

  .nav-toggle {
    display: inline-flex;
    margin-left: auto;
  }

  .primary-nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    z-index: 3;
    gap: 16px;
    max-height: min(78vh, 620px);
    padding: 20px var(--gutter) 28px;
    overflow-y: auto;
    background: linear-gradient(180deg, #0B1324 0%, #050812 100%);
    border-bottom: 1px solid var(--c-line);
    box-shadow: 0 34px 64px -34px rgba(0, 0, 0, 0.95);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translateY(-12px);
    transition:
      opacity 0.22s var(--ease),
      transform 0.22s var(--ease),
      visibility 0.22s var(--ease);
  }

  .primary-nav[data-open] {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: translateY(0);
  }

  .nav-caption { padding-left: 12px; }

  .nav-list a { padding: 13px 12px; }

  .rail-foot { display: none; }

  .rail-progress {
    top: auto;
    bottom: -1px;
    left: 0;
    right: 0;
    width: 100%;
    height: 2px;
    background: rgba(36, 58, 90, 0.5);
  }

  .rail-progress-fill {
    width: var(--scroll-progress, 0%);
    height: 100%;
    background: linear-gradient(90deg, var(--c-cyan), var(--c-violet) 60%, var(--c-orange));
    transition: width 0.12s linear;
  }

  html.nav-open,
  html.nav-open body { overflow: hidden; }

  .footer-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .footer-brand { grid-column: 1 / -1; }
}

@media (max-width: 900px) {
  .grid--3,
  .grid--4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 620px) {
  body { font-size: 15.5px; }

  .grid--2,
  .grid--3,
  .grid--4 { grid-template-columns: minmax(0, 1fr); }

  .footer-grid { grid-template-columns: minmax(0, 1fr); }
  .footer-brand { grid-column: auto; }

  .footer-base {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }

  .copy-chip { width: 100%; }
}

/* ---------- 8. 减少动态效果 ---------- */
@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;
  }

  .btn:hover,
  .card:hover,
  .nav-list a:hover,
  .nav-cta:hover,
  .footer-links a:hover { transform: none; }
}
