/* Workings launch site. Palette, type and logo from docs/site/BRIEF.md. */

:root {
  --paper: #f6f1e7;
  --surface: #fbf8f2;
  --sunken: #ece5d7;
  --ink: #1f1b16;
  --ink-muted: #5e554a;
  --line: #ddd3c2;
  --accent: #c8371c;
  --accent-ink: #a62b13;
  --on-accent: #fffaf3;
  --pencil: #8a857c;
  --shadow-sheet: 0 1px 2px rgb(31 27 22 / 0.08), 0 18px 40px -18px rgb(31 27 22 / 0.28);

  --font-display: "Fraunces", "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, serif;
  --font-body: "Instrument Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --ease: cubic-bezier(0.2, 0, 0, 1);
  --gutter: clamp(1rem, 4vw, 2.5rem);
  --rhythm: clamp(5rem, 10vw, 9rem);
  --header-h: 4.5rem;
}

@media (prefers-color-scheme: dark) {
  :root {
    --paper: #171512;
    --surface: #201d19;
    --sunken: #110f0d;
    --ink: #efe8db;
    --ink-muted: #b0a593;
    --line: #38322b;
    --accent: #f0603f;
    --accent-ink: #ff8466;
    --on-accent: #1a0e0a;
    --pencil: #8f877b;
    --shadow-sheet: 0 1px 2px rgb(0 0 0 / 0.4), 0 18px 40px -18px rgb(0 0 0 / 0.7);
  }
}

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

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

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.6;
  overflow-x: clip;
}

h1,
h2,
h3,
p,
ol,
ul,
figure {
  margin: 0;
}

ol,
ul {
  padding: 0;
  list-style: none;
}

svg {
  display: block;
}

a {
  color: var(--accent-ink);
}

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

main:focus {
  outline: none;
}

section[id] {
  scroll-margin-top: var(--header-h);
}

.sprite {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

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

.skip-link {
  position: absolute;
  top: 0.5rem;
  left: 0.5rem;
  z-index: 100;
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 1rem;
  background: var(--ink);
  color: var(--paper);
  font-weight: 600;
  border-radius: 4px;
  transform: translateY(-200%);
}

.skip-link:focus-visible {
  transform: none;
}

.wrap {
  width: min(72rem, 100% - 2 * var(--gutter));
  margin-inline: auto;
}

/* ---------- Type ---------- */

.headline,
.section-heading,
.close__heading {
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: -0.03em;
  line-height: 1.02;
  font-variation-settings:
    "opsz" 144,
    "SOFT" 50;
  text-wrap: balance;
}

.headline {
  font-size: clamp(3rem, 1.8rem + 6vw, 7rem);
}

.section-heading {
  font-size: clamp(2rem, 1.4rem + 2.6vw, 3.25rem);
  line-height: 1.08;
}

.item-title {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.375rem;
  line-height: 1.25;
  letter-spacing: -0.01em;
}

.label,
.eyebrow {
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.75rem;
  line-height: 1.4;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--ink-muted);
}

.eyebrow {
  margin-bottom: 0.75rem;
}

p {
  max-width: 38rem;
}

/* ---------- Buttons and links ---------- */

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  min-width: 44px;
  padding: 0 1.5rem;
  border-radius: 4px;
  font: 600 1rem / 1 var(--font-body);
  white-space: nowrap;
  text-decoration: none;
  cursor: pointer;
  transition:
    transform 160ms var(--ease),
    opacity 160ms var(--ease);
}

.button--primary {
  min-height: 52px;
  background: var(--accent);
  color: var(--on-accent);
  border: 0;
}

.button--primary:hover {
  transform: translateY(-1px);
}

.button--primary:active {
  transform: translateY(0);
}

.button--small {
  min-height: 44px;
  padding: 0 1.125rem;
  font-size: 0.9375rem;
}

.button--large {
  min-height: 56px;
  padding: 0 2rem;
  font-size: 1.0625rem;
}

.button--outline {
  background: var(--surface);
  color: var(--ink);
  border: 1px solid var(--line);
  padding: 0 1rem;
  font-size: 0.9375rem;
}

.button--outline[aria-disabled="true"] {
  opacity: 0.45;
  cursor: default;
}

.text-link {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: var(--accent-ink);
  font-weight: 600;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 4px;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: color-mix(in srgb, var(--paper) 85%, transparent);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}

.js .site-header:not(.is-scrolled) {
  border-bottom-color: transparent;
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  width: min(72rem, 100% - 2 * var(--gutter));
  min-height: var(--header-h);
  margin-inline: auto;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  min-height: 44px;
  color: var(--ink);
  text-decoration: none;
}

.brand__mark {
  width: 28px;
  height: 28px;
  flex: none;
}

.brand__word {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.25rem;
  letter-spacing: -0.02em;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.site-nav__links {
  display: flex;
  gap: 0.25rem;
  margin-right: 0.75rem;
}

.site-nav__links a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 0.75rem;
  color: var(--ink);
  font-size: 0.9375rem;
  font-weight: 500;
  text-decoration: none;
  border-radius: 4px;
}

.site-nav__links a:hover {
  color: var(--accent-ink);
}

@media (max-width: 719.98px) {
  .site-nav__links {
    display: none;
  }
}

@media (max-width: 359.98px) {
  .site-header .button--small {
    padding: 0 0.75rem;
    font-size: 0.875rem;
  }
}

/* ---------- Artwork frames ---------- */

.frame {
  position: relative;
  aspect-ratio: 4 / 3;
  border-radius: 8px;
  border: 1px solid var(--line);
  box-shadow: var(--shadow-sheet);
  background: var(--sunken);
  overflow: hidden;
}

.frame > svg {
  width: 100%;
  height: 100%;
}

/* ---------- Main rhythm ---------- */

main > section + section {
  margin-top: var(--rhythm);
}

/* ---------- 1. Hero ---------- */

.hero__inner {
  width: min(72rem, 100% - 2 * var(--gutter));
  margin-inline: auto;
  display: grid;
  gap: 2.5rem;
  padding-top: clamp(2rem, 6vw, 3rem);
}

.hero__sub {
  margin-top: 1.5rem;
  max-width: 32rem;
  font-size: 1.25rem;
  line-height: 1.5;
  color: var(--ink-muted);
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem 1.5rem;
  margin-top: 2rem;
}

.small-print {
  margin-top: 1rem;
  font-size: 0.875rem;
  color: var(--ink-muted);
}

@media (min-width: 960px) {
  .hero__inner {
    grid-template-columns: repeat(12, minmax(0, 1fr));
    align-items: center;
    min-height: min(88vh, 860px);
    padding-block: 2rem;
  }

  .hero__text {
    grid-column: 1 / span 5;
  }

  .hero__art {
    grid-column: 6 / span 7;
  }

  .hero .headline {
    font-size: clamp(3rem, 0.6rem + 5.2vw, 7rem);
  }
}

/* The sheet pile: the front sheet sits in flow, the earlier stages fan out behind it. */

.pile {
  --step: 18px;
  --turn: -1.5deg;
  --depth: 4;
  position: relative;
  padding-left: calc(var(--step) * var(--depth));
  padding-top: calc(var(--step) * (var(--depth) + 1) + 10.5%);
}

.pile .sheet {
  position: absolute;
  top: calc(var(--step) * (var(--depth) + 1) + 10.5%);
  left: calc(var(--step) * var(--depth));
  right: 0;
  transform-origin: 0 0;
  transform: translate(calc(var(--step) * var(--d) * -1), calc(var(--step) * var(--d) * -1))
    rotate(calc(var(--turn) * var(--d)));
}

.pile .sheet--front {
  position: relative;
  top: auto;
  left: auto;
  right: auto;
}

.sheet__drift {
  position: relative;
}

.pile .frame {
  background: var(--sunken);
}

.tab {
  position: absolute;
  bottom: 100%;
  left: 12px;
  z-index: 1;
  height: 18px;
  padding: 0 8px;
  border: 1px solid var(--line);
  border-bottom: 0;
  border-radius: 4px 4px 0 0;
  background: var(--surface);
  font-weight: 600;
  font-size: 0.75rem;
  line-height: 17px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-muted);
  white-space: nowrap;
}

@media (max-width: 959.98px) {
  .pile--hero {
    --step: 9px;
    --turn: -0.75deg;
    padding-top: calc(18px + 9px * 4 + 5.5%);
  }

  .pile--hero .sheet:not(.sheet--front) {
    top: calc(18px + 9px * 4 + 5.5%);
  }

  /* With 9 px steps five tabs would collide, so phones label only the back and front sheets. */
  .pile--hero .sheet:nth-child(n + 2):not(.sheet--front) .tab {
    display: none;
  }

  .pile--hero .sheet--front .tab {
    left: auto;
    right: 12px;
  }
}

@media (prefers-reduced-motion: no-preference) {
  .pile--hero .sheet {
    animation: deal 600ms var(--ease) backwards;
    animation-delay: calc((4 - var(--d)) * 60ms);
  }
}

@keyframes deal {
  from {
    transform: none;
  }
}

/* ---------- 2. The redraw ---------- */

.redraw__intro {
  text-align: center;
}

.redraw__intro p {
  max-width: 34rem;
  margin: 1.25rem auto 0;
  color: var(--ink-muted);
}

.redraw__track {
  width: min(72rem, 100% - 2 * var(--gutter));
  margin: clamp(2.5rem, 5vw, 4rem) auto 0;
}

/* Base: a plain sequence of five figures (no JavaScript, or reduced motion). */

.redraw__figures {
  display: grid;
  gap: 2.5rem 2rem;
}

.redraw__caption {
  display: grid;
  gap: 0.375rem;
  margin-top: 1rem;
}

.redraw__note {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: 1.25rem;
  line-height: 1.35;
  color: var(--ink);
  max-width: 30rem;
}

.rail {
  display: none;
}

@media (min-width: 720px) {
  .redraw__figures {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .redraw__item:last-child {
    grid-column: 1 / -1;
  }
}

/* Live: pinned, the picture rebuilds under the scroll. main.js adds .redraw--live. */

.redraw--live .redraw__track {
  width: 100%;
  height: 500vh;
  margin-top: 0;
}

.redraw--live .redraw__stage {
  position: sticky;
  top: 0;
  height: 100vh;
  height: 100svh;
  width: min(72rem, 100% - 2 * var(--gutter));
  margin-inline: auto;
  padding: calc(var(--header-h) + 1.5rem) 0 2rem;
  display: grid;
  grid-template-columns: minmax(0, 58fr) minmax(0, 42fr);
  grid-template-rows: 1fr auto auto 1fr;
  grid-template-areas:
    "art ."
    "art cap"
    "art rail"
    "art .";
  column-gap: clamp(2rem, 5vw, 4.5rem);
  align-items: center;
}

.redraw--live .redraw__figures,
.redraw--live .redraw__item,
.redraw--live .redraw__figure {
  display: contents;
}

.redraw--live .redraw__frame {
  grid-area: art;
  width: min(100%, calc((100svh - var(--header-h) - 4rem) * 4 / 3));
  justify-self: center;
}

.redraw--live .redraw__item:not(:first-child) .redraw__frame {
  background: transparent;
  border-color: transparent;
  box-shadow: none;
}

.redraw--live [data-stage="1"] .redraw__frame {
  opacity: var(--a1, 0);
}

.redraw--live [data-stage="2"] .redraw__frame {
  --paper-o: var(--a2, 0);
  --draw: calc(1 - var(--a2, 0));
}

.redraw--live [data-stage="3"] .redraw__frame {
  clip-path: inset(calc((1 - var(--a3, 0)) * 100%) 0 0 0 round 8px);
}

.redraw--live [data-stage="4"] .redraw__frame {
  opacity: var(--a4, 0);
}

.redraw--live .redraw__caption {
  grid-area: cap;
  align-self: end;
  margin: 0;
  gap: 1rem;
  opacity: 0;
  transform: translateY(8px);
  transition:
    opacity 220ms var(--ease),
    transform 220ms var(--ease);
  pointer-events: none;
}

.redraw--live [data-state="before"] .redraw__caption {
  transform: translateY(-8px);
}

.redraw--live [data-state="current"] .redraw__caption {
  opacity: 1;
  transform: none;
}

.redraw--live .redraw__note {
  font-size: clamp(1.5rem, 1rem + 1.6vw, 2.25rem);
  line-height: 1.25;
  max-width: 18rem;
}

.redraw--live .rail {
  grid-area: rail;
  align-self: start;
  display: flex;
  gap: 6px;
  margin-top: 1.5rem;
  max-width: 18rem;
}

.rail__step {
  flex: 1;
  min-width: 44px;
  height: 44px;
  padding: 0;
  border: 0;
  background: none;
  cursor: pointer;
  position: relative;
}

.rail__step::before {
  content: "";
  position: absolute;
  inset: 50% 0 auto;
  height: 3px;
  margin-top: -1.5px;
  border-radius: 2px;
  background: var(--line);
}

.rail__step.is-done::before {
  background: var(--accent);
}

@media (max-width: 959.98px) {
  .redraw--live .redraw__track {
    height: 400vh;
  }

  .redraw--live .redraw__stage {
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: auto auto auto;
    grid-template-areas:
      "art"
      "cap"
      "rail";
    align-content: center;
    padding: calc(var(--header-h) + 0.75rem) 0 1rem;
  }

  .redraw--live .redraw__frame {
    width: min(100%, calc((100svh - var(--header-h) - 16rem) * 4 / 3));
  }

  .redraw--live .redraw__caption {
    align-self: start;
    margin-top: 1.25rem;
    gap: 0.5rem;
  }

  .redraw--live .redraw__note {
    max-width: 24rem;
  }

  .redraw--live .rail {
    max-width: none;
    margin-top: 0.75rem;
  }
}

@media (max-width: 959.98px) and (max-height: 639.98px) {
  .redraw--live .redraw__note {
    font-size: 1.25rem;
  }
}

/* ---------- 3. How it works ---------- */

.how {
  display: grid;
  gap: 2.5rem;
}

.steps {
  display: grid;
}

.step {
  padding-block: 1.75rem;
  border-top: 1px solid var(--line);
}

.step:first-child {
  border-top: 0;
  padding-top: 0;
}

.step__thumb {
  width: 72px;
  height: 54px;
  border-radius: 4px;
  margin-bottom: 1.25rem;
}

.step p {
  margin-top: 0.5rem;
  color: var(--ink-muted);
}

@media (min-width: 960px) {
  .how {
    grid-template-columns: minmax(0, 4fr) minmax(0, 8fr);
    align-items: start;
    gap: 3rem;
  }

  .steps {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .step {
    padding: 0 1.75rem;
    border-top: 0;
    border-left: 1px solid var(--line);
  }

  .step:first-child {
    padding-left: 0;
    border-left: 0;
  }
}

/* ---------- 4. Features ---------- */

.features {
  display: grid;
  gap: var(--rhythm);
}

.feature-row {
  display: grid;
  gap: 1.75rem;
  margin-top: clamp(2.5rem, 6vw, 4.5rem);
  align-items: center;
}

.feature-row__text p {
  margin-top: 0.75rem;
  color: var(--ink-muted);
}

@media (min-width: 960px) {
  .feature-row {
    grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
    gap: clamp(3rem, 6vw, 5.5rem);
  }

  .feature-row--flip {
    grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
  }

  .feature-row--flip .feature-row__text {
    order: 2;
  }
}

/* Row A: stepper demo */

.stepper-demo {
  display: grid;
  gap: 0.75rem;
}

.stepper-demo__controls {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.75rem;
  margin-top: 0.25rem;
}

.stepper-demo input[type="range"] {
  width: 100%;
  min-height: 44px;
  margin: 0;
  accent-color: var(--accent);
  cursor: pointer;
}

/* Row B: compare demo */

.compare-demo {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
}

.compare-demo figcaption {
  margin-bottom: 0.5rem;
}

@media (max-width: 479.98px) {
  .compare-demo {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* Row C: filter demo */

.filter-demo {
  display: grid;
  gap: 1.25rem;
  padding: clamp(1.25rem, 3vw, 2rem);
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow-sheet);
}

.chips {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
}

.chips__name {
  width: 100%;
}

.chip {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 1rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--paper);
  color: var(--ink);
  font-size: 0.9375rem;
  font-weight: 500;
}

.chip--on {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--paper);
}

.filter-demo__count {
  padding-top: 1rem;
  border-top: 1px solid var(--line);
}

/* Rows D to F: studio mock and three-column band */

.studio-mock {
  margin-top: clamp(2.5rem, 6vw, 4.5rem);
  padding: clamp(1rem, 3vw, 2rem);
  border-radius: 8px;
  background: var(--sunken);
  border: 1px solid var(--line);
}

.studio-row {
  display: grid;
  grid-template-columns: 6rem minmax(0, 1fr);
  gap: 1rem 1.5rem;
  align-items: center;
  padding: 1rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow-sheet);
}

.studio-row__thumb {
  width: 6rem;
  border-radius: 4px;
  box-shadow: none;
}

.studio-row__body {
  display: grid;
  gap: 0.25rem;
}

.studio-row__title {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.375rem;
  line-height: 1.2;
}

.studio-row__note {
  color: var(--ink-muted);
}

.studio-row__actions {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.mock-button {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 1rem;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: var(--paper);
  font-size: 0.9375rem;
  font-weight: 600;
}

@media (min-width: 720px) {
  .studio-row {
    grid-template-columns: 6rem minmax(0, 1fr) auto;
  }

  .studio-row__actions {
    grid-column: auto;
  }
}

.artist-band {
  display: grid;
  margin-top: clamp(2rem, 4vw, 3rem);
}

.artist-band > div {
  padding-block: 1.5rem;
  border-top: 1px solid var(--line);
}

.artist-band p {
  margin-top: 0.5rem;
  color: var(--ink-muted);
}

@media (min-width: 720px) {
  .artist-band {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 2rem;
  }
}

/* ---------- 5. See it live ---------- */

.live {
  background: var(--sunken);
  padding-block: clamp(4rem, 9vw, 7rem);
}

.live__inner {
  display: grid;
  justify-items: center;
  text-align: center;
  gap: 1.25rem;
}

.live__body {
  max-width: 34rem;
  color: var(--ink-muted);
}

.browser {
  width: 100%;
  max-width: 72rem;
  margin: 1.5rem 0 1rem;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--surface);
  box-shadow: var(--shadow-sheet);
  overflow: hidden;
  transform-origin: 50% 100%;
}

.browser__bar {
  position: relative;
  display: flex;
  align-items: center;
  height: 36px;
  padding: 0 14px;
  border-bottom: 1px solid var(--line);
  background: var(--surface);
}

.browser__dots {
  display: flex;
  gap: 6px;
}

.browser__dots i {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--line);
}

.browser__pill {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  padding: 2px 14px;
  border-radius: 999px;
  background: var(--paper);
  white-space: nowrap;
}

.browser__view {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 10;
  border: 0;
  background: var(--paper);
}

@media (max-width: 719.98px) {
  .browser__view {
    aspect-ratio: auto;
    height: 640px;
  }
}

/* ---------- 6. Plain facts ---------- */

.facts__list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  font-size: 0.9375rem;
  text-align: center;
  color: var(--ink-muted);
}

.facts__list li {
  padding: 1.25rem 1rem;
  border-color: var(--line);
  border-style: solid;
  border-width: 0;
}

.facts__list li:nth-child(odd) {
  border-right-width: 1px;
}

.facts__list li:nth-child(-n + 2) {
  border-bottom-width: 1px;
}

.facts__list strong {
  display: block;
  color: var(--ink);
  font-weight: 600;
}

@media (min-width: 720px) {
  .facts__list {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .facts__list li,
  .facts__list li:nth-child(-n + 2) {
    border-width: 0;
  }

  .facts__list li:not(:last-child) {
    border-right-width: 1px;
  }
}

/* ---------- 7. Close ---------- */

.close {
  display: grid;
  justify-items: center;
  text-align: center;
  padding-block: clamp(6rem, 14vw, 11rem);
}

main > section.close {
  margin-top: 0;
}

.pile--close {
  --step: 10px;
  --turn: -2deg;
  --depth: 2;
  width: 200px;
  margin-bottom: 2.5rem;
  padding-top: calc(var(--step) * 3 + 6%);
}

.pile--close .sheet:not(.sheet--front) {
  top: calc(var(--step) * 3 + 6%);
}

.pile--close .frame {
  border-radius: 6px;
}

.close__heading {
  max-width: 14ch;
  font-size: clamp(2.5rem, 1.5rem + 4.2vw, 5.25rem);
}

.close__line {
  margin: 1.25rem 0 2.25rem;
  font-size: 1.25rem;
  color: var(--ink-muted);
}

@media (prefers-reduced-motion: no-preference) {
  .js .pile--close .sheet {
    transition: transform 600ms var(--ease);
    transition-delay: calc((2 - var(--d)) * 60ms);
  }

  .js .pile--close:not(.is-in) .sheet {
    transform: none;
  }

  /* Scroll reveals: fade up once on entry. */
  .js .reveal {
    transition:
      opacity 500ms var(--ease),
      transform 500ms var(--ease);
  }

  .js .reveal:not(.is-in) {
    opacity: 0;
    transform: translateY(12px);
  }

  .js .reveal--demo:not(.is-in) {
    transform: translateY(16px);
  }

  .js .step:nth-child(2) {
    transition-delay: 80ms;
  }

  .js .step:nth-child(3) {
    transition-delay: 160ms;
  }
}

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

.site-footer {
  border-top: 1px solid var(--line);
  background: var(--paper);
}

.site-footer__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem 2rem;
  width: min(72rem, 100% - 2 * var(--gutter));
  margin-inline: auto;
  padding-block: 1.5rem;
}

.site-footer__brand {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: -0.02em;
}

.site-footer__mark {
  width: 20px;
  height: 20px;
}

.site-footer__credit {
  font-size: 0.8125rem;
  color: var(--ink-muted);
}

/* ---------- Reduced motion: everything still, nothing pinned ---------- */

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