/* ==================== RESET & BASE ==================== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --primary: #e85d04;
  --primary-dark: #c44d00;
  --secondary: #1b2a4a;
  --accent: #0077b6;
  --bg: #ffffff;
  --bg-dark: #0f1724;
  --bg-card: #f8fafc;
  --bg-card-dark: #161f2e;
  --text: #1e2a3a;
  --text-muted: #64748b;
  --text-light: #94a3b8;
  --border: #e2e8f0;
  --border-dark: #1e2d40;
  --radius: 12px;
  --radius-lg: 20px;
  --shadow: 0 4px 24px rgba(0,0,0,.08);
  --shadow-lg: 0 12px 48px rgba(0,0,0,.15);
  --font: 'Inter', system-ui, sans-serif;
}

html { scroll-behavior: smooth; }

body {
  font-family: var(--font);
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
  overflow-x: hidden;
}

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

a { text-decoration: none; color: inherit; }
code { font-family: 'Fira Code', 'Cascadia Code', monospace; }

/* ==================== NAVBAR ==================== */
.navbar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  background: rgba(255,255,255,.95);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  height: 64px;
}

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

.brand { display: flex; align-items: center; gap: 10px; }
.brand-logo { height: 36px; width: auto; }

.nav-links {
  display: flex;
  align-items: center;
  gap: 8px;
  list-style: none;
}

.nav-links a {
  font-size: .9rem;
  font-weight: 500;
  color: var(--text-muted);
  padding: 6px 12px;
  border-radius: 8px;
  transition: color .2s, background .2s;
}
.nav-links a:hover { color: var(--primary); background: #fff4ee; }

.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}
.hamburger span {
  display: block;
  width: 24px; height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: all .3s;
}

/* ==================== BUTTONS ==================== */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 22px;
  border-radius: 10px;
  font-size: .9rem;
  font-weight: 600;
  cursor: pointer;
  border: 2px solid transparent;
  transition: all .2s;
}

.btn-primary {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}
.btn-primary:hover { background: var(--primary-dark); border-color: var(--primary-dark); transform: translateY(-1px); }

.btn-outline {
  background: transparent;
  color: var(--primary);
  border-color: var(--primary);
}
.btn-outline:hover { background: var(--primary); color: #fff; }

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

.btn-large { padding: 14px 32px; font-size: 1rem; }

/* ==================== TAGS ==================== */
.tag {
  display: inline-block;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: .78rem;
  font-weight: 600;
  letter-spacing: .02em;
}
.tag-blue { background: #dbeafe; color: #1d4ed8; }
.tag-orange { background: #ffedd5; color: #c2410c; }
.tag-dark { background: #1e293b; color: #e2e8f0; }
.tag-green { background: #dcfce7; color: #166534; }
.tag-purple { background: #ede9fe; color: #6d28d9; }
.tag-sm { padding: 3px 10px; font-size: .72rem; }

/* ==================== HERO ==================== */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding: 100px 0 80px;
  position: relative;
  overflow: hidden;
}

.hero-gradient-bg {
  position: absolute;
  top: -200px; right: -200px;
  width: 700px; height: 700px;
  background: radial-gradient(circle, rgba(232,93,4,.12) 0%, transparent 70%);
  border-radius: 50%;
  pointer-events: none;
}

.hero-inner {
  position: relative;
  z-index: 1;
  text-align: center;
  max-width: 800px;
  margin: 0 auto;
}

.hero-badge {
  display: inline-block;
  background: linear-gradient(135deg, #ffedd5, #fed7aa);
  color: var(--primary-dark);
  padding: 6px 18px;
  border-radius: 20px;
  font-size: .85rem;
  font-weight: 600;
  margin-bottom: 24px;
  border: 1px solid #fdba74;
}

.hero-title {
  font-size: clamp(2.5rem, 6vw, 4.5rem);
  font-weight: 900;
  line-height: 1.1;
  color: var(--secondary);
  margin-bottom: 24px;
}

.gradient-text {
  background: linear-gradient(135deg, var(--primary), #ff8c42);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-subtitle {
  font-size: 1.15rem;
  color: var(--text-muted);
  max-width: 600px;
  margin: 0 auto 28px;
  line-height: 1.7;
}

.hero-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
  margin-bottom: 36px;
}

.hero-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 20px;
}

.hero-license {
  font-size: .82rem;
  color: var(--text-light);
}

/* ==================== STATS BAR ==================== */
.stats-bar {
  background: var(--secondary);
  padding: 28px 0;
}

.stats-inner {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  flex-wrap: wrap;
}

.stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 8px 48px;
}

.stat-num {
  font-size: 2rem;
  font-weight: 900;
  color: var(--primary);
}

.stat-label {
  font-size: .82rem;
  color: #94a3b8;
  margin-top: 2px;
}

.stat-divider {
  width: 1px;
  height: 48px;
  background: rgba(255,255,255,.1);
}

/* ==================== SECTIONS ==================== */
.section {
  padding: 80px 0;
}

.section-dark {
  background: var(--bg-dark);
  color: #e2e8f0;
}

.section-header {
  text-align: center;
  margin-bottom: 56px;
}

.section-label {
  display: inline-block;
  font-size: .8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .1em;
  color: var(--primary);
  margin-bottom: 12px;
}

.section-title {
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  font-weight: 800;
  color: inherit;
  margin-bottom: 16px;
}

.section-dark .section-title { color: #f1f5f9; }

.section-desc {
  font-size: 1.05rem;
  color: var(--text-muted);
  max-width: 560px;
  margin: 0 auto;
  line-height: 1.7;
}

.section-dark .section-desc { color: #94a3b8; }

/* ==================== CARDS ==================== */
.cards-grid {
  display: grid;
  gap: 24px;
}

.cards-3 { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }

.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px;
  transition: transform .2s, box-shadow .2s;
}

.card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }

.card-highlight {
  background: linear-gradient(135deg, #fff7ed, #ffedd5);
  border-color: #fed7aa;
}

.card-icon { font-size: 2rem; margin-bottom: 14px; }
.card h3 { font-size: 1.05rem; font-weight: 700; margin-bottom: 8px; color: var(--secondary); }
.card p { font-size: .9rem; color: var(--text-muted); line-height: 1.6; }

/* ==================== MODULES ==================== */
.modules-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 20px;
}

.module-card {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  background: var(--bg-card-dark);
  border: 1px solid var(--border-dark);
  border-radius: var(--radius);
  padding: 20px;
  transition: border-color .2s, transform .2s;
}

.module-card:hover { border-color: var(--primary); transform: translateY(-2px); }

.module-card-featured {
  border-color: var(--primary);
  background: linear-gradient(135deg, #1a1f2e, #1f2940);
}

.module-icon { font-size: 1.8rem; flex-shrink: 0; }

.module-body h4 { font-size: .95rem; font-weight: 700; color: #f1f5f9; margin-bottom: 6px; }
.module-body p { font-size: .84rem; color: #94a3b8; line-height: 1.55; }

.module-badge {
  display: inline-block;
  background: var(--primary);
  color: #fff;
  font-size: .72rem;
  font-weight: 700;
  padding: 2px 10px;
  border-radius: 20px;
  margin-top: 8px;
}

/* ==================== BETA BANNER ==================== */
.beta-banner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: center;
  background: linear-gradient(135deg, var(--secondary), #0f2040);
  border-radius: var(--radius-lg);
  padding: 56px;
  color: #fff;
}

.beta-badge {
  display: inline-block;
  background: rgba(232,93,4,.2);
  border: 1px solid var(--primary);
  color: var(--primary);
  padding: 4px 14px;
  border-radius: 20px;
  font-size: .82rem;
  font-weight: 700;
  margin-bottom: 16px;
}

.beta-banner h2 { font-size: 1.8rem; font-weight: 800; margin-bottom: 16px; }
.beta-banner p { color: #94a3b8; font-size: .95rem; line-height: 1.7; margin-bottom: 24px; }

.beta-list { list-style: none; display: flex; flex-direction: column; gap: 10px; margin-bottom: 28px; }
.beta-list li { font-size: .9rem; color: #cbd5e1; }

.beta-actions { display: flex; gap: 12px; flex-wrap: wrap; }

.beta-visual {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.beta-stat-box {
  background: rgba(255,255,255,.05);
  border: 1px solid rgba(255,255,255,.1);
  border-radius: var(--radius);
  padding: 24px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  transition: background .2s;
}
.beta-stat-box:hover { background: rgba(255,255,255,.1); }

.bsb-icon { font-size: 2rem; }
.bsb-label { font-size: .82rem; color: #94a3b8; font-weight: 500; }

/* ==================== API ==================== */
.api-grid {
  display: grid;
  grid-template-columns: 1fr 1.5fr;
  gap: 40px;
  align-items: start;
}

.api-endpoints h3 {
  font-size: 1rem;
  font-weight: 700;
  color: #f1f5f9;
  margin-bottom: 20px;
}

.endpoint-list { display: flex; flex-direction: column; gap: 10px; }

.endpoint {
  display: flex;
  align-items: center;
  gap: 12px;
  background: var(--bg-card-dark);
  border: 1px solid var(--border-dark);
  border-radius: 8px;
  padding: 10px 14px;
}

.method {
  font-size: .72rem;
  font-weight: 800;
  padding: 2px 8px;
  border-radius: 4px;
  min-width: 46px;
  text-align: center;
}
.method.get { background: #064e3b; color: #34d399; }
.method.post { background: #1e3a5f; color: #60a5fa; }

.endpoint code { font-size: .82rem; color: #cbd5e1; }

/* ==================== CODE BLOCKS ==================== */
.code-header {
  background: #0d1117;
  border-radius: var(--radius) var(--radius) 0 0;
  padding: 10px 16px;
  display: flex;
  align-items: center;
  gap: 6px;
  border: 1px solid #21262d;
  border-bottom: none;
}

.code-dot { width: 12px; height: 12px; border-radius: 50%; }
.code-dot.red { background: #ff5f57; }
.code-dot.yellow { background: #febc2e; }
.code-dot.green { background: #28c840; }

.code-title { font-size: .8rem; color: #6e7681; margin-left: 8px; }

.code-block {
  background: #0d1117;
  border: 1px solid #21262d;
  border-top: none;
  border-radius: 0 0 var(--radius) var(--radius);
  padding: 20px;
  overflow-x: auto;
  font-size: .83rem;
  line-height: 1.7;
  color: #c9d1d9;
}

.c-keyword { color: #ff7b72; }
.c-string { color: #a5d6ff; }
.c-header { color: #d2a8ff; }
.c-comment { color: #8b949e; font-style: italic; }
.c-key { color: #79c0ff; }

.code-inline {
  background: #0d1117;
  border: 1px solid #21262d;
  border-radius: 8px;
  padding: 12px 16px;
  font-size: .85rem;
  color: #a5d6ff;
  overflow-x: auto;
}

/* ==================== PLUGINS ==================== */
.plugins-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 24px;
  margin-bottom: 40px;
}

.plugin-feature {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
  transition: transform .2s, box-shadow .2s;
}
.plugin-feature:hover { transform: translateY(-3px); box-shadow: var(--shadow); }

.pf-icon { font-size: 2rem; margin-bottom: 14px; }
.plugin-feature h4 { font-size: .95rem; font-weight: 700; margin-bottom: 8px; color: var(--secondary); }
.plugin-feature p { font-size: .87rem; color: var(--text-muted); line-height: 1.6; }
.plugin-feature code { background: #f1f5f9; padding: 2px 6px; border-radius: 4px; font-size: .8rem; color: var(--primary-dark); }

.plugin-code-example { margin-top: 8px; }

/* ==================== STACK ==================== */
.stack-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 20px;
}

.stack-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  background: var(--bg-card-dark);
  border: 1px solid var(--border-dark);
  border-radius: var(--radius);
  padding: 28px 16px;
  text-align: center;
  transition: border-color .2s, transform .2s;
}
.stack-item:hover { border-color: var(--primary); transform: translateY(-3px); }

.stack-icon { font-size: 2.4rem; }
.stack-name { font-size: .95rem; font-weight: 700; color: #f1f5f9; }
.stack-desc { font-size: .78rem; color: #64748b; }

/* ==================== INSTALL ==================== */
.install-steps {
  display: flex;
  flex-direction: column;
  gap: 20px;
  max-width: 700px;
  margin: 0 auto;
}

.install-step {
  display: flex;
  gap: 20px;
  align-items: flex-start;
}

.step-num {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--primary);
  color: #fff;
  font-weight: 800;
  font-size: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.step-body h4 { font-size: .95rem; font-weight: 700; margin-bottom: 8px; color: var(--secondary); }

/* ==================== CTA ==================== */
.cta-section {
  background: linear-gradient(135deg, var(--secondary), #0a1628);
  padding: 80px 0;
  text-align: center;
  position: relative;
  overflow: hidden;
  color: #fff;
}

.cta-gradient {
  position: absolute;
  top: -100px; left: 50%;
  transform: translateX(-50%);
  width: 600px; height: 600px;
  background: radial-gradient(circle, rgba(232,93,4,.2), transparent 70%);
  pointer-events: none;
}

.cta-inner { position: relative; z-index: 1; }

.cta-section h2 { font-size: 2.2rem; font-weight: 800; margin-bottom: 16px; }
.cta-section p { color: #94a3b8; font-size: 1.05rem; margin-bottom: 36px; }
.cta-actions { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; }
.cta-license { margin-top: 24px; font-size: .82rem; color: #64748b; }

/* ==================== FOOTER ==================== */
.footer {
  background: #060c16;
  padding: 60px 0 0;
}

.footer-inner {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 40px;
  padding-bottom: 48px;
  border-bottom: 1px solid #1e2d40;
}

.footer-logo { height: 32px; width: auto; margin-bottom: 12px; filter: brightness(0) invert(1); }
.footer-brand p { font-size: .87rem; color: #64748b; margin-bottom: 16px; line-height: 1.6; }
.footer-tags { display: flex; gap: 8px; flex-wrap: wrap; }

.footer-links { display: flex; flex-direction: column; gap: 10px; }
.footer-links h5 { font-size: .82rem; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: #94a3b8; margin-bottom: 4px; }
.footer-links a { font-size: .87rem; color: #64748b; transition: color .2s; }
.footer-links a:hover { color: var(--primary); }

.footer-bottom {
  padding: 20px 24px;
  text-align: center;
}
.footer-bottom p { font-size: .82rem; color: #374151; }
.footer-bottom a { color: var(--primary); }

/* ==================== RESPONSIVE ==================== */
@media (max-width: 900px) {
  .nav-links { display: none; }
  .nav-links.open {
    display: flex;
    flex-direction: column;
    position: fixed;
    top: 64px; left: 0; right: 0;
    background: #fff;
    border-bottom: 1px solid var(--border);
    padding: 16px 24px;
    gap: 4px;
    z-index: 99;
  }
  .hamburger { display: flex; }
  .beta-banner { grid-template-columns: 1fr; }
  .beta-visual { grid-template-columns: 1fr 1fr; }
  .api-grid { grid-template-columns: 1fr; }
  .footer-inner { grid-template-columns: 1fr 1fr; }
  .stat { padding: 8px 28px; }
}

@media (max-width: 600px) {
  .hero { padding: 80px 0 60px; }
  .section { padding: 56px 0; }
  .beta-banner { padding: 32px 24px; }
  .stat-divider { display: none; }
  .stats-inner { gap: 16px; }
  .footer-inner { grid-template-columns: 1fr; }
  .hero-actions { flex-direction: column; align-items: center; }
}
