/* ============================================================
   SpeedX 落地页 — 自定义样式
   补充 Tailwind 之外的：动效、节点光点、特殊组件样式
   ============================================================ */

:root {
  --bg: #0A1628;
  --bg-2: #0F2547;
  --bg-3: #13315C;
  --blue: #3B82F6;
  --cyan: #06B6D4;
  --green: #10B981;
  --text-2: #94A3B8;
  --line: rgba(255, 255, 255, 0.08);
}

html { scroll-behavior: smooth; }
body { -webkit-tap-highlight-color: transparent; }

/* ---------- 吸底 CTA ---------- */
.sticky-cta {
  position: fixed;
  left: 0; right: 0; bottom: 0;
  z-index: 50;
  padding: 10px 16px calc(10px + env(safe-area-inset-bottom, 0px));
  background: rgba(10, 22, 40, 0.88);
  backdrop-filter: blur(16px) saturate(180%);
  -webkit-backdrop-filter: blur(16px) saturate(180%);
  border-top: 1px solid rgba(59, 130, 246, 0.18);
  box-shadow: 0 -8px 24px rgba(0, 0, 0, 0.3);
  transform: translateY(120%);
  opacity: 0;
  transition: transform .35s cubic-bezier(0.4, 0, 0.2, 1),
              opacity .25s ease;
  pointer-events: none;
}
.sticky-cta.visible {
  transform: translateY(0);
  opacity: 1;
  pointer-events: auto;
}
.sticky-cta-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  width: 100%;
  padding: 0.85rem 1.5rem;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--blue), var(--cyan));
  color: white;
  font-weight: 600;
  font-size: 1rem;
  box-shadow: 0 4px 16px rgba(59, 130, 246, 0.45),
              inset 0 1px 0 rgba(255, 255, 255, 0.2);
  position: relative;
  overflow: hidden;
}
.sticky-cta-btn::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(120deg, transparent, rgba(255,255,255,0.2), transparent);
  transform: translateX(-100%);
  animation: shine 3s ease-in-out infinite;
}
@keyframes shine {
  0%, 60% { transform: translateX(-100%); }
  100% { transform: translateX(100%); }
}
.sticky-cta-btn:active { transform: scale(0.98); }
.sticky-cta-hint {
  text-align: center;
  font-size: 0.7rem;
  color: var(--text-2);
  margin: 6px 0 0;
  opacity: 0.75;
  letter-spacing: 0.02em;
}

/* ---------- Hero 背景 ---------- */
.hero-bg {
  background:
    radial-gradient(ellipse at top, rgba(59, 130, 246, 0.18), transparent 60%),
    radial-gradient(ellipse at bottom, rgba(6, 182, 212, 0.12), transparent 60%);
}
.hero-glow {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.6;
  pointer-events: none;
}
.hero-glow-1 {
  width: 320px; height: 320px;
  background: var(--blue);
  top: -80px; left: -80px;
}
.hero-glow-2 {
  width: 280px; height: 280px;
  background: var(--cyan);
  bottom: -100px; right: -100px;
  opacity: 0.4;
}
.hero-glow-3 {
  width: 360px; height: 360px;
  background: var(--blue);
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  opacity: 0.25;
}

/* ---------- 节点光点 ---------- */
.node-dots { position: absolute; inset: 0; }
.node {
  position: absolute;
  left: var(--x); top: var(--y);
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--cyan);
  box-shadow: 0 0 10px var(--cyan), 0 0 20px rgba(6, 182, 212, 0.4);
  animation: twinkle 3s ease-in-out infinite;
  animation-delay: var(--d);
  opacity: 0.7;
}
@keyframes twinkle {
  0%, 100% { opacity: 0.3; transform: scale(0.8); }
  50% { opacity: 1; transform: scale(1.3); }
}

/* ---------- 主 CTA 按钮 ---------- */
.cta-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.95rem 2rem;
  background: linear-gradient(135deg, var(--blue), var(--cyan));
  color: white;
  font-weight: 600;
  font-size: 1rem;
  border-radius: 999px;
  box-shadow: 0 4px 24px rgba(59, 130, 246, 0.4),
              inset 0 1px 0 rgba(255, 255, 255, 0.2);
  transition: transform .2s ease, box-shadow .2s ease;
  min-width: 220px;
  position: relative;
  overflow: hidden;
}
.cta-primary::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(120deg, transparent, rgba(255,255,255,0.25), transparent);
  transform: translateX(-100%);
  transition: transform .6s ease;
}
.cta-primary:hover { transform: translateY(-1px); box-shadow: 0 6px 28px rgba(59, 130, 246, 0.55); }
.cta-primary:hover::before { transform: translateX(100%); }
.cta-primary:active { transform: translateY(0); }

.cta-primary-large {
  padding: 1.1rem 2.4rem;
  font-size: 1.05rem;
  min-width: 260px;
}

.cta-icon { display: inline-flex; align-items: center; }

/* ---------- Hero 副标题 ---------- */
.hero-sub {
  font-size: 0.95rem;
  line-height: 1.7;
  color: var(--text-2);
  margin-bottom: 2.5rem;
}
.hero-sub-num {
  color: white;
  font-weight: 700;
  font-family: 'Inter', 'SF Pro Display', sans-serif;
  background: linear-gradient(135deg, var(--blue), var(--cyan));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  letter-spacing: -0.02em;
}

/* ---------- Hero 6 大卖点 ---------- */
.hero-feat {
  display: flex;
  align-items: flex-start;
  gap: 0.55rem;
  padding: 0.7rem 0.7rem;
  background: rgba(255, 255, 255, 0.035);
  border: 1px solid var(--line);
  border-radius: 12px;
  text-align: left;
  transition: background .2s, border-color .2s;
}
.hero-feat:hover {
  background: rgba(59, 130, 246, 0.08);
  border-color: rgba(59, 130, 246, 0.25);
}
.hero-feat svg {
  color: var(--cyan);
  flex-shrink: 0;
  margin-top: 1px;
}
.hero-feat-text { min-width: 0; }
.hero-feat-title {
  font-size: 0.82rem;
  font-weight: 600;
  color: white;
  line-height: 1.25;
  margin: 0 0 2px;
  letter-spacing: -0.01em;
  white-space: nowrap;
}
.hero-feat-sub {
  font-size: 0.68rem;
  color: var(--text-2);
  line-height: 1.3;
  margin: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ---------- 滚动提示 ---------- */
.scroll-hint {
  width: 36px; height: 36px;
  border-radius: 50%;
  border: 1px solid var(--line);
  display: flex; align-items: center; justify-content: center;
  animation: bounce 2s infinite;
}
@keyframes bounce {
  0%, 100% { transform: translateY(0); opacity: 0.5; }
  50% { transform: translateY(6px); opacity: 1; }
}

/* ---------- 痛点卡片 ---------- */
.pain-card {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  padding: 1.25rem;
  border-radius: 16px;
  background: rgba(15, 37, 71, 0.6);
  border: 1px solid var(--line);
  backdrop-filter: blur(8px);
}
.pain-emoji {
  font-size: 2rem;
  line-height: 1;
  flex-shrink: 0;
}

/* ---------- 场景卡片 ---------- */
.scene-card {
  padding: 1.75rem 1.5rem;
  margin-bottom: 1.25rem;
  border-radius: 20px;
  background: linear-gradient(180deg, rgba(15, 37, 71, 0.85), rgba(10, 22, 40, 0.85));
  border: 1px solid var(--line);
  position: relative;
  overflow: hidden;
}
.scene-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(59, 130, 246, 0.5), transparent);
}
.scene-icon-wrap {
  width: 56px; height: 56px;
  border-radius: 14px;
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 1rem;
  box-shadow: 0 4px 16px rgba(59, 130, 246, 0.3);
}
.scene-tags {
  display: flex; flex-wrap: wrap; gap: 0.5rem;
  margin-bottom: 1rem;
}
.tag {
  padding: 0.35rem 0.75rem;
  border-radius: 999px;
  background: rgba(59, 130, 246, 0.12);
  color: #BFDBFE;
  font-size: 0.75rem;
  border: 1px solid rgba(59, 130, 246, 0.2);
}
.scene-mini-cta {
  display: inline-block;
  margin-top: 0.5rem;
  color: var(--cyan);
  font-size: 0.875rem;
  font-weight: 500;
  transition: opacity .2s;
}
.scene-mini-cta:hover { opacity: 0.8; }

/* ---------- ping 值对比图 ---------- */
.ping-compare {
  background: rgba(0, 0, 0, 0.25);
  border-radius: 12px;
  padding: 1rem;
  margin-bottom: 1rem;
}
.ping-row {
  display: flex; align-items: center; gap: 0.75rem;
  margin-bottom: 0.5rem;
}
.ping-row:last-child { margin-bottom: 0; }
.ping-label {
  width: 64px;
  font-size: 0.8rem;
  color: var(--text-2);
  flex-shrink: 0;
}
.ping-bar-wrap {
  flex: 1;
  height: 10px;
  background: rgba(255, 255, 255, 0.06);
  border-radius: 999px;
  overflow: hidden;
}
.ping-bar {
  height: 100%;
  border-radius: 999px;
  width: 0;
  transition: width 1.2s cubic-bezier(0.4, 0, 0.2, 1);
}
.ping-bar.bad { background: linear-gradient(90deg, #DC2626, #F59E0B); }
.ping-bar.good { background: linear-gradient(90deg, var(--green), var(--cyan)); }
.ping-row.in-view .ping-bar.bad { width: 90%; }
.ping-row.in-view .ping-bar.good { width: 14%; }
.ping-value {
  font-family: 'Inter', 'SF Pro Display', sans-serif;
  font-size: 0.85rem;
  font-weight: 700;
  width: 60px;
  text-align: right;
  flex-shrink: 0;
  letter-spacing: -0.01em;
}
.ping-value.bad-text { color: #F59E0B; }
.ping-value.good-text { color: var(--green); }

/* ---------- 游戏卡专属 4 大能力 ---------- */
.game-feats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.5rem;
  margin-bottom: 1rem;
}
.game-feat {
  padding: 0.65rem 0.75rem;
  background: rgba(6, 182, 212, 0.06);
  border: 1px solid rgba(6, 182, 212, 0.15);
  border-radius: 10px;
  transition: background .2s, border-color .2s;
}
.game-feat:hover {
  background: rgba(6, 182, 212, 0.1);
  border-color: rgba(6, 182, 212, 0.25);
}
.gf-title {
  font-size: 0.8rem;
  font-weight: 600;
  color: white;
  margin: 0 0 2px;
  letter-spacing: -0.01em;
  line-height: 1.25;
}
.gf-sub {
  font-size: 0.68rem;
  color: var(--text-2);
  line-height: 1.3;
  margin: 0;
}

/* ---------- 硬实力数据墙：节点分布 ---------- */
.data-wall-glow {
  position: absolute;
  width: 480px; height: 480px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(6, 182, 212, 0.15), transparent 60%);
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  filter: blur(40px);
}
.data-wall-dots { position: absolute; inset: 0; }
.dw-node {
  position: absolute;
  left: var(--x); top: var(--y);
  width: 4px; height: 4px;
  border-radius: 50%;
  background: var(--cyan);
  box-shadow: 0 0 8px var(--cyan), 0 0 16px rgba(6, 182, 212, 0.5);
  animation: twinkle 4s ease-in-out infinite;
  animation-delay: var(--d);
  opacity: 0.6;
}
.dw-node::after {
  content: '';
  position: absolute;
  inset: -3px;
  border-radius: 50%;
  border: 1px solid rgba(6, 182, 212, 0.25);
  animation: ping 3s ease-out infinite;
  animation-delay: var(--d);
}
@keyframes ping {
  0% { transform: scale(0.8); opacity: 0.6; }
  100% { transform: scale(3); opacity: 0; }
}

/* ---------- 数据卡 ---------- */
.stat-card {
  padding: 1.5rem 1rem;
  border-radius: 16px;
  background: rgba(15, 37, 71, 0.7);
  border: 1px solid var(--line);
  text-align: center;
  position: relative;
  overflow: hidden;
}
.stat-card::after {
  content: '';
  position: absolute;
  top: -1px; left: 10%; right: 10%;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--cyan), transparent);
  opacity: 0.5;
}
.stat-icon {
  width: 40px; height: 40px;
  border-radius: 10px;
  background: rgba(6, 182, 212, 0.1);
  border: 1px solid rgba(6, 182, 212, 0.2);
  display: flex; align-items: center; justify-content: center;
  margin: 0 auto 0.75rem;
}
.stat-num {
  font-family: 'Inter', 'SF Pro Display', sans-serif;
  font-size: 2rem;
  font-weight: 700;
  background: linear-gradient(135deg, var(--blue), var(--cyan));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  line-height: 1;
  margin-bottom: 0.4rem;
}
.stat-prefix, .stat-suffix {
  font-size: 1.2rem;
  font-weight: 600;
}
.stat-label {
  font-size: 0.8rem;
  color: var(--text-2);
}

/* ---------- 三步使用 ---------- */
.step-row {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
}
.step-num {
  width: 36px; height: 36px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--blue), var(--cyan));
  display: flex; align-items: center; justify-content: center;
  font-weight: 700;
  font-size: 1rem;
  flex-shrink: 0;
  box-shadow: 0 2px 12px rgba(59, 130, 246, 0.4);
}
.step-body { flex: 1; padding-top: 0.4rem; }

/* ---------- 安全行 ---------- */
.security-row {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
}
.security-icon {
  font-size: 1.75rem;
  width: 48px; height: 48px;
  border-radius: 12px;
  background: rgba(6, 182, 212, 0.08);
  border: 1px solid rgba(6, 182, 212, 0.15);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}

/* ---------- FAQ ---------- */
.faq-item {
  border-radius: 12px;
  background: rgba(15, 37, 71, 0.5);
  border: 1px solid var(--line);
  overflow: hidden;
  transition: background .2s;
}
.faq-item[open] { background: rgba(15, 37, 71, 0.85); }
.faq-item summary {
  padding: 1rem 1.25rem;
  cursor: pointer;
  font-weight: 500;
  font-size: 0.95rem;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: '+';
  font-size: 1.4rem;
  color: var(--text-2);
  font-weight: 300;
  transition: transform .2s;
  flex-shrink: 0;
}
.faq-item[open] summary::after { transform: rotate(45deg); }
.faq-item p {
  padding: 0 1.25rem 1.1rem;
  font-size: 0.875rem;
  color: var(--text-2);
  line-height: 1.7;
}
.faq-item p a { color: var(--cyan); text-decoration: underline; }

/* ---------- 滚动入场动画 ---------- */
.fade-in {
  opacity: 0;
  transform: translateY(16px);
  animation: fadeInUp .8s ease forwards;
}
.fade-in:nth-child(1) { animation-delay: 0s; }
.fade-in:nth-child(2) { animation-delay: 0.1s; }
.fade-in:nth-child(3) { animation-delay: 0.2s; }
.fade-in:nth-child(4) { animation-delay: 0.3s; }
.fade-in:nth-child(5) { animation-delay: 0.4s; }
.fade-in:nth-child(6) { animation-delay: 0.5s; }
@keyframes fadeInUp {
  to { opacity: 1; transform: translateY(0); }
}

.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity .8s ease, transform .8s ease;
}
.reveal.in-view {
  opacity: 1;
  transform: translateY(0);
}

/* ---------- 媒体查询 / 桌面端兜底 ---------- */
@media (min-width: 768px) {
  h1 { font-size: 3.5rem !important; }
  .max-w-md { max-width: 32rem; }
}

/* 用户偏好减少动效 */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
  .reveal { opacity: 1; transform: none; }
  .fade-in { opacity: 1; transform: none; animation: none; }
}
