/* ═══════════════════════════════════════════════════════════════
   VulnScan5G — Landing Page Stylesheet
   Professional dark theme, cybersecurity-forward design
   ═══════════════════════════════════════════════════════════════ */

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

:root {
  /* Core palette */
  --bg-primary: #06080f;
  --bg-secondary: #0c1021;
  --bg-card: #111629;
  --bg-card-hover: #161d38;
  --border: #1e2744;
  --border-light: #2a3556;

  /* Text */
  --text-primary: #e8ecf4;
  --text-secondary: #8892ab;
  --text-muted: #5c6580;

  /* Accent — cyan/blue */
  --accent: #38bdf8;
  --accent-dim: rgba(56, 189, 248, 0.12);
  --accent-glow: rgba(56, 189, 248, 0.25);
  --accent-solid: #2196e0;

  /* Severity colors */
  --critical: #ef4444;
  --high: #f97316;
  --medium: #eab308;
  --low: #38bdf8;

  /* Spacing */
  --section-gap: 120px;
  --container-max: 1120px;

  /* Typography */
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-mono: 'JetBrains Mono', 'Fira Code', 'Consolas', monospace;
}

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

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

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

a:hover {
  color: #7dd3fc;
}

img {
  max-width: 100%;
  height: auto;
}

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

/* ── Navigation ────────────────────────────────────────────── */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: 0 24px;
  transition: background 0.3s, box-shadow 0.3s, backdrop-filter 0.3s;
}

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

.navbar-inner {
  max-width: var(--container-max);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}

.navbar-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 1.15rem;
  color: var(--text-primary);
  letter-spacing: -0.01em;
}

.navbar-brand img {
  width: 32px;
  height: 32px;
  border-radius: 8px;
}

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

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

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

.nav-download-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 20px;
  background: var(--accent);
  color: #06080f !important;
  font-weight: 600;
  font-size: 0.85rem;
  border-radius: 8px;
  transition: background 0.2s, transform 0.15s;
}

.nav-download-btn:hover {
  background: #7dd3fc;
  color: #06080f !important;
  transform: translateY(-1px);
}

/* Mobile nav toggle */
.nav-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--text-secondary);
  cursor: pointer;
  padding: 8px;
}

.nav-toggle svg {
  width: 24px;
  height: 24px;
}

/* ── Hero Section ──────────────────────────────────────────── */
.hero {
  position: relative;
  padding: 160px 24px 100px;
  overflow: hidden;
  text-align: center;
}

/* Grid pattern background */
.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(56, 189, 248, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(56, 189, 248, 0.03) 1px, transparent 1px);
  background-size: 60px 60px;
  mask-image: radial-gradient(ellipse at center, black 20%, transparent 70%);
  -webkit-mask-image: radial-gradient(ellipse at center, black 20%, transparent 70%);
}

/* Radial glow */
.hero::after {
  content: '';
  position: absolute;
  top: -50%;
  left: 50%;
  width: 800px;
  height: 800px;
  transform: translateX(-50%);
  background: radial-gradient(circle, var(--accent-dim) 0%, transparent 60%);
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 1;
  max-width: 720px;
  margin: 0 auto;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 16px;
  background: var(--accent-dim);
  border: 1px solid rgba(56, 189, 248, 0.15);
  border-radius: 100px;
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--accent);
  margin-bottom: 28px;
}

.hero-badge .dot {
  width: 6px;
  height: 6px;
  background: var(--accent);
  border-radius: 50%;
  animation: pulse-dot 2s ease-in-out infinite;
}

@keyframes pulse-dot {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}

.hero h1 {
  font-size: clamp(2.2rem, 5vw, 3.5rem);
  font-weight: 800;
  line-height: 1.12;
  letter-spacing: -0.03em;
  margin-bottom: 20px;
  color: var(--text-primary);
}

.hero h1 .gradient-text {
  background: linear-gradient(135deg, var(--accent) 0%, #818cf8 50%, #c084fc 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-description {
  font-size: 1.1rem;
  line-height: 1.7;
  color: var(--text-secondary);
  max-width: 560px;
  margin: 0 auto 36px;
}

.hero-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  margin-bottom: 16px;
}

.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 28px;
  background: var(--accent);
  color: #06080f;
  font-weight: 700;
  font-size: 0.95rem;
  border-radius: 10px;
  border: none;
  cursor: pointer;
  transition: background 0.2s, transform 0.15s, box-shadow 0.2s;
  box-shadow: 0 0 0 0 var(--accent-glow);
}

.btn-primary:hover {
  background: #7dd3fc;
  color: #06080f;
  transform: translateY(-2px);
  box-shadow: 0 8px 30px var(--accent-glow);
}

.btn-primary svg {
  width: 18px;
  height: 18px;
}

.btn-secondary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 28px;
  background: transparent;
  color: var(--text-secondary);
  font-weight: 600;
  font-size: 0.95rem;
  border-radius: 10px;
  border: 1px solid var(--border-light);
  cursor: pointer;
  transition: all 0.2s;
}

.btn-secondary:hover {
  background: var(--bg-card);
  border-color: var(--accent);
  color: var(--text-primary);
}

.btn-secondary svg {
  width: 18px;
  height: 18px;
}

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

.hero-meta span {
  margin: 0 6px;
}

/* Hero screenshot */
.hero-screenshot {
  position: relative;
  z-index: 1;
  max-width: 960px;
  margin: 60px auto 0;
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid var(--border);
  box-shadow:
    0 4px 6px rgba(0, 0, 0, 0.3),
    0 24px 80px rgba(0, 0, 0, 0.5),
    0 0 120px var(--accent-dim);
}

.hero-screenshot img {
  display: block;
  width: 100%;
}

/* ── Section common ────────────────────────────────────────── */
section {
  padding: var(--section-gap) 24px;
}

.section-label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.78rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--accent);
  margin-bottom: 16px;
}

.section-label svg {
  width: 16px;
  height: 16px;
}

.section-title {
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.02em;
  margin-bottom: 14px;
}

.section-subtitle {
  font-size: 1rem;
  color: var(--text-secondary);
  max-width: 540px;
  line-height: 1.6;
}

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

.section-header-center .section-subtitle {
  margin: 0 auto;
}

/* ── Features Grid ─────────────────────────────────────────── */
.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: 14px;
  padding: 32px 28px;
  transition: border-color 0.25s, transform 0.2s, box-shadow 0.25s;
}

.feature-card:hover {
  border-color: var(--border-light);
  transform: translateY(-3px);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.3);
}

.feature-icon {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 18px;
  font-size: 1.2rem;
}

.feature-icon.blue    { background: rgba(56, 189, 248, 0.12); color: #38bdf8; }
.feature-icon.purple  { background: rgba(129, 140, 248, 0.12); color: #818cf8; }
.feature-icon.orange  { background: rgba(249, 115, 22, 0.12); color: #f97316; }
.feature-icon.green   { background: rgba(52, 211, 153, 0.12); color: #34d399; }
.feature-icon.red     { background: rgba(239, 68, 68, 0.12); color: #ef4444; }
.feature-icon.yellow  { background: rgba(234, 179, 8, 0.12); color: #eab308; }

.feature-icon svg {
  width: 22px;
  height: 22px;
}

.feature-card h3 {
  font-size: 1.02rem;
  font-weight: 650;
  margin-bottom: 8px;
  letter-spacing: -0.01em;
}

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

/* ── Detection Coverage ────────────────────────────────────── */
.coverage-section {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.coverage-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}

.coverage-item {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 20px 22px;
  transition: border-color 0.2s;
}

.coverage-item:hover {
  border-color: var(--border-light);
}

.coverage-cwe {
  flex-shrink: 0;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 6px;
  white-space: nowrap;
}

.coverage-cwe.critical { background: rgba(239, 68, 68, 0.12); color: var(--critical); }
.coverage-cwe.high     { background: rgba(249, 115, 22, 0.12); color: var(--high); }
.coverage-cwe.medium   { background: rgba(234, 179, 8, 0.12); color: var(--medium); }

.coverage-info h4 {
  font-size: 0.92rem;
  font-weight: 600;
  margin-bottom: 4px;
}

.coverage-info p {
  font-size: 0.8rem;
  color: var(--text-muted);
  line-height: 1.4;
}

/* ── How It Works ──────────────────────────────────────────── */
.pipeline-steps {
  display: flex;
  gap: 0;
  position: relative;
}

.pipeline-step {
  flex: 1;
  text-align: center;
  padding: 0 16px;
  position: relative;
}

.pipeline-step:not(:last-child)::after {
  content: '';
  position: absolute;
  top: 26px;
  right: -2px;
  width: calc(100%);
  height: 1px;
  background: linear-gradient(90deg, var(--border-light), transparent);
  z-index: 0;
}

.step-number {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 16px;
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--accent);
  position: relative;
  z-index: 1;
}

.pipeline-step h4 {
  font-size: 0.9rem;
  font-weight: 650;
  margin-bottom: 6px;
}

.pipeline-step p {
  font-size: 0.8rem;
  color: var(--text-muted);
  line-height: 1.45;
}

/* ── Stats Banner ──────────────────────────────────────────── */
.stats-banner {
  padding: 60px 24px;
  background: var(--bg-secondary);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 40px;
  text-align: center;
}

.stat-item .stat-value {
  font-size: 2.4rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--accent);
  line-height: 1.1;
  margin-bottom: 4px;
}

.stat-item .stat-label {
  font-size: 0.85rem;
  color: var(--text-muted);
  font-weight: 500;
}

/* ── Download Section ──────────────────────────────────────── */
.download-section {
  position: relative;
  overflow: hidden;
}

.download-card {
  position: relative;
  max-width: 720px;
  margin: 0 auto;
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: 20px;
  padding: 56px 48px;
  text-align: center;
  overflow: hidden;
}

.download-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 400px;
  height: 200px;
  background: radial-gradient(ellipse, var(--accent-dim) 0%, transparent 70%);
  pointer-events: none;
}

.download-card .section-title,
.download-card .section-subtitle {
  position: relative;
  z-index: 1;
}

.download-card .section-subtitle {
  margin: 0 auto 32px;
}

.download-actions {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}

.download-info {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 24px;
  font-size: 0.78rem;
  color: var(--text-muted);
}

.download-info-item {
  display: flex;
  align-items: center;
  gap: 6px;
}

.download-info-item svg {
  width: 14px;
  height: 14px;
  color: var(--text-muted);
}

/* Checksum display */
.checksum {
  margin-top: 8px;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--text-muted);
  background: var(--bg-primary);
  padding: 8px 16px;
  border-radius: 8px;
  border: 1px solid var(--border);
  user-select: all;
  word-break: break-all;
  max-width: 480px;
}

/* ── Footer ────────────────────────────────────────────────── */
.footer {
  padding: 48px 24px;
  border-top: 1px solid var(--border);
}

.footer-inner {
  max-width: var(--container-max);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--text-secondary);
  font-size: 0.85rem;
}

.footer-brand img {
  width: 24px;
  height: 24px;
  border-radius: 6px;
  opacity: 0.6;
}

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

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

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

/* ── Scroll Animations ─────────────────────────────────────── */
.animate-on-scroll {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.animate-on-scroll.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Staggered children */
.stagger-children > *:nth-child(1) { transition-delay: 0ms; }
.stagger-children > *:nth-child(2) { transition-delay: 60ms; }
.stagger-children > *:nth-child(3) { transition-delay: 120ms; }
.stagger-children > *:nth-child(4) { transition-delay: 180ms; }
.stagger-children > *:nth-child(5) { transition-delay: 240ms; }
.stagger-children > *:nth-child(6) { transition-delay: 300ms; }

/* ── Responsive ────────────────────────────────────────────── */
@media (max-width: 900px) {
  .features-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .coverage-grid {
    grid-template-columns: 1fr;
  }
  .pipeline-steps {
    flex-direction: column;
    gap: 24px;
  }
  .pipeline-step:not(:last-child)::after {
    display: none;
  }
  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 32px;
  }
}

@media (max-width: 640px) {
  :root {
    --section-gap: 80px;
  }

  .navbar-links {
    display: none;
    position: absolute;
    top: 72px;
    left: 0;
    right: 0;
    flex-direction: column;
    background: rgba(6, 8, 15, 0.97);
    backdrop-filter: blur(20px);
    padding: 16px 24px;
    gap: 16px;
    border-bottom: 1px solid var(--border);
  }

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

  .nav-toggle {
    display: block;
  }

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

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

  .hero-actions {
    flex-direction: column;
    gap: 12px;
  }

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

  .stats-grid {
    grid-template-columns: 1fr 1fr;
    gap: 24px;
  }

  .download-card {
    padding: 40px 24px;
  }

  .download-info {
    flex-direction: column;
    gap: 8px;
  }

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