@font-face {
  font-family: "Archivo Black";
  src: url("fonts/archivo-black-latin.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "IBM Plex Mono";
  src: url("fonts/ibm-plex-mono-medium-latin1.woff2") format("woff2");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0020-007E, U+00A0-00FF, U+2013-2014, U+2018-201A, U+201C-201E, U+2026;
}

@font-face {
  font-family: "IBM Plex Mono";
  src: url("fonts/ibm-plex-mono-bold-latin1.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0020-007E, U+00A0-00FF, U+2013-2014, U+2018-201A, U+201C-201E, U+2026;
}

@font-face {
  font-family: "IBM Plex Mono";
  src: url("fonts/ibm-plex-mono-bold-pi.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
  unicode-range: U+2192, U+2713;
}

:root {
  --counter: #e6e9e3;
  --counter-2: #dce0d7;
  --ink: #16181d;
  --muted: #4a4f57;
  --line: rgba(22, 24, 29, 0.15);
  --fleck: rgba(22, 24, 29, 0.055);
  --fleck-2: rgba(255, 255, 255, 0.5);
  --accent-text: #b81f2e;
  --red: #d62839;
  --red-edge: #9e1424;
  --paper: #fffdf6;
  --print: #2a2c31;
  --print-soft: #5d6066;
  --body: #23262d;
  --body-hi: #3a3e48;
  --body-lo: #17191e;
  --led: #3ddc84;
  --shadow: rgba(22, 24, 29, 0.3);
  --paper-shadow: rgba(22, 24, 29, 0.2);
  --paper-glow: rgba(255, 244, 214, 0);
  --lamp: 0;
  --chip: rgba(255, 255, 255, 0.55);
  --rim: rgba(255, 255, 255, 0.08);
  --display: "Archivo Black", "Arial Black", "Helvetica Neue", system-ui, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  --text: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --counter: #121418;
    --counter-2: #16191e;
    --ink: #eef0ea;
    --muted: #b3b7af;
    --line: rgba(238, 240, 234, 0.13);
    --fleck: rgba(238, 240, 234, 0.03);
    --fleck-2: rgba(0, 0, 0, 0.25);
    --accent-text: #ff5a6a;
    --shadow: rgba(0, 0, 0, 0.62);
    --paper-shadow: rgba(0, 0, 0, 0.5);
    --paper-glow: rgba(255, 238, 196, 0.32);
    --lamp: 1;
    --chip: rgba(255, 255, 255, 0.05);
    --rim: rgba(255, 236, 200, 0.2);
    color-scheme: dark;
  }
}

:root[data-theme="dark"] {
  --counter: #121418;
  --counter-2: #16191e;
  --ink: #eef0ea;
  --muted: #b3b7af;
  --line: rgba(238, 240, 234, 0.13);
  --fleck: rgba(238, 240, 234, 0.03);
  --fleck-2: rgba(0, 0, 0, 0.25);
  --accent-text: #ff5a6a;
  --shadow: rgba(0, 0, 0, 0.62);
  --paper-shadow: rgba(0, 0, 0, 0.5);
  --paper-glow: rgba(255, 238, 196, 0.32);
  --lamp: 1;
  --chip: rgba(255, 255, 255, 0.05);
  --rim: rgba(255, 236, 200, 0.2);
  color-scheme: dark;
}

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

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

body {
  margin: 0;
  min-height: 100vh;
  background-color: var(--counter);
  background-image:
    radial-gradient(var(--fleck) 0.8px, transparent 1.2px),
    radial-gradient(var(--fleck-2) 0.7px, transparent 1.1px);
  background-size: 9px 11px, 13px 7px;
  background-position: 0 0, 4px 3px;
  color: var(--ink);
  font: 400 1rem/1.55 var(--text);
  overflow-x: clip;
}

a {
  color: inherit;
}

:focus-visible {
  outline: 3px solid var(--ink);
  outline-offset: 3px;
  border-radius: 6px;
}

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

.wrap {
  width: 100%;
  max-width: 1200px;
  margin-inline: auto;
  padding-inline: 16px;
}

/* ---------- top bar ---------- */

.bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-block: 14px;
}

.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 0.45em;
  font: 400 1.3rem/1 var(--display);
  letter-spacing: -0.01em;
  text-decoration: none;
  font-synthesis: none;
}

.mark {
  position: relative;
  display: inline-block;
  width: 0.72em;
  height: 0.98em;
  background: var(--ink);
  border-radius: 0.08em 0.08em 0 0;
  -webkit-mask: conic-gradient(from -45deg at bottom, #0000, #000 1deg 89deg, #0000 90deg) bottom / 0.24em 51% repeat-x,
    linear-gradient(#000 0 0) top / 100% 51% no-repeat;
  mask: conic-gradient(from -45deg at bottom, #0000, #000 1deg 89deg, #0000 90deg) bottom / 0.24em 51% repeat-x,
    linear-gradient(#000 0 0) top / 100% 51% no-repeat;
}

.mark span {
  position: absolute;
  right: -0.02em;
  bottom: 0.2em;
  width: 0.42em;
  height: 0.42em;
  border-radius: 50%;
  background: var(--red);
}

.theme {
  display: inline-flex;
  margin: 0;
  padding: 3px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--chip);
  min-inline-size: 0;
}

.theme label {
  position: relative;
  cursor: pointer;
}

.theme span {
  display: block;
  padding: 0.5em 0.75em;
  border-radius: 999px;
  color: var(--muted);
  font: 700 0.66rem/1 var(--mono);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  transition: background-color 0.2s, color 0.2s;
}

.theme label:hover span {
  color: var(--ink);
}

.theme input:checked + span {
  background: var(--ink);
  color: var(--counter);
}

.theme input:focus-visible + span {
  outline: 3px solid var(--ink);
  outline-offset: 2px;
}

/* ---------- hero ---------- */

.hero {
  display: grid;
  gap: 18px;
  padding-top: 6px;
  padding-bottom: 40px;
}

h1,
h2,
h3 {
  font-family: var(--display);
  font-weight: 400;
  font-synthesis: none;
  margin: 0;
}

h1 {
  font-size: clamp(2.7rem, 12.4vw, 6.9rem);
  line-height: 0.96;
  letter-spacing: -0.035em;
}

h1 span {
  display: block;
}

.accent {
  color: var(--accent-text);
}

.lede {
  margin: 14px 0 0;
  max-width: 34ch;
  color: var(--muted);
  font-size: 1rem;
  line-height: 1.5;
}

.cta-row {
  margin: 18px 0 0;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5em;
  min-height: 48px;
  padding: 0.85em 1.25em;
  border: 0;
  border-radius: 10px;
  background: var(--red);
  color: #fff;
  font: 700 0.95rem/1.1 var(--mono);
  letter-spacing: 0.01em;
  text-decoration: none;
  cursor: pointer;
  box-shadow: 0 3px 0 var(--red-edge), 0 10px 22px -10px rgba(214, 40, 57, 0.7);
  transition: transform 0.12s ease, box-shadow 0.12s ease, filter 0.2s;
  -webkit-tap-highlight-color: transparent;
}

.btn:hover {
  filter: brightness(1.06);
}

.btn:active {
  transform: translateY(2px);
  box-shadow: 0 1px 0 var(--red-edge), 0 6px 14px -8px rgba(214, 40, 57, 0.7);
}

.btn--big {
  font-size: 1rem;
  padding: 0.95em 1.5em;
}

/* ---------- the art: counter, lamp, printer and paper ---------- */

.art {
  position: relative;
  display: flex;
  justify-content: center;
  overflow: clip;
  overflow-clip-margin: 0;
}

.art--hero {
  --rig: 13.5px;
  padding: 4px 0 18px 70px;
  margin-inline: -16px;
  justify-content: center;
}

.art--hero::before {
  content: "";
  position: absolute;
  inset: -10% -20% 0;
  background: radial-gradient(ellipse 46% 52% at 58% 42%, rgba(255, 233, 186, 0.15), transparent 70%);
  opacity: var(--lamp);
  pointer-events: none;
}

.lamp {
  display: none;
}

.rig {
  --room: 15.6em;
  position: relative;
  flex: none;
  width: 16em;
  height: calc(var(--room) + 6.2em);
  font-size: var(--rig);
}

.feed,
.pile {
  position: absolute;
  inset: 0 0 auto 0;
  height: var(--room);
}

.feed {
  z-index: 2;
  filter: drop-shadow(0 0.5em 0.7em var(--paper-shadow)) drop-shadow(0 0 1.6em var(--paper-glow));
}

.paper {
  position: absolute;
  left: 50%;
  bottom: -0.2em;
  width: 11.2em;
  margin-left: -5.6em;
  transform-origin: 50% 100%;
  transform: perspective(40em) rotateX(5deg);
}

.sheet {
  --tooth: 0.62em;
  position: relative;
  padding: 1.3em 1.15em 4.4em;
  background:
    linear-gradient(180deg, rgba(60, 50, 30, 0.1), rgba(60, 50, 30, 0) 2.4em),
    linear-gradient(90deg, rgba(60, 50, 30, 0.06), rgba(60, 50, 30, 0) 14%, rgba(60, 50, 30, 0) 86%, rgba(60, 50, 30, 0.06)),
    var(--paper);
  color: var(--print);
  font: 500 0.74em/1.62 var(--mono);
  letter-spacing: 0.02em;
  text-shadow: 0 0 0.6px rgba(42, 44, 49, 0.55);
  -webkit-mask: conic-gradient(from 135deg at top, #0000, #000 1deg 89deg, #0000 90deg) top / var(--tooth) 51% repeat-x,
    linear-gradient(#000 0 0) bottom / 100% 51% no-repeat;
  mask: conic-gradient(from 135deg at top, #0000, #000 1deg 89deg, #0000 90deg) top / var(--tooth) 51% repeat-x,
    linear-gradient(#000 0 0) bottom / 100% 51% no-repeat;
}

.is-torn .sheet {
  -webkit-mask: conic-gradient(from 135deg at top, #0000, #000 1deg 89deg, #0000 90deg) top / var(--tooth) 51% repeat-x,
    conic-gradient(from -45deg at bottom, #0000, #000 1deg 89deg, #0000 90deg) bottom / var(--tooth) 51% repeat-x;
  mask: conic-gradient(from 135deg at top, #0000, #000 1deg 89deg, #0000 90deg) top / var(--tooth) 51% repeat-x,
    conic-gradient(from -45deg at bottom, #0000, #000 1deg 89deg, #0000 90deg) bottom / var(--tooth) 51% repeat-x;
}

/* thermal print fades a little toward one side, as a worn print head does */
.sheet::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(100deg, rgba(255, 253, 246, 0) 20%, rgba(255, 253, 246, 0.24) 62%, rgba(255, 253, 246, 0.06));
  pointer-events: none;
}

.row {
  white-space: nowrap;
}

.rc-shop {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.4em;
  font: 400 1.32em/1.5 var(--display);
  letter-spacing: -0.01em;
  color: #1f2126;
}

.rc-logo {
  width: 0.55em;
  height: 0.55em;
  border-radius: 50%;
  border: 0.12em solid var(--red);
  opacity: 0.85;
}

.rc-no {
  text-align: center;
  font-weight: 700;
  letter-spacing: 0.14em;
  color: var(--print-soft);
}

.rc-no .rc-num {
  color: var(--print);
}

.rc-rule {
  height: 1.05em;
  background: linear-gradient(90deg, currentColor 55%, transparent 0) 0 50% / 0.62em 1.4px repeat-x;
  opacity: 0.5;
}

.rc-line {
  display: flex;
  justify-content: space-between;
}

.rc-line b {
  font-weight: 700;
}

.rc-total {
  margin-top: 0.1em;
  text-align: center;
  font-weight: 700;
  font-size: 1.12em;
  letter-spacing: 0.06em;
  color: #1c1e22;
}

.rc-code {
  height: 1.9em;
  margin: 0.55em 0.6em 0;
  background:
    linear-gradient(90deg,
      currentColor 0 2%, transparent 2% 4%, currentColor 4% 5%, transparent 5% 7.5%, currentColor 7.5% 10.5%,
      transparent 10.5% 12%, currentColor 12% 13%, transparent 13% 16%, currentColor 16% 17%, transparent 17% 18.5%,
      currentColor 18.5% 22%, transparent 22% 23.5%, currentColor 23.5% 24.5%, transparent 24.5% 27%,
      currentColor 27% 29%, transparent 29% 30%, currentColor 30% 31%, transparent 31% 34%, currentColor 34% 37%,
      transparent 37% 38.5%, currentColor 38.5% 39.5%, transparent 39.5% 41%, currentColor 41% 42%,
      transparent 42% 45%, currentColor 45% 47%, transparent 47% 48%, currentColor 48% 51%, transparent 51% 53%,
      currentColor 53% 54%, transparent 54% 55.5%, currentColor 55.5% 58.5%, transparent 58.5% 60%,
      currentColor 60% 61%, transparent 61% 64%, currentColor 64% 65%, transparent 65% 66.5%, currentColor 66.5% 69%,
      transparent 69% 70.5%, currentColor 70.5% 71.5%, transparent 71.5% 74%, currentColor 74% 77%,
      transparent 77% 78%, currentColor 78% 79%, transparent 79% 81.5%, currentColor 81.5% 83%, transparent 83% 85%,
      currentColor 85% 88%, transparent 88% 89.5%, currentColor 89.5% 90.5%, transparent 90.5% 93%,
      currentColor 93% 95%, transparent 95% 96%, currentColor 96% 97%, transparent 97% 98%, currentColor 98% 100%);
  opacity: 0.82;
}

.rc-sub {
  font-size: 0.86em;
  letter-spacing: 0.12em;
  color: var(--print-soft);
}

.nf .rc-sub {
  text-align: center;
}

/* the rubber stamp: Archivo Black in stamp red, a double rim, uneven ink */
.stamp {
  position: absolute;
  left: 50%;
  bottom: 0.85em;
  translate: -50% 0;
  z-index: 2;
  padding: 0.44em 0.66em 0.38em;
  border: 0.16em solid var(--red);
  border-radius: 0.38em;
  box-shadow: inset 0 0 0 0.12em var(--paper), inset 0 0 0 0.23em var(--red);
  color: var(--red);
  font: 400 0.88em/1 var(--display);
  letter-spacing: 0.08em;
  white-space: nowrap;
  rotate: -7deg;
  opacity: 0.9;
  mix-blend-mode: multiply;
  -webkit-mask: url("img/grain.svg") 0 0 / 7em 7em;
  mask: url("img/grain.svg") 0 0 / 7em 7em;
}

.stamp--void {
  bottom: 0.5em;
  padding: 0.28em 0.5em 0.24em;
  border-width: 0.1em;
  box-shadow: inset 0 0 0 0.07em var(--paper), inset 0 0 0 0.13em var(--red);
  rotate: -14deg;
}

/* with motion, paper waits inside the slot and the stamp waits above it until the script runs */
.motion .rig .feed .paper:not([style]),
.motion .slip-paper:not([style]) {
  clip-path: inset(0 0 100% 0);
}

.motion .paper:not(.is-stamped) .stamp {
  opacity: 0;
}

/* the printer: a back lid with the top of the slot, then the body in front of the paper */
.lid {
  position: absolute;
  z-index: 1;
  left: 0.9em;
  right: 0.9em;
  top: calc(var(--room) - 1.4em);
  height: 1.55em;
  border-radius: 1.1em 1.1em 0 0;
  background: linear-gradient(180deg, #2f333b, #262930);
  box-shadow: inset 0 0.08em 0 var(--rim);
}

.lid-slot {
  position: absolute;
  left: 1.7em;
  right: 1.7em;
  bottom: 0;
  height: 0.5em;
  border-radius: 0.3em 0.3em 0 0;
  background: #0a0b0d;
}

.printer {
  position: absolute;
  z-index: 3;
  left: 0;
  right: 0;
  top: var(--room);
  height: 6em;
}

.printer-top {
  position: relative;
  height: 1.55em;
  background: linear-gradient(180deg, #3d414b, #30333b 70%, #2a2d34);
  clip-path: polygon(2.4% 0, 97.6% 0, 100% 100%, 0 100%);
}

.printer-top::before {
  content: "";
  position: absolute;
  left: 2.6em;
  right: 2.6em;
  top: 0;
  height: 0.3em;
  border-radius: 0 0 0.3em 0.3em;
  background: #08090b;
  box-shadow: 0 0.12em 0 rgba(255, 255, 255, 0.07);
}

.printer-front {
  position: relative;
  height: 4.45em;
  border-radius: 0 0 0.9em 0.9em;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.07), rgba(255, 255, 255, 0) 0.5em),
    linear-gradient(100deg, var(--body-hi), var(--body) 35%, var(--body) 70%, var(--body-lo));
  box-shadow: inset 0 -0.25em 0 rgba(0, 0, 0, 0.28), inset 0.06em 0 0 var(--rim), inset -0.06em 0 0 var(--rim);
}

.model {
  position: absolute;
  left: 1.25em;
  top: 1.15em;
  color: #a2a7b0;
  font: 700 0.66em/1 var(--mono);
  letter-spacing: 0.22em;
}

.grille {
  position: absolute;
  left: 1.25em;
  bottom: 1.15em;
  width: 4.6em;
  height: 0.95em;
  background: repeating-linear-gradient(90deg, #121418 0 0.2em, transparent 0.2em 0.46em);
  border-radius: 0.1em;
  opacity: 0.9;
}

.led {
  position: absolute;
  right: 3.75em;
  top: 1.12em;
  width: 0.5em;
  height: 0.5em;
  border-radius: 50%;
  background: var(--led);
  box-shadow: 0 0 0.35em var(--led), 0 0 1em rgba(61, 220, 132, 0.45);
}

.feed-btn {
  position: absolute;
  right: 1.2em;
  top: 0.78em;
  width: 1.5em;
  height: 1.5em;
  border-radius: 50%;
  background: radial-gradient(circle at 40% 35%, #4a4f5a, #2b2e35 70%);
  box-shadow: inset 0 0 0 0.09em #15171b, 0 0.08em 0 rgba(255, 255, 255, 0.06);
}

.counter-shadow {
  position: absolute;
  z-index: 0;
  left: -0.6em;
  right: -0.6em;
  bottom: -0.55em;
  height: 1.3em;
  border-radius: 50%;
  background: radial-gradient(closest-side, var(--shadow), transparent);
}

/* torn receipts lie flat on the counter, left of the printer */
.pile {
  z-index: 0;
}

/* ---------- play ---------- */

.play {
  background: var(--counter-2);
  border-block: 1px solid var(--line);
  padding-block: 40px 44px;
}

.play-grid {
  display: grid;
  grid-template-areas: "copy" "stage" "note";
  gap: 26px;
}

.play-copy {
  grid-area: copy;
  display: grid;
  gap: 18px;
  justify-items: start;
}

h2 {
  font-size: clamp(2rem, 8.6vw, 3.4rem);
  line-height: 1;
  letter-spacing: -0.03em;
  text-wrap: balance;
}

.play-note-slot {
  grid-area: note;
  min-height: 4.6em;
}

.play-note {
  margin: 0;
  max-width: 40ch;
  color: var(--muted);
  font-size: 0.95rem;
}

.js .play-note-slot:not(.is-shown) .play-note {
  visibility: hidden;
}

.motion .play-note-slot.is-shown .play-note {
  animation: rise 0.5s ease both;
}

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(6px);
  }
}

.stage {
  position: relative;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 8px;
  grid-area: stage;
}

.rig--play {
  --rig: 11.2px;
}

/* the friend's phone */
.phone {
  --w: 126px;
  position: relative;
  flex: none;
  width: var(--w);
  margin-bottom: 4px;
  font-size: calc(var(--w) / 12.6);
}

.phone-label {
  display: block;
  margin-bottom: 0.8em;
  color: var(--muted);
  font: 700 0.92em/1.2 var(--mono);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.phone-body {
  position: relative;
  height: calc(var(--w) * 1.86);
  padding: 0.55em;
  border-radius: 1.9em;
  background: linear-gradient(140deg, #3a3e48, #1c1e23 60%);
  box-shadow: 0 1.2em 2em -1em var(--shadow), inset 0 0 0 0.1em rgba(255, 255, 255, 0.07);
}

.phone-notch {
  position: absolute;
  z-index: 3;
  left: 50%;
  top: 1em;
  width: 3.2em;
  height: 0.9em;
  margin-left: -1.6em;
  border-radius: 1em;
  background: #0b0c0e;
}

.screen {
  position: relative;
  height: 100%;
  overflow: hidden;
  border-radius: 1.45em;
  background: #f4f5f1;
  color: #16181d;
}

.screen::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 4;
  background:
    linear-gradient(115deg, rgba(255, 255, 255, 0) 30%, rgba(255, 255, 255, 0.07) 31%, rgba(255, 255, 255, 0.02) 52%, rgba(255, 255, 255, 0) 53%),
    radial-gradient(circle at 70% 18%, rgba(214, 40, 57, 0.22), transparent 42%),
    radial-gradient(circle at 20% 85%, rgba(255, 253, 246, 0.07), transparent 50%),
    linear-gradient(160deg, #2b2f38, #121418 72%);
  transition: opacity 0.5s ease;
  pointer-events: none;
}

.is-awake .screen::after,
html:not(.js) .screen::after {
  opacity: 0;
}

.chat {
  position: absolute;
  inset: 0;
  padding: 3.2em 0.9em 1em;
}

.bubble {
  display: grid;
  gap: 0.45em;
  padding: 0.85em 0.9em 0.9em;
  border-radius: 1.1em 1.1em 1.1em 0.3em;
  background: #fff;
  box-shadow: 0 0.2em 0.6em rgba(0, 0, 0, 0.08);
  font: 400 1em/1.3 var(--text);
}

.from {
  font: 700 0.86em/1 var(--mono);
  color: #4a4f57;
}

.msg {
  font-size: 1.02em;
}

.link-card {
  display: flex;
  align-items: center;
  gap: 0.55em;
  padding: 0.5em;
  border-radius: 0.7em;
  background: #eef0ea;
  font: 700 0.92em/1.1 var(--text);
  color: #b01d2d;
}

.app-tile {
  flex: none;
  position: relative;
  width: 1.9em;
  height: 1.9em;
  border-radius: 0.5em;
  background: linear-gradient(145deg, #2b2e35, #16181d);
}

.app-tile::after {
  content: "";
  position: absolute;
  inset: 28%;
  border-radius: 50%;
  border: 0.22em solid #fffdf6;
  border-right-color: var(--red);
}

.app-tile--big {
  width: 4.4em;
  height: 4.4em;
  border-radius: 1.05em;
}

.store {
  position: absolute;
  inset: auto 0 0 0;
  z-index: 2;
  display: grid;
  justify-items: center;
  gap: 0.6em;
  padding: 1.7em 1em 1.5em;
  border-radius: 1.3em 1.3em 0 0;
  background: #fff;
  box-shadow: 0 -0.6em 1.6em rgba(0, 0, 0, 0.12);
  transform: translateY(105%);
  transition: transform 0.45s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.store-open .store {
  transform: none;
}

.store-name {
  font: 700 1.1em/1.1 var(--text);
}

.store-stars {
  display: flex;
  gap: 0.2em;
}

.store-stars span {
  width: 0.7em;
  height: 0.7em;
  background: #16181d;
  clip-path: polygon(50% 0, 62% 35%, 100% 38%, 70% 60%, 80% 100%, 50% 77%, 20% 100%, 30% 60%, 0 38%, 38% 35%);
  opacity: 0.85;
}

.store-btn {
  position: relative;
  display: grid;
  place-items: center;
  width: 100%;
  margin-top: 0.4em;
  padding: 0.75em 0.5em;
  border-radius: 999px;
  background: #16181d;
  color: #fff;
  font: 700 0.98em/1 var(--text);
  transition: background-color 0.25s;
}

.store-btn > span {
  grid-area: 1 / 1;
  transition: opacity 0.2s;
}

.bought,
.is-bought .buy {
  opacity: 0;
}

.is-bought .bought {
  opacity: 1;
}

.is-bought .store-btn {
  background: #3b3f48;
}

.finger {
  position: absolute;
  z-index: 5;
  left: 50%;
  top: 50%;
  width: 2.6em;
  height: 2.6em;
  margin: -1.3em 0 0 -1.3em;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(22, 24, 29, 0.35) 35%, rgba(22, 24, 29, 0.12) 60%, transparent 62%);
  opacity: 0;
  pointer-events: none;
}

/* ---------- steps ---------- */

.steps {
  padding-block: 44px 36px;
}

.step-list {
  display: grid;
  gap: 26px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.step {
  display: grid;
  grid-template-columns: 128px 1fr;
  grid-template-rows: auto 1fr;
  column-gap: 18px;
  align-items: start;
}

.slip {
  grid-row: 1 / 3;
  position: relative;
  height: 76px;
  font-size: 11.5px;
}

.slip-paper {
  position: absolute;
  left: 50%;
  bottom: 0.45em;
  width: 10em;
  margin-left: -5em;
  filter: drop-shadow(0 0.3em 0.4em var(--paper-shadow)) drop-shadow(0 0 1em var(--paper-glow));
}

.slip-paper .sheet {
  padding: 0.9em 0.9em 0.8em;
  font-size: 0.8em;
}

.slip-mouth {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 0.9em;
  border-radius: 0.45em;
  background: linear-gradient(180deg, #0a0b0d 0 40%, #30333b 40%, #23262d);
  box-shadow: 0 0.3em 0.6em -0.2em var(--shadow);
}

.step h3 {
  display: flex;
  align-items: baseline;
  gap: 0.55em;
  font-size: 1.3rem;
  line-height: 1.15;
  letter-spacing: -0.015em;
}

.step-no {
  color: var(--accent-text);
  font: 700 0.72rem/1 var(--mono);
  letter-spacing: 0.08em;
}

.step p {
  margin: 6px 0 0;
  color: var(--muted);
}

/* ---------- footer ---------- */

.foot {
  padding-block: 20px 34px;
}

.foot-line {
  margin: 0;
  padding-top: 20px;
  border-top: 2px dashed var(--line);
  color: var(--muted);
  font: 500 0.82rem/1.5 var(--mono);
  text-align: center;
}

.foot-line a {
  color: var(--ink);
  text-underline-offset: 3px;
}

/* ---------- 404 ---------- */

.nf {
  display: grid;
  justify-items: center;
  align-content: center;
  gap: 18px;
  min-height: calc(100svh - 170px);
  padding-block: 8px 48px;
  text-align: center;
}

.nf h1 {
  font-size: clamp(2.4rem, 10vw, 4.6rem);
}

.art--nf {
  --rig: 13px;
  padding-bottom: 10px;
}

.rig--nf {
  --room: 13.6em;
}

.nf .rc-sub {
  letter-spacing: 0.04em;
}

.nf .rc-total {
  margin-top: 0.3em;
}

.stamp--void {
  font-size: 1.7em;
}

/* ---------- calm mode: nothing slides or fades ---------- */

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

/* ---------- wider screens ---------- */

@media (min-width: 420px) {
  .wrap {
    padding-inline: 20px;
  }
}

@media (min-width: 760px) {
  .wrap {
    padding-inline: 40px;
  }

  .hero {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    align-items: center;
    gap: 32px;
    padding-top: 24px;
    padding-bottom: 64px;
  }

  .lede {
    font-size: 1.125rem;
    margin-top: 22px;
  }

  .cta-row {
    margin-top: 28px;
  }

  .art--hero {
    --rig: 17px;
    margin-inline: 0;
    padding: 70px 0 20px 120px;
  }

  .lamp {
    display: block;
    position: absolute;
    top: 0;
    left: calc(50% + 60px);
    width: 0;
    opacity: var(--lamp);
  }

  .lamp-cord {
    position: absolute;
    left: -1px;
    top: -10px;
    width: 2px;
    height: 34px;
    background: #2a2d34;
  }

  .lamp-shade {
    position: absolute;
    left: -34px;
    top: 22px;
    width: 68px;
    height: 30px;
    border-radius: 34px 34px 4px 4px;
    background: linear-gradient(180deg, #2f333b, #1b1d22);
    box-shadow: inset 0 2px 0 rgba(255, 255, 255, 0.08);
  }

  .lamp-bulb {
    position: absolute;
    left: -16px;
    top: 46px;
    width: 32px;
    height: 10px;
    border-radius: 0 0 16px 16px;
    background: #fff3d6;
    box-shadow: 0 0 18px 6px rgba(255, 228, 170, 0.45);
  }

  .art--hero::before {
    background: conic-gradient(from 180deg at calc(50% + 60px) 56px, transparent 154deg, rgba(255, 233, 186, 0.1) 168deg, rgba(255, 233, 186, 0.13) 180deg, rgba(255, 233, 186, 0.1) 192deg, transparent 206deg),
      radial-gradient(ellipse 40% 30% at calc(50% + 60px) 88%, rgba(255, 233, 186, 0.12), transparent 70%);
    inset: 0;
  }

  .play {
    padding-block: 64px;
  }

  .play-grid {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr);
    grid-template-rows: 1fr auto 1fr;
    grid-template-areas: ". stage" "copy stage" "note stage";
    column-gap: 40px;
    row-gap: 22px;
  }

  .play-note-slot {
    align-self: start;
  }

  .stage {
    justify-content: center;
    gap: 44px;
  }

  .phone {
    --w: 160px;
  }

  .rig--play {
    --rig: 15px;
  }

  .step-list {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 40px;
  }

  .step {
    grid-template-columns: 1fr;
    grid-template-rows: auto;
  }

  .slip {
    grid-row: auto;
    width: 210px;
    height: 112px;
    margin-bottom: 22px;
    font-size: 16px;
  }

  .step h3 {
    font-size: 1.5rem;
  }

  .art--nf {
    --rig: 15px;
  }
}

@media (min-width: 1100px) {
  .art--hero {
    --rig: 19.5px;
  }

  .hero {
    min-height: min(760px, calc(100vh - 80px));
  }

  .rig--play {
    --rig: 17px;
  }

  .phone {
    --w: 178px;
  }
}
