:root {
  --color-dark: #271231;
  --color-paper: #F6F3F7;
  --color-text: #1F1523;
  --color-brand: #9E13DD;
  --color-accent: #ED6EC0;
  --color-white: #FFFFFF;
  --radius-card: 0;
  --radius-btn: 0;
  --card-border: 0;
  --card-shadow: 0 10px 28px -14px rgba(31,21,35,0.3);
  --section-y: clamp(5rem, 10vw, 9rem);
  --gap: clamp(1.5rem, 3vw, 2.5rem);
  --content-max: 1280px;
  --font-main: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font-main);
  color: var(--color-text);
  background: var(--color-paper);
  line-height: 1.75;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; }

.container { max-width: var(--content-max); margin: 0 auto; padding: 0 var(--gap); }

/* Header & Nav */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--color-paper);
  border-bottom: 1px solid rgba(31,21,35,0.08);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}
.brand-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 1.125rem;
  color: var(--color-text);
}
.brand-logo img { width: 32px; height: 32px; object-fit: contain; }
.main-nav ul { display: flex; gap: 24px; align-items: center; }
.main-nav a {
  font-weight: 500;
  font-size: 0.95rem;
  transition: color 0.2s;
}
.main-nav a:hover, .main-nav a[aria-current="page"] { color: var(--color-brand); }
.nav-btn {
  padding: 8px 16px;
  font-size: 0.9rem;
  height: 36px;
}

/* Typography */
h1, h2, h3 { font-weight: 700; letter-spacing: 0.02em; line-height: 1.25; color: inherit; }
h1 { font-size: clamp(2.2rem, 5vw, 3.8rem); text-wrap: balance; }
h2 { font-size: clamp(1.6rem, 3vw, 2.4rem); margin-bottom: 1rem; }
h3 { font-size: 1.25rem; margin-bottom: 0.75rem; }
.section-label {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--color-brand);
  margin-bottom: 0.5rem;
}
.dark-surface .section-label { color: var(--color-accent); }
.hl { color: var(--color-brand); }
.dark-surface .hl { color: var(--color-accent); }
p { margin-bottom: 1rem; max-width: 38em; }
ul.feature-list li { position: relative; padding-left: 1.25rem; margin-bottom: 0.5rem; }
ul.feature-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.6em;
  width: 6px;
  height: 6px;
  background: var(--color-brand);
}
.dark-surface ul.feature-list li::before { background: var(--color-accent); }

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 0 24px;
  height: 52px;
  font-weight: 600;
  font-size: 1rem;
  cursor: pointer;
  border: none;
  transition: transform 0.2s, background 0.2s, box-shadow 0.2s;
}
.btn-primary { background: var(--color-accent); color: var(--color-dark); }
.btn-primary:hover { transform: translateY(-2px); background: #d95aab; }
.btn-secondary { background: transparent; border: 1px solid var(--color-text); color: var(--color-text); }
.dark-surface .btn-secondary { border-color: var(--color-paper); color: var(--color-paper); }
.btn-secondary:hover { background: rgba(31,21,35,0.05); }
.dark-surface .btn-secondary:hover { background: rgba(255,255,255,0.05); }
.btn:focus-visible { outline: 3px solid var(--color-accent); outline-offset: 2px; }

/* Layout Grids */
.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; gap: var(--gap); align-items: center; }
.flex-col { flex-direction: column; }

/* Cards */
.card {
  background: var(--color-paper);
  border: var(--card-border);
  box-shadow: var(--card-shadow);
  padding: 24px;
}
.dark-surface .card {
  background: rgba(255,255,255,0.06);
  box-shadow: none;
}

/* Tables */
.data-table-wrapper { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.data-table { min-width: 480px; width: 100%; border-collapse: collapse; margin: 1.5rem 0; }
.data-table th, .data-table td { padding: 12px 16px; border-bottom: 1px solid rgba(31,21,35,0.1); text-align: left; vertical-align: top; }
.data-table th { font-weight: 700; white-space: nowrap; }
.data-table tr:last-child td { border-bottom: none; }
.dark-surface .data-table th, .dark-surface .data-table td { border-bottom-color: rgba(255,255,255,0.1); }

/* FAQ */
.faq-item { margin-bottom: 1rem; border-bottom: 1px solid rgba(31,21,35,0.1); padding-bottom: 1rem; }
.faq-item summary { 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.2rem; font-weight: 400; }
.faq-item[open] summary::after { content: "-"; }
.faq-item p { margin-top: 0.75rem; }

/* Steps */
.step-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  background: var(--color-accent);
  color: var(--color-dark);
  font-weight: 700;
  font-size: 0.9rem;
  margin-right: 12px;
}

/* SVG Animation Classes */
.svg-line {
  pathLength: 1;
  stroke-dasharray: 1;
  stroke-dashoffset: 0;
  animation: draw-line 6s ease-in-out infinite;
}
@keyframes draw-line {
  0%, 100% { stroke-dashoffset: 1; opacity: 0.4; }
  50% { stroke-dashoffset: 0; opacity: 1; }
}
.svg-node {
  animation: node-pulse 4s ease-in-out infinite;
  transform-box: fill-box;
  transform-origin: center;
}
@keyframes node-pulse {
  0%, 100% { opacity: 0.25; transform: scale(0.8); }
  50% { opacity: 1; transform: scale(1); }
}
.node-stagger-1 { animation-delay: 0s; }
.node-stagger-2 { animation-delay: 0.8s; }
.node-stagger-3 { animation-delay: 1.6s; }
.node-stagger-4 { animation-delay: 2.4s; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* Utility */
.text-center { text-align: center; }
.mt-1 { margin-top: 1rem; }
.mb-2 { margin-bottom: 2rem; }
.overflow-hidden { overflow: hidden; }

/* 兜底：裁掉横向溢出 */
div {
  overflow-x: clip;
}
