/* Guidy website. Colours and type come from the app's design system
   (DesignSystem.swift) and the Marker Glow drawing style (DrawingStyle.swift). */

:root {
  --paper: #FAF6EF;
  --paper-shade: #F4F0E7;
  --paper-edge: #E7E0D2;
  --paper-edge-strong: #D6CCB8;
  --card: #FFFFFF;
  --ink: #22223A;
  --ink-soft: #6B6B85;
  --ink-faint: #A8A5BA;
  --marker: #3380FF;
  --marker-deep: #2563EB;
  --marker-text: #2E6FF2;
  --amber: #F59E0B;
  --page-width: 1040px;
  --page-gutter: 20px;
}

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

html { scroll-behavior: smooth; scroll-padding-top: 96px; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: Inter, -apple-system, BlinkMacSystemFont, "Helvetica Neue", sans-serif;
  font-size: 18px;
  line-height: 29px;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

h1, h2, h3, p, ol, figure { margin: 0; }
ol { padding: 0; list-style: none; }
a { color: inherit; text-decoration: none; }
i, em, u, b { font-style: normal; text-decoration: none; }

h2 {
  font-weight: 500;
  font-size: clamp(32px, 4.6vw, 44px);
  line-height: 1.14;
  letter-spacing: -0.035em;
}

.handwritten {
  font-family: Caveat, "Bradley Hand", cursive;
  font-weight: 600;
  font-size: 24px;
  line-height: 1.2;
  color: var(--marker-text);
}
.handwritten--muted { color: var(--ink-soft); }

a:focus-visible, summary:focus-visible {
  outline: 3px solid var(--marker);
  outline-offset: 3px;
  border-radius: 6px;
}

/* ── Nav ─────────────────────────────────────────────────────────── */

.site-nav {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
  padding: 0 40px;
  background: rgba(250, 246, 239, 0.86);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--paper-edge);
  font-size: 15px;
}
.site-nav__links, .site-nav__right { display: flex; align-items: center; flex: 1; }
.site-nav__links { gap: 32px; }
.site-nav__right { gap: 20px; justify-content: flex-end; }
.site-nav__links a, .site-nav__requirement { color: var(--ink-soft); }
.site-nav__links a { transition: color 0.15s; }
.site-nav__links a:hover { color: var(--ink); }
.site-nav__links .site-nav__wordmark {
  font-weight: 600;
  font-size: 20px;
  letter-spacing: -0.03em;
  color: var(--ink);
}
.site-nav__buddy { display: flex; transition: transform 0.25s; }
.site-nav__buddy:hover { transform: rotate(-10deg) scale(1.08); }
.site-nav__get { font-weight: 500; color: var(--marker-text); }
.site-nav__get:hover { text-decoration: underline; text-underline-offset: 4px; }

/* ── Shared pieces ───────────────────────────────────────────────── */

.download { display: flex; flex-direction: column; align-items: center; gap: 12px; }
.download-button {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  height: 52px;
  padding: 0 26px;
  border-radius: 26px;
  background: var(--marker);
  color: #fff;
  font-weight: 600;
  font-size: 17px;
  cursor: pointer;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.35) inset, 0 6px 18px rgba(51, 128, 255, 0.32);
  transition: transform 0.15s, box-shadow 0.15s, background 0.15s;
}
.download-button:hover {
  background: var(--marker-text);
  transform: translateY(-2px);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.35) inset, 0 10px 24px rgba(51, 128, 255, 0.4);
}
.download-button:active { transform: translateY(0); }
.download__note { font-size: 14px; line-height: 20px; color: var(--ink-soft); }

/* The Marker Glow line: hand-drawn blue ink that draws itself on. */
.marker-stroke { position: absolute; overflow: visible; pointer-events: none; }
.marker-stroke path, .marker-stroke__line {
  stroke: var(--marker);
  stroke-width: 4.5;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-dasharray: 1;
  stroke-dashoffset: 0;
}
.marker-stroke .marker-stroke__halo { stroke: #fff; stroke-width: 8; }

.ink-pill {
  position: absolute;
  display: inline-flex;
  align-items: center;
  height: 36px;
  padding: 0 16px;
  border-radius: 18px;
  background: var(--marker-deep);
  border: 3px solid #fff;
  box-shadow: 0 4px 12px rgba(34, 34, 58, 0.2);
  color: #fff;
  font-weight: 800;
  font-size: 16px;
  white-space: nowrap;
}
.ink-pill--small { height: 26px; padding: 0 10px; border-width: 2px; font-weight: 700; font-size: 12px; }

.waveform { display: inline-flex; align-items: center; gap: 3px; flex-shrink: 0; }
.waveform i { width: 3px; border-radius: 2px; background: var(--marker); }
.waveform i:nth-child(1) { height: 10px; }
.waveform i:nth-child(2) { height: 20px; }
.waveform i:nth-child(3) { height: 14px; }
.waveform i:nth-child(4) { height: 22px; }
.waveform i:nth-child(5) { height: 9px; }
.waveform--light i { background: #93C5FD; }
.waveform--large { gap: 5px; }
.waveform--large i { width: 5px; border-radius: 3px; }
.waveform--large i:nth-child(1) { height: 18px; background: #BFDBFE; }
.waveform--large i:nth-child(2) { height: 38px; background: #93C5FD; }
.waveform--large i:nth-child(3) { height: 60px; }
.waveform--large i:nth-child(4) { height: 30px; }
.waveform--large i:nth-child(5) { height: 72px; }
.waveform--large i:nth-child(6) { height: 44px; }
.waveform--large i:nth-child(7) { height: 64px; }
.waveform--large i:nth-child(8) { height: 26px; background: #93C5FD; }
.waveform--large i:nth-child(9) { height: 14px; background: #BFDBFE; }

.keycaps { display: flex; align-items: center; gap: 8px; }
.keycaps span { font-size: 16px; color: var(--ink-faint); }
.keycaps kbd {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 74px;
  height: 52px;
  border-radius: 10px;
  background: #fff;
  border: 1px solid var(--paper-edge-strong);
  box-shadow: 0 3px 0 var(--paper-edge-strong);
  font-family: inherit;
  font-weight: 500;
  font-size: 14px;
  color: var(--ink);
}
.keycaps--blue kbd {
  width: 86px;
  height: 48px;
  background: #EFF6FF;
  border-color: #93C5FD;
  box-shadow: 0 3px 0 #93C5FD;
  color: #1D4ED8;
}

/* ── Hero ────────────────────────────────────────────────────────── */

.hero {
  position: relative;
  max-width: 1440px;
  margin: 0 auto;
  padding: 150px 0 120px;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.hero__copy { display: flex; flex-direction: column; align-items: center; text-align: center; padding: 0 var(--page-gutter); }
.hero__hello { font-size: 26px; transform: rotate(-3deg); }
.hero h1 {
  font-weight: 500;
  font-size: clamp(76px, 13vw, 112px);
  line-height: 1.07;
  letter-spacing: -0.045em;
}
.hero__tagline { font-size: clamp(18px, 2.4vw, 22px); line-height: 1.45; padding-top: 8px; }
.hero .download { padding-top: 36px; }

.floater { position: absolute; }
.floater--files { left: 84px; top: 64px; transform: rotate(-4deg); }
.floater--hotkey { left: 170px; top: 330px; transform: rotate(3deg); display: flex; flex-direction: column; align-items: center; gap: 10px; }
.floater--hotkey .handwritten { font-size: 22px; }
.floater--question { right: 44px; top: 84px; transform: rotate(4deg); }
.floater--route { right: 90px; top: 270px; transform: rotate(-3deg); }

.mini-window {
  width: 270px;
  background: var(--card);
  border: 1px solid var(--paper-edge);
  border-radius: 12px;
  box-shadow: 0 10px 30px rgba(34, 34, 58, 0.08);
}
.mini-window__bar {
  display: flex;
  align-items: center;
  gap: 6px;
  height: 30px;
  padding: 0 12px;
  background: var(--paper-shade);
  border-bottom: 1px solid var(--paper-edge);
  border-radius: 12px 12px 0 0;
  font-size: 11px;
  line-height: 1;
  color: var(--ink-soft);
}
.mini-window__bar i, .demo-window__title i { width: 9px; height: 9px; border-radius: 50%; background: #F0A8A0; }
.mini-window__bar i:nth-child(2), .demo-window__title i:nth-child(2) { background: #F2D08A; }
.mini-window__bar i:nth-child(3), .demo-window__title i:nth-child(3) { background: #A9D8A5; }
.mini-window__bar span { padding-left: 8px; }
.mini-window__body { display: flex; flex-direction: column; gap: 10px; padding: 16px; }

.file-row { position: relative; display: flex; align-items: center; gap: 10px; height: 14px; font-size: 12px; font-weight: 500; line-height: 1; }
.file-row b { width: 18px; height: 14px; border-radius: 3px; background: #BFDBFE; }
.file-row u { height: 8px; border-radius: 4px; background: #ECE6DA; }
.file-row__box { left: -10px; top: -10px; width: 170px; height: 34px; }
.file-row__box path { stroke-width: 3.5; }
.file-row .ink-pill { left: 166px; top: -6px; }

.speech-bubble {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 18px;
  border-radius: 20px 20px 20px 6px;
  background: var(--card);
  border: 1px solid var(--paper-edge);
  box-shadow: 0 10px 30px rgba(34, 34, 58, 0.08);
  font-size: 16px;
  line-height: 22px;
  white-space: nowrap;
}

.mini-window--menu { width: 250px; }
.mini-window__bar--menu { gap: 16px; padding: 0 14px 0 48px; }
.mini-window__bar--menu span { padding: 0; }
.mini-window__bar--menu strong { font-weight: 600; color: var(--ink); }
.menu-route {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 16px 16px 18px 48px;
  font-size: 12px;
  line-height: 15px;
  color: var(--ink-soft);
}
/* The dotted trail joining the three numbered stops. */
.menu-route::before {
  content: "";
  position: absolute;
  left: 30px;
  top: -8px;
  bottom: 26px;
  border-left: 3px dotted var(--marker);
}
.menu-route__stop { position: relative; font-weight: 500; color: var(--ink); }
.menu-route__stop em {
  position: absolute;
  left: -29px;
  top: -4px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--marker-deep);
  border: 2px solid #fff;
  color: #fff;
  font-weight: 700;
  font-size: 11px;
}
.menu-route__stop--title { position: absolute; left: 48px; top: -23px; }

/* ── Demo window ─────────────────────────────────────────────────── */

.demo { display: flex; flex-direction: column; align-items: center; gap: 14px; width: 100%; padding: 84px var(--page-gutter) 0; }
.demo figcaption { font-size: 13px; line-height: 18px; color: var(--ink-faint); }
.demo-window {
  position: relative;
  width: 100%;
  max-width: var(--page-width);
  background: var(--card);
  border: 1px solid var(--paper-edge-strong);
  border-radius: 16px;
  box-shadow: 0 30px 80px rgba(34, 34, 58, 0.14);
}
.demo-window__toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 52px;
  padding: 0 18px;
  background: var(--paper-shade);
  border-bottom: 1px solid var(--paper-edge);
  border-radius: 16px 16px 0 0;
}
.demo-window__title { display: flex; align-items: center; gap: 8px; font-size: 14px; }
.demo-window__title i { width: 12px; height: 12px; }
.demo-window__title strong { font-weight: 600; padding-left: 14px; }
.demo-window__tools { display: flex; align-items: center; gap: 10px; }
.tool-blank { width: 30px; height: 28px; border-radius: 7px; background: #E3DCCC; }
.tool-search { width: 150px; height: 28px; border-radius: 7px; background: #ECE6DA; }
.share-target { position: relative; display: flex; }
.share-button {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 28px;
  border-radius: 7px;
  background: #fff;
  border: 1px solid var(--paper-edge-strong);
}
.share-target__box { left: -14px; top: -12px; width: 58px; height: 52px; z-index: 2; }
.share-target__pill { left: -32px; top: 48px; z-index: 3; }
.share-target__buddy { position: absolute; left: 48px; top: 32px; z-index: 3; transform: rotate(-14deg); }

.demo-window__body { display: flex; }
.demo-window__sidebar {
  display: flex;
  flex-direction: column;
  gap: 14px;
  width: 200px;
  flex-shrink: 0;
  padding: 22px 18px;
  background: #FBF9F4;
  border-right: 1px solid var(--paper-edge);
  border-radius: 0 0 0 16px;
  font-size: 14px;
  line-height: 18px;
  color: var(--ink-soft);
}
.demo-window__sidebar small { font-weight: 600; font-size: 11px; letter-spacing: 0.06em; color: var(--ink-faint); }
.demo-window__sidebar b { font-weight: 500; color: var(--ink); }
.photo-grid { flex: 1; display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; padding: 22px 22px 34px; }
.photo-grid i { aspect-ratio: 186 / 140; border-radius: 10px; }
.photo-grid__selected { outline: 3px solid var(--marker); outline-offset: 2px; }
.tint-blue { background: #DCE9FB; }
.tint-sand { background: #F8E3C4; }
.tint-pink { background: #F9DCE4; }
.tint-mint { background: #D6EEE4; }
.tint-lilac { background: #EAE3F7; }

.spoken-line {
  position: absolute;
  left: 50%;
  bottom: 30px;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 52px;
  max-width: calc(100% - 32px);
  width: max-content;
  padding: 12px 22px;
  border-radius: 26px;
  background: var(--ink);
  color: #fff;
  font-size: 17px;
  line-height: 24px;
  box-shadow: 0 10px 30px rgba(34, 34, 58, 0.25);
}

/* ── Feature rows ────────────────────────────────────────────────── */

.features {
  display: flex;
  flex-direction: column;
  gap: 120px;
  max-width: calc(var(--page-width) + 2 * var(--page-gutter));
  margin: 0 auto;
  padding: 40px var(--page-gutter) 140px;
}
.feature { display: flex; align-items: center; justify-content: space-between; gap: 48px; }
.feature__copy { display: flex; flex-direction: column; gap: 16px; width: 420px; max-width: 100%; }
.feature__copy > p:last-child { color: var(--ink-soft); }

.art {
  position: relative;
  width: 520px;
  max-width: 100%;
  height: 360px;
  flex-shrink: 0;
  border-radius: 24px;
  background: var(--card);
  border: 1px solid var(--paper-edge);
}
.art--ask { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 28px; padding: 0 20px; text-align: center; }
.art__question { font-weight: 500; font-size: 22px; line-height: 28px; letter-spacing: -0.01em; }

.art--draw { display: flex; flex-direction: column; justify-content: center; gap: 26px; padding: 0 56px; font-size: 15px; line-height: 20px; }
.setting-row { position: relative; display: flex; align-items: center; justify-content: space-between; color: var(--ink-soft); }
.setting-row u { height: 10px; border-radius: 5px; background: #ECE6DA; }
.setting-row b { font-weight: 500; color: var(--ink); }
.slider { position: relative; width: 180px; max-width: 50%; height: 6px; border-radius: 3px; background: #E3DCCC; }
.slider i {
  position: absolute;
  left: 54%;
  top: -7px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: #fff;
  border: 1px solid var(--paper-edge-strong);
  box-shadow: 0 1px 3px rgba(34, 34, 58, 0.2);
}
.setting-row__box { left: -21px; top: -21px; width: calc(100% + 42px); height: 62px; }
.setting-row__box path { stroke-width: 5; }
.setting-row__pill { left: 144px; top: -64px; }
.setting-row__buddy { position: absolute; right: -40px; top: 26px; transform: rotate(12deg); }

.art--journey { overflow: hidden; }
.journey__note { position: absolute; left: 32px; top: 28px; z-index: 1; transform: rotate(-2deg); }
/* The journey is drawn in a fixed 520x360 space and scaled down on small screens. */
.journey { position: absolute; left: 0; top: 0; width: 520px; height: 360px; transform-origin: top left; }
.journey__path { position: absolute; inset: 0; width: 520px; height: 360px; }
.journey__path .marker-stroke__line { stroke-width: 5; }
.journey__ahead { stroke: #93C5FD; stroke-width: 4; stroke-linecap: round; stroke-dasharray: 2 11; }
.journey__stop {
  position: absolute;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  margin: -18px 0 0 -18px;
  border-radius: 50%;
  font-weight: 700;
  font-size: 15px;
  line-height: 1;
}
.journey__stop small {
  position: absolute;
  top: 46px;
  left: 50%;
  transform: translateX(-50%);
  white-space: nowrap;
  font-weight: 400;
  font-size: 13px;
  color: var(--ink-soft);
}
.journey__stop--label-above small { top: -30px; left: 22px; transform: none; }
.journey__stop--label-right small { top: 11px; left: 48px; transform: none; font-weight: 600; color: var(--ink); }
.journey__stop--done { background: var(--marker-deep); border: 3px solid #fff; box-shadow: 0 2px 8px rgba(34, 34, 58, 0.18); }
.journey__stop--current { background: #fff; border: 3px solid var(--marker); color: var(--marker-deep); }
.journey__stop--next { background: #fff; border: 2px dashed #93C5FD; color: #93C5FD; }
.journey__stop--next small { color: var(--ink-faint); }
.journey__buddy { position: absolute; left: 300px; top: 96px; }

/* ── Extras ──────────────────────────────────────────────────────── */

.extras {
  display: flex;
  flex-direction: column;
  gap: 48px;
  max-width: calc(var(--page-width) + 2 * var(--page-gutter));
  margin: 0 auto;
  padding: 0 var(--page-gutter) 140px;
}
.extras__row { display: flex; gap: 48px; }
.extra { flex: 1; display: flex; flex-direction: column; gap: 10px; padding-top: 20px; border-top: 2px solid var(--ink); }
.extra--amber { border-top-color: var(--amber); }
.extra h3 { font-weight: 600; font-size: 19px; line-height: 26px; letter-spacing: -0.01em; }
.extra p { font-size: 16px; line-height: 26px; color: var(--ink-soft); }

/* ── Note ────────────────────────────────────────────────────────── */

.note-band { display: flex; justify-content: center; padding: 110px var(--page-gutter); background: var(--marker); }
.note {
  display: flex;
  flex-direction: column;
  gap: 22px;
  width: 620px;
  max-width: 100%;
  padding: 48px 52px 44px;
  background: #fff;
  border-radius: 6px;
  box-shadow: 0 24px 60px rgba(23, 37, 84, 0.35);
  transform: rotate(-1.5deg);
  line-height: 30px;
  color: var(--ink-soft);
}
.note__label { font-weight: 600; font-size: 12px; line-height: 16px; letter-spacing: 0.08em; color: var(--ink-faint); }
.note__lead { font-weight: 500; font-size: clamp(24px, 3.6vw, 30px); line-height: 1.33; letter-spacing: -0.025em; color: var(--ink); }
.note__signature { font-size: 30px; padding-top: 6px; }

/* ── Privacy ─────────────────────────────────────────────────────── */

.privacy {
  display: flex;
  justify-content: space-between;
  gap: 48px;
  max-width: calc(var(--page-width) + 2 * var(--page-gutter));
  margin: 0 auto;
  padding: 140px var(--page-gutter) 0;
}
.privacy__heading { display: flex; flex-direction: column; gap: 16px; width: 400px; max-width: 100%; }
.privacy__list { width: 540px; max-width: 100%; border-bottom: 1px solid var(--paper-edge-strong); }
.privacy__list li { display: flex; gap: 20px; padding: 22px 0; border-top: 1px solid var(--paper-edge-strong); line-height: 28px; }
.privacy__list span { width: 28px; flex-shrink: 0; font-weight: 600; font-size: 15px; color: var(--marker-text); }
.privacy__more a, .faq details p a { color: var(--marker-text); text-decoration: underline; text-underline-offset: 3px; }
.privacy__more a:hover, .faq details p a:hover { color: var(--marker-deep); }

/* ── Questions ───────────────────────────────────────────────────── */

.faq {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 40px;
  max-width: calc(760px + 2 * var(--page-gutter));
  margin: 0 auto;
  padding: 150px var(--page-gutter) 0;
}
.faq h2 { text-align: center; }
.faq__list { display: flex; flex-direction: column; gap: 10px; width: 100%; }
.faq details { border-radius: 16px; background: var(--card); border: 1px solid var(--paper-edge); transition: border-color 0.15s; }
.faq details:hover { border-color: var(--paper-edge-strong); }
.faq summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: 22px 26px;
  font-weight: 500;
  font-size: 18px;
  line-height: 26px;
  cursor: pointer;
  list-style: none;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-weight: 400; font-size: 24px; color: var(--ink-soft); transition: transform 0.2s; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { max-width: 640px; padding: 0 26px 24px; font-size: 16px; line-height: 26px; color: var(--ink-soft); }

/* ── Closing and footer ──────────────────────────────────────────── */

.closing { display: flex; flex-direction: column; align-items: center; text-align: center; padding: 160px var(--page-gutter) 140px; }
.closing h2 { font-size: clamp(40px, 7vw, 72px); line-height: 1.11; letter-spacing: -0.04em; padding: 20px 0 36px; }

.site-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
  max-width: var(--page-width);
  margin: 0 auto;
  padding: 28px 0 36px;
  border-top: 1px solid var(--paper-edge);
  font-size: 14px;
  line-height: 20px;
  color: var(--ink-soft);
}
.site-footer nav { display: flex; gap: 28px; flex-wrap: wrap; }
.site-footer a:hover { color: var(--ink); }

/* ── Motion ──────────────────────────────────────────────────────────
   Ink draws on, then its pill pops, the way the app does it. script.js adds
   .draws-ink to <html> (so without JavaScript everything is simply shown),
   and .is-drawn to a drawing once it scrolls into view. */

.draws-ink .buddy { animation: buddy-bob 3.2s ease-in-out infinite; }
@keyframes buddy-bob { 0%, 100% { translate: 0 0; } 50% { translate: 0 -5px; } }

.draws-ink .marker-stroke path,
.draws-ink .marker-stroke__line { stroke-dashoffset: 1; transition: stroke-dashoffset 0.8s ease-in-out 0.15s; }
.draws-ink .is-drawn .marker-stroke path,
.draws-ink .is-drawn .marker-stroke__line { stroke-dashoffset: 0; }

.draws-ink .ink-pill { opacity: 0; scale: 0.5; transition: opacity 0.2s 0.95s, scale 0.3s cubic-bezier(0.34, 1.56, 0.64, 1) 0.95s; }
.draws-ink .is-drawn .ink-pill { opacity: 1; scale: 1; }

/* Every animation on the page is behind .draws-ink, which the <head> script
   leaves off for Reduce Motion (unless the address ends in ?motion=on). */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .download-button, .site-nav__buddy { transition: none; }
}

/* ── Smaller screens ─────────────────────────────────────────────── */

@media (max-width: 1240px) {
  .floater { display: none; }
  .hero { padding-top: 96px; }
}

@media (max-width: 1080px) {
  .site-footer { margin: 0 var(--page-gutter); }
  .features { gap: 96px; }
  .feature, .feature--art-first { flex-direction: column; align-items: flex-start; gap: 36px; }
  .feature--art-first .feature__copy { order: -1; }
  .feature__copy { width: 520px; }
  .privacy { flex-direction: column; }
  .extras__row { flex-direction: column; gap: 32px; }
}

@media (max-width: 760px) {
  .site-nav { padding: 0 var(--page-gutter); height: 64px; }
  .site-nav__links a:not(.site-nav__wordmark), .site-nav__requirement { display: none; }
  .hero { padding: 72px 0 88px; }
  .demo { padding-top: 64px; }
  .demo-window__sidebar, .tool-blank { display: none; }
  .tool-search { width: 70px; }
  .photo-grid { grid-template-columns: repeat(3, 1fr); gap: 10px; padding: 16px 16px 30px; }
  .spoken-line { left: 16px; right: 16px; bottom: 20px; transform: none; width: auto; max-width: none; font-size: 15px; line-height: 21px; border-radius: 22px; }
  .features { padding-bottom: 104px; }
  .extras { padding-bottom: 104px; }
  .note-band { padding: 80px var(--page-gutter); }
  .note { padding: 36px 28px 32px; }
  .privacy { padding-top: 104px; }
  .faq { padding-top: 112px; }
  .faq summary { padding: 18px 20px; font-size: 17px; }
  .faq details p { padding: 0 20px 20px; }
  .closing { padding: 120px var(--page-gutter) 104px; }
}

@media (max-width: 600px) {
  .art { height: auto; min-height: 300px; }
  .art--ask { padding: 40px 20px; }
  .art--draw { padding: 84px 40px 56px; }
  .setting-row__pill { left: 110px; }
  .setting-row__buddy { right: -30px; }
  .art--journey { height: 216px; min-height: 0; }
  .journey { transform: scale(0.62); }
  .journey__note { left: 20px; top: 16px; font-size: 20px; }
}

@media (max-width: 370px) {
  .art--journey { height: 206px; }
  .journey { transform: scale(0.54); }
}

/* ── Pop-up book ─────────────────────────────────────────────────────
   The page behaves like a pop-up card: scenes fold up from the paper as they
   scroll into view, labels sit on ribbons, the blue band has layered cut-paper
   edges, and the buddy does a small job in every scene. All of it is behind
   .draws-ink (set in <head>, never with Reduce Motion), and each piece gets
   .is-drawn from script.js when it scrolls into view. */

.hero__copy, .demo, .note { position: relative; z-index: 1; }
.art { box-shadow: 0 3px 0 var(--paper-edge), 0 18px 40px rgba(34, 34, 58, 0.06); }

/* A scene folding up from its bottom edge, with a small lean past upright. */
.draws-ink .pops-up {
  transform-origin: 50% 100%;
  transform: perspective(1400px) rotateX(-86deg);
  opacity: 0;
  transition:
    transform 0.85s cubic-bezier(0.2, 1.35, 0.4, 1) var(--pop-delay, 0s),
    opacity 0.2s linear var(--pop-delay, 0s);
}
.draws-ink .pops-up.is-drawn { transform: perspective(1400px) rotateX(0deg); opacity: 1; }

/* The note opens downward from its top fold, like a card being opened. */
.draws-ink .note {
  transform-origin: 50% 0;
  transform: perspective(1400px) rotateX(82deg) rotate(-1.5deg);
  opacity: 0;
  transition: transform 1s cubic-bezier(0.2, 1.3, 0.4, 1), opacity 0.25s linear;
}
.draws-ink .note.is-drawn { transform: perspective(1400px) rotateX(0deg) rotate(-1.5deg); opacity: 1; }

/* The wordmark's letters stand up one after another. */
.pop-up-letter { display: inline-block; }
.draws-ink .pop-up-letter {
  transform-origin: 50% 85%;
  transform: perspective(700px) rotateX(-90deg);
  opacity: 0;
  transition:
    transform 0.7s cubic-bezier(0.2, 1.5, 0.4, 1) calc(0.1s + var(--stagger-index, 0) * 0.09s),
    opacity 0.15s linear calc(0.1s + var(--stagger-index, 0) * 0.09s);
}
.draws-ink .is-drawn .pop-up-letter { transform: perspective(700px) rotateX(0deg); opacity: 1; }

/* The ink waits until its scene is standing. */
.draws-ink .marker-stroke path,
.draws-ink .marker-stroke__line { transition-delay: 0.8s; }
.draws-ink .ink-pill { transition-delay: 1.6s, 1.6s; }
.draws-ink .floater--files .marker-stroke path { transition-delay: 1.5s; }
.draws-ink .floater--files .ink-pill { transition-delay: 2.3s, 2.3s; }

/* Hero pieces sit at different depths and drift a little with the mouse. */
.floater {
  z-index: 1;
  transform: none;
  translate: calc(var(--parallax-x, 0px) * var(--depth, 1)) calc(var(--parallax-y, 0px) * var(--depth, 1));
}
.floater--files { rotate: -4deg; }
.floater--hotkey { rotate: 3deg; }
.floater--question { rotate: 4deg; }
.floater--route { rotate: -3deg; }

/* Ribbon labels: a folded paper banner that unrolls from its middle. */
.ribbon {
  position: relative;
  align-self: flex-start;
  display: inline-flex;
  margin-left: 14px;
  rotate: -2deg;
  font-family: Caveat, "Bradley Hand", cursive;
  font-weight: 600;
  font-size: 22px;
  line-height: 1;
  color: #fff;
}
.ribbon span {
  display: flex;
  align-items: center;
  height: 34px;
  padding: 0 18px 2px;
  background: var(--marker);
  box-shadow: 0 2px 0 rgba(23, 37, 84, 0.22);
}
/* The two folded tails, tucked behind the banner. */
.ribbon::before, .ribbon::after {
  content: "";
  position: absolute;
  top: 7px;
  z-index: -1;
  width: 24px;
  height: 34px;
  background: var(--marker-deep);
}
.ribbon::before { left: -14px; clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%, 9px 50%); }
.ribbon::after { right: -14px; clip-path: polygon(0 0, 100% 0, calc(100% - 9px) 50%, 100% 100%, 0 100%); }
.draws-ink .ribbon { clip-path: inset(-12px 50% -12px 50%); transition: clip-path 0.55s cubic-bezier(0.3, 1.2, 0.5, 1) 0.1s; }
.draws-ink .ribbon.is-drawn { clip-path: inset(-12px -20px -12px -20px); }

/* Layered cut-paper edges on the blue band. */
.note-band { position: relative; }
.paper-edge { position: absolute; left: 0; width: 100%; height: 90px; overflow: visible; pointer-events: none; }
.paper-edge--top { top: -89px; }
.paper-edge--bottom { bottom: -89px; transform: scaleY(-1); }
.paper-edge__layer { filter: drop-shadow(0 -3px 3px rgba(23, 37, 84, 0.14)); transition: translate 0.2s linear; }
.paper-edge__layer--back { fill: #D5E4FC; translate: calc(var(--paper-shift, 0px) * 1.6) 0; }
.paper-edge__layer--middle { fill: #8DB8FF; translate: calc(var(--paper-shift, 0px) * -1.2) 0; }
.paper-edge__layer--front { fill: var(--marker); translate: calc(var(--paper-shift, 0px) * 0.6) 0; }
.extras { padding-bottom: 200px; }
.privacy { padding-top: 210px; }

/* Small bits of cut paper drifting down, made by script.js. */
.paper-bits { position: absolute; inset: 0; overflow: hidden; pointer-events: none; z-index: 0; }
.paper-bit {
  position: absolute;
  top: -24px;
  width: var(--bit-size);
  height: var(--bit-size);
  border-radius: 2px;
  background: var(--bit-color);
  opacity: 0.55;
  animation: paper-fall var(--bit-duration) linear var(--bit-delay) infinite;
}
.paper-bit--triangle { clip-path: polygon(50% 0, 100% 100%, 0 100%); border-radius: 0; }
.paper-bit--circle { border-radius: 50%; }
.paper-bits--light .paper-bit { background: #fff; opacity: 0.3; }
@keyframes paper-fall {
  from { transform: translate3d(0, 0, 0) rotate(0deg); }
  to { transform: translate3d(var(--bit-sway), var(--fall-distance), 0) rotate(var(--bit-spin)); }
}
/* The bits thrown when the buddy or a download button is clicked. */
.paper-burst-bit { position: fixed; z-index: 50; width: 9px; height: 9px; border-radius: 2px; pointer-events: none; }

/* The buddy looks toward the mouse and blinks. */
.buddy-symbol__look { transform: translate(var(--look-x, 0px), var(--look-y, 0px)); transition: transform 0.12s ease-out; }
.buddy-symbol__eyes { transform-box: fill-box; transform-origin: center; }
.draws-ink .buddy-symbol__eyes { animation: buddy-blink 4.6s infinite; }
@keyframes buddy-blink { 0%, 94%, 100% { transform: scaleY(1); } 97% { transform: scaleY(0.1); } }
.buddy, .buddy-looks { cursor: pointer; }
.draws-ink .closing:has(.download-button:hover) .closing__buddy { animation: buddy-jump 0.55s ease-out; }
@keyframes buddy-jump { 0%, 100% { translate: 0 0; rotate: 0deg; } 40% { translate: 0 -22px; rotate: -8deg; } 70% { translate: 0 -4px; rotate: 6deg; } }

/* Demo scene: photos pop in one by one, then Guidy speaks. */
.draws-ink .photo-grid i { scale: 0; transition: scale 0.45s cubic-bezier(0.34, 1.56, 0.64, 1) calc(0.55s + var(--stagger-index, 0) * 0.05s); }
.draws-ink .is-drawn .photo-grid i { scale: 1; }
.draws-ink .demo-window .marker-stroke path { transition-delay: 1.3s; }
.draws-ink .demo-window .ink-pill { transition-delay: 2.1s, 2.1s; }
.draws-ink .spoken-line { opacity: 0; translate: 0 18px; transition: opacity 0.3s 2.5s, translate 0.45s cubic-bezier(0.34, 1.56, 0.64, 1) 2.5s; }
.draws-ink .is-drawn .spoken-line { opacity: 1; translate: 0 0; }

/* Step one: the voice moves, and the two keys are pressed. */
.draws-ink .waveform i { transform-origin: center; animation: wave-pulse 0.9s ease-in-out infinite alternate; animation-delay: calc(var(--stagger-index, 0) * -0.17s); }
@keyframes wave-pulse { from { transform: scaleY(0.45); } to { transform: scaleY(1); } }
.draws-ink .is-drawn .keycaps--blue kbd { animation: key-press 0.5s ease-in-out 1s; }
.draws-ink .is-drawn .keycaps--blue kbd:last-child { animation-delay: 1.12s; }
@keyframes key-press { 40%, 60% { transform: translateY(3px); box-shadow: 0 0 0 #93C5FD; } }

/* Step two: once the box is drawn, the slider is dragged along. */
.draws-ink .slider i { left: 18%; }
.draws-ink .is-drawn .slider i { animation: slider-drag 1.5s ease-in-out 2.2s both; }
@keyframes slider-drag { from { left: 18%; } to { left: 54%; } }

/* Step three: the buddy hops along the path to the current stop. */
.draws-ink .journey__buddy { animation: none; translate: -250px 70px; }
.draws-ink .is-drawn .journey__buddy { animation: journey-hop 2.4s ease-in-out 1s both, buddy-bob 3.2s ease-in-out 3.5s infinite; }
@keyframes journey-hop {
  0% { translate: -250px 70px; }
  18% { translate: -185px -12px; }
  36%, 52% { translate: -120px 20px; }
  76% { translate: -55px -42px; }
  100% { translate: 0 0; }
}

@media (max-width: 760px) {
  .extras { padding-bottom: 170px; }
  .privacy { padding-top: 180px; }
}

/* ── The cast: cut-paper pop-up scenes ───────────────────────────────
   Four illustrated cards near the end of the page, like a film's end credits.
   Each .cast-layer is one sheet of paper; the sheets stand up back to front,
   the ribbon unrolls last, and then each scene keeps one small thing moving. */

.cast {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  max-width: calc(var(--page-width) + 2 * var(--page-gutter));
  margin: 0 auto;
  padding: 150px var(--page-gutter) 150px;
  text-align: center;
}
.cast__eyebrow { font-size: 26px; rotate: -2deg; }
.cast__grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 44px 40px; width: 100%; padding-top: 46px; }
.cast-card { display: flex; flex-direction: column; gap: 16px; text-align: left; }
.cast-card__art {
  display: block;
  width: 100%;
  height: auto;
  overflow: visible;
  filter: drop-shadow(0 16px 26px rgba(34, 34, 58, 0.14));
  transition: rotate 0.3s ease, translate 0.3s ease;
}
/* Cards sit a little crooked, like cards propped on a shelf, and straighten on hover. */
.cast-card:nth-child(odd) .cast-card__art { rotate: -1deg; }
.cast-card:nth-child(even) .cast-card__art { rotate: 1deg; }
.cast-card:hover .cast-card__art { rotate: 0deg; translate: 0 -4px; }
.cast-card figcaption { font-size: 17px; line-height: 27px; color: var(--ink-soft); }
.cast-card figcaption strong { font-weight: 600; color: var(--ink); }
.cast-card text { user-select: none; }

/* Sheets of paper standing up one behind the other. */
.draws-ink .cast-layer {
  transform-box: view-box;
  transform-origin: 50% 100%;
  transform: scaleY(0);
  transition: transform 0.7s cubic-bezier(0.2, 1.4, 0.4, 1) calc(0.45s + var(--pop-delay, 0s) + var(--layer-index, 0) * 0.16s);
}
.draws-ink .is-drawn .cast-layer { transform: scaleY(1); }
.draws-ink .cast-ribbon {
  transform-box: fill-box;
  transform-origin: center;
  transform: scaleX(0);
  transition: transform 0.5s cubic-bezier(0.3, 1.3, 0.5, 1) calc(1.45s + var(--pop-delay, 0s));
}
.draws-ink .is-drawn .cast-ribbon { transform: scaleX(1); }

/* Every buddy in the cast bobs a little. */
.draws-ink .cast-buddy__bob { animation: cast-bob 3s ease-in-out infinite; }
.draws-ink .cast-card--listener .cast-buddy__bob { animation: cast-nod 1.8s ease-in-out infinite; transform-box: fill-box; transform-origin: 50% 100%; }
@keyframes cast-bob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-3px); } }
@keyframes cast-nod { 0%, 100% { transform: rotate(-3deg); } 50% { transform: rotate(3deg); } }

/* The pointer draws its box; the guard's cross is stamped on the letter. */
.cast-ink, .cast-cross path { stroke-dasharray: 1; stroke-dashoffset: 0; }
.draws-ink .cast-ink, .draws-ink .cast-cross path { stroke-dashoffset: 1; transition: stroke-dashoffset 0.8s ease-in-out 1.9s; }
.draws-ink .cast-cross path:nth-child(even) { transition-delay: 2.3s; }
.draws-ink .cast-cross path { transition-duration: 0.35s; }
.draws-ink .is-drawn .cast-ink, .draws-ink .is-drawn .cast-cross path { stroke-dashoffset: 0; }
.draws-ink .cast-letter { animation: cast-wiggle 2.4s ease-in-out infinite; transform-box: fill-box; transform-origin: center; }
@keyframes cast-wiggle { 0%, 100% { transform: rotate(-2.5deg); } 50% { transform: rotate(2.5deg); } }

/* The listener: sound rings breathe and the voice bars move. */
.draws-ink .cast-ring { transform-box: fill-box; transform-origin: center; animation: cast-ring-pulse 2.8s ease-in-out infinite; animation-delay: var(--ring-delay, 0s); }
@keyframes cast-ring-pulse { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.05); } }
.draws-ink .cast-bar { transform-box: fill-box; transform-origin: center; animation: wave-pulse 0.9s ease-in-out infinite alternate; animation-delay: calc(var(--stagger-index, 0) * -0.17s); }

/* The patient one: stars twinkle and the tea steams. */
.draws-ink .cast-star { transform-box: fill-box; transform-origin: center; animation: cast-twinkle 2.2s ease-in-out infinite alternate; animation-delay: var(--twinkle-delay, 0s); }
@keyframes cast-twinkle { from { transform: scale(0.55); opacity: 0.4; } to { transform: scale(1); opacity: 1; } }
.draws-ink .cast-steam { animation: cast-steam 2.6s ease-in-out infinite; }
.draws-ink .cast-steam--late { animation-delay: -1.3s; }
@keyframes cast-steam { 0% { transform: translateY(6px); opacity: 0; } 35% { opacity: 1; } 100% { transform: translateY(-10px); opacity: 0; } }

/* The guard: the lantern glows. */
.draws-ink .cast-glow { transform-box: fill-box; transform-origin: center; animation: cast-glow 2.2s ease-in-out infinite alternate; }
@keyframes cast-glow { from { transform: scale(0.82); opacity: 0.35; } to { transform: scale(1.15); opacity: 0.65; } }

/* ── Finale: the paper-cloud tunnel around the last download button ── */

.closing {
  position: relative;
  overflow: hidden;
  justify-content: center;
  min-height: 680px;
  padding: 0;
  background: #1D4ED8;
}
.finale__tunnel { position: absolute; inset: 0; width: 100%; height: 100%; }
.closing__content { position: relative; z-index: 1; display: flex; flex-direction: column; align-items: center; padding: 60px var(--page-gutter); }
.closing h2 { max-width: 600px; font-size: clamp(36px, 5.4vw, 60px); padding: 12px 0 28px; }
.tunnel-layer { translate: calc(var(--parallax-x, 0px) * var(--layer-depth, 1)) calc(var(--parallax-y, 0px) * var(--layer-depth, 1)); transition: translate 0.3s ease-out; }
/* The cloud layers close in from outside, the darkest first. */
.draws-ink .tunnel-layer {
  transform-box: view-box;
  transform-origin: 50% 50%;
  transform: scale(1.6);
  opacity: 0;
  transition:
    transform 1s cubic-bezier(0.2, 1.15, 0.4, 1) calc(var(--layer-index, 0) * 0.11s),
    opacity 0.3s linear calc(var(--layer-index, 0) * 0.11s),
    translate 0.3s ease-out;
}
.draws-ink .closing.is-drawn .tunnel-layer { transform: scale(1); opacity: 1; }
.draws-ink .closing__content { opacity: 0; scale: 0.9; transition: opacity 0.4s 0.9s, scale 0.6s cubic-bezier(0.34, 1.56, 0.64, 1) 0.9s; }
.draws-ink .closing.is-drawn .closing__content { opacity: 1; scale: 1; }
.site-footer { border-top: 0; }

@media (max-width: 760px) {
  .cast { padding: 112px var(--page-gutter) 112px; }
  .cast__grid { grid-template-columns: minmax(0, 1fr); gap: 36px; padding-top: 34px; }
  .closing { min-height: 620px; padding: 0; }
}

/* ── The photos in the demo window ───────────────────────────────────
   Each tile is a small cut-paper scene of Guidy and friends. Under .draws-ink
   every scene keeps one thing moving; --d staggers the timing. */

.photo-grid i { display: block; overflow: hidden; }
.photo { display: block; width: 100%; height: 100%; }
.draws-ink .tile-bob { animation: tile-bob 3s ease-in-out infinite; animation-delay: var(--d, 0s); }
.draws-ink .tile-float { animation: tile-float 4s ease-in-out infinite; }
.draws-ink .tile-nod { transform-box: fill-box; transform-origin: 50% 100%; animation: tile-nod 0.9s ease-in-out infinite alternate; }
.draws-ink .tile-wave { animation: tile-wave 3.2s ease-in-out infinite alternate; animation-delay: var(--d, 0s); }
.draws-ink .tile-drift { animation: tile-drift 9s ease-in-out infinite alternate; }
.draws-ink .tile-rock { transform-box: fill-box; transform-origin: 50% 100%; animation: tile-rock 3s ease-in-out infinite alternate; }
.draws-ink .tile-sway { transform-box: fill-box; transform-origin: 50% 100%; animation: tile-sway 2.6s ease-in-out infinite alternate; animation-delay: var(--d, 0s); }
.draws-ink .tile-flame { transform-box: fill-box; transform-origin: 50% 100%; animation: tile-flame 0.45s ease-in-out infinite alternate; animation-delay: var(--d, 0s); }
.draws-ink .tile-flag { transform-box: fill-box; transform-origin: 0 50%; animation: tile-flag 0.8s ease-in-out infinite alternate; }
.draws-ink .tile-pulse { transform-box: fill-box; transform-origin: center; animation: tile-pulse 0.8s ease-in-out infinite alternate; }
.draws-ink .tile-wave-arm { transform-box: fill-box; transform-origin: 0 100%; animation: tile-wave-arm 0.6s ease-in-out infinite alternate; }
.draws-ink .tile-fall { animation: tile-fall var(--t, 3s) linear infinite; animation-delay: var(--d, 0s); }
.draws-ink .tile-drop { animation: tile-drop 0.9s ease-in infinite; animation-delay: var(--d, 0s); }
.draws-ink .tile-rise { animation: tile-rise 2.4s ease-out infinite; animation-delay: var(--d, 0s); }
@keyframes tile-bob { 50% { transform: translateY(-4px); } }
@keyframes tile-float { 0%, 100% { transform: translateY(4px) rotate(-2deg); } 50% { transform: translateY(-8px) rotate(2deg); } }
@keyframes tile-nod { from { transform: rotate(-5deg); } to { transform: rotate(5deg); } }
@keyframes tile-wave { from { transform: translateX(0); } to { transform: translateX(-20px); } }
@keyframes tile-drift { from { transform: translateX(-14px); } to { transform: translateX(18px); } }
@keyframes tile-rock { from { transform: rotate(-4deg); } to { transform: rotate(4deg); } }
@keyframes tile-sway { from { transform: rotate(-7deg); } to { transform: rotate(7deg); } }
@keyframes tile-flame { from { transform: scale(0.9, 0.85); } to { transform: scale(1.05, 1.12); } }
@keyframes tile-flag { from { transform: scaleX(1); } to { transform: scaleX(0.8) skewY(6deg); } }
@keyframes tile-pulse { from { transform: scale(0.88); } to { transform: scale(1.12); } }
@keyframes tile-wave-arm { from { transform: rotate(-14deg); } to { transform: rotate(16deg); } }
@keyframes tile-fall { from { transform: translate(0, 0); } to { transform: translate(10px, 160px); } }
@keyframes tile-drop { from { transform: translateY(0); opacity: 1; } to { transform: translateY(20px); opacity: 0; } }
@keyframes tile-rise { 0% { transform: translateY(12px); opacity: 0; } 25% { opacity: 1; } 100% { transform: translateY(-34px); opacity: 0; } }
/* Room under the photos, so Guidy's spoken line doesn't cover the bottom row. */
.photo-grid { padding-bottom: 100px; }
@media (max-width: 760px) { .photo-grid { padding-bottom: 104px; } }

/* Extra motions for the doodle photos. */
.draws-ink .tile-sled { animation: tile-sled 1.6s ease-in-out infinite alternate; }
.draws-ink .tile-twinkle { transform-box: fill-box; transform-origin: center; animation: tile-pulse 0.7s ease-in-out infinite alternate; animation-delay: var(--d, 0s); }
.draws-ink .tile-flicker { animation: tile-flicker 0.5s steps(2) infinite; }
.draws-ink .tile-kite { transform-box: fill-box; transform-origin: 20% 100%; animation: tile-kite 2.4s ease-in-out infinite alternate; }
.draws-ink .tile-jump { animation: tile-jump 1.1s cubic-bezier(0.3, 0, 0.7, 1) infinite alternate; }
.draws-ink .tile-hop { animation: tile-hop 0.7s ease-in-out infinite alternate; }
.draws-ink .tile-rain { animation: tile-rain 0.7s linear infinite; animation-delay: var(--d, 0s); }
.draws-ink .tile-burst { transform-box: fill-box; transform-origin: center; animation: tile-burst 2.1s ease-out infinite; animation-delay: var(--d, 0s); }
.draws-ink .tile-spin { transform-box: fill-box; transform-origin: center; animation: tile-spin 14s linear infinite; }
@keyframes tile-sled { from { transform: translate(-10px, 0) rotate(-2deg); } to { transform: translate(12px, 0) rotate(2deg); } }
@keyframes tile-flicker { from { opacity: 1; } to { opacity: 0.6; } }
@keyframes tile-kite { from { transform: rotate(-9deg) translateY(4px); } to { transform: rotate(8deg) translateY(-4px); } }
@keyframes tile-jump { from { transform: translateY(8px); } to { transform: translateY(-42px); } }
@keyframes tile-hop { from { transform: translateY(0); } to { transform: translateY(-9px); } }
@keyframes tile-rain { from { transform: translate(0, -14px); opacity: 0; } 20% { opacity: 1; } to { transform: translate(-10px, 34px); opacity: 0; } }
@keyframes tile-burst { 0% { transform: scale(0.15); opacity: 0; } 20% { opacity: 1; } 70% { transform: scale(1); opacity: 1; } 100% { transform: scale(1.1); opacity: 0; } }
@keyframes tile-spin { to { transform: rotate(360deg); } }

/* ── The pencil case: a live drawing stage ───────────────────────────
   A list of questions beside one mock app screen. runDrawingStage (script.js)
   flies the buddy to each stroke's start and moves its tip along the line as
   the ink appears. Without motion, a chosen scene simply shows finished. */

.kit {
  display: flex;
  flex-direction: column;
  gap: 16px;
  max-width: calc(var(--page-width) + 2 * var(--page-gutter));
  margin: 0 auto;
  padding: 0 var(--page-gutter) 140px;
}
.kit__intro { max-width: 560px; color: var(--ink-soft); }
.stage { display: grid; grid-template-columns: 318px minmax(0, 1fr); gap: 26px; align-items: start; padding-top: 28px; }
.ask-list { position: relative; display: flex; flex-direction: column; gap: 4px; }
.ask-chip {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  width: 100%;
  padding: 9px 14px;
  border: 1px solid transparent;
  border-radius: 12px;
  background: transparent;
  font: inherit;
  font-size: 15px;
  line-height: 21px;
  text-align: left;
  color: var(--ink-soft);
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, color 0.15s, box-shadow 0.15s;
}
.ask-chip small { font-family: Caveat, "Bradley Hand", cursive; font-weight: 600; font-size: 18px; line-height: 1; color: var(--marker-text); white-space: nowrap; opacity: 0; transition: opacity 0.15s; }
.ask-chip:hover { background: var(--card); border-color: var(--paper-edge); color: var(--ink); }
.ask-chip:focus-visible { outline: 3px solid var(--marker); outline-offset: 2px; }
.ask-chip[aria-pressed="true"] { background: var(--card); border-color: var(--paper-edge-strong); box-shadow: 0 2px 0 var(--paper-edge-strong); color: var(--ink); }
.ask-chip[aria-pressed="true"] small { opacity: 1; }

.stage__screen {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 16px;
  border: 1px solid var(--paper-edge-strong);
  background: var(--card);
  box-shadow: 0 24px 60px rgba(34, 34, 58, 0.12);
}
.stage__spoken {
  display: flex;
  align-items: center;
  gap: 12px;
  width: fit-content;
  max-width: 100%;
  min-height: 52px;
  margin: 16px auto 0;
  padding: 12px 22px;
  border-radius: 26px;
  background: var(--ink);
  color: #fff;
  font-size: 17px;
  line-height: 24px;
}
.stage__spoken-text { transition: opacity 0.2s; }
.stage__spoken-text.is-changing { opacity: 0; }

/* One scene shows at a time. Its ink is hidden until drawn (or shown whole when complete). */
.stage-scene { display: none; }
.stage-scene.is-current { display: inline; }
.scene-ink { stroke-dasharray: 1; stroke-dashoffset: 1; }
.stage-scene.is-complete .scene-ink { stroke-dashoffset: 0; }
.scene-pop { opacity: 0; transform-box: fill-box; transform-origin: center; transform: scale(0.4); }
.scene-pop.is-on, .stage-scene.is-complete .scene-pop { opacity: 1; transform: scale(1); }
.scene-ghost, .scene-ripple { opacity: 0; }
.scene-ripple { transform-box: fill-box; transform-origin: center; }
.stage-buddy { cursor: pointer; }
.draws-ink .scene-pop { transition: opacity 0.2s, transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1); transition-delay: calc(var(--pop-order, 0) * 0.14s); }
.draws-ink .scene-prop, .draws-ink .scene-fade { animation: kit-fade 0.3s ease-out both; }
.draws-ink .stage-scene.is-complete .scene-ripple { animation: kit-ripple 1.8s ease-out infinite; }
.draws-ink .stage-scene.is-complete .scene-ripple--second { animation-delay: 0.9s; }
.draws-ink .stage-scene.is-complete .scene-caret { animation: kit-blink 1.1s steps(1) 0.6s infinite; }
@keyframes kit-fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes kit-ripple { 0% { transform: scale(0.6); opacity: 0.9; } 60%, 100% { transform: scale(2.6); opacity: 0; } }
@keyframes kit-blink { 0% { opacity: 1; } 50% { opacity: 0; } }

@media (max-width: 980px) {
  .stage { grid-template-columns: minmax(0, 1fr); gap: 16px; }
  /* The questions become one row to swipe through. */
  .ask-list { flex-direction: row; gap: 8px; margin: 0 calc(-1 * var(--page-gutter)); padding: 4px var(--page-gutter) 8px; overflow-x: auto; scrollbar-width: none; }
  .ask-list::-webkit-scrollbar { display: none; }
  .ask-chip { width: auto; flex-shrink: 0; white-space: nowrap; background: var(--card); border-color: var(--paper-edge); }
  .ask-chip small { display: none; }
  .ask-chip[aria-pressed="true"] { background: var(--marker); border-color: var(--marker); box-shadow: none; color: #fff; }
}
@media (max-width: 760px) {
  .kit { padding-bottom: 104px; }
  .stage__spoken { font-size: 15px; line-height: 21px; border-radius: 22px; }
}

/* ── Little live scenes (the "kind extras" cards) ───────────────────────
   Each card has a small picture that plays its own story on a loop while it
   is on screen. runLittleScenes in script.js plays the [data-beat] parts in order. */
.extra { padding-top: 0; border-top: 0; }
.little-scene {
  display: block;
  width: 100%;
  height: auto;
  margin-bottom: 10px;
  border-radius: 16px;
  border: 1px solid var(--paper-edge);
  box-shadow: 0 3px 0 var(--paper-edge), 0 14px 30px rgba(34, 34, 58, 0.05);
}
.extra--amber .little-scene { border-color: #F3D08A; box-shadow: 0 3px 0 #F3D08A, 0 14px 30px rgba(34, 34, 58, 0.05); }
.little-scene .beat-ink { stroke-dasharray: 1; stroke-dashoffset: 1; }
.little-scene [data-beat="pop"] { opacity: 0; transform-box: fill-box; transform-origin: center; transform: scale(0.4); }
.little-scene [data-beat="pop"][data-pop="fade"] { transform: none; }
.little-scene [data-beat="pop"].is-on { opacity: 1; transform: scale(1); }
.little-scene [data-beat="pop"][data-pop="fade"].is-on { transform: none; }
.little-scene.is-clearing [data-beat="pop"].is-on, .little-scene.is-clearing [data-beat="stroke"] { opacity: 0; }
.little-scene.is-answering .little-wonder.is-on { opacity: 0; }
.little-window { transform-box: fill-box; transform-origin: center; }
.little-scene.is-minimized .little-window { transform: translate(77px, 105px) scale(0.1); opacity: 0; }
.little-sheet { transform-origin: 158px 100px; }
.little-scene.is-saved .little-sheet { transform: rotate(-3deg) translate(-8px, -3px); }
.little-scene.is-closed .little-popup-layer { opacity: 0; transform: translateY(14px); }
.draws-ink .little-scene [data-beat="pop"] { transition: opacity 0.22s, transform 0.38s cubic-bezier(0.34, 1.56, 0.64, 1); }
.draws-ink .little-scene [data-beat="stroke"] { transition: opacity 0.3s; }
.draws-ink .little-window { transition: transform 0.6s cubic-bezier(0.5, 0, 0.8, 0.4), opacity 0.2s 0.42s; }
.draws-ink .little-sheet { transition: transform 0.5s cubic-bezier(0.34, 1.56, 0.64, 1); }
.draws-ink .little-popup-layer { transition: opacity 0.35s, transform 0.45s ease-in; }
@media (max-width: 1080px) {
  .little-scene { max-width: 440px; }
}

/* ── Step one: hold the two keys (or press and hold them) to ask ──────── */
.art--ask { gap: 22px; }
.talk .waveform i { transition: transform 0.25s; }
.talk:not(.is-listening) .waveform i { animation: none; transform: scaleY(0.2); }
.talk__question { min-height: 28px; transition: color 0.2s; }
.talk.is-listening .talk__question { color: var(--marker-deep); }
.talk__keys {
  margin: 0;
  padding: 8px;
  border: 0;
  border-radius: 16px;
  background: none;
  font: inherit;
  cursor: pointer;
  touch-action: none;
  -webkit-user-select: none;
  user-select: none;
  -webkit-touch-callout: none;
}
.talk__keys kbd { transition: transform 0.12s, box-shadow 0.12s, background 0.12s; }
.talk__keys:hover kbd { background: #DBEAFE; transform: translateY(-1px); box-shadow: 0 4px 0 #93C5FD; }
.talk__keys:focus-visible { outline: 3px solid #93C5FD; outline-offset: 2px; }
.talk.is-listening .talk__keys kbd { animation: none; background: #BFDBFE; transform: translateY(3px); box-shadow: 0 0 0 #93C5FD; }
.talk__line { min-height: 28px; margin: -6px 0 0; color: var(--ink-soft); }
.talk.is-answering .talk__line { color: var(--marker-deep); }

/* ── Step two: the slider really drags ─────────────────────────────── */
.slider { cursor: grab; touch-action: none; }
.slider::before { content: ""; position: absolute; inset: -16px -12px; }
.slider:active { cursor: grabbing; }
.slider i { transition: scale 0.15s, box-shadow 0.15s; }
.slider:hover i, .slider:focus-visible i { scale: 1.2; box-shadow: 0 2px 8px rgba(51, 128, 255, 0.45); }
.slider:focus-visible { outline: 3px solid #93C5FD; outline-offset: 8px; }
.setting-row__name { transform-origin: left center; }
.draws-ink .buddy.is-cheering { animation: buddy-cheer 0.7s ease-out; }
@keyframes buddy-cheer { 0%, 100% { translate: 0 0; scale: 1; } 30% { translate: 0 -18px; scale: 1.12; } 60% { translate: 0 0; scale: 0.96; } 80% { translate: 0 -6px; } }

/* ── Step three: the journey is walked, one stop at a time ─────────────
   runLiveJourney in script.js moves the buddy and the ink. The current stop is
   the visitor's turn: click it and Guidy checks it off and walks on. */
.journey__ink { stroke-dasharray: 1; stroke-dashoffset: 1; stroke-linecap: round; stroke-linejoin: round; }
.journey__ink--halo { stroke: #fff; stroke-width: 10; }
.journey__ink--line { stroke: var(--marker); stroke-width: 5; }
.journey__stop { padding: 0; font-family: inherit; cursor: pointer; -webkit-appearance: none; appearance: none; transition: scale 0.15s; }
.journey__stop:hover { scale: 1.14; }
.journey__stop:focus-visible { outline: 3px solid #93C5FD; outline-offset: 3px; }
.journey__stop svg { display: none; }
.journey__stop--done svg { display: block; }
.journey__stop--done .journey__number { display: none; }
.journey__stop--current small { font-weight: 600; color: var(--ink); }
.journey__stop--label-right:not(.journey__stop--current) small { font-weight: 400; color: var(--ink-soft); }
.journey__stop--next.journey__stop--label-right small { color: var(--ink-faint); }
.journey__buddy { pointer-events: none; transition: rotate 0.25s; }
.journey__buddy.is-puzzled { rotate: -18deg; }
/* The waiting beacon: soft rings from the stop that is the visitor's turn. */
.draws-ink .journey__stop--current::after {
  content: "";
  position: absolute;
  inset: -3px;
  border-radius: 50%;
  border: 2px solid var(--marker);
  pointer-events: none;
  animation: journey-beacon 2.6s ease-out infinite;
}
@keyframes journey-beacon { 0% { scale: 1; opacity: 0.7; } 70%, 100% { scale: 2.3; opacity: 0; } }
.draws-ink .journey__stop.is-just-done { animation: journey-stop-pop 0.5s cubic-bezier(0.34, 1.56, 0.64, 1); }
@keyframes journey-stop-pop { 0% { scale: 0.6; } 60% { scale: 1.35; } 100% { scale: 1; } }
.draws-ink .journey__stop.is-just-done::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 6px;
  height: 6px;
  margin: -3px 0 0 -3px;
  border-radius: 50%;
  pointer-events: none;
  animation: journey-sparkles 0.7s ease-out both;
}
@keyframes journey-sparkles {
  0% { box-shadow: 0 0 0 var(--marker), 0 0 0 var(--amber), 0 0 0 #F6A5C0, 0 0 0 var(--marker); opacity: 1; }
  100% { box-shadow: -30px -24px 0 var(--marker), 32px -20px 0 var(--amber), -26px 26px 0 #F6A5C0, 30px 24px 0 var(--marker); opacity: 0; }
}
.draws-ink .journey__stop.is-nudged { animation: journey-shake 0.45s ease-in-out; }
@keyframes journey-shake { 20%, 60% { translate: -5px 0; } 40%, 80% { translate: 5px 0; } }
.draws-ink .journey--live .journey__buddy, .draws-ink .is-drawn .journey--live .journey__buddy { translate: none; animation: buddy-bob 3.2s ease-in-out infinite; }
.draws-ink .journey--live .journey__buddy.is-cheering { animation: buddy-cheer 0.7s ease-out; }
/* Stop two's name sits below and to the left, clear of the buddy standing on the stop. */
.journey__stop--label-above small { top: 32px; left: auto; right: 24px; }

/* ── Privacy: each claim in the list plays its own small picture ───────
   The four pictures share one spot under the heading; only the current one
   shows. runLittleScenes in script.js plays them from the list. */
.privacy-stage { position: relative; width: 100%; max-width: 400px; aspect-ratio: 320 / 200; margin-top: 20px; }
.privacy-stage .little-scene { position: absolute; inset: 0; margin: 0; max-width: none; opacity: 0; visibility: hidden; }
.privacy-stage .little-scene.is-current { opacity: 1; visibility: visible; }
.draws-ink .privacy-stage .little-scene { transition: opacity 0.25s; }
.privacy__list li { padding: 0; }
.privacy__claim {
  display: flex;
  gap: 20px;
  width: 100%;
  margin: 0;
  padding: 22px 12px 22px 0;
  border: 0;
  background: none;
  color: inherit;
  font: inherit;
  line-height: 28px;
  text-align: left;
  cursor: pointer;
  transition: background 0.18s, padding 0.18s, box-shadow 0.18s;
}
.privacy__claim:hover { background: rgba(51, 128, 255, 0.06); }
.privacy__claim:focus-visible { outline: 3px solid #93C5FD; outline-offset: -3px; }
.privacy__claim[aria-pressed="true"] { padding-left: 16px; background: #EFF6FF; box-shadow: inset 3px 0 0 var(--marker); }

.privacy-mic__disc { fill: #F4F0E7; stroke: #E7E0D2; }
.privacy-mic__glyph { fill: #A8A5BA; }
.privacy-mic__line { fill: none; stroke: #A8A5BA; stroke-width: 3; stroke-linecap: round; }
.privacy-mic__ring { fill: none; stroke: #3380FF; stroke-width: 2; opacity: 0; transform-box: fill-box; transform-origin: center; }
.privacy-key__face { fill: #EFF6FF; stroke: #93C5FD; }
.privacy-label-on { opacity: 0; }
.is-held:not(.is-released) .privacy-mic__disc { fill: #DBEAFE; stroke: #93C5FD; }
.is-held:not(.is-released) .privacy-mic__glyph { fill: #2563EB; }
.is-held:not(.is-released) .privacy-mic__line { stroke: #2563EB; }
.is-held:not(.is-released) .privacy-label-on { opacity: 1; }
.is-held:not(.is-released) .privacy-label-off { opacity: 0; }
.is-held:not(.is-released) .privacy-key__top { transform: translateY(3px); }
.is-held:not(.is-released) .privacy-key__face { fill: #BFDBFE; }
.draws-ink .is-held:not(.is-released) .privacy-mic__ring { animation: kit-ripple 1.4s ease-out infinite; }
.draws-ink .is-held:not(.is-released) .privacy-mic__ring--second { animation-delay: 0.7s; }
.draws-ink .privacy-key__top { transition: transform 0.12s; }
.draws-ink .privacy-label-on, .draws-ink .privacy-label-off { transition: opacity 0.15s; }

.privacy-parcel, .privacy-reply { opacity: 0; }
.is-answering .privacy-reply { opacity: 1; transform: translateX(-190px); }
.draws-ink .is-sending .privacy-parcel { animation: privacy-parcel-goes 1.5s ease-in-out both; }
.draws-ink .is-answering .privacy-reply { animation: privacy-reply-returns 1.4s ease-in-out both; }
@keyframes privacy-parcel-goes { 0% { opacity: 0; transform: none; } 12%, 86% { opacity: 1; } 100% { opacity: 0; transform: translateX(166px); } }
@keyframes privacy-reply-returns { 0% { opacity: 0; transform: none; } 14% { opacity: 1; } 100% { opacity: 1; transform: translateX(-190px); } }

.little-scene.is-erased .memory-note { opacity: 0; }

.privacy-save { fill: #fff; stroke: #3380FF; stroke-width: 1.5; }
.privacy-save__text { fill: #2563EB; }
.privacy-pointer, .privacy-click-ring { opacity: 0; }
.privacy-click-ring { transform-box: fill-box; transform-origin: center; }
.is-clicking .privacy-pointer { opacity: 1; transform: translate(160px, -36px); }
.is-clicked .privacy-save { fill: #2563EB; }
.is-clicked .privacy-save__text { fill: #fff; }
.draws-ink .privacy-pointer { transition: transform 0.9s cubic-bezier(0.3, 0, 0.2, 1), opacity 0.2s; }
.draws-ink .is-clicked .privacy-click-ring { animation: kit-ripple 0.9s ease-out 2; }
