/* ============================================================
   海鸥赛场 · 共享样式表 /assets/site.css
   高原数据赛场：左侧航标栏 + 右侧悬浮顶条 + 斜向数据纹理
   ============================================================ */

/* ---------- 1. 变量 ---------- */
:root {
  --c-deep: #0B3C5D;
  --c-white: #F5F7FA;
  --c-paper: #F1E9DA;
  --c-ink: #10222E;
  --c-orange: #F28C28;
  --c-blue: #2E7DB2;
  --c-green: #1F8F6B;
  --c-red: #C6473A;
  --c-yellow: #E8C24A;
  --c-mist: #5E7180;
  --c-night: #072A41;

  --rail-w: 320px;
  --topbar-h: 68px;
  --pad-x: clamp(1.1rem, 3vw, 2.75rem);
  --gap: clamp(1rem, 2.2vw, 1.75rem);

  --r-xl: 30px;
  --r-lg: 20px;
  --r-md: 14px;
  --r-pill: 999px;

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

  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
  --shadow-1: 0 1px 0 rgba(11, 60, 93, 0.08), 0 14px 28px -22px rgba(7, 42, 65, 0.6);
  --shadow-2: 0 3px 0 rgba(11, 60, 93, 0.1), 0 26px 44px -28px rgba(7, 42, 65, 0.65);
}

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

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

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

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

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

a { color: inherit; }

[hidden] { display: none !important; }

/* ---------- 3. 基础排版 ---------- */
body {
  font-family: var(--font-body);
  font-size: 16.5px;
  line-height: 1.75;
  color: var(--c-ink);
  background: var(--c-white);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

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

h1 { font-size: clamp(2.4rem, 6vw, 4.6rem); }
h2 { font-size: clamp(1.5rem, 3vw, 2.2rem); }
h3 { font-size: 1.25rem; }
h4 { font-size: 1.05rem; }

p { text-wrap: pretty; }

/* ---------- 4. 通用工具类 ---------- */
.content-shell {
  max-width: 1180px;
  margin-inline: auto;
  padding-inline: var(--pad-x);
}

.display {
  font-family: var(--font-head);
  font-weight: 900;
  font-size: clamp(2.4rem, 6vw, 4.6rem);
  line-height: 1.04;
  letter-spacing: -0.012em;
  color: var(--c-deep);
  transform: skewX(-2deg);
  transform-origin: left bottom;
}

.mono {
  font-family: var(--font-mono);
  font-weight: 600;
  letter-spacing: 0.02em;
  font-variant-numeric: tabular-nums;
  display: inline-block;
  max-width: 100%;
}

.lead {
  font-size: 1.0625rem;
  line-height: 1.8;
  color: #29404f;
  max-width: 38em;
}

.stack > * + * { margin-top: var(--gap); }

.grid { display: grid; gap: var(--gap); }
.grid-2 { grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.grid-3 { grid-template-columns: repeat(auto-fit, minmax(206px, 1fr)); }

.dot {
  display: inline-block;
  width: 7px;
  height: 7px;
  margin-right: 0.45rem;
  border-radius: 50%;
  background: var(--c-green);
  box-shadow: 0 0 0 3px rgba(31, 143, 107, 0.18);
  vertical-align: middle;
}

/* ---------- 5. 焦点与跳过链接 ---------- */
:focus-visible {
  outline: 2px solid var(--c-orange);
  outline-offset: 3px;
  box-shadow: 0 0 0 5px rgba(245, 247, 250, 0.7);
  border-radius: 4px;
}

.skip-link {
  position: fixed;
  top: 0;
  left: 50%;
  z-index: 999;
  padding: 0.8rem 1.5rem;
  border-radius: 0 0 var(--r-md) var(--r-md);
  background: var(--c-orange);
  color: #fff;
  font-weight: 800;
  font-size: 0.92rem;
  text-decoration: none;
  transform: translate(-50%, -150%);
  transition: transform 0.22s var(--ease);
}

.skip-link:focus,
.skip-link:focus-visible {
  transform: translate(-50%, 0);
  outline: none;
}

/* ---------- 6. 页头 ---------- */
.site-header {
  position: relative;
  z-index: 60;
}

/* 6.1 左侧航标栏 */
.rail {
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  z-index: 60;
  width: var(--rail-w);
  display: flex;
  flex-direction: column;
  gap: 1.35rem;
  padding: 1.7rem 1.1rem 1.35rem;
  background: linear-gradient(168deg, var(--c-deep) 0%, #093450 54%, var(--c-night) 100%);
  color: var(--c-white);
  border-right: 1px solid rgba(245, 247, 250, 0.08);
  overflow: hidden auto;
}

.rail::before {
  content: "";
  position: absolute;
  top: -18%;
  right: -32%;
  width: 340px;
  height: 340px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(242, 140, 40, 0.3), transparent 68%);
  pointer-events: none;
}

.rail::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image: repeating-linear-gradient(
    112deg,
    rgba(245, 247, 250, 0.055) 0 1px,
    transparent 1px 42px
  );
  pointer-events: none;
}

.rail > * { position: relative; z-index: 1; }

/* 6.2 品牌 */
.brand {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  text-decoration: none;
  color: inherit;
}

.brand-mark {
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  color: var(--c-orange);
}

.brand-text { display: block; }

.brand-name {
  display: block;
  font-family: var(--font-head);
  font-size: 1.2rem;
  font-weight: 900;
  letter-spacing: 0.02em;
  color: var(--c-white);
}

.brand-sub {
  display: block;
  margin-top: 0.15rem;
  font-size: 0.7rem;
  letter-spacing: 0.05em;
  color: rgba(245, 247, 250, 0.58);
}

/* 6.3 移动菜单按钮 */
.nav-toggle {
  display: none;
  align-items: center;
  gap: 0.5rem;
  padding: 0.45rem 0.85rem;
  border: 1.5px solid rgba(245, 247, 250, 0.28);
  border-radius: var(--r-pill);
  color: var(--c-white);
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
  transition: border-color 0.18s var(--ease), background 0.18s var(--ease);
}

.nav-toggle:hover { border-color: var(--c-orange); }

.nav-toggle-bars {
  position: relative;
  display: block;
  width: 16px;
  height: 2px;
  background: currentColor;
  border-radius: 2px;
}

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

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

.site-header[data-open] .nav-toggle-bars { background: transparent; }
.site-header[data-open] .nav-toggle-bars::before { transform: translateY(5px) rotate(45deg); }
.site-header[data-open] .nav-toggle-bars::after { transform: translateY(-5px) rotate(-45deg); }

/* 6.4 竖排导航 */
.rail-nav { min-height: 0; }

.rail-label {
  margin-bottom: 0.55rem;
  padding-left: 1rem;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.22em;
  color: rgba(245, 247, 250, 0.42);
}

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

.rail-link {
  position: relative;
  display: flex;
  align-items: center;
  gap: 0.7rem;
  padding: 0.6rem 0.9rem 0.6rem 1rem;
  border-radius: 0 var(--r-pill) var(--r-pill) 0;
  color: rgba(245, 247, 250, 0.78);
  font-size: 0.95rem;
  font-weight: 600;
  text-decoration: none;
  transition: color 0.18s var(--ease), background 0.18s var(--ease);
}

.rail-link::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  width: 3px;
  height: 26px;
  border-radius: 3px;
  background: var(--c-orange);
  opacity: 0;
  transform: translateY(-50%) scaleY(0.25);
  transition: opacity 0.18s var(--ease), transform 0.24s var(--ease);
}

.rail-link:hover {
  color: #fff;
  background: rgba(245, 247, 250, 0.08);
}

.rail-link[aria-current="page"] {
  color: #fff;
  background: rgba(242, 140, 40, 0.16);
}

.rail-link[aria-current="page"]::before {
  opacity: 1;
  transform: translateY(-50%) scaleY(1);
}

.rail-num {
  flex: 0 0 auto;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: var(--c-orange);
}

.rail-word { flex: 1 1 auto; }

/* 6.5 经幡条与版本 */
.rail-foot {
  margin-top: auto;
  padding-top: 1rem;
  border-top: 1px solid rgba(245, 247, 250, 0.12);
}

.rail-flag {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 4px;
  height: 20px;
  margin-bottom: 0.7rem;
}

.rail-flag span {
  border-radius: 2px;
  transform-origin: top center;
  animation: flag-wave 5.4s var(--ease) infinite alternate;
}

.rail-flag span:nth-child(1) { background: var(--c-blue); animation-delay: 0s; }
.rail-flag span:nth-child(2) { background: #F5F7FA; animation-delay: 0.5s; }
.rail-flag span:nth-child(3) { background: var(--c-red); animation-delay: 1s; }
.rail-flag span:nth-child(4) { background: var(--c-green); animation-delay: 1.5s; }
.rail-flag span:nth-child(5) { background: var(--c-yellow); animation-delay: 2s; }

@keyframes flag-wave {
  from { transform: skewY(0deg); }
  to { transform: skewY(0.6deg); }
}

.rail-version {
  font-size: 0.72rem;
  letter-spacing: 0.05em;
  color: rgba(245, 247, 250, 0.55);
}

.rail-version .mono { color: var(--c-yellow); }

/* 6.6 右侧顶条 */
.topbar {
  position: fixed;
  top: 0;
  left: var(--rail-w);
  right: 0;
  z-index: 55;
  height: var(--topbar-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0 var(--pad-x);
  background: rgba(245, 247, 250, 0.92);
  border-bottom: 1px solid rgba(11, 60, 93, 0.12);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
}

.topbar-note {
  display: flex;
  align-items: center;
  font-size: 0.8rem;
  letter-spacing: 0.02em;
  color: var(--c-mist);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.topbar-actions {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  flex: 0 0 auto;
}

.pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  padding: 0.52rem 1.15rem;
  border-radius: var(--r-pill);
  font-size: 0.88rem;
  font-weight: 800;
  letter-spacing: 0.01em;
  text-decoration: none;
  white-space: nowrap;
  transition: transform 0.18s var(--ease), background 0.18s var(--ease),
    color 0.18s var(--ease), border-color 0.18s var(--ease),
    box-shadow 0.18s var(--ease);
}

.pill-ghost {
  border: 1.5px solid rgba(11, 60, 93, 0.26);
  color: var(--c-deep);
}

.pill-ghost:hover {
  border-color: var(--c-orange);
  color: var(--c-orange);
  transform: translateY(-1px);
}

.pill-accent {
  background: var(--c-orange);
  color: #fff;
  box-shadow: 0 3px 0 rgba(11, 60, 93, 0.22);
}

.pill-accent:hover {
  background: #ff9b3c;
  transform: translateY(-2px);
  box-shadow: 0 5px 0 rgba(11, 60, 93, 0.22);
}

/* 6.7 滚动进度线 */
.scroll-progress {
  position: fixed;
  top: var(--topbar-h);
  left: var(--rail-w);
  right: 0;
  z-index: 56;
  height: 3px;
  pointer-events: none;
}

.scroll-progress-bar {
  display: block;
  width: 0;
  height: 100%;
  background: linear-gradient(90deg, var(--c-orange), var(--c-yellow));
}

/* ---------- 7. 页脚 ---------- */
.site-footer {
  position: relative;
  margin-top: clamp(3rem, 7vw, 6rem);
  background: var(--c-night);
  color: rgba(245, 247, 250, 0.76);
  font-size: 0.92rem;
}

.footer-flags {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  height: 5px;
}

.footer-flags span:nth-child(1) { background: var(--c-blue); }
.footer-flags span:nth-child(2) { background: #F5F7FA; }
.footer-flags span:nth-child(3) { background: var(--c-red); }
.footer-flags span:nth-child(4) { background: var(--c-green); }
.footer-flags span:nth-child(5) { background: var(--c-yellow); }

.footer-inner {
  max-width: 1180px;
  margin-inline: auto;
  padding: clamp(2.2rem, 5vw, 3.4rem) var(--pad-x) clamp(1.6rem, 3vw, 2.2rem);
  display: grid;
  grid-template-columns: minmax(0, 0.82fr) minmax(0, 2.6fr);
  gap: clamp(1.6rem, 4vw, 3.2rem);
}

.footer-logo {
  font-family: var(--font-head);
  font-size: 1.45rem;
  font-weight: 900;
  letter-spacing: 0.02em;
  color: var(--c-white);
}

.footer-tagline {
  margin-top: 0.35rem;
  font-size: 0.78rem;
  letter-spacing: 0.04em;
  color: rgba(245, 247, 250, 0.55);
}

.footer-domain {
  display: inline-block;
  margin-top: 0.9rem;
  padding: 0.24rem 0.7rem;
  border: 1px solid rgba(242, 140, 40, 0.42);
  border-radius: var(--r-pill);
  font-size: 0.72rem;
  color: var(--c-yellow);
}

.footer-cols {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: clamp(0.9rem, 2vw, 1.6rem);
}

.footer-title {
  margin-bottom: 0.85rem;
  font-family: var(--font-head);
  font-size: 0.82rem;
  font-weight: 900;
  letter-spacing: 0.16em;
  color: rgba(245, 247, 250, 0.62);
}

.footer-list li + li { margin-top: 0.42rem; }

.footer-list a {
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: color 0.18s var(--ease), border-color 0.18s var(--ease);
}

.footer-list a:hover {
  color: var(--c-orange);
  border-bottom-color: var(--c-orange);
}

.copy-line {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.55rem;
  width: 100%;
  margin-bottom: 0.45rem;
  padding: 0.4rem 0.72rem;
  border: 1px solid rgba(245, 247, 250, 0.16);
  border-radius: var(--r-pill);
  background: rgba(245, 247, 250, 0.06);
  color: var(--c-white);
  font-size: 0.8rem;
  text-align: left;
  cursor: pointer;
  transition: background 0.18s var(--ease), border-color 0.18s var(--ease);
}

.copy-line:hover {
  background: rgba(242, 140, 40, 0.16);
  border-color: rgba(242, 140, 40, 0.55);
}

.copy-value {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.copy-hint {
  flex: 0 0 auto;
  font-size: 0.66rem;
  letter-spacing: 0.08em;
  color: var(--c-orange);
}

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

.footer-addr {
  margin-top: 0.5rem;
  font-size: 0.78rem;
  line-height: 1.6;
  color: rgba(245, 247, 250, 0.58);
}

.footer-icp {
  margin-top: 0.5rem;
  font-size: 0.74rem;
  color: rgba(245, 247, 250, 0.48);
}

.footer-bottom {
  max-width: 1180px;
  margin-inline: auto;
  padding: 1rem var(--pad-x) 1.8rem;
  border-top: 1px solid rgba(245, 247, 250, 0.12);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem 1.5rem;
  font-size: 0.76rem;
  color: rgba(245, 247, 250, 0.5);
}

/* ---------- 8. 通用组件 ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.78rem 1.5rem;
  border-radius: var(--r-pill);
  font-family: var(--font-head);
  font-size: 0.94rem;
  font-weight: 900;
  letter-spacing: 0.01em;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.18s var(--ease), background 0.18s var(--ease),
    color 0.18s var(--ease), border-color 0.18s var(--ease),
    box-shadow 0.18s var(--ease);
}

.btn-primary {
  background: var(--c-orange);
  color: #fff;
  box-shadow: 0 3px 0 rgba(11, 60, 93, 0.22);
}

.btn-primary:hover {
  background: #ff9b3c;
  transform: translateY(-2px);
  box-shadow: 0 5px 0 rgba(11, 60, 93, 0.22);
}

.btn-outline {
  border: 1.5px solid rgba(11, 60, 93, 0.28);
  color: var(--c-deep);
}

.btn-outline:hover {
  border-color: var(--c-orange);
  color: var(--c-orange);
  transform: translateY(-2px);
}

.btn-ink {
  background: var(--c-deep);
  color: var(--c-white);
}

.btn-ink:hover {
  background: var(--c-night);
  transform: translateY(-2px);
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.42rem 1rem;
  border: 1.5px solid rgba(11, 60, 93, 0.2);
  border-radius: var(--r-pill);
  background: #fff;
  color: var(--c-deep);
  font-size: 0.86rem;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.18s var(--ease), color 0.18s var(--ease),
    border-color 0.18s var(--ease), transform 0.18s var(--ease);
}

.chip:hover {
  border-color: var(--c-orange);
  color: var(--c-orange);
  transform: translateY(-1px);
}

.chip[aria-pressed="true"],
.chip.is-active {
  background: var(--c-deep);
  border-color: var(--c-deep);
  color: #fff;
}

.card {
  position: relative;
  padding: clamp(1.1rem, 2.2vw, 1.7rem);
  background: #fff;
  border: 1px solid rgba(11, 60, 93, 0.08);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-1);
  transition: transform 0.22s var(--ease), box-shadow 0.22s var(--ease);
}

.card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-2);
}

.section-head {
  display: flex;
  align-items: flex-end;
  gap: 0.85rem;
  padding-bottom: 0.85rem;
  margin-bottom: 1.6rem;
  border-bottom: 1px solid rgba(11, 60, 93, 0.16);
}

.section-no {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  color: var(--c-orange);
}

.section-title {
  font-family: var(--font-head);
  font-size: clamp(1.35rem, 2.6vw, 2rem);
  font-weight: 900;
  color: var(--c-deep);
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.45rem;
  margin-bottom: 1.4rem;
  font-size: 0.79rem;
  color: var(--c-mist);
}

.breadcrumb a {
  text-decoration: none;
  border-bottom: 1px solid rgba(94, 113, 128, 0.36);
  transition: color 0.18s var(--ease), border-color 0.18s var(--ease);
}

.breadcrumb a:hover {
  color: var(--c-orange);
  border-bottom-color: var(--c-orange);
}

.breadcrumb-sep { opacity: 0.5; }

/* ---------- 9. 图片容器基础规则 ---------- */
.media {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  aspect-ratio: 16 / 10;
  border-radius: var(--r-xl);
  background:
    linear-gradient(135deg, rgba(11, 60, 93, 0.16), rgba(46, 125, 178, 0.12) 55%, rgba(242, 140, 40, 0.16));
}

.media::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image:
    repeating-linear-gradient(0deg, rgba(245, 247, 250, 0.16) 0 1px, transparent 1px 34px),
    repeating-linear-gradient(90deg, rgba(245, 247, 250, 0.16) 0 1px, transparent 1px 34px);
  mix-blend-mode: screen;
}

.media > img,
.media > picture > img,
.media > svg {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* ---------- 10. 显现与动效 ---------- */
[data-reveal] {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.5s var(--ease), transform 0.62s var(--ease);
}

[data-reveal].is-in {
  opacity: 1;
  transform: none;
}

#main-content { scroll-margin-top: calc(var(--topbar-h) + 14px); }

/* ---------- 11. 桌面端外壳偏移 ---------- */
@media (min-width: 961px) {
  body {
    padding-left: var(--rail-w);
    padding-top: var(--topbar-h);
  }
}

@media (min-width: 961px) and (max-width: 1140px) {
  :root { --rail-w: 268px; }
}

/* ---------- 12. 平板与移动端 ---------- */
@media (max-width: 1024px) {
  .footer-inner {
    grid-template-columns: 1fr;
    gap: 1.8rem;
  }

  .footer-cols {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1.6rem;
  }
}

@media (max-width: 960px) {
  body {
    padding-left: 0;
    padding-top: 0;
  }

  .site-header {
    position: sticky;
    top: 0;
    z-index: 80;
  }

  /* 左栏 -> 顶部品牌条 */
  .rail {
    position: relative;
    inset: auto;
    width: 100%;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: 0.8rem;
    padding: 0.7rem var(--pad-x);
    border-right: 0;
    border-bottom: 1px solid rgba(245, 247, 250, 0.12);
    overflow: visible;
  }

  .rail::before,
  .rail::after { display: none; }

  .rail-foot { display: none; }

  .brand-name { font-size: 1.06rem; }
  .brand-sub { font-size: 0.64rem; }

  .nav-toggle { display: inline-flex; }

  /* 抽屉导航 */
  .rail-nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    margin: 0;
    padding: 0 var(--pad-x);
    max-height: 0;
    overflow: hidden;
    background: var(--c-night);
    border-bottom: 1px solid rgba(245, 247, 250, 0.12);
    transition: max-height 0.34s var(--ease), padding 0.34s var(--ease);
  }

  .site-header[data-open] .rail-nav {
    max-height: 74vh;
    overflow-y: auto;
    padding: 0.9rem var(--pad-x) 1.6rem;
  }

  .rail-label { padding-left: 0; }

  .rail-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 4px;
  }

  .rail-link {
    border-radius: var(--r-md);
    padding: 0.62rem 0.7rem;
    background: rgba(245, 247, 250, 0.05);
  }

  .rail-link::before { display: none; }

  .rail-link[aria-current="page"] {
    box-shadow: inset 3px 0 0 var(--c-orange);
  }

  /* 顶条 -> 横向胶囊条（第二区块） */
  .topbar {
    position: static;
    height: auto;
    justify-content: flex-start;
    gap: 0.5rem;
    padding: 0.55rem var(--pad-x);
    background: var(--c-paper);
    border-bottom: 1px solid rgba(11, 60, 93, 0.14);
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
    overflow-x: auto;
    scrollbar-width: none;
  }

  .topbar::-webkit-scrollbar { display: none; }

  .topbar-note { display: none; }

  .topbar-actions { gap: 0.5rem; }

  .pill {
    padding: 0.45rem 1rem;
    font-size: 0.82rem;
  }

  .scroll-progress { display: none; }

  #main-content { scroll-margin-top: 16px; }
}

@media (max-width: 640px) {
  body { font-size: 16px; }

  .footer-cols { grid-template-columns: 1fr; }

  .footer-bottom {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.35rem;
  }

  .lead { font-size: 1rem; }
}

/* ---------- 13. 降低动效 ---------- */
@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;
  }

  [data-reveal] {
    opacity: 1;
    transform: none;
  }

  .rail-flag span { animation: none; }
}
