:root {
  --paper: #ffffff;
  --wash: #f2f5f9;
  --navy: #0d2342;
  --navy-2: #17335c;
  --ink: #0d1b2e;
  --muted: #4a5a72;
  --line: #d5dde9;
  --field: #7a8aa3;
  --done: #16744a;
  --done-soft: #e2f3ea;
  --on-navy: #c6d3e6;
  --focus: #2f7bd8;
  --serif: "Newsreader", Georgia, "Times New Roman", serif;
  --sans: "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 400 17px/1.6 var(--sans);
  -webkit-font-smoothing: antialiased;
}
img, svg { max-width: 100%; height: auto; display: block; }
a { color: var(--navy-2); }
p { margin: 0; }
h1, h2, h3 {
  font-family: var(--serif);
  font-weight: 400;
  letter-spacing: -0.01em;
  line-height: 1.06;
  margin: 0;
  color: var(--navy);
}
h1 { font-size: clamp(2.6rem, 6vw, 5.2rem); }
h2 { font-size: clamp(2rem, 4vw, 3.3rem); }
h3 { font-size: 1.5rem; line-height: 1.2; }
.num { font-variant-numeric: tabular-nums; }
.wrap { width: min(1180px, calc(100% - 32px)); margin-inline: auto; }
.skip-link { position: absolute; left: -999px; top: 8px; display: flex; align-items: center; min-height: 44px; }
.skip-link:focus { left: 16px; background: var(--navy); color: #fff; padding: 10px 14px; z-index: 10; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; }

/* header */
.site-header { border-bottom: 1px solid var(--line); background: var(--paper); }
.bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 72px; }
.brand { display: inline-flex; align-items: center; gap: 10px; font-family: var(--serif); font-size: 1.6rem; color: var(--navy); text-decoration: none; min-height: 44px; }
.brand svg { width: 30px; height: 30px; }
.header-cta { min-height: 44px; padding: 0 16px; white-space: nowrap; }
.header-tools { display: flex; align-items: center; gap: 10px; }
.nav-disclosure { position: relative; }
.nav-disclosure summary { list-style: none; cursor: pointer; display: inline-flex; align-items: center; min-height: 44px; padding: 0 16px; border: 1px solid var(--navy); border-radius: 6px; color: var(--navy); font-weight: 600; }
.nav-disclosure summary::-webkit-details-marker { display: none; }
.site-nav { position: absolute; right: 0; top: calc(100% + 8px); z-index: 5; display: flex; flex-direction: column; min-width: 230px; padding: 8px; background: var(--paper); border: 1px solid var(--line); border-radius: 8px; box-shadow: 0 18px 40px -20px rgba(13, 35, 66, 0.35); }
.site-nav a { display: flex; align-items: center; min-height: 44px; padding: 0 12px; color: var(--ink); text-decoration: none; border-radius: 6px; }
.site-nav a:hover { background: var(--wash); }
.site-nav a[aria-current="page"] { color: var(--navy); font-weight: 600; box-shadow: inset 3px 0 0 var(--done); }

/* buttons and links */
.button { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: 0 22px; background: var(--navy); color: #fff; font-weight: 600; text-decoration: none; border-radius: 6px; border: 1px solid var(--navy); }
.button:hover { background: var(--navy-2); }
.button.ghost { background: transparent; color: var(--navy); }
.button.ghost:hover { background: var(--wash); }
.text-link { display: inline-flex; align-items: center; min-height: 48px; color: var(--navy); font-weight: 600; text-decoration: underline; text-decoration-thickness: 1.5px; text-underline-offset: 5px; }
.actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 24px; margin-top: 32px; }
.eyebrow { font-size: 0.95rem; font-weight: 600; color: var(--done); margin-bottom: 18px; }
.lede { font-size: 1.2rem; color: var(--muted); max-width: 36em; margin-top: 24px; }
.flush { margin-top: 0; }
.flush.section-head { margin-bottom: 0; }
.footer-cta { margin-top: 16px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.micro { color: var(--muted); font-size: 0.95rem; margin-top: 20px; }

/* sections */
.section { padding: 84px 0; border-top: 1px solid var(--line); }
.section.wash { background: var(--wash); }
.section.navy { background: var(--navy); color: #fff; border-top: 0; }
.section.navy h2, .section.navy h3 { color: #fff; }
.section.navy .lede, .section.navy p { color: var(--on-navy); }
.section-head { display: grid; gap: 16px; align-content: start; max-width: 46em; margin-bottom: 48px; }
.section-head p { color: var(--muted); font-size: 1.1rem; }
.split { display: grid; gap: 40px; }
.stack { display: grid; gap: 20px; }

.steps { list-style: none; margin: 0; padding: 0; }
.steps li { display: grid; grid-template-columns: 64px 1fr; gap: 12px 20px; padding: 28px 0; border-top: 1px solid var(--line); }
.steps li:last-child { border-bottom: 1px solid var(--line); }
.steps .n { font-family: var(--serif); font-size: 2.6rem; line-height: 1; color: var(--done); font-variant-numeric: tabular-nums; }
.steps h3 { margin-bottom: 8px; }
.steps p { color: var(--muted); }

.rows { list-style: none; margin: 0; padding: 0; }
.rows li { display: grid; gap: 8px; padding: 26px 0; border-top: 1px solid var(--line); }
.rows li:last-child { border-bottom: 1px solid var(--line); }
.rows h3 { font-size: 1.6rem; }
.rows p { color: var(--muted); max-width: 40em; }

.stats { display: grid; gap: 36px; }
.stat-value { font-family: var(--serif); font-size: clamp(3.2rem, 7vw, 5.6rem); line-height: 1; color: #fff; font-variant-numeric: tabular-nums; }
.stat-label { color: var(--on-navy); margin-top: 12px; max-width: 16em; }

.names { display: flex; flex-wrap: wrap; gap: 12px 40px; list-style: none; padding: 0; margin: 0; }
.names li { font-family: var(--serif); font-size: clamp(1.3rem, 2.4vw, 1.8rem); color: var(--navy); }

/* ledger (home hero) */
.ledger { background: var(--paper); border: 1px solid var(--line); border-radius: 10px; box-shadow: 0 30px 60px -36px rgba(13, 35, 66, 0.45); overflow: hidden; }
.ledger-head { display: flex; justify-content: space-between; gap: 12px; padding: 16px 20px; border-bottom: 1px solid var(--line); font-weight: 600; font-size: 0.95rem; color: var(--navy); }
.ledger-head span:last-child { color: var(--muted); font-weight: 400; }
.ledger-row { display: grid; grid-template-columns: 1fr auto auto; gap: 8px 16px; align-items: center; padding: 14px 20px; border-bottom: 1px solid var(--line); font-size: 0.95rem; }
.ledger-row small { display: block; color: var(--muted); font-size: 0.82rem; }
.amount { font-variant-numeric: tabular-nums; text-align: right; white-space: nowrap; }
.state { display: inline-flex; align-items: center; gap: 8px; font-size: 0.85rem; font-weight: 600; color: var(--done); white-space: nowrap; }
.state::before { content: ""; width: 18px; height: 18px; border-radius: 50%; background: var(--done) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 18 18'%3E%3Cpath d='M5 9.4l2.6 2.5L13 6.4' fill='none' stroke='%23ffffff' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 18px 18px no-repeat; flex: none; }
.state.open { color: var(--navy); }
.state.open::before { background: var(--paper); box-shadow: inset 0 0 0 2px var(--navy); }
.ledger-total { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; padding: 20px; background: var(--done-soft); }
.ledger-total strong { font-family: var(--serif); font-weight: 400; font-size: 1.9rem; color: var(--navy); font-variant-numeric: tabular-nums; }
.ledger-total span { font-weight: 600; color: var(--navy); }

/* table (compare) */
.compare { width: 100%; border-collapse: collapse; font-size: 0.98rem; }
.compare th, .compare td { text-align: left; padding: 18px 16px; border-bottom: 1px solid var(--line); vertical-align: top; }
.compare thead th { font-weight: 600; color: var(--navy); border-bottom: 2px solid var(--navy); }
.compare td.yes { color: var(--done); font-weight: 600; }
.compare td.no { color: var(--muted); }
.compare th.us, .compare td.us { background: var(--done-soft); }
.compare th:first-child, .compare td:first-child { width: 36%; }

/* pricing */
.plans { display: grid; gap: 20px; }
.plan { display: flex; flex-direction: column; gap: 20px; padding: 32px; border: 1px solid var(--line); border-radius: 10px; background: var(--paper); }
.plan .plan-name { font-size: 1.5rem; line-height: 1.2; color: var(--navy); }
.plan .price { font-family: var(--serif); font-size: 3.4rem; line-height: 1; color: var(--navy); font-variant-numeric: tabular-nums; }
.plan .price small { font-family: var(--sans); font-size: 1rem; color: var(--muted); }
.plan p.note { color: var(--muted); }
.plan.featured { background: var(--navy); border-color: var(--navy); color: #fff; }
.plan.featured .plan-name, .plan.featured .price { color: #fff; }
.plan.featured .price small, .plan.featured p.note { color: var(--on-navy); }
.plan.featured .button { background: #fff; color: var(--navy); border-color: #fff; }
.plan.featured .button:hover { background: var(--wash); }
.checks { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.checks li { display: grid; grid-template-columns: 22px 1fr; gap: 10px; }
.checks li::before { content: "\2713"; color: var(--done); font-weight: 600; }
.plan.featured .checks li::before { color: #8fd6ae; }
.plan .button { margin-top: auto; }

/* stories (customers) */
.story { display: grid; gap: 24px; padding: 48px 0; border-top: 1px solid var(--line); }
.story:last-child { border-bottom: 1px solid var(--line); }
.story .photo { width: 100%; aspect-ratio: 1 / 1; object-fit: cover; border-radius: 10px; background: var(--wash); }
.story blockquote { margin: 0; font-family: var(--serif); font-size: clamp(1.5rem, 2.6vw, 2rem); line-height: 1.25; color: var(--navy); }
.story cite { display: block; margin-top: 18px; font-style: normal; color: var(--muted); }
.story cite strong { color: var(--ink); }
.story .figure { font-family: var(--serif); font-size: clamp(2.6rem, 5vw, 4rem); line-height: 1; color: var(--done); font-variant-numeric: tabular-nums; }
.story .figure small { display: block; font-family: var(--sans); font-size: 1rem; color: var(--muted); margin-top: 10px; }

/* product */
.photo { width: 100%; height: auto; border-radius: 10px; border: 1px solid var(--line); }
.feature { display: grid; gap: 28px; align-items: center; }
.feature p { color: var(--muted); font-size: 1.08rem; margin-top: 16px; }
.match-demo { display: grid; gap: 12px; padding: 20px; border: 1px solid var(--line); border-radius: 10px; background: var(--wash); }
.match-demo div { display: grid; grid-template-columns: 1fr auto; gap: 8px 12px; align-items: center; padding: 12px 14px; background: var(--paper); border-radius: 6px; font-size: 0.95rem; }
.match-demo .amount { font-weight: 600; }

/* security */
.controls { display: grid; gap: 0; margin: 0; }
.controls div { display: grid; gap: 8px; padding: 26px 0; border-top: 1px solid var(--line); }
.controls div:last-child { border-bottom: 1px solid var(--line); }
.controls dt { font-family: var(--serif); font-size: 1.5rem; color: var(--navy); }
.controls dd { margin: 0; color: var(--muted); max-width: 40em; }

/* forms (slot fallback is shown; the form itself is only in the template) */
.slot { padding: 24px; border: 1px dashed var(--field); border-radius: 10px; background: var(--paper); }
.slot p + p { margin-top: 12px; }
.slot a { font-weight: 600; }
.demo-form label { display: block; margin-top: 18px; font-weight: 600; color: var(--navy); }
.demo-form input, .demo-form textarea { display: block; width: 100%; min-height: 48px; margin-top: 8px; padding: 10px 12px; font: inherit; color: var(--ink); background: var(--paper); border: 1px solid var(--field); border-radius: 6px; }
.demo-form textarea { min-height: 120px; }
.demo-form button { margin-top: 24px; }

/* footer */
.site-footer { background: var(--wash); border-top: 1px solid var(--line); padding: 64px 0 36px; }
.footer-grid { display: grid; gap: 32px; }
.footer-grid h2 { font-family: var(--sans); font-size: 0.95rem; font-weight: 600; letter-spacing: 0; color: var(--navy); margin-bottom: 12px; }
.footer-grid ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; }
.footer-grid a { display: inline-flex; align-items: center; min-height: 44px; color: var(--ink); }
.footer-grid a.button { color: #fff; }
.footer-grid p { color: var(--muted); }
.legal a { display: inline-flex; align-items: center; min-height: 44px; color: var(--navy); }
.legal { margin-top: 40px; padding-top: 20px; border-top: 1px solid var(--line); color: var(--muted); font-size: 0.9rem; display: flex; flex-wrap: wrap; gap: 8px 24px; }

/* not found */
.notfound { padding: 120px 0; text-align: left; }
.notfound p { color: var(--muted); font-size: 1.15rem; max-width: 34em; margin-top: 20px; }

/* page hero (inner pages) */
.page-hero { padding: 72px 0 56px; }
.page-hero .lede { margin-top: 24px; }
.page-hero.navy { background: var(--navy); color: #fff; }
.page-hero.navy h1 { color: #fff; }
.page-hero.navy .lede, .page-hero.navy .eyebrow { color: var(--on-navy); }
.page-hero.navy .eyebrow { color: #8fd6ae; }

/* small screens: stack the compare table into labelled rows */
@media (max-width: 759px) {
  .compare thead { display: none; }
  .compare, .compare tbody, .compare tr, .compare td { display: block; width: 100%; }
  .compare tr { padding: 18px 0; border-bottom: 1px solid var(--line); }
  .compare th:first-child, .compare td:first-child { width: 100%; }
  .compare td { border: 0; padding: 6px 0; }
  .compare td::before { content: attr(data-label); display: block; font-size: 0.85rem; color: var(--muted); }
  .compare td.us { background: none; }
  .compare th { display: block; width: 100%; padding: 0 0 6px; border: 0; font-weight: 600; color: var(--navy); }
}

@media (min-width: 760px) {
  .nav-disclosure summary { display: none; }
  .nav-disclosure { display: flex; align-items: center; gap: 28px; }
  .site-nav { position: static; flex-direction: row; gap: 4px; min-width: 0; padding: 0; border: 0; box-shadow: none; background: none; }
  .site-nav a { min-height: 44px; padding: 0 12px; }
  .stats { grid-template-columns: repeat(3, 1fr); }
  .plans { grid-template-columns: repeat(3, 1fr); align-items: stretch; }
  .footer-grid { grid-template-columns: 2fr 1fr 1fr 1fr; }
  .steps li { grid-template-columns: 90px 1fr 1fr; align-items: start; }
  .steps li > div { grid-column: 2 / 4; }
  .steps li h3 { margin: 0; }
  .rows li { grid-template-columns: 1fr 2fr; align-items: baseline; }
  .rows li > p { grid-column: 2; }
  .story { grid-template-columns: 260px 1fr 260px; align-items: start; }
  .story .photo { width: 260px; }
  .feature { grid-template-columns: 1fr 1fr; }
  .feature.reverse .feature-copy { order: 2; }
}

@media (min-width: 760px) and (max-width: 959px) { .site-nav a { padding: 0 8px; } .nav-disclosure { gap: 12px; } }
@media (max-width: 419px) { .header-cta { display: none; } }

@media (min-width: 960px) {
  .hero { grid-template-columns: 1.05fr 0.95fr; align-items: center; }
  .split { grid-template-columns: 0.8fr 1.2fr; gap: 72px; }
  .demo-grid { grid-template-columns: 1fr 1fr; gap: 72px; align-items: start; }
}

.hero { display: grid; gap: 52px; padding: 64px 0 80px; }

@supports (animation-timeline: view()) {
  .ledger-row { animation: settle linear both; animation-timeline: view(); animation-range: entry 0% cover 45%; }
  @keyframes settle {
    from { opacity: 0.35; transform: translateX(-8px); }
    to { opacity: 1; transform: none; }
  }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
