/* ============================================================
   买球网中心 · 共享样式表 /assets/site.css
   夜场赛点指挥中心：夜墨绿底 + 电光青轨迹 + 高亮橙赛点
   ============================================================ */

/* ---------- 1. 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, picture, svg, video { display: block; max-width: 100%; }
button, input, select, textarea { font: inherit; color: inherit; }
button { background: none; border: 0; }
a { color: var(--c-cyan); text-underline-offset: 0.22em; text-decoration-thickness: 1px; }
table { border-collapse: collapse; width: 100%; }
[hidden] { display: none !important; }

/* ---------- 2. 变量 ---------- */
:root {
  --c-ink: #06251F;
  --c-deep: #0C3A31;
  --c-mist: #12483D;
  --c-cyan: #2FE3D0;
  --c-cyan-soft: #8DF5EA;
  --c-orange: #FF7A29;
  --c-sand: #FFC08A;
  --c-paper: #F3EEE4;
  --c-fog: #E7EFEC;
  --c-graphite: #A9BBB6;
  --c-alert: #FF5C57;

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

  --fs-display: clamp(2.75rem, 6.2vw, 4rem);
  --fs-h1: clamp(2.125rem, 5vw, 3rem);
  --fs-h2: clamp(1.625rem, 3.2vw, 2.375rem);
  --fs-h3: clamp(1.25rem, 2vw, 1.625rem);
  --fs-lg: 1.25rem;
  --fs-md: 1.0625rem;
  --fs-sm: 0.9375rem;
  --fs-xs: 0.8125rem;

  --gutter: clamp(16px, 3vw, 40px);
  --maxw: 1280px;
  --cut: 18px;
  --cut-sm: 10px;
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
  --dur: 0.18s;
}

/* ---------- 3. 中文排版基线 ---------- */
body {
  min-height: 100vh;
  background: var(--c-ink);
  color: var(--c-fog);
  font-family: var(--font-sans);
  font-size: var(--fs-md);
  font-weight: 400;
  line-height: 1.75;
  letter-spacing: 0.01em;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3, h4 {
  font-weight: 900;
  line-height: 1.18;
  letter-spacing: -0.02em;
  color: inherit;
}
h1 { font-size: var(--fs-h1); }
h2 { font-size: var(--fs-h2); }
h3 { font-size: var(--fs-h3); }

p { max-width: 68ch; }
.lede { font-size: var(--fs-lg); line-height: 1.7; color: var(--c-cyan-soft); max-width: 56ch; }
.mono { font-family: var(--font-mono); font-weight: 600; letter-spacing: 0.02em; }

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

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

/* ---------- 4. 跳转链接 ---------- */
.skip-link {
  position: absolute;
  left: 16px;
  top: -120px;
  z-index: 200;
  padding: 12px 20px;
  background: var(--c-orange);
  color: #2A1004;
  font-weight: 800;
  font-size: var(--fs-sm);
  text-decoration: none;
  transition: top var(--dur) var(--ease);
}
.skip-link:focus { top: 12px; }

/* ---------- 5. 页头 / 框架 ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 90;
  background: linear-gradient(180deg, rgba(6, 37, 31, 0.99), rgba(6, 37, 31, 0.93));
  border-bottom: 1px solid rgba(47, 227, 208, 0.28);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
}

.header-bar {
  max-width: var(--maxw);
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, auto) minmax(0, 1fr) auto;
  align-items: center;
  gap: clamp(12px, 2vw, 28px);
  padding: 12px var(--gutter);
}

.site-header[data-open="true"] { border-bottom-color: var(--c-cyan); }

/* 品牌锁定 */
.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
  text-decoration: none;
  color: inherit;
}
.brand-mark {
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  background: var(--c-cyan);
  color: var(--c-ink);
  font-family: var(--font-mono);
  font-size: 0.875rem;
  font-weight: 700;
  letter-spacing: 0.06em;
}
.brand-text { display: flex; flex-direction: column; min-width: 0; line-height: 1.25; }
.brand-name {
  font-size: var(--fs-md);
  font-weight: 900;
  letter-spacing: -0.02em;
  color: var(--c-fog);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.brand-tag {
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  letter-spacing: 0.14em;
  color: var(--c-cyan);
  white-space: nowrap;
}
.brand:hover .brand-name { color: var(--c-cyan-soft); }

/* 主导航 —— 与刻度线共同构成页面边框 */
.site-nav { justify-self: center; min-width: 0; }
.nav-list { display: flex; align-items: center; gap: 2px; }
.nav-list > li { display: block; }
.nav-list a {
  position: relative;
  display: block;
  padding: 10px 14px;
  color: var(--c-fog);
  font-size: var(--fs-sm);
  font-weight: 700;
  letter-spacing: 0.02em;
  text-decoration: none;
  transition: color var(--dur) var(--ease), background var(--dur) var(--ease);
}
.nav-list a::after {
  content: "";
  position: absolute;
  left: 14px;
  right: 14px;
  bottom: 3px;
  height: 2px;
  background: var(--c-cyan);
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform var(--dur) var(--ease);
}
.nav-list a:hover { color: var(--c-cyan-soft); }
.nav-list a:hover::after,
.nav-list a:focus-visible::after { transform: scaleX(1); }
.nav-list a[aria-current="page"] {
  background: var(--c-cyan);
  color: var(--c-ink);
}
.nav-list a[aria-current="page"]::after { display: none; }

/* 工具区 */
.header-tools { display: flex; align-items: center; gap: 8px; }

/* ---------- 6. 按钮 ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 18px;
  border: 1px solid transparent;
  background: transparent;
  color: var(--c-fog);
  font-family: var(--font-sans);
  font-size: var(--fs-sm);
  font-weight: 700;
  line-height: 1;
  letter-spacing: 0.02em;
  text-decoration: none;
  cursor: pointer;
  white-space: nowrap;
  transition: background var(--dur) var(--ease), color var(--dur) var(--ease),
              border-color var(--dur) var(--ease), transform var(--dur) var(--ease);
}
.btn--accent { background: var(--c-orange); color: #2A1004; }
.btn--accent:hover { background: var(--c-sand); transform: translateY(-2px); }
.btn--ghost { border-color: rgba(47, 227, 208, 0.5); color: var(--c-cyan-soft); }
.btn--ghost:hover { background: rgba(47, 227, 208, 0.14); color: var(--c-cyan); }
.btn--quiet { padding: 12px 12px; color: var(--c-graphite); }
.btn--quiet:hover { color: var(--c-cyan-soft); }

/* 移动端菜单按钮 */
.nav-toggle {
  display: none;
  align-items: center;
  gap: 10px;
  padding: 11px 14px;
  border: 1px solid rgba(47, 227, 208, 0.5);
  color: var(--c-cyan-soft);
  font-size: var(--fs-sm);
  font-weight: 700;
  cursor: pointer;
}
.nav-toggle-bars { display: grid; gap: 5px; width: 18px; }
.nav-toggle-bars i { display: block; height: 2px; background: currentColor; transition: transform var(--dur) var(--ease); }
.nav-toggle[aria-expanded="true"] { background: var(--c-cyan); border-color: var(--c-cyan); color: var(--c-ink); }
.nav-toggle[aria-expanded="true"] .nav-toggle-bars i:first-child { transform: translateY(3.5px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle-bars i:last-child { transform: translateY(-3.5px) rotate(-45deg); }

/* 滚动进度刻度 */
.scroll-progress {
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  height: 2px;
  background: linear-gradient(90deg, var(--c-cyan), var(--c-orange));
  transform: scaleX(0);
  transform-origin: left center;
}

/* ---------- 7. 通用布局 ---------- */
.container {
  width: 100%;
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: var(--gutter);
}
.container--narrow { max-width: 860px; }

.section { padding-block: clamp(48px, 7vw, 96px); }
.section--paper {
  background: var(--c-paper);
  color: var(--c-ink);
  --c-cyan: #0E7C6D;
  --c-cyan-soft: #0A5F52;
  --c-graphite: #5B6B67;
  --c-fog: #06251F;
}
.section--fog {
  background: var(--c-deep);
  color: var(--c-fog);
}
.section--paper .btn--ghost { border-color: rgba(6, 37, 31, 0.4); color: var(--c-ink); }
.section--paper .btn--ghost:hover { background: rgba(6, 37, 31, 0.08); }

.grid { display: grid; gap: clamp(16px, 2.4vw, 28px); }
.grid--12 { grid-template-columns: repeat(12, minmax(0, 1fr)); }
.grid--3 { grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.grid--2 { grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); }

/* ---------- 8. 装饰语言 ---------- */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--c-cyan);
}
.eyebrow::before { content: ""; width: 26px; height: 1px; background: currentColor; }

.ticks { display: flex; align-items: flex-end; gap: 7px; height: 16px; }
.ticks span { display: block; width: 1px; height: 7px; background: rgba(47, 227, 208, 0.42); }
.ticks span:nth-child(4n + 1) { height: 16px; background: rgba(47, 227, 208, 0.8); }

.slant-divider {
  height: 2px;
  background: linear-gradient(90deg, transparent, rgba(47, 227, 208, 0.6), rgba(255, 122, 41, 0.6), transparent);
  transform: rotate(-8deg) scaleX(1.06);
  transform-origin: center;
}

/* ---------- 9. 面板 / 标签 / 指标 ---------- */
.panel {
  position: relative;
  padding: clamp(18px, 2.4vw, 28px);
  background: var(--c-deep);
  box-shadow: inset 0 0 0 1px rgba(47, 227, 208, 0.22);
  clip-path: polygon(var(--cut) 0, 100% 0, 100% calc(100% - var(--cut)), calc(100% - var(--cut)) 100%, 0 100%, 0 var(--cut));
  transition: transform var(--dur) var(--ease), box-shadow var(--dur) var(--ease), background var(--dur) var(--ease);
}
.panel--flat { clip-path: none; }
@media (hover: hover) {
  .panel:hover {
    transform: translateY(-4px);
    background: var(--c-mist);
    box-shadow: inset 0 0 0 1px var(--c-cyan);
  }
}
.section--paper .panel {
  background: #FFFFFF;
  box-shadow: inset 0 0 0 1px rgba(6, 37, 31, 0.16);
}
@media (hover: hover) {
  .section--paper .panel:hover { background: #FFFCF6; box-shadow: inset 0 0 0 1px #0E7C6D; }
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border: 1px solid rgba(47, 227, 208, 0.42);
  background: rgba(47, 227, 208, 0.08);
  color: var(--c-cyan-soft);
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  font-weight: 600;
  line-height: 1.5;
  letter-spacing: 0.04em;
}
.chip--live { background: var(--c-orange); border-color: var(--c-orange); color: #2A1004; }
.chip--muted { border-color: rgba(169, 187, 182, 0.38); background: transparent; color: var(--c-graphite); }

.metric { display: flex; flex-direction: column; gap: 8px; }
.metric__value {
  font-family: var(--font-mono);
  font-size: clamp(2rem, 4.4vw, 3rem);
  font-weight: 600;
  line-height: 1;
  letter-spacing: -0.03em;
  color: var(--c-cyan);
}
.metric__label {
  font-size: var(--fs-xs);
  letter-spacing: 0.08em;
  color: var(--c-graphite);
}

/* ---------- 10. 筛选协议 ---------- */
.filter-bar { display: flex; flex-wrap: wrap; gap: 8px; }
.filter-chip {
  padding: 10px 16px;
  border: 1px solid rgba(47, 227, 208, 0.35);
  background: transparent;
  color: var(--c-cyan-soft);
  font-size: var(--fs-sm);
  font-weight: 700;
  line-height: 1;
  cursor: pointer;
  transition: background var(--dur) var(--ease), color var(--dur) var(--ease), border-color var(--dur) var(--ease);
}
.filter-chip:hover { background: rgba(47, 227, 208, 0.12); }
.filter-chip[aria-pressed="true"] {
  background: var(--c-cyan);
  border-color: var(--c-cyan);
  color: var(--c-ink);
}
.section--paper .filter-chip { border-color: rgba(6, 37, 31, 0.3); color: var(--c-ink); }
.section--paper .filter-chip[aria-pressed="true"] { background: #0E7C6D; border-color: #0E7C6D; color: #FFFFFF; }

/* ---------- 11. 折叠区 ---------- */
.collapse {
  border: 1px solid rgba(47, 227, 208, 0.24);
  background: var(--c-deep);
}
.collapse + .collapse { margin-top: 10px; }
.collapse summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 20px;
  font-weight: 700;
  color: var(--c-fog);
  cursor: pointer;
  list-style: none;
  transition: background var(--dur) var(--ease);
}
.collapse summary::-webkit-details-marker { display: none; }
.collapse summary::after {
  content: "＋";
  flex: 0 0 auto;
  font-family: var(--font-mono);
  color: var(--c-cyan);
}
.collapse[open] summary { background: var(--c-mist); }
.collapse[open] summary::after { content: "－"; }
.collapse__body { padding: 4px 20px 20px; color: var(--c-fog); }
.collapse__body > * + * { margin-top: 12px; }

/* ---------- 12. 面包屑 ---------- */
.breadcrumbs {
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  letter-spacing: 0.04em;
  color: var(--c-graphite);
}
.breadcrumbs ol { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.breadcrumbs li { display: flex; align-items: center; gap: 8px; }
.breadcrumbs li + li::before { content: "／"; color: rgba(169, 187, 182, 0.6); }
.breadcrumbs a { color: var(--c-cyan-soft); text-decoration: none; }
.breadcrumbs a:hover { text-decoration: underline; }

/* ---------- 13. 图片容器基础规则 ---------- */
.media {
  position: relative;
  display: block;
  overflow: hidden;
  background: linear-gradient(135deg, var(--c-deep), var(--c-mist));
  box-shadow: inset 0 0 0 1px rgba(47, 227, 208, 0.24);
}
.media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(0.85) contrast(1.08) brightness(0.94);
}
.media::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(180deg, rgba(6, 37, 31, 0) 42%, rgba(6, 37, 31, 0.72) 100%);
}
.media--21x9 { aspect-ratio: 21 / 9; }
.media--16x9 { aspect-ratio: 16 / 9; }
.media--4x3  { aspect-ratio: 4 / 3; }
.media--1x1  { aspect-ratio: 1 / 1; }

/* ---------- 14. 显现 ---------- */
[data-reveal] {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.5s var(--ease), transform 0.5s var(--ease);
}
[data-reveal].is-visible { opacity: 1; transform: none; }

/* ---------- 15. 页脚 ---------- */
.site-footer {
  background: var(--c-deep);
  color: var(--c-fog);
  border-top: 1px solid rgba(47, 227, 208, 0.28);
}
.footer-band {
  height: 8px;
  background: repeating-linear-gradient(90deg,
    var(--c-cyan) 0 10px,
    transparent 10px 24px,
    var(--c-orange) 24px 30px,
    transparent 30px 48px);
  opacity: 0.55;
}
.footer-inner {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: clamp(36px, 5vw, 64px) var(--gutter) 28px;
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) repeat(3, minmax(0, 1fr));
  gap: clamp(24px, 3vw, 44px);
}
.footer-brand { display: flex; flex-direction: column; align-items: flex-start; gap: 12px; }
.footer-brand-name {
  font-size: var(--fs-lg);
  font-weight: 900;
  letter-spacing: -0.02em;
  color: var(--c-fog);
  max-width: none;
}
.footer-tagline {
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  letter-spacing: 0.16em;
  color: var(--c-cyan);
  max-width: none;
}
.footer-note {
  font-size: var(--fs-sm);
  line-height: 1.7;
  color: var(--c-graphite);
  max-width: 38ch;
}
.footer-col-title {
  margin-bottom: 14px;
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  font-weight: 600;
  letter-spacing: 0.16em;
  color: var(--c-cyan-soft);
}
.footer-links { display: grid; gap: 10px; }
.footer-links a {
  color: var(--c-fog);
  font-size: var(--fs-sm);
  text-decoration: none;
  transition: color var(--dur) var(--ease);
}
.footer-links a:hover { color: var(--c-cyan); text-decoration: underline; }
.footer-links--plain li { font-size: var(--fs-sm); color: var(--c-graphite); }
.footer-links--plain a { color: var(--c-cyan-soft); }

.footer-legal {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 18px var(--gutter) 32px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-top: 1px solid rgba(47, 227, 208, 0.18);
  font-size: var(--fs-xs);
  color: var(--c-graphite);
}
.footer-legal p { max-width: none; }
.footer-meta { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.footer-meta a { color: var(--c-graphite); text-decoration: none; }
.footer-meta a:hover { color: var(--c-cyan); }

/* ---------- 16. 导航打开状态（移动端） ---------- */
body.is-nav-open { overflow: hidden; }

/* ---------- 17. 响应式 ---------- */
@media (max-width: 1080px) {
  .header-tools .btn--quiet { display: none; }
}

@media (max-width: 900px) {
  .header-bar { grid-template-columns: minmax(0, 1fr) auto; }
  .nav-toggle { display: inline-flex; }
  .header-tools .btn--ghost { display: none; }

  .site-nav {
    position: fixed;
    inset: 0;
    z-index: 1;
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 96px var(--gutter) 40px;
    background: var(--c-ink);
    border-top: 1px solid rgba(47, 227, 208, 0.24);
    overflow-y: auto;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: opacity 0.2s var(--ease), transform 0.2s var(--ease), visibility 0.2s linear;
  }
  .site-header[data-open="true"] .site-nav {
    opacity: 1;
    visibility: visible;
    transform: none;
  }
  .nav-list { flex-direction: column; align-items: stretch; gap: 0; }
  .nav-list a {
    padding: 16px 12px;
    font-size: var(--fs-lg);
    border-bottom: 1px solid rgba(47, 227, 208, 0.16);
  }
  .nav-list a::after { display: none; }

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

@media (max-width: 600px) {
  :root { --cut: 12px; }
  .brand-tag { display: none; }
  .brand-name { font-size: var(--fs-sm); }
  .header-tools .btn--accent { padding: 11px 14px; }
  .grid--12 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .footer-inner { grid-template-columns: minmax(0, 1fr); }
  .footer-legal { flex-direction: column; align-items: flex-start; }
}

/* ---------- 18. 减弱动效 ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  [data-reveal] { opacity: 1; transform: none; }
  .btn--accent:hover { transform: none; }
  @media (hover: hover) { .panel:hover { transform: none; } }
}
