/*
 * The home page: our own scenes, full screen, one after another; the words set
 * straight into the sky; KUSHU huge along the bottom. No boxes, no glass.
 */

@font-face {
  font-family: 'Inter';
  src: url('fonts/Inter-Variable.ttf') format('truetype');
  font-weight: 100 900;
  font-display: swap;
}

:root {
  --ink: #0E0C0B;
  --text: #F6F1EA;
  --soft: rgba(246, 241, 234, 0.72);
  --faint: rgba(246, 241, 234, 0.16);
  --sans: 'Google Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; overflow-x: clip; }
body { margin: 0; background: var(--ink); color: var(--text); font-family: var(--sans); -webkit-font-smoothing: antialiased; }
a { color: inherit; }
[hidden] { display: none !important; }
:focus-visible { outline: 2px solid #fff; outline-offset: 3px; border-radius: 4px; }


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

.hero {
  position: relative;
  height: 100svh;
  min-height: 560px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.slides, .slide { position: absolute; inset: 0; }
.slide {
  background-size: cover;
  background-position: center 60%;
  opacity: 0;
  transform: scale(1.06);
  transition: opacity 1800ms ease, transform 9000ms linear;
}
.slide.is-on { opacity: 1; transform: scale(1); }
/* Darker at the top for the words, and at the bottom where KUSHU sits. */
.slides::after {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 60% 55% at 12% 38%, rgba(8, 10, 14, 0.42), rgba(8, 10, 14, 0) 70%),
    linear-gradient(180deg, rgba(8, 10, 14, 0.45) 0%, rgba(8, 10, 14, 0) 38%, rgba(14, 12, 11, 0) 55%, rgba(14, 12, 11, 0.55) 74%, rgba(14, 12, 11, 0.9) 90%, var(--ink) 100%);
}

.nav {
  position: relative;
  z-index: 2;
  display: flex;
  justify-content: space-between;
  align-items: center;
  /* Below the phone's status bar (the page reaches under it: viewport-fit=cover). */
  padding: calc(env(safe-area-inset-top, 0px) + 22px) clamp(16px, 4vw, 48px) 22px;
  font-size: 15px;
}
.wordmark { font-weight: 700; font-size: 18px; letter-spacing: -0.01em; text-decoration: none; }
.nav nav { display: flex; gap: clamp(16px, 3vw, 32px); }
.nav nav a { text-decoration: none; color: var(--soft); transition: color 200ms; }
.nav nav a:hover { color: var(--text); }

.hero-words {
  position: relative;
  z-index: 2;
  margin-top: clamp(24px, 9vh, 110px);
  padding: 0 clamp(16px, 4vw, 48px);
  max-width: 760px;
}
.hero h1 {
  margin: 0;
  font-size: clamp(40px, 6.4vw, 92px);
  line-height: 1.06;
  font-weight: 700;
  letter-spacing: -0.028em;
  max-width: 11ch;
}
.lede { margin: 18px 0 0; font-size: clamp(16px, 1.5vw, 19px); line-height: 1.5; color: rgba(246, 241, 234, 0.9); max-width: 34ch; }
.cta { display: flex; flex-wrap: wrap; align-items: center; gap: 18px; margin-top: 28px; }
.cta-alt { font-size: 14px; color: var(--text); }
.cta-note { margin: 12px 0 0; font-size: 13px; color: rgba(246, 241, 234, 0.85); }

.button {
  display: inline-block;
  padding: 13px 24px;
  border-radius: 999px;
  background: var(--text);
  color: var(--ink);
  font-size: 15px;
  font-weight: 600;
  text-decoration: none;
  text-shadow: none;
  transition: transform 200ms, background 200ms;
}
.button:hover { background: #fff; transform: translateY(-1px); }

/* The name, huge, sinking into the ground. */
.giant {
  position: absolute;
  z-index: 1;
  left: 0;
  right: 0;
  bottom: 0.02em;
  margin: 0;
  text-align: center;
  font-size: clamp(96px, 25vw, 420px);
  line-height: 1;
  font-weight: 800;
  letter-spacing: -0.05em;
  color: transparent;
  background: linear-gradient(180deg, rgba(246, 241, 234, 0.92) 0%, rgba(246, 241, 234, 0.3) 50%, rgba(246, 241, 234, 0) 84%);
  -webkit-background-clip: text;
  background-clip: text;
  user-select: none;
  pointer-events: none;
}

/* ---- what it does ---- */

.what {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 40px clamp(24px, 4vw, 56px);
  padding: clamp(72px, 12vh, 140px) clamp(16px, 4vw, 48px);
  max-width: 1280px;
  margin: 0 auto;
}
.line { border-top: 1px solid var(--faint); padding-top: 18px; }
.eyebrow { margin: 0; font-size: 12px; font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase; color: var(--soft); }
.line h2 { margin: 10px 0 10px; font-size: clamp(24px, 2.4vw, 32px); line-height: 1.15; font-weight: 700; letter-spacing: -0.02em; }
.line p:not(.eyebrow) { margin: 0; color: var(--soft); line-height: 1.55; }

/* ---- download ---- */

.download { padding: 0 clamp(16px, 4vw, 48px) clamp(80px, 14vh, 160px); max-width: 1280px; margin: 0 auto; }
.download h2 { margin: 0 0 36px; font-size: clamp(36px, 5vw, 64px); font-weight: 700; letter-spacing: -0.028em; }
.platforms { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 32px; }
.platform { border-top: 1px solid var(--faint); padding-top: 18px; display: flex; flex-direction: column; align-items: flex-start; gap: 12px; }
.platform h3 { margin: 0; font-size: 20px; font-weight: 600; }
.platform p { margin: 0; color: var(--soft); line-height: 1.5; font-size: 15px; }
.platform .button { margin-top: 6px; padding: 11px 20px; font-size: 14px; }
.platform.is-yours { border-top-color: var(--text); }
.version { font-size: 13px !important; }

.footer {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px;
  padding: 24px clamp(16px, 4vw, 48px) 32px;
  border-top: 1px solid var(--faint);
  font-size: 13px;
  color: var(--soft);
}

@media (max-width: 600px) {
  /* A phone: the whole picture as a band at the top (as on the other pages), the words under it on dark. */
  .hero { --band: clamp(240px, 36vh, 380px); height: auto; min-height: 0; display: block; padding-bottom: 8px; }
  .slides { bottom: auto; height: var(--band); }
  .slide { background-position: center 55%; transform: none; }
  .slides::after {
    background: linear-gradient(180deg, rgba(8, 10, 14, 0.4) 0%, rgba(14, 12, 11, 0) 35%, rgba(14, 12, 11, 0.55) 72%, var(--ink) 100%);
  }
  .nav { position: absolute; top: 0; left: 0; right: 0; }
  .nav nav a[href="#what"] { display: none; }
  .hero-words { margin-top: 0; padding-top: calc(var(--band) - 28px); text-shadow: none; }
  .hero h1 { font-size: 42px; max-width: none; }
  .giant { position: static; margin: 32px 0 0; font-size: 24vw; letter-spacing: -0.03em; }
  .cta { gap: 12px; }
  .cta-alt { flex-basis: 100%; }
  .story { padding-top: 8px; }
  .what { padding-top: 56px; padding-bottom: 72px; }
}

@media (prefers-reduced-motion: reduce) {
  .slide { transition: none; transform: none; }
  html { scroll-behavior: auto; }
}

/* ---- why it works: the story, set large and quiet ---- */
.story {
  max-width: 760px;
  margin: 0 auto;
  padding: clamp(80px, 14vh, 160px) clamp(16px, 4vw, 48px) 0;
}
.story h2 { margin: 12px 0 22px; font-size: clamp(34px, 5vw, 62px); line-height: 1.06; font-weight: 700; letter-spacing: -0.028em; }
.story p:not(.eyebrow) { margin: 0 0 16px; font-size: clamp(18px, 1.8vw, 22px); line-height: 1.6; color: var(--soft); }
.story p:last-child { color: var(--text); }
.story .held { margin-top: 28px; font-size: clamp(15px, 1.3vw, 17px) !important; letter-spacing: 0.02em; color: var(--soft) !important; font-style: italic; }

/* ---- the hero, set as spacefs.com sets theirs: centred, Google Sans, a quieter second line ---- */
.hero-words {
  margin: clamp(40px, 12vh, 140px) auto 0;
  max-width: 760px;
  text-align: center;
}
.hero h1 {
  max-width: none;
  font-weight: 400;
  font-size: clamp(42px, 5.6vw, 76px);
  line-height: 1.02;
  letter-spacing: -0.035em;
}
.hero h1 span { color: rgba(246, 241, 234, 0.72); }
.hero .lede { margin: 22px auto 0; max-width: 36ch; font-size: clamp(16px, 1.3vw, 18px); line-height: 1.6; color: rgba(246, 241, 234, 0.86); text-align: center; }
.hero .cta { justify-content: center; margin-top: 30px; }
.hero .button { padding: 14px 30px; font-weight: 500; }
.platforms-note { margin: 16px 0 0; font-size: 12px; letter-spacing: 0.02em; color: rgba(246, 241, 234, 0.7); text-align: center; }
.story h2, .download h2, .line h2 { font-weight: 500; letter-spacing: -0.03em; }
@media (max-width: 600px) {
  .hero-words { padding-left: 16px; padding-right: 16px; }
  .hero h1 { font-size: 40px; }
}

/* ---- 2026-10-17: the words at the bottom middle of the scene; MAST down by the footer ---- */
.hero-words { position: absolute; z-index: 2; left: 0; right: 0; bottom: clamp(48px, 9vh, 96px); margin: 0 auto; padding: 0 16px; }
.hero h1 { font-weight: 500; line-height: 0.96; }
.giant { position: static; margin: clamp(48px, 10vh, 120px) 0 -0.12em; overflow: hidden; }
.intro { max-width: 760px; margin: 0 auto; padding: clamp(80px, 14vh, 150px) clamp(16px, 4vw, 48px) 0; }
.intro h2 { margin: 0 0 20px; font-size: clamp(30px, 4vw, 52px); line-height: 1.04; font-weight: 500; letter-spacing: -0.03em; }
.intro p { margin: 0; font-size: clamp(18px, 1.8vw, 22px); line-height: 1.6; color: var(--soft); }
.story { padding-top: clamp(64px, 10vh, 110px); }
.how { max-width: 1280px; margin: 0 auto; padding: clamp(80px, 14vh, 150px) clamp(16px, 4vw, 48px) 0; }
.how > h2 { margin: 0; font-size: clamp(30px, 4vw, 52px); line-height: 1.04; font-weight: 500; letter-spacing: -0.03em; }
.how .what { padding: 40px 0 clamp(72px, 12vh, 140px); }
.line h3 { margin: 0 0 10px; font-size: clamp(20px, 1.9vw, 24px); line-height: 1.2; font-weight: 500; letter-spacing: -0.02em; }
@media (max-width: 600px) {
  .hero-words { position: static; padding-top: calc(var(--band) - 28px); }
  .intro { padding-top: 56px; }
  .story { padding-top: 48px; }
  .how { padding-top: 64px; }
  .how .what { padding: 28px 0 64px; }
  .giant { margin-top: 24px; }
}
/* The car and the figure above the words, not behind them. */
@media (min-width: 601px) { .slide { background-position: center 88%; } }
@media (min-width: 601px) {
  .hero-words { bottom: clamp(20px, 4vh, 44px); }
  .hero h1 { font-size: clamp(40px, 4.6vw, 64px); }
  .hero .lede { margin-top: 14px; }
  .hero .cta { margin-top: 20px; }
  .platforms-note { margin-top: 12px; }
}

/* ---- 2026-10-17 fixes ---- */
/* Only the first line bold; the second quieter, regular. */
.hero h1 { font-weight: 400; }
.hero h1 .strong { font-weight: 600; color: var(--text); }
/* The problem: one light line, not a heading. */
.intro p { font-size: clamp(20px, 2vw, 26px); line-height: 1.5; font-weight: 400; color: var(--soft); letter-spacing: -0.01em; }
@media (max-width: 600px) {
  /* In front of the picture band, and left-aligned as before. */
  .hero-words { position: relative; z-index: 2; bottom: auto; text-align: center; padding: calc(var(--band) - 28px) 16px 0; }
  .hero h1 { font-size: 42px; line-height: 1.02; }
}

/* ---- the picture switch: a soft pill with two line icons, as in the reference ---- */
.nav nav { align-items: center; }
.scene-switch { display: inline-flex; gap: 2px; padding: 3px; border-radius: 999px; background: rgba(246, 241, 234, 0.12); box-shadow: inset 0 0 0 1px rgba(246, 241, 234, 0.16); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px); }
.scene-switch button { width: 32px; height: 28px; padding: 0; border: 0; border-radius: 999px; background: transparent; color: rgba(246, 241, 234, 0.72); cursor: pointer; display: grid; place-items: center; transition: background 200ms, color 200ms; }
.scene-switch button:hover { color: var(--text); }
.scene-switch button svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.scene-switch button[aria-checked="true"] { background: rgba(246, 241, 234, 0.95); color: #1A1A1A; box-shadow: 0 1px 4px rgba(0, 0, 0, 0.25); }
/* Only the chosen picture shows. */
body:not(.blossom) .blossom-only, body.blossom .field-only { display: none; }
body { transition: background-color 400ms; }
/* The top bar above everything in the hero, so its links and the picture switch can always be tapped. */
.nav { z-index: 10; }

/* ---- the top edge: Safari's status bar takes the picture's own top colour, and the picture fades into it ---- */
:root { --top: #22424A; }
html { background-color: var(--top); }
body { background-color: var(--ink); }
.hero::before {
  content: '';
  position: absolute;
  z-index: 1;
  top: 0;
  left: 0;
  right: 0;
  height: 140px;
  pointer-events: none;
  background: linear-gradient(180deg, var(--top) 0%, rgba(34, 66, 74, 0.55) 40%, rgba(34, 66, 74, 0) 100%);
}
body.blossom { --top: #632B2E; }
html:has(body.blossom) { --top: #632B2E; }
body.blossom .hero::before { background: linear-gradient(180deg, #632B2E 0%, rgba(99, 43, 46, 0.5) 40%, rgba(99, 43, 46, 0) 100%); }

/* ---- 2026-10-17: phones get the tall picture, full screen; the top and bottom both melt ---- */
/* Safari tints its bar from the page's own background: make that the picture's top colour, and keep the reading area dark. */
body { background-color: var(--top); }
main, .giant, .footer { background-color: var(--ink); }
.hero { background-color: var(--top); }
@media (max-width: 600px) {
  .hero { --band: 100svh; height: 100svh; min-height: 600px; display: block; }
  .slides { bottom: 0; height: auto; }
  .field-only { background-image: url('img/scene-field-tall.webp') !important; }
  .slide { background-position: center 40%; }
  .slides::after {
    background: linear-gradient(180deg, rgba(14, 12, 11, 0) 0%, rgba(14, 12, 11, 0) 44%, rgba(14, 12, 11, 0.4) 62%, rgba(14, 12, 11, 0.8) 80%, rgba(14, 12, 11, 0.95) 92%, var(--ink) 100%);
  }
  .hero-words { position: absolute; left: 0; right: 0; bottom: 40px; padding: 0 16px; text-align: center; }
  .hero::before { height: 160px; }
}

/* ---- the bottom: dark behind MAST, and the page dark once the picture has scrolled away ---- */
.giant-wrap { background-color: var(--ink); overflow: hidden; }
body.past-hero { background-color: var(--ink); }
html:has(body.past-hero) { background-color: var(--ink); }
.footer { padding-bottom: calc(32px + env(safe-area-inset-bottom, 0px)); }

/* ---- the moment: a two-tone headline, then the moment shown on a screen (as spacefs shows its product) ---- */
.moment { max-width: 1040px; text-align: center; }
.moment h2 { margin: 0; font-size: clamp(34px, 4.6vw, 64px); line-height: 1.02; font-weight: 400; letter-spacing: -0.035em; }
.moment h2 .strong { font-weight: 600; color: var(--text); }
.moment h2 span:not(.strong) { color: rgba(246, 241, 234, 0.6); }
.moment .moment-sub { margin: 20px auto 0; max-width: 34ch; font-size: clamp(16px, 1.4vw, 19px); line-height: 1.6; color: var(--soft); }

.moment .moment-sub { max-width: 44ch; }

/* ---- the moment: the reading story, told on white pages, ending on Mast's real lock screen (lockscreen/). */
.demo { margin: clamp(40px, 7vh, 72px) auto 0; max-width: 1000px; text-align: left; }
/* Drawn at 1000 × 640 and scaled to fit, so a phone sees the same screen, smaller. */
.demo-frame { position: relative; width: 100%; aspect-ratio: 1000 / 640; border-radius: 14px; overflow: hidden; box-shadow: 0 50px 120px rgba(0, 0, 0, 0.55), 0 0 0 1px rgba(255, 255, 255, 0.12); }
.demo-stage { position: absolute; left: 0; top: 0; width: 1000px; height: 640px; transform-origin: 0 0; transform: scale(var(--k, 1)); overflow: hidden; background: #1a1a1a url('img/scene-car-field.webp') center / cover; font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif; color: #F1F1F1; }
body.blossom .demo-stage { background-image: url('img/scene-blossom.webp'); }
.demo p { margin: 0; max-width: none; letter-spacing: normal; color: inherit; font-size: inherit; line-height: inherit; }


/* One stage per scroll: the screen holds still while the page moves on underneath it. */
.demo { height: calc(100vh + 12 * 72vh); height: calc(100svh + 12 * 72svh); }
.demo-sticky { position: sticky; top: 0; height: 100vh; height: 100svh; display: flex; flex-direction: column; justify-content: center; gap: 18px; }
.demo-frame { width: min(100%, calc((100vh - 150px) * 1000 / 640)); margin: 0 auto; }




/* The opening and the ending: white, and the name coming into focus, as Apple shows a name. */
.demo { --accent: #2F5A56; }
body.blossom .demo { --accent: #6E1A24; }
.brand-screen { position: absolute; inset: 0; z-index: 8; display: grid; place-items: center; background: #fff; opacity: 0; pointer-events: none; transition: opacity 900ms ease; }
.demo.brand .brand-screen { opacity: 1; }
.demo .brand-screen .brand-word, .demo .brand-screen .brand-line { grid-area: 1 / 1; margin: 0; text-align: center; font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Display', Inter, system-ui, sans-serif; opacity: 0; filter: blur(14px); transform: scale(1.06); transition: opacity 1100ms cubic-bezier(.2, .8, .2, 1), filter 1100ms cubic-bezier(.2, .8, .2, 1), transform 1600ms cubic-bezier(.2, .8, .2, 1); }
.demo .brand-screen .brand-word { font-size: 132px; line-height: 1; font-weight: 700; letter-spacing: -0.055em; color: var(--accent); }
.demo .brand-screen .brand-line { max-width: 720px; font-size: 46px; line-height: 1.08; font-weight: 600; letter-spacing: -0.035em; color: #1D1D1F; }
.demo.word-in .brand-screen .brand-word, .demo.line-in .brand-screen .brand-line { opacity: 1; filter: blur(0); transform: none; }
.demo.word-out .brand-screen .brand-word { opacity: 0; filter: blur(10px); transform: translateY(-18px) scale(0.97); transition-duration: 700ms; }

.moment .demo .brand-screen .brand-line { max-width: 640px; }

/* The last words: two short lines, the same size, the second in the picture's colour. */
.moment .demo .brand-screen .brand-line { max-width: none; }
.demo .brand-screen .brand-line .l1, .demo .brand-screen .brand-line .l2 { display: block; white-space: nowrap; font-size: 40px; line-height: 1.2; }
.demo .brand-screen .brand-line .l1 { color: #1D1D1F; }
.demo .brand-screen .brand-line .l2 { color: var(--accent); }

/* Nothing white waits unseen on the pinned screen (Safari colours its bars from what it finds there). */
.demo-sticky { background: var(--ink, #0E0C0B); }
.brand-screen { background: transparent; opacity: 1; transition: background-color 900ms ease; }
.demo.brand .brand-screen { background: #fff; }


/* After the name: what Mast is, three lines a page, each coming into focus after the last. */
.intro-page { grid-area: 1 / 1; text-align: center; }
.moment .demo .intro-page p { margin: 0; font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Display', Inter, system-ui, sans-serif; font-size: 40px; line-height: 1.12; font-weight: 600; letter-spacing: -0.03em; color: #1D1D1F; opacity: 0; filter: blur(12px); transform: translateY(10px); transition: opacity 400ms ease, filter 400ms ease, transform 400ms ease; }
.demo .intro-page p em { font-style: normal; color: var(--accent); }
/* A time or a length never breaks across lines ("6 / AM"). */
.demo .intro-page p em { white-space: nowrap; }
.demo .intro-page p.on { opacity: 1; filter: blur(0); transform: none; transition: opacity 1000ms cubic-bezier(.2, .8, .2, 1), filter 1000ms cubic-bezier(.2, .8, .2, 1), transform 1200ms cubic-bezier(.2, .8, .2, 1); }


/* The reading story: a 16:9 frame for the real recording; the white pages over it until it rolls. */
.demo.reel { height: auto; }
.demo.reel .demo-sticky { position: static; height: auto; padding: 24px 0; }
.demo.reel .demo-frame { aspect-ratio: 16 / 9; width: min(100%, calc((100vh - 150px) * 16 / 9)); width: min(100%, calc((100svh - 150px) * 16 / 9)); }
.demo.reel .demo-stage { height: 562.5px; background: #fff; }
.demo.reel .intro-page { max-width: 760px; }
.demo.reel .intro-page p { white-space: normal; text-wrap: balance; }
.demo.reel .intro-page p + p { margin-top: 18px; }
.demo.reel .brand-screen .brand-line .l2 { color: var(--accent); }

/* A time on a page of its own: big, in the accent colour. */
.moment .demo.reel .intro-page.time p { font-size: 96px; line-height: 1; letter-spacing: -0.045em; color: var(--accent); }

/* The clock between the words: the minute rolls up into place. */
.demo.reel .tick-label { display: block; margin-bottom: 14px; font-size: 32px; letter-spacing: -0.02em; color: #6E6E73; }
.demo.reel .tick { display: inline-block; overflow: hidden; height: 1.05em; vertical-align: top; font-variant-numeric: tabular-nums; }
.demo.reel .tick span { display: block; }
.demo.reel .tick { position: relative; min-width: 4.6em; text-align: center; }
.demo.reel .tick span + span { position: absolute; left: 0; right: 0; top: 0; }
.demo.reel .tick .in { animation: tick-in 640ms cubic-bezier(.33, 0, .2, 1) both; }
.demo.reel .tick .out { animation: tick-out 640ms cubic-bezier(.33, 0, .2, 1) both; }
@keyframes tick-in { from { transform: translateY(70%); opacity: 0; filter: blur(4px); } to { transform: none; opacity: 1; filter: none; } }
@keyframes tick-out { from { transform: none; opacity: 1; filter: none; } to { transform: translateY(-70%); opacity: 0; filter: blur(4px); } }
/* The last line's ask, big. */
.demo.reel .huge { display: block; margin-top: 10px; font-size: 104px; line-height: .95; letter-spacing: -0.05em; color: var(--accent); }
/* Mast's lock screen over the whole frame (its page is 1600 × 900, drawn at the frame's size). */
/* The lock lands: a cut to black (the computer going dark), then the lock screen slams in from a touch too
   big and blurred, sharp and still in a blink, and the whole frame takes the knock. */
.demo.reel .reel-shut { position: absolute; inset: 0; z-index: 8; background: #000; opacity: 0; pointer-events: none; transition: opacity 90ms linear; }
.demo.reel.shut .reel-shut { opacity: 1; }
.demo.reel.locked .reel-shut { opacity: 0; transition: opacity 500ms ease 300ms; }
.demo.reel .reel-lock { position: absolute; inset: 0; z-index: 9; overflow: hidden; opacity: 0; pointer-events: none; transform: scale(1.12); filter: blur(18px) brightness(1.6);
  transition: opacity 260ms ease, transform 620ms cubic-bezier(.16, 1, .3, 1), filter 520ms cubic-bezier(.16, 1, .3, 1); }
.demo.reel .reel-lock iframe { position: absolute; left: 0; top: 0; width: 1600px; height: 900px; border: 0; transform-origin: 0 0; transform: scale(0.625); }
.demo.reel.locked .reel-lock { opacity: 1; transform: none; filter: none; }
.demo.reel.thud .demo-frame { animation: lock-thud 520ms cubic-bezier(.3, 0, .2, 1) 180ms both; }
@keyframes lock-thud { 0% { transform: scale(1); } 35% { transform: scale(0.982); } 70% { transform: scale(1.006); } 100% { transform: scale(1); } }
@media (prefers-reduced-motion: reduce) {
  .demo.reel .reel-lock { transform: none; filter: none; transition: opacity 400ms ease; }
  .demo.reel.thud .demo-frame { animation: none; }
}

/* The line under the demo, filling as it plays. */
.demo.reel .reel-progress { width: min(100%, calc((100vh - 150px) * 16 / 9)); margin: 16px auto 0; height: 3px; border-radius: 2px; background: rgba(255, 255, 255, 0.12); overflow: hidden; }
.demo.reel .reel-progress i { display: block; height: 100%; width: 0; background: rgba(255, 255, 255, 0.6); }

/* The first time: the white grows out of the card to the whole screen, and back. The demo sits above it. */
.takeover { display: none; position: fixed; inset: 0; z-index: 40; background: #fff; pointer-events: none; clip-path: inset(50% 50% 50% 50%); transition: clip-path 900ms cubic-bezier(.22, 1.1, .36, 1); }
/* Gone entirely when not in use: a phone's browser tints its bars from what sits at the top and bottom. */
.takeover.on { display: block; }
body.demo-held .demo.reel .demo-frame { position: relative; z-index: 41; box-shadow: none; transition: box-shadow 600ms ease; }
body.demo-held .demo.reel .reel-progress { position: relative; z-index: 41; background: rgba(0, 0, 0, 0.08); }
body.demo-held .demo.reel .reel-progress i { background: rgba(0, 0, 0, 0.35); }
.takeover-skip { position: fixed; right: 24px; bottom: 22px; z-index: 42; border: 0; background: none; cursor: pointer; padding: 8px 12px; font: 500 14px -apple-system, BlinkMacSystemFont, 'SF Pro Text', Inter, system-ui, sans-serif; color: rgba(0, 0, 0, 0.42); }
.takeover-skip:hover { color: rgba(0, 0, 0, 0.75); }
@media (prefers-reduced-motion: reduce) { .takeover { transition: none; } }
html { scrollbar-gutter: stable; }
html.held, html.held body { overflow: hidden; }
html.held { background-color: #fff; }

/* "Another scenario?" and its Yes: only pressable while the question is showing. */
.demo .ask-yes { display: block; margin-top: 26px; }
.demo .ask-yes button { appearance: none; -webkit-appearance: none; border: 0; cursor: pointer; pointer-events: none; padding: 16px 44px; border-radius: 999px;
  font: 600 30px/1 -apple-system, BlinkMacSystemFont, 'SF Pro Display', Inter, system-ui, sans-serif; letter-spacing: -0.02em; color: #fff; background: var(--accent);
  box-shadow: 0 10px 30px rgba(20, 30, 28, 0.25); transition: transform 150ms ease, filter 150ms ease; }
.demo .intro-page p.on .ask-yes button { pointer-events: auto; }
.demo .ask-yes button:hover { filter: brightness(1.12); }
.demo .ask-yes button:active { transform: scale(0.96); }
