/* =========================================================
   必一赛场 · 共享站点样式 /assets/site.css
   数据舱 v3.4 — 深夜球场配色 · 锐利直角 · 1px 精密网格
   ========================================================= */

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

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

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

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

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

button, input, select, textarea { font: inherit; color: inherit; }

button { background: none; border: 0; cursor: pointer; }

a { color: inherit; }

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

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

/* ---------- 2. 变量 ---------- */
:root {
  --bg: #08150F;
  --surface: #0F211B;
  --surface-2: #142A22;
  --line: #2C4740;
  --ink: #EEF5F1;
  --lime: #C8FF4D;
  --lime-soft: #D9FF7B;
  --orange: #FF6A2B;
  --amber: #FFC85C;
  --muted: #7FA79A;
  --teal: #0B2B33;
  --heat: #3E7F55;

  --rail: 96px;
  --masthead-h: 76px;
  --dock-h: 0px;
  --maxw: 1360px;
  --pad: clamp(16px, 3vw, 40px);

  --mono: ui-monospace, "SFMono-Regular", "JetBrains Mono", "Roboto Mono", Menlo, Consolas, "Liberation Mono", monospace;
  --sans: "Noto Sans SC", "Source Han Sans SC", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", system-ui, -apple-system, "Segoe UI", sans-serif;

  --ease: cubic-bezier(.2, .7, .2, 1);
}

/* ---------- 3. 基础排版 ---------- */
body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  font-weight: 400;
  line-height: 1.75;
  min-height: 100vh;
  padding-top: var(--masthead-h);
  padding-left: var(--rail);
  padding-bottom: var(--dock-h);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3, h4 {
  font-weight: 900;
  line-height: 1.14;
  letter-spacing: -0.02em;
}

h1 { font-size: clamp(34px, 5.4vw, 66px); }
h2 { font-size: clamp(24px, 3vw, 38px); }
h3 { font-size: clamp(17px, 1.5vw, 21px); font-weight: 700; letter-spacing: 0; }
h4 { font-size: 15px; font-weight: 700; letter-spacing: 0; }

.num,
.mono {
  font-family: var(--mono);
  font-variant-numeric: tabular-nums;
  font-feature-settings: "tnum" 1;
  letter-spacing: -0.01em;
}

.muted { color: var(--muted); }
.lime { color: var(--lime); }
.orange { color: var(--orange); }
.amber { color: var(--amber); }

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

.lead {
  font-size: clamp(17px, 1.5vw, 20px);
  line-height: 1.7;
  max-width: 62ch;
}

.prose { color: var(--ink); }
.prose p { max-width: 68ch; }
.prose p + p { margin-top: 1em; }
.prose h2 { margin-top: 1.6em; margin-bottom: 0.5em; }
.prose h3 { margin-top: 1.4em; margin-bottom: 0.4em; }
.prose ul { margin-top: 0.6em; }
.prose li { position: relative; padding-left: 18px; max-width: 66ch; }
.prose li + li { margin-top: 6px; }
.prose li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.72em;
  width: 7px;
  height: 1px;
  background: var(--lime);
}

/* ---------- 4. 布局工具 ---------- */
.wrap {
  width: 100%;
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: var(--pad);
}

.section { padding-block: clamp(48px, 7vw, 96px); }

.bleed { margin-left: calc(var(--rail) * -1); }

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

/* ---------- 5. 链接与按钮 ---------- */
.link {
  position: relative;
  color: var(--ink);
  text-decoration: none;
  padding-bottom: 2px;
  transition: color .16s var(--ease);
}
.link::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 1px;
  background: var(--lime);
  transform: scaleX(0);
  transform-origin: center;
  transition: transform .18s var(--ease);
}
.link:hover { color: var(--lime); }
.link:hover::after { transform: scaleX(1); }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 18px;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--ink);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.06em;
  line-height: 1.4;
  text-decoration: none;
  cursor: pointer;
  transition: background-color .16s var(--ease),
              color .16s var(--ease),
              border-color .16s var(--ease);
}
.btn:hover { border-color: var(--lime); color: var(--lime); }

.btn--accent {
  background: var(--lime);
  border-color: var(--lime);
  color: #08150F;
  font-weight: 700;
}
.btn--accent:hover {
  background: var(--lime-soft);
  border-color: var(--lime-soft);
  color: #08150F;
}

.btn--lg { padding: 14px 24px; font-size: 14px; }

/* ---------- 6. 头部：刊头 + 数据轨道 ---------- */
.site-header { position: relative; z-index: 70; }

.skip-link {
  position: fixed;
  top: 8px;
  left: calc(var(--rail) + 8px);
  z-index: 200;
  padding: 10px 16px;
  background: var(--lime);
  color: #08150F;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-decoration: none;
  transform: translateY(-200%);
  transition: transform .16s var(--ease);
}
.skip-link:focus { transform: translateY(0); }

.masthead {
  position: fixed;
  top: 0;
  left: var(--rail);
  right: 0;
  height: var(--masthead-h);
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 16px;
  padding-inline: var(--pad);
  background: rgba(8, 21, 15, .94);
  border-bottom: 1px solid var(--line);
  z-index: 70;
}

.masthead__edition {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.14em;
  color: var(--muted);
  white-space: nowrap;
}

.brand {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  text-decoration: none;
  color: var(--ink);
  transition: color .16s var(--ease);
}
.brand:hover { color: var(--lime); }

.brand__mark {
  font-size: 22px;
  font-weight: 900;
  letter-spacing: 0.14em;
  line-height: 1.1;
}

.brand__sub {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.28em;
  color: var(--muted);
  transition: color .16s var(--ease);
}
.brand:hover .brand__sub { color: var(--lime); }

.masthead__slot {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 20px;
}

.util-link {
  position: relative;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.08em;
  color: var(--muted);
  text-decoration: none;
  padding-bottom: 3px;
  transition: color .16s var(--ease);
}
.util-link::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 1px;
  background: var(--lime);
  transform: scaleX(0);
  transform-origin: center;
  transition: transform .18s var(--ease);
}
.util-link:hover { color: var(--lime); }
.util-link:hover::after { transform: scaleX(1); }

/* 左侧竖向数据轨道 */
.rail {
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  width: var(--rail);
  display: flex;
  flex-direction: column;
  background: var(--bg);
  border-right: 1px solid var(--line);
  z-index: 80;
}

.rail__tag {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  writing-mode: vertical-rl;
  padding-top: 20px;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.34em;
  color: var(--line);
  pointer-events: none;
  user-select: none;
}

.rail__list {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  padding: 88px 0 24px;
}

.rail__item {
  flex: 1 1 0;
  min-height: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.rail__link {
  position: relative;
  display: block;
  max-height: 100%;
  padding: 14px 0;
  writing-mode: vertical-rl;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.18em;
  color: var(--muted);
  text-decoration: none;
  transition: color .16s var(--ease);
}
.rail__link::before {
  content: "";
  position: absolute;
  top: 6px;
  bottom: 6px;
  left: -22px;
  width: 3px;
  background: var(--lime);
  transform: scaleY(0);
  transform-origin: top;
  transition: transform .18s var(--ease);
}
.rail__link:hover { color: var(--lime); }
.rail__link:hover::before,
.rail__link[aria-current="page"]::before { transform: scaleY(1); }
.rail__link[aria-current="page"] {
  color: var(--lime);
  font-weight: 700;
}

.rail__meter {
  position: absolute;
  left: 0;
  top: 0;
  width: 3px;
  height: 0;
  background: var(--lime);
}

/* 移动端底部状态栏 */
.dock {
  display: none;
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  height: var(--dock-h);
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-inline: 16px;
  background: var(--bg);
  border-top: 1px solid var(--line);
  z-index: 95;
}

.dock__status {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  color: var(--muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.dock__toggle {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 8px 12px;
  border: 1px solid var(--line);
  color: var(--lime);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.1em;
  transition: border-color .16s var(--ease), background-color .16s var(--ease);
}
.dock__toggle:hover { border-color: var(--lime); }

.dock__bars {
  position: relative;
  display: inline-block;
  width: 16px;
  height: 10px;
}
.dock__bars::before,
.dock__bars::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  height: 1.5px;
  background: currentColor;
  transition: transform .18s var(--ease), top .18s var(--ease), bottom .18s var(--ease);
}
.dock__bars::before { top: 0; }
.dock__bars::after { bottom: 0; }
.dock__toggle[aria-expanded="true"] .dock__bars::before {
  top: 4px;
  transform: rotate(45deg);
}
.dock__toggle[aria-expanded="true"] .dock__bars::after {
  bottom: 4px;
  transform: rotate(-45deg);
}

/* ---------- 7. 页脚：状态栏式信息带 ---------- */
.site-footer {
  margin-top: clamp(64px, 8vw, 120px);
  border-top: 1px solid var(--line);
  background: var(--bg);
}

.footer-status {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 13px var(--pad);
  background: var(--teal);
  border-bottom: 1px solid var(--line);
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.12em;
  color: #B9DCD4;
}

.footer-status__dot {
  flex: none;
  width: 7px;
  height: 7px;
  background: var(--orange);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr;
  gap: 1px;
  background: var(--line);
  border-bottom: 1px solid var(--line);
}

.footer-grid__cell {
  background: var(--bg);
  padding: clamp(22px, 2.6vw, 36px);
}

.footer-brand__mark {
  font-size: 20px;
  font-weight: 900;
  letter-spacing: 0.14em;
  line-height: 1.2;
}

.footer-brand__sub {
  margin-top: 6px;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.24em;
  color: var(--muted);
}

.footer-brand__note {
  margin-top: 14px;
  max-width: 34ch;
  font-size: 13px;
  line-height: 1.7;
  color: var(--muted);
}

.footer-col__title {
  margin-bottom: 14px;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.08em;
  color: var(--muted);
}

.footer-col li + li { margin-top: 10px; }

.footer-col a {
  position: relative;
  display: inline-block;
  font-size: 14px;
  text-decoration: none;
  color: var(--ink);
  transition: color .16s var(--ease);
}
.footer-col a::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: -3px;
  height: 1px;
  background: var(--lime);
  transform: scaleX(0);
  transform-origin: center;
  transition: transform .18s var(--ease);
}
.footer-col a:hover { color: var(--lime); }
.footer-col a:hover::after { transform: scaleX(1); }

.footer-contact {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 28px;
  padding: 24px 0;
  border-bottom: 1px solid var(--line);
  font-size: 13px;
  line-height: 1.7;
  color: var(--muted);
}
.footer-contact__line { max-width: 100%; }
.footer-contact .mono { color: var(--ink); }

.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 24px;
  padding: 18px 0 30px;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  color: var(--muted);
}

/* ---------- 8. 通用内容组件 ---------- */
.grid {
  display: grid;
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
}

.grid__cell {
  background: var(--bg);
  padding: clamp(18px, 2.4vw, 30px);
}

.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)); }

.card {
  background: var(--surface);
  border: 1px solid var(--line);
  padding: clamp(18px, 2.4vw, 28px);
  transition: background-color .16s var(--ease), border-color .16s var(--ease);
}
.card:hover {
  background: var(--surface-2);
  border-color: var(--rail-hover, #3C6055);
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--muted);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.06em;
  line-height: 1.5;
  cursor: pointer;
  transition: color .16s var(--ease),
              border-color .16s var(--ease),
              background-color .16s var(--ease);
}
.chip:hover { color: var(--ink); border-color: var(--muted); }
.chip[aria-pressed="true"] {
  background: var(--lime);
  border-color: var(--lime);
  color: #08150F;
  font-weight: 700;
}

.badge {
  display: inline-block;
  padding: 3px 8px;
  border: 1px solid var(--line);
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  color: var(--amber);
}
.badge--signal {
  color: var(--orange);
  border-color: rgba(255, 106, 43, .55);
}

.stat__value {
  font-family: var(--mono);
  font-variant-numeric: tabular-nums;
  font-size: clamp(32px, 5vw, 64px);
  font-weight: 700;
  line-height: 1;
  letter-spacing: -0.02em;
  color: var(--lime);
}
.stat__unit {
  margin-left: 0.4em;
  font-size: 0.36em;
  font-weight: 500;
  color: var(--muted);
}
.stat__label {
  margin-top: 10px;
  font-size: 12px;
  letter-spacing: 0.08em;
  color: var(--muted);
}

.fold {
  border: 1px solid var(--line);
  background: var(--surface);
}
.fold + .fold { margin-top: -1px; }

.fold__summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 20px;
  font-size: 15px;
  font-weight: 500;
  line-height: 1.6;
  color: var(--ink);
  cursor: pointer;
  list-style: none;
  transition: color .16s var(--ease), background-color .16s var(--ease);
}
.fold__summary::-webkit-details-marker { display: none; }
.fold__summary::after {
  content: "+";
  flex: none;
  font-family: var(--mono);
  font-size: 16px;
  color: var(--lime);
}
.fold[open] .fold__summary::after { content: "–"; }
.fold__summary:hover { background: var(--surface-2); color: var(--lime); }

.fold__body {
  padding: 0 20px 20px;
  font-size: 14px;
  line-height: 1.7;
  color: var(--muted);
}
.fold[open] .fold__body { animation: fold-in .2s var(--ease) both; }

@keyframes fold-in {
  from { opacity: 0; transform: translateY(-4px); }
  to { opacity: 1; transform: none; }
}

.crumbs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  padding: 18px 0;
  font-size: 12px;
  letter-spacing: 0.06em;
  color: var(--muted);
}
.crumbs a {
  color: var(--muted);
  text-decoration: none;
  transition: color .16s var(--ease);
}
.crumbs a:hover { color: var(--lime); }
.crumbs__sep { color: var(--line); }
.crumbs [aria-current="page"] { color: var(--ink); }

/* 图片容器（页面阶段放置实际图片） */
.media {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--line);
  background:
    repeating-linear-gradient(0deg, rgba(44, 71, 64, .5) 0 1px, transparent 1px 24px),
    repeating-linear-gradient(90deg, rgba(44, 71, 64, .5) 0 1px, transparent 1px 24px),
    var(--teal);
  aspect-ratio: 16 / 9;
}
.media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(.92) contrast(1.05) brightness(.92);
}
.media--wide { aspect-ratio: 21 / 9; }
.media--tall { aspect-ratio: 4 / 5; }
.media--square { aspect-ratio: 1 / 1; }

.media__cap {
  display: block;
  margin-top: 10px;
  font-size: 12px;
  line-height: 1.6;
  color: var(--muted);
}

/* ---------- 9. 显现动效 ---------- */
[data-reveal] {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity .35s var(--ease), transform .35s var(--ease);
}
[data-reveal].is-in {
  opacity: 1;
  transform: none;
}

/* ---------- 10. 响应式 ---------- */
@media (max-width: 1080px) {
  .masthead { grid-template-columns: 1fr auto 1fr; }
  .util-link { display: none; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 900px) {
  :root {
    --rail: 0px;
    --masthead-h: 56px;
    --dock-h: 56px;
  }

  body {
    padding-left: 0;
    padding-bottom: var(--dock-h);
    font-size: 15px;
  }

  .masthead {
    left: 0;
    grid-template-columns: 1fr auto;
    gap: 12px;
    padding-inline: 16px;
  }

  .masthead__edition { display: none; }

  .brand { align-items: flex-start; }
  .brand__mark { font-size: 17px; letter-spacing: 0.1em; }
  .brand__sub { display: none; }

  .masthead__slot { gap: 12px; }
  .btn--accent { padding: 8px 12px; font-size: 12px; }

  .skip-link { left: 8px; }

  /* 轨道收为底部可上滑面板 */
  .rail {
    top: auto;
    left: 0;
    right: 0;
    bottom: var(--dock-h);
    width: 100%;
    max-height: 68vh;
    overflow-y: auto;
    border-right: 0;
    border-top: 1px solid var(--line);
    background: var(--surface);
    transform: translateY(110%);
    transition: transform .2s var(--ease);
  }
  .rail[data-open="true"] { transform: translateY(0); }

  .rail__tag { display: none; }

  .rail__list {
    flex-direction: row;
    flex-wrap: wrap;
    padding: 10px;
  }

  .rail__item {
    flex: 0 0 auto;
    display: block;
  }

  .rail__link {
    writing-mode: horizontal-tb;
    padding: 11px 14px;
    margin: 4px;
    border: 1px solid var(--line);
    font-size: 13px;
    letter-spacing: 0.1em;
  }
  .rail__link::before { display: none; }
  .rail__link:hover { border-color: var(--lime); }
  .rail__link[aria-current="page"] {
    border-color: var(--lime);
    background: rgba(200, 255, 77, .08);
  }

  .rail__meter { display: none; }

  .dock { display: flex; }

  .footer-grid { grid-template-columns: 1fr; }
  .footer-contact { flex-direction: column; gap: 6px; padding: 20px 0; }
  .footer-bottom { padding: 16px 0 24px; }
}

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

/* ---------- 11. 减少动态偏好 ---------- */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
  }
  [data-reveal] {
    opacity: 1 !important;
    transform: none !important;
  }
  .rail { transition: none; }
}
