/* Billdeck marketing homepage — built from Figma "Billdeck Design" node 5:3339. */

@font-face { font-family: "PP Neue Montreal"; src: url("fonts/PPNeueMontreal-Regular.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "PP Neue Montreal"; src: url("fonts/PPNeueMontreal-Medium.woff2") format("woff2"); font-weight: 500; font-display: swap; }
@font-face { font-family: "PP Neue Montreal"; src: url("fonts/PPNeueMontreal-SemiBold.woff2") format("woff2"); font-weight: 600; font-display: swap; }
@font-face { font-family: "Recoleta"; src: url("fonts/Recoleta-Regular.woff2") format("woff2"); font-weight: 400; font-display: swap; }

:root {
  --bg: #ffffff;
  --bg-subtle: #f4f4f4;
  --bg-surface: #fbfbfb;
  --bg-inverse: #0c0c0c;
  --text: #0c0c0c;
  --text-muted: #484848;
  --text-soft: #888888;
  --text-disabled: #b1b1b1;
  --text-inverse: #ffffff;
  --border: #e6e6e6;
  --border-soft: #f4f4f4;
  --line: #e6e8ee;
  --blue: #2563eb;
  --blue-tint: #eff4ff;
  --blue-bar: #dbe6fe;
  --success: #18c76a;
  --success-subtle: #e4fbeb;
  --success-soft: #f3fef6;
  --success-emphasis: #00783c;
  --warning: #f6b400;
  --warning-soft: #fdfaf2;
  --warning-emphasis: #9f6900;
  --danger: #ef4444;
  --danger-soft: #fff8f8;
  --white-64: rgba(255, 255, 255, 0.64);
  --white-72: rgba(255, 255, 255, 0.72);
  --white-16: rgba(255, 255, 255, 0.16);
  --white-8: rgba(255, 255, 255, 0.08);
  --sans: "PP Neue Montreal", system-ui, -apple-system, "Segoe UI", sans-serif;
  --serif: "Recoleta", Georgia, "Times New Roman", serif;
  --container: 1248px;
  --gutter: 24px;
  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  --ease-out-expo: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-in-out: cubic-bezier(0.77, 0, 0.175, 1);
}

*,
*::before,
*::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body.bd {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 24px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

/* Resets wrapped in :where() so they never outrank component classes. */
:where(.bd) p { margin: 0; }
:where(.bd) a { color: inherit; text-decoration: none; }
:where(.bd) img { display: block; max-width: none; }
:where(.bd) :is(h1, h2, h3) { margin: 0; font-weight: 400; }
:where(.bd) button { font: inherit; color: inherit; }

.container {
  width: min(var(--container), calc(100% - var(--gutter) * 2));
  margin-inline: auto;
}

/* ── Type ──────────────────────────────────────────────── */
.serif, .display, .h1, .h2, .h3, .statement .line { font-weight: 400; }
.serif { font-family: var(--serif); }
.display { font-family: var(--serif); font-size: 60px; line-height: 72px; letter-spacing: -0.8px; }
.h1 { font-family: var(--serif); font-size: 48px; line-height: 60px; letter-spacing: -0.8px; }
.h2 { font-family: var(--serif); font-size: 36px; line-height: 44px; letter-spacing: -0.4px; }
.h3 { font-family: var(--serif); font-size: 32px; line-height: 40px; letter-spacing: -0.4px; }

.t-xs { font-size: 12px; line-height: 16px; }
.t-sm { font-size: 14px; line-height: 20px; }
.t-md { font-size: 16px; line-height: 24px; }
.t-lg { font-size: 18px; line-height: 28px; }
.t-xl { font-size: 20px; line-height: 32px; }
.t-2xl { font-size: 24px; line-height: 36px; letter-spacing: -0.2px; }
.t-3xl { font-size: 32px; line-height: 40px; letter-spacing: -0.4px; }
.t-4xl { font-size: 36px; line-height: 44px; letter-spacing: -0.4px; }
.t-6xl { font-size: 60px; line-height: 72px; letter-spacing: -0.8px; }
.wide { letter-spacing: 0.4px; }
.upper { text-transform: uppercase; }
.m { font-weight: 500; }
.c-default { color: var(--text); }
.c-muted { color: var(--text-muted); }
.c-soft { color: var(--text-soft); }
.c-blue { color: var(--blue); }
.c-danger { color: var(--danger); }
.c-success { color: var(--success); }
.c-warn { color: var(--warning-emphasis); }
.c-white { color: var(--text-inverse); }
.c-white-64 { color: var(--white-64); }
.center { text-align: center; }
.nowrap { white-space: nowrap; }
.grow { flex: 1 0 0; min-width: 1px; }

.eyebrow { font-size: 14px; line-height: 20px; font-weight: 500; letter-spacing: 0.4px; text-transform: uppercase; color: var(--blue); }
.eyebrow-chip { display: inline-flex; align-self: flex-start; padding: 4px 10px 4px 8px; border-radius: 6px; background: var(--blue-tint); }
.lead { font-size: 18px; line-height: 28px; color: var(--text-muted); }

/* ── Buttons ───────────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 12px;
  height: 44px; padding: 0 20px; border-radius: 10px; border: 0;
  font-size: 16px; line-height: 24px; font-weight: 500; white-space: nowrap;
  cursor: pointer; transition: background-color .15s ease, scale .16s var(--ease-out);
}
.btn:active { scale: 0.97; }
.btn-primary { background: var(--blue); color: var(--text-inverse); }
.btn-primary:hover { background: #1d4fd8; }
.btn-subtle { background: var(--bg-subtle); color: var(--text); }
.btn-subtle:hover { background: #ebebeb; }
.btn-outline { background: var(--bg); color: var(--text); border: 1px solid var(--border); }
.btn-outline:hover { background: var(--bg-surface); }
.btn-white { background: var(--bg); color: var(--text); }
.btn-arrowed { justify-content: space-between; text-align: left; }
.btn-arrowed > span:first-child { flex: 1 0 0; }
.btn-arrow { display: flex; align-items: center; justify-content: center; width: 20px; height: 20px; flex: 0 0 20px; border-radius: 5px; background: var(--white-16); }
.btn-subtle .btn-arrow { background: rgba(9, 12, 16, 0.16); }
.btn-arrow img { width: 14px; height: 14px; }
.btn:focus-visible, .bd a:focus-visible, .bd summary:focus-visible, .rate:focus-visible, .seg:focus-visible, .calc-input:focus-visible {
  outline: 2px solid var(--blue); outline-offset: 2px;
}

/* ── Chips ─────────────────────────────────────────────── */
.chip { display: inline-flex; align-items: flex-start; padding: 2px 8px; border-radius: 9999px; font-size: 12px; line-height: 16px; font-weight: 500; white-space: nowrap; }
.chip-paid { background: var(--success-soft); color: var(--success); }
.chip-paid-strong { background: var(--success-soft); color: var(--success-emphasis); }
.chip-paid-subtle { background: var(--success-subtle); color: var(--success); }
.chip-partial { background: var(--warning-soft); color: var(--warning-emphasis); }
.chip-overdue { background: var(--danger-soft); color: var(--danger); }
.chip-sent { background: var(--blue-tint); color: var(--blue); }
.chip-grey { background: var(--bg-subtle); color: var(--text-muted); }

/* ── Shared art panels ─────────────────────────────────── */
.art { position: relative; overflow: hidden; border-radius: 24px; isolation: isolate; }
.art-bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center; z-index: -1; pointer-events: none; user-select: none; }
.card { background: var(--bg); border: 1px solid var(--border); }
.rule { height: 1px; background: var(--border); width: 100%; flex: 0 0 auto; }
.dotted { height: 4px; width: 100%; overflow: hidden; flex: 0 0 auto; }
.dotted img { width: 1200px; height: 4px; }
.row { display: flex; align-items: center; gap: 12px; width: 100%; }
.col { display: flex; flex-direction: column; }
.ico-24 { width: 24px; height: 24px; flex: 0 0 24px; }
.ico-18 { width: 18px; height: 18px; flex: 0 0 18px; }
.ico-16 { width: 16px; height: 16px; flex: 0 0 16px; }

.feature-items { display: flex; flex-direction: column; gap: 8px; }
.feature-item { display: flex; flex-direction: column; gap: 6px; padding: 16px 0; }
.feature-item .title { display: flex; align-items: center; gap: 10px; }
.feature-items.cols { flex-direction: row; gap: 24px; }
.feature-items.cols .feature-item { flex: 1 0 0; min-width: 1px; }

.section-head { display: flex; flex-direction: column; align-items: center; gap: 20px; text-align: center; margin-inline: auto; }

/* ── Announcement + nav ───────────────────────────────── */
.announce { background: var(--bg-inverse); height: 40px; display: flex; align-items: center; justify-content: center; padding: 0 16px; }
.announce .msg { display: flex; gap: 6px; align-items: center; font-size: 14px; line-height: 20px; white-space: nowrap; }
.announce a { color: var(--text-inverse); font-weight: 500; }
.announce a:hover { text-decoration: underline; }

.nav { background: var(--bg); border-bottom: 1px solid var(--border); padding: 16px 0; position: sticky; top: 0; z-index: 20; }
.nav .bar { display: flex; align-items: center; gap: 12px; }
.logo { display: inline-flex; align-items: center; gap: 6px; font-size: 24px; line-height: 36px; letter-spacing: -0.2px; font-weight: 500; }
.logo img { width: 20px; height: 20px; }
.nav .links { display: flex; gap: 28px; margin-left: 24px; font-size: 14px; line-height: 20px; color: var(--text-muted); }
.nav .links a:hover { color: var(--text); }
.nav .right { display: flex; align-items: center; gap: 20px; margin-left: auto; }
.nav .login { font-size: 14px; line-height: 20px; font-weight: 500; }
.nav .btn { min-width: 144px; }

/* ── Hero ──────────────────────────────────────────────── */
.hero { position: relative; padding: 96px 0; overflow: hidden; }
.hero-field { position: absolute; top: 0; left: 0; width: 100%; height: 400px; object-fit: cover; object-position: top center; pointer-events: none; }
.hero-content { position: relative; display: flex; flex-direction: column; align-items: center; gap: 64px; }
.hero-copy { display: flex; flex-direction: column; align-items: center; gap: 24px; max-width: 1000px; text-align: center; }
.cta-row { display: flex; gap: 16px; align-items: center; flex-wrap: wrap; justify-content: center; }
.cta-row .btn-primary { min-width: 160px; }
.cta-row .btn-subtle { min-width: 192px; }

.stage { width: 100%; height: 608px; padding-top: 48px; display: flex; justify-content: center; }
.phone-wrap { position: relative; width: 520px; height: 640px; flex: 0 0 520px; }
.phone-btn { position: absolute; width: 4px; border-radius: 2px; background: #6b6b70; }
.phone-btn.action { left: -3px; top: 128px; height: 36px; }
.phone-btn.vol-up { left: -3px; top: 188px; height: 64px; }
.phone-btn.vol-down { left: -3px; top: 264px; height: 64px; }
.phone-btn.side { right: -3px; top: 208px; height: 96px; }
.phone { position: relative; width: 520px; height: 640px; padding: 14px 14px 0; border-radius: 72px; overflow: hidden; isolation: isolate; }
.phone-shell { position: absolute; inset: 0; width: 520px; height: 640px; z-index: -1; }
.screen { width: 492px; background: var(--bg); border-radius: 60px 60px 0 0; padding: 16px 24px 24px; display: flex; flex-direction: column; gap: 16px; }
.island { width: 120px; height: 34px; border-radius: 20px; background: var(--bg-inverse); margin: 0 auto; }
.circle-36 { width: 36px; height: 36px; flex: 0 0 36px; border-radius: 9999px; display: flex; align-items: center; justify-content: center; }
.bell { border: 1px solid var(--line); }
.avatar-blue { background: var(--blue); color: #fff; font-size: 12px; line-height: 16px; font-weight: 500; }
.amount { display: flex; align-items: flex-end; font-weight: 500; white-space: nowrap; }
/* Right-aligned so the cents stay snug against the dollars while the count-up reserves its final width. */
.amount .t-4xl { text-align: right; }
.sparkline { width: 444px; height: 84px; }
.stats { display: flex; border: 1px solid var(--line); border-radius: 14px; }
.stat { flex: 1 0 0; display: flex; flex-direction: column; gap: 2px; padding: 12px 16px; white-space: nowrap; }
.stats .divider { width: 1px; background: var(--line); align-self: stretch; }
.setaside { display: flex; align-items: center; gap: 12px; padding: 12px; border-radius: 14px; background: var(--success-soft); }
.disc-green { background: #e3fce9; }
.btn-sm { height: 44px; padding: 0 16px; border-radius: 10px; font-size: 14px; line-height: 20px; font-weight: 500; background: var(--blue); color: #fff; display: inline-flex; align-items: center; white-space: nowrap; }
.recent-row { display: flex; align-items: center; gap: 12px; padding: 10px 0; }
.recent .rule { background: #eef0f3; }
.av-blue { background: var(--blue-tint); color: var(--blue); font-size: 12px; line-height: 16px; font-weight: 500; }
.av-purple { background: #f3eeff; color: #7c3aed; font-size: 12px; line-height: 16px; font-weight: 500; }

/* ── Statement ────────────────────────────────────────── */
.statement .inner { display: flex; flex-direction: column; align-items: center; gap: 40px; }
.statement .line { max-width: 800px; font-family: var(--serif); font-size: 24px; line-height: 40px; letter-spacing: -0.4px; text-align: center; }
.creatives { display: flex; justify-content: space-between; width: 100%; gap: 24px; flex-wrap: wrap; }
.creative { display: flex; align-items: center; gap: 10px; color: var(--text-soft); font-size: 24px; line-height: 36px; letter-spacing: -0.2px; font-weight: 500; white-space: nowrap; }

/* ── Problem ──────────────────────────────────────────── */
.problem { padding: 96px 0; }
.problem .inner { display: flex; flex-direction: column; align-items: center; gap: 40px; }
.problem .section-head { max-width: 760px; }
.problem .btn { min-width: 144px; padding: 0 24px; }
.problem .btn-arrow { background: rgba(255, 255, 255, 0.2); }
.problem-panel { width: 100%; min-height: 704px; padding: 96px 32px; display: flex; align-items: center; justify-content: center; gap: 32px; }
.p-card { width: 316px; flex: 0 0 316px; padding: 24px; border-radius: 16px; display: flex; flex-direction: column; gap: 16px; }
.bars { display: flex; align-items: flex-end; gap: 8px; height: 96px; }
.bar-col { flex: 1 0 0; min-width: 0; height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; gap: 6px; }
.bar-col .bar { width: 100%; border-radius: 4px; background: var(--blue-bar); }
.bar-col .bar.on { background: var(--blue); }
.invoice-stack { position: relative; width: 440px; flex: 0 0 440px; padding-top: 32px; }
.stack-back2 { position: absolute; left: 40px; top: 0; width: 360px; height: 56px; border-radius: 16px; background: rgba(255, 255, 255, 0.45); }
.stack-back1 { position: absolute; left: 20px; top: 16px; width: 400px; height: 56px; border-radius: 16px; background: rgba(255, 255, 255, 0.7); border: 1px solid var(--border); }
.invoice { position: relative; isolation: isolate; width: 440px; padding: 28px 28px 40px; border-radius: 16px; display: flex; flex-direction: column; gap: 20px; }
.invoice-paper { position: absolute; left: 0; top: 0; width: 440px; height: 512px; z-index: -1; }
.logo-sm { display: inline-flex; align-items: center; gap: 6px; font-size: 24px; line-height: 36px; letter-spacing: -0.2px; font-weight: 500; }
.logo-sm img { width: 16px; height: 16px; }
.line-item { display: flex; align-items: center; gap: 16px; font-size: 14px; line-height: 20px; white-space: nowrap; }
.pay-row { display: flex; gap: 8px; }
.pay-row .pay { flex: 1 0 0; height: 44px; border-radius: 10px; background: var(--blue); color: #fff; display: flex; align-items: center; justify-content: center; font-size: 14px; line-height: 20px; font-weight: 500; }
.pay-row .share { height: 44px; padding: 0 16px; border-radius: 10px; border: 1px solid var(--border); display: flex; align-items: center; gap: 8px; font-size: 14px; line-height: 20px; font-weight: 500; color: var(--text-muted); white-space: nowrap; }
.p-card.payment { height: 315px; }
.disc-32 { width: 32px; height: 32px; flex: 0 0 32px; border-radius: 9999px; background: var(--success-subtle); display: flex; align-items: center; justify-content: center; }
.split-bar { display: flex; gap: 4px; }
.split-bar .yours { flex: 1 0 0; height: 10px; border-radius: 9999px; background: var(--blue); }
.split-bar .tax { width: 78px; flex: 0 0 78px; height: 10px; border-radius: 9999px; background: var(--warning); }
.mark-btn { height: 44px; border-radius: 10px; background: var(--bg-subtle); display: flex; align-items: center; justify-content: center; font-size: 14px; line-height: 20px; font-weight: 500; }

/* ── Suite (how it works) ─────────────────────────────── */
.suite .inner { display: flex; flex-direction: column; align-items: center; gap: 56px; }
.suite .section-head { max-width: 880px; }
.steps { position: relative; display: flex; gap: 32px; width: 100%; }
/* Dotted line from the centre of step 1 to the centre of step 4 (each column is (100% - 3 gaps) / 4 wide).
   The dots flow toward step 4, and a blue glow travels along them like a payment moving through the steps. */
.steps-connector {
  position: absolute; top: 34px; height: 4px; left: calc((100% - 96px) / 8); right: calc((100% - 96px) / 8);
  background: radial-gradient(circle, #d9d9d9 1.5px, transparent 1.75px) 0 50% / 10px 4px repeat-x;
  animation: bd-flow 1.2s linear infinite;
}
.steps-connector::after {
  content: ""; position: absolute; inset: 0;
  background: radial-gradient(circle, var(--blue) 1.5px, transparent 1.75px) 0 50% / 10px 4px repeat-x;
  -webkit-mask: linear-gradient(90deg, transparent, #000 45%, #000 55%, transparent) no-repeat;
  mask: linear-gradient(90deg, transparent, #000 45%, #000 55%, transparent) no-repeat;
  -webkit-mask-size: 24% 100%;
  mask-size: 24% 100%;
  animation: bd-flow 1.2s linear infinite, bd-pulse 3.2s var(--ease-in-out) infinite;
}
/* With JS, a canvas (motion.js) draws the same dots, the pulse, and the hover sound wave (48px peak to peak). */
.steps-connector.is-canvas { background: none; animation: none; }
.steps-connector.is-canvas::after { display: none; }
.steps-connector canvas { position: absolute; left: -4px; top: -26px; width: calc(100% + 8px); height: 56px; pointer-events: none; }
@keyframes bd-flow { to { background-position: 10px 50%; } }
@keyframes bd-pulse {
  from { -webkit-mask-position: -32% 0; mask-position: -32% 0; }
  to { -webkit-mask-position: 132% 0; mask-position: 132% 0; }
}
.step { position: relative; flex: 1 0 0; min-width: 1px; display: flex; flex-direction: column; align-items: center; gap: 12px; text-align: center; }
.step-dot { width: 72px; height: 72px; border-radius: 9999px; background: var(--bg); border: 1px solid var(--border); display: flex; align-items: center; justify-content: center; margin-bottom: 8px; }
.step-dot.on { background: var(--blue); border-color: var(--blue); }
.step-dot img { width: 28px; height: 28px; }

/* ── Feature split (invoicing, tax) ───────────────────── */
.feature { padding: 96px 0; }
.feature-split { display: flex; gap: 48px; align-items: stretch; }
.feature-split > .left { flex: 0 0 600px; display: flex; flex-direction: column; justify-content: space-between; gap: 32px; }
.feature-split .head { display: flex; flex-direction: column; gap: 16px; }
.feature-art { flex: 0 0 600px; height: 620px; display: flex; align-items: center; justify-content: center; padding: 24px; }
.composer { width: 440px; max-width: 100%; padding: 24px; border-radius: 20px; display: flex; flex-direction: column; gap: 20px; }
.field { display: flex; flex-direction: column; gap: 6px; flex: 1 0 0; min-width: 1px; }
.box { height: 40px; border: 1px solid var(--border); border-radius: 10px; background: var(--bg); display: flex; align-items: center; padding: 0 12px; font-size: 14px; line-height: 20px; white-space: nowrap; }
.box.q { width: 48px; flex: 0 0 48px; justify-content: center; padding: 0; }
.box.p { width: 96px; flex: 0 0 96px; }
.item-row { display: flex; gap: 8px; }
.item-row .box:first-child { flex: 1 0 0; min-width: 1px; }
.composer .actions { display: flex; gap: 8px; }
.composer .actions .send { flex: 1 0 0; padding: 0 12px 0 16px; gap: 10px; }

.tax-stack { display: flex; flex-direction: column; gap: 16px; width: 420px; max-width: 100%; }
.tax-card { padding: 16px; border-radius: 20px; display: flex; flex-direction: column; gap: 12px; }
.tax-card.estimate { padding: 20px; }
.icon-tile { width: 36px; height: 36px; flex: 0 0 36px; border-radius: 10px; background: var(--success-soft); display: flex; align-items: center; justify-content: center; }
.icon-tile img { width: 20px; height: 20px; }
.suggest { background: var(--success-soft); border-radius: 10px; padding: 12px 16px; display: flex; flex-direction: column; gap: 2px; white-space: nowrap; }
.period { display: flex; gap: 2px; padding: 2px; border-radius: 8px; background: var(--bg-subtle); }
.period span { padding: 4px 10px; border-radius: 6px; font-size: 12px; line-height: 16px; font-weight: 500; color: var(--text-soft); border: 1px solid transparent; }
.period span.on { background: var(--bg); border-color: var(--border); color: var(--text); }
.est-lines { display: flex; flex-direction: column; gap: 10px; }
.est-lines .row { font-size: 14px; line-height: 20px; white-space: nowrap; }

/* ── Wide feature (payments, dashboard) ───────────────── */
.wide-feature .inner { display: flex; flex-direction: column; gap: 40px; }
.wide-feature .head { display: flex; flex-direction: column; gap: 16px; max-width: 900px; }
.wide-media { width: 100%; display: flex; align-items: center; justify-content: center; padding: 32px; }
.payments-media { min-height: 520px; }
.table-card { width: 1088px; max-width: 100%; background: var(--bg); border-radius: 20px; padding: 24px 24px 16px; display: flex; flex-direction: column; gap: 16px; }
/* Still scrolls sideways on narrow screens, without showing a scrollbar. */
.table-scroll { overflow-x: auto; scrollbar-width: none; }
.table-scroll::-webkit-scrollbar { display: none; }
.inv-grid { display: grid; grid-template-columns: 100px 220px 140px 140px 140px 48px 200px; min-width: 988px; }
.inv-grid > div { display: flex; align-items: center; }
.inv-grid .h { height: 36px; font-size: 12px; line-height: 16px; font-weight: 500; color: var(--text-soft); white-space: nowrap; }
.inv-grid .c { height: 52px; font-size: 14px; line-height: 20px; white-space: nowrap; }
.inv-grid .r { justify-content: flex-end; }
.inv-grid .client { flex-direction: column; align-items: flex-start; justify-content: center; gap: 8px; }
.progress { width: 120px; height: 4px; border-radius: 9999px; background: var(--bg-subtle); display: flex; }
.progress span { height: 4px; border-radius: 9999px; background: var(--blue); min-width: 4px; }
.log-btn { height: 44px; padding: 0 12px; border-radius: 8px; background: var(--blue); color: #fff; display: inline-flex; align-items: center; gap: 6px; font-size: 14px; line-height: 20px; font-weight: 500; white-space: nowrap; }

.dashboard-feature .inner { gap: 48px; }
.dash-media { min-height: 560px; }
.window { width: 1088px; max-width: 100%; background: rgba(255, 255, 255, 0.95); border-radius: 20px; padding: 16px 20px 20px; display: flex; flex-direction: column; gap: 16px; }
.traffic { display: flex; gap: 6px; }
.traffic span { width: 10px; height: 10px; border-radius: 9999px; }
.kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.kpi { padding: 16px; border-radius: 16px; display: flex; flex-direction: column; gap: 4px; white-space: nowrap; }
.dash-body { display: flex; gap: 12px; height: 280px; }
.dash-chart { flex: 1 0 0; min-width: 1px; padding: 20px; border-radius: 16px; display: flex; flex-direction: column; gap: 16px; }
.dash-bars { flex: 1 0 0; display: flex; align-items: flex-end; gap: 12px; min-height: 1px; }
.dash-bars .bar-col { gap: 8px; }
.dash-bars .bar { width: 56px; max-width: 100%; border-radius: 8px; }
.attention { flex: 1 0 0; min-width: 300px; max-width: 384px; padding: 20px; border-radius: 16px; display: flex; flex-direction: column; gap: 12px; }
.attention .who { display: flex; flex-direction: column; gap: 2px; white-space: nowrap; }

/* ── Get paid ─────────────────────────────────────────── */
.getpaid { padding: 96px 0 24px; }
.getpaid-panel { padding: 96px 32px; display: flex; justify-content: center; }
.getpaid .inner { display: flex; flex-direction: column; align-items: center; gap: 20px; max-width: 880px; text-align: center; }
.getpaid .btn { min-width: 176px; padding: 0 24px; }
.tiles { display: flex; gap: 16px; flex-wrap: wrap; justify-content: center; margin-top: 0; }
.tile { width: 140px; display: flex; flex-direction: column; align-items: center; gap: 12px; }
.tile-icon { width: 72px; height: 72px; border-radius: 18px; background: var(--bg); border: 1px solid var(--border); display: flex; align-items: center; justify-content: center; }
.tile-icon img { width: 36px; height: 36px; }

/* ── Calculator ───────────────────────────────────────── */
.calc-panel { padding: 64px 24px; display: flex; flex-direction: column; align-items: center; gap: 12px; }
.calc-cards { width: 700px; max-width: 100%; display: flex; flex-direction: column; gap: 24px; margin-top: 12px; }
.calc-card { padding: 32px; border-radius: 20px; display: flex; flex-direction: column; gap: 20px; }
.calc-input {
  height: 44px; width: 120px; padding: 0 12px; border-radius: 10px; border: 1px solid var(--border);
  background: var(--bg); font: inherit; font-size: 16px; line-height: 24px; font-weight: 500; color: var(--text); text-align: left;
}
.rates { display: flex; gap: 12px; }
.rate {
  flex: 1 0 0; min-width: 1px; height: 48px; border-radius: 10px; border: 1px solid var(--border); background: var(--bg-surface);
  font-size: 16px; line-height: 24px; font-weight: 500; color: var(--text); cursor: pointer;
}
.rate:hover { border-color: #cfcfcf; }
.rate[aria-pressed="true"] { background: var(--blue-tint); border-color: var(--blue); color: var(--blue); }
.calc-line { display: flex; align-items: center; gap: 12px; }
.calc-icon { width: 36px; height: 36px; flex: 0 0 36px; border-radius: 18px; background: var(--blue-tint); display: flex; align-items: center; justify-content: center; }
.calc-icon img { width: 18px; height: 18px; }
/* Centred so a count-up stays balanced inside the width it reserves for the final number. */
.pill { padding: 4px 12px; border-radius: 9999px; background: var(--blue); color: #fff; font-size: 14px; line-height: 20px; font-weight: 500; white-space: nowrap; text-align: center; }
.big-total { padding: 4px 24px; border-radius: 10px; background: var(--blue); color: #fff; font-size: 60px; line-height: 72px; letter-spacing: -0.8px; font-weight: 600; white-space: nowrap; text-align: center; }

/* ── Privacy ──────────────────────────────────────────── */
.privacy { padding: 96px 0; }
.privacy .inner { display: flex; flex-direction: column; align-items: center; gap: 56px; }
.privacy .section-head { max-width: 760px; }
.privacy-cols { display: flex; gap: 64px; width: 100%; }
.privacy-col { flex: 1 0 0; min-width: 1px; display: flex; flex-direction: column; gap: 16px; }
.icon-48 { width: 48px; height: 48px; border-radius: 10px; background: var(--blue-tint); display: flex; align-items: center; justify-content: center; }
.icon-48 img { width: 24px; height: 24px; }

/* ── Testimonial ──────────────────────────────────────── */
.testimonial { position: relative; padding: 96px 0; overflow: hidden; }
.testimonial-field { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; pointer-events: none; }
.testimonial .inner { position: relative; display: flex; flex-direction: column; align-items: center; gap: 40px; text-align: center; }
.avatars { display: flex; gap: 24px; align-items: center; }
.profile {
  position: relative; padding: 12px; border-radius: 96px; border: 2px solid #ebebeb; background: none; cursor: pointer;
  transition: border-color .3s var(--ease-out), scale .15s var(--ease-out);
}
.profile:active { scale: 0.96; }
.profile[aria-pressed="true"] { border-color: #ebf1ff; }
.profile img { width: 56px; height: 56px; border-radius: 999px; object-fit: cover; object-position: center top; filter: grayscale(1); transition: filter .4s var(--ease-out); }
.profile[aria-pressed="true"] img { filter: none; }
.profile:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }
/* Slides share one grid cell, so the section is always as tall as the longest quote. */
.slides { display: grid; width: 100%; max-width: 800px; }
.slide { grid-area: 1 / 1; margin: 0; display: flex; flex-direction: column; align-items: center; }
.slide:not(.is-active) { visibility: hidden; }
.quote { max-width: 800px; margin: 0; }

/* ── Pricing ──────────────────────────────────────────── */
.pricing .inner { display: flex; flex-direction: column; align-items: center; gap: 56px; }
.pricing .section-head { max-width: 760px; }
.toggle { display: inline-flex; padding: 4px; border-radius: 9999px; background: var(--bg-subtle); }
.seg {
  height: 36px; padding: 0 20px; border-radius: 9999px; border: 1px solid transparent; background: transparent;
  font-size: 14px; line-height: 20px; font-weight: 500; color: var(--text-muted); cursor: pointer;
}
.seg[aria-pressed="true"] { background: var(--bg); border-color: var(--line); color: var(--text); }
.plans { display: flex; gap: 24px; justify-content: center; width: 100%; }
.plan { position: relative; isolation: isolate; overflow: hidden; width: 400px; min-height: 596px; padding: 32px; border-radius: 20px; display: flex; flex-direction: column; gap: 24px; }
.plan.free { background: var(--bg); border: 1px solid var(--border); }
.plan.pro { background: var(--bg-inverse); color: var(--text-inverse); }
.plan-field { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -1; pointer-events: none; }
.price { display: flex; align-items: flex-end; gap: 8px; white-space: nowrap; }
.badge { padding: 4px 10px; border-radius: 9999px; background: var(--blue); color: #fff; font-size: 12px; line-height: 16px; font-weight: 500; }
.strike { text-decoration: line-through; }
.features { display: flex; flex-direction: column; gap: 12px; }
.features li { display: flex; gap: 12px; align-items: flex-start; }
.features img { width: 20px; height: 20px; flex: 0 0 20px; margin-top: 2px; }
.bd ul.features { list-style: none; margin: 0; padding: 0; }
.plan .btn { width: 100%; }
.plan.pro .feat-text { color: var(--white-72); }
[hidden] { display: none !important; }

/* ── FAQ ──────────────────────────────────────────────── */
.faq { padding: 96px 0 0; }
.faq .inner { display: flex; flex-direction: column; align-items: center; gap: 48px; }
.faq-head { width: 734px; max-width: 100%; display: flex; flex-direction: column; align-items: center; gap: 16px; text-align: center; }
.faq-head .sub { max-width: 450px; }
.faq-list { width: 808px; max-width: 100%; display: flex; flex-direction: column; gap: 12px; }
.faq-item { background: var(--bg-surface); border: 1px solid var(--border-soft); border-radius: 16px; overflow: hidden; }
.faq-item summary {
  list-style: none; cursor: pointer; display: flex; align-items: center; gap: 48px; padding: 24px;
  font-size: 18px; line-height: 28px; font-weight: 500; color: var(--text-muted);
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item .num { width: 24px; flex: 0 0 24px; text-align: center; color: var(--text-soft); }
.faq-item .q { flex: 1 0 0; min-width: 1px; }
.faq-item .toggle-icon { width: 24px; height: 24px; flex: 0 0 24px; }
.faq-item .toggle-icon .close { display: none; }
.faq-item[open] summary { align-items: flex-start; }
.faq-item[open] .num { color: var(--text-muted); }
.faq-item[open] .q { color: var(--text); }
.faq-item[open] .toggle-icon .open { display: none; }
.faq-item[open] .toggle-icon .close { display: block; }
.faq-item .answer { padding: 0 24px 24px 96px; margin-top: -8px; font-size: 16px; line-height: 24px; font-weight: 500; color: var(--text-muted); }
.faq-more { text-align: center; font-weight: 500; color: var(--text-soft); }

/* ── Closing ──────────────────────────────────────────── */
.closing { padding: 96px 0; }
.closing-split { display: flex; gap: 24px; align-items: stretch; }
.closing-left { flex: 0 0 736px; min-height: 544px; display: flex; align-items: center; justify-content: center; padding: 32px; text-align: center; }
.closing-left .display { font-size: 48px; line-height: 60px; }
.closing-right { position: relative; isolation: isolate; overflow: hidden; flex: 1 0 0; min-width: 1px; background: var(--bg-inverse); border-radius: 24px; padding: 32px 36px; display: flex; flex-direction: column; gap: 16px; }
.closing-right .tag { align-self: flex-start; padding: 6px 12px 6px 10px; border-radius: 8px; background: var(--white-8); color: var(--text-disabled); }
.checks { display: flex; flex-direction: column; gap: 12px; }
.check { display: flex; gap: 12px; align-items: flex-start; }
.check-box { width: 18px; height: 18px; flex: 0 0 18px; border-radius: 4px; background: var(--bg); display: flex; align-items: center; justify-content: center; margin-top: 3px; }
.check-box img { width: 12px; height: 12px; }
.closing-right .cta { margin-top: auto; padding: 48px 64px 0; }
.closing-right .cta .btn { width: 100%; padding: 0 20px 0 24px; }

/* ── Footer ───────────────────────────────────────────── */
.footer { position: relative; overflow: hidden; background: var(--bg-inverse); color: var(--text-inverse); display: flex; flex-direction: column; gap: 64px; }
.footer-halo { position: absolute; top: 0; left: 50%; transform: translateX(-50%); width: 1440px; height: 720px; pointer-events: none; }
.footer-body { position: relative; padding-top: 96px; display: flex; flex-direction: column; gap: 96px; }
.footer-top { display: flex; gap: 48px; }
.footer-top .left { flex: 0 0 600px; }
.footer-top .h1 { font-size: 36px; line-height: 44px; letter-spacing: -0.4px; }
.footer-nav { flex: 1 0 0; display: flex; gap: 32px; }
.footer-group { flex: 1 0 0; min-width: 1px; display: flex; flex-direction: column; gap: 12px; }
.footer-group .head { font-weight: 500; margin-bottom: 4px; }
.footer-group a, .footer-group span { color: var(--white-64); }
.footer-group a:hover { color: var(--text-inverse); }
.footer-bar { display: flex; align-items: center; gap: 12px; }
.footer-bar > div { flex: 1 0 0; min-width: 1px; display: flex; align-items: center; }
.footer-bar .copy { justify-content: center; }
.footer-bar .ask { justify-content: flex-end; gap: 6px; }
.logo-white { color: var(--text-inverse); }
.logo-white img { width: 18px; height: 18px; }
.ask-btn { width: 32px; height: 32px; flex: 0 0 32px; border-radius: 10px; background: var(--white-8); display: flex; align-items: center; justify-content: center; transition: background-color .15s ease; }
.ask-btn:hover { background: rgba(255, 255, 255, 0.16); }
.ask-btn img { width: 18px; height: 18px; }
.wordmark { position: relative; height: 280px; overflow: hidden; display: flex; justify-content: center; }
.wordmark span { font-size: 412px; line-height: 364px; letter-spacing: -14px; font-weight: 500; color: #232228; white-space: nowrap; user-select: none; }

/* ── Motion ───────────────────────────────────────────── */
/* Initial states only apply under html.js (set in <head>); motion.js marks elements with data-r and adds .is-in.
   Individual translate/scale properties are used so they compose with existing transforms (e.g. the phone's mobile scale). */
.js:not(.motion-ready) :is(.hero-field, .hero-copy, .stage) { opacity: 0; }

.js [data-r] {
  transition: opacity .8s var(--ease-out), translate 1.1s var(--ease-out-expo), scale 1.1s var(--ease-out-expo),
              filter .8s var(--ease-out), clip-path 1.2s var(--ease-in-out);
  transition-delay: var(--d, 0ms);
}
.js [data-r]:not(.is-in) { opacity: 0; }
.js [data-r="up"]:not(.is-in) { translate: 0 24px; }
.js [data-r="soft"]:not(.is-in) { translate: 0 12px; filter: blur(6px); }
.js [data-r="pop"]:not(.is-in) { scale: 0.92; }
.js [data-r="fade"] { transition-duration: 1.4s; }
.js [data-r="rise"] { transition-duration: .7s, 1.1s, 1.1s, .8s, 1.2s; }
.js [data-r="rise"]:not(.is-in) { translate: 0 120px; }
.js :is([data-r^="bar"], [data-r="draw"]):not(.is-in) { opacity: 1; }
.js [data-r="bar-y"] { transform-origin: bottom; }
.js [data-r="bar-y"]:not(.is-in) { scale: 1 0; }
.js [data-r="bar-x"] { transform-origin: left; }
.js [data-r="bar-x"]:not(.is-in) { scale: 0 1; }
.js [data-r="draw"]:not(.is-in) { clip-path: inset(0 100% 0 0); }

/* Headings arrive word by word, the footer wordmark letter by letter. */
.js :is([data-r="words"], [data-r="letters"]):not(.is-in) { opacity: 1; }
.js :is([data-r="words"], [data-r="letters"]) .wi {
  display: inline-block;
  transition: opacity .7s var(--ease-out), translate 1s var(--ease-out-expo), filter .7s var(--ease-out);
  transition-delay: calc(var(--d, 0ms) + var(--wi) * 36ms);
}
.js [data-r="words"]:not(.is-in) .wi { opacity: 0; translate: 0 0.3em; filter: blur(8px); }
.js [data-r="letters"] .wi { transition-duration: .6s, 1.4s; transition-delay: calc(var(--d, 0ms) + var(--wi) * 55ms); }
.js [data-r="letters"]:not(.is-in) .wi { opacity: 0; translate: 0 100%; }

.scrub .wi { transition: opacity .25s linear; }

.nav { transition: background-color .3s var(--ease-out); }
.nav.is-scrolled { background: rgba(255, 255, 255, 0.82); -webkit-backdrop-filter: saturate(180%) blur(14px); backdrop-filter: saturate(180%) blur(14px); }
.nav .links a, .footer-group a, .faq-item .q { transition: color .15s ease; }

.btn-arrow img { transition: translate .25s var(--ease-out); }
/* Magnetic CTAs (motion.js sets translate); the transition is what makes the follow and the release glide. */
.btn.is-magnetic:not([data-r]) { transition: background-color .15s ease, scale .16s var(--ease-out), translate .45s var(--ease-out); }
.btn.is-magnetic .btn-arrow { transition: translate .45s var(--ease-out); }

/* Spotlight that follows the cursor (motion.js sets --mx / --my). */
.plan { --spot: rgba(37, 99, 235, 0.04); }
.plan.pro { --spot: rgba(255, 255, 255, 0.045); }
.closing-right { --spot: rgba(255, 255, 255, 0.09); }
.plan::after, .closing-right::after {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none; opacity: 0;
  background: radial-gradient(420px circle at var(--mx, 50%) var(--my, 50%), var(--spot), transparent 70%);
  transition: opacity .4s var(--ease-out);
}
.rate { transition: background-color .15s ease, border-color .15s ease, color .15s ease, scale .15s var(--ease-out); }
.rate:active, .seg:active { scale: 0.96; }
.tile-icon { transition: translate .3s var(--ease-out), border-color .3s var(--ease-out); }

/* Hover only where a real pointer can hover, so taps never leave things stuck. */
@media (hover: hover) and (pointer: fine) {
  .btn-arrowed:hover .btn-arrow img { translate: 2px -2px; }
  .plan:hover::after, .closing-right:hover::after { opacity: 1; }
  .tile:hover .tile-icon { translate: 0 -3px; border-color: #d4d4d4; }
  .faq-item summary:hover .q { color: var(--text); }
}

/* Pricing: one thumb slides between Monthly and Yearly; the new price settles in. */
.toggle { position: relative; }
.seg { position: relative; z-index: 1; transition: color .2s ease, scale .15s var(--ease-out); }
.seg-thumb {
  position: absolute; top: 4px; left: 0; height: 36px; border-radius: 9999px; background: var(--bg); border: 1px solid var(--line);
  transition: translate .4s var(--ease-in-out), width .4s var(--ease-in-out);
}
.has-thumb .seg[aria-pressed="true"] { background: transparent; border-color: transparent; }
.swap-in { animation: bd-swap .35s var(--ease-out) both; }
@keyframes bd-swap { from { opacity: 0; translate: 0 6px; filter: blur(4px); } }

/* Honey headlines (melt.js): the section pins at --pin-top for --pin of scroll while the honey pass plays.
   The WebGL copy only shows during the pass; at rest the real heading is what you see. */
[data-melt-pin].is-live::after { content: ""; display: block; height: var(--pin, 0px); }
[data-melt-pin].is-live > section { position: sticky; top: var(--pin-top, 0px); }
[data-melt] { position: relative; }
.melt-canvas { position: absolute; left: 0; top: 0; pointer-events: none; visibility: hidden; }
[data-melt].is-melting { color: transparent; }
[data-melt].is-melting .melt-canvas { visibility: visible; }

/* ── Demos and moments ─────────────────────────────────── */

/* First-visit intro: the mark settles, the wordmark wipes in, then the veil lifts off the hero. */
.intro-veil { display: none; }
.js.intro body { overflow: hidden; }
.js.intro .intro-veil {
  display: flex; position: fixed; inset: 0; z-index: 100; align-items: center; justify-content: center; background: var(--bg);
  clip-path: inset(0 0 0 0); transition: clip-path .8s var(--ease-in-out);
}
.js.intro.intro-out .intro-veil { clip-path: inset(0 0 100% 0); }
.intro-mark { display: flex; align-items: center; gap: 12px; font-size: 40px; line-height: 48px; font-weight: 500; letter-spacing: -0.6px; transition: opacity .3s ease, translate .6s var(--ease-out); }
.intro-mark img { width: 40px; height: 40px; animation: bd-intro-mark .8s var(--ease-out-expo) both; }
.intro-word { display: inline-block; clip-path: inset(0 100% 0 0); animation: bd-intro-word .8s .18s var(--ease-out-expo) both; }
.js.intro.intro-out .intro-mark { opacity: 0; translate: 0 -16px; }
@keyframes bd-intro-mark { from { opacity: 0; scale: 0.8; } }
@keyframes bd-intro-word { to { clip-path: inset(0 0 0 0); } }

/* Hero phone: the dynamic island opens into a payment notification, then the matching row glows. */
.island-alert {
  position: absolute; top: 30px; left: 50%; z-index: 2; translate: -50% 0; opacity: 0;
  width: 120px; height: 34px; border-radius: 20px; background: var(--bg-inverse); color: #fff; overflow: hidden;
  display: flex; align-items: center; gap: 12px; padding: 0 20px 0 12px;
  transition: width .6s cubic-bezier(0.32, 0.72, 0, 1), height .6s cubic-bezier(0.32, 0.72, 0, 1), border-radius .6s cubic-bezier(0.32, 0.72, 0, 1);
}
.island-alert.is-open, .island-alert.is-closing { opacity: 1; }
.island-alert.is-open { width: 400px; height: 64px; border-radius: 32px; }
.island-alert > * { flex: none; white-space: nowrap; opacity: 0; filter: blur(4px); transition: opacity .15s ease, filter .15s ease; }
.island-alert.is-open > * { opacity: 1; filter: none; transition: opacity .35s .22s var(--ease-out), filter .35s .22s var(--ease-out); }
.ia-icon { width: 40px; height: 40px; border-radius: 9999px; background: rgba(24, 199, 106, 0.18); display: flex; align-items: center; justify-content: center; }
.ia-icon img { width: 18px; height: 18px; }
.ia-text { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; }
.ia-title { font-size: 14px; line-height: 20px; font-weight: 500; }
.ia-sub { font-size: 12px; line-height: 16px; color: rgba(255, 255, 255, 0.6); }
.ia-amount { font-size: 16px; line-height: 24px; font-weight: 500; color: #4ade80; }
.recent-row { border-radius: 10px; }
.recent-row.is-new { animation: bd-row-glow 2.6s var(--ease-out); }
.recent-row.is-new .chip { animation: bd-pop .5s .35s var(--ease-out); }
@keyframes bd-row-glow { 0%, 100% { background: transparent; box-shadow: 0 0 0 8px transparent; } 18% { background: var(--success-soft); box-shadow: 0 0 0 8px var(--success-soft); } }
@keyframes bd-pop { 40% { scale: 1.14; } }

/* Invoice composer types itself, then sends. */
.composer { position: relative; }
.box.is-typing::after { content: ""; width: 1.5px; height: 16px; margin-left: 1px; background: var(--blue); animation: bd-caret 1s steps(1) infinite; }
@keyframes bd-caret { 50% { opacity: 0; } }
.composer .send { transition: background-color .15s ease, scale .16s var(--ease-out); }
.composer .send.is-pressed, .log-btn.is-pressed { scale: 0.96; filter: brightness(0.92); }
.log-btn { transition: scale .16s var(--ease-out), filter .16s ease; }
/* Sits 20px under the Send button (the card's bottom padding is 24px), and slides down into place. */
.composer-toast {
  position: absolute; left: 50%; top: calc(100% - 4px); translate: -50% -8px; scale: 0.96; opacity: 0; pointer-events: none;
  display: flex; align-items: center; gap: 8px; padding: 10px 16px 10px 12px; border-radius: 9999px; white-space: nowrap;
  background: var(--bg-inverse); color: #fff; font-size: 14px; line-height: 20px; font-weight: 500; box-shadow: 0 12px 32px rgba(12, 12, 12, 0.18);
  transition: opacity .3s var(--ease-out), translate .5s var(--ease-out-expo), scale .5s var(--ease-out-expo);
}
.composer-toast.is-shown { opacity: 1; translate: -50% 0; scale: 1; }
.composer-toast svg { width: 18px; height: 18px; flex: none; }

/* Payments table: logging Kofi Films' balance. */
.inv-grid .c { transition: background-color .5s var(--ease-out); }
.inv-grid .c.is-hl { background: var(--blue-tint); }
[data-kofi="bar"] { transition: width 1.2s var(--ease-out-expo); }
[data-kofi="chip"] { transition: background-color .4s ease, color .4s ease; }

/* Pricing: digits roll like an odometer; the old price's strike-through draws itself. */
.odo {
  display: inline-block; overflow: hidden; vertical-align: top; text-align: center;
  -webkit-mask: linear-gradient(transparent, #000 22%, #000 78%, transparent);
  mask: linear-gradient(transparent, #000 22%, #000 78%, transparent);
}
.odo-strip { display: block; transition: translate 1.1s var(--ease-out-expo); }
.odo-strip > span { display: block; }
.strike { position: relative; text-decoration: none; }
.strike::after { content: ""; position: absolute; left: -1px; right: -1px; top: 54%; height: 1.5px; background: currentColor; transform-origin: left; }
.swap-in .strike::after { animation: bd-strike .5s .35s var(--ease-out) both; }
@keyframes bd-strike { from { scale: 0 1; } }

/* Tax card: one pill slides between Month, Quarter and Year as the estimate cycles. */
.period { position: relative; }
.period span { position: relative; z-index: 1; transition: color .3s ease; }
.period.has-thumb span.on { background: transparent; border-color: transparent; }
.period > .period-thumb { position: absolute; z-index: 0; padding: 0; top: 2px; left: 0; height: calc(100% - 4px); border-radius: 6px; background: var(--bg); border: 1px solid var(--border); transition: translate .5s var(--ease-in-out), width .5s var(--ease-in-out); }

/* Smooth scrolling (Lenis) takes over from CSS smooth scrolling. */
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
.lenis.lenis-stopped { overflow: hidden; }

/* "Start free" grows into the sign-up card on the register page (browsers with cross-document view transitions). */
@view-transition { navigation: auto; }
::view-transition-group(bd-cta) { animation-duration: .6s; animation-timing-function: cubic-bezier(0.32, 0.72, 0, 1); }
::view-transition-old(root), ::view-transition-new(root) { animation-duration: .4s; }

/* Problem dive: by default the panel sits in the page as a normal card. Under .is-live (large screens, motion allowed)
   the track gets tall, the stage pins, and motion.js scrubs clip-path, layers and --ink from scroll progress. */
.dive { width: min(var(--container), calc(100% - var(--gutter) * 2)); margin: 40px auto 0; }
.dive-layer { display: contents; }
/* The negative bottom margin lets the next section rise over the paper while the zoom is still finishing,
   so there is no dead stretch of white between them. */
.dive.is-live { width: 100%; height: 280vh; margin: calc(40px - var(--t0, 0px)) 0 -100vh; }
.problem.is-diving { padding-bottom: 0; }
/* Everything after the dive sits above its stage: the stage's white paper ends 100vh below the dive, which can
   reach past "How it works" into the next sections and would otherwise cover them. */
.problem.is-diving ~ section, .problem.is-diving ~ div { position: relative; z-index: 1; }
.dive.is-live .dive-stage { position: sticky; top: 0; height: 100vh; overflow: hidden; pointer-events: none; }
.dive.is-live .problem-panel { position: absolute; inset: 0; min-height: 0; border-radius: 0; padding: var(--nav-h, 0px) 32px 0; }
.dive.is-live .dive-layer { display: block; flex: none; will-change: transform, opacity; }
.dive.is-live .problem-panel > .art-bg { will-change: transform; }
.dive.is-live :is(.invoice > :not(.invoice-paper), .stack-back1, .stack-back2) { opacity: var(--ink, 1); }

/* Testimonials: the active avatar's ring fills while its quote is up; motion.js advances when it completes. */
@property --ring { syntax: "<angle>"; inherits: false; initial-value: 0deg; }
.profile::after {
  content: ""; position: absolute; inset: -2px; padding: 2px; border-radius: inherit; pointer-events: none; opacity: 0;
  background: conic-gradient(var(--blue) var(--ring), transparent 0);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask: linear-gradient(#000 0 0) content-box exclude, linear-gradient(#000 0 0);
}
.testimonial.is-playing .profile[aria-pressed="true"]::after { opacity: 1; animation: bd-ring 7s linear forwards; }
.testimonial.is-playing.is-paused .profile[aria-pressed="true"]::after { animation-play-state: paused; }
@keyframes bd-ring { to { --ring: 360deg; } }
.slides .wi { display: inline-block; }
.slide.is-leaving { visibility: visible; pointer-events: none; animation: bd-out .22s var(--ease-out) both; }
.slide.is-entering .wi { animation: bd-word-in .8s var(--ease-out-expo) both; animation-delay: calc(80ms + var(--wi) * 24ms); }
.slide.is-entering figcaption { animation: bd-swap .5s var(--ease-out) .3s both; }
@keyframes bd-out { to { opacity: 0; translate: 0 -8px; filter: blur(6px); } }
@keyframes bd-word-in { from { opacity: 0; translate: 0 0.3em; filter: blur(8px); } }
@media (hover: hover) and (pointer: fine) {
  .profile:not([aria-pressed="true"]):hover img { filter: grayscale(0.4); }
}

/* FAQ: answers open and close smoothly where the browser can animate to auto height. */
@supports (interpolate-size: allow-keywords) and selector(::details-content) {
  .faq-list { interpolate-size: allow-keywords; }
  .faq-item::details-content { block-size: 0; transition: block-size .4s var(--ease-in-out), content-visibility .4s allow-discrete; }
  .faq-item[open]::details-content { block-size: auto; }
}
.faq-item[open] .answer { animation: bd-swap .4s var(--ease-out) .05s both; }
.faq-item[open] .toggle-icon .close { animation: bd-turn .3s var(--ease-out); }
@keyframes bd-turn { from { rotate: -90deg; opacity: 0; } }

/* ── Responsive ───────────────────────────────────────── */
@media (max-width: 1280px) {
  .feature-split > .left, .feature-art { flex: 1 1 0; min-width: 1px; }
  .closing-left { flex: 1.5 1 0; }
  .footer-top .left { flex: 1 1 0; }
  .problem-panel { gap: 20px; padding: 64px 20px; }
}

@media (max-width: 1100px) {
  .nav .links { display: none; }
  .problem-panel { flex-direction: column; }
  .p-card.payment { height: auto; }
  .feature-split { flex-direction: column; }
  .feature-split > .left { flex: none; }
  .feature-art { flex: none; width: 100%; }
  .feature-items.cols { flex-direction: column; gap: 0; }
  .kpis { grid-template-columns: repeat(2, 1fr); }
  .dash-body { flex-direction: column; height: auto; }
  .dash-chart { min-height: 280px; }
  .attention { max-width: none; min-width: 0; }
  .privacy-cols { flex-direction: column; gap: 40px; }
  .plans { flex-direction: column; align-items: center; }
  .plan { width: 100%; max-width: 480px; min-height: 0; }
  .closing-split { flex-direction: column; }
  .closing-left { flex: none; min-height: 420px; }
  .closing-right { flex: none; }
  .footer-top { flex-direction: column; }
  .footer-top .left { flex: none; }
}

@media (max-width: 760px) {
  :root { --gutter: 16px; }
  /* Desktop line breaks from the design read badly at phone widths. */
  :is(.display, .h1, .h2, .lead, .statement .line, .footer-top .h1) br { display: none; }
  .calc-hint { white-space: normal; }
  .announce .hide-sm { display: none; }
  .nav .login { display: none; }
  .nav .btn { min-width: 0; }
  .display { font-size: 40px; line-height: 48px; }
  .h1 { font-size: 34px; line-height: 42px; letter-spacing: -0.6px; }
  .h2 { font-size: 28px; line-height: 36px; }
  .h3, .t-3xl { font-size: 24px; line-height: 32px; }
  .hero { padding: 56px 0; }
  .hero-content { gap: 40px; }
  .stage { height: 420px; padding-top: 32px; overflow: hidden; }
  .phone-wrap { transform: scale(0.62); transform-origin: top center; }
  .statement .line { font-size: 20px; line-height: 32px; }
  .creatives { justify-content: center; gap: 12px 24px; }
  .creative { font-size: 18px; line-height: 28px; }
  .problem, .feature, .privacy, .testimonial, .closing { padding: 56px 0; }
  .getpaid { padding-top: 56px; }
  .faq { padding-top: 56px; }
  .problem-panel { padding: 32px 16px; }
  .p-card { width: 100%; flex: none; max-width: 360px; }
  .invoice-stack { width: 100%; max-width: 440px; flex: none; }
  .invoice { width: 100%; }
  .invoice-paper { width: 100%; height: 100%; object-fit: fill; }
  .steps { flex-direction: column; gap: 40px; }
  .steps-connector { display: none; }
  .feature-art { height: auto; min-height: 480px; padding: 24px 12px; }
  .wide-media { padding: 16px; }
  .payments-media, .dash-media { min-height: 0; }
  .kpis { grid-template-columns: 1fr; }
  .calc-card { padding: 20px; }
  .rates { flex-wrap: wrap; }
  .rate { flex: 1 0 calc(33.33% - 8px); }
  .big-total { font-size: 44px; line-height: 56px; }
  .getpaid-panel { padding: 56px 16px; }
  .tiles { gap: 20px 8px; }
  .tile { width: 120px; }
  .faq-item summary { gap: 16px; padding: 20px; font-size: 16px; line-height: 24px; }
  .faq-item .answer { padding: 0 20px 20px 60px; }
  .closing-left { min-height: 320px; }
  .closing-left .display { font-size: 34px; line-height: 42px; }
  .closing-right .cta { padding: 32px 0 0; }
  .footer-top .h1 { font-size: 28px; line-height: 36px; }
  .footer-nav { flex-wrap: wrap; gap: 32px 16px; }
  .footer-group { flex: 1 0 40%; }
  .footer-bar { flex-direction: column; align-items: flex-start; gap: 20px; }
  .footer-bar > div { justify-content: flex-start !important; }
  .wordmark { height: 160px; }
  .wordmark span { font-size: 27vw; line-height: 24vw; letter-spacing: -1vw; }
}

@media (prefers-reduced-motion: reduce) {
  @view-transition { navigation: none; }
  html { scroll-behavior: auto; }
  .btn, .ask-btn { transition: none; }
  /* Keep gentle fades; drop movement, blur and wipes. */
  .js [data-r], .js [data-r] .wi {
    translate: none !important; scale: none !important; filter: none !important; clip-path: none !important;
    transition-property: opacity !important; transition-duration: .5s !important;
  }
  .seg-thumb { transition: none; }
  .swap-in, .faq-item[open] .answer, .faq-item[open] .toggle-icon .close { animation: none; }
  .slide.is-entering .wi, .slide.is-entering figcaption { animation: none; }
  .steps-connector, .steps-connector::after { animation: none; }
  .swap-in .strike::after, .recent-row.is-new, .recent-row.is-new .chip { animation: none; }
  .steps-connector::after { display: none; }
  .faq-item::details-content { transition: none; }
}
