/* === 设计变量与基础重置 === */
:root {
  /* 色板 */
  --color-dark: #140E25;
  --color-paper: #FCFCFD;
  --color-text: #191523;
  --color-brand: #5214EB;
  --color-accent: #6EEDD2;
  
  /* 结构 Token */
  --radius-card: 8px;
  --radius-btn: 6px;
  --card-border: 0;
  --card-shadow: none;
  --section-y: clamp(3.5rem, 7vw, 6rem);
  --gap: clamp(1rem, 2vw, 1.75rem);
  --content-max: 1280px;
  
  /* 字体与排版 */
  --font-main: system-ui, -apple-system, "PingFang SC", "Microsoft YaHei", "Segoe UI", Roboto, sans-serif;
  --line-height-base: 1.65;
  --line-height-tight: 1.1;
  --letter-spacing-heading: -0.02em;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--font-main);
  font-size: 16px;
  line-height: var(--line-height-base);
  color: var(--color-text);
  background-color: var(--color-paper);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img, svg { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; }
button, input, select, textarea { font: inherit; color: inherit; }

/* === 容器与布局 === */
.container {
  width: 100%;
  max-width: var(--content-max);
  margin-inline: auto;
  padding-inline: var(--gap);
}
.section {
  padding-block: var(--section-y);
  position: relative;
}
.grid-2 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(0, 1fr));
  gap: var(--gap);
  align-items: center;
}
@media (min-width: 900px) {
  .grid-2.hero-layout { grid-template-columns: 1.1fr 0.9fr; }
  .grid-2.split-row:nth-child(even) { direction: rtl; }
  .grid-2.split-row:nth-child(even) > * { direction: ltr; }
}

/* === 主题表面控制 === */
.paper-surface { background-color: var(--color-paper); }
.dark-surface {
  background-color: var(--color-dark);
  color: var(--color-paper);
}
.card-light {
  background-color: var(--color-paper);
  color: var(--color-text);
}
.text-fg { color: var(--fg-color, currentColor); }
.text-hl { color: var(--hl-color, currentColor); }

/* 表面变量覆盖 */
.dark-surface { --fg-color: var(--color-paper); --hl-color: var(--color-accent); }
.paper-surface { --fg-color: var(--color-text); --hl-color: var(--color-brand); }
.card-light { --fg-color: var(--color-text); --hl-color: var(--color-brand); }

/* === 排版组件 === */
.badge {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  margin-bottom: 0.75rem;
  color: var(--hl-color);
}
h1 {
  font-size: clamp(2.4rem, 6vw, 4.5rem);
  font-weight: 800;
  line-height: var(--line-height-tight);
  letter-spacing: var(--letter-spacing-heading);
  margin-bottom: 1.25rem;
  text-wrap: balance;
}
h2 {
  font-size: clamp(1.6rem, 3vw, 2.4rem);
  font-weight: 800;
  line-height: 1.25;
  letter-spacing: var(--letter-spacing-heading);
  margin-bottom: 1.5rem;
  text-wrap: balance;
}
h3 {
  font-size: clamp(1.1rem, 2vw, 1.35rem);
  font-weight: 700;
  line-height: 1.3;
  margin-bottom: 0.75rem;
}
p { margin-bottom: 1rem; max-width: 38em; }
.lead { font-size: clamp(1rem, 1.5vw, 1.15rem); line-height: 1.7; margin-bottom: 1.5rem; }
.fact-line { font-size: 0.85rem; opacity: 0.85; margin-top: 0.5rem; }

/* === 按钮 === */
.btn-group { display: flex; flex-wrap: wrap; gap: 0.75rem; margin-top: 1.5rem; }
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  height: 48px;
  padding-inline: 1.25rem;
  font-weight: 600;
  font-size: 1rem;
  border-radius: var(--radius-btn);
  cursor: pointer;
  transition: transform 0.2s ease, filter 0.2s ease;
  white-space: nowrap;
}
.btn:hover { transform: translateY(-1px); }
.btn:focus-visible { outline: 2px solid var(--hl-color); outline-offset: 2px; }
.btn-primary {
  background-color: var(--color-accent);
  color: var(--color-dark);
  border: none;
}
.btn-secondary {
  background: transparent;
  border: 1px solid var(--fg-color);
  color: var(--fg-color);
}
.btn-icon { width: 20px; height: 20px; stroke-width: 2; }

/* === 卡片与面板 === */
.card {
  background: var(--card-bg, var(--color-paper));
  border: var(--card-border, 0);
  box-shadow: var(--card-shadow, none);
  border-radius: var(--radius-card);
  padding: var(--gap);
  margin-bottom: var(--gap);
}
.panel {
  background: var(--panel-bg, var(--color-dark));
  border-radius: 12px;
  padding: clamp(1.5rem, 3vw, 2.5rem);
  aspect-ratio: 4 / 3;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  position: relative;
}

/* === 表格 === */
.spec-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 1rem;
}
.spec-table td {
  padding: 0.75rem 0;
  border-bottom: 1px solid rgba(128,128,128,0.2);
  vertical-align: top;
}
.spec-table td:first-child { font-weight: 600; width: 40%; }
.spec-table td:last-child { width: 60%; }

/* === FAQ === */
.faq-item {
  border-bottom: 1px solid rgba(128,128,128,0.25);
  margin-bottom: 0.5rem;
}
.faq-item summary {
  padding: 1rem 0;
  cursor: pointer;
  font-weight: 600;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: "+";
  font-size: 1.25rem;
  font-weight: 400;
  transition: transform 0.2s ease;
}
.faq-item[open] summary::after { transform: rotate(45deg); }
.faq-item p { margin-top: 0.5rem; margin-bottom: 0; font-size: 0.95rem; opacity: 0.9; }

/* === 新闻卡片 === */
.news-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: var(--gap);
}
.news-card {
  background: var(--card-bg, var(--color-paper));
  border: var(--card-border, 0);
  border-radius: var(--radius-card);
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}
.news-date { font-size: 0.8rem; opacity: 0.7; }
.news-excerpt { font-size: 0.9rem; line-height: 1.6; opacity: 0.85; }

/* === 步骤条 === */
.steps-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: var(--gap);
  counter-reset: step;
}
.step-item {
  position: relative;
  padding-left: 3rem;
}
.step-item::before {
  counter-increment: step;
  content: counter(step, decimal-leading-zero);
  position: absolute;
  left: 0;
  top: 0;
  width: 2rem;
  height: 2rem;
  background: var(--color-accent);
  color: var(--color-dark);
  font-weight: 700;
  font-size: 0.9rem;
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* === 场景卡片 === */
.scenario-block {
  border-left: 3px solid var(--hl-color);
  padding-left: 1.25rem;
  margin-bottom: 1.5rem;
}
.scenario-tag {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.25rem 0.5rem;
  border-radius: 4px;
  background: rgba(82, 20, 235, 0.1);
  color: var(--color-brand);
  margin-bottom: 0.5rem;
}
.dark-surface .scenario-tag {
  background: rgba(110, 237, 210, 0.15);
  color: var(--color-accent);
}
.scenario-flow {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}
.flow-step {
  display: flex;
  gap: 0.75rem;
  align-items: flex-start;
}
.flow-label {
  font-weight: 600;
  font-size: 0.85rem;
  min-width: 3.5ch;
  padding-top: 0.15rem;
}

/* === 头部与页脚 === */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(252, 252, 253, 0.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid rgba(0,0,0,0.06);
}
.dark-surface .site-header {
  background: rgba(20, 14, 37, 0.92);
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}
.nav-links { display: flex; gap: 1.5rem; align-items: center; }
.nav-link { font-size: 0.95rem; font-weight: 500; transition: opacity 0.2s; }
.nav-link:hover { opacity: 0.8; }
.nav-link[aria-current="page"] { font-weight: 700; opacity: 1; }
.footer {
  padding-block: 2rem;
  border-top: 1px solid rgba(128,128,128,0.2);
  font-size: 0.9rem;
  text-align: center;
  opacity: 0.85;
}

/* === SVG 动效系统 === */
.hero-svg {
  width: 100%;
  height: auto;
  max-width: 600px;
  display: block;
}
.anim-draw {
  pathLength: 1;
  stroke-dasharray: 1;
  stroke-dashoffset: 0;
}
@keyframes draw-path {
  0% { stroke-dashoffset: 1; }
  100% { stroke-dashoffset: 0; }
}
.anim-draw.delay-1 { animation: draw-path 1.2s cubic-bezier(0.4, 0, 0.2, 1) 0.3s forwards; }
.anim-draw.delay-2 { animation: draw-path 1.4s cubic-bezier(0.4, 0, 0.2, 1) 0.6s forwards; }
.anim-draw.delay-3 { animation: draw-path 1.1s cubic-bezier(0.4, 0, 0.2, 1) 0.9s forwards; }

.anim-breathe {
  transform-box: fill-box;
  transform-origin: center;
  animation: breathe 6s ease-in-out infinite alternate;
}
@keyframes breathe {
  0% { transform: scale(0.98); opacity: 0.7; }
  100% { transform: scale(1.02); opacity: 1; }
}
.anim-breathe.slow { animation-duration: 8s; }
.anim-breathe.fast { animation-duration: 4.5s; }

.anim-slide-up {
  animation: slide-up 5s ease-in-out infinite alternate;
}
@keyframes slide-up {
  0% { transform: translateY(2px); }
  100% { transform: translateY(-4px); }
}
.anim-pulse-dot {
  animation: pulse-dot 3s ease-in-out infinite alternate;
}
@keyframes pulse-dot {
  0% { r: 3; opacity: 0.6; }
  100% { r: 4.5; opacity: 1; }
}

/* === 响应式与无障碍 === */
@media (max-width: 768px) {
  .nav-links { gap: 1rem; }
  .btn-group { flex-direction: column; }
  .btn { width: 100%; }
  h1 { font-size: clamp(2rem, 8vw, 2.8rem); }
  .grid-2.hero-layout { grid-template-columns: 1fr; }
  .grid-2.split-row { grid-template-columns: 1fr; }
}

@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;
  }
}

/* 兜底：裁掉横向溢出 */
body > * {
  overflow-x: clip;
}
