/* ==========================================================================
   Modueh — marketing site
   Brand: logo brown #6f4b22 (app /brand), cream #fdf7ec and yellow #fbcf2d
   (printed tri-fold). Geist for Latin text; Heebo only for Hebrew script.
   Scroll-driven chapters set --p (0 to 1) on [data-pin] sections.
   ========================================================================== */

:root {
  --cream: #fdf7ec;
  --cream-2: #f6edda;
  --white: #fffdf8;
  --brown: #6f4b22;
  --brown-2: #5a3b18;
  --ink: #2a1c0c;
  --ink-2: #4a3418;
  --muted: #8a7052;
  --gold: #fbcf2d;
  --gold-2: #e9bb17;
  --line: rgba(111, 75, 34, 0.14);
  --line-2: rgba(111, 75, 34, 0.3);
  --shadow: 0 24px 64px rgba(63, 42, 17, 0.12), 0 2px 6px rgba(63, 42, 17, 0.06);

  --font: "Geist", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-he: "Heebo", "Geist", system-ui, sans-serif;

  --ease: cubic-bezier(0.32, 0.72, 0, 1);
  --dur: 800ms;

  --s-25: 2px; --s-50: 4px; --s-75: 8px; --s-100: 12px; --s-200: 16px;
  --s-300: 24px; --s-400: 32px; --s-500: 40px; --s-600: 48px;
  --s-700: 64px; --s-800: 80px; --s-900: 96px;

  --r-md: 8px; --r-lg: 12px; --r-xl: 16px; --r-2xl: 24px; --r-full: 999px;

  --top-h: 64px;
  --vh: 100vh;
}
@supports (height: 100dvh) { :root { --vh: 100dvh; } }

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 1rem; line-height: 1.5rem;
  color: var(--ink-2);
  background: var(--cream);
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}
h1, h2, h3, p, ul, ol, figure { margin: 0; }
ul, ol { padding: 0; list-style: none; }
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
strong { font-weight: 600; }
small { font-size: 0.875rem; line-height: 1.25rem; }
:focus-visible { outline: 2px solid var(--gold-2); outline-offset: 3px; border-radius: var(--r-md); }
::selection { background: var(--gold); color: var(--ink); }

h1, h2, h3 { color: var(--ink); font-weight: 600; letter-spacing: -0.02em; text-wrap: balance; }
p { text-wrap: pretty; }
h2 { font-size: 2.25rem; line-height: 2.5rem; }
@media (min-width: 900px) { h2 { font-size: 3rem; line-height: 1.08; } }

.container { width: 100%; max-width: 1120px; margin-inline: auto; padding-inline: var(--s-300); }
@media (min-width: 900px) { .container { padding-inline: var(--s-500); } }

.icon { width: 1.125em; height: 1.125em; fill: currentColor; flex: none; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }

.skip {
  position: absolute; left: var(--s-200); top: var(--s-200); z-index: 100;
  padding: var(--s-75) var(--s-200); border-radius: var(--r-full);
  background: var(--brown); color: var(--cream); font-weight: 600;
  transform: translateY(-200%); transition: transform 0.4s var(--ease);
}
.skip:focus { transform: none; }

/* The three-dot mark from the wordmark, used as a small ornament */
.dots { display: inline-flex; gap: 4px; }
.dots i { width: 5px; height: 5px; border-radius: 50%; background: var(--gold); }

/* Chapter label */
.chapter {
  display: flex; align-items: center; gap: var(--s-100);
  font-size: 0.875rem; line-height: 1.25rem; font-weight: 500; color: var(--muted);
  margin-bottom: var(--s-300);
}
.chapter span { font-weight: 600; color: var(--brown); letter-spacing: 0.06em; }
.chapter::after { content: ""; width: 32px; height: 1px; background: var(--line-2); }
.chapter-light { color: rgba(253, 247, 236, 0.7); }
.chapter-light span { color: var(--gold); }
.chapter-light::after { background: rgba(253, 247, 236, 0.3); }

.eyebrow-yi { font-family: var(--font-he); font-weight: 700; color: var(--brown); font-size: 1.5rem; line-height: 2rem; text-align: left; }
.yi { font-family: var(--font-he); font-weight: 700; }

/* ---------- Buttons and links ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: var(--s-75);
  padding: var(--s-100) var(--s-300);
  border-radius: var(--r-full);
  font-size: 1rem; line-height: 1.5rem; font-weight: 600;
  white-space: nowrap;
  transition: transform 0.7s var(--ease), background-color 0.7s var(--ease), color 0.7s var(--ease), box-shadow 0.7s var(--ease);
}
.btn .icon { transition: transform 0.7s var(--ease); }
.btn:hover { transform: translateY(-2px); }
.btn:hover .icon { transform: translateX(3px); }
.btn:active { transform: scale(0.98); }
.btn-sm { padding: var(--s-75) var(--s-200); font-size: 0.875rem; line-height: 1.25rem; }
.btn-primary { background: var(--brown); color: var(--cream); }
.btn-primary:hover { background: var(--brown-2); box-shadow: 0 12px 28px rgba(111, 75, 34, 0.22); }
.btn-gold { background: var(--gold); color: var(--ink); }
.btn-gold:hover { background: var(--gold-2); box-shadow: 0 12px 28px rgba(0, 0, 0, 0.2); }

.link-quiet, .link-arrow {
  display: inline-flex; align-items: center; gap: var(--s-75);
  font-weight: 500; color: var(--brown); position: relative; padding: var(--s-100) 0;
}
.link-quiet::after, .link-arrow::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 6px; height: 1.5px;
  background: currentColor; transform: scaleX(0.3); transform-origin: left; opacity: 0.5;
  transition: transform 0.7s var(--ease), opacity 0.7s var(--ease);
}
.link-quiet:hover::after, .link-arrow:hover::after { transform: scaleX(1); opacity: 1; }
.link-arrow { font-weight: 600; font-size: 1.125rem; line-height: 1.75rem; }
.link-arrow .icon { transition: transform 0.7s var(--ease); }
.link-arrow:hover .icon { transform: translateX(4px); }

/* ---------- Header: a slim bar with a scroll progress line ---------- */
.top {
  position: fixed; inset: 0 0 auto 0; z-index: 60;
  background: rgba(253, 247, 236, 0);
  transition: background-color 0.6s var(--ease), box-shadow 0.6s var(--ease);
}
.top.is-scrolled { background: rgba(253, 247, 236, 0.94); box-shadow: 0 1px 0 var(--line); }
.top-inner {
  height: var(--top-h);
  display: flex; align-items: center; justify-content: space-between; gap: var(--s-300);
  padding-inline: var(--s-300);
}
.top-logo img { width: 84px; height: auto; }
.top-links { display: none; gap: var(--s-400); }
.top-links a {
  position: relative; font-size: 0.875rem; line-height: 1.25rem; font-weight: 500; color: var(--ink-2);
  padding: var(--s-50) 0; transition: color 0.5s var(--ease);
}
.top-links a::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 1.5px; background: var(--brown);
  transform: scaleX(0); transform-origin: left; transition: transform 0.6s var(--ease);
}
.top-links a:hover, .top-links a.is-current { color: var(--brown); }
.top-links a.is-current::after { transform: scaleX(1); }
.top-actions { display: flex; align-items: center; gap: var(--s-200); }
.top-signin { display: none; font-size: 0.875rem; line-height: 1.25rem; font-weight: 500; color: var(--ink-2); transition: color 0.5s var(--ease); }
.top-signin:hover { color: var(--brown); }
.top-menu { display: inline-flex; align-items: center; gap: var(--s-75); font-size: 0.875rem; line-height: 1.25rem; font-weight: 500; color: var(--ink); padding: var(--s-50) 0; }
.top-menu-icon { position: relative; width: 18px; height: 14px; }
.top-menu-icon i { position: absolute; left: 0; width: 18px; height: 1.5px; background: var(--ink); border-radius: 2px; transition: transform 0.7s var(--ease), top 0.7s var(--ease); }
.top-menu-icon i:first-child { top: 3px; }
.top-menu-icon i:last-child { top: 10px; }
.top-menu[aria-expanded="true"] .top-menu-icon i:first-child { top: 6px; transform: rotate(45deg); }
.top-menu[aria-expanded="true"] .top-menu-icon i:last-child { top: 6px; transform: rotate(-45deg); }
.top-progress {
  position: absolute; left: 0; bottom: -1px; height: 2px; width: 100%;
  background: var(--brown); transform: scaleX(var(--sp, 0)); transform-origin: left;
}
@media (min-width: 900px) {
  .top-inner { padding-inline: var(--s-500); }
  .top-links { display: flex; }
  .top-signin { display: inline; }
  .top-menu { display: none; }
}

/* Full-screen menu */
.menu {
  position: fixed; inset: 0; z-index: 55;
  background: var(--cream);
  padding-top: var(--top-h);
  opacity: 0; visibility: hidden;
  transition: opacity 0.6s var(--ease), visibility 0s linear 0.6s;
}
.menu[hidden] { display: block; }
.menu.is-open { opacity: 1; visibility: visible; transition-delay: 0s; }
.menu-inner { height: calc(var(--vh) - var(--top-h)); display: flex; flex-direction: column; justify-content: space-between; padding-block: var(--s-600) var(--s-500); }
.menu-links { display: flex; flex-direction: column; gap: var(--s-200); }
.menu-links a, .menu-side {
  opacity: 0; transform: translateY(32px);
  transition: opacity 0.8s var(--ease), transform 0.8s var(--ease);
  transition-delay: calc(var(--i) * 60ms);
}
.menu.is-open .menu-links a, .menu.is-open .menu-side { opacity: 1; transform: none; transition-delay: calc(120ms + var(--i) * 70ms); }
.menu-links a { display: flex; align-items: baseline; gap: var(--s-200); font-size: 2.25rem; line-height: 2.5rem; font-weight: 600; color: var(--ink); letter-spacing: -0.02em; }
.menu-links a span { font-size: 0.875rem; line-height: 1.25rem; font-weight: 600; color: var(--brown); letter-spacing: 0.06em; min-width: 24px; }
.menu-links a:hover { color: var(--brown); }
.menu-side { display: flex; flex-direction: column; align-items: flex-start; gap: var(--s-200); }
.menu-signin { font-size: 0.875rem; line-height: 1.25rem; color: var(--muted); }
.menu-yi { font-family: var(--font-he); font-weight: 700; color: var(--brown); font-size: 1.25rem; line-height: 1.75rem; margin-top: var(--s-300); }
body.menu-open { overflow: hidden; }

/* ---------- Reveal on enter ---------- */
[data-reveal] {
  opacity: 0; transform: translateY(48px); filter: blur(6px);
  transition: opacity var(--dur) var(--ease), transform var(--dur) var(--ease), filter var(--dur) var(--ease);
  transition-delay: calc(var(--i, 0) * 90ms);
}
[data-reveal="left"] { transform: translateX(-48px); }
[data-reveal="right"] { transform: translateX(48px); }
[data-reveal="scale"] { transform: translateY(32px) scale(0.97); }
[data-reveal].in { opacity: 1; transform: none; filter: none; }

/* ---------- Pinned chapters ---------- */
.pin { position: relative; height: calc(var(--pin, 3) * var(--vh)); }
.pin-inner { position: sticky; top: 0; height: var(--vh); overflow: hidden; display: flex; flex-direction: column; justify-content: center; }
@media (max-width: 899px) { .pin { --pin: 2.4; } }

/* ---------- Hero: the board assembles as you scroll ---------- */
.hero { --pin: 2.2; }
.hero .pin-inner { padding-top: var(--top-h); }
.hero-grid { display: grid; gap: var(--s-500); align-items: center; }
.hero-copy { max-width: 620px; }
.hero-title {
  margin-top: var(--s-200);
  font-size: 2.25rem; line-height: 1.06; font-weight: 600; letter-spacing: -0.03em;
  background: linear-gradient(90deg, var(--ink) 0%, var(--brown) 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.hero-sub { margin-top: var(--s-300); font-size: 1.125rem; line-height: 1.75rem; max-width: 480px; }
.hero-cta { display: flex; flex-wrap: wrap; align-items: center; gap: var(--s-200) var(--s-300); margin-top: var(--s-400); }
.scroll-hint {
  position: absolute; left: 50%; bottom: var(--s-300); transform: translateX(-50%);
  display: flex; flex-direction: column; align-items: center; gap: var(--s-75);
  font-size: 0.75rem; line-height: 1rem; font-weight: 500; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted);
  opacity: clamp(0, calc(1 - var(--p, 0) * 6), 1);
}
.scroll-hint i { width: 1px; height: 40px; background: var(--brown); transform-origin: top; animation: hint 2.2s var(--ease) infinite; }
@keyframes hint { 0% { transform: scaleY(0); } 45% { transform: scaleY(1); transform-origin: top; } 46% { transform-origin: bottom; } 100% { transform: scaleY(0); transform-origin: bottom; } }
@media (min-width: 900px) {
  .hero-grid { grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: var(--s-800); }
  .hero-title { font-size: 3rem; }
}
@media (max-width: 899px) {
  .hero { height: auto; }
  .hero .pin-inner { position: static; height: auto; overflow: visible; padding-top: calc(var(--top-h) + var(--s-600)); padding-bottom: var(--s-700); }
  .scroll-hint { display: none; }
}

.scene {
  position: relative; --bp: 0;
  aspect-ratio: 5 / 4.4;
  border-radius: var(--r-2xl);
  background: var(--cream-2);
  border: 1px solid var(--line);
  overflow: hidden;
}
.scene-wall { position: absolute; inset: 0; }
.scrap {
  position: absolute; left: var(--x); top: var(--y); width: 14%; aspect-ratio: 3 / 4; border-radius: 3px;
  background: var(--white); border: 1px solid var(--line);
  --f: clamp(0, calc((var(--bp) - 0.08) / 0.45), 1);
  transform: translateY(calc(var(--f) * 180px)) rotate(calc(var(--r0) + var(--f) * 32deg));
  opacity: calc(1 - var(--f));
}
.scrap::before { content: ""; position: absolute; left: 50%; top: -5px; width: 32%; height: 9px; background: rgba(251, 207, 45, 0.85); transform: translateX(-50%) rotate(-6deg); border-radius: 2px; }
.board { position: absolute; inset: 10% 9%; }
.board-frame {
  position: absolute; inset: 0;
  border: 12px solid var(--brown); border-radius: var(--r-lg);
  background: var(--cream);
  box-shadow: inset 0 0 0 2px var(--gold);
  --fr: clamp(0, calc((var(--bp) - 0.45) / 0.3), 1);
  opacity: var(--fr);
  transform: scale(calc(0.94 + 0.06 * var(--fr)));
}
.posters {
  position: absolute; inset: 24px;
  display: grid; grid-template-columns: repeat(24, 1fr); grid-template-rows: 1fr 1fr; gap: 10px;
}
.poster {
  position: relative; grid-column: span 6; min-width: 0;
  border-radius: 4px; padding: 10% 9%;
  display: flex; flex-direction: column; gap: 7%;
  background: var(--white);
  --a: clamp(0, calc((var(--bp) - var(--t0)) / 0.5), 1);
  transform: translate(calc(var(--sx) * (1 - var(--a))), calc(var(--sy) * (1 - var(--a)))) rotate(calc(var(--sr) * (1 - var(--a))));
  box-shadow: 0 8px 20px rgba(63, 42, 17, calc(0.16 - 0.1 * var(--a)));
  will-change: transform;
}
.poster:nth-child(5) { grid-column: 4 / span 6; }
.poster:nth-child(6) { grid-column: 10 / span 6; }
.poster:nth-child(7) { grid-column: 16 / span 6; }
.p-cream { background: var(--cream-2); }
.p-gold { background: #fdefb9; }
.p-brown { background: var(--brown); }
.tape {
  position: absolute; left: 50%; top: -6px; width: 42%; height: 10px; border-radius: 2px;
  background: rgba(251, 207, 45, 0.9); transform: translateX(-50%) rotate(-5deg);
  opacity: calc(1 - var(--a));
}
.poster-cat { display: block; font-size: 0.5rem; line-height: 0.75rem; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: var(--brown); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.poster-line { display: block; height: 4px; border-radius: 2px; background: rgba(111, 75, 34, 0.22); }
.w-50 { width: 50%; } .w-60 { width: 60%; } .w-70 { width: 70%; } .w-80 { width: 80%; }
.poster-foot { margin-top: auto; height: 5px; width: 40%; border-radius: 2px; background: rgba(111, 75, 34, 0.32); }
.poster-house { color: var(--cream); font-size: 0.625rem; line-height: 0.875rem; font-weight: 600; text-align: center; display: flex; flex-direction: column; align-items: center; gap: 6px; margin: auto 0; }
.poster-foot-brand { font-size: 0.5rem; line-height: 0.75rem; text-align: center; color: rgba(253, 247, 236, 0.7); font-weight: 500; }
.scene-state { position: absolute; left: var(--s-200); bottom: var(--s-200); height: 1rem; font-size: 0.75rem; line-height: 1rem; font-weight: 500; letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted); }
.scene-state span { position: absolute; left: 0; top: 0; white-space: nowrap; }
.state-before { opacity: clamp(0, calc(1 - (var(--bp) - 0.7) / 0.1), 1); }
.state-after { opacity: clamp(0, calc((var(--bp) - 0.8) / 0.1), 1); color: var(--brown); }
@media (max-width: 480px) { .posters { inset: 16px; gap: 6px; } .board-frame { border-width: 8px; } .poster-cat { font-size: 0.4rem; } }

/* ---------- 01 The wall today: stages crossfade ---------- */
.wall { --pin: 3.2; background: var(--cream-2); }
.wall-inner { position: relative; text-align: center; padding-top: var(--top-h); }
.wall-inner .chapter { justify-content: center; }
.wall-inner .chapter::after { display: none; }
.stages { position: relative; height: 320px; }
.stage {
  position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: var(--s-200);
  opacity: 0; transform: translateY(24px);
  transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
  pointer-events: none;
}
.stage.is-active { opacity: 1; transform: none; }
.stage.is-past { opacity: 0; transform: translateY(-24px); }
.stage .yi { font-size: 1.5rem; line-height: 2rem; color: var(--brown); max-width: 720px; }
.stage .en { font-size: 2.25rem; line-height: 1.1; font-weight: 600; letter-spacing: -0.03em; color: var(--ink); max-width: 720px; }
.stage-track { display: flex; justify-content: center; gap: var(--s-75); margin-top: var(--s-400); }
.stage-track i { width: 40px; height: 2px; border-radius: 2px; background: var(--line-2); transition: background-color 0.6s var(--ease), transform 0.6s var(--ease); }
.stage-track i.is-on { background: var(--brown); }
@media (min-width: 900px) {
  .stage .yi { font-size: 2.25rem; line-height: 2.5rem; }
  .stage .en { font-size: 3.75rem; }
  .stages { height: 360px; }
}

/* ---------- Tagline ---------- */
.tagline { padding-block: var(--s-900); }
.tagline-text { max-width: 960px; font-size: 2.25rem; line-height: 1.12; font-weight: 600; letter-spacing: -0.025em; color: var(--ink); text-wrap: balance; }
.tagline-text .w { display: inline-block; color: rgba(42, 28, 12, 0.22); transition: color 0.7s var(--ease); }
.tagline-text .w.on { color: var(--ink); }
@media (min-width: 900px) { .tagline { padding-block: 160px; } .tagline-text { font-size: 3.75rem; } }

/* ---------- 02 How it works: pinned horizontal track ---------- */
.how { --pin: 4.4; }
.how .pin-inner { justify-content: flex-start; padding-top: calc(var(--top-h) + var(--s-400)); }
.how-head { display: flex; align-items: center; justify-content: space-between; }
.how-head .chapter { margin-bottom: 0; }
.how-dots { display: flex; gap: var(--s-200); font-size: 0.875rem; line-height: 1.25rem; font-weight: 600; letter-spacing: 0.06em; color: var(--line-2); }
.how-dots li { transition: color 0.5s var(--ease); }
.how-dots li.is-on { color: var(--brown); }
.track {
  flex: 1; display: flex; width: 100%;
  transform: translate3d(calc(var(--t, 0) * -300%), 0, 0);
  will-change: transform;
}
.slide { flex: none; width: 100%; display: flex; align-items: center; }
.slide-grid { display: grid; gap: var(--s-400); align-items: center; }
.slide-num { display: block; font-size: 0.875rem; line-height: 1.25rem; font-weight: 600; letter-spacing: 0.06em; color: var(--brown); margin-bottom: var(--s-200); }
.slide-copy h2 { font-size: 2.25rem; line-height: 1.08; }
.slide-copy p { margin-top: var(--s-200); font-size: 1.125rem; line-height: 1.75rem; max-width: 440px; }
.slide-copy > * { opacity: 0; transform: translateY(20px); transition: opacity 0.7s var(--ease), transform 0.7s var(--ease); }
.slide.is-active .slide-copy > * { opacity: 1; transform: none; }
.slide.is-active .slide-copy > :nth-child(2) { transition-delay: 0.08s; }
.slide.is-active .slide-copy > :nth-child(3) { transition-delay: 0.16s; }
.ill {
  position: relative; border-radius: var(--r-2xl); background: var(--white); border: 1px solid var(--line);
  padding: var(--s-300); box-shadow: var(--shadow);
  opacity: 0; transform: translateY(24px) scale(0.98);
  transition: opacity 0.8s var(--ease) 0.1s, transform 0.8s var(--ease) 0.1s;
}
.slide.is-active .ill { opacity: 1; transform: none; }
.ill-title { font-size: 1.125rem; line-height: 1.75rem; font-weight: 600; color: var(--ink); }
.ill-hint { margin-top: var(--s-100); font-size: 0.75rem; line-height: 1rem; color: var(--muted); }
.ill-mail img { width: 88px; height: auto; margin-bottom: var(--s-200); }
.ill-input { margin-top: var(--s-200); height: 44px; padding: 0 var(--s-200); display: flex; align-items: center; border: 1.5px solid var(--line-2); border-radius: var(--r-lg); font-size: 0.875rem; color: var(--ink); }
.caret { width: 1.5px; height: 18px; margin-left: 2px; background: var(--brown); animation: blink 1s steps(2) infinite; }
@keyframes blink { to { opacity: 0; } }
.ill-btn { margin-top: var(--s-100); height: 44px; display: grid; place-items: center; border-radius: var(--r-lg); background: var(--brown); color: var(--cream); font-weight: 600; font-size: 0.875rem; }
.ill-mail .ill-hint { text-align: center; }
.ill-cats ul { margin-top: var(--s-200); display: flex; flex-direction: column; }
.ill-cats li {
  display: flex; align-items: center; justify-content: space-between; gap: var(--s-100);
  padding: var(--s-100) 0; border-bottom: 1px solid var(--line); font-size: 0.875rem; line-height: 1.25rem; color: var(--ink);
  opacity: 0; transform: translateX(-12px); transition: opacity 0.6s var(--ease), transform 0.6s var(--ease);
}
.slide.is-active .ill-cats li { opacity: 1; transform: none; }
.slide.is-active .ill-cats li:nth-child(1) { transition-delay: 0.3s; }
.slide.is-active .ill-cats li:nth-child(2) { transition-delay: 0.4s; }
.slide.is-active .ill-cats li:nth-child(3) { transition-delay: 0.5s; }
.slide.is-active .ill-cats li:nth-child(4) { transition-delay: 0.6s; }
.seg-mini { display: inline-flex; padding: 2px; border-radius: var(--r-full); background: var(--cream-2); flex: none; }
.seg-mini i { font-style: normal; font-size: 0.75rem; line-height: 1rem; padding: 2px var(--s-75); border-radius: var(--r-full); color: var(--muted); }
.seg-mini[data-on="0"] i:nth-child(1) { background: var(--brown); color: var(--cream); }
.seg-mini[data-on="1"] i:nth-child(2) { background: var(--gold); color: var(--ink); }
.seg-mini[data-on="2"] i:nth-child(3) { background: var(--ink); color: var(--cream); }
.pages { position: relative; height: 92px; margin-top: var(--s-200); }
.pages i {
  position: absolute; left: 0; top: 0; width: 56px; height: 84px; border-radius: 4px;
  background: var(--white); border: 1px solid var(--line-2); box-shadow: 0 6px 16px rgba(63, 42, 17, 0.1);
  transform: translateX(calc(var(--n) * 22px)); opacity: 0;
  transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
}
.pages i::before { content: ""; position: absolute; left: 8px; right: 8px; top: 10px; height: 5px; background: rgba(111, 75, 34, 0.3); border-radius: 2px; }
.pages i::after { content: ""; position: absolute; left: 8px; right: 18px; top: 22px; height: 30px; background: rgba(111, 75, 34, 0.12); border-radius: 2px; }
.pages i:nth-child(1) { --n: 0; } .pages i:nth-child(2) { --n: 1; } .pages i:nth-child(3) { --n: 2; } .pages i:nth-child(4) { --n: 3; }
.pages i:nth-child(5) { --n: 4; } .pages i:nth-child(6) { --n: 5; } .pages i:nth-child(7) { --n: 6; }
.slide.is-active .pages i { opacity: 1; transition-delay: calc(0.25s + var(--n) * 60ms); }
.chip {
  position: absolute; right: var(--s-300); bottom: var(--s-300);
  display: inline-flex; align-items: center; gap: var(--s-75);
  padding: var(--s-50) var(--s-100); border-radius: var(--r-full);
  background: var(--brown); color: var(--cream); font-size: 0.75rem; line-height: 1rem; font-weight: 600;
  opacity: 0; transform: translateY(8px); transition: opacity 0.6s var(--ease) 0.9s, transform 0.6s var(--ease) 0.9s;
}
.slide.is-active .chip { opacity: 1; transform: none; }
.pipe { margin-top: var(--s-200); display: flex; flex-direction: column; gap: var(--s-100); }
.pipe li { display: flex; align-items: center; gap: var(--s-100); font-size: 0.875rem; line-height: 1.25rem; color: var(--ink); }
.pipe li.last { font-weight: 600; }
.pipe i { width: 18px; height: 18px; border-radius: 50%; border: 1.5px solid var(--line-2); display: grid; place-items: center; transition: background-color 0.5s var(--ease), border-color 0.5s var(--ease); }
.pipe i::after { content: ""; width: 8px; height: 4px; border-left: 2px solid var(--cream); border-bottom: 2px solid var(--cream); transform: rotate(-45deg) translate(1px, -1px); opacity: 0; transition: opacity 0.3s var(--ease); }
.slide.is-active .pipe i { background: var(--brown); border-color: var(--brown); }
.slide.is-active .pipe i::after { opacity: 1; }
.slide.is-active .pipe li:nth-child(1) i, .slide.is-active .pipe li:nth-child(1) i::after { transition-delay: 0.4s; }
.slide.is-active .pipe li:nth-child(2) i, .slide.is-active .pipe li:nth-child(2) i::after { transition-delay: 0.7s; }
.slide.is-active .pipe li:nth-child(3) i, .slide.is-active .pipe li:nth-child(3) i::after { transition-delay: 1s; }
.slide.is-active .pipe li.last i { background: var(--gold); border-color: var(--gold); }
.slide.is-active .pipe li.last i::after { border-color: var(--ink); }
@media (min-width: 900px) {
  .how .pin-inner { padding-top: calc(var(--top-h) + var(--s-500)); }
  .slide-grid { grid-template-columns: 1fr 1fr; gap: var(--s-900); }
  .slide-copy h2 { font-size: 3rem; }
  .ill { padding: var(--s-500); max-width: 460px; margin-left: auto; }
  .chip { right: var(--s-500); bottom: var(--s-500); }
}
@media (max-width: 899px) {
  .slide-grid { grid-template-columns: 1fr; }
  .slide-copy h2 { font-size: 1.875rem; line-height: 2.25rem; }
  .slide-copy p { font-size: 1rem; line-height: 1.5rem; }
}

/* ---------- Photo band ---------- */
.photo-band { padding-block: var(--s-800) 0; }
.photo { position: relative; overflow: hidden; border-radius: var(--r-2xl); background: var(--cream-2); border: 1px solid var(--line); }
.photo-wide { aspect-ratio: 16 / 9; }
.photo img, .photo-ph {
  position: absolute; inset: -8% 0; width: 100%; height: 116%; object-fit: cover;
  transform: translateY(calc((var(--p, 0.5) - 0.5) * -72px));
}
.photo-ph { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: var(--s-75); color: var(--muted); }
.photo-ph .dots i { width: 6px; height: 6px; background: var(--brown); opacity: 0.5; }
.ph-label { font-size: 0.75rem; line-height: 1rem; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; }
.ph-caption { font-size: 0.875rem; line-height: 1.25rem; }
@media (min-width: 900px) { .photo-band { padding-top: var(--s-900); } }

/* ---------- Who does what ---------- */
.split { padding-block: var(--s-800); }
.split-grid { display: grid; gap: var(--s-300); }
.panel { position: relative; border-radius: var(--r-2xl); background: var(--brown); color: var(--cream); padding: var(--s-500) var(--s-400); }
.panel h2 { color: var(--cream); font-size: 1.875rem; line-height: 2.25rem; margin-top: var(--s-300); }
.panel ul { margin-top: var(--s-300); display: flex; flex-direction: column; }
.panel li { padding: var(--s-200) 0; border-top: 1px solid rgba(253, 247, 236, 0.18); font-size: 1.125rem; line-height: 1.75rem; color: rgba(253, 247, 236, 0.9); }
.panel p { margin-top: var(--s-200); font-size: 1.125rem; line-height: 1.75rem; color: rgba(253, 247, 236, 0.85); }
@media (min-width: 900px) {
  .split { padding-block: var(--s-900); }
  .split-grid { grid-template-columns: 1fr 1fr; gap: var(--s-400); }
  .panel { padding: var(--s-700) var(--s-600); }
}

/* ---------- 03 Your rules ---------- */
.rules { padding-block: var(--s-800); }
.rules-grid { display: grid; gap: var(--s-600); align-items: center; }
.rules-copy > p:not(.chapter):not(.rules-summary) { margin-top: var(--s-200); font-size: 1.125rem; line-height: 1.75rem; max-width: 440px; }
.rules-summary { margin-top: var(--s-400); font-size: 1rem; line-height: 1.5rem; color: var(--muted); max-width: 440px; }
.rules-summary strong { color: var(--brown); display: inline-block; transition: transform 0.5s var(--ease); }
.rules-summary strong.tick { transform: translateY(-3px); }
.rules-demo { background: var(--white); border: 1px solid var(--line); border-radius: var(--r-2xl); padding: var(--s-300); box-shadow: var(--shadow); }
.rule-row { display: flex; flex-direction: column; gap: var(--s-100); padding: var(--s-200) 0; border-bottom: 1px solid var(--line); }
.rule-row:first-child { padding-top: var(--s-50); }
.rule-row:last-child { border-bottom: 0; padding-bottom: var(--s-50); }
.rule-name { font-weight: 600; color: var(--ink); display: flex; flex-direction: column; flex: 1; min-width: 0; }
.rule-name small { font-weight: 400; color: var(--muted); }
.rule-row[data-stance="block"] .rule-name { color: var(--muted); }
.seg { display: flex; width: 100%; padding: 3px; border-radius: var(--r-full); background: var(--cream-2); flex: none; }
.seg [role="radio"] {
  flex: 1; text-align: center; white-space: nowrap;
  padding: var(--s-50) var(--s-75); border-radius: var(--r-full);
  font-size: 0.75rem; line-height: 1rem; font-weight: 500; color: var(--muted);
  transition: background-color 0.6s var(--ease), color 0.6s var(--ease), transform 0.4s var(--ease);
}
.seg [role="radio"]:hover { color: var(--brown); }
.seg [role="radio"]:active { transform: scale(0.97); }
.seg [role="radio"][aria-checked="true"] { color: var(--cream); background: var(--brown); }
.seg [role="radio"][aria-checked="true"][data-stance="review"] { color: var(--ink); background: var(--gold); }
.seg [role="radio"][aria-checked="true"][data-stance="block"] { background: var(--ink); }
@media (min-width: 900px) {
  .rules { padding-block: var(--s-900); }
  .rules-grid { grid-template-columns: 1fr 1fr; gap: var(--s-900); }
  .rule-row { flex-direction: row; align-items: center; justify-content: space-between; gap: var(--s-300); }
  .seg { display: inline-flex; width: auto; }
  .seg [role="radio"] { flex: none; padding: var(--s-50) var(--s-100); font-size: 0.875rem; line-height: 1.25rem; }
  .rules-demo { padding: var(--s-400); }
}

/* ---------- 04 Getting paid: words light up ---------- */
.money { --pin: 3; background: var(--cream-2); }
.money-inner { padding-top: var(--top-h); }
.money-words { display: flex; flex-direction: column; gap: var(--s-50); font-size: 3rem; line-height: 1; font-weight: 600; letter-spacing: -0.03em; }
.mw { color: rgba(42, 28, 12, 0.18); transition: color 0.6s var(--ease), transform 0.6s var(--ease); transform: translateX(-8px); }
.mw.on { color: var(--ink); transform: none; }
.mw-gold.on { color: var(--brown); }
.money-sub {
  margin-top: var(--s-500); max-width: 560px; font-size: 1.125rem; line-height: 1.75rem;
  opacity: 0; transform: translateY(16px); transition: opacity 0.8s var(--ease), transform 0.8s var(--ease);
}
.money.is-done .money-sub { opacity: 1; transform: none; }
@media (min-width: 900px) {
  .money-words { flex-direction: row; flex-wrap: wrap; gap: 0 var(--s-300); font-size: 4.5rem; }
}
@media (min-width: 1200px) { .money-words { font-size: 6rem; } }

/* ---------- 05 The one condition ---------- */
.condition { padding-block: var(--s-800); }
.panel-wide { padding: var(--s-500) var(--s-400); }
.condition-grid { display: grid; gap: var(--s-500); }
.panel-wide h2 { font-size: 1.5rem; line-height: 2rem; margin-top: 0; }
.panel-link { display: inline-flex; align-items: center; gap: var(--s-75); margin-top: var(--s-500); font-weight: 600; color: var(--gold); }
.panel-link .icon { transition: transform 0.6s var(--ease); }
.panel-link:hover .icon { transform: translate(2px, -2px); }
@media (min-width: 900px) {
  .condition { padding-block: var(--s-900); }
  .panel-wide { padding: var(--s-800) var(--s-800); }
  .condition-grid { grid-template-columns: 1fr 1fr; gap: var(--s-800); }
  .panel-wide h2 { font-size: 1.875rem; line-height: 2.25rem; }
}

/* ---------- For advertisers ---------- */
.adv { padding-block: var(--s-800); border-top: 1px solid var(--line); }
.adv-inner > * { max-width: 680px; }
.adv-inner > p:not(.chapter) { margin-top: var(--s-200); font-size: 1.125rem; line-height: 1.75rem; }
.adv-inner .link-arrow { margin-top: var(--s-300); }
@media (min-width: 900px) { .adv { padding-block: var(--s-900); } }

/* ---------- Questions ---------- */
.faq { padding-block: var(--s-800); border-top: 1px solid var(--line); }
.faq-grid { display: grid; gap: var(--s-500); align-items: start; }
.faq-head p:not(.chapter) { margin-top: var(--s-200); color: var(--muted); }
.faq-head a { color: var(--brown); font-weight: 500; }
.faq-list { border-top: 1px solid var(--line); }
.faq-item { border-bottom: 1px solid var(--line); }
.faq-item h3 { font-size: 1rem; line-height: 1.5rem; }
.faq-q {
  width: 100%; display: flex; justify-content: space-between; align-items: center; gap: var(--s-300);
  padding: var(--s-300) 0; text-align: left;
  font-size: 1.125rem; line-height: 1.75rem; font-weight: 600; color: var(--ink);
  transition: color 0.6s var(--ease);
}
.faq-q:hover { color: var(--brown); }
.faq-icon { position: relative; width: 20px; height: 20px; flex: none; }
.faq-icon::before, .faq-icon::after { content: ""; position: absolute; left: 50%; top: 50%; width: 14px; height: 1.5px; background: var(--brown); border-radius: 2px; transform: translate(-50%, -50%); transition: transform 0.7s var(--ease); }
.faq-icon::after { transform: translate(-50%, -50%) rotate(90deg); }
.faq-q[aria-expanded="true"] .faq-icon::after { transform: translate(-50%, -50%) rotate(0deg); }
.faq-q[aria-expanded="true"] .faq-icon::before { transform: translate(-50%, -50%) rotate(180deg); }
.faq-a { display: grid; grid-template-rows: 0fr; transition: grid-template-rows 0.7s var(--ease); }
.faq-a > div { overflow: hidden; }
.faq-a p { padding-bottom: var(--s-300); font-size: 1.125rem; line-height: 1.75rem; max-width: 620px; }
.faq-item.is-open .faq-a { grid-template-rows: 1fr; }
@media (min-width: 900px) { .faq { padding-block: var(--s-900); } .faq-grid { grid-template-columns: 0.8fr 1.2fr; gap: var(--s-900); } }

/* ---------- Begin ---------- */
.cta { padding-block: var(--s-800); }
.cta-panel { position: relative; background: var(--brown); color: var(--cream); border-radius: var(--r-2xl); padding: var(--s-700) var(--s-300); text-align: center; overflow: hidden; }
.cta-panel::before { content: ""; position: absolute; inset: var(--s-200); border: 2px solid var(--gold); border-radius: var(--r-xl); pointer-events: none; }
.cta-yi { font-family: var(--font-he); font-weight: 700; font-size: 1.5rem; line-height: 2rem; color: var(--gold); margin-top: var(--s-300); }
.cta-panel h2 { color: var(--cream); margin: var(--s-200) auto 0; max-width: 620px; }
.cta-panel p:not(.cta-yi) { margin: var(--s-300) auto 0; max-width: 520px; font-size: 1.125rem; line-height: 1.75rem; color: rgba(253, 247, 236, 0.85); }
.cta-panel .btn { margin-top: var(--s-500); }
@media (min-width: 900px) { .cta { padding-block: var(--s-900); } .cta-panel { padding: var(--s-900) var(--s-800); } .cta-yi { font-size: 2.25rem; line-height: 2.5rem; } }

/* ---------- Footer ---------- */
.footer { padding: var(--s-700) 0 var(--s-500); border-top: 1px solid var(--line); }
.footer-inner { display: flex; flex-direction: column; gap: var(--s-500); }
.footer-brand img { width: 96px; height: auto; }
.footer-brand p { margin-top: var(--s-200); color: var(--muted); max-width: 300px; }
.footer-links { display: flex; flex-wrap: wrap; gap: var(--s-100) var(--s-300); }
.footer-links a { font-size: 0.875rem; line-height: 1.25rem; font-weight: 500; color: var(--ink-2); transition: color 0.5s var(--ease); }
.footer-links a:hover { color: var(--brown); }
.footer-base { display: flex; flex-wrap: wrap; justify-content: space-between; gap: var(--s-200); margin-top: var(--s-600); padding-top: var(--s-300); border-top: 1px solid var(--line); font-size: 0.875rem; line-height: 1.25rem; color: var(--muted); }
.footer-base [lang="yi"] { font-family: var(--font-he); font-weight: 500; }
@media (min-width: 900px) { .footer-inner { flex-direction: row; justify-content: space-between; align-items: flex-end; } }

/* ---------- Simple pages (404, privacy) ---------- */
.simple { min-height: 100vh; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: var(--s-900) var(--s-300); }
.simple img { width: 140px; height: auto; margin-bottom: var(--s-500); }
.simple h1 { font-size: 2.25rem; line-height: 2.5rem; }
.simple p { margin-top: var(--s-200); font-size: 1.125rem; line-height: 1.75rem; max-width: 520px; }
.simple .btn { margin-top: var(--s-400); }
.simple-yi { font-family: var(--font-he); font-weight: 700; color: var(--brown); font-size: 1.5rem; line-height: 2rem; margin-bottom: var(--s-200); }
.doc { max-width: 720px; margin: 0 auto; padding: calc(var(--top-h) + var(--s-800)) var(--s-300) var(--s-900); }
.doc h1 { font-size: 2.25rem; line-height: 2.5rem; }
.doc h2 { font-size: 1.5rem; line-height: 2rem; margin-top: var(--s-600); }
.doc p, .doc li { margin-top: var(--s-200); font-size: 1.125rem; line-height: 1.75rem; }
.doc ul { list-style: disc; padding-left: var(--s-300); }
.doc .meta { font-size: 0.875rem; line-height: 1.25rem; color: var(--muted); margin-top: var(--s-75); }
.doc a { color: var(--brown); text-decoration: underline; text-underline-offset: 3px; }
.doc .back { display: inline-flex; align-items: center; gap: var(--s-75); margin-bottom: var(--s-500); text-decoration: none; font-weight: 600; }

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: 0.01ms !important; animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; }
  [data-reveal] { opacity: 1; transform: none; filter: none; }
  .tagline-text .w { color: var(--ink); }
  .scene { --bp: 1 !important; }
  .photo img, .photo-ph { transform: none !important; }
}
