/* Copychest marketing site — single stylesheet, all pages.
   Every colour is a verbatim app token (Copychest Colour Tokens / App.css);
   shadows are the sole sanctioned exception, tuned in the palette's own tint.
   Spacing sits on the 8px scale: 8/16/24/32/48/64/96. The one deliberate
   off-grid value is the 860px hero figure cap — the capture's own native CSS
   width, so the app renders at true 1:1 (864 would resample every pixel). */

@font-face {
  font-family: "Bricolage Grotesque";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url(/fonts/bricolage-grotesque-latin-600-normal.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA,
    U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191,
    U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  color-scheme: light;

  /* Surfaces — verbatim from App.css (light) */
  --bg: #faf7f1;
  --band: #fffefb; /* app --sidebar-bg; renamed: no sidebar here */
  --border: #e8e1d2;
  --text: #2a2620;
  --text-muted: #6e6455;
  --text-faint: #746c5e;
  --accent: #b45309;
  --accent-hover: #9a4507;
  --accent-strong: #9a4507;
  --on-accent: #ffffff;
  --brand-fg-dim: #ddaf6e;
  --favorite-color: #d97706; /* App.css:49 */

  /* Card/demo tokens — verbatim from App.css (light) */
  --card-bg: #ffffff;
  --surface-hover: #f3eee3;
  --border-hover: #d9cfbb;
  --chip-bg: #f3eee3;
  --chip-text: #6e6455;
  --success-soft-bg: #e9efd6;
  --success-soft-text: #3f6d0d;

  /* Shadows — the sanctioned exception, light palette's own tint */
  --shadow: 0 1px 2px rgba(42, 38, 32, 0.05), 0 1px 3px rgba(42, 38, 32, 0.07);
  --shadow-hover: 0 4px 12px rgba(42, 38, 32, 0.12);
  --shadow-figure: 0 24px 48px rgba(42, 38, 32, 0.1),
    0 6px 16px rgba(42, 38, 32, 0.07);

  /* Radii — app tokens */
  --r-control: 7px;
  --r-surface: 10px;
  --r-figure: 14px;

  --font-brand: "Bricolage Grotesque", -apple-system, "Segoe UI", Roboto,
    Helvetica, Arial, sans-serif;
  --font-body: -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #161513;
  --band: #1b1a17;
  --border: #2d2a25;
  --text: #ece9e3;
  --text-muted: #a39d92;
  --text-faint: #8b8579;
  --accent: #e2a44e;
  --accent-hover: #ecb463;
  --accent-strong: #e2a44e;
  --on-accent: #161513; /* app's --on-accent = var(--bg) in dark */
  --brand-fg-dim: #8f6a2c;
  --favorite-color: #fbbf24; /* App.css:110 */

  --card-bg: #201e1b;
  --surface-hover: #2a2723;
  --border-hover: #3c3831;
  --chip-bg: #2a2723;
  --chip-text: #a39d92;
  --success-soft-bg: #343a28; /* app's own opaque flatten, deliberately not the rgba version */
  --success-soft-text: #9ece6a;

  --shadow: 0 1px 2px rgba(0, 0, 0, 0.3), 0 1px 3px rgba(0, 0, 0, 0.35);
  --shadow-hover: 0 4px 14px rgba(0, 0, 0, 0.5);
  --shadow-figure: 0 24px 48px rgba(0, 0, 0, 0.5),
    0 6px 16px rgba(0, 0, 0, 0.35);
}

/* ---------- Base ---------- */

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  background: var(--bg);
  color: var(--text-muted);
  font: 400 16px/26px var(--font-body);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1,
h2,
h3 {
  font-family: var(--font-brand);
  font-weight: 600;
  color: var(--text);
}

strong {
  font-weight: 600;
  color: var(--text);
}

img {
  max-width: 100%;
  height: auto;
}

.container {
  width: 100%;
  max-width: 1120px;
  margin-inline: auto;
  padding-inline: 24px;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

section {
  padding-block: 64px;
}

/* Band surfaces — separation by surface shift, never by rule */
.band {
  background: var(--band);
}

/* ---------- Header ---------- */

:root {
  --bar-h: 56px;
}

@media (min-width: 600px) {
  :root {
    --bar-h: 64px;
  }
}

html {
  scroll-padding-top: calc(var(--bar-h) + 8px);
}

header {
  position: sticky;
  top: 0;
  z-index: 10;
  height: var(--bar-h);
  background: var(--band);
  border-bottom: 1px solid var(--border);
}

header .container {
  height: 100%;
  display: flex;
  align-items: center;
  gap: 16px;
}

@media (max-height: 480px) {
  header {
    position: static;
  }
}

.lockup {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-right: auto;
  text-decoration: none;
}

.lockup svg {
  width: 28px;
  height: 28px;
  display: block;
}

.lockup .wordmark {
  font: 600 22px/1 var(--font-brand);
  letter-spacing: -0.01em;
  color: var(--text);
  transition: color 0.12s ease;
}

.lockup:hover .wordmark {
  color: var(--accent);
}

.lockup:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 4px;
  border-radius: 4px;
}

@media (max-width: 599px) {
  .lockup {
    gap: 8px;
  }
  .lockup svg {
    width: 24px;
    height: 24px;
  }
  .lockup .wordmark {
    font-size: 19px;
  }
}

/* Theme switch: the app's own toggle-switch control (App.css .toggle-switch)
   scaled x1.29 to web body size. 44px track is off the 8-grid on purpose —
   it keeps the app switch's 34:19 proportion AND makes the thumb travel
   exactly its own width (20px). Track stays neutral in both states: "on"
   here means dark theme, and an accent track would put a second amber mass
   16px from the CTA. The brass lands on the lit flank icon instead, which is
   the app's own .icon-btn.active convention. */
.theme-switch {
  flex-shrink: 0; display: inline-flex; align-items: center; gap: 8px;
  height: 40px; padding: 0; border: 0; background: none;
  border-radius: var(--r-control); cursor: pointer;
}
.theme-switch:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.switch-track {
  position: relative; flex-shrink: 0; width: 44px; height: 24px;
  border-radius: 999px; background: var(--border); transition: background .15s ease;
}
.theme-switch:hover .switch-track { background: var(--border-hover); }
.switch-thumb {
  position: absolute; top: 2px; left: 2px; width: 20px; height: 20px;
  border-radius: 50%; background: var(--card-bg); box-shadow: var(--shadow);
  display: flex; align-items: center; justify-content: center;
  transition: transform .15s ease;
}
:root[data-theme="dark"] .switch-thumb { transform: translateX(20px); }
.switch-flank { flex-shrink: 0; width: 16px; height: 16px; color: var(--text-faint); transition: color .15s ease; }
:root:not([data-theme="dark"]) .switch-flank-sun,
:root[data-theme="dark"] .switch-flank-moon { color: var(--accent-strong); }
.theme-switch:hover .switch-flank { color: var(--text-muted); }
.theme-switch:hover .switch-flank-sun:where(:root:not([data-theme="dark"]) *),
.theme-switch:hover .switch-flank-moon:where(:root[data-theme="dark"] *) { color: var(--accent-strong); }
.switch-thumb-icon { display: none; width: 12px; height: 12px; color: var(--accent-strong); }
html:not(.js) .theme-switch { display: none; }
@media (max-width: 599px) {
  header .container { gap: 12px; }
  .switch-flank { display: none; }
  :root:not([data-theme="dark"]) .switch-thumb-sun,
  :root[data-theme="dark"] .switch-thumb-moon { display: block; }
}
@media (max-width: 359px) { .lockup .wordmark { display: none; } }

.bar-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 40px;
  padding: 0 20px;
  border-radius: var(--r-surface);
  background: var(--accent);
  color: var(--on-accent);
  font: 600 15px/1 var(--font-body);
  text-decoration: none;
  transition: background 0.12s ease, opacity 0.16s ease;
}

.bar-cta:hover {
  background: var(--accent-hover);
}

.bar-cta:active {
  transform: translateY(1px);
}

.bar-cta:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

@media (max-width: 599px) {
  .bar-cta {
    height: 36px;
    padding: 0 16px;
    font-size: 14px;
  }
}

/* index.html ships header.hide-cta; visibility (not display) keeps the slot
   reserved so the toggle never shifts when the CTA fades in. */
header.hide-cta .bar-cta {
  opacity: 0;
  visibility: hidden;
}

html:not(.js) .bar-cta {
  opacity: 1;
  visibility: visible;
}

/* ---------- Hero ---------- */

.hero {
  padding-block: 40px 64px;
  text-align: center;
}

.hero-copy {
  max-width: 680px;
  margin-inline: auto;
}

.hero h1 {
  font-size: 36px;
  line-height: 40px;
  letter-spacing: -0.02em;
  text-wrap: balance;
  margin-inline: auto;
}

.hero .subhead {
  font-size: 18px;
  line-height: 28px;
  max-width: 600px;
  margin: 24px auto 0;
}

.hero .cta-row {
  margin-top: 32px;
}

.cta-subline {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0 8px;
  margin-top: 16px;
  font-size: 14px;
  line-height: 20px;
}

.cta-subline span {
  white-space: nowrap;
}

.hero .shot {
  margin-top: 48px;
}

/* ---------- Product figures ---------- */

.shot {
  max-width: 860px;
  margin-inline: auto;
}

.shot img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 860 / 645;
  border-radius: var(--r-figure);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-figure);
  background: var(--bg);
}

@media (max-width: 599px) {
  .shot {
    max-width: 480px;
  }
  .shot img {
    aspect-ratio: 480 / 460;
  }
}

/* Panel figure (features band lead, and its own standalone use) */
.panel-shot {
  display: none;
  max-width: 400px;
  margin-inline: auto;
}

.panel-shot img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 480 / 460;
  border-radius: var(--r-figure);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-figure);
  background: var(--bg);
}

/* Before JS sets a src, there's nothing to show — avoids a broken-image icon. */
.shot img:not([src]),
.panel-shot img:not([src]) {
  display: none;
}

.prose {
  max-width: 680px;
  margin-inline: auto;
  text-align: left;
}

.lead-in {
  display: block;
  font-family: var(--font-brand);
  font-weight: 600;
  font-size: 22px;
  line-height: 30px;
  letter-spacing: -0.01em;
  color: var(--text);
}

/* ---------- Problem band ---------- */
/* One left axis for the whole band — prose, heading, promise and the demo all
   sit on the 680px column (the same rule the pricing CTA follows). The band
   escalates rather than stacks: muted body prose (the pain) -> the turn at
   section rank -> the promise as emphasised body -> the demo, which is that
   promise happening. Gaps encode it: 40px before the turn, 32px before the
   proof, so the demo reads as belonging to the sentence above it. */

.problem .prose > p {
  font-size: 18px;
  line-height: 28px;
}

.problem .prose > p + p { margin-top: 16px; }

/* Section rank, identical to .faq h2 — the page's one heading step below h1. */
.problem h2 {
  font-size: 24px;
  line-height: 30px;
  letter-spacing: -0.015em;
  margin-top: 32px;
}

/* The claim the demo proves. Emphasised BODY, not a second heading: system
   600 at body-prose size in --text. A 24px Bricolage slab here fought the h2
   12px above it, which is what made the band read as two headings and a
   widget rather than a turn and its proof. */
.problem .promise {
  font-size: 18px;
  line-height: 28px;
  font-weight: 600;
  color: var(--text);
  margin-top: 12px;
}

@media (min-width: 600px) {
  .problem .prose > p { font-size: 20px; line-height: 32px; }
  .problem h2 { font-size: 28px; line-height: 34px; margin-top: 40px; }
  .problem .promise { font-size: 20px; line-height: 32px; }
}

/* ---------- Interactive demo ---------- */
/* A RECESS, not a third bordered panel: --bg inside a --band section, with
   --card-bg rows sitting on it. That is the app's own surface stack
   (.component-card on the list's --bg, App.css) and it keeps the page to two
   box treatments — elevated panels (.features-facts, .faq-item) and this one
   well. A border here would have made five nested outlines, since the rows
   and the textarea already carry their own. */
.demo {
  margin-top: 32px;
  padding: 16px;
  background: var(--bg);
  border-radius: var(--r-figure);
}

@media (min-width: 600px) { .demo { padding: 24px; } }

html:not(.js) .demo { display: none; }

/* Scoped to .demo (0,2,0) on purpose. As a bare .demo-label (0,1,0) this lost
   to .problem p (0,1,1) and the "small muted label" shipped at 20/32 — the
   third time this exact cascade trap has bitten this file. */
.demo .demo-label {
  margin: 0 0 16px;
  font-size: 14px;
  line-height: 20px;
  color: var(--text-faint);
}

.demo-rows {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.demo-row {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  min-height: 48px;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: var(--r-control);
  background: var(--card-bg);
  box-shadow: var(--shadow);
  font: inherit;
  text-align: left;
  cursor: pointer;
  transition: background 0.12s ease, border-color 0.12s ease;
}

.demo-row:hover {
  background: var(--surface-hover);
  border-color: var(--border-hover);
  box-shadow: var(--shadow-hover);
}

.demo-row:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 1px;
}

.demo-row:active {
  transform: translateY(1px);
}

.demo-row.is-copied {
  border-color: var(--accent);
}

.demo-row-label {
  flex: 1;
  min-width: 0;
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Explicit line-height on both chips: without it they inherit the page
   body's 28px line box and a 12px pill renders 34px tall. Same fidelity bug
   the panel's chips had. Keep the pair identical so the swap on copy never
   changes the row's height. */
.demo-row-tag {
  flex-shrink: 0;
  font-size: 12px;
  line-height: 16px;
  font-weight: 600;
  padding: 3px 9px;
  border-radius: 999px;
  background: var(--chip-bg);
  color: var(--chip-text);
}

.demo-row-copied {
  flex-shrink: 0;
  font-size: 12px;
  line-height: 16px;
  font-weight: 700;
  padding: 3px 9px;
  border-radius: 999px;
  background: var(--success-soft-bg);
  color: var(--success-soft-text);
}

.demo-row-copied.demo-row-fallback {
  background: var(--chip-bg);
  color: var(--text);
}

.demo-paste {
  display: block;
  width: 100%;
  margin-top: 16px;
  min-height: 88px;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: var(--r-control);
  background: var(--card-bg);
  color: var(--text);
  font: 400 15px/24px var(--font-body);
  resize: vertical;
}

/* Pick on the left, it lands on the right: the copy->paste mapping made
   spatial. Two-up only from 700px; below that the rows run full width and the
   paste box stacks under them (in a half-width row "Directions to the office"
   ellipsises at 674px and under, which is what put the breakpoint here).
   minmax(0,1fr), never fixed tracks (see the features-grid note).
   This block MUST stay below the base .demo-paste rule: both selectors are
   (0,1,0), so source order alone decides, and when this sat higher up the
   base 88px silently beat the 160px floor at every width over 700. */
@media (min-width: 700px) {
  .demo-body {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    column-gap: 32px;
    align-items: stretch;
  }
  .demo-paste {
    margin-top: 0;
    height: 100%;
    min-height: 160px;
  }
}

.demo-paste::placeholder {
  color: var(--text-faint);
}

.demo-paste:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 1px;
  border-color: var(--accent);
}

/* ---------- Features band ---------- */

.feature-lead {
  display: grid;
  grid-template-columns: 1fr;
  row-gap: 32px;
  margin-bottom: 48px;
}

.feature-lead-copy {
  max-width: 680px;
  margin-inline: auto;   /* no-op at >=1140 (track is 480); caps the measure when stacked */
}

@media (min-width: 600px) {
  .feature-lead {
    margin-bottom: 64px;
  }
}

@media (min-width: 1140px) {
  .feature-lead {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    column-gap: 96px;
    align-items: center;
    margin-bottom: 96px;
  }
  .feature-lead-copy { margin-inline: 0; }
}

.features-grid {
  display: grid;
  grid-template-columns: 1fr;
  row-gap: 48px;
}

/* Feature icons take the accent rule's slot — same position, same accent,
   near-identical ink mass, so the band gains meaning without gaining density.
   lucide 0.469.0 paths verbatim (the version the app ships); two of the five
   are the app's own glyphs for those features. No icon library on the site. */
.feature-icon { display: block; width: 24px; height: 24px; color: var(--accent); margin-bottom: 16px; }

.feature h3,
.feature-lead-copy h3 {
  font-size: 20px;
  line-height: 28px;
  letter-spacing: -0.01em;
  margin-bottom: 12px;
}

/* No width cap on block bodies: one measure per column (the old 460px cap
   left headings running wider than their own body text). */

.features-facts {
  margin-top: 64px;
  padding: 24px;
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: var(--r-figure);
}

@media (min-width: 600px) {
  .features-facts {
    padding: 32px;
  }
}

@media (min-width: 900px) {
  .features-facts {
    margin-top: 96px;
    padding: 40px;
  }
}

.features-facts h3 {
  font-size: 20px;
  line-height: 28px;
  letter-spacing: -0.01em;
  margin-bottom: 24px;
}

.features-facts ul {
  list-style: disc;
  padding-left: 24px;
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

.features-facts li {
  font-size: 16px;
  line-height: 26px;
  color: var(--text-muted);
}

.features-facts li::marker {
  color: var(--accent);
}

@media (min-width: 900px) {
  .features-facts ul {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    column-gap: 64px;
    row-gap: 16px;
  }
}

/* ---------- Quick Panel animation ---------- */
/* Loops a synthetic Quick Panel over a synthetic email: blank doc -> panel
   appears -> cursor clicks a saved reply -> text lands -> loop. The play/
   pause/replay state machine lives in site.js (qp* variables); the CSS here
   only owns geometry, appearance and the keyframes it drives. The existing
   <figure class="panel-shot"> stays in the DOM as the reduced-motion/no-JS
   fallback — see the visibility rules at the end of this section. */

.qp-anim { display: none; }                 /* turned on below */
.qp-stage {
  position: relative;
  width: 480px; height: 380px;
  max-width: 100%;
  overflow: hidden;
  margin-inline: auto;
  contain: layout paint;
  pointer-events: none;                     /* nothing here is clickable */
  cursor: default;
}

.qp-doc {
  position: absolute; inset: 0;
  padding: 24px;
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: var(--r-figure);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.qp-doc-field {
  display: flex; align-items: center; gap: 12px;
  height: 30px;
  border-bottom: 1px solid var(--border);
}
.qp-doc-label { flex: 0 0 52px; font-size: 12px; line-height: 16px; color: var(--text-faint); }
.qp-doc-value { font-size: 13px; line-height: 16px; color: var(--text); white-space: nowrap; }

.qp-doc-body { margin-top: 20px; }
.qp-doc-body p, .qp-doc-sign p, .qp-drop-body {
  font: 400 14px/24px var(--font-body);
  color: var(--text);
  margin: 0;
}
.qp-doc-drop { position: relative; margin-top: 12px; min-height: 48px; }
.qp-drop-body { max-width: 300px; }         /* pins the paste to exactly 2 lines at any font metric */
.qp-doc-sign { margin-top: 12px; }

/* Panel — every value lifted from App.css (.compact-panel and friends).
   line-height is set HERE and not left to inherit: the page body runs
   17px/28px, and an 11px chip inheriting a 28px line box renders 32px tall
   inside a 36px row, i.e. a pill that swallows its own row. The app's chips
   sit in a much tighter line box, so inheriting the marketing-page value was
   a fidelity bug, not a style choice. 16px suits everything in here (11-13px
   text); anything needing different says so explicitly. */
.qp-panel {
  position: absolute; left: 168px; top: 108px;
  width: 296px; height: 248px;
  box-sizing: border-box;
  line-height: 16px;
  background: var(--bg);                     /* .compact-panel, App.css:3709 */
  border: 1px solid var(--border);
  border-radius: 8px;
  box-shadow: var(--shadow-figure);
  overflow: hidden;
  will-change: transform, opacity;
}

.qp-panel-head { padding: 10px; border-bottom: 1px solid var(--border); }
.qp-field {
  display: flex; align-items: center; gap: 6px;
  height: 35px; padding: 5px 8px; box-sizing: border-box;
  border: 1px solid var(--accent);           /* focused on open — matches the shipped shot */
  border-radius: var(--r-control);
  background: var(--card-bg);
}
.qp-field-icon { flex-shrink: 0; color: var(--text-muted); }
.qp-field-ph   { font-size: 13px; color: var(--text-faint); }

.qp-tabs {
  display: flex; gap: 2px; margin: 8px 10px; padding: 2px;
  background: var(--bg); border: 1px solid var(--border);
  border-radius: var(--r-control);
}
.qp-tab {
  flex: 1; display: inline-flex; align-items: center; justify-content: center; gap: 5px;
  padding: 8px 6px; border-radius: var(--r-control);
  font-size: 12px; line-height: 16px; color: var(--text-muted);
}
.qp-tab.is-active {
  background: var(--card-bg); color: var(--accent);
  font-weight: 600; box-shadow: var(--shadow);
}
.qp-count {
  font-size: 11px; font-weight: 700; line-height: 1;
  padding: 1px 7px; border-radius: 999px;
  background: var(--chip-bg); color: var(--chip-text);
}

.qp-list { padding: 8px; display: flex; flex-direction: column; gap: 6px; }
.qp-row {
  display: flex; align-items: center; gap: 8px;
  height: 36px; padding: 0 10px; box-sizing: border-box;
  border: 1px solid var(--border); border-radius: var(--r-control);
  background: var(--card-bg);
}
.qp-star { flex-shrink: 0; display: flex; color: var(--text-muted); }
.qp-star.is-fav { color: var(--favorite-color); }
.qp-row-label {
  flex: 1; min-width: 0; font-size: 13px; font-weight: 600; color: var(--text);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.qp-row-tag {
  flex-shrink: 0; font-size: 11px; padding: 2px 7px; border-radius: 999px;
  background: var(--chip-bg); color: var(--chip-text);
}

/* Carets. The nested <i> is required: the blink owns the inner element's
   opacity while the cycle animation owns the outer's, so they multiply
   instead of fighting over the same property. */
.qp-caret { display: inline-block; width: 1px; height: 18px; vertical-align: -3px; }
.qp-caret > i { display: block; width: 1px; height: 18px; background: var(--text);
                animation: qp-blink 1.06s steps(1, end) infinite; }
.qp-caret-lead  { position: absolute; left: 0; top: 3px; }
.qp-caret-trail { margin-left: 2px; }
@keyframes qp-blink { 0%, 49% { opacity: 1 } 50%, 100% { opacity: 0 } }

/* Cursor: outer translates, inner fades + dips. True 20px scale, tip at the
   element origin so the transform coordinate IS the hotspot. */
.qp-cursor {
  position: absolute; left: 0; top: 0;
  transform: translate(72px, 196px);
  will-change: transform;
  z-index: 3;
}
.qp-cursor-inner {
  display: block;
  opacity: 0;
  filter: drop-shadow(0 1px 1.5px rgba(0,0,0,.35));
}

.qp-ctl {
  display: flex; align-items: center; gap: 6px;
  margin: 8px 0 0 auto;
  padding: 4px 2px;
  border: 0; background: none; cursor: pointer;
  font: 400 12px/16px var(--font-body); color: var(--text-faint);
  transition: color .12s ease;
}
.qp-ctl:hover { color: var(--text-muted); }
.qp-ctl:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 4px; }
.qp-ctl-icon { flex-shrink: 0; }

/* Motion: every animated element shares one 5300ms duration so they can
   never drift apart over repeated cycles. Percentages below are exact
   ms/5300 fractions of the design's master timeline. */
.qp-a {
  animation-duration: 5300ms;
  animation-iteration-count: 3;
  animation-fill-mode: both;
  animation-timing-function: linear;   /* real easing is declared inside each keyframe */
  animation-play-state: paused;
}
.qp-anim.is-running .qp-a { animation-play-state: running; }

/* animation-name applied ONLY under .is-armed — removing the class cancels
   the animations outright, which is what makes a clean restart possible. */
.qp-anim.is-armed .qp-panel        { animation-name: qp-panel; }
.qp-anim.is-armed .qp-cursor       { animation-name: qp-cursor-move; }
.qp-anim.is-armed .qp-cursor-inner { animation-name: qp-cursor-fade; }
.qp-anim.is-armed .qp-row.is-target { animation-name: qp-row; }
.qp-anim.is-armed .qp-drop-body    { animation-name: qp-drop; }
.qp-anim.is-armed .qp-caret-lead   { animation-name: qp-lead-caret; }

@keyframes qp-panel {
  0%      { opacity: 0; transform: scale(.96); animation-timing-function: linear; }
  11.32%  { opacity: 0; transform: scale(.96); animation-timing-function: cubic-bezier(.16,1,.3,1); }
  16.23%  { opacity: 1; transform: scale(1);   animation-timing-function: linear; }
  38.68%  { opacity: 1; transform: scale(1);   animation-timing-function: cubic-bezier(.4,0,1,1); }
  42.08%  { opacity: 0; transform: scale(.97); animation-timing-function: linear; }
  100%    { opacity: 0; transform: scale(.97); }
}

@keyframes qp-cursor-move {
  0%      { transform: translate(72px,196px); animation-timing-function: linear; }
  20.38%  { transform: translate(72px,196px); animation-timing-function: cubic-bezier(.22,1,.36,1); }
  30.19%  { transform: translate(252px,328px); animation-timing-function: linear; }
  100%    { transform: translate(252px,328px); }
}

@keyframes qp-cursor-fade {
  0%      { opacity: 0; transform: translateY(0); animation-timing-function: linear; }
  20.38%  { opacity: 0; transform: translateY(0); animation-timing-function: ease-out; }
  22.64%  { opacity: 1; transform: translateY(0); animation-timing-function: linear; }
  33.58%  { opacity: 1; transform: translateY(0); animation-timing-function: ease-out; }
  35.28%  { opacity: 1; transform: translateY(1px); animation-timing-function: linear; }
  37.55%  { opacity: 1; transform: translateY(0); animation-timing-function: linear; }
  38.68%  { opacity: 1; transform: translateY(0); animation-timing-function: ease-in; }
  42.08%  { opacity: 0; transform: translateY(0); animation-timing-function: linear; }
  100%    { opacity: 0; transform: translateY(0); }
}

@keyframes qp-row {
  0%      { background: var(--card-bg); border-color: var(--border); transform: translateY(0); animation-timing-function: linear; }
  30.19%  { background: var(--card-bg); border-color: var(--border); transform: translateY(0); animation-timing-function: ease-out; }
  31.51%  { background: var(--surface-hover); border-color: var(--border-hover); transform: translateY(0); animation-timing-function: linear; }
  33.58%  { background: var(--surface-hover); border-color: var(--border-hover); transform: translateY(0); animation-timing-function: ease-out; }
  35.28%  { background: var(--surface-hover); border-color: var(--accent); transform: translateY(1px); animation-timing-function: linear; }
  37.55%  { background: var(--surface-hover); border-color: var(--accent); transform: translateY(0); animation-timing-function: linear; }
  100%    { background: var(--surface-hover); border-color: var(--accent); transform: translateY(0); }
}

@keyframes qp-drop {
  0%      { opacity: 0; transform: translateY(4px); animation-timing-function: linear; }
  39.43%  { opacity: 0; transform: translateY(4px); animation-timing-function: cubic-bezier(.16,1,.3,1); }
  44.72%  { opacity: 1; transform: translateY(0);   animation-timing-function: linear; }
  86.23%  { opacity: 1; transform: translateY(0);   animation-timing-function: ease-out; }
  92.26%  { opacity: 0; transform: translateY(4px); animation-timing-function: linear; }
  100%    { opacity: 0; transform: translateY(4px); }
}

@keyframes qp-lead-caret {
  0%      { opacity: 1; }
  39.43%  { opacity: 1; animation-timing-function: linear; }
  41.51%  { opacity: 0; }
  86.23%  { opacity: 0; animation-timing-function: linear; }
  92.26%  { opacity: 1; }
  100%    { opacity: 1; }
}

/* Poster frame (animations are cancelled by removing .is-armed, so these
   plain rules win): panel open over the document, drop zone empty, no
   cursor, lead caret solid. */
.qp-anim.is-finished .qp-panel        { opacity: 1; transform: none; }
.qp-anim.is-finished .qp-cursor-inner { opacity: 0; }
.qp-anim.is-finished .qp-drop-body    { opacity: 0; }
.qp-anim.is-finished .qp-caret-lead   { opacity: 1; }
.qp-anim.is-finished .qp-caret-lead > i { animation: none; opacity: 1; }
.qp-anim.is-finished .qp-row.is-target { background: var(--card-bg); border-color: var(--border); }

/* Visibility */
@media (min-width: 600px) {
  .qp-anim { display: block; }
}
html:not(.js) .qp-anim { display: none; }
html:not(.js) .panel-shot { display: block; }

/* BUILD-BREAKER IF MISSED: the site's global reduced-motion rule (see
   ---------- Preferences ---------- below) forces animation-duration:
   0.01ms !important on *, so without this display:none a reduced-motion
   visitor would get three instantaneous cycles and a garbage final frame
   instead of the static fallback. */
@media (prefers-reduced-motion: reduce) {
  .qp-anim { display: none !important; }
  .panel-shot { display: none; }
}
@media (prefers-reduced-motion: reduce) and (min-width: 600px) {
  .panel-shot { display: block; }
}

/* ---------- Buttons & links ---------- */

.btn-cta {
  display: flex;
  width: 100%;
  max-width: 360px;
  margin-inline: auto;
  align-items: center;
  justify-content: center;
  height: 56px;
  padding: 0 32px;
  border-radius: var(--r-surface);
  font: 600 17px/1 var(--font-body);
  text-decoration: none;
  background: var(--accent);
  color: var(--on-accent);
  border: 1px solid transparent;
  box-shadow: var(--shadow);
  transition: background 0.12s ease, box-shadow 0.12s ease;
}

.btn-cta:hover {
  background: var(--accent-hover);
  box-shadow: var(--shadow-hover);
}

.btn-cta:active {
  background: var(--accent-hover);
  box-shadow: var(--shadow);
  transform: translateY(1px);
}

.btn-cta:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

/* :not(.btn-cta) matters: the pricing CTA lives inside .prose, and without
   the guard this rule outranks .btn-cta's own color — amber label on amber
   fill, an invisible button (shipped exactly that way on 2026-07-27). */
.prose a:not(.btn-cta),
.faq-item a,
.legal a {
  color: var(--accent);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 2px;
}

.prose a:not(.btn-cta):hover,
.faq-item a:hover,
.legal a:hover {
  color: var(--accent-hover);
  text-decoration-thickness: 2px;
}

.prose a:not(.btn-cta):focus-visible,
.faq-item a:focus-visible,
.legal a:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: 2px;
}

/* ---------- Pricing band ---------- */

.pricing .tier + .tier {
  margin-top: 32px;
}

.pricing .lead-in {
  margin-bottom: 8px;
}

.pricing .licence-line {
  margin-top: 24px;
  font-size: 14px;
  line-height: 20px;
}

/* Left-aligned with the prose above it is DELIBERATE (it sits on the
   paragraph's own axis); do not centre it. */
.pricing .btn-cta {
  margin-top: 48px;
}

/* ---------- FAQ band ---------- */

.faq h2 {
  font-size: 24px;
  line-height: 30px;
  letter-spacing: -0.015em;
  margin-bottom: 32px;
}

@media (min-width: 600px) {
  .faq h2 {
    font-size: 28px;
    line-height: 34px;
  }
}

@media (min-width: 900px) {
  .faq h2 {
    margin-bottom: 40px;
  }
}

/* Balanced column flow, not a grid: cards hug their content, so the dead
   space a long answer used to force on its row-mate is gone. */
.faq-grid {
  columns: 1;
}

.faq-item {
  break-inside: avoid;
  margin: 0 0 16px;
  padding: 20px;
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: var(--r-surface);
}

.faq-item h3 {
  font-size: 18px;
  line-height: 26px;
  letter-spacing: -0.01em;
  margin-bottom: 8px;
}

.faq-item p {
  font-size: 16px;
  line-height: 26px;
}

@media (min-width: 900px) {
  .faq-grid {
    columns: 2;
    column-gap: 32px;
  }
  .faq-item {
    margin-bottom: 24px;
    padding: 24px;
  }
}


/* ---------- Footer ---------- */

footer {
  background: var(--band);
  padding-block: 48px;
}

.footer-inner {
  display: flex;
  flex-direction: column-reverse;
  align-items: flex-start;
}

.footer-copyright {
  font-size: 14px;
  line-height: 20px;
  color: var(--text-faint);
  margin-top: 24px;
}

footer nav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 24px;
}

footer nav a {
  font-size: 14px;
  line-height: 20px;
  padding-block: 12px;
  color: var(--text-muted);
  text-decoration: none;
}

footer nav a:hover {
  color: var(--text);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 2px;
}

footer nav a:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: 2px;
}

/* ---------- Legal pages ---------- */

.legal {
  max-width: 680px;
  margin-inline: auto;
  padding-block: 48px 64px;
}

.legal h1 {
  font-size: 28px;
  line-height: 34px;
  letter-spacing: -0.015em;
}

.legal .updated {
  margin-top: 8px;
  font-size: 14px;
  line-height: 20px;
  color: var(--text-faint);
}

.legal .legal-body {
  margin-top: 48px;
}

.legal h2 {
  font-size: 20px;
  line-height: 28px;
  letter-spacing: -0.01em;
  margin-top: 48px;
  margin-bottom: 16px;
}

.legal h2:first-child {
  margin-top: 0;
}

.legal p {
  margin-bottom: 16px;
}

.legal ul {
  padding-left: 24px;
  margin-bottom: 16px;
}

.legal li {
  margin-bottom: 12px;
}

.legal li::marker {
  color: var(--accent);
}

/* ---------- Breakpoints ---------- */

@media (min-width: 600px) {
  .container {
    padding-inline: 32px;
  }
  body {
    font-size: 17px;
    line-height: 28px;
  }
  .hero h1 {
    font-size: 44px;
    line-height: 48px;
  }
  .hero .subhead {
    font-size: 20px;
    line-height: 32px;
  }
  .hero .cta-row {
    margin-top: 40px;
  }
  .lead-in {
    font-size: 24px;
    line-height: 32px;
  }
  .btn-cta {
    display: inline-flex;
    width: auto;
    max-width: none;
  }
  .footer-inner {
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
  }
  .footer-copyright {
    margin-top: 0;
  }
}

@media (min-width: 900px) {
  section {
    padding-block: 96px;
  }
  .hero {
    padding-block: 64px 96px;
  }
  .hero h1 {
    font-size: 56px;
    line-height: 60px;
    max-width: 16ch;
  }
  .hero .shot {
    margin-top: 64px;
  }
  /* Fluid tracks, never fixed: 512px 512px + 96px gap = 1120px of track
     inside a 1056px content box, which shipped a real horizontal scrollbar
     on every 900-1250px viewport (design-critique F1, 2026-07-27). */
  .features-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    column-gap: 96px;
    row-gap: 64px;
  }
  .legal {
    padding-block: 64px 96px;
  }
  .legal h1 {
    font-size: 32px;
    line-height: 40px;
  }
}

/* ---------- Preferences ---------- */

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

@media print {
  header,
  footer nav {
    display: none;
  }
  body {
    background: #fff;
    color: #000;
  }
  a[href^="http"]::after {
    content: " (" attr(href) ")";
  }
}
