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

:root {
  --bg: #0a0a0a;
  --bg-raised: #141414;
  --bg-surface: #1c1c1c;
  --bg-surface-hover: #242424;
  --text: #e8e8e8;
  --text-dim: #888;
  --text-dimmer: #555;
  --accent: #7aa2f7;
  --accent-hover: #a4b8fc;
  --green: #44cf6e;
  --red: #fb464c;
  --yellow: #e0de71;
  --border: #2a2a2a;
  --code-bg: #181818;
  --radius: 8px;
  --radius-lg: 12px;
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, monospace;
}

[data-theme="light"] {
  --bg: #ffffff;
  --bg-raised: #f7f7f8;
  --bg-surface: #ededed;
  --bg-surface-hover: #e3e3e3;
  --text: #1a1a1a;
  --text-dim: #666;
  --text-dimmer: #aaa;
  --accent: #086ddd;
  --accent-hover: #0655b5;
  --green: #08b94e;
  --red: #e93147;
  --yellow: #e0ac00;
  --border: #ddd;
  --code-bg: #f4f4f4;
}

html { scroll-behavior: smooth; }
body { font-family: var(--font); background: var(--bg); color: var(--text); line-height: 1.6; overflow-x: hidden; }
a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-hover); }
code { font-family: var(--mono); background: var(--code-bg); padding: 2px 6px; border-radius: 4px; font-size: 0.88em; word-break: break-word; }
pre { overflow-x: auto; max-width: 100%; }

nav { position: sticky; top: 0; z-index: 100; background: var(--bg); border-bottom: 1px solid var(--border); }
.nav-inner { max-width: 1200px; margin: 0 auto; padding: 0 24px; height: 56px; display: flex; align-items: center; justify-content: space-between; }
.nav-logo { display: flex; align-items: center; gap: 8px; color: var(--text); font-weight: 700; font-size: 15px; text-decoration: none; }
.nav-logo img { width: 28px; height: 28px; border-radius: 4px; flex-shrink: 0; }
.nav-logo svg { flex-shrink: 0; }
.nav-links { display: flex; gap: 24px; }
.nav-links a { color: var(--text-dim); font-size: 14px; transition: color 0.15s; }
.nav-links a:hover { color: var(--text); }
.nav-actions { display: flex; align-items: center; gap: 12px; }
.nav-discord { font-size: 13px; }
#theme-toggle { background: none; border: 1px solid var(--border); color: var(--text-dim); font-size: 18px; cursor: pointer; width: 36px; height: 36px; border-radius: 6px; display: flex; align-items: center; justify-content: center; transition: background 0.15s, color 0.15s; }
#theme-toggle:hover { background: var(--bg-surface); color: var(--text); }

.btn { display: inline-flex; align-items: center; justify-content: center; padding: 10px 20px; border-radius: var(--radius); font-size: 14px; font-weight: 500; cursor: pointer; transition: background 0.15s, color 0.15s, border-color 0.15s; text-decoration: none; border: 1px solid transparent; }
.btn-primary { background: var(--accent); color: #fff; border-color: var(--accent); }
.btn-primary:hover { background: var(--accent-hover); border-color: var(--accent-hover); color: #fff; }
.btn-outline { background: transparent; color: var(--text); border-color: var(--border); }
.btn-outline:hover { background: var(--bg-surface); border-color: var(--text-dimmer); }
.btn-ghost { background: transparent; color: var(--text-dim); border-color: transparent; }
.btn-ghost:hover { color: var(--text); }
.btn-block { width: 100%; }
.btn-sm { padding: 6px 14px; font-size: 13px; }
.btn-disabled { opacity: 0.5; pointer-events: none; cursor: default; }

.hero { max-width: 1200px; margin: 0 auto; padding: 80px 24px 40px; display: grid; grid-template-columns: 1fr; gap: 48px; align-items: center; }
@media (min-width: 900px) { .hero { grid-template-columns: minmax(0, 440px) minmax(0, 1fr); } }
.hero-content { max-width: 520px; }
.hero-badge { display: inline-block; font-size: 12px; font-weight: 500; color: var(--accent); background: color-mix(in srgb, var(--accent) 12%, transparent); border: 1px solid color-mix(in srgb, var(--accent) 25%, transparent); border-radius: 20px; padding: 4px 14px; margin-bottom: 20px; letter-spacing: 0.02em; }
.hero-banner { width: 260px; height: auto; margin-bottom: 16px; }
h1 { font-size: 44px; font-weight: 700; line-height: 1.1; letter-spacing: -0.02em; margin-bottom: 20px; }
.hero-sub { font-size: 17px; color: var(--text-dim); line-height: 1.6; margin-bottom: 32px; }
.hero-ctas { display: flex; gap: 12px; margin-bottom: 32px; }
.hero-stats { display: flex; gap: 32px; }
.hero-stats div { font-size: 13px; color: var(--text-dimmer); }
.hero-stats span { font-weight: 600; color: var(--text-dim); }
.hero-discord { font-size: 13px; color: var(--text-dimmer); margin-top: -20px; margin-bottom: 16px; }
.hero-discord a { color: var(--text-dim); }

.hero-visual { position: relative; }
.mock-window { background: var(--bg-raised); border: 1px solid var(--border); border-radius: var(--radius-lg); overflow: hidden; box-shadow: 0 20px 60px rgba(0,0,0,0.3); }
.mock-titlebar { display: flex; align-items: center; gap: 8px; padding: 10px 14px; background: var(--bg-surface); border-bottom: 1px solid var(--border); }
.mock-dot { width: 10px; height: 10px; border-radius: 50%; }
.mock-dot.red { background: #fb464c; }
.mock-dot.yellow { background: #e0de71; }
.mock-dot.green { background: #44cf6e; }
.mock-title { font-size: 12px; color: var(--text-dim); font-family: var(--mono); margin-left: 8px; }

.carousel { position: relative; }
.carousel-slide { display: none; width: 100%; height: auto; border-radius: var(--radius-lg); }
.carousel-slide.active { display: block; }
.carousel-controls { display: flex; align-items: center; justify-content: center; gap: 12px; margin-top: 16px; }
.carousel-prev, .carousel-next { background: var(--bg-surface); border: 1px solid var(--border); color: var(--text-dim); width: 36px; height: 36px; border-radius: 50%; cursor: pointer; font-size: 16px; display: flex; align-items: center; justify-content: center; transition: background 0.15s, color 0.15s; }
.carousel-prev:hover, .carousel-next:hover { background: var(--bg-surface-hover); color: var(--text); }
.carousel-dots { display: flex; gap: 8px; }
.carousel-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--border); cursor: pointer; transition: background 0.15s; }
.carousel-dot.active { background: var(--accent); }
.mock-sidebar { position: absolute; left: 0; top: 0; bottom: 0; width: 140px; background: rgba(20,20,20,0.95); border-right: 1px solid rgba(255,255,255,0.06); padding: 10px 8px; font-size: 9px; font-family: var(--mono); color: #999; }
.mock-sb-item { padding: 4px 6px; border-radius: 3px; margin-bottom: 2px; }
.mock-sb-item.active { background: rgba(122,162,247,0.15); color: #7aa2f7; }
.mock-sb-item.err { color: #fb464c; }
.mock-sb-divider { height: 1px; background: rgba(255,255,255,0.06); margin: 6px 0; }
.mock-sb-section { font-weight: 600; color: #666; font-size: 8px; text-transform: uppercase; letter-spacing: 0.05em; margin-bottom: 3px; padding: 0 6px; }
.mock-sb-toggle { padding: 1px 6px; color: #7aa2f7; }

.mock-cable { position: absolute; height: 1px; background: #7aa2f7; opacity: 0.4; }
.mock-cable.c1 { top: 60%; left: 20%; width: 65%; transform: rotate(-8deg); }
.mock-cable.c2 { top: 45%; left: 30%; width: 50%; transform: rotate(5deg); }
.mock-cable.c3 { top: 75%; left: 25%; width: 55%; transform: rotate(-12deg); }

.mock-server { position: absolute; font-size: 9px; font-family: var(--mono); color: #fff; background: #2a2a2a; padding: 2px 6px; border-radius: 3px; border: 1px solid #44cf6e; }
.mock-server.s1 { top: 50%; left: 52%; }
.mock-server.s2 { top: 35%; left: 65%; }
.mock-server.s3 { top: 55%; left: 72%; border-color: #fb464c; }
.mock-ping { display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: #44cf6e; margin-right: 2px; box-shadow: 0 0 6px #44cf6e; }
.mock-ping.bad { background: #fb464c; box-shadow: 0 0 6px #fb464c; }
.mock-ixp { position: absolute; top: 58%; left: 40%; font-size: 8px; font-family: var(--mono); color: #e0de71; background: rgba(224,222,113,0.15); padding: 1px 4px; border-radius: 2px; }
.mock-cloud { position: absolute; top: 40%; left: 60%; font-size: 8px; font-family: var(--mono); color: #a882ff; background: rgba(168,130,255,0.15); padding: 1px 4px; border-radius: 2px; }

section { padding: 80px 24px; }
.section-inner { max-width: 1200px; margin: 0 auto; }
h2 { font-size: 36px; font-weight: 700; letter-spacing: -0.02em; margin-bottom: 16px; }
.section-sub { font-size: 17px; color: var(--text-dim); max-width: 600px; margin-bottom: 48px; }

.features { background: var(--bg-raised); }
.feature-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.feature-card { background: var(--bg); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 28px; transition: border-color 0.15s, transform 0.15s; }
.feature-card:hover { border-color: var(--accent); transform: translateY(-2px); }
.feature-icon { font-size: 28px; margin-bottom: 16px; }
.feature-card h3 { font-size: 17px; font-weight: 600; margin-bottom: 8px; }
.feature-card p { font-size: 14px; color: var(--text-dim); line-height: 1.6; }

.how-it-works { background: var(--bg); }
.steps { display: flex; flex-direction: column; gap: 48px; margin-top: 32px; }
.step { display: grid; grid-template-columns: 60px 1fr; gap: 24px; align-items: start; }
.step-number { width: 48px; height: 48px; border-radius: 50%; background: var(--accent); color: #fff; display: flex; align-items: center; justify-content: center; font-size: 20px; font-weight: 700; flex-shrink: 0; }
.step-content h3 { font-size: 20px; font-weight: 600; margin-bottom: 12px; }
.step-content p { font-size: 15px; color: var(--text-dim); line-height: 1.7; }
.step-content pre { background: var(--code-bg); border: 1px solid var(--border); border-radius: var(--radius); padding: 16px; overflow-x: auto; font-size: 13px; line-height: 1.5; margin-top: 12px; }

.terminal-showcase { background: var(--bg-raised); }
.mock-terminal { background: #0d0d0d; padding: 20px; font-family: var(--mono); font-size: 13px; line-height: 1.7; color: #d4d4d4; min-height: 200px; }
.prompt { color: #7aa2f7; }
.term-ok { color: #44cf6e; }
.term-warn { color: #e0de71; }
.cursor { animation: blink 1s step-end infinite; }
@keyframes blink { 50% { opacity: 0; } }

.pricing { background: var(--bg); }
.pricing-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.pricing-card { background: var(--bg-raised); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 32px 24px; display: flex; flex-direction: column; position: relative; }
.pricing-card.popular { border-color: var(--accent); }
.pricing-badge { position: absolute; top: -12px; left: 50%; transform: translateX(-50%); background: var(--accent); color: #fff; font-size: 11px; font-weight: 600; padding: 3px 12px; border-radius: 20px; text-transform: uppercase; letter-spacing: 0.05em; }
.pricing-tier { font-size: 18px; font-weight: 600; margin-bottom: 8px; }
.pricing-price { font-size: 40px; font-weight: 700; margin-bottom: 4px; }
.pricing-price span { font-size: 16px; font-weight: 400; color: var(--text-dim); }
.pricing-alt { font-size: 12px; color: var(--text-dimmer); margin-bottom: 16px; }
.pricing-desc { font-size: 14px; color: var(--text-dim); margin-bottom: 24px; }
.pricing-features { list-style: none; margin-bottom: 28px; flex: 1; }
.pricing-features li { font-size: 14px; color: var(--text-dim); padding: 6px 0; border-bottom: 1px solid var(--border); }
.pricing-features li:last-child { border-bottom: none; }
.pricing-features li::before { content: "\2713 "; color: var(--green); font-weight: 600; }

.faq { background: var(--bg-raised); }
.faq-list { max-width: 720px; }
details { border-bottom: 1px solid var(--border); }
details summary { padding: 20px 0; font-size: 16px; font-weight: 500; cursor: pointer; list-style: none; display: flex; justify-content: space-between; align-items: center; }
details summary::after { content: "+"; font-size: 20px; color: var(--text-dim); flex-shrink: 0; margin-left: 16px; }
details[open] summary::after { content: "\2212"; }
details summary:hover { color: var(--accent); }
details p { padding: 0 0 20px; font-size: 15px; color: var(--text-dim); line-height: 1.7; max-width: 600px; }

.download { background: var(--bg); text-align: center; }
.download h2 { margin-bottom: 12px; }
.download p { color: var(--text-dim); margin-bottom: 32px; }
.download-or { margin-top: 16px; font-size: 13px; color: var(--text-dimmer); }
.download-community { margin-top: 20px; font-size: 14px; color: var(--text-dim); }
.download-community a { color: var(--accent); }
.download-platforms { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; }

.contact { background: var(--bg-raised); text-align: center; }
.contact .section-inner { display: flex; flex-direction: column; align-items: center; }
.contact h2 { margin-bottom: 8px; }

footer { background: var(--bg-raised); border-top: 1px solid var(--border); padding: 24px; }
.footer-inner { max-width: 1200px; margin: 0 auto; text-align: center; }
.footer-inner p { font-size: 12px; color: var(--text-dimmer); }
.footer-inner a { color: var(--text-dimmer); }
.footer-inner a:hover { color: var(--accent); }

@media (max-width: 900px) {
  .hero { grid-template-columns: 1fr; padding: 60px 24px 24px; }
  .hero-content { max-width: 100%; }
  .hero-visual { order: 2; }
  .carousel-slide { max-width: 100%; }
  .feature-grid { grid-template-columns: 1fr 1fr; }
  .pricing-grid { grid-template-columns: 1fr 1fr; }
  .footer-inner { text-align: center; }
  .nav-links { display: none; }
  .nav-discord { display: none; }
  h1 { font-size: 32px; }
  h2 { font-size: 28px; }
}

@media (max-width: 600px) {
  .feature-grid { grid-template-columns: 1fr; }
  .pricing-grid { grid-template-columns: 1fr; }
  .hero-ctas { flex-direction: column; }
  .download-platforms { flex-direction: column; align-items: center; }
  .footer-links { grid-template-columns: 1fr; }
  .hero-badge { font-size: 11px; }
  .step { grid-template-columns: 1fr; gap: 12px; }
  .step-number { width: 36px; height: 36px; font-size: 16px; }
}