/* ============================================================
   BOB体官网看台 · 共享样式 /assets/site.css
   1 复位  2 变量  3 基础排版  4 布局  5 头部  6 导航
   7 搜索面板  8 进度条  9 通用组件  10 页脚  11 响应式  12 动效降级
   ============================================================ */

/* ---------- 1 复位 ---------- */
*,
*::before,
*::after { box-sizing: border-box; }

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

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

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

button {
  font: inherit;
  color: inherit;
  background: none;
  border: 0;
  border-radius: 0;
  padding: 0;
  margin: 0;
  cursor: pointer;
  -webkit-appearance: none;
  appearance: none;
}

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

table { border-collapse: collapse; width: 100%; }

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

[id] { scroll-margin-top: 120px; }

/* ---------- 2 变量 ---------- */
:root {
  --ink: #071612;
  --panel: #0E2A22;
  --panel-2: #12362C;
  --deep: #1B4A3E;
  --cyan: #2BE8C8;
  --cyan-soft: #7CF5DC;
  --amber: #FF8A3D;
  --amber-soft: #FFC08A;
  --text: #E8F2EE;
  --muted: #9DB5AD;
  --line: #3A5A50;
  --line-soft: rgba(58, 90, 80, 0.5);

  --font-display: 'Barlow Condensed', 'Oswald', 'Noto Sans SC', 'PingFang SC', sans-serif;
  --font-mono: 'JetBrains Mono', 'IBM Plex Mono', 'Menlo', 'Consolas', monospace;
  --font-body: 'PingFang SC', 'Noto Sans SC', 'Source Han Sans SC', system-ui, -apple-system, 'Segoe UI', sans-serif;

  --shell: 1240px;
  --gutter: 24px;
  --ease: cubic-bezier(.2, .7, .2, 1);
  --dur: 320ms;
}

/* ---------- 3 基础排版 ---------- */
body {
  min-height: 100vh;
  background-color: var(--ink);
  background-image:
    linear-gradient(rgba(58, 90, 80, 0.13) 1px, transparent 1px),
    linear-gradient(90deg, rgba(58, 90, 80, 0.13) 1px, transparent 1px);
  background-size: 64px 64px;
  color: var(--text);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.75;
  letter-spacing: 0.01em;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.15;
  letter-spacing: 0.02em;
}

h1 { font-size: clamp(32px, 5vw, 56px); }
h2 { font-size: clamp(26px, 3.2vw, 40px); }
h3 { font-size: clamp(20px, 2.2vw, 28px); }
h4 { font-size: 20px; }

p { max-width: 68ch; }

strong, b { color: var(--text); font-weight: 600; }

::selection { background: var(--cyan); color: var(--ink); }

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

/* ---------- 4 布局 ---------- */
.shell {
  width: 100%;
  max-width: var(--shell);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.grid { display: grid; gap: 24px; }
.grid--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid--sidebar {
  grid-template-columns: 300px minmax(0, 1fr);
  gap: 32px;
  align-items: start;
}

.stack { display: flex; flex-direction: column; gap: 16px; }
.stack--lg { gap: 32px; }
.cluster { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }

.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
}

.u-mono { font-family: var(--font-mono); font-variant-numeric: tabular-nums; }
.u-muted { color: var(--muted); }
.u-nowrap { white-space: nowrap; }

/* ---------- 5 头部 ---------- */
.skip-link {
  position: fixed;
  top: 0;
  left: var(--gutter);
  z-index: 400;
  transform: translateY(-160%);
  padding: 12px 18px;
  background: var(--cyan);
  color: var(--ink);
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.08em;
  transition: transform 180ms var(--ease);
}
.skip-link:focus { transform: translateY(8px); }

.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 120;
  color: var(--text);
  background: linear-gradient(180deg, rgba(7, 22, 18, 0.86), rgba(7, 22, 18, 0));
  transition: background-color 280ms var(--ease), box-shadow 280ms var(--ease);
}

.site-header::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--cyan), transparent);
  opacity: 0;
  transition: opacity 280ms var(--ease);
}

.site-header[data-scrolled],
.site-header[data-nav-open] {
  background: rgba(7, 22, 18, 0.96);
  box-shadow: 0 22px 48px -34px rgba(0, 0, 0, 0.95);
}

.site-header[data-scrolled]::after { opacity: 0.6; }

/* 工具窄栏 */
.header-rail {
  border-bottom: 1px solid rgba(58, 90, 80, 0.32);
  background: rgba(7, 22, 18, 0.42);
}

.header-rail__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 34px;
}

.header-rail__motto {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  line-height: 1.6;
  letter-spacing: 0.18em;
  color: var(--muted);
  text-transform: uppercase;
  max-width: none;
}

.header-rail__tools {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  line-height: 1;
  letter-spacing: 0.12em;
}

.tool-btn,
.tool-link {
  color: var(--muted);
  white-space: nowrap;
  transition: color 120ms linear;
}

.tool-btn:hover,
.tool-link:hover { color: var(--cyan); }

.tool-sep {
  display: inline-block;
  width: 1px;
  height: 11px;
  background: var(--line);
}

.tool-ver {
  color: rgba(157, 181, 173, 0.62);
  white-space: nowrap;
}

/* 主导航条 */
.header-bar__inner {
  display: flex;
  align-items: center;
  gap: 20px;
  min-height: 70px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-right: auto;
}

.brand__mark {
  position: relative;
  display: block;
  width: 26px;
  height: 26px;
  border: 1px solid var(--cyan);
  flex: none;
}

.brand__mark::before {
  content: "";
  position: absolute;
  inset: 5px;
  border: 1px solid rgba(43, 232, 200, 0.48);
}

.brand__mark span {
  position: absolute;
  right: -3px;
  bottom: -3px;
  display: block;
  width: 7px;
  height: 7px;
  background: var(--amber);
}

.brand__type {
  display: flex;
  flex-direction: column;
  gap: 3px;
  line-height: 1;
}

.brand__name {
  font-family: var(--font-display);
  font-size: 19px;
  font-weight: 600;
  letter-spacing: 0.03em;
  color: var(--text);
}

.brand__sub {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.22em;
  color: var(--muted);
  text-transform: uppercase;
}

/* ---------- 6 导航 ---------- */
.nav-toggle {
  display: none;
  align-items: center;
  gap: 10px;
  padding: 9px 12px;
  border: 1px solid var(--line);
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.16em;
  color: var(--text);
  transition: border-color 120ms linear, color 120ms linear;
}

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

.nav-toggle__bars {
  position: relative;
  display: block;
  width: 16px;
  height: 10px;
}

.nav-toggle__bars::before,
.nav-toggle__bars::after {
  content: "";
  position: absolute;
  left: 0; right: 0;
  height: 1px;
  background: currentColor;
  transition: transform 200ms var(--ease);
}

.nav-toggle__bars::before { top: 0; }
.nav-toggle__bars::after { bottom: 0; }

.nav-toggle[aria-expanded="true"] .nav-toggle__bars::before { transform: translateY(5px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle__bars::after { transform: translateY(-4px) rotate(-45deg); }

.site-nav__list {
  display: flex;
  align-items: center;
  gap: 2px;
}

.site-nav__link {
  position: relative;
  display: flex;
  align-items: baseline;
  gap: 7px;
  padding: 10px 12px;
  color: var(--muted);
  font-size: 14px;
  letter-spacing: 0.05em;
  white-space: nowrap;
  transition: color 120ms linear;
}

.site-nav__idx {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 500;
  color: var(--line);
  transition: color 120ms linear;
}

.site-nav__link::after {
  content: "";
  position: absolute;
  left: 12px; right: 12px; bottom: 4px;
  height: 1px;
  background: var(--cyan);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 180ms var(--ease);
}

.site-nav__link:hover { color: var(--text); }
.site-nav__link:hover .site-nav__idx { color: var(--cyan); }
.site-nav__link:hover::after { transform: scaleX(1); }

.site-nav__link[aria-current="page"] { color: var(--cyan); }
.site-nav__link[aria-current="page"] .site-nav__idx { color: var(--cyan); }
.site-nav__link[aria-current="page"]::after { transform: scaleX(1); }

/* ---------- 7 搜索面板 ---------- */
.header-search {
  position: absolute;
  top: 100%;
  left: 0; right: 0;
  background: rgba(9, 26, 22, 0.98);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.header-search[hidden] { display: none; }

.header-search__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px 28px;
  padding: 16px 0 20px;
}

.header-search__hint {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  line-height: 1.7;
  letter-spacing: 0.06em;
  color: var(--muted);
  max-width: 60ch;
}

.header-search__links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.header-search__links a {
  display: inline-block;
  padding: 9px 14px;
  border: 1px solid var(--line);
  font-size: 13px;
  color: var(--text);
  transition: border-color 120ms linear, color 120ms linear;
}

.header-search__links a:hover { border-color: var(--cyan); color: var(--cyan); }

/* ---------- 8 进度条 ---------- */
.header-progress {
  position: absolute;
  left: 0; bottom: -1px;
  width: 100%;
  height: 2px;
  transform: scaleX(0);
  transform-origin: left center;
  background: linear-gradient(90deg, var(--cyan), var(--cyan-soft) 60%, var(--amber));
  will-change: transform;
}

/* ---------- 9 通用组件 ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 13px 22px;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--text);
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 600;
  line-height: 1;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  transition: border-color 120ms linear, color 120ms linear, background-color 120ms linear;
}

.btn:hover { border-color: var(--cyan); color: var(--cyan); }

.btn--primary {
  background: var(--cyan);
  border-color: var(--cyan);
  color: var(--ink);
}
.btn--primary:hover { background: var(--cyan-soft); border-color: var(--cyan-soft); color: var(--ink); }

.btn--amber { border-color: var(--amber); color: var(--amber); }
.btn--amber:hover { background: var(--amber); border-color: var(--amber); color: var(--ink); }

.btn--block { width: 100%; }

.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 500;
  line-height: 1.6;
  letter-spacing: 0.08em;
  color: var(--cyan);
  border-bottom: 1px solid transparent;
  transition: border-color 120ms linear;
}

.link-arrow::after {
  content: "→";
  transition: transform 180ms var(--ease);
}

.link-arrow:hover { border-bottom-color: var(--cyan); }
.link-arrow:hover::after { transform: translateX(4px); }

.crumbs {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  line-height: 1.6;
  letter-spacing: 0.08em;
  color: var(--muted);
}

.crumbs ol { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.crumbs li + li::before { content: "/"; margin-right: 8px; color: var(--line); }
.crumbs a:hover { color: var(--cyan); }
.crumbs [aria-current="page"] { color: var(--text); }

.section-label {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 10px 14px;
  margin-bottom: 28px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
}

.section-label__no {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.18em;
  color: var(--cyan);
}

.section-label__name {
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text);
}

.section-label__meta {
  margin-left: auto;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  line-height: 1.6;
  letter-spacing: 0.08em;
  color: var(--muted);
}

.panel {
  padding: 22px;
  background: var(--panel);
  border: 1px solid var(--line);
}

.panel--inset { background: var(--panel-2); }

.panel__title {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 600;
  letter-spacing: 0.06em;
}

.panel__meta {
  margin-top: 6px;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  line-height: 1.6;
  letter-spacing: 0.08em;
  color: var(--muted);
}

.stat { display: flex; flex-direction: column; gap: 6px; }

.stat__num {
  font-family: var(--font-mono);
  font-size: clamp(24px, 3vw, 32px);
  font-weight: 600;
  line-height: 1;
  color: var(--cyan);
  font-variant-numeric: tabular-nums;
}

.stat__num--amber { color: var(--amber); }

.stat__lab {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  line-height: 1.5;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
}

.tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 9px;
  border: 1px solid var(--line);
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  line-height: 1;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
}

.tag--cyan { border-color: rgba(43, 232, 200, 0.45); color: var(--cyan); }
.tag--amber { border-color: rgba(255, 138, 61, 0.5); color: var(--amber); }

.data-table-wrap {
  overflow-x: auto;
  background: var(--panel);
  border: 1px solid var(--line);
}

.data-table { font-size: 14px; min-width: 520px; }

.data-table th,
.data-table td {
  padding: 12px 14px;
  border-bottom: 1px solid var(--line-soft);
  text-align: left;
  vertical-align: middle;
}

.data-table thead th {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  line-height: 1.4;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
  border-bottom-color: var(--line);
}

.data-table tbody tr:nth-child(even) { background: var(--panel-2); }
.data-table tbody tr:last-child td { border-bottom: 0; }

.data-table .num {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  text-align: right;
  color: var(--text);
}

.data-table thead th.num { color: var(--muted); }

/* 图片容器基础规则 */
.media-frame {
  position: relative;
  display: block;
  width: 100%;
  overflow: hidden;
  border: 1px solid var(--line);
  background-color: var(--panel);
  background-image:
    linear-gradient(rgba(58, 90, 80, 0.22) 1px, transparent 1px),
    linear-gradient(90deg, rgba(58, 90, 80, 0.22) 1px, transparent 1px);
  background-size: 32px 32px;
}

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

.media-frame::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(120% 90% at 18% 0%, rgba(43, 232, 200, 0.1), transparent 62%);
  pointer-events: none;
}

.media-frame--16x9 { aspect-ratio: 16 / 9; }
.media-frame--4x3 { aspect-ratio: 4 / 3; }
.media-frame--1x1 { aspect-ratio: 1 / 1; }
.media-frame--tall { aspect-ratio: 3 / 4; }

.media-frame__caption {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  padding: 22px 14px 10px;
  background: linear-gradient(180deg, transparent, rgba(7, 22, 18, 0.92));
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  line-height: 1.5;
  letter-spacing: 0.08em;
  color: var(--muted);
}

.media-frame__tag {
  position: absolute;
  top: 12px;
  left: 12px;
}

.figure-note {
  margin-top: 10px;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  line-height: 1.6;
  letter-spacing: 0.06em;
  color: var(--muted);
}

[data-reveal] {
  opacity: 0;
  transform: translateY(12px);
  transition: opacity var(--dur) var(--ease), transform var(--dur) var(--ease);
  transition-delay: var(--reveal-delay, 0ms);
}

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

/* ---------- 10 页脚 ---------- */
.site-footer {
  position: relative;
  overflow: hidden;
  margin-top: 96px;
  border-top: 1px solid var(--line);
  background: linear-gradient(180deg, #0A1F1A 0%, var(--ink) 72%);
  color: var(--text);
}

.site-footer::before {
  content: "";
  position: absolute;
  top: 0; left: 0;
  width: min(560px, 62%);
  height: 1px;
  background: linear-gradient(90deg, var(--cyan), transparent);
}

.site-footer::after {
  content: "";
  position: absolute;
  top: 0; left: 0;
  width: 540px;
  height: 220px;
  background: radial-gradient(62% 100% at 0% 0%, rgba(43, 232, 200, 0.12), transparent 72%);
  pointer-events: none;
}

.footer-top {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 2fr);
  gap: 48px;
  padding: 56px 0 40px;
}

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

.footer-brand__name {
  font-family: var(--font-display);
  font-size: 28px;
  font-weight: 600;
  letter-spacing: 0.04em;
  max-width: none;
}

.footer-brand__sub {
  margin-top: 8px;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--cyan);
  max-width: none;
}

.footer-brand__summary {
  margin-top: 18px;
  font-size: 15px;
  line-height: 1.85;
  color: var(--muted);
}

.footer-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 28px;
  margin-top: 24px;
  padding-top: 18px;
  border-top: 1px solid var(--line-soft);
}

.footer-stats__num {
  display: block;
  font-family: var(--font-mono);
  font-size: 24px;
  font-weight: 600;
  line-height: 1;
  color: var(--text);
  font-variant-numeric: tabular-nums;
}

.footer-stats__lab {
  display: block;
  margin-top: 8px;
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 500;
  line-height: 1;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
}

.footer-cols {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 32px;
}

.footer-col__title {
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 600;
  line-height: 1;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text);
}

.footer-col__list li + li { margin-top: 2px; }

.footer-col__list a {
  display: inline-block;
  padding: 6px 0;
  font-size: 14px;
  line-height: 1.65;
  color: var(--muted);
  transition: color 120ms linear;
}

.footer-col__list a::before {
  content: "—";
  margin-right: 8px;
  color: var(--line);
}

.footer-col__list a:hover { color: var(--cyan); }

.footer-col__note {
  margin-top: 16px;
  font-size: 13px;
  line-height: 1.75;
  color: var(--muted);
  max-width: 40ch;
}

.contact-list li + li { margin-top: 10px; }

.copy-chip {
  display: flex;
  flex-direction: column;
  gap: 6px;
  align-items: flex-start;
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--line-soft);
  text-align: left;
  transition: border-color 120ms linear, background-color 120ms linear;
}

.copy-chip:hover { border-color: var(--cyan); }

.copy-chip[data-copied="true"] {
  border-color: var(--cyan);
  background: rgba(43, 232, 200, 0.08);
}

.copy-chip__key {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 500;
  line-height: 1;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--muted);
}

.copy-chip__val {
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 500;
  line-height: 1.5;
  color: var(--text);
  word-break: break-all;
}

.copy-status {
  min-height: 20px;
  margin-top: 12px;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  line-height: 1.6;
  letter-spacing: 0.08em;
  color: var(--cyan);
  max-width: none;
}

.footer-bottom {
  position: relative;
  z-index: 1;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px 28px;
  padding: 22px 0 34px;
  border-top: 1px solid var(--line);
}

.footer-legal {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  line-height: 1.7;
  letter-spacing: 0.06em;
  color: var(--muted);
  max-width: none;
}

.footer-legal__links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 22px;
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  line-height: 1.7;
  letter-spacing: 0.06em;
}

.footer-legal__links a {
  color: var(--muted);
  border-bottom: 1px solid transparent;
  transition: color 120ms linear, border-color 120ms linear;
}

.footer-legal__links a:hover {
  color: var(--cyan);
  border-bottom-color: var(--cyan);
}

/* ---------- 11 响应式 ---------- */
@media (max-width: 1120px) {
  .site-nav__link { padding: 10px 9px; font-size: 13px; }
  .site-nav__link::after { left: 9px; right: 9px; }
}

@media (max-width: 1000px) {
  .footer-top { grid-template-columns: 1fr; gap: 36px; }
  .footer-cols { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 980px) {
  :root { --gutter: 20px; }

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

  .site-nav {
    position: absolute;
    top: 100%;
    left: 0; right: 0;
    max-height: 80vh;
    overflow-y: auto;
    padding: 8px var(--gutter) 20px;
    background: rgba(7, 22, 18, 0.99);
    border-top: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: opacity 220ms var(--ease), transform 220ms var(--ease), visibility 220ms linear;
  }

  .site-nav[data-open] {
    opacity: 1;
    visibility: visible;
    transform: none;
  }

  .site-nav__list {
    flex-direction: column;
    align-items: stretch;
    gap: 0;
  }

  .site-nav__link {
    padding: 15px 4px;
    font-size: 16px;
    border-bottom: 1px solid var(--line-soft);
  }

  .site-nav__link::after { display: none; }
  .site-nav__idx { font-size: 11px; }

  .grid--2,
  .grid--3,
  .grid--sidebar { grid-template-columns: 1fr; }

  .header-bar__inner { min-height: 62px; }
  .header-rail__inner { min-height: 32px; }

  .section-label__meta { margin-left: 0; }
}

@media (max-width: 860px) {
  .header-rail__motto { display: none; }
  .tool-ver { display: none; }
  .header-rail__tools { width: 100%; justify-content: flex-end; }
}

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

  .footer-cols { grid-template-columns: 1fr; gap: 28px; }
  .footer-top { padding: 40px 0 28px; }
  .footer-brand__name { font-size: 24px; }
  .footer-bottom { padding: 18px 0 28px; }
  .site-footer { margin-top: 64px; }

  .btn { width: 100%; }
  .btn--inline { width: auto; }
}

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

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

  [data-reveal] {
    opacity: 1 !important;
    transform: none !important;
    transition-delay: 0ms !important;
  }

  .header-progress { display: none; }
}
