/* =====================================================================
   HCODX Landing — Production CSS
   DM Sans · Clean Developer SaaS · Mobile-First · CLS/INP Safe
   Generated: 2026-03-01
   ===================================================================== */

/* ---------------------------------------------------------------------
   0) Reset + Base
   --------------------------------------------------------------------- */

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

/* Text rendering improvements */
html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
  /* Prevent horizontal scroll/drag on mobile — must be on html, not just body */
  overflow-x: hidden;
  overscroll-behavior-x: none;
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation: none !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* ---------------------------------------------------------------------
   1) Design Tokens
   --------------------------------------------------------------------- */

:root {
  /* Core palette */
  --ink: #0b0f1a;
  --ink-2: #1e2538;
  --muted: #5a6480;
  --muted-2: #8b96b0;
  --line: #e4e8f2;
  --bg: #f6f8fd;
  --surface: #ffffff;

  /* Brand accents */
  --accent: #2a5cf6;
  --accent-dk: #1a44d8;
  --accent-lt: #e8eeff;

  --accent-2: #00c896;
  --accent-2lt: #e0faf3;

  --warn: #f59e0b;

  /* Typography */
  --ff: 'DM Sans', system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  --fm: 'DM Mono', ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;

  /* Radii */
  --r: 10px;
  --r-lg: 20px;

  /* Shadows */
  --sh: 0 1px 3px rgba(0, 0, 0, 0.06), 0 4px 16px rgba(0, 0, 0, 0.08);
  --sh-lg: 0 8px 40px rgba(0, 0, 0, 0.12);
  --sh-accent: 0 6px 30px rgba(42, 92, 246, 0.25);

  /* Layout */
  --container: 1200px;
  --gutter: 24px;

  /* Touch targets */
  --tap: 44px;

  /* Safe area for iOS notches */
  --safe-top: env(safe-area-inset-top, 0px);
  --safe-right: env(safe-area-inset-right, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  --safe-left: env(safe-area-inset-left, 0px);
}

/* Selection */
::selection {
  background: rgba(42, 92, 246, 0.18);
}

/* ---------------------------------------------------------------------
   2) Body + Global Elements
   --------------------------------------------------------------------- */

body {
  font-family: var(--ff);
  background: var(--bg);
  color: var(--ink);
  line-height: 1.65;
  overflow-x: hidden;
  /* Lock horizontal pan on mobile — prevents layout being dragged sideways */
  overscroll-behavior-x: none;
  touch-action: pan-y;
  max-width: 100%;
  position: relative;
}

/* Links default */
a {
  color: inherit;
}

/* Improve tap performance on mobile */
button,
.btn {
  touch-action: manipulation;
}

/* Prevent layout shift for media */
img,
video,
canvas {
  max-width: 100%;
  height: auto;
  display: block;
}

/* SVG: constrain size but keep inline-flex compatible (don't force display:block) */
svg {
  max-width: 100%;
  overflow: visible;
  flex-shrink: 0;
}

/* Focus states (keyboard only) */
:focus {
  outline: none;
}

:focus-visible {
  outline: 3px solid rgba(42, 92, 246, 0.35);
  outline-offset: 3px;
  border-radius: 10px;
}

/* Subtle scrollbar (desktop) */
@media (hover: hover) and (pointer: fine) {
  * {
    scrollbar-width: thin;
    scrollbar-color: rgba(30, 37, 56, 0.35) transparent;
  }

  *::-webkit-scrollbar {
    width: 10px;
    height: 10px;
  }

  *::-webkit-scrollbar-thumb {
    background: rgba(30, 37, 56, 0.22);
    border-radius: 999px;
    border: 2px solid transparent;
    background-clip: content-box;
  }

  *::-webkit-scrollbar-thumb:hover {
    background: rgba(30, 37, 56, 0.30);
    border: 2px solid transparent;
    background-clip: content-box;
  }

  *::-webkit-scrollbar-track {
    background: transparent;
  }
}

/* ---------------------------------------------------------------------
   3) Container Utilities
   --------------------------------------------------------------------- */

.container {
  max-width: var(--container);
  margin: 0 auto;
  padding-left: var(--gutter);
  padding-right: var(--gutter);
}

.center {
  text-align: center;
}

/* ---------------------------------------------------------------------
   4) NAV
   --------------------------------------------------------------------- */

.nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  border-bottom: 1px solid var(--line);
  transition: box-shadow 0.2s;
  padding-top: var(--safe-top);
}

/* Scrolled shadow (add class via JS) */
.nav.scrolled {
  box-shadow: 0 2px 20px rgba(0, 0, 0, 0.08);
}

.nav-inner {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 var(--gutter);
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  flex-shrink: 0;
}

.nav-logo-mark {
  width: 32px;
  height: 32px;
  background: var(--accent);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.nav-logo-mark svg {
  width: 18px;
  height: 18px;
  color: #fff;
}

.nav-logo-text {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--ink);
  letter-spacing: -0.02em;
}

/* Main nav links */
.nav-links {
  display: flex;
  align-items: center;
  gap: 4px;
  flex: 1;
}

.nav-links a {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--muted);
  text-decoration: none;
  padding: 6px 14px;
  border-radius: 8px;
  transition: color 0.15s, background 0.15s;
}

.nav-links a:hover {
  color: var(--ink);
  background: var(--bg);
}

/* ---- Tools nav link (special) ---- */
/* Remove purple highlight completely */
.nav-tools-link {
  color: var(--muted) !important;
  font-weight: 500 !important;
  display: flex;
  align-items: center;
  gap: 6px;
  text-decoration: none;
  padding: 6px 14px;
  border-radius: 8px;
  background: transparent !important;
}

.nav-tools-link:hover {
  color: var(--ink) !important;
  background: var(--bg) !important;
}

/* Neutral dot keeps brand blue (not purple) */
.nav-tools-dot {
  width: 6px;
  height: 6px;
  background: var(--accent);
  border-radius: 50%;
  display: inline-block;
  flex-shrink: 0;
  box-shadow: 0 0 0 3px rgba(42, 92, 246, 0.12);
}

/* CTA area */
.nav-ctas {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

/* ---------------------------------------------------------------------
   5) Buttons
   --------------------------------------------------------------------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  font-family: var(--ff);
  font-weight: 600;
  text-decoration: none;
  border-radius: 8px;
  transition: transform 0.15s ease, background 0.15s ease, color 0.15s ease,
    border-color 0.15s ease, box-shadow 0.15s ease;
  cursor: pointer;
  border: none;
  white-space: nowrap;
  min-height: var(--tap);
  padding: 10px 16px;
  line-height: 1;
}

.btn svg {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}

/* Size variants */
.btn-sm {
  font-size: 0.825rem;
  padding: 9px 14px;
  min-height: 38px;
}

.btn-md {
  font-size: 0.9rem;
  padding: 12px 20px;
  min-height: 42px;
}

.btn-lg {
  font-size: 1rem;
  padding: 14px 28px;
  border-radius: 10px;
  min-height: 48px;
}

/* Ghost */
.btn-ghost {
  background: transparent;
  color: var(--muted);
  border: 1px solid var(--line);
}

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

/* IMPORTANT FIX:
   If a "btn btn-sm btn-ghost" is used on dark sections or has white hover,
   keep text visible and avoid "white on white". */
.btn.btn-sm.btn-ghost:hover {
  color: var(--ink) !important;
  background: rgba(255, 255, 255, 0.92) !important;
  border-color: rgba(255, 255, 255, 0.45) !important;
}

/* Primary */
.btn-primary {
  background: var(--accent);
  color: #fff;
  box-shadow: var(--sh-accent);
}

.btn-primary:hover {
  background: var(--accent-dk);
  transform: translateY(-1px);
  box-shadow: 0 8px 36px rgba(42, 92, 246, 0.35);
}

.btn-primary:active {
  transform: translateY(0);
}

/* Outline */
.btn-outline {
  background: transparent;
  color: var(--accent);
  border: 1.5px solid var(--accent);
}

.btn-outline:hover {
  background: var(--accent-lt);
}

/* Compiler button (dark) */
.btn-compiler {
  background: var(--ink);
  color: #fff;
}

.btn-compiler:hover {
  background: #2d3650;
  color: #fff;
  transform: translateY(-1px);
  box-shadow: 0 6px 24px rgba(11, 15, 26, 0.3);
}

.btn-compiler:active {
  transform: translateY(0);
  background: var(--ink-2);
  color: #fff;
}

/* Tools button (original purple -> keep for other areas if used) */
.btn-tools {
  background: #7c3cf5;
  color: #fff;
}

.btn-tools:hover {
  background: #6a2ee0;
  color: #fff;
  transform: translateY(-1px);
  box-shadow: 0 6px 24px rgba(124, 60, 245, 0.3);
}

.btn-tools:active {
  transform: translateY(0);
  background: #5c28c8;
  color: #fff;
}

/* ---------------------------------------------------------------------
   6) nav-ctas — Elegant minimal style (Tools + Compiler)
   --------------------------------------------------------------------- */

.nav-ctas .btn-tools,
.nav-ctas .btn-compiler {
  background: rgba(255, 255, 255, 0.62);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid var(--line);
  box-shadow: none;
  color: var(--ink);
}

/* Hover effect */
.nav-ctas .btn-tools:hover,
.nav-ctas .btn-compiler:hover {
  background: var(--accent-lt);
  border-color: rgba(42, 92, 246, 0.55);
  color: var(--accent);
  transform: translateY(-1px);
}

/* Active */
.nav-ctas .btn-tools:active,
.nav-ctas .btn-compiler:active {
  transform: translateY(0);
  background: rgba(42, 92, 246, 0.08);
}

/* Better spacing on tiny screens */
@media (max-width: 420px) {
  .nav-ctas .btn {
    padding-left: 12px;
    padding-right: 12px;
  }
}

/* ---------------------------------------------------------------------
   7) HERO
   --------------------------------------------------------------------- */

.hero {
  position: relative;
  overflow: hidden;
  padding: 96px 24px 80px;
  text-align: center;
  background: var(--surface);
}

.hero-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(42, 92, 246, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(42, 92, 246, 0.04) 1px, transparent 1px);
  background-size: 40px 40px;
  mask-image: radial-gradient(ellipse 90% 80% at 50% 0%, #000 40%, transparent 100%);
}

.hero-glow {
  position: absolute;
  top: -120px;
  left: 50%;
  transform: translateX(-50%);
  width: 700px;
  height: 500px;
  background: radial-gradient(ellipse, rgba(42, 92, 246, 0.12) 0%, transparent 70%);
  pointer-events: none;
}

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

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--accent-lt);
  color: var(--accent);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  padding: 6px 14px;
  border-radius: 50px;
  border: 1px solid rgba(42, 92, 246, 0.2);
  margin-bottom: 28px;
  animation: fadeUp 0.5s ease both;
}

.hero-badge svg {
  width: 12px;
  height: 12px;
}

.hero h1 {
  font-size: clamp(2.2rem, 5vw, 3.6rem);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.03em;
  color: var(--ink);
  margin-bottom: 22px;
  animation: fadeUp 0.5s 0.08s ease both;
}

.hero h1 em {
  font-style: normal;
  background: linear-gradient(135deg, var(--accent) 0%, #7c5cf5 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-desc {
  font-size: 1.1rem;
  color: var(--muted);
  max-width: 580px;
  margin: 0 auto 36px;
  line-height: 1.7;
  animation: fadeUp 0.5s 0.16s ease both;
}

.hero-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
  animation: fadeUp 0.5s 0.24s ease both;
}

/* Hero buttons: elegant outlined (as requested) */
.hero-actions .btn-compiler,
.hero-actions .btn-tools {
  background: transparent;
  box-shadow: none;
  border: 1.5px solid var(--line);
  color: var(--ink);
}

.hero-actions .btn-compiler:hover,
.hero-actions .btn-tools:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: var(--accent-lt);
}

/* Stats */
.hero-stats {
  display: flex;
  justify-content: center;
  margin-top: 56px;
  padding-top: 40px;
  border-top: 1px solid var(--line);
  animation: fadeUp 0.5s 0.32s ease both;
  flex-wrap: wrap;
  gap: 32px;
}

.stat {
  text-align: center;
}

.stat-num {
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--ink);
  letter-spacing: -0.03em;
  display: block;
  line-height: 1;
  margin-bottom: 4px;
}

.stat-label {
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--muted-2);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

/* ---------------------------------------------------------------------
   8) TOOL STRIP
   --------------------------------------------------------------------- */

.tool-strip {
  background: var(--ink);
  padding: 20px 24px;
}

.tool-strip-inner {
  max-width: var(--container);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
}

.tool-strip-text {
  color: rgba(255, 255, 255, 0.7);
  font-size: 0.9rem;
  font-weight: 500;
}

.tool-strip-text strong {
  color: #fff;
}

.tool-strip-links {
  display: flex;
  gap: 12px;
  align-items: center;
  flex-wrap: wrap;
}

/* tool-strip-links — elegant minimal (as requested) */
.tool-strip-links .btn-tools,
.tool-strip-links .btn-ghost {
  background: transparent !important;
  box-shadow: none !important;
  border: 1.5px solid rgba(255, 255, 255, 0.25);
  color: rgba(255, 255, 255, 0.85);
}

.tool-strip-links .btn-tools:hover,
.tool-strip-links .btn-ghost:hover {
  background: rgba(255, 255, 255, 0.08) !important;
  border-color: rgba(255, 255, 255, 0.5);
  color: #fff;
  transform: translateY(-1px);
}

.tool-strip-links .btn-tools:active,
.tool-strip-links .btn-ghost:active {
  transform: translateY(0);
  background: rgba(255, 255, 255, 0.12) !important;
}

/* ---------------------------------------------------------------------
   9) Sections Base
   --------------------------------------------------------------------- */

.section {
  max-width: var(--container);
  margin: 0 auto;
  padding: 88px 24px;
}

.section + .section {
  padding-top: 0;
}

.section-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 14px;
}

.section-eyebrow svg {
  width: 13px;
  height: 13px;
}

.section-title {
  font-size: clamp(1.6rem, 3vw, 2.4rem);
  font-weight: 800;
  color: var(--ink);
  letter-spacing: -0.025em;
  line-height: 1.15;
  margin-bottom: 14px;
}

.section-sub {
  font-size: 1.05rem;
  color: var(--muted);
  max-width: 620px;
  line-height: 1.7;
  margin-bottom: 56px;
}

.center .section-sub {
  margin-left: auto;
  margin-right: auto;
}

/* ---------------------------------------------------------------------
   10) Feature Grid
   --------------------------------------------------------------------- */

.feat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 20px;
}

.feat-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  padding: 28px;
  transition: border-color 0.2s, box-shadow 0.2s, transform 0.2s;
  position: relative;
  overflow: hidden;
  will-change: transform;
}

.feat-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--accent), #7c5cf5);
  opacity: 0;
  transition: opacity 0.2s;
}

.feat-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--sh-lg);
  border-color: transparent;
}

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

.feat-icon {
  width: 48px;
  height: 48px;
  background: var(--accent-lt);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 18px;
}

.feat-icon svg {
  width: 24px;
  height: 24px;
  color: var(--accent);
}

.feat-title {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--ink);
  margin-bottom: 10px;
  letter-spacing: -0.01em;
}

.feat-desc {
  font-size: 0.9rem;
  color: var(--muted);
  line-height: 1.65;
}

/* ---------------------------------------------------------------------
   11) Steps
   --------------------------------------------------------------------- */

.steps-wrap {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 32px;
  counter-reset: steps;
}

.step-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  padding: 32px;
  position: relative;
  transition: box-shadow 0.2s, transform 0.2s;
  will-change: transform;
}

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

.step-num {
  font-family: var(--fm);
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--accent);
  background: var(--accent-lt);
  border: 1px solid rgba(42, 92, 246, 0.2);
  padding: 3px 10px;
  border-radius: 50px;
  display: inline-block;
  margin-bottom: 16px;
}

.step-title {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--ink);
  margin-bottom: 10px;
  letter-spacing: -0.01em;
}

.step-desc {
  font-size: 0.9rem;
  color: var(--muted);
  line-height: 1.65;
}

/* ---------------------------------------------------------------------
   12) Benefits
   --------------------------------------------------------------------- */

.benefits-bg {
  background: var(--ink);
  /* Padding removed — inner .section provides correct 88px padding on all sides */
  padding: 0;
}

.benefits-bg .section-title,
.benefits-bg .section-sub {
  color: rgba(255, 255, 255, 0.9);
}

.benefits-bg .section-eyebrow {
  color: var(--accent-2);
}

.benefits-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 16px;
}

.benefit-item {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--r);
  padding: 18px 20px;
  transition: background 0.2s, border-color 0.2s;
}

.benefit-item:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.15);
}

.benefit-icon {
  width: 36px;
  height: 36px;
  background: rgba(0, 200, 150, 0.15);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.benefit-icon svg {
  width: 18px;
  height: 18px;
  color: var(--accent-2);
}

.benefit-text {
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.8);
  font-weight: 500;
  line-height: 1.5;
  padding-top: 2px;
}

/* ---------------------------------------------------------------------
   13) Use Cases
   --------------------------------------------------------------------- */

.usecases-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
}

.usecase-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  padding: 28px;
  transition: border-color 0.2s, box-shadow 0.2s, transform 0.2s;
  will-change: transform;
}

.usecase-card:hover {
  border-color: var(--accent);
  box-shadow: 0 8px 32px rgba(42, 92, 246, 0.1);
  transform: translateY(-3px);
}

.usecase-icon {
  width: 44px;
  height: 44px;
  background: linear-gradient(135deg, var(--accent-lt), #ede8ff);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
}

.usecase-icon svg {
  width: 22px;
  height: 22px;
  color: var(--accent);
}

.usecase-title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--ink);
  margin-bottom: 8px;
}

.usecase-desc {
  font-size: 0.875rem;
  color: var(--muted);
  line-height: 1.65;
}

/* ---------------------------------------------------------------------
   14) FAQ
   --------------------------------------------------------------------- */

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

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

.faq-item.open {
  border-color: var(--accent);
}

.faq-q {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: 20px 24px;
  background: none;
  border: none;
  cursor: pointer;
  font-family: var(--ff);
  font-size: 0.975rem;
  font-weight: 600;
  color: var(--ink);
  text-align: left;
  transition: background 0.15s;
}

.faq-q:hover {
  background: var(--bg);
}

.faq-chevron {
  width: 32px;
  height: 32px;
  background: var(--bg);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: background 0.2s, transform 0.3s;
}

.faq-chevron svg {
  width: 16px;
  height: 16px;
  color: var(--muted);
  transition: color 0.2s;
}

.faq-item.open .faq-chevron {
  background: var(--accent-lt);
  transform: rotate(180deg);
}

.faq-item.open .faq-chevron svg {
  color: var(--accent);
}

.faq-a {
  display: none;
  padding: 0 24px 22px;
  font-size: 0.9rem;
  color: var(--muted);
  line-height: 1.7;
  border-top: 1px solid var(--line);
  padding-top: 18px;
}

.faq-item.open .faq-a {
  display: block;
}

/* ---------------------------------------------------------------------
   15) Compare Strip
   --------------------------------------------------------------------- */

.compare-strip {
  background: var(--accent-lt);
  border: 1px solid rgba(42, 92, 246, 0.15);
  border-radius: var(--r-lg);
  padding: 40px;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 32px;
  align-items: center;
}

.compare-label {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 10px;
}

.compare-title {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--ink);
  margin-bottom: 8px;
}

.compare-desc {
  font-size: 0.875rem;
  color: var(--muted);
  line-height: 1.6;
}

.compare-divider {
  width: 1px;
  height: 80px;
  background: rgba(42, 92, 246, 0.2);
  margin: 0 auto;
}

/* ---------------------------------------------------------------------
   16) CTA Band
   --------------------------------------------------------------------- */

.cta-band {
  background: linear-gradient(135deg, var(--accent) 0%, #5b3cf5 100%);
  padding: 88px 24px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.cta-band::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.05) 1px, transparent 1px);
  background-size: 40px 40px;
}

.cta-band-inner {
  position: relative;
  max-width: 640px;
  margin: 0 auto;
}

.cta-band h2 {
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  font-weight: 800;
  color: #fff;
  letter-spacing: -0.03em;
  margin-bottom: 16px;
}

.cta-band p {
  font-size: 1.05rem;
  color: rgba(255, 255, 255, 0.8);
  margin-bottom: 36px;
  line-height: 1.6;
}

.cta-band-btns {
  display: flex;
  gap: 14px;
  justify-content: center;
  flex-wrap: wrap;
}

.btn-white {
  background: #fff;
  color: var(--accent);
  font-weight: 700;
}

.btn-white:hover {
  background: var(--bg);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
}

.btn-wh-outline {
  background: rgba(255, 255, 255, 0.15);
  color: #fff;
  border: 1.5px solid rgba(255, 255, 255, 0.4);
  font-weight: 600;
}

.btn-wh-outline:hover {
  background: rgba(255, 255, 255, 0.25);
  border-color: rgba(255, 255, 255, 0.7);
}

/* ---------------------------------------------------------------------
   17) Footer
   --------------------------------------------------------------------- */

.footer {
  background: var(--ink);
  color: rgba(255, 255, 255, 0.65);
  padding: 64px 24px 32px;
}

.footer-inner {
  max-width: var(--container);
  margin: 0 auto;
}

.footer-top {
  display: grid;
  grid-template-columns: 1.8fr repeat(3, 1fr);
  gap: 48px;
  padding-bottom: 48px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  margin-bottom: 32px;
}

.footer-brand-mark {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 14px;
}

.footer-brand-icon {
  width: 30px;
  height: 30px;
  background: var(--accent);
  border-radius: 7px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.footer-brand-icon svg {
  width: 17px;
  height: 17px;
  color: #fff;
}

.footer-brand-name {
  font-size: 1.05rem;
  font-weight: 800;
  color: #fff;
  letter-spacing: -0.02em;
}

.footer-brand-desc {
  font-size: 0.875rem;
  line-height: 1.65;
  margin-bottom: 20px;
}

.footer-cta-row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.footer-col h4 {
  font-size: 0.8rem;
  font-weight: 700;
  color: #fff;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 18px;
}

.footer-col ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-col ul li a {
  font-size: 0.875rem;
  color: rgba(255, 255, 255, 0.55);
  text-decoration: none;
  transition: color 0.15s;
}

.footer-col ul li a:hover {
  color: #fff;
}

.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  font-size: 0.8rem;
}

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

.footer-bottom-links a {
  color: rgba(255, 255, 255, 0.45);
  text-decoration: none;
  transition: color 0.15s;
}

.footer-bottom-links a:hover {
  color: rgba(255, 255, 255, 0.8);
}

/* ---------------------------------------------------------------------
   18) Mobile / Tablet Drawer
   --------------------------------------------------------------------- */

.nav-hamburger {
  display: none;
  width: 40px;
  height: 40px;
  align-items: center;
  justify-content: center;
  background: none;
  border: 1px solid var(--line);
  border-radius: 8px;
  cursor: pointer;
  flex-shrink: 0;
  transition: border-color 0.15s, background 0.15s;
}

.nav-hamburger:hover {
  border-color: var(--ink-2);
  background: var(--bg);
}

.nav-hamburger svg {
  width: 18px;
  height: 18px;
  color: var(--muted);
}

.icon-close {
  display: none;
}

/* Show X and hide hamburger lines when menu is open — driven by aria-expanded, no JS inline style needed */
.nav-hamburger[aria-expanded="true"] .icon-open {
  display: none;
}

.nav-hamburger[aria-expanded="true"] .icon-close {
  display: flex;
  align-items: center;
  justify-content: center;
}

.nav-drawer {
  display: none;
  position: fixed;
  top: calc(64px + var(--safe-top));
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(11, 15, 26, 0.45);
  z-index: 190;
  opacity: 0;
  transition: opacity 0.2s ease;
  pointer-events: none;
  padding-bottom: var(--safe-bottom);
}

.nav-drawer.open {
  opacity: 1;
  pointer-events: all;
}

.nav-drawer-panel {
  background: var(--surface);
  border-bottom: 1px solid var(--line);
  padding: 12px 0 20px;
  transform: translateY(-8px);
  transition: transform 0.25s ease;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.12);
}

.nav-drawer.open .nav-drawer-panel {
  transform: translateY(0);
}

.drawer-section-label {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted-2);
  padding: 10px 20px 4px;
}

.drawer-link {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 20px;
  text-decoration: none;
  font-size: 0.92rem;
  font-weight: 500;
  color: var(--ink);
  transition: background 0.15s;
}

.drawer-link:hover {
  background: var(--bg);
}

.drawer-icon {
  width: 34px;
  height: 34px;
  border-radius: 8px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.drawer-icon svg {
  width: 16px;
  height: 16px;
}

.drawer-icon.blue {
  background: #e8eeff;
  color: var(--accent);
}

.drawer-icon.dark {
  background: var(--ink);
  color: #fff;
}

.drawer-icon.purple {
  background: #f3eeff;
  color: #7c3cf5;
}

.drawer-icon.green {
  background: #e0faf3;
  color: #00c896;
}

.drawer-link-info {
  flex: 1;
}

.drawer-link-name {
  display: block;
  font-weight: 600;
  color: var(--ink);
  font-size: 0.9rem;
}

.drawer-link-desc {
  display: block;
  font-size: 0.76rem;
  color: var(--muted);
  margin-top: 1px;
}

.drawer-divider {
  height: 1px;
  background: var(--line);
  margin: 8px 20px;
}

.drawer-ctas {
  display: flex;
  gap: 10px;
  padding: 14px 20px 4px;
  flex-wrap: wrap;
}

.drawer-ctas .btn {
  flex: 1;
  justify-content: center;
  min-width: 110px;
}

/* ---------------------------------------------------------------------
   19) Animations
   --------------------------------------------------------------------- */

@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(18px);
  }

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

/* ---------------------------------------------------------------------
   20) Responsive — Desktop → Tablet → Mobile (Production tuned)
   --------------------------------------------------------------------- */

/* Tablet */
@media (max-width: 960px) {
  .nav-links {
    display: none;
  }

  .nav-ctas {
    display: none;
  }

  .nav-hamburger {
    display: flex;
  }

  .nav-drawer {
    display: block;
  }

  .tool-strip-inner {
    justify-content: center;
    text-align: center;
  }

  .tool-strip-text {
    width: 100%;
  }

  .tool-strip-links {
    justify-content: center;
    width: 100%;
  }
}

/* Mid tablet */
@media (max-width: 900px) {
  .footer-top {
    grid-template-columns: 1fr 1fr;
  }

  .compare-strip {
    grid-template-columns: 1fr;
  }

  .compare-divider {
    display: none;
  }

  .compare-strip {
    gap: 18px;
  }
}

/* Mobile */
@media (max-width: 680px) {
  :root {
    --gutter: 20px;
  }

  .hero {
    padding: 72px 20px 60px;
  }

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

  .hero-actions .btn {
    width: 100%;
    max-width: 420px;
  }

  .hero-stats {
    gap: 24px;
  }

  .stat-num {
    font-size: 1.4rem;
  }

  .section {
    padding: 64px 20px;
  }

  .benefits-bg .section {
    padding: 64px 20px;
  }

  .cta-band {
    padding: 64px 20px;
  }

  .footer-top {
    grid-template-columns: 1fr;
    gap: 32px;
  }

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

  .footer-bottom {
    flex-direction: column;
    align-items: flex-start;
  }

  .compare-strip {
    padding: 28px 24px;
  }

  /* Make grids denser on small screens */
  .feat-grid {
    grid-template-columns: 1fr;
  }

  .steps-wrap {
    grid-template-columns: 1fr;
  }

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

  /* Slightly reduce card padding */
  .feat-card,
  .usecase-card {
    padding: 22px;
  }

  .step-card {
    padding: 24px;
  }

  /* Larger tap targets for drawer links */
  .drawer-link {
    padding-top: 14px;
    padding-bottom: 14px;
  }
}

/* Extra small phones */
@media (max-width: 420px) {
  .nav-inner {
    padding-left: 16px;
    padding-right: 16px;
  }

  .hero h1 {
    font-size: clamp(1.9rem, 8vw, 2.6rem);
  }

  .btn-lg {
    padding-left: 18px;
    padding-right: 18px;
  }

  .compare-strip {
    padding: 22px 18px;
  }
}

/* ---------------------------------------------------------------------
   21) Print (optional)
   --------------------------------------------------------------------- */

@media print {
  .nav,
  .nav-drawer,
  .tool-strip,
  .cta-band {
    display: none !important;
  }

  body {
    background: #fff;
    color: #000;
  }

  .section {
    padding: 24px 0;
  }

  .feat-card,
  .usecase-card,
  .step-card,
  .faq-item,
  .compare-strip {
    box-shadow: none !important;
  }
}

/* ---------------------------------------------------------------------
   22) Performance helpers
   --------------------------------------------------------------------- */

/* Keep expensive sections isolated for better INP/paint */
/* contain:paint is safe — avoids the overflow-clipping and scroll issues that layout+style causes on mobile */
.feat-card,
.usecase-card,
.step-card {
  contain: paint;
}

/* hero and section: paint only — layout containment breaks position:sticky and overflow on iOS */
.hero,
.section {
  contain: style;
}

/* Avoid text shifting when icons load */
.btn svg,
.nav-logo-mark svg {
  flex: 0 0 auto;
}
/* =====================================
   FIX: Hero Stats Mobile Layout
   ===================================== */

@media (max-width: 680px) {

  .hero-stats {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    margin-top: 40px;
    padding-top: 30px;
  }

  .hero-stats .stat {
    text-align: center;
    padding: 12px 8px;
  }

  .hero-stats .stat-num {
    font-size: 1.4rem;
    line-height: 1.1;
  }

  .hero-stats .stat-label {
    font-size: 0.72rem;
    letter-spacing: 0.06em;
  }
}
/* =====================================================================
   End of Production CSS
   ===================================================================== */
