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

:root {
  /* The ground matches the app's own window, so product shots sit on the page with no frame. */
  --bg: #fcfcfd;
  --surface: #f1f1f4;
  --zebra: #f6f6f8;
  --ink: #1d1d1f;
  --muted: #5e5e66;
  --accent: #c8392f;
  --accent-ink: #ffffff;
  --line: rgb(0 0 0 / 0.08);
  --float: 0 0 0 0.5px rgb(0 0 0 / 0.16), 0 30px 80px rgb(20 20 60 / 0.28);
  --m: clamp(16px, 2.4vw, 32px);
  --bar: 60px;
  --t-s: 15px;
  --t-b: 17px;
  --t-l: 20px;
  --t-h: clamp(34px, 3.4vw, 52px);
  --t-d: clamp(88px, 12vw, 190px);
  --ease: cubic-bezier(0.2, 0.8, 0.2, 1);
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #141416; --surface: #1d1d20; --zebra: #19191b; --ink: #f2f2f4; --muted: #a2a2aa;
    --line: rgb(255 255 255 / 0.09); --float: 0 0 0 0.5px rgb(255 255 255 / 0.16), 0 30px 80px rgb(0 0 0 / 0.6);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #141416; --surface: #1d1d20; --zebra: #19191b; --ink: #f2f2f4; --muted: #a2a2aa;
  --line: rgb(255 255 255 / 0.09); --float: 0 0 0 0.5px rgb(255 255 255 / 0.16), 0 30px 80px rgb(0 0 0 / 0.6);
  color-scheme: dark;
}

html { scroll-padding-top: calc(var(--bar) + 4px); }
body {
  margin: 0; background: var(--bg); color: var(--ink); overflow-x: clip;
  font: var(--t-b)/1.5 -apple-system, BlinkMacSystemFont, "SF Pro Text", "Inter", "Helvetica Neue", sans-serif;
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
h1, h2, h3 { font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", "Inter", sans-serif; margin: 0; letter-spacing: -0.03em; line-height: 1.04; font-weight: 600; text-wrap: balance; }
h1, h2 { font-size: var(--t-h); }
h3 { font-size: var(--t-l); letter-spacing: -0.01em; line-height: 1.25; }
p { margin: 0; text-wrap: pretty; }
::selection { background: color-mix(in srgb, var(--accent) 26%, transparent); }
.wrap { padding-inline: var(--m); }
.lede { font-size: var(--t-l); max-width: 44ch; }
.note { font-size: var(--t-s); color: var(--muted); max-width: 70ch; }
/* No focus rings: keyboard focus is a soft tint in the control's own shape. */
:focus-visible { outline: none; background-color: color-mix(in srgb, var(--accent) 14%, transparent); border-radius: 6px; }
.btn:focus-visible { background-color: var(--accent); filter: brightness(1.15); }
.btn-ghost:focus-visible { background-color: color-mix(in srgb, var(--ink) 12%, var(--surface)); filter: none; }
@media (prefers-contrast: more), (forced-colors: active) { :focus-visible { outline: 2px solid CanvasText; } }

/* Buttons: one shape on the whole site, fully round, flat fill. */
.btn {
  display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: 0 24px;
  border: 0; border-radius: 999px; background: var(--accent); color: var(--accent-ink); font: inherit; font-weight: 600;
  text-decoration: none; white-space: nowrap; cursor: pointer;
  transition: transform 160ms var(--ease), filter 160ms var(--ease), background-color 160ms var(--ease);
}
.btn:hover { filter: brightness(1.1); }
.btn:active { transform: scale(0.97); }
.btn s { opacity: 0.7; margin: 0 0.3em; }
.btn:disabled { opacity: 0.45; filter: none; transform: none; cursor: default; }
.btn-small { min-height: 34px; padding: 0 16px; font-size: var(--t-s); }
.btn-ghost { background: var(--surface); color: var(--ink); }
.btn-ghost:hover { filter: none; background: color-mix(in srgb, var(--ink) 9%, var(--surface)); }
.btns { display: flex; flex-wrap: wrap; gap: 12px; }

/* Bar: wordmark, page links, one action. */
.bar {
  position: sticky; top: 0; z-index: 20; display: flex; align-items: center; gap: 28px;
  height: var(--bar); padding-inline: var(--m); background: var(--bg);
}
.mark { display: inline-flex; align-items: center; gap: 10px; font-weight: 600; text-decoration: none; margin-right: auto; white-space: nowrap; }
.mark img { width: 28px; height: 28px; }
.bar nav { display: flex; gap: 24px; font-size: var(--t-s); }
.bar nav a { text-decoration: none; color: var(--muted); transition: color 150ms; white-space: nowrap; }
.bar nav a:hover, .bar nav a[aria-current="page"] { color: var(--ink); }
.menu { display: none; position: relative; }
.menu summary { list-style: none; cursor: pointer; font-size: var(--t-s); color: var(--ink); padding: 6px 10px; border-radius: 8px; }
.menu summary::-webkit-details-marker { display: none; }
.menu[open] summary { background: var(--surface); }
.menu div {
  position: absolute; right: -8px; top: calc(100% + 10px); width: 220px; padding: 6px; display: grid;
  background: var(--bg); border-radius: 14px; box-shadow: var(--float); animation: drop 160ms var(--ease);
}
.menu div a { padding: 10px 12px; border-radius: 8px; text-decoration: none; }
.menu div a:hover { background: var(--surface); }
@keyframes drop { from { opacity: 0; transform: translateY(-6px); } }

/* Desk: a real wallpaper that the app and the price panels sit on, as on a Mac desktop. */
.desk { position: relative; overflow: hidden; border-radius: 18px; isolation: isolate; }
.desk > .wall { position: absolute; inset: 0; z-index: -1; }
.desk > .wall img { width: 100%; height: 100%; object-fit: cover; }

/* Story: the window stays pinned on the desk while the page scrolls through its sidebar. */
.story { --n: 10; height: calc(100svh + var(--n) * 52svh); }
.stage {
  position: sticky; top: var(--bar); height: calc(100svh - var(--bar)); padding: 8px var(--m) var(--m);
  display: grid; grid-template-columns: minmax(300px, 380px) 1fr; gap: 0 clamp(32px, 4vw, 64px);
}
.story-copy { display: flex; flex-direction: column; gap: 22px; padding-top: clamp(8px, 4svh, 48px); min-height: 0; }
.story-copy h1 { font-size: clamp(40px, 4.4vw, 68px); }
.story-copy .lede { max-width: 30ch; }
.steps { list-style: none; margin: 4px 0 0; padding: 0; display: grid; gap: 2px; }
.steps button {
  all: unset; box-sizing: border-box; display: flex; align-items: center; width: 100%; min-height: 34px; padding: 0 12px;
  border-radius: 8px; color: var(--muted); font-size: var(--t-s); cursor: pointer; transition: background-color 180ms var(--ease), color 180ms var(--ease);
}
.steps button:hover { color: var(--ink); }
.steps button[aria-current="step"] { background: var(--surface); color: var(--ink); font-weight: 600; }
.steps button:focus-visible { background: color-mix(in srgb, var(--accent) 14%, transparent); }
/* Every caption sits in one grid cell, so the tallest sets the height and nothing below moves. */
.caps { display: grid; margin-top: auto; }
.caps p { grid-area: 1 / 1; opacity: 0; transform: translateY(6px); transition: opacity 200ms var(--ease), transform 200ms var(--ease); }
.caps p.on { opacity: 1; transform: none; }
.caps b { display: block; font-size: var(--t-l); margin-bottom: 4px; }
.story .desk { container-type: size; min-height: 0; }
.story .wall img { transform: scale(1.06) translateY(calc(var(--p, 0) * -2.5%)); }
/* The captures are the real 1050 x 750 window with its own corners and shadow (1096 x 796 with the shadow). */
.win { position: absolute; left: 50%; top: 50%; width: min(92cqw, 92cqh * 1.377); aspect-ratio: 1096 / 796; translate: -50% -50%; }
.win picture { position: absolute; inset: 0; opacity: 0; transition: opacity 240ms var(--ease); }
.win picture.on { opacity: 1; }
.win img { width: 100%; height: 100%; object-fit: contain; }
.js .win { animation: open 700ms var(--ease) both 120ms; }
@keyframes open { from { opacity: 0; transform: translateY(40px) scale(0.94); } }

/* Summary window */
.summary { padding-top: clamp(120px, 14vw, 220px); }
.summary-head { display: grid; grid-template-columns: 7fr 5fr; gap: 16px 48px; align-items: end; }
.summary-head h2 { grid-column: 1; }
.summary-head .lede { grid-column: 1; }
.summary-head .seg { grid-column: 2; grid-row: 1 / span 2; justify-self: end; }
.seg { display: inline-flex; padding: 3px; border-radius: 9px; background: var(--surface); gap: 2px; }
.seg button {
  font: inherit; font-size: var(--t-s); font-weight: 500; color: var(--muted); background: transparent; border: 0;
  min-height: 34px; min-width: 88px; padding: 0 16px; border-radius: 7px; cursor: pointer;
  transition: background 180ms var(--ease), color 180ms var(--ease);
}
.seg button:hover { color: var(--ink); }
.seg button[aria-checked="true"] { background: var(--bg); color: var(--ink); }
.summary-shot { margin: 40px 0 0; overflow: hidden; }
.summary-shot img { width: 100%; }
.summary-shot picture.swap { animation: swap 260ms var(--ease); }
@keyframes swap { from { opacity: 0; transform: scale(0.985); } }
.uses { list-style: none; margin: 40px 0 0; padding-block: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 32px; }
.uses strong { display: block; font-size: var(--t-l); margin-bottom: 6px; }

/* Compare */
.compare { padding-top: clamp(120px, 14vw, 220px); display: grid; grid-template-columns: 5fr 7fr; gap: 48px; align-items: start; }
.compare-side { position: sticky; top: 92px; display: grid; gap: 16px; }
.side-shot { margin: 16px 0 0; }
.side-shot img { width: 100%; border-radius: 8px; }
.side-shot figcaption { font-size: var(--t-s); color: var(--muted); margin-top: 12px; }
table { width: 100%; border-collapse: collapse; }
thead th { position: sticky; top: var(--bar); background: var(--bg); text-align: left; font-weight: 600; font-size: var(--t-s); color: var(--muted); padding: 12px 12px 12px 0; z-index: 1; }
tbody th, tbody td { text-align: left; vertical-align: top; padding: 12px 12px 12px 0; border-top: 1px solid var(--line); font-weight: 400; }
thead th:last-child, tbody td:last-child { padding-right: 0; }
tbody th { width: 52%; }
thead th:nth-child(2), tbody td:nth-of-type(1) { width: 26%; }
td:first-of-type { font-weight: 600; }
tr.grp th { border-top: 0; padding-top: 32px; font-size: var(--t-l); font-weight: 600; }
tbody tr:not(.grp) { transition: background-color 150ms; }
tbody tr:not(.grp):hover { background: var(--surface); }
/* Footnote: a small underlined number; its note shows on hover or keyboard focus. */
.fn { position: relative; margin-left: 2px; font-size: 0.7em; color: var(--muted); text-decoration: underline; text-underline-offset: 2px; cursor: help; outline: none; }
.fn::after {
  content: attr(data-tip); position: absolute; left: 50%; bottom: calc(100% + 8px); translate: -50% 4px; width: max-content; max-width: 240px;
  padding: 8px 10px; border-radius: 8px; background: var(--ink); color: var(--bg); font-size: 13px; line-height: 1.35; font-weight: 400;
  text-align: left; white-space: normal; opacity: 0; pointer-events: none; transition: opacity 120ms, translate 120ms; z-index: 2;
}
.fn:hover::after, .fn:focus-visible::after { opacity: 1; translate: -50% 0; }
.fn:focus-visible { color: var(--ink); }
td .fn::after { left: auto; right: -8px; translate: 0 4px; }
td .fn:hover::after, td .fn:focus-visible::after { translate: 0 0; }

/* Performance: one flat field */
.perf { margin-top: clamp(120px, 14vw, 220px); background: var(--surface); padding-block: clamp(80px, 10vw, 160px); }
.perf-figure { font-size: var(--t-d); font-weight: 600; letter-spacing: -0.05em; line-height: 0.9; font-variant-numeric: tabular-nums; }
.perf h2 { margin-top: 16px; }
.perf .lede { margin-top: 20px; max-width: 46ch; }
.figures { list-style: none; margin: 64px 0 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 32px; }
.figures b { display: block; font-size: var(--t-h); font-weight: 600; letter-spacing: -0.03em; line-height: 1.1; font-variant-numeric: tabular-nums; margin-bottom: 8px; }
.figures b span { font-size: var(--t-l); color: var(--muted); letter-spacing: 0; }
.perf .note { margin-top: 40px; }

/* Pricing: two plans side by side on the desk. */
.pricing { padding-top: clamp(120px, 14vw, 220px); }
.pricing-head { display: grid; gap: 16px; margin-bottom: 40px; }
.pricing .desk { margin-inline: var(--m); padding: clamp(24px, 6vw, 96px) clamp(16px, 6vw, 96px); }
.plans { display: grid; grid-template-columns: 1fr 1fr; gap: 0 clamp(16px, 2vw, 28px); max-width: 1100px; margin: 0 auto; }
/* Subgrid: the price, the features, the terms, and the button line up across both plans. */
.plan { grid-row: span 5; display: grid; grid-template-rows: subgrid; row-gap: 20px; background: var(--bg); border-radius: 16px; padding: clamp(24px, 3vw, 40px); box-shadow: var(--float); }
.plan-name { display: flex; align-items: center; gap: 14px; }
.plan-name img { width: 56px; height: 56px; }
.plan-name :is(h2, h3) { font-size: 24px; letter-spacing: -0.02em; line-height: 1.2; }
.price { display: grid; gap: 4px; }
.price b { font-size: 56px; font-weight: 700; letter-spacing: -0.035em; line-height: 1; font-variant-numeric: tabular-nums; }
.price b span { font-size: var(--t-b); font-weight: 500; letter-spacing: 0; color: var(--muted); margin-left: 6px; }
.price small { font-size: var(--t-s); color: var(--muted); min-height: 1.5em; }
.feats { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.feats li { display: grid; grid-template-columns: 20px 1fr; gap: 10px; }
.feats li::before { content: ""; width: 16px; height: 16px; margin-top: 4px; border-radius: 50%; background: color-mix(in srgb, var(--accent) 16%, transparent); box-shadow: inset 0 0 0 4.5px var(--bg), inset 0 0 0 16px var(--accent); }
.plan.classic .feats li::before { box-shadow: inset 0 0 0 4.5px var(--bg), inset 0 0 0 16px var(--muted); }
.rows { margin: 0; border-radius: 10px; overflow: hidden; }
.rows div { display: flex; justify-content: space-between; gap: 24px; padding: 10px 14px; }
.rows div:nth-child(odd) { background: var(--zebra); }
.rows dt { color: var(--muted); }
.rows dd { margin: 0; text-align: right; font-weight: 500; }
.plan .btn { margin-top: auto; align-self: stretch; }
.pricing-foot.note { margin-top: 24px; text-align: center; max-width: none; }
.pricing-foot a { color: var(--ink); }

/* Plain pages: Pricing questions, Download, Changelog, and the legal pages. */
.page { padding-top: clamp(48px, 7vw, 112px); }
.page-head { display: grid; gap: 16px; max-width: 760px; }
.page-head h1 { font-size: clamp(40px, 5vw, 72px); }
.qa { margin-top: clamp(80px, 10vw, 160px); display: grid; grid-template-columns: 4fr 8fr; gap: 48px; align-items: start; }
.qa dl { margin: 0; display: grid; gap: 28px; }
.qa dt { font-weight: 600; font-size: var(--t-l); margin-bottom: 6px; }
.qa dd { margin: 0; max-width: 62ch; }
.apps { margin-top: 48px; display: grid; grid-template-columns: 1fr 1fr; gap: clamp(16px, 2vw, 28px); }
.app { background: var(--surface); border-radius: 16px; padding: clamp(24px, 3vw, 40px); display: flex; flex-direction: column; gap: 18px; }
.app .plan-name img { width: 72px; height: 72px; }
.app .btns { margin-top: 4px; }
.app .btn-ghost { background: var(--bg); }
.app .btn-ghost:hover { background: color-mix(in srgb, var(--ink) 6%, var(--bg)); }
.cmd { display: flex; align-items: center; gap: 8px; padding: 6px 6px 6px 14px; border-radius: 10px; background: var(--bg); min-width: 0; }
.cmd code { flex: 1; min-width: 0; overflow-wrap: anywhere; font: 14px/1.45 ui-monospace, "SF Mono", Menlo, monospace; }
.cmd button { flex: none; min-height: 32px; padding: 0 12px; border: 0; border-radius: 7px; background: var(--surface); color: var(--ink); font: inherit; font-size: 14px; font-weight: 500; cursor: pointer; transition: background-color 150ms; }
.cmd button:hover { background: color-mix(in srgb, var(--ink) 9%, var(--surface)); }
.needs { margin-top: 48px; }
.release { margin-top: 56px; display: grid; grid-template-columns: 220px 1fr; gap: 32px; max-width: 1100px; }
.release h2 { font-size: 40px; }
.release .when { color: var(--muted); margin-top: 6px; }
.release h3 { margin: 28px 0 10px; }
.release h3:first-child { margin-top: 0; }
.release ul, .legal ul { margin: 0; padding-left: 1.2em; display: grid; gap: 8px; }
.legal { max-width: 720px; margin-top: 48px; }
.legal h2 { font-size: 26px; letter-spacing: -0.02em; margin: 44px 0 12px; }
.legal p + p, .legal p + ul, .legal ul + p { margin-top: 12px; }
.legal .note { margin-top: 48px; }

/* Footer: the name returns, then the links. */
.foot { margin-top: clamp(120px, 14vw, 220px); padding: 48px var(--m) 32px; background: var(--surface); display: grid; grid-template-columns: 1fr auto; gap: 24px 48px; align-items: end; font-size: var(--t-s); }
.foot .mark { font-size: var(--t-l); }
.foot nav { display: flex; flex-wrap: wrap; gap: 10px 24px; justify-content: flex-end; }
.foot nav a { text-decoration: none; color: var(--ink); }
.foot nav a:hover { text-decoration: underline; }
.foot small { grid-column: 1 / -1; color: var(--muted); font-size: 14px; }

/* Entrances: content is visible without script; the script adds .js first. */
.js [data-in] { opacity: 0; transform: translateY(24px); transition: opacity 560ms var(--ease), transform 560ms var(--ease); transition-delay: var(--d, 0ms); }
.js [data-in].in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  .js [data-in] { transform: none; transition: opacity 200ms; }
  .js .win { animation: none; }
  .story .wall img { transform: scale(1.06); }
  .caps p { transform: none; }
  .summary-shot picture.swap { animation: none; }
}

/* Tablet: the menu replaces the links; the story stacks its copy over the desk. */
@media (max-width: 1080px) {
  .bar nav { display: none; }
  .menu { display: block; }
  .bar { gap: 12px; }
  .uses, .figures { grid-template-columns: repeat(2, 1fr); }
  .compare, .qa { grid-template-columns: 1fr; }
  .compare-side { position: static; }
  .side-shot { max-width: 520px; }
}
@media (max-width: 1080px), (max-height: 760px) {
  /* The copy opens up into the stage, so the caption can sit under the desk. */
  .stage { grid-template-columns: 1fr; grid-template-rows: auto auto 1fr auto; gap: 12px; padding-top: 12px; }
  .story-copy { display: contents; }
  .story .desk { order: 1; }
  .caps { order: 2; min-height: 0; }
  .story-copy h1 { font-size: clamp(32px, 6vw, 52px); }
  .story-copy .lede { font-size: var(--t-b); max-width: 52ch; }
  .story-copy .btns, .steps { display: none; }
  .caps { margin-top: 0; }
  .caps b { font-size: var(--t-b); margin-bottom: 2px; }
  .caps p { font-size: var(--t-s); }
}

@media (max-width: 760px) {
  .desk { border-radius: 14px; }
  .win { width: 100cqw; }
  .summary-head { grid-template-columns: 1fr; }
  .summary-head .seg { grid-column: 1; grid-row: auto; justify-self: start; }
  .summary-shot img { width: 240%; max-width: none; margin-left: -70%; }
  .uses, .figures { grid-template-columns: 1fr; gap: 24px; }
  table { font-size: var(--t-s); }
  tbody th { width: 46%; }
  .plans, .apps { grid-template-columns: 1fr; }
  .pricing .desk { margin-inline: 0; border-radius: 0; padding: 32px 16px; }
  .price b { font-size: 48px; }
  .rows div { flex-direction: column; gap: 2px; }
  .rows dd { text-align: left; }
  .release { grid-template-columns: 1fr; gap: 16px; }
  .foot { grid-template-columns: 1fr; }
  .foot nav { justify-content: flex-start; }
}

/* Store only: the buy page's side column. */
[hidden] { display: none !important; }
.app-side { padding: clamp(8px, 3vw, 40px) 0; display: grid; align-content: start; gap: 18px; }
.app-side h2 { font-size: 24px; letter-spacing: -0.02em; }
.steps-list { margin: 0; padding-left: 1.2em; display: grid; gap: 12px; }
