/* Keystone Commerce site styles.
   Order: fonts, tokens, base, layout, components, page sections, utilities. */

/* Fonts: self-hosted Barlow (SIL OFL), Latin subset.
   The fallback faces are Arial scaled to Barlow's metrics so text doesn't reflow when the web font arrives. */
@font-face {
  font-family: "Barlow";
  src: url("/assets/fonts/barlow-400.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Barlow";
  src: url("/assets/fonts/barlow-600.woff2") format("woff2");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Barlow";
  src: url("/assets/fonts/barlow-700.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Barlow";
  src: url("/assets/fonts/barlow-800.woff2") format("woff2");
  font-weight: 800;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Barlow Fallback";
  src: local("Arial"), local("ArialMT");
  font-weight: 400 500;
  size-adjust: 95.3%;
  ascent-override: 104.9%;
  descent-override: 21%;
  line-gap-override: 0%;
}
@font-face {
  font-family: "Barlow Fallback";
  src: local("Arial Bold"), local("Arial-BoldMT");
  font-weight: 600 900;
  size-adjust: 93.1%;
  ascent-override: 107.5%;
  descent-override: 21.5%;
  line-gap-override: 0%;
}

:root {
  /* Brand colors */
  --navy: #12222E;
  --navy-raised: #1A2E3C;
  --bone: #F4F1EA;
  --bone-deep: #EAE6DC;
  --white: #FFFFFF;
  --paper-raised: #FAF8F3;
  --slate: #4E626B;          /* secondary text on light, 5.67:1 on bone */
  --mist: #A8B4BC;           /* secondary text on navy, 7.67:1 */
  --brick: #C7431D;          /* buttons; white text 4.94:1 */
  --brick-hover: #B03A17;
  --brick-text: #A83614;     /* brick as text on light, 5.81:1 */
  --amber: #C8843A;          /* accent on navy only, 5.27:1 */
  --sms-green: #2F7D3C;
  --bubble-in: #E8E5DC;
  --tint-brick: #FBF1EC;

  --line: rgba(18, 34, 46, 0.12);
  --line-strong: rgba(18, 34, 46, 0.24);
  --field-border: #7A858D;   /* 3.6:1 on white, meets the 3:1 rule for form controls */
  --line-on-navy: rgba(244, 241, 234, 0.16);

  /* Type */
  --font: "Barlow", "Barlow Fallback", system-ui, sans-serif;
  --text-xs: 0.8125rem;
  --text-sm: 0.9375rem;
  --text-base: 1.0625rem;
  --text-md: 1.25rem;
  --text-lg: clamp(1.75rem, 1.25rem + 2vw, 2.5rem);
  --text-xl: clamp(2.5rem, 1.5rem + 4vw, 3.875rem);
  --text-stat: clamp(2.75rem, 2rem + 3vw, 4rem);

  /* Spacing (4px base) */
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.5rem;
  --space-6: 2rem;
  --space-7: 3rem;
  --space-8: 4rem;
  --space-9: 6rem;

  --radius-sm: 6px;
  --radius: 10px;
  --radius-lg: 16px;
  --radius-pill: 999px;
  --shadow: 0 1px 2px rgba(18, 34, 46, 0.06), 0 4px 16px rgba(18, 34, 46, 0.05);
  --shadow-lift: 0 2px 4px rgba(18, 34, 46, 0.08), 0 20px 48px rgba(0, 0, 0, 0.28);

  --z-sticky: 90;
  --z-nav: 100;
  --nav-h: 4.5rem;
  --container: 70rem;
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);

  interpolate-size: allow-keywords;
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--nav-h) + var(--space-4));
  -webkit-text-size-adjust: 100%;
}

body {
  background: var(--bone);
  color: var(--navy);
  font-family: var(--font);
  font-size: var(--text-base);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img, svg, picture { display: block; max-width: 100%; }
input, button, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
h1, h2, h3 { line-height: 1.12; text-wrap: balance; }
p { text-wrap: pretty; }
ul[class], ol[class] { list-style: none; padding: 0; }
a { color: var(--brick-text); }
a[href^="tel:"], a[href^="sms:"] { white-space: nowrap; }
::selection { background: rgba(199, 67, 29, 0.2); }

:focus-visible {
  outline: 2px solid var(--brick);
  outline-offset: 3px;
  border-radius: 2px;
}
.on-navy :focus-visible { outline-color: var(--amber); }

/* Layout */
.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--space-5);
}

.section { padding-block: var(--space-9); }
.section--white {
  background: var(--white);
  border-block: 1px solid var(--line);
}

.h2 {
  font-size: var(--text-lg);
  font-weight: 800;
  letter-spacing: -0.015em;
  max-width: 26ch;
  margin-bottom: var(--space-4);
}
.lede {
  color: var(--slate);
  font-size: var(--text-md);
  line-height: 1.5;
  max-width: 38rem;
}
.section-head { margin-bottom: var(--space-7); }
.section-head--center { text-align: center; }
.section-head--center .h2, .section-head--center .lede { margin-inline: auto; }

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  min-height: 3rem;
  padding: var(--space-3) var(--space-5);
  border: 1px solid transparent;
  border-radius: var(--radius);
  font-size: var(--text-base);
  font-weight: 700;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
  white-space: nowrap;
  transition: background-color 150ms var(--ease), border-color 150ms var(--ease), color 150ms var(--ease);
}
.btn--primary { background: var(--brick); color: var(--white); }
.btn--primary:hover { background: var(--brick-hover); }
.btn--ghost { background: transparent; color: var(--navy); border-color: var(--line-strong); }
.btn--ghost:hover { border-color: var(--navy); }
.on-navy .btn--ghost { color: var(--bone); border-color: rgba(244, 241, 234, 0.45); }
.on-navy .btn--ghost:hover { border-color: var(--bone); }
.btn--sm { min-height: 2.5rem; padding: var(--space-2) var(--space-4); font-size: var(--text-sm); }
.btn--block { width: 100%; }

.icon { width: 1.125rem; height: 1.125rem; flex-shrink: 0; }

/* Inline facts row: "Flat monthly fee · No contracts · Cancel anytime" */
.facts {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-1) var(--space-3);
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--slate);
}
.facts li { display: inline-flex; align-items: center; gap: var(--space-3); }
.facts li + li::before {
  content: "";
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: currentColor;
  opacity: 0.6;
}
.on-navy .facts { color: var(--mist); }

/* Watched by JS to tell when the page has scrolled under the sticky nav */
.nav-sentinel { position: absolute; top: 0; left: 0; width: 1px; height: 1px; pointer-events: none; }

/* Skip link */
.skip-link {
  position: absolute;
  top: var(--space-2);
  left: var(--space-2);
  z-index: calc(var(--z-nav) + 1);
  padding: var(--space-2) var(--space-4);
  background: var(--white);
  color: var(--navy);
  font-weight: 700;
  border-radius: var(--radius-sm);
  transform: translateY(-200%);
}
.skip-link:focus-visible { transform: none; }

/* Nav */
.site-nav {
  position: sticky;
  top: 0;
  z-index: var(--z-nav);
  background: var(--navy);
  color: var(--bone);
  border-bottom: 1px solid transparent;
  transition: border-color 200ms var(--ease);
}
.site-nav.is-stuck { border-bottom-color: var(--line-on-navy); }
.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-5);
  height: var(--nav-h);
}

.wordmark {
  display: inline-flex;
  align-items: center;
  gap: var(--space-3);
  color: inherit;
  text-decoration: none;
  white-space: nowrap;
}
.wordmark__mark { width: 1.25rem; height: 1.25rem; color: var(--amber); }
.wordmark__name {
  display: inline-flex;
  align-items: baseline;
  gap: 0.45em;
  font-size: 1.0625rem;
  font-weight: 700;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}
.wordmark__name span { font-size: 0.82em; font-weight: 400; color: var(--mist); }

.nav-links {
  display: flex;
  align-items: center;
  gap: var(--space-5);
  padding: 0;
  list-style: none;
}
.nav-links a:not(.btn) {
  display: inline-block;
  padding-block: var(--space-2);
  color: var(--mist);
  font-size: var(--text-sm);
  font-weight: 600;
  text-decoration: none;
  transition: color 150ms var(--ease);
}
.nav-links a:not(.btn):hover { color: var(--bone); }
.nav-links .nav-phone { color: var(--bone); font-variant-numeric: tabular-nums; }

.menu-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  width: 2.75rem;
  height: 2.75rem;
  margin-right: calc(var(--space-2) * -1);
  background: none;
  border: 0;
  color: var(--bone);
}
.menu-toggle__bars, .menu-toggle__bars::before, .menu-toggle__bars::after {
  display: block;
  width: 1.375rem;
  height: 2px;
  background: currentColor;
  border-radius: 2px;
  transition: transform 200ms var(--ease), opacity 200ms var(--ease);
}
.menu-toggle__bars { position: relative; }
.menu-toggle__bars::before, .menu-toggle__bars::after { content: ""; position: absolute; left: 0; }
.menu-toggle__bars::before { top: -7px; }
.menu-toggle__bars::after { top: 7px; }
.menu-toggle[aria-expanded="true"] .menu-toggle__bars { background: transparent; }
.menu-toggle[aria-expanded="true"] .menu-toggle__bars::before { transform: translateY(7px) rotate(45deg); }
.menu-toggle[aria-expanded="true"] .menu-toggle__bars::after { transform: translateY(-7px) rotate(-45deg); }

.mobile-menu {
  display: none;
  padding: var(--space-2) var(--space-5) var(--space-5);
  border-top: 1px solid var(--line-on-navy);
}
.mobile-menu ul { display: grid; gap: 0; }
.mobile-menu a:not(.btn) {
  display: block;
  padding-block: var(--space-4);
  border-bottom: 1px solid var(--line-on-navy);
  color: var(--bone);
  font-size: var(--text-md);
  font-weight: 600;
  text-decoration: none;
}
.mobile-menu .btn { margin-top: var(--space-5); width: 100%; }

/* Hero */
.hero {
  background: var(--navy);
  color: var(--bone);
  padding-block: var(--space-8) var(--space-9);
}
.hero__grid {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: var(--space-8);
  align-items: center;
}
.hero h1 {
  font-size: var(--text-xl);
  font-weight: 800;
  letter-spacing: -0.025em;
  line-height: 1.02;
  margin-bottom: var(--space-5);
}
.hero__sub {
  color: var(--mist);
  font-size: var(--text-md);
  line-height: 1.5;
  max-width: 32rem;
  margin-bottom: var(--space-6);
}
.hero__actions { display: flex; flex-wrap: wrap; gap: var(--space-3); margin-bottom: var(--space-4); }
.hero__promise {
  display: flex;
  align-items: flex-start;
  gap: var(--space-2);
  color: var(--bone);
  font-weight: 600;
  margin-bottom: var(--space-2);
}
.hero__promise .icon { color: var(--amber); margin-top: 0.2em; }
.hero__proof {
  display: inline-flex;
  align-items: center;
  gap: var(--space-3);
  margin-top: var(--space-6);
  padding: var(--space-2) var(--space-4);
  border: 1px solid var(--line-on-navy);
  border-radius: var(--radius-pill);
  background: rgba(244, 241, 234, 0.05);
  color: var(--bone);
  font-size: var(--text-sm);
  font-weight: 600;
  text-decoration: none;
  transition: border-color 150ms var(--ease);
}
.hero__proof:hover { border-color: rgba(244, 241, 234, 0.4); }
.hero__proof .icon { color: var(--amber); width: 1rem; height: 1rem; }
.hero__proof .arrow { color: var(--mist); }
.hero__where { margin-top: var(--space-4); color: var(--mist); font-size: var(--text-sm); }

/* Sample texts: tabs plus a phone thread */
.samples { max-width: 25rem; margin-inline: auto; width: 100%; }
.samples__tabs {
  display: flex;
  gap: var(--space-1);
  padding: var(--space-1);
  margin-bottom: var(--space-4);
  border-radius: var(--radius);
  background: rgba(244, 241, 234, 0.06);
  border: 1px solid var(--line-on-navy);
  flex-wrap: wrap;
}
.samples__tab {
  flex: 1 1 auto;
  padding: var(--space-2);
  border: 0;
  border-radius: var(--radius-sm);
  background: transparent;
  color: var(--mist);
  font-size: var(--text-sm);
  font-weight: 600;
  transition: background-color 150ms var(--ease), color 150ms var(--ease);
}
.samples__tab:hover { color: var(--bone); }
.samples__tab[aria-selected="true"] { background: var(--bone); color: var(--navy); }

.phone {
  background: var(--white);
  color: var(--navy);
  border-radius: 1.75rem;
  box-shadow: var(--shadow-lift);
  overflow: hidden;
}
.phone__bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-3) var(--space-4);
  background: var(--paper-raised);
  border-bottom: 1px solid var(--line);
  font-size: var(--text-sm);
  font-weight: 700;
}
.phone__bar span { font-size: var(--text-xs); font-weight: 600; color: var(--slate); }
.thread {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  min-height: 19rem;
  padding: var(--space-4);
}
.bubble {
  max-width: 85%;
  padding: var(--space-3) var(--space-4);
  border-radius: 1.125rem;
  font-size: var(--text-sm);
  line-height: 1.45;
}
.bubble--sent { align-self: flex-start; background: var(--bubble-in); border-bottom-left-radius: var(--radius-sm); }
.bubble--reply { align-self: flex-end; background: var(--sms-green); color: var(--white); border-bottom-right-radius: var(--radius-sm); }
.thread__booked {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  align-self: center;
  margin-top: auto;
  padding: var(--space-1) var(--space-3);
  border-radius: var(--radius-pill);
  background: var(--tint-brick);
  color: var(--brick-text);
  font-size: var(--text-xs);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}
.thread__booked .icon { width: 0.875rem; height: 0.875rem; }
.samples__note { margin-top: var(--space-4); color: var(--mist); font-size: var(--text-sm); text-align: center; }

/* How it works: dated timeline */
.timeline {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: var(--space-5);
  counter-reset: none;
}
.timeline li {
  position: relative;
  padding-top: var(--space-6);
  border-top: 2px solid var(--line);
}
.timeline li::before {
  content: "";
  position: absolute;
  top: -7px;
  left: 0;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--white);
  border: 2px solid var(--brick);
}
.timeline__when {
  display: block;
  color: var(--brick-text);
  font-size: var(--text-xs);
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-bottom: var(--space-2);
  font-variant-numeric: tabular-nums;
}
.timeline h3 { font-size: var(--text-md); font-weight: 700; margin-bottom: var(--space-2); }
.timeline p { color: var(--slate); font-size: var(--text-sm); }
.timeline__time {
  display: inline-block;
  margin-top: var(--space-3);
  padding: 2px var(--space-2);
  border-radius: var(--radius-sm);
  background: var(--bone-deep);
  color: var(--navy);
  font-size: var(--text-xs);
  font-weight: 700;
}
.timeline-total {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: var(--space-2) var(--space-4);
  margin-top: var(--space-7);
  padding-top: var(--space-5);
  border-top: 1px solid var(--line);
  font-size: var(--text-md);
}
.timeline-total strong { font-weight: 800; }
.timeline-total span { color: var(--slate); font-size: var(--text-base); }

/* Pitch statement */
.pitch { text-align: center; }
.pitch h2 {
  font-size: var(--text-lg);
  font-weight: 800;
  letter-spacing: -0.015em;
  max-width: 44rem;
  margin: 0 auto var(--space-5);
}
.pitch p { color: var(--slate); font-size: var(--text-md); line-height: 1.55; max-width: 40rem; margin-inline: auto; }

/* Results */
.results-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: var(--space-5);
  margin-bottom: var(--space-6);
}
.results-head .h2 { margin-bottom: 0; }
.as-of { color: var(--slate); font-size: var(--text-sm); font-weight: 600; }

.stats {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-5) var(--space-8);
  padding-block: var(--space-6);
  margin-bottom: var(--space-7);
  border-block: 1px solid var(--line);
}
.stats div { display: flex; flex-direction: column-reverse; }
.stats dt {
  color: var(--slate);
  font-size: var(--text-xs);
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.stats dd {
  font-size: var(--text-stat);
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.02em;
  margin-bottom: var(--space-2);
  font-variant-numeric: tabular-nums;
}

.quotes { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-5); align-items: start; }
.quote {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: var(--space-6);
  box-shadow: var(--shadow);
}
.quote__result {
  color: var(--brick-text);
  font-size: var(--text-xs);
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-bottom: var(--space-4);
}
.quote blockquote { font-size: var(--text-md); line-height: 1.5; margin-bottom: var(--space-5); }
.quote figcaption { color: var(--slate); font-size: var(--text-sm); line-height: 1.5; }
.quote figcaption strong { display: block; color: var(--navy); font-weight: 700; font-size: var(--text-base); }

/* Founder */
.founder {
  display: grid;
  grid-template-columns: minmax(0, 22rem) minmax(0, 1fr);
  gap: var(--space-8);
  align-items: center;
}
.founder__photo img {
  width: 100%;
  height: auto;
  border-radius: var(--radius-lg);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  background: var(--bone-deep);
}
.founder__copy > p { color: var(--slate); font-size: var(--text-md); line-height: 1.55; margin-bottom: var(--space-6); max-width: 36rem; }
.checklist { display: grid; max-width: 36rem; }
.checklist li {
  display: flex;
  gap: var(--space-3);
  padding-block: var(--space-4);
  border-top: 1px solid var(--line);
  line-height: 1.5;
}
.checklist li:last-child { border-bottom: 1px solid var(--line); }
.checklist .icon { color: var(--brick); margin-top: 0.2em; }

/* Pricing: calculator beside the tier table */
.pricing {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: var(--space-6);
  align-items: start;
}
.card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: var(--space-6);
  box-shadow: var(--shadow);
}
.card__title { font-size: var(--text-md); font-weight: 800; margin-bottom: var(--space-1); }
.card__sub { color: var(--slate); font-size: var(--text-sm); margin-bottom: var(--space-5); }

.calc__fields { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-4); margin-bottom: var(--space-5); }
.calc__fields .field--full { grid-column: 1 / -1; }
.calc__out {
  display: grid;
  gap: var(--space-4);
  padding: var(--space-5);
  border-radius: var(--radius);
  background: var(--navy);
  color: var(--bone);
}
.calc__row { display: flex; align-items: baseline; justify-content: space-between; gap: var(--space-4); }
.calc__row dt { color: var(--mist); font-size: var(--text-sm); }
.calc__row dd { font-size: var(--text-md); font-weight: 800; font-variant-numeric: tabular-nums; text-align: right; }
.calc__row--plan { padding-top: var(--space-4); border-top: 1px solid var(--line-on-navy); }
.calc__row--plan dd small { display: block; color: var(--amber); font-size: var(--text-sm); font-weight: 600; }
.calc__why { margin-top: var(--space-4); font-size: var(--text-sm); color: var(--slate); }
.calc__why summary { font-weight: 600; color: var(--navy); cursor: pointer; width: fit-content; }
.calc__why p { margin-top: var(--space-2); }
.calc__send { margin-top: var(--space-5); }

.tier-lede { color: var(--slate); font-size: var(--text-sm); margin-bottom: var(--space-4); }
.tier-lede strong { color: var(--navy); }
.tiers { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
.tiers th {
  padding: 0 var(--space-3) var(--space-3);
  border-bottom: 1px solid var(--line-strong);
  color: var(--slate);
  font-size: var(--text-xs);
  font-weight: 700;
  letter-spacing: 0.06em;
  text-align: left;
  text-transform: uppercase;
}
.tiers th:last-child, .tiers td:last-child { text-align: right; }
.tiers td {
  padding: var(--space-3);
  border-bottom: 1px solid var(--line);
  transition: background-color 200ms var(--ease);
}
.tiers tbody tr:last-child td { border-bottom: 0; }
.tiers td:last-child { font-size: var(--text-md); font-weight: 800; white-space: nowrap; }
.tiers td small { color: var(--slate); font-size: var(--text-sm); font-weight: 600; }
.tiers tr.is-match td { background: var(--tint-brick); }
.tiers tr.is-match td:first-child { box-shadow: inset 3px 0 0 var(--brick); }
.tier-flag {
  margin-left: var(--space-2);
  padding: 1px var(--space-2);
  border-radius: var(--radius-sm);
  background: var(--brick);
  color: var(--white);
  font-size: var(--text-xs);
  font-weight: 700;
  vertical-align: 1px;
}

.promise {
  margin-top: var(--space-5);
  padding: var(--space-5);
  border-radius: var(--radius);
  background: var(--tint-brick);
  border: 1px solid rgba(199, 67, 29, 0.22);
}
.promise h3 { font-size: var(--text-base); font-weight: 800; margin-bottom: var(--space-2); }
.promise p { font-size: var(--text-sm); line-height: 1.55; }
.promise__sign { margin-top: var(--space-3); font-weight: 700; }
.promise__sign span { color: var(--slate); font-weight: 400; }
.pricing__cta { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-4); margin-top: var(--space-5); }

/* Comparison table */
.table-scroll {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--white);
}
.compare { width: 100%; min-width: 46rem; border-collapse: collapse; font-size: var(--text-sm); }
.compare th, .compare td { padding: var(--space-4); text-align: left; vertical-align: top; border-bottom: 1px solid var(--line); }
.compare tbody tr:last-child > * { border-bottom: 0; }
.compare thead th { font-size: var(--text-base); font-weight: 800; background: var(--paper-raised); }
.compare tbody th { width: 11rem; color: var(--slate); font-weight: 600; }
.compare .is-us { background: var(--tint-brick); font-weight: 600; }
.compare thead .is-us { background: var(--navy); color: var(--bone); }
.compare tbody th, .compare thead th:first-child {
  position: sticky;
  left: 0;
  z-index: 1;
  background: var(--white);
}
.compare thead th:first-child { background: var(--paper-raised); }
.table-note { margin-top: var(--space-4); color: var(--slate); font-size: var(--text-sm); }

/* Who it's for */
.who { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-8); }
.who h3 {
  color: var(--slate);
  font-size: var(--text-xs);
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-bottom: var(--space-3);
}
.plain-list li { padding-block: var(--space-3); border-top: 1px solid var(--line); font-weight: 600; }
.plain-list li:last-child { border-bottom: 1px solid var(--line); }
.plain-list small { display: block; color: var(--slate); font-size: var(--text-sm); font-weight: 400; }
.who-note {
  margin-top: var(--space-7);
  padding-left: var(--space-4);
  border-left: 3px solid var(--brick);
  color: var(--slate);
}

/* FAQ: native details/summary */
.faq { max-width: 48rem; border-top: 1px solid var(--line-strong); }
.faq details { border-bottom: 1px solid var(--line-strong); }
.faq summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-5);
  padding: var(--space-5) var(--space-2);
  cursor: pointer;
  list-style: none;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary h3 { font-size: var(--text-md); font-weight: 700; }
.faq summary::after {
  content: "";
  flex-shrink: 0;
  width: 0.875rem;
  height: 0.875rem;
  background: var(--brick);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 14 9'%3E%3Cpath d='M1 1l6 6 6-6' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 14 9'%3E%3Cpath d='M1 1l6 6 6-6' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / contain no-repeat;
  transition: transform 200ms var(--ease);
}
.faq details[open] summary::after { transform: rotate(180deg); }
.faq details::details-content {
  block-size: 0;
  overflow: hidden;
  transition: block-size 250ms var(--ease), content-visibility 250ms allow-discrete;
}
.faq details[open]::details-content { block-size: auto; }
.faq details p { padding: 0 var(--space-2) var(--space-5); color: var(--slate); max-width: 44rem; }

/* Contact */
.contact {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: var(--space-8);
  align-items: start;
}
.contact__ways { display: grid; gap: var(--space-3); margin-block: var(--space-6); }
.way {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-4);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
}
.way > .icon { color: var(--brick); }
.way__link { flex: 1; color: var(--navy); font-weight: 700; text-decoration: none; }
.way__link span { display: block; color: var(--slate); font-size: var(--text-sm); font-weight: 400; font-variant-numeric: tabular-nums; }
.way__link:hover { color: var(--brick-text); }
.copy-btn {
  padding: var(--space-1) var(--space-3);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  background: transparent;
  color: var(--slate);
  font-size: var(--text-xs);
  font-weight: 700;
}
.copy-btn:hover { color: var(--navy); border-color: var(--navy); }
.contact__meta { color: var(--slate); font-size: var(--text-sm); }

.form { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-4) var(--space-4); }
.form__note { grid-column: 1 / -1; color: var(--slate); font-size: var(--text-sm); }
.field { display: flex; flex-direction: column; gap: var(--space-2); }
.field--full { grid-column: 1 / -1; }
.field label { font-size: var(--text-sm); font-weight: 700; }
.field label .req { color: var(--brick-text); }
.field input, .field select, .field textarea {
  width: 100%;
  min-height: 3rem;
  padding: var(--space-3) var(--space-4);
  border: 1px solid var(--field-border);
  border-radius: var(--radius-sm);
  background: var(--white);
  color: var(--navy);
  font-size: 1rem;
  appearance: none;
  transition: border-color 150ms var(--ease), box-shadow 150ms var(--ease);
}
.field input:focus-visible, .field select:focus-visible, .field textarea:focus-visible {
  outline: 2px solid var(--brick);
  outline-offset: 0;
  border-color: var(--brick);
}
.field select {
  padding-right: var(--space-7);
  background: var(--white) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%234E626B' stroke-width='2' fill='none' stroke-linecap='round'/%3E%3C/svg%3E") no-repeat right var(--space-4) center;
}
.field textarea { min-height: 7rem; resize: vertical; }
.field ::placeholder { color: #69787F; }
.field [aria-invalid="true"] { border-color: var(--brick); box-shadow: 0 0 0 1px var(--brick); }
.field__hint { color: var(--slate); font-size: var(--text-xs); }
.field__error { color: var(--brick-text); font-size: var(--text-sm); font-weight: 600; }
.field__prefix { position: relative; }
.field__prefix::before {
  content: "$";
  position: absolute;
  left: var(--space-4);
  top: 50%;
  transform: translateY(-50%);
  color: var(--slate);
  font-weight: 600;
  pointer-events: none;
}
.field__prefix input { padding-left: calc(var(--space-4) + 0.625rem); }
.form__actions { grid-column: 1 / -1; display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-4); }
.form__status { grid-column: 1 / -1; color: var(--brick-text); font-weight: 600; }
.form-success { text-align: center; padding: var(--space-7) var(--space-5); }
.form-success__mark {
  display: grid;
  place-items: center;
  width: 3.5rem;
  height: 3.5rem;
  margin: 0 auto var(--space-5);
  border-radius: 50%;
  background: var(--tint-brick);
  color: var(--brick);
}
.form-success h3 { font-size: var(--text-lg); font-weight: 800; margin-bottom: var(--space-2); }
.form-success h3:focus { outline: none; }
.form-success p { color: var(--slate); }

/* Footer */
.site-footer { background: var(--navy); color: var(--mist); padding-block: var(--space-7); font-size: var(--text-sm); }
.site-footer__inner { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--space-4) var(--space-6); }
.site-footer .wordmark { color: var(--bone); }
.site-footer ul { display: flex; flex-wrap: wrap; gap: var(--space-1) var(--space-5); padding: 0; list-style: none; }
.site-footer ul a { display: inline-block; padding-block: var(--space-1); color: var(--mist); text-decoration: none; font-variant-numeric: tabular-nums; }
.site-footer ul a:hover, .site-footer ul a[aria-current="page"] { color: var(--bone); }

/* Sticky mobile bar */
.sticky-bar {
  display: none;
  position: fixed;
  inset: auto 0 0 0;
  z-index: var(--z-sticky);
  gap: var(--space-2);
  padding: var(--space-2) var(--space-4) calc(var(--space-2) + env(safe-area-inset-bottom));
  background: var(--white);
  border-top: 1px solid var(--line);
  box-shadow: 0 -4px 16px rgba(18, 34, 46, 0.08);
  transform: translateY(110%);
  visibility: hidden;
  transition: transform 200ms var(--ease), visibility 200ms;
}
.sticky-bar.is-visible { transform: none; visibility: visible; }
.sticky-bar .btn { min-height: 2.75rem; padding-inline: var(--space-4); font-size: var(--text-sm); }
.sticky-bar .btn--primary { flex: 1; }

/* Legal and utility pages */
.page { padding-block: var(--space-8) var(--space-9); }
.prose { max-width: 44rem; }
.prose h1 { font-size: var(--text-lg); font-weight: 800; letter-spacing: -0.015em; margin-bottom: var(--space-2); }
.prose .updated { color: var(--slate); font-size: var(--text-sm); margin-bottom: var(--space-7); }
.prose h2 { font-size: var(--text-md); font-weight: 700; margin: var(--space-7) 0 var(--space-3); }
.prose p, .prose li { color: var(--slate); }
.prose p + p { margin-top: var(--space-3); }
.prose ul { padding-left: var(--space-5); margin-top: var(--space-3); }
.prose li + li { margin-top: var(--space-2); }
.prose strong { color: var(--navy); }
.prose a { font-weight: 600; }

.center-page {
  min-height: 70vh;
  display: grid;
  place-items: center;
  text-align: center;
  padding: var(--space-8) var(--space-5);
}
.center-page h1 { font-size: var(--text-lg); font-weight: 800; margin-bottom: var(--space-3); }
.center-page p { color: var(--slate); margin-bottom: var(--space-6); max-width: 30rem; margin-inline: auto; }
.center-page .mark { width: 3rem; height: 3rem; margin: 0 auto var(--space-6); color: var(--navy); }

/* Utilities */
.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}
.tabular { font-variant-numeric: tabular-nums; }
[hidden] { display: none !important; }

/* Breakpoints */
@media (max-width: 61.25em) { /* 980px */
  .hero__grid, .founder, .contact, .pricing { grid-template-columns: 1fr; }
  .hero__grid { gap: var(--space-7); }
  .founder__photo { max-width: 20rem; }
  .quotes { grid-template-columns: 1fr; }
  .timeline { grid-template-columns: 1fr; gap: 0; }
  .timeline li { border-top: 0; border-left: 2px solid var(--line); padding: 0 0 var(--space-6) var(--space-6); }
  .timeline li:last-child { padding-bottom: 0; }
  .timeline li::before { top: 0.15rem; left: -7px; }
  .nav-links .nav-anchor { display: none; }
}

@media (max-width: 51.25em) { /* 820px */
  :root { --nav-h: 4rem; }
  .section { padding-block: var(--space-8); }
  .hero { padding-block: var(--space-6) var(--space-8); }
  .nav-links { display: none; }
  .menu-toggle { display: inline-flex; }
  .site-nav.is-open .mobile-menu { display: block; }
  .who, .calc__fields, .form { grid-template-columns: 1fr; }
  .who { gap: var(--space-6); }
  .card { padding: var(--space-5); }
  .hero__actions .btn { flex: 1 1 12rem; }
  .sticky-bar { display: flex; }
  .site-footer { padding-bottom: calc(var(--space-7) + 4rem); }
  .site-footer__inner { flex-direction: column; align-items: flex-start; }
}

@media (hover: none) {
  .copy-btn { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
