/* ==========================================================================
   乐鱼赛场 · /assets/site.css
   共享外壳：reset / 设计令牌 / 命令栏头部 / 数据墙页脚 / 通用组件
   ========================================================================== */

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

* { margin: 0; }

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

body {
  min-height: 100vh;
  margin: 0;
  font-family: var(--f-sans);
  font-size: 16px;
  line-height: 1.75;
  color: var(--text);
  background-color: var(--bg-page);
  background-image:
    radial-gradient(78% 52% at 10% -8%, rgba(0, 229, 199, 0.10), transparent 62%),
    radial-gradient(62% 48% at 102% 2%, rgba(139, 92, 246, 0.12), transparent 64%),
    radial-gradient(58% 42% at 46% 104%, rgba(255, 107, 74, 0.07), transparent 60%);
  background-repeat: no-repeat;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img, svg, video, canvas { display: block; max-width: 100%; }
img { height: auto; }
a { color: inherit; }
button, input, select, textarea { font: inherit; color: inherit; }
button { background: none; border: 0; cursor: pointer; }
ul, ol { list-style: none; padding: 0; }
h1, h2, h3, h4, h5, h6 { font-weight: 500; line-height: 1.2; letter-spacing: -0.01em; }
table { border-collapse: collapse; width: 100%; }

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

/* ---------- 2. 设计令牌 ---------- */
:root {
  /* 原色 */
  --c-ink: #071A2B;
  --c-ink-2: #0D2B45;
  --c-cyan: #00E5C7;
  --c-coral: #FF6B4A;
  --c-violet: #8B5CF6;
  --c-ice: #E6F4F1;
  --c-steel: #7A8FA6;
  --c-green: #34D399;
  --c-amber: #FBBF24;
  --c-mist: #A7F3EF;

  /* 语义层 */
  --bg-page: var(--c-ink);
  --bg-panel: rgba(13, 43, 69, 0.72);
  --bg-panel-soft: rgba(13, 43, 69, 0.42);
  --line: rgba(122, 143, 166, 0.20);
  --line-soft: rgba(122, 143, 166, 0.12);
  --line-cyan: rgba(0, 229, 199, 0.34);
  --line-coral: rgba(255, 107, 74, 0.34);
  --text: var(--c-ice);
  --text-soft: rgba(230, 244, 241, 0.74);
  --text-dim: var(--c-steel);

  /* 形状 */
  --r-xs: 10px;
  --r-sm: 16px;
  --r-md: 24px;
  --r-lg: 34px;
  --r-pill: 999px;

  /* 节奏 */
  --gutter: clamp(20px, 5vw, 64px);
  --measure: 1240px;
  --bar-h: 76px;

  /* 字体 */
  --f-sans: "Inter", "Source Han Sans SC", "Noto Sans SC", "PingFang SC",
    "Hiragino Sans GB", "Microsoft YaHei", system-ui, -apple-system, sans-serif;
  --f-mono: "SFMono-Regular", "JetBrains Mono", "Roboto Mono",
    "DejaVu Sans Mono", Menlo, Consolas, monospace;

  --ease: cubic-bezier(0.22, 0.75, 0.24, 1);
}

/* ---------- 3. 中文排版与通用文本 ---------- */
.shell {
  width: min(var(--measure), calc(100% - var(--gutter) * 2));
  margin-inline: auto;
}

.prose {
  max-width: 68ch;
  color: var(--text-soft);
  line-height: 1.9;
}
.prose p + p,
.prose ul + p,
.prose p + ul { margin-top: 1.1em; }
.prose ul { list-style: disc; padding-left: 1.25em; }
.prose li + li { margin-top: 0.4em; }
.prose strong { color: var(--text); font-weight: 600; }

.eyebrow {
  display: inline-block;
  font-family: var(--f-mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  color: var(--c-cyan);
}

.num {
  font-family: var(--f-mono);
  font-variant-numeric: tabular-nums;
  font-weight: 600;
  letter-spacing: -0.01em;
}

.t-cyan { color: var(--c-cyan); }
.t-coral { color: var(--c-coral); }
.t-violet { color: var(--c-violet); }
.t-amber { color: var(--c-amber); }
.t-green { color: var(--c-green); }
.t-dim { color: var(--text-dim); }

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

/* ---------- 4. 跳至主要内容 ---------- */
.skip-link {
  position: absolute;
  left: 16px;
  top: -120px;
  z-index: 200;
  display: inline-flex;
  align-items: center;
  padding: 12px 22px;
  border-radius: var(--r-pill);
  background: var(--c-cyan);
  color: #04141F;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-decoration: none;
  transition: top 0.22s var(--ease);
}
.skip-link:focus,
.skip-link:focus-visible {
  top: 12px;
  outline: none;
  box-shadow: 0 0 0 3px rgba(7, 26, 43, 0.9), 0 0 0 5px var(--c-violet);
}

/* ---------- 5. 命令栏头部 ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 80;
  isolation: isolate;
  background: linear-gradient(180deg, rgba(7, 26, 43, 0.95) 0%, rgba(7, 26, 43, 0.78) 100%);
  -webkit-backdrop-filter: blur(20px) saturate(160%);
  backdrop-filter: blur(20px) saturate(160%);
  border-bottom: 1px solid var(--line);
}

.site-header::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 1px;
  background: linear-gradient(90deg, transparent 2%, rgba(0, 229, 199, 0.55) 34%, rgba(139, 92, 246, 0.5) 66%, transparent 98%);
  opacity: 0.7;
  pointer-events: none;
}

.cmdbar {
  position: relative;
  width: min(var(--measure), calc(100% - var(--gutter) * 2));
  margin-inline: auto;
  display: flex;
  align-items: center;
  gap: clamp(12px, 2vw, 24px);
  min-height: var(--bar-h);
  padding-block: 10px;
}

/* 品牌 */
.cmdbar-brand {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 6px 8px 6px 0;
  border-radius: var(--r-pill);
  color: var(--text);
  text-decoration: none;
}

.brand-mark {
  position: relative;
  flex: 0 0 auto;
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border-radius: 15px;
  border: 1px solid var(--line-cyan);
  background:
    radial-gradient(120% 120% at 22% 0%, rgba(0, 229, 199, 0.34), transparent 62%),
    linear-gradient(152deg, var(--c-ink-2), var(--c-ink));
  box-shadow: 0 12px 28px -18px rgba(0, 229, 199, 0.95);
}

.mark-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--c-cyan);
  box-shadow: 0 0 14px rgba(0, 229, 199, 0.95);
}

.mark-ring {
  position: absolute;
  inset: 7px;
  border-radius: 50%;
  border: 1px solid rgba(255, 107, 74, 0.62);
  border-top-color: transparent;
  border-left-color: transparent;
  transform: rotate(38deg);
}

.brand-text {
  display: flex;
  flex-direction: column;
  gap: 1px;
  min-width: 0;
}

.brand-name {
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 0.06em;
  line-height: 1.25;
  color: var(--text);
}

.brand-desc {
  font-family: var(--f-mono);
  font-size: 10px;
  letter-spacing: 0.11em;
  line-height: 1.25;
  color: var(--text-dim);
  white-space: nowrap;
}

/* 导航 */
.cmdbar-nav {
  flex: 1 1 auto;
  min-width: 0;
}

.nav-list {
  display: flex;
  align-items: center;
  gap: 4px;
}

.nav-list a {
  display: inline-flex;
  align-items: baseline;
  gap: 7px;
  padding: 9px 14px;
  border: 1px solid transparent;
  border-radius: var(--r-pill);
  font-size: 14px;
  font-weight: 500;
  white-space: nowrap;
  color: var(--text-dim);
  text-decoration: none;
  transition: color 0.24s var(--ease), background 0.24s var(--ease), border-color 0.24s var(--ease);
}

.nav-idx {
  font-family: var(--f-mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  color: rgba(122, 143, 166, 0.62);
  transition: color 0.24s var(--ease);
}

.nav-list a:hover {
  color: var(--text);
  background: rgba(0, 229, 199, 0.07);
}

.nav-list a:hover .nav-idx { color: var(--c-cyan); }

.nav-list a[aria-current="page"] {
  color: var(--text);
  border-color: var(--line-cyan);
  background: linear-gradient(120deg, rgba(0, 229, 199, 0.16), rgba(139, 92, 246, 0.14));
  box-shadow: 0 10px 26px -18px rgba(0, 229, 199, 0.95);
}

.nav-list a[aria-current="page"] .nav-idx { color: var(--c-coral); }

/* 移动菜单按钮 */
.nav-toggle {
  display: none;
  align-items: center;
  gap: 9px;
  padding: 10px 16px 10px 14px;
  border: 1px solid var(--line-cyan);
  border-radius: var(--r-pill);
  background: rgba(0, 229, 199, 0.07);
  color: var(--text);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.04em;
  transition: background 0.22s var(--ease), border-color 0.22s var(--ease);
}
.nav-toggle:hover { background: rgba(0, 229, 199, 0.14); }

.nav-toggle-bars {
  display: grid;
  gap: 4px;
  width: 16px;
}
.nav-toggle-bars i {
  display: block;
  height: 1.5px;
  border-radius: 2px;
  background: var(--c-cyan);
  transition: transform 0.28s var(--ease), opacity 0.28s var(--ease);
}
.nav-toggle[aria-expanded="true"] .nav-toggle-bars i:first-child {
  transform: translateY(2.75px) rotate(45deg);
}
.nav-toggle[aria-expanded="true"] .nav-toggle-bars i:last-child {
  transform: translateY(-2.75px) rotate(-45deg);
}

/* 右侧动作区 */
.cmdbar-actions {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 10px;
  margin-left: auto;
}

/* 滚动进度 */
.scroll-meter {
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  height: 2px;
  overflow: hidden;
  background: rgba(122, 143, 166, 0.14);
  pointer-events: none;
}
.scroll-meter-fill {
  display: block;
  width: 100%;
  height: 100%;
  transform: scaleX(0);
  transform-origin: 0 50%;
  background: linear-gradient(90deg, var(--c-cyan), var(--c-violet) 58%, var(--c-coral));
  will-change: transform;
}

/* ---------- 6. 页脚：多屏数据墙 ---------- */
.site-footer {
  position: relative;
  margin-top: clamp(72px, 11vw, 140px);
  border-top: 1px solid var(--line);
  background:
    radial-gradient(72% 92% at 6% 0%, rgba(0, 229, 199, 0.09), transparent 62%),
    radial-gradient(60% 82% at 97% 8%, rgba(139, 92, 246, 0.10), transparent 62%),
    linear-gradient(180deg, #0A2338 0%, #061523 72%);
  color: var(--text-soft);
  font-size: 14px;
}

.site-footer::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 1px;
  background: linear-gradient(90deg, transparent 3%, rgba(0, 229, 199, 0.5) 32%, rgba(255, 107, 74, 0.42) 68%, transparent 97%);
  opacity: 0.8;
  pointer-events: none;
}

.footer-top {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) repeat(3, minmax(0, 0.95fr));
  gap: clamp(28px, 4vw, 64px);
  padding-block: clamp(52px, 8vw, 96px) clamp(36px, 5vw, 56px);
}

.footer-logo {
  display: inline-block;
  font-size: clamp(22px, 2.6vw, 28px);
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--text);
  text-decoration: none;
  transition: color 0.22s var(--ease);
}
.footer-logo:hover { color: var(--c-cyan); }

.footer-tagline {
  margin-top: 12px;
  font-size: 13.5px;
  line-height: 1.8;
  color: var(--text-soft);
  max-width: 26ch;
}

.footer-meta {
  margin-top: 14px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  border: 1px solid var(--line-cyan);
  border-radius: var(--r-pill);
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  color: var(--c-cyan);
  background: rgba(0, 229, 199, 0.06);
}

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

.footer-h {
  font-family: var(--f-mono);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--text-dim);
  margin-bottom: 16px;
}

.footer-links a {
  display: inline-block;
  padding: 5px 0;
  font-size: 14px;
  color: var(--text-soft);
  text-decoration: none;
  transition: color 0.2s var(--ease), transform 0.2s var(--ease);
}
.footer-links a:hover {
  color: var(--c-cyan);
  transform: translateX(3px);
}

.footer-contact li {
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr);
  gap: 10px;
  align-items: baseline;
  padding: 7px 0;
}

.fc-key {
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: 0.14em;
  color: var(--text-dim);
}

.fc-val {
  font-size: 13px;
  line-height: 1.72;
  color: rgba(230, 244, 241, 0.84);
  overflow-wrap: anywhere;
}

.footer-legal {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px 28px;
  padding-block: 22px;
  border-top: 1px solid var(--line-soft);
  font-family: var(--f-mono);
  font-size: 12px;
  letter-spacing: 0.05em;
  color: var(--text-dim);
}

/* ---------- 7. 通用按钮 / 标签 / 卡片 ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 11px 22px;
  border: 1px solid transparent;
  border-radius: var(--r-pill);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.02em;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.2s var(--ease), box-shadow 0.25s var(--ease),
    background 0.25s var(--ease), border-color 0.25s var(--ease), color 0.25s var(--ease);
}
.btn:active { transform: translateY(1px); }

.btn-quick,
.btn-primary {
  background: linear-gradient(118deg, var(--c-cyan) 0%, #3EE0CD 42%, var(--c-violet) 100%);
  color: #04141F;
  box-shadow: 0 14px 32px -20px rgba(0, 229, 199, 0.95);
}
.btn-quick:hover,
.btn-primary:hover {
  box-shadow: 0 18px 38px -18px rgba(0, 229, 199, 0.95), 0 0 0 1px rgba(0, 229, 199, 0.55);
}

.btn-ghost {
  border-color: var(--line);
  background: rgba(230, 244, 241, 0.04);
  color: var(--text);
}
.btn-ghost:hover {
  border-color: var(--line-cyan);
  background: rgba(0, 229, 199, 0.08);
  color: var(--c-cyan);
}

.btn-coral {
  background: linear-gradient(118deg, var(--c-coral), #FF9163);
  color: #1A0A05;
  box-shadow: 0 14px 32px -20px rgba(255, 107, 74, 0.95);
}
.btn-coral:hover { box-shadow: 0 18px 38px -18px rgba(255, 107, 74, 0.95); }

.tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 12px;
  border-radius: var(--r-pill);
  border: 1px solid transparent;
  font-family: var(--f-mono);
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: 0.06em;
  line-height: 1.6;
  white-space: nowrap;
}
.tag-cyan  { color: var(--c-cyan);  background: rgba(0, 229, 199, 0.12);  border-color: rgba(0, 229, 199, 0.34); }
.tag-coral { color: var(--c-coral); background: rgba(255, 107, 74, 0.13); border-color: rgba(255, 107, 74, 0.34); }
.tag-violet{ color: #C4B5FD;        background: rgba(139, 92, 246, 0.14); border-color: rgba(139, 92, 246, 0.36); }
.tag-amber { color: var(--c-amber); background: rgba(251, 191, 36, 0.12); border-color: rgba(251, 191, 36, 0.32); }
.tag-green { color: var(--c-green); background: rgba(52, 211, 153, 0.12); border-color: rgba(52, 211, 153, 0.32); }

.card {
  position: relative;
  padding: clamp(20px, 2.4vw, 30px);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  background: linear-gradient(158deg, rgba(13, 43, 69, 0.92), rgba(7, 26, 43, 0.90));
}

/* ---------- 8. 分区 / 网格 / 图片容器 ---------- */
.section { padding-block: clamp(48px, 7vw, 92px); }

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

.section-title {
  font-size: clamp(24px, 3.4vw, 40px);
  font-weight: 400;
  line-height: 1.15;
  letter-spacing: -0.015em;
  color: var(--text);
}
.section-title em {
  font-style: normal;
  color: var(--c-cyan);
}

.grid {
  display: grid;
  gap: clamp(16px, 2vw, 24px);
}

.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)); }

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin: 0;
  padding: 0;
  font-family: var(--f-mono);
  font-size: 11.5px;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--text-dim);
}
.breadcrumb li { display: inline-flex; align-items: center; gap: 8px; }
.breadcrumb li + li::before {
  content: "/";
  color: rgba(122, 143, 166, 0.42);
}
.breadcrumb a {
  color: var(--text-dim);
  text-decoration: none;
  transition: color 0.2s var(--ease);
}
.breadcrumb a:hover { color: var(--c-cyan); }
.breadcrumb [aria-current="page"] { color: var(--text-soft); }

.img-frame {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16 / 10;
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  background:
    radial-gradient(88% 90% at 18% 4%, rgba(0, 229, 199, 0.16), transparent 62%),
    linear-gradient(155deg, var(--c-ink-2), var(--c-ink));
}
.img-frame > img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.img-frame[data-ratio="4x3"]  { aspect-ratio: 4 / 3; }
.img-frame[data-ratio="1x1"]  { aspect-ratio: 1 / 1; }
.img-frame[data-ratio="9x16"] { aspect-ratio: 9 / 16; }
.img-frame[data-ratio="21x9"] { aspect-ratio: 21 / 9; }
.img-frame[data-ratio="3x2"]  { aspect-ratio: 3 / 2; }

/* ---------- 9. 响应式 ---------- */
@media (max-width: 1024px) {
  :root { --bar-h: 68px; }

  .brand-desc { display: none; }

  .nav-toggle {
    display: inline-flex;
    margin-left: auto;
  }

  .cmdbar-actions { margin-left: 0; }

  .cmdbar-nav {
    position: absolute;
    top: calc(100% + 6px);
    left: 16px;
    right: 16px;
    z-index: 90;
    flex: 0 0 auto;
    padding: 12px;
    border: 1px solid var(--line);
    border-radius: var(--r-md);
    background: linear-gradient(165deg, #0D2B45 0%, #071A2B 100%);
    box-shadow: 0 30px 60px -30px rgba(0, 0, 0, 0.9), 0 0 0 1px rgba(0, 229, 199, 0.08);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: opacity 0.26s var(--ease), transform 0.26s var(--ease), visibility 0.26s;
  }

  .cmdbar-nav[data-open] {
    opacity: 1;
    visibility: visible;
    transform: none;
  }

  .nav-list {
    flex-direction: column;
    align-items: stretch;
    gap: 2px;
  }

  .nav-list a {
    justify-content: flex-start;
    padding: 14px 16px;
    border-radius: var(--r-sm);
    font-size: 15px;
  }

  .footer-top {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .footer-brand { grid-column: 1 / -1; }

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

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

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

  .brand-mark { width: 36px; height: 36px; border-radius: 13px; }
  .brand-name { font-size: 15px; }

  .btn { padding: 10px 18px; font-size: 13px; }

  .footer-top {
    grid-template-columns: minmax(0, 1fr);
    gap: 34px;
  }

  .footer-legal {
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
  }

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

@media (max-width: 560px) {
  .nav-toggle-label { display: none; }
  .nav-toggle { padding: 11px 13px; }
}

@media (max-width: 400px) {
  .cmdbar-actions .btn-quick { padding: 9px 14px; font-size: 12.5px; }
}

/* ---------- 10. 可访问性偏好 ---------- */
@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;
    scroll-behavior: auto !important;
  }

  .scroll-meter-fill { transition: none !important; }
}
