/* 设计变量 */
:root {
  /* 色板 */
  --color-dark: #121531;
  --color-paper: #E8E9EA;
  --color-paper-light: #F3F4F5;
  --color-text: #151723;
  --color-brand: #142CEB;
  --color-accent: #ED7D6E;
  
  /* 组件变量 */
  --radius-card: 24px;
  --radius-btn: 999px;
  --card-border: 0;
  --card-shadow: none;
  
  /* 节奏与密度 */
  --section-y: clamp(3.5rem, 7vw, 6rem);
  --gap: clamp(1rem, 2vw, 1.75rem);
  --content-max: 1120px;
  
  /* 字体 */
  --font-sans: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
}

/* 基础重置与排版 */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-sans);
  color: var(--color-text);
  background-color: var(--color-paper);
  line-height: 1.65;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img, svg {
  display: block;
  max-width: 100%;
}

a {
  text-decoration: none;
  color: inherit;
  transition: color 0.2s ease;
}

ul, ol {
  list-style: none;
}

/* 布局容器 */
.container {
  width: 100%;
  max-width: var(--content-max);
  margin: 0 auto;
  padding: 0 var(--gap);
}

/* 区块通用 */
.section {
  padding: var(--section-y) 0;
}

.section-dark {
  background-color: var(--color-dark);
  color: var(--color-paper);
}

.section-paper {
  background-color: var(--color-paper);
  color: var(--color-text);
}

.section-paper-light {
  background-color: var(--color-paper-light);
  color: var(--color-text);
}

/* 眉标与标题 */
.eyebrow {
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  margin-bottom: 0.75rem;
  display: inline-block;
}

.paper .eyebrow, .paper-light .eyebrow {
  color: var(--color-brand);
}

.dark .eyebrow {
  color: var(--color-accent);
}

h1, h2, h3 {
  font-weight: 700;
  letter-spacing: 0.02em;
  line-height: 1.25;
}

h1 {
  font-size: clamp(2.2rem, 5vw, 3.8rem);
  margin-bottom: 1rem;
}

h2 {
  font-size: clamp(1.6rem, 3vw, 2.4rem);
  margin-bottom: 1.5rem;
}

h3 {
  font-size: 1.25rem;
  margin-bottom: 0.75rem;
}

/* 高亮关键词 */
.hl {
  color: var(--color-brand);
}

.dark .hl {
  color: var(--color-accent);
}

/* 按钮 */
.btn-group {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  margin-top: 1.5rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  height: 48px;
  padding: 0 1.5rem;
  border-radius: var(--radius-btn);
  font-weight: 600;
  font-size: 1rem;
  cursor: pointer;
  transition: transform 0.2s ease, opacity 0.2s ease;
  white-space: nowrap;
}

.btn:hover {
  transform: translateY(-1px);
}

.btn:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 2px;
}

.btn-primary {
  background-color: var(--color-accent);
  color: var(--color-dark);
}

.btn-secondary {
  border: 1px solid var(--color-text);
  color: var(--color-text);
  background: transparent;
}

.dark .btn-secondary {
  border-color: var(--color-paper);
  color: var(--color-paper);
}

.btn-icon {
  width: 20px;
  height: 20px;
  stroke-width: 2;
}

/* 卡片 */
.card {
  background: var(--color-paper-light);
  border: var(--card-border);
  box-shadow: var(--card-shadow);
  border-radius: var(--radius-card);
  padding: var(--gap);
  position: relative;
  overflow: hidden;
}

.dark .card {
  background: rgba(255, 255, 255, 0.05);
}

/* 表格 */
.table-wrapper {
  overflow-x: auto;
  border-radius: var(--radius-card);
  background: var(--color-paper-light);
  padding: 1rem;
}

.dark .table-wrapper {
  background: rgba(255, 255, 255, 0.05);
}

table {
  width: 100%;
  border-collapse: collapse;
  min-width: 400px;
}

th, td {
  text-align: left;
  padding: 1rem;
  border-bottom: 1px solid rgba(0, 0, 0, 0.1);
}

.dark th, td {
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

th {
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--color-brand);
}

.dark th {
  color: var(--color-accent);
}

tr:last-child td {
  border-bottom: none;
}

td strong {
  display: block;
  font-weight: 600;
  margin-bottom: 0.25rem;
}

/* FAQ */
.faq-item {
  margin-bottom: 1rem;
  border-radius: 12px;
  overflow: hidden;
  background: var(--color-paper-light);
}

.dark .faq-item {
  background: rgba(255, 255, 255, 0.05);
}

summary {
  padding: 1rem 1.5rem;
  cursor: pointer;
  font-weight: 600;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  transition: background 0.2s;
}

summary:hover {
  background: rgba(0,0,0,0.02);
}

summary::-webkit-details-marker {
  display: none;
}

summary::after {
  content: "+";
  font-size: 1.2rem;
  font-weight: 400;
}

details[open] summary::after {
  content: "−";
}

.faq-content {
  padding: 0 1.5rem 1.5rem;
  font-size: 0.95rem;
  line-height: 1.7;
}

/* 页头页脚 */
.header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(232, 233, 234, 0.85);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(0,0,0,0.05);
  padding: 0.75rem 0;
}

.dark-header {
  background: rgba(18, 21, 49, 0.85);
  border-bottom: 1px solid rgba(255,255,255,0.05);
}

.nav-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 700;
  font-size: 1.1rem;
}

.logo img {
  height: 32px;
  width: auto;
}

.nav-links {
  display: flex;
  gap: 1.5rem;
  align-items: center;
}

.nav-link {
  font-size: 0.9rem;
  font-weight: 500;
  opacity: 0.8;
}

.nav-link:hover, .nav-link[aria-current="page"] {
  opacity: 1;
  color: var(--color-brand);
}

.dark .nav-link[aria-current="page"], .dark .nav-link:hover {
  color: var(--color-accent);
}

.footer {
  padding: 3rem 0;
  border-top: 1px solid rgba(0,0,0,0.05);
  margin-top: 2rem;
}

.dark .footer {
  border-top: 1px solid rgba(255,255,255,0.05);
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 2rem;
}

.footer-col h4 {
  font-size: 0.9rem;
  font-weight: 700;
  margin-bottom: 1rem;
  opacity: 0.7;
}

.footer-col a {
  display: block;
  margin-bottom: 0.5rem;
  font-size: 0.9rem;
  opacity: 0.8;
}

.footer-col a:hover {
  opacity: 1;
  color: var(--color-brand);
}

.dark .footer-col a:hover {
  color: var(--color-accent);
}

/* SVG 动效基础 */
.svg-anim {
  width: 100%;
  height: auto;
}

.svg-anim path, .svg-anim circle, .svg-rect, .svg-line {
  fill: none;
  stroke: currentColor;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* 自绘描边动画 */
.draw-path {
  pathLength: 1;
  stroke-dasharray: 1;
  stroke-dashoffset: 0;
  animation: drawStroke 4s ease-in-out infinite alternate;
}

.breath {
  animation: breathe 4s ease-in-out infinite alternate;
}

.slide-up {
  animation: slideUp 6s ease-in-out infinite alternate;
}

.float {
  animation: floatAnim 5s ease-in-out infinite alternate;
}

@keyframes drawStroke {
  from { stroke-dashoffset: 1; }
  to { stroke-dashoffset: 0; }
}

@keyframes breathe {
  from { opacity: 0.7; transform: scale(0.98); }
  to { opacity: 1; transform: scale(1.02); }
}

@keyframes slideUp {
  from { transform: translateY(10px); opacity: 0.8; }
  to { transform: translateY(0); opacity: 1; }
}

@keyframes floatAnim {
  from { transform: translateY(0); }
  to { transform: translateY(-8px); }
}

/* 减少动态效果 */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
  .draw-path, .breath, .slide-up, .float {
    animation: none;
    opacity: 1;
    transform: none;
  }
}

/* 响应式调整 */
@media (max-width: 768px) {
  .nav-links {
    display: none; /* 简化移动端，实际项目可加汉堡菜单，此处为保持纯净静态 */
  }
  
  .grid-2, .grid-3 {
    grid-template-columns: 1fr !important;
  }
  
  .btn-group {
    flex-direction: column;
  }
  
  .btn {
    width: 100%;
  }
}

.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--gap);
}

.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--gap);
}

@media (max-width: 900px) {
  .grid-2, .grid-3 {
    grid-template-columns: 1fr;
  }
}

/* 图文交错布局 */
.split-section {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--gap);
  align-items: center;
}

@media (max-width: 900px) {
  .split-section {
    grid-template-columns: 1fr;
  }
}

.panel-bg {
  background: var(--color-dark);
  border-radius: var(--radius-card);
  padding: 2rem;
  position: relative;
  overflow: hidden;
  aspect-ratio: 4/3;
  display: flex;
  align-items: center;
  justify-content: center;
}

.paper .panel-bg {
  background: #fff;
  border: 1px solid rgba(0,0,0,0.05);
}

.panel-content {
  width: 100%;
  height: 100%;
  position: relative;
}

/* 提示框 */
.callout {
  border-left: 4px solid var(--color-brand);
  padding: 1rem 1.5rem;
  margin: 1.5rem 0;
  background: rgba(20, 44, 235, 0.05);
  border-radius: 0 12px 12px 0;
}

.dark .callout {
  border-color: var(--color-accent);
  background: rgba(237, 125, 110, 0.1);
}

.callout p {
  font-size: 0.95rem;
  margin: 0;
}

/* 步骤徽标 */
.step-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: var(--color-accent);
  color: var(--color-dark);
  font-weight: 700;
  font-size: 0.9rem;
  margin-right: 0.75rem;
  flex-shrink: 0;
}

.step-list li {
  display: flex;
  gap: 0.75rem;
  margin-bottom: 1.25rem;
  align-items: flex-start;
}

/* 资讯卡片 */
.news-card {
  background: var(--color-paper-light);
  border-radius: var(--radius-card);
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  height: 100%;
  transition: transform 0.2s;
}

.news-card:hover {
  transform: translateY(-4px);
}

.news-date {
  font-size: 0.8rem;
  color: var(--color-brand);
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.news-title {
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 0.75rem;
  line-height: 1.4;
}

.news-excerpt {
  font-size: 0.9rem;
  opacity: 0.8;
  line-height: 1.6;
  flex-grow: 1;
}

.dark .news-card {
  background: rgba(255,255,255,0.05);
}

.dark .news-date {
  color: var(--color-accent);
}

/* 纯文本段落限制 */
.prose p {
  margin-bottom: 1.25rem;
  max-width: 38em;
}

.prose ul {
  list-style: disc;
  padding-left: 1.5rem;
  margin-bottom: 1.25rem;
}

.prose li {
  margin-bottom: 0.5rem;
}

/* 焦点可见性 */
*:focus-visible {
  outline: 2px solid var(--color-brand);
  outline-offset: 2px;
}

.dark *:focus-visible {
  outline-color: var(--color-accent);
}

