/* ===== 设计变量 ===== */
:root {
  /* 色板 */
  --color-dark: #21163C;
  --color-paper: #E9E8EA;
  --color-body: #191523;
  --color-brand: #5214EB;
  --color-accent: #ED926E;

  /* 圆角 */
  --radius-card: 20px;
  --radius-btn: 12px;

  /* 卡片边界与阴影 */
  --card-border: 0;
  --card-shadow: 0 10px 28px -14px rgba(25, 21, 35, 0.3);

  /* 节奏与密度 */
  --section-y: clamp(3.5rem, 7vw, 6rem);
  --gap: clamp(1rem, 2vw, 1.75rem);
  --content-max: 960px;
  --line-height-body: 1.65;

  /* 标题处理 */
  --title-weight: 800;
  --title-tracking: -0.02em;
  --title-line-height: 1.1;
}

/* ===== 基础排版 ===== */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans SC", sans-serif;
  font-size: 16px;
  line-height: var(--line-height-body);
  color: var(--color-body);
  background-color: var(--color-paper);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

img, svg {
  display: block;
  max-width: 100%;
  height: auto;
}

a {
  color: inherit;
  text-decoration: none;
}

ul, ol {
  list-style: none;
}

/* ===== 容器 ===== */
.container {
  width: 100%;
  max-width: var(--content-max);
  margin: 0 auto;
  padding-left: var(--gap);
  padding-right: var(--gap);
}

/* ===== 页头 ===== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background-color: rgba(233, 232, 234, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(25, 21, 35, 0.08);
  transition: background-color 0.3s;
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}

.site-logo {
  display: flex;
  align-items: center;
  gap: 8px;
}

.site-logo img {
  width: 32px;
  height: 32px;
  object-fit: contain;
}

.site-logo span {
  font-size: 1.125rem;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 24px;
}

.site-nav a {
  font-size: 0.9375rem;
  font-weight: 500;
  color: var(--color-body);
  padding: 6px 0;
  position: relative;
  transition: color 0.2s;
}

.site-nav a:hover {
  color: var(--color-brand);
}

.site-nav a[aria-current="page"] {
  color: var(--color-brand);
  font-weight: 700;
}

.site-nav a[aria-current="page"]::after {
  content: "";
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 100%;
  height: 2px;
  background-color: var(--color-brand);
  border-radius: 1px;
}

.header-cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 20px;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--color-dark);
  background-color: var(--color-accent);
  border: none;
  border-radius: var(--radius-btn);
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
}

.header-cta:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(237, 146, 110, 0.35);
}

.header-cta:focus-visible {
  outline: none;
  box-shadow: 0 0 0 3px rgba(237, 146, 110, 0.5), 0 4px 12px rgba(237, 146, 110, 0.35);
}

.header-cta svg {
  width: 18px;
  height: 18px;
  stroke-width: 2;
}

/* ===== 按钮通用 ===== */
.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 48px;
  padding: 0 28px;
  font-size: 1rem;
  font-weight: 600;
  color: var(--color-dark);
  background-color: var(--color-accent);
  border: none;
  border-radius: var(--radius-btn);
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s, background-color 0.2s;
  white-space: nowrap;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(237, 146, 110, 0.4);
  background-color: #f0a484;
}

.btn-primary:focus-visible {
  outline: none;
  box-shadow: 0 0 0 3px rgba(237, 146, 110, 0.5), 0 8px 24px rgba(237, 146, 110, 0.4);
}

.btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 48px;
  padding: 0 28px;
  font-size: 1rem;
  font-weight: 600;
  color: var(--color-body);
  background-color: transparent;
  border: 1.5px solid var(--color-body);
  border-radius: var(--radius-btn);
  cursor: pointer;
  transition: transform 0.2s, border-color 0.2s, color 0.2s;
  white-space: nowrap;
}

.btn-secondary:hover {
  transform: translateY(-2px);
  border-color: var(--color-brand);
  color: var(--color-brand);
}

.btn-secondary:focus-visible {
  outline: none;
  box-shadow: 0 0 0 3px rgba(82, 20, 235, 0.4);
}

/* 深色面上的按钮变体 */
.surface-dark .btn-primary {
  color: var(--color-dark);
}

.surface-dark .btn-secondary {
  color: var(--color-paper);
  border-color: var(--color-paper);
}

.surface-dark .btn-secondary:hover {
  color: var(--color-accent);
  border-color: var(--color-accent);
}

/* ===== 眉标 ===== */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-bottom: 12px;
}

.eyebrow-line {
  display: inline-block;
  width: 18px;
  height: 2px;
  border-radius: 1px;
  background-color: currentColor;
}

/* 纸面上用品牌色 */
.paper-surface .eyebrow {
  color: var(--color-brand);
}

/* 深色面上用强调色 */
.surface-dark .eyebrow {
  color: var(--color-accent);
}

/* ===== 标题 ===== */
h1, h2, h3, h4 {
  font-weight: var(--title-weight);
  letter-spacing: var(--title-tracking);
  line-height: var(--title-line-height);
}

h1 {
  font-size: clamp(2.4rem, 6vw, 4.5rem);
}

h2 {
  font-size: clamp(1.6rem, 3vw, 2.4rem);
  line-height: 1.25;
}

h3 {
  font-size: clamp(1.2rem, 2vw, 1.5rem);
  line-height: 1.3;
}

p {
  max-width: 38em;
}

/* ===== 高亮关键词 ===== */
.hl {
  color: var(--color-brand);
}

.surface-dark .hl {
  color: var(--color-accent);
}

/* ===== 区块通用 ===== */
.section {
  padding-top: var(--section-y);
  padding-bottom: var(--section-y);
}

.section-header {
  margin-bottom: calc(var(--gap) * 2);
}

/* ===== 卡片 ===== */
.card {
  background-color: var(--color-paper);
  border-radius: var(--radius-card);
  border: var(--card-border);
  box-shadow: var(--card-shadow);
  padding: 24px;
  transition: box-shadow 0.3s, transform 0.2s;
}

.card:hover {
  box-shadow: 0 14px 32px -12px rgba(25, 21, 35, 0.35);
  transform: translateY(-2px);
}

/* ===== 表格 ===== */
.data-table {
  width: 100%;
  min-width: 0;
  border-collapse: collapse;
  font-size: 0.9375rem;
}

.data-table th,
.data-table td {
  padding: 12px 16px;
  text-align: left;
  border-bottom: 1px solid rgba(25, 21, 35, 0.1);
  max-width: 100%;
  overflow-wrap: break-word;
  word-break: break-word;
}

.data-table th {
  font-weight: 700;
  color: var(--color-body);
}

.data-table td:first-child {
  font-weight: 600;
  white-space: nowrap;
}

.data-table tr:last-child td {
  border-bottom: none;
}

/* ===== FAQ ===== */
.faq-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.faq-item summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  border-radius: var(--radius-card);
  background-color: rgba(25, 21, 35, 0.03);
  transition: background-color 0.2s;
  list-style: none;
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item summary::after {
  content: "+";
  font-size: 1.25rem;
  font-weight: 400;
  color: var(--color-brand);
  transition: transform 0.2s;
  flex-shrink: 0;
  margin-left: 16px;
}

.faq-item[open] summary::after {
  transform: rotate(45deg);
}

.faq-item summary:hover {
  background-color: rgba(25, 21, 35, 0.06);
}

.faq-item summary:focus-visible {
  outline: none;
  box-shadow: inset 0 0 0 2px var(--color-brand);
}

.faq-item .faq-answer {
  padding: 16px 20px;
  font-size: 0.9375rem;
  line-height: 1.7;
  color: var(--color-body);
}

/* ===== 视觉面板（深色背景圆角面板） ===== */
.visual-panel {
  background-color: var(--color-dark);
  border-radius: var(--radius-card);
  padding: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 320px;
  position: relative;
  overflow: hidden;
}

/* ===== 图文交错行 ===== */
.split-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: calc(var(--gap) * 2);
  align-items: center;
}

.split-row.reverse .split-text {
  order: 2;
}

.split-row.reverse .split-visual {
  order: 1;
}

.split-text h3 {
  margin-bottom: 12px;
}

.split-text p {
  margin-bottom: 12px;
}

.split-text ul {
  padding-left: 0;
}

.split-text ul li {
  position: relative;
  padding-left: 20px;
  margin-bottom: 8px;
}

.split-text ul li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 8px;
  width: 6px;
  height: 6px;
  border-radius: 2px;
  background-color: var(--color-brand);
}

/* ===== 时间轴 ===== */
.timeline {
  position: relative;
  padding-left: 32px;
}

.timeline::before {
  content: "";
  position: absolute;
  left: 11px;
  top: 0;
  bottom: 0;
  width: 2px;
  background-color: rgba(82, 20, 235, 0.15);
  border-radius: 1px;
}

.timeline-item {
  position: relative;
  margin-bottom: 32px;
}

.timeline-item:last-child {
  margin-bottom: 0;
}

.timeline-marker {
  position: absolute;
  left: -32px;
  top: 4px;
  width: 24px;
  height: 24px;
  border-radius: 8px;
  background-color: var(--color-brand);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-paper);
  font-size: 0.75rem;
  font-weight: 700;
}

.timeline-time {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--color-brand);
  margin-bottom: 4px;
}

.timeline-content h4 {
  font-size: 1.05rem;
  font-weight: 700;
  margin-bottom: 6px;
}

.timeline-content p {
  font-size: 0.9375rem;
}

/* ===== 步骤编号徽标 ===== */
.step-list {
  counter-reset: step-counter;
}

.step-item {
  counter-increment: step-counter;
  display: flex;
  gap: 16px;
  margin-bottom: 24px;
  align-items: flex-start;
}

.step-item:last-child {
  margin-bottom: 0;
}

.step-badge {
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background-color: var(--color-accent);
  color: var(--color-dark);
  font-size: 0.875rem;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
}

.step-text h4 {
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 4px;
}

.step-text p {
  font-size: 0.9375rem;
  color: var(--color-body);
}

/* ===== 资讯卡片网格 ===== */
.news-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--gap);
}

.news-card {
  background-color: rgba(25, 21, 35, 0.03);
  border: 1px solid rgba(25, 21, 35, 0.08);
  border-radius: var(--radius-card);
  padding: 20px;
  transition: box-shadow 0.3s, border-color 0.3s;
}

.news-card:hover {
  box-shadow: var(--card-shadow);
  border-color: rgba(82, 20, 235, 0.15);
}

.news-card time {
  display: block;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--color-brand);
  margin-bottom: 8px;
}

.news-card h4 {
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 8px;
  line-height: 1.35;
}

.news-card p {
  font-size: 0.875rem;
  line-height: 1.6;
  color: var(--color-body);
}

/* ===== 提示框 ===== */
.callout {
  border-left: 3px solid var(--color-brand);
  padding: 16px 20px;
  margin: 24px 0;
  border-radius: 0 var(--radius-card) var(--radius-card) 0;
  background-color: rgba(82, 20, 235, 0.04);
  font-size: 0.9375rem;
}

.callout strong {
  display: block;
  margin-bottom: 4px;
  font-weight: 700;
}

/* ===== 特性胶囊 ===== */
.capsule-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 24px;
}

.capsule {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  border-radius: 100px;
  background-color: rgba(82, 20, 235, 0.06);
  border: 1px solid rgba(82, 20, 235, 0.12);
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--color-body);
}

.capsule svg {
  width: 16px;
  height: 16px;
  stroke-width: 2;
  flex-shrink: 0;
}

/* ===== 页脚 ===== */
.site-footer {
  background-color: var(--color-dark);
  color: var(--color-paper);
  padding: 48px 0 32px;
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 32px;
  flex-wrap: wrap;
}

.footer-brand {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.footer-brand img {
  width: 28px;
  height: 28px;
}

.footer-brand span {
  font-size: 1rem;
  font-weight: 700;
}

.footer-links {
  display: flex;
  gap: 32px;
}

.footer-links a {
  font-size: 0.875rem;
  color: rgba(233, 232, 234, 0.7);
  transition: color 0.2s;
}

.footer-links a:hover {
  color: var(--color-accent);
}

.footer-bottom {
  margin-top: 32px;
  padding-top: 24px;
  border-top: 1px solid rgba(233, 232, 234, 0.1);
  font-size: 0.8rem;
  color: rgba(233, 232, 234, 0.5);
  text-align: center;
}

/* ===== 响应式 ===== */
@media (max-width: 768px) {
  .site-nav {
    display: none;
  }

  .split-row {
    grid-template-columns: 1fr;
  }

  .split-row.reverse .split-text {
    order: 1;
  }

  .split-row.reverse .split-visual {
    order: 2;
  }

  .news-grid {
    grid-template-columns: 1fr;
  }

  .footer-inner {
    flex-direction: column;
    gap: 24px;
  }

  .footer-links {
    flex-wrap: wrap;
    gap: 16px;
  }

  .visual-panel {
    min-height: 240px;
    padding: 20px;
  }
}

@media (max-width: 480px) {
  .capsule-row {
    flex-direction: column;
  }

  .btn-primary, .btn-secondary {
    width: 100%;
  }
}

/* ===== SVG 动效 ===== */

/* 卡片层叠漂浮 */
@keyframes floatA {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}

@keyframes floatB {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-5px); }
}

@keyframes floatC {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-12px); }
}

.anim-float-a {
  animation: floatA 6s ease-in-out infinite;
}

.anim-float-b {
  animation: floatB 7.5s ease-in-out infinite;
}

.anim-float-c {
  animation: floatC 8s ease-in-out infinite;
}

/* 气泡依次浮现 */
@keyframes bubbleIn {
  0%, 10% { opacity: 0; transform: translateY(8px); }
  15%, 85% { opacity: 1; transform: translateY(0); }
  90%, 100% { opacity: 0; transform: translateY(8px); }
}

.anim-bubble-1 { animation: bubbleIn 8s ease-in-out infinite 0s; }
.anim-bubble-2 { animation: bubbleIn 8s ease-in-out infinite 1.5s; }
.anim-bubble-3 { animation: bubbleIn 8s ease-in-out infinite 3s; }

/* 输入中呼吸点 */
@keyframes breathe {
  0%, 100% { opacity: 0.3; }
  50% { opacity: 1; }
}

.anim-breathe-1 { animation: breathe 2s ease-in-out infinite 0s; }
.anim-breathe-2 { animation: breathe 2s ease-in-out infinite 0.3s; }
.anim-breathe-3 { animation: breathe 2s ease-in-out infinite 0.6s; }

/* 通知卡片滑入 */
@keyframes notifSlide {
  0%, 5% { opacity: 0; transform: translateX(20px); }
  10%, 40% { opacity: 1; transform: translateX(0); }
  45%, 50% { opacity: 0; transform: translateX(20px); }
  55%, 100% { opacity: 0; transform: translateX(20px); }
}

.anim-notif {
  animation: notifSlide 10s ease-in-out infinite;
}

/* 连接线流动 */
@keyframes dashFlow {
  from { stroke-dashoffset: 1; }
  to { stroke-dashoffset: 0; }
}

.anim-flow {
  stroke-dasharray: 1;
  stroke-dashoffset: 0;
  animation: dashFlow 3s linear infinite;
}

/* 扫描线循环 */
@keyframes scanPulse {
  0%, 100% { opacity: 0.15; }
  50% { opacity: 0.6; }
}

.anim-scan {
  animation: scanPulse 4s ease-in-out infinite;
}

/* 设置面板微旋转 */
@keyframes subtleRotate {
  0%, 100% { transform: rotate(0deg); }
  50% { transform: rotate(2deg); }
}

.anim-subtle-rotate {
  transform-box: fill-box;
  transform-origin: center;
  animation: subtleRotate 6s ease-in-out infinite;
}

/* ===== 减少动态效果 ===== */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
