/* ============================================
   WebWeaveX — Premium Dark Developer Landing
   ============================================ */

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

:root {
  --bg:           #0a0b0f;
  --bg-card:      #111318;
  --bg-card-2:    #14161d;
  --border:       rgba(255,255,255,0.07);
  --border-glow:  rgba(120,90,255,0.3);
  --accent:       #7c5df9;
  --accent2:      #38bdf8;
  --text:         #e8eaf0;
  --text-muted:   #6b7280;
  --text-dim:     #9ca3af;
  --py:           #3b82f6;
  --node:         #f59e0b;
  --dart:         #06b6d4;
  --java:         #ef4444;
  --kotlin:       #a855f7;
  --font:         'Inter', system-ui, sans-serif;
  --mono:         'JetBrains Mono', 'Fira Code', monospace;
  --radius:       14px;
  --radius-sm:    8px;
}

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* ── Layout ── */
.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ── Nav ── */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  padding: 16px 0;
  transition: background 0.3s, box-shadow 0.3s;
}
.nav-scrolled {
  background: rgba(10,11,15,0.85);
  box-shadow: 0 1px 0 var(--border);
  backdrop-filter: blur(12px);
}
.nav-inner {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.nav-logo {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--text);
  text-decoration: none;
}
.logo-icon { font-size: 1.3rem; }
.nav-links {
  display: flex;
  align-items: center;
  gap: 28px;
}
.nav-links a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
  transition: color 0.2s;
}
.nav-links a:hover { color: var(--text); }
.nav-github {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--text) !important;
  background: rgba(255,255,255,0.07);
  border: 1px solid var(--border);
  padding: 6px 14px;
  border-radius: 8px;
  transition: background 0.2s, border-color 0.2s !important;
}
.nav-github:hover {
  background: rgba(255,255,255,0.12) !important;
  border-color: rgba(255,255,255,0.15) !important;
}

/* ── Hero ── */
.hero {
  position: relative;
  padding: 130px 0 80px;
  text-align: center;
  overflow: hidden;
}
.hero-glow {
  position: absolute;
  top: -100px;
  left: 50%;
  transform: translateX(-50%);
  width: 800px;
  height: 600px;
  background: radial-gradient(ellipse at center, rgba(124,93,249,0.18) 0%, transparent 70%);
  pointer-events: none;
}
.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 16px;
  border: 1px solid var(--border-glow);
  border-radius: 50px;
  font-size: 0.8rem;
  font-weight: 500;
  color: #a78bfa;
  background: rgba(124,93,249,0.08);
  margin-bottom: 28px;
}
.hero-title {
  font-size: clamp(2.4rem, 5vw, 4rem);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.03em;
  margin-bottom: 22px;
}
.gradient-text {
  background: linear-gradient(135deg, #7c5df9 0%, #38bdf8 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.hero-sub {
  font-size: 1.15rem;
  color: var(--text-muted);
  max-width: 540px;
  margin: 0 auto 36px;
  line-height: 1.7;
}
.hero-cta {
  display: flex;
  gap: 14px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 48px;
}
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 28px;
  border-radius: 10px;
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  transition: all 0.2s;
  cursor: pointer;
}
.btn-primary {
  background: linear-gradient(135deg, #7c5df9, #5b3fd4);
  color: #fff;
  box-shadow: 0 4px 24px rgba(124,93,249,0.35);
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 32px rgba(124,93,249,0.5);
}
.btn-ghost {
  background: rgba(255,255,255,0.05);
  color: var(--text);
  border: 1px solid var(--border);
}
.btn-ghost:hover {
  background: rgba(255,255,255,0.1);
  border-color: rgba(255,255,255,0.15);
}
.hero-stats {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
}
.stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 0 32px;
}
.stat-num {
  font-size: 2rem;
  font-weight: 800;
  background: linear-gradient(135deg, #7c5df9, #38bdf8);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1;
}
.stat-label { color: var(--text-muted); font-size: 0.8rem; margin-top: 4px; }
.stat-divider { width: 1px; height: 40px; background: var(--border); }

/* ── Section ── */
.section { padding: 90px 0; }
.section-alt { background: rgba(255,255,255,0.015); }
.section-header {
  text-align: center;
  margin-bottom: 52px;
}
.section-header h2 {
  font-size: clamp(1.8rem, 3vw, 2.5rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 10px;
}
.section-header p { color: var(--text-muted); font-size: 1.05rem; }

/* ── Tabs ── */
.tabs {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}
.tab-buttons {
  display: flex;
  border-bottom: 1px solid var(--border);
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}
.tab-btn {
  padding: 14px 22px;
  background: none;
  border: none;
  color: var(--text-muted);
  font-family: var(--font);
  font-size: 0.88rem;
  font-weight: 500;
  cursor: pointer;
  white-space: nowrap;
  transition: color 0.2s, background 0.2s;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
}
.tab-btn:hover { color: var(--text); background: rgba(255,255,255,0.03); }
.tab-btn.active { color: var(--accent); border-bottom-color: var(--accent); }
.tab-content { display: none; padding: 28px; }
.tab-content.active { display: block; }

.code-block {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  overflow: hidden;
  margin-bottom: 16px;
}
.code-block:last-child { margin-bottom: 0; }
.code-header {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  border-bottom: 1px solid var(--border);
  font-size: 0.78rem;
  color: var(--text-muted);
  font-family: var(--mono);
}
.lang-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  display: inline-block;
}
.py-dot { background: var(--py); }
.node-dot { background: var(--node); }
.dart-dot { background: var(--dart); }
.java-dot { background: var(--java); }
.kotlin-dot { background: var(--kotlin); }
.code-block pre { padding: 18px; overflow-x: auto; }
.code-block code {
  font-family: var(--mono);
  font-size: 0.88rem;
  color: #c9d1d9;
  line-height: 1.6;
}

/* ── Examples Grid ── */
.examples-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 20px;
}
.example-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  transition: border-color 0.2s, transform 0.2s;
}
.example-card:hover {
  border-color: var(--border-glow);
  transform: translateY(-3px);
}
.example-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 18px;
  border-bottom: 1px solid var(--border);
}
.lang-badge {
  font-size: 0.75rem;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 50px;
  letter-spacing: 0.02em;
}
.lang-badge.py     { background: rgba(59,130,246,0.15); color: #60a5fa; }
.lang-badge.node   { background: rgba(245,158,11,0.15); color: #fbbf24; }
.lang-badge.dart   { background: rgba(6,182,212,0.15);  color: #22d3ee; }
.lang-badge.java   { background: rgba(239,68,68,0.15);  color: #f87171; }
.lang-badge.kotlin { background: rgba(168,85,247,0.15); color: #c084fc; }
.example-endpoint {
  font-family: var(--mono);
  font-size: 0.75rem;
  color: var(--text-muted);
}
.example-code {
  padding: 20px 18px;
  overflow-x: auto;
  font-family: var(--mono);
  font-size: 0.82rem;
  line-height: 1.7;
  color: #c9d1d9;
}
.kw  { color: #ff7b72; }
.fn  { color: #79c0ff; }
.str { color: #a5d6ff; }
.cmt { color: #6e7681; font-style: italic; }
.num { color: #f2cc60; }

/* ── SDK Grid ── */
.sdk-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 16px;
}
.sdk-card {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 22px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  text-decoration: none;
  transition: border-color 0.2s, transform 0.2s, box-shadow 0.2s;
}
.sdk-card:hover {
  border-color: var(--border-glow);
  transform: translateY(-3px);
  box-shadow: 0 8px 32px rgba(0,0,0,0.4);
}
.sdk-icon {
  font-size: 2rem;
  width: 52px; height: 52px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 12px;
}
.py-icon     { background: rgba(59,130,246,0.12); }
.node-icon   { background: rgba(245,158,11,0.12); }
.dart-icon   { background: rgba(6,182,212,0.12);  }
.java-icon   { background: rgba(239,68,68,0.12);  }
.kotlin-icon { background: rgba(168,85,247,0.12); }
.sdk-info h3 { font-size: 1.05rem; font-weight: 600; color: var(--text); }
.sdk-registry { font-size: 0.78rem; color: var(--text-muted); }
.sdk-cmd {
  font-family: var(--mono);
  font-size: 0.78rem;
  color: var(--text-dim);
  background: var(--bg);
  padding: 8px 12px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  word-break: break-all;
}

/* ── Footer ── */
.footer {
  padding: 36px 0;
  border-top: 1px solid var(--border);
}
.footer-inner {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
  justify-content: space-between;
}
.footer-brand {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 600;
}
.footer-version {
  font-size: 0.75rem;
  color: var(--text-muted);
  background: rgba(255,255,255,0.06);
  padding: 2px 8px;
  border-radius: 50px;
}
.footer-copy { font-size: 0.85rem; color: var(--text-muted); }
.footer-copy a { color: var(--accent); text-decoration: none; }
.footer-copy a:hover { text-decoration: underline; }
.footer-gh {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.9rem;
  transition: color 0.2s;
}
.footer-gh:hover { color: var(--text); }

/* ── Responsive ── */
@media (max-width: 640px) {
  .hero { padding: 100px 0 60px; }
  .nav-links a:not(.nav-github) { display: none; }
  .hero-stats { gap: 0; }
  .stat { padding: 0 18px; }
  .examples-grid { grid-template-columns: 1fr; }
  .sdk-grid { grid-template-columns: 1fr; }
  .footer-inner { flex-direction: column; align-items: flex-start; }
}
