:root {
  /* Warm, light editorial palette — most of the site lives here */
  --bg: #f9f5ec;
  --bg-alt: #f0e9d8;
  --surface: #ffffff;
  --border: #ddd0b2;
  --border-soft: #e8ddc4;
  --text: #221f19;
  --text-dim: #6c6252;
  --text-faint: #978c72;
  --accent: #9c7530;
  --accent-bright: #7c5c26;
  --accent-ink: #fbf8f2;
  --error: #b0503a;
  --radius: 2px;
  --max-width: 1160px;
  --serif: "Fraunces", "Iowan Old Style", "Palatino Linotype", Georgia, serif;
  --sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

/* Dark masthead band — reserved for the header + hero only, so the drama is
   up top and the rest of the site reads light and open rather than somber. */
.theme-dark {
  --bg: #1c160f;
  --bg-alt: #221b12;
  --surface: #251e14;
  --border: #3a3120;
  --border-soft: #2c261a;
  --text: #f5f0e6;
  --text-dim: #c7bca4;
  --text-faint: #99907a;
  --accent: #d9b877;
  --accent-bright: #e9d09a;
  --accent-ink: #1c160f;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--sans);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 32px;
}
.container-narrow { max-width: 640px; }
.center { text-align: center; }

a { color: inherit; }

/* Masthead rule */
.masthead-rule {
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--accent) 20%, var(--accent) 80%, transparent);
  opacity: 0.6;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  background: color-mix(in srgb, var(--bg) 92%, transparent);
  color: var(--text);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border-soft);
  z-index: 100;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 22px 32px;
}

.logo {
  font-family: var(--serif);
  font-weight: 500;
  letter-spacing: 0.02em;
  text-decoration: none;
  color: var(--text);
  font-size: 19px;
}
.logo em {
  font-style: italic;
  color: var(--accent);
  font-weight: 400;
}
.logo-sub {
  display: block;
  font-family: var(--sans);
  font-size: 9px;
  letter-spacing: 0.28em;
  color: var(--text-faint);
  text-transform: uppercase;
  margin-top: 2px;
}

.nav { display: flex; align-items: center; gap: 36px; }
.nav a {
  color: var(--text-dim);
  text-decoration: none;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  transition: color 0.2s;
}
.nav a:hover { color: var(--accent-bright); }
.nav-cta {
  border: 1px solid var(--accent);
  color: var(--accent) !important;
  padding: 9px 20px;
  transition: background 0.2s, color 0.2s;
}
.nav-cta:hover {
  background: var(--accent);
  color: var(--accent-ink) !important;
}

/* Hero */
.hero {
  padding: 130px 0 100px;
  position: relative;
  background: var(--bg);
  color: var(--text);
}
.hero-inner { max-width: 780px; margin: 0 auto; text-align: center; }
.hero-kicker {
  display: inline-block;
  font-size: 11px;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 28px;
  font-weight: 600;
}
.hero h1 {
  font-family: var(--serif);
  font-size: clamp(38px, 5.4vw, 64px);
  line-height: 1.08;
  margin: 0 0 28px;
  font-weight: 500;
  letter-spacing: -0.01em;
}
.hero h1 em { font-style: italic; color: var(--accent); font-weight: 400; }
.hero-sub {
  font-size: 18px;
  color: var(--text-dim);
  max-width: 540px;
  margin: 0 auto 40px;
  font-weight: 300;
}
.hero-ctas { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; margin-bottom: 22px; }
.hero-trust {
  font-size: 12px;
  letter-spacing: 0.06em;
  color: var(--text-faint);
  text-transform: uppercase;
}

/* Buttons */
.btn {
  display: inline-block;
  padding: 15px 32px;
  border-radius: var(--radius);
  font-weight: 600;
  font-size: 13px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  text-decoration: none;
  border: 1px solid transparent;
  cursor: pointer;
  transition: background 0.2s, border-color 0.2s, color 0.2s;
}
.btn-primary { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
.btn-primary:hover { background: var(--accent-bright); border-color: var(--accent-bright); }
.btn-secondary { background: transparent; color: var(--text); border-color: color-mix(in srgb, var(--text) 35%, transparent); }
.btn-secondary:hover { border-color: var(--accent); color: var(--accent-bright); }
.btn-lg { padding: 18px 42px; font-size: 13px; }
.btn:disabled { opacity: 0.5; cursor: not-allowed; }

/* Sections */
.section { padding: 96px 0; }
.section-alt { background: var(--bg-alt); border-top: 1px solid var(--border-soft); border-bottom: 1px solid var(--border-soft); }
.section-kicker {
  display: block;
  text-align: center;
  font-size: 11px;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 16px;
  font-weight: 600;
}
.section h2 {
  font-family: var(--serif);
  font-size: clamp(28px, 3.6vw, 38px);
  font-weight: 500;
  margin: 0 0 16px;
  text-align: center;
  letter-spacing: -0.01em;
}
.section-sub {
  text-align: center;
  color: var(--text-dim);
  max-width: 520px;
  margin: 0 auto 56px;
  font-weight: 300;
  font-size: 16px;
}

/* Steps */
.steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 1px;
  background: var(--border-soft);
  border: 1px solid var(--border-soft);
}
.step {
  background: var(--bg);
  padding: 36px 30px;
}
.step-num {
  font-family: var(--serif);
  font-style: italic;
  font-size: 28px;
  color: var(--accent);
  display: block;
  margin-bottom: 18px;
}
.step h3 { margin: 0 0 10px; font-size: 16px; font-weight: 600; letter-spacing: 0.01em; }
.step p { margin: 0; color: var(--text-dim); font-size: 14px; font-weight: 300; line-height: 1.7; }

/* Pricing */
.pricing-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1px;
  max-width: 680px;
  margin: 0 auto;
  background: var(--border);
  border: 1px solid var(--border);
}
.price-card {
  background: var(--bg-alt);
  padding: 40px 32px;
  text-align: center;
}
.price-card-highlight { background: var(--surface); }
.price-card h3 {
  margin: 0 0 18px;
  font-size: 11px;
  color: var(--text-faint);
  text-transform: uppercase;
  letter-spacing: 0.2em;
  font-weight: 600;
}
.price {
  font-family: var(--serif);
  font-size: 44px;
  font-weight: 500;
  margin: 0 0 14px;
  color: var(--text);
}
.price-card-highlight .price { color: var(--accent-bright); }
.price-note { display: block; font-size: 12px; font-weight: 400; color: var(--text-faint); margin-top: 6px; letter-spacing: 0.02em; }
.price-desc { color: var(--text-dim); font-size: 14px; margin: 0; font-weight: 300; line-height: 1.7; }
.pricing-arrow {
  text-align: center;
  color: var(--text-faint);
  font-size: 20px;
  margin: -1px 0;
  display: none;
}
.pricing-total {
  text-align: center;
  margin-top: 32px;
  font-size: 13px;
  letter-spacing: 0.04em;
  color: var(--text-dim);
}
.pricing-total strong { color: var(--accent-bright); font-weight: 600; }
.pricing-footnote {
  text-align: center;
  font-size: 12px;
  color: var(--error);
  max-width: 600px;
  margin: 40px auto 0;
  letter-spacing: 0.01em;
}

/* Forms */
.form { display: flex; flex-direction: column; gap: 20px; }
.form-row { display: flex; flex-direction: column; gap: 8px; }
.form-row-split { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.form label {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-faint);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  /* Reserve consistent height for up to two lines and bottom-anchor the text,
     so a long label (e.g. "Annual Mileage Allowance") and a short one sharing
     a row (e.g. "Lease Term") don't push their inputs to different heights. */
  min-height: 28px;
  display: flex;
  align-items: flex-end;
}
.form input,
.form select,
.form textarea {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 13px 14px;
  color: var(--text);
  font-size: 15px;
  font-family: var(--sans);
}
.form input::placeholder, .form textarea::placeholder { color: var(--text-faint); }
.form input:focus,
.form select:focus,
.form textarea:focus {
  outline: none;
  border-color: var(--accent);
}
.form-privacy-note { font-size: 12px; color: var(--text-faint); margin: 0; font-weight: 300; }
.form-success { color: var(--accent-bright); text-align: center; font-weight: 500; margin-top: 20px; letter-spacing: 0.02em; }
.form-error { color: var(--error); text-align: center; margin-top: 14px; font-size: 13px; }

/* FAQ */
details {
  background: transparent;
  border-bottom: 1px solid var(--border-soft);
  padding: 22px 0;
}
details:first-of-type { border-top: 1px solid var(--border-soft); }
summary {
  cursor: pointer;
  font-weight: 500;
  font-size: 15px;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
summary::-webkit-details-marker { display: none; }
summary::after {
  content: "+";
  color: var(--accent);
  font-size: 18px;
  font-weight: 300;
  margin-left: 16px;
}
details[open] summary::after { content: "\2212"; }
details p { color: var(--text-dim); margin: 16px 0 0; font-size: 14px; font-weight: 300; line-height: 1.7; }

/* About */
.about-copy p {
  font-size: 16px;
  color: var(--text-dim);
  line-height: 1.8;
  margin: 0 0 22px;
  font-weight: 300;
}
.about-copy p:last-child { margin-bottom: 0; }
.about-signoff {
  margin: 28px 0 0;
  font-family: var(--serif);
  font-style: italic;
  color: var(--accent);
  font-size: 15px;
  text-align: right;
}

/* Selectivity note */
.selectivity {
  max-width: 620px;
  margin: 0 auto;
  text-align: center;
  padding: 28px 32px;
  border: 1px solid var(--border);
}
.selectivity p {
  margin: 0;
  color: var(--text-dim);
  font-size: 14px;
  font-weight: 300;
  font-style: italic;
  font-family: var(--serif);
  font-size: 18px;
  line-height: 1.6;
}

/* Footer */
.site-footer { border-top: 1px solid var(--border-soft); padding: 40px 0; }
.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
  font-size: 12px;
  color: var(--text-faint);
  letter-spacing: 0.02em;
}
.footer-nav { display: flex; gap: 28px; }
.footer-nav a { color: var(--text-faint); text-decoration: none; text-transform: uppercase; letter-spacing: 0.08em; font-size: 11px; }
.footer-nav a:hover { color: var(--accent); }

/* Static pages (terms/privacy/success/cancel) headings */
main h2 { font-family: var(--serif); font-weight: 500; }
main h3 { font-family: var(--serif); font-weight: 500; font-size: 19px; margin-top: 32px; }

/* Collapse the text nav links (keep just the CTA) before the logo + full nav
   get cramped — "DealerBuffer" is wider than a short wordmark, so this needs
   a more generous threshold than the old single mobile breakpoint did. */
@media (max-width: 900px) {
  .nav a:not(.nav-cta) { display: none; }
}

@media (max-width: 640px) {
  .nav { gap: 18px; }
  .form-row-split { grid-template-columns: 1fr; }
  .header-inner { padding: 18px 20px; }
  .hero { padding: 90px 0 64px; }
}
