





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

:root {
  --bg-deep: #0a0e1a;
  --bg-mid: #1a1a2e;
  --bg-card: rgba(26, 26, 46, 0.55);
  --bg-card-solid: rgba(20, 24, 40, 0.85);
  --border-glow: rgba(0, 212, 255, 0.25);
  --border-glow-strong: rgba(0, 212, 255, 0.6);
  --text-primary: #e8eaf6;
  --text-secondary: #a8b0c8;
  --text-muted: #6b7390;
  --accent-blue: #00d4ff;
  --accent-purple: #7c3aed;
  --accent-green: #10b981;
  --accent-red: #ef4444;
  --accent-red-soft: #ff6b6b;
  --accent-yellow: #f59e0b;
  --gradient-neon: linear-gradient(135deg, #00d4ff 0%, #7c3aed 100%);
  --gradient-neon-hover: linear-gradient(135deg, #00e5ff 0%, #8b45f0 100%);
  --shadow-glow: 0 0 24px rgba(0, 212, 255, 0.25);
  --shadow-glow-purple: 0 0 24px rgba(124, 58, 237, 0.3);

  /* 2026-07-25: 组件级 var (Phase 3 — 内容适配) — 之前硬编码 rgba() 在浅色模式会反向冲突 */
  --field-bg: rgba(10, 14, 26, 0.6);
  --field-border: rgba(255, 255, 255, 0.1);
  --field-focus-ring: rgba(0, 212, 255, 0.15);
  --faq-bg: rgba(20, 24, 40, 0.4);
  --faq-border: rgba(255, 255, 255, 0.05);
  --nav-pill-bg: rgba(0, 212, 255, 0.05);
  --nav-pill-border: rgba(0, 212, 255, 0.18);
  --nav-link-color: rgba(255, 255, 255, 0.7);
  --ghost-bg: rgba(255, 255, 255, 0.04);
  --ghost-border: rgba(255, 255, 255, 0.12);
  --ghost-color: rgba(255, 255, 255, 0.95);
  --ghost-hover-bg: rgba(255, 255, 255, 0.08);
  --ghost-hover-border: rgba(0, 212, 255, 0.4);
  --nav-bg: rgba(6, 8, 24, 0.6);
  --nav-border: rgba(255, 255, 255, 0.06);
  --nav-shadow: 0 0 40px rgba(0, 212, 255, 0.05);
  --nav-logo-glow: drop-shadow(0 0 12px rgba(0, 212, 255, 0.5));
  /* 2026-07-25: Phase 5 — pricing/chat/skills 跨文件用 */
  --card-bg: rgba(20, 22, 26, 0.7);
  --card-bg-soft: rgba(20, 22, 26, 0.5);
  --card-bg-strong: rgba(20, 22, 26, 0.6);
  --hover-overlay: rgba(255, 255, 255, 0.04);
  --hover-overlay-strong: rgba(255, 255, 255, 0.08);
  --hover-overlay-soft: rgba(255, 255, 255, 0.06);
  /* 2026-07-25: Phase 9 — holo-card / testimonial / security 等深色专用卡片 */
  --holo-gradient-start: #2d1b4b;
  --holo-gradient-end: #1e1b4b;
  --holo-border: rgba(124, 58, 237, 0.3);
  --inset-highlight: rgba(255, 255, 255, 0.05);
  --inset-highlight-strong: rgba(255, 255, 255, 0.1);
  --card-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
  --card-shadow-hover: 0 14px 50px rgba(0, 0, 0, 0.4), 0 0 28px rgba(0, 212, 255, 0.2);
  --glow-edge: rgba(0, 212, 255, 0.6);
  --glow-edge-soft: rgba(0, 212, 255, 0.2);
  /* 2026-07-25: console-3d (浅色统一白色卡片) */
  --console-3d-bg: rgba(10, 14, 26, 0.7);
  --console-3d-bar-bg: rgba(0, 0, 0, 0.3);
  --console-3d-stat-bg: rgba(0, 0, 0, 0.3);
}

/* 2026-07-25: light theme 覆盖 (双模式) — 同源变量, 浅色版用 10 度以下饱和度配色 */
/* 2026-07-26 Phase 9o: B 方案浅色品牌色染背景
   - --bg-deep: slate-50 → cyan-50 (顶部 cyan 染)
   - --bg-mid: slate-100 → purple-50 (主体 purple 染)
   - 跟深色版 cyan/purple 主色调呼应, 浅色版也有 AI / 宇宙识别度 */
:root[data-theme="light"] {
  --bg-deep: #f0f9ff;
  --bg-mid: #faf5ff;
  --bg-card: #ffffff;
  --bg-card-solid: #ffffff;
  --border-glow: rgba(8, 145, 178, 0.18);
  --border-glow-strong: rgba(8, 145, 178, 0.45);
  --text-primary: #0f172a;
  --text-secondary: #475569;
  --text-muted: #94a3b8;
  --accent-blue: #0891b2;
  --accent-purple: #7c3aed;
  --accent-green: #10b981;
  --accent-red: #ef4444;
  --accent-red-soft: #ef4444;
  --accent-yellow: #f59e0b;
  --gradient-neon: linear-gradient(135deg, #0891b2 0%, #7c3aed 100%);
  --gradient-neon-hover: linear-gradient(135deg, #06b6d4 0%, #8b45f0 100%);
  --shadow-glow: 0 4px 16px rgba(0, 0, 0, 0.06);
  --shadow-glow-purple: 0 4px 16px rgba(124, 58, 237, 0.12);

  /* 2026-07-25: 组件级 var 浅色版 — 反转深浅 */
  --field-bg: #ffffff;
  --field-border: rgba(15, 23, 42, 0.1);
  --field-focus-ring: rgba(8, 145, 178, 0.18);
  --faq-bg: #ffffff;
  --faq-border: rgba(15, 23, 42, 0.06);
  --nav-pill-bg: rgba(8, 145, 178, 0.04);
  --nav-pill-border: rgba(8, 145, 178, 0.18);
  --nav-link-color: rgba(15, 23, 42, 0.7);
  --ghost-bg: rgba(255, 255, 255, 0.5);
  --ghost-border: rgba(15, 23, 42, 0.1);
  --ghost-color: rgba(15, 23, 42, 0.95);
  --ghost-hover-bg: rgba(255, 255, 255, 0.7);
  --ghost-hover-border: rgba(8, 145, 178, 0.45);
  --nav-bg: rgba(255, 255, 255, 0.85);
  --nav-border: rgba(15, 23, 42, 0.06);
  --nav-shadow: 0 0 16px rgba(8, 145, 178, 0.06);
  --nav-logo-glow: drop-shadow(0 0 2px rgba(15, 23, 42, 0.08));
  /* 2026-07-25: Phase 5 — pricing/chat/skills 跨文件用 */
  --card-bg: #ffffff;
  --card-bg-soft: #ffffff;
  --card-bg-strong: #ffffff;
  --hover-overlay: rgba(15, 23, 42, 0.04);
  --hover-overlay-strong: rgba(15, 23, 42, 0.08);
  --hover-overlay-soft: rgba(15, 23, 42, 0.06);
  /* 2026-07-25: Phase 9 — holo-card / testimonial / security 等深色专用卡片 (浅色重设) */
  --holo-gradient-start: #ede9fe;
  --holo-gradient-end: #ddd6fe;
  --holo-border: rgba(124, 58, 237, 0.25);
  --inset-highlight: rgba(255, 255, 255, 0.55);
  --inset-highlight-strong: rgba(255, 255, 255, 0.7);
  --card-shadow: 0 4px 20px rgba(15, 23, 42, 0.06), 0 1px 3px rgba(15, 23, 42, 0.04);
  --card-shadow-hover: 0 12px 36px rgba(15, 23, 42, 0.1), 0 0 20px rgba(8, 145, 178, 0.12);
  --glow-edge: rgba(8, 145, 178, 0.5);
  --glow-edge-soft: rgba(8, 145, 178, 0.2);
  /* 2026-07-25: console-3d 浅色版 — 统一白色卡片 (乐总:浅色主题卡片要统一白色) */
  --console-3d-bg: #ffffff;
  --console-3d-bar-bg: #f8fafc;
  --console-3d-stat-bg: #f8fafc;
}

html, body {
  min-height: 100vh;
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", sans-serif;
  color: var(--text-primary);
  background: var(--bg-mid);
  overflow-x: hidden;
  position: relative;
}

body::after {
  content: "";
  position: fixed;
  top: -200px;
  left: 50%;
  transform: translateX(-50%);
  width: 800px;
  height: 800px;
  background: radial-gradient(circle, rgba(0, 212, 255, 0.15) 0%, transparent 70%);
  pointer-events: none;
  z-index: 0;
}
/* 2026-07-26 Phase 9o: 浅色模式顶部 glow 改为 cyan/purple 混合
   - 深色 cyan rgba(0,212,255,0.15) 在 cyan-50 底色上 = 偏冷单调
   - 改 rgba(8,145,178,0.12) cyan-600 + rgba(124,58,237,0.06) purple-500 双色叠加
   - 视觉: 顶部 cyan 中心 + 紫色外圈, 跟 hero 球 (cyan→purple) 协调 */
:root[data-theme="light"] body::after {
  background:
    radial-gradient(circle at 40% 50%, rgba(8, 145, 178, 0.12) 0%, transparent 60%),
    radial-gradient(circle at 60% 50%, rgba(124, 58, 237, 0.06) 0%, transparent 70%),
    transparent;
}




@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: translateY(0); }
}

main {
  animation: fadeInUp 0.4s cubic-bezier(0.16, 1, 0.3, 1) both;
}




.glass {
  background: var(--bg-card);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid var(--border-glow);
  border-radius: 16px;
  box-shadow: var(--shadow-glow), inset 0 1px 0 rgba(255, 255, 255, 0.05);
  position: relative;
  overflow: hidden;
}

.glass::before {
  content: "";
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--accent-blue), transparent);
  opacity: 0.6;
}




/* 2026-07-25: 主题切换按钮 (data-theme-toggle) */
.theme-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  padding: 0;
  border: 1px solid var(--border-glow);
  border-radius: 50%;
  background: transparent;
  color: var(--text-secondary);
  cursor: pointer;
  transition: color 0.2s, border-color 0.2s, background 0.2s;
  font-family: inherit;
}
.theme-toggle:hover {
  color: var(--accent-blue);
  border-color: var(--accent-blue);
  background: rgba(0, 212, 255, 0.08);
}
/* 深色模式: 显示太阳 (暗示"切亮"); 浅色模式: 显示月亮 */
.theme-icon-dark { display: inline-block; }
.theme-icon-light { display: none; }
:root[data-theme="light"] .theme-icon-dark { display: none; }
:root[data-theme="light"] .theme-icon-light { display: inline-block; }

/* 2026-07-27: static HTML 移动端汉堡里的 theme-toggle 全宽样式
   覆盖 common.css 默认 .theme-toggle 的圆形 36x36, 跟 nav-link / lang-trigger 视觉对齐
   color 用 var(--text-secondary) 双主题自适应 (深 #a8b0c8 / 浅 #475569)
   border-bottom 浅色加深, 浅背景下也能看清分隔 */
.nav-mobile-drawer .theme-toggle {
  display: flex !important;
  justify-content: center;
  align-items: center;
  gap: 10px;
  width: 100% !important;
  height: auto !important;
  padding: 14px 12px !important;
  border: none !important;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08) !important;
  border-radius: 8px !important;
  background: transparent !important;
  color: var(--text-secondary) !important;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  box-sizing: border-box !important;
}
.nav-mobile-drawer .theme-toggle:hover {
  background: rgba(0, 212, 255, 0.08) !important;
  color: var(--accent-blue) !important;
  border-color: transparent !important;
}
:root[data-theme="light"] .nav-mobile-drawer .theme-toggle {
  border-bottom-color: rgba(15, 23, 42, 0.1) !important;
}

/* 2026-07-27: nav-mobile-drawer 背景 fallback (landing.html / chat.html 没在自己 CSS 定义 --drawer-bg)
   pricing.css / skills.css / docs.html 各自有自己的 --drawer-bg 覆盖此默认值
   深色: 深蓝半透 (rgba 10,14,26 .97) 跟 cosmic.css 一致
   浅色: 白色半透 (rgba 255,255,255 .97) */
:root {
  --drawer-bg: rgba(10, 14, 26, 0.97);
}
:root[data-theme="light"] {
  --drawer-bg: rgba(255, 255, 255, 0.97);
}
/* 2026-07-26 Phase 9i: 删掉浅色覆写, 让登录/注册页 theme-toggle 跟 landing.html
   完全共用默认 .theme-toggle 样式 (乐总要求"跟主页一样") */


.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 20px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  border: none;
  transition: all 0.2s ease;
  font-family: inherit;
  text-decoration: none;
}



.field { margin-bottom: 14px; }

.field label {
  display: block;
  font-size: 13px;
  color: var(--text-secondary);
  margin-bottom: 6px;
  font-weight: 500;
}

.field input,
.field select,
.field textarea {
  width: 100%;
  padding: 11px 14px;
  background: var(--field-bg);
  border: 1px solid var(--field-border);
  border-radius: 8px;
  color: var(--text-primary);
  font-size: 14px;
  font-family: inherit;
  transition: all 0.2s;
}

.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--accent-blue);
  box-shadow: 0 0 0 3px var(--field-focus-ring);
  background: var(--field-bg);
}

.field input::placeholder,
.field textarea::placeholder { color: var(--text-muted); }

.field textarea {
  resize: vertical;
  min-height: 90px;
  font-family: inherit;
}


.field input.input-error,
.field input.input-error:focus {
  border-color: var(--accent-red-soft);
  box-shadow: 0 0 0 3px rgba(255, 107, 107, 0.15);
}

.field-error {
  color: var(--accent-red-soft);
  font-size: 12px;
  margin-top: 4px;
  min-height: 16px;
}


.pwd-strength {
  display: flex;
  gap: 4px;
  margin-top: 6px;
}

.pwd-strength-bar {
  flex: 1;
  height: 3px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 2px;
  transition: background 0.2s;
}

.pwd-strength-bar.weak   { background: var(--accent-red-soft); }
.pwd-strength-bar.medium { background: var(--accent-yellow); }
.pwd-strength-bar.strong { background: var(--accent-green); }

.pwd-strength-label {
  font-size: 11px;
  margin-top: 4px;
  min-height: 14px;
}

.pwd-strength-label.weak   { color: var(--accent-red-soft); }
.pwd-strength-label.medium { color: var(--accent-yellow); }
.pwd-strength-label.strong { color: var(--accent-green); }




.stagger > * {
  opacity: 0;
  animation: fadeInUp 0.5s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.stagger > *:nth-child(1)  { animation-delay: 0.05s; }
.stagger > *:nth-child(2)  { animation-delay: 0.10s; }
.stagger > *:nth-child(3)  { animation-delay: 0.15s; }
.stagger > *:nth-child(4)  { animation-delay: 0.20s; }
.stagger > *:nth-child(5)  { animation-delay: 0.25s; }
.stagger > *:nth-child(6)  { animation-delay: 0.30s; }





.faq-item {
  background: var(--faq-bg);
  border: 1px solid var(--faq-border);
  border-radius: 10px;
  overflow: hidden;
  transition: all 0.2s;
}

.faq-item:hover { border-color: var(--border-glow); }

.faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 20px;
  cursor: pointer;
  user-select: none;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-primary);
  transition: color 0.15s;
}

.faq-question:hover { color: var(--accent-blue); }

.faq-icon {
  font-size: 18px;
  color: var(--accent-blue);
  font-weight: 300;
  transition: transform 0.25s ease;
  flex-shrink: 0;
  margin-left: 12px;
  width: 18px;
  text-align: center;
}

.faq-item.open .faq-icon { transform: rotate(45deg); }

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease, padding 0.3s ease;
  padding: 0 20px;
  color: var(--text-secondary);
  font-size: 13px;
  line-height: 1.6;
}

.faq-item.open .faq-answer {
  max-height: 200px;
  padding: 0 20px 16px;
}




.logo {
  font-size: 22px;
  font-weight: 700;
  background: var(--gradient-neon);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  letter-spacing: -0.5px;
  cursor: pointer;
}

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

.link {
  color: var(--accent-blue);
  text-decoration: none;
  transition: all 0.15s;
}
.link:hover { text-decoration: underline; }




.toast {
  position: fixed;
  top: 24px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--bg-card-solid);
  backdrop-filter: blur(12px);
  border: 1px solid var(--border-glow-strong);
  border-radius: 10px;
  padding: 12px 20px;
  color: var(--text-primary);
  font-size: 14px;
  z-index: 999;
  box-shadow: var(--shadow-glow);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s, transform 0.3s;
}

.toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

.toast.success { border-color: var(--accent-green); box-shadow: 0 0 24px rgba(16, 185, 129, 0.3); }
.toast.error { border-color: var(--accent-red); box-shadow: 0 0 24px rgba(239, 68, 68, 0.3); }




@media (max-width: 600px) {
  .glass { border-radius: 12px; }
  .logo { font-size: 18px; }
}







.nav-pill {
  display: flex;
  justify-content: space-around;
  gap: 8px;
  align-items: center;
  padding: 5px 12px;
  background: var(--nav-pill-bg);
  border: 1px solid var(--nav-pill-border);
  border-radius: 30px;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
  flex: 1;
  max-width: 720px;
  margin: 0 24px;
}

.nav-link {
  position: relative;
  font-size: 15px;
  color: var(--nav-link-color);
  text-decoration: none;
  padding: 7px 18px;
  border-radius: 24px;
  transition: color 0.2s, background 0.2s, box-shadow 0.2s;
  letter-spacing: 0.5px;
  white-space: nowrap;
}

/* 2026-07-26 Phase 9p: nav-auth-btn (登录 / 控制台 / Sign Up Free / 登出)
   white-space: nowrap 防止"控制台"4字 + 中文环境挤容器被压成竖排
   (之前 chat.html 登录状态显示"🎛 进入控制台"5字符 + emoji 被压成 2 行) */
.nav-auth-btn { white-space: nowrap; }

.nav-link:hover,
.nav-link.active,
.nav-link:target {
  color: #00d4ff;
  background: linear-gradient(135deg, rgba(0, 212, 255, 0.22), rgba(124, 58, 237, 0.22));
  box-shadow:
    0 0 16px rgba(0, 212, 255, 0.25),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
  text-shadow: 0 0 10px rgba(0, 212, 255, 0.5);
}


.btn-3d {
  position: relative;
  padding: 18px 36px;
  border: none;
  border-radius: 12px;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  text-decoration: none;
  font-family: inherit;
  transform: translateZ(0);
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.3s;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.btn-3d-neon {
  background: linear-gradient(135deg, #00d4ff 0%, #7c3aed 100%);
  color: white;
  box-shadow:
    0 6px 0 0 rgba(0, 0, 0, 0.3),
    0 8px 20px rgba(0, 212, 255, 0.4),
    inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

.btn-3d-neon:hover {
  transform: translateZ(20px) translateY(-4px);
  box-shadow:
    0 10px 0 0 rgba(0, 0, 0, 0.3),
    0 14px 30px rgba(0, 212, 255, 0.6),
    inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

.btn-3d-neon:active {
  transform: translateZ(-4px) translateY(2px);
  box-shadow:
    0 2px 0 0 rgba(0, 0, 0, 0.3),
    0 4px 10px rgba(0, 212, 255, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.btn-3d-ghost {
  background: var(--ghost-bg);
  color: var(--ghost-color);
  border: 1px solid var(--ghost-border);
  box-shadow:
    0 6px 0 0 rgba(0, 0, 0, 0.3),
    0 8px 20px rgba(0, 0, 0, 0.2);
}

.btn-3d-ghost:hover {
  transform: translateZ(20px) translateY(-4px);
  background: var(--ghost-hover-bg);
  border-color: var(--ghost-hover-border);
  box-shadow:
    0 10px 0 0 rgba(0, 0, 0, 0.3),
    0 14px 30px rgba(0, 212, 255, 0.2);
}

.btn-3d-ghost:active {
  transform: translateZ(-4px) translateY(2px);
}




@media (min-width: 769px) {
  nav .btn-3d,
  nav .btn-3d:hover,
  nav .btn-3d:active {
    transform: none !important;
    transition: none !important;
  }
}
