/* Curet — chapters of flat colour. Each pet's colour is a chapter; the pet peeks over the chapter's top edge. */

@font-face {
  font-family: "Nunito";
  src: url("assets/fonts/nunito-latin.woff2") format("woff2");
  font-weight: 200 1000;
  font-style: normal;
  font-display: swap;
}

:root {
  --peach: #ffe6d2;
  --paper: #fff7ee;
  --ink: #33201f;
  --soft: #6a4a43;          /* secondary text on light fields */
  --soft-dark: #dcc3b6;     /* secondary text on cocoa */
  --tangerine: #f7924f;
  --pink: #f4a3c1;
  --mint: #7addb6;
  --sky: #9ed7ff;
  --butter: #ffd75e;
  --coral: #ff7a59;
  --peach-dark: #ffc9a3;

  --margin: clamp(18px, 4vw, 60px);
  /* the cat peeking over the top of "One Tuesday"; the hero bubble points down at it, so both share this */
  --cat-w: min(24vw, 330px, 40svh);
  --radius: 22px;

  /* five type steps */
  --t-small: 18px;
  --t-body: clamp(19px, 1.95vw, 30px);
  --t-clause: clamp(26px, 3.1vw, 49px);
  --t-head: clamp(42px, 6.8vw, 106px);
  --t-hero: clamp(64px, 8.8vw, 140px);

  --ease: cubic-bezier(0.2, 0.8, 0.2, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: "Nunito", ui-rounded, "SF Pro Rounded", system-ui, sans-serif;
  font-size: var(--t-body);
  line-height: 1.5;
  font-weight: 600;
  color: var(--ink);
  background: var(--peach);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img { display: block; max-width: 100%; height: auto; }
h1, h2, p { margin: 0; }
h1, h2 { font-weight: 900; letter-spacing: -0.03em; line-height: 0.98; text-wrap: balance; }
a { color: inherit; }
:focus-visible { outline: 3px solid var(--ink); outline-offset: 3px; border-radius: 8px; }
::selection { background: var(--ink); color: var(--peach); }
code { font-family: ui-monospace, "SF Mono", Menlo, monospace; font-size: 0.86em; background: rgba(51, 32, 31, 0.1); padding: 0.1em 0.4em; border-radius: 6px; overflow-wrap: anywhere; }

/* ---------------------------------------------------------- shared pieces */
.button {
  display: inline-block; background: var(--ink); color: var(--paper); text-decoration: none;
  font-weight: 800; font-size: var(--t-body); padding: 16px 30px; border-radius: 999px;
  transition: transform 0.18s var(--ease), background-color 0.18s;
}
.button:hover { transform: translateY(-3px) rotate(-1deg); background: #000; }
.button:active { transform: translateY(0); }
.button.dark { background: var(--ink); }
.textlink { font-weight: 800; text-underline-offset: 4px; text-decoration-thickness: 3px; text-decoration-color: currentColor; }
.fine { font-size: var(--t-small); font-weight: 700; color: var(--soft); }
.wordmark { font-weight: 900; font-size: var(--t-clause); letter-spacing: -0.04em; text-decoration: none; line-height: 1; }
.wordmark b { color: var(--tangerine); font-weight: 900; }
.wordmark.small { font-size: var(--t-body); }

/* Interface fragments are built from the app's own pieces: the speech bubble and its buttons. */
.bubble {
  background: var(--paper); color: var(--ink); border: 3px solid var(--ink); border-radius: 20px;
  padding: 14px 16px; position: relative; font-weight: 700; font-size: 16px; line-height: 1.4;
}
.bubble::after {
  content: ""; position: absolute; left: 50%; bottom: -10px; width: 16px; height: 16px; margin-left: -8px; background: var(--paper);
  border: 3px solid var(--ink); border-top: 0; border-left: 0; transform: rotate(45deg);
}
.bubble-actions { display: flex; gap: 8px; margin-top: 10px; }
.b { display: inline-block; padding: 5px 13px; border-radius: 999px; background: var(--peach); border: 2px solid var(--ink); font-weight: 800; font-size: var(--t-small); }
.b.go { background: var(--mint); }

.reveal { opacity: 1; }
.js .reveal { opacity: 0; transform: translateY(24px); transition: opacity 0.7s var(--ease), transform 0.7s var(--ease); transition-delay: calc(var(--d, 0) * 90ms); }
.js .reveal.in { opacity: 1; transform: none; }

/* A pet peeking over the top edge of a chapter: only the top of the picture is shown, cut flat on the edge. */
.peek { position: absolute; z-index: 4; left: var(--x); top: 0; width: var(--w); transform: translate(-50%, -100%); pointer-events: none; }
/* Cut flat only along the bottom edge, so ears and sides stay whole while it sways or walks. */
.peek .crop { height: calc(var(--w) * var(--r) * 0.6); clip-path: inset(-40% -40% 0 -40%); }
.peek .crop img { width: 100%; height: auto; transform-origin: 50% 100%; animation: peek-bob 5.5s ease-in-out infinite; }
/* the signature move: the hero cat opens from the bottom edge like a shutter */
.peek-cat .crop { animation: shutter 1.1s var(--ease) 0.25s both; transform-origin: 50% 100%; }
@keyframes shutter { from { clip-path: inset(100% -40% 0 -40%); transform: scale(1.12); } to { clip-path: inset(-40% -40% 0 -40%); transform: none; } }
@keyframes peek-bob { 0%, 100% { transform: translateY(2%) rotate(-1.2deg); } 50% { transform: translateY(0) rotate(1.2deg); } }
/* The cat's front paws over the edge, in its own cream fur with soft shading so they read as part of the picture. */
.paw {
  position: absolute; bottom: calc(var(--w) * -0.03); width: calc(var(--w) * 0.19); height: calc(var(--w) * 0.12);
  border-radius: 50% 50% 44% 44% / 62% 62% 38% 38%;
  background: radial-gradient(120% 110% at 42% 22%, #fffdf8 0%, #fbe9d3 48%, #ecc79f 100%);
  box-shadow: 0 3px 6px rgba(70, 38, 20, 0.22), inset 0 -3px 5px rgba(196, 128, 72, 0.25);
  transform-origin: 50% 100%;
}
/* two soft creases for toes */
.paw::before, .paw::after { content: ""; position: absolute; top: 18%; width: 2px; height: 34%; border-radius: 2px; background: rgba(196, 128, 72, 0.35); }
.paw::before { left: 36%; } .paw::after { right: 36%; }
.paw.l { left: 22%; } .paw.r { right: 22%; }
/* Walking in: paws patter one after the other and the body sways, until it stops. */
.peek-cat.walking .paw { animation: patter 0.34s ease-in-out infinite alternate; }
.peek-cat.walking .paw.r { animation-delay: -0.17s; }
.peek-cat.walking .crop img { animation: waddle 0.34s ease-in-out infinite alternate; }
@keyframes patter { from { transform: translateY(0) scaleY(1); } to { transform: translateY(-38%) scaleY(1.06); } }
@keyframes waddle { from { transform: translateY(1%) rotate(-3deg); } to { transform: translateY(-1%) rotate(3deg); } }

section { position: relative; }

/* ---------------------------------------------------------- hero */
.hero { min-height: 100svh; background: var(--peach); overflow: hidden; display: flex; flex-direction: column; justify-content: center; padding: 120px var(--margin) 160px; }
.nav { position: absolute; top: 0; left: 0; right: 0; z-index: 5; display: flex; justify-content: space-between; align-items: center; padding: 28px var(--margin); }
.nav nav { display: flex; gap: clamp(16px, 2.4vw, 36px); }
.nav nav a { font-weight: 800; text-decoration: none; padding: 6px 2px; }
.nav nav a:hover { text-decoration: underline; text-decoration-thickness: 3px; text-underline-offset: 6px; }
.hero-disc { position: absolute; z-index: 0; width: 112vh; height: 112vh; border-radius: 50%; background: var(--pink); left: calc(82vw - 56vh); top: calc(54svh - 56vh); }
.hero-copy { position: relative; z-index: 2; max-width: 46rem; }
.hero-copy h1 { font-size: var(--t-hero); }
.hero-copy > p { margin-top: 28px; max-width: 30em; }
.hero-copy > p:first-of-type { margin-top: 36px; }
.hero-bubble {
  --bw: min(300px, 28vw);
  position: absolute; z-index: 3; width: var(--bw); transform-origin: 50% 100%;
  /* centred over the peeking cat at 84%, kept on screen, and stood just above the cat's ears at any height */
  /* --bx follows the cat as it walks in (main.js) */
  left: min(calc(var(--bx, 84%) - var(--bw) / 2), calc(100% - var(--bw) - 16px));
  bottom: calc(var(--cat-w) * 1.19 * 0.6 + 26px);
}
.hero-bubble::after { left: 50%; }
.hero-bubble.talk { animation: nudge-in 0.28s var(--ease); }
@keyframes nudge-in { from { transform: translateY(5px) scale(0.98); } }

/* The seven pets in the hero, dressed up (hero-pets.js places them). Each sits in its own spot; hovering lifts
   it and shows its tagline, clicking makes it jump. Hops and jumps move only the inner .hp-hop, hover only
   .hp-body, and the spot only .hp, so no two motions ever fight over the same transform. */
.hero-pets { position: absolute; inset: 0; z-index: 65; pointer-events: none; }
.hero-pets .hp {
  position: absolute; left: 0; top: 0; z-index: 10; padding: 0; margin: 0; border: 0; background: none; cursor: pointer;
  pointer-events: auto; -webkit-tap-highlight-color: transparent; font: inherit; color: inherit;
}
.hero-pets.placed .hp { transition: transform 0.5s var(--ease); }
.hero-pets .hp:focus-visible { outline: none; }
.hero-pets .hp:focus-visible .hp-body { outline: 3px solid var(--ink); outline-offset: 4px; border-radius: 18px; }
.hp-hop, .hp-body { position: absolute; inset: 0; display: block; transform-origin: 50% 100%; }
.hp-body { transition: transform 0.25s var(--ease), filter 0.25s; animation: hp-in 0.6s var(--ease) both; animation-delay: calc(0.3s + var(--i) * 80ms); }
.hp-body img { width: 100%; height: 100%; display: block; user-select: none; -webkit-user-drag: none; filter: drop-shadow(0 6px 8px rgba(51, 32, 31, 0.18)); }
.hp-acc { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; pointer-events: none; }
.hp:hover .hp-body, .hp:focus-visible .hp-body { transform: translateY(-6%) rotate(-2deg); }
.hp:hover, .hp:focus-visible { z-index: 30 !important; }
@keyframes hp-in { from { opacity: 0; transform: translateY(12px); } }
.hp-hop.hop { animation: hp-hop 0.48s var(--ease); }
.hp-hop.jump { animation: hp-jump 0.62s var(--ease); }
@keyframes hp-hop { 0%, 100% { transform: none; } 45% { transform: translateY(calc(var(--s) * -0.1)); } }
@keyframes hp-jump {
  0%, 100% { transform: none; }
  40% { transform: translateY(calc(var(--s) * -0.16)) rotate(-5deg); }
  70% { transform: translateY(calc(var(--s) * -0.05)) rotate(4deg); }
}
/* the tagline: a small speech-bubble label above the pet, clear of its hat */
.hp-tip {
  --shift: 0px;
  position: absolute; left: 50%; bottom: calc(100% + var(--rise, 0px) + 10px); width: max-content; max-width: 220px;
  transform: translate(calc(-50% + var(--shift)), 6px); opacity: 0; pointer-events: none;
  background: var(--paper); color: var(--ink); border: 2.5px solid var(--ink); border-radius: 14px; box-shadow: 0 3px 0 var(--ink);
  padding: 6px 11px 7px; font-size: 14px; line-height: 1.3; font-weight: 700; text-align: left; white-space: normal;
  transition: opacity 0.18s, transform 0.18s var(--ease);
}
.hp-tip b { display: block; font-weight: 900; font-size: 15px; }
.hp:hover .hp-tip, .hp:focus-visible .hp-tip { opacity: 1; transform: translate(calc(-50% + var(--shift)), 0); }
@media (prefers-reduced-motion: reduce) {
  .hp-body { animation: none; }
  .hero-pets.placed .hp, .hp-body, .hp-tip { transition: none; }
}

/* ---------------------------------------------------------- one Tuesday */
/* The finished composition: four colour fields side by side. This is what a phone, reduced motion and a failed script show. */
.day .scene-stage { display: grid; grid-template-columns: repeat(4, 1fr); min-height: 84svh; }
.field { position: relative; display: flex; flex-direction: column; justify-content: flex-end; padding: 0 calc(var(--margin) / 2) 32px var(--pad-l, calc(var(--margin) / 2)); min-height: 84svh; }
.f-sky { background: var(--sky); } .f-butter { background: var(--butter); } .f-pink { background: var(--pink); } .f-mint { background: var(--mint); }
.day-title { position: absolute; z-index: 3; top: 40px; left: var(--margin); font-size: var(--t-head); }
.f-sky { --pad-l: var(--margin); }
.time { position: absolute; left: var(--pad-l, calc(var(--margin) / 2)); top: 25%; font-size: var(--t-head); font-weight: 900; letter-spacing: -0.03em; line-height: 1; }
.time span { display: inline-block; }
.time small { font-size: 0.34em; font-weight: 800; letter-spacing: 0; margin-left: 0.14em; }
.card { position: absolute; left: var(--pad-l, calc(var(--margin) / 2)); top: 40%; width: min(280px, calc(100% - var(--margin))); }
.clause { font-size: var(--t-clause); line-height: 1.12; font-weight: 800; max-width: 11em; text-wrap: balance; }
.walker { display: none; }

/* The live scene: the stage is held for a few screens, and scrolling plays the day. The fields stack and wipe in. */
html.js .day.is-live .scene-stage { display: block; background: var(--sky); }
.day.is-live .field { position: absolute; inset: 0; min-height: 0; padding: 0; isolation: isolate; }
.day.is-live .time { font-size: clamp(100px, 22.1vw, 390px); left: var(--margin); top: 21%; line-height: 0.92; }
.day.is-live .card { left: auto; right: var(--margin); top: 30%; width: min(480px, 41vw); padding: 17px 19px; border-radius: 24px; }
.day.is-live .card .bubble-text { font-size: 21.6px; }
.day.is-live .card .b { font-size: 21.6px; padding: 6px 16px; }
.day.is-live .card .bubble-actions { gap: 10px; margin-top: 12px; }
.day.is-live .clause { position: absolute; left: var(--margin); bottom: 72px; font-size: clamp(26px, 3.64vw, 57.2px); max-width: 11em; }
.day.is-live .walker { display: block; position: absolute; z-index: 4; bottom: -4px; left: 0; width: clamp(110px, 11vw, 180px); height: auto; transform-origin: 50% 100%; }


/* ---------------------------------------------------------- five pets */
.pets { background: var(--ink); color: var(--paper); }
.pets .scene-stage { padding: 140px var(--margin) 100px; min-height: 100svh; }
html.js .pets.is-live > .scene-stage { padding: 96px var(--margin) 56px; min-height: 0; display: flex; align-items: center; }
html.js .pets.is-live .pets-grid { width: 100%; min-height: 0; }
.pets-grid { display: grid; grid-template-columns: repeat(12, 1fr); column-gap: 24px; align-items: end; min-height: calc(100svh - 240px); }
.pets-list { grid-column: 1 / span 5; display: flex; flex-direction: column; align-items: flex-start; gap: 4px; align-self: end; }
.pets-list h2 { font-size: clamp(28px, 3.77vw, 57.2px); line-height: 1.15; color: var(--soft-dark); letter-spacing: -0.02em; margin-bottom: 4px; }
.pets-list button {
  appearance: none; background: none; border: 0; padding: 2px 0; font: inherit; font-weight: 900; font-size: clamp(32px, 4.81vw, 75.4px);
  letter-spacing: -0.03em; line-height: 1.08; color: var(--soft-dark); cursor: pointer; text-align: left;
  transition: transform 0.2s var(--ease), color 0.2s;
}
.pets-list button:hover { transform: translateX(8px); color: var(--paper); }
.pets-list button[aria-pressed="true"] { color: var(--paper); }
.pets-list button:focus-visible { outline-color: var(--paper); }
.stage { --disc: min(64vh, 620px); grid-column: 6 / span 7; position: relative; height: calc(var(--disc) + 40px); align-self: center; }
.disc { position: absolute; left: calc(50% - var(--disc) / 2); top: calc(50% - var(--disc) / 2); width: var(--disc); aspect-ratio: 1; border-radius: 50%; background: #9ed7ff; transition: background-color 0.45s var(--ease); }
/* the pet stands in front of the disc and breaks its outline at the top */
.stage-pet { position: absolute; left: 0; right: 0; margin: 0 auto; top: calc(50% - var(--disc) * 0.54); height: calc(var(--disc) * 0.86); width: auto; max-width: calc(var(--disc) * 0.96); object-fit: contain; transform-origin: 50% 100%; animation: peek-bob 6s ease-in-out infinite; transition: opacity 0.3s; }
.stage-pet.swap { opacity: 0; }
.fact { grid-column: 9 / span 4; align-self: end; font-size: var(--t-body); max-width: 20em; padding-bottom: 8px; }

/* ---------------------------------------------------------- the board of close-ups */
.board-wrap { background: var(--peach); padding: 130px var(--margin) 96px; }
.board { display: grid; grid-template-columns: repeat(12, 1fr); grid-auto-rows: 104px; gap: 8px; }
.tile { container-type: inline-size; position: relative; top: 0; overflow: hidden; border-radius: var(--radius); padding: 20px; display: flex; flex-direction: column; justify-content: flex-end; transition: top 0.2s var(--ease); }
.tile:hover { top: -4px; }
.tile h2 { font-size: var(--t-head); }
.t-head { grid-column: 1 / span 6; grid-row: 1 / span 2; background: transparent; padding: 0; justify-content: flex-start; }
.t-head:hover { top: 0; }
.t-join { grid-column: 7 / span 6; grid-row: 1 / span 4; }
.t-keys { grid-column: 1 / span 3; grid-row: 3 / span 4; }
.t-brief { grid-column: 4 / span 3; grid-row: 3 / span 2; }
.t-add { grid-column: 4 / span 6; grid-row: 5 / span 2; }
.t-tick { grid-column: 10 / span 3; grid-row: 5 / span 2; }
.t-focus { grid-column: 1 / span 6; grid-row: 7 / span 2; }
.t-week { grid-column: 7 / span 6; grid-row: 7 / span 2; }
.c-butter { background: var(--butter); } .c-pink { background: var(--pink); } .c-sky { background: var(--sky); }
.c-mint { background: var(--mint); } .c-coral { background: var(--coral); } .c-peachdark { background: var(--peach-dark); }
.cap { position: relative; z-index: 2; font-size: 23px; line-height: 1.3; max-width: 26em; }
.cap b { display: block; font-size: var(--t-body); font-weight: 900; margin-bottom: 2px; }
/* each close-up is a real piece of the app, enlarged and pushed off-centre so the tile crops it */
.zoom { position: absolute; font-size: var(--zs, 3.4em); line-height: 1.05; font-weight: 900; letter-spacing: -0.03em; white-space: nowrap; }
.zoom p { font-weight: 900; }
.z-join { --zs: min(42px, 7.4cqi); right: 24px; top: 40px; display: flex; flex-direction: column; gap: 20px; align-items: flex-start; white-space: normal; width: 70%; }
.z-join p { font-size: 1.5em; line-height: 1.02; }
.z-join .b { font-size: 0.7em; padding: 8px 26px; border-width: 4px; }
.z-keys { --zs: min(78px, 21cqi); left: 18px; top: 24px; display: flex; flex-direction: column; gap: 14px; }
.z-keys kbd { font: inherit; background: var(--paper); border: 4px solid var(--ink); border-radius: 22px; width: 1.5em; height: 1.4em; display: grid; place-items: center; }
.z-keys kbd:nth-child(2) { margin-left: 1.1em; } .z-keys kbd:nth-child(3) { margin-left: 2.3em; }
.z-brief { --zs: min(30px, 11.5cqi); left: 16px; top: 10px; display: flex; align-items: center; gap: 14px; }
.toggle { width: 2.2em; height: 1.2em; border-radius: 999px; background: var(--ink); position: relative; flex: none; }
.toggle::after { content: ""; position: absolute; right: 0.14em; top: 0.14em; width: 0.92em; height: 0.92em; border-radius: 50%; background: var(--mint); }
.z-add { --zs: min(38px, 6.4cqi); left: 22px; top: 18px; }
.z-add .b { font-size: 1em; padding: 6px 24px; border-width: 4px; }
.z-tick { --zs: min(24px, 10cqi); left: 18px; top: 18px; right: 12px; display: flex; align-items: flex-start; gap: 12px; white-space: normal; }
.check { width: 1.4em; height: 1.4em; border-radius: 8px; background: var(--mint); border: 3px solid var(--ink); position: relative; flex: none; }
.check::after { content: ""; position: absolute; left: 28%; top: 6%; width: 28%; height: 56%; border: solid var(--ink); border-width: 0 4px 4px 0; transform: rotate(40deg); }
.z-focus { --zs: min(40px, 8cqi); right: 24px; top: 12px; display: flex; align-items: center; gap: 18px; }
.orb { width: 1.8em; height: 1.8em; border-radius: 50%; background: var(--mint); border: 4px solid var(--ink); display: grid; place-items: center; flex: none; }
.orb svg { width: 56%; height: 56%; }
.z-week { --zs: min(38px, 6.4cqi); left: 26px; top: 12px; white-space: normal; width: 86%; }

/* ---------------------------------------------------------- syllabus → calendar → study blocks (a demo you click) */
.plan { background: var(--mint); padding: 110px var(--margin) 88px; display: flex; flex-direction: column; gap: 36px; }
.plan-head { display: flex; align-items: end; justify-content: space-between; gap: 24px; flex-wrap: wrap; }
.plan-head h2 { font-size: var(--t-head); }
.plan-try { font-size: var(--t-clause); font-weight: 900; letter-spacing: -0.02em; }
.plan-flow { display: grid; grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.35fr) minmax(0, 0.9fr); gap: 24px; align-items: start; }
.step { display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.step-n { display: flex; align-items: center; gap: 10px; font-size: var(--t-clause); font-weight: 900; letter-spacing: -0.02em; line-height: 1; }
.step-n b { display: grid; place-items: center; width: 1.5em; height: 1.5em; border-radius: 50%; background: var(--ink); color: var(--paper); font-size: 0.8em; }

/* fragments of the app's own panel: cream paper, cocoa outline, hard shadow */
.mini-panel { background: var(--paper); color: var(--ink); border: 3px solid var(--ink); border-radius: 22px; box-shadow: 0 5px 0 var(--ink); padding: 16px 18px; font-size: 15px; line-height: 1.35; font-weight: 700; }
.mp-h { display: inline-block; font-weight: 900; font-size: 16px; padding: 0 5px; margin: 0 0 8px -5px; background: linear-gradient(transparent 55%, var(--sky) 55%); border-radius: 3px; }
.syl-list { list-style: none; margin: 0 0 12px; padding: 0; display: grid; gap: 2px; }
.syl-item { width: 100%; display: flex; align-items: center; gap: 12px; padding: 7px 6px; border: 0; border-radius: 12px; background: none; font: inherit; color: inherit; text-align: left; cursor: pointer; transition: background-color 0.15s, opacity 0.15s; }
.syl-item:hover { background: rgba(51, 32, 31, 0.06); }
.syl-item:not(.on) { opacity: 0.55; }
.syl-item span { display: flex; flex-direction: column; min-width: 0; }
.syl-item b { font-weight: 900; font-size: 16px; }
.syl-item small { font-size: 12.5px; font-weight: 600; color: var(--soft); }
.tick { width: 24px; height: 24px; flex: none; border: 2px solid var(--ink); border-radius: 8px; background: #fff; box-shadow: 0 2px 0 var(--ink); position: relative; transition: background-color 0.15s; }
.on .tick { background: var(--mint); }
.on .tick::after { content: ""; position: absolute; left: 7px; top: 2px; width: 5px; height: 11px; border: solid var(--ink); border-width: 0 3px 3px 0; transform: rotate(40deg); }
button.b { font: inherit; font-weight: 800; color: var(--ink); cursor: pointer; transition: transform 0.1s ease-out, box-shadow 0.1s ease-out; box-shadow: 0 2px 0 var(--ink); }
button.b:hover:not(:disabled) { transform: translateY(-1px); box-shadow: 0 3px 0 var(--ink); }
button.b:active:not(:disabled) { transform: translateY(2px); box-shadow: 0 0 0 var(--ink); }
button.b:disabled { opacity: 0.6; cursor: default; }
.b.wide { display: block; width: 100%; text-align: center; padding: 9px 14px; font-size: 15px; }
.demo-add.nudge { animation: nudge 1.6s ease-in-out infinite; }
@keyframes nudge { 0%, 70%, 100% { transform: none; } 80% { transform: translateY(-3px); } 90% { transform: translateY(1px); } }

.gcal { padding: 14px 16px 12px; }
.week { display: grid; grid-template-columns: 24px repeat(5, minmax(0, 1fr)); grid-template-rows: 22px 28px repeat(10, 24px); column-gap: 5px; background: repeating-linear-gradient(to bottom, transparent 0 23px, rgba(51, 32, 31, 0.08) 23px 24px); background-position: 0 50px; background-repeat: no-repeat; background-size: 100% calc(100% - 50px); }
.wd { grid-row: 1; text-align: center; font-size: 13px; font-weight: 900; }
.hr { grid-column: 1; font-size: 11px; font-weight: 800; color: var(--soft); align-self: start; margin-top: -7px; }
.ev { position: relative; z-index: 1; margin: 1px 0; padding: 3px 6px; border-radius: 8px; border: 2px solid var(--ink); font-size: 11.5px; line-height: 1.15; font-weight: 900; overflow: hidden; }
.ev.syl { background: var(--coral); }
.ev.study { background: var(--mint); }
.ev.cls { background: var(--sky); }
.ev.allday { align-self: center; margin: 0; padding: 2px 6px; }
/* in the demo, syllabus items and study blocks appear as you click */
.plan-flow.live .ev[data-ev], .plan-flow.live .ev[data-slot] { visibility: hidden; }
.plan-flow.live .ev.show { visibility: visible; animation: ev-in 0.42s var(--ease) both; }
.plan-flow.live .ev.preview { background: transparent; border-style: dashed; animation: ev-in 0.3s var(--ease) both; }
.plan-flow.live .ev.booked { background: var(--mint); border-style: solid; animation: ev-book 0.45s var(--ease) both; }
@keyframes ev-in { from { opacity: 0; transform: translateY(-8px) scale(0.85); } }
@keyframes ev-book { 0% { transform: scale(1); } 40% { transform: scale(1.08); } 100% { transform: none; } }
.legend { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 14px; margin-top: 10px; font-size: 12px; font-weight: 700; color: var(--soft); }
.legend i { display: inline-block; width: 12px; height: 12px; border: 2px solid var(--ink); border-radius: 4px; margin-right: -8px; vertical-align: -2px; }
.legend i.syl { background: var(--coral); } .legend i.study { background: var(--mint); } .legend i.cls { background: var(--sky); }

.offer { display: flex; flex-direction: column; align-items: center; }
.offer-bubble { width: 100%; font-size: 16px; min-height: 96px; }
.offer-bubble .bubble-actions { flex-wrap: wrap; }
.offer-bubble .bubble-actions:empty { display: none; }
.offer-bubble.talk { animation: talk 0.3s var(--ease); }
@keyframes talk { from { transform: translateY(6px) scale(0.97); opacity: 0.4; } }
.offer-pet { width: 52%; max-width: 190px; margin-top: 18px; transform-origin: 50% 100%; animation: peek-bob 5s ease-in-out infinite; }

.chips { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 10px; }
.chips li { background: var(--paper); border: 2.5px solid var(--ink); border-radius: 999px; box-shadow: 0 3px 0 var(--ink); padding: 7px 16px; font-weight: 900; font-size: 15px; }

/* ---------------------------------------------------------- looks after you */
.care { background: var(--peach); padding: 130px var(--margin) 96px; }
.care-board { grid-auto-rows: 96px; }
.care-board .t-head { grid-column: 1 / span 5; grid-row: 1 / span 2; }
.care-board .t-head h2 { font-size: clamp(36px, 5.2vw, 80px); } /* two lines, inside its two-row tile */
.k-procrast { grid-column: 6 / span 7; grid-row: 1 / span 3; }
.k-week { grid-column: 1 / span 5; grid-row: 3 / span 3; }
.k-eyes { grid-column: 6 / span 3; grid-row: 4 / span 2; }
.k-journal { grid-column: 9 / span 4; grid-row: 4 / span 3; }
.k-late { grid-column: 1 / span 3; grid-row: 6 / span 4; }
.k-mood { grid-column: 4 / span 5; grid-row: 6 / span 2; }
.k-voice { grid-column: 9 / span 4; grid-row: 7 / span 3; }
.k-dress { grid-column: 4 / span 5; grid-row: 8 / span 2; }
.c-ink { background: var(--ink); color: var(--paper); }
.k-bubble { position: absolute; left: 22px; top: 22px; width: min(420px, calc(100% - 44px)); font-size: clamp(15px, 1.82vw, 24.7px); }
.k-bubble .bubble-actions { flex-wrap: wrap; }
.k-chart { position: absolute; left: 20px; right: 20px; top: 18px; }
.k-big { font-size: clamp(28px, 3.9vw, 57.2px); font-weight: 900; letter-spacing: -0.03em; line-height: 1; }
.k-big small { font-size: 0.42em; font-weight: 800; letter-spacing: 0; }
.k-bars { display: grid; grid-template-columns: repeat(7, 1fr); gap: 8px; align-items: end; height: 88px; margin-top: 12px; border-bottom: 3px solid var(--ink); }
.k-bars i { display: block; height: var(--h); background: var(--paper); border: 2.5px solid var(--ink); border-bottom: 0; border-radius: 6px 6px 0 0; }
.k-days { display: grid; grid-template-columns: repeat(7, 1fr); gap: 8px; text-align: center; font-size: 12px; font-weight: 900; margin-top: 4px; }
.k-ring { position: absolute; left: 18px; top: 14px; width: 74px; height: 74px; display: grid; place-items: center; }
.k-ring svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.k-ring span { font-weight: 900; font-size: 18px; }
.k-lines { position: absolute; left: 20px; right: 20px; top: 18px; display: grid; gap: 14px; }
.k-lines p { font-weight: 900; font-size: clamp(17px, 2.08vw, 28.6px); line-height: 1.15; letter-spacing: -0.01em; }
.k-lines i { display: block; height: 2px; background: rgba(51, 32, 31, 0.28); }
.k-quote { position: absolute; left: 20px; right: 20px; top: 18px; font-weight: 900; font-size: clamp(17px, 1.95vw, 27.3px); line-height: 1.2; color: var(--paper); }
.care .cap b { font-size: clamp(18px, 2.08vw, 31.2px); letter-spacing: -0.01em; line-height: 1.15; }
.c-ink .cap { color: var(--soft-dark); }
.c-ink .cap b { color: var(--paper); }
.k-moods { position: absolute; left: 18px; top: 14px; right: 18px; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.k-moods img { width: 54px; height: auto; }
.k-wave { position: absolute; left: 22px; top: 22px; display: flex; align-items: center; gap: 5px; height: 44px; }
.k-wave i { width: 8px; border-radius: 99px; background: var(--ink); animation: wave 1.1s ease-in-out infinite; }
.k-wave i:nth-child(1) { height: 30%; } .k-wave i:nth-child(2) { height: 70%; animation-delay: 0.1s; } .k-wave i:nth-child(3) { height: 100%; animation-delay: 0.2s; }
.k-wave i:nth-child(4) { height: 55%; animation-delay: 0.3s; } .k-wave i:nth-child(5) { height: 85%; animation-delay: 0.4s; } .k-wave i:nth-child(6) { height: 40%; animation-delay: 0.5s; } .k-wave i:nth-child(7) { height: 20%; animation-delay: 0.6s; }
@keyframes wave { 50% { transform: scaleY(0.45); } }
.k-dress { flex-direction: row; align-items: center; justify-content: space-between; gap: 14px; }
.k-dress .cap { order: 2; }
.k-pets { position: static; display: flex; align-items: flex-end; gap: 6px; flex: none; }
.dressed-pet { position: relative; display: block; width: 46px; height: calc(46px * var(--ar)); }
.dressed-pet img { width: 100%; height: 100%; display: block; }
.dressed-pet .hp-acc { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }

/* ---------------------------------------------------------- setup */
.setup { background: var(--sky); padding: 130px var(--margin) 96px; }
.two { display: grid; grid-template-columns: repeat(12, 1fr); column-gap: 24px; align-items: start; }
.two > h2, .two > .side { grid-column: 1 / span 5; }
.two h2 { font-size: var(--t-head); }
.side { display: flex; flex-direction: column; gap: 28px; align-items: flex-start; }
.side .mini-panel { width: 100%; max-width: 440px; }
.paste { overflow-wrap: anywhere; font-size: 13px; font-weight: 600; color: var(--soft); margin-bottom: 10px; }
.paste-card .ok { margin-top: 10px; font-size: 13px; color: #1f8a63; }
.side-note { font-size: var(--t-clause); font-weight: 800; line-height: 1.15; max-width: 12em; color: var(--ink); opacity: 0.8; }
.setup ol { grid-column: 6 / span 7; margin: 0; padding: 0 0 0 1.4em; display: grid; gap: 28px; font-size: var(--t-body); max-width: 40em; }
.setup li { padding-left: 6px; }
.setup li::marker { font-weight: 900; font-size: 1.2em; }
.setup li b { font-weight: 900; font-size: var(--t-clause); letter-spacing: -0.02em; display: block; line-height: 1.1; margin-bottom: 6px; }

/* ---------------------------------------------------------- questions */
.faq { background: var(--pink); padding: 130px var(--margin) 96px; }
.acc { grid-column: 6 / span 7; display: grid; gap: 8px; }
.acc details { background: #f9bfd5; border-radius: var(--radius); transition: background-color 0.2s; }
.acc summary { list-style: none; cursor: pointer; display: flex; justify-content: space-between; align-items: center; gap: 16px; min-height: 72px; padding: 16px 24px; font-size: var(--t-body); font-weight: 800; border-radius: var(--radius); }
.acc summary::-webkit-details-marker { display: none; }
.acc summary { position: relative; padding-right: 64px; }
.acc summary::before, .acc summary::after { content: ""; position: absolute; right: 24px; top: 50%; width: 16px; height: 3px; margin-top: -1.5px; background: currentColor; border-radius: 2px; }
.acc summary::after { transition: transform 0.25s var(--ease); transform: rotate(90deg); }
.acc details[open] { background: var(--ink); color: var(--paper); }
.acc details[open] summary::after { transform: rotate(0deg); }
.acc details p { padding: 0 24px 22px; font-size: var(--t-body); max-width: 52ch; }
.acc details:not([open]):hover { background: #fbcade; }

/* ---------------------------------------------------------- closing call */
.cta { background: var(--tangerine); min-height: 64svh; padding: 120px var(--margin) 56px; display: grid; grid-template-columns: repeat(12, 1fr); column-gap: 24px; align-items: end; }
.cta-line { grid-column: 1 / span 6; align-self: end; }
.cta-line h2 { font-size: clamp(56px, 9.1vw, 145.6px); line-height: 0.92; }
.cta-line p { margin-top: 24px; max-width: 24em; }
.dialog { grid-column: 8 / span 4; align-self: center; background: var(--paper); border-radius: 28px; padding: 32px; width: 100%; max-width: 440px; justify-self: end; box-shadow: 0 24px 60px rgba(51, 32, 31, 0.35); } /* taste-skill-ignore: the dialog floats above the page */
.dialog-title { font-size: var(--t-clause); font-weight: 900; letter-spacing: -0.02em; line-height: 1.1; }
.dialog-sub { margin: 10px 0 26px; font-size: var(--t-body); }
.dialog p + p { margin-top: 18px; }

@media (max-width: 1180px) and (min-width: 861px) {
  .day.is-live .card { width: min(480px, 44vw); top: max(46%, calc(21% + 20vw + 10px)); } /* below the time, which fills the width here */
  .plan-flow { grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr); }
  .plan-flow > .step:last-child { grid-column: 1 / -1; }
  .offer { flex-direction: row; align-items: flex-end; justify-content: center; gap: 24px; }
  .offer-bubble { max-width: 440px; }
  .offer-pet { width: 140px; margin: 0; }
}

/* ---------------------------------------------------------- phones */
@media (max-width: 860px) {
  .nav nav a:nth-child(n+3) { display: none; }
  .hero { padding: 110px var(--margin) 0; justify-content: flex-start; min-height: 100svh; }
  .hero-copy h1 { font-size: 11.5vw; }
  .hero-disc { width: 130vw; height: 130vw; left: -15vw; top: 58svh; }
  .hero-bubble { position: relative; left: auto; bottom: auto; width: min(300px, 100%); margin-top: 28px; }
  .hero-bubble::after { left: 24%; }

  .pets, .setup, .faq, .cta { min-height: 0; }
  .day:not(.is-live) .scene-stage { grid-template-columns: repeat(2, 1fr); min-height: 0; }
  .day:not(.is-live) .field { min-height: 0; padding: 48px var(--margin) 44px; justify-content: flex-start; gap: 20px; }
  .day:not(.is-live) .time { position: static; order: 0; }
  .day:not(.is-live) .card { position: relative; left: auto; top: auto; width: min(300px, 100%); order: 2; }
  .day:not(.is-live) .day-title { position: static; grid-column: 1 / -1; font-size: 9vw; padding: 48px var(--margin) 0; }
  .day:not(.is-live) .clause { font-size: var(--t-clause); order: 1; }
  /* the live scene on a tablet: a smaller clock beside a narrower bubble */
  .day.is-live .time { font-size: 13.5vw; }
  .day.is-live .card { width: min(480px, 37vw); }
  .day.is-live .clause { font-size: clamp(24px, 3.4vw, 40px); }

  .pets .scene-stage { padding: 110px var(--margin) 60px; }
  .pets-grid { grid-template-columns: 1fr; min-height: 0; row-gap: 22px; }
  .stage { --disc: 80vw; grid-column: 1; grid-row: 1; }
  .pets-list { grid-column: 1; grid-row: 2; flex-direction: row; flex-wrap: wrap; align-items: baseline; gap: 4px 22px; width: 100%; }
  .pets-list h2 { display: none; }
  .pets-list button { font-size: 28px; white-space: nowrap; }
  .fact { grid-column: 1; grid-row: 3; font-size: 16px; }

  .board-wrap { padding: 110px var(--margin) 80px; }
  .board { grid-template-columns: repeat(2, 1fr); grid-auto-rows: min(28vw, 124px); gap: 6px; }
  .board-wrap .peek { left: 84%; }
  .tile { padding: 14px; }
  .t-head { grid-column: 1 / -1; grid-row: auto / span 2; }
  .t-head h2 { font-size: 9vw; }
  .t-join, .t-keys, .t-focus, .t-week, .t-add { grid-column: 1 / -1; grid-row: auto / span 3; }
  .t-brief, .t-tick { grid-column: auto / span 1; grid-row: auto / span 2; }
  .cap { font-size: 16px; } .cap b { font-size: 18px; }
  .z-join { --zs: 30px; right: auto; left: 16px; width: 90%; }
  .z-keys { --zs: 56px; flex-direction: row; left: 14px; }
  .z-keys kbd:nth-child(n) { margin-left: 0; }
  .z-add { --zs: 21px; } .z-week { --zs: 28px; } .z-focus { --zs: 30px; right: auto; left: 16px; }
  .z-brief { --zs: 20px; } .z-tick { --zs: 17px; white-space: normal; width: 86%; align-items: flex-start; }

  .plan, .care { padding: 110px var(--margin) 80px; }
  .plan { gap: 28px; }
  .plan-head h2 { font-size: 9vw; }
  .plan-flow { grid-template-columns: 1fr; }
  .offer-pet { width: 34%; max-width: 150px; }
  .week { grid-template-columns: 18px repeat(5, minmax(0, 1fr)); column-gap: 3px; }
  .ev { font-size: 9.5px; padding: 1px 3px; border-radius: 5px; }
  .care-board { grid-auto-rows: min(28vw, 118px); }
  .care-board .t-head { grid-column: 1 / -1; grid-row: auto / span 1; }
  .care-board .t-head h2 { font-size: 9vw; }
  .k-procrast, .k-week, .k-journal, .k-late { grid-column: 1 / -1; grid-row: auto / span 3; }
  .k-eyes, .k-mood, .k-voice { grid-column: auto / span 1; grid-row: auto / span 2; }
  .k-mood { grid-column: 1 / -1; }
  .k-dress { grid-column: 1 / -1; grid-row: auto / span 2; flex-direction: column; align-items: flex-start; justify-content: flex-end; }
  .k-dress .cap { order: 0; }
  .two { grid-template-columns: 1fr; row-gap: 28px; }
  .two > h2 { grid-column: 1; position: static; font-size: 9vw; }
  .setup, .faq { padding: 110px var(--margin) 80px; }
  .setup ol, .acc { grid-column: 1; }
  .acc summary { font-size: 18px; min-height: 64px; }
  .acc details p { font-size: 16px; padding: 0 20px 20px; }

  .cta { grid-template-columns: 1fr; align-content: start; row-gap: 32px; padding: 110px var(--margin) 48px; }
  .cta-line, .dialog { grid-column: 1; }
  .cta-line h2 { font-size: 13vw; }
  .dialog { max-width: none; justify-self: stretch; padding: 24px; }
  .dialog .button { display: block; text-align: center; padding: 18px; }

}

@media (max-width: 560px) {
  .day:not(.is-live) .scene-stage { grid-template-columns: 1fr; }
  .field { padding: 40px var(--margin); }
  .day:not(.is-live) .day-title { font-size: 12vw; padding-top: 40px; }
}

/* the Three.js layer: one fixed canvas that lets every click through */
#gl { position: fixed; inset: 0; width: 100%; height: 100%; z-index: 60; pointer-events: none; }
.scene > .scene-stage { z-index: 70; }
.gl .stage-pet, .gl .disc { opacity: 0; animation: none; }
:is(h1, h2, h3, p, li, summary, label, a, button, kbd) { position: relative; z-index: 70; }
.nav, .hero-copy, .hero-bubble, .card, .zoom, .cap, .bubble, .dialog, .day-title, .stage-pet, .tile, .acc details { z-index: 70; }
.acc details { position: relative; }
.dialog { position: relative; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .peek .crop img, .stage-pet { animation: none; }
  .js .reveal { opacity: 1; transform: none; transition: none; }
  .peek-cat .crop { animation: none; }
  *, *::before, *::after { transition-duration: 0.001ms !important; }
}
