/* ============================================================
   bsports赛场 · 共享样式表 /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, h6,
p, ul, ol, li, figure, blockquote, dl, dd, address {
  margin: 0;
}

ul, ol { padding: 0; list-style: none; }
img { max-width: 100%; height: auto; display: block; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; }
a { color: inherit; }
table { border-collapse: collapse; width: 100%; }

/* 2. 设计令牌 ------------------------------------------------ */
:root {
  --ink: #0E1116;
  --ink-2: #131C2B;
  --blue: #2E7BFF;
  --cyan: #6FD3FF;
  --orange: #FF6B2C;
  --mint: #4BE0A8;
  --cream: #F2EAD9;
  --brown: #2A2118;
  --paper: #E6EAF2;
  --gray: #8A93A3;
  --red: #E5484D;

  --line: rgba(138, 147, 163, 0.26);
  --line-strong: rgba(138, 147, 163, 0.46);

  --max: 1240px;
  --gutter: 20px;
  --cut: 16px;

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

  --t-fast: 180ms;
  --header-h: 128px;
}

@media (max-width: 900px) {
  :root { --header-h: 172px; }
}

/* 3. 基础排版 ------------------------------------------------ */
body {
  background: var(--ink);
  color: var(--paper);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.7;
  letter-spacing: 0.01em;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

h1, h2, h3, h4 {
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.015em;
}

h1 { font-size: clamp(34px, 5.2vw, 62px); font-weight: 900; letter-spacing: -0.03em; }
h2 { font-size: clamp(24px, 3vw, 36px); }
h3 { font-size: clamp(18px, 1.6vw, 22px); }
h4 { font-size: 17px; }

.num,
.score-num,
.metric__value,
.footer-icp,
.footer-meta,
.footer-contact__val--mono,
.media-frame__caption,
.section-head__eyebrow,
.tag {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  font-feature-settings: "tnum" 1;
}

::selection { background: var(--blue); color: #ffffff; }

::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: var(--ink); }
::-webkit-scrollbar-thumb { background: var(--ink-2); border: 1px solid var(--line); }
::-webkit-scrollbar-thumb:hover { background: var(--blue); }

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

#main-content { display: block; outline: none; }

[data-section] { scroll-margin-top: calc(var(--header-h) + 16px); }

/* 4. 容器与通用工具 ------------------------------------------ */
.wrap {
  width: 100%;
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.skip-link {
  position: fixed;
  top: 10px;
  left: 10px;
  z-index: 200;
  transform: translateY(-220%);
  padding: 10px 16px;
  background: var(--orange);
  color: #10141A;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-decoration: none;
  transition: transform var(--t-fast) ease;
}
.skip-link:focus { transform: translateY(0); }

.rule-scale {
  position: relative;
  height: 10px;
  border-top: 1px solid var(--line);
}
.rule-scale::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  height: 7px;
  background-image: repeating-linear-gradient(
    90deg,
    rgba(138, 147, 163, 0.42) 0 1px,
    transparent 1px 15px
  );
  background-repeat: no-repeat;
  background-size: 100% 7px;
}

.prose p { max-width: 68ch; color: var(--paper); }
.prose p + p { margin-top: 14px; }
.prose a {
  color: var(--cyan);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
  transition: color var(--t-fast) ease;
}
.prose a:hover { color: var(--orange); }
.prose strong { color: #ffffff; }

/* 5. 按钮 ---------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 11px 20px;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--paper);
  background: var(--ink-2);
  border: 1px solid var(--line-strong);
  text-decoration: none;
  transition: background var(--t-fast) ease, border-color var(--t-fast) ease,
    color var(--t-fast) ease;
}
.btn:hover { border-color: var(--cyan); color: #ffffff; background: #17223a; }
.btn:focus-visible { outline: none; box-shadow: inset 0 0 0 2px var(--cyan); }

.btn--primary {
  background: var(--blue);
  border-color: var(--blue);
  color: #ffffff;
}
.btn--primary:hover { background: var(--orange); border-color: var(--orange); color: #10141A; }

.btn--ghost { background: transparent; border-color: var(--line-strong); }
.btn--ghost:hover { background: rgba(46, 123, 255, 0.12); }

.btn--sm { padding: 8px 14px; font-size: 12px; letter-spacing: 0.1em; }

/* 6. 标签 ---------------------------------------------------- */
.tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 9px 2px;
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--cyan);
  background: rgba(46, 123, 255, 0.14);
  border: 1px solid rgba(111, 211, 255, 0.38);
}
.tag--orange {
  color: var(--orange);
  background: rgba(255, 107, 44, 0.12);
  border-color: rgba(255, 107, 44, 0.4);
}
.tag--mint {
  color: var(--mint);
  background: rgba(75, 224, 168, 0.12);
  border-color: rgba(75, 224, 168, 0.4);
}

/* 7. 面包屑 -------------------------------------------------- */
.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  letter-spacing: 0.08em;
  color: var(--gray);
}
.breadcrumb a {
  color: var(--gray);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: color var(--t-fast) ease, border-color var(--t-fast) ease;
}
.breadcrumb a:hover { color: var(--orange); border-bottom-color: var(--orange); }
.breadcrumb__sep { color: rgba(138, 147, 163, 0.5); }
.breadcrumb__here { color: var(--paper); }

/* 8. 分区标题 ------------------------------------------------ */
.section-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 8px 16px;
  padding-bottom: 12px;
  margin-bottom: 26px;
  border-bottom: 1px solid var(--line);
}
.section-head__eyebrow {
  font-size: 11px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--cyan);
}
.section-head__title { font-size: clamp(22px, 3vw, 32px); }
.section-head__note {
  margin-left: auto;
  font-size: 13px;
  color: var(--gray);
}

/* 9. 分屏网格 ------------------------------------------------ */
.split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.6fr);
  gap: clamp(20px, 4vw, 48px);
  align-items: start;
}
.split--even { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
.split--aside { grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); }

@media (max-width: 820px) {
  .split,
  .split--even,
  .split--aside { grid-template-columns: minmax(0, 1fr); }
}

/* 10. 数据面板 ----------------------------------------------- */
.panel {
  position: relative;
  padding: 22px;
  background: var(--ink-2);
  border: 1px solid var(--line);
}
.panel--cut {
  clip-path: polygon(
    var(--cut) 0,
    100% 0,
    100% calc(100% - var(--cut)),
    calc(100% - var(--cut)) 100%,
    0 100%,
    0 var(--cut)
  );
}
.panel--cream {
  background: var(--cream);
  border-color: rgba(42, 33, 24, 0.28);
  color: var(--brown);
}
.panel--cream .panel__title { color: var(--brown); }
.panel--cream .panel__label { color: rgba(42, 33, 24, 0.6); }

.panel__label {
  display: block;
  margin-bottom: 8px;
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--gray);
}
.panel__title { font-size: 19px; font-weight: 800; }

/* 11. 指标块 ------------------------------------------------ */
.metric {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding-left: 12px;
  border-left: 2px solid var(--blue);
}
.metric__value {
  font-size: clamp(28px, 4vw, 44px);
  font-weight: 700;
  line-height: 1;
  color: var(--paper);
}
.metric__label {
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--gray);
}
.metric--accent { border-left-color: var(--orange); }
.metric--accent .metric__value { color: var(--orange); }
.metric--mint { border-left-color: var(--mint); }
.metric--mint .metric__value { color: var(--mint); }

/* 12. 图片容器 ----------------------------------------------- */
.media-frame {
  position: relative;
  display: block;
  overflow: hidden;
  background: var(--ink-2);
  border: 1px solid var(--line);
  aspect-ratio: 16 / 9;
}
.media-frame > img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(0.92) contrast(1.06);
}
.media-frame::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0.55;
  background-image: repeating-linear-gradient(
    0deg,
    rgba(14, 17, 22, 0) 0 3px,
    rgba(14, 17, 22, 0.24) 3px 4px
  );
}
.media-frame--wide { aspect-ratio: 21 / 9; }
.media-frame--tall { aspect-ratio: 3 / 4; }
.media-frame--square { aspect-ratio: 1 / 1; }

.media-frame__caption {
  position: absolute;
  left: 0;
  bottom: 0;
  z-index: 2;
  padding: 6px 12px;
  font-size: 11px;
  letter-spacing: 0.12em;
  color: var(--paper);
  background: rgba(14, 17, 22, 0.84);
  border-top: 1px solid var(--line);
}

/* 13. 折叠面板 ----------------------------------------------- */
[data-collapse] {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 240ms ease;
}
[data-collapse][data-open] { grid-template-rows: 1fr; }
[data-collapse] > * { overflow: hidden; min-height: 0; }

/* 14. 站点页头 ----------------------------------------------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 80;
  background: var(--ink);
  border-bottom: 1px solid var(--line);
}
.site-header::before {
  content: "";
  display: block;
  height: 3px;
  background: linear-gradient(
    90deg,
    var(--blue) 0 38%,
    var(--orange) 38% 52%,
    var(--mint) 52% 60%,
    var(--ink-2) 60% 100%
  );
}
html[data-scrolled] .site-header { box-shadow: 0 14px 34px rgba(0, 0, 0, 0.5); }

.header-inner {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: center;
  gap: 20px;
  max-width: var(--max);
  min-height: 74px;
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.header-rail {
  position: relative;
  justify-self: start;
  width: 100%;
  max-width: 210px;
  height: 34px;
}
.header-rail::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: repeating-linear-gradient(
    90deg,
    rgba(138, 147, 163, 0.45) 0 1px,
    transparent 1px 12px
  );
}
.header-rail::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 50%;
  height: 1px;
  background: var(--line);
}

/* 品牌报头 */
.brand {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  justify-self: center;
  padding: 8px 4px;
  text-decoration: none;
}
.brand__mark {
  width: 12px;
  height: 12px;
  flex: none;
  background: var(--blue);
  clip-path: polygon(0 0, 100% 0, 100% 62%, 62% 100%, 0 100%);
  transition: background var(--t-fast) ease;
}
.brand:hover .brand__mark { background: var(--orange); }
.brand__word {
  font-size: 26px;
  font-weight: 900;
  letter-spacing: -0.03em;
  color: var(--paper);
}
.brand__cn {
  font-size: 20px;
  font-weight: 800;
  letter-spacing: 0.14em;
  color: var(--paper);
}
.brand__sub {
  padding-left: 9px;
  border-left: 1px solid var(--line);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.22em;
  color: var(--cyan);
}

/* 比分窄条 */
.header-score {
  justify-self: end;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 7px 12px;
  background: var(--ink-2);
  border: 1px solid var(--line);
  clip-path: polygon(
    12px 0,
    100% 0,
    100% calc(100% - 12px),
    calc(100% - 12px) 100%,
    0 100%,
    0 12px
  );
  white-space: nowrap;
}
.score-live {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.18em;
  color: var(--mint);
}
.score-live::before {
  content: "";
  width: 6px;
  height: 6px;
  background: var(--mint);
  border-radius: 50%;
  animation: bs-pulse 2.4s ease-in-out infinite;
}
@keyframes bs-pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.22; }
}
.score-num {
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--orange);
}
.score-num i { font-style: normal; padding: 0 2px; color: var(--gray); }
.score-meta { font-family: var(--font-mono); font-size: 11px; color: var(--gray); }
.score-cta {
  margin-left: 2px;
  padding: 6px 10px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: var(--ink);
  background: var(--cyan);
  text-decoration: none;
  transition: background var(--t-fast) ease, color var(--t-fast) ease;
}
.score-cta:hover { background: var(--orange); color: #ffffff; }

@media (max-width: 1080px) {
  .score-meta { display: none; }
}

/* 移动菜单按钮 */
.nav-toggle {
  display: none;
  align-items: center;
  gap: 9px;
  justify-self: end;
  padding: 9px 12px;
  border: 1px solid var(--line-strong);
  background: var(--ink-2);
  color: var(--paper);
  font-size: 12px;
  letter-spacing: 0.16em;
  cursor: pointer;
}
.nav-toggle:hover { border-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: 2px;
  background: currentColor;
  transition: transform var(--t-fast) ease;
}
.nav-toggle__bars::before { top: 0; }
.nav-toggle__bars::after { bottom: 0; }
.nav-toggle[aria-expanded="true"] .nav-toggle__bars::before { transform: translateY(4px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle__bars::after { transform: translateY(-4px) rotate(-45deg); }

/* 15. 主导航 ------------------------------------------------ */
.site-nav {
  border-top: 1px solid var(--line);
  background: rgba(19, 28, 43, 0.55);
}
.nav-list {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 2px;
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 var(--gutter);
}
.nav-item { display: block; }
.nav-link {
  display: block;
  position: relative;
  padding: 13px 16px 11px;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.08em;
  color: var(--gray);
  text-decoration: none;
  border-bottom: 2px solid transparent;
  transition: color var(--t-fast) ease, background var(--t-fast) ease,
    border-color var(--t-fast) ease;
}
.nav-link:hover {
  color: var(--paper);
  background: rgba(46, 123, 255, 0.1);
  border-bottom-color: var(--orange);
}
.nav-link[aria-current="page"] {
  color: var(--paper);
  border-bottom-color: var(--orange);
}

/* 滚动进度尺 */
.scroll-meter {
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  display: block;
  height: 2px;
  background: var(--orange);
  transform: scaleX(0);
  transform-origin: 0 50%;
  pointer-events: none;
  will-change: transform;
}

/* 16. 站点页脚 ----------------------------------------------- */
.site-footer {
  margin-top: 76px;
  background: var(--ink-2);
  border-top: 1px solid var(--line);
}
.footer-inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 48px var(--gutter) 30px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr;
  gap: 32px;
}
.footer-heading {
  margin-bottom: 16px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--cyan);
}
.footer-list {
  display: flex;
  flex-direction: column;
  gap: 9px;
}
.footer-list--inline {
  flex-direction: row;
  flex-wrap: wrap;
  gap: 8px 18px;
}
.footer-list a {
  font-size: 14px;
  color: var(--gray);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  padding-bottom: 1px;
  transition: color var(--t-fast) ease, border-color var(--t-fast) ease;
}
.footer-list a:hover { color: var(--orange); border-bottom-color: var(--orange); }

.footer-contact {
  display: flex;
  flex-direction: column;
  gap: 11px;
  font-style: normal;
}
.footer-contact__row { display: flex; flex-direction: column; gap: 2px; }
.footer-contact__key {
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--gray);
}
.footer-contact__val { font-size: 14px; color: var(--paper); word-break: break-all; }
.footer-contact__val--mono { letter-spacing: 0.02em; }

.footer-note {
  margin-top: 14px;
  font-size: 12px;
  line-height: 1.65;
  color: var(--gray);
}

.footer-icp {
  font-size: 13px;
  letter-spacing: 0.04em;
  color: var(--gray);
  margin-bottom: 14px;
}

.footer-scale {
  max-width: var(--max);
  height: 10px;
  margin: 0 auto;
  padding: 0 var(--gutter);
  border-top: 1px solid var(--line);
  background-image: repeating-linear-gradient(
    90deg,
    rgba(138, 147, 163, 0.4) 0 1px,
    transparent 1px 16px
  );
  background-repeat: no-repeat;
  background-size: calc(100% - 40px) 6px;
  background-position: 20px 0;
}

.footer-base {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px 20px;
  max-width: var(--max);
  margin: 0 auto;
  padding: 14px var(--gutter) 24px;
}
.footer-meta {
  font-size: 12px;
  letter-spacing: 0.04em;
  color: var(--gray);
}

/* 17. 章节高亮协议 ------------------------------------------- */
[data-section-link] {
  color: var(--gray);
  transition: color var(--t-fast) ease, border-color var(--t-fast) ease;
}
[data-section-link][data-active] {
  color: var(--orange);
  border-color: var(--orange);
}

/* 18. 响应式 ------------------------------------------------- */
@media (max-width: 900px) {
  .header-inner {
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-areas:
      "brand toggle"
      "score score";
    gap: 0 12px;
    min-height: 0;
    padding: 10px var(--gutter) 0;
  }
  .header-rail { display: none; }
  .brand { grid-area: brand; justify-self: start; gap: 7px; }
  .brand__word { font-size: 22px; }
  .brand__cn { font-size: 17px; }
  .brand__sub { display: none; }
  .nav-toggle { grid-area: toggle; display: inline-flex; }
  .header-score {
    grid-area: score;
    justify-self: stretch;
    margin: 10px 0;
    overflow-x: auto;
    clip-path: polygon(
      10px 0,
      100% 0,
      100% calc(100% - 10px),
      calc(100% - 10px) 100%,
      0 100%,
      0 10px
    );
  }
  .site-nav { display: none; }
  .site-nav[data-open] { display: block; }
  .nav-list {
    flex-direction: column;
    gap: 0;
    justify-content: flex-start;
    padding: 6px var(--gutter) 14px;
  }
  .nav-link {
    padding: 12px 0;
    border-bottom: 1px solid var(--line);
    border-left: 3px solid transparent;
    padding-left: 12px;
  }
  .nav-link:hover { background: rgba(46, 123, 255, 0.1); }
  .nav-link[aria-current="page"] {
    border-bottom-color: var(--line);
    border-left-color: var(--orange);
  }
}

@media (max-width: 900px) {
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 28px; }
  .footer-inner { padding: 36px var(--gutter) 24px; }
}

@media (max-width: 620px) {
  .footer-grid { grid-template-columns: 1fr; }
  .footer-base { flex-direction: column; }
  .section-head__note { margin-left: 0; width: 100%; }
}

/* 19. 动效偏好 ----------------------------------------------- */
@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;
  }
  .score-live::before { animation: none; }
  [data-collapse] { transition: none; }
  .scroll-meter { transition: none; }
}
