/* Nestora website. Brand: identity v1 (docs/brand, frozen 2026-09-14). Two colours: forest and cream, with tonal steps of each. */
:root {
  --forest: #1A2E27;
  --forest-2: #24402F;
  --forest-deep: #13211B;
  --cream: #F9F8F4;
  --surface: #FFFFFF;
  --ink: #111C18;
  --ink-2: #3B4A45;
  --muted: #606E69;
  --line: #E5E5E0;
  --hair: rgba(26, 46, 39, 0.08);
  --tint: rgba(26, 46, 39, 0.07);
  --shadow: 0 1px 2px rgba(26, 46, 39, 0.06), 0 18px 40px -24px rgba(26, 46, 39, 0.35);
  --serif: 'Cormorant Garamond', Georgia, 'Times New Roman', serif;
  --sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --measure: 680px;
  --wide: 1360px;
  --gutter: 56px;
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  margin: 0;
  background: var(--cream);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
a { color: var(--forest); text-underline-offset: 3px; text-decoration-thickness: 1px; }
a:hover { color: var(--forest-2); }
:focus-visible { outline: 2px solid var(--forest); outline-offset: 3px; border-radius: 4px; }
img { display: block; max-width: 100%; }
h1, h2, h3 { font-weight: 600; color: var(--ink); }
.serif, .hero h1, .problem h2, .demo h2, .control h2, .privacy h2, .closing h2 { font-family: var(--serif); font-weight: 600; letter-spacing: -0.015em; }

.skip { position: absolute; left: -9999px; }
.skip:focus { left: 16px; top: 12px; background: var(--surface); padding: 8px 12px; z-index: 50; }

/* Header */
.site-header {
  max-width: var(--wide);
  margin: 0 auto;
  padding: 28px var(--gutter);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
}
.home .site-header { position: absolute; top: 0; left: 0; right: 0; z-index: 20; }
.brand { display: inline-flex; align-items: center; }
.brand img { height: 30px; width: auto; }
.nav { display: flex; gap: 32px; flex-wrap: wrap; }
.nav a {
  color: var(--ink-2);
  text-decoration: none;
  font-size: 15px;
  font-weight: 500;
  padding: 6px 0;
  background: linear-gradient(var(--forest), var(--forest)) left bottom / 0 1.5px no-repeat;
  transition: background-size 400ms var(--ease), color 400ms var(--ease);
}
.nav a:hover, .nav a[aria-current="page"] { color: var(--forest); background-size: 100% 1.5px; }

.btn {
  display: inline-block;
  border: 1.5px solid var(--forest);
  color: var(--forest);
  text-decoration: none;
  font-weight: 600;
  font-size: 15px;
  padding: 13px 24px;
  border-radius: 6px;
  transition: background 400ms var(--ease), color 400ms var(--ease);
}
.btn:hover { background: var(--forest); color: var(--cream); }

/* ---------- Phone: the Today view, sample data ---------- */
.phone {
  --s: 1;
  width: 417px; height: 876px;
  padding: 12px;
  border-radius: 66px;
  background: var(--forest-deep);
  box-shadow: 0 0 0 1.5px #2C3F37 inset, 0 60px 100px -50px rgba(19, 33, 27, 0.6);
  transform: scale(var(--s)); transform-origin: top left;
}
.screen { position: relative; height: 100%; border-radius: 54px; background: var(--cream); overflow: hidden; padding: 0 20px; color: var(--ink); font-family: var(--sans); }
.p-status { display: flex; justify-content: space-between; align-items: center; height: 56px; padding: 4px 12px 0 18px; }
.p-time { font-size: 17px; font-weight: 600; }
.p-island { width: 122px; height: 35px; border-radius: 20px; background: var(--forest-deep); }
.p-icons { display: flex; gap: 6px; align-items: center; fill: var(--ink); color: var(--ink); }
.p-top { display: flex; align-items: center; gap: 12px; margin-top: 8px; }
.p-word { font-family: var(--serif); font-weight: 600; font-size: 25px; color: var(--forest); letter-spacing: -0.01em; flex: 1; }
.p-sync { font-size: 13px; color: var(--muted); }
.p-ic { color: var(--ink-2); display: flex; }
.p-greet { font-family: var(--serif); font-weight: 600; font-size: 32px; line-height: 1.1; margin: 16px 0 14px; letter-spacing: -0.01em; }
.p-tabs { display: flex; gap: 22px; font-size: 15px; font-weight: 500; color: var(--muted); border-bottom: 1px solid var(--line); margin: 0 -20px 14px; padding: 0 20px; }
.p-tabs span { padding-bottom: 11px; white-space: nowrap; }
.p-tabs .on { color: var(--ink); font-weight: 600; box-shadow: inset 0 -2.5px 0 var(--forest); }
.p-tabs i, .p-label i { font-style: normal; font-size: 12px; font-weight: 600; background: var(--tint); color: var(--ink-2); border-radius: 999px; padding: 2px 8px; margin-left: 4px; letter-spacing: 0; }
.p-card { background: var(--surface); border-radius: 18px; padding: 13px 16px 2px; margin-bottom: 10px; box-shadow: 0 1px 2px rgba(26, 46, 39, 0.06); }
.p-label { font-size: 11.5px; font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); padding-bottom: 10px; border-bottom: 1px solid var(--line); }
.p-row { display: flex; align-items: center; gap: 10px; padding: 10px 0; }
.p-row + .p-row { border-top: 1px solid var(--line); }
.p-row > div { flex: 1; min-width: 0; }
.p-row b { display: block; font-weight: 500; font-size: 16.5px; line-height: 1.3; }
.p-row small { display: block; color: var(--muted); font-size: 13.5px; margin-top: 2px; }
.p-chip { background: var(--tint); color: var(--forest); font-weight: 600; font-size: 12px; border-radius: 999px; padding: 5px 10px; white-space: nowrap; }
.p-tick { width: 23px; height: 23px; border-radius: 50%; border: 1.6px solid var(--ink-2); flex: none; }
.p-btn { border: 1px solid var(--forest); color: var(--forest); border-radius: 10px; font-weight: 600; font-size: 13px; padding: 6px 12px; white-space: nowrap; }
.p-tabbar { position: absolute; left: 0; right: 0; bottom: 0; height: 92px; padding: 10px 14px 0; display: flex; justify-content: space-around; border-top: 1px solid var(--line); background: var(--cream); }
.p-tabbar span { display: flex; flex-direction: column; align-items: center; gap: 4px; font-size: 11.5px; font-weight: 500; color: var(--muted); }
.p-tabbar span.on { color: var(--forest); }
.p-tabbar span.on svg { fill: var(--forest); }
.p-tabbar svg { color: currentColor; }

/* ---------- Hero ---------- */
.hero {
  max-width: var(--wide);
  margin: 0 auto;
  padding: 0 var(--gutter);
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(0, 1fr);
  column-gap: 48px;
  min-height: min(100vh, 1000px);
  position: relative;
}
.hero::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 1px; background: var(--line); }
.hero-copy { align-self: center; padding: 150px 0 110px; }
.hero h1 { font-size: clamp(56px, 7.4vw, 118px); line-height: 0.94; letter-spacing: -0.02em; margin: 0 0 36px; text-wrap: balance; }
.hero h1 span { display: block; font-style: italic; color: var(--forest); }
.lede { font-size: 20px; line-height: 1.55; color: var(--ink-2); margin: 0 0 40px; max-width: 29em; }
.status { font-size: 15px; color: var(--muted); margin: 0; }
.status a { color: var(--ink-2); text-decoration: none; background: linear-gradient(var(--forest), var(--forest)) left bottom / 100% 1px no-repeat; padding-bottom: 2px; }
.status a:hover { color: var(--forest); }
.hero-device { align-self: end; justify-self: center; position: relative; overflow: hidden; --hs: 1.08; width: calc(417px * var(--hs)); height: clamp(560px, 80vh, 820px); }
.hero-device .phone { --s: var(--hs); }

/* ---------- Problem ---------- */
.problem { max-width: var(--wide); margin: 0 auto; padding: 170px var(--gutter) 160px; }
.problem h2 { font-size: clamp(46px, 6.4vw, 104px); line-height: 0.98; letter-spacing: -0.02em; margin: 0 0 88px; font-weight: 500; }
.problem h2 > span { display: block; }
.problem h2 > span + span { padding-left: 1.4em; }
.problem h2 .mem { color: var(--forest); }
.problem-body { display: grid; grid-template-columns: minmax(0, 30%) minmax(0, 1fr); column-gap: 3%; align-items: start; }
.problem-lede { font-size: 19px; color: var(--muted); margin: 0; max-width: 16em; }
.moments { list-style: none; margin: 0; padding: 0; }
.moments li { font-family: var(--serif); font-weight: 500; font-size: clamp(24px, 2.3vw, 34px); line-height: 1.25; padding: 22px 0; border-top: 1px solid var(--line); }
.moments li:last-child { border-bottom: 1px solid var(--line); }

/* ---------- Demonstration ---------- */
.demo { position: relative; border-top: 1px solid var(--line); }
.stage {
  position: relative;
  max-width: var(--wide);
  margin: 0 auto;
  padding: 120px var(--gutter);
  display: grid;
  grid-template-columns: minmax(0, 600px) minmax(0, 1fr);
  column-gap: 64px;
  align-items: center;
}
.demo-copy { position: relative; z-index: 3; }
.demo h2 { font-size: clamp(40px, 3.9vw, 56px); line-height: 1.02; margin: 0 0 22px; max-width: 11em; }
.demo h2 span { display: block; font-style: italic; color: var(--forest); }
.demo-lede { font-size: 18px; color: var(--ink-2); max-width: 26em; margin: 0 0 36px; }
.ledger { list-style: none; margin: 0; padding: 0; border-bottom: 1px solid var(--line); }
.ledger li { display: grid; grid-template-columns: 11.5em minmax(0, 1fr); gap: 16px; padding: 13px 0; border-top: 1px solid var(--line); font-size: 15px; line-height: 1.45; }
.ledger .from { color: var(--muted); }
.ledger em { font-style: normal; font-weight: 600; color: var(--forest); margin-right: 4px; }
.ledger li[data-for="noise"] .to, .ledger li[data-for="noise"] em { color: var(--muted); }
.demo-lede-short, .pairs { display: none; }
.demo-device { justify-self: center; position: relative; z-index: 1; --ds: 0.8; width: calc(417px * var(--ds)); height: calc(876px * var(--ds)); }
.demo-device .phone { --s: var(--ds); }
.demo-device .slot { border-radius: 8px; }

/* The six emails. Their size and position are set by story.js, relative to the phone. */
.pieces { position: absolute; inset: 0; pointer-events: none; z-index: 4; display: none; }
.piece, .pair-src {
  background: var(--surface);
  border: 1px solid var(--hair);
  border-radius: 4px;
  padding: 14px 16px 15px;
  box-shadow: var(--shadow);
}
.piece { position: absolute; left: 0; top: 0; width: 260px; transform: rotate(var(--r, 0deg)); will-change: transform, opacity; }
.src { display: flex; justify-content: space-between; gap: 12px; font-size: 12px; color: var(--muted); white-space: nowrap; }
.src b { color: var(--ink); font-weight: 600; overflow: hidden; text-overflow: ellipsis; }
.piece p, .pair-src p { margin: 6px 0 0; font-size: 14px; line-height: 1.45; color: var(--ink-2); }
.piece:nth-child(1) { --d: 0.1s; }
.piece:nth-child(2) { --d: 0.2s; }
.piece:nth-child(3) { --d: 0.3s; }
.piece:nth-child(4) { --d: 0.4s; }
.piece:nth-child(5) { --d: 0.5s; }
.piece:nth-child(6) { --d: 0.6s; }
.piece:nth-child(7) { --d: 0.7s; }
/* A scanned document: the same card, holding a small document instead of an email's words. */
.scan { margin-top: 8px; border: 1px solid var(--line); border-radius: 8px; padding: 10px 12px 11px; background: var(--cream); display: grid; gap: 1px; }
.scan span { font-size: 10.5px; font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); }
.scan b { font-size: 15px; font-weight: 600; color: var(--ink); line-height: 1.3; }
.scan small { font-size: 12.5px; color: var(--ink-2); }

/* Pinned scene (motion on). story.js locks the heights in pixels once it has measured them. */
html.pin .demo { height: 300vh; }
html.pin .stage { position: sticky; top: 0; height: 100vh; min-height: 640px; overflow: hidden; padding-top: 72px; padding-bottom: 48px; }
html.pin .pieces { display: block; }
html.pin .slot { opacity: 0; }
html.pin .p-label i { opacity: 0; }
html.pin .ledger li { opacity: 0.22; transition: opacity 400ms var(--ease); }
html.pin .ledger li.on { opacity: 1; }

/* ---------- You stay in charge ---------- */
.control { max-width: var(--wide); margin: 0 auto; padding: 120px var(--gutter) 140px; border-top: 1px solid var(--line); display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: 96px; align-items: center; }
.control h2 { font-family: var(--serif); font-weight: 600; font-size: clamp(40px, 4.3vw, 66px); line-height: 1; letter-spacing: -0.015em; margin: 0 0 22px; }
.control h2 span, .closing h2 span { display: block; font-style: italic; color: var(--forest); }
.control p { margin: 0; font-size: 19px; line-height: 1.55; color: var(--ink-2); max-width: 26em; }
.ex { margin: 0; justify-self: center; width: 100%; max-width: 440px; }
.ex figcaption { font-size: 13.5px; color: var(--muted); margin: 0 0 12px; }
/* Three sources, one Friday. */
.assemble { display: grid; }
.sources { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.sources li { background: var(--surface); border: 1px solid var(--hair); border-radius: 4px; padding: 11px 14px 12px; box-shadow: var(--shadow); }
.sources li p { margin: 4px 0 0; font-size: 13.5px; line-height: 1.45; color: var(--ink-2); max-width: none; }
.sources li.cal { background: var(--tint); border-color: transparent; box-shadow: none; }
.sources li.cal p { color: var(--ink); }
.sources mark { background: var(--tint); color: var(--ink); border-radius: 3px; padding: 1px 2px; margin: 0 -1px; box-shadow: inset 0 -1.5px 0 var(--forest); }
.join { width: 1px; height: 28px; margin: 6px auto; background: var(--forest); opacity: 0.45; }
.result { background: var(--surface); border-radius: 18px; box-shadow: var(--shadow); padding: 14px 18px 10px; }
.result-head { font-family: var(--serif); font-weight: 600; font-size: 21px; letter-spacing: -0.01em; padding-bottom: 10px; border-bottom: 1px solid var(--line); }
.result-row { display: flex; align-items: center; gap: 10px; padding: 11px 0; border-bottom: 1px solid var(--line); }
.result-row > div { flex: 1; min-width: 0; }
.result-row b { display: block; font-weight: 500; font-size: 16px; line-height: 1.3; }
.result-row small { display: block; color: var(--muted); font-size: 13px; margin-top: 2px; }
.result .result-note { margin: 10px 0 4px; font-size: 13px; line-height: 1.5; color: var(--muted); max-width: none; }
html.motion .control .result-row, html.motion .control .result-note { opacity: 0; transform: translateY(8px); transition: opacity 520ms var(--ease), transform 520ms var(--ease); }
html.motion .control .result-row:nth-child(2) { transition-delay: 600ms; }
html.motion .control .result-row:nth-child(3) { transition-delay: 760ms; }
html.motion .control .result-note { transition-delay: 980ms; }
html.motion .control.in .result-row, html.motion .control.in .result-note { opacity: 1; transform: none; }
html.motion .control .sources mark { background: linear-gradient(var(--tint), var(--tint)) left / 0 100% no-repeat; box-shadow: none; transition: background-size 600ms var(--ease) 200ms, box-shadow 300ms var(--ease) 700ms; }
html.motion .control.in .sources mark { background-size: 100% 100%; box-shadow: inset 0 -1.5px 0 var(--forest); }

/* ---------- Privacy ---------- */
.privacy { border-top: 1px solid var(--line); }
.privacy-inner { max-width: var(--wide); margin: 0 auto; padding: 130px var(--gutter) 130px; display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: 96px; align-items: center; }
.eyebrow { font-size: 12px; font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase; color: var(--forest); margin: 0 0 22px; }
.privacy h2 { font-size: clamp(46px, 5.6vw, 92px); line-height: 0.98; margin: 0; letter-spacing: -0.02em; font-weight: 500; text-wrap: balance; }
.privacy h2 span { display: block; font-style: italic; color: var(--forest); }
.privacy-lede { font-size: 20px; line-height: 1.55; color: var(--ink-2); margin: 32px 0 0; max-width: 26em; }
.privacy-foot { margin: 28px 0 0; padding-top: 18px; border-top: 1px solid var(--line); font-size: 14.5px; line-height: 1.55; color: var(--muted); max-width: 30em; }
.privacy-foot a { color: var(--forest); }
/* One flow: where your information is processed. */
.flow { list-style: none; margin: 0; padding: 0; display: grid; justify-items: stretch; }
.node { position: relative; border: 1px solid var(--line); border-radius: 16px; padding: 22px 24px 24px; background: var(--surface); }
.node b { display: block; font-family: var(--serif); font-weight: 600; font-size: 26px; line-height: 1.1; letter-spacing: -0.01em; }
.node span { display: block; margin-top: 6px; font-size: 15px; line-height: 1.45; color: var(--ink-2); }
.node i { display: block; font-style: normal; font-size: 11.5px; font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase; margin: 0 0 12px; color: rgba(249, 248, 244, 0.7); }
.node.device { background: var(--forest); border-color: var(--forest); color: var(--cream); padding: 24px 24px 26px; }
.node.device span { color: rgba(249, 248, 244, 0.82); }
.node + .node { margin-top: 34px; }
.node + .node::before { content: ""; position: absolute; left: 50%; top: -35px; width: 1px; height: 34px; background: var(--forest); opacity: 0.5; }
.node + .node::after { content: ""; position: absolute; left: calc(50% - 3px); top: -8px; width: 6px; height: 6px; border-right: 1px solid var(--forest); border-bottom: 1px solid var(--forest); transform: rotate(45deg); opacity: 0.6; }

/* ---------- Closing ---------- */
.closing { max-width: var(--wide); margin: 0 auto; padding: 150px var(--gutter) 160px; display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: 96px; align-items: end; }
.closing h2 { font-size: clamp(44px, 5.2vw, 84px); line-height: 0.98; margin: 0 0 24px; max-width: 11em; font-weight: 500; letter-spacing: -0.02em; }
.closing-lede { font-size: 19px; line-height: 1.55; color: var(--ink-2); max-width: 28em; margin: 0; }
.contacts { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }
.contacts li { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; flex-wrap: wrap; padding: 16px 0; border-bottom: 1px solid var(--line); }
.contacts span { color: var(--muted); font-size: 15px; }
.contacts a { font-weight: 500; }

/* ---------- Documents and support ---------- */
.doc { max-width: var(--measure); margin: 0 auto; padding: 56px 24px 140px; }
.doc h1 {
  font-family: var(--serif);
  font-weight: 600;
  font-size: clamp(56px, 7vw, 96px);
  line-height: 0.95;
  letter-spacing: -0.02em;
  margin: 0 0 20px;
}
.doc .meta { color: var(--muted); font-size: 15px; margin: 0 0 8px; padding-bottom: 28px; border-bottom: 1px solid var(--line); display: flex; gap: 8px 24px; flex-wrap: wrap; }
.doc .meta span { white-space: nowrap; }
.doc h2 { font-family: var(--serif); font-weight: 600; font-size: 30px; line-height: 1.1; letter-spacing: -0.01em; margin: 64px 0 14px; scroll-margin-top: 24px; font-variant-numeric: lining-nums; }
.doc h2 + p, .doc h2 + ul { margin-top: 0; }
.doc p, .doc li { color: var(--ink-2); }
.doc strong { color: var(--ink); font-weight: 600; }
.doc ul { padding-left: 22px; }
.doc li { margin: 8px 0; }
.doc li > p { margin: 0; }

/* ---------- Support ---------- */
.support { max-width: var(--wide); margin: 0 auto; padding: 56px var(--gutter) 150px; }
.support-head { padding-bottom: 48px; border-bottom: 1px solid var(--line); margin-bottom: 64px; }
.support h1 { font-family: var(--serif); font-weight: 600; font-size: clamp(56px, 7vw, 104px); line-height: 0.95; letter-spacing: -0.02em; margin: 0 0 24px; }
.support-lede { font-size: 20px; line-height: 1.55; color: var(--ink-2); max-width: 30em; margin: 0; }
.support-grid { display: grid; grid-template-columns: minmax(0, 360px) minmax(0, 1fr); column-gap: 112px; align-items: start; }
.support-contact { position: sticky; top: 40px; }
.support-contact h2 { font-family: var(--serif); font-weight: 600; font-size: 34px; line-height: 1.05; letter-spacing: -0.01em; margin: 0 0 24px; }
.support-note { font-size: 15px; line-height: 1.55; color: var(--ink-2); margin: 20px 0 0; max-width: 24em; }
.addresses { margin: 36px 0 0; border-top: 1px solid var(--line); }
.addresses div { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; flex-wrap: wrap; padding: 14px 0; border-bottom: 1px solid var(--line); }
.addresses dt { color: var(--muted); font-size: 15px; }
.addresses dd { margin: 0; font-weight: 500; }
.support-meta { margin: 20px 0 0; font-size: 13.5px; color: var(--muted); display: flex; gap: 4px 20px; flex-wrap: wrap; }
.support-meta span { white-space: nowrap; }
.support-meta a { color: var(--muted); }
.support-meta a:hover { color: var(--forest); }
.support-qa section + section { margin-top: 72px; }
.support-qa h2 { font-family: var(--serif); font-weight: 600; font-size: 34px; line-height: 1.05; letter-spacing: -0.01em; margin: 0 0 8px; }
.qa { margin: 0; }
.qa div { padding: 22px 0; border-top: 1px solid var(--line); }
.qa div:last-child { border-bottom: 1px solid var(--line); }
.qa dt { font-weight: 600; font-size: 18px; line-height: 1.35; color: var(--ink); margin: 0 0 8px; }
.qa dd { margin: 0; color: var(--ink-2); font-size: 16.5px; line-height: 1.6; max-width: 36em; }
.qa dd a { font-weight: 500; }

/* ---------- Footer ---------- */
.site-footer { background: var(--forest); color: var(--cream); }
.site-footer .inner { max-width: var(--wide); margin: 0 auto; padding: 44px var(--gutter) 36px; display: flex; align-items: center; gap: 24px 48px; flex-wrap: wrap; }
.foot-lockup { height: 26px; width: auto; }
.foot-links { list-style: none; margin: 0; padding: 0; display: flex; gap: 26px; flex-wrap: wrap; }
.foot-links + .foot-links { margin-left: auto; }
.site-footer a { color: var(--cream); text-decoration: none; font-size: 15px; }
.site-footer a:hover { text-decoration: underline; }
.site-footer .legal { max-width: var(--wide); margin: 0 auto; padding: 20px var(--gutter) 32px; box-shadow: inset 0 1px 0 rgba(249, 248, 244, 0.14); font-size: 13px; color: rgba(249, 248, 244, 0.62); }

/* ---------- Motion: one load sequence and the scroll moments ---------- */
html.motion .hero h1, html.motion .lede, html.motion .status { animation: rise 1000ms var(--ease) backwards; }
html.motion .lede { animation-delay: 140ms; }
html.motion .status { animation-delay: 260ms; }
html.motion .hero-device .phone { animation: lift 1400ms var(--ease) 200ms backwards; }
html.motion .hero-device .p-card { animation: rise 900ms var(--ease) backwards; }
html.motion .hero-device .p-card:nth-child(1) { animation-delay: 700ms; }
html.motion .hero-device .p-card:nth-child(2) { animation-delay: 820ms; }
html.motion .hero-device .p-card:nth-child(3) { animation-delay: 940ms; }
html.motion .hero-device .p-card:nth-child(4) { animation-delay: 1060ms; }
html.pin .piece { animation: land 1100ms var(--ease) var(--d) backwards; }
html.pin.mid .piece { animation: none; }
@keyframes rise { from { opacity: 0; transform: translateY(18px); } }
@keyframes lift { from { opacity: 0; transform: translateY(60px) scale(var(--s)); } to { transform: scale(var(--s)); } }
@keyframes land { from { opacity: 0; transform: translateY(-24px) rotate(calc(var(--r) * 2.5)); } }
html.motion .problem .mem .w { display: inline-block; will-change: transform; }
@media (min-width: 861px) {
}

/* ---------- Tablet ---------- */
@media (max-width: 1100px) {
  :root { --gutter: 40px; }
  .support-grid { grid-template-columns: minmax(0, 300px) minmax(0, 1fr); column-gap: 64px; }
  .hero-device { --hs: 0.92; }
  .stage { grid-template-columns: minmax(0, 440px) minmax(0, 1fr); column-gap: 48px; }
  .demo h2 { font-size: 40px; }
  .ledger li { grid-template-columns: 9.5em minmax(0, 1fr); font-size: 14px; }
  .privacy-inner, .closing { gap: 56px; }
}

/* ---------- Phones and narrow tablets ---------- */
@media (max-width: 860px) {
  :root { --gutter: 20px; }
  .site-header { padding: 20px var(--gutter); }
  .nav { gap: 20px; }
  .home .nav a:nth-child(2) { display: none; }
  .hero-copy { padding-bottom: 36px; }

  .hero { grid-template-columns: 1fr; min-height: 0; }
  .hero::after { display: none; }
  .hero-copy { padding: 104px 0 40px; }
  .hero h1 { font-size: clamp(44px, 12vw, 64px); margin-bottom: 20px; }
  .lede { font-size: 17px; margin-bottom: 26px; }
  .hero-device { --hs: 0.78; height: 440px; }
  .hero-device::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 200px; background: linear-gradient(rgba(249, 248, 244, 0), var(--cream) 85%); pointer-events: none; }

  .problem { padding: 72px var(--gutter) 96px; }
  .problem h2 { font-size: clamp(32px, 8.8vw, 40px); line-height: 1.06; margin-bottom: 24px; }
  .problem h2 > span + span { padding-left: 0; margin-top: 0.35em; }
  .problem-body { grid-template-columns: 1fr; row-gap: 28px; }
  .problem-lede { font-size: 17px; max-width: none; color: var(--ink-2); }
  .moments li { font-size: 21px; padding: 14px 0; }

  /* Story, static version (reduced motion or no script): each email with its result */
  .stage { display: block; padding: 90px var(--gutter); }
  .demo-device, .ledger, .pieces { display: none; }
  .demo h2 { font-size: 42px; }
  .demo-lede { font-size: 17px; margin-bottom: 32px; }
  .pairs { display: block; list-style: none; margin: 0; padding: 0; }
  .pairs li { margin-bottom: 34px; }
  .pair-src { transform: rotate(-1.2deg); }
  .pairs li:nth-child(even) .pair-src { transform: rotate(1.2deg); }
  .pair-out { margin: 10px 0 0 22px; position: relative; background: var(--surface); border-radius: 12px; padding: 13px 16px; box-shadow: var(--shadow); border-left: 2.5px solid var(--forest); }
  .pair-out em { display: block; font-style: normal; font-size: 12px; font-weight: 600; color: var(--forest); margin-bottom: 2px; }
  .pair-out b { font-weight: 500; font-size: 16px; }
  .pair-left p { margin: 0; color: var(--muted); font-size: 15px; line-height: 1.5; padding: 4px 0 0; }

  /* Story, pinned version: a two-line heading and one line of copy, then the phone anchoring the
     screen. Emails arrive two at a time below the plan's rows (story.js). The phone may run past the
     bottom edge, where it fades into the page. */
  html.pin .demo { height: 310vh; }
  html.pin .stage {
    display: grid; grid-template-columns: 1fr; grid-template-rows: auto auto 1fr; row-gap: 0;
    height: 100vh; height: 100svh; min-height: 0; padding: 32px var(--gutter) 0;
  }
  html.pin .stage::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 64px; background: linear-gradient(rgba(249, 248, 244, 0), var(--cream) 80%); z-index: 5; pointer-events: none; }
  html.pin .demo::after { content: ""; display: block; height: 56px; }
  html.pin .demo-copy { display: contents; }
  html.pin .demo h2 { font-size: clamp(28px, 8vw, 36px); line-height: 1.04; margin: 0 0 8px; max-width: none; }
  html.pin .demo-lede, html.pin .pairs { display: none; }
  html.pin .demo-lede-short { display: block; margin: 0 0 20px; font-size: 15px; color: var(--ink-2); }
  html.pin .demo-device { display: block; align-self: start; justify-self: center; }
  html.pin .pieces { display: block; }
  html.pin .piece { padding: 11px 13px 12px; animation: none; }
  html.pin .piece p { font-size: 12.5px; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 3; overflow: hidden; }
  html.pin .piece .src { font-size: 10.5px; }
  html.pin .piece .scan { display: flex; flex-wrap: wrap; align-items: baseline; gap: 1px 8px; margin-top: 6px; padding: 7px 10px 8px; }
  html.pin .piece .scan span { font-size: 9.5px; }
  html.pin .piece .scan b { font-size: 13px; }
  html.pin .piece .scan small { font-size: 11.5px; flex-basis: 100%; }

  .control { grid-template-columns: 1fr; gap: 28px; padding: 80px var(--gutter) 88px; }
  .control h2 { font-size: clamp(34px, 9.4vw, 42px); margin-bottom: 14px; }
  .control p { font-size: 17px; }
  .ex { max-width: none; }
  .privacy-inner { grid-template-columns: 1fr; gap: 40px; padding: 80px var(--gutter) 72px; }
  .privacy-lede { font-size: 17px; margin-top: 20px; }
  .privacy-foot { margin-top: 22px; font-size: 14px; }
  .node { padding: 18px 18px 20px; }
  .node b { font-size: 23px; }
  .node + .node { margin-top: 28px; }
  .node + .node::before { top: -29px; height: 28px; }
  .privacy h2 { font-size: clamp(38px, 10vw, 46px); }
  .privacy-lede { font-size: 17px; margin-bottom: 28px; }
  .closing { grid-template-columns: 1fr; gap: 32px; padding: 80px var(--gutter) 96px; }
  .closing h2 { font-size: clamp(36px, 9.6vw, 44px); margin-bottom: 16px; }
  .closing-lede { font-size: 17px; }
  .contacts li { flex-direction: column; align-items: flex-start; gap: 2px; padding: 14px 0; }
  .contacts a { font-size: 17px; }
  .support { padding: 24px var(--gutter) 96px; }
  .support h1 { font-size: 52px; margin-bottom: 14px; }
  .support-head { padding-bottom: 28px; margin-bottom: 32px; }
  .support-lede { font-size: 17px; }
  .support-grid { grid-template-columns: 1fr; row-gap: 48px; }
  .support-contact { position: static; padding-bottom: 40px; border-bottom: 1px solid var(--line); }
  .support-contact h2, .support-qa h2 { font-size: 27px; }
  .support-contact .btn { display: block; text-align: center; }
  .addresses { margin-top: 28px; }
  .support-qa section + section { margin-top: 44px; }
  .qa div { padding: 18px 0; }
  .qa dt { font-size: 17px; }
  .qa dd { font-size: 15.5px; }

  .doc { padding: 24px 20px 96px; }
  .doc h1 { font-size: 52px; margin-bottom: 14px; }
  .doc .meta { flex-direction: column; gap: 2px; padding-bottom: 20px; }
  .doc h2 { font-size: 26px; margin-top: 48px; }

  .site-footer .inner { gap: 20px 28px; padding: 36px var(--gutter) 24px; }
  .foot-links + .foot-links { margin-left: 0; }
  .foot-lockup { width: 100%; max-width: 102px; }
  .site-footer .legal { padding-bottom: 36px; }
}
@media (max-width: 599px) {
  html.pin .piece p { -webkit-line-clamp: 2; }
}
@media (min-width: 600px) and (max-width: 860px) {
  html.pin .demo h2 { font-size: 44px; }
  html.pin .demo-lede-short { font-size: 17px; }
  html.pin .piece { padding: 13px 15px 14px; }
  html.pin .piece p { font-size: 13.5px; }
  html.pin .piece .src { font-size: 11.5px; }
}
@media (max-width: 520px) {
  body { font-size: 16px; }
}
@media print {
  .site-header nav, .site-footer, .toc, .pieces { display: none; }
  body { background: #fff; }
}

