:root {
  --bg: #0a0b10;
  --bg-card: #13151e;
  --bg-section: #0f1117;
  --border: #1e2235;
  --text: #e2e8f0;
  --text-dim: #8892a8;
  --primary: #6366f1;
  --primary-hover: #818cf8;
  --success: #4ade80;
  --danger: #f87171;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  font-family: 'Inter', -apple-system, system-ui, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
}

/* Nav */
.nav { padding: 1rem 0; border-bottom: 1px solid var(--border); }
.nav-inner { max-width: 1320px; margin: 0 auto; padding: 0 2rem; display: flex; justify-content: space-between; align-items: center; }
.logo { font-size: 1.3rem; font-weight: 700; line-height: 1.1; }
.logo-sub { display: block; font-size: 0.6rem; font-weight: 400; color: var(--text-dim); letter-spacing: 0.05em; }
.nav-links { display: flex; gap: 1.4rem; align-items: center; }
.nav-links a { color: var(--text-dim); text-decoration: none; font-size: 0.85rem; white-space: nowrap; }
.nav-links a:hover { color: var(--text); }
.btn-nav { background: var(--primary); color: #fff !important; padding: 0.4rem 1rem; border-radius: 6px; font-weight: 600; font-size: 0.85rem; }
.btn-nav:hover { background: var(--primary-hover); }

.nav-toggle { display: none; background: none; border: 1px solid var(--border); color: var(--text); padding: 0.3rem 0.6rem; border-radius: 4px; cursor: pointer; font-size: 1.2rem; }

@media (max-width: 900px) {
  .nav-toggle { display: block; }
  .nav-links { display: none; flex-direction: column; width: 100%; gap: 0.75rem; padding-top: 0.75rem; }
  .nav-links.open { display: flex; }
  .nav-links a { font-size: 0.9rem; }
  .nav-inner { flex-wrap: wrap; }
}

/* Hero */
.hero { text-align: center; padding: 6rem 1.5rem 4rem; max-width: 1080px; margin: 0 auto; }
.hero h1 { font-size: 2.8rem; line-height: 1.2; font-weight: 800; margin-bottom: 1.5rem; }
.highlight { color: var(--primary); }
.hero-sub { font-size: 1.15rem; color: var(--text-dim); margin-bottom: 2rem; }
.hero-cta { display: flex; flex-direction: column; align-items: center; gap: 0.75rem; }
.btn-primary { display: inline-block; background: var(--primary); color: #fff; padding: 0.7rem 2rem; border-radius: 8px; font-size: 1rem; font-weight: 600; text-decoration: none; border: none; cursor: pointer; }
.btn-primary:hover { background: var(--primary-hover); }
.btn-lg { padding: 0.9rem 2.5rem; font-size: 1.1rem; }
.hero-note { font-size: 0.85rem; color: var(--text-dim); }

/* Trust bar */
.trust-bar { background: var(--bg-card); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); padding: 1rem 0; }
.trust-inner { max-width: 1080px; margin: 0 auto; display: flex; justify-content: center; gap: 2.5rem; flex-wrap: wrap; padding: 0 1.5rem; }
.trust-item { font-size: 0.9rem; color: var(--text-dim); white-space: nowrap; }

/* Sections */
.section { max-width: 1080px; margin: 0 auto; padding: 4rem 1.5rem; }
.section h2 { font-size: 1.8rem; text-align: center; margin-bottom: 0.75rem; }
.section-sub { text-align: center; color: var(--text-dim); margin-bottom: 2.5rem; max-width: 600px; margin-left: auto; margin-right: auto; }
.section-dark { background: var(--bg-section); max-width: none; padding-left: calc((100% - 1080px) / 2 + 1.5rem); padding-right: calc((100% - 1080px) / 2 + 1.5rem); }

/* Steps */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2rem; }
.step { text-align: center; }
.step-num { display: inline-flex; width: 2.5rem; height: 2.5rem; border-radius: 50%; background: var(--primary); color: #fff; font-weight: 700; align-items: center; justify-content: center; margin-bottom: 0.75rem; font-size: 1.1rem; }
.step h3 { margin-bottom: 0.5rem; font-size: 1rem; }
.step p { color: var(--text-dim); font-size: 0.9rem; }

/* Features */
.features { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem; max-width: 1080px; margin: 0 auto; }
.feature { background: var(--bg-card); border: 1px solid var(--border); border-radius: 8px; padding: 1.25rem; }
.feature h3 { font-size: 0.95rem; margin-bottom: 0.5rem; }
.feature p { color: var(--text-dim); font-size: 0.85rem; }

/* Story / origin */
.story-section { padding-top: 2.5rem; padding-bottom: 2.5rem; }
.story { max-width: 640px; margin: 0 auto; text-align: center; }
.story h2 { font-size: 1.4rem; font-weight: 700; margin-bottom: 1rem; }
.story p { font-size: 0.95rem; color: var(--text-dim); line-height: 1.8; }
.story strong { color: var(--text); font-weight: 600; }

/* Pricing */
.pricing-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 1rem; }
.price-card { background: var(--bg-card); border: 1px solid var(--border); border-radius: 10px; padding: 1.5rem; text-align: center; position: relative; display: flex; flex-direction: column; }
.price-card.popular { border-color: var(--primary); }
.popular-tag { position: absolute; top: -0.7rem; left: 50%; transform: translateX(-50%); background: var(--primary); color: #fff; padding: 0.15rem 0.75rem; border-radius: 10px; font-size: 0.7rem; font-weight: 600; white-space: nowrap; }
.price-card h3 { font-size: 1.1rem; margin-bottom: 0.5rem; }
.price { font-size: 2rem; font-weight: 800; margin-bottom: 1rem; }
.price span { font-size: 0.85rem; font-weight: 400; color: var(--text-dim); }
.price-card ul { list-style: none; text-align: left; margin-bottom: 1.5rem; flex: 1; }
.price-card .btn-primary { font-size: 0.82rem; margin-top: auto; }
.price-card li { font-size: 0.8rem; color: var(--text-dim); padding: 0.25rem 0; border-bottom: 1px solid var(--border); }
.price-card li:last-child { border-bottom: none; }
.pricing-note { text-align: center; color: var(--text-dim); font-size: 0.85rem; margin-top: 1.5rem; }

/* Comparison */
.comparison { max-width: 700px; margin: 0 auto; overflow-x: auto; }
.comparison table { width: 100%; border-collapse: collapse; font-size: 0.9rem; }
.comparison th, .comparison td { padding: 0.6rem 1rem; border-bottom: 1px solid var(--border); text-align: left; }
.comparison th { color: var(--text-dim); font-weight: 500; }
.comparison th:not(:first-child) { text-align: center; }
.comparison td:not(:first-child) { text-align: center; }
.yes { color: var(--success); font-weight: 600; }
.no { color: var(--danger); }

/* FAQ / SEO content */
.seo-faq { border-top: 1px solid var(--border); padding-top: 3rem; padding-bottom: 3rem; }
.faq-heading { font-size: 1.3rem; color: var(--text-dim); font-weight: 500; margin-bottom: 1.5rem; }
.faq-list { max-width: 800px; margin: 0 auto; }
.faq-item { border-bottom: 1px solid var(--border); }
.faq-item summary { padding: 0.9rem 0; cursor: pointer; font-size: 0.88rem; color: var(--text-dim); list-style: none; display: flex; justify-content: space-between; align-items: center; }
.faq-item summary::after { content: '+'; font-size: 1.1rem; color: var(--text-dim); flex-shrink: 0; margin-left: 1rem; transition: transform 0.2s; }
.faq-item[open] summary::after { content: '\2212'; }
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary:hover { color: var(--text); }
.faq-answer { padding: 0 0 1.25rem; font-size: 0.82rem; color: var(--text-dim); line-height: 1.75; opacity: 0.8; }

/* Footer */
.footer { border-top: 1px solid var(--border); padding: 2rem 0; }
.footer-inner { max-width: 1080px; margin: 0 auto; padding: 0 1.5rem; display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 1rem; }
.footer-brand { font-weight: 700; }
.footer-links { display: flex; gap: 1.5rem; }
.footer-links a { color: var(--text-dim); text-decoration: none; font-size: 0.85rem; }
.footer-links a:hover { color: var(--text); }
.footer-note { color: var(--text-dim); font-size: 0.8rem; }

@media (max-width: 1100px) {
  .pricing-grid { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 900px) {
  .pricing-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
  .hero h1 { font-size: 1.8rem; }
  .steps { grid-template-columns: 1fr; }
  .features { grid-template-columns: 1fr; }
  .pricing-grid { grid-template-columns: 1fr; }
  .trust-inner { flex-direction: column; align-items: center; gap: 0.5rem; }
  .footer-inner { flex-direction: column; text-align: center; }
}

/* Problem section */
.problem-section { padding-top: 3.5rem; padding-bottom: 3.5rem; }
.problems { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.5rem; max-width: 1080px; margin: 1.5rem auto 0; }
.problem-item { text-align: center; padding: 1.25rem; }
.problem-icon { font-size: 2rem; margin-bottom: 0.75rem; }
.problem-item h3 { font-size: 0.95rem; margin-bottom: 0.5rem; }
.problem-item p { color: var(--text-dim); font-size: 0.85rem; }

@media (max-width: 768px) {
  .problems { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 480px) {
  .problems { grid-template-columns: 1fr; }
}

/* Before & After */
.before-after-section { padding-top: 3rem; padding-bottom: 3rem; }
.code-compare { display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem; max-width: 1080px; margin: 0 auto; }
.code-panel { background: var(--bg-card); border: 1px solid var(--border); border-radius: 10px; overflow: hidden; }
.code-label { padding: 0.6rem 1rem; font-size: 0.8rem; font-weight: 600; display: flex; align-items: center; gap: 0.5rem; border-bottom: 1px solid var(--border); }
.label-dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; }
.dot-red { background: var(--danger); }
.dot-green { background: var(--success); }
.label-bad { color: var(--danger); }
.label-good { color: var(--success); }
.code-block { padding: 1rem; font-size: 0.72rem; line-height: 1.6; color: var(--text-dim); overflow-x: auto; margin: 0; background: transparent; font-family: 'SF Mono', 'Fira Code', 'Consolas', monospace; }
.hl-bad { color: var(--danger); }
.hl-good { color: var(--success); }
.hl-dim { color: #4b5064; }
.code-checks { list-style: none; padding: 0.75rem 1rem; font-size: 0.78rem; border-top: 1px solid var(--border); }
.code-checks li { padding: 0.15rem 0; }
.checks-bad { color: var(--danger); }
.checks-good { color: var(--success); }
@media (max-width: 768px) { .code-compare { grid-template-columns: 1fr; } }

/* Crawler Test */
.crawler-test-section { padding-top: 3rem; padding-bottom: 3rem; }
.test-box { max-width: 640px; margin: 0 auto; }
.test-form { display: flex; gap: 0.5rem; margin-bottom: 1rem; }
.test-input { flex: 1; background: var(--bg-card); border: 1px solid var(--border); border-radius: 8px; padding: 0.7rem 1rem; color: var(--text); font-size: 0.95rem; outline: none; }
.test-input:focus { border-color: var(--primary); }
.test-btn { white-space: nowrap; flex-shrink: 0; }
.test-results { background: var(--bg-card); border: 1px solid var(--border); border-radius: 10px; padding: 1.5rem; }
.test-result-grid { display: grid; grid-template-columns: auto 1fr; gap: 1.5rem; margin-bottom: 1.25rem; }
.test-score-card { text-align: center; }
.test-score { font-size: 3rem; font-weight: 800; line-height: 1; }
.test-score span { font-size: 1.2rem; color: var(--text-dim); }
.test-score-sub { font-size: 0.8rem; color: var(--text-dim); margin-top: 0.25rem; }
.test-details { font-size: 0.85rem; }
.test-meta { color: var(--text-dim); margin-bottom: 0.4rem; word-break: break-all; }
.test-meta strong { color: var(--text); }
.test-issue-count { color: var(--danger); font-weight: 600; margin-bottom: 0.4rem; }
.test-issue-list { list-style: none; padding: 0; }
.test-issue-list li { color: var(--text-dim); font-size: 0.8rem; padding: 0.2rem 0; }
.test-issue-list li::before { content: '\2022'; color: var(--danger); margin-right: 0.4rem; }
.test-pass { color: var(--success); font-weight: 600; }
.test-email-section { border-top: 1px solid var(--border); padding-top: 1rem; margin-bottom: 1rem; }
.test-email-label { font-size: 0.9rem; color: var(--text); margin-bottom: 0.5rem; }
.test-email-row { display: flex; gap: 0.5rem; margin-bottom: 0.5rem; }
.test-consent-label { font-size: 0.75rem; color: var(--text-dim); display: flex; align-items: center; gap: 0.4rem; cursor: pointer; }
.test-consent-label input { accent-color: var(--primary); }
.test-code-input { max-width: 140px; text-align: center; font-size: 1.2rem; letter-spacing: 0.3em; }
.test-sent { color: var(--success); font-weight: 600; font-size: 0.95rem; padding: 0.5rem 0; }
.test-error { color: var(--danger); font-size: 0.9rem; padding: 0.5rem 0; }
.test-cta-row { display: flex; align-items: center; gap: 1rem; justify-content: center; flex-wrap: wrap; font-size: 0.9rem; color: var(--text-dim); }
@media (max-width: 640px) { .test-form { flex-direction: column; } .test-result-grid { grid-template-columns: 1fr; text-align: center; } .test-email-row { flex-direction: column; } }

/* Final CTA */
.final-cta-section { padding-top: 3.5rem; padding-bottom: 3.5rem; }
.final-cta { text-align: center; max-width: 600px; margin: 0 auto; }
.final-cta h2 { font-size: 2rem; margin-bottom: 0.75rem; }
.final-cta-sub { color: var(--text-dim); font-size: 1.05rem; margin-bottom: 2rem; }

/* Cookie Consent Banner */
.cookie-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 10000;
  background: var(--bg-card);
  border-top: 1px solid var(--border);
  box-shadow: 0 -4px 20px rgba(0,0,0,0.4);
  padding: 1rem 1.5rem;
  animation: slideUp 0.3s ease-out;
}

@keyframes slideUp {
  from { transform: translateY(100%); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}

.cookie-inner {
  max-width: 900px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 1rem;
}

.cookie-inner p {
  flex: 1;
  font-size: 0.82rem;
  color: var(--text-dim);
  line-height: 1.5;
}

.cookie-actions {
  display: flex;
  gap: 0.5rem;
  align-items: center;
  flex-shrink: 0;
}

.btn-sm {
  padding: 0.35rem 0.75rem;
  font-size: 0.8rem;
  border-radius: 6px;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text);
  cursor: pointer;
}

.btn-sm:hover {
  background: var(--bg-card);
}

.cookie-link {
  font-size: 0.75rem;
  color: var(--text-dim);
  text-decoration: underline;
  white-space: nowrap;
}

@media (max-width: 640px) {
  .cookie-inner {
    flex-direction: column;
    text-align: center;
  }
  .cookie-actions {
    justify-content: center;
  }
}
