/* ==========================================================================
   雷竞技赛场 — 共享样式 /assets/site.css
   深空蓝底色 + 荧光绿数据脉冲 + 橙红关键事件，斜向切割与层叠数据面板
   ========================================================================== */

:root {
  --ink: #050B1C;
  --ink-2: #0B1533;
  --jade: #06282B;
  --wine: #54132C;
  --mint: #33F5A2;
  --mint-soft: #A8FFDD;
  --flare: #FF5A2B;
  --amber: #FFC24B;
  --fog: #E8F1F5;
  --silver: #8FA3B8;

  --shell: 1320px;
  --gutter: 20px;
  --bar-h: 56px;

  --r-lg: 28px;
  --r-md: 18px;
  --r-sm: 12px;
  --r-pill: 999px;

  --ease: cubic-bezier(.2, .7, .3, 1);
  --t: 220ms;

  --font-sans: "PingFang SC", "HarmonyOS Sans SC", "Hiragino Sans GB",
    "Microsoft YaHei", "Source Han Sans SC", system-ui, -apple-system,
    "Segoe UI", Roboto, sans-serif;
  --font-mono: "JetBrains Mono", "Roboto Mono", "DIN Alternate",
    ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

@media (min-width: 640px) {
  :root { --gutter: 40px; }
}
@media (min-width: 1024px) {
  :root { --gutter: 72px; }
}

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

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

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

h1, h2, h3, h4, h5, h6 {
  margin: 0;
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.02em;
}

p, figure, blockquote { margin: 0; }

ul, ol { margin: 0; padding: 0; list-style: none; }

a { color: inherit; text-decoration: none; }

button {
  font: inherit;
  color: inherit;
  background: none;
  border: 0;
  padding: 0;
  cursor: pointer;
}

input { font: inherit; color: inherit; }

img, svg, video { display: block; max-width: 100%; }

[hidden] { display: none !important; }

::selection { background: rgba(51, 245, 162, 0.28); color: var(--fog); }

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

/* ---------- 布局 ---------- */

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

.section {
  position: relative;
  padding-block: clamp(48px, 7vw, 96px);
}

.section--tight { padding-block: clamp(32px, 4vw, 56px); }
.section--ink2 { background: var(--ink-2); }
.section--jade { background: var(--jade); }
.section--wine { background: var(--wine); }

.section--cut {
  clip-path: polygon(
    0 clamp(20px, 3vw, 44px),
    100% 0,
    100% calc(100% - clamp(20px, 3vw, 44px)),
    0 100%
  );
}

.split {
  display: grid;
  grid-template-columns: 1fr;
  gap: clamp(24px, 4vw, 64px);
  align-items: start;
}

@media (min-width: 900px) {
  .split { grid-template-columns: 7fr 5fr; }
  .split--flip { grid-template-columns: 5fr 7fr; }
  .split--even { grid-template-columns: 1fr 1fr; }
}

.grid-2, .grid-3 {
  display: grid;
  grid-template-columns: 1fr;
  gap: clamp(18px, 2.4vw, 32px);
}

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

/* ---------- 排版 ---------- */

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--mint);
}

.eyebrow::before {
  content: "";
  width: 26px;
  height: 1px;
  background: currentColor;
  opacity: 0.75;
}

.vnote {
  writing-mode: vertical-rl;
  text-orientation: upright;
  font-size: 12px;
  letter-spacing: 0.26em;
  color: var(--silver);
  margin: 0;
  width: max-content;
}

.num {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  font-feature-settings: "tnum" 1;
  letter-spacing: -0.01em;
}

.prose {
  max-width: 38em;
  font-size: 16px;
  line-height: 1.8;
  color: #D5E3EA;
}

.prose > * + * { margin-top: 1em; }
.prose h2 { font-size: clamp(22px, 2.4vw, 30px); margin-top: 1.8em; }
.prose h3 { font-size: clamp(18px, 2vw, 22px); margin-top: 1.5em; }
.prose ul, .prose ol { padding-left: 1.2em; list-style: disc; }
.prose ol { list-style: decimal; }
.prose li + li { margin-top: 0.4em; }
.prose a { color: var(--mint-soft); border-bottom: 1px solid rgba(51, 245, 162, 0.4); }

.sec-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 18px 32px;
  margin-bottom: clamp(24px, 3vw, 44px);
}

.sec-head__title {
  font-size: clamp(28px, 4vw, 48px);
  letter-spacing: -0.02em;
  margin: 0;
}

.sec-head__note {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.16em;
  color: var(--silver);
}

/* ---------- 按钮与控件 ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 11px 22px;
  border-radius: var(--r-pill);
  border: 1px solid transparent;
  font-size: 14px;
  font-weight: 700;
  white-space: nowrap;
  transition: transform var(--t) var(--ease),
    background var(--t) var(--ease),
    color var(--t) var(--ease),
    border-color var(--t) var(--ease);
}

.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0); }

.btn--mint {
  background: var(--mint);
  color: #031810;
}
.btn--mint:hover { background: var(--mint-soft); }

.btn--ghost {
  border-color: rgba(143, 163, 184, 0.42);
  color: var(--fog);
}
.btn--ghost:hover {
  border-color: var(--mint);
  color: var(--mint-soft);
}

.btn--flare {
  background: var(--flare);
  color: #1B0600;
}
.btn--flare:hover { background: #FF7A52; }

.btn--sm { padding: 8px 16px; font-size: 13px; }

.tool-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  border-radius: var(--r-pill);
  border: 1px solid rgba(143, 163, 184, 0.32);
  font-size: 13px;
  font-weight: 600;
  color: var(--silver);
  transition: color var(--t) var(--ease), border-color var(--t) var(--ease);
}

.tool-btn:hover,
.tool-btn[aria-expanded="true"] {
  color: var(--mint-soft);
  border-color: var(--mint);
}

.pill-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 16px;
  border-radius: var(--r-pill);
  background: rgba(143, 163, 184, 0.1);
  color: var(--silver);
  font-size: 13px;
  font-weight: 600;
  transition: background var(--t) var(--ease),
    color var(--t) var(--ease),
    transform var(--t) var(--ease);
}

.pill:hover {
  background: rgba(51, 245, 162, 0.14);
  color: var(--mint-soft);
  transform: translateY(-2px);
}

.pill[aria-selected="true"],
.pill[aria-pressed="true"] {
  background: var(--mint);
  color: #031810;
}

/* ---------- 面板 ---------- */

.panel {
  position: relative;
  border-radius: var(--r-lg);
  background: var(--ink-2);
  padding: clamp(22px, 3vw, 36px);
  overflow: hidden;
}

.panel--jade { background: var(--jade); }
.panel--wine { background: var(--wine); }

.panel--edge {
  box-shadow: inset 0 0 0 1px rgba(51, 245, 162, 0.18);
}

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

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--silver);
  padding: 0;
  list-style: none;
}

.breadcrumb li { display: flex; align-items: center; }
.breadcrumb li + li::before {
  content: "/";
  padding: 0 10px;
  color: rgba(143, 163, 184, 0.45);
}
.breadcrumb a { transition: color var(--t) var(--ease); }
.breadcrumb a:hover { color: var(--mint); }
.breadcrumb [aria-current="page"] { color: var(--fog); }

/* ---------- 图片容器 ---------- */

.frame {
  position: relative;
  display: block;
  overflow: hidden;
  border-radius: var(--r-lg);
  background: var(--ink-2);
  aspect-ratio: 16 / 9;
  isolation: isolate;
}

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

.frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(0.95);
  transition: transform 420ms var(--ease), filter 420ms var(--ease);
}

.frame:hover img {
  transform: scale(1.03);
  filter: saturate(1.06);
}

.frame::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(5, 11, 28, 0) 42%, rgba(5, 11, 28, 0.76));
  pointer-events: none;
}

.frame--clean::after { display: none; }

.frame__tag {
  position: absolute;
  left: 14px;
  top: 14px;
  z-index: 2;
  padding: 5px 12px;
  border-radius: var(--r-pill);
  background: rgba(5, 11, 28, 0.74);
  border: 1px solid rgba(51, 245, 162, 0.32);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.16em;
  color: var(--mint);
}

/* ---------- 跳过链接 ---------- */

.skip-link {
  position: absolute;
  left: 16px;
  top: -80px;
  z-index: 200;
  padding: 10px 20px;
  border-radius: var(--r-pill);
  background: var(--mint);
  color: #031810;
  font-size: 14px;
  font-weight: 700;
  transition: top 180ms var(--ease);
}

.skip-link:focus { top: 12px; }

/* ---------- 头部命令栏 ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(5, 11, 28, 0.9);
  -webkit-backdrop-filter: saturate(150%) blur(14px);
  backdrop-filter: saturate(150%) blur(14px);
  border-bottom: 1px solid rgba(143, 163, 184, 0.16);
}

.cmd-bar { position: relative; }

.cmd-bar__inner {
  display: flex;
  align-items: center;
  gap: clamp(12px, 2vw, 32px);
  min-height: var(--bar-h);
  padding-block: 8px;
}

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

.brand__pulse {
  position: relative;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--mint);
  box-shadow: 0 0 0 4px rgba(51, 245, 162, 0.16);
}

.brand__pulse::after {
  content: "";
  position: absolute;
  inset: -6px;
  border-radius: 50%;
  border: 1px solid rgba(51, 245, 162, 0.55);
  animation: brand-pulse 2.6s var(--ease) infinite;
}

@keyframes brand-pulse {
  0% { transform: scale(0.6); opacity: 0.9; }
  70%, 100% { transform: scale(1.5); opacity: 0; }
}

.brand__text {
  font-size: 17px;
  font-weight: 800;
  letter-spacing: -0.01em;
  white-space: nowrap;
}

.brand__meta {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.18em;
  color: var(--mint);
  opacity: 0.75;
  white-space: nowrap;
}

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

/* ---------- 栏目索引 ---------- */

.nav-index { flex: 1 1 auto; min-width: 0; }

.nav-index__list {
  display: flex;
  align-items: center;
  gap: 2px;
  padding-block: 6px;
}

.nav-link {
  position: relative;
  display: inline-block;
  padding: 8px 11px;
  border-radius: var(--r-pill);
  font-size: 14px;
  font-weight: 600;
  color: var(--silver);
  white-space: nowrap;
  transition: color var(--t) var(--ease), background var(--t) var(--ease);
}

.nav-link::after {
  content: "";
  position: absolute;
  left: 11px;
  right: 11px;
  bottom: 3px;
  height: 2px;
  border-radius: 2px;
  background: var(--mint);
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform var(--t) var(--ease);
}

.nav-link:hover {
  color: var(--fog);
  background: rgba(143, 163, 184, 0.08);
}

.nav-link:hover::after { transform: scaleX(1); }

.nav-link[aria-current="page"] {
  color: var(--mint-soft);
  background: rgba(51, 245, 162, 0.08);
}

.nav-link[aria-current="page"]::after { transform: scaleX(1); }

.nav-toggle {
  display: none;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border-radius: var(--r-pill);
  border: 1px solid rgba(143, 163, 184, 0.32);
  font-size: 13px;
  font-weight: 700;
  color: var(--fog);
  transition: color var(--t) var(--ease), border-color var(--t) var(--ease);
}

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

.nav-toggle__bars {
  position: relative;
  display: block;
  width: 15px;
  height: 2px;
  border-radius: 2px;
  background: currentColor;
}

.nav-toggle__bars::before,
.nav-toggle__bars::after {
  content: "";
  position: absolute;
  left: 0;
  width: 15px;
  height: 2px;
  border-radius: 2px;
  background: currentColor;
}

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

/* ---------- 滚动进度 ---------- */

.scroll-progress {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--mint), var(--amber) 58%, var(--flare));
  transform: scaleX(0);
  transform-origin: 0 50%;
  will-change: transform;
  pointer-events: none;
}

/* ---------- 检索抽屉 ---------- */

.search-tray {
  background: var(--ink-2);
  border-top: 1px solid rgba(51, 245, 162, 0.18);
  padding-block: 22px 28px;
}

.search-tray__label {
  display: block;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.22em;
  color: var(--mint);
  margin-bottom: 4px;
}

.search-input {
  width: 100%;
  padding: 8px 0;
  background: transparent;
  border: 0;
  border-bottom: 1px solid rgba(143, 163, 184, 0.35);
  font-family: var(--font-mono);
  font-size: clamp(20px, 3vw, 28px);
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--fog);
  transition: border-color var(--t) var(--ease);
}

.search-input:focus {
  outline: none;
  border-color: var(--mint);
}

.search-input::placeholder {
  font-family: var(--font-sans);
  font-weight: 600;
  color: rgba(143, 163, 184, 0.55);
}

.search-tray__hint {
  margin-top: 12px;
  font-size: 13px;
  color: var(--silver);
}

.search-results {
  display: grid;
  gap: 4px;
  margin-top: 16px;
  max-height: 42vh;
  overflow-y: auto;
}

.search-results__item a {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 6px 12px;
  padding: 10px 14px;
  border-radius: var(--r-md);
  transition: background var(--t) var(--ease);
}

.search-results__item a:hover { background: rgba(51, 245, 162, 0.1); }

.search-results__label { font-weight: 700; color: var(--fog); }

.search-results__hint {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--silver);
}

.search-results__empty {
  padding: 12px 14px;
  font-size: 14px;
  color: var(--silver);
}

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

.site-footer {
  position: relative;
  overflow: hidden;
  margin-top: clamp(64px, 9vw, 128px);
  background: var(--ink);
  border-top: 1px solid rgba(143, 163, 184, 0.16);
}

.site-footer::before {
  content: "";
  position: absolute;
  left: -10%;
  right: -10%;
  top: -60px;
  height: 300px;
  pointer-events: none;
  background:
    radial-gradient(50% 100% at 28% 100%, rgba(51, 245, 162, 0.1), transparent 70%),
    radial-gradient(42% 100% at 76% 100%, rgba(255, 90, 43, 0.1), transparent 70%);
}

.site-footer::after {
  content: "";
  position: absolute;
  left: 50%;
  top: -46px;
  width: 160%;
  height: 220px;
  transform: translateX(-50%);
  border-radius: 50% 50% 0 0 / 100% 100% 0 0;
  border-top: 1px solid rgba(51, 245, 162, 0.16);
  pointer-events: none;
}

.footer-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1fr;
  gap: clamp(28px, 4vw, 48px);
  padding-block: clamp(48px, 7vw, 88px) clamp(30px, 4vw, 52px);
}

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

@media (min-width: 1040px) {
  .footer-grid { grid-template-columns: 1.4fr repeat(4, minmax(0, 1fr)); }
}

.footer-brand__line {
  margin-top: 14px;
  font-size: 14px;
  color: var(--silver);
}

.footer-brand__meta {
  margin-top: 6px;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.1em;
  color: var(--mint);
}

.footer-col {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.footer-col__title {
  writing-mode: vertical-rl;
  text-orientation: upright;
  width: max-content;
  height: max-content;
  margin: 0 0 20px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.28em;
  color: var(--mint);
}

.footer-col__list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-col__list a {
  display: inline-block;
  font-size: 14px;
  color: var(--silver);
  transition: color var(--t) var(--ease), transform var(--t) var(--ease);
}

.footer-col__list a:hover {
  color: var(--mint-soft);
  transform: translateX(3px);
}

.footer-base {
  position: relative;
  z-index: 1;
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px 32px;
  padding-block: 20px 30px;
  border-top: 1px solid rgba(143, 163, 184, 0.16);
}

.footer-base p {
  font-size: 13px;
  line-height: 1.7;
  color: var(--silver);
}

.footer-base__contact { max-width: 70ch; }

.footer-base__legal {
  font-family: var(--font-mono);
  letter-spacing: 0.04em;
  color: rgba(143, 163, 184, 0.85);
  white-space: nowrap;
}

/* ---------- 显现 ---------- */

.js [data-reveal] {
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 420ms var(--ease), transform 420ms var(--ease);
}

.js [data-reveal].is-shown {
  opacity: 1;
  transform: none;
}

/* ---------- 响应式：移动端底部标签栏 ---------- */

@media (max-width: 900px) {
  body { padding-bottom: 72px; }

  .nav-toggle { display: inline-flex; }
  .brand__meta { display: none; }
  .btn--sm { padding: 7px 14px; font-size: 12.5px; }
  .tool-btn { padding: 7px 12px; font-size: 12.5px; }

  .nav-index {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 110;
    background: rgba(11, 21, 51, 0.97);
    -webkit-backdrop-filter: blur(12px);
    backdrop-filter: blur(12px);
    border-top: 1px solid rgba(51, 245, 162, 0.24);
    box-shadow: 0 -20px 44px rgba(0, 0, 0, 0.55);
    padding: 8px var(--gutter) calc(8px + env(safe-area-inset-bottom, 0px));
    transform: translateY(115%);
    transition: transform 260ms var(--ease);
  }

  .nav-index[data-open] { transform: translateY(0); }

  .nav-index__list {
    gap: 2px;
    overflow-x: auto;
    scrollbar-width: none;
    -ms-overflow-style: none;
  }

  .nav-index__list::-webkit-scrollbar { display: none; }

  .nav-link {
    padding: 9px 12px;
    font-size: 13px;
  }

  .nav-link::after {
    left: 12px;
    right: 12px;
    bottom: 4px;
  }

  .search-results { max-height: 52vh; }
}

@media (max-width: 420px) {
  .brand__text { font-size: 15.5px; }
  .nav-link { padding: 9px 10px; font-size: 12.5px; }
}

/* ---------- 无障碍动效降级 ---------- */

@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;
  }

  .btn:hover,
  .pill:hover,
  .frame:hover img,
  .footer-col__list a:hover { transform: none; }
}
