/* ============ 设计令牌 (Design Tokens) ============ */
:root {
  /* 字体 */
  --font: -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI",
    "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Helvetica Neue", sans-serif;

  /* 浅色主题 */
  --bg: #f5f5f7;
  --bg-grad-1: #ffffff;
  --bg-grad-2: #f0f0f3;
  --surface: rgba(255, 255, 255, 0.82);
  --surface-solid: #ffffff;
  --surface-2: rgba(255, 255, 255, 0.6);
  --border: rgba(0, 0, 0, 0.08);
  --border-strong: rgba(0, 0, 0, 0.12);

  --text: #1d1d1f;
  --text-2: #6e6e73;
  --text-3: #86868b;

  --accent: #0071e3;
  --accent-strong: #0067cc;
  --accent-soft: rgba(0, 113, 227, 0.1);

  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.04), 0 4px 16px rgba(0, 0, 0, 0.05);
  --shadow-md: 0 8px 30px rgba(0, 0, 0, 0.08), 0 2px 8px rgba(0, 0, 0, 0.04);
  --shadow-lg: 0 24px 60px rgba(0, 0, 0, 0.14);

  --radius-sm: 12px;
  --radius: 18px;
  --radius-lg: 28px;

  --nav-h: 56px;
  --maxw: 1180px;
}

/* 深色主题（跟随系统 + 手动切换） */
[data-theme="dark"] {
  --bg: #000000;
  --bg-grad-1: #161616;
  --bg-grad-2: #0a0a0a;
  --surface: rgba(28, 28, 30, 0.78);
  --surface-solid: #1c1c1e;
  --surface-2: rgba(44, 44, 46, 0.6);
  --border: rgba(255, 255, 255, 0.1);
  --border-strong: rgba(255, 255, 255, 0.18);

  --text: #f5f5f7;
  --text-2: #a1a1a6;
  --text-3: #6e6e73;

  --accent: #2997ff;
  --accent-strong: #2fa2ff;
  --accent-soft: rgba(41, 151, 255, 0.14);

  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.5), 0 4px 16px rgba(0, 0, 0, 0.4);
  --shadow-md: 0 8px 30px rgba(0, 0, 0, 0.5), 0 2px 8px rgba(0, 0, 0, 0.3);
  --shadow-lg: 0 24px 60px rgba(0, 0, 0, 0.6);
}

/* ============ 基础重置 ============ */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--nav-h) + 10px);
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  transition: background 0.4s ease, color 0.3s ease;
}

a {
  color: var(--accent);
  text-decoration: none;
}

.container {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 24px;
}

::selection {
  background: var(--accent);
  color: #fff;
}

.no-js .reveal { opacity: 1 !important; transform: none !important; }

/* ============ 导航栏 ============ */
.nav {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 100;
  height: var(--nav-h);
  background: rgba(255, 255, 255, 0.72);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid transparent;
  transition: background 0.35s ease, height 0.3s ease, border-color 0.35s ease;
}

[data-theme="dark"] .nav {
  background: rgba(0, 0, 0, 0.72);
}

.nav.scrolled {
  border-bottom-color: var(--border);
}

.nav-inner {
  max-width: var(--maxw);
  height: var(--nav-h);
  margin: 0 auto;
  padding: 0 22px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  color: var(--text);
  font-weight: 600;
  font-size: 17px;
  letter-spacing: -0.01em;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 27px;
  height: 27px;
  border-radius: 8px;
  background: linear-gradient(135deg, var(--accent), #48a5ff);
  color: #fff;
  font-size: 16px;
  font-weight: 700;
  box-shadow: 0 2px 8px rgba(0, 113, 227, 0.35);
}

.nav-links {
  display: flex;
  gap: 8px;
}

.nav-links a,
.mobile-menu a {
  color: var(--text-2);
  font-size: 14px;
  font-weight: 500;
  padding: 7px 11px;
  border-radius: 999px;
  transition: color 0.2s ease, background 0.2s ease;
}

.nav-links a:hover,
.mobile-menu a:hover {
  color: var(--text);
  background: var(--accent-soft);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.ghost {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border: none;
  border-radius: 10px;
  background: transparent;
  color: var(--text-2);
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease;
}

.ghost:hover {
  background: var(--accent-soft);
  color: var(--text);
}

.icon-moon { display: none; }
[data-theme="dark"] .icon-sun { display: none; }
[data-theme="dark"] .icon-moon { display: block; }

/* 按钮 */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 500;
  padding: 9px 18px;
  cursor: pointer;
  border: 1px solid transparent;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease, opacity 0.2s ease;
}

.btn:active { transform: scale(0.97); }

.btn-primary {
  background: var(--accent);
  color: #fff;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.2) inset, 0 2px 8px rgba(0, 113, 227, 0.3);
}

.btn-primary:hover {
  background: var(--accent-strong);
}

.btn-ghost-lg,
.btn.btn-ghost-lg {
  background: var(--surface-solid);
  border-color: var(--border-strong);
  color: var(--text);
}

.btn-ghost-lg:hover { background: var(--surface-2); }

.btn-lg {
  font-size: 16px;
  padding: 14px 26px;
}

/* 移动端菜单按钮 */
.menu-btn {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 4px;
  width: 38px;
  height: 38px;
  background: transparent;
  border: none;
  cursor: pointer;
  align-items: center;
}

.menu-btn span {
  display: block;
  width: 17px;
  height: 1.8px;
  background: var(--text);
  border-radius: 2px;
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.menu-btn.open span:nth-child(1) { transform: translateY(5.8px) rotate(45deg); }
.menu-btn.open span:nth-child(2) { opacity: 0; }
.menu-btn.open span:nth-child(3) { transform: translateY(-5.8px) rotate(-45deg); }

.mobile-menu {
  display: none;
  flex-direction: column;
  gap: 4px;
  padding: 10px 20px 18px;
  background: var(--surface);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid var(--border);
}

.mobile-menu.open { display: flex; }

.mobile-cta { margin-top: 10px; }

@media (max-width: 720px) {
  .nav-links,
  .nav-actions .btn-primary {
    display: none;
  }
  .menu-btn {
    display: flex;
  }
}

/* ============ Hero ============ */
.hero {
  position: relative;
  padding: calc(var(--nav-h) + 90px) 0 60px;
  min-height: 100vh;
  display: flex;
  align-items: center;
  overflow: hidden;
}

/* ambient glow */
.hero-glow {
  position: absolute;
  top: -20%;
  left: 50%;
  transform: translateX(-50%);
  width: 900px;
  height: 700px;
  background: radial-gradient(
    circle at center,
    rgba(0, 113, 227, 0.14),
    rgba(88, 101, 242, 0.06) 40%,
    transparent 70%
  );
  filter: blur(20px);
  pointer-events: none;
}

.hero-inner {
  position: relative;
  z-index: 2;
  max-width: 760px;
  text-align: center;
  margin: 0 auto;
}

.eyebrow {
  display: inline-block;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 18px;
}

.hero-title {
  font-size: clamp(2.6rem, 6vw, 4.2rem);
  font-weight: 700;
  line-height: 1.08;
  letter-spacing: -0.025em;
  margin-bottom: 22px;
}

.hero-title em {
  font-style: normal;
  background: linear-gradient(120deg, var(--accent), #5856d6);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-sub {
  font-size: clamp(1rem, 2vw, 1.2rem);
  color: var(--text-2);
  max-width: 560px;
  margin: 0 auto 32px;
}

.hero-sub strong { color: var(--text); font-weight: 600; }

.hero-actions {
  display: flex;
  gap: 14px;
  justify-content: center;
  flex-wrap: wrap;
}

.hero-note {
  margin-top: 20px;
  font-size: 13px;
  color: var(--text-3);
}

/* 浮层视觉 */
.hero-visual {
  position: relative;
  z-index: 2;
  max-width: 860px;
  margin: 70px auto 0;
  display: grid;
  place-items: center;
}

.device {
  width: min(520px, 88vw);
  aspect-ratio: 1 / 1.15;
  background: linear-gradient(160deg, var(--bg-grad-1), var(--bg-grad-2));
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
  padding: 18px;
  position: relative;
}

.device-top {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 16px;
}

.device-top .dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 4px var(--accent-soft);
}

.device-top .bar {
  flex: 1;
  height: 10px;
  border-radius: 6px;
  background: var(--surface-2);
  border: 1px solid var(--border);
}

.device-content {
  display: grid;
  gap: 14px;
}

.mini-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-sm);
}

.mini-ava {
  flex-shrink: 0;
  width: 34px;
  height: 34px;
  border-radius: 50%;
}

.ava-a { background: linear-gradient(135deg,#f43f5e,#f97316); }
.ava-b { background: linear-gradient(135deg,#3b82f6,#06b6d4); }
.ava-c { background: linear-gradient(135deg,#8b5cf6,#ec4899); }
.ava-d { background: linear-gradient(135deg,#10b981,#34d399); }

.mini-lines {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 7px;
}
.mini-lines i {
  display: block;
  height: 8px;
  border-radius: 5px;
  background: var(--surface-2);
  border: 1px solid var(--border);
}

/* 浮层标签 */
.float-chip {
  position: absolute;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 16px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
  background: var(--surface);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-md);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  animation: float 5s ease-in-out infinite;
}

.chip-1 { top: -18px; left: 6%; }
.chip-2 { bottom: 24px; right: 2%; animation-delay: 2.2s; }

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}

/* ============ 通用 section ============ */
.section {
  padding: 90px 0;
}

.section-head {
  text-align: center;
  margin-bottom: 56px;
}

.section-title {
  font-size: clamp(1.9rem, 4vw, 2.7rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 14px;
}

.section-sub {
  color: var(--text-2);
  font-size: 1.05rem;
}

/* ============ 产品大卡片 ============ */
.product-feature {
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  gap: 48px;
  align-items: center;
  background: var(--surface-solid);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 48px 44px;
  box-shadow: var(--shadow-md);
  overflow: hidden;
  position: relative;
}

.pf-logo {
  display: grid;
  place-items: center;
  width: 54px;
  height: 54px;
  border-radius: 15px;
  background: linear-gradient(135deg, var(--accent), #48a5ff);
  color: #fff;
  font-size: 30px;
  font-weight: 700;
  margin-bottom: 18px;
  box-shadow: 0 4px 16px rgba(0, 113, 227, 0.35);
}

.pf-name {
  font-size: 1.8rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 6px;
}

.pf-tagline {
  color: var(--accent);
  font-weight: 600;
  margin-bottom: 14px;
}

.pf-desc {
  color: var(--text-2);
  margin-bottom: 20px;
}

.pf-list {
  list-style: none;
  display: grid;
  gap: 10px;
  margin-bottom: 26px;
}

.pf-list li {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 15px;
  color: var(--text-2);
}

.pf-list li::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent);
  flex-shrink: 0;
}

.pf-actions {
  display: flex;
  align-items: center;
  gap: 16px;
}

.pf-status {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 13px;
  font-weight: 600;
  color: #34c759;
}

.pulse {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #34c759;
  position: relative;
}

.pulse::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: #34c759;
  animation: pulse 1.8s ease-out infinite;
}

@keyframes pulse {
  0% { transform: scale(1); opacity: 0.7; }
  100% { transform: scale(3); opacity: 0; }
}

/* xshow 浏览器视觉 */
.pf-visual { position: relative; }

.pf-browser {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
  transform: rotate(-2deg);
}

.pf-browser-bar {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 11px 14px;
  background: var(--surface-2);
  border-bottom: 1px solid var(--border);
}

.pf-browser-bar span {
  width: 11px;
  height: 11px;
  border-radius: 50%;
}
.pf-browser-bar span:nth-child(1) { background: #ff5f57; }
.pf-browser-bar span:nth-child(2) { background: #febc2e; }
.pf-browser-bar span:nth-child(3) { background: #28c840; }

.pf-url {
  margin-left: 8px;
  flex: 1;
  font-size: 12px;
  color: var(--text-3);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 7px;
  padding: 4px 10px;
  text-align: center;
}

.pf-browser-body {
  padding: 26px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 22px;
}

.pf-av {
  display: grid;
  place-items: center;
  width: 66px;
  height: 66px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent), #5856d6);
  color: #fff;
  font-size: 26px;
  font-weight: 700;
  box-shadow: 0 6px 20px rgba(0, 113, 227, 0.4);
}

.pf-social-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  width: 100%;
}

.pf-social-grid i {
  aspect-ratio: 1;
  border-radius: 14px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  transform: translateY(var(--t, 0));
  transition: transform 0.3s ease, background 0.3s ease, border-color 0.3s ease;
}

.pf-social-grid i:hover {
  transform: translateY(calc(var(--t, 0))) scale(1.06);
  border-color: var(--accent);
}

@media (max-width: 900px) {
  .product-feature {
    grid-template-columns: 1fr;
    padding: 34px 26px;
  }
}

/* ============ 关于·哲学 ============ */
.philosophy-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.phi-card {
  padding: 30px 26px;
  background: var(--surface-solid);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.phi-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-md);
  border-color: var(--border-strong);
}

.phi-icon {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border-radius: 13px;
  background: var(--accent-soft);
  color: var(--accent);
  margin-bottom: 16px;
}

.phi-card h4 {
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 8px;
}

.phi-card p {
  color: var(--text-2);
  font-size: 0.95rem;
}

@media (max-width: 900px) {
  .philosophy-grid { grid-template-columns: 1fr; }
}

/* ============ CTA ============ */
.cta-section { padding-top: 40px; }

.cta {
  text-align: center;
  padding: 70px 40px;
  background:
    radial-gradient(circle at 20% 30%, rgba(0, 113, 227, 0.12), transparent 55%),
    radial-gradient(circle at 80% 70%, rgba(88, 101, 242, 0.1), transparent 55%),
    var(--surface-solid);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
}

.cta-title {
  font-size: clamp(1.7rem, 3.6vw, 2.4rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 14px;
}

.cta-sub {
  color: var(--text-2);
  margin-bottom: 30px;
}

.cta-buttons {
  display: flex;
  gap: 14px;
  justify-content: center;
  flex-wrap: wrap;
}

/* ============ 页脚 ============ */
.footer {
  border-top: 1px solid var(--border);
  padding: 34px 0;
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  flex-wrap: wrap;
}

.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-weight: 600;
}

.footer-brand .brand-mark {
  width: 24px;
  height: 24px;
  border-radius: 7px;
  font-size: 14px;
}

.footer-note { color: var(--text-3); font-size: 13px; }

.footer-links {
  display: flex;
  gap: 18px;
}

.footer-links a {
  color: var(--text-2);
  font-size: 13px;
  transition: color 0.2s ease;
}

.footer-links a:hover { color: var(--text); }

/* ============ 滚动显现动画 ============ */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1),
    transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
  will-change: opacity, transform;
}

.reveal.in-view {
  opacity: 1;
  transform: translateY(0);
}

.reveal.delay-1 { transition-delay: 0.12s; }
.reveal.delay-2 { transition-delay: 0.24s; }

/* ============ 响应式 ============ */
@media (max-width: 640px) {
  .section { padding: 66px 0; }
  .hero { padding: calc(var(--nav-h) + 70px) 0 40px; }
  .rift { display: none; }
  .float-chip { font-size: 12px; padding: 7px 12px; }
}
