/* stingkit: "title sequence" art direction. Warm film-black (dark) or paper (light), one signal colour (a tally-light
   red-orange), Instrument Serif for titles, Inter for reading, JetBrains Mono for the machine voice (timecodes, specs).
   Scale 1.25 from 16px, 4/8px spacing grid, 2 radii. */
@font-face { font-family: "Instrument Serif"; font-weight: 400; font-display: swap; src: url(/fonts/instrument-serif-latin-400-normal.woff2) format("woff2"); }
@font-face { font-family: "Instrument Serif"; font-weight: 400; font-style: italic; font-display: swap; src: url(/fonts/instrument-serif-latin-400-italic.woff2) format("woff2"); }
@font-face { font-family: "Inter"; font-weight: 400; font-display: swap; src: url(/fonts/inter-latin-400-normal.woff2) format("woff2"); }
@font-face { font-family: "Inter"; font-weight: 500; font-display: swap; src: url(/fonts/inter-latin-500-normal.woff2) format("woff2"); }
@font-face { font-family: "Inter"; font-weight: 600; font-display: swap; src: url(/fonts/inter-latin-600-normal.woff2) format("woff2"); }
@font-face { font-family: "JetBrains Mono"; font-weight: 500; font-display: swap; src: url(/fonts/jetbrains-mono-latin-500-normal.woff2) format("woff2"); }

:root {
  color-scheme: dark light;
  --bg: #0f0e0c; --bg-2: #151411; --surface: #1b1a16; --line: #2b2924; --line-2: #3a3731;
  --fg: #eeeae1; --dim: #aaa396; --dim-2: #8f897d;
  --brand: #ff5a2a; --brand-ink: #120f0c; --brand-soft: rgba(255, 90, 42, .12); --ok: #9fd4a3; --bad: #ff8a73;
  --stage: #0a0908;   /* behind video frames, in both themes */
  --serif: "Instrument Serif", "Iowan Old Style", Georgia, serif;
  --sans: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;
  --t-2: .64rem; --t-1: .8rem; --t0: 1rem; --t1: 1.25rem; --t2: 1.5625rem; --t3: 1.953rem; --t4: 2.441rem; --t5: 3.052rem; --t6: 3.815rem; --t7: 4.768rem;
  --s1: 4px; --s2: 8px; --s3: 12px; --s4: 16px; --s5: 24px; --s6: 32px; --s7: 48px; --s8: 64px; --s9: 96px; --s10: 128px;
  --r: 6px; --r-s: 3px;
  --ease: cubic-bezier(.2, .7, .2, 1); --fast: 160ms; --mid: 220ms;
  --wrap: 1200px; --bar: 60px;
}
@media (prefers-color-scheme: light) {
  :root {
    --bg: #f4f1ea; --bg-2: #ece8df; --surface: #fbfaf6; --line: #dcd6ca; --line-2: #c4bdae;
    --fg: #171512; --dim: #57524a; --dim-2: #6b655a;
    --brand: #b3380a; --brand-ink: #ffffff; --brand-soft: rgba(179, 56, 10, .09); --ok: #2f6b3a; --bad: #a3290b;
  }
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: calc(var(--bar) + var(--s4)); }
body { margin: 0; background: var(--bg); color: var(--fg); font: 400 var(--t0)/1.6 var(--sans); -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; }
a { color: inherit; text-decoration-line: underline; text-decoration-thickness: 1px; text-decoration-color: var(--line-2); text-underline-offset: .2em; transition: text-decoration-color var(--fast) var(--ease), color var(--fast) var(--ease); }
a:hover { text-decoration-color: var(--brand); }
:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; border-radius: var(--r-s); }
img, video, canvas { display: block; max-width: 100%; }
h1, h2, h3 { margin: 0; font-weight: 400; text-wrap: balance; }
h1, h2 { font-family: var(--serif); letter-spacing: -.01em; line-height: 1.02; }
h1 { font-size: clamp(2.6rem, 1.4rem + 3.6vw, 4.25rem); }
h2 { font-size: clamp(var(--t4), 1.6rem + 2vw, var(--t5)); }
h3 { font: 600 var(--t0)/1.35 var(--sans); letter-spacing: -.005em; }
p { margin: 0 0 var(--s4); text-wrap: pretty; }
em { font-style: italic; }
h1 em, h2 em { font-style: italic; }
code, .mono { font-family: var(--mono); font-size: .875em; }
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 var(--s5); }
.label { font: 500 var(--t-1)/1.4 var(--mono); letter-spacing: .06em; text-transform: uppercase; color: var(--dim-2); }
.lede { font-size: var(--t1); line-height: 1.5; color: var(--dim); max-width: 38em; }
.muted { color: var(--dim); } .small { font-size: var(--t-1); }
.skip { position: absolute; left: var(--s4); top: -100px; z-index: 100; background: var(--brand); color: var(--brand-ink); padding: var(--s2) var(--s4); border-radius: var(--r); }
.skip:focus { top: var(--s2); }
.vh { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* header / footer */
.top { position: sticky; top: 0; z-index: 20; background: var(--bg); border-bottom: 1px solid var(--line); }
.bar { display: flex; align-items: center; gap: var(--s6); height: var(--bar); }
.brand { display: inline-flex; align-items: center; gap: var(--s2); font: 400 1.6rem/1 var(--serif); letter-spacing: -.01em; text-decoration: none; }
.brand .dot { width: 9px; height: 9px; border-radius: 50%; background: var(--brand); transform: translateY(-.35em); }
.top nav { display: flex; gap: var(--s5); align-items: center; font-size: .9375rem; margin-left: auto; }
.top nav a { text-decoration: none; color: var(--dim); padding: var(--s3) 0; }
.top nav a:hover, .top nav a[aria-current] { color: var(--fg); }
.top nav a.btn { color: var(--brand-ink); padding: var(--s2) var(--s4); }
@media (max-width: 760px) { .top nav .hide-s { display: none; } .top nav { gap: var(--s4); } }
.foot { border-top: 1px solid var(--line); margin-top: var(--s10); padding: var(--s8) 0 var(--s7); color: var(--dim); font-size: .9375rem; }
.foot .cols { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: var(--s6); }
.foot h2 { font: 500 var(--t-1)/1.4 var(--mono); letter-spacing: .06em; text-transform: uppercase; color: var(--dim-2); margin-bottom: var(--s3); }
.foot ul { list-style: none; margin: 0; padding: 0; }
.foot li { padding: var(--s1) 0; }
.foot a { text-decoration: none; } .foot a:hover { color: var(--fg); }
.foot .fine { margin-top: var(--s7); padding-top: var(--s4); border-top: 1px solid var(--line); font: 500 var(--t-1)/1.6 var(--mono); color: var(--dim-2); display: flex; flex-wrap: wrap; gap: var(--s2) var(--s5); }
@media (max-width: 760px) { .foot .cols { grid-template-columns: 1fr 1fr; } .foot .cols > :first-child { grid-column: 1 / -1; } }

/* buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: var(--s2); min-height: 44px; padding: 0 var(--s5); border: 1px solid var(--line-2); border-radius: var(--r); background: transparent; color: var(--fg); font: 600 .9375rem/1 var(--sans); text-decoration: none; cursor: pointer; transition: background-color var(--fast) var(--ease), border-color var(--fast) var(--ease), color var(--fast) var(--ease); }
.btn:hover { border-color: var(--fg); }
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: .45; cursor: not-allowed; transform: none; }
.btn.primary { background: var(--brand); border-color: var(--brand); color: var(--brand-ink); }
.btn.primary:hover { background: color-mix(in srgb, var(--brand) 86%, var(--fg)); border-color: transparent; }
.btn.big { min-height: 52px; padding: 0 var(--s6); font-size: var(--t0); }
.btn.sm { min-height: 36px; padding: 0 var(--s3); font-size: .8125rem; }
.btn .arr { font-family: var(--mono); font-weight: 500; }
.linkbtn { background: none; border: 0; padding: 0; color: var(--dim); font: inherit; text-decoration: underline; text-underline-offset: .2em; cursor: pointer; }
.linkbtn:hover { color: var(--fg); }

/* ---------- landing ---------- */
.hero { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: var(--s8); align-items: start; padding: var(--s8) 0 var(--s7); }
.hero h1 { margin: var(--s4) 0 var(--s5); }
.hero .answer { font-size: 1.0625rem; color: var(--dim); max-width: 34em; }
.hero .answer strong { color: var(--fg); font-weight: 500; }
.cta { display: flex; gap: var(--s3); flex-wrap: wrap; align-items: center; margin: var(--s6) 0 var(--s4); }
.facts { list-style: none; margin: var(--s6) 0 0; padding: var(--s4) 0 0; border-top: 1px solid var(--line); display: grid; grid-template-columns: repeat(3, auto); justify-content: start; gap: var(--s2) var(--s6); font: 500 var(--t-1)/1.5 var(--mono); color: var(--dim-2); }
.facts b { display: block; color: var(--fg); font: 400 var(--t2)/1.1 var(--serif); letter-spacing: 0; }
@media (max-width: 980px) { .hero { grid-template-columns: 1fr; gap: var(--s7); padding-top: var(--s6); } }

/* the viewfinder: a real export, crop marks, timecode */
.reel { margin: 0; }
.vf { position: relative; padding: var(--s4); }
.vf::before, .vf::after, .vf .c3, .vf .c4 { content: ""; position: absolute; width: 18px; height: 18px; border-color: var(--dim-2); border-style: solid; pointer-events: none; }
.vf::before { top: 0; left: 0; border-width: 1px 0 0 1px; } .vf::after { top: 0; right: 0; border-width: 1px 1px 0 0; }
.vf .c3 { bottom: 0; left: 0; border-width: 0 0 1px 1px; } .vf .c4 { bottom: 0; right: 0; border-width: 0 1px 1px 0; }
.vf .screen { position: relative; margin: 0 auto; background: var(--stage); aspect-ratio: 16 / 9; max-height: 70vh; transition: max-width var(--mid) var(--ease); }
.vf[data-ratio="1:1"] .screen { aspect-ratio: 1; max-width: 62%; }
.vf[data-ratio="9:16"] .screen { aspect-ratio: 9 / 16; max-width: 40%; }
.vf video, .vf .screen > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; }
.vf video.js { opacity: 0; transition: opacity var(--mid) var(--ease); } .vf video.js.on { opacity: 1; }
.vf .tc { position: absolute; top: var(--s3); left: var(--s3); font: 500 var(--t-1)/1 var(--mono); color: #eeeae1; background: rgba(10, 9, 8, .72); padding: var(--s1) var(--s2); border-radius: var(--r-s); font-variant-numeric: tabular-nums; }
.vf .tc::before { content: ""; display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: #ff5a2a; margin-right: var(--s2); vertical-align: 1px; }
.vf .tc.paused::before { background: #8f897d; }
.reel figcaption { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: var(--s3) var(--s5); padding: var(--s3) 0 0; }
.reel .spec { font: 500 var(--t-1)/1.6 var(--mono); color: var(--dim-2); margin: 0; }
.reel .spec b { color: var(--dim); font-weight: 500; }
.seg { display: inline-flex; border: 1px solid var(--line-2); border-radius: var(--r); overflow: hidden; }
.seg button { min-height: 36px; min-width: 52px; padding: 0 var(--s3); border: 0; background: transparent; color: var(--dim); font: 500 var(--t-1)/1 var(--mono); cursor: pointer; transition: background-color var(--fast) var(--ease), color var(--fast) var(--ease); }
.seg button + button { border-left: 1px solid var(--line-2); }
.seg button:hover { color: var(--fg); }
.seg button[aria-pressed="true"] { background: var(--fg); color: var(--bg); }
.strip { display: grid; grid-template-columns: repeat(6, 1fr); gap: 2px; margin-top: var(--s4); background: var(--stage); padding: 2px; border-radius: var(--r-s); }
.strip img { width: 100%; height: auto; aspect-ratio: 16 / 9; }

.section { padding-top: var(--s10); }
.section .head { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: var(--s8); align-items: end; margin-bottom: var(--s7); }
.section .head p { margin: 0; color: var(--dim); max-width: 36em; }
.section .head .label { display: block; margin-bottom: var(--s3); }
@media (max-width: 980px) { .section { padding-top: var(--s9); } .section .head { grid-template-columns: 1fr; gap: var(--s4); } }

/* spec sheet */
.sheet { width: 100%; border-collapse: collapse; font-size: .9375rem; }
.sheet th, .sheet td { text-align: left; vertical-align: top; padding: var(--s3) var(--s4) var(--s3) 0; border-top: 1px solid var(--line); }
.sheet tr:last-child th, .sheet tr:last-child td { border-bottom: 1px solid var(--line); }
.sheet th { width: 28%; font: 500 var(--t-1)/1.9 var(--mono); letter-spacing: .04em; text-transform: uppercase; color: var(--dim-2); }
.sheet td.v { font-family: var(--mono); font-size: .875rem; color: var(--fg); width: 30%; }
.sheet td { color: var(--dim); }
@media (max-width: 640px) { .sheet th { width: 34%; } .sheet td.n { display: none; } }

/* templates */
.gallery { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--s7) var(--s5); list-style: none; margin: 0; padding: 0; }
.tcard { display: block; text-decoration: none; }
.tcard .shot { position: relative; aspect-ratio: 16 / 9; background: var(--stage); border-radius: var(--r-s); overflow: hidden; outline: 1px solid var(--line); outline-offset: -1px; }
.tcard .shot img, .tcard .shot canvas { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.tcard .shot canvas { opacity: 0; transition: opacity var(--mid) var(--ease); } .tcard .shot canvas.on { opacity: 1; }
.tcard .meta { display: grid; grid-template-columns: auto 1fr auto; gap: var(--s3); align-items: baseline; padding-top: var(--s3); }
.tcard .n, .tcard .d { font: 500 var(--t-1)/1 var(--mono); color: var(--dim-2); }
.tcard h3 { font: 400 var(--t2)/1 var(--serif); }
.tcard p { grid-column: 1 / -1; margin: 0; color: var(--dim); font-size: .9375rem; }
.tcard:hover h3 { color: var(--brand); }
@media (max-width: 980px) { .gallery { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 600px) { .gallery { grid-template-columns: 1fr; } }

/* steps as a cue sheet */
.cues { list-style: none; margin: 0; padding: 0; counter-reset: c; }
.cues li { display: grid; grid-template-columns: 7rem minmax(0, 4fr) minmax(0, 7fr); gap: var(--s5); padding: var(--s5) 0; border-top: 1px solid var(--line); align-items: baseline; }
.cues li:last-child { border-bottom: 1px solid var(--line); }
.cues .tcode { font: 500 var(--t-1)/1 var(--mono); color: var(--brand); }
.cues h3 { font: 400 var(--t3)/1.1 var(--serif); }
.cues p { margin: 0; color: var(--dim); }
@media (max-width: 760px) { .cues li { grid-template-columns: 1fr; gap: var(--s2); } }

/* use cases */
.uses { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--s5); }
.uses a { display: flex; flex-direction: column; gap: var(--s3); height: 100%; padding: var(--s5); border: 1px solid var(--line); border-radius: var(--r); text-decoration: none; transition: border-color var(--fast) var(--ease), background-color var(--fast) var(--ease); }
.uses a:hover { border-color: var(--fg); background: var(--bg-2); }
.uses h3 { font: 400 var(--t2)/1.1 var(--serif); }
.uses p { margin: 0; color: var(--dim); font-size: .9375rem; flex: 1; }
.uses .go { font: 500 var(--t-1)/1 var(--mono); color: var(--brand); }
@media (max-width: 900px) { .uses { grid-template-columns: 1fr; } }

/* pricing: one table, not a card trio */
.price { width: 100%; border-collapse: collapse; table-layout: fixed; }
.price th, .price td { padding: var(--s3) var(--s4); border-top: 1px solid var(--line); text-align: left; vertical-align: top; }
.price thead th { border-top: 0; padding-bottom: var(--s5); vertical-align: bottom; }
.price thead .plan { font: 400 var(--t2)/1.1 var(--serif); display: block; }
.price thead .amt { display: block; font: 400 var(--t5)/1 var(--serif); margin-top: var(--s3); }
.price thead .amt small { font: 500 var(--t-1)/1 var(--mono); color: var(--dim-2); margin-left: var(--s1); }
.price thead .for { display: block; margin-top: var(--s2); font-size: .875rem; color: var(--dim); font-weight: 400; }
.price tbody th { font: 500 var(--t-1)/1.9 var(--mono); letter-spacing: .04em; text-transform: uppercase; color: var(--dim-2); font-weight: 500; }
.price td { color: var(--dim); font-size: .9375rem; }
.price td.y { color: var(--fg); }
.price .rowh { width: 25%; }
.price tfoot td { border-bottom: 1px solid var(--line); padding: var(--s5) var(--s4); }
.price tfoot .btn { width: 100%; }
.price .pick { background: var(--brand-soft); }
.terms-note { margin-top: var(--s4); color: var(--dim); font-size: .875rem; max-width: 52em; }
.plans-m { display: none; }
@media (max-width: 760px) {
  .price { display: none; }
  .plans-m { display: grid; gap: 0; }
  .plans-m > div { display: grid; gap: var(--s3); padding: var(--s5) 0; border-top: 1px solid var(--line); }
  .plans-m > div:last-child { border-bottom: 1px solid var(--line); }
  .plans-m h3 { display: flex; justify-content: space-between; align-items: baseline; font: 400 var(--t2)/1.1 var(--serif); }
  .plans-m h3 b { font: 400 var(--t4)/1 var(--serif); }
  .plans-m h3 small { font: 500 var(--t-1)/1 var(--mono); color: var(--dim-2); margin-left: var(--s1); }
  .plans-m p { margin: 0; color: var(--dim); }
  .plans-m .btn { width: 100%; }
}
/* phones: the sample video right under the headline, tighter rhythm */
@media (max-width: 980px) {
  .hero { gap: 0; }
  .hero > div:first-child { display: contents; }
  .hero > div > *, .hero .reel { order: 3; }
  .hero .label, .hero h1 { order: 1; }
  .hero .reel { order: 2; margin-bottom: var(--s5); }
  .hero h1 { margin-bottom: var(--s4); }
  .hero .cta { margin-top: var(--s5); }
  .vf { padding: var(--s2); }
  .strip { display: none; }
}
@media (max-width: 760px) {
  .section { padding-top: var(--s8); }
  .section .head { margin-bottom: var(--s5); }
  .closer { margin-top: var(--s8); }
  .foot { margin-top: var(--s8); }
  .reel .spec { font-size: .72rem; }
  .gallery { gap: var(--s5); }
}
/* FAQ */
.faq { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: var(--s8); }
.faq .head { display: block; margin: 0; }
.faq details { border-top: 1px solid var(--line); }
.faq details:last-child { border-bottom: 1px solid var(--line); }
.faq summary { cursor: pointer; list-style: none; display: flex; justify-content: space-between; gap: var(--s5); padding: var(--s4) 0; font-weight: 500; font-size: 1.0625rem; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font: 500 var(--t0)/1.6 var(--mono); color: var(--dim-2); transition: transform var(--fast) var(--ease); }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq summary:hover { color: var(--brand); }
.faq details p { color: var(--dim); margin: 0 0 var(--s5); max-width: 40em; }
@media (max-width: 980px) { .faq { grid-template-columns: 1fr; gap: var(--s5); } }

.closer { display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: var(--s5); padding: var(--s7) 0 0; margin-top: var(--s10); border-top: 1px solid var(--fg); }
.closer h2 { max-width: 14em; }

/* prose pages: legal, use cases, 404 */
.doc { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 8fr); gap: var(--s8); padding-top: var(--s8); }
.doc aside { position: sticky; top: calc(var(--bar) + var(--s6)); align-self: start; }
.doc aside p { margin: 0 0 var(--s2); }
.doc aside ul { list-style: none; margin: var(--s4) 0 0; padding: 0; font-size: .9375rem; }
.doc aside li { padding: var(--s1) 0; } .doc aside a { text-decoration: none; color: var(--dim); } .doc aside a:hover, .doc aside a[aria-current] { color: var(--fg); }
.crumbs { font: 500 var(--t-1)/1.4 var(--mono); color: var(--dim-2); margin: 0 0 var(--s5); }
.crumbs a { text-decoration: none; } .crumbs a:hover { color: var(--fg); }
.prose { max-width: 42em; }
.prose h1 { font-size: clamp(var(--t5), 1.8rem + 3vw, var(--t6)); margin-bottom: var(--s5); }
.prose h2 { font-size: var(--t3); margin: var(--s7) 0 var(--s3); }
.prose h3 { margin: var(--s5) 0 var(--s2); }
.prose p, .prose li { color: var(--dim); }
.prose strong { color: var(--fg); font-weight: 500; }
.prose .answer { font-size: var(--t1); line-height: 1.5; color: var(--fg); }
.prose ul, .prose ol { padding-left: 1.2em; margin: 0 0 var(--s4); } .prose li { margin-bottom: var(--s2); }
.prose table { width: 100%; border-collapse: collapse; margin: var(--s4) 0 var(--s5); font-size: .9375rem; }
.prose th, .prose td { text-align: left; vertical-align: top; padding: var(--s2) var(--s3) var(--s2) 0; border-top: 1px solid var(--line); }
.prose thead th { font: 500 var(--t-1)/1.6 var(--mono); text-transform: uppercase; letter-spacing: .04em; color: var(--dim-2); border-top: 0; }
.prose td:first-child { color: var(--fg); }
.prose .cta { margin: var(--s6) 0; }
.prose figure { margin: var(--s5) 0; } .prose figure img { border-radius: var(--r-s); outline: 1px solid var(--line); outline-offset: -1px; width: 100%; height: auto; }
.prose figcaption { font: 500 var(--t-1)/1.6 var(--mono); color: var(--dim-2); margin-top: var(--s2); }
.lost { padding-top: var(--s9); }
.lost .code { font: 500 var(--t-1)/1 var(--mono); color: var(--brand); margin-bottom: var(--s4); }
.lost h1 { font-size: clamp(var(--t5), 2rem + 4vw, var(--t7)); margin-bottom: var(--s5); }
.lost ul { list-style: none; padding: 0; margin: var(--s6) 0 0; border-top: 1px solid var(--line); max-width: 36em; }
.lost li a { display: flex; justify-content: space-between; padding: var(--s4) 0; border-bottom: 1px solid var(--line); text-decoration: none; }
.lost li a:hover { color: var(--brand); }
@media (max-width: 860px) { .doc { grid-template-columns: minmax(0, 1fr); gap: var(--s5); padding-top: var(--s6); } .doc aside { position: static; } .doc aside ul, .doc aside .rail { display: none; } .doc aside .mt24 { margin-top: 0 !important; } }

.prose pre { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: var(--s4); overflow-x: auto; font-size: .8125rem; line-height: 1.6; }
.prose code { color: var(--fg); }
.faq-inline details { border-top: 1px solid var(--line); }
.faq-inline details:last-child { border-bottom: 1px solid var(--line); }
.faq-inline summary { cursor: pointer; padding: var(--s3) 0; font-weight: 500; color: var(--fg); }
.faq-inline details p { margin: 0 0 var(--s4); }

/* ---------- editor ---------- */
body.editor { overflow: hidden; }
body.editor .foot { display: none; }
.top { padding-left: env(safe-area-inset-left); padding-right: env(safe-area-inset-right); }
body.editor .top .wrap { max-width: none; }
.ed { display: grid; grid-template-columns: 400px minmax(0, 1fr); height: calc(100vh - var(--bar) - 1px); height: calc(100dvh - var(--bar) - 1px); }
.ed h1 { font: 500 var(--t-1)/1.4 var(--mono); letter-spacing: .06em; text-transform: uppercase; color: var(--dim-2); padding: var(--s5) var(--s5) 0; margin: 0; }
.ed-side { display: flex; flex-direction: column; min-height: 0; border-right: 1px solid var(--line); background: var(--bg-2); }
.ed-form { overflow-y: auto; padding: var(--s4) var(--s5) var(--s8); flex: 1; }
.ed-main { display: flex; flex-direction: column; min-width: 0; min-height: 0; }
/* phone and tablet: the preview stays pinned under the header while the form scrolls; export is docked at the bottom */
@media (max-width: 960px) {
  body.editor { overflow: auto; }
  .ed { display: flex; flex-direction: column; height: auto; }
  .ed-main { order: -1; position: sticky; top: var(--bar); z-index: 5; background: var(--bg); border-bottom: 1px solid var(--line); }
  .ed-side { border-right: 0; }
  .ed-side h1 { padding-top: var(--s4); }
  .ed-form { overflow: visible; padding-bottom: calc(160px + env(safe-area-inset-bottom)); }
  .dock { position: fixed; left: 0; right: 0; bottom: 0; z-index: 15; background: var(--bg-2); border-top: 1px solid var(--line-2); padding-bottom: env(safe-area-inset-bottom); }
  .dock .exp { border-top: 0; }
  .dock .jobs { max-height: 36vh; }
}
.fs { border: 0; border-top: 1px solid var(--line); padding: var(--s4) 0 var(--s2); margin: 0; min-width: 0; }
.fs:first-child { border-top: 0; padding-top: 0; }
.fs > legend { float: left; width: 100%; padding: 0; margin: 0 0 var(--s3); font: 500 var(--t-1)/1.4 var(--mono); letter-spacing: .06em; text-transform: uppercase; color: var(--dim-2); }
.fs > legend + * { clear: both; }
.fs legend small { text-transform: none; letter-spacing: 0; font-family: var(--sans); }
.field { display: block; margin-bottom: var(--s3); }
.field > span { display: block; font-size: .8125rem; color: var(--dim); margin-bottom: var(--s1); font-weight: 500; }
.field > span small { color: var(--dim-2); font-weight: 400; }
input[type=text], input[type=url], input[type=email], textarea, select { width: 100%; min-height: 40px; background: var(--surface); border: 1px solid var(--line); color: var(--fg); font: 400 .9375rem/1.4 var(--sans); padding: var(--s2) var(--s3); border-radius: var(--r); transition: border-color var(--fast) var(--ease), box-shadow var(--fast) var(--ease); }
input::placeholder, textarea::placeholder { color: var(--dim-2); opacity: .8; }
input:hover, textarea:hover, select:hover { border-color: var(--line-2); }
input:focus, textarea:focus, select:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px var(--brand-soft); }
textarea { resize: vertical; min-height: 64px; }
.fs [data-feat] { margin-bottom: var(--s2); }
.two { display: grid; grid-template-columns: 1fr 1.5fr; gap: var(--s2); }
.fs > .two { margin-bottom: var(--s2); }
.tpls { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--s2); }
.tpl { position: relative; padding: 0; border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; cursor: pointer; background: var(--surface); color: var(--fg); text-align: left; font: inherit; transition: border-color var(--fast) var(--ease); }
.tpl:hover { border-color: var(--line-2); }
.tpl canvas { width: 100%; aspect-ratio: 16 / 9; background: var(--stage); }
.tpl span { display: flex; justify-content: space-between; gap: var(--s1); font-size: .75rem; font-weight: 500; padding: var(--s1) var(--s2); }
.tpl span i { font: 500 var(--t-2)/1.8 var(--mono); font-style: normal; color: var(--dim-2); }
.tpl[aria-pressed="true"] { border-color: var(--brand); box-shadow: inset 0 0 0 1px var(--brand); }
.swatches { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--s2); }
.sw { display: flex; flex-direction: column; gap: var(--s1); font-size: .75rem; color: var(--dim); }
.sw input[type=color] { width: 100%; height: 40px; border: 1px solid var(--line); border-radius: var(--r); background: var(--surface); padding: 3px; cursor: pointer; }
.palettes { display: flex; gap: var(--s2); flex-wrap: wrap; margin-top: var(--s3); }
.pal { display: flex; min-height: 32px; border-radius: var(--r-s); overflow: hidden; border: 1px solid var(--line); cursor: pointer; padding: 0; background: none; }
.pal:hover { border-color: var(--fg); }
.pal i { width: 12px; display: block; }
.upl { display: flex; gap: var(--s3); align-items: center; flex-wrap: wrap; }
.upl input[type=file] { position: absolute; width: 1px; height: 1px; opacity: 0; }
.upl input[type=file]:focus-visible + label, .upl label:focus-within { outline: 2px solid var(--brand); outline-offset: 2px; }
.thumbs { display: flex; gap: var(--s2); flex-wrap: wrap; margin-top: var(--s2); }
.thumbs:empty { display: none; }
.thumbs .th { position: relative; width: 76px; height: 48px; border-radius: var(--r-s); overflow: hidden; border: 1px solid var(--line); background: var(--surface) center/contain no-repeat; }
.thumbs .th button { position: absolute; top: 2px; right: 2px; width: 24px; height: 24px; border-radius: var(--r-s); border: 0; background: rgba(10, 9, 8, .8); color: #fff; font: 500 12px/24px var(--mono); padding: 0; cursor: pointer; }
.note { font-size: .8125rem; color: var(--dim-2); margin: var(--s2) 0 0; }
.privacy { margin: var(--s5) 0 var(--s4); padding: var(--s3) var(--s4); border-left: 2px solid var(--brand); background: var(--surface); font-size: .8125rem; color: var(--dim); }
.pv { position: relative; flex: 1; min-height: 0; display: flex; align-items: center; justify-content: center; padding: var(--s5); background: var(--bg); background-image: linear-gradient(var(--line) 1px, transparent 1px), linear-gradient(90deg, var(--line) 1px, transparent 1px); background-size: 32px 32px; background-position: -1px -1px; }
.pv canvas { max-width: 100%; max-height: 100%; background: var(--stage); outline: 1px solid var(--line-2); }
.pv .state { position: absolute; inset: 0; display: grid; place-items: center; font: 500 var(--t-1)/1.4 var(--mono); color: var(--dim); pointer-events: none; }
.pv .state[hidden] { display: none; }
.pv .state span { background: var(--bg); padding: var(--s2) var(--s3); border: 1px solid var(--line); border-radius: var(--r); }
.pv .state.err span { color: var(--bad); border-color: var(--bad); }
@media (max-width: 960px) { .pv { height: min(34vh, calc(56.25vw + 16px)); height: min(34dvh, calc(56.25vw + 16px)); padding: var(--s2); background-size: 24px 24px; } }
@media (max-width: 960px) {
  .ctl { padding: var(--s1) var(--s3); gap: var(--s2); }
  .ctl input[type=range] { order: 5; flex-basis: 100%; height: 28px; }
  .ctl .time { min-width: 0; margin-right: auto; text-align: left; }
  .ctl .seg button { min-height: 40px; min-width: 48px; }
  .exp { display: grid; grid-template-columns: 1fr auto; gap: var(--s2) var(--s3); padding: var(--s2) var(--s3); }
  .exp fieldset { grid-column: 1 / -1; gap: var(--s3); justify-content: space-between; }
  .exp .grow { display: none; } .exp .grow.bad { display: block; grid-column: 1 / -1; }
  .exp .pro { grid-column: 1 / -1; }
  .exp #export { grid-column: 2; }
  .exp #rm-wm { grid-column: 1; justify-self: start; }
  .jobs { padding: 0 var(--s3) var(--s2); }
}
.ctl { display: flex; gap: var(--s3); align-items: center; padding: var(--s2) var(--s5); border-top: 1px solid var(--line); background: var(--bg-2); flex-wrap: wrap; }
.ctl .play { width: 44px; min-height: 44px; padding: 0; flex: none; }
.ctl .play::before { content: ""; width: 0; height: 0; border-style: solid; border-width: 7px 0 7px 12px; border-color: transparent transparent transparent currentColor; margin-left: 3px; }
.ctl .play[aria-pressed="true"]::before { width: 10px; height: 14px; border: 0; border-left: 3px solid currentColor; border-right: 3px solid currentColor; margin-left: 0; }
.ctl input[type=range] { flex: 1; min-width: 120px; accent-color: var(--brand); height: 44px; }
.ctl .time { font: 500 var(--t-1)/1 var(--mono); color: var(--dim); min-width: 96px; text-align: right; font-variant-numeric: tabular-nums; }
.exp { display: flex; gap: var(--s3) var(--s5); align-items: center; padding: var(--s3) var(--s5); border-top: 1px solid var(--line); background: var(--bg-2); flex-wrap: wrap; }
.exp fieldset { border: 0; margin: 0; padding: 0; display: flex; gap: var(--s4); align-items: center; }
.exp legend { float: left; margin-right: var(--s2); font: 500 var(--t-1)/1.4 var(--mono); letter-spacing: .06em; text-transform: uppercase; color: var(--dim-2); }
.exp label.chk { display: inline-flex; align-items: center; gap: var(--s2); min-height: 44px; font: 500 .875rem/1 var(--mono); color: var(--dim); cursor: pointer; }
.exp label.chk input { accent-color: var(--brand); width: 16px; height: 16px; }
.exp .grow { flex: 1; min-width: 12em; }
.exp .pro { display: inline-flex; gap: var(--s3); align-items: center; font-size: .8125rem; color: var(--ok); font-weight: 500; }
.exp .pro .muted { color: var(--dim); font-weight: 400; }
.exp .pro[hidden], .btn[hidden], .linkbtn[hidden], .note [hidden] { display: none; }
.jobs { display: flex; flex-direction: column; gap: var(--s2); padding: 0 var(--s5) var(--s3); background: var(--bg-2); max-height: 30vh; overflow-y: auto; }
.jobs:empty { display: none; }
.job { display: grid; grid-template-columns: 56px minmax(0, 1fr) auto; gap: var(--s3); align-items: center; font-size: .875rem; }
.job b { font: 500 .8125rem/1 var(--mono); }
.job .pbar { height: 4px; background: var(--line); border-radius: 2px; overflow: hidden; }
.job .pbar i { display: block; height: 100%; width: 0; background: var(--brand); transition: width var(--fast) linear; }
.job.done .pbar i { background: var(--ok); }
.job.failed .pbar i { background: var(--bad); }
.job .st { font: 500 var(--t-1)/1.4 var(--mono); color: var(--dim); }
.job.failed .st { color: var(--bad); }
.job a.btn { min-height: 36px; padding: 0 var(--s3); font-size: .8125rem; }

/* modal */
.modal { position: fixed; inset: 0; z-index: 50; display: grid; place-items: center; background: rgba(10, 9, 8, .7); padding: var(--s5); }
.modal[hidden] { display: none; }
.modal .box { background: var(--bg); border: 1px solid var(--line-2); border-radius: var(--r); max-width: 560px; width: 100%; padding: var(--s6); position: relative; box-shadow: 0 24px 64px rgba(0, 0, 0, .35); }
.modal h3 { font: 400 var(--t3)/1.1 var(--serif); margin: 0 var(--s7) var(--s3) 0; }
.modal .x { position: absolute; top: var(--s3); right: var(--s3); width: 44px; height: 44px; background: none; border: 0; color: var(--dim); font: 400 24px/1 var(--sans); cursor: pointer; border-radius: var(--r); }
.modal .x:hover { color: var(--fg); background: var(--bg-2); }
.modal .opts { display: grid; grid-template-columns: 1fr 1fr; gap: var(--s3); margin: var(--s5) 0; }
.modal .opt { border: 1px solid var(--line-2); border-radius: var(--r); padding: var(--s4); cursor: pointer; background: var(--surface); text-align: left; color: var(--fg); font: inherit; transition: border-color var(--fast) var(--ease); }
.modal .opt:hover { border-color: var(--brand); }
.modal .opt b { display: block; font: 400 var(--t4)/1 var(--serif); margin-bottom: var(--s2); }
.modal .opt b small { font: 500 var(--t-1)/1 var(--mono); color: var(--dim-2); }
.modal .opt span { color: var(--dim); font-size: .875rem; }
.modal form { display: flex; gap: var(--s2); margin-top: var(--s3); }
.modal form input[type=email] { min-height: 44px; }
.modal .ok { color: var(--ok); font-weight: 500; }
.modal form.buy { flex-direction: column; align-items: stretch; gap: var(--s4); }
.modal .consent { display: flex; gap: var(--s3); align-items: flex-start; font-size: .875rem; color: var(--fg); cursor: pointer; }
.modal .consent input { margin-top: 3px; accent-color: var(--brand); width: 18px; height: 18px; flex: none; }
@media (max-width: 520px) { .modal .opts { grid-template-columns: 1fr; } .modal .box { padding: var(--s5); } .modal form { flex-direction: column; } }
.toast { position: fixed; bottom: var(--s5); left: 50%; transform: translateX(-50%); max-width: calc(100% - 2 * var(--s5)); background: var(--fg); color: var(--bg); padding: var(--s3) var(--s4); border-radius: var(--r); font-size: .875rem; z-index: 60; animation: rise var(--mid) var(--ease); }
@keyframes rise { from { opacity: 0; transform: translate(-50%, 8px); } }
.mt12 { margin-top: var(--s3); } .m0 { margin: 0 !important; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: 1ms !important; animation-duration: 1ms !important; scroll-behavior: auto !important; }
}
.exp .note.bad { color: var(--bad); }
@media (max-width: 960px) { .exp label.chk { min-height: 36px; } .exp legend { display: none; } }
.mt24 { margin-top: var(--s5) !important; }
/* phones: while typing, the on-screen keyboard owns the bottom of the screen (iOS floats fixed bars above it) */
@media (max-width: 960px) and (hover: none) { .ed-side:focus-within + .ed-main .dock { display: none; } }
