/* ============================================================
   /assets/site.css — 买球网指南 共享外壳
   框架式坐标导航 · 堆叠画板 · 夜航网格
   ============================================================ */

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

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

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

ul, ol { list-style: none; }

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

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

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

/* ---------- 02. Tokens ---------- */
:root {
  --ink: #071A2F;
  --ink-2: #0C2947;
  --line: #1E4E6B;
  --orange: #FF7A1A;
  --jade: #3DBFA3;
  --warm: #F7F3EA;
  --mist: #B9C6D2;
  --amber: #F2B84B;
  --clay: #E0614E;
  --glass: #F7F3EA1F;
  --line-soft: rgba(247, 243, 234, 0.13);
  --line-strong: rgba(247, 243, 234, 0.26);

  --rail-w: 248px;
  --rail-h: 66px;
  --shell: 1180px;
  --pad: clamp(18px, 4vw, 48px);
  --grid-unit: 56px;

  --mono: "IBM Plex Mono", "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  --sans: "HarmonyOS Sans SC", "Noto Sans SC", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", system-ui, sans-serif;
}

/* ---------- 03. Base & 中文排版 ---------- */
html { scroll-behavior: smooth; }

body {
  min-height: 100vh;
  padding-top: var(--rail-h);
  padding-left: var(--rail-w);
  font-family: var(--sans);
  font-size: clamp(15px, 0.28vw + 14px, 17px);
  line-height: 1.72;
  color: var(--warm);
  background-color: var(--ink);
  background-image:
    radial-gradient(1100px 560px at 82% -8%, rgba(61, 191, 163, 0.10), transparent 68%),
    radial-gradient(900px 520px at 4% 108%, rgba(255, 122, 26, 0.10), transparent 70%),
    linear-gradient(to right, rgba(30, 78, 107, 0.32) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(30, 78, 107, 0.32) 1px, transparent 1px);
  background-size: auto, auto, var(--grid-unit) var(--grid-unit), var(--grid-unit) var(--grid-unit);
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--sans);
  font-weight: 800;
  line-height: 1.12;
  letter-spacing: -0.012em;
}

h1 { font-size: clamp(34px, 5.4vw, 66px); }
h2 { font-size: clamp(24px, 3.2vw, 34px); }
h3 { font-size: clamp(19px, 1.8vw, 24px); }

p { text-wrap: pretty; }

::selection { background: var(--orange); color: #150800; }

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

/* ---------- 04. 通用工具 ---------- */
.shell {
  width: 100%;
  max-width: var(--shell);
  margin-inline: auto;
  padding-inline: var(--pad);
}

.mono {
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.coord-no {
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--orange);
}

.kicker {
  display: inline-block;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--jade);
}

.prose { max-width: 68ch; color: rgba(247, 243, 234, 0.88); }
.prose p + p { margin-top: 1.05em; }

/* ---------- 05. 跳转链接 ---------- */
.skip-link {
  position: fixed;
  top: 8px;
  left: 8px;
  z-index: 240;
  padding: 10px 18px;
  font-size: 14px;
  font-weight: 700;
  color: #150800;
  background: var(--orange);
  border-radius: 3px;
  transform: translateY(-220%);
  transition: transform 160ms ease;
}

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

/* ---------- 06. 头部框架 ---------- */
.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 80;
}

.read-progress {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 2px;
  background: rgba(247, 243, 234, 0.09);
  pointer-events: none;
}

.read-progress__fill {
  display: block;
  height: 100%;
  width: 100%;
  background: linear-gradient(90deg, var(--jade), var(--orange));
  transform: scaleX(0);
  transform-origin: 0 50%;
  transition: transform 120ms linear;
}

.frame-top {
  position: relative;
  display: flex;
  align-items: stretch;
  height: var(--rail-h);
  background: rgba(7, 26, 47, 0.9);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line-soft);
}

/* 品牌块：与左侧导航轨同宽，构成直角边框 */
.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  flex: 0 0 auto;
  width: var(--rail-w);
  padding: 0 18px;
  border-right: 1px solid var(--line-soft);
  transition: background 200ms ease;
}

.brand:hover { background: rgba(61, 191, 163, 0.08); }

.brand__mark {
  position: relative;
  flex: 0 0 auto;
  width: 26px;
  height: 26px;
  border: 1px solid var(--orange);
  background-image:
    linear-gradient(to right, rgba(255, 122, 26, 0.45) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255, 122, 26, 0.45) 1px, transparent 1px);
  background-size: 8px 8px;
}

.brand__dot {
  position: absolute;
  right: -3px;
  bottom: -3px;
  width: 7px;
  height: 7px;
  background: var(--orange);
  box-shadow: 0 0 0 2px var(--ink);
}

.brand__text { display: flex; flex-direction: column; gap: 2px; min-width: 0; }

.brand__name {
  font-size: 16px;
  font-weight: 800;
  letter-spacing: 0.04em;
  color: var(--warm);
  white-space: nowrap;
}

.brand__tag {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.14em;
  color: var(--mist);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.top-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex: 1 1 auto;
  min-width: 0;
  padding: 0 18px 0 22px;
}

.top-meta__readout {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--mist);
  white-space: nowrap;
}

.top-meta__sep { color: var(--line); }

.status-chip {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 5px 10px;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.12em;
  color: var(--jade);
  border: 1px solid rgba(61, 191, 163, 0.42);
  border-radius: 2px;
  background: rgba(61, 191, 163, 0.08);
  white-space: nowrap;
}

.status-chip__dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--jade);
  animation: signal-pulse 2.6s ease-in-out infinite;
}

@keyframes signal-pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.35; transform: scale(0.82); }
}

.top-meta__actions {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-left: auto;
}

/* ---------- 07. 按钮 ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.02em;
  line-height: 1.2;
  border-radius: 2px;
  border: 1px solid transparent;
  transition: background 180ms ease, color 180ms ease, border-color 180ms ease, transform 180ms ease;
}

.btn--signal::after {
  content: "→";
  font-family: var(--mono);
  font-size: 13px;
  line-height: 1;
}

.btn--signal {
  background: var(--orange);
  border-color: var(--orange);
  color: #170900;
}

.btn--signal:hover { background: #ff8f3d; border-color: #ff8f3d; }

.btn--jade {
  background: var(--jade);
  border-color: var(--jade);
  color: #04211c;
}

.btn--jade:hover { background: #55cfb5; border-color: #55cfb5; }

.btn--ghost {
  color: var(--warm);
  border-color: var(--line-strong);
  background: rgba(247, 243, 234, 0.05);
}

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

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

/* ---------- 08. 移动导航开关 ---------- */
.nav-toggle {
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  border: 1px solid var(--line-strong);
  border-radius: 3px;
  background: rgba(247, 243, 234, 0.06);
  cursor: pointer;
}

.nav-toggle__bar {
  display: block;
  width: 18px;
  height: 2px;
  background: var(--warm);
  transition: transform 180ms ease, opacity 180ms ease;
}

.nav-toggle[aria-expanded="true"] { border-color: var(--orange); }

.nav-toggle[aria-expanded="true"] .nav-toggle__bar:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle__bar:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] .nav-toggle__bar:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- 09. 坐标导航轨 ---------- */
.frame-nav {
  position: fixed;
  top: var(--rail-h);
  left: 0;
  bottom: 0;
  z-index: 70;
  display: flex;
  flex-direction: column;
  width: var(--rail-w);
  padding: 22px 0 20px;
  overflow-y: auto;
  overscroll-behavior: contain;
  background:
    linear-gradient(180deg, rgba(12, 41, 71, 0.94), rgba(7, 26, 47, 0.97));
  border-right: 1px solid var(--line-soft);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
}

.frame-nav__label {
  padding: 0 20px 14px;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--mist);
}

.frame-nav__list { display: flex; flex-direction: column; }

.nav-link {
  position: relative;
  display: grid;
  grid-template-columns: 30px 1fr;
  align-items: center;
  gap: 10px;
  padding: 12px 20px;
  font-size: 15px;
  color: rgba(247, 243, 234, 0.8);
  border-left: 2px solid transparent;
  transition: background 200ms ease, color 200ms ease, border-color 200ms ease;
}

.nav-link__no {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  color: rgba(185, 198, 210, 0.72);
  transition: color 200ms ease;
}

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

.nav-link:hover,
.nav-link:focus-visible {
  color: var(--warm);
  background: rgba(61, 191, 163, 0.12);
  border-left-color: var(--jade);
}

.nav-link:hover .nav-link__no,
.nav-link:focus-visible .nav-link__no { color: var(--jade); }

.nav-link[aria-current="page"] {
  color: var(--warm);
  font-weight: 700;
  border-left-color: var(--orange);
  background: linear-gradient(90deg, rgba(255, 122, 26, 0.2), rgba(255, 122, 26, 0));
  box-shadow: inset 0 0 0 1px rgba(255, 122, 26, 0.22);
}

.nav-link[aria-current="page"] .nav-link__no { color: var(--orange); }

.frame-nav__foot {
  margin-top: auto;
  padding: 18px 20px 0;
  border-top: 1px solid var(--line-soft);
}

.frame-nav__stamp {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.16em;
  line-height: 1.9;
  color: rgba(185, 198, 210, 0.6);
}

.rail-spine {
  position: absolute;
  top: 34%;
  right: 7px;
  writing-mode: vertical-rl;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.42em;
  color: rgba(185, 198, 210, 0.34);
  pointer-events: none;
}

.nav-scrim {
  position: fixed;
  inset: var(--rail-h) 0 0 0;
  z-index: 65;
  background: rgba(4, 14, 26, 0.62);
  opacity: 0;
  pointer-events: none;
  transition: opacity 200ms ease;
}

/* ---------- 10. 页脚 ---------- */
.site-footer {
  margin-top: clamp(56px, 8vw, 104px);
  border-top: 1px solid var(--line-soft);
  background: linear-gradient(180deg, rgba(12, 41, 71, 0.72), rgba(7, 26, 47, 0.98));
}

.footer-panel {
  background-image:
    linear-gradient(to right, rgba(30, 78, 107, 0.22) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(30, 78, 107, 0.22) 1px, transparent 1px);
  background-size: 56px 56px;
}

.footer-top {
  display: grid;
  grid-template-columns: minmax(240px, 1fr) minmax(0, 2.15fr);
  gap: clamp(26px, 4vw, 56px);
  padding-block: clamp(36px, 5.4vw, 64px);
}

.footer-brand { display: flex; flex-direction: column; gap: 12px; }

.footer-brand__line {
  font-size: clamp(17px, 1.5vw, 20px);
  font-weight: 800;
  color: var(--warm);
  letter-spacing: 0.01em;
}

.footer-brand__intro {
  font-size: 14px;
  line-height: 1.7;
  color: var(--mist);
  max-width: 34ch;
}

.footer-mono {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(185, 198, 210, 0.66);
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(20px, 3vw, 40px);
}

.footer-col { display: flex; flex-direction: column; gap: 12px; min-width: 0; }

.footer-col__title {
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--jade);
  padding-bottom: 10px;
  border-bottom: 1px solid var(--line-soft);
}

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

.footer-link {
  position: relative;
  display: inline-block;
  font-size: 14px;
  color: rgba(247, 243, 234, 0.82);
  padding-left: 14px;
  transition: color 180ms ease, padding-left 180ms ease;
}

.footer-link::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.72em;
  width: 6px;
  height: 1px;
  background: var(--line);
  transition: background 180ms ease, width 180ms ease;
}

.footer-link:hover {
  color: var(--orange);
  padding-left: 18px;
}

.footer-link:hover::before { background: var(--orange); width: 10px; }

.contact-line {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding-bottom: 8px;
  border-bottom: 1px dashed rgba(30, 78, 107, 0.7);
}

.contact-line__k {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(185, 198, 210, 0.7);
}

.contact-line__v {
  font-size: 13.5px;
  line-height: 1.55;
  color: var(--warm);
  word-break: break-word;
}

.footer-note {
  font-size: 12px;
  line-height: 1.65;
  color: rgba(185, 198, 210, 0.72);
}

.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  padding-block: 20px;
  border-top: 1px solid var(--line-soft);
}

.footer-icp {
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.1em;
  color: var(--mist);
}

/* ---------- 11. 页面基础组件（供页面阶段复用） ---------- */
.panel {
  position: relative;
  padding: clamp(18px, 2.4vw, 28px);
  border: 1px solid var(--line-soft);
  border-radius: 4px;
  background: linear-gradient(160deg, rgba(12, 41, 71, 0.94), rgba(7, 26, 47, 0.88));
}

.panel--glass {
  background: var(--glass);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  border-color: var(--line-strong);
}

.tag {
  display: inline-block;
  padding: 5px 8px;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  border: 1px solid currentColor;
  border-radius: 2px;
  color: var(--mist);
}

.tag--jade { color: var(--jade); }
.tag--amber { color: var(--amber); }
.tag--clay { color: var(--clay); }

.crumbs {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.12em;
  color: rgba(185, 198, 210, 0.7);
}

.crumbs li { display: inline-flex; align-items: center; gap: 8px; }
.crumbs li + li::before { content: "/"; color: var(--line); }
.crumbs a { color: var(--mist); transition: color 180ms ease; }
.crumbs a:hover { color: var(--orange); }
.crumbs [aria-current="page"] { color: var(--warm); }

.media-frame {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16 / 10;
  border: 1px solid var(--line-soft);
  border-radius: 4px;
  background: linear-gradient(160deg, rgba(12, 41, 71, 0.92), rgba(7, 26, 47, 0.96));
}

.media-frame::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  background-image:
    linear-gradient(to right, rgba(30, 78, 107, 0.5) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(30, 78, 107, 0.5) 1px, transparent 1px);
  background-size: 32px 32px;
  opacity: 0.45;
}

.media-frame img {
  position: relative;
  z-index: 1;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(0.85) brightness(0.92);
}

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

.media-frame__caption {
  position: absolute;
  left: 0;
  bottom: 0;
  z-index: 3;
  padding: 8px 12px;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--mist);
  background: rgba(7, 26, 47, 0.82);
  border-top: 1px solid var(--line-soft);
  border-right: 1px solid var(--line-soft);
}

/* ---------- 12. 显现 ---------- */
[data-reveal] {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 460ms ease, transform 460ms ease;
}

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

/* ---------- 13. 响应式 ---------- */
@media (max-width: 1180px) {
  :root { --rail-w: 214px; }
}

@media (max-width: 1023px) {
  body {
    padding-left: 0;
    background-size: auto, auto, 44px 44px, 44px 44px;
  }

  .brand {
    width: auto;
    flex: 1 1 auto;
    border-right: 0;
    padding-inline: 16px;
  }

  .top-meta {
    flex: 0 0 auto;
    padding: 0 12px 0 0;
    gap: 10px;
  }

  .top-meta__readout,
  .status-chip { display: none; }

  .nav-toggle { display: flex; }

  .frame-nav {
    width: min(320px, 86vw);
    transform: translateX(-104%);
    transition: transform 220ms ease;
    box-shadow: 24px 0 60px rgba(2, 9, 18, 0.55);
    z-index: 78;
  }

  .frame-nav[data-open="true"] { transform: translateX(0); }

  .site-header[data-open="true"] .nav-scrim {
    opacity: 1;
    pointer-events: auto;
  }

  body.is-nav-open { overflow: hidden; }

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

  .rail-spine { display: none; }
}

@media (max-width: 760px) {
  .brand__tag { display: none; }

  .btn--signal { padding: 9px 12px; font-size: 13px; }

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

  .footer-col:last-child { grid-column: 1 / -1; }

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

@media (max-width: 480px) {
  .footer-grid { grid-template-columns: 1fr; }
  .footer-col:last-child { grid-column: auto; }
  .brand__name { font-size: 15px; }
}

/* ---------- 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;
  }

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

  .read-progress__fill { transition: none; }
}
