:root {
  --bg-dark: #1B1231;
  --bg-paper: #F4F3F7;
  --text-main: #191523;
  --brand: #5214EB;
  --accent: #9977EE;
  --radius-card: 24px;
  --radius-btn: 999px;
  --card-border: 0;
  --card-shadow: none;
  --section-y: clamp(2.5rem, 5vw, 4rem);
  --gap: clamp(0.75rem, 1.5vw, 1.25rem);
  --content-max: 1120px;
  --font-sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans SC", sans-serif;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font-sans);
  color: var(--text-main);
  background: var(--bg-paper);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

img, svg { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; }

.container {
  max-width: var(--content-max);
  margin-inline: auto;
  padding-inline: var(--gap);
}

/* 背景上下文切换 */
.dark-bg { background: var(--bg-dark); color: var(--bg-paper); }
.dark-bg .hl { color: var(--accent); }
.paper-bg { background: var(--bg-paper); color: var(--text-main); }
.paper-bg .hl { color: var(--brand); }

/* 眉标 */
.label {
  display: inline-flex;
  align-items: center;
  gap: 0.5em;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 0.75em;
}
.paper-bg .label { color: var(--brand); }
.dark-bg .label { color: var(--accent); }

/* 标题 */
h1, h2, h3, h4 { line-height: 1.25; letter-spacing: 0; font-weight: 600; }
h1 { font-size: clamp(2rem, 4.6vw, 3.4rem); margin-bottom: 1em; }
h2 { font-size: clamp(1.6rem, 3vw, 2.4rem); margin-bottom: 0.8em; }
h3 { font-size: 1.25rem; margin-bottom: 0.6em; }
p { margin-bottom: 1em; max-width: 38em; }

/* 按钮 */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6em;
  height: 52px;
  padding-inline: 1.5em;
  border-radius: var(--radius-btn);
  font-weight: 600;
  font-size: 1rem;
  cursor: pointer;
  transition: transform 0.2s ease, background-color 0.2s ease, border-color 0.2s ease;
}
.btn:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }
.btn:hover { transform: translateY(-1px); }
.btn-primary {
  background: var(--accent);
  color: var(--bg-dark);
}
.btn-primary:hover { background: #8866DD; }
.btn-secondary {
  background: transparent;
  border: 2px solid currentColor;
  color: inherit;
}
.paper-bg .btn-secondary { color: var(--text-main); border-color: var(--text-main); }
.dark-bg .btn-secondary { color: var(--bg-paper); border-color: var(--bg-paper); }

/* 卡片 */
.card {
  background: rgba(255,255,255,0.06);
  border: var(--card-border);
  box-shadow: var(--card-shadow);
  border-radius: var(--radius-card);
  padding: var(--gap);
  transition: background 0.2s ease;
}
.dark-bg .card { background: rgba(255,255,255,0.08); }
.paper-bg .card { background: rgba(0,0,0,0.03); }
.card:hover { background: rgba(255,255,255,0.1); }
.paper-bg .card:hover { background: rgba(0,0,0,0.06); }

/* 网格与布局 */
.grid-2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(0, 1fr)); gap: var(--gap); }
.grid-3 { display: grid; grid-template-columns: repeat(auto-fit, minmax(0, 1fr)); gap: var(--gap); }
.flex-row { display: flex; flex-wrap: wrap; gap: var(--gap); align-items: center; }
.text-left { text-align: left; }
.mt-lg { margin-top: var(--section-y); }

/* 表格 */
.table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.95rem;
}
th, td { padding: 0.8em 1em; text-align: left; border-bottom: 1px solid rgba(128,128,128,0.2); }
th { font-weight: 600; }
td:first-child { font-weight: 600; }

/* FAQ */
details {
  border: var(--card-border);
  border-radius: var(--radius-card);
  background: rgba(0,0,0,0.03);
  margin-bottom: var(--gap);
  overflow: hidden;
}
.dark-bg details { background: rgba(255,255,255,0.06); }
summary {
  padding: 1em 1.5em;
  cursor: pointer;
  font-weight: 600;
  list-style: none;
  position: relative;
}
summary::-webkit-details-marker { display: none; }
summary::after {
  content: "+";
  position: absolute;
  right: 1.5em;
  top: 50%;
  transform: translateY(-50%);
  transition: transform 0.2s;
}
details[open] summary::after { content: "−"; }
details p { padding: 0 1.5em 1.25em; margin-bottom: 0; }

/* 时间线 */
.timeline { position: relative; padding-left: 2rem; }
.timeline::before {
  content: "";
  position: absolute;
  left: 1.25rem;
  top: 0;
  bottom: 0;
  width: 2px;
  background: currentColor;
  opacity: 0.2;
}
.step { position: relative; margin-bottom: 2rem; }
.step-num {
  position: absolute;
  left: -2.75rem;
  top: 0;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 8px;
  background: var(--accent);
  color: var(--bg-dark);
  display: grid;
  place-items: center;
  font-weight: 700;
  font-size: 1rem;
}
.dark-bg .step-num { background: var(--accent); color: var(--bg-dark); }
.paper-bg .step-num { background: var(--brand); color: #fff; }

/* 页头页脚 */
header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(244,243,247,0.85);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid rgba(0,0,0,0.06);
}
.dark-bg header { background: rgba(27,18,49,0.9); border-color: rgba(255,255,255,0.08); }
.nav-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 64px;
}
.brand { display: flex; align-items: center; gap: 0.75em; font-weight: 700; font-size: 1.1rem; }
.brand img { height: 32px; width: auto; }
nav ul { display: flex; gap: 1.5em; }
nav a { font-weight: 500; font-size: 0.95rem; transition: color 0.2s; }
nav a:hover, nav a[aria-current="page"] { color: var(--brand); }
.dark-bg nav a:hover, .dark-bg nav a[aria-current="page"] { color: var(--accent); }
footer {
  padding-block: var(--section-y);
  border-top: 1px solid rgba(128,128,128,0.15);
  margin-top: var(--section-y);
  font-size: 0.9rem;
}
.footer-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: var(--gap); }
.footer-links a { display: block; margin-bottom: 0.5em; opacity: 0.8; }
.footer-links a:hover { opacity: 1; }

/* SVG 动效基础 */
svg.panel-svg { width: 100%; height: auto; }
.anim-rotate { animation: rotate-slow 16s linear infinite; transform-box: fill-box; transform-origin: center; }
.anim-float { animation: float-up 6s ease-in-out infinite alternate; }
.anim-draw { stroke-dasharray: 1; stroke-dashoffset: 0; animation: draw-line 4s ease forwards; }
.anim-breathe { animation: breathe 3s ease-in-out infinite alternate; }
.anim-slide { animation: slide-in 0.8s cubic-bezier(0.2, 0.8, 0.2, 1) forwards; opacity: 0; transform: translateX(10px); }

@keyframes rotate-slow { from { transform: rotate(0deg); } to { transform: rotate(360deg); } }
@keyframes float-up { from { transform: translateY(0); } to { transform: translateY(-8px); } }
@keyframes draw-line { from { stroke-dashoffset: 1; } to { stroke-dashoffset: 0; } }
@keyframes breathe { from { opacity: 0.4; } to { opacity: 1; } }
@keyframes slide-in { to { opacity: 1; transform: translateX(0); } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    animation: none !important;
  }
}
