/* ===== WhatsApp 品牌落地站 - 共享样式 ===== */

/* ---------- 设计变量 ---------- */
:root {
  --bg-primary: #070b11;
  --bg-secondary: #0c111a;
  --bg-card: #111824;
  --bg-card-hover: #162032;
  --text-primary: #e8edf4;
  --text-secondary: #8fa4be;
  --text-muted: #5a6e88;
  --accent: #25d366;
  --accent-dim: rgba(37, 211, 102, .18);
  --accent-glow: rgba(37, 211, 102, .35);
  --border-subtle: rgba(255, 255, 255, .06);
  --border-accent: rgba(37, 211, 102, .25);
  --radius-sm: 6px;
  --radius-md: 12px;
  --radius-lg: 20px;
  --max-w: 1200px;
  --header-h: 64px;
  --font-sans: 'Inter', 'PingFang SC', 'Microsoft YaHei', system-ui, sans-serif;
  --font-heading: 'Inter', 'PingFang SC', 'Noto Sans SC', system-ui, sans-serif;
}

/* ---------- Reset & 基础 ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--font-sans);
  background: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.7;
  font-size: 16px;
  overflow-x: hidden;
}
img, svg { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; }

/* ---------- 排版 ---------- */
h1, h2, h3, h4, h5, h6 { font-family: var(--font-heading); font-weight: 700; text-wrap: balance; line-height: 1.25; }
h1 { font-size: clamp(2rem, 5vw, 3.2rem); letter-spacing: -.02em; }
h2 { font-size: clamp(1.5rem, 3.5vw, 2.2rem); }
h3 { font-size: clamp(1.1rem, 2vw, 1.35rem); }
p { color: var(--text-secondary); }
.container { width: 100%; max-width: var(--max-w); margin: 0 auto; padding: 0 24px; }

/* ---------- Section 通用 ---------- */
.section { padding: 80px 0; position: relative; }
.section--alt { background: var(--bg-secondary); }
.section__title { margin-bottom: 12px; color: var(--text-primary); }
.section__desc { margin-bottom: 48px; max-width: 680px; }

/* ---------- Header / Nav ---------- */
.site-header {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  height: var(--header-h);
  background: rgba(7, 11, 17, .85);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-subtle);
}
.header-inner {
  display: flex; align-items: center; justify-content: space-between;
  height: var(--header-h);
}
.logo { display: flex; align-items: center; gap: 10px; }
.logo img { width: 28px; height: 28px; }
.logo span { font-weight: 700; font-size: 1.05rem; color: var(--text-primary); }
.main-nav { display: flex; gap: 28px; }
.main-nav a {
  font-size: .9rem; color: var(--text-secondary); transition: color .2s;
  position: relative;
}
.main-nav a:hover,
.main-nav a[aria-current="page"] { color: var(--accent); }
.main-nav a[aria-current="page"]::after {
  content: ''; position: absolute; bottom: -4px; left: 0; right: 0;
  height: 2px; background: var(--accent); border-radius: 1px;
}
.mobile-toggle { display: none; background: none; border: none; cursor: pointer; }
.mobile-toggle svg { stroke: var(--text-secondary); }

@media (max-width: 768px) {
  .main-nav { display: none; }
  .mobile-toggle { display: block; }
}

/* ---------- Footer ---------- */
.site-footer {
  padding: 48px 0 32px;
  border-top: 1px solid var(--border-subtle);
  background: var(--bg-secondary);
}
.footer-inner { display: flex; flex-direction: column; align-items: center; gap: 24px; text-align: center; }
.footer-links { display: flex; gap: 24px; flex-wrap: wrap; justify-content: center; }
.footer-links a { font-size: .85rem; color: var(--text-muted); transition: color .2s; }
.footer-links a:hover { color: var(--accent); }
.footer-copy { font-size: .8rem; color: var(--text-muted); }

/* ---------- 按钮 ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 12px 28px; border-radius: var(--radius-md); font-size: .95rem; font-weight: 600;
  cursor: pointer; border: none; transition: all .25s ease;
}
.btn--primary {
  background: var(--accent); color: #070b11;
  box-shadow: 0 4px 24px var(--accent-dim);
}
.btn--primary:hover { background: #2de06e; transform: translateY(-1px); box-shadow: 0 6px 32px var(--accent-glow); }
.btn--outline {
  background: transparent; color: var(--accent);
  border: 1.5px solid var(--border-accent);
}
.btn--outline:hover { background: var(--accent-dim); }
.btn svg { width: 18px; height: 18px; stroke: currentColor; fill: none; stroke-width: 2; }

/* ---------- 卡片 ---------- */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 28px;
  transition: border-color .25s, background .25s, transform .25s;
}
.card:hover { border-color: var(--border-accent); background: var(--bg-card-hover); transform: translateY(-2px); }
.card__icon { width: 44px; height: 44px; margin-bottom: 16px; }
.card__icon svg { width: 100%; height: 100%; stroke: var(--accent); stroke-width: 1.8; fill: none; }
.card__title { margin-bottom: 8px; }
.card__body { font-size: .92rem; color: var(--text-secondary); line-height: 1.65; }

/* ---------- 网格便当格 ---------- */
.grid-6 {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 20px;
}
@media (max-width: 700px) { .grid-6 { grid-template-columns: 1fr; } }

/* ---------- 功能图文交错 ---------- */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: center; }
.split--reverse { direction: rtl; }
.split--reverse > * { direction: ltr; }
@media (max-width: 860px) {
  .split, .split--reverse { grid-template-columns: 1fr; direction: ltr; }
}

/* ---------- 场景卡片 ---------- */
.scene-card { display: flex; gap: 20px; align-items: flex-start; }
.scene-num {
  flex-shrink: 0; width: 36px; height: 36px;
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: .95rem; color: var(--accent);
  border: 1.5px solid var(--border-accent); border-radius: 50%;
}
.scene-card p { font-size: .92rem; line-height: 1.65; }

/* ---------- 步骤 ---------- */
.steps { counter-reset: step; }
.steps li {
  position: relative; padding: 16px 0 16px 48px;
  border-left: 2px solid var(--border-subtle);
  counter-increment: step;
}
.steps li::before {
  content: counter(step);
  position: absolute; left: -12px; top: 16px;
  width: 24px; height: 24px;
  display: flex; align-items: center; justify-content: center;
  font-size: .8rem; font-weight: 700; color: var(--accent);
  background: var(--bg-card);
  border: 1.5px solid var(--border-accent);
  border-radius: 50%;
}
.steps li:last-child { border-left-color: transparent; }
.steps p { font-size: .92rem; }

/* ---------- 表格 ---------- */
.table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
table {
  width: 100%; border-collapse: collapse; font-size: .9rem;
}
th, td { padding: 14px 16px; text-align: left; border-bottom: 1px solid var(--border-subtle); }
th { font-weight: 600; color: var(--text-primary); white-space: nowrap; }
td { color: var(--text-secondary); }
tr:hover td { background: rgba(255,255,255,.02); }

/* ---------- FAQ ---------- */
.faq-item { border-bottom: 1px solid var(--border-subtle); }
.faq-item summary {
  padding: 18px 0; cursor: pointer; font-weight: 600; font-size: .95rem;
  color: var(--text-primary); list-style: none; display: flex; align-items: center; gap: 12px;
  transition: color .2s;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::marker { display: none; content: ''; }
.faq-item summary:hover { color: var(--accent); }
.faq-item summary::before {
  content: '+'; font-size: 1.2rem; font-weight: 300; color: var(--accent); flex-shrink: 0;
  transition: transform .25s;
}
.faq-item[open] summary::before { content: '−'; }
.faq-item .faq-answer { padding: 0 0 18px 28px; font-size: .9rem; color: var(--text-secondary); line-height: 1.65; }

/* ---------- 文章卡片 ---------- */
.article-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 20px; }
.article-card { padding: 24px; }
.article-card .date { font-size: .8rem; color: var(--text-muted); margin-bottom: 8px; }
.article-card h4 { font-size: 1rem; margin-bottom: 8px; color: var(--text-primary); }
.article-card p { font-size: .88rem; line-height: 1.6; margin-bottom: 14px; }
.article-card .btn--sm { padding: 8px 18px; font-size: .82rem; }

/* ---------- 相关链接 ---------- */
.related-list { display: flex; flex-direction: column; gap: 14px; }
.related-item a {
  display: flex; align-items: baseline; gap: 12px;
  padding: 12px 16px; border-radius: var(--radius-sm);
  transition: background .2s;
}
.related-item a:hover { background: rgba(255,255,255,.03); }
.related-item .dot { flex-shrink: 0; width: 6px; height: 6px; border-radius: 50%; background: var(--accent); margin-top: 7px; }
.related-item .rel-title { font-size: .9rem; font-weight: 500; color: var(--text-primary); }
.related-item .rel-desc { font-size: .82rem; color: var(--text-muted); }

/* ---------- 焦点可见 ---------- */
*:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 3px; }

/* ---------- SVG 动效关键帧 ---------- */
@keyframes draw-path {
  from { stroke-dashoffset: 1; }
  to   { stroke-dashoffset: 0; }
}
@keyframes float-node {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-4px); }
}
@keyframes fade-in-up {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes dash-circle {
  from { stroke-dashoffset: 100; }
  to   { stroke-dashoffset: 0; }
}

.animate-draw { animation: draw-path 3s ease forwards; }
.animate-float { animation: float-node 4s ease-in-out infinite; }
.animate-fade-in { animation: fade-in-up .8s ease both; }
.animate-dash-circle { animation: dash-circle 4s ease infinite; }

/* 节点延迟浮动 */
.float-delay-1 { animation-delay: .5s; }
.float-delay-2 { animation-delay: 1s; }
.float-delay-3 { animation-delay: 1.5s; }

/* 减少动态效果 */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  .animate-draw, .animate-float, .animate-fade-in, .animate-dash-circle {
    animation: none !important;
  }
}

/* ---------- 工具类 ---------- */
.text-center { text-align: center; }
.mt-8 { margin-top: 8px; }
.mt-16 { margin-top: 16px; }
.mt-24 { margin-top: 24px; }
.mt-32 { margin-top: 32px; }
.mt-48 { margin-top: 48px; }
.mb-8 { margin-bottom: 8px; }
.mb-16 { margin-bottom: 16px; }
.mb-24 { margin-bottom: 24px; }
.gap-20 { gap: 20px; }
.flex-center { display: flex; align-items: center; justify-content: center; }
