/* Sweep website. Tokens mirror the app's Daylight system
   (src/styles/tokens.css) so the site and the product read as one thing. */

/* Both fonts are variable (one file carries every weight on its wght axis), so
   each family is one file and one rule with a weight range. Six rules pointing
   at copies of two files made the browser download the same bytes six times. */
@font-face {
  font-family: "Inter";
  font-weight: 400 700;
  font-display: swap;
  src: url("assets/fonts/inter-variable.woff2") format("woff2");
}
@font-face {
  font-family: "JetBrains Mono";
  font-weight: 400 500;
  font-display: swap;
  src: url("assets/fonts/jetbrains-mono-variable.woff2") format("woff2");
}

:root {
  color-scheme: light;
  --ground: #f5f5f7;
  --surface: #ffffff;
  --surface-2: #fbfbfd;
  --ink: #1d1d1f;
  --ink-2: #515154;
  --ink-3: #6e6e73;
  --hairline: rgba(0, 0, 0, 0.1);
  --fill: rgba(0, 0, 0, 0.05);
  --accent: #0066cc;
  --accent-ink: #ffffff;
  --accent-hover: #0058b0;
  --link: #0066cc;
  --green: #30b94d;
  --green-deep: #1f7a36;
  --green-soft: rgba(48, 185, 77, 0.14);
  --warn: #b25000;
  --warn-soft: rgba(178, 80, 0, 0.1);
  --nav: rgba(245, 245, 247, 0.78);
  --shadow-window:
    0 0 0 0.5px rgba(0, 0, 0, 0.12), 0 12px 40px rgba(0, 0, 0, 0.12),
    0 40px 90px rgba(0, 0, 0, 0.1);
  --shadow-card: 0 0 0 0.5px rgba(0, 0, 0, 0.08), 0 2px 8px rgba(0, 0, 0, 0.04);
  --shadow-chip: 0 0 0 0.5px rgba(0, 0, 0, 0.1), 0 8px 24px rgba(0, 0, 0, 0.14);
  --grime-tint: rgba(110, 96, 70, 0.1);

  --nav-h: 52px;
  --font:
    "Inter", -apple-system, "Segoe UI Variable Text", "Segoe UI", system-ui, sans-serif;
  --mono: "JetBrains Mono", "Cascadia Mono", Consolas, ui-monospace, monospace;
  --measure: 62ch;
  --page: 1120px;
  --gutter: clamp(16px, 4vw, 40px);
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --ground: #111113;
    --surface: #1c1c1e;
    --surface-2: #19191b;
    --ink: #f5f5f7;
    --ink-2: #c7c7cc;
    --ink-3: #a1a1a6;
    --hairline: rgba(255, 255, 255, 0.12);
    --fill: rgba(255, 255, 255, 0.07);
    --accent: #0a6fe0;
    --accent-ink: #ffffff;
    --accent-hover: #1f7ff0;
    --link: #57a9ff;
    --green: #32d74b;
    --green-deep: #32d74b;
    --green-soft: rgba(50, 215, 75, 0.14);
    --warn: #ffa626;
    --warn-soft: rgba(255, 166, 38, 0.14);
    --nav: rgba(17, 17, 19, 0.72);
    --shadow-window:
      0 0 0 0.5px rgba(255, 255, 255, 0.12), 0 12px 40px rgba(0, 0, 0, 0.5),
      0 40px 90px rgba(0, 0, 0, 0.4);
    --shadow-card: 0 0 0 0.5px rgba(255, 255, 255, 0.1), 0 2px 8px rgba(0, 0, 0, 0.3);
    --shadow-chip: 0 0 0 0.5px rgba(255, 255, 255, 0.12), 0 8px 24px rgba(0, 0, 0, 0.5);
    --grime-tint: rgba(0, 0, 0, 0.3);
  }
}

:root[data-theme="dark"] {
  color-scheme: dark;
  --ground: #111113;
  --surface: #1c1c1e;
  --surface-2: #19191b;
  --ink: #f5f5f7;
  --ink-2: #c7c7cc;
  --ink-3: #a1a1a6;
  --hairline: rgba(255, 255, 255, 0.12);
  --fill: rgba(255, 255, 255, 0.07);
  --accent: #0a6fe0;
  --accent-ink: #ffffff;
  --accent-hover: #1f7ff0;
  --link: #57a9ff;
  --green: #32d74b;
  --green-deep: #32d74b;
  --green-soft: rgba(50, 215, 75, 0.14);
  --warn: #ffa626;
  --warn-soft: rgba(255, 166, 38, 0.14);
  --nav: rgba(17, 17, 19, 0.72);
  --shadow-window:
    0 0 0 0.5px rgba(255, 255, 255, 0.12), 0 12px 40px rgba(0, 0, 0, 0.5),
    0 40px 90px rgba(0, 0, 0, 0.4);
  --shadow-card: 0 0 0 0.5px rgba(255, 255, 255, 0.1), 0 2px 8px rgba(0, 0, 0, 0.3);
  --shadow-chip: 0 0 0 0.5px rgba(255, 255, 255, 0.12), 0 8px 24px rgba(0, 0, 0, 0.5);
  --grime-tint: rgba(0, 0, 0, 0.3);
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--ground);
  color: var(--ink);
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.5;
  letter-spacing: -0.011em;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}
a {
  color: var(--link);
  text-decoration: none;
}
a:hover {
  text-decoration: underline;
}
:focus-visible {
  outline: 3px solid var(--link);
  outline-offset: 3px;
  border-radius: 6px;
}

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

.skip {
  position: absolute;
  left: 16px;
  top: -48px;
  z-index: 50;
  padding: 8px 14px;
  border-radius: 8px;
  background: var(--surface);
  color: var(--ink);
  box-shadow: var(--shadow-card);
}
.skip:focus {
  top: 12px;
}

.wrap {
  width: 100%;
  max-width: calc(var(--page) + 2 * var(--gutter));
  margin: 0 auto;
  padding-inline: var(--gutter);
}

h1,
h2,
h3 {
  margin: 0;
  text-wrap: balance;
  letter-spacing: -0.03em;
}
h1 {
  font-size: clamp(44px, 7.4vw, 88px);
  line-height: 1.02;
  font-weight: 700;
}
h2 {
  font-size: clamp(34px, 5vw, 56px);
  line-height: 1.06;
  font-weight: 700;
}
h3 {
  font-size: 22px;
  line-height: 1.25;
  font-weight: 600;
  letter-spacing: -0.02em;
}
p {
  margin: 0;
}
.lede {
  font-size: clamp(19px, 2vw, 23px);
  line-height: 1.45;
  color: var(--ink-2);
  max-width: var(--measure);
  text-wrap: pretty;
}
.eyebrow {
  font-size: 15px;
  font-weight: 600;
  color: var(--green-deep);
  letter-spacing: 0;
}
.mono {
  font-family: var(--mono);
  letter-spacing: 0;
}
.tabular {
  font-variant-numeric: tabular-nums;
}

/* ---------- Nav ---------- */
.nav {
  position: sticky;
  top: env(safe-area-inset-top, 0px);
  z-index: 20;
  background: var(--nav);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 0.5px solid var(--hairline);
}
.nav-inner {
  display: flex;
  align-items: center;
  gap: 24px;
  height: var(--nav-h);
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  font-weight: 600;
  font-size: 17px;
}
.brand:hover {
  text-decoration: none;
}
.brand img {
  width: 26px;
  height: 26px;
}
.nav-links {
  display: flex;
  gap: 22px;
  margin-left: auto;
  font-size: 14px;
}
.nav-links a {
  color: var(--ink-2);
}
.nav-links a:hover {
  color: var(--ink);
  text-decoration: none;
}
@media (max-width: 720px) {
  .nav-links {
    display: none;
  }
  .nav-inner .btn {
    margin-left: auto;
  }
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 0 22px;
  border-radius: 980px;
  border: 0;
  font: inherit;
  font-size: 17px;
  font-weight: 500;
  cursor: pointer;
  transition:
    background-color 0.2s var(--ease),
    transform 0.2s var(--ease);
}
.btn:hover {
  text-decoration: none;
}
.btn:active {
  transform: scale(0.98);
}
.btn-primary {
  background: var(--accent);
  color: var(--accent-ink);
}
.btn-primary:hover {
  background: var(--accent-hover);
}
.btn-ghost {
  background: transparent;
  color: var(--link);
  padding-inline: 12px;
}
.btn-ghost:hover {
  text-decoration: underline;
}
.btn-sm {
  min-height: 32px;
  padding: 0 14px;
  font-size: 14px;
}
/* A link not live yet: says so instead of going nowhere. */
.is-soon {
  background: var(--fill) !important;
  color: var(--ink-3) !important;
  cursor: default;
  pointer-events: none;
}
.btn-ghost.is-soon {
  background: transparent !important;
}

/* ---------- Hero ---------- */
/* Narrow screens: centred copy with the drawing under it. Wide ones (below):
   the copy beside the drawing, so the whole hero fits one screen and the
   drawing gets the width. */
.hero {
  padding-block: clamp(48px, 7vw, 88px) 0;
  /* clip, not hidden: hidden makes the hero a scroll container, which stops the
     sticky pin from sticking. This only keeps swept chips from widening the page. */
  overflow-x: clip;
}
.hero-copy {
  text-align: center;
}
.hero h1 {
  font-size: clamp(44px, 6.6vw, 80px);
}
.hero .lede {
  margin: 24px auto 0;
}
.hero-ctas {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 12px 20px;
  margin-top: 36px;
}
.hero-meta {
  margin-top: 18px;
  font-size: 14px;
  color: var(--ink-3);
}
.visual {
  margin-top: clamp(32px, 4vw, 52px);
}

@media (min-width: 960px) and (min-aspect-ratio: 5/4) {
  .hero {
    padding-block: 0;
  }
  .hero-pin {
    display: grid;
    align-items: center;
    min-height: calc(100svh - var(--nav-h));
    padding-block: clamp(20px, 4vh, 48px);
  }
  .hero-grid {
    display: grid;
    grid-template-columns: minmax(300px, 520px) minmax(0, 1fr);
    align-items: center;
    gap: clamp(32px, 4vw, 72px);
    max-width: calc(1440px + 2 * var(--gutter));
  }
  .hero-copy {
    text-align: left;
  }
  /* Scaled by height as well, so a short laptop screen still fits it all. */
  .hero h1 {
    font-size: clamp(38px, min(4.2vw, 8vh), 62px);
  }
  .hero .lede {
    margin: 20px 0 0;
    font-size: clamp(17px, min(1.4vw, 2.6vh), 20px);
  }
  .hero-ctas {
    justify-content: flex-start;
    margin-top: clamp(20px, 4vh, 32px);
  }
  .visual {
    margin-top: 0;
  }
}

/* The headline word gets one pass of sweep light on load. */
.sheen {
  background: linear-gradient(
    100deg,
    var(--ink) 0%,
    var(--ink) 40%,
    var(--green) 50%,
    var(--ink) 60%,
    var(--ink) 100%
  );
  background-size: 250% 100%;
  background-position: 100% 0;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: sheen 1.6s 0.4s var(--ease) both;
}
@keyframes sheen {
  from {
    background-position: 100% 0;
  }
  to {
    background-position: 0% 0;
  }
}

/* Brightens as the sweep finishes (main.js sets --glow). */
.hero-arc {
  position: absolute;
  inset: -12% -8% auto -8%;
  height: 70%;
  z-index: 0;
  pointer-events: none;
  background: radial-gradient(60% 70% at 50% 100%, var(--green-soft), transparent 70%);
  opacity: var(--glow, 1);
}

/* ---------- Sections ---------- */
section {
  scroll-margin-top: 64px;
}
.section {
  padding-block: clamp(88px, 12vw, 150px);
}
.section-head {
  display: grid;
  gap: 20px;
  max-width: 760px;
}
.section-head.center {
  margin-inline: auto;
  text-align: center;
  justify-items: center;
}

/* ---------- Drawn app windows (.mock) ---------- */
/* Representative drawings of Sweep's screens, in HTML rather than screenshots:
   sharp at any size, in either theme, and free of anyone's machine names.
   Everything inside is in em, and the em follows the width of the nearest
   .mock-frame, so a drawing scales as one piece. */
.mock-frame {
  container-type: inline-size;
}
.sprite {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}
.mock {
  --m-window: #f5f5f7;
  --m-side: #ededf0;
  --m-card: #ffffff;
  --m-bar: #e8e8eb;
  --m-selected: rgba(0, 102, 204, 0.12);
  --m-track: rgba(0, 0, 0, 0.09);
  --m-hair: rgba(0, 0, 0, 0.08);
  --m-ink: #1d1d1f;
  --m-ink-2: #515154;
  --m-ink-3: #6e6e73;
  --m-accent: #0066cc;
  --m-button: #0066cc;
  --m-accent-soft: rgba(0, 102, 204, 0.1);
  --m-ok: #1f7a36;
  --m-ok-soft: rgba(48, 185, 77, 0.15);
  --m-danger: #d70015;
  --m-stripe: rgba(0, 0, 0, 0.025);
  --m-lift: 0 0 0 0.06em rgba(0, 0, 0, 0.06), 0 0.1em 0.3em rgba(0, 0, 0, 0.05);
  position: relative;
  display: grid;
  grid-template-rows: 2.3em minmax(0, 1fr);
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-radius: 0.8em;
  background: var(--m-window);
  box-shadow: var(--shadow-window);
  color: var(--m-ink);
  font-size: calc(100cqw / 56);
  line-height: 1.3;
  letter-spacing: -0.005em;
  text-align: left;
  user-select: none;
}
/* Dark with the page, or always (.is-dark), for the theme comparison. */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .mock {
    --m-window: #1c1c1e;
    --m-side: #161618;
    --m-card: #2a2a2d;
    --m-bar: #2a2a2d;
    --m-selected: rgba(10, 132, 255, 0.2);
    --m-track: rgba(255, 255, 255, 0.12);
    --m-hair: rgba(255, 255, 255, 0.08);
    --m-ink: #f5f5f7;
    --m-ink-2: #c7c7cc;
    --m-ink-3: #a1a1a6;
    --m-accent: #3b8eff;
    --m-button: #0a6fe0;
    --m-accent-soft: rgba(10, 132, 255, 0.18);
    --m-ok: #32d74b;
    --m-ok-soft: rgba(50, 215, 75, 0.16);
    --m-danger: #e5323f;
    --m-stripe: rgba(255, 255, 255, 0.03);
    --m-lift: 0 0 0 0.06em rgba(255, 255, 255, 0.06), 0 0.1em 0.3em rgba(0, 0, 0, 0.3);
  }
}
:root[data-theme="dark"] .mock,
:root .mock.is-dark {
  --m-window: #1c1c1e;
  --m-side: #161618;
  --m-card: #2a2a2d;
  --m-bar: #2a2a2d;
  --m-selected: rgba(10, 132, 255, 0.2);
  --m-track: rgba(255, 255, 255, 0.12);
  --m-hair: rgba(255, 255, 255, 0.08);
  --m-ink: #f5f5f7;
  --m-ink-2: #c7c7cc;
  --m-ink-3: #a1a1a6;
  --m-accent: #3b8eff;
  --m-button: #0a6fe0;
  --m-accent-soft: rgba(10, 132, 255, 0.18);
  --m-ok: #32d74b;
  --m-ok-soft: rgba(50, 215, 75, 0.16);
  --m-danger: #e5323f;
  --m-stripe: rgba(255, 255, 255, 0.03);
  --m-lift: 0 0 0 0.06em rgba(255, 255, 255, 0.06), 0 0.1em 0.3em rgba(0, 0, 0, 0.3);
}
:root .mock.is-light {
  --m-window: #f5f5f7;
  --m-side: #ededf0;
  --m-card: #ffffff;
  --m-bar: #e8e8eb;
  --m-selected: rgba(0, 102, 204, 0.12);
  --m-track: rgba(0, 0, 0, 0.09);
  --m-hair: rgba(0, 0, 0, 0.08);
  --m-ink: #1d1d1f;
  --m-ink-2: #515154;
  --m-ink-3: #6e6e73;
  --m-accent: #0066cc;
  --m-button: #0066cc;
  --m-accent-soft: rgba(0, 102, 204, 0.1);
  --m-ok: #1f7a36;
  --m-ok-soft: rgba(48, 185, 77, 0.15);
  --m-danger: #d70015;
  --m-stripe: rgba(0, 0, 0, 0.025);
  --m-lift: 0 0 0 0.06em rgba(0, 0, 0, 0.06), 0 0.1em 0.3em rgba(0, 0, 0, 0.05);
}

.m-i {
  flex-shrink: 0;
  width: 1.15em;
  height: 1.15em;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.m-bar {
  display: flex;
  align-items: center;
  gap: 0.55em;
  padding-left: 0.9em;
  background: var(--m-bar);
  font-size: 0.8em;
  color: var(--m-ink-2);
}
.m-bar img {
  width: 1.15em;
  height: 1.15em;
}
.m-caps {
  display: flex;
  height: 100%;
  margin-left: auto;
}
.m-caps span {
  display: grid;
  place-items: center;
  width: 3.6em;
  font-size: 0.85em;
  color: var(--m-ink-3);
}
.m-body {
  display: grid;
  grid-template-columns: 11.5em minmax(0, 1fr);
  min-height: 0;
}
.m-side {
  display: flex;
  flex-direction: column;
  gap: 0.15em;
  padding: 1em 0.7em;
  background: var(--m-side);
  border-right: 0.06em solid var(--m-hair);
}
.m-brand {
  display: flex;
  align-items: center;
  gap: 0.55em;
  padding: 0.2em 0.5em 1em;
  font-size: 0.95em;
  font-weight: 600;
}
.m-brand img {
  width: 1.55em;
  height: 1.55em;
}
.m-nav {
  display: flex;
  align-items: center;
  gap: 0.6em;
  padding: 0.45em 0.6em;
  border-radius: 0.45em;
  font-size: 0.88em;
}
.m-nav .m-i {
  color: var(--m-ink-2);
}
.m-nav.is-on {
  background: var(--m-selected);
  color: var(--m-accent);
  font-weight: 600;
}
.m-nav.is-on .m-i {
  color: inherit;
}
.m-count {
  margin-left: auto;
  font-size: 0.85em;
  font-weight: 400;
  color: var(--m-ink-3);
  font-variant-numeric: tabular-nums;
  transition: opacity 0.3s var(--ease);
}
.m-foot {
  margin-top: auto;
}
.m-main {
  display: flex;
  flex-direction: column;
  gap: 1em;
  min-width: 0;
  padding: 1.3em 1.6em;
}
.m-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1em;
}
.m-title {
  font-size: 1.7em;
  font-weight: 700;
  letter-spacing: -0.02em;
}
.m-muted {
  display: inline-flex;
  align-items: center;
  gap: 0.5em;
  font-size: 0.78em;
  color: var(--m-ink-3);
}
.m-card {
  border-radius: 0.7em;
  background: var(--m-card);
  box-shadow: var(--m-lift);
}
.m-tile {
  display: grid;
  flex-shrink: 0;
  place-items: center;
  width: 2.2em;
  height: 2.2em;
  border-radius: 0.5em;
  background: var(--m-track);
  color: var(--m-ink-2);
}
.m-tile.is-accent {
  background: var(--m-accent-soft);
  color: var(--m-accent);
}
.m-tile.is-ok {
  background: var(--m-ok-soft);
  color: var(--m-ok);
}
.m-stack {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: 0.15em;
  min-width: 0;
}
.m-label {
  font-size: 0.82em;
  font-weight: 500;
  color: var(--m-ink-2);
}
.m-detail {
  display: block;
  overflow: hidden;
  font-size: 0.78em;
  color: var(--m-ink-2);
  white-space: nowrap;
  text-overflow: ellipsis;
}
/* A caption with a figure at its far end ("8 cores"). */
.m-detail.is-split {
  display: flex;
  justify-content: space-between;
  gap: 0.6em;
}
.m-btn {
  display: inline-flex;
  flex-shrink: 0;
  align-items: center;
  padding: 0.55em 1.1em;
  border-radius: 0.45em;
  background: var(--m-card);
  box-shadow: 0 0 0 0.06em var(--m-hair);
  font-size: 0.85em;
  font-weight: 600;
  white-space: nowrap;
}
.m-btn.is-primary {
  background: var(--m-button);
  color: #ffffff;
  box-shadow: none;
}

/* The Overview's reclaimable card, and the calm state that follows a clean-up
   (the app's own words). main.js adds .is-clean at the end of the sweep. */
.m-hero {
  display: grid;
}
.m-state {
  display: flex;
  grid-area: 1 / 1;
  align-items: center;
  gap: 1em;
  padding: 1.2em 1.3em;
  transition: opacity 0.45s var(--ease);
}
.m-hero .m-tile {
  width: 3.2em;
  height: 3.2em;
  border-radius: 0.7em;
}
.m-hero .m-tile .m-i {
  width: 1.5em;
  height: 1.5em;
}
.m-big {
  font-size: 2.5em;
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: -0.03em;
  font-variant-numeric: tabular-nums;
}
.m-empty {
  font-size: 1.35em;
  font-weight: 600;
}
.m-after,
.mock.is-clean .m-before,
.mock.is-clean .m-count {
  opacity: 0;
}
.mock.is-clean .m-after {
  opacity: 1;
}

.m-cols {
  display: grid;
  grid-template-columns: minmax(0, 3fr) minmax(0, 2fr);
  gap: 1em;
}
.m-group {
  display: flex;
  flex-direction: column;
  gap: 0.45em;
  min-width: 0;
}
.m-sec {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  padding: 0 0.2em;
  font-size: 0.85em;
  font-weight: 600;
}
.m-sec .m-muted {
  font-size: 0.9em;
  font-weight: 400;
}
.m-row {
  display: flex;
  align-items: center;
  gap: 0.8em;
  padding: 0.62em 0.9em;
}
.m-row + .m-row {
  border-top: 0.06em solid var(--m-hair);
}
.m-row-main {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: 0.12em;
  min-width: 0;
}
.m-name {
  font-size: 0.9em;
  font-weight: 500;
}
.m-value {
  align-self: flex-start;
  margin-top: 0.1em;
  font-size: 0.88em;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.m-meter {
  display: block;
  height: 0.36em;
  margin-top: 0.3em;
  overflow: hidden;
  border-radius: 1em;
  background: var(--m-track);
}
.m-meter i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--m-accent);
}
.m-activity {
  display: flex;
  flex-direction: column;
  height: 100%;
}
.m-metric {
  display: flex;
  flex: 1;
  flex-direction: column;
  justify-content: center;
  gap: 0.3em;
  padding: 0.7em 1em;
}
.m-metric + .m-metric {
  border-top: 0.06em solid var(--m-hair);
}
.m-metric-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
}
.m-metric-head b {
  font-size: 1.3em;
  font-variant-numeric: tabular-nums;
}
.m-facts {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
.m-facts > span {
  display: flex;
  flex-direction: column;
  gap: 0.1em;
  padding: 0.6em 0.9em;
  font-size: 0.85em;
  font-weight: 500;
}
.m-facts > span + span {
  border-left: 0.06em solid var(--m-hair);
}
.m-facts i {
  font-size: 0.85em;
  font-style: normal;
  font-weight: 400;
  color: var(--m-ink-2);
}

/* Feature drawings sit in a narrower column, so their type is set larger. */
.mock.is-large {
  font-size: calc(100cqw / 48);
}
.mock.is-large .m-main {
  gap: 0.8em;
}
figure.art {
  margin: 0;
}
.m-sub {
  font-size: 0.8em;
  color: var(--m-ink-2);
}
.m-head .m-btn {
  align-self: center;
  gap: 0.45em;
}
.m-path {
  overflow: hidden;
  font-family: var(--mono);
  font-size: 0.72em;
  color: var(--m-ink-3);
  white-space: nowrap;
  text-overflow: ellipsis;
}
.m-row.is-cache {
  padding-block: 0.5em;
}
.m-row.is-cache .m-value {
  align-self: center;
  margin-top: 0;
}
.m-row.is-cache .m-btn {
  font-size: 0.78em;
  font-weight: 500;
}
.m-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1em;
}
.m-toolbar .m-sec {
  padding: 0;
}
.m-tools {
  display: flex;
  align-items: center;
  gap: 0.6em;
}
.m-seg {
  display: flex;
  gap: 0.1em;
  padding: 0.18em;
  border-radius: 0.5em;
  background: var(--m-track);
  font-size: 0.72em;
  white-space: nowrap;
}
.m-seg span {
  padding: 0.3em 0.75em;
  border-radius: 0.38em;
}
.m-seg .is-on {
  background: var(--m-card);
  box-shadow: var(--m-lift);
  font-weight: 500;
}
.m-seg i {
  font-style: normal;
  color: var(--m-ink-3);
}
.m-search {
  display: flex;
  align-items: center;
  gap: 0.5em;
  width: 13em;
  padding: 0.4em 0.7em;
  border-radius: 0.45em;
  background: var(--m-track);
  font-size: 0.75em;
  color: var(--m-ink-3);
}
.m-search .m-i {
  width: 1.1em;
  height: 1.1em;
}

/* The process table: zebra rows, figures right-aligned, End Task on hover. */
.m-table {
  overflow: hidden;
  font-size: 0.82em;
}
.m-tr {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 4.5em 3.5em 5em 6.5em;
  align-items: center;
  gap: 0.8em;
  min-height: 2.3em;
  padding: 0 1em;
}
.m-tr > :nth-child(n + 2) {
  text-align: right;
  font-variant-numeric: tabular-nums;
}
.m-tr:nth-child(odd):not(.is-head) {
  background: var(--m-stripe);
}
.m-tr.is-head {
  min-height: 2em;
  border-bottom: 0.06em solid var(--m-hair);
  font-size: 0.85em;
  font-weight: 500;
  color: var(--m-ink-2);
}
.m-tr.is-hover {
  background: var(--m-selected);
}
.m-tr .m-btn {
  justify-self: end;
  padding: 0.3em 0.8em;
  font-size: 0.9em;
  font-weight: 500;
}

/* The preview sheet over a dimmed Clean Up screen. */
.m-scrim {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: rgba(0, 0, 0, 0.2);
}
.m-sheet {
  position: absolute;
  top: 55%;
  left: 55%;
  z-index: 2;
  display: flex;
  flex-direction: column;
  gap: 0.7em;
  width: 32em;
  padding: 1.2em 1.3em 1.1em;
  border-radius: 0.9em;
  background: var(--m-card);
  box-shadow:
    0 0 0 0.05em var(--m-hair),
    0 1.2em 3em rgba(0, 0, 0, 0.25);
  transform: translate(-50%, -50%);
}
.m-sheet-head {
  display: flex;
  align-items: center;
  gap: 0.8em;
}
.m-sheet-title {
  font-size: 1.15em;
  font-weight: 600;
}
.m-list {
  border-radius: 0.55em;
  box-shadow: 0 0 0 0.06em var(--m-hair);
}
.m-check-row {
  display: flex;
  align-items: center;
  gap: 0.7em;
  padding: 0.45em 0.8em;
  font-size: 0.85em;
}
.m-check-row + .m-check-row {
  border-top: 0.06em solid var(--m-hair);
}
.m-check-row.is-all {
  padding-inline: 0.2em;
  font-weight: 500;
}
.m-check-row .m-i {
  width: 1.1em;
  height: 1.1em;
  color: var(--m-ink-3);
}
.m-check-row .m-path {
  flex: 1;
  font-size: 0.85em;
  color: var(--m-ink);
}
.m-check-row .m-value {
  margin: 0 0 0 auto;
  align-self: center;
}
/* A ticked box, drawn: the tick is two borders of a turned rectangle. */
.m-check {
  display: grid;
  flex-shrink: 0;
  place-items: center;
  width: 1.15em;
  height: 1.15em;
  border-radius: 0.3em;
  background: var(--m-button);
}
.m-check::after {
  content: "";
  width: 0.55em;
  height: 0.28em;
  border-bottom: 0.14em solid #ffffff;
  border-left: 0.14em solid #ffffff;
  transform: translateY(-0.06em) rotate(-45deg);
}
.m-sheet-foot {
  display: flex;
  align-items: center;
  gap: 0.6em;
  margin-top: 0.2em;
}
.m-sheet-foot .m-muted {
  margin-right: auto;
}
.m-btn.is-danger {
  background: var(--m-danger);
  color: #ffffff;
  box-shadow: none;
}

/* A small frame gets a phone-sized drawing: no sidebar, one drive, bigger type. */
@container (max-width: 520px) {
  .mock {
    aspect-ratio: 10 / 7;
    font-size: calc(100cqw / 30);
  }
  .m-body {
    grid-template-columns: minmax(0, 1fr);
  }
  .m-main {
    gap: 0.8em;
    padding: 1em 1.1em;
  }
  .m-cols {
    grid-template-columns: minmax(0, 1fr);
  }
  .m-side,
  .m-muted,
  .m-hero .m-btn,
  .m-cols .m-group + .m-group,
  .m-cols .m-row + .m-row {
    display: none;
  }
  .m-sheet {
    width: 92%;
  }
  /* Feature drawings keep their shape; only their sidebar goes. */
  .mock.is-large {
    aspect-ratio: 16 / 9;
  }
}

/* ---------- The sweep (hero) ---------- */
/* The still (no JavaScript, reduced motion, a short window) shows the drawing as
   it is and two lines under it. The scroll-driven version (.is-scrolly, set by
   main.js) pins it, strews the scan's caches over it, and sweeps them off. */
.stage {
  position: relative;
  width: min(960px, 100%);
  margin-inline: auto;
}
.caption {
  display: grid;
  justify-items: center;
  gap: 6px;
  margin-top: clamp(14px, 2.4vh, 24px);
  text-align: center;
}
.beats {
  display: grid;
  gap: 2px;
}
.beat {
  font-size: clamp(17px, 1.5vw, 21px);
  font-weight: 600;
  letter-spacing: -0.015em;
  text-wrap: balance;
}
.beat[data-beat="2"] {
  color: var(--ink-2);
}
.beat[data-beat="3"] {
  display: none;
}
.caption-note {
  font-size: 13px;
  color: var(--ink-3);
}

.debris {
  margin: 0;
  padding: 0;
  list-style: none;
}
.sweep-cue,
.broom,
.debris,
.m-grime {
  display: none;
}

/* Wide: the drawing as big as the screen's height allows beside the copy. */
@media (min-width: 960px) and (min-aspect-ratio: 5/4) {
  .stage {
    width: min(100%, calc((100svh - var(--nav-h) - 170px) * 1.78));
  }
}

/* Scroll-driven. The track (the hero when wide, else the drawing's column) is
   one pinned screen plus one screen of travel. */
.hero.is-scrolly.is-wide {
  height: calc(200svh - var(--nav-h));
}
.is-scrolly.is-wide .hero-pin {
  position: sticky;
  top: var(--nav-h);
  height: calc(100svh - var(--nav-h));
  min-height: 0;
}
/* Narrow: the pin is only as tall as the drawing and its caption, so nothing
   pushes the drawing down on arrival; main.js measures it (--pin-h) and
   centres it while stuck (--pin-top). */
.is-scrolly:not(.is-wide) .visual {
  height: calc(var(--pin-h, 60svh) + 100svh);
}
.is-scrolly:not(.is-wide) .visual-pin {
  position: sticky;
  top: var(--pin-top, var(--nav-h));
}
.is-scrolly:not(.is-wide) .stage {
  width: min(960px, 100%, max(300px, calc((100svh - var(--nav-h) - 150px) * 1.78)));
}
.is-scrolly .beats > * {
  grid-area: 1 / 1;
}
.is-scrolly .beat[data-beat] {
  display: block;
  color: var(--ink);
}

/* The caches, strewn over the drawing. main.js moves each one off as the
   broom's head passes it; until then they sit where --x and --y put them. */
.is-scrolly .debris {
  display: block;
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
}
.debris li {
  position: absolute;
  top: var(--y);
  left: var(--x);
  display: inline-flex;
  align-items: baseline;
  gap: 0.75em;
  padding: 0.7em 1em;
  border-radius: 0.8em;
  background: var(--surface);
  box-shadow: var(--shadow-chip);
  font-size: calc(100cqw / 62);
  line-height: 1.3;
  white-space: nowrap;
  transform: translate(-50%, -50%) rotate(var(--r)) scale(var(--s));
  will-change: transform, opacity;
}
.debris .mono {
  font-size: 0.93em;
  color: var(--ink-2);
}
.debris strong {
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}

/* Dust over the drawing, wiped away behind the broom: its mask slides right
   with the broom's head (--wipe). */
.is-scrolly .m-grime {
  display: block;
  position: absolute;
  inset: 2.3em 0 0 0;
  z-index: 3;
  pointer-events: none;
  background: var(--grime-tint);
  -webkit-backdrop-filter: grayscale(0.85) blur(1.5px) brightness(0.97);
  backdrop-filter: grayscale(0.85) blur(1.5px) brightness(0.97);
  -webkit-mask: linear-gradient(100deg, transparent 38%, #000 52%) var(--wipe, 100%) 0 /
    260% 100% no-repeat;
  mask: linear-gradient(100deg, transparent 38%, #000 52%) var(--wipe, 100%) 0 / 260% 100%
    no-repeat;
}

/* The broom overhangs the drawing by 6% a side, so its stroke enters and leaves
   off-frame. main.js draws it with stroke-dashoffset. */
.is-scrolly .broom {
  display: block;
  position: absolute;
  top: -8%;
  left: -6%;
  z-index: 3;
  width: 112%;
  height: 116%;
  pointer-events: none;
}
.broom path {
  fill: none;
  stroke: url(#broomGradient);
  stroke-width: 30;
  stroke-linecap: round;
  filter: drop-shadow(0 0 14px var(--green-soft));
}

.is-scrolly .sweep-cue {
  display: inline-flex;
  position: absolute;
  top: 36%;
  left: 50%;
  z-index: 4;
  align-items: center;
  gap: 8px;
  padding: 9px 14px 9px 18px;
  border-radius: 980px;
  background: var(--ink);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.22);
  color: var(--ground);
  font-size: 15px;
  font-weight: 600;
  transform: translate(-50%, -50%);
  pointer-events: none;
}
.sweep-cue svg {
  width: 16px;
  height: 16px;
  animation: nudge 1.6s var(--ease) infinite;
}
@keyframes nudge {
  0%,
  100% {
    transform: translateY(-1px);
  }
  50% {
    transform: translateY(3px);
  }
}

/* A phone: fewer, smaller chips, kept inside the frame rather than cut off by
   the screen edge. */
@container (max-width: 520px) {
  .debris li {
    left: clamp(24%, var(--x), 76%);
    font-size: calc(100cqw / 36);
  }
  .debris .sub {
    display: none;
  }
}
@media (max-width: 700px) {
  .is-scrolly .sweep-cue {
    padding: 7px 11px 7px 14px;
    font-size: 13px;
  }
}

/* ---------- Feature rows ---------- */
.feature {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: clamp(32px, 6vw, 80px);
  align-items: center;
}
.feature + .feature {
  margin-top: clamp(88px, 12vw, 140px);
}
.feature.flip {
  grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
}
.feature.flip .feature-copy {
  order: 2;
}
.feature-copy {
  display: grid;
  gap: 18px;
}
.feature-copy p {
  color: var(--ink-2);
  font-size: 19px;
  max-width: 46ch;
}
.ticks {
  list-style: none;
  margin: 8px 0 0;
  padding: 0;
  display: grid;
  gap: 10px;
  color: var(--ink-2);
}
.ticks li {
  display: grid;
  grid-template-columns: 20px 1fr;
  gap: 10px;
  align-items: baseline;
}
.ticks li::before {
  content: "";
  width: 8px;
  height: 8px;
  margin-top: 8px;
  border-radius: 50%;
  background: var(--green);
}
@media (max-width: 860px) {
  .feature,
  .feature.flip {
    grid-template-columns: minmax(0, 1fr);
  }
  .feature.flip .feature-copy {
    order: 0;
  }
}

.recover {
  display: grid;
  gap: 12px;
  margin-top: 8px;
}
.recover-row {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 4px 14px;
  align-items: baseline;
  padding: 14px 16px;
  border-radius: 12px;
  background: var(--surface);
  box-shadow: var(--shadow-card);
}
.tag {
  font-size: 13px;
  font-weight: 600;
  padding: 3px 8px;
  border-radius: 4px;
  background: var(--fill);
  color: var(--ink-2);
  white-space: nowrap;
}
.tag.warn {
  background: var(--warn-soft);
  color: var(--warn);
}
.recover-row p {
  font-size: 15px;
  color: var(--ink-2);
}

/* ---------- Careful by design ---------- */
.careful {
  background: var(--surface);
}
.grid-6 {
  margin-top: 56px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}
@media (max-width: 900px) {
  .grid-6 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 560px) {
  .grid-6 {
    grid-template-columns: minmax(0, 1fr);
  }
}
.card {
  padding: 26px;
  border-radius: 18px;
  background: var(--surface-2);
  box-shadow: var(--shadow-card);
  display: grid;
  gap: 10px;
  align-content: start;
}
.card svg {
  width: 26px;
  height: 26px;
  color: var(--green-deep);
}
.card p {
  color: var(--ink-2);
  font-size: 16px;
}

/* ---------- Themes ---------- */
/* The app's own appearance choice (System, Light, Dark), switching this page. */
.theme-try {
  display: grid;
  justify-items: center;
  gap: 10px;
}
.theme-try[hidden] {
  display: none;
}
.segmented {
  display: inline-flex;
  gap: 2px;
  margin: 0;
  padding: 3px;
  border: 0;
  border-radius: 980px;
  background: var(--fill);
}
.segmented label {
  position: relative;
}
/* The real radio covers its label: native arrow keys, clicks and focus. */
.segmented input {
  position: absolute;
  inset: 0;
  margin: 0;
  opacity: 0;
  cursor: pointer;
}
.segmented span {
  display: block;
  padding: 7px 20px;
  border-radius: 980px;
  font-size: 15px;
  font-weight: 500;
  color: var(--ink-2);
  transition:
    background-color 0.2s var(--ease),
    color 0.2s var(--ease);
}
.segmented input:checked + span {
  background: var(--surface);
  color: var(--ink);
  box-shadow: var(--shadow-card);
}
.segmented input:focus-visible + span {
  outline: 3px solid var(--link);
  outline-offset: 2px;
}
.theme-hint {
  font-size: 14px;
  color: var(--ink-3);
}

/* Both themes at once: the chosen one in front, the other behind it. Each
   drawing is fixed to its theme (.is-light, .is-dark), whatever the page's. */
.theme-stack {
  display: grid;
  max-width: 1000px;
  margin: 48px auto 0;
  padding-bottom: 6%;
}
.theme-stack > figure {
  grid-area: 1 / 1;
  width: 90%;
  margin: 0;
  transition:
    transform 0.6s var(--ease),
    filter 0.6s var(--ease);
}
/* Light in front unless the page is dark. */
.theme-stack .theme-light,
:root[data-theme="dark"] .theme-stack .theme-dark {
  z-index: 1;
  transform: none;
  filter: none;
}
.theme-stack .theme-dark,
:root[data-theme="dark"] .theme-stack .theme-light {
  z-index: 0;
  transform: translate(11%, 9%) scale(0.94);
  filter: brightness(0.97);
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .theme-stack .theme-dark {
    z-index: 1;
    transform: none;
    filter: none;
  }
  :root:not([data-theme="light"]) .theme-stack .theme-light {
    z-index: 0;
    transform: translate(11%, 9%) scale(0.94);
    filter: brightness(0.97);
  }
}

/* ---------- Keys ---------- */
.keys {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px 28px;
  margin-top: 44px;
}
.key-pair {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--ink-2);
  font-size: 15px;
}
kbd {
  display: inline-grid;
  place-items: center;
  min-width: 34px;
  height: 34px;
  padding: 0 9px;
  border-radius: 8px;
  background: var(--surface);
  box-shadow:
    var(--shadow-card),
    inset 0 -2px 0 var(--hairline);
  font-family: var(--font);
  font-size: 14px;
  font-weight: 500;
  color: var(--ink);
}

/* ---------- Pricing ---------- */
.price-card {
  margin: 56px auto 0;
  max-width: 520px;
  padding: clamp(28px, 5vw, 44px);
  border-radius: 28px;
  background: var(--surface);
  box-shadow: var(--shadow-window);
  display: grid;
  gap: 22px;
  text-align: center;
  justify-items: center;
}
.price {
  font-size: 72px;
  font-weight: 700;
  letter-spacing: -0.04em;
  line-height: 1;
}
.price small {
  font-size: 20px;
  font-weight: 500;
  color: var(--ink-3);
  letter-spacing: 0;
}
.price-card .ticks {
  text-align: left;
}
.price-ctas {
  margin-top: 0;
}
.price-note {
  font-size: 13px;
  color: var(--ink-3);
  max-width: 40ch;
}

/* ---------- FAQ ---------- */
.faq {
  margin-top: 48px;
  max-width: 820px;
  border-top: 0.5px solid var(--hairline);
}
.faq details {
  border-bottom: 0.5px solid var(--hairline);
}
.faq summary {
  list-style: none;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 22px 4px;
  font-size: 19px;
  font-weight: 600;
  letter-spacing: -0.015em;
}
.faq summary::-webkit-details-marker {
  display: none;
}
.faq summary::after {
  content: "+";
  font-weight: 400;
  font-size: 24px;
  line-height: 1;
  color: var(--ink-3);
  transition: transform 0.25s var(--ease);
}
.faq details[open] summary::after {
  transform: rotate(45deg);
}
.faq details p {
  padding: 0 4px 22px;
  color: var(--ink-2);
  max-width: var(--measure);
}

/* ---------- Footer ---------- */
.footer {
  padding-block: 48px 64px;
  border-top: 0.5px solid var(--hairline);
  font-size: 13px;
  color: var(--ink-3);
}
.footer-inner {
  display: flex;
  flex-wrap: wrap;
  gap: 16px 32px;
  align-items: center;
  justify-content: space-between;
}
.footer .brand {
  font-size: 15px;
}

/* ---------- Motion ---------- */
/* Scroll-linked rise where supported; content is always visible at rest. */
@supports (animation-timeline: view()) {
  /* Finishes once the element has fully entered, so nothing rests half-faded. */
  .rise {
    animation: rise linear both;
    animation-timeline: view();
    animation-range: entry 0% entry 100%;
  }
  @keyframes rise {
    from {
      opacity: 0.6;
      transform: translateY(24px);
    }
    to {
      opacity: 1;
      transform: none;
    }
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }
  .sheen {
    color: var(--ink);
    background: none;
  }
}

/* Download facts (WU-7.2): the honest unsigned-build note, checksum and scan. */
.download-facts {
  max-width: var(--measure);
  margin: 40px auto 0;
  padding: 24px;
  border-radius: 16px;
  background: var(--surface);
  box-shadow: var(--shadow-card);
  color: var(--ink-2);
}

.download-facts h3 {
  margin: 0 0 8px;
  color: var(--ink);
  font-size: 17px;
}

.download-facts p {
  margin: 0 0 12px;
}

.download-facts dl {
  display: grid;
  grid-template-columns: max-content 1fr;
  gap: 8px 16px;
  margin: 16px 0 0;
}

.download-facts dt {
  color: var(--ink);
  font-weight: 600;
}

.download-facts dd {
  margin: 0;
  min-width: 0;
}

.download-facts code {
  font-family: var(--mono);
  font-size: 13px;
  overflow-wrap: anywhere;
}

@media (max-width: 560px) {
  .download-facts dl {
    grid-template-columns: 1fr;
  }
}

/* ---------- Legal page (legal.html, generated from legal/*.txt) ---------- */
.legal {
  max-width: calc(760px + 2 * var(--gutter));
  padding-block: clamp(48px, 7vw, 88px) clamp(64px, 9vw, 120px);
}
.legal h1 {
  font-size: clamp(36px, 5vw, 52px);
}
.legal .lede {
  margin-top: 16px;
}
.legal section {
  margin-top: 56px;
  scroll-margin-top: 72px;
}
.legal h2 {
  font-size: clamp(26px, 3vw, 32px);
}
.legal-text {
  margin-top: 8px;
  color: var(--ink-2);
}
.legal-text h3 {
  margin-top: 28px;
  font-size: 18px;
  color: var(--ink);
}
.legal-text p,
.legal-text ul {
  margin: 12px 0 0;
}
.legal-text ul {
  padding-left: 22px;
}
.legal-updated {
  font-size: 14px;
  color: var(--ink-3);
}
.legal section > p {
  margin-top: 12px;
  color: var(--ink-2);
}
.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
}
