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

:root {
  --bg: #09090b;
  --bg-subtle: #0f0f13;
  --surface: #18181b;
  --surface-hover: #1e1e23;
  --border: #27272a;
  --border-subtle: #1e1e22;
  --text: #fafafa;
  --text-muted: #a1a1aa;
  --text-dim: #71717a;
  --primary: #818cf8;
  --primary-bright: #a5b4fc;
  --primary-dim: #6366f1;
  --accent: #c084fc;
  --gradient: linear-gradient(135deg, #818cf8, #c084fc, #f472b6);
  --gradient-subtle: linear-gradient(135deg, rgba(129,140,248,0.15), rgba(192,132,252,0.08));
  --radius: 12px;
  --radius-lg: 20px;
  --radius-sm: 8px;
  --font: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --shadow-lg: 0 24px 64px rgba(0,0,0,0.4);
  --shadow-glow: 0 0 80px rgba(129,140,248,0.12);
}

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

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

img {
  max-width: 100%;
  display: block;
}

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

/* ===== NAVBAR ===== */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  padding: 16px 0;
  transition: background 0.3s, backdrop-filter 0.3s, box-shadow 0.3s;
}

.navbar.scrolled {
  background: rgba(9, 9, 11, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  box-shadow: 0 1px 0 var(--border-subtle);
}

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

.nav-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 1.15rem;
}

.logo-icon {
  font-size: 1.5rem;
}

.logo-icon-img {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  object-fit: contain;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 32px;
}

.nav-links a {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-muted);
  transition: color 0.2s;
}

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

.nav-cta {
  background: var(--primary-dim);
  color: white !important;
  padding: 8px 20px;
  border-radius: 999px;
  font-weight: 600 !important;
  font-size: 0.85rem !important;
  transition: background 0.2s, transform 0.2s !important;
}

.nav-cta:hover {
  background: var(--primary);
  transform: translateY(-1px);
}

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}

.nav-toggle span {
  width: 22px;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: transform 0.3s, opacity 0.3s;
}

/* ===== HERO ===== */
.hero {
  position: relative;
  padding: 160px 0 100px;
  overflow: hidden;
}

.hero-glow {
  position: absolute;
  top: -200px;
  left: 50%;
  transform: translateX(-50%);
  width: 900px;
  height: 600px;
  background: radial-gradient(ellipse, rgba(129,140,248,0.12) 0%, rgba(192,132,252,0.06) 40%, transparent 70%);
  pointer-events: none;
}

.hero-container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}

.hero-badge {
  display: inline-block;
  padding: 6px 16px;
  border-radius: 999px;
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--primary-bright);
  background: rgba(129,140,248,0.1);
  border: 1px solid rgba(129,140,248,0.2);
  margin-bottom: 24px;
}

.hero h1 {
  font-size: 3.5rem;
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.03em;
  margin-bottom: 20px;
}

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

.hero-subtitle {
  font-size: 1.15rem;
  color: var(--text-muted);
  max-width: 520px;
  margin-bottom: 32px;
  line-height: 1.7;
}

.hero-actions {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 40px;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font);
  font-weight: 600;
  border-radius: 999px;
  cursor: pointer;
  border: none;
  transition: all 0.2s;
  white-space: nowrap;
}

.btn-primary {
  background: var(--primary-dim);
  color: white;
  box-shadow: 0 4px 20px rgba(99,102,241,0.3);
}

.btn-primary:hover {
  background: var(--primary);
  box-shadow: 0 4px 30px rgba(99,102,241,0.5);
  transform: translateY(-2px);
}

.btn-ghost {
  background: transparent;
  color: var(--text-muted);
  border: 1px solid var(--border);
}

.btn-ghost:hover {
  color: var(--text);
  border-color: var(--text-dim);
  background: var(--surface);
}

.btn-lg {
  padding: 14px 28px;
  font-size: 1rem;
}

/* Social proof */
.hero-social-proof {
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 0.9rem;
  color: var(--text-dim);
}

.avatar-stack {
  display: flex;
}

.avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 700;
  color: white;
  border: 2px solid var(--bg);
  margin-left: -8px;
}

.avatar:first-child {
  margin-left: 0;
}

/* Browser mockup */
.hero-visual {
  position: relative;
}

.browser-mockup {
  background: var(--surface);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  overflow: hidden;
  box-shadow: var(--shadow-lg), var(--shadow-glow);
}

.browser-header {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 14px 20px;
  background: var(--bg-subtle);
  border-bottom: 1px solid var(--border);
}

.browser-dots {
  display: flex;
  gap: 6px;
}

.browser-dots span {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--border);
}

.browser-dots span:first-child { background: #f87171; }
.browser-dots span:nth-child(2) { background: #fbbf24; }
.browser-dots span:nth-child(3) { background: #34d399; }

.browser-url {
  flex: 1;
  background: var(--bg);
  padding: 6px 14px;
  border-radius: 8px;
  font-size: 0.8rem;
  color: var(--text-dim);
  border: 1px solid var(--border-subtle);
}

.browser-body {
  display: grid;
  grid-template-columns: 1fr 260px;
  min-height: 320px;
}

.mock-content {
  padding: 28px 24px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.mock-line {
  height: 10px;
  background: var(--border);
  border-radius: 6px;
  opacity: 0.5;
}

.w100 { width: 100%; }
.w90 { width: 90%; }
.w85 { width: 85%; }
.w80 { width: 80%; }
.w70 { width: 70%; }
.w60 { width: 60%; }

.mock-widget {
  background: var(--bg);
  border-left: 1px solid var(--border);
  display: flex;
  flex-direction: column;
}

.mock-widget-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 14px;
  border-bottom: 1px solid var(--border);
  font-size: 0.8rem;
  font-weight: 600;
}

.mock-status {
  color: #34d399;
  font-size: 0.7rem;
  font-weight: 500;
}

.mock-chat {
  flex: 1;
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  overflow: hidden;
}

.mock-msg {
  padding: 8px 12px;
  border-radius: 10px;
  font-size: 0.75rem;
  line-height: 1.5;
  max-width: 95%;
}

.mock-user {
  background: var(--primary-dim);
  color: white;
  align-self: flex-end;
  border-bottom-right-radius: 4px;
}

.mock-ai {
  background: var(--surface);
  color: var(--text-muted);
  border-bottom-left-radius: 4px;
}

.typing-cursor::after {
  content: "▎";
  animation: blink 1s steps(2) infinite;
  color: var(--primary);
}

@keyframes blink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0; }
}

.mock-input {
  margin: 10px 14px 14px;
  padding: 10px 14px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: 0.73rem;
  color: var(--text-dim);
}

/* ===== SECTIONS COMMON ===== */
.section-header {
  text-align: center;
  max-width: 640px;
  margin: 0 auto 64px;
}

.section-badge {
  display: inline-block;
  padding: 5px 14px;
  border-radius: 999px;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--primary-bright);
  background: rgba(129,140,248,0.1);
  border: 1px solid rgba(129,140,248,0.15);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 16px;
}

.section-header h2 {
  font-size: 2.5rem;
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.025em;
  margin-bottom: 16px;
}

.section-header p {
  font-size: 1.1rem;
  color: var(--text-muted);
}

/* ===== FEATURES ===== */
.features {
  padding: 120px 0;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

.feature-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px 24px;
  transition: border-color 0.3s, transform 0.3s, box-shadow 0.3s;
}

.feature-card:hover {
  border-color: rgba(129,140,248,0.3);
  transform: translateY(-4px);
  box-shadow: 0 12px 40px rgba(0,0,0,0.3);
}

.feature-icon {
  font-size: 2rem;
  margin-bottom: 16px;
}

.feature-card h3 {
  font-size: 1.05rem;
  font-weight: 700;
  margin-bottom: 8px;
}

.feature-card p {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.6;
}

/* ===== HOW IT WORKS ===== */
.how-it-works {
  padding: 120px 0;
  background: var(--bg-subtle);
  border-top: 1px solid var(--border-subtle);
  border-bottom: 1px solid var(--border-subtle);
}

.steps {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  max-width: 900px;
  margin: 0 auto;
}

.step {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  flex: 1;
  padding: 0 24px;
}

.step-number {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--gradient);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  font-weight: 800;
  color: white;
  margin-bottom: 20px;
  box-shadow: 0 4px 20px rgba(99,102,241,0.3);
}

.step-content h3 {
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 8px;
}

.step-content p {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.6;
}

.step-connector {
  width: 80px;
  height: 2px;
  background: var(--gradient);
  opacity: 0.3;
  flex-shrink: 0;
  margin-bottom: 60px;
}

/* ===== USE CASES ===== */
.use-cases {
  padding: 120px 0;
}

.use-cases-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

.use-case-card {
  position: relative;
  background: var(--gradient-subtle);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px 24px;
  transition: border-color 0.3s, transform 0.3s;
}

.use-case-card:hover {
  border-color: rgba(192,132,252,0.3);
  transform: translateY(-3px);
}

.use-case-emoji {
  font-size: 2.2rem;
  margin-bottom: 16px;
}

.use-case-card h3 {
  font-size: 1.05rem;
  font-weight: 700;
  margin-bottom: 8px;
}

.use-case-card p {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.6;
}

/* ===== FAQ ===== */
.faq {
  padding: 120px 0;
  background: var(--bg-subtle);
  border-top: 1px solid var(--border-subtle);
  border-bottom: 1px solid var(--border-subtle);
}

.faq-list {
  max-width: 700px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.faq-item {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  overflow: hidden;
  transition: border-color 0.3s;
}

.faq-item[open] {
  border-color: rgba(129,140,248,0.3);
}

.faq-item summary {
  padding: 18px 24px;
  font-weight: 600;
  font-size: 1rem;
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  transition: color 0.2s;
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item summary::after {
  content: "+";
  font-size: 1.3rem;
  font-weight: 400;
  color: var(--text-dim);
  transition: transform 0.3s;
}

.faq-item[open] summary::after {
  transform: rotate(45deg);
  color: var(--primary);
}

.faq-item summary:hover {
  color: var(--primary-bright);
}

.faq-item p {
  padding: 0 24px 18px;
  font-size: 0.95rem;
  color: var(--text-muted);
  line-height: 1.7;
}

/* ===== CTA ===== */
.cta-section {
  padding: 120px 0;
}

.cta-card {
  position: relative;
  text-align: center;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 80px 48px;
  overflow: hidden;
}

.cta-glow {
  position: absolute;
  top: -100px;
  left: 50%;
  transform: translateX(-50%);
  width: 600px;
  height: 400px;
  background: radial-gradient(ellipse, rgba(129,140,248,0.1) 0%, rgba(192,132,252,0.05) 40%, transparent 70%);
  pointer-events: none;
}

.cta-card h2 {
  font-size: 2.5rem;
  font-weight: 800;
  letter-spacing: -0.025em;
  margin-bottom: 12px;
  position: relative;
}

.cta-card > p {
  font-size: 1.1rem;
  color: var(--text-muted);
  margin-bottom: 32px;
  position: relative;
}

.cta-card .btn {
  position: relative;
}

.cta-note {
  font-size: 0.8rem;
  color: var(--text-dim);
  margin-top: 16px;
  position: relative;
}

/* ===== FOOTER ===== */
.footer {
  padding: 40px 0;
  border-top: 1px solid var(--border-subtle);
}

.footer-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
}

.footer-copy {
  font-size: 0.85rem;
  color: var(--text-dim);
}

.footer-links {
  display: flex;
  gap: 24px;
}

.footer-links a {
  font-size: 0.85rem;
  color: var(--text-muted);
  transition: color 0.2s;
}

.footer-links a:hover {
  color: var(--text);
}

/* ===== SCROLL ANIMATIONS ===== */
.feature-card,
.step,
.use-case-card,
.faq-item,
.cta-card {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}

.feature-card.visible,
.step.visible,
.use-case-card.visible,
.faq-item.visible,
.cta-card.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Stagger delays for grid items */
.features-grid .feature-card:nth-child(2),
.use-cases-grid .use-case-card:nth-child(2) { transition-delay: 0.08s; }
.features-grid .feature-card:nth-child(3),
.use-cases-grid .use-case-card:nth-child(3) { transition-delay: 0.16s; }
.features-grid .feature-card:nth-child(4),
.use-cases-grid .use-case-card:nth-child(4) { transition-delay: 0.24s; }
.features-grid .feature-card:nth-child(5) { transition-delay: 0.32s; }
.features-grid .feature-card:nth-child(6) { transition-delay: 0.40s; }
.features-grid .feature-card:nth-child(7) { transition-delay: 0.48s; }
.features-grid .feature-card:nth-child(8) { transition-delay: 0.56s; }

/* ===== RESPONSIVE ===== */
@media (max-width: 1024px) {
  .hero-container {
    grid-template-columns: 1fr;
    gap: 48px;
    text-align: center;
  }

  .hero-subtitle {
    margin-left: auto;
    margin-right: auto;
  }

  .hero-actions {
    justify-content: center;
  }

  .hero-social-proof {
    justify-content: center;
  }

  .features-grid,
  .use-cases-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .browser-body {
    grid-template-columns: 1fr 220px;
  }
}

@media (max-width: 768px) {
  .nav-links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    background: rgba(9,9,11,0.97);
    backdrop-filter: blur(20px);
    padding: 24px;
    gap: 16px;
    border-bottom: 1px solid var(--border);
  }

  .nav-links.open {
    display: flex;
  }

  .nav-toggle {
    display: flex;
  }

  .hero {
    padding: 120px 0 60px;
  }

  .hero h1 {
    font-size: 2.4rem;
  }

  .hero-subtitle {
    font-size: 1rem;
  }

  .section-header h2 {
    font-size: 2rem;
  }

  .steps {
    flex-direction: column;
    gap: 0;
  }

  .step-connector {
    width: 2px;
    height: 40px;
    margin-bottom: 0;
  }

  .step {
    padding: 16px 0;
  }

  .features-grid,
  .use-cases-grid {
    grid-template-columns: 1fr;
  }

  .browser-body {
    grid-template-columns: 1fr;
  }

  .mock-content {
    display: none;
  }

  .mock-widget {
    border-left: none;
    border-top: 1px solid var(--border);
  }

  .footer-container {
    flex-direction: column;
    gap: 16px;
    text-align: center;
  }

  .cta-card {
    padding: 48px 24px;
  }

  .cta-card h2 {
    font-size: 1.8rem;
  }
}

@media (max-width: 480px) {
  .hero h1 {
    font-size: 1.9rem;
  }

  .btn-lg {
    padding: 12px 22px;
    font-size: 0.9rem;
  }
}
