/* 羽析 · 设计原型共享样式
   视觉语言与知识库资产（图解/动画）同源：米白纸面 + 活力橙；
   球场深绿只用于 hero / 页头 / 底部导航等"场"的表面。 */

:root {
  --paper: #FAF9F5;
  --card: #FFFFFF;
  --ink: #2C2C2A;
  --muted: #6B6960;
  --faint: #9B988C;
  --line: #DDD9CD;
  --accent: #D85A30;
  --accent-deep: #993C1D;
  --accent-soft: #FAECE7;
  --court: #14453A;
  --court-deep: #0E332B;
  --court-line: rgba(255, 255, 255, 0.5);
  --ok: #0F6E56;
  --radius: 14px;
  --font: -apple-system, BlinkMacSystemFont, 'PingFang SC', 'Hiragino Sans GB',
    'Noto Sans SC', 'Microsoft YaHei', sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: var(--font);
  background: var(--paper);
  color: var(--ink);
  font-size: 15px;
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
  padding-bottom: calc(64px + env(safe-area-inset-bottom));
}

a { color: inherit; text-decoration: none; }
img { display: block; width: 100%; height: auto; }

/* 展示字体处理：重字重 + 紧字距 + 轻微前倾（羽毛球的速度感） */
.display {
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.25;
}
.skew { transform: skew(-4deg); }

.wrap { max-width: 720px; margin: 0 auto; padding: 0 20px; }
.wrap-wide { max-width: 1080px; margin: 0 auto; padding: 0 20px; }

/* ── 顶部栏 ─────────────────────────────── */
.topbar {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  padding: 18px 0 14px;
}
.brand {
  font-weight: 700;
  font-size: 19px;
  letter-spacing: -0.02em;
  display: flex;
  align-items: center;
  gap: 8px;
}
.brand i {
  width: 9px; height: 9px;
  border-radius: 50%;
  background: var(--accent);
  display: inline-block;
}
.topnav { display: none; gap: 22px; font-size: 14px; color: var(--muted); }
.topnav a.on { color: var(--ink); font-weight: 600; }

/* ── 底部标签导航（移动端） ───────────────── */
.tabbar {
  position: fixed;
  left: 0; right: 0; bottom: 0;
  background: var(--court-deep);
  display: flex;
  padding-bottom: env(safe-area-inset-bottom);
  z-index: 50;
}
.tabbar a {
  flex: 1;
  text-align: center;
  padding: 10px 0 12px;
  color: rgba(255, 255, 255, 0.55);
  font-size: 12.5px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
}
.tabbar a svg { width: 21px; height: 21px; }
.tabbar a.on { color: #FFFFFF; }
.tabbar a.on::before {
  content: '';
  position: absolute;
  top: 0;
  width: 28px; height: 2.5px;
  background: var(--accent);
  border-radius: 0 0 3px 3px;
}
.tabbar a { position: relative; }

/* ── 节标题：短双打线记号（不用眉题/全大写） ── */
.sec { margin: 44px 0 18px; }
.sec::before {
  content: '';
  display: block;
  width: 34px; height: 6px;
  border-top: 2px solid var(--accent);
  border-bottom: 2px solid var(--accent);
  margin-bottom: 12px;
}
.sec h2 { font-size: 21px; }
.sec p { color: var(--muted); font-size: 13.5px; margin-top: 4px; }

/* ── 卡片 ──────────────────────────────── */
.card {
  background: var(--card);
  border: 0.5px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}
.card + .card { margin-top: 14px; }
.card-pad { padding: 18px; }

/* ── 状态徽章 ──────────────────────────── */
.badge {
  display: inline-block;
  font-size: 11.5px;
  padding: 2px 9px;
  border-radius: 999px;
  line-height: 1.6;
  white-space: nowrap;
}
.badge-live { background: var(--accent-soft); color: var(--accent-deep); }
.badge-new { background: var(--accent); color: #FFF; }
.badge-wait { background: #F1EFE8; color: var(--faint); }

/* ── 按钮 ─────────────────────────────── */
.btn {
  display: inline-block;
  font-weight: 600;
  font-size: 14.5px;
  padding: 12px 26px;
  border-radius: 12px;
  border: none;
  cursor: pointer;
}
.btn-accent { background: var(--accent); color: #FFF; }
.btn-ghost {
  background: transparent;
  color: #FFF;
  border: 1px solid rgba(255, 255, 255, 0.4);
}

/* ── 图解与动画嵌入 ─────────────────────── */
.diagram { background: var(--card); border: 0.5px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.diagram + .diagram { margin-top: 14px; }
.diagram figcaption {
  padding: 10px 16px;
  font-size: 12.5px;
  color: var(--muted);
  border-top: 0.5px solid var(--line);
}
.anim-frame { width: 100%; border: 0; display: block; height: 200px; }
/* 内联注入的动画（同源 fetch 场景，含 Vercel） */
.anim-host .wrap { padding: 18px 16px; max-width: none; }
.anim-host svg { width: 100%; height: auto; display: block; }
.anim-host .chain { margin-bottom: 4px; }
.anim-host .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;
}

/* ── 要点清单 ──────────────────────────── */
.points { list-style: none; }
.points li {
  display: flex;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 0.5px solid var(--line);
  font-size: 14.5px;
}
.points li:last-child { border-bottom: none; }
.points li b {
  flex-shrink: 0;
  width: 22px; height: 22px;
  border-radius: 50%;
  background: var(--accent-soft);
  color: var(--accent-deep);
  font-size: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 3px;
}

/* ── 自检卡 ────────────────────────────── */
.check {
  background: var(--accent-soft);
  border: 0.5px solid #F0997B;
  border-radius: var(--radius);
  padding: 16px 18px;
  color: var(--accent-deep);
}
.check h3 { font-size: 14px; margin-bottom: 6px; }
.check p { font-size: 13.5px; color: #712B13; }

/* ── 桌面端 ────────────────────────────── */
@media (min-width: 768px) {
  body { padding-bottom: 0; }
  .topnav { display: flex; }
  .tabbar { display: none; }
}

:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
}
