/* ===== 星空体育主站 · 共享样式表 /assets/site.css =====
   1 变量与基础  2 排版与容器  3 框架头部  4 轨道侧栏  5 页脚
   6 通用组件  7 图片容器  8 动效与响应式
   ===================================================== */

/* ---------- 1 变量与基础 ---------- */
:root {
  --c-space: #0B1230;
  --c-orbit: #060A1E;
  --c-panel: #16204A;
  --c-line: #2A3560;
  --c-gold: #F2C14E;
  --c-signal: #FF6A2B;
  --c-white: #F5F7FF;
  --c-muted: #A7B0CC;
  --c-cyan: #4FC3D9;
  --c-green: #46B98B;

  --frame: clamp(18px, 3.2vw, 48px);
  --maxw: 1440px;
  --rail-w: 68px;
  --bar-h: 74px;
  --gap: clamp(18px, 2.4vw, 32px);
  --cut: 12px;

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

  --ease: cubic-bezier(.22, .61, .36, 1);
}

*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--bar-h) + 18px);
}

body, h1, h2, h3, h4, h5, p, ul, ol, li, figure, blockquote, dl, dd { margin: 0; padding: 0; }
ul, ol { list-style: none; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
img, svg, video { display: block; max-width: 100%; }

body {
  min-height: 100vh;
  font-family: var(--font-sans);
  font-size: 17px;
  line-height: 1.75;
  letter-spacing: .01em;
  color: var(--c-white);
  background-color: var(--c-space);
  background-image:
    radial-gradient(circle at 10% 4%, rgba(79, 195, 217, .12), transparent 44%),
    radial-gradient(circle at 92% -4%, rgba(242, 193, 78, .10), transparent 40%),
    linear-gradient(180deg, #0B1230 0%, #0B1230 58%, #080E26 100%);
  background-attachment: fixed;
  overflow-x: hidden;
}

/* 星图网点底纹 */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background-image:
    radial-gradient(rgba(245, 247, 255, .16) 1px, transparent 1.4px),
    radial-gradient(rgba(79, 195, 217, .13) 1px, transparent 1.4px);
  background-size: 128px 128px, 197px 197px;
  background-position: 0 0, 62px 88px;
  opacity: .55;
}

main { position: relative; z-index: 1; }

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

.skip-link {
  position: absolute;
  left: var(--frame);
  top: -120px;
  z-index: 200;
  padding: 11px 20px;
  background: var(--c-gold);
  color: #14100A;
  font-size: 14px;
  font-weight: 800;
  transition: top .22s var(--ease);
}
.skip-link:focus { top: 14px; }

/* ---------- 2 排版与容器 ---------- */
h1, h2, h3 { font-weight: 900; letter-spacing: -.01em; line-height: 1.14; }

h1 { font-size: clamp(34px, 6vw, 84px); }
h2 { font-size: clamp(24px, 3.4vw, 40px); }
h3 { font-size: clamp(19px, 2.2vw, 26px); }

p { max-width: 40em; }

.container {
  width: 100%;
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: var(--frame);
}

.section { position: relative; padding: clamp(48px, 7vw, 104px) 0; }
.section--tight { padding: clamp(28px, 4vw, 56px) 0; }

.mono {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  letter-spacing: .02em;
}

.stat-num {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  font-weight: 700;
  font-size: clamp(28px, 3.4vw, 54px);
  line-height: 1;
  letter-spacing: -.02em;
  color: var(--c-gold);
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .24em;
  color: var(--c-gold);
}
.eyebrow::before { content: ""; width: 26px; height: 1px; background: var(--c-gold); }

.anno {
  writing-mode: vertical-rl;
  font-size: 12px;
  letter-spacing: .22em;
  color: var(--c-muted);
}

.prose { max-width: 46em; font-size: 17px; line-height: 1.8; }
.prose p { margin-bottom: 1.05em; max-width: 38em; }
.prose h2 { margin: 1.5em 0 .55em; }
.prose h3 { margin: 1.3em 0 .5em; font-weight: 800; }
.prose li { position: relative; padding-left: 20px; margin-bottom: .5em; }
.prose li::before {
  content: "";
  position: absolute;
  left: 0;
  top: .78em;
  width: 9px;
  height: 1px;
  background: var(--c-cyan);
}

.breadcrumb { font-size: 13px; color: var(--c-muted); }
.breadcrumb ol { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.breadcrumb li + li::before { content: "/"; margin-right: 8px; color: var(--c-line); }
.breadcrumb a:hover { color: var(--c-white); }
.breadcrumb [aria-current="page"] { color: var(--c-gold); }

/* ---------- 3 框架头部 ---------- */
.site-header { position: sticky; top: 0; z-index: 60; }

.site-header__bar {
  background: rgba(6, 10, 30, .82);
  -webkit-backdrop-filter: blur(16px) saturate(140%);
  backdrop-filter: blur(16px) saturate(140%);
  border-bottom: 1px solid var(--c-line);
  transition: background .3s var(--ease), box-shadow .3s var(--ease);
}
.site-header[data-scrolled="true"] .site-header__bar {
  background: rgba(6, 10, 30, .97);
  box-shadow: 0 22px 44px -34px rgba(0, 0, 0, .95), inset 0 -1px 0 rgba(242, 193, 78, .28);
}

.site-header__inner {
  max-width: var(--maxw);
  margin-inline: auto;
  min-height: var(--bar-h);
  padding-inline: var(--frame);
  display: flex;
  align-items: center;
  gap: clamp(12px, 1.6vw, 26px);
}

.brand { display: inline-flex; align-items: center; gap: 10px; flex: 0 0 auto; }
.brand__glyph {
  color: var(--c-gold);
  font-size: 18px;
  line-height: 1;
  text-shadow: 0 0 18px rgba(242, 193, 78, .65);
}
.brand__text { display: flex; flex-direction: column; line-height: 1.16; }
.brand__name { font-size: 17px; font-weight: 900; letter-spacing: -.01em; }
.brand__sub {
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: .26em;
  color: var(--c-muted);
}

.primary-nav { margin-left: auto; }
.primary-nav__list { display: flex; align-items: center; gap: 2px; }
.primary-nav__link {
  position: relative;
  display: inline-flex;
  align-items: baseline;
  gap: 6px;
  padding: 10px 11px;
  font-size: 15px;
  font-weight: 600;
  color: var(--c-muted);
  transition: color .24s var(--ease);
}
.primary-nav__idx {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: .08em;
  color: var(--c-muted);
  opacity: .5;
}
.primary-nav__label { display: inline-block; }
.primary-nav__link::after {
  content: "";
  position: absolute;
  left: 11px;
  right: 11px;
  bottom: 3px;
  height: 2px;
  background: var(--c-gold);
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform .3s var(--ease);
}
.primary-nav__link:hover { color: var(--c-white); }
.primary-nav__link:hover::after { transform: scaleX(1); }
.primary-nav__link[aria-current="page"] { color: var(--c-gold); }
.primary-nav__link[aria-current="page"]::after { transform: scaleX(1); }
.primary-nav__link[aria-current="page"] .primary-nav__idx { color: var(--c-gold); opacity: .85; }

.primary-nav__foot { display: none; }

.header-utils { display: flex; align-items: center; gap: 10px; flex: 0 0 auto; }

.util-link {
  display: inline-flex;
  align-items: center;
  padding: 7px 12px;
  font-size: 13px;
  font-weight: 600;
  color: var(--c-muted);
  border: 1px solid var(--c-line);
  clip-path: polygon(8px 0, 100% 0, 100% calc(100% - 8px), calc(100% - 8px) 100%, 0 100%, 0 8px);
  transition: color .24s var(--ease), border-color .24s var(--ease), background .24s var(--ease);
}
.util-link:hover {
  color: var(--c-white);
  border-color: var(--c-cyan);
  background: rgba(79, 195, 217, .08);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 20px;
  font-size: 14px;
  font-weight: 800;
  letter-spacing: .02em;
  border: 1px solid transparent;
  clip-path: polygon(12px 0, 100% 0, 100% calc(100% - 12px), calc(100% - 12px) 100%, 0 100%, 0 12px);
  transition: transform .24s var(--ease), background .24s var(--ease), color .24s var(--ease), border-color .24s var(--ease);
}
.btn--signal { background: var(--c-signal); color: #16060C; }
.btn--signal:hover { background: #FF8149; transform: translateY(-2px); }
.btn--gold { background: var(--c-gold); color: #191305; }
.btn--gold:hover { background: #FFD375; transform: translateY(-2px); }
.btn--ghost {
  border-color: var(--c-line);
  background: rgba(22, 32, 74, .55);
  color: var(--c-white);
}
.btn--ghost:hover { border-color: var(--c-gold); color: var(--c-gold); }

.header-cta { padding: 11px 18px; font-size: 13.5px; }

.nav-toggle {
  display: none;
  align-items: center;
  gap: 9px;
  padding: 9px 13px;
  font-size: 13px;
  font-weight: 700;
  color: var(--c-white);
  border: 1px solid var(--c-line);
  transition: border-color .24s var(--ease);
}
.nav-toggle:hover { border-color: var(--c-gold); }
.nav-toggle__bars { display: inline-flex; flex-direction: column; gap: 4px; width: 18px; }
.nav-toggle__bars span {
  display: block;
  height: 2px;
  background: currentColor;
  transition: transform .28s var(--ease), opacity .2s var(--ease);
}
.nav-toggle[aria-expanded="true"] .nav-toggle__bars span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle__bars span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] .nav-toggle__bars span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }
.nav-toggle__text { letter-spacing: .12em; }

/* ---------- 4 轨道侧栏 ---------- */
.rail { display: none; }

@media (min-width: 1024px) {
  body { padding-left: var(--rail-w); }

  .rail {
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    z-index: 70;
    width: var(--rail-w);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-between;
    padding: 24px 0;
    background: linear-gradient(180deg, #060A1E 0%, #0A1130 52%, #060A1E 100%);
    border-right: 1px solid var(--c-line);
  }
  .rail__mark {
    writing-mode: vertical-rl;
    font-family: var(--font-mono);
    font-size: 10.5px;
    letter-spacing: .34em;
    color: var(--c-muted);
    opacity: .85;
  }
  .rail__track {
    position: relative;
    flex: 1 1 auto;
    width: 2px;
    margin: 24px 0;
    background: rgba(42, 53, 96, .8);
    overflow: hidden;
  }
  .rail__fill {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 0;
    background: linear-gradient(180deg, var(--c-cyan), var(--c-gold));
    transition: height .12s linear;
  }
  .rail__foot { color: var(--c-gold); font-size: 12px; opacity: .7; }
}

/* ---------- 5 页脚 ---------- */
.site-footer {
  position: relative;
  z-index: 1;
  margin-top: clamp(64px, 9vw, 120px);
  background: linear-gradient(180deg, rgba(6, 10, 30, .35), #060A1E 34%);
  border-top: 1px solid var(--c-line);
  color: var(--c-muted);
}

.site-footer__scan {
  position: relative;
  height: 2px;
  overflow: hidden;
  background: linear-gradient(90deg, transparent, rgba(79, 195, 217, .7) 30%, rgba(242, 193, 78, .7) 70%, transparent);
}
.site-footer__scan::after {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  width: 22%;
  background: linear-gradient(90deg, transparent, rgba(245, 247, 255, .9), transparent);
  animation: scanSweep 7s linear infinite;
}
@keyframes scanSweep {
  0% { transform: translateX(-120%); }
  100% { transform: translateX(560%); }
}

.site-footer__inner {
  max-width: var(--maxw);
  margin-inline: auto;
  padding: clamp(40px, 5vw, 72px) var(--frame) clamp(28px, 4vw, 48px);
}

.footer-brand {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 10px 24px;
  padding-bottom: clamp(22px, 3vw, 38px);
  margin-bottom: clamp(26px, 3.6vw, 52px);
  border-bottom: 1px dashed rgba(42, 53, 96, .95);
}
.footer-brand__name {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: clamp(20px, 2.4vw, 28px);
  font-weight: 900;
  letter-spacing: -.01em;
  color: var(--c-white);
}
.footer-brand__glyph { color: var(--c-gold); font-size: .72em; }
.footer-brand__line { font-size: 14px; color: var(--c-muted); max-width: 32em; }

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

.footer-col__title {
  margin-bottom: 16px;
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .24em;
  color: var(--c-gold);
}
.footer-col__note { font-size: 13px; line-height: 1.7; opacity: .88; margin-bottom: 12px; }

.footer-list li { margin-bottom: 10px; font-size: 14px; }
.footer-list a {
  color: var(--c-muted);
  border-bottom: 1px solid transparent;
  transition: color .24s var(--ease), border-color .24s var(--ease);
}
.footer-list a:hover { color: var(--c-white); border-color: var(--c-gold); }

.footer-list--legal {
  margin-top: 18px;
  padding-top: 14px;
  font-size: 13px;
  border-top: 1px dashed rgba(42, 53, 96, .95);
}

.footer-list--contact li {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  line-height: 1.65;
}

.footer-link {
  display: inline-block;
  font-size: 13px;
  font-weight: 700;
  color: var(--c-gold);
  border-bottom: 1px solid rgba(242, 193, 78, .45);
  transition: border-color .24s var(--ease), color .24s var(--ease);
}
.footer-link:hover { color: #FFD375; border-color: #FFD375; }

.tag-list { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 14px; }
.tag {
  display: inline-flex;
  align-items: center;
  padding: 5px 10px;
  font-size: 12px;
  letter-spacing: .08em;
  color: var(--c-muted);
  border: 1px solid var(--c-line);
  clip-path: polygon(7px 0, 100% 0, 100% calc(100% - 7px), calc(100% - 7px) 100%, 0 100%, 0 7px);
}
.tag--data { color: var(--c-cyan); border-color: rgba(79, 195, 217, .55); }
.tag--alert { color: #FF9B6B; border-color: rgba(255, 106, 43, .55); }
.tag--ok { color: var(--c-green); border-color: rgba(70, 185, 139, .55); }

.copy-btn {
  padding: 4px 10px;
  font-size: 12px;
  font-weight: 700;
  color: var(--c-muted);
  border: 1px solid var(--c-line);
  clip-path: polygon(6px 0, 100% 0, 100% calc(100% - 6px), calc(100% - 6px) 100%, 0 100%, 0 6px);
  transition: color .24s var(--ease), border-color .24s var(--ease), background .24s var(--ease);
}
.copy-btn:hover { color: var(--c-white); border-color: var(--c-cyan); }
.copy-btn[data-copied="true"] { color: var(--c-green); border-color: rgba(70, 185, 139, .7); background: rgba(70, 185, 139, .1); }

.site-footer__base {
  border-top: 1px solid var(--c-line);
  background: rgba(4, 7, 17, .88);
}
.site-footer__base-inner {
  max-width: var(--maxw);
  margin-inline: auto;
  padding: 18px var(--frame);
  display: flex;
  flex-wrap: wrap;
  gap: 8px 28px;
}
.footer-legal-line { font-size: 12.5px; line-height: 1.7; color: var(--c-muted); opacity: .88; max-width: none; }

/* ---------- 6 通用组件 ---------- */
.panel {
  position: relative;
  padding: clamp(18px, 2.2vw, 30px);
  background: linear-gradient(160deg, rgba(22, 32, 74, .92), rgba(11, 18, 48, .94));
  border: 1px solid var(--c-line);
}
.panel--cut {
  border: 0;
  padding: clamp(20px, 2.4vw, 32px);
  background: linear-gradient(160deg, rgba(22, 32, 74, .96), rgba(9, 15, 40, .96));
  clip-path: polygon(0 0, calc(100% - 18px) 0, 100% 18px, 100% 100%, 18px 100%, 0 calc(100% - 18px));
}

.grid { display: grid; gap: var(--gap); }
.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)); }

.pulse-dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--c-signal);
  animation: livePulse 2s ease-in-out infinite;
}
.pulse-dot--ok { background: var(--c-green); animation-name: livePulseGreen; }
@keyframes livePulse {
  0%, 100% { opacity: 1; box-shadow: 0 0 0 0 rgba(255, 106, 43, .5); }
  50% { opacity: .5; box-shadow: 0 0 0 8px rgba(255, 106, 43, 0); }
}
@keyframes livePulseGreen {
  0%, 100% { opacity: 1; box-shadow: 0 0 0 0 rgba(70, 185, 139, .5); }
  50% { opacity: .5; box-shadow: 0 0 0 8px rgba(70, 185, 139, 0); }
}

/* ---------- 7 图片容器 ---------- */
.figure { margin: 0; }

.media {
  position: relative;
  display: block;
  overflow: hidden;
  aspect-ratio: 16 / 9;
  border: 1px solid var(--c-line);
  background:
    radial-gradient(circle at 72% 18%, rgba(79, 195, 217, .20), transparent 56%),
    radial-gradient(circle at 14% 88%, rgba(242, 193, 78, .14), transparent 52%),
    linear-gradient(150deg, #16204A, #0B1230 72%);
}
.media--tall { aspect-ratio: 3 / 4; }
.media--wide { aspect-ratio: 21 / 9; }
.media > img { width: 100%; height: 100%; object-fit: cover; }
.media__grid {
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: .5;
  background-image:
    linear-gradient(rgba(42, 53, 96, .55) 1px, transparent 1px),
    linear-gradient(90deg, rgba(42, 53, 96, .55) 1px, transparent 1px);
  background-size: 48px 48px;
}
.media__caption {
  margin-top: 10px;
  font-size: 12.5px;
  letter-spacing: .12em;
  color: var(--c-muted);
}

/* ---------- 8 动效与响应式 ---------- */
[data-reveal] {
  opacity: 0;
  transform: translate3d(0, 22px, 0) rotate(var(--rv-rot, -1.2deg));
  transition: opacity .6s var(--ease), transform .6s var(--ease);
  transition-delay: var(--rv-delay, 0ms);
}
[data-reveal]:nth-child(even) { --rv-rot: 1.2deg; }
[data-reveal="in"] { opacity: 1; transform: none; }

@media (max-width: 1279px) {
  .header-utils .util-link { display: none; }
}

@media (max-width: 1023px) {
  :root { --bar-h: 64px; }

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

  .primary-nav {
    position: fixed;
    top: var(--bar-h);
    left: 0;
    right: 0;
    margin: 0;
    display: none;
    flex-direction: column;
    max-height: calc(100vh - var(--bar-h));
    overflow-y: auto;
    padding: 10px var(--frame) 28px;
    background: rgba(6, 10, 30, .985);
    border-bottom: 1px solid var(--c-line);
    box-shadow: 0 42px 62px -42px #000;
  }
  .primary-nav[data-open] { display: flex; }
  .primary-nav__list { flex-direction: column; align-items: stretch; gap: 0; }
  .primary-nav__link {
    justify-content: flex-start;
    padding: 16px 8px;
    font-size: 17px;
    border-bottom: 1px dashed rgba(42, 53, 96, .9);
  }
  .primary-nav__link::after { display: none; }
  .primary-nav__link[aria-current="page"] {
    color: var(--c-gold);
    background: linear-gradient(90deg, rgba(242, 193, 78, .13), transparent 72%);
    box-shadow: inset 3px 0 0 var(--c-gold);
  }
  .primary-nav__foot { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 18px; }
  .header-cta { padding: 10px 14px; font-size: 13px; }

  .footer-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid--3, .grid--4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 640px) {
  body { font-size: 16px; }
  .brand__sub { display: none; }
  .footer-grid { grid-template-columns: 1fr; }
  .grid--2, .grid--3, .grid--4 { grid-template-columns: 1fr; }
  .site-footer__base-inner { flex-direction: column; gap: 6px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .2s !important;
    transition-delay: 0ms !important;
  }
  [data-reveal] {
    opacity: 1 !important;
    transform: none !important;
    transition: opacity .2s ease !important;
  }
  .site-footer__scan::after { display: none; }
  .pulse-dot { animation: none; }
}
