/* ========================================
   Luna Landing Page — Design System
   ======================================== */

:root {
  /* Colors */
  --primary: #7c3aed;
  --primary-light: #8b5cf6;
  --primary-dark: #6d28d9;
  --accent: #3b82f6;
  --bg: #0a0a0f;
  --bg-card: #12121a;
  --bg-card-hover: #1a1a25;
  --bg-surface: #16161f;
  --text: #e2e8f0;
  --text-muted: #94a3b8;
  --text-dim: #64748b;
  --border: rgba(148, 163, 184, 0.1);
  --border-hover: rgba(124, 58, 237, 0.3);
  --gradient: linear-gradient(135deg, #7c3aed, #3b82f6);
  --gradient-text: linear-gradient(135deg, #8b5cf6, #60a5fa);
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.5);
  --shadow-glow: 0 0 40px rgba(124, 58, 237, 0.15);

  /* Typography */
  --font: "Inter", -apple-system, BlinkMacSystemFont, sans-serif;
  --radius: 12px;
  --radius-lg: 20px;
  --radius-full: 9999px;
  --transition: 0.2s ease;
}

/* ========================================
   Reset & Base
   ======================================== */

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}

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;
}
button {
  cursor: pointer;
  font-family: inherit;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ========================================
   Navigation
   ======================================== */

.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: 16px 0;
  transition:
    background 0.3s,
    backdrop-filter 0.3s,
    box-shadow 0.3s;
}

.nav.scrolled {
  background: rgba(10, 10, 15, 0.85);
  backdrop-filter: blur(20px);
  box-shadow: 0 1px 0 var(--border);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1.4rem;
  font-weight: 800;
  letter-spacing: -0.03em;
}

.logo-icon {
  width: 32px;
  height: 32px;
}

.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 var(--transition);
}

.nav-links a:hover {
  color: var(--text);
}

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  padding: 4px;
}

.nav-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition:
    transform 0.3s,
    opacity 0.3s;
}

/* ========================================
   Buttons
   ======================================== */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-weight: 600;
  font-size: 0.95rem;
  border: none;
  border-radius: var(--radius);
  padding: 10px 24px;
  transition: all var(--transition);
  white-space: nowrap;
}

.btn-sm {
  padding: 8px 18px;
  font-size: 0.85rem;
}
.btn-lg {
  padding: 14px 32px;
  font-size: 1.05rem;
}
.btn-block {
  width: 100%;
}

.btn-primary {
  background: var(--gradient);
  color: white;
  box-shadow: 0 2px 12px rgba(124, 58, 237, 0.3);
}

.btn-primary:hover {
  box-shadow: 0 4px 20px rgba(124, 58, 237, 0.5);
  transform: translateY(-1px);
}

.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.08);
  border-color: var(--border-hover);
}

.btn-outline {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--border);
}

.btn-outline:hover {
  border-color: var(--primary);
  background: rgba(124, 58, 237, 0.08);
}

/* ========================================
   Gradient Text
   ======================================== */

.gradient-text {
  background: var(--gradient-text);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ========================================
   Hero
   ======================================== */

.hero {
  position: relative;
  padding: 160px 0 100px;
  overflow: hidden;
  min-height: 100vh;
  display: flex;
  align-items: center;
}

.hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.hero-gradient {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(
      ellipse 80% 60% at 50% 20%,
      rgba(124, 58, 237, 0.12),
      transparent 70%
    ),
    radial-gradient(
      ellipse 60% 40% at 70% 40%,
      rgba(59, 130, 246, 0.08),
      transparent 60%
    );
}

.hero-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.02) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.02) 1px, transparent 1px);
  background-size: 60px 60px;
  mask-image: radial-gradient(ellipse 70% 50% at 50% 30%, black, transparent);
}

.hero-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  animation: float 8s ease-in-out infinite;
}

.hero-orb-1 {
  width: 400px;
  height: 400px;
  background: rgba(124, 58, 237, 0.12);
  top: -10%;
  right: -5%;
}

.hero-orb-2 {
  width: 300px;
  height: 300px;
  background: rgba(59, 130, 246, 0.1);
  bottom: 10%;
  left: -5%;
  animation-delay: -4s;
}

@keyframes float {
  0%,
  100% {
    transform: translateY(0) scale(1);
  }
  50% {
    transform: translateY(-30px) scale(1.05);
  }
}

.hero-inner {
  position: relative;
  z-index: 1;
  text-align: center;
  max-width: 800px;
  margin: 0 auto;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 16px;
  background: rgba(124, 58, 237, 0.1);
  border: 1px solid rgba(124, 58, 237, 0.25);
  border-radius: var(--radius-full);
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--primary-light);
  margin-bottom: 32px;
}

.badge-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #22c55e;
  animation: pulse-dot 2s infinite;
}

@keyframes pulse-dot {
  0%,
  100% {
    opacity: 1;
  }
  50% {
    opacity: 0.4;
  }
}

.hero h1 {
  font-size: clamp(2.8rem, 6vw, 4.5rem);
  font-weight: 900;
  line-height: 1.1;
  letter-spacing: -0.04em;
  margin-bottom: 24px;
}

.hero-sub {
  font-size: 1.15rem;
  color: var(--text-muted);
  max-width: 600px;
  margin: 0 auto 40px;
  line-height: 1.7;
}

.hero-cta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  margin-bottom: 60px;
}

.hero-stats {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 40px;
}

.stat-value {
  display: block;
  font-size: 1.8rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  background: var(--gradient-text);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.stat-label {
  font-size: 0.85rem;
  color: var(--text-dim);
}

.stat-divider {
  width: 1px;
  height: 40px;
  background: var(--border);
}

/* ========================================
   Trusted Section
   ======================================== */

.trusted {
  padding: 60px 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.trusted-label {
  text-align: center;
  font-size: 0.85rem;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 24px;
}

.trusted-logos {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 48px;
  flex-wrap: wrap;
}

.trusted-logo {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-dim);
  opacity: 0.5;
  transition: opacity var(--transition);
}

.trusted-logo:hover {
  opacity: 0.8;
}

/* ========================================
   Section Shared
   ======================================== */

.section-header {
  text-align: center;
  margin-bottom: 64px;
}

.section-tag {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--primary-light);
  margin-bottom: 16px;
}

.section-header h2 {
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.2;
  margin-bottom: 16px;
}

.section-header p {
  font-size: 1.05rem;
  color: var(--text-muted);
  max-width: 550px;
  margin: 0 auto;
}

/* ========================================
   Features
   ======================================== */

.features {
  padding: 120px 0;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.feature-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 32px;
  transition: all 0.3s ease;
}

.feature-card:hover {
  border-color: var(--border-hover);
  background: var(--bg-card-hover);
  box-shadow: var(--shadow-glow);
  transform: translateY(-4px);
}

.feature-card-lg {
  grid-column: span 3;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: center;
}

.feature-icon {
  width: 48px;
  height: 48px;
  border-radius: var(--radius);
  background: rgba(124, 58, 237, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
  color: var(--primary-light);
}

.feature-icon svg {
  width: 24px;
  height: 24px;
}

.feature-card h3 {
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 8px;
}

.feature-card p {
  color: var(--text-muted);
  font-size: 0.95rem;
  line-height: 1.6;
}

/* Chat Demo in Feature */
.chat-demo {
  background: var(--bg);
  border-radius: var(--radius);
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.chat-msg {
  max-width: 85%;
  padding: 12px 16px;
  border-radius: 16px;
  font-size: 0.9rem;
  line-height: 1.5;
  animation: chatIn 0.6s ease forwards;
  opacity: 0;
}

.chat-msg-user {
  align-self: flex-end;
  background: var(--primary);
  color: white;
  border-bottom-right-radius: 4px;
  animation-delay: 0.5s;
}

.chat-msg-ai {
  align-self: flex-start;
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-bottom-left-radius: 4px;
  animation-delay: 1.2s;
}

@keyframes chatIn {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ========================================
   How it Works
   ======================================== */

.how-it-works {
  padding: 120px 0;
  background: var(--bg-card);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.steps {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  gap: 20px;
}

.step {
  text-align: center;
  max-width: 280px;
}

.step-number {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--gradient);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  font-weight: 800;
  color: white;
  margin: 0 auto 20px;
  box-shadow: 0 4px 16px rgba(124, 58, 237, 0.3);
}

.step h3 {
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 8px;
}

.step p {
  color: var(--text-muted);
  font-size: 0.9rem;
}

.step-connector {
  width: 60px;
  height: 2px;
  background: var(--border);
  margin-top: 28px;
  flex-shrink: 0;
}

/* ========================================
   Pricing
   ======================================== */

.pricing {
  padding: 120px 0;
}

.pricing-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  align-items: start;
}

.pricing-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 40px 32px;
  position: relative;
  transition: all 0.3s ease;
}

.pricing-card:hover {
  border-color: var(--border-hover);
  transform: translateY(-4px);
  box-shadow: var(--shadow-glow);
}

.pricing-card-popular {
  border-color: var(--primary);
  background: linear-gradient(
    180deg,
    rgba(124, 58, 237, 0.08) 0%,
    var(--bg-card) 60%
  );
  box-shadow: 0 0 40px rgba(124, 58, 237, 0.12);
}

.popular-badge {
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--gradient);
  color: white;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 4px 16px;
  border-radius: var(--radius-full);
}

.pricing-header h3 {
  font-size: 1.3rem;
  font-weight: 700;
  margin-bottom: 4px;
}

.pricing-desc {
  font-size: 0.9rem;
  color: var(--text-dim);
}

.pricing-price {
  display: flex;
  align-items: baseline;
  gap: 2px;
  margin: 24px 0;
}

.price-currency {
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--text-muted);
}

.price-amount {
  font-size: 3.5rem;
  font-weight: 900;
  letter-spacing: -0.04em;
  line-height: 1;
}

.price-period {
  font-size: 0.9rem;
  color: var(--text-dim);
}

.pricing-features {
  list-style: none;
  margin: 24px 0 32px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.pricing-features li {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.9rem;
  color: var(--text-muted);
}

.pricing-features svg {
  width: 18px;
  height: 18px;
  color: #22c55e;
  flex-shrink: 0;
}

/* ========================================
   FAQ
   ======================================== */

.faq {
  padding: 120px 0;
  background: var(--bg-card);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.faq-list {
  max-width: 700px;
  margin: 0 auto;
}

.faq-item {
  border-bottom: 1px solid var(--border);
}

.faq-question {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 0;
  background: none;
  border: none;
  color: var(--text);
  font-size: 1rem;
  font-weight: 600;
  text-align: left;
  transition: color var(--transition);
}

.faq-question:hover {
  color: var(--primary-light);
}

.faq-icon {
  width: 20px;
  height: 20px;
  color: var(--text-dim);
  transition: transform 0.3s ease;
  flex-shrink: 0;
}

.faq-item.open .faq-icon {
  transform: rotate(180deg);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition:
    max-height 0.4s ease,
    padding 0.3s ease;
}

.faq-item.open .faq-answer {
  max-height: 200px;
  padding-bottom: 20px;
}

.faq-answer p {
  color: var(--text-muted);
  font-size: 0.95rem;
  line-height: 1.7;
}

/* ========================================
   Register
   ======================================== */

.register {
  padding: 120px 0;
}

.register-wrapper {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
}

.register-info h2 {
  font-size: clamp(2rem, 4vw, 2.8rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.2;
  margin-bottom: 16px;
}

.register-info p {
  color: var(--text-muted);
  font-size: 1.05rem;
  margin-bottom: 32px;
}

.register-benefits {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.register-benefits li {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.95rem;
  color: var(--text-muted);
}

.register-benefits svg {
  width: 20px;
  height: 20px;
  color: #22c55e;
  flex-shrink: 0;
}

.register-form-wrapper {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 40px;
  box-shadow: var(--shadow-lg);
}

.register-form h3 {
  font-size: 1.3rem;
  font-weight: 700;
  margin-bottom: 28px;
  text-align: center;
}

.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 6px;
  color: var(--text-muted);
}

.optional {
  font-weight: 400;
  color: var(--text-dim);
}

.form-group input {
  width: 100%;
  padding: 12px 16px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text);
  font-size: 0.95rem;
  font-family: inherit;
  transition:
    border-color var(--transition),
    box-shadow var(--transition);
}

.form-group input:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(124, 58, 237, 0.15);
}

.form-group input::placeholder {
  color: var(--text-dim);
}

.form-group input.error {
  border-color: #ef4444;
  box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.15);
}

.form-message {
  margin-top: 16px;
  padding: 12px 16px;
  border-radius: var(--radius);
  font-size: 0.9rem;
  text-align: center;
}

.form-message.success {
  background: rgba(34, 197, 94, 0.1);
  border: 1px solid rgba(34, 197, 94, 0.3);
  color: #22c55e;
}

.form-message.error-msg {
  background: rgba(239, 68, 68, 0.1);
  border: 1px solid rgba(239, 68, 68, 0.3);
  color: #ef4444;
}

.form-terms {
  font-size: 0.8rem;
  color: var(--text-dim);
  text-align: center;
  margin-top: 16px;
}

.form-terms a {
  color: var(--primary-light);
  text-decoration: underline;
}

.spinner {
  width: 20px;
  height: 20px;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* ========================================
   Footer
   ======================================== */

.footer {
  padding: 80px 0 32px;
  border-top: 1px solid var(--border);
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  gap: 64px;
  margin-bottom: 48px;
}

.footer-brand {
  max-width: 300px;
}

.footer-brand .nav-logo {
  margin-bottom: 12px;
}

.footer-brand p {
  color: var(--text-dim);
  font-size: 0.9rem;
}

.footer-links {
  display: flex;
  gap: 64px;
}

.footer-col {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-col h4 {
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text);
  margin-bottom: 4px;
}

.footer-col a {
  font-size: 0.9rem;
  color: var(--text-dim);
  transition: color var(--transition);
}

.footer-col a:hover {
  color: var(--text);
}

.footer-bottom {
  padding-top: 24px;
  border-top: 1px solid var(--border);
}

.footer-bottom p {
  font-size: 0.8rem;
  color: var(--text-dim);
  text-align: center;
}

/* ========================================
   Animations
   ======================================== */

[data-animate] {
  opacity: 0;
  transform: translateY(24px);
  transition:
    opacity 0.6s ease,
    transform 0.6s ease;
}

[data-animate].visible {
  opacity: 1;
  transform: translateY(0);
}

/* ========================================
   Responsive
   ======================================== */

@media (max-width: 768px) {
  .nav-links {
    display: none;
  }
  .nav-toggle {
    display: flex;
  }

  .nav-links.open {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: rgba(10, 10, 15, 0.95);
    backdrop-filter: blur(20px);
    padding: 24px;
    gap: 16px;
    border-bottom: 1px solid var(--border);
  }

  .hero {
    padding: 120px 0 80px;
    min-height: auto;
  }
  .hero h1 {
    font-size: 2.4rem;
  }

  .hero-cta {
    flex-direction: column;
  }
  .hero-stats {
    flex-direction: column;
    gap: 16px;
  }
  .stat-divider {
    width: 40px;
    height: 1px;
  }

  .features-grid {
    grid-template-columns: 1fr;
  }
  .feature-card-lg {
    grid-column: span 1;
    grid-template-columns: 1fr;
  }

  .steps {
    flex-direction: column;
    align-items: center;
  }
  .step-connector {
    width: 2px;
    height: 30px;
    margin: 0;
  }

  .pricing-grid {
    grid-template-columns: 1fr;
    max-width: 400px;
    margin: 0 auto;
  }

  .register-wrapper {
    grid-template-columns: 1fr;
    gap: 40px;
  }
  .register-form-wrapper {
    padding: 28px;
  }

  .footer-inner {
    flex-direction: column;
    gap: 40px;
  }
  .footer-links {
    gap: 40px;
  }

  .trusted-logos {
    gap: 24px;
  }
}

@media (max-width: 480px) {
  .hero h1 {
    font-size: 2rem;
  }
  .container {
    padding: 0 16px;
  }
}
