:root {
  /* Light Mode (amber accents) */
  --primary: #d97706; 
  --primary-hover: #b45309;
  --bg-color: #fafafa;
  --surface-color: #f4f4f5;
  --card-bg: rgba(255, 255, 255, 0.7);
  --text-main: #0a0a0d;
  --text-muted: #52525b;
  --border-color: #e4e4e7;
  --glass-border: rgba(217, 119, 6, 0.2);
  --glass-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.05);
  --gold-glow: rgba(217, 119, 6, 0.3);
  --transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

[data-theme="dark"] {
  /* Dark Obsidian Fantasy */
  --primary: #f59e0b; /* liquid gold */
  --primary-hover: #fbbf24;
  --bg-color: #0a0a0d; /* obsidian */
  --surface-color: #121217;
  --card-bg: rgba(20, 20, 25, 0.6);
  --text-main: #f8fafc;
  --text-muted: #a1a1aa;
  --border-color: rgba(255, 255, 255, 0.05);
  --glass-border: rgba(245, 158, 11, 0.2);
  --glass-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.5);
  --gold-glow: rgba(245, 158, 11, 0.4);
}

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

html { scroll-behavior: smooth; }

body {
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", sans-serif;
  background-color: var(--bg-color);
  color: var(--text-main);
  line-height: 1.6;
  transition: background-color 0.4s, color 0.4s;
  overflow-x: hidden;
}

a { text-decoration: none; color: inherit; }

.container { max-width: 1200px; margin: 0 auto; padding: 0 20px; }

/* Navbar - Frosted Glass */
header {
  position: fixed;
  top: 0; left: 0; right: 0;
  background-color: rgba(var(--bg-color), 0.7);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-color);
  z-index: 1000;
  transition: var(--transition);
}

.nav-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 70px;
}

.logo {
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--text-main);
  letter-spacing: 1px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.logo span { color: var(--primary); }

.nav-links {
  display: flex;
  gap: 1.8rem;
  align-items: center;
}

.nav-links a {
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--text-main);
  transition: color 0.3s;
}

.nav-links a:hover { color: var(--primary); }

.nav-cta {
  background: rgba(245, 158, 11, 0.1);
  border: 1px solid var(--primary);
  color: var(--primary) !important;
  padding: 6px 16px;
  border-radius: 20px;
  transition: var(--transition);
}
.nav-cta:hover {
  background: var(--primary);
  color: #fff !important;
  box-shadow: 0 0 15px var(--gold-glow);
}

.theme-toggle {
  background: transparent;
  border: 1px solid var(--border-color);
  border-radius: 50%;
  width: 38px; height: 38px;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer; color: var(--text-main);
  transition: var(--transition);
}
.theme-toggle:hover {
  border-color: var(--primary);
  color: var(--primary);
  box-shadow: 0 0 10px var(--gold-glow);
}
.theme-toggle svg { width: 18px; height: 18px; }
.sun-icon { display: none; }
.moon-icon { display: block; }
[data-theme="dark"] .sun-icon { display: block; }
[data-theme="dark"] .moon-icon { display: none; }

/* Hero Section */
.hero {
  padding: 180px 0 120px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: -50%; left: 50%; transform: translateX(-50%);
  width: 800px; height: 800px;
  background: radial-gradient(circle, var(--gold-glow) 0%, transparent 60%);
  opacity: 0.15; z-index: -1;
  pointer-events: none;
}

/* 3D Glowing Gold Ring */
.glowing-ring-container {
  perspective: 1000px;
  margin: 0 auto 40px;
  width: 140px; height: 140px;
}
.glowing-ring {
  width: 100%; height: 100%;
  border-radius: 50%;
  border: 2px solid var(--glass-border);
  border-top: 4px solid var(--primary);
  border-bottom: 4px solid var(--primary);
  box-shadow: 0 0 40px var(--gold-glow), inset 0 0 20px var(--gold-glow);
  animation: ringSpin 6s cubic-bezier(0.4, 0, 0.2, 1) infinite;
  transform-style: preserve-3d;
}
@keyframes ringSpin {
  0% { transform: rotateX(70deg) rotateY(0deg) rotateZ(0deg); }
  50% { transform: rotateX(70deg) rotateY(15deg) rotateZ(180deg); }
  100% { transform: rotateX(70deg) rotateY(0deg) rotateZ(360deg); }
}

.hero h1 {
  font-size: 3.5rem; font-weight: 800; margin-bottom: 1.5rem; letter-spacing: 2px;
}
.hero h1 .highlight {
  color: var(--primary);
  text-shadow: 0 0 20px var(--gold-glow);
}

.hero p {
  font-size: 1.2rem; color: var(--text-muted);
  max-width: 650px; margin: 0 auto 3rem;
}

.btn {
  display: inline-block; padding: 14px 36px; border-radius: 8px;
  font-size: 1.1rem; font-weight: 600; cursor: pointer;
  transition: var(--transition); border: 1px solid transparent;
}
.btn-primary {
  background: var(--primary); color: #fff;
  box-shadow: 0 4px 15px var(--gold-glow);
}
.btn-primary:hover {
  background: var(--primary-hover); transform: translateY(-3px);
  box-shadow: 0 8px 25px var(--gold-glow);
}
.btn-secondary {
  background: rgba(255, 255, 255, 0.05); color: var(--text-main);
  border-color: var(--glass-border); backdrop-filter: blur(5px);
}
.btn-secondary:hover {
  border-color: var(--primary); transform: translateY(-3px);
  box-shadow: 0 0 15px var(--gold-glow);
}
.cta-group { display: flex; gap: 1.5rem; justify-content: center; }

/* Sections & Glass Cards */
section { padding: 100px 0; position: relative; }
.section-title { text-align: center; font-size: 2.2rem; margin-bottom: 1rem; font-weight: 700; }
.section-subtitle { text-align: center; color: var(--text-muted); margin-bottom: 4rem; font-size: 1.1rem; }

.glass-card {
  background: var(--card-bg);
  backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--border-color);
  border-radius: 16px; padding: 2.5rem;
  box-shadow: var(--glass-shadow);
  transition: var(--transition);
  position: relative; overflow: hidden;
}
.glass-card::before {
  content: ''; position: absolute; top: 0; left: 0; right: 0; height: 2px;
  background: linear-gradient(90deg, transparent, var(--primary), transparent);
  opacity: 0; transition: var(--transition);
}
.glass-card:hover {
  border-color: var(--glass-border);
  transform: translateY(-5px);
  box-shadow: 0 15px 35px rgba(0,0,0,0.2), 0 0 20px var(--gold-glow);
}
.glass-card:hover::before { opacity: 1; }

/* Features Grid */
.features-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2rem; }
.feature-icon {
  width: 60px; height: 60px; border-radius: 12px;
  background: rgba(245, 158, 11, 0.1); color: var(--primary);
  display: flex; align-items: center; justify-content: center; margin-bottom: 1.5rem;
}
.feature-icon svg { width: 30px; height: 30px; }

/* Node Status Matrix */
.node-matrix {
  margin-top: 3rem; padding: 2rem; border-radius: 12px;
  background: rgba(0,0,0,0.2); border: 1px solid var(--border-color);
  display: flex; flex-wrap: wrap; gap: 1.5rem; justify-content: center;
}
.node-item {
  display: flex; align-items: center; gap: 10px; font-family: monospace; font-size: 1.1rem;
}
.status-dot {
  width: 10px; height: 10px; border-radius: 50%; background: #10b981;
  box-shadow: 0 0 10px #10b981; animation: pulse 2s infinite;
}
.ping { color: var(--primary); font-weight: bold; }
@keyframes pulse { 0% { opacity: 1; transform: scale(1); } 50% { opacity: 0.5; transform: scale(1.2); } 100% { opacity: 1; transform: scale(1); } }

/* Streaming & AI */
.media-ai-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 2rem; }
.media-ai-grid .glass-card h3 { color: var(--primary); margin-bottom: 1rem; font-size: 1.5rem; }

/* Pricing */
.pricing-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2rem; }
.price-card { display: flex; flex-direction: column; text-align: center; }
.price-card.popular { border-color: var(--primary); }
.price-card.popular .popular-badge {
  position: absolute; top: 0; left: 50%; transform: translate(-50%, -50%);
  background: var(--primary); color: #fff; padding: 4px 16px; border-radius: 20px;
  font-size: 0.85rem; font-weight: bold; box-shadow: 0 0 10px var(--gold-glow);
}
.price-amount { font-size: 3.5rem; font-weight: 800; color: var(--primary); margin: 1.5rem 0; text-shadow: 0 0 15px var(--gold-glow); }
.price-amount span { font-size: 1rem; color: var(--text-muted); font-weight: normal; }
.price-features { list-style: none; margin-bottom: 2rem; flex-grow: 1; text-align: left; }
.price-features li { margin-bottom: 12px; display: flex; align-items: center; gap: 10px; }
.price-features li svg { color: var(--primary); width: 18px; height: 18px; }

/* FAQ & Reviews */
.reviews-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2rem; }
.faq-list { max-width: 800px; margin: 0 auto; }
.faq-item { margin-bottom: 1.5rem; padding-bottom: 1.5rem; border-bottom: 1px solid var(--border-color); }
.faq-item h4 { color: var(--primary); margin-bottom: 0.5rem; }

/* Footer */
footer {
  border-top: 1px solid var(--border-color); padding: 4rem 0 2rem; text-align: center;
  background: rgba(0,0,0,0.1);
}
.footer-links { display: flex; justify-content: center; gap: 2.5rem; margin-bottom: 2rem; }
.footer-links a { color: var(--text-muted); transition: var(--transition); }
.footer-links a:hover { color: var(--primary); }
.footer-copy { color: var(--text-muted); font-size: 0.9rem; }

/* Page Generic */
.page-content { padding: 150px 0 100px; min-height: calc(100vh - 120px); }
.page-content h1 { font-size: 2.5rem; margin-bottom: 2rem; color: var(--primary); }
.page-content h2 { font-size: 1.5rem; margin-top: 2rem; margin-bottom: 1rem; border-left: 4px solid var(--primary); padding-left: 12px; }
.page-content p, .page-content ul { margin-bottom: 1rem; color: var(--text-muted); }
.page-content ul { padding-left: 20px; }
.page-content li { margin-bottom: 0.5rem; }

@media (max-width: 992px) {
  .features-grid, .pricing-grid, .reviews-grid, .media-ai-grid { grid-template-columns: repeat(2, 1fr); }
  .nav-links { display: none; }
}
@media (max-width: 768px) {
  .hero h1 { font-size: 2.2rem; }
  .features-grid, .pricing-grid, .reviews-grid, .media-ai-grid { grid-template-columns: 1fr; }
  .cta-group { flex-direction: column; }
}
