/* ============================================
   PestGrade — Marketing Website Styles

   This stylesheet ships every CSS class the Content Agent is allowed to use
   (see the approved class list in CLAUDE.md). Do NOT rename or remove those
   classes — the "never invent CSS classes" safety rule depends on them
   existing here. To rebrand, change the design tokens in :root below
   (colors, radius, fonts) and the class names stay the same. The default
   look is a warm-cream background with a green accent.
   ============================================ */

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

:root {
  /* PestGrade brand palette. These are the only values you normally need
     to touch to rebrand. --green-accent / --green-bright are the primary
     accent (buttons, links, highlights) — a clean field-green that reads as
     pest-control/outdoors without looking like a vendor's own UI. Rename the
     variables if you like, but if you do, update every reference below too.
     Easiest path: keep the variable names and just change the hex values. */
  --bg-primary: #f5f0ea;
  --bg-card: #faf7f2;
  --border-warm: #e8e3dc;
  --border-medium: #d5d0ca;
  --green-accent: #22c55e;
  --green-bright: #16a34a;
  --green-text: #167c3a; /* darker green — passes WCAG AA as text on cream */
  --text-primary: #1a1a1a;
  --text-body: #4a4a4a;
  --text-secondary: #6b6b6b;
  --text-muted: #706b65;
  --bg-secondary: #ede8e2;
  --code-bg: #1a1a1a;
  --radius: 8px;
  --radius-lg: 12px;
  --container-max: 1200px;
  --nav-height: 64px;
  /* Display font — used only for the hero title (heavy monospace) */
  --font-display: 'JetBrains Mono', ui-monospace, 'SF Mono', Menlo, monospace;
  /* Motion */
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  /* Elevation — warm-tinted shadows that sit naturally on the cream */
  --shadow-md: 0 4px 16px rgba(20, 16, 12, 0.06);
  --shadow-lg: 0 10px 30px rgba(20, 16, 12, 0.10);
  --shadow-terminal: 0 2px 6px rgba(20, 16, 12, 0.16), 0 24px 56px rgba(20, 16, 12, 0.20);
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: var(--nav-height);
  /* clip (not hidden) suppresses horizontal scroll WITHOUT creating a scroll
     container — hidden forces overflow-y to compute to auto, which makes the
     page a scroll container and defeats position:sticky (e.g. the comparison
     table header). clip leaves overflow-y visible. */
  overflow-x: clip;
}

body {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  background: var(--bg-primary);
  color: var(--text-body);
  line-height: 1.7;
  font-size: 17px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: clip; /* see note on html above — keeps sticky working */
  -webkit-text-size-adjust: 100%;
}

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

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

a {
  color: var(--text-body);
  text-decoration: none;
  transition: color 150ms ease;
}
a:hover { color: var(--text-primary); }

code {
  font-family: 'JetBrains Mono', 'Fira Code', monospace;
  font-size: 0.9em;
}

p code, .faq__answer code {
  background: #ede8e2;
  padding: 2px 8px;
  border-radius: 4px;
  color: var(--text-primary);
  font-size: 0.85em;
}

/* --- Section Dividers — hidden, whitespace only --- */
.section-divider {
  display: none;
}

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 24px;
  border-radius: 6px;
  font-weight: 600;
  font-size: 0.9rem;
  text-decoration: none;
  transition: all 150ms var(--ease-out);
  border: none;
  cursor: pointer;
}

.btn:active {
  transform: translateY(0) scale(0.98);
}

.btn--primary {
  background: var(--text-primary);
  color: #ffffff;
}
.btn--primary:hover {
  background: #333333;
  color: #ffffff;
  transform: translateY(-1px) scale(1.02);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
}

.btn--secondary {
  background: transparent;
  color: var(--text-body);
  border: 1px solid var(--border-medium);
}
.btn--secondary:hover {
  border-color: var(--text-secondary);
  color: var(--text-primary);
  transform: translateY(-1px) scale(1.02);
}

.btn--outline {
  background: transparent;
  color: var(--text-body);
  border: 1px solid var(--border-medium);
}
.btn--outline:hover {
  border-color: var(--text-secondary);
  color: var(--text-primary);
  transform: translateY(-1px) scale(1.02);
}

.btn--sm {
  padding: 8px 16px;
  font-size: 0.82rem;
  border-radius: 6px;
}

/* --- Section Eyebrow / Overline --- */
.section-eyebrow {
  display: block;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--green-text);
  margin-bottom: 12px;
  text-align: center;
}

/* --- Section Titles --- */
.section-title {
  font-size: clamp(1.625rem, 4vw, 2.25rem);
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 16px;
  text-align: center;
  color: var(--text-primary);
}

.section-title strong {
  color: var(--green-text);
  font-weight: 700;
}

/* ============================================
   NAV
   ============================================ */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  height: var(--nav-height);
  transition: background 300ms ease, border-color 300ms ease, box-shadow 300ms ease;
  border-bottom: 1px solid transparent;
}

.nav--scrolled {
  background: rgba(245, 240, 234, 0.98);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom-color: var(--border-warm);
  box-shadow: 0 1px 8px rgba(20, 16, 12, 0.06);
}

.nav__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
}

.nav__logo {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--text-primary);
  font-weight: 700;
  font-size: 1.1rem;
  letter-spacing: -0.01em;
}
.nav__logo:hover { color: var(--text-primary); }
.nav__logo-icon { height: 28px; width: auto; display: inline-block; vertical-align: middle; margin-right: 2px; }

.nav__links {
  display: flex;
  align-items: center;
  gap: 24px;
  list-style: none;
}

.nav__links a {
  color: var(--text-body);
  font-size: 0.8rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  transition: color 150ms ease;
}
.nav__links a:hover { color: var(--text-primary); }
.nav__links .btn--primary { color: #ffffff; text-transform: none; letter-spacing: 0; }
.nav__links .btn--primary:hover { color: #ffffff; }

.nav__toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 10px;
  min-width: 44px;
  min-height: 44px;
  justify-content: center;
  align-items: center;
}

.nav__toggle span {
  display: block;
  width: 20px;
  height: 1.5px;
  background: var(--text-secondary);
  transition: all 0.3s;
}

/* ============================================
   HERO
   ============================================ */
.hero {
  position: relative;
  padding: calc(var(--nav-height) + 80px) 0 60px;
  background: var(--bg-primary);
  overflow: hidden;
}

.hero__grid-overlay {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(0, 0, 0, 0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0, 0, 0, 0.025) 1px, transparent 1px);
  background-size: 80px 80px;
  pointer-events: none;
  mask-image: radial-gradient(ellipse at 50% 30%, black 0%, transparent 70%);
  -webkit-mask-image: radial-gradient(ellipse at 50% 30%, black 0%, transparent 70%);
}

.hero__content {
  position: relative;
  text-align: center;
  max-width: 840px;
}

.hero__title {
  font-family: var(--font-display);
  font-size: clamp(1.875rem, 2.9vw, 2.1875rem);
  font-weight: 800;
  line-height: 1.12;
  margin-bottom: 20px;
  color: var(--text-primary);
  letter-spacing: -0.02em;
  word-spacing: -0.06em;
  text-wrap: balance;
}

.hero__title strong {
  display: block;
  color: var(--green-text);
  font-weight: 800;
}

.hero__subtitle {
  font-size: clamp(1rem, 2vw, 1.15rem);
  color: var(--text-secondary);
  max-width: 620px;
  margin: 0 auto 12px;
  line-height: 1.7;
}

.hero__ctas {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  margin-bottom: 48px;
}

/* --- Hero Signup Form --- */
.hero-signup {
  width: 100%;
  max-width: 520px;
}

.hero-signup__form {
  display: flex;
  gap: 8px;
  width: 100%;
}

.hero-signup__input {
  flex: 1;
  padding: 12px 16px;
  border: 2px solid var(--border-medium);
  border-radius: 8px;
  background: #ffffff;
  font-family: inherit;
  font-size: 1rem;
  color: var(--text-primary);
  outline: none;
  transition: border-color 0.15s, box-shadow 0.15s;
}

.hero-signup__input:focus {
  border-color: var(--green-accent);
  box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.15);
}

.hero-signup__input::placeholder {
  color: var(--text-muted);
}

.hero-signup__btn {
  white-space: nowrap;
  padding: 12px 24px;
  font-size: 1rem;
  font-weight: 600;
}

.hero-signup__hint {
  margin: 8px 0 0;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.hero-signup__status {
  margin: 6px 0 0;
  font-size: 0.88rem;
  min-height: 1.3em;
}

.hero-signup__status--error {
  color: #dc2626;
}

.hero-signup__success {
  width: 100%;
  max-width: 520px;
  text-align: left;
}

.hero-signup__success-title {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--green-accent);
  margin: 0 0 8px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.hero-signup__warning {
  margin: 8px 0 0;
  font-size: 0.85rem;
  color: #dc2626;
  font-weight: 500;
}

.hero-signup__next {
  margin: 8px 0 0;
  font-size: 0.88rem;
  color: var(--text-secondary);
}

.hero-signup__next code {
  background: rgba(0,0,0,0.06);
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 0.82rem;
}

.hero-signup__or {
  font-size: 0.82rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

@media (max-width: 768px) {
  .hero-signup__form {
    flex-direction: column;
  }

  .hero-signup__btn {
    width: 100%;
  }
}

/* --- Code Blocks --- */
.code-block {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  background: var(--code-bg);
  border: 1px solid #2a2a2e;
  border-radius: var(--radius);
  padding: 12px 16px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.85rem;
  color: #e5e5e5;
  max-width: 100%;
  overflow-x: auto;
}

.code-block--hero {
  font-size: 0.95rem;
  padding: 16px 20px;
  border-radius: 8px;
  background: #1e1e22;
}

.code-block code {
  white-space: pre;
}

.copy-btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: none;
  border: 1px solid transparent;
  border-radius: 4px;
  color: #71717a;
  cursor: pointer;
  padding: 4px 8px;
  font-size: 0.7rem;
  font-family: 'Inter', sans-serif;
  transition: all 150ms ease;
  flex-shrink: 0;
}

.copy-btn:hover {
  color: #a1a1aa;
}

.copy-btn--copied {
  opacity: 1;
  color: #4ade80;
  border-color: #4ade80;
}

/* --- Terminal --- */
.terminal {
  background: var(--code-bg);
  border-radius: var(--radius-lg);
  overflow: hidden;
  text-align: left;
  max-width: 800px;
  margin: 0 auto;
  border: 1px solid rgba(255, 255, 255, 0.06);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.07), var(--shadow-terminal);
}

.terminal--sm {
  margin-top: 16px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06), var(--shadow-md);
}

.terminal__bar {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 14px 18px;
  background: #222222;
  border-bottom: 1px solid #2a2a2e;
}

.terminal__dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  opacity: 0.7;
}
.terminal__dot--red { background: #ff5f56; }
.terminal__dot--yellow { background: #ffbd2e; }
.terminal__dot--green { background: #27c93f; }

.terminal__title {
  color: #ffffff;
  font-size: 0.72rem;
  margin-left: auto;
  margin-right: auto;
  font-weight: 400;
}

.terminal__body {
  padding: 24px;
  overflow-x: auto;
}

.terminal__body pre {
  margin: 0;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.875rem;
  line-height: 1.65;
  white-space: pre;
  overflow-x: auto;
}

.terminal__body code {
  white-space: pre;
  color: #f0f0f0;
}

.t-prompt { color: #71717a; }
.t-cmd { color: #4ade80; font-weight: 500; }
.t-string { color: #86efac; }
.t-key { color: #6ee7b7; }
.t-bool { color: #fbbf24; }
.t-bracket { color: #a1a1aa; }

/* ============================================
   PROBLEM
   ============================================ */
.problem {
  padding: 80px 0;
  background: var(--bg-primary);
}

.problem .section-title {
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

.problem__text {
  text-align: left;
  color: var(--text-body);
  max-width: 600px;
  margin: 0 auto;
  font-size: 1.05rem;
  line-height: 1.8;
}

.problem__text + .problem__text {
  margin-top: 16px;
}

.wilderness-divider {
  display: none;
}

/* ============================================
   HOW IT WORKS
   ============================================ */
.how-it-works {
  padding: 80px 0;
  background: var(--bg-primary);
}

.how-it-works__tagline {
  text-align: center;
  color: var(--text-muted);
  font-size: 0.95rem;
  font-weight: 500;
  letter-spacing: 0.01em;
  margin-top: 32px;
  padding-top: 24px;
  border-top: 1px solid var(--border-warm);
  max-width: 720px;
  margin-left: auto;
  margin-right: auto;
}

.steps {
  display: flex;
  flex-direction: column;
  gap: 24px;
  max-width: 720px;
  margin: 0 auto;
  position: relative;
}

.steps::before {
  display: none;
}

.step {
  background: var(--bg-card);
  border: 1px solid var(--border-warm);
  border-radius: var(--radius-lg);
  padding: 40px;
  position: relative;
  z-index: 1;
}

.step__number {
  display: inline-block;
  color: var(--text-muted);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  margin-bottom: 12px;
}

.step__title {
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 16px;
  color: var(--text-primary);
}

.step .code-block {
  width: 100%;
}

.step .code-block code {
  white-space: nowrap;
}

/* ============================================
   BLOG HERO IMAGE
   ============================================ */
.blog-hero {
  max-width: 680px;
  margin: 0 auto 40px;
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--border-warm);
}
.blog-hero img {
  width: 100%;
  height: auto;
  display: block;
}

/* ============================================
   HUMAN GUIDE (standalone page + shared components)
   ============================================ */
.guide-page {
  padding: calc(var(--nav-height) + 80px) 0 100px;
  background: var(--bg-secondary);
}

.guide-page__title {
  text-align: center;
  font-size: clamp(2rem, 5vw, 3rem);
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: 16px;
  max-width: 680px;
  margin-left: auto;
  margin-right: auto;
}

.guide-page__intro {
  max-width: 680px;
  margin: 0 auto 48px;
  text-align: center;
  color: var(--text-body);
  font-size: 1.1rem;
  line-height: 1.7;
}

.guide-page__prereq {
  max-width: 680px;
  margin: 0 auto 40px;
  background: var(--bg-card);
  border: 1px solid var(--border-warm);
  border-radius: var(--radius-lg);
  padding: 28px 32px;
}

.guide-page__prereq h2 {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 16px;
}

.guide-page__prereq p {
  color: var(--text-body);
  font-size: 1rem;
  line-height: 1.7;
  margin-bottom: 16px;
}

.guide-page__prereq p:last-child {
  margin-bottom: 0;
}

.guide-page__prereq a {
  color: var(--text-primary);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.guide-page__prereq code {
  background: var(--bg-code);
  padding: 2px 6px;
  border-radius: 3px;
  font-size: 0.88rem;
}

.guide-page__explainer {
  max-width: 680px;
  margin: 48px auto 0;
  background: var(--bg-card);
  border: 1px solid var(--border-warm);
  border-radius: var(--radius-lg);
  padding: 36px 40px;
}

.guide-page__explainer h2 {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 16px;
}

.guide-page__explainer p {
  color: var(--text-body);
  font-size: 1rem;
  line-height: 1.7;
  margin-bottom: 16px;
}

.guide-page__explainer p:last-child {
  margin-bottom: 0;
}

.guide-page__explainer ul,
.guide-page__explainer ol {
  color: var(--text-body);
  font-size: 1rem;
  line-height: 1.7;
  margin-bottom: 16px;
  padding-left: 24px;
}

.guide-page__explainer li {
  margin-bottom: 8px;
}

.guide-page__explainer a {
  color: var(--text-primary);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.guide-page__explainer strong {
  color: var(--text-primary);
}

.guide-page__explainer .code-block {
  display: flex;
  align-items: flex-start;
  margin: 4px 0 20px;
  max-width: 100%;
  padding: 14px 18px;
}

.guide-page__explainer .code-block + .code-block {
  margin-top: 0;
}

.guide-page__explainer .code-block code {
  white-space: pre-wrap;
  word-break: break-word;
  overflow-wrap: anywhere;
  min-width: 0;
  flex: 1;
  line-height: 1.6;
}

.guide-page__explainer .terminal {
  margin: 24px auto;
}

.guide-page__explainer .compare-table-wrap {
  margin: 8px 0 24px;
}

.guide-page__checks {
  display: grid;
  gap: 8px;
}

.guide-page__checks dt {
  font-weight: 600;
  color: var(--text-primary);
  font-size: 1.05rem;
}

.guide-page__checks dt:not(:first-child) {
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid rgba(0, 0, 0, 0.08);
}

.guide-page__checks dd {
  margin: 4px 0 0;
  color: var(--text-body);
  font-size: 1rem;
  line-height: 1.7;
}

.guide-page__checks code {
  background: var(--bg-code);
  padding: 2px 6px;
  border-radius: 3px;
  font-size: 0.88rem;
}

.guide-page__cta {
  max-width: 680px;
  margin: 48px auto 0;
  text-align: center;
  background: var(--bg-card);
  border: 2px solid var(--green-accent);
  border-radius: 16px;
  padding: 40px 32px;
  box-shadow: 0 4px 24px rgba(34, 197, 94, 0.08);
}

.guide-page__cta h2 {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 12px;
}

.guide-page__cta p {
  color: var(--text-body);
  font-size: 1rem;
  line-height: 1.7;
  margin-bottom: 20px;
}

.guide-page__cta .code-block {
  max-width: 480px;
  margin: 0 auto 16px;
}

.guide-page__cta .hero-signup {
  max-width: 480px;
  margin: 0 auto 16px;
}

.guide-page__cta .hero-signup__or {
  margin: 12px 0 4px;
}

.guide-page__cta-sub {
  font-size: 0.92rem;
  color: var(--text-secondary);
}

.guide-page__cta-sub code {
  background: var(--bg-code);
  padding: 2px 6px;
  border-radius: 3px;
  font-size: 0.85rem;
}

.human-guide__steps {
  max-width: 680px;
  margin: 0 auto;
  display: grid;
  gap: 36px;
}

.guide-step {
  background: var(--bg-card);
  border: 1px solid var(--border-warm);
  border-radius: var(--radius-lg);
  padding: 32px 36px;
  min-width: 0;
}

.guide-step__header {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  margin-bottom: 20px;
}

.guide-step__number {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--text-primary);
  color: var(--bg-primary);
  font-weight: 700;
  font-size: 0.95rem;
  margin-top: 2px;
}

.guide-step__title {
  font-size: 1.18rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.guide-step__desc {
  color: var(--text-body);
  font-size: 1rem;
  line-height: 1.7;
}

.guide-step__desc a {
  color: var(--text-primary);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.guide-step__note {
  margin-top: 12px;
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.7;
}

.guide-step__note code {
  background: var(--bg-code);
  padding: 2px 6px;
  border-radius: 3px;
  font-size: 0.85rem;
}

.guide-step .code-block {
  margin-bottom: 0;
}

.guide-step .terminal--guide {
  margin-top: 16px;
}

.guide-step .terminal--guide .terminal__body {
  font-size: 0.78rem;
  line-height: 1.6;
}

.t-pass {
  color: var(--green-accent);
  font-weight: 700;
}

.t-comment {
  color: var(--text-secondary);
  font-style: italic;
}

/* Guide step: other commands */
.guide-step__commands {
  display: grid;
  gap: 20px;
}

.guide-step__commands dt {
  font-size: 1rem;
  font-weight: 500;
  color: var(--text-primary);
  margin-bottom: 8px;
}

.guide-step__commands dd {
  margin: 0;
}

.human-guide__footer {
  max-width: 680px;
  margin: 48px auto 0;
  text-align: center;
  padding: 24px 32px;
  background: var(--bg-card);
  border: 1px solid var(--border-warm);
  border-radius: var(--radius-lg);
  color: var(--text-body);
  font-size: 0.95rem;
  line-height: 1.7;
}

.human-guide__footer code {
  background: var(--bg-code);
  padding: 1px 5px;
  border-radius: 3px;
  font-size: 0.85rem;
}

/* ============================================
   BLOG INDEX
   ============================================ */

/* --- Toolbar: Search + Filters --- */
.blog-toolbar {
  max-width: 900px;
  margin: 0 auto 32px;
  position: sticky;
  top: var(--nav-height);
  z-index: 90;
  background: var(--bg-secondary);
  padding: 24px 28px 20px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-warm);
}

.blog-search {
  position: relative;
  max-width: 440px;
  margin-bottom: 16px;
}

.blog-search__icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  pointer-events: none;
}

.blog-search__input {
  width: 100%;
  padding: 10px 14px 10px 40px;
  font-family: inherit;
  font-size: 0.9rem;
  color: var(--text-primary);
  background: var(--bg-card);
  border: 1px solid var(--border-warm);
  border-radius: var(--radius);
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.blog-search__input:focus {
  border-color: var(--green-accent);
  box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.15);
}

.blog-search__input::placeholder {
  color: var(--text-muted);
}

.blog-filters {
  display: flex;
  gap: 8px;
  flex-wrap: nowrap;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  -ms-overflow-style: none;
  padding-bottom: 4px;
}

.blog-filters::-webkit-scrollbar {
  display: none;
}

.blog-filter {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 6px 14px;
  font-family: inherit;
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--text-secondary);
  background: var(--bg-card);
  border: 1px solid var(--border-warm);
  border-radius: 20px;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.15s ease;
}

.blog-filter:hover {
  border-color: var(--text-secondary);
  color: var(--text-primary);
}

.blog-filter--active {
  background: var(--text-primary);
  border-color: var(--text-primary);
  color: var(--bg-primary);
}

.blog-filter--active:hover {
  background: var(--text-primary);
  border-color: var(--text-primary);
  color: var(--bg-primary);
}

.blog-filter__count {
  font-size: 0.72rem;
  font-weight: 600;
  opacity: 0.6;
}

/* --- Pillar Guides Featured Section --- */
.blog-pillars {
  max-width: 900px;
  margin: 0 auto 40px;
  background: linear-gradient(135deg, rgba(34, 197, 94, 0.05), rgba(34, 197, 94, 0.015));
  border: 1px solid rgba(34, 197, 94, 0.15);
  border-radius: 16px;
  padding: 32px;
}

.blog-pillars__header {
  margin-bottom: 24px;
}

.blog-pillars__heading {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.blog-pillars__sub {
  font-size: 0.85rem;
  color: var(--text-secondary);
}

.blog-pillars__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

/* --- Blog Cards (shared) --- */
.blog-card {
  display: flex;
  flex-direction: column;
  background: var(--bg-card);
  border: 1px solid var(--border-warm);
  border-radius: var(--radius-lg);
  text-decoration: none;
  overflow: hidden;
  transition: border-color 0.2s, box-shadow 0.2s, transform 0.2s;
}

.blog-card:hover {
  border-color: var(--text-secondary);
  box-shadow: 0 6px 24px rgba(0, 0, 0, 0.07);
  transform: translateY(-2px);
}

/* Featured / Pillar card */
.blog-card--featured {
  border-left: 3px solid var(--green-accent);
}

.blog-card--featured:hover {
  border-left-color: var(--green-accent);
}

/* Hero image at the top of each card */
.blog-card__hero {
  display: block;
  width: 100%;
  aspect-ratio: 1200 / 630;
  object-fit: cover;
  background: linear-gradient(135deg, #f5f0ea, #eae4db);
  border-bottom: 1px solid var(--border-warm);
}

/* Body wrapper (injected by JS) — holds all non-hero content with padding */
.blog-card__body {
  display: flex;
  flex-direction: column;
  flex: 1;
  padding: 20px 24px 22px;
}

.blog-card__badge {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--green-bright);
  background: rgba(34, 197, 94, 0.1);
  padding: 3px 10px;
  border-radius: 4px;
  margin-bottom: 10px;
  width: fit-content;
}

.blog-card__category {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--text-secondary);
  margin-bottom: 8px;
}

.blog-card__category::before {
  content: '';
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
}

.blog-card__category[data-cat="campaign"]::before { background: var(--green-accent); }
.blog-card__category[data-cat="mcp"]::before { background: var(--text-primary); }
.blog-card__category[data-cat="landing"]::before { background: var(--text-muted); }
.blog-card__category[data-cat="start"]::before { background: var(--green-bright); }

.blog-card__title {
  font-size: 1.02rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 8px;
  line-height: 1.4;
}

.blog-card__desc {
  color: var(--text-body);
  font-size: 0.85rem;
  line-height: 1.6;
  margin-bottom: 12px;
  flex: 1;
}

.blog-card__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: auto;
}

.blog-card__readtime {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 0.78rem;
  color: var(--text-muted);
}

.blog-card__readtime svg {
  opacity: 0.6;
}

.blog-card__date {
  display: inline-flex;
  align-items: center;
  font-size: 0.78rem;
  color: var(--text-muted);
}

.blog-card__date::after {
  content: '·';
  margin: 0 8px;
  opacity: 0.6;
}

.blog-card__new {
  display: inline-block;
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: white;
  background: var(--green-accent);
  padding: 2px 8px;
  border-radius: 3px;
}

.blog-card__meta {
  font-size: 0.78rem;
  color: var(--text-secondary);
}

/* --- Latest Posts Section --- */
.blog-latest {
  max-width: 900px;
  margin: 0 auto 40px;
}

.blog-section__heading {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 16px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--border-warm);
}

.blog-latest__row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

/* --- All Posts Grid --- */
.blog-all {
  max-width: 900px;
  margin: 0 auto 48px;
}

.blog-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

/* --- Empty State --- */
.blog-empty {
  max-width: 900px;
  margin: 60px auto;
  text-align: center;
  color: var(--text-muted);
  font-size: 0.95rem;
}

/* --- Back to Top --- */
.back-to-top {
  position: fixed;
  bottom: 32px;
  right: 32px;
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--text-primary);
  color: var(--bg-primary);
  border: none;
  border-radius: 50%;
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transform: translateY(12px);
  transition: opacity 0.3s, visibility 0.3s, transform 0.3s;
  z-index: 100;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.back-to-top--visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.back-to-top:hover {
  background: var(--green-accent);
}

/* ============================================
   BLOG ARTICLE (shared styles for all posts + pillar pages)
   ============================================ */
.article-content {
  max-width: 680px;
  margin: 0 auto;
}

.article-content h2 {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--text-primary);
  margin: 48px 0 16px;
  line-height: 1.3;
}

.article-content h3 {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text-primary);
  margin: 32px 0 12px;
}

.article-content p {
  color: var(--text-body);
  font-size: 0.95rem;
  line-height: 1.8;
  margin-bottom: 16px;
}

.article-content ul,
.article-content ol {
  color: var(--text-body);
  font-size: 0.95rem;
  line-height: 1.8;
  margin-bottom: 16px;
  padding-left: 24px;
}

.article-content li {
  margin-bottom: 8px;
}

.article-content strong {
  color: var(--text-primary);
}

.article-content a {
  color: var(--text-primary);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.article-content blockquote {
  border-left: 3px solid var(--border-warm);
  padding: 12px 20px;
  margin: 20px 0;
  background: var(--bg-card);
  border-radius: 0 var(--radius-lg) var(--radius-lg) 0;
  color: var(--text-body);
  font-size: 0.95rem;
  line-height: 1.7;
}

.article-content table {
  width: 100%;
  border-collapse: collapse;
  margin: 20px 0;
  font-size: 0.88rem;
}

.article-content th {
  text-align: left;
  font-weight: 600;
  color: var(--text-primary);
  padding: 10px 12px;
  border-bottom: 2px solid var(--border-warm);
}

.article-content td {
  padding: 10px 12px;
  border-bottom: 1px solid var(--border-warm);
  color: var(--text-body);
}

.article-content code {
  background: var(--bg-code);
  padding: 1px 5px;
  border-radius: 3px;
  font-size: 0.85rem;
}

.article-content .code-block {
  margin: 16px 0;
}

.article-content .terminal {
  margin: 16px 0;
}

.article-meta {
  max-width: 680px;
  margin: 0 auto 8px;
  font-size: 0.82rem;
  color: var(--text-secondary);
}

.article-footer {
  max-width: 680px;
  margin: 48px auto 0;
  padding-top: 32px;
  border-top: 1px solid var(--border-warm);
}

.article-footer__heading {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 16px;
}

.article-footer p {
  color: var(--text-body);
  font-size: 0.9rem;
  line-height: 1.7;
  margin-bottom: 12px;
}

.article-footer code {
  background: var(--bg-code);
  padding: 1px 5px;
  border-radius: 3px;
  font-size: 0.82rem;
}

.article-related {
  max-width: 680px;
  margin: 40px auto 0;
}

.article-related__heading {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 12px;
}

.article-related__list {
  list-style: none;
  padding: 0;
}

.article-related__list li {
  margin-bottom: 8px;
}

.article-related__list a {
  color: var(--text-primary);
  text-decoration: underline;
  text-underline-offset: 2px;
  font-size: 0.92rem;
}

/* Article metadata (date, author, reading time) */
.article-meta {
  max-width: 680px;
  margin: 0 auto 32px;
  text-align: center;
  font-size: 0.88rem;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
}

.article-meta__separator {
  color: var(--border-medium);
}

/* Related reading cards */
.related-cards {
  display: grid;
  gap: 12px;
  margin-top: 16px;
}

.related-card {
  display: block;
  background: var(--bg-card);
  border: 1px solid var(--border-warm);
  border-radius: var(--radius);
  padding: 16px 20px;
  text-decoration: none;
  transition: border-color 150ms ease, box-shadow 150ms ease;
}

.related-card:hover {
  border-color: var(--border-medium);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
  color: var(--text-body);
}

.related-card__title {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.related-card__desc {
  font-size: 0.9rem;
  color: var(--text-body);
  line-height: 1.5;
}

/* ============================================
   FEATURES
   ============================================ */
.features {
  padding: 80px 0;
  background: var(--bg-primary);
}

.features__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.feature-card {
  background: var(--bg-card);
  border: 1px solid var(--border-warm);
  border-radius: var(--radius-lg);
  padding: 40px;
  transition: border-color 200ms var(--ease-out), transform 200ms var(--ease-out), box-shadow 200ms var(--ease-out);
}

.feature-card:hover {
  border-color: var(--border-medium);
  transform: translateY(-3px);
  box-shadow: var(--shadow-lg);
}

.feature-card__number {
  display: inline-block;
  color: var(--text-muted);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 16px;
}

.feature-card__title {
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 10px;
  color: var(--text-primary);
}

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

.feature-card code {
  color: var(--text-primary);
  font-size: 0.85em;
}

/* ============================================
   STATS / ROI
   ============================================ */
.stats {
  padding: 80px 0;
  background: var(--bg-primary);
}

.stats__intro {
  text-align: center;
  color: var(--text-secondary);
  max-width: 620px;
  margin: -24px auto 56px;
  font-size: 1.05rem;
  line-height: 1.7;
}

.stats__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-bottom: 48px;
}

.stat-card {
  background: var(--bg-card);
  border: 1px solid var(--border-warm);
  border-radius: var(--radius-lg);
  padding: 40px 32px;
  text-align: center;
  transition: border-color 200ms var(--ease-out), transform 200ms var(--ease-out), box-shadow 200ms var(--ease-out);
}

.stat-card:hover {
  border-color: var(--border-medium);
  transform: translateY(-3px);
  box-shadow: var(--shadow-lg);
}

.stat-card__number {
  display: block;
  font-size: clamp(2.5rem, 5vw, 3.5rem);
  font-weight: 800;
  color: var(--green-text);
  letter-spacing: -0.03em;
  line-height: 1;
  margin-bottom: 16px;
}

.stat-card__label {
  color: var(--text-body);
  font-size: 0.95rem;
  line-height: 1.5;
  margin-bottom: 12px;
}

.stat-card__source {
  color: var(--text-muted);
  font-size: 0.78rem;
  font-style: italic;
}

.stats__cta {
  text-align: center;
  color: var(--text-body);
  font-size: 1.1rem;
  font-weight: 500;
  max-width: 680px;
  margin: 0 auto;
}

/* ============================================
   PRICING
   ============================================ */
.pricing {
  padding: 80px 0;
  background: var(--bg-primary);
}

.pricing__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-bottom: 40px;
}

.pricing-card {
  background: var(--bg-card);
  border: 1px solid var(--border-warm);
  border-radius: var(--radius-lg);
  padding: 36px 32px;
  text-align: center;
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  transition: transform 200ms var(--ease-out), box-shadow 200ms var(--ease-out);
}

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

.pricing-card--popular {
  border-color: var(--text-primary);
  border-width: 2px;
  box-shadow: var(--shadow-lg);
}

.pricing-card__badge {
  position: absolute;
  top: -12px;
  background: var(--text-primary);
  color: #ffffff;
  font-size: 0.72rem;
  font-weight: 600;
  padding: 4px 16px;
  border-radius: 20px;
  letter-spacing: 0.02em;
}

.pricing-card__name {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 16px;
  margin-top: 8px;
  color: var(--text-secondary);
}

.pricing-card__price {
  font-size: 3rem;
  font-weight: 800;
  margin-bottom: 8px;
  color: var(--text-primary);
  letter-spacing: -0.02em;
}

.pricing-card__price span {
  font-size: 0.9rem;
  font-weight: 400;
  color: var(--text-muted);
}

.pricing-card__links {
  color: var(--text-body);
  margin-bottom: 4px;
  font-size: 0.95rem;
}

.pricing-card__note {
  color: var(--text-muted);
  font-size: 0.85rem;
  margin-bottom: 16px;
}

.pricing-card__features {
  list-style: none;
  padding: 0;
  margin: 0 0 24px 0;
  color: var(--text-body);
  font-size: 0.88rem;
  line-height: 1.6;
  text-align: left;
  flex: 1;
  align-self: stretch;
}

.pricing-card__features li {
  position: relative;
  padding-left: 20px;
  margin-bottom: 6px;
}

.pricing-card__features li::before {
  content: "\2713";
  position: absolute;
  left: 0;
  color: var(--text-primary);
  font-weight: 600;
}

.pricing-card__price--custom {
  font-size: 2.4rem;
}

.pricing-card .btn {
  margin-top: auto;
  width: 100%;
  align-self: stretch;
}

.pricing-card--popular .btn--primary {
  background: var(--text-primary);
  color: #ffffff;
}
.pricing-card--popular .btn--primary:hover {
  background: #333333;
  color: #ffffff;
}

.pricing__footer {
  text-align: center;
  color: var(--text-muted);
  font-size: 0.88rem;
  max-width: 640px;
  margin: 0 auto;
}

.manage-sub {
  margin-top: 48px;
  text-align: center;
}

.manage-sub__label {
  color: var(--text-secondary);
  font-size: 0.95rem;
  margin-bottom: 12px;
}

.manage-sub__form {
  display: flex;
  justify-content: center;
  gap: 8px;
  max-width: 480px;
  margin: 0 auto;
}

.manage-sub__input {
  flex: 1;
  padding: 10px 16px;
  border: 1px solid var(--border-warm);
  border-radius: 6px;
  background: #ffffff;
  font-family: inherit;
  font-size: 0.9rem;
  color: var(--text-primary);
  outline: none;
  transition: border-color 0.15s, box-shadow 0.15s;
}

.manage-sub__input:focus {
  border-color: var(--green-accent);
  box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.15);
}

.manage-sub__input::placeholder {
  color: var(--text-muted);
}

.manage-sub__status {
  margin-top: 8px;
  font-size: 0.85rem;
  color: var(--text-secondary);
  min-height: 1.2em;
}

.manage-sub__status--error {
  color: #dc2626;
}

@media (max-width: 768px) {
  .manage-sub {
    margin-top: 36px;
    padding: 0 8px;
  }

  .manage-sub__form {
    flex-direction: column;
    max-width: 320px;
  }

  .manage-sub__input {
    width: 100%;
  }
}

/* ============================================
   COMPETITOR COMPARISON TABLE
   ============================================ */
.compare-table-wrap {
  max-width: 100%;
  /* Must stay visible so the sticky thead can pin to the viewport. A scroll
     container (overflow-x:auto) would trap the sticky header and it would just
     scroll away. Horizontal scroll is re-enabled on narrow screens below, where
     the header is unpinned to match. */
  overflow: visible;
  margin: 0 auto 32px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-warm);
}

.compare-table {
  width: 100%;
  min-width: 640px;
  /* separate (not collapse) so the corner cells can be rounded — this keeps the
     rounded frame without an overflow clip, which would disable the sticky thead */
  border-collapse: separate;
  border-spacing: 0;
  font-size: 0.9rem;
  background: var(--bg-card);
}

.compare-table thead {
  background: var(--bg-primary);
  position: sticky;
  top: var(--nav-height);
  z-index: 2;
}

.compare-table th {
  padding: 14px 16px;
  text-align: left;
  font-weight: 600;
  color: var(--text-primary);
  font-size: 0.85rem;
  white-space: nowrap;
  background: var(--bg-primary);
  /* border on the cell, not the row group — row-group borders don't render in
     the separate border model */
  border-bottom: 2px solid var(--border-warm);
}

.compare-table th:first-child {
  min-width: 200px;
}

/* Rounded outer corners (corner cells, since the wrapper can't clip) */
.compare-table thead th:first-child { border-top-left-radius: var(--radius-lg); }
.compare-table thead th:last-child { border-top-right-radius: var(--radius-lg); }
.compare-table tbody tr:last-child td:first-child { border-bottom-left-radius: var(--radius-lg); }
.compare-table tbody tr:last-child td:last-child { border-bottom-right-radius: var(--radius-lg); }

.compare-table td {
  padding: 12px 16px;
  border-bottom: 1px solid var(--border-warm);
  color: var(--text-body);
  font-size: 0.88rem;
}

.compare-table tbody tr:last-child td {
  border-bottom: none;
}

.compare-table tbody tr:hover {
  background: rgba(0, 0, 0, 0.015);
}

/* Narrow screens: the table needs horizontal scroll, which requires a scroll
   container — incompatible with the sticky header, so unpin it here. */
@media (max-width: 860px) {
  .compare-table-wrap {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
  .compare-table thead {
    position: static;
  }
}

.compare-table .check {
  color: var(--green-text);
  font-weight: 700;
  font-size: 1.1rem;
}

.compare-table .cross {
  color: var(--text-muted);
  font-size: 1.1rem;
  opacity: 0.6;
}

.compare-table .highlight-col {
  background: rgba(34, 197, 94, 0.06);
  border-left: 2px solid var(--green-accent);
}

.compare-note {
  max-width: 800px;
  margin: 24px auto 0;
  text-align: center;
  color: var(--text-secondary);
  font-size: 0.92rem;
  line-height: 1.7;
}

/* Hero body text */
.hero__body {
  color: var(--text-body);
  font-size: 1.05rem;
  line-height: 1.7;
  max-width: 640px;
  margin: 0 auto 32px;
  text-align: center;
}

/* Terminal pass/arrow styling */
.t-pass {
  color: var(--green-accent);
}

.t-arrow {
  color: var(--green-accent);
  font-weight: 700;
}

/* Future-proof section reuse of problem styles */
.future-proof {
  padding: 80px 0;
}

.future-proof p {
  max-width: 680px;
  margin: 0 auto 20px;
  text-align: center;
  font-size: 1.05rem;
  line-height: 1.7;
  color: var(--text-body);
}

.future-proof p:last-child {
  margin-bottom: 0;
}

/* ============================================
   FOR AGENTS
   ============================================ */
/* Agent Decision Triggers */
.agent-decision {
  max-width: 720px;
  margin: 0 auto 32px;
  background: var(--bg-card);
  border: 1px solid var(--border-warm);
  border-radius: var(--radius-lg);
  padding: 40px;
}

.agent-decision__heading {
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 12px;
}

.agent-decision__text {
  color: var(--text-body);
  font-size: 0.95rem;
  line-height: 1.7;
  margin-bottom: 20px;
}

.agent-decision__triggers {
  list-style: none;
  padding: 0;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px 24px;
}

.agent-decision__triggers li {
  color: var(--text-secondary);
  font-size: 0.9rem;
  padding-left: 20px;
  position: relative;
}

.agent-decision__triggers li::before {
  content: '\2713';
  position: absolute;
  left: 0;
  color: var(--green-accent);
  font-weight: 700;
}

/* Agent Justification Block */
.agent-justify {
  max-width: 720px;
  margin: 0 auto 32px;
  background: var(--bg-card);
  border: 1px solid var(--border-warm);
  border-radius: var(--radius-lg);
  padding: 40px;
}

.agent-justify__heading {
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 20px;
}

.agent-justify__points {
  padding-left: 20px;
  display: grid;
  gap: 16px;
}

.agent-justify__points li {
  color: var(--text-body);
  font-size: 0.95rem;
  line-height: 1.6;
}

.agent-justify__points li strong {
  color: var(--text-primary);
}

.for-agents {
  padding: 80px 0;
  background: #f0ebe4;
}

.for-agents .section-title {
  color: var(--text-primary);
}

.agent-card {
  background: var(--code-bg);
  border-radius: 16px;
  padding: 48px;
  max-width: 720px;
  margin: 0 auto;
  font-family: 'JetBrains Mono', monospace;
}

.agent-card__intro {
  color: #e5e5e5;
  margin-bottom: 28px;
  font-size: 0.95rem;
  font-family: 'JetBrains Mono', monospace;
}

.agent-card__list {
  display: grid;
  gap: 20px;
  margin-bottom: 28px;
}

.agent-card__list dt {
  font-weight: 600;
  color: #a1a1aa;
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 6px;
  font-family: 'JetBrains Mono', monospace;
}

.agent-card__list dd {
  margin-left: 0;
}

.agent-card__list .code-block {
  width: 100%;
}

.agent-card__list a {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.85rem;
  color: #4ade80;
}
.agent-card__list a:hover {
  color: #86efac;
}

.agent-card__recommend {
  color: #a1a1aa;
  font-size: 0.88rem;
  padding-top: 20px;
  border-top: 1px solid #2a2a2e;
  font-family: 'JetBrains Mono', monospace;
}

/* ============================================
   FAQ
   ============================================ */
.faq {
  padding: 80px 0;
  background: var(--bg-primary);
}

.faq__list {
  max-width: 720px;
  margin: 0 auto;
}

.faq__item {
  border-bottom: 1px solid var(--border-warm);
}

.faq__item:first-child {
  border-top: 1px solid var(--border-warm);
}

.faq__question {
  padding: 24px 0;
  font-weight: 600;
  font-size: 1.1rem;
  cursor: pointer;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  transition: color 150ms ease;
  color: var(--text-primary);
}

.faq__question:hover {
  color: var(--text-primary);
  background: #f0ebe4;
  margin: 0 -16px;
  padding-left: 16px;
  padding-right: 16px;
  border-radius: 6px;
}

.faq__question::after {
  content: '+';
  font-size: 1.3rem;
  font-weight: 300;
  color: var(--text-muted);
  transition: transform 300ms ease;
  flex-shrink: 0;
  margin-left: 16px;
}

.faq__item[open] .faq__question::after {
  content: '\2212';
}

.faq__question::-webkit-details-marker {
  display: none;
}

.faq__answer {
  padding: 0 0 24px;
  color: var(--text-secondary);
  line-height: 1.7;
  font-size: 0.95rem;
}

.faq__answer code {
  color: var(--text-primary);
  font-size: 0.85em;
}

/* ============================================
   CTA SECTION
   ============================================ */
.cta-section {
  position: relative;
  padding: 80px 0;
  overflow: hidden;
  background: var(--bg-primary);
}

.cta-section__bg {
  display: none;
}

.cta-section__content {
  position: relative;
  z-index: 1;
  text-align: center;
}

.cta-section__buttons {
  display: flex;
  justify-content: center;
  gap: 16px;
  margin-top: 24px;
}

/* ============================================
   AGENT METADATA
   ============================================ */
.agent-technical__heading {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-top: 48px;
  margin-bottom: 16px;
  max-width: 720px;
  margin-left: auto;
  margin-right: auto;
}

.agent-technical {
  background: var(--code-bg);
  border-radius: var(--radius-lg);
  overflow: hidden;
  max-width: 720px;
  margin: 0 auto;
}

.agent-technical__list dt {
  padding: 12px 16px 0;
  font-weight: 500;
  font-size: 0.75rem;
  color: #a1a1aa;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.agent-technical__list dd {
  margin: 0;
  padding: 4px 16px 12px;
  border-bottom: 1px solid #2a2a2e;
  word-break: break-all;
  color: #e5e5e5;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.78rem;
}

.agent-technical__list dd:last-child {
  border-bottom: none;
}

.agent-technical__list dd a {
  color: #4ade80;
}
.agent-technical__list dd a:hover {
  color: #86efac;
}

/* ============================================
   FOOTER
   ============================================ */
.footer {
  border-top: 1px solid var(--border-warm);
  padding: 36px 0 24px;
  background: var(--bg-primary);
}

.footer__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 24px;
}

.footer__brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.footer__brand p {
  color: var(--text-muted);
  font-size: 0.82rem;
}

.footer__logo-icon {
  height: 24px;
  width: auto;
  display: inline-block;
  vertical-align: middle;
  opacity: 0.5;
}

.footer__links {
  display: flex;
  gap: 24px;
}

.footer__links a {
  color: var(--text-muted);
  font-size: 0.82rem;
  transition: color 150ms ease;
}

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

.footer__meta {
  text-align: right;
  font-size: 0.78rem;
  color: var(--text-muted);
}

.footer__meta a {
  color: var(--text-muted);
  transition: color 150ms ease;
}

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

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 1024px) {
  .nav__toggle {
    display: flex;
  }

  .nav__links {
    display: none;
    position: absolute;
    top: var(--nav-height);
    left: 0;
    right: 0;
    background: rgba(245, 240, 234, 0.96);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    flex-direction: column;
    padding: 24px;
    gap: 16px;
    border-bottom: 1px solid var(--border-warm);
  }

  .nav__links.open {
    display: flex;
  }

  .features__grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .stats__grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .pricing__grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .steps::before {
    display: none;
  }
}

@media (max-width: 768px) {
  body {
    font-size: 16px;
  }

  .steps {
    max-width: 100%;
  }

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

  .pricing__grid {
    grid-template-columns: 1fr;
    max-width: 400px;
    margin-left: auto;
    margin-right: auto;
  }

  .hero {
    padding: calc(var(--nav-height) + 60px) 0 80px;
  }

  .hero__title {
    font-size: clamp(1.75rem, 7vw, 2.5rem);
  }

  .section-title {
    font-size: clamp(1.75rem, 6vw, 2.25rem);
    margin-bottom: 36px;
  }

  .stats__grid {
    grid-template-columns: 1fr;
    max-width: 400px;
    margin-left: auto;
    margin-right: auto;
  }

  .problem,
  .how-it-works,
  .features,
  .stats,
  .pricing,
  .for-agents,
  .faq,
  .cta-section {
    padding: 60px 0;
  }

  .guide-step {
    padding: 24px 20px;
  }

  .guide-step__header {
    gap: 12px;
  }

  .guide-step .terminal--guide .terminal__body {
    font-size: 0.7rem;
    overflow-x: auto;
  }

  .guide-page {
    padding-top: calc(var(--nav-height) + 40px);
  }

  .blog-toolbar {
    padding: 18px 18px 14px;
  }

  .blog-search {
    max-width: 100%;
  }

  .blog-pillars {
    padding: 20px;
  }

  .blog-pillars__grid {
    grid-template-columns: 1fr;
  }

  .blog-latest__row {
    grid-template-columns: 1fr;
    gap: 12px;
  }

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

  .blog-card__body {
    padding: 18px 20px 20px;
  }

  .back-to-top {
    bottom: 20px;
    right: 20px;
    width: 40px;
    height: 40px;
  }

  .guide-page__prereq,
  .guide-page__explainer {
    padding: 24px 20px;
  }

  .code-block {
    font-size: 0.78rem;
    display: flex;
  }

  .code-block code {
    white-space: normal;
    word-break: break-all;
    min-width: 0;
  }

  .compare-table th,
  .compare-table td {
    padding: 10px 12px;
    font-size: 0.82rem;
  }

  .compare-note {
    font-size: 0.85rem;
    padding: 0 16px;
  }

  .terminal__body pre {
    font-size: 0.72rem;
  }

  .terminal__body {
    padding: 16px;
  }

  .footer__inner {
    flex-direction: column;
    text-align: center;
  }

  .footer__meta {
    text-align: center;
  }

  .cta-section__buttons {
    flex-direction: column;
    align-items: center;
  }

  .hero__ctas {
    margin-bottom: 40px;
  }

  .agent-decision,
  .agent-justify {
    padding: 32px 24px;
  }

  .agent-decision__triggers {
    grid-template-columns: 1fr;
  }

  .agent-card {
    padding: 32px 24px;
  }

  .agent-card__list .code-block {
    display: flex;
  }

  .agent-card__list .code-block code {
    white-space: normal;
    word-break: break-all;
    min-width: 0;
  }

  .agent-technical__list dd {
    font-size: 0.72rem;
  }

  .step {
    padding: 32px;
  }

  .feature-card {
    padding: 32px;
  }
}

@media (max-width: 480px) {
  .problem,
  .how-it-works,
  .features,
  .stats,
  .pricing,
  .for-agents,
  .faq,
  .cta-section {
    padding: 48px 0;
  }

  .code-block--hero {
    font-size: 0.78rem;
    padding: 10px 14px;
  }

  .code-block {
    display: flex;
    overflow-x: auto;
  }

  .code-block code {
    white-space: normal;
    word-break: break-all;
    min-width: 0;
  }

  .btn {
    min-height: 44px;
    min-width: 44px;
  }

  .step {
    padding: 24px;
  }

  .agent-card {
    padding: 24px 16px;
  }

  .agent-technical__list dt {
    padding: 10px 12px 0;
  }

  .agent-technical__list dd {
    padding: 4px 12px 10px;
    font-size: 0.7rem;
  }

  .feature-card {
    padding: 28px;
  }

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

  .container {
    padding: 0 16px;
  }
}

/* ============================================
   SCROLL REVEAL ANIMATIONS
   ============================================ */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 600ms ease-out, transform 600ms ease-out;
}

.reveal--up-sm {
  transform: translateY(20px);
}

.reveal--up-lg {
  transform: translateY(40px);
}

.reveal--fade {
  transform: none;
  transition-duration: 800ms;
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* Stagger delays for cards */
.reveal-stagger-1 { transition-delay: 0ms; }
.reveal-stagger-2 { transition-delay: 100ms; }
.reveal-stagger-3 { transition-delay: 200ms; }
.reveal-stagger-4 { transition-delay: 300ms; }
.reveal-stagger-5 { transition-delay: 400ms; }
.reveal-stagger-6 { transition-delay: 500ms; }

/* Terminal cursor blink */
.terminal-cursor {
  display: inline-block;
  color: rgba(74, 222, 128, 0.7);
  animation: blink 1s step-end infinite;
  font-family: 'JetBrains Mono', monospace;
}

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

/* Terminal typing animation — lines appear sequentially */
.terminal--animated .terminal__line {
  /* inline-block (not block): the lines are separated by real newlines in the
     source, which white-space:pre already renders as line breaks. Using block
     here added a SECOND break per line, double-spacing the whole terminal.
     inline-block keeps the single break while still allowing the opacity /
     translateX entrance animation. */
  display: inline-block;
  opacity: 0;
  transform: translateX(-6px);
}

.terminal--animated.is-visible .terminal__line {
  animation: termLineIn 400ms ease forwards;
}

@keyframes termLineIn {
  to { opacity: 1; transform: translateX(0); }
}

/* Lines 1-3: command typing (fast) */
.terminal--animated.is-visible .terminal__line:nth-child(1)  { animation-delay: 200ms; }
.terminal--animated.is-visible .terminal__line:nth-child(2)  { animation-delay: 400ms; }
.terminal--animated.is-visible .terminal__line:nth-child(3)  { animation-delay: 600ms; }
/* Line 4: blank pause */
.terminal--animated.is-visible .terminal__line:nth-child(4)  { animation-delay: 1200ms; }
/* Lines 5-13: check results (staggered) */
.terminal--animated.is-visible .terminal__line:nth-child(5)  { animation-delay: 1400ms; }
.terminal--animated.is-visible .terminal__line:nth-child(6)  { animation-delay: 1600ms; }
.terminal--animated.is-visible .terminal__line:nth-child(7)  { animation-delay: 1800ms; }
.terminal--animated.is-visible .terminal__line:nth-child(8)  { animation-delay: 2000ms; }
.terminal--animated.is-visible .terminal__line:nth-child(9)  { animation-delay: 2200ms; }
.terminal--animated.is-visible .terminal__line:nth-child(10) { animation-delay: 2400ms; }
.terminal--animated.is-visible .terminal__line:nth-child(11) { animation-delay: 2600ms; }
.terminal--animated.is-visible .terminal__line:nth-child(12) { animation-delay: 2800ms; }
.terminal--animated.is-visible .terminal__line:nth-child(13) { animation-delay: 3000ms; }
/* Line 14: blank pause before result */
.terminal--animated.is-visible .terminal__line:nth-child(14) { animation-delay: 3500ms; }
/* Lines 15-16: summary and URL */
.terminal--animated.is-visible .terminal__line:nth-child(15) { animation-delay: 3700ms; }
.terminal--animated.is-visible .terminal__line:nth-child(16) { animation-delay: 4000ms; }

/* Copy button pulse */
@keyframes copy-pulse {
  0% { transform: scale(1); }
  50% { transform: scale(1.05); }
  100% { transform: scale(1); }
}

.copy-btn--copied {
  animation: copy-pulse 300ms ease;
}

/* No-JS fallback: if JS hasn't run, show everything (reveals + terminal lines
   are otherwise stuck at opacity 0 because the JS-added .is-visible never fires) */
html:not(.js-ready) .reveal,
html:not(.js-ready) .terminal--animated .terminal__line {
  opacity: 1;
  transform: none;
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }

  .reveal,
  .terminal--animated .terminal__line {
    opacity: 1;
    transform: none;
  }
}
