/* ==========================================================================
   亚体育主站 — 共享样式表 /assets/site.css
   秦砖深灰 · 城墙赭红 · 纸灰白，荧光草绿与电光蓝仅作数据脉冲
   ========================================================================== */

:root {
  --ink: #141518;
  --ink-soft: #3A3D44;
  --brick: #25272B;
  --ochre: #B0462E;
  --ochre-deep: #8C341F;
  --ochre-soft: #D98B72;
  --paper: #F4F0E8;
  --stone: #FCFBF8;
  --lime: #B6FF4A;
  --blue: #2F7BFF;
  --slate: #667085;
  --forest: #1E3D2F;

  --line: rgba(20, 21, 24, 0.14);
  --line-soft: rgba(20, 21, 24, 0.08);
  --line-invert: rgba(244, 240, 232, 0.18);

  --font-serif: "Noto Serif SC", "Source Han Serif SC", "Songti SC", "SimSun", serif;
  --font-sans: "Noto Sans SC", "Source Han Sans SC", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", system-ui, sans-serif;
  --font-mono: "JetBrains Mono", "IBM Plex Mono", "SFMono-Regular", ui-monospace, Menlo, Consolas, monospace;

  --shell: 1280px;
  --gutter: clamp(1rem, 4vw, 3.25rem);
  --radius: 2px;
  --dur: 220ms;
}

/* ---------- reset ---------- */

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

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

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 17px;
  font-weight: 400;
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3, h4, h5, h6, p, ul, ol, figure, blockquote, dl, dd { margin: 0; }
ul[class], ol[class] { list-style: none; padding: 0; }
img, picture, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
strong, b { font-weight: 700; }
::selection { background: var(--ochre); color: var(--stone); }

:where(a, button, [tabindex]):focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 3px;
  border-radius: 1px;
}

.header-brandbar :where(a, button):focus-visible,
.site-footer :where(a, button):focus-visible {
  outline-color: var(--lime);
}

.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  margin: -1px; padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
}

/* ---------- 布局容器 ---------- */

.shell {
  width: 100%;
  max-width: var(--shell);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.page-main { display: block; }
#main-content:focus-visible { outline: 2px solid var(--blue); outline-offset: 6px; }

/* ---------- 跳转链接 ---------- */

.skip-link {
  position: absolute;
  left: 1rem;
  top: -5rem;
  z-index: 200;
  padding: 0.7rem 1.1rem;
  background: var(--lime);
  color: var(--brick);
  font-weight: 700;
  font-size: 0.9rem;
  border-radius: var(--radius);
  transition: top 180ms ease;
}
.skip-link:focus { top: 0.9rem; }

/* ---------- 顶部阅读进度 ---------- */

.read-progress {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  z-index: 120;
  background: rgba(37, 39, 43, 0.9);
  pointer-events: none;
}
.read-progress__bar {
  display: block;
  height: 100%;
  width: 0;
  background: var(--lime);
  box-shadow: 0 0 12px rgba(182, 255, 74, 0.5);
  transition: width 100ms linear;
}

/* ---------- 页头 · 第一层 品牌签名 ---------- */

.site-header { position: relative; z-index: 60; }

.header-brandbar {
  background: var(--brick);
  color: var(--paper);
  border-bottom: 1px solid rgba(182, 255, 74, 0.34);
}
.header-brandbar__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  min-height: 74px;
  padding-block: 0.8rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.8rem;
  color: inherit;
  flex: 0 1 auto;
}
.brand__mark {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  flex: none;
  background: var(--ochre);
  color: var(--stone);
  font-family: var(--font-serif);
  font-size: 1.35rem;
  font-weight: 700;
  line-height: 1;
  border-radius: var(--radius);
  box-shadow: 4px 4px 0 rgba(182, 255, 74, 0.92);
}
.brand__text {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  min-width: 0;
}
.brand__name {
  font-family: var(--font-serif);
  font-size: 1.16rem;
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: 0.05em;
}
.brand__sig {
  font-family: var(--font-mono);
  font-size: 0.66rem;
  letter-spacing: 0.14em;
  color: rgba(244, 240, 232, 0.6);
}

.header-meta {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  flex: none;
}
.coord-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.34rem 0.75rem;
  border: 1px solid rgba(244, 240, 232, 0.26);
  border-radius: 999px;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.04em;
  color: rgba(244, 240, 232, 0.86);
  white-space: nowrap;
}
.coord-chip__dot {
  width: 7px;
  height: 7px;
  flex: none;
  border-radius: 50%;
  background: var(--lime);
  box-shadow: 0 0 0 3px rgba(182, 255, 74, 0.16);
}
.hdr-feedback {
  display: inline-flex;
  align-items: center;
  padding: 0.42rem 0.9rem;
  border: 1px solid var(--lime);
  border-radius: var(--radius);
  color: var(--lime);
  font-size: 0.78rem;
  font-weight: 500;
  letter-spacing: 0.06em;
  white-space: nowrap;
  transition: background var(--dur) ease, color var(--dur) ease;
}
.hdr-feedback:hover,
.hdr-feedback:focus-visible {
  background: var(--lime);
  color: var(--brick);
}

/* ---------- 页头 · 第二层 栏目导航 ---------- */

.header-navbar {
  position: relative;
  background: var(--stone);
  border-bottom: 1px solid var(--line);
}
.header-navbar__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;
  min-height: 62px;
}

.primary-nav { display: block; }
.primary-nav__list {
  display: flex;
  align-items: center;
  gap: clamp(0.9rem, 2.2vw, 2rem);
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: navitem;
}
.primary-nav__list > li { counter-increment: navitem; }

.primary-nav a {
  position: relative;
  display: inline-block;
  padding: 0.6rem 0;
  font-size: 0.94rem;
  font-weight: 500;
  color: var(--ink);
  transition: color var(--dur) ease;
}
.primary-nav a::before {
  content: "0" counter(navitem);
  margin-right: 0.42rem;
  font-family: var(--font-mono);
  font-size: 0.62rem;
  letter-spacing: 0.06em;
  color: var(--ochre-soft);
  vertical-align: 0.14em;
}
.primary-nav a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 2px;
  background: var(--ochre);
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform var(--dur) ease;
}
.primary-nav a:hover { color: var(--ochre); }
.primary-nav a:hover::after { transform: scaleX(1); }
.primary-nav a[aria-current="page"] { color: var(--ochre); }
.primary-nav a[aria-current="page"]::before { color: var(--ochre); }
.primary-nav a[aria-current="page"]::after { transform: scaleX(1); }

.header-index {
  font-family: var(--font-mono);
  font-size: 0.66rem;
  letter-spacing: 0.2em;
  color: var(--slate);
  white-space: nowrap;
}

/* ---------- 移动导航按钮 ---------- */

.nav-toggle {
  display: none;
  align-items: center;
  gap: 0.55rem;
  padding: 0.5rem 0.8rem;
  border: 1px solid rgba(20, 21, 24, 0.24);
  border-radius: var(--radius);
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  color: var(--ink);
}
.nav-toggle__bars {
  position: relative;
  width: 18px;
  height: 11px;
  flex: none;
}
.nav-toggle__bars::before,
.nav-toggle__bars::after {
  content: "";
  position: absolute;
  left: 0;
  width: 18px;
  height: 1.5px;
  background: currentColor;
  transition: transform var(--dur) ease, top var(--dur) ease;
}
.nav-toggle__bars::before { top: 1px; }
.nav-toggle__bars::after { top: 9px; }
.nav-toggle[aria-expanded="true"] { border-color: var(--ochre); color: var(--ochre); }
.nav-toggle[aria-expanded="true"] .nav-toggle__bars::before { top: 5px; transform: rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle__bars::after { top: 5px; transform: rotate(-45deg); }
.nav-toggle__label { line-height: 1; }

/* ---------- 页脚 ---------- */

.site-footer {
  position: relative;
  margin-top: clamp(3rem, 8vw, 6rem);
  background: var(--brick);
  color: rgba(244, 240, 232, 0.8);
  border-top: 4px solid var(--ochre);
  overflow: hidden;
}
.site-footer::after {
  content: "";
  position: absolute;
  right: -10vw;
  bottom: -16vw;
  width: 38vw;
  height: 38vw;
  border-radius: 50%;
  background: rgba(182, 255, 74, 0.05);
  pointer-events: none;
}

.footer-inner {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1.6fr 1fr 1.5fr 1fr;
  gap: clamp(1.75rem, 3.4vw, 3.25rem);
  padding-block: clamp(2.5rem, 5vw, 4rem);
}

.footer-brand .brand__mark { box-shadow: 4px 4px 0 rgba(182, 255, 74, 0.55); }
.brand--invert .brand__name { color: var(--stone); }
.brand--invert .brand__sig { color: rgba(244, 240, 232, 0.55); }

.footer-motto {
  margin-top: 1.15rem;
  max-width: 34ch;
  font-size: 0.9rem;
  line-height: 1.8;
  color: rgba(244, 240, 232, 0.66);
}
.footer-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem 1.1rem;
  margin: 1.3rem 0 0;
  padding: 0;
  list-style: none;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.06em;
  color: rgba(244, 240, 232, 0.5);
}

.footer-title {
  margin-bottom: 1.05rem;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--lime);
}
.footer-links {
  display: grid;
  gap: 0.55rem;
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: 0.92rem;
}
.footer-links a {
  color: rgba(244, 240, 232, 0.8);
  transition: color var(--dur) ease;
}
.footer-links a:hover,
.footer-links a:focus-visible { color: var(--lime); }

.footer-links--plain li {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  font-size: 0.88rem;
  line-height: 1.7;
  color: rgba(244, 240, 232, 0.72);
  overflow-wrap: anywhere;
}
.footer-key {
  font-family: var(--font-mono);
  font-size: 0.64rem;
  letter-spacing: 0.14em;
  color: rgba(182, 255, 74, 0.75);
}

.footer-cta {
  display: inline-flex;
  margin-top: 1.3rem;
  padding: 0.6rem 1.05rem;
  border: 1px solid rgba(182, 255, 74, 0.5);
  border-radius: var(--radius);
  color: var(--lime);
  font-size: 0.82rem;
  letter-spacing: 0.06em;
  transition: background var(--dur) ease, color var(--dur) ease;
}
.footer-cta:hover,
.footer-cta:focus-visible {
  background: var(--lime);
  color: var(--brick);
}

.footer-base {
  position: relative;
  z-index: 1;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.75rem 1.5rem;
  padding-block: 1.1rem;
  border-top: 1px solid var(--line-invert);
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.12em;
  color: rgba(244, 240, 232, 0.5);
}
.footer-stamp { color: var(--lime); }

/* ---------- 通用排版 ---------- */

.section { padding-block: clamp(2.5rem, 6vw, 5rem); }
.section--stone { background: var(--stone); }
.section--brick { background: var(--brick); color: var(--paper); }
.section--brick .section-title { color: var(--stone); }
.section--brick .lede { color: rgba(244, 240, 232, 0.76); }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ochre);
}
.eyebrow::before {
  content: "";
  width: 20px;
  height: 2px;
  flex: none;
  background: var(--ochre);
}

.section-title {
  font-family: var(--font-serif);
  font-size: clamp(1.65rem, 3.2vw, 2.25rem);
  font-weight: 700;
  line-height: 1.32;
  letter-spacing: 0.01em;
  color: var(--ink);
}
.lede {
  max-width: 62ch;
  font-size: 1.04rem;
  line-height: 1.85;
  color: var(--ink-soft);
}

/* ---------- 面包屑 ---------- */

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.4rem;
  padding-block: 1.1rem;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  color: var(--slate);
}
.breadcrumb ol {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin: 0;
  padding: 0;
  list-style: none;
}
.breadcrumb li + li::before {
  content: "/";
  margin-right: 0.4rem;
  color: var(--ochre-soft);
}
.breadcrumb a { color: var(--slate); }
.breadcrumb a:hover { color: var(--ochre); }

/* ---------- 网格 ---------- */

.grid {
  display: grid;
  gap: clamp(1rem, 2.5vw, 1.75rem);
}
.grid--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid--aside { grid-template-columns: minmax(0, 240px) minmax(0, 1fr); }

/* ---------- 卡片与标签 ---------- */

.card {
  background: var(--stone);
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  padding: clamp(1.1rem, 2.4vw, 1.75rem);
  box-shadow: 0 1px 0 rgba(20, 21, 24, 0.04);
}
.card--float { box-shadow: 0 24px 44px -32px rgba(20, 21, 24, 0.55); }

.tag {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.2rem 0.6rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-family: var(--font-mono);
  font-size: 0.64rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--slate);
}
.tag--lime {
  background: var(--lime);
  border-color: transparent;
  color: var(--brick);
}
.tag--ochre {
  background: rgba(176, 70, 46, 0.1);
  border-color: rgba(176, 70, 46, 0.35);
  color: var(--ochre);
}

/* ---------- 数据数字 ---------- */

.data-figure {
  display: block;
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: clamp(1.6rem, 4vw, 2.6rem);
  line-height: 1.05;
  letter-spacing: -0.02em;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}
.data-figure--accent { color: var(--ochre); }
.section--brick .data-figure { color: var(--stone); }
.section--brick .data-figure--accent { color: var(--lime); }

/* ---------- 图片容器基础（页面阶段放 img/picture） ---------- */

.media {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16 / 9;
  border-radius: var(--radius);
  background: var(--brick);
}
.media > img,
.media > picture > img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.media--wide { aspect-ratio: 21 / 9; }
.media--square { aspect-ratio: 1 / 1; }
.media--field { aspect-ratio: 4 / 3; }
.media__caption {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 1.4rem 1rem 0.85rem;
  background: linear-gradient(180deg, rgba(20, 21, 24, 0) 0%, rgba(20, 21, 24, 0.82) 100%);
  color: var(--paper);
  font-family: var(--font-mono);
  font-size: 0.74rem;
  letter-spacing: 0.05em;
}

/* ---------- 按钮 ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.82rem 1.45rem;
  border: 1px solid transparent;
  border-radius: var(--radius);
  font-size: 0.92rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  cursor: pointer;
  transition: background var(--dur) ease, color var(--dur) ease,
              border-color var(--dur) ease, transform var(--dur) ease;
}
.btn--primary {
  background: var(--ochre);
  color: var(--stone);
}
.btn--primary:hover,
.btn--primary:focus-visible {
  background: var(--ochre-deep);
  transform: translateY(-1px);
}
.btn--outline {
  border-color: var(--ink);
  color: var(--ink);
}
.btn--outline:hover,
.btn--outline:focus-visible {
  background: var(--ink);
  color: var(--stone);
}
.btn--lime {
  background: var(--lime);
  color: var(--brick);
}
.btn--lime:hover,
.btn--lime:focus-visible {
  background: #A4F034;
  transform: translateY(-1px);
}

/* ---------- 滚动显现与章节高亮 ---------- */

.js [data-reveal] {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 260ms ease, transform 260ms ease;
}
.js [data-reveal].is-visible {
  opacity: 1;
  transform: none;
}

[data-toc-link] {
  transition: color var(--dur) ease, border-color var(--dur) ease;
}
[data-toc-link][data-current="true"] {
  color: var(--ochre);
  font-weight: 500;
}

/* ---------- 平板 ---------- */

@media (max-width: 1024px) {
  body { font-size: 16.5px; }
  .footer-inner { grid-template-columns: 1.5fr 1fr 1.4fr; }
  .footer-legalcol { grid-column: 1 / -1; }
  .grid--3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* ---------- 移动导航断点 ---------- */

@media (max-width: 900px) {
  .header-index { display: none; }
  .header-navbar__inner { min-height: 58px; }
  .nav-toggle { display: inline-flex; }

  .primary-nav {
    position: absolute;
    left: 0;
    right: 0;
    top: 100%;
    z-index: 90;
    display: none;
    background: var(--stone);
    border-top: 1px solid var(--line-soft);
    border-bottom: 1px solid var(--line);
    box-shadow: 0 28px 44px -30px rgba(20, 21, 24, 0.7);
  }
  .primary-nav[data-open="true"] { display: block; }

  .primary-nav__list {
    flex-direction: column;
    align-items: stretch;
    gap: 0;
  }
  .primary-nav__list > li + li { border-top: 1px solid var(--line-soft); }
  .primary-nav a {
    display: block;
    padding: 0.95rem var(--gutter);
    font-size: 1rem;
  }
  .primary-nav a::after { display: none; }
  .primary-nav a[aria-current="page"] {
    background: rgba(176, 70, 46, 0.06);
    box-shadow: inset 3px 0 0 var(--ochre);
  }

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

/* ---------- 手机 ---------- */

@media (max-width: 720px) {
  .grid--2,
  .grid--3 { grid-template-columns: minmax(0, 1fr); }
  .footer-inner { grid-template-columns: minmax(0, 1fr); }
  .footer-legalcol { grid-column: auto; }
  .footer-motto { max-width: none; }
}

@media (max-width: 620px) {
  .header-brandbar__inner {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.7rem;
    padding-block: 0.9rem;
  }
  .header-meta { width: 100%; justify-content: space-between; }
  .brand__sig { display: none; }
  .coord-chip { font-size: 0.66rem; padding: 0.3rem 0.65rem; }
  .hdr-feedback { padding: 0.38rem 0.75rem; font-size: 0.74rem; }
  .footer-base { font-size: 0.62rem; letter-spacing: 0.08em; }
  .breadcrumb { font-size: 0.64rem; }
}

/* ---------- 减少动效 ---------- */

@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;
  }
  .js [data-reveal] {
    opacity: 1;
    transform: none;
  }
}
