/* Permit Intelligence — homepage styles
   Hybrid institutional + SaaS aesthetic.
*/

:root {
  --bg:        oklch(0.985 0.003 85);   /* warm off-white paper */
  --bg-alt:    oklch(0.965 0.005 85);   /* slightly darker panel */
  --bg-deep:   oklch(0.18 0.01 250);    /* near-black ink for proof section */
  --ink:       oklch(0.22 0.01 250);
  --ink-soft:  oklch(0.38 0.01 250);
  --mute:      oklch(0.55 0.01 250);
  --hairline:  oklch(0.88 0.005 250);
  --hairline-strong: oklch(0.78 0.005 250);

  --blue:        oklch(0.45 0.13 250);
  --blue-soft:   oklch(0.78 0.06 250);
  --orange:      oklch(0.68 0.16 50);
  --green:       oklch(0.72 0.14 145);
  --amber:       oklch(0.78 0.14 75);
  --gray-soft:   oklch(0.82 0.005 250);
  --red:         oklch(0.6 0.18 25);

  --serif: "Source Serif 4", "Source Serif Pro", "Iowan Old Style", Georgia, serif;
  --sans:  "Inter Tight", "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  --mono:  "JetBrains Mono", "IBM Plex Mono", ui-monospace, "SF Mono", Menlo, monospace;

  --maxw: 1240px;
  --pad-x: clamp(20px, 4vw, 56px);
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: var(--sans);
  background: var(--bg);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  font-size: 16px;
  line-height: 1.55;
  font-feature-settings: "ss01", "cv11";
}

a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }
::selection { background: var(--ink); color: var(--bg); }

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

.serif { font-family: var(--serif); font-weight: 400; }
.mono  { font-family: var(--mono); }
.small { font-size: 12px; letter-spacing: 0.04em; }
.mute  { color: var(--mute); }

.eyebrow {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--mute);
  margin-bottom: 18px;
}
.eyebrow.light { color: oklch(0.7 0.01 250); }

.section-title {
  font-size: clamp(32px, 4.2vw, 52px);
  line-height: 1.05;
  letter-spacing: -0.02em;
  margin: 0 0 16px;
  color: var(--ink);
  text-wrap: balance;
}
.section-title.light { color: var(--bg); }

.section-sub {
  font-size: 17px;
  color: var(--ink-soft);
  max-width: 56ch;
  margin: 0;
}

.section-head {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 32px;
  margin-bottom: 56px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--hairline);
}
.section-head.center {
  flex-direction: column;
  align-items: center;
  text-align: center;
  border-bottom: none;
  padding-bottom: 0;
  margin-bottom: 48px;
}
.head-l { flex: 1; }
.head-r { flex-shrink: 0; padding-bottom: 8px; }

.prose {
  font-size: 17px;
  line-height: 1.65;
  color: var(--ink-soft);
  max-width: 60ch;
  margin: 0 0 18px;
}

.link-arrow {
  font-size: 14px;
  color: var(--ink);
  border-bottom: 1px solid var(--hairline-strong);
  padding-bottom: 2px;
  transition: border-color 0.15s;
}
.link-arrow:hover { border-color: var(--ink); }
.link-arrow .arrow { display: inline-block; transition: transform 0.2s; margin-left: 4px; }
.link-arrow:hover .arrow { transform: translateX(3px); }

/* ---------- NAV ---------- */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: oklch(0.985 0.003 85 / 0.85);
  backdrop-filter: saturate(150%) blur(12px);
  border-bottom: 1px solid var(--hairline);
}
.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
  gap: 32px;
}
.logo { display: inline-flex; align-items: center; gap: 10px; }
.logo-mark {
  width: 28px; height: 28px;
  background: var(--ink);
  color: var(--bg);
  border-radius: 4px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.02em;
}
.logo-text { font-size: 18px; letter-spacing: -0.01em; }

.nav-links {
  display: flex;
  gap: 28px;
  font-size: 14px;
  color: var(--ink-soft);
}
.nav-links a:hover { color: var(--ink); }

.nav-right { display: flex; align-items: center; gap: 14px; }

.theme-toggle,
.lang-toggle {
  background: transparent;
  border: 1px solid var(--hairline);
  border-radius: 999px;
  padding: 5px 10px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: var(--mute);
  transition: border-color 0.15s, color 0.15s;
}
.theme-toggle:hover,
.lang-toggle:hover { border-color: var(--ink-soft); }
.theme-toggle .active,
.lang-toggle .active { color: var(--ink); font-weight: 600; }
.theme-toggle .lang-sep,
.lang-toggle .lang-sep { color: var(--hairline-strong); }

.nav-cta-ghost {
  font-size: 14px;
  color: var(--ink);
  padding: 8px 14px;
  border-radius: 6px;
  transition: background 0.15s;
}
.nav-cta-ghost:hover { background: var(--bg-alt); }

.nav-cta {
  font-size: 14px;
  font-weight: 500;
  padding: 9px 16px;
  border-radius: 6px;
  transition: opacity 0.15s, transform 0.15s;
}
.nav-cta:hover { opacity: 0.92; transform: translateY(-1px); }

/* ---------- HERO ---------- */
.hero {
  padding: clamp(56px, 8vw, 96px) 0 clamp(48px, 7vw, 80px);
  border-bottom: 1px solid var(--hairline);
  position: relative;
  overflow: hidden;
}
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(to right, oklch(0.88 0.005 250 / 0.4) 1px, transparent 1px);
  background-size: calc(100% / 12) 100%;
  pointer-events: none;
  mask-image: linear-gradient(to bottom, black, transparent);
}
.hero-grid {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: clamp(32px, 5vw, 64px);
  align-items: start;
  position: relative;
}
.hero-text { padding-top: 16px; }
.hero-headline {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(44px, 6vw, 76px);
  line-height: 1.0;
  letter-spacing: -0.025em;
  margin: 8px 0 28px;
  color: var(--ink);
  text-wrap: balance;
}
.headline-line { display: block; }
.headline-emph {
  font-style: italic;
  color: var(--ink);
  position: relative;
}
.hero-sub {
  font-size: 19px;
  line-height: 1.55;
  color: var(--ink-soft);
  max-width: 52ch;
  margin: 0 0 32px;
}

.hero-ctas {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 32px;
}

.btn {
  font-size: 15px;
  font-weight: 500;
  padding: 13px 22px;
  border-radius: 8px;
  border: 1px solid transparent;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: transform 0.15s, opacity 0.15s, background 0.15s;
}
.btn:hover { transform: translateY(-1px); }
.btn .arrow { display: inline-block; transition: transform 0.2s; }
.btn:hover .arrow { transform: translateX(3px); }
.btn-primary { /* color set inline */ }
.btn-ghost {
  background: transparent;
  border-color: var(--hairline-strong);
  color: var(--ink);
}
.btn-ghost:hover { background: var(--bg-alt); }

.hero-foot {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  font-size: 13px;
  color: var(--mute);
  font-family: var(--mono);
}
.foot-item { display: inline-flex; align-items: center; gap: 6px; }
.foot-sep { color: var(--hairline-strong); }
.dot.live {
  width: 7px; height: 7px;
  background: var(--green);
  border-radius: 999px;
  display: inline-block;
  box-shadow: 0 0 0 3px oklch(0.72 0.14 145 / 0.18);
  animation: pulse 2.4s ease-in-out infinite;
}
@keyframes pulse {
  0%, 100% { box-shadow: 0 0 0 3px oklch(0.72 0.14 145 / 0.18); }
  50% { box-shadow: 0 0 0 6px oklch(0.72 0.14 145 / 0.05); }
}

/* ---------- HERO WIDGET ---------- */
.hero-aside {
  position: relative;
  padding-top: 0;
}
.hero-widget {
  background: var(--bg);
  border: 1px solid var(--hairline-strong);
  border-radius: 12px;
  padding: 20px 22px 22px 22px;
  box-shadow:
    0 1px 0 0 oklch(1 0 0) inset,
    0 30px 60px -30px oklch(0.18 0.01 250 / 0.18),
    0 8px 20px -10px oklch(0.18 0.01 250 / 0.08);
}
.widget-head {
  display: flex;
  justify-content: space-between;
  align-items: start;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--hairline);
  margin-bottom: 18px;
}
.widget-title { font-size: 15px; font-weight: 600; color: var(--ink); }
.widget-sub { font-size: 13px; color: var(--mute); margin-top: 2px; }
.widget-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.04em;
  color: var(--ink-soft);
  background: var(--bg-alt);
  border: 1px solid var(--hairline);
  padding: 4px 8px;
  border-radius: 999px;
}

.widget-form {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 18px;
}
.field { display: flex; flex-direction: column; gap: 6px; }
.field-units { grid-column: span 1; }
.field-label {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--mute);
}
.field-input {
  font-family: var(--sans);
  font-size: 14px;
  color: var(--ink);
  background: var(--bg-alt);
  border: 1px solid var(--hairline);
  border-radius: 6px;
  padding: 10px 12px;
  outline: none;
  transition: border-color 0.15s, background 0.15s;
}
.field-input:focus { border-color: var(--ink); background: var(--bg); }

.widget-cta {
  grid-column: span 2;
  font-size: 14px;
  font-weight: 500;
  border: none;
  border-radius: 6px;
  padding: 12px 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: opacity 0.15s, transform 0.15s;
}
.widget-cta:hover { opacity: 0.92; }
.widget-cta .arrow { transition: transform 0.2s; }
.widget-cta:hover .arrow { transform: translateX(3px); }

.widget-result {
  background: var(--bg-alt);
  border: 1px solid var(--hairline);
  border-radius: 8px;
  padding: 14px 16px;
}
.result-row {
  display: grid;
  grid-template-columns: 88px 1fr;
  gap: 12px;
  padding: 8px 0;
  border-bottom: 1px dashed var(--hairline);
  align-items: center;
}
.result-row:last-child { border-bottom: none; }
.result-key {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--mute);
}
.result-val { font-size: 14px; color: var(--ink); }
.result-val.mono { font-family: var(--mono); font-size: 13px; }
.result-val.small { font-size: 12px; }
.src-link { color: var(--mute); margin-left: 6px; }

.result-empty { padding: 8px 0; }
.empty-line { font-size: 14px; color: var(--ink); }
.empty-sub { font-size: 12px; color: var(--mute); margin-top: 4px; }

/* Document Checklist Widget (hero right column) */
.checklist-muni-tag {
  font-weight: 400;
  color: var(--ink-soft);
  margin-left: 6px;
  font-size: 13px;
}

.checklist-body {
  padding: 4px 0 12px;
  min-height: 148px;
  transition: opacity 0.3s ease;
}
.checklist-clearing { opacity: 0; }

.checklist-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 7px 0;
  border-bottom: 1px solid var(--hairline);
  opacity: 0;
  transform: translateY(4px);
  transition: opacity 0.22s ease, transform 0.22s ease;
}
.checklist-item:last-child { border-bottom: none; }
.checklist-item.checklist-visible {
  opacity: 1;
  transform: translateY(0);
}
.checklist-item.checklist-loading { opacity: 0.45; }

.checklist-check {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  border-radius: 4px;
  background: oklch(0.72 0.14 145 / 0.12);
  flex-shrink: 0;
}
.checklist-item.checklist-loading .checklist-check {
  background: var(--hairline);
}

.checklist-label {
  font-size: 13.5px;
  color: var(--ink);
  flex: 1;
  line-height: 1.3;
}
.checklist-ref {
  color: var(--mute);
  white-space: nowrap;
}

/* Spinner for loading item */
.checklist-spinner {
  display: inline-block;
  width: 8px;
  height: 8px;
  border: 1.5px solid var(--hairline-strong);
  border-top-color: var(--ink-soft);
  border-radius: 999px;
  animation: spin 0.6s linear infinite;
}

/* Footer row */
.checklist-footer {
  display: flex;
  align-items: center;
  gap: 7px;
  padding-top: 10px;
  border-top: 1px solid var(--hairline);
}
.checklist-status-dot {
  width: 7px;
  height: 7px;
  border-radius: 999px;
  flex-shrink: 0;
}
.checklist-status-text { color: var(--ink-soft); }
.checklist-footer-sep { color: var(--hairline-strong); }

/* ---------- STATS ---------- */
.stats {
  padding: clamp(56px, 8vw, 96px) 0;
  border-bottom: 1px solid var(--hairline);
}
.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border-top: 1px solid var(--hairline);
  border-left: 1px solid var(--hairline);
}
.stat {
  border-right: 1px solid var(--hairline);
  border-bottom: 1px solid var(--hairline);
  padding: 28px 24px;
  background: var(--bg);
}
.stat-value {
  font-size: clamp(48px, 5.5vw, 72px);
  line-height: 1;
  letter-spacing: -0.03em;
  margin-bottom: 12px;
}
.stat-label {
  font-size: 14px;
  color: var(--ink-soft);
  max-width: 22ch;
}
.stats-legend {
  display: flex;
  align-items: center;
  gap: 24px;
  flex-wrap: wrap;
  margin-top: 24px;
  font-size: 13px;
  color: var(--ink-soft);
}
.legend-item { display: inline-flex; align-items: center; gap: 8px; }
.legend-dot { width: 10px; height: 10px; border-radius: 999px; display: inline-block; }
.dot-green { background: var(--green); }
.dot-amber { background: var(--amber); }
.dot-gray  { background: var(--gray-soft); }
.legend-spacer { flex: 1; }
.legend-link { color: var(--ink); border-bottom: 1px solid var(--hairline-strong); padding-bottom: 2px; font-size: 13px; }
.legend-link:hover { border-color: var(--ink); }

/* ---------- PROBLEM ---------- */
.problem {
  padding: clamp(56px, 8vw, 96px) 0;
  border-bottom: 1px solid var(--hairline);
  background: var(--bg-alt);
}
.problem-grid {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: clamp(32px, 5vw, 80px);
  align-items: start;
}
.problem-text .section-title { margin-bottom: 24px; }

.cost-card {
  background: var(--bg);
  border: 1px solid var(--hairline-strong);
  border-radius: 12px;
  padding: 28px;
  position: sticky;
  top: 88px;
}
.cost-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--hairline);
  margin-bottom: 8px;
}
.cost-title { font-size: 15px; font-weight: 600; color: var(--ink); }
.cost-tag {
  color: var(--mute);
  background: var(--bg-alt);
  padding: 3px 8px;
  border-radius: 4px;
}
.cost-list { padding: 6px 0; }
.cost-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 0;
  border-bottom: 1px dashed var(--hairline);
}
.cost-row:last-child { border-bottom: none; }
.cost-label { font-size: 14px; color: var(--ink); font-weight: 500; }
.cost-note  { font-size: 12px; color: var(--mute); margin-top: 2px; }
.cost-value { font-size: 22px; letter-spacing: -0.02em; color: var(--ink); white-space: nowrap; }

.cost-foot {
  margin-top: 14px;
  padding-top: 18px;
  border-top: 1px solid var(--ink);
  display: flex;
  justify-content: space-between;
  align-items: baseline;
}
.cost-foot-label { font-size: 13px; color: var(--ink); font-weight: 600; max-width: 18ch; }
.cost-foot-value {
  font-size: 32px;
  letter-spacing: -0.02em;
  color: var(--orange);
}

/* ---------- HOW ---------- */
.how {
  padding: clamp(56px, 8vw, 96px) 0;
  border-bottom: 1px solid var(--hairline);
}
.how-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
  border-top: 1px solid var(--hairline);
}
.how-step {
  padding: 32px 28px 32px 0;
  border-right: 1px solid var(--hairline);
  position: relative;
}
.how-step:last-child { border-right: none; padding-right: 0; }
.how-step:not(:first-child) { padding-left: 28px; }
.step-n {
  font-size: 12px;
  letter-spacing: 0.1em;
  color: var(--mute);
  margin-bottom: 24px;
}
.step-title {
  font-size: 28px;
  letter-spacing: -0.02em;
  margin-bottom: 12px;
  color: var(--ink);
}
.step-body {
  font-size: 15px;
  line-height: 1.55;
  color: var(--ink-soft);
  margin-bottom: 18px;
  max-width: 32ch;
}
.step-tag {
  display: inline-block;
  color: var(--mute);
  background: var(--bg-alt);
  padding: 4px 8px;
  border-radius: 4px;
  border: 1px solid var(--hairline);
}

/* ---------- PROOF ---------- */
.proof {
  padding: clamp(64px, 9vw, 120px) 0;
  background: var(--bg-deep);
  color: var(--bg);
}
.proof-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: clamp(32px, 6vw, 80px);
  align-items: start;
}
.proof-quote {
  font-family: var(--serif);
  font-size: clamp(28px, 3vw, 38px);
  line-height: 1.25;
  letter-spacing: -0.015em;
  color: oklch(0.90 0.005 250);
  margin: 28px 0 28px;
  text-wrap: balance;
}
.quote-mark {
  font-family: var(--serif);
  color: var(--ink-soft);
  font-size: 1em;
  margin-right: 4px;
}
.quote-mark.close { margin-left: 4px; margin-right: 0; }

.proof-attr {
  border-top: 1px solid var(--hairline);
  padding-top: 16px;
  display: flex;
  align-items: baseline;
  gap: 16px;
}
.attr-line { font-size: 14px; color: oklch(0.85 0.005 250); }
.attr-note { color: oklch(0.85 0.005 250); }

.proof-sources {
  background: var(--bg-deep);
  border: 1px solid var(--hairline-strong);
  border-radius: 12px;
  padding: 28px;
  margin-top: 64px;
}
.sources-title {
  font-size: 15px;
  font-weight: 600;
  color: oklch(0.85 0.005 250);
  margin-bottom: 12px;
}
.sources-body {
  font-size: 14px;
  line-height: 1.6;
  color: oklch(0.75 0.005 250);
  margin: 0 0 18px;
}
.sources-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
  color: oklch(0.75 0.005 250);
}
.sources-list li { display: inline-flex; align-items: center; gap: 8px; }
.src-bullet { color: oklch(0.75 0.005 250); }

/* ---------- PRICING ---------- */
.pricing {
  padding: clamp(64px, 9vw, 120px) 0;
  border-bottom: 1px solid var(--hairline);
}
.tiers {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  align-items: stretch;
}
.tier {
  background: var(--bg);
  border: 1px solid var(--hairline-strong);
  border-radius: 12px;
  padding: 32px 28px;
  display: flex;
  flex-direction: column;
  position: relative;
  transition: transform 0.2s, box-shadow 0.2s;
}
.tier:hover { transform: translateY(-2px); box-shadow: 0 12px 30px -16px oklch(0.18 0.01 250 / 0.15); }
.tier-accent {
  background: var(--bg-deep);
  border-color: var(--bg-deep);
  color: var(--bg);
}
.tier-flag {
  position: absolute;
  top: -10px;
  left: 28px;
  background: var(--orange);
  color: #fff;
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 4px 10px;
  border-radius: 999px;
}
.tier-name {
  font-size: 13px;
  font-family: var(--mono);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--mute);
  margin-bottom: 18px;
}
.tier-accent .tier-name { color: oklch(0.7 0.01 250); }
.tier-price-row {
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin-bottom: 12px;
}
.tier-price {
  font-size: 44px;
  letter-spacing: -0.025em;
  line-height: 1;
}
.tier-period { color: var(--mute); }
.tier-accent .tier-period { color: oklch(0.7 0.01 250); }
.tier-desc {
  font-size: 14px;
  color: var(--ink-soft);
  margin-bottom: 22px;
  min-height: 42px;
}
.tier-accent .tier-desc { color: oklch(0.75 0.005 250); }
.tier-features {
  list-style: none;
  padding: 0;
  margin: 0 0 24px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  font-size: 14px;
  flex: 1;
}
.tier-features li { display: flex; align-items: start; gap: 10px; }
.check {
  color: var(--green);
  font-weight: 700;
  flex-shrink: 0;
  width: 16px;
}
.tier-accent .check { color: oklch(0.85 0.12 145); }
.tier-accent .tier-price { color: oklch(0.85 0.005 250); }
.tier-accent .tier-features li { color: oklch(0.75 0.005 250); }

.tier-cta {
  font-size: 14px;
  font-weight: 500;
  background: transparent;
  color: var(--ink);
  border: 1px solid var(--hairline-strong);
  border-radius: 8px;
  padding: 12px 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: background 0.15s, opacity 0.15s, transform 0.15s;
}
.tier-cta:hover { background: var(--bg-alt); transform: translateY(-1px); }
.tier-accent .tier-cta { color: oklch(0.85 0.005 250); border-color: oklch(0.4 0.01 250); }
.tier-accent .tier-cta:hover { background: oklch(0.25 0.01 250); }
.tier-cta .arrow { transition: transform 0.2s; }
.tier-cta:hover .arrow { transform: translateX(3px); }

/* ---------- FAQ ---------- */
.faq {
  padding: clamp(64px, 9vw, 120px) 0;
  border-bottom: 1px solid var(--hairline);
}
.faq-grid {
  display: grid;
  grid-template-columns: 1fr 1.6fr;
  gap: clamp(32px, 6vw, 80px);
  align-items: start;
}
.faq-head .section-title { margin-bottom: 24px; }
.link-arrow.small { font-size: 13px; }

.faq-list { border-top: 1px solid var(--hairline); }
.faq-item { border-bottom: 1px solid var(--hairline); }
.faq-q {
  width: 100%;
  background: transparent;
  border: none;
  text-align: left;
  padding: 22px 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  font-size: 17px;
  color: var(--ink);
  font-family: var(--sans);
  transition: opacity 0.15s;
}
.faq-q:hover { opacity: 0.7; }
.faq-q-text { font-weight: 500; }
.faq-toggle {
  font-size: 20px;
  font-family: var(--serif);
  color: var(--mute);
  flex-shrink: 0;
}
.faq-a {
  padding: 0 0 22px;
  max-width: 64ch;
  font-size: 15px;
}

/* ---------- FOOTER ---------- */
.footer {
  padding: 64px 0 32px;
  background: var(--bg-alt);
}
.footer-top {
  display: grid;
  grid-template-columns: 1.2fr 2.4fr;
  gap: 48px;
  padding-bottom: 48px;
  border-bottom: 1px solid var(--hairline);
}
.footer-brand .brand-mark {
  width: 32px; height: 32px;
  background: var(--ink); color: var(--bg);
  border-radius: 5px;
  display: inline-flex; align-items: center; justify-content: center;
  font-family: var(--mono); font-size: 12px; font-weight: 600;
  margin-bottom: 12px;
}
.brand-name { font-size: 18px; margin-bottom: 8px; }
.footer-tagline {
  font-size: 14px;
  color: var(--ink-soft);
  max-width: 32ch;
  margin: 0;
}
.footer-cols {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 32px;
}
.footer-col-title {
  color: var(--mute);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 14px;
}
.footer-col ul {
  list-style: none;
  padding: 0; margin: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.footer-col a {
  font-size: 14px;
  color: var(--ink-soft);
  transition: color 0.15s;
}
.footer-col a:hover { color: var(--ink); }
.footer-bottom {
  padding-top: 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  flex-wrap: wrap;
}
.footer-legal { color: var(--mute); }
.footer-disclaimer { font-size: 12px; color: var(--mute); max-width: 60ch; }

/* ---------- RESPONSIVE ---------- */
@media (max-width: 960px) {
  .hero-grid,
  .problem-grid,
  .proof-grid,
  .faq-grid,
  .footer-top { grid-template-columns: 1fr; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .how-grid { grid-template-columns: 1fr; }
  .how-step { border-right: none; border-bottom: 1px solid var(--hairline); padding: 28px 0; }
  .how-step:last-child { border-bottom: none; }
  .how-step:not(:first-child) { padding-left: 0; }
  .tiers { grid-template-columns: 1fr; }
  .footer-cols { grid-template-columns: repeat(2, 1fr); }
  .nav-links { display: none; }
  .cost-card { position: static; }
}
@media (max-width: 540px) {
  .stats-grid { grid-template-columns: 1fr; }
  .footer-cols { grid-template-columns: 1fr; }
  .nav-cta-ghost { display: none; }
  .widget-form { grid-template-columns: 1fr; }
  .widget-cta { grid-column: span 1; }
  .section-head { flex-direction: column; align-items: start; }
}

/* ---------- AESTHETIC MODES (Tweaks) ---------- */
body[data-aesthetic="institutional"] {
  --bg: oklch(0.99 0.002 250);
  --bg-alt: oklch(0.97 0.003 250);
}
body[data-aesthetic="institutional"] .hero-headline,
body[data-aesthetic="institutional"] .section-title {
  font-style: normal;
}
body[data-aesthetic="institutional"] .headline-emph { font-style: normal; }

body[data-aesthetic="saas"] .hero-headline,
body[data-aesthetic="saas"] .section-title,
body[data-aesthetic="saas"] .stat-value,
body[data-aesthetic="saas"] .tier-price,
body[data-aesthetic="saas"] .step-title,
body[data-aesthetic="saas"] .proof-quote,
body[data-aesthetic="saas"] .cost-value,
body[data-aesthetic="saas"] .cost-foot-value,
body[data-aesthetic="saas"] .brand-name,
body[data-aesthetic="saas"] .logo-text {
  font-family: var(--sans);
  letter-spacing: -0.025em;
  font-weight: 600;
}
body[data-aesthetic="saas"] .headline-emph { font-style: normal; }

body[data-aesthetic="editorial"] .hero-headline,
body[data-aesthetic="editorial"] .section-title {
  letter-spacing: -0.035em;
}
body[data-aesthetic="editorial"] .hero-headline { font-size: clamp(56px, 8vw, 96px); line-height: 0.95; }
body[data-aesthetic="editorial"] .headline-emph { font-style: italic; }

/* ---------- TWEAKS: dynamic CSS-var driven layers ---------- */

/* Type scale (multiplier) */
.hero-headline { font-size: calc(clamp(44px, 6vw, 76px) * var(--scale, 1)); }
.section-title { font-size: calc(clamp(32px, 4.2vw, 52px) * var(--scale, 1)); }
.stat-value    { font-size: calc(clamp(48px, 5.5vw, 72px) * var(--scale, 1)); }
.proof-quote   { font-size: calc(clamp(28px, 3vw, 38px) * var(--scale, 1)); }
.tier-price    { font-size: calc(44px * var(--scale, 1)); }
.step-title    { font-size: calc(28px * var(--scale, 1)); }

/* Radius cascade */
.nav-cta, .nav-cta-ghost, .btn, .field-input, .widget-cta, .step-tag, .cost-tag,
.faq-item, .footer-brand .brand-mark { border-radius: calc(var(--radius-base, 8px) * 0.85); }
.hero-widget, .cost-card, .tier, .proof-sources, .widget-result, .logo-mark {
  border-radius: calc(var(--radius-base, 8px) * 1.4);
}

/* Italic emphasis toggle */
body[data-italic="no"] .headline-emph { font-style: normal; }
body[data-italic="yes"] .headline-emph { font-style: italic; }

/* Uppercase eyebrows toggle */
body[data-uppercase="no"] .eyebrow,
body[data-uppercase="no"] .field-label,
body[data-uppercase="no"] .result-key,
body[data-uppercase="no"] .tier-name,
body[data-uppercase="no"] .footer-col-title {
  text-transform: none;
  letter-spacing: 0.02em;
}

/* Bordered sections toggle (already on by default) */
body[data-bordered="no"] .nav,
body[data-bordered="no"] .hero,
body[data-bordered="no"] .stats,
body[data-bordered="no"] .problem,
body[data-bordered="no"] .how,
body[data-bordered="no"] .pricing,
body[data-bordered="no"] .faq {
  border-bottom: none;
}
body[data-bordered="no"] .stats-grid,
body[data-bordered="no"] .how-grid {
  border-top: none;
}
body[data-bordered="no"] .stat,
body[data-bordered="no"] .how-step {
  border-right: none;
  border-bottom: none;
}
body[data-bordered="no"] .stats-grid {
  border-left: none;
}
body[data-bordered="no"] .stat,
body[data-bordered="no"] .how-step {
  padding-top: 8px;
  padding-bottom: 28px;
}

/* Sticky nav off */
body:has(.nav[data-sticky="no"]) { /* no-op marker for clarity */ }
.nav[data-sticky="no"] { position: relative; }

/* Density modes — adjust section padding */
body[data-density="compact"] .hero { padding: 48px 0 40px; }
body[data-density="compact"] .stats,
body[data-density="compact"] .problem,
body[data-density="compact"] .how,
body[data-density="compact"] .pricing,
body[data-density="compact"] .faq { padding: 48px 0; }
body[data-density="compact"] .proof { padding: 56px 0; }
body[data-density="compact"] .section-head { margin-bottom: 32px; padding-bottom: 16px; }
body[data-density="compact"] .footer { padding: 40px 0 24px; }
body[data-density="compact"] .footer-top { padding-bottom: 28px; }
body[data-density="compact"] .tier { padding: 22px 22px; }
body[data-density="compact"] .how-step { padding-top: 22px; padding-bottom: 22px; }

body[data-density="spacious"] .hero { padding: clamp(80px, 12vw, 140px) 0 clamp(72px, 10vw, 120px); }
body[data-density="spacious"] .stats,
body[data-density="spacious"] .problem,
body[data-density="spacious"] .how,
body[data-density="spacious"] .pricing,
body[data-density="spacious"] .faq { padding: clamp(96px, 12vw, 160px) 0; }
body[data-density="spacious"] .proof { padding: clamp(100px, 14vw, 180px) 0; }
body[data-density="spacious"] .section-head { margin-bottom: 80px; padding-bottom: 40px; }
body[data-density="spacious"] .tier { padding: 44px 36px; }
body[data-density="spacious"] .how-step { padding-top: 48px; padding-bottom: 48px; }

/* 12-col grid overlay (visual aid) */
body[data-grid="yes"] main {
  position: relative;
}
body[data-grid="yes"] main::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 40;
  max-width: var(--maxw, 1240px);
  margin: 0 auto;
  background-image:
    repeating-linear-gradient(to right,
      oklch(0.6 0.18 25 / 0.08) 0,
      oklch(0.6 0.18 25 / 0.08) calc((100% - 11 * 24px) / 12),
      transparent calc((100% - 11 * 24px) / 12),
      transparent calc(((100% - 11 * 24px) / 12) + 24px));
  left: 0; right: 0;
  padding: 0 var(--pad-x);
}

/* Subtle paper noise */
body[data-noise="yes"]::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 30;
  opacity: 0.5;
  mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='180' height='180'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 0  0 0 0 0 0  0 0 0 0 0  0 0 0 0.06 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
}

/* Dark theme */
body[data-theme="dark"] {
  --bg: oklch(0.18 0.01 250);
  --bg-alt: oklch(0.22 0.012 250);
  --bg-deep: oklch(0.12 0.01 250);
  --ink: oklch(0.97 0.005 250);
  --ink-soft: oklch(0.82 0.008 250);
  --mute: oklch(0.62 0.01 250);
  --hairline: oklch(0.32 0.012 250);
  --hairline-strong: oklch(0.42 0.012 250);
  --gray-soft: oklch(0.4 0.012 250);
}
body[data-theme="dark"] .nav {
  background: oklch(0.18 0.01 250 / 0.85);
}
body[data-theme="dark"] .proof {
  background: oklch(0.1 0.008 250);
}
body[data-theme="dark"] .proof .eyebrow {
  color: oklch(0.7 0.01 250);
}
body[data-theme="dark"] .proof .section-title {
  color: oklch(0.90 0.005 250);
}
body[data-theme="dark"] .proof-sources {
  background: oklch(0.14 0.008 250);
  border-color: oklch(0.28 0.01 250);
}
body[data-theme="dark"] .tier-accent {
  background: oklch(0.08 0.005 250);
  border-color: oklch(0.32 0.012 250);
}
body[data-theme="dark"] .footer {
  background: oklch(0.14 0.008 250);
}
body[data-theme="dark"] ::selection {
  background: var(--ink);
  color: var(--bg);
}
body[data-theme="dark"] .hero::before {
  background-image: linear-gradient(to right, oklch(0.32 0.012 250 / 0.5) 1px, transparent 1px);
}

/* Rounded variants — make all the cards softer/sharper */
body[data-rounded="sharp"] .hero-widget,
body[data-rounded="sharp"] .cost-card,
body[data-rounded="sharp"] .tier,
body[data-rounded="sharp"] .proof-sources,
body[data-rounded="sharp"] .widget-result {
  box-shadow: 0 0 0 1px var(--hairline-strong) inset, 0 1px 0 rgba(255,255,255,0.4) inset;
}

/* ──────────────────────────────────────────────
   PROCESS TIMELINE (5-stage permit process)
   ────────────────────────────────────────────── */
.process {
  padding: clamp(64px, 9vw, 120px) 0;
  border-bottom: 1px solid var(--hairline);
}
.process-timeline {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  border: 1px solid var(--hairline);
  border-radius: calc(var(--radius-base, 8px) * 1.4);
  overflow: hidden;
  margin: 48px 0 24px;
}
.process-stage {
  padding: 28px 22px;
  border-right: 1px solid var(--hairline);
  position: relative;
}
.process-stage:last-child { border-right: none; }
.process-stage.is-blackbox { background: var(--bg-alt); }
.process-stage.is-blackbox .stage-label::after {
  content: "";
  display: block;
  width: 28px;
  height: 2px;
  background: var(--amber);
  margin-top: 8px;
  border-radius: 2px;
}
.stage-n {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--mute);
  margin-bottom: 14px;
}
.stage-label {
  font-family: var(--serif);
  font-size: 15px;
  font-weight: 500;
  color: var(--ink);
  margin-bottom: 10px;
}
.stage-body {
  font-size: 13px;
  line-height: 1.55;
  color: var(--ink-soft);
  margin-bottom: 14px;
}
.stage-timing {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--mute);
  letter-spacing: 0.04em;
}
.process-blackbox-label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--amber);
  color: oklch(0.3 0.06 75);
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 5px 12px;
  border-radius: 4px;
  margin-bottom: 12px;
}
.process-gov-stat {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--mute);
  margin-top: 10px;
}
@media (max-width: 960px) {
  .process-timeline { grid-template-columns: 1fr; }
  .process-stage { border-right: none; border-bottom: 1px solid var(--hairline); }
  .process-stage:last-child { border-bottom: none; }
}

/* ──────────────────────────────────────────────
   ROADMAP (3-layer product layers)
   ────────────────────────────────────────────── */
.roadmap {
  padding: clamp(64px, 9vw, 120px) 0;
  border-bottom: 1px solid var(--hairline);
}
.roadmap-layers {
  display: flex;
  flex-direction: column;
  gap: 3px;
  margin-top: 48px;
}
.roadmap-layer {
  display: flex;
  gap: 28px;
  align-items: flex-start;
  padding: 28px 32px;
  border: 1px solid var(--hairline);
  border-radius: calc(var(--radius-base, 8px) * 1.1);
  transition: border-color 0.2s;
}
.roadmap-layer.layer-live {
  border-color: oklch(0.72 0.14 145 / 0.5);
  background: oklch(0.98 0.006 145);
}
.roadmap-layer.layer-soon { background: var(--bg-alt); }
.roadmap-layer.layer-dev  { opacity: 0.75; }
.layer-n {
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.1em;
  color: var(--mute);
  padding-top: 4px;
  min-width: 28px;
}
.layer-body { flex: 1; }
.layer-header {
  display: flex;
  align-items: baseline;
  gap: 14px;
  margin-bottom: 10px;
  flex-wrap: wrap;
}
.layer-label {
  font-family: var(--serif);
  font-size: 20px;
  color: var(--ink);
}
.layer-status {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 3px 10px;
  border-radius: 4px;
}
.layer-status.status-live  { background: var(--green); color: oklch(0.15 0.04 145); }
.layer-status.status-soon  { background: var(--amber); color: oklch(0.3 0.06 75); }
.layer-status.status-dev   { background: var(--gray-soft); color: var(--ink-soft); }
body[data-theme="dark"] .layer-status.status-dev {
  background: oklch(0.28 0.012 250);
  color: oklch(0.88 0.005 250);
}
.layer-text {
  font-size: 15px;
  line-height: 1.6;
  color: var(--ink-soft);
}
@media (max-width: 768px) {
  .roadmap-layer { padding: 20px 20px; gap: 16px; }
  .layer-label { font-size: 18px; }
}
body[data-theme="dark"] .roadmap-layer.layer-live {
  background: oklch(0.22 0.02 145);
  border-color: oklch(0.5 0.1 145 / 0.5);
}

/* ──────────────────────────────────────────────
   TRIAL MODAL (email capture)
   ────────────────────────────────────────────── */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: oklch(0.18 0.01 250 / 0.5);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 200;
  padding: 20px;
}
.modal-box {
  background: var(--bg);
  border: 1px solid var(--hairline-strong);
  border-radius: calc(var(--radius-base, 8px) * 1.6);
  padding: 40px;
  max-width: 440px;
  width: 100%;
  position: relative;
  box-shadow:
    0 1px 0 0 rgba(255,255,255,0.6) inset,
    0 40px 80px -20px oklch(0.18 0.01 250 / 0.25);
}
.modal-close {
  position: absolute;
  top: 16px; right: 16px;
  width: 32px; height: 32px;
  background: var(--bg-alt);
  border: 1px solid var(--hairline);
  border-radius: 50%;
  font-size: 18px;
  cursor: pointer;
  color: var(--mute);
  display: flex; align-items: center; justify-content: center;
  transition: background 0.15s;
  line-height: 1;
  padding: 0;
}
.modal-close:hover { background: var(--hairline); color: var(--ink); }
.modal-title {
  font-size: 24px;
  letter-spacing: -0.02em;
  margin: 0 0 8px;
  color: var(--ink);
}
.modal-sub {
  font-size: 15px;
  color: var(--ink-soft);
  margin: 0 0 28px;
}
.modal-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.modal-submit {
  width: 100%;
  justify-content: center;
  margin-top: 4px;
  font-size: 16px;
  padding: 14px 22px;
}
.modal-submit:disabled { opacity: 0.7; cursor: wait; }
.modal-error {
  font-size: 13px;
  color: var(--red);
  font-family: var(--mono);
}
.modal-success { text-align: center; padding: 12px 0 8px; }
.modal-success-icon {
  width: 56px; height: 56px;
  background: oklch(0.72 0.14 145 / 0.12);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 26px;
  margin: 0 auto 20px;
  color: oklch(0.5 0.14 145);
}
.modal-success h3 { font-size: 22px; margin: 0 0 10px; }
.modal-success p  { font-size: 15px; color: var(--ink-soft); margin: 0; }
.modal-divider {
  border: none;
  border-top: 1px solid var(--hairline);
  margin: 20px 0 16px;
}
.modal-fine {
  font-size: 12px;
  color: var(--mute);
  font-family: var(--mono);
  text-align: center;
  margin: 0;
}
@media (max-width: 540px) {
  .modal-box { padding: 28px 24px; }
}
body[data-theme="dark"] .modal-box {
  background: var(--bg-alt);
  border-color: var(--hairline-strong);
}

/* ─────────────────────────────────────────────────────────
   HERO — full-width (no widget aside)
───────────────────────────────────────────────────────── */
.hero-text-full {
  max-width: 820px;
}
.hero-headline-full {
  font-size: clamp(52px, 7.5vw, 92px);
}
.hero-sub-full {
  font-size: 20px;
  max-width: 60ch;
}

/* ─────────────────────────────────────────────────────────
   NETHERLANDS MAP SECTION
───────────────────────────────────────────────────────── */
.nl-map-section {
  padding: clamp(56px, 8vw, 96px) 0;
  border-bottom: 1px solid var(--hairline);
  background: var(--bg);
}

.nl-map-layout {
  display: grid;
  grid-template-columns: 1fr 280px;
  gap: 32px;
  align-items: start;
}

.nl-map-container {
  position: relative;
  z-index: 1;
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid var(--hairline);
  box-shadow: 0 8px 32px -8px oklch(0.18 0.01 250 / 0.12);
}

.nl-map-canvas {
  height: 520px;
  width: 100%;
}

.nl-map-active-label {
  position: absolute;
  bottom: 12px;
  left: 12px;
  background: var(--bg);
  border: 1px solid var(--hairline-strong);
  border-radius: 6px;
  padding: 6px 12px;
  font-size: 12px;
  color: var(--ink-soft);
  pointer-events: none;
  z-index: 500;
}

/* Sidebar */
.nl-map-sidebar {
  display: flex;
  flex-direction: column;
  gap: 20px;
  padding-top: 4px;
}

.nl-map-stat-card {
  background: var(--bg-alt);
  border: 1px solid var(--hairline);
  border-radius: 10px;
  padding: 20px 22px;
}
.nlms-eyebrow {
  color: var(--mute);
  margin-bottom: 6px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.nlms-value {
  font-size: 56px;
  line-height: 1;
  letter-spacing: -0.03em;
  margin-bottom: 6px;
}
.nlms-label { font-size: 13px; color: var(--ink-soft); }

.nl-map-legend {
  background: var(--bg);
  border: 1px solid var(--hairline);
  border-radius: 10px;
  padding: 18px 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.nml-title {
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--mute);
  padding-bottom: 10px;
  border-bottom: 1px solid var(--hairline);
}
.nml-item {
  display: flex;
  align-items: center;
  gap: 10px;
}
.nml-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  flex-shrink: 0;
  box-shadow: 0 0 0 3px oklch(0.85 0.01 250 / 0.5);
}
.nml-label { font-size: 13px; color: var(--ink); font-weight: 500; }
.nml-count { color: var(--mute); margin-top: 1px; }

.nl-map-cta-block {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.nl-map-source {
  text-align: center;
  color: var(--mute);
  letter-spacing: 0.03em;
}

/* Leaflet tooltip overrides */
.nl-map-tooltip {
  border: none !important;
  box-shadow: 0 4px 20px -4px oklch(0.18 0.01 250 / 0.25) !important;
  border-radius: 8px !important;
  padding: 0 !important;
  background: transparent !important;
}
.nl-map-tooltip::before { display: none !important; }
.map-tooltip {
  background: var(--bg, #fff);
  border: 1px solid var(--hairline-strong);
  border-radius: 8px;
  padding: 12px 14px;
  min-width: 180px;
}
.mtt-name  { font-weight: 600; font-size: 14px; color: var(--ink); margin-bottom: 4px; }
.mtt-status{ font-size: 12px; color: var(--ink-soft); margin-bottom: 3px; }
.mtt-trigger { font-size: 12px; color: var(--mute); margin-bottom: 4px; }
.mtt-cvdr  { font-family: "JetBrains Mono", monospace; font-size: 11px; color: var(--mute); }

/* Map cursor */
.nl-map-canvas .leaflet-container { cursor: default; }
.nl-map-canvas .leaflet-clickable { cursor: pointer; }

@media (max-width: 900px) {
  .nl-map-layout {
    grid-template-columns: 1fr;
  }
  .nl-map-sidebar {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
  }
  .nl-map-cta-block { grid-column: span 2; }
  .nl-map-canvas { height: 380px; }
}

/* ─────────────────────────────────────────────────────────
   TOOL — step indicator
───────────────────────────────────────────────────────── */
.tool-step-indicator {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 20px 0 28px;
  border-bottom: 1px solid var(--hairline);
  margin-bottom: 28px;
}
.tsi-item {
  display: flex;
  align-items: center;
  gap: 8px;
  opacity: 0.35;
  transition: opacity 0.2s;
}
.tsi-item.tsi-active { opacity: 1; }
.tsi-item.tsi-done   { opacity: 0.7; }
.tsi-n {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  background: var(--bg-alt);
  border: 1px solid var(--hairline-strong);
  border-radius: 4px;
  padding: 3px 7px;
  color: var(--ink);
}
.tsi-item.tsi-active .tsi-n {
  background: var(--ink);
  color: var(--bg);
  border-color: var(--ink);
}
.tsi-item.tsi-done .tsi-n {
  background: var(--green);
  color: var(--bg);
  border-color: var(--green);
}
.tsi-label { font-size: 13px; font-weight: 500; color: var(--ink); }
.tsi-arrow { font-size: 12px; color: var(--hairline-strong); }

/* ── Tool step blocks ── */
.tool-step-block {
  margin-bottom: 20px;
  padding: 18px;
  border: 1px solid var(--hairline);
  border-radius: 8px;
  background: var(--bg);
}
.tool-step-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 14px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--hairline);
}
.tool-step-num   { color: var(--mute); font-size: 11px; letter-spacing: 0.08em; }
.tool-step-title { font-weight: 600; font-size: 14px; flex: 1; }
.tool-step-tag   { color: var(--mute); letter-spacing: 0.04em; }

.tool-step-divider {
  text-align: center;
  color: var(--mute);
  padding: 12px 0 10px;
  letter-spacing: 0.04em;
}

/* ── Municipality list (replaces old scrollable div) ── */
.muni-list-scroll {
  max-height: 180px;
  overflow-y: auto;
  border: 1px solid var(--hairline);
  border-radius: 6px;
  margin-bottom: 4px;
}
.muni-list-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  text-align: left;
  padding: 9px 12px;
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--hairline);
  font-size: 14px;
  color: var(--ink);
  font-family: var(--sans);
  transition: background 0.12s;
}
.muni-list-item:last-child { border-bottom: none; }
.muni-list-item:hover      { background: var(--bg-alt); }
.muni-list-item.is-selected { background: var(--bg-alt); font-weight: 500; }

/* ── PDOK address search ── */
.address-search-wrap {
  position: relative;
  margin-bottom: 4px;
}
.address-input-row {
  position: relative;
  display: flex;
  align-items: center;
}
.address-icon {
  position: absolute;
  left: 12px;
  font-size: 16px;
  color: var(--mute);
  pointer-events: none;
  z-index: 1;
}
.address-input {
  padding-left: 34px !important;
  width: 100%;
}
.address-spinner {
  position: absolute;
  right: 12px;
  width: 14px;
  height: 14px;
  border: 2px solid var(--hairline-strong);
  border-top-color: var(--ink);
  border-radius: 50%;
  animation: spin 0.6s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

.pdok-dropdown {
  position: absolute;
  top: calc(100% + 4px);
  left: 0; right: 0;
  background: var(--bg);
  border: 1px solid var(--hairline-strong);
  border-radius: 8px;
  box-shadow: 0 8px 24px -4px oklch(0.18 0.01 250 / 0.18);
  list-style: none;
  margin: 0;
  padding: 4px 0;
  z-index: 200;
  max-height: 240px;
  overflow-y: auto;
}
.pdok-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  cursor: pointer;
  transition: background 0.1s;
}
.pdok-item:hover { background: var(--bg-alt); }
.pdok-name  { font-size: 13px; color: var(--ink); }
.pdok-muni  { color: var(--mute); flex-shrink: 0; }

.pdok-detected {
  margin-top: 6px;
  padding: 6px 12px;
  border-radius: 5px;
  font-size: 12px;
  font-family: var(--mono);
}
.pdok-hit  { background: oklch(0.72 0.14 145 / 0.12); color: var(--ink); }
.pdok-miss { background: oklch(0.78 0.14 75 / 0.12);  color: var(--ink); }

/* ─────────────────────────────────────────────────────────
   MOBILE & TABLET OPTIMIZATION
───────────────────────────────────────────────────────── */

/* Hamburger menu button (hidden on desktop) */
.nav-menu-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: transparent;
  border: none;
  padding: 8px;
  cursor: pointer;
  margin-left: 12px;
}
.nav-menu-toggle span {
  width: 24px;
  height: 2px;
  background: var(--ink);
  transition: all 0.3s ease;
  display: block;
}

/* Mobile menu open state */
.nav-menu-toggle.open span:nth-child(1) {
  transform: rotate(45deg) translate(10px, 10px);
}
.nav-menu-toggle.open span:nth-child(2) {
  opacity: 0;
}
.nav-menu-toggle.open span:nth-child(3) {
  transform: rotate(-45deg) translate(8px, -8px);
}

/* Make sure all touch targets are at least 44px */
.btn, .nav-cta, .nav-cta-ghost, .lang-toggle, .theme-toggle,
.field-input, .widget-cta, button, a[class*="btn"], input[type="button"],
input[type="submit"], .faq-q, .tier-cta, .muni-list-item {
  min-height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Responsive typography */
@media (max-width: 768px) {
  html {
    font-size: 15px;
  }
  body {
    font-size: 15px;
  }
}

@media (max-width: 480px) {
  html {
    font-size: 14px;
  }
  body {
    font-size: 14px;
  }
}

/* Tablet optimization (768px - 1024px) */
@media (min-width: 481px) and (max-width: 1024px) {
  .hero-grid,
  .problem-grid,
  .proof-grid,
  .faq-grid,
  .footer-top {
    gap: clamp(24px, 5vw, 40px);
  }

  .nav-links {
    gap: 20px;
  }

  .section-title {
    font-size: clamp(28px, 4vw, 48px);
  }

  .hero-headline {
    font-size: clamp(36px, 5vw, 64px);
  }

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

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

  .how-step:nth-child(3) {
    grid-column: 1 / -1;
    max-width: 50%;
  }
}

/* Mobile optimization (max-width 480px) */
@media (max-width: 480px) {
  /* Show hamburger menu */
  .nav-menu-toggle {
    display: flex;
  }

  /* Mobile nav links */
  .nav-links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    background: var(--bg);
    border-bottom: 1px solid var(--hairline);
    padding: 16px var(--pad-x);
    gap: 12px;
    z-index: 100;
  }

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

  .nav-links a {
    padding: 12px 0;
    font-size: 16px;
    display: block;
  }

  /* Compact nav-right for mobile */
  .nav-right {
    gap: 4px !important;
  }

  .lang-toggle,
  .theme-toggle {
    padding: 4px 6px !important;
    font-size: 11px !important;
  }

  .nav-cta-ghost,
  .nav-cta {
    display: none;
  }

  /* Hero section mobile */
  .hero {
    padding: clamp(40px, 6vw, 56px) 0 clamp(32px, 5vw, 48px);
  }

  .hero-headline {
    font-size: clamp(32px, 7vw, 52px);
    line-height: 1.1;
    margin: 8px 0 20px;
  }

  .hero-sub {
    font-size: 16px;
    margin-bottom: 24px;
  }

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

  .hero-ctas .btn {
    width: 100%;
    justify-content: center;
  }

  .hero-foot {
    font-size: 12px;
    flex-direction: column;
    gap: 8px;
  }

  .foot-sep {
    display: none;
  }

  /* Stats grid mobile */
  .stats {
    padding: clamp(40px, 6vw, 56px) 0;
  }

  .stats-grid {
    grid-template-columns: 1fr;
    border: none;
  }

  .stat {
    border: 1px solid var(--hairline);
    border-radius: 8px;
    margin-bottom: 12px;
    padding: 20px 16px;
  }

  .stat:last-child {
    margin-bottom: 0;
  }

  /* Problem section mobile */
  .problem {
    padding: clamp(40px, 6vw, 56px) 0;
  }

  .problem-grid {
    gap: 24px;
  }

  /* How section mobile */
  .how {
    padding: clamp(40px, 6vw, 56px) 0;
  }

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

  .how-step {
    border-right: none;
    padding: 24px 0;
    border-bottom: 1px solid var(--hairline);
  }

  .how-step:first-child {
    padding-top: 0;
  }

  /* Pricing tiers mobile */
  .pricing {
    padding: clamp(40px, 6vw, 56px) 0;
  }

  .tiers {
    gap: 12px;
  }

  .tier {
    padding: 20px 16px;
  }

  .tier-price {
    font-size: 36px;
  }

  /* FAQ mobile */
  .faq {
    padding: clamp(40px, 6vw, 56px) 0;
  }

  .faq-grid {
    gap: 20px;
  }

  .faq-q {
    padding: 16px 0;
    gap: 16px;
  }

  .faq-a {
    padding: 0 0 16px;
    font-size: 14px;
  }

  /* Footer mobile */
  .footer {
    padding: 48px 0 24px;
  }

  .footer-top {
    gap: 24px;
  }

  .footer-cols {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .footer-col-title {
    margin-bottom: 10px;
  }

  /* Form inputs mobile */
  .field-input,
  .field-input:focus {
    font-size: 16px;
    padding: 12px 14px;
    min-height: 44px;
  }

  input[type="text"],
  input[type="email"],
  textarea,
  select {
    font-size: 16px;
  }

  /* Button mobile */
  .btn {
    width: 100%;
    min-height: 44px;
    padding: 12px 20px;
    font-size: 16px;
  }

  .btn-primary {
    font-weight: 600;
  }

  /* Modal mobile */
  .modal-box {
    padding: 24px 20px;
    max-width: 90vw;
  }

  .modal-title {
    font-size: 20px;
  }

  .modal-form {
    gap: 12px;
  }

  /* Breadcrumb mobile */
  .breadcrumb {
    display: none;
  }

  /* Page header mobile */
  .page-header {
    padding: clamp(32px, 6vw, 48px) 0 clamp(24px, 4vw, 32px);
  }

  .page-title {
    font-size: clamp(28px, 6vw, 40px);
    margin: 8px 0 16px;
  }

  .page-sub {
    font-size: 16px;
  }

  /* Longform mobile */
  .longform-grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .longform-toc {
    position: static;
    top: auto;
    border: 1px solid var(--hairline);
    border-radius: 8px;
    padding: 16px;
    margin-bottom: 24px;
  }

  /* Proof section mobile */
  .proof {
    padding: clamp(48px, 8vw, 80px) 0;
  }

  .proof-quote {
    font-size: clamp(24px, 5vw, 32px);
  }

  /* Process timeline mobile */
  .process-timeline {
    grid-template-columns: 1fr;
  }

  .process-stage {
    border-right: none;
    border-bottom: 1px solid var(--hairline);
    padding: 20px 0;
  }

  .process-stage:last-child {
    border-bottom: none;
  }

  /* Roadmap mobile */
  .roadmap {
    padding: clamp(40px, 6vw, 56px) 0;
  }

  .roadmap-layer {
    padding: 16px 14px;
    gap: 16px;
  }

  .layer-label {
    font-size: 16px;
  }

  /* Tool page mobile */
  .tool-step-indicator {
    flex-wrap: wrap;
    gap: 8px;
  }

  .tsi-item {
    font-size: 12px;
  }

  .tsi-n {
    padding: 2px 5px;
    font-size: 10px;
  }

  .tool-step-block {
    padding: 14px;
    margin-bottom: 16px;
  }

  /* Checklist mobile */
  .checklist-item {
    padding: 6px 0;
  }

  .checklist-label {
    font-size: 13px;
  }

  .checklist-ref {
    font-size: 11px;
  }

  /* Netherlands map mobile */
  .nl-map-layout {
    grid-template-columns: 1fr;
  }

  .nl-map-canvas {
    height: 300px;
  }

  .nl-map-sidebar {
    grid-template-columns: 1fr;
  }

  .nl-map-cta-block {
    grid-column: auto;
  }

  /* Widget/card mobile */
  .hero-widget,
  .cost-card,
  .tier,
  .proof-sources {
    padding: 16px 14px;
  }

  .widget-title {
    font-size: 14px;
  }

  /* Scanner/checklist mobile */
  .checklist-body {
    min-height: auto;
    padding: 4px 0 8px;
  }

  /* Cost card mobile */
  .cost-card {
    position: static;
    top: auto;
    margin-bottom: 24px;
  }
}

/* Large mobile (480px - 768px) */
@media (max-width: 768px) and (min-width: 481px) {
  .nav-links {
    gap: 18px;
  }

  .hero-headline {
    font-size: clamp(36px, 5vw, 60px);
  }

  .section-title {
    font-size: clamp(28px, 4vw, 46px);
  }

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

  .how-step:nth-child(3) {
    grid-column: 1 / -1;
    max-width: 50%;
  }

  .tiers {
    grid-template-columns: repeat(2, 1fr);
  }

  .tier:nth-child(2) {
    grid-column: 1 / -1;
    max-width: calc(50% + 8px);
  }

  .footer-cols {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Extra small mobile (max-width 360px) */
@media (max-width: 360px) {
  :root {
    --pad-x: 12px;
  }

  .nav-right {
    gap: 0 !important;
  }

  .lang-toggle,
  .theme-toggle {
    padding: 2px 4px !important;
    font-size: 10px !important;
    gap: 2px !important;
  }

  .hero-headline {
    font-size: clamp(24px, 6vw, 40px);
  }

  .btn {
    padding: 10px 16px;
    font-size: 14px;
  }
}

