/*
 * Leascape marketing site.
 *
 * Colour tokens are copied from the app's shipped indigo palette
 * (Leascape.Web/src/styles/tokens.css, [data-palette='indigo'] blocks) so the site and the
 * product look like one brand. Keep them in sync by hand — there is no build step here.
 *
 * Same two-step accent contract as the app:
 *   --accent       decorative only (focus rings, lines, icons) — never body text.
 *   --accent-fill  anything carrying a label; pair with --on-accent, which flips to
 *                  near-black in dark mode because white on the lighter fill fails AA.
 */

/* Self-hosted variable fonts (SIL Open Font License; see assets/fonts/LICENSE-*.txt).
   Served from our own origin so no visitor's IP reaches a third-party font CDN. */
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url('/assets/fonts/inter-latin-wght-normal.woff2') format('woff2-variations');
}
@font-face {
  font-family: 'Newsreader';
  font-style: normal;
  font-weight: 200 800;
  font-display: swap;
  src: url('/assets/fonts/newsreader-latin-wght-normal.woff2') format('woff2-variations');
}

:root {
  --canvas: #fafbfd;
  --surface: #ffffff;
  --surface-sunken: #f1f4f9;
  --ink: #0e1a2b;
  --muted: #5c6e86;
  --border: #e1e7f0;
  --border-strong: #7e8fa9;

  --accent: #6a7fe0;
  --accent-fill: #2b4bd4;
  --accent-fill-hover: #1f39ae;
  --accent-subtle: #edf1fe;
  --on-accent: #ffffff;

  --success: #0f7a55;
  --success-subtle: #e6f6ef;
  --warning: #9a6100;
  --danger: #b23a2e;
  --danger-subtle: #fcecea;
  --amber: #b0640a;

  --mark-bg: #2b4bd4;
  --mark-fg: #ffffff;
  --mark-trend: #8aa4ff;

  --cta-bg: #0e1a2b;
  --cta-ink: #e9eef7;
  --cta-muted: #a9b6ca;

  --radius-sm: 6px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --radius-xl: 16px;

  --shadow-overlay: 0 1px 2px rgb(14 26 43 / 0.05), 0 8px 24px -6px rgb(14 26 43 / 0.12);
  --shadow-mock: 0 1px 2px rgb(14 26 43 / 0.06), 0 24px 60px -20px rgb(43 75 212 / 0.28);

  --duration-fast: 120ms;
  --duration-base: 160ms;
  --duration-slow: 200ms;
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);

  --font-sans: 'Inter', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', sans-serif;
  --font-display: 'Newsreader', ui-serif, Georgia, 'Times New Roman', serif;
  --font-mono: ui-monospace, 'Cascadia Mono', 'SF Mono', Menlo, Consolas, monospace;

  --gutter: 16px;
  --max: 1160px;

  color-scheme: light;
}

/* Dark tokens — applied by OS preference unless the visitor chose light, or by explicit choice. */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme='light']) {
    --canvas: #080d16;
    --surface: #0f1725;
    --surface-sunken: #05080e;
    --ink: #e9eef7;
    --muted: #8c9cb4;
    --border: #1e2a3c;
    --border-strong: #5c7096;
    --accent: #8aa4ff;
    --accent-fill: #7b96fa;
    --accent-fill-hover: #9bb0ff;
    --accent-subtle: #131f3d;
    --on-accent: #080d16;
    --success: #5fd3a2;
    --success-subtle: #0f2a20;
    --warning: #e3ae5a;
    --danger: #f08f80;
    --danger-subtle: #2a1512;
    --amber: #bf7a38;
    --mark-bg: #7b96fa;
    --mark-fg: #080d16;
    --mark-trend: #1f39ae;
    --cta-bg: #0f1725;
    --cta-ink: #e9eef7;
    --cta-muted: #8c9cb4;
    --shadow-overlay: 0 1px 2px rgb(0 0 0 / 0.35), 0 8px 24px -6px rgb(0 0 0 / 0.55);
    --shadow-mock: 0 1px 2px rgb(0 0 0 / 0.4), 0 24px 60px -20px rgb(0 0 0 / 0.7);
    color-scheme: dark;
  }
}
:root[data-theme='dark'] {
  --canvas: #080d16;
  --surface: #0f1725;
  --surface-sunken: #05080e;
  --ink: #e9eef7;
  --muted: #8c9cb4;
  --border: #1e2a3c;
  --border-strong: #5c7096;
  --accent: #8aa4ff;
  --accent-fill: #7b96fa;
  --accent-fill-hover: #9bb0ff;
  --accent-subtle: #131f3d;
  --on-accent: #080d16;
  --success: #5fd3a2;
  --success-subtle: #0f2a20;
  --warning: #e3ae5a;
  --danger: #f08f80;
  --danger-subtle: #2a1512;
  --amber: #bf7a38;
  --mark-bg: #7b96fa;
  --mark-fg: #080d16;
  --mark-trend: #1f39ae;
  --cta-bg: #0f1725;
  --cta-ink: #e9eef7;
  --cta-muted: #8c9cb4;
  --shadow-overlay: 0 1px 2px rgb(0 0 0 / 0.35), 0 8px 24px -6px rgb(0 0 0 / 0.55);
  --shadow-mock: 0 1px 2px rgb(0 0 0 / 0.4), 0 24px 60px -20px rgb(0 0 0 / 0.7);
  color-scheme: dark;
}

/* ───────────── Base ───────────── */
*,
*::before,
*::after {
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
  scroll-padding-top: 80px;
  -webkit-text-size-adjust: 100%;
}
body {
  margin: 0;
  background: var(--canvas);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img,
svg {
  display: block;
  max-width: 100%;
}
a {
  color: inherit;
  text-decoration: none;
}
h1,
h2,
h3,
h4 {
  margin: 0;
  line-height: 1.15;
  letter-spacing: -0.02em;
}
p {
  margin: 0;
}
ul,
ol {
  margin: 0;
  padding: 0;
  list-style: none;
}
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: var(--radius-sm);
}
.skip-link {
  position: absolute;
  left: var(--gutter);
  top: -48px;
  z-index: 100;
  padding: 8px 14px;
  background: var(--accent-fill);
  color: var(--on-accent);
  border-radius: var(--radius-md);
  transition: top var(--duration-base) var(--ease-out);
}
.skip-link:focus {
  top: 12px;
}

.container {
  width: 100%;
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 var(--gutter);
}
@media (min-width: 768px) {
  :root {
    --gutter: 32px;
  }
}
.narrow {
  max-width: 820px;
}

/* ───────────── Buttons ───────────── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 40px;
  padding: 0 16px;
  border: 1px solid transparent;
  border-radius: var(--radius-md);
  font: 600 14px/1 var(--font-sans);
  white-space: nowrap;
  cursor: pointer;
  transition:
    background-color var(--duration-fast) var(--ease-out),
    border-color var(--duration-fast) var(--ease-out),
    color var(--duration-fast) var(--ease-out),
    transform var(--duration-fast) var(--ease-out);
}
.btn-lg {
  height: 48px;
  padding: 0 22px;
  font-size: 15px;
}
.btn-block {
  width: 100%;
}
.btn-primary {
  background: var(--accent-fill);
  color: var(--on-accent);
}
.btn-primary:hover {
  background: var(--accent-fill-hover);
}
.btn-primary:active {
  transform: translateY(1px);
}
.btn-secondary {
  background: var(--surface);
  color: var(--ink);
  border-color: var(--border);
}
.btn-secondary:hover {
  border-color: var(--border-strong);
}
.btn-ghost {
  background: transparent;
  color: var(--ink);
}
.btn-ghost:hover {
  background: var(--surface-sunken);
}
.icon-btn {
  display: inline-grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: var(--surface);
  color: var(--ink);
  cursor: pointer;
  transition: border-color var(--duration-fast) var(--ease-out);
}
.icon-btn:hover {
  border-color: var(--border-strong);
}
.icon-btn svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* Floating back-to-top button, added by main.js once the visitor is a screen down. */
.to-top {
  position: fixed;
  right: max(16px, env(safe-area-inset-right, 0px));
  bottom: max(16px, env(safe-area-inset-bottom, 0px));
  z-index: 40;
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border: 0;
  border-radius: 50%;
  background: var(--accent-fill);
  color: var(--on-accent);
  box-shadow: var(--shadow-overlay);
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
  transition:
    opacity var(--duration-base) var(--ease-out),
    transform var(--duration-base) var(--ease-out),
    visibility var(--duration-base),
    background-color var(--duration-fast) var(--ease-out);
}
.to-top.is-visible {
  opacity: 1;
  visibility: visible;
  transform: none;
}
.to-top:hover {
  background: var(--accent-fill-hover);
}
.to-top:focus-visible {
  border-radius: 50%;
}
.to-top svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* Sun in dark mode, moon in light mode. */
.i-sun {
  display: none;
}
:root[data-theme='dark'] .i-sun {
  display: block;
}
:root[data-theme='dark'] .i-moon {
  display: none;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme='light']) .i-sun {
    display: block;
  }
  :root:not([data-theme='light']) .i-moon {
    display: none;
  }
}

/* ───────────── Header ───────────── */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: color-mix(in srgb, var(--canvas) 82%, transparent);
  backdrop-filter: saturate(1.4) blur(12px);
  -webkit-backdrop-filter: saturate(1.4) blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color var(--duration-base) var(--ease-out);
}
.site-header.is-scrolled {
  border-bottom-color: var(--border);
}
.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  height: 68px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 650;
  font-size: 19px;
  letter-spacing: -0.022em;
}
.brand-mark {
  width: 30px;
  height: 30px;
}
.brand-mark rect {
  fill: var(--mark-bg);
}
.brand-mark path {
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.brand-mark .m1 {
  stroke: var(--mark-fg);
  stroke-width: 4.4;
}
.brand-mark .m2 {
  stroke: var(--mark-trend);
  stroke-width: 3.4;
}
.brand-mark .m3 {
  fill: var(--mark-fg);
}
.nav-links {
  display: flex;
  align-items: center;
  gap: 4px;
}
.nav-links > a:not(.btn) {
  padding: 8px 12px;
  border-radius: var(--radius-md);
  font-size: 14px;
  font-weight: 500;
  color: var(--muted);
  transition:
    color var(--duration-fast) var(--ease-out),
    background-color var(--duration-fast) var(--ease-out);
}
.nav-links > a:not(.btn):hover {
  color: var(--ink);
  background: var(--surface-sunken);
}
.nav-links > a[aria-current]:not(.btn) {
  color: var(--ink);
  background: var(--surface-sunken);
}
.nav-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}
.nav-mobile-only,
.menu-btn {
  display: none;
}

@media (max-width: 959px) {
  .menu-btn {
    display: inline-grid;
  }
  .nav-desktop-only {
    display: none;
  }
  .nav-links {
    position: absolute;
    top: 68px;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 2px;
    padding: 12px var(--gutter) 20px;
    background: var(--canvas);
    border-bottom: 1px solid var(--border);
    box-shadow: var(--shadow-overlay);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-6px);
    transition:
      opacity var(--duration-base) var(--ease-out),
      transform var(--duration-base) var(--ease-out),
      visibility var(--duration-base);
  }
  .nav-links.is-open {
    opacity: 1;
    visibility: visible;
    transform: none;
  }
  .nav-links > a:not(.btn) {
    padding: 12px;
    font-size: 15px;
  }
  .nav-mobile-only {
    display: inline-flex;
    margin-top: 8px;
    height: 44px;
  }
}

/* ───────────── Shared text ───────────── */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 5px 10px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  font: 500 12px/1.2 var(--font-mono);
  letter-spacing: 0.06em;
  color: var(--muted);
}
.eyebrow .dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent-fill);
  box-shadow: 0 0 0 3px var(--accent-subtle);
}
.accent-text {
  color: var(--accent-fill);
}
.kicker {
  display: inline-block;
  margin-bottom: 12px;
  font: 500 12px/1.2 var(--font-mono);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent-fill);
}
/* The CTA band is dark in both themes, so its kicker uses the dark-mode accent directly. */
.kicker-invert {
  color: #8aa4ff;
}

/* ───────────── Hero ───────────── */
.hero {
  position: relative;
  padding: 48px 0 64px;
  overflow: hidden;
}
.hero::before {
  /* Soft indigo wash behind the mockup — decorative, never behind text. */
  content: '';
  position: absolute;
  top: -120px;
  right: -200px;
  width: 720px;
  height: 720px;
  border-radius: 50%;
  background: radial-gradient(closest-side, var(--accent-subtle), transparent);
  pointer-events: none;
}
.hero-grid {
  position: relative;
  display: grid;
  gap: 48px;
  align-items: center;
}
@media (min-width: 1000px) {
  .hero {
    padding: 80px 0 96px;
  }
  .hero-grid {
    grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
    gap: 48px;
  }
  .hero .hero-copy h1 {
    font-size: clamp(42px, 4vw, 56px);
  }
}
.hero h1 {
  margin-top: 20px;
  font-size: clamp(38px, 6.4vw, 62px);
  font-weight: 700;
  letter-spacing: -0.035em;
  line-height: 1.04;
}
.hero .lede {
  margin-top: 20px;
  max-width: 540px;
  font-size: 18px;
  color: var(--muted);
}
.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 32px;
}
.ticks {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 22px;
  margin-top: 32px;
  font-size: 14px;
  color: var(--muted);
}
.ticks li,
.balanced {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.ticks svg,
.balanced svg,
.bullets li::before {
  flex: none;
  width: 16px;
  height: 16px;
  fill: none;
  stroke: var(--success);
  stroke-width: 2.2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* ───────────── Mockup ───────────── */
.mockup {
  min-width: 0;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-mock);
  overflow: hidden;
}
.mock-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  height: 40px;
  padding: 0 14px;
  background: var(--accent-fill);
  color: var(--on-accent);
}
.mock-dots {
  display: inline-flex;
  gap: 6px;
}
.mock-dots i {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: currentColor;
  opacity: 0.45;
}
.mock-title {
  font: 500 12px/1 var(--font-mono);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.mock-body {
  padding: 18px;
}
.mock-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
}
.mock-label {
  font: 500 11px/1 var(--font-mono);
  letter-spacing: 0.08em;
  color: var(--muted);
}
.mock-value {
  margin-top: 6px;
  font-weight: 600;
  font-size: 15px;
}
.badge {
  display: inline-flex;
  align-items: center;
  flex: none;
  padding: 3px 9px;
  border-radius: var(--radius-sm);
  background: var(--surface-sunken);
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
}
.badge-success {
  background: var(--success-subtle);
  color: var(--success);
}
.mock-meta {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(118px, 1fr));
  gap: 1px;
  margin-top: 16px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  overflow: hidden;
}
.mock-meta div {
  padding: 10px 12px;
  background: var(--surface);
}
.mock-meta span {
  display: block;
  font-size: 11px;
  color: var(--muted);
}
.mock-meta b {
  font: 600 12.5px/1.4 var(--font-mono);
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}
.mock-tabs {
  display: flex;
  gap: 4px;
  margin-top: 16px;
  padding: 3px;
  width: max-content;
  background: var(--surface-sunken);
  border-radius: var(--radius-md);
}
.mock-tab {
  padding: 6px 12px;
  border: 0;
  border-radius: var(--radius-sm);
  background: transparent;
  color: var(--muted);
  font: 600 12px/1 var(--font-sans);
  cursor: pointer;
  transition:
    background-color var(--duration-fast) var(--ease-out),
    color var(--duration-fast) var(--ease-out);
}
.mock-tab.is-active {
  background: var(--surface);
  color: var(--ink);
  box-shadow: 0 1px 2px rgb(14 26 43 / 0.08);
}
.mock-panel {
  display: none;
  margin-top: 12px;
  animation: fade-in var(--duration-slow) var(--ease-out);
}
.mock-panel.is-active {
  display: block;
}
.table-scroll {
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
}
.mock-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 11.5px;
  white-space: nowrap;
}
.mock-table th {
  padding: 8px;
  background: var(--surface-sunken);
  color: var(--muted);
  font-weight: 600;
  font-size: 11px;
  text-align: right;
}
.mock-table td {
  padding: 7px 8px;
  border-top: 1px solid var(--border);
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  text-align: right;
}
.mock-table th:first-child,
.mock-table td:first-child {
  text-align: left;
  font-family: var(--font-sans);
}
.mock-table td.indent {
  padding-left: 26px;
  color: var(--muted);
}
.mock-table tbody tr:first-child td {
  background: var(--accent-subtle);
}
.mock-table tfoot td {
  font-weight: 600;
  border-top: 1px solid var(--border-strong);
  background: var(--surface-sunken);
}
.mock-foot {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px 16px;
  margin-top: 12px;
  font-size: 12px;
  color: var(--muted);
}
.mock-foot b {
  color: var(--ink);
  font-family: var(--font-mono);
  font-weight: 600;
}
.balanced {
  color: var(--success);
  font-weight: 600;
}

/* ───────────── Standards strip ───────────── */
.strip {
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  background: var(--surface);
}
.strip-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px 40px;
  padding-top: 24px;
  padding-bottom: 24px;
}
.strip-label {
  font: 500 12px/1 var(--font-mono);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}
.strip-list {
  display: flex;
  flex-wrap: wrap;
  gap: 16px 36px;
}
.strip-list li {
  display: flex;
  flex-direction: column;
}
.strip-list b {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 600;
  letter-spacing: -0.01em;
}
.strip-list span {
  font-size: 12px;
  color: var(--muted);
}

/* ───────────── Sections ───────────── */
.section {
  padding: 72px 0;
}
@media (min-width: 768px) {
  .section {
    padding: 104px 0;
  }
}
.section-sunken {
  background: var(--surface-sunken);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.section-head {
  max-width: 680px;
  margin-bottom: 48px;
}
.section-head h2,
.split-copy h2,
.cta-copy h2 {
  font-family: var(--font-display);
  font-size: clamp(30px, 4.2vw, 44px);
  font-weight: 600;
  letter-spacing: -0.02em;
}
.section-head p,
.split-copy > p {
  margin-top: 16px;
  font-size: 17px;
  color: var(--muted);
}

/* Steps */
.steps {
  display: grid;
  gap: 16px;
  counter-reset: step;
}
@media (min-width: 800px) {
  .steps {
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
  }
}
.step {
  position: relative;
  padding: 28px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
}
.step::before {
  content: '';
  position: absolute;
  top: 0;
  left: 28px;
  width: 40px;
  height: 3px;
  border-radius: 0 0 3px 3px;
  background: var(--accent-fill);
}
.step-no {
  font: 500 12px/1 var(--font-mono);
  letter-spacing: 0.06em;
  color: var(--accent-fill);
}
.step h3 {
  margin-top: 14px;
  font-size: 20px;
}
.step p {
  margin-top: 10px;
  color: var(--muted);
  font-size: 15px;
}

/* Feature cards */
.feature-grid {
  display: grid;
  gap: 16px;
}
@media (min-width: 640px) {
  .feature-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}
/* Eight cards: two rows of four on wide screens, so no row is left half-empty. */
@media (min-width: 1100px) {
  .feature-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
  }
}
.card {
  padding: 24px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  transition:
    border-color var(--duration-base) var(--ease-out),
    transform var(--duration-base) var(--ease-out);
}
.card:hover {
  border-color: var(--accent);
  transform: translateY(-2px);
}
.card-icon {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: var(--radius-md);
  background: var(--accent-subtle);
  color: var(--accent-fill);
}
.card-icon svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.card h3,
.sec-item h3 {
  margin-top: 16px;
  font-size: 17px;
}
.card p,
.sec-item p {
  margin-top: 8px;
  font-size: 14.5px;
  color: var(--muted);
}

/* Split / version timeline */
.split {
  display: grid;
  gap: 48px;
  align-items: center;
}
@media (min-width: 900px) {
  .split {
    grid-template-columns: 1fr 1fr;
    gap: 72px;
  }
}
.bullets {
  display: grid;
  gap: 10px;
  margin-top: 24px;
}
.bullets li {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 500;
}
.bullets li::before {
  content: '';
  border-radius: 50%;
  background: var(--success-subtle)
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M6 12.5l4 4L18 8.5' fill='none' stroke='%230f7a55' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E")
    center / 14px no-repeat;
  width: 20px;
  height: 20px;
}
.timeline {
  position: relative;
  display: grid;
  gap: 16px;
  padding-left: 28px;
}
.timeline::before {
  content: '';
  position: absolute;
  top: 12px;
  bottom: 12px;
  left: 7px;
  width: 2px;
  background: linear-gradient(var(--border), var(--accent));
}
.tl-item {
  position: relative;
}
.tl-dot {
  position: absolute;
  left: -28px;
  top: 22px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--surface);
  border: 2px solid var(--border-strong);
}
.tl-item.is-current .tl-dot {
  border-color: var(--accent-fill);
  background: var(--accent-fill);
  box-shadow: 0 0 0 4px var(--accent-subtle);
}
.tl-card {
  padding: 16px 18px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
}
.tl-item.is-current .tl-card {
  border-color: var(--accent);
  box-shadow: var(--shadow-overlay);
}
.tl-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}
.tl-card p {
  margin-top: 6px;
  font: 500 13px/1.5 var(--font-mono);
  color: var(--muted);
}

/* Comparison */
.compare {
  display: grid;
  gap: 16px;
}
@media (min-width: 800px) {
  .compare {
    grid-template-columns: 1fr 1fr;
    gap: 24px;
  }
}
.compare-col {
  padding: 28px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  background: var(--surface);
}
.compare-good {
  border-color: var(--accent);
  box-shadow: var(--shadow-overlay);
}
.compare-col h3 {
  font-size: 18px;
}
.compare-col ul {
  display: grid;
  gap: 12px;
  margin-top: 20px;
}
.compare-col li {
  position: relative;
  padding-left: 28px;
  font-size: 15px;
}
.compare-col li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 3px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
}
.compare-bad li {
  color: var(--muted);
}
.compare-bad li::before {
  background: var(--danger-subtle)
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M8 8l8 8M16 8l-8 8' fill='none' stroke='%23b23a2e' stroke-width='2.6' stroke-linecap='round'/%3E%3C/svg%3E")
    center / 12px no-repeat;
}
.compare-good li::before {
  background: var(--success-subtle)
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M6 12.5l4 4L18 8.5' fill='none' stroke='%230f7a55' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E")
    center / 13px no-repeat;
}

/* Security */
.security-grid {
  display: grid;
  gap: 16px;
}
@media (min-width: 640px) {
  .security-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (min-width: 1000px) {
  .security-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
  }
}
.sec-item {
  padding: 24px;
  border-top: 2px solid var(--accent-fill);
  background: var(--surface);
  border-radius: 0 0 var(--radius-lg) var(--radius-lg);
  box-shadow: inset 0 0 0 1px var(--border);
}

/* Stats */
.stats {
  background: var(--accent-fill);
  color: var(--on-accent);
}
.stats-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 32px 16px;
  padding-top: 48px;
  padding-bottom: 48px;
}
@media (min-width: 800px) {
  .stats-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}
.stat b {
  display: block;
  font-family: var(--font-display);
  font-size: clamp(34px, 5vw, 48px);
  font-weight: 600;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}
.stat span {
  display: block;
  margin-top: 8px;
  font-size: 14px;
  opacity: 0.85;
}

/* FAQ */
.faq {
  display: grid;
  gap: 12px;
}
.faq details {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  transition: border-color var(--duration-base) var(--ease-out);
}
.faq details[open] {
  border-color: var(--accent);
}
.faq summary {
  position: relative;
  padding: 18px 56px 18px 20px;
  font-weight: 600;
  cursor: pointer;
  list-style: none;
}
.faq summary::-webkit-details-marker {
  display: none;
}
.faq summary::after {
  content: '';
  position: absolute;
  right: 20px;
  top: 50%;
  width: 10px;
  height: 10px;
  border-right: 2px solid var(--muted);
  border-bottom: 2px solid var(--muted);
  transform: translateY(-70%) rotate(45deg);
  transition: transform var(--duration-base) var(--ease-out);
}
.faq details[open] summary::after {
  transform: translateY(-30%) rotate(-135deg);
}
.faq details p {
  padding: 0 20px 20px;
  color: var(--muted);
  animation: fade-in var(--duration-slow) var(--ease-out);
}

/* CTA */
.cta {
  background: var(--cta-bg);
  color: var(--cta-ink);
}
.cta-grid {
  display: grid;
  gap: 40px;
  align-items: center;
}
@media (min-width: 900px) {
  .cta-grid {
    grid-template-columns: 1fr 1fr;
    gap: 72px;
  }
}
.cta-copy p {
  margin-top: 16px;
  font-size: 17px;
  color: var(--cta-muted);
}
.cta-copy .cta-mail a {
  color: var(--cta-ink);
  text-decoration: underline;
  text-underline-offset: 3px;
}
.demo-form {
  display: grid;
  gap: 16px;
  padding: 28px;
  background: var(--surface);
  color: var(--ink);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-overlay);
}
.field {
  display: grid;
  gap: 6px;
}
.field label {
  font-size: 14px;
  font-weight: 600;
}
.field input,
.field select {
  width: 100%;
  height: 44px;
  padding: 0 12px;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-md);
  background: var(--surface);
  color: var(--ink);
  font: 15px var(--font-sans);
  transition:
    border-color var(--duration-fast) var(--ease-out),
    box-shadow var(--duration-fast) var(--ease-out);
}
.field input:focus,
.field select:focus {
  outline: none;
  border-color: var(--accent-fill);
  box-shadow: 0 0 0 3px var(--accent-subtle);
}
.field.has-error input,
.field.has-error select {
  border-color: var(--danger);
}
.error {
  min-height: 0;
  font-size: 13px;
  color: var(--danger);
}
.error:empty {
  display: none;
}
.form-note {
  font-size: 13px;
  line-height: 1.55;
  color: var(--muted);
}
.form-note a {
  color: var(--accent-fill);
  text-decoration: underline;
  text-underline-offset: 2px;
}
.form-status {
  font-size: 14px;
  color: var(--success);
  font-weight: 500;
}
.form-status:empty {
  display: none;
}

/* Footer */
.site-footer {
  padding: 56px 0 28px;
  border-top: 1px solid var(--border);
  background: var(--canvas);
}
/* Room for the floating back-to-top button, which only exists when JS runs. */
.js .site-footer {
  padding-bottom: 88px;
}
.footer-grid {
  display: grid;
  gap: 32px;
}
/* Brand block on its own row above the four link columns (two by two, then four across), then all five in one row. */
@media (min-width: 480px) {
  .footer-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .footer-brand {
    grid-column: 1 / -1;
  }
}
@media (min-width: 900px) {
  .footer-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}
@media (min-width: 1200px) {
  .footer-grid {
    grid-template-columns: 1.4fr 1.15fr 1.25fr 0.8fr 1.1fr;
  }
  .footer-brand {
    grid-column: auto;
  }
}
.footer-brand .footer-note + .footer-note {
  margin-top: 4px;
}

/* Call-to-action card at the top of the footer: brand indigo with the logo pattern showing only on the right,
   never behind the text (the same rule as the business card). Indigo in both themes. */
.footer-cta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 20px 32px;
  margin-bottom: 56px;
  padding: 32px 36px;
  border-radius: var(--radius-xl);
  color: #ffffff;
  background:
    linear-gradient(90deg, #2b4bd4 0%, #2b4bd4 62%, rgb(43 75 212 / 0.5) 86%, rgb(43 75 212 / 0.2) 100%),
    url('/brand/pattern/leascape-pattern-tile.svg') right center / 112px auto repeat #2b4bd4;
}
.footer-cta-title {
  font-family: var(--font-display);
  font-size: clamp(24px, 3vw, 32px);
  font-weight: 600;
  letter-spacing: -0.015em;
  line-height: 1.15;
}
.footer-cta-title span {
  color: #c9d5ff;
}
.footer-cta-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}
.btn-on-indigo {
  background: #ffffff;
  color: #2b4bd4;
  border-color: #ffffff;
}
.btn-on-indigo:hover {
  background: #edf1fe;
}
.btn-outline-on-indigo {
  background: transparent;
  color: #ffffff;
  border-color: rgb(255 255 255 / 0.6);
}
.btn-outline-on-indigo:hover {
  background: rgb(255 255 255 / 0.1);
  border-color: #ffffff;
}
@media (max-width: 699px) {
  .footer-cta {
    padding: 28px 24px;
    /* Stacked: the text spans the card, so the pattern stays at the bottom edge, below it. */
    background:
      linear-gradient(180deg, #2b4bd4 0%, #2b4bd4 55%, rgb(43 75 212 / 0.6) 100%),
      url('/brand/pattern/leascape-pattern-tile.svg') center bottom / 96px auto repeat #2b4bd4;
  }
}
.footer-note {
  margin-top: 12px;
  font-size: 14px;
  color: var(--muted);
}
.site-footer nav {
  display: grid;
  gap: 8px;
  align-content: start;
}
.site-footer h4 {
  margin-bottom: 4px;
  font: 500 12px/1 var(--font-mono);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}
.site-footer nav a {
  font-size: 14px;
}
.site-footer nav a:hover {
  color: var(--accent-fill);
}
.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px;
  margin-top: 40px;
  padding-top: 24px;
  border-top: 1px solid var(--border);
  font-size: 13px;
  color: var(--muted);
}

/* ───────────── Legal pages ─────────────
   Shared by privacy.html, terms.html and the rest. A single reading column, numbered
   headings from a CSS counter, and the page chrome those pages keep deliberately slim. */
.legal {
  padding: 48px 0 80px;
}
.legal-wrap {
  max-width: 800px;
}
.legal-notice {
  padding: 12px 16px;
  border: 1px dashed var(--border-strong);
  border-radius: var(--radius-md);
  font-size: 14px;
  color: var(--muted);
}
.legal-head {
  margin: 40px 0 32px;
}
.legal-head h1 {
  margin-top: 12px;
  font-family: var(--font-display);
  font-size: clamp(34px, 5vw, 48px);
  font-weight: 600;
  letter-spacing: -0.02em;
}
.legal-meta {
  margin-top: 14px;
  font: 500 13px/1 var(--font-mono);
  color: var(--muted);
}
.legal-summary {
  padding: 22px 24px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
}
.legal-summary h2 {
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--accent-fill);
}
.legal-summary p {
  margin-top: 10px;
  font-size: 16px;
  line-height: 1.65;
}
.legal-body {
  counter-reset: legal-section;
  margin-top: 8px;
}
.legal-body h2 {
  counter-increment: legal-section;
  margin: 44px 0 14px;
  font-size: 21px;
  letter-spacing: -0.015em;
}
.legal-body h2::before {
  content: counter(legal-section) '. ';
  color: var(--accent-fill);
  font-variant-numeric: tabular-nums;
}
.legal-body p,
.legal-body li {
  font-size: 16px;
  line-height: 1.7;
  color: var(--muted);
}
.legal-body p + p {
  margin-top: 14px;
}
.legal-body b {
  color: var(--ink);
  font-weight: 600;
}
.legal-body ul {
  display: grid;
  gap: 10px;
  margin-top: 14px;
  padding-left: 22px;
  list-style: disc;
}
.legal-body li::marker {
  color: var(--border-strong);
}
.legal-body a {
  color: var(--accent-fill);
  text-decoration: underline;
  text-underline-offset: 3px;
}
.legal-body a:hover {
  color: var(--accent-fill-hover);
}
.legal-body code {
  padding: 2px 6px;
  border-radius: var(--radius-sm);
  background: var(--surface-sunken);
  font: 500 13px/1.4 var(--font-mono);
  color: var(--ink);
}
.legal-table {
  width: 100%;
  margin-top: 18px;
  border-collapse: collapse;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  overflow: hidden;
  font-size: 15px;
}
.legal-table th {
  padding: 10px 14px;
  background: var(--surface-sunken);
  text-align: left;
  font-size: 13px;
  font-weight: 600;
  color: var(--muted);
}
.legal-table td {
  padding: 11px 14px;
  border-top: 1px solid var(--border);
  color: var(--muted);
  vertical-align: top;
}
.legal-table td:first-child {
  color: var(--ink);
  font-weight: 500;
  white-space: nowrap;
}
@media (max-width: 520px) {
  .legal-table td:first-child {
    white-space: normal;
  }
}

/* Slim footer used by the legal pages. */
.footer-legal nav {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 28px;
}
.footer-legal a {
  font-size: 14px;
  color: var(--muted);
}
.footer-legal a:hover {
  color: var(--accent-fill);
}

/* ───────────── Landing pages ─────────────
   The product pages built by tools/landing_pages.py: a hero with breadcrumbs, a long-form article with a sticky
   "On this page" list beside it, data tables for worked examples, then FAQ, related pages and the demo form. */
.page-hero {
  position: relative;
  padding: 28px 0 56px;
  overflow: hidden;
  border-bottom: 1px solid var(--border);
}
.page-hero::before {
  content: '';
  position: absolute;
  top: -160px;
  right: -220px;
  width: 640px;
  height: 640px;
  border-radius: 50%;
  background: radial-gradient(closest-side, var(--accent-subtle), transparent);
  pointer-events: none;
}
.page-hero .container {
  position: relative;
}
.page-hero h1 {
  max-width: 900px;
  font-family: var(--font-display);
  font-size: clamp(34px, 5.2vw, 54px);
  font-weight: 600;
  letter-spacing: -0.025em;
  line-height: 1.06;
}
.page-hero .lede {
  max-width: 700px;
  margin-top: 18px;
  font-size: 18px;
  color: var(--muted);
}
.crumbs {
  margin-bottom: 28px;
}
.crumbs ol {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  font-size: 13px;
  color: var(--muted);
}
.crumbs li + li::before {
  content: '/';
  margin-right: 6px;
  color: var(--border-strong);
}
.crumbs a:hover {
  color: var(--accent-fill);
}
.crumbs [aria-current] {
  color: var(--ink);
}
@media (min-width: 768px) {
  .page-hero {
    padding: 36px 0 72px;
  }
}

.page-section {
  padding-top: 56px;
}
.page-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr); /* lets wide tables scroll inside .table-scroll instead of widening the page */
  gap: 48px;
}
@media (min-width: 1000px) {
  .page-grid {
    grid-template-columns: minmax(0, 1fr) 260px;
    gap: 72px;
  }
}
.page-aside {
  display: none;
}
@media (min-width: 1000px) {
  .page-aside {
    display: block;
    position: sticky;
    top: 96px;
    align-self: start;
  }
}
.toc-title {
  margin-bottom: 12px;
  font: 500 12px/1.2 var(--font-mono);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}
.toc ol {
  display: grid;
  gap: 2px;
  border-left: 1px solid var(--border);
}
.toc a {
  display: block;
  padding: 5px 0 5px 14px;
  margin-left: -1px;
  border-left: 2px solid transparent;
  font-size: 14px;
  line-height: 1.4;
  color: var(--muted);
}
.toc a:hover {
  color: var(--accent-fill);
  border-left-color: var(--accent);
}
.aside-cta {
  margin-top: 28px;
  padding: 20px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
}
.aside-cta .aside-title {
  font-weight: 600;
}
.aside-cta p + p {
  margin: 6px 0 16px;
  font-size: 14px;
  color: var(--muted);
}

.prose {
  max-width: 760px;
}
.prose h2 {
  margin: 56px 0 14px;
  font-family: var(--font-display);
  font-size: clamp(25px, 3vw, 31px);
  font-weight: 600;
  letter-spacing: -0.015em;
  line-height: 1.15;
  scroll-margin-top: 96px;
}
.prose h2:first-child {
  margin-top: 0;
}
.prose p,
.prose li {
  font-size: 16.5px;
  line-height: 1.75;
  color: var(--muted);
}
.prose p {
  margin-top: 14px;
}
.prose h2 + p {
  margin-top: 0;
}
.prose b {
  color: var(--ink);
  font-weight: 600;
}
.prose a {
  color: var(--accent-fill);
  text-decoration: underline;
  text-underline-offset: 3px;
}
.prose a:hover {
  color: var(--accent-fill-hover);
}
.prose ul,
.prose ol {
  display: grid;
  gap: 8px;
  margin-top: 14px;
  padding-left: 22px;
}
.prose ul {
  list-style: disc;
}
.prose ol {
  list-style: decimal;
}
.prose li::marker {
  color: var(--accent-fill);
}
.prose .note {
  font-size: 14px;
  line-height: 1.6;
}
.prose .table-scroll {
  margin-top: 18px;
}
.data {
  width: 100%;
  border-collapse: collapse;
  font-size: 15px;
  font-variant-numeric: tabular-nums;
}
.data th {
  padding: 10px 14px;
  background: var(--surface-sunken);
  text-align: left;
  font-size: 13px;
  font-weight: 600;
  color: var(--muted);
}
.data td {
  padding: 10px 14px;
  border-top: 1px solid var(--border);
  color: var(--ink);
  vertical-align: top;
}
.data .num {
  text-align: right;
  white-space: nowrap;
}
.data tr.total td {
  background: var(--accent-subtle);
  font-weight: 600;
}

.related-grid {
  display: grid;
  gap: 16px;
}
@media (min-width: 640px) {
  .related-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (min-width: 1100px) {
  .related-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
  }
}
.related-card {
  display: flex;
  flex-direction: column;
  color: inherit;
}
.related-card h3 {
  margin-top: 0;
}
.related-card .more,
.card-more {
  margin-top: auto;
  padding-top: 14px;
  font-size: 14px;
  font-weight: 500;
  color: var(--accent-fill);
}
.related-card .more::after,
.card-more::after {
  content: ' \2192';
}
.card-more {
  display: inline-block;
}
.card-more:hover {
  color: var(--accent-fill-hover);
}

/* Contact page: three cards, then what happens next. */
.contact-grid {
  display: grid;
  gap: 16px;
}
@media (min-width: 800px) {
  .contact-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
  }
}
.contact-card {
  display: flex;
  flex-direction: column;
}
.contact-card h2 {
  margin-top: 16px;
  font-size: 19px;
  letter-spacing: -0.01em;
}
.contact-card > p {
  margin-top: 8px;
  font-size: 15px;
  color: var(--muted);
}
.contact-card dl {
  display: grid;
  gap: 12px;
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}
.contact-card dt {
  font: 500 12px/1.2 var(--font-mono);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}
.contact-card dd {
  margin: 4px 0 0;
  font-size: 15px;
  color: var(--ink);
}
.contact-card .btn {
  align-self: flex-start;
  margin-top: 20px;
}
.contact-next {
  margin-top: 64px;
}

/* ───────────── Motion ───────────── */
@keyframes fade-in {
  from {
    opacity: 0;
    transform: translateY(4px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}
/* Only hide reveal targets once JS has confirmed it can show them again. */
.js .reveal {
  opacity: 0;
  transform: translateY(8px);
  transition:
    opacity 480ms var(--ease-out),
    transform 480ms var(--ease-out);
}
.js .reveal.is-visible {
  opacity: 1;
  transform: none;
}
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *,
  *::before,
  *::after {
    animation-duration: 1ms !important;
    transition-duration: 1ms !important;
  }
  .js .reveal {
    opacity: 1;
    transform: none;
  }
}
