/* ============================================
   HyperSnatch Landing Page — Design System
   ============================================ */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800;900&family=JetBrains+Mono:wght@400;500;600&display=swap');

/* --- Tokens --- */
:root {
  --bg-primary: #0a0e17;
  --bg-secondary: #111827;
  --bg-card: rgba(17, 24, 39, 0.65);
  --bg-card-hover: rgba(20, 30, 50, 0.85);
  --border-subtle: rgba(56, 189, 248, 0.12);
  --border-glow: rgba(56, 189, 248, 0.35);

  --text-primary: #f0f4f8;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;

  --accent: #38bdf8;
  --accent-bright: #67e8f9;
  --accent-dim: #0ea5e9;
  --accent-gradient: linear-gradient(135deg, #0ea5e9, #38bdf8, #67e8f9);
  --cta-gradient: linear-gradient(135deg, #0ea5e9 0%, #22d3ee 100%);
  --cta-hover: linear-gradient(135deg, #0284c7 0%, #06b6d4 100%);

  --danger: #f43f5e;
  --success: #34d399;

  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-xl: 28px;

  --shadow-card: 0 4px 30px rgba(0, 0, 0, 0.35);
  --shadow-glow: 0 0 40px rgba(56, 189, 248, 0.08);

  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-mono: 'JetBrains Mono', 'Fira Code', monospace;

  --max-w: 1140px;
  --section-pad: 100px 0;
}

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font-body);
  background: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

a {
  color: var(--accent);
  text-decoration: none;
  transition: color 0.2s;
}

a:hover {
  color: var(--accent-bright);
}

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

/* --- Layout --- */
.container {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 24px;
}

section {
  padding: var(--section-pad);
  position: relative;
}

/* --- Background Grain / Glow --- */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background:
    radial-gradient(ellipse 80% 50% at 50% -20%, rgba(56, 189, 248, 0.06), transparent),
    radial-gradient(ellipse 60% 40% at 80% 100%, rgba(14, 165, 233, 0.04), transparent);
  pointer-events: none;
  z-index: 0;
}

/* ============================================
   NAV
   ============================================ */
nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: 16px 0;
  background: rgba(10, 14, 23, 0.85);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-subtle);
  transition: background 0.3s;
}

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

.nav-brand {
  font-weight: 800;
  font-size: 1.35rem;
  letter-spacing: -0.03em;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 10px;
}

.nav-brand .brand-icon {
  width: 32px;
  height: 32px;
  background: var(--accent-gradient);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
}

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

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

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

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

.nav-cta:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 20px rgba(56, 189, 248, 0.3);
  color: var(--bg-primary) !important;
}

/* ============================================
   HERO
   ============================================ */
.hero {
  padding: 180px 0 120px;
  text-align: center;
  position: relative;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--accent);
  background: rgba(56, 189, 248, 0.08);
  border: 1px solid var(--border-subtle);
  padding: 6px 16px;
  border-radius: 100px;
  margin-bottom: 28px;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.hero h1 {
  font-size: clamp(2.4rem, 5.5vw, 3.8rem);
  font-weight: 900;
  line-height: 1.12;
  letter-spacing: -0.04em;
  margin-bottom: 24px;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

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

.hero-sub {
  font-size: 1.15rem;
  line-height: 1.75;
  color: var(--text-secondary);
  max-width: 640px;
  margin: 0 auto 40px;
}

.hero-cta-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  flex-wrap: wrap;
}

.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-body);
  font-size: 1rem;
  font-weight: 700;
  color: var(--bg-primary);
  background: var(--cta-gradient);
  padding: 14px 32px;
  border-radius: var(--radius-md);
  border: none;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
  text-decoration: none;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(56, 189, 248, 0.3);
  color: var(--bg-primary);
}

.btn-secondary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-body);
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-primary);
  background: transparent;
  padding: 14px 32px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-subtle);
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s;
  text-decoration: none;
}

.btn-secondary:hover {
  border-color: var(--border-glow);
  background: rgba(56, 189, 248, 0.05);
  color: var(--text-primary);
}

/* ============================================
   FEATURES
   ============================================ */
.features {
  padding: var(--section-pad);
}

.section-label {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  text-align: center;
  margin-bottom: 12px;
}

.section-title {
  font-size: clamp(1.8rem, 3.5vw, 2.5rem);
  font-weight: 800;
  text-align: center;
  letter-spacing: -0.03em;
  margin-bottom: 16px;
}

.section-desc {
  font-size: 1.05rem;
  color: var(--text-secondary);
  text-align: center;
  max-width: 580px;
  margin: 0 auto 56px;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 24px;
}

.feature-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 36px 32px;
  backdrop-filter: blur(12px);
  transition: transform 0.3s, border-color 0.3s, box-shadow 0.3s;
  position: relative;
  overflow: hidden;
}

.feature-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--accent-gradient);
  opacity: 0;
  transition: opacity 0.3s;
}

.feature-card:hover {
  transform: translateY(-4px);
  border-color: var(--border-glow);
  box-shadow: var(--shadow-glow);
}

.feature-card:hover::before {
  opacity: 1;
}

.feature-icon {
  width: 48px;
  height: 48px;
  background: rgba(56, 189, 248, 0.08);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  margin-bottom: 20px;
}

.feature-card h3 {
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 10px;
  letter-spacing: -0.01em;
}

.feature-card p {
  color: var(--text-secondary);
  font-size: 0.93rem;
  line-height: 1.65;
}

/* ============================================
   DETERMINISM DEMO
   ============================================ */
.demo {
  padding: var(--section-pad);
  background: linear-gradient(180deg, transparent 0%, rgba(14, 165, 233, 0.03) 50%, transparent 100%);
}

.demo-box {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 48px;
  backdrop-filter: blur(12px);
  max-width: 860px;
  margin: 0 auto;
}

.demo-box h3 {
  font-size: 1.3rem;
  margin-bottom: 24px;
}

.demo-steps {
  display: flex;
  flex-direction: column;
  gap: 20px;
  margin-bottom: 32px;
}

.demo-step {
  display: flex;
  gap: 16px;
  align-items: flex-start;
}

.step-num {
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  background: rgba(56, 189, 248, 0.1);
  border: 1px solid var(--border-subtle);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--accent);
}

.demo-step p {
  color: var(--text-secondary);
  font-size: 0.95rem;
}

.code-block {
  background: rgba(0, 0, 0, 0.4);
  border: 1px solid rgba(56, 189, 248, 0.08);
  border-radius: var(--radius-sm);
  padding: 20px 24px;
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--accent-bright);
  overflow-x: auto;
  line-height: 1.6;
}

.code-block .comment {
  color: var(--text-muted);
}

.code-block .hash {
  color: var(--success);
  word-break: break-all;
}

/* ============================================
   PRICING
   ============================================ */
.pricing {
  padding: var(--section-pad);
}

.pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 32px;
  max-width: 1100px;
  margin: 0 auto;
}

.pricing-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: 48px 40px;
  text-align: left;
  position: relative;
  overflow: hidden;
  backdrop-filter: blur(16px);
  transition: transform 0.3s, border-color 0.3s, box-shadow 0.3s;
}

.pricing-card:hover {
  transform: translateY(-4px);
  border-color: var(--border-glow);
  box-shadow: var(--shadow-glow);
}

.pricing-card.featured {
  border-color: var(--border-glow);
  box-shadow: var(--shadow-glow);
  transform: scale(1.02);
  z-index: 2;
}

.pricing-card.featured:hover {
  transform: scale(1.02) translateY(-4px);
}

.pricing-card.featured::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--accent-gradient);
}

.pricing-badge {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--bg-primary);
  background: var(--cta-gradient);
  padding: 4px 14px;
  border-radius: 100px;
  margin-bottom: 20px;
}

.pricing-card .price {
  font-size: 3.5rem;
  font-weight: 900;
  letter-spacing: -0.04em;
  margin-bottom: 4px;
}

.pricing-card .price-note {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-bottom: 28px;
}

.pricing-list {
  list-style: none;
  text-align: left;
  margin-bottom: 32px;
}

.pricing-list li {
  padding: 10px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
  color: var(--text-secondary);
  font-size: 0.93rem;
  display: flex;
  align-items: center;
  gap: 10px;
}

.pricing-list li::before {
  content: '✓';
  color: var(--success);
  font-weight: 700;
  flex-shrink: 0;
}

.pricing-card .btn-primary,
.pricing-card .btn-secondary {
  width: 100%;
  justify-content: center;
  font-size: 1.05rem;
  padding: 16px 0;
  margin-top: 10px;
}

.guarantee {
  margin-top: 16px;
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* ============================================
   FAQ
   ============================================ */
.faq {
  padding: var(--section-pad);
}

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

.faq-item {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  overflow: hidden;
  transition: border-color 0.2s;
}

.faq-item:hover {
  border-color: var(--border-glow);
}

.faq-q {
  width: 100%;
  background: none;
  border: none;
  color: var(--text-primary);
  font-family: var(--font-body);
  font-size: 1rem;
  font-weight: 600;
  text-align: left;
  padding: 20px 24px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.faq-q::after {
  content: '+';
  font-size: 1.3rem;
  color: var(--accent);
  transition: transform 0.3s;
  flex-shrink: 0;
}

.faq-item.open .faq-q::after {
  transform: rotate(45deg);
}

.faq-a {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.35s ease, padding 0.35s ease;
}

.faq-item.open .faq-a {
  max-height: 300px;
  padding: 0 24px 20px;
}

.faq-a p {
  color: var(--text-secondary);
  font-size: 0.93rem;
  line-height: 1.7;
}

/* ============================================
   FOOTER
   ============================================ */
footer {
  padding: 48px 0;
  border-top: 1px solid var(--border-subtle);
  text-align: center;
}

.footer-links {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 24px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}

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

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

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

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 768px) {
  :root {
    --section-pad: 72px 0;
  }

  nav .nav-links {
    display: none;
  }

  .hero {
    padding: 140px 0 80px;
  }

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

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

  .pricing-grid {
    grid-template-columns: 1fr;
  }

  .pricing-card.featured {
    transform: scale(1);
  }

  .pricing-card.featured:hover {
    transform: translateY(-4px);
  }

  .pricing-card {
    padding: 36px 24px;
  }

  .hero-cta-row {
    flex-direction: column;
  }

  .hero-cta-row .btn-primary,
  .hero-cta-row .btn-secondary {
    width: 100%;
    justify-content: center;
  }
}

/* --- Animations --- */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(24px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.animate-in {
  opacity: 0;
  animation: fadeInUp 0.6s ease forwards;
}

.animate-in.d1 {
  animation-delay: 0.1s;
}

.animate-in.d2 {
  animation-delay: 0.2s;
}

.animate-in.d3 {
  animation-delay: 0.3s;
}

.animate-in.d4 {
  animation-delay: 0.4s;
}

.animate-in.d5 {
  animation-delay: 0.5s;
}