/* =============================================================
   爱游戏主站 · /assets/site.css
   夜场战术室体系 · 共享外壳：reset / 变量 / 排版 / 头部 / 页脚 / 基础组件
   ============================================================= */

/* ---------- 1. Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body, h1, h2, h3, h4, p, ul, ol, li, figure, blockquote, dl, dd, address { margin: 0; }
ul, ol { padding: 0; list-style: none; }
img, svg, video { display: block; max-width: 100%; height: auto; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
a { color: inherit; text-decoration: none; }
address { font-style: normal; }
table { border-collapse: collapse; width: 100%; }

/* ---------- 2. 变量 ---------- */
:root {
  --night: #0A0E0D;
  --panel: #111816;
  --raised: #182220;
  --hair: #263230;
  --ink: #E9F1EC;
  --muted: #93A39D;
  --muted-deep: #6E7C77;
  --lime: #B4FF3A;
  --ember: #FF5A2B;
  --amber: #FFC24B;
  --cyan: #4ED8D0;
  --paper: #F2F4EF;
  --paper-ink: #101614;
  --paper-muted: #57635F;

  --font-display: "Noto Serif SC", "Source Han Serif SC", "Songti SC", "SimSun", serif;
  --font-body: "Inter", "Source Han Sans SC", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", system-ui, sans-serif;
  --font-num: "Oswald", "Roboto Condensed", "DIN Alternate", "Arial Narrow", var(--font-body);

  --s12: 0.75rem;
  --s14: 0.875rem;
  --s16: 1rem;
  --s20: 1.25rem;
  --s26: 1.625rem;
  --s34: 2.125rem;
  --s48: 3rem;
  --s72: 4.5rem;

  --gut: clamp(16px, 4vw, 40px);
  --radius-capsule: 999px;
  --radius-slab: 14px;
  --radius-card: 18px;
  --shadow-hair: 0 1px 2px rgba(0, 0, 0, 0.55);
  --shadow-float: 0 22px 48px -28px rgba(0, 0, 0, 0.95);
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
}

/* ---------- 3. 基础排版 ---------- */
body {
  background: var(--night);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16px;
  font-weight: 400;
  line-height: 1.75;
  letter-spacing: 0.01em;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}
::selection { background: var(--lime); color: #0A0E0D; }

.display-1 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(42px, 9vw, 112px);
  line-height: 1.02;
  letter-spacing: -0.02em;
}
.display-2 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(28px, 5vw, 56px);
  line-height: 1.12;
  letter-spacing: -0.01em;
}
.display-3 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(21px, 2.6vw, 34px);
  line-height: 1.25;
}
.lede {
  font-size: clamp(16px, 1.5vw, 20px);
  line-height: 1.7;
  color: var(--muted);
  max-width: 34em;
}
.body-copy { color: #C9D5CF; max-width: 68ch; }
.body-copy + .body-copy { margin-top: 1em; }
.meta {
  font-size: 0.7875rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 0.8125rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--lime);
}
.eyebrow::before {
  content: "";
  width: 22px;
  height: 1px;
  background: currentColor;
  opacity: 0.75;
}
.num {
  font-family: var(--font-num);
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.01em;
  line-height: 1;
}
.slant { font-style: italic; font-weight: 700; }
strong { font-weight: 600; color: var(--ink); }

/* ---------- 4. 容器与栅格 ---------- */
.wrap {
  width: min(1240px, calc(100% - var(--gut) * 2));
  margin-inline: auto;
}
.wrap-narrow {
  width: min(780px, calc(100% - var(--gut) * 2));
  margin-inline: auto;
}
.section { padding: clamp(48px, 7vw, 96px) 0; }
.section-tight { padding: clamp(26px, 4vw, 52px) 0; }
.section-paper {
  background: var(--paper);
  color: var(--paper-ink);
  border-block: 1px solid #DCE2DC;
}
.section-paper .lede,
.section-paper .body-copy { color: var(--paper-muted); }
.section-paper .meta,
.section-paper .stat-label,
.section-paper .slab-note { color: var(--paper-muted); }
.section-paper .slab,
.section-paper .stat { background: #FFFFFF; border-color: #DCE2DC; }
.section-paper .stat-row { background: #DCE2DC; border-color: #DCE2DC; }
.section-paper .pill { border-color: rgba(16, 22, 20, 0.22); color: var(--paper-muted); }
.section-paper .pill-lime { color: #3F6A00; border-color: rgba(63, 106, 0, 0.35); background: rgba(180, 255, 58, 0.22); }
.section-paper .pill-ember { color: #A62E0B; border-color: rgba(166, 46, 11, 0.32); background: rgba(255, 90, 43, 0.12); }
.section-paper .eyebrow { color: #3F6A00; }
.section-paper .hairline { background: #DCE2DC; }
.section-paper .measure { background: #DCE2DC; }
.section-paper .media-frame { border-color: #DCE2DC; background: #E4E9E4; }

.grid-12 {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: var(--gut);
}
.col-3 { grid-column: span 3; }
.col-4 { grid-column: span 4; }
.col-5 { grid-column: span 5; }
.col-6 { grid-column: span 6; }
.col-7 { grid-column: span 7; }
.col-8 { grid-column: span 8; }
.col-9 { grid-column: span 9; }
.col-12 { grid-column: span 12; }

.stack { display: flex; flex-direction: column; gap: 16px; }
.cluster { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }

/* ---------- 5. 通用按钮与标签 ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 11px 20px;
  border-radius: var(--radius-capsule);
  border: 1px solid var(--hair);
  font-size: var(--s14);
  font-weight: 500;
  letter-spacing: 0.02em;
  line-height: 1.4;
  white-space: nowrap;
  transition: background 0.22s var(--ease), color 0.22s var(--ease), border-color 0.22s var(--ease), transform 0.22s var(--ease);
}
.btn:hover { transform: translateY(-1px); }
.btn-sm { padding: 9px 16px; font-size: 0.8125rem; }
.btn-lime {
  background: var(--lime);
  border-color: transparent;
  color: #0A0E0D;
  font-weight: 600;
}
.btn-lime:hover { background: #C8FF6B; }
.btn-ember {
  background: var(--ember);
  border-color: transparent;
  color: #170603;
  font-weight: 600;
}
.btn-ember:hover { background: #FF7048; }
.btn-ghost { background: transparent; color: var(--ink); }
.btn-ghost:hover { border-color: var(--lime); color: var(--lime); }

.pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 5px 12px;
  border-radius: var(--radius-capsule);
  border: 1px solid var(--hair);
  font-size: 0.7875rem;
  letter-spacing: 0.06em;
  color: var(--muted);
  white-space: nowrap;
}
.pill::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
  opacity: 0.85;
}
.pill-lime { color: var(--lime); border-color: rgba(180, 255, 58, 0.36); background: rgba(180, 255, 58, 0.07); }
.pill-ember { color: var(--ember); border-color: rgba(255, 90, 43, 0.38); background: rgba(255, 90, 43, 0.08); }
.pill-amber { color: var(--amber); border-color: rgba(255, 194, 75, 0.36); background: rgba(255, 194, 75, 0.07); }
.pill-cyan { color: var(--cyan); border-color: rgba(78, 216, 208, 0.34); background: rgba(78, 216, 208, 0.07); }

.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: var(--s14);
  color: var(--lime);
  font-weight: 500;
}
.link-arrow::after {
  content: "→";
  transition: transform 0.24s var(--ease);
}
.link-arrow:hover::after { transform: translateX(5px); }
.link-arrow-ember { color: var(--ember); }

.hairline { height: 1px; background: var(--hair); border: 0; }
.rule-lime { height: 2px; width: 56px; background: var(--lime); border: 0; }

/* ---------- 6. 专题研究板 ---------- */
.slab {
  background: var(--panel);
  border: 1px solid var(--hair);
  border-radius: var(--radius-slab);
  padding: clamp(20px, 2.6vw, 32px);
  box-shadow: var(--shadow-hair);
}
.slab-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
}
.slab-title {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: var(--s20);
  line-height: 1.35;
  letter-spacing: 0.01em;
}
.slab-note {
  font-size: 0.7875rem;
  letter-spacing: 0.06em;
  color: var(--muted);
}
.slab-body { margin-top: 16px; }
.slab-foot {
  margin-top: 20px;
  padding-top: 14px;
  border-top: 1px solid var(--hair);
  display: flex;
  flex-wrap: wrap;
  gap: 10px 20px;
  align-items: center;
}
.slab-lime { border-color: rgba(180, 255, 58, 0.3); }
.slab-ember { border-color: rgba(255, 90, 43, 0.3); }
.slab-raised { background: var(--raised); }

.stat-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(148px, 1fr));
  gap: 1px;
  background: var(--hair);
  border: 1px solid var(--hair);
  border-radius: 12px;
  overflow: hidden;
}
.stat { background: var(--panel); padding: 18px 20px; }
.stat-num {
  font-family: var(--font-num);
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  font-size: clamp(28px, 4vw, 48px);
  line-height: 1;
  color: var(--lime);
}
.stat-num-ember { color: var(--ember); }
.stat-num-amber { color: var(--amber); }
.stat-num-cyan { color: var(--cyan); }
.stat-label {
  margin-top: 8px;
  font-size: 0.7875rem;
  letter-spacing: 0.06em;
  color: var(--muted);
}

.measure {
  position: relative;
  height: 6px;
  border-radius: var(--radius-capsule);
  background: var(--hair);
  overflow: hidden;
}
.measure-fill {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--lime);
}
.measure-fill-ember { background: var(--ember); }
.measure-fill-amber { background: var(--amber); }
.measure-fill-cyan { background: var(--cyan); }

/* ---------- 7. 图片容器基础规则 ---------- */
.media-frame {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--hair);
  border-radius: var(--radius-slab);
  background: var(--raised);
  aspect-ratio: 16 / 9;
  box-shadow: var(--shadow-hair);
}
.media-frame > img,
.media-frame > picture > img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.media-frame::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(10, 14, 13, 0) 42%, rgba(10, 14, 13, 0.78) 100%);
  pointer-events: none;
}
.media-frame-wide { aspect-ratio: 21 / 9; }
.media-frame-square { aspect-ratio: 1 / 1; }
.media-frame-tall { aspect-ratio: 3 / 4; }
.media-frame figcaption {
  position: absolute;
  left: 16px;
  right: 16px;
  bottom: 14px;
  z-index: 1;
  font-size: 0.7875rem;
  letter-spacing: 0.06em;
  color: var(--ink);
}

/* ---------- 8. 面包屑 ---------- */
.breadcrumb { padding: 18px 0 0; }
.breadcrumb-list {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  font-size: 0.8125rem;
  color: var(--muted);
  letter-spacing: 0.04em;
}
.breadcrumb-list li { display: inline-flex; align-items: center; gap: 8px; }
.breadcrumb-list li + li::before {
  content: "/";
  color: var(--hair);
}
.breadcrumb-list a:hover { color: var(--lime); }
.breadcrumb-list [aria-current="page"] { color: var(--ink); }

/* ---------- 9. 头部：悬浮胶囊导航 ---------- */
.skip-link {
  position: fixed;
  left: 16px;
  top: -80px;
  z-index: 99;
  padding: 11px 20px;
  border-radius: 0 0 12px 12px;
  background: var(--lime);
  color: #0A0E0D;
  font-size: var(--s14);
  font-weight: 600;
  transition: top 0.24s var(--ease);
}
.skip-link:focus { top: 0; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  padding: 16px 0;
  background: transparent;
  transition: padding 0.3s var(--ease);
}
.site-header[data-condensed] { padding: 8px 0; }

.scroll-meter {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 2px;
  z-index: 60;
  background: linear-gradient(90deg, var(--lime) 0%, var(--cyan) 45%, var(--ember) 100%);
  transform: scaleX(0);
  transform-origin: 0 50%;
  pointer-events: none;
}

.header-rail {
  position: relative;
  width: min(1240px, calc(100% - var(--gut) * 2));
  margin-inline: auto;
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 8px 10px 8px 8px;
  border: 1px solid var(--hair);
  border-radius: var(--radius-capsule);
  background: rgba(24, 34, 32, 0.86);
  box-shadow: var(--shadow-float);
  -webkit-backdrop-filter: blur(16px) saturate(140%);
  backdrop-filter: blur(16px) saturate(140%);
  transition: padding 0.3s var(--ease), background 0.3s var(--ease);
}
.site-header[data-condensed] .header-rail {
  padding: 5px 8px 5px 6px;
  background: rgba(24, 34, 32, 0.94);
}

.brand-clip {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex: 0 0 auto;
  padding-right: 6px;
}
.brand-mark {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  flex: 0 0 auto;
  border-radius: 50%;
  background: var(--lime);
  color: #0A0E0D;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 17px;
  line-height: 1;
}
.brand-stack { display: flex; flex-direction: column; line-height: 1.25; }
.brand-name {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 17px;
  letter-spacing: 0.02em;
  color: var(--ink);
}
.brand-tag {
  font-size: 0.71875rem;
  letter-spacing: 0.04em;
  color: var(--muted);
}

.nav-capsule {
  flex: 1 1 auto;
  display: flex;
  justify-content: center;
  min-width: 0;
}
.nav-list {
  display: flex;
  align-items: center;
  gap: 2px;
}
.nav-link {
  display: inline-block;
  padding: 8px 14px;
  border-radius: var(--radius-capsule);
  font-size: var(--s14);
  color: var(--muted);
  white-space: nowrap;
  transition: color 0.2s var(--ease), background 0.2s var(--ease);
}
.nav-link:hover { color: var(--ink); background: rgba(233, 241, 236, 0.07); }
.nav-link[aria-current="page"] {
  color: #0A0E0D;
  background: var(--lime);
  font-weight: 600;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 0 0 auto;
  margin-left: auto;
}

.nav-toggle {
  display: none;
  align-items: center;
  gap: 9px;
  padding: 9px 14px;
  border: 1px solid var(--hair);
  border-radius: var(--radius-capsule);
  color: var(--ink);
}
.nav-toggle:hover { border-color: var(--lime); }
.nav-toggle-text { font-size: 0.8125rem; letter-spacing: 0.06em; }
.nav-toggle-bars {
  position: relative;
  display: block;
  width: 16px;
  height: 2px;
  border-radius: 2px;
  background: var(--ink);
  transition: background 0.22s var(--ease);
}
.nav-toggle-bars::before,
.nav-toggle-bars::after {
  content: "";
  position: absolute;
  left: 0;
  width: 16px;
  height: 2px;
  border-radius: 2px;
  background: var(--ink);
  transition: transform 0.26s var(--ease), background 0.22s var(--ease);
}
.nav-toggle-bars::before { top: -5px; }
.nav-toggle-bars::after { top: 5px; }
.nav-toggle[aria-expanded="true"] .nav-toggle-bars { background: transparent; }
.nav-toggle[aria-expanded="true"] .nav-toggle-bars::before {
  transform: translateY(5px) rotate(45deg);
  background: var(--ember);
}
.nav-toggle[aria-expanded="true"] .nav-toggle-bars::after {
  transform: translateY(-5px) rotate(-45deg);
  background: var(--ember);
}

/* ---------- 10. 页脚 ---------- */
.site-footer {
  margin-top: clamp(56px, 8vw, 120px);
  padding: clamp(40px, 6vw, 76px) 0 28px;
  border-top: 1px solid var(--hair);
  background: linear-gradient(180deg, rgba(17, 24, 22, 0.65) 0%, var(--night) 46%);
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr;
  gap: clamp(24px, 4vw, 52px);
}
.footer-brand { min-width: 0; }
.footer-blurb {
  margin-top: 16px;
  max-width: 30em;
  font-size: var(--s14);
  line-height: 1.85;
  color: var(--muted);
}
.footer-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 18px;
}
.footer-col { min-width: 0; }
.footer-col-title {
  margin-bottom: 14px;
  font-family: var(--font-body);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
}
.footer-links { display: flex; flex-direction: column; gap: 9px; }
.footer-links a {
  font-size: 0.90625rem;
  color: #C6D2CC;
  transition: color 0.2s var(--ease), padding-left 0.2s var(--ease);
}
.footer-links a:hover { color: var(--lime); padding-left: 4px; }

.footer-rail {
  margin-top: clamp(32px, 5vw, 58px);
  padding-top: 22px;
  border-top: 1px solid var(--hair);
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 10px 28px;
  font-size: 0.85rem;
  color: var(--muted);
}
.rail-label {
  font-size: 0.71875rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--lime);
}
.rail-note { color: var(--muted-deep); }

.footer-legal {
  margin-top: 18px;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px 24px;
  font-size: 0.7875rem;
  letter-spacing: 0.04em;
  color: var(--muted-deep);
}

/* ---------- 11. 显现与无障碍 ---------- */
html.has-reveal [data-reveal] {
  opacity: 0;
  transform: translateY(var(--reveal-shift, 20px));
  transition: opacity 0.62s var(--ease) var(--reveal-delay, 0ms),
              transform 0.62s var(--ease) var(--reveal-delay, 0ms);
}
html.has-reveal [data-reveal].is-inview {
  opacity: 1;
  transform: translateY(0);
}

[hidden] { display: none !important; }

:focus-visible {
  outline: 2px solid var(--lime);
  outline-offset: 3px;
  border-radius: 6px;
}
.section-paper :focus-visible { outline-color: #3F6A00; }

/* ---------- 12. 响应式 ---------- */
@media (max-width: 1100px) {
  .footer-grid { grid-template-columns: 1.4fr 1fr 1fr; }
  .footer-brand { grid-column: 1 / -1; }
}

@media (max-width: 980px) {
  .site-header { padding: 12px 0; }
  .site-header[data-condensed] { padding: 7px 0; }
  .header-rail { gap: 10px; }
  .brand-tag { display: none; }
  .nav-toggle { display: inline-flex; }

  .nav-capsule {
    position: absolute;
    top: calc(100% + 10px);
    left: 0;
    right: 0;
    display: none;
    flex-direction: column;
    align-items: stretch;
    padding: 12px;
    border: 1px solid var(--hair);
    border-radius: var(--radius-card);
    background: rgba(24, 34, 32, 0.97);
    box-shadow: var(--shadow-float);
    -webkit-backdrop-filter: blur(18px);
    backdrop-filter: blur(18px);
  }
  .nav-capsule[data-open] { display: flex; }
  .nav-list { flex-direction: column; align-items: stretch; gap: 2px; }
  .nav-link {
    padding: 13px 16px;
    font-size: 0.9375rem;
    border-radius: 12px;
  }
  .nav-link[aria-current="page"] { border-radius: 12px; }

  .grid-12 { gap: 20px; }
  .col-3, .col-4, .col-5 { grid-column: span 6; }
  .col-7, .col-8, .col-9 { grid-column: span 12; }
}

@media (max-width: 720px) {
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .footer-brand { grid-column: 1 / -1; }
  .footer-legal { flex-direction: column; }
}

@media (max-width: 600px) {
  .col-3, .col-4, .col-5, .col-6 { grid-column: span 12; }
  .header-actions .btn-sm { display: none; }
  .brand-mark { width: 30px; height: 30px; font-size: 15px; }
  .brand-name { font-size: 16px; }
  .footer-grid { grid-template-columns: 1fr; gap: 28px; }
}

@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;
    transition-delay: 0ms !important;
  }
  html.has-reveal [data-reveal] {
    opacity: 1;
    transform: none;
  }
  .btn:hover { transform: none; }
  .link-arrow:hover::after { transform: none; }
  .footer-links a:hover { padding-left: 0; }
}
