/* ============================================================
   美博体育 · 共享样式表  /assets/site.css
   夜间赛场 × 数据指挥中心
   ============================================================ */

/* ---------- 1. 设计变量 ---------- */
:root {
  --bg: #071A14;
  --deep: #0C241C;
  --card: #113128;
  --red: #F23847;
  --red-deep: #B3122A;
  --cyan: #2FF3D0;
  --amber: #FFB62E;
  --paper: #F4EFE6;
  --text: #F7F4EC;
  --text-2: #B9CFC6;
  --line: #2A4A3E;

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

  --shell: min(1240px, calc(100% - 2.4rem));
  --radius: 3px;
  --ease: cubic-bezier(.2, .7, .3, 1);
}

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-padding-top: 8rem;
}

@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
}

body {
  margin: 0;
  min-height: 100vh;
  background-color: var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 16.5px;
  line-height: 1.65;
  font-weight: 400;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background-image:
    radial-gradient(900px 520px at 88% -8%, rgba(242, 56, 71, .16), transparent 62%),
    radial-gradient(760px 460px at 2% 4%, rgba(47, 243, 208, .09), transparent 60%),
    linear-gradient(rgba(42, 74, 62, .34) 1px, transparent 1px),
    linear-gradient(90deg, rgba(42, 74, 62, .34) 1px, transparent 1px);
  background-size: auto, auto, 76px 76px, 76px 76px;
  background-position: 0 0, 0 0, -1px -1px, -1px -1px;
}

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

h1, h2, h3, h4, h5, h6, p, figure, blockquote { margin: 0; }
ul, ol { margin: 0; padding: 0; }
img, svg, video { max-width: 100%; display: block; }
a { color: inherit; }
button { font: inherit; }
hr { border: 0; }

::selection {
  background: var(--red);
  color: #FFFFFF;
}

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

/* ---------- 3. 容器与排版基础 ---------- */
.shell {
  width: var(--shell);
  margin-inline: auto;
}

.section {
  position: relative;
  padding-block: clamp(2.4rem, 5.5vw, 4.6rem);
}

.section--paper {
  background: var(--paper);
  color: #0A1F18;
}

.section--paper .lede,
.section--paper .eyebrow { color: #2E4A40; }

.rule {
  height: 1px;
  border: 0;
  margin: 0;
  background: linear-gradient(90deg, var(--line), transparent);
}

.eyebrow {
  display: flex;
  align-items: center;
  gap: .6rem;
  margin: 0 0 .9rem;
  font-family: var(--font-mono);
  font-size: .68rem;
  font-weight: 500;
  letter-spacing: .24em;
  color: var(--cyan);
}

.eyebrow::before {
  content: "";
  flex: none;
  width: 1.7rem;
  height: 2px;
  background: var(--red);
}

.display-xl {
  margin: 0;
  font-family: var(--font-sans);
  font-size: clamp(2.6rem, 6vw, 6.4rem);
  font-weight: 900;
  line-height: .98;
  letter-spacing: -.022em;
}

.display-lg {
  margin: 0;
  font-family: var(--font-sans);
  font-size: clamp(1.7rem, 3.4vw, 2.9rem);
  font-weight: 800;
  line-height: 1.06;
  letter-spacing: -.015em;
}

.lede {
  margin: 0;
  max-width: 62ch;
  font-size: clamp(1rem, 1.35vw, 1.12rem);
  line-height: 1.75;
  font-weight: 400;
  color: var(--text-2);
}

/* ---------- 4. 按钮 ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .45rem;
  padding: .62rem 1.15rem;
  font-family: var(--font-sans);
  font-size: .84rem;
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: .06em;
  text-decoration: none;
  border: 1px solid transparent;
  border-radius: var(--radius);
  cursor: pointer;
  transition: transform .18s var(--ease), background-color .18s var(--ease),
              color .18s var(--ease), border-color .18s var(--ease),
              box-shadow .18s var(--ease);
}

.btn--signal {
  background: var(--red-deep);
  color: #FFFFFF;
  border-color: var(--red);
  box-shadow: 0 8px 22px -14px rgba(242, 56, 71, .95);
}

.btn--signal:hover {
  background: #C81732;
  border-color: var(--red);
  color: #FFFFFF;
  transform: translateY(-1px);
  box-shadow: 0 12px 26px -14px rgba(242, 56, 71, 1);
}

.btn--ghost {
  background: transparent;
  color: var(--text);
  border-color: var(--line);
}

.btn--ghost:hover {
  color: var(--cyan);
  border-color: var(--cyan);
  transform: translateY(-1px);
}

.btn--amber {
  background: var(--amber);
  color: #1A1204;
  border-color: var(--amber);
}

.btn--amber:hover {
  background: #FFC957;
  border-color: #FFC957;
  transform: translateY(-1px);
}

.btn:active { transform: translateY(0); }

/* ---------- 5. 标签 ---------- */
.tag {
  display: inline-flex;
  align-items: center;
  gap: .35rem;
  padding: .18rem .5rem;
  font-family: var(--font-mono);
  font-size: .66rem;
  font-weight: 500;
  letter-spacing: .14em;
  white-space: nowrap;
  color: var(--cyan);
  background: rgba(47, 243, 208, .07);
  border: 1px solid rgba(47, 243, 208, .4);
  border-radius: var(--radius);
}

.tag--amber {
  color: var(--amber);
  background: rgba(255, 182, 46, .08);
  border-color: rgba(255, 182, 46, .45);
}

.tag--red {
  color: #FFD7DA;
  background: rgba(242, 56, 71, .16);
  border-color: rgba(242, 56, 71, .55);
}

.tag--paper {
  color: #0A1F18;
  background: var(--paper);
  border-color: rgba(10, 31, 24, .25);
}

/* ---------- 6. 面包屑 ---------- */
.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: .45rem;
  margin: 0 0 1.4rem;
  padding: 0;
  list-style: none;
  font-family: var(--font-mono);
  font-size: .7rem;
  letter-spacing: .1em;
  color: var(--text-2);
}

.breadcrumb li {
  display: flex;
  align-items: center;
  gap: .45rem;
}

.breadcrumb li + li::before {
  content: "/";
  color: rgba(185, 207, 198, .38);
}

.breadcrumb a {
  color: var(--text-2);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: color .16s var(--ease), border-color .16s var(--ease);
}

.breadcrumb a:hover {
  color: var(--cyan);
  border-bottom-color: var(--cyan);
}

.breadcrumb [aria-current="page"] { color: var(--text); }

/* ---------- 7. 栅格 ---------- */
.grid {
  display: grid;
  gap: clamp(1rem, 2.4vw, 2rem);
}

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

/* ---------- 8. 图片容器基础规则 ---------- */
.media-frame {
  position: relative;
  display: block;
  width: 100%;
  overflow: hidden;
  aspect-ratio: 16 / 9;
  background: linear-gradient(150deg, var(--card), #081D16);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  isolation: isolate;
}

.media-frame img,
.media-frame video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  filter: saturate(.92) contrast(1.06);
}

.media-frame::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background:
    linear-gradient(180deg, rgba(7, 26, 20, 0) 42%, rgba(7, 26, 20, .82) 100%),
    repeating-linear-gradient(0deg, rgba(7, 26, 20, .14) 0 1px, transparent 1px 4px);
}

.media-frame--wide { aspect-ratio: 21 / 9; }
.media-frame--banner { aspect-ratio: 4 / 3; }
.media-frame--tall { aspect-ratio: 3 / 4; }
.media-frame--square { aspect-ratio: 1 / 1; }

/* ---------- 9. 侧边目录（页面阶段使用） ---------- */
[data-toc] a {
  color: var(--text-2);
  text-decoration: none;
  transition: color .16s var(--ease);
}

[data-toc] a:hover { color: var(--cyan); }

[data-toc] a.is-active {
  color: var(--text);
  font-weight: 700;
}

[data-toc] a.is-active::before {
  content: "";
  display: inline-block;
  width: .55rem;
  height: 2px;
  margin-right: .45rem;
  vertical-align: middle;
  background: var(--red);
}

/* ---------- 10. 站点页头 ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 80;
  background: linear-gradient(180deg, rgba(7, 26, 20, .97), rgba(12, 36, 28, .95));
  border-bottom: 1px solid var(--line);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
}

.skip-link {
  position: absolute;
  left: 1rem;
  top: .5rem;
  z-index: 120;
  padding: .55rem 1rem;
  background: var(--paper);
  color: #071A14;
  font-size: .85rem;
  font-weight: 800;
  text-decoration: none;
  border-radius: var(--radius);
  transform: translateY(-180%);
  transition: transform .18s var(--ease);
}

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

.header-row {
  display: flex;
  align-items: center;
  gap: clamp(.7rem, 2vw, 1.4rem);
  padding-block: .7rem .62rem;
}

.brand-mark {
  display: inline-flex;
  align-items: center;
  gap: .68rem;
  margin-right: auto;
  min-width: 0;
  text-decoration: none;
  color: var(--text);
}

.brand-mark__glyph {
  flex: none;
  display: grid;
  place-items: center;
  width: 2.35rem;
  height: 2.35rem;
  background: linear-gradient(150deg, var(--red) 0%, var(--red-deep) 100%);
  color: #FFFFFF;
  font-size: .95rem;
  font-weight: 900;
  line-height: 1;
  letter-spacing: .02em;
  clip-path: polygon(0 0, 100% 0, 100% calc(100% - 9px), calc(100% - 9px) 100%, 0 100%);
  box-shadow: 0 6px 18px -10px rgba(242, 56, 71, .9);
  transition: filter .18s var(--ease);
}

.brand-mark:hover .brand-mark__glyph { filter: brightness(1.14); }

.brand-mark__text {
  display: flex;
  flex-direction: column;
  min-width: 0;
  line-height: 1.12;
}

.brand-mark__name {
  font-size: 1.02rem;
  font-weight: 800;
  letter-spacing: .05em;
  white-space: nowrap;
}

.brand-mark__meta {
  margin-top: .12rem;
  font-family: var(--font-mono);
  font-size: .6rem;
  letter-spacing: .16em;
  color: var(--text-2);
  white-space: nowrap;
}

.header-index {
  display: flex;
  align-items: baseline;
  gap: .28rem;
  margin: 0;
  padding-left: clamp(.4rem, 1.6vw, 1.2rem);
  border-left: 1px solid var(--line);
  font-family: var(--font-mono);
  font-size: .66rem;
  letter-spacing: .2em;
  color: rgba(185, 207, 198, .72);
  white-space: nowrap;
}

.header-index__num {
  font-size: .8rem;
  letter-spacing: .1em;
  color: var(--cyan);
}

.header-cta { flex: none; }

.nav-toggle {
  display: none;
  align-items: center;
  gap: .55rem;
  padding: .48rem .7rem;
  background: transparent;
  color: var(--text);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  cursor: pointer;
  font-family: var(--font-mono);
  font-size: .66rem;
  letter-spacing: .16em;
  transition: border-color .18s var(--ease), color .18s var(--ease);
}

.nav-toggle:hover {
  color: var(--cyan);
  border-color: var(--cyan);
}

.nav-toggle__bars {
  position: relative;
  display: block;
  width: 16px;
  height: 2px;
  background: var(--red);
  transition: background-color .18s var(--ease);
}

.nav-toggle__bars::before,
.nav-toggle__bars::after {
  content: "";
  position: absolute;
  left: 0;
  width: 16px;
  height: 2px;
  background: var(--red);
  transition: transform .2s var(--ease);
}

.nav-toggle__bars::before { top: -5px; }
.nav-toggle__bars::after { top: 5px; }

.site-header[data-open] .nav-toggle__bars { background: transparent; }
.site-header[data-open] .nav-toggle__bars::before { transform: translateY(5px) rotate(45deg); }
.site-header[data-open] .nav-toggle__bars::after { transform: translateY(-5px) rotate(-45deg); }

.nav-row { border-top: 1px solid rgba(42, 74, 62, .75); }

.primary-nav { display: block; }

.nav-list {
  display: flex;
  flex-wrap: wrap;
  align-items: stretch;
  gap: 0;
  margin: 0;
  padding: 0;
  list-style: none;
}

.nav-list__item { display: flex; }

.nav-link {
  position: relative;
  display: inline-flex;
  align-items: baseline;
  gap: .42rem;
  padding: .68rem .95rem .72rem;
  font-size: .9rem;
  font-weight: 700;
  letter-spacing: .03em;
  color: var(--text-2);
  text-decoration: none;
  border-right: 1px solid rgba(42, 74, 62, .5);
  transition: color .18s var(--ease), background-color .18s var(--ease);
}

.nav-list__item:last-child .nav-link { border-right: 0; }

.nav-link__idx {
  font-family: var(--font-mono);
  font-size: .58rem;
  font-weight: 500;
  letter-spacing: .1em;
  color: rgba(185, 207, 198, .5);
  transition: color .18s var(--ease);
}

.nav-link:hover {
  color: var(--text);
  background: rgba(47, 243, 208, .07);
}

.nav-link:hover .nav-link__idx { color: var(--cyan); }

.nav-link:focus-visible { outline-offset: -3px; }

.nav-link[aria-current="page"] {
  color: var(--text);
  background: rgba(242, 56, 71, .1);
}

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

.nav-link[aria-current="page"]::after {
  content: "";
  position: absolute;
  left: .95rem;
  right: .95rem;
  bottom: 0;
  height: 3px;
  background: var(--red);
  box-shadow: 0 0 12px rgba(242, 56, 71, .8);
}

.read-progress {
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  z-index: 2;
  height: 2px;
  overflow: hidden;
  background: rgba(42, 74, 62, .55);
}

.read-progress__bar {
  display: block;
  width: 100%;
  height: 100%;
  transform: scaleX(0);
  transform-origin: 0 50%;
  background: linear-gradient(90deg, var(--red) 0%, var(--amber) 62%, var(--cyan) 100%);
}

/* ---------- 11. 站点页脚 ---------- */
.site-footer {
  position: relative;
  z-index: 1;
  margin-top: clamp(3rem, 7vw, 6rem);
  background: linear-gradient(180deg, rgba(12, 36, 28, .97), rgba(7, 26, 20, 1));
  border-top: 1px solid var(--line);
}

.site-footer::before {
  content: "";
  position: absolute;
  top: -1px;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg,
    var(--red) 0 18%,
    var(--amber) 18% 26%,
    var(--cyan) 26% 34%,
    var(--line) 34% 100%);
}

.footer-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(0, .7fr) minmax(0, .7fr) minmax(0, 1.05fr);
  gap: clamp(1.6rem, 3.4vw, 3.4rem);
  padding-block: clamp(2.6rem, 5vw, 4.2rem) clamp(1.8rem, 3.5vw, 2.8rem);
}

.footer-brand { min-width: 0; }

.footer-eyebrow {
  margin: 0 0 .9rem;
  font-family: var(--font-mono);
  font-size: .64rem;
  letter-spacing: .28em;
  color: var(--red);
}

.footer-brandline {
  margin: 0 0 .85rem;
  max-width: 26ch;
  font-size: clamp(1.15rem, 2.1vw, 1.6rem);
  font-weight: 800;
  line-height: 1.28;
  letter-spacing: -.01em;
  color: var(--text);
}

.footer-note {
  margin: 0 0 1.3rem;
  max-width: 34ch;
  font-size: .86rem;
  line-height: 1.7;
  color: var(--text-2);
}

.footer-brand__cta { flex: none; }

.footer-col { min-width: 0; }

.footer-coltitle {
  display: flex;
  align-items: center;
  gap: .6rem;
  margin: 0 0 1rem;
  font-family: var(--font-mono);
  font-size: .66rem;
  font-weight: 500;
  letter-spacing: .22em;
  color: var(--cyan);
}

.footer-coltitle::after {
  content: "";
  flex: 1 1 auto;
  height: 1px;
  background: linear-gradient(90deg, var(--line), transparent);
}

.footer-links {
  display: grid;
  gap: .58rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.footer-links a {
  display: inline-block;
  font-size: .93rem;
  line-height: 1.5;
  color: var(--text-2);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: color .16s var(--ease), border-color .16s var(--ease), transform .16s var(--ease);
}

.footer-links a:hover {
  color: var(--text);
  border-bottom-color: var(--red);
  transform: translateX(2px);
}

.footer-contact {
  display: grid;
  gap: .8rem;
}

.contact-line {
  display: flex;
  flex-direction: column;
  gap: .1rem;
  margin: 0;
}

.contact-line__label {
  font-family: var(--font-mono);
  font-size: .6rem;
  letter-spacing: .2em;
  color: rgba(185, 207, 198, .8);
}

.contact-line__value {
  font-family: var(--font-mono);
  font-size: .9rem;
  letter-spacing: .01em;
  line-height: 1.5;
  color: var(--text);
  word-break: break-word;
}

.contact-line__value--quiet {
  font-family: var(--font-sans);
  font-size: .86rem;
  letter-spacing: .02em;
  color: var(--text-2);
}

.footer-base {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: .8rem 1.6rem;
  padding-block: 1.1rem 1.6rem;
  border-top: 1px solid rgba(42, 74, 62, .7);
}

.footer-copy,
.footer-legal {
  margin: 0;
  font-family: var(--font-mono);
  font-size: .74rem;
  letter-spacing: .06em;
  color: var(--text-2);
}

.footer-legal { color: rgba(185, 207, 198, .8); }

.footer-base-nav {
  display: flex;
  flex-wrap: wrap;
  gap: .35rem 1.1rem;
}

.footer-base-nav a {
  font-size: .78rem;
  color: var(--text-2);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: color .16s var(--ease), border-color .16s var(--ease);
}

.footer-base-nav a:hover {
  color: var(--cyan);
  border-bottom-color: var(--cyan);
}

/* ---------- 12. 响应式 ---------- */
@media (max-width: 1080px) {
  .footer-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .footer-brand { grid-column: 1 / -1; }
  .footer-brandline { max-width: 34ch; }
}

@media (max-width: 980px) {
  .brand-mark__meta { display: none; }
}

@media (max-width: 900px) {
  .grid--3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 860px) {
  .nav-toggle { display: inline-flex; }
  .primary-nav { display: none; }
  .site-header[data-open] .primary-nav { display: block; }

  .nav-list { flex-direction: column; padding-block: .35rem .9rem; }
  .nav-list__item { width: 100%; }

  .nav-link {
    width: 100%;
    padding: .8rem 0;
    font-size: .98rem;
    border-right: 0;
    border-bottom: 1px solid rgba(42, 74, 62, .55);
  }

  .nav-link[aria-current="page"] {
    background: transparent;
    padding-left: .9rem;
  }

  .nav-link[aria-current="page"]::after {
    left: 0;
    right: auto;
    top: .55rem;
    bottom: .55rem;
    width: 3px;
    height: auto;
  }

  .nav-link:hover { background: rgba(47, 243, 208, .06); }
}

@media (max-width: 720px) {
  .header-index { display: none; }
  .footer-grid { gap: 1.8rem; }
}

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

@media (max-width: 620px) {
  :root { --shell: min(1240px, calc(100% - 1.8rem)); }
  .header-cta { display: none; }
  .brand-mark__name { font-size: .96rem; }
  .brand-mark__glyph { width: 2.1rem; height: 2.1rem; font-size: .86rem; }
  .footer-grid { grid-template-columns: minmax(0, 1fr); }
  .footer-base { justify-content: flex-start; }
  .footer-base-nav { width: 100%; }
}

@media (max-width: 420px) {
  body { font-size: 16px; }
  .nav-toggle__label { display: none; }
}

/* ---------- 13. 动效偏好 ---------- */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
    scroll-behavior: auto !important;
  }

  .read-progress__bar { transition: none !important; }
  .footer-links a:hover { transform: none; }
  .btn:hover { transform: none; }
}
