/* chalka.app, in the app's own look (docs/DESIGN.md in the app repo): matte
   black, one accent (white), smoked glass, Kanit for headings (in capitals
   for the opening statement), Big Shoulders for the scoreboard digits, the system font
   (SF Pro on Apple devices) for text. Green appears only on the skeleton, for
   a rep done right, as in the app. */

@font-face {
  font-family: "Kanit";
  font-weight: 600;
  font-style: normal;
  font-display: swap;
  src: url("/fonts/kanit-600.woff2") format("woff2");
}

@font-face {
  font-family: "Big Shoulders";
  font-weight: 900;
  font-style: normal;
  font-display: swap;
  src: url("/fonts/big-shoulders-900.woff2") format("woff2");
}

:root {
  --ink: #0b0b0c;
  --ink2: #141416;
  --ink3: #1d1d20;
  --line: #2a2a2e;
  --glass: rgba(255, 255, 255, 0.07);
  --glass-edge: rgba(255, 255, 255, 0.12);
  --bone: #ededed;
  --ash: #9b9ba1;
  --dim: #5e5e64;
  --accent: #ffffff;
  --accent-ink: #0b0b0c;
  --unlit: rgba(255, 255, 255, 0.18);
  --glow: rgba(255, 255, 255, 0.45);
  --scrim: rgba(11, 11, 12, 0.55);

  --text: -apple-system, BlinkMacSystemFont, "SF Pro Text", system-ui, "Segoe UI", Roboto, sans-serif;
  --head: "Kanit", var(--text);
  --digits: "Big Shoulders", "Arial Narrow", sans-serif;

  --gutter: 16px;
  --max: 1120px;
  --measure: 68ch;
  --radius: 28px;
  color-scheme: dark;
}

@media (min-width: 640px) {
  :root {
    --gutter: 24px;
  }
}

@media (min-width: 1024px) {
  :root {
    --gutter: 32px;
  }
}

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

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-padding-top: 80px;
  scroll-behavior: smooth;
  background: var(--ink);
}

body {
  margin: 0;
  background: var(--ink);
  color: var(--bone);
  font-family: var(--text);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-wrap: break-word;
}

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

img {
  height: auto;
}

::selection {
  background: var(--accent);
  color: var(--accent-ink);
}

/* Layout */

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

.doc .wrap {
  max-width: calc(var(--measure) + var(--gutter) * 2);
}

/* Skip link */

.skip {
  position: absolute;
  left: var(--gutter);
  top: -100px;
  padding: 8px 14px;
  border-radius: 999px;
  background: var(--accent);
  color: var(--accent-ink);
  font-weight: 600;
  text-decoration: none;
  z-index: 10;
}

.skip:focus {
  top: 12px;
}

/* Header */

.bar .wrap {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 24px;
  padding-top: 18px;
  padding-bottom: 18px;
}

.doc .bar {
  border-bottom: 1px solid var(--line);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--accent);
  font-family: var(--head);
  font-weight: 600;
  font-size: 20px;
  letter-spacing: 0.01em;
  text-decoration: none;
}

.brand img {
  width: 30px;
  height: 30px;
  border-radius: 8px;
}

.bar nav ul {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 22px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.bar nav li {
  margin: 0;
}

.bar nav a {
  color: var(--ash);
  font-size: 15px;
  text-decoration: none;
}

.bar nav a:hover,
.bar nav a[aria-current="page"] {
  color: var(--accent);
}

.bar nav ul {
  align-items: center;
}

/* On Home the bar stays at the top, clear over the hero and smoked glass once the page moves. */
.home .bar {
  position: sticky;
  top: 0;
  z-index: 15;
  border-bottom: 1px solid transparent;
  transition: background-color 0.4s ease, border-color 0.4s ease;
}

.home .bar.scrolled {
  border-bottom-color: rgba(255, 255, 255, 0.07);
  background: rgba(11, 11, 12, 0.72);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  backdrop-filter: saturate(180%) blur(20px);
}

.home .bar .wrap {
  padding-top: 14px;
  padding-bottom: 14px;
}

/* Apple's badge in the bar: 40 px tall, Apple's minimum, with its clear space (a quarter of its height) inside the bar's padding. */
.bar nav .store {
  margin: 0;
}

.bar nav .store img {
  height: 40px;
}

@media (max-width: 479px) {
  /* Support is in the footer; the bar keeps Guides and the badge on one line. */
  .home .bar nav li:nth-child(2) {
    display: none;
  }
}

@media (max-width: 374px) {
  /* The smallest iPhones: only the badge (Guides is in the footer too). */
  .home .bar nav li:nth-child(1) {
    display: none;
  }
}

/* Type */

h1,
h2,
h3 {
  color: var(--accent);
  font-family: var(--head);
  font-weight: 600;
  line-height: 1.15;
  letter-spacing: -0.005em;
  text-wrap: balance;
}

p,
ul,
ol,
dl {
  margin: 0 0 16px;
}

ul,
ol {
  padding-left: 1.25em;
}

li {
  margin-bottom: 8px;
}

li::marker {
  color: var(--ash);
}

strong {
  color: var(--accent);
  font-weight: 600;
}

a {
  color: var(--accent);
  text-decoration: underline;
  text-decoration-color: rgba(255, 255, 255, 0.4);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
}

a:hover {
  text-decoration-color: var(--accent);
}

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

/* Kanit capitals, the heading font (owner, 2026-10-15; it was Anton). */
.statement {
  margin: 0;
  color: var(--accent);
  font-family: var(--head);
  font-weight: 600;
  line-height: 1.02;
  letter-spacing: 0.005em;
  text-transform: uppercase;
}

.lead {
  color: var(--bone);
  font-size: clamp(1.0625rem, 2.2vw, 1.25rem);
  line-height: 1.55;
}

.muted {
  color: var(--ash);
}

.fine {
  color: var(--ash);
  font-size: 14px;
}

/* Scoreboard digits: lit ones glow, padding zeros stay unlit. */

.led {
  color: var(--accent);
  font-family: var(--digits);
  font-weight: 900;
  font-variant-numeric: tabular-nums;
  line-height: 1;
  letter-spacing: 0.02em;
  text-shadow: 0 0 0.3em var(--glow);
}

.led .off {
  color: var(--unlit);
  text-shadow: none;
}

.panel {
  display: inline-block;
  padding: 0.08em 0.28em 0.06em;
  border: 1px solid var(--glass-edge);
  border-radius: 0.5em;
  background: var(--ink2);
}

/* Apple's "Download on the App Store" badge, black, as Apple supplies it
   (img/app-store-badge.svg). Apple asks for at least 40 px tall and clear
   space of a quarter of its height all round; never restyle the badge. */

.store {
  display: inline-block;
  margin: 10px;
  border-radius: 8px;
  line-height: 0;
}

.store img {
  width: auto;
  height: 48px;
}

/* Home */

.home section {
  padding-top: clamp(80px, 12vw, 144px);
}

.home h2 {
  margin: 0 0 18px;
  font-size: clamp(2.125rem, 5.4vw, 3.6rem);
  line-height: 1.04;
  letter-spacing: -0.02em;
}

.home .intro {
  max-width: 40rem;
  margin-bottom: clamp(32px, 5vw, 56px);
}

.home .intro .lead {
  margin: 0;
  color: var(--ash);
}

/* Hero: Chalk peeking over the alarm clock in a pool of studio light, as on
   the app's Home. Everything in .clock scales with its font size, the digits'. */

/* The light falls from above the top of the page, behind the header too. */
body.home {
  background: radial-gradient(ellipse min(620px, 90vw) 720px at 50% -60px, rgba(255, 255, 255, 0.13), rgba(255, 255, 255, 0.035) 50%, rgba(255, 255, 255, 0) 78%) no-repeat, var(--ink);
}

.home .hero {
  position: relative;
  padding-top: clamp(24px, 6vw, 64px);
  text-align: center;
}

.hero .wrap {
  position: relative;
}

.clock {
  position: relative;
  display: inline-block;
  padding-top: 1.19em;
  font-size: clamp(92px, 23vw, 196px);
  line-height: 1;
}

.clock > .panel {
  position: relative;
  z-index: 2;
  padding: 0.06em 0.26em 0.02em;
  border-radius: 0.2em;
}

/* The pup's canvas is 432 × 511. Its edge line, 0.875 of the way down, sits
   just above the panel's top, so the flat cut across its chest hides behind
   the panel and only the paws (a second layer, in front) curl over it. */
.clock .peek,
.clock .paws {
  position: absolute;
  top: 0;
  left: 50%;
  width: 1.1em;
  margin-left: -0.55em;
}

/* Its layers have 14 rows (of 432) more on top, for the ear tips, so they
   start that much higher and the pup still sits where the paws expect it. */
.clock .peek {
  top: -0.0356em;
  z-index: 1;
  /* Buttons don't inherit the font size, and the width is in em. */
  font-size: inherit;
  padding: 0;
  border: 0;
  background: none;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.clock .peek .face {
  display: block;
  position: relative;
  transform-origin: 50% 100%;
  animation: breathe 3.6s ease-in-out infinite;
}

.clock .peek img {
  display: block;
  width: 100%;
}

/* Between blinks, one small move at a time, all on the colon's beat over a
   12 s round (six beats): the left ear flicks at 2 s, the head tilts at 5.3 s,
   the right ear flicks at 10 s. The head pivots low, behind the panel, and the
   paws stay put on the clock; each ear pivots level with its outer base, so
   that edge slides along the side of the head. */
.clock .peek .head {
  display: block;
  position: relative;
  transform-origin: 50% 92.2%;
  animation: tilt 12s ease-in-out infinite;
}

.clock .peek .ear,
.clock .peek .eyes {
  position: absolute;
  inset: 0;
}

.clock .peek .ear.left {
  transform-origin: 38.2% 31.2%;
  animation: flick-left 12s ease-in-out infinite;
}

.clock .peek .ear.right {
  transform-origin: 61.6% 31.2%;
  animation: flick-right 12s ease-in-out infinite;
}

/* The eyes are their own layer, so they can close: Chalk blinks each time the
   colon dims, on the colon's 2 s beat (site.js keeps the two in step). They
   close onto a line a little below their middle, like a lid coming down. */
.clock .peek .eyes {
  transform-origin: 50% 49.8%;
  animation: wink 2s linear infinite;
}

.clock .paws {
  z-index: 3;
  pointer-events: none;
}

.clock.hop .peek,
.clock.hop .paws {
  animation: hop 0.55s ease-out;
}

.clock .colon {
  animation: blink 2s linear infinite;
}

@keyframes breathe {
  50% {
    transform: scale(0.994, 1.016);
  }
}

/* Small enough that the cut never rises above the panel. */
@keyframes hop {
  30% {
    transform: translateY(-0.07em);
  }
  60% {
    transform: translateY(0);
  }
  78% {
    transform: translateY(-0.02em);
  }
}

@keyframes blink {
  0%,
  49% {
    opacity: 1;
  }
  50%,
  100% {
    opacity: 0.3;
  }
}

/* Shut by the time the colon dims at 50%: 90 ms to close, a beat shut, 140 ms to open. */
@keyframes wink {
  0%,
  45.5% {
    transform: scaleY(1);
    animation-timing-function: ease-in;
  }
  50%,
  51.5% {
    transform: scaleY(0.14);
    animation-timing-function: ease-out;
  }
  58.5%,
  100% {
    transform: scaleY(1);
  }
}

@keyframes tilt {
  0%,
  44.2% {
    transform: rotate(0);
  }
  47.9%,
  52.9% {
    transform: rotate(2.5deg);
  }
  57.1%,
  100% {
    transform: rotate(0);
  }
}

/* A flick out and a smaller one after it, like an ear shaking off a fly. */
@keyframes flick-left {
  0%,
  16.6% {
    transform: rotate(0);
  }
  17.2% {
    transform: rotate(-7deg);
  }
  18.1% {
    transform: rotate(0);
  }
  18.6% {
    transform: rotate(-4deg);
  }
  19.7%,
  100% {
    transform: rotate(0);
  }
}

@keyframes flick-right {
  0%,
  83.3% {
    transform: rotate(0);
  }
  83.9% {
    transform: rotate(7deg);
  }
  84.75% {
    transform: rotate(0);
  }
  85.25% {
    transform: rotate(4deg);
  }
  86.3%,
  100% {
    transform: rotate(0);
  }
}

.caption {
  margin: 18px 0 0;
  color: var(--ash);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.hero .statement {
  margin-top: clamp(32px, 6vw, 56px);
  /* "Then the day." is 6.8 em wide in Kanit capitals: this keeps it on one
     line from a 320 px phone up. */
  font-size: clamp(2.5rem, 12.6vw, 6.25rem);
}

.hero .lead {
  max-width: 30rem;
  margin: 20px auto 28px;
}

/* The page's h1: what Chalka is, in the words people search with, under the
   statement (which is styled text, not a heading). */
.hero .tagline {
  max-width: 28rem;
  margin: clamp(20px, 4vw, 28px) auto 0;
  font-size: clamp(1.25rem, 3.4vw, 1.625rem);
}

.hero .tagline + .lead {
  margin-top: 10px;
}

.hero .fine {
  margin: 14px 0 0;
}

/* Your morning, counted: three screens from the app, each in an iPhone.
   Inside a phone, sizes are in cqw (a hundredth of its screen's width), so
   a phone looks the same at every size. */

.moments {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

@media (max-width: 699px) {
  .moments {
    grid-template-columns: none;
    grid-auto-flow: column;
    grid-auto-columns: min(72%, 290px);
    gap: 20px;
    margin: 0 calc(var(--gutter) * -1);
    padding: 16px var(--gutter) 12px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-padding-inline: var(--gutter);
    scrollbar-width: none;
  }

  .moments::-webkit-scrollbar {
    display: none;
  }

  .moment {
    scroll-snap-align: start;
  }
}

.moment {
  margin: 0;
}

/* An iPhone: a titanium edge, a black bezel and the screen, with its side button. */
.phone {
  position: relative;
  width: 100%;
  max-width: 290px;
  margin: 0 auto;
  aspect-ratio: 9 / 19.5;
  padding: 3.4%;
  border-radius: 15% / 6.92%;
  background: #050506;
  /* The screens size their contents from this; 1cqw is a hundredth of the screen's width. */
  container-type: inline-size;
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.08),
    0 60px 90px -40px rgba(0, 0, 0, 0.95),
    0 40px 120px -60px rgba(255, 255, 255, 0.12);
}

.phone::before {
  content: "";
  position: absolute;
  z-index: -1;
  inset: -2px;
  border-radius: 15.6% / 7.1%;
  background: linear-gradient(150deg, #9a9aa0 0%, #3a3a3f 16%, #1a1a1d 46%, #2c2c30 74%, #8c8c92 100%);
}

.phone::after {
  content: "";
  position: absolute;
  top: 25%;
  right: -4px;
  width: 3px;
  height: 11%;
  border-radius: 0 3px 3px 0;
  background: linear-gradient(90deg, #2a2a2e, #6a6a70);
}

/* clip-path as well as overflow: Safari doesn't round the corners of a
   blurred or masked layer inside (the camera's backdrop and frames), so they
   showed square past the phone's edge. */
.screen {
  position: relative;
  height: 100%;
  overflow: hidden;
  border-radius: 12.4% / 5.53%;
  clip-path: inset(0 round 12.4% / 5.53%);
  background: var(--ink2);
}

/* The Dynamic Island and the home indicator. */
.screen::before,
.screen::after {
  content: "";
  position: absolute;
  z-index: 6;
  left: 50%;
  transform: translateX(-50%);
  border-radius: 999px;
  pointer-events: none;
}

.screen::before {
  top: 3.2cqw;
  width: 31cqw;
  height: 9.2cqw;
  background: #000;
}

.screen::after {
  bottom: 2.4cqw;
  width: 36cqw;
  height: 1.5cqw;
  background: rgba(255, 255, 255, 0.55);
}

/* The status bar: each screen's own time, and the battery. */
.status {
  position: absolute;
  z-index: 6;
  top: 5.6cqw;
  left: 0;
  right: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 9cqw 0 11cqw;
  color: #fff;
  font-family: var(--text);
  font-weight: 600;
  font-size: 4.6cqw;
  line-height: 1;
  letter-spacing: -0.01em;
  font-variant-numeric: tabular-nums;
  pointer-events: none;
}

.status i {
  position: relative;
  width: 7.6cqw;
  height: 3.7cqw;
  border: 0.45cqw solid rgba(255, 255, 255, 0.45);
  border-radius: 1.2cqw;
}

.status i::before {
  content: "";
  position: absolute;
  inset: 0.45cqw 1.8cqw 0.45cqw 0.45cqw;
  border-radius: 0.6cqw;
  background: #fff;
}

.status i::after {
  content: "";
  position: absolute;
  top: 50%;
  right: -1.4cqw;
  width: 0.8cqw;
  height: 1.4cqw;
  transform: translateY(-50%);
  border-radius: 0 0.5cqw 0.5cqw 0;
  background: rgba(255, 255, 255, 0.45);
}

.moment figcaption {
  max-width: 290px;
  margin: 28px auto 0;
  color: var(--ash);
  font-size: 15px;
  line-height: 1.5;
  text-align: center;
}

.moment figcaption .led {
  display: block;
  margin-bottom: 8px;
  font-size: 30px;
}

.moment figcaption strong {
  font-family: var(--head);
  font-size: 18px;
}

.screen .hello {
  margin: 0;
  color: var(--accent);
  font-family: var(--head);
  font-size: 7.4cqw;
  line-height: 1.2;
}

.screen .line {
  margin: 0.8cqw 0 0;
  color: var(--ash);
  font-size: 5cqw;
}

/* 06:30, the alarm screen (src/app/wake.tsx) */

.wake {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 19cqw 6cqw 9cqw;
  text-align: center;
}

.wake .day {
  margin: 0 0 3cqw;
  color: var(--ash);
  font-size: 4.2cqw;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.wake .led {
  font-size: 19cqw;
}

.wake .ring {
  animation: ring 1.4s ease-in-out infinite;
}

@keyframes ring {
  50% {
    box-shadow: 0 0 0 6px rgba(255, 255, 255, 0.05), 0 0 40px rgba(255, 255, 255, 0.2);
  }
}

.wake img {
  flex: 1 1 auto;
  width: 100%;
  min-height: 0;
  margin: 2cqw 0;
  object-fit: contain;
  -webkit-mask-image: radial-gradient(closest-side, #000 62%, transparent);
  mask-image: radial-gradient(closest-side, #000 62%, transparent);
}

.wake .line {
  margin-bottom: 5cqw;
}

.btn {
  display: block;
  width: 100%;
  padding: 3.8cqw 4cqw;
  border: 1px solid transparent;
  border-radius: 999px;
  background: var(--accent);
  color: var(--accent-ink);
  font-weight: 600;
  font-size: 5.4cqw;
  line-height: 1.2;
}

.btn.ghost {
  margin-top: 2.6cqw;
  border-color: var(--glass-edge);
  background: var(--glass);
  color: var(--bone);
}

/* 06:31, the camera: the app's onboarding demo, joints from Apple Vision.
   The photo fills the width, as the app shows it, over a blurred copy of
   itself, the way iOS letterboxes a video. */

.stage .backdrop {
  position: absolute;
  inset: -12%;
  background: url("/img/demo/pushup-0.webp") center / cover;
  filter: blur(22px) brightness(0.42);
}

.stage .frames {
  position: absolute;
  left: 0;
  right: 0;
  -webkit-mask-image: linear-gradient(transparent, #000 8%, #000 92%, transparent);
  mask-image: linear-gradient(transparent, #000 8%, #000 92%, transparent);
}

.stage .frames img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
}

.stage .frames img:first-child {
  opacity: 1;
}

.stage .fade {
  display: none;
}

.stage svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.counter {
  position: absolute;
  top: 17cqw;
  left: 0;
  right: 0;
  display: flex;
  justify-content: center;
  align-items: flex-end;
  gap: 2.6cqw;
}

.counter .led {
  font-size: 16cqw;
  transform-origin: center bottom;
}

.counter .of {
  padding-bottom: 2.6cqw;
  color: var(--ash);
  font-family: var(--head);
  font-size: 7.6cqw;
  line-height: 1;
}

.cue {
  position: absolute;
  left: 4cqw;
  right: 4cqw;
  bottom: 8cqw;
  margin: 0;
  padding: 3.4cqw 4.6cqw;
  border-radius: 5cqw;
  background: var(--scrim);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  color: var(--accent);
  font-weight: 600;
  font-size: 5.2cqw;
  line-height: 1.35;
  text-align: center;
}

/* 06:34, the set done: the XP and Chalk awake on its floor. */

.done {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding-top: 24cqw;
  text-align: center;
}

.done .xp {
  font-size: 24cqw;
}

.done .xp small {
  margin-left: 0.1em;
  color: var(--ash);
  font-size: 0.42em;
  text-shadow: none;
}

.done .hello {
  margin-top: 4cqw;
}

.floor {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 54%;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding-bottom: 22%;
  background: radial-gradient(ellipse 62% 20% at 50% 80%, rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0) 70%);
}

.floor::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: 19%;
  width: 52%;
  height: 5%;
  transform: translateX(-50%);
  background: radial-gradient(closest-side, rgba(0, 0, 0, 0.75), rgba(0, 0, 0, 0));
}

.floor img {
  position: relative;
  z-index: 1;
  width: 78%;
}

/* Section backdrops below the hero, each from the app's own vocabulary: film
   grain over everything, the scoreboard's dot matrix, engraved coin rings,
   and big outlined numbers that say what the section counts. All full width,
   behind the content, faint enough to read as texture. */

body.home {
  overflow-x: clip;
}

body.home::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 20;
  background: url("/img/grain.png");
  opacity: 0.07;
  pointer-events: none;
}

.home main > section {
  position: relative;
  isolation: isolate;
}

.home main > section::before {
  content: "";
  position: absolute;
  z-index: -2;
  top: -96px;
  bottom: -96px;
  left: 50%;
  width: 100vw;
  transform: translateX(-50%);
  pointer-events: none;
}

/* The scoreboard's dot matrix, lit in the middle. */
.band-morning::before {
  background-image: radial-gradient(circle, rgba(255, 255, 255, 0.11) 1px, rgba(255, 255, 255, 0) 1.6px);
  background-size: 9px 9px;
  -webkit-mask-image: radial-gradient(ellipse closest-side at 50% 55%, #000 0%, rgba(0, 0, 0, 0.55) 55%, transparent 100%);
  mask-image: radial-gradient(ellipse closest-side at 50% 55%, #000 0%, rgba(0, 0, 0, 0.55) 55%, transparent 100%);
}

/* A studio light over the figures. */
.band-moves::before {
  background: radial-gradient(ellipse closest-side at 50% 42%, rgba(255, 255, 255, 0.075), rgba(255, 255, 255, 0.02) 60%, rgba(255, 255, 255, 0) 100%);
}

/* Engraved rings, like a coin's edge, centred behind the coins. */
.band-levels::before {
  background: repeating-radial-gradient(circle at 50% 62%, rgba(255, 255, 255, 0.06) 0 1px, rgba(255, 255, 255, 0) 1px 13px);
  -webkit-mask-image: radial-gradient(ellipse closest-side at 50% 62%, #000 0%, rgba(0, 0, 0, 0.5) 50%, transparent 100%);
  mask-image: radial-gradient(ellipse closest-side at 50% 62%, #000 0%, rgba(0, 0, 0, 0.5) 50%, transparent 100%);
}

/* The dot matrix again, faint, with light pooling on Chalk's floor. */
.band-chalk::before {
  background:
    radial-gradient(ellipse 60% 26% at 50% 58%, rgba(255, 255, 255, 0.07), rgba(255, 255, 255, 0) 70%),
    radial-gradient(circle, rgba(255, 255, 255, 0.07) 1px, rgba(255, 255, 255, 0) 1.6px) 0 0 / 9px 9px;
  -webkit-mask-image: linear-gradient(transparent, #000 25%, #000 70%, transparent);
  mask-image: linear-gradient(transparent, #000 25%, #000 70%, transparent);
}

/* The same light as the top of the page, on the icon. */
.end::before {
  background: radial-gradient(ellipse closest-side at 50% 40%, rgba(255, 255, 255, 0.09), rgba(255, 255, 255, 0.02) 55%, rgba(255, 255, 255, 0) 100%);
}

.hero::before {
  display: none;
}

.bignum {
  display: none;
}

@media (min-width: 1100px) {
  .bignum {
    display: block;
    position: absolute;
    z-index: -1;
    /* Whole, never faded or cut (owner, 2026-10-15): the top of the digits
       level with the top of the section's heading, and short enough to end
       above the section's content. */
    top: calc(clamp(80px, 12vw, 144px) + 6px);
    right: var(--gutter);
    color: transparent;
    font-family: var(--digits);
    font-weight: 900;
    font-size: 220px;
    line-height: 0.8;
    -webkit-text-stroke: 1.5px rgba(255, 255, 255, 0.12);
    user-select: none;
    pointer-events: none;
  }
}

/* Exercises */

.moves {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 28px 16px;
  margin: 0;
  padding: 0;
  list-style: none;
}

@media (min-width: 760px) {
  .moves {
    grid-template-columns: repeat(4, 1fr);
    gap: 36px 20px;
  }
}

.moves li {
  margin: 0;
}

.moves img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  border-radius: 20px;
  background: var(--ink2);
}

.moves strong {
  display: block;
  margin-top: 12px;
  font-family: var(--head);
  font-size: 17px;
  line-height: 1.25;
}

.moves span {
  color: var(--ash);
  font-size: 15px;
}

/* Coins */

.coins {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 12px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.coins li {
  margin: 0;
  text-align: center;
}

.coins img {
  width: 100%;
  max-width: 160px;
  margin: 0 auto;
  aspect-ratio: 1;
}

.coins strong {
  display: block;
  margin-top: 8px;
  font-family: var(--head);
  font-size: clamp(13px, 2.4vw, 17px);
  line-height: 1.2;
}

.coins span {
  color: var(--ash);
  font-size: clamp(12px, 2vw, 14px);
}

/* Chalk, the streak pup, at three days old on its own floor. It's the one
   age the site shows: what Chalk grows into stays a surprise for the app. */

.yard {
  position: relative;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  height: clamp(200px, 32vw, 320px);
  border-bottom: 1px solid var(--line);
}

/* Its shadow on the floor, which shrinks as it jumps. */
.yard::before {
  content: "";
  position: absolute;
  left: 50%;
  bottom: -3%;
  width: clamp(130px, 20vw, 210px);
  height: 8%;
  transform: translateX(-50%);
  background: radial-gradient(closest-side, rgba(0, 0, 0, 0.8), rgba(0, 0, 0, 0));
}

.yard button {
  position: relative;
  height: 82%;
  padding: 0;
  border: 0;
  background: none;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.yard img {
  display: block;
  width: auto;
  height: 100%;
}

.yard.hop button {
  animation: jump 0.55s ease-out;
}

.yard.hop::before {
  animation: shadow 0.55s ease-out;
}

@keyframes jump {
  30% {
    transform: translateY(-16%);
  }
  60% {
    transform: translateY(0);
  }
  78% {
    transform: translateY(-4%);
  }
}

@keyframes shadow {
  30% {
    transform: translateX(-50%) scale(0.7);
    opacity: 0.5;
  }
  60% {
    transform: translateX(-50%);
  }
  78% {
    transform: translateX(-50%) scale(0.92);
  }
}

.asleep {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 24px;
  max-width: 40rem;
  margin: 48px auto 0;
}

.asleep img {
  width: 120px;
  flex: none;
}

.asleep p {
  margin: 0;
  color: var(--ash);
}

@media (max-width: 599px) {
  .asleep {
    flex-direction: column;
    gap: 12px;
    text-align: center;
  }

  .asleep img {
    width: 132px;
  }
}

/* The end */

.end {
  padding-bottom: clamp(72px, 11vw, 136px) !important;
  text-align: center;
}

.end > img {
  width: 112px;
  height: 112px;
  margin: 0 auto 24px;
  border-radius: 26px;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.07), 0 40px 70px -30px rgba(0, 0, 0, 0.95), 0 0 90px rgba(255, 255, 255, 0.08);
}

.end h2 {
  margin-bottom: 4px !important;
}

.end p {
  margin: 0 0 24px;
  color: var(--ash);
}

/* Legal and help pages */

.doc main {
  padding-bottom: 64px;
}

.doc h1 {
  margin: 48px 0 8px;
  font-size: clamp(2rem, 7vw, 2.75rem);
  letter-spacing: -0.01em;
}

.doc h2 {
  margin: 48px 0 12px;
  font-size: 1.5rem;
}

.doc h3 {
  margin: 32px 0 8px;
  font-size: 1.125rem;
}

.effective {
  margin: 0 0 32px;
  color: var(--ash);
  font-size: 15px;
}

/* The one smoked-glass panel on a page: the plain-English summary. */

.summary {
  margin: 0 0 40px;
  padding: 20px 22px 6px;
  border: 1px solid var(--glass-edge);
  border-radius: 20px;
  background: var(--glass);
}

.summary h2 {
  margin: 0 0 12px !important;
  font-size: 1.125rem !important;
}

.contents {
  margin: 32px 0 8px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--line);
}

.contents h2 {
  margin: 0 0 8px !important;
  font-size: 1.125rem !important;
}

.contents ul {
  padding: 0;
  list-style: none;
  columns: 2 18ch;
  column-gap: 32px;
}

.contents li {
  margin-bottom: 6px;
  break-inside: avoid;
}

.contents a {
  color: var(--ash);
  text-decoration: none;
}

.contents a:hover {
  color: var(--accent);
}

/* Guides (generated by build-guides.mjs): the doc layout, plus app entries,
   tables that stack on phones, and the App Store badge after the lead and at
   the end. Hairlines separate things; nothing sits in a card. */

.guide .lead {
  margin: 0 0 20px;
}

.cta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0 8px;
  /* The badge keeps its 10 px clear space; pull it back onto the text edge. */
  margin: 0 0 32px -10px;
}

.cta p {
  margin: 0;
}

.cta.end {
  margin: 56px 0 8px -10px;
  padding-top: 24px;
  border-top: 1px solid var(--line);
}

.note {
  color: var(--ash);
  font-size: 15px;
}

.app {
  padding: 24px 0 4px;
  border-top: 1px solid var(--line);
}

.doc .app h3 {
  margin: 0 0 4px;
  font-size: 1.25rem;
}

.app .meta {
  margin: 0 0 14px;
  color: var(--ash);
  font-size: 14px;
}

.app .price {
  color: var(--ash);
  font-size: 15px;
}

.table {
  margin: 20px 0 28px;
}

.table table {
  width: 100%;
  border-collapse: collapse;
  font-size: 15px;
  line-height: 1.45;
}

.table th,
.table td {
  padding: 10px 14px 10px 0;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}

.table thead th {
  color: var(--ash);
  font-size: 13px;
  font-weight: 600;
}

.table tbody th {
  color: var(--accent);
  font-weight: 600;
}

.table.numeric table {
  font-variant-numeric: tabular-nums;
}

.table.numeric tbody th {
  color: var(--ash);
  font-weight: 400;
}

@media (max-width: 640px) {
  .table.stack thead {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip-path: inset(50%);
  }

  .table.stack tr {
    display: block;
    padding: 12px 0;
    border-bottom: 1px solid var(--line);
  }

  .table.stack th,
  .table.stack td {
    display: block;
    padding: 2px 0;
    border: 0;
  }

  .table.stack tbody th {
    margin-bottom: 4px;
    font-size: 16px;
  }

  .table.stack td::before {
    content: attr(data-label);
    display: block;
    color: var(--ash);
    font-size: 13px;
  }
}

.steps li {
  margin-bottom: 10px;
}

.related {
  padding: 0;
  list-style: none;
}

.sources {
  color: var(--ash);
  font-size: 14px;
}

.sources a {
  color: var(--ash);
  overflow-wrap: anywhere;
}

.how {
  margin-top: 40px;
}

.how a {
  color: var(--ash);
}

/* The guides hub. */

.hub {
  margin: 8px 0 24px;
  padding: 0;
  list-style: none;
}

.hub li {
  margin: 0;
  padding: 16px 0;
  border-top: 1px solid var(--line);
}

.hub a {
  display: block;
  font-family: var(--head);
  font-size: 1.125rem;
  font-weight: 600;
  line-height: 1.3;
  text-decoration: none;
}

.hub a:hover {
  text-decoration: underline;
}

.hub span {
  display: block;
  margin-top: 4px;
  color: var(--ash);
  font-size: 15px;
}

/* Home: questions, then the guides, before the closing panel. */

/* Lined up with the other sections' left edge, at a reading width. */
.home .faq > *,
.home .guides-home > * {
  max-width: var(--measure);
}

.guides-home .more {
  margin-top: 8px;
}

.faq h3 {
  margin: 28px 0 6px;
  font-size: 1.125rem;
}

.faq p {
  color: var(--ash);
}

.faq .more {
  margin-top: 32px;
}

/* Footer */

.foot {
  border-top: 1px solid var(--line);
  color: var(--ash);
  font-size: 14px;
}

.foot .wrap {
  padding-top: 24px;
  padding-bottom: 40px;
  text-align: center;
}

.foot ul {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 4px 20px;
  margin: 0 0 12px;
  padding: 0;
  list-style: none;
}

.foot li {
  margin: 0;
}

.foot p {
  margin: 0;
}

.foot a {
  color: var(--ash);
}

.foot a:hover {
  color: var(--accent);
}

/* Not found */

.lost {
  padding: 96px 0 120px;
  text-align: center;
}

.lost .led {
  font-size: clamp(96px, 26vw, 180px);
}

.lost h1 {
  margin: 16px 0 8px;
}

.lost p {
  color: var(--ash);
}

@media (prefers-reduced-motion: no-preference) {
  .js .reveal,
  .js .stagger > li {
    opacity: 0;
    transform: translateY(28px);
    transition:
      opacity 0.9s cubic-bezier(0.2, 0.7, 0.2, 1) var(--d, 0s),
      transform 1.1s cubic-bezier(0.2, 0.7, 0.2, 1) var(--d, 0s);
  }

  .js .reveal.in,
  .js .stagger.in > li {
    opacity: 1;
    transform: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  * {
    scroll-behavior: auto !important;
    animation: none !important;
  }
}

/* Print: legal pages get printed and saved as PDF. */

@media print {
  :root {
    color-scheme: light;
  }

  html,
  body {
    background: #fff;
    color: #000;
    font-size: 11pt;
  }

  h1,
  h2,
  h3,
  strong,
  a {
    color: #000;
  }

  .skip,
  .bar nav,
  .contents {
    display: none;
  }

  .summary {
    border-color: #999;
    background: none;
  }

  .doc .bar,
  .foot {
    border-color: #999;
  }
}
