/* ═══════════════════════════════════════════════════════════════
 * 未知之致 Unfound Depth —— 共享样式
 * 所有页面通用：CSS变量、基础重置、通用组件、Navbar、Footer
 * ═══════════════════════════════════════════════════════════════ */

:root {
  --bg: #050a18;
  --bg-2: #0a1428;
  --bg-3: #111d35;
  --bg-card: rgba(255, 255, 255, 0.04);
  --bg-card-hover: rgba(255, 255, 255, 0.07);
  --border: rgba(255, 255, 255, 0.08);
  --border-strong: rgba(255, 255, 255, 0.15);
  --text: #f0ebe0;
  --text-2: #a8b3cc;
  --text-3: #6b7a99;
  --text-4: #4a5670;
  --accent: #6b9ce8;
  --accent-2: #8eb8f0;
  --accent-3: #a7c4f5;
  --accent-soft: rgba(107, 156, 232, 0.15);
  --accent-soft-2: rgba(142, 184, 240, 0.15);
  --gradient-primary: linear-gradient(135deg, #6b9ce8 0%, #8eb8f0 100%);
  --gradient-secondary: linear-gradient(135deg, #a7c4f5 0%, #6b9ce8 100%);
  --gradient-bg: linear-gradient(180deg, #050a18 0%, #0a1428 100%);
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, .4);
  --shadow-md: 0 8px 24px rgba(0, 0, 0, .5);
  --shadow-lg: 0 20px 60px rgba(0, 0, 0, .6);
  --shadow-glow: 0 0 40px rgba(107, 156, 232, .3);
  --radius: 16px;
  --radius-sm: 10px;
  --radius-lg: 24px;
  --font-display: 'Space Grotesk', 'Noto Serif SC', 'Noto Sans SC', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-body: 'Noto Sans SC', -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-mono: 'SF Mono', 'Cascadia Code', 'JetBrains Mono', Consolas, monospace;
  /* 产品色槽位 - 各产品页可覆盖 */
  --product-accent: var(--accent);
  --product-accent-soft: var(--accent-soft);
  --product-gradient: var(--gradient-primary);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--text);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  overflow-x: hidden;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 32px;
  width: 100%;
}

a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; border: none; background: none; color: inherit; }
img { max-width: 100%; display: block; }

/* ───────────────────── 通用组件 ───────────────────── */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-size: 14px;
  font-weight: 500;
  padding: 12px 24px;
  border-radius: var(--radius-sm);
  transition: all .25s cubic-bezier(.4, 0, .2, 1);
  white-space: nowrap;
  border: 1px solid transparent;
}
.btn svg { width: 16px; height: 16px; }
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0); }

.btn-primary {
  background: var(--gradient-primary);
  color: #fff;
  box-shadow: 0 4px 20px rgba(107, 156, 232, .3);
}
.btn-primary:hover {
  box-shadow: 0 8px 30px rgba(107, 156, 232, .45);
}

.btn-ghost {
  background: transparent;
  color: var(--text);
  border-color: var(--border-strong);
}
.btn-ghost:hover {
  background: var(--bg-card-hover);
  border-color: var(--accent);
  color: var(--accent);
}

.btn-lg {
  padding: 16px 32px;
  font-size: 15px;
  border-radius: 12px;
}
.btn-lg svg { width: 18px; height: 18px; }

.btn-full { width: 100%; }

.gradient-text {
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.gradient-text-2 {
  background: var(--gradient-secondary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.section-header {
  text-align: center;
  max-width: 640px;
  margin: 0 auto 64px;
}

.section-header-left {
  text-align: left;
  margin-left: 0;
  margin-right: 0;
}

.section-tag {
  display: inline-block;
  font-size: 13px;
  font-weight: 500;
  color: var(--accent);
  background: var(--accent-soft);
  padding: 6px 16px;
  border-radius: 100px;
  margin-bottom: 20px;
  letter-spacing: .5px;
}

.section-title {
  font-family: var(--font-display);
  font-size: clamp(28px, 5vw, 44px);
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 16px;
  letter-spacing: -.5px;
}

.section-desc {
  font-size: 16px;
  color: var(--text-2);
  line-height: 1.7;
}

/* Reveal 动画 */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity .8s cubic-bezier(.22,.8,.36,1),
              transform .8s cubic-bezier(.22,.8,.36,1);
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ───────────────────── 导航栏 ───────────────────── */
.navbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  padding: 16px 0;
  transition: all .3s ease;
}
.navbar.scrolled {
  background: rgba(5, 10, 24, .85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
  padding: 12px 0;
}

.navbar .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

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

.brand-logo {
  width: 40px;
  height: 40px;
  object-fit: contain;
  border-radius: 10px;
}

.brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.1;
}

.brand-name {
  font-family: var(--font-display);
  font-size: 17px;
  font-weight: 600;
  letter-spacing: 2px;
  color: var(--text);
}

.brand-sub {
  font-size: 10px;
  color: var(--text-3);
  letter-spacing: 2px;
  margin-top: 2px;
  font-weight: 400;
}

.nav-right {
  display: flex;
  align-items: center;
  gap: 8px;
}

.nav-link {
  font-size: 14px;
  color: var(--text-2);
  padding: 8px 16px;
  border-radius: 8px;
  transition: all .2s ease;
  font-weight: 500;
}
.nav-link:hover {
  color: var(--text);
  background: var(--bg-card);
}
.nav-link.active {
  color: var(--accent);
  background: var(--accent-soft);
}

.nav-cta {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  font-weight: 600;
  color: #fff;
  background: var(--gradient-primary);
  padding: 9px 20px;
  border-radius: 8px;
  margin-left: 8px;
  transition: all .25s ease;
  box-shadow: 0 4px 14px rgba(107, 156, 232, .3);
}
.nav-cta:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(107, 156, 232, .45);
}
.nav-cta svg { width: 14px; height: 14px; }

.mobile-menu-btn {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: 8px;
}
.mobile-menu-btn span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: all .3s ease;
}

/* ───────────────────── 页脚 ───────────────────── */
.footer {
  background: var(--bg-2);
  border-top: 1px solid var(--border);
  padding: 64px 0 32px;
}

.footer-top {
  display: grid;
  grid-template-columns: 1.5fr 2fr;
  gap: 64px;
  margin-bottom: 48px;
}

.footer-brand .footer-desc {
  font-size: 14px;
  color: var(--text-3);
  line-height: 1.7;
  margin-top: 16px;
  max-width: 320px;
}

.footer-links {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
}

.footer-col h4 {
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 16px;
}
.footer-col a {
  display: block;
  font-size: 13px;
  color: var(--text-3);
  padding: 6px 0;
  transition: color .2s ease;
}
.footer-col a:hover { color: var(--accent); }

.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 24px;
  border-top: 1px solid var(--border);
}
.footer-bottom p {
  font-size: 13px;
  color: var(--text-4);
}

.footer-social {
  display: flex;
  gap: 10px;
}
.social-link {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  display: grid;
  place-items: center;
  color: var(--text-3);
  transition: all .2s ease;
}
.social-link svg { width: 16px; height: 16px; }
.social-link:hover {
  color: var(--accent);
  border-color: var(--accent);
  background: var(--accent-soft);
  transform: translateY(-2px);
}

/* ───────────────────── 回到顶部 ───────────────────── */
.back-to-top {
  position: fixed;
  bottom: 32px;
  right: 32px;
  width: 48px;
  height: 48px;
  border-radius: 14px;
  background: var(--gradient-primary);
  color: #fff;
  display: grid;
  place-items: center;
  box-shadow: 0 4px 20px rgba(107, 156, 232, .4);
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  transition: all .3s ease;
  z-index: 90;
}
.back-to-top.show {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}
.back-to-top:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 30px rgba(107, 156, 232, .5);
}
.back-to-top svg { width: 20px; height: 20px; }

/* ───────────────────── 响应式（共享部分） ───────────────────── */
@media (max-width: 1024px) {
  .footer-top { grid-template-columns: 1fr; gap: 40px; }
}

@media (max-width: 768px) {
  .container { padding: 0 20px; }

  .nav-right { display: none; }
  .mobile-menu-btn { display: flex; }

  .section-header { margin-bottom: 48px; }

  .footer-links { grid-template-columns: repeat(2, 1fr); }
  .footer-bottom { flex-direction: column; gap: 16px; text-align: center; }

  .back-to-top { bottom: 20px; right: 20px; width: 42px; height: 42px; }
}

@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
  .reveal { opacity: 1; transform: none; }
}
