/* Cliptall brand tokens. The one place where a colour, a typeface or a step of the scale is named: the app links
   this file and the site build copies it. Rules and contrast numbers: brand/README.md. Plain CSS, no build step.

   The typeface itself is loaded next to this file, because the app and the web need different packaging:
   app  -> fonts/pretendard-full.css        (one 2.0 MB variable woff2, already on disk)
   web  -> fonts/pretendard-dynamic-subset.css (92 small woff2, only the glyphs the page shows)
   Link one of those BEFORE this file. */

:root {
  /* Dark first: creators edit in dark tools and the clips are previewed on dark. A user who forces light,
     and the reading parts of the landing page, get the light values. data-theme on <html> overrides both. */
  color-scheme: dark light;

  --paper: light-dark(#f7f6f2, #0f1014); /* page and window background */
  --surface: light-dark(#ffffff, #181a20); /* cards, panels, inputs */
  --sunken: light-dark(#eceae4, #22252d); /* wells, tracks, neutral badges */
  --ink: light-dark(#15161b, #f2f2ef); /* text */
  --ink-muted: light-dark(#5a5d66, #a4a7b0); /* secondary text */
  --line: light-dark(#e2dfd7, #2b2e37); /* hairlines, decorative */
  --line-strong: light-dark(#85837a, #6c707c); /* control edges that must be seen (3:1) */
  --accent: light-dark(#ffd23f, #ffd23f); /* caption yellow: primary button fill, the word being spoken, the mark */
  --accent-hover: light-dark(#f0be14, #ffe176);
  --on-accent: light-dark(#1a1505, #1a1505); /* text on --accent */
  --accent-ink: light-dark(#7a5c00, #ffd23f); /* yellow as text, as a link, and as the primary button's edge */
  --accent-soft: light-dark(#fff2cc, #2e2713); /* tinted background behind accent text */
  --ok: light-dark(#0f7544, #6fd9a0);
  --ok-soft: light-dark(#e0f1e7, #0e2619);
  --danger: light-dark(#b52a1e, #ff9087);
  --danger-soft: light-dark(#fbe7e4, #2e1614);

  /* Type. One family, Latin and Hangul together, so an English and a Korean screen are the same screen. */
  --font-text: 'Pretendard Variable', Pretendard, 'Segoe UI', 'Malgun Gothic', system-ui, sans-serif;
  --font-display: var(--font-text);
  --font-mono: 'Cascadia Mono', Consolas, ui-monospace, monospace;
  --display-weight: 780;
  --display-tracking: -0.025em;
  --leading-body: 1.6;
  --leading-heading: 1.12;
  --text-xs: 0.75rem;
  --text-sm: 0.875rem;
  --text-md: 1rem;
  --text-lg: 1.125rem;
  --text-xl: 1.375rem;
  --text-2xl: 1.75rem;
  --text-3xl: 2.25rem;
  --text-4xl: 3rem;
  --text-5xl: 3.75rem;
  --weight-regular: 400;
  --weight-medium: 500;
  --weight-semibold: 600;
  --weight-bold: 700;

  /* Space: a 4 px base */
  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 24px;
  --space-6: 32px;
  --space-7: 48px;
  --space-8: 64px;
  --space-9: 96px;

  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --radius-full: 999px;

  --shadow-sm: 0 1px 2px light-dark(rgb(21 22 27 / 0.1), rgb(0 0 0 / 0.55));
  --shadow-md: 0 1px 2px light-dark(rgb(21 22 27 / 0.06), rgb(0 0 0 / 0.45)), 0 10px 28px -12px light-dark(rgb(21 22 27 / 0.22), rgb(0 0 0 / 0.75));
  --shadow-lg: 0 2px 6px light-dark(rgb(21 22 27 / 0.06), rgb(0 0 0 / 0.45)), 0 32px 64px -24px light-dark(rgb(21 22 27 / 0.3), rgb(0 0 0 / 0.85));

  /* Motion: short and calm. Reduced motion turns every duration to zero. */
  --ease-out: cubic-bezier(0.22, 0.8, 0.3, 1);
  --ease-in-out: cubic-bezier(0.65, 0, 0.35, 1);
  --duration-fast: 120ms;
  --duration-base: 220ms;
  --duration-slow: 480ms;

  /* The 9:16 frame: every preview, the mark and the empty state use this one ratio. */
  --ratio-tall: 9 / 16;
  --ratio-wide: 16 / 9;
}

:root[data-theme='light'] { color-scheme: light; }
:root[data-theme='dark'] { color-scheme: dark; }

@media (prefers-reduced-motion: reduce) {
  :root {
    --duration-fast: 0ms;
    --duration-base: 0ms;
    --duration-slow: 0ms;
  }
}

/* Korean sets wider than Latin at the same size and breaks badly at a space, so it gets a little more air. */
:lang(ko) {
  --leading-body: 1.72;
  --leading-heading: 1.34;
  --display-tracking: -0.015em;
}

/* Cliptall brand components, shared by the app and the landing page. Every value comes from tokens.css: no colour
   and no typeface may be written here. The class names are the contract; brand/README.md lists them. */

/* Base: low specificity (:where), so a page layer overrides it without a fight. */
:where(body) {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-text);
  font-size: var(--text-md);
  line-height: var(--leading-body);
  -webkit-font-smoothing: antialiased;
}
:where(h1, h2, h3, .display) {
  font-family: var(--font-display);
  font-weight: var(--display-weight);
  letter-spacing: var(--display-tracking);
  line-height: var(--leading-heading);
  text-wrap: balance;
}
:where(:lang(ko)) { word-break: keep-all; overflow-wrap: break-word; }
:where(code, kbd, samp) { font-family: var(--font-mono); font-size: 0.9em; }
:where(a) { color: var(--accent-ink); text-decoration-thickness: 1px; text-underline-offset: 0.2em; }
:where(a:hover) { text-decoration-thickness: 2px; }
:where(:focus-visible) { outline: 2px solid var(--accent); outline-offset: 2px; }
::selection { background: var(--accent-soft); color: var(--ink); }

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

/* Buttons. One .btn-primary per screen; everything else is .btn-quiet, .btn-ghost or a link. On light paper the
   yellow fill alone has no visible edge, so the primary button always carries the --accent-ink hairline. */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  min-height: 44px;
  padding: 0 var(--space-5);
  border: 1px solid transparent;
  border-radius: var(--radius-md);
  font-family: var(--font-text);
  font-size: var(--text-md);
  font-weight: var(--weight-semibold);
  line-height: 1.2;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color var(--duration-fast) var(--ease-out), border-color var(--duration-fast) var(--ease-out), transform var(--duration-fast) var(--ease-out);
}
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--accent); border-color: var(--accent-ink); color: var(--on-accent); box-shadow: var(--shadow-sm); }
.btn-primary:hover { background: var(--accent-hover); }
.btn-quiet { background: var(--surface); border-color: var(--line-strong); color: var(--ink); }
.btn-quiet:hover { background: var(--sunken); }
.btn-ghost { background: transparent; color: var(--ink-muted); }
.btn-ghost:hover { color: var(--ink); background: var(--sunken); }
.btn-lg { min-height: 52px; padding-inline: var(--space-6); font-size: var(--text-lg); }
.btn-sm { min-height: 34px; padding-inline: var(--space-4); font-size: var(--text-sm); }
.btn:disabled,
.btn[aria-disabled='true'] { opacity: 0.45; cursor: not-allowed; box-shadow: none; transform: none; }

/* Card: a surface with a hairline edge. */
.card {
  padding: var(--space-5);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
}
.card-raised { box-shadow: var(--shadow-md); }

/* Badge: a short state label, never a control. */
.badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  padding: 2px 10px;
  border-radius: var(--radius-full);
  background: var(--sunken);
  color: var(--ink-muted);
  font-size: var(--text-xs);
  font-weight: var(--weight-semibold);
  line-height: 1.6;
  white-space: nowrap;
}
.badge-accent { background: var(--accent-soft); color: var(--accent-ink); }
.badge-ok { background: var(--ok-soft); color: var(--ok); }
.badge-danger { background: var(--danger-soft); color: var(--danger); }

/* A number first, its meaning second. */
.stat { display: flex; flex-direction: column; gap: var(--space-1); }
.stat-value {
  font-family: var(--font-display);
  font-size: var(--text-4xl);
  font-weight: var(--display-weight);
  font-variant-numeric: lining-nums tabular-nums;
  letter-spacing: -0.03em;
  line-height: 1;
}
.stat-label { color: var(--ink-muted); font-size: var(--text-sm); }

/* The clip: a 9:16 frame with the result inside it. Put <video>, <img> or .clip-fallback in .clip-frame.
   <figure class="clip"><div class="clip-frame">…</div><figcaption class="clip-foot">…</figcaption></figure> */
.clip { display: flex; flex-direction: column; gap: var(--space-2); margin: 0; min-width: 0; }
.clip-frame {
  position: relative;
  aspect-ratio: var(--ratio-tall);
  overflow: hidden;
  background: var(--sunken);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
}
.clip-frame > video,
.clip-frame > img { display: block; width: 100%; height: 100%; object-fit: cover; }
.clip-wide { aspect-ratio: var(--ratio-wide); }
.clip-foot { display: flex; align-items: center; justify-content: space-between; gap: var(--space-2); color: var(--ink-muted); font-size: var(--text-sm); font-variant-numeric: tabular-nums; }
.clip-rank { font-weight: var(--weight-semibold); color: var(--ink); }
/* A corner tag inside the frame: the length, or "watermarked". */
.clip-tag {
  position: absolute;
  inset-block-end: var(--space-2);
  inset-inline-end: var(--space-2);
  padding: 2px 8px;
  border-radius: var(--radius-full);
  background: var(--paper);
  color: var(--ink);
  font-size: var(--text-xs);
  font-weight: var(--weight-semibold);
  font-variant-numeric: tabular-nums;
}

/* The signature: a caption line with the word being spoken lit in yellow. The one place yellow lands on text.
   <p class="caption"><span>the</span> <span class="is-now">word</span> <span>now</span></p> */
.caption {
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.28em;
  font-weight: var(--weight-bold);
  letter-spacing: -0.01em;
  line-height: 1.25;
  text-align: center;
}
.caption > * { color: var(--ink); }
.caption > .is-now { color: var(--accent); }

/* Progress: <progress class="progress" value max>. Without a value it sweeps. */
.progress {
  appearance: none;
  display: block;
  width: 100%;
  height: 8px;
  border: 0;
  border-radius: var(--radius-full);
  background: var(--sunken);
  overflow: hidden;
}
.progress::-webkit-progress-bar { background: var(--sunken); border-radius: var(--radius-full); }
.progress::-webkit-progress-value { background: var(--accent); border-radius: var(--radius-full); transition: inline-size var(--duration-base) var(--ease-out); }
.progress::-moz-progress-bar { background: var(--accent); border-radius: var(--radius-full); }
.progress:indeterminate,
.progress:indeterminate::-webkit-progress-bar {
  background: linear-gradient(90deg, var(--sunken) 0 35%, var(--accent) 35% 65%, var(--sunken) 65%) 0 0 / 300% 100% no-repeat;
  animation: ct-sweep 1.4s var(--ease-in-out) infinite;
}
.progress:indeterminate::-webkit-progress-value { background: transparent; } /* Chrome draws its own pill on top */
@keyframes ct-sweep { from { background-position-x: 100%; } to { background-position-x: -100%; } }
@media (prefers-reduced-motion: reduce) {
  .progress:indeterminate, .progress:indeterminate::-webkit-progress-bar { animation: none; }
}

/* Steps: the stages of one run, in words a user knows. <ol class="steps"><li class="is-done|is-now">…</li></ol> */
.steps { list-style: none; display: grid; gap: var(--space-2); margin: 0; padding: 0; }
.steps > li {
  display: grid;
  grid-template-columns: 20px 1fr;
  align-items: center;
  gap: var(--space-3);
  color: var(--ink-muted);
}
.steps > li::before {
  content: '';
  width: 10px;
  height: 10px;
  margin-inline: 5px;
  border-radius: var(--radius-full);
  border: 2px solid var(--line-strong);
}
.steps > .is-done { color: var(--ink); }
.steps > .is-done::before { background: var(--ok); border-color: var(--ok); }
.steps > .is-now { color: var(--ink); font-weight: var(--weight-semibold); }
.steps > .is-now::before { background: var(--accent); border-color: var(--accent); animation: ct-pulse 1.2s var(--ease-in-out) infinite; }
@keyframes ct-pulse { 50% { opacity: 0.35; } }
@media (prefers-reduced-motion: reduce) { .steps > .is-now::before { animation: none; } }

/* Empty state: the drop target. Add .is-over while a file is dragged over it. */
.empty {
  display: grid;
  justify-items: center;
  gap: var(--space-3);
  padding: var(--space-7) var(--space-6);
  background: var(--surface);
  border: 2px dashed var(--line-strong);
  border-radius: var(--radius-xl);
  text-align: center;
  transition: background-color var(--duration-fast) var(--ease-out), border-color var(--duration-fast) var(--ease-out);
}
.empty.is-over { background: var(--accent-soft); border-color: var(--accent); }
.empty-title { margin: 0; font-size: var(--text-2xl); }
.empty-text { margin: 0; max-width: 46ch; color: var(--ink-muted); }
.empty-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: var(--space-3); margin-top: var(--space-2); }

/* Banner: a message about the whole screen. role="alert" for errors. */
.banner {
  display: grid;
  gap: var(--space-1);
  padding: var(--space-4) var(--space-5);
  background: var(--sunken);
  border-left: 4px solid var(--line-strong);
  border-radius: var(--radius-md);
}
.banner-title { margin: 0; font-weight: var(--weight-semibold); font-family: var(--font-text); font-size: var(--text-md); letter-spacing: normal; }
.banner-text { margin: 0; color: var(--ink-muted); }
.banner-error { background: var(--danger-soft); border-left-color: var(--danger); }
.banner-error .banner-title { color: var(--danger); }
.banner-accent { background: var(--accent-soft); border-left-color: var(--accent); }
.banner-accent .banner-title { color: var(--accent-ink); }
.banner-ok { background: var(--ok-soft); border-left-color: var(--ok); }
.banner-ok .banner-title { color: var(--ok); }

/* Field: a labelled input, used for the licence key. */
.field { display: grid; gap: var(--space-2); }
.field > label { font-size: var(--text-sm); font-weight: var(--weight-semibold); color: var(--ink); }
.field > input {
  min-height: 44px;
  padding: 0 var(--space-4);
  background: var(--surface);
  color: var(--ink);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-md);
  font-family: var(--font-mono);
  font-size: var(--text-md);
  letter-spacing: 0.04em;
}
.field > input::placeholder { color: var(--ink-muted); }
.field > input:focus-visible { border-color: var(--accent); }
.field-hint { margin: 0; color: var(--ink-muted); font-size: var(--text-sm); }
.field-error { margin: 0; color: var(--danger); font-size: var(--text-sm); }

/* The landing page's own layout. Colours, typefaces, spacing, corners and motion come from brand/tokens.css through
   var(--…); nothing here may name one. Shared parts (.btn, .card, .clip, .badge, .progress …) come from
   brand/components.css. tools/build-web.js joins the three into web/style.css in that order.
   test/web/brand.test.js holds this file to it. */

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

body { overflow-x: hidden; }

img,
video,
svg { max-width: 100%; }

p { margin: 0 0 var(--space-4); }
h1,
h2,
h3 { margin: 0 0 var(--space-4); }
h1 { font-size: var(--text-4xl); }
h2 { font-size: var(--text-3xl); }
h3 { font-size: var(--text-xl); }
ul,
ol { margin: 0; padding: 0; list-style: none; }

.wrap { width: min(100% - 2 * var(--space-4), 1120px); margin-inline: auto; }
.wrap.narrow { width: min(100% - 2 * var(--space-4), 720px); }
.section { padding-block: var(--space-9); border-top: 1px solid var(--line); }
.section > .wrap > h2 { max-width: 20ch; }
.lead { max-width: 62ch; color: var(--ink-muted); font-size: var(--text-lg); }

.skip {
  position: absolute;
  left: var(--space-4);
  top: calc(-1 * var(--space-9));
  z-index: 10;
  padding: var(--space-3) var(--space-4);
  background: var(--surface);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-md);
  color: var(--ink);
}
.skip:focus { top: var(--space-4); }

/* Header: the mark, the name, the sections, the language menu. */
.site-header {
  position: sticky;
  top: 0;
  z-index: 5;
  background: color-mix(in srgb, var(--paper) 88%, transparent);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.header-row { display: flex; align-items: center; gap: var(--space-5); min-height: 60px; }
.brand { display: inline-flex; align-items: center; gap: var(--space-2); color: var(--ink); text-decoration: none; }
.brand-mark { display: block; }
.brand-name { font-family: var(--font-display); font-weight: var(--display-weight); letter-spacing: var(--display-tracking); font-size: var(--text-lg); }
.site-nav { display: flex; gap: var(--space-5); margin-inline-start: auto; }
.site-nav a { color: var(--ink-muted); font-size: var(--text-sm); font-weight: var(--weight-medium); text-decoration: none; }
.site-nav a:hover { color: var(--ink); }
.langs { margin-inline-start: auto; position: relative; }
.site-nav + .langs { margin-inline-start: 0; }
.langs summary {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-2) var(--space-3);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  color: var(--ink-muted);
  font-size: var(--text-sm);
  cursor: pointer;
  list-style: none;
}
.langs summary::-webkit-details-marker { display: none; }
.langs summary:hover { color: var(--ink); border-color: var(--line-strong); }
.langs svg { fill: none; stroke: currentColor; stroke-width: 1.6; }
.langs ul {
  position: absolute;
  inset-inline-end: 0;
  margin-top: var(--space-2);
  min-width: 160px;
  padding: var(--space-2);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
}
.langs ul a { display: block; padding: var(--space-2) var(--space-3); border-radius: var(--radius-sm); color: var(--ink); text-decoration: none; }
.langs ul a:hover { background: var(--sunken); }
.langs ul a[aria-current='page'] { color: var(--accent-ink); font-weight: var(--weight-semibold); }

/* Hero: one sentence, two buttons, and the film right under them, all down the middle of the page. */
.hero { padding-block: var(--space-8) var(--space-7); text-align: center; }
.hero-copy { display: grid; justify-items: center; }
.hero h1 { font-size: var(--text-5xl); max-width: 18ch; margin-bottom: var(--space-5); }
.hero .lead { font-size: var(--text-xl); color: var(--ink-muted); max-width: 56ch; }
.hero-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: var(--space-3); margin-block: var(--space-5) var(--space-4); }
.hero-note { color: var(--ink-muted); font-size: var(--text-sm); margin: 0; max-width: 60ch; }
.hero .clips { width: min(100%, 720px); margin-inline: auto; margin-top: var(--space-7); text-align: start; }
.ba-section .film { width: min(100%, 880px); }

/* A film: one or more videos that play while they are on screen, with one button in the caption. */
.film { margin: 0; display: grid; gap: var(--space-3); }
.film .clip-frame { box-shadow: var(--shadow-lg); }
.film-video { display: block; width: 100%; height: 100%; object-fit: cover; background: var(--sunken); }
.film-caption,
.clips-caption { display: flex; align-items: center; gap: var(--space-3); color: var(--ink-muted); font-size: var(--text-sm); margin: 0; }
.film-toggle {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  flex: none;
  min-height: 34px;
  padding: 0 var(--space-3);
  background: var(--surface);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-full);
  color: var(--ink);
  font-family: var(--font-text);
  font-size: var(--text-sm);
  font-weight: var(--weight-semibold);
  cursor: pointer;
}
.film-toggle:hover { background: var(--sunken); }
.film-toggle svg { width: 16px; height: 16px; fill: currentColor; }

/* Before and after: the wide frame, an arrow, the tall clip. */
.ba { display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 0.42fr); gap: var(--space-5); align-items: center; margin-block: var(--space-6); }
.ba-arrow { margin: 0; color: var(--ink-muted); }
.ba-arrow svg { fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.ba-note { color: var(--ink-muted); font-size: var(--text-sm); }
.clips-title { margin-top: var(--space-8); }
.clips { margin: 0; display: grid; gap: var(--space-4); }
.clips-row { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--space-5); }
.clip-video { display: block; width: 100%; height: 100%; object-fit: cover; }

/* How it works: three numbered cards, each with the window at that moment. */
.howsteps { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--space-6); margin-top: var(--space-6); }
.howstep {
  display: grid;
  gap: var(--space-2);
  padding: var(--space-5);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
}
.howstep-shot { margin: 0 0 var(--space-2); }
.howstep-shot img { display: block; width: 100%; height: auto; border: 1px solid var(--line); border-radius: var(--radius-md); background: var(--sunken); }
.howstep-n {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  margin: 0;
  border-radius: var(--radius-full);
  background: var(--accent-soft);
  color: var(--accent-ink);
  font-size: var(--text-sm);
  font-weight: var(--weight-bold);
  font-variant-numeric: tabular-nums;
}
.howstep h3 { margin: 0; font-size: var(--text-lg); }
.howstep p:last-child { margin: 0; color: var(--ink-muted); }

/* Why it runs on your PC. */
.reasons { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-5); margin-top: var(--space-6); }
.reason h3 { margin: 0 0 var(--space-2); font-size: var(--text-lg); }
.reason p { margin: 0; color: var(--ink-muted); }

/* Price: free on the left, the licence on the right. */
.price-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-5); margin-top: var(--space-6); align-items: stretch; }
.price-card { display: flex; flex-direction: column; gap: var(--space-4); padding: var(--space-6); }
.price-card .checks { margin-bottom: var(--space-2); }
.price-buy { margin-top: auto; }
.price-card-paid { border-color: var(--accent-ink); }
.price-name { margin: 0; font-weight: var(--weight-semibold); }
.price-amount { margin: 0; display: flex; align-items: baseline; gap: var(--space-2); }
.price-amount .amount {
  font-family: var(--font-display);
  font-size: var(--text-4xl);
  font-weight: var(--display-weight);
  letter-spacing: -0.03em;
  font-variant-numeric: lining-nums tabular-nums;
  line-height: 1;
}
.price-once { color: var(--ink-muted); font-size: var(--text-sm); }
.checks { display: grid; gap: var(--space-2); }
.checks li { position: relative; padding-inline-start: var(--space-6); color: var(--ink-muted); }
.checks li::before {
  content: '';
  position: absolute;
  inset-inline-start: 0;
  top: 0.55em;
  width: 11px;
  height: 6px;
  border-inline-start: 2px solid var(--accent-ink);
  border-block-end: 2px solid var(--accent-ink);
  transform: rotate(-45deg);
}
.price-buy { width: 100%; }
.watermark { margin: var(--space-6) 0 0; max-width: 300px; }
.watermark img { display: block; width: 100%; height: auto; border: 1px solid var(--line); border-radius: var(--radius-md); }
.watermark figcaption { margin-top: var(--space-2); color: var(--ink-muted); font-size: var(--text-sm); }
.price-secure,
.price-soon,
.price-fine { margin: 0; color: var(--ink-muted); font-size: var(--text-sm); }
.price-soon { margin-top: var(--space-5); }
.price-fine { margin-top: var(--space-3); }
.price-compare {
  display: inline-block;
  max-width: 62ch;
  margin: 0;
  padding: var(--space-3) var(--space-4);
  background: var(--accent-soft);
  border-radius: var(--radius-md);
  color: var(--accent-ink);
  font-weight: var(--weight-medium);
}

/* Download: the button and its facts on the left, the unsigned warning on the right. */
.download-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); gap: var(--space-7); margin-top: var(--space-6); align-items: start; }
.download-facts { display: grid; gap: var(--space-1); margin-block: var(--space-4) var(--space-3); color: var(--ink-muted); font-size: var(--text-sm); }
.download-sum summary { cursor: pointer; color: var(--ink-muted); font-size: var(--text-sm); }
.download-sum code { display: block; margin-top: var(--space-2); padding: var(--space-2) var(--space-3); background: var(--sunken); border-radius: var(--radius-sm); font-size: var(--text-xs); overflow-wrap: anywhere; }
.unsigned p { color: var(--ink-muted); font-size: var(--text-sm); }
.winwarn { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-3); }
.winwarn-box {
  position: relative;
  display: grid;
  gap: var(--space-2);
  padding: var(--space-4);
  background: var(--sunken);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
}
.winwarn-n {
  position: absolute;
  top: calc(-1 * var(--space-2));
  inset-inline-start: calc(-1 * var(--space-2));
  display: grid;
  place-items: center;
  width: 22px;
  height: 22px;
  border-radius: var(--radius-full);
  background: var(--accent);
  color: var(--on-accent);
  font-size: var(--text-xs);
  font-weight: var(--weight-bold);
}
.winwarn-title { margin: 0; font-size: var(--text-sm); font-weight: var(--weight-semibold); }
.winwarn-line { display: block; height: 6px; border-radius: var(--radius-full); background: var(--line); }
.winwarn-line:nth-of-type(2) { width: 70%; }
.winwarn-link { margin: 0; color: var(--accent-ink); font-size: var(--text-sm); text-decoration: underline; }
.winwarn-buttons { display: flex; gap: var(--space-2); margin: 0; }
.winwarn-run {
  padding: var(--space-1) var(--space-3);
  background: var(--accent);
  color: var(--on-accent);
  border-radius: var(--radius-sm);
  font-size: var(--text-xs);
  font-weight: var(--weight-semibold);
}
.winwarn-other { width: 56px; border-radius: var(--radius-sm); background: var(--line); }

/* Questions. */
.faq-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 2fr); gap: var(--space-7); }
.faq-list { display: grid; gap: var(--space-2); }
.faq-list details { padding: var(--space-4) var(--space-5); background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-md); }
.faq-list summary { cursor: pointer; font-weight: var(--weight-semibold); }
.faq-list details[open] summary { margin-bottom: var(--space-3); }
.faq-list p { margin: 0; color: var(--ink-muted); }

/* Footer. */
.site-footer { padding-block: var(--space-7); border-top: 1px solid var(--line); background: var(--surface); }
.footer-grid { display: grid; gap: var(--space-4); }
.footer-brand { display: flex; align-items: center; gap: var(--space-3); margin: 0; }
.footer-links { display: flex; flex-wrap: wrap; gap: var(--space-5); }
.footer-notes p { margin: 0 0 var(--space-1); color: var(--ink-muted); font-size: var(--text-sm); }

/* The thank-you page. */
.thanks { padding-block: var(--space-9) var(--space-8); }
.thanks-steps { display: grid; gap: var(--space-4); margin-block: var(--space-6); }
.thanks-steps li { display: grid; grid-template-columns: 28px minmax(0, 1fr); gap: var(--space-4); align-items: start; }
.thanks-n {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border-radius: var(--radius-full);
  background: var(--accent-soft);
  color: var(--accent-ink);
  font-size: var(--text-sm);
  font-weight: var(--weight-bold);
}
.thanks-steps p { margin: 0; color: var(--ink-muted); }
.thanks-steps strong { color: var(--ink); }
.thanks-pcs,
.thanks-help { color: var(--ink-muted); font-size: var(--text-sm); }
.thanks-download { padding-block: var(--space-6); }
.thanks-download .download-grid { grid-template-columns: minmax(0, 1fr); gap: var(--space-5); }

/* The legal pages. */
.legal { padding-block: var(--space-8); }
.legal-updated { color: var(--ink-muted); font-size: var(--text-sm); }
.legal-body section { margin-top: var(--space-7); }
.legal-body h2 { font-size: var(--text-xl); }
.legal-body p { color: var(--ink-muted); }
.legal-home { margin-top: var(--space-8); }

.not-found { padding-block: var(--space-9); text-align: center; }
.not-found p { margin-bottom: var(--space-3); }

/* A stand-in picture or film, until the real one is imported. tools/stage-deploy.js refuses to stage a page that
   still has one of these, so this label never reaches a visitor. */
[data-placeholder] { position: relative; outline: 2px dashed var(--danger); outline-offset: 4px; }
[data-placeholder]::after {
  content: 'PLACEHOLDER: ' attr(data-placeholder);
  position: absolute;
  top: 0;
  inset-inline-start: 0;
  z-index: 2;
  padding: var(--space-1) var(--space-2);
  background: var(--danger);
  color: var(--paper);
  font-size: var(--text-xs);
  font-weight: var(--weight-bold);
  letter-spacing: 0.04em;
}

@media (max-width: 900px) {
  .download-grid,
  .faq-grid { grid-template-columns: minmax(0, 1fr); gap: var(--space-6); }
  .howsteps,
  .reasons,
  .price-grid { grid-template-columns: minmax(0, 1fr); }
  .ba { grid-template-columns: minmax(0, 1fr); justify-items: center; }
  .ba-after { width: min(60%, 260px); }
  .ba-arrow svg { rotate: 90deg; }
  .site-nav { display: none; }
  .langs { margin-inline-start: auto; }
  h1 { font-size: var(--text-3xl); }
  .hero h1 { font-size: var(--text-4xl); }
  h2 { font-size: var(--text-2xl); }
  .section { padding-block: var(--space-8); }
  .winwarn { grid-template-columns: minmax(0, 1fr); }
}

@media (max-width: 560px) {
  /* Three clips side by side would be 110 px wide, too small to read a caption. One and a bit, and a swipe. */
  .clips-row {
    display: flex;
    gap: var(--space-4);
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    padding-bottom: var(--space-2);
  }
  .clips-row li { flex: 0 0 64%; scroll-snap-align: start; }
  .hero h1 { font-size: var(--text-3xl); }
  .hero .lead { font-size: var(--text-lg); }
  .hero-actions .btn { width: 100%; }
}
