/* Paperlight website. Lots of air; the only colour is the warm light (spec 10.1). Motion is springs and
   scroll, and only transform and opacity move (CLAUDE.md "Chuyển động"). */

:root {
  --bg: #FAFAF8;
  --bg-2: #F2F1EE;
  --surface: #FFFFFF;
  --ink: #111113;
  --muted: #6E6E73;
  --line: #E4E4E7;
  --chip: #EFEFF1;
  --btn: #111113;
  --btn-ink: #FFFFFF;
  --warm-ink: #B85F1A;
  --warm: 255, 196, 128;
  --hl: rgba(255, 196, 128, .55);
  --night: #0B1030;
  --shadow: 0 1px 1px rgba(0,0,0,.03), 0 8px 28px rgba(0,0,0,.06);
  --nav-glass: rgba(250,250,248,.72);
  --font: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Be Vietnam Pro", "Segoe UI", system-ui, sans-serif;
  --font-display: -apple-system, BlinkMacSystemFont, "SF Pro Display", "Be Vietnam Pro", "Segoe UI", system-ui, sans-serif;
  --spring: cubic-bezier(.2, 1.15, .32, 1);
  --soft: cubic-bezier(.2, .9, .25, 1);
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0A0A0C; --bg-2: #111114; --surface: #161618; --ink: #F5F5F7; --muted: #98989D; --line: #2A2A2E; --chip: #1F1F22;
    --btn: #F5F5F7; --btn-ink: #0A0A0C; --warm-ink: #FFB36B; --hl: rgba(255, 170, 90, .38); --shadow: 0 0 0 1px rgba(255,255,255,.06);
    --nav-glass: rgba(16,16,20,.66);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0A0A0C; --bg-2: #111114; --surface: #161618; --ink: #F5F5F7; --muted: #98989D; --line: #2A2A2E; --chip: #1F1F22;
  --btn: #F5F5F7; --btn-ink: #0A0A0C; --warm-ink: #FFB36B; --hl: rgba(255, 170, 90, .38); --shadow: 0 0 0 1px rgba(255,255,255,.06);
  --nav-glass: rgba(16,16,20,.66);
  color-scheme: dark;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 84px; }
body {
  margin: 0; background: var(--bg); color: var(--ink); font-family: var(--font); font-size: 16px; line-height: 1.55;
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; overflow-x: clip;
}
a { color: inherit; }
img { display: block; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- buttons ---------- */
.btn {
  appearance: none; border: 0; display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 44px; padding: 0 22px; border-radius: 999px; font: 600 15px/1 var(--font); text-decoration: none; cursor: pointer;
  transition: transform .35s var(--spring), background-color .2s, opacity .2s, box-shadow .3s;
}
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: scale(.97); transition-duration: .1s; }
.btn:focus-visible, .nav a:focus-visible, .foot a:focus-visible, summary:focus-visible, .lang button:focus-visible, .chip-new:focus-visible, .link-arrow:focus-visible { outline: 2px solid rgb(var(--warm)); outline-offset: 3px; }
.btn-dark { background: var(--btn); color: var(--btn-ink); }
.btn-dark:hover { box-shadow: 0 10px 30px -10px rgba(var(--warm), .9); }
.btn-light { background: #F5F5F7; color: #0A0A0C; }
.btn-light:hover { box-shadow: 0 10px 40px -8px rgba(var(--warm), .9); }
.btn-quiet { background: var(--chip); color: var(--ink); }
.btn-quiet:hover { background: var(--line); }
.btn-sm { min-height: 34px; padding: 0 14px; font-size: 14px; gap: 6px; }
.btn-lg { min-height: 50px; padding: 0 26px; font-size: 16px; }
.btn-block { width: 100%; }
.btn-key { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 1px var(--line); padding: 0 8px 0 18px; }
.btn-key:hover { background: var(--chip); }
.apple { width: 14px; height: 17px; fill: currentColor; margin-top: -2px; }
.btn-sm .apple { width: 12px; height: 15px; }
kbd {
  display: inline-grid; place-items: center; min-width: 24px; height: 24px; padding: 0 6px; border-radius: 6px;
  font: 600 12px/1 var(--font); color: var(--muted); background: var(--chip); box-shadow: inset 0 -1px 0 var(--line);
}
.btn-key kbd + kbd { margin-left: -4px; }
.tag { font: 600 11px/1 var(--font); font-style: normal; color: var(--warm-ink); padding: 3px 6px; border-radius: 5px; background: rgba(var(--warm), .22); vertical-align: 2px; margin-left: 4px; letter-spacing: 0; }

/* ---------- intro: one lantern lights, then the page opens ---------- */
.intro { display: none; }
.intro-on .intro {
  position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; background: #07081A; color: #F5F5F7;
  cursor: pointer; transition: opacity .6s ease .1s, visibility 0s .7s;
}
.intro.out { opacity: 0; visibility: hidden; }
.intro-wire { position: absolute; left: 0; top: 18vh; width: 100%; height: 120px; overflow: visible; }
.intro-wire path { fill: none; stroke: rgba(255,255,255,.42); stroke-width: 1.2; vector-effect: non-scaling-stroke; stroke-dasharray: 1; stroke-dashoffset: 1; animation: draw .9s var(--soft) .1s forwards; }
@keyframes draw { to { stroke-dashoffset: 0; } }
.intro-lantern { position: absolute; left: 50%; top: calc(18vh + 50px); width: 132px; margin-left: -66px; display: flex; flex-direction: column; align-items: center; transform-origin: 50% 0; opacity: 0; }
.intro-thread { width: 1px; height: 40px; background: rgba(255,255,255,.4); }
.intro-lantern .hook { width: 16px; height: 5px; border-radius: 3px; margin-bottom: -2.5px; position: relative; z-index: 3; background: rgba(255,255,255,.8); }
.intro-body { position: relative; width: 100%; }
.intro-body .card { --glass: rgba(70,64,96,.55); --glass-edge: rgba(255,255,255,.45); }
.intro-body .photo { object-fit: cover; }
.intro-body .glow { opacity: 0; }
.intro-word { position: absolute; top: calc(18vh + 260px); margin: 0; font: 700 28px/1 var(--font-display); letter-spacing: -.03em; opacity: 0; transform: translateY(10px); transition: opacity .6s, transform .8s var(--soft); }
.intro.lit .intro-word { opacity: .92; transform: none; }

.progress { position: fixed; left: 0; top: 0; z-index: 60; height: 2px; width: 100%; transform-origin: 0 50%; transform: scaleX(0); background: linear-gradient(90deg, rgba(var(--warm), 0), rgb(var(--warm))); pointer-events: none; }

/* ---------- nav: a pill that tightens and turns to glass on scroll ---------- */
.nav { position: fixed; z-index: 50; top: 12px; left: 0; right: 0; display: flex; justify-content: center; padding-inline: 16px; pointer-events: none; }
.nav-pill {
  pointer-events: auto; width: min(1080px, 100%); display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 8px 8px 8px 14px; border-radius: 999px; transition: width .6s var(--soft), background-color .4s, box-shadow .4s, transform .5s var(--soft);
}
.nav.scrolled .nav-pill {
  width: min(720px, 100%); background: var(--nav-glass); box-shadow: 0 0 0 .5px var(--line), 0 8px 30px rgba(0,0,0,.08);
  backdrop-filter: blur(20px) saturate(180%); -webkit-backdrop-filter: blur(20px) saturate(180%);
}
.nav.hidden .nav-pill { transform: translateY(-80px); }
.brand { display: inline-flex; align-items: center; gap: 9px; text-decoration: none; font: 600 16px/1 var(--font-display); letter-spacing: -.01em; }
.brand img { border-radius: 7px; }
.nav-links { display: flex; align-items: center; gap: 22px; font-size: 14px; }
.nav-links a { color: var(--muted); text-decoration: none; transition: color .2s; }
.nav-links a:hover { color: var(--ink); }
.nav-end { display: flex; align-items: center; gap: 10px; }
.nav .lang { margin-left: 0; border-radius: 999px; }
.nav .lang button { border-radius: 999px; padding: 6px 10px; }

/* ---------- layout ---------- */
main { max-width: 1160px; margin: 0 auto; padding: 0 20px; }
section { padding-block: clamp(64px, 10vw, 128px); }
h1, h2, h3 { font-family: var(--font-display); margin: 0; text-wrap: balance; }
h2 { font-size: clamp(30px, 4.6vw, 52px); font-weight: 700; letter-spacing: -.035em; line-height: 1.06; }
.sec-head { text-align: center; display: grid; justify-items: center; gap: 14px; margin-bottom: clamp(36px, 5vw, 56px); }
.eyebrow { margin: 0; font: 600 14px/1.2 var(--font); color: var(--warm-ink); letter-spacing: .01em; }
.sub { max-width: 52ch; margin: 0 auto; text-align: center; color: var(--muted); font-size: 17px; }
.fine { margin: 0; font-size: 13px; color: var(--muted); }
mark.hl {
  color: inherit; padding: 0 .06em; border-radius: .12em;
  background: linear-gradient(transparent 60%, var(--hl) 60%, var(--hl) 92%, transparent 92%) no-repeat 0 0 / 0% 100%;
  transition: background-size 1.1s var(--soft) .35s;
}
.in mark.hl, mark.hl.in, .no-js mark.hl, html:not(.js) mark.hl { background-size: 100% 100%; }

/* loops only tick while their section is on screen */
.js [data-anim]:not(.live), .js [data-anim]:not(.live) *, .js [data-anim]:not(.live) *::before, .js [data-anim]:not(.live) *::after { animation-play-state: paused !important; }

/* reveal on scroll */
.js [data-reveal] { opacity: 0; transform: translateY(26px); transition: opacity .8s ease, transform 1s var(--soft); transition-delay: var(--d, 0s); }
.js [data-reveal].in { opacity: 1; transform: none; }

/* ---------- hero ---------- */
.hero {
  position: relative; min-height: min(92svh, 860px); padding-block: 132px 72px; text-align: center;
  display: grid; justify-items: center; align-content: center; gap: 22px;
}
.hero > :not(.hero-lanterns):not(.scroll-cue) { position: relative; z-index: 2; }
.hero h1 { font-size: clamp(42px, 8.4vw, 96px); font-weight: 800; line-height: .98; letter-spacing: -.05em; max-width: 12.5em; }
.hero h1 .w { display: inline-block; white-space: pre; }
.js .hero h1 .w { opacity: 0; transform: translateY(.42em) rotate(2deg); animation: rise 1s var(--soft) both; animation-delay: calc(var(--i) * 55ms + .08s); }
.intro-hold .hero h1 .w { animation-play-state: paused; }
.hero h1.static .w { animation: none !important; opacity: 1 !important; transform: none !important; }
@keyframes rise { to { opacity: 1; transform: none; } }
.glowword { position: relative; font-style: normal; color: var(--warm-ink); text-shadow: 0 0 .3em rgba(var(--warm), .3); }
.glowword::before { content: ""; position: absolute; inset: -.1em -.35em; z-index: -1; border-radius: 50%; background: radial-gradient(closest-side, rgba(var(--warm), .42), rgba(var(--warm), 0)); opacity: .25; animation: glowpulse 4.5s ease-in-out 1.4s infinite; }
@keyframes glowpulse { 50% { opacity: 1; } }
.lede { margin: 0; max-width: 44ch; font-size: clamp(17px, 2vw, 20px); color: var(--muted); text-wrap: pretty; }
.cta { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin-top: 6px; }
.chip-new {
  display: inline-flex; align-items: center; gap: 8px; padding: 7px 14px 7px 10px; border-radius: 999px; text-decoration: none;
  font: 500 13.5px/1 var(--font); color: var(--ink); background: var(--surface); box-shadow: 0 0 0 .5px var(--line), 0 4px 14px rgba(0,0,0,.05);
  transition: transform .35s var(--spring), box-shadow .3s;
}
.chip-new:hover { transform: translateY(-1px); box-shadow: 0 0 0 .5px var(--line), 0 8px 24px -6px rgba(var(--warm), .8); }
.chip-dot { width: 8px; height: 8px; border-radius: 50%; background: rgb(var(--warm)); box-shadow: 0 0 10px rgb(var(--warm)); animation: breathe 1.7s ease-in-out infinite; }
.scroll-cue { position: absolute; left: 50%; bottom: 18px; width: 22px; height: 34px; margin-left: -11px; border-radius: 12px; box-shadow: inset 0 0 0 1.5px var(--line); }
.scroll-cue span { position: absolute; left: 50%; top: 7px; width: 3px; height: 7px; margin-left: -1.5px; border-radius: 2px; background: var(--muted); animation: cue 1.8s var(--soft) infinite; }
@keyframes cue { 0% { opacity: 0; transform: translateY(-3px); } 30% { opacity: 1; } 80%, 100% { opacity: 0; transform: translateY(10px); } }

/* hanging lanterns at the sides of the hero */
.hero-lanterns { position: absolute; inset: 0 calc(50% - 50vw); z-index: 1; pointer-events: none; overflow: hidden; }
.hl-lantern { position: absolute; top: 0; width: var(--lw); display: flex; flex-direction: column; align-items: center; transform-origin: 50% 0; will-change: transform; pointer-events: auto;
  --thread: rgba(120,120,130,.45); --glass: rgba(255,255,255,.55); --glass-edge: rgba(255,255,255,.9); }
.hl-lantern .long { width: 1px; background: var(--thread); }
.hl-lantern .hook { width: 16px; height: 5px; border-radius: 3px; margin-bottom: -2.5px; position: relative; z-index: 3; background: #FFF; box-shadow: 0 0 0 .5px rgba(0,0,0,.2), 0 1px 2px rgba(0,0,0,.2); }
.hl-lantern .body { cursor: default; }
.hl-lantern .glow { opacity: .55; }
.hl-in { opacity: 0; animation: hangin 1.2s var(--soft) both; animation-delay: var(--delay, 0s); }
@keyframes hangin { from { opacity: 0; transform: translateY(-60px); } to { opacity: 1; transform: none; } }
.intro-hold .hl-in { animation-play-state: paused; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .hl-lantern { --thread: rgba(255,255,255,.3); --glass: rgba(70,64,96,.55); --glass-edge: rgba(255,255,255,.45); } }
:root[data-theme="dark"] .hl-lantern { --thread: rgba(255,255,255,.3); --glass: rgba(70,64,96,.55); --glass-edge: rgba(255,255,255,.45); }

/* ---------- scroll story: a MacBook whose desktop tidies itself as you scroll ---------- */
.story { padding: 0; margin-inline: calc(50% - 50vw); }
.story-track { position: relative; height: 560vh; }
.story-sticky {
  position: sticky; top: 0; height: 100vh; height: 100svh; display: grid; grid-template-rows: 1fr auto auto; justify-items: center; align-items: end;
  padding: 84px 0 28px; gap: 18px; perspective: 1800px;
}
.device { width: min(1100px, 94vw, calc((100svh - 250px) * 1.52)); transform-origin: 50% 80%; will-change: transform; align-self: center; }
.bezel { position: relative; padding: 1.6% 1.6% 1.2%; border-radius: 3.2% / 4.9%; background: #0C0C0F; box-shadow: inset 0 0 0 1.5px #2A2A30, 0 50px 90px -40px rgba(20,16,50,.55); }
.screen { position: relative; aspect-ratio: 16 / 10; border-radius: 1.4% / 2.2%; overflow: hidden; background: var(--night); isolation: isolate; }
.notch { position: absolute; left: 50%; top: 1.6%; width: 13%; height: 3.2%; transform: translateX(-50%); border-radius: 0 0 10px 10px; background: #0C0C0F; z-index: 5; }
.base { position: relative; height: clamp(10px, 1.9vw, 20px); margin: 0 -6.5%; border-radius: 0 0 22px 22px / 0 0 100% 100%; background: linear-gradient(#D9DADF, #A9ABB2 70%, #7D7F86); box-shadow: 0 18px 30px -18px rgba(0,0,0,.5); }
.base span { position: absolute; left: 50%; top: 0; width: 14%; height: 45%; transform: translateX(-50%); border-radius: 0 0 8px 8px; background: linear-gradient(#B8BAC1, #CFD0D5); }

.vp { position: absolute; left: 0; top: 0; width: 1280px; height: 800px; transform-origin: 0 0; transform: scale(var(--s, .5)); color: #F5F5F7;
  --thread: rgba(255,255,255,.38); --glass: rgba(70,64,96,.55); --glass-edge: rgba(255,255,255,.45); --hud: rgba(30,30,34,.82);
  background:
    radial-gradient(60% 70% at 18% 30%, #3B2B6B 0%, rgba(0,0,0,0) 70%),
    radial-gradient(55% 65% at 85% 85%, #7A3E6E 0%, rgba(0,0,0,0) 70%),
    radial-gradient(70% 60% at 70% 10%, #12204A 0%, rgba(0,0,0,0) 70%),
    #0B1030; }
.s-menubar { position: absolute; inset: 0 0 auto 0; height: 28px; z-index: 30; display: flex; align-items: center; gap: 18px; padding-inline: 18px; font: 500 14px/1 var(--font); background: rgba(28,28,36,.55); }
.s-menubar b { font-weight: 700; }
.s-apple { width: 13px; height: 13px; border-radius: 50%; background: currentColor; opacity: .9; }
.s-right { margin-left: auto; display: flex; align-items: center; gap: 14px; }
.s-strip { position: absolute; left: 0; right: 0; top: 28px; height: 150px; z-index: 10; will-change: transform; }
.s-wire { position: absolute; left: 0; top: 0; width: 100%; height: 40px; overflow: visible; }
.s-wire path { fill: none; }
.s-wire-line { stroke: rgba(255,255,255,.42); stroke-width: 1; }
.s-items { position: absolute; inset: 0; z-index: 12; }
.si { position: absolute; left: 0; top: 0; width: 112px; will-change: transform; }
.si .rig { position: absolute; left: 50%; bottom: 100%; display: flex; flex-direction: column; align-items: center; transform: translateX(-50%); opacity: 0; }
.si .rig i:first-child { width: 1px; height: 9px; background: var(--thread); }
.si .rig .hook { width: 16px; height: 5px; border-radius: 3px; margin-bottom: -2.5px; background: rgba(255,255,255,.75); box-shadow: 0 0 0 .5px rgba(0,0,0,.25); }
.si.pinned .rig .hook { background: rgb(var(--warm)); box-shadow: 0 0 8px rgba(var(--warm), .8); }
.si .body { cursor: default; }
.si .card { transition: none; }
.si .glass { position: absolute; inset: 0; border-radius: 14px; background: linear-gradient(180deg, rgba(255,255,255,.16), rgba(255,255,255,0) 60%), var(--glass); box-shadow: inset 0 0 0 .5px var(--glass-edge), inset 0 1px 0 rgba(255,255,255,.35), 0 10px 24px rgba(0,0,0,.26); }
.si .card { background: none; box-shadow: none; }
.si .label { position: absolute; left: 50%; top: calc(100% + 6px); width: 200px; margin-left: -100px; text-align: center; font: 600 13.5px/1.3 var(--font); color: #FFF; text-shadow: 0 1px 2px rgba(0,0,0,.6); }
.si .label b { display: inline; padding: 1px 4px; border-radius: 4px; font-weight: 600; white-space: nowrap; }
.si .badge-pin { display: grid; opacity: 0; }
.s-chat { position: absolute; left: 0; top: 250px; width: 430px; height: 400px; z-index: 8; border-radius: 14px; overflow: hidden; background: rgba(246,246,248,.98); color: #1D1D1F;
  box-shadow: 0 30px 70px rgba(0,0,0,.4), 0 0 0 .5px rgba(0,0,0,.5); will-change: transform; }
.s-chat .bar { height: 34px; display: flex; align-items: center; gap: 8px; padding-inline: 14px; background: rgba(232,232,237,.98); font: 600 13.5px/1 var(--font); }
.s-chat .bar span { flex: 1; text-align: center; margin-right: 56px; opacity: .65; }
.s-chat .msgs { padding: 16px; display: grid; gap: 9px; font: 400 15px/1.35 var(--font); }
.msg-img { justify-self: end; width: 190px; aspect-ratio: 128 / 99; border-radius: 16px; overflow: hidden; opacity: 0; transform-origin: 100% 0; }
.msg-img img { width: 100%; height: 100%; object-fit: cover; }
.s-ghost { position: absolute; left: 0; top: 0; width: 112px; z-index: 40; opacity: 0; will-change: transform, opacity; }
.s-ghost .card { box-shadow: inset 0 0 0 .5px var(--glass-edge), 0 18px 40px rgba(0,0,0,.45); }
.s-hud { position: absolute; left: 0; top: 0; z-index: 41; padding: 6px 11px; border-radius: 999px; font: 600 13px/1 var(--font); color: #F5F5F7; background: var(--hud); white-space: nowrap; opacity: 0; box-shadow: 0 4px 14px rgba(0,0,0,.3); }
.s-cursor { position: absolute; left: 0; top: 0; z-index: 42; opacity: 0; filter: drop-shadow(0 2px 3px rgba(0,0,0,.35)); }

.story-captions { position: relative; width: min(680px, 92vw); height: 104px; text-align: center; }
.cap { position: absolute; inset: 0; display: grid; align-content: start; gap: 6px; opacity: 0; transform: translateY(-8px); transition: opacity .18s ease, transform .3s ease; pointer-events: none; }
.cap.on { opacity: 1; transform: none; transition: opacity .45s ease .16s, transform .8s var(--soft) .16s; }
.cap:not(.on) { transform: translateY(-8px); }
.cap.on ~ .cap:not(.on) { transform: translateY(14px); }
.cap h3 { font-size: clamp(22px, 3vw, 32px); font-weight: 700; letter-spacing: -.03em; line-height: 1.1; }
.cap p { margin: 0; color: var(--muted); font-size: clamp(15px, 1.7vw, 17px); }
.story-dots { display: flex; gap: 6px; padding: 7px 9px; border-radius: 999px; background: var(--chip); }
.story-dots i { width: 6px; height: 6px; border-radius: 3px; background: var(--muted); opacity: .4; transition: width .5s var(--spring), opacity .3s, background-color .3s; }
.story-dots i.on { width: 22px; opacity: 1; background: var(--ink); }

/* ---------- demo stage: a depicted macOS desktop, same in both page themes ---------- */
.demo { padding-block: clamp(72px, 10vw, 120px) clamp(40px, 7vw, 80px); }
.stage {
  --mb: 26px;
  --thread: rgba(255,255,255,.38);
  --glass: rgba(70, 64, 96, .55);
  --glass-edge: rgba(255,255,255,.45);
  --hud: rgba(30,30,34,.82);
  position: relative; height: clamp(400px, 56vw, 620px); border-radius: 20px; overflow: hidden; isolation: isolate;
  user-select: none; -webkit-user-select: none; color: #F5F5F7;
  background:
    radial-gradient(60% 70% at 18% 30%, #3B2B6B 0%, rgba(0,0,0,0) 70%),
    radial-gradient(55% 65% at 85% 85%, #7A3E6E 0%, rgba(0,0,0,0) 70%),
    radial-gradient(70% 60% at 70% 10%, #12204A 0%, rgba(0,0,0,0) 70%),
    #0B1030;
  box-shadow: 0 40px 80px -30px rgba(20,16,50,.45), 0 0 0 1px rgba(0,0,0,.06);
}
.menubar {
  position: absolute; inset: 0 0 auto 0; height: var(--mb); z-index: 40; display: flex; align-items: center; gap: 16px; padding-inline: 14px;
  font: 500 13px/1 var(--font); background: rgba(28,28,36,.62);
}
.mb-left { display: flex; align-items: center; gap: 18px; min-width: 0; overflow: hidden; white-space: nowrap; }
.mb-left b { font-weight: 700; }
.mb-apple { flex: none; opacity: .92; }
.mb-right { margin-left: auto; display: flex; align-items: center; gap: 10px; white-space: nowrap; }
.mb-glyph { appearance: none; border: 0; background: transparent; color: inherit; height: 22px; padding: 0 7px; border-radius: 5px; display: grid; place-items: center; cursor: pointer; }
.mb-glyph:hover, .mb-glyph[aria-expanded="true"], .mb-glyph:focus-visible { background: rgba(255,255,255,.18); outline: none; }
.clock { font-variant-numeric: tabular-nums; }

.win {
  position: absolute; z-index: 5; border-radius: 12px; overflow: hidden;
  box-shadow: 0 22px 60px rgba(0,0,0,.38), 0 0 0 .5px rgba(0,0,0,.5), inset 0 0 0 .5px rgba(255,255,255,.18);
}
.win .bar { height: 28px; display: flex; align-items: center; gap: 7px; padding-inline: 12px; font: 600 12px/1 var(--font); }
.win .bar span { flex: 1; text-align: center; margin-right: 46px; opacity: .65; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tl { width: 11px; height: 11px; border-radius: 50%; flex: none; }
.tl.r { background: #FF5F57; } .tl.y { background: #FEBC2E; } .tl.g { background: #28C840; }
.win-code { left: 5%; top: 40%; width: 54%; height: 52%; background: rgba(30,32,44,.97); }
.win-code .bar { background: rgba(40,43,58,.97); color: #C9CEDD; }
.code { padding: 14px 16px; display: grid; gap: 10px; }
.cl { display: flex; gap: 6px; align-items: center; height: 7px; }
.cl i { display: block; height: 7px; border-radius: 4px; }
.win-chat { right: 5%; top: 34%; width: 33%; height: 50%; background: rgba(246,246,248,.98); color: #1D1D1F; }
.win-chat .bar { background: rgba(232,232,237,.98); }
.msgs { padding: 12px; display: grid; gap: 7px; font: 400 12.5px/1.35 var(--font); }
.msg { justify-self: start; max-width: 86%; padding: 6px 10px; border-radius: 14px; background: #E9E9EB; }
.msg.me { justify-self: end; background: #0A84FF; color: #FFFFFF; }

.strip { position: absolute; left: 0; right: 0; top: var(--mb); height: 220px; z-index: 20; pointer-events: none; will-change: transform; }
.wire { position: absolute; left: 0; top: 0; width: 100%; height: 40px; overflow: visible; }
.wire path { fill: none; }
.wire-line { stroke: url(#wireFade); stroke-width: 1; }
.wire-glow { stroke: rgba(var(--warm), .22); stroke-width: 3; }
.fx { position: absolute; inset: 0; z-index: 35; pointer-events: none; overflow: hidden; }

/* ---------- lantern (spec 10.2–10.4, numbers from design/source/Card.dc.html) ---------- */
.lantern { position: absolute; left: 0; top: 0; width: var(--lw, 124px); pointer-events: auto; will-change: transform, opacity; }
.lantern.gone { opacity: 0; pointer-events: none; transition: opacity .4s .45s; }
.lantern.gone .glow, .lantern.gone .wash { opacity: 0 !important; transition: opacity .45s; }
.lantern.gone .dim { opacity: .5 !important; transition: opacity .45s; }
.lantern.gone .body { transform: scale(.86); transition: transform .4s .45s; }
.hang { display: flex; flex-direction: column; align-items: center; transform-origin: 50% 0; will-change: transform; }
.thread { width: 1px; height: 9px; background: var(--thread); }
.hook {
  width: 16px; height: 5px; border-radius: 3px; margin-bottom: -2.5px; position: relative; z-index: 3;
  background: rgba(255,255,255,.75); box-shadow: 0 0 0 .5px rgba(0,0,0,.25), 0 1px 2px rgba(0,0,0,.25);
}
.lantern.pinned .hook { background: rgb(var(--warm)); box-shadow: 0 0 0 .5px rgba(120,60,0,.4), 0 0 8px rgba(var(--warm), .8); }
.body { position: relative; width: 100%; cursor: pointer; transition: transform .35s cubic-bezier(.2,1.3,.4,1); }
.lantern:hover .body { transform: scale(1.035); }
.lantern.pressed .body { transform: scale(.965); transition-duration: .1s; }
.glow {
  position: absolute; left: 50%; top: 52%; width: 220%; aspect-ratio: 1; transform: translate(-50%, -50%); pointer-events: none; z-index: 0;
  background: radial-gradient(closest-side, rgba(var(--warm), .62) 0%, rgba(var(--warm), .2) 42%, rgba(var(--warm), 0) 100%);
  transition: opacity 1s ease-out;
}
.si .glow { will-change: opacity; }
.lantern.lit .glow { transition-duration: .12s; }
.lantern.dying .glow { animation: breathe 1.7s ease-in-out infinite; }
@keyframes breathe { 50% { opacity: .12; } }
.card {
  position: relative; z-index: 1; width: 100%; aspect-ratio: 128 / 99; padding: 6px; border-radius: 14px;
  background: linear-gradient(180deg, rgba(255,255,255,.16), rgba(255,255,255,0) 60%), var(--glass);
  box-shadow: inset 0 0 0 .5px var(--glass-edge), inset 0 1px 0 rgba(255,255,255,.35), 0 10px 24px rgba(0,0,0,.26), 0 2px 5px rgba(0,0,0,.16);
}
.wash { position: absolute; inset: 0; border-radius: inherit; background: radial-gradient(120% 90% at 50% 100%, rgba(var(--warm), .55), rgba(var(--warm), 0) 70%); transition: opacity 1s; }
.photo { position: relative; z-index: 1; display: block; width: 100%; height: 100%; border-radius: 9px; box-shadow: 0 0 0 .5px rgba(0,0,0,.3); }
.dim { position: absolute; inset: 6px; z-index: 2; border-radius: 9px; background: #0A0806; opacity: 0; pointer-events: none; transition: opacity 1s; }
.badge-time { position: absolute; z-index: 3; left: 11px; bottom: 11px; padding: 2px 5px; border-radius: 5px; font: 600 10px/1.3 var(--font); color: #FFF; background: rgba(0,0,0,.55); font-variant-numeric: tabular-nums; }
.badge-pin { position: absolute; z-index: 3; right: 10px; top: 10px; width: 17px; height: 17px; border-radius: 50%; display: none; place-items: center; background: rgba(var(--warm), .95); color: #5A2E00; box-shadow: 0 1px 3px rgba(0,0,0,.3); }
.lantern.pinned .badge-pin { display: grid; }
.hud, .tools { position: absolute; left: 50%; top: calc(100% + 8px); white-space: nowrap; }
.hud {
  transform: translate(-50%, -4px) scale(.94); padding: 5px 10px; border-radius: 999px; z-index: 4; pointer-events: none;
  font: 600 11.5px/1 var(--font); color: #F5F5F7; background: var(--hud); opacity: 0;
  transition: opacity .18s, transform .3s cubic-bezier(.2,1.3,.4,1);
}
.lantern.copied .hud { opacity: 1; transform: translate(-50%, 0) scale(1); }
.tools { transform: translateX(-50%); display: flex; gap: 4px; opacity: 0; transition: opacity .15s; pointer-events: none; }
.lantern:hover .tools { opacity: 1; pointer-events: auto; }
.lantern.copied .tools { opacity: 0; }
.tools button { appearance: none; border: 0; background: var(--hud); color: #F5F5F7; font: 600 11px/1 var(--font); padding: 5px 9px; border-radius: 999px; cursor: pointer; }
.tools button:hover { background: rgba(60,60,66,.9); }
@media (hover: none) { .tools { display: none; } }

/* capture effects */
.flyer { position: absolute; left: 0; top: 0; transform-origin: 0 0; will-change: transform, opacity; }
.flyer .card { box-shadow: inset 0 0 0 .5px var(--glass-edge), 0 6px 18px rgba(0,0,0,.3); }
.sel { position: absolute; border: 1px solid rgba(255,255,255,.95); box-shadow: 0 0 0 9999px rgba(0,0,0,.2); transition: opacity .15s; }
.flash { position: absolute; background: #FFF; transition: opacity .3s ease-out; }

.demo-bar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 20px; margin-top: 18px; }
.hint { margin: 0; font-size: 15px; color: var(--muted); transition: opacity .4s; }
.hint.done { opacity: 0; }

/* ---------- marquee ---------- */
.marquee { position: relative; padding-block: 24px; display: grid; gap: 12px; margin-inline: calc(50% - 50vw); overflow: hidden; }
.marquee::before, .marquee::after { content: ""; position: absolute; top: 0; bottom: 0; width: 12%; z-index: 1; pointer-events: none; }
.marquee::before { left: 0; background: linear-gradient(90deg, var(--bg), transparent); }
.marquee::after { right: 0; background: linear-gradient(-90deg, var(--bg), transparent); }
.mq-row { display: flex; width: max-content; animation: mq 60s linear infinite; }
.mq-rev { animation-direction: reverse; animation-duration: 70s; }
.marquee:hover .mq-row { animation-play-state: paused; }
.mq-row ul { list-style: none; margin: 0; padding: 0 6px; display: flex; gap: 12px; }
.mq-row li { padding: 11px 18px; border-radius: 999px; background: var(--surface); box-shadow: 0 0 0 .5px var(--line); font: 600 15px/1 var(--font); color: var(--muted); white-space: nowrap; transition: color .2s, box-shadow .3s; }
.mq-row li:hover { color: var(--ink); box-shadow: 0 0 0 .5px var(--line), 0 6px 22px -6px rgba(var(--warm), .9); }
@keyframes mq { to { transform: translateX(-50%); } }

/* ---------- light states ---------- */
.states { text-align: center; }
.state-row { margin: 0 auto; padding: 32px 12px 24px; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 12px; border-radius: 22px; background: #0E1028; color: #F5F5F7; max-width: 900px; overflow: hidden;
  --thread: rgba(255,255,255,.38); --glass: rgba(70,64,96,.55); --glass-edge: rgba(255,255,255,.45); --hud: rgba(30,30,34,.82); }
.state { margin: 0; display: grid; gap: 10px; justify-items: center; min-width: 0; }
.pen { position: relative; width: 100%; height: 118px; border-top: 1px solid rgba(255,255,255,.3); }
.pen { --lw: min(112px, 100%); }
.pen .lantern { left: 50%; transform: translateX(-50%); }
.pen .body { cursor: default; }
.pen .lantern:hover .body { transform: none; }
.js .state-row .lantern { opacity: 0; }
.state-row.in .lantern { animation: ignite-in .9s var(--soft) both; animation-delay: calc(var(--n) * .14s + .2s); }
.state-row.in .glow { animation: ignite 1.4s ease-out both; animation-delay: calc(var(--n) * .14s + .3s); }
.state-row.in .lantern.dying .glow { animation: ignite 1.4s ease-out both, breathe 1.7s ease-in-out 2.2s infinite; animation-delay: calc(var(--n) * .14s + .3s), 2.2s; }
@keyframes ignite-in { from { opacity: 0; transform: translate(-50%, -14px); } to { opacity: 1; transform: translateX(-50%); } }
@keyframes ignite { 0% { opacity: 0; } 25% { opacity: 1; } }
figcaption { font-size: 13px; font-weight: 500; color: rgba(245,245,247,.72); }

/* ---------- chapters ---------- */
.chapter { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.15fr); align-items: center; gap: clamp(32px, 6vw, 80px); }
.chapter.flip .ch-text { order: 2; }
.ch-text { display: grid; gap: 16px; align-content: start; }
.ch-text h2 { font-size: clamp(30px, 4vw, 46px); }
.ch-text > p:not(.eyebrow) { margin: 0; color: var(--muted); font-size: 17px; text-wrap: pretty; }
.ch-points { list-style: none; margin: 6px 0 0; padding: 0; display: grid; gap: 10px; font-size: 15px; }
.ch-points li { display: flex; align-items: center; gap: 10px; }
.ch-points kbd, .pt-ico { flex: none; min-width: 30px; }
.pt-ico { display: inline-grid; place-items: center; height: 26px; border-radius: 7px; background: rgba(var(--warm), .18); color: var(--warm-ink); font: 600 13px/1 var(--font); }
.ch-points .tag { margin-left: 0; }
.link-arrow { justify-self: start; font-weight: 600; font-size: 15px; color: var(--warm-ink); text-decoration: none; }
.link-arrow:hover { text-decoration: underline; }

/* a scripted scene, drawn at 640 × 440 and scaled to fit */
.vig { position: relative; aspect-ratio: 640 / 440; border-radius: 22px; overflow: hidden; isolation: isolate; color: #F5F5F7; user-select: none; -webkit-user-select: none;
  background:
    radial-gradient(60% 70% at 18% 30%, #3B2B6B 0%, rgba(0,0,0,0) 70%),
    radial-gradient(55% 65% at 85% 85%, #7A3E6E 0%, rgba(0,0,0,0) 70%),
    #0B1030;
  box-shadow: 0 40px 80px -36px rgba(20,16,50,.5), 0 0 0 1px rgba(0,0,0,.06);
  --thread: rgba(255,255,255,.38); --glass: rgba(70,64,96,.55); --glass-edge: rgba(255,255,255,.45); --hud: rgba(30,30,34,.86); }
.vig-light { background: radial-gradient(70% 80% at 20% 10%, #FFE9D2 0%, rgba(255,233,210,0) 70%), radial-gradient(60% 70% at 90% 90%, #D8DDF6 0%, rgba(216,221,246,0) 70%), #EEF0F6; color: #1D1D1F; }
.vig > .vp2 { position: absolute; left: 0; top: 0; width: 640px; height: 440px; transform-origin: 0 0; transform: scale(var(--s, 1)); }
.vig .mbar { position: absolute; inset: 0 0 auto 0; height: 22px; display: flex; align-items: center; gap: 14px; padding-inline: 12px; font: 500 11px/1 var(--font); background: rgba(28,28,36,.5); color: #F5F5F7; z-index: 20; }
.vig-light .mbar { background: rgba(255,255,255,.6); color: #1D1D1F; }
.vig .mbar .r { margin-left: auto; display: flex; gap: 10px; align-items: center; }
.vig .el { position: absolute; left: 0; top: 0; }
.fade { transition: opacity .35s ease; }
.vwin { position: absolute; border-radius: 12px; overflow: hidden; box-shadow: 0 22px 50px rgba(0,0,0,.35), 0 0 0 .5px rgba(0,0,0,.45); }
.vwin .bar { height: 26px; display: flex; align-items: center; gap: 6px; padding-inline: 10px; font: 600 11px/1 var(--font); }
.vwin .bar span { flex: 1; text-align: center; margin-right: 40px; opacity: .6; }
.vwin.dark { background: rgba(30,32,44,.97); color: #C9CEDD; }
.vwin.dark .bar { background: rgba(40,43,58,.97); }
.vwin.lightw { background: #FFF; color: #1D1D1F; }
.vwin.lightw .bar { background: #F1F1F4; }
.vkeys { position: absolute; left: 50%; bottom: 16px; transform: translateX(-50%); display: flex; align-items: center; gap: 8px; padding: 6px 12px 6px 6px; border-radius: 999px; background: var(--hud); color: #F5F5F7; font: 600 12.5px/1 var(--font); white-space: nowrap; z-index: 30; box-shadow: 0 8px 24px rgba(0,0,0,.3); }
.vkeys kbd { min-width: 26px; height: 24px; color: #F5F5F7; background: rgba(255,255,255,.14); box-shadow: inset 0 -1px 0 rgba(0,0,0,.4); transition: transform .12s, background-color .12s; }
.vkeys kbd.down { transform: translateY(1px) scale(.94); background: rgba(var(--warm), .9); color: #3A1D00; }
.vcursor { position: absolute; left: 0; top: 0; z-index: 40; filter: drop-shadow(0 2px 3px rgba(0,0,0,.35)); will-change: transform; }
.vlc { position: absolute; left: 0; top: 0; transform-origin: 0 0; }
.vlc .body { cursor: default; }
.vhud { position: absolute; padding: 6px 11px; border-radius: 999px; font: 600 12px/1 var(--font); color: #F5F5F7; background: var(--hud); white-space: nowrap; z-index: 35; box-shadow: 0 6px 16px rgba(0,0,0,.3); }
.numb { position: absolute; left: -8px; top: -8px; z-index: 4; width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; font: 700 12px/1 var(--font); color: #3A1D00; background: rgb(var(--warm)); box-shadow: 0 2px 6px rgba(0,0,0,.3); }

/* float scene */
.meas { position: absolute; background: rgb(var(--warm)); transform-origin: 0 0; z-index: 25; }
.meas-label { position: absolute; z-index: 26; padding: 3px 6px; border-radius: 5px; font: 700 11px/1 var(--font); color: #3A1D00; background: rgb(var(--warm)); }
.loupe { position: absolute; z-index: 27; width: 96px; height: 96px; border-radius: 50%; overflow: hidden; box-shadow: 0 0 0 3px #FFF, 0 10px 24px rgba(0,0,0,.4);
  background: repeating-linear-gradient(0deg, rgba(0,0,0,.15) 0 1px, transparent 1px 8.7px), repeating-linear-gradient(90deg, rgba(0,0,0,.15) 0 1px, transparent 1px 8.7px), linear-gradient(90deg, #FF9F43 0 55%, #FFFFFF 55%); }
.loupe::after { content: ""; position: absolute; left: 50%; top: 50%; width: 9px; height: 9px; margin: -4.5px; box-shadow: 0 0 0 1.5px #111; }
.swatch { position: absolute; z-index: 27; display: flex; align-items: center; gap: 8px; padding: 6px 10px 6px 6px; border-radius: 10px; background: var(--hud); font: 600 12px/1.2 var(--font); white-space: nowrap; }
.swatch i { width: 22px; height: 22px; border-radius: 6px; background: #FF9F43; box-shadow: inset 0 0 0 1px rgba(255,255,255,.3); }
.swatch small { display: block; color: #9FE3A6; font-weight: 600; }

/* ask scene */
.vsearch { position: absolute; left: 70px; top: 46px; width: 500px; height: 46px; display: flex; align-items: center; gap: 10px; padding-inline: 16px; border-radius: 14px; z-index: 20;
  background: rgba(40,40,52,.78); box-shadow: inset 0 0 0 .5px rgba(255,255,255,.3), 0 14px 30px rgba(0,0,0,.35); font: 500 16px/1 var(--font); }
.vsearch .q { white-space: nowrap; overflow: hidden; }
.vsearch .caret { width: 2px; height: 20px; background: rgb(var(--warm)); animation: blink 1s steps(1) infinite; margin-left: -8px; }
@keyframes blink { 50% { opacity: 0; } }
.vsearch .ret { margin-left: auto; opacity: .5; font-size: 13px; }
.answer { position: absolute; left: 50%; top: 340px; transform: translateX(-50%); display: flex; align-items: center; gap: 12px; padding: 8px 8px 8px 16px; border-radius: 14px; z-index: 22;
  background: rgba(30,30,36,.9); box-shadow: inset 0 0 0 .5px rgba(255,255,255,.25), 0 14px 30px rgba(0,0,0,.35); white-space: nowrap; }
.answer b { font: 700 22px/1 var(--font-display); letter-spacing: .02em; color: rgb(var(--warm)); }
.answer small { font: 500 12px/1.3 var(--font); color: rgba(245,245,247,.7); }
.answer .abtn { padding: 8px 12px; border-radius: 9px; font: 600 12.5px/1 var(--font); background: rgba(var(--warm), .95); color: #3A1D00; transition: transform .15s; }
.answer .abtn.press { transform: scale(.94); }
.hitbox { position: absolute; z-index: 5; border-radius: 4px; box-shadow: 0 0 0 2px rgb(var(--warm)), 0 0 16px rgba(var(--warm), .8); opacity: 0; transition: opacity .4s; }

/* translate scene */
.tr-sheet { position: absolute; left: 100px; top: 56px; width: 440px; border-radius: 16px; overflow: hidden; background: #FFF; color: #1D1D1F; box-shadow: 0 30px 60px rgba(30,30,60,.25), 0 0 0 .5px rgba(0,0,0,.15); }
.tr-sheet .bar { height: 30px; display: flex; align-items: center; gap: 6px; padding-inline: 12px; background: #F3F3F6; }
.tr-rows { padding: 16px 20px 18px; display: grid; gap: 10px; }
.tr-row { position: relative; height: 38px; display: flex; align-items: center; justify-content: space-between; padding: 0 12px; border-radius: 10px; background: #F5F5F8; font: 500 15px/1 var(--font); }
.tr-row.h { background: transparent; height: 34px; padding: 0; font: 700 22px/1 var(--font-display); }
.tr-row .sw { width: 34px; height: 20px; border-radius: 10px; background: #34C759; position: relative; flex: none; }
.tr-row .sw::after { content: ""; position: absolute; right: 2px; top: 2px; width: 16px; height: 16px; border-radius: 50%; background: #FFF; }
.tr-row .sw.off { background: #D1D1D6; }
.tr-row .sw.off::after { right: auto; left: 2px; }
.tr-row.btnrow { justify-content: center; background: #0A84FF; color: #FFF; font-weight: 600; }
.tr-patch { position: absolute; left: 8px; top: 4px; bottom: 4px; display: flex; align-items: center; padding-inline: 4px; border-radius: 4px; background: inherit; opacity: 0; transform: translateY(4px); transition: opacity .35s, transform .5s var(--soft); white-space: nowrap; }
.tr-row.h .tr-patch { left: 0; background: #FFF; min-width: 110px; }
.tr-row:not(.h):not(.btnrow) .tr-patch { min-width: 136px; }
.tr-row.btnrow .tr-patch { padding-inline: 12px; }
.tr-row.btnrow .tr-patch { left: 50%; transform: translate(-50%, 4px); }
.tr-row.on .tr-patch { opacity: 1; transform: none; }
.tr-row.btnrow.on .tr-patch { transform: translateX(-50%); }
.tr-scan { position: absolute; left: 100px; width: 440px; height: 2px; top: 86px; background: rgb(var(--warm)); box-shadow: 0 0 14px 2px rgba(var(--warm), .8); opacity: 0; z-index: 10; }
.tr-sheet.peek .tr-patch { opacity: 0 !important; }
.tr-chip { position: absolute; right: 24px; top: 34px; padding: 6px 10px; border-radius: 999px; font: 600 12px/1 var(--font); color: #F5F5F7; background: rgba(30,30,34,.86); z-index: 12; }

/* veil scene */
.veil-strip .vlc .photo { transition: filter .12s ease; }
.vlc.veiled .photo { filter: blur(7px) brightness(.82) saturate(.9); transition-duration: .3s; }
.vlc .lock { position: absolute; z-index: 5; left: 50%; top: 50%; width: 28px; height: 28px; margin: -14px; border-radius: 50%; display: grid; place-items: center; background: rgba(20,20,26,.7); box-shadow: inset 0 0 0 .5px rgba(255,255,255,.4); opacity: 0; transition: opacity .3s; }
.vlc.private .lock { opacity: 1; }
.share-pill { position: relative; display: flex; align-items: center; gap: 6px; padding: 3px 8px; border-radius: 6px; font: 600 10.5px/1 var(--font); background: #5E5CE6; color: #FFF; opacity: 0; transform: translateY(-6px); transition: opacity .3s, transform .5s var(--spring); }
.share-pill.on { opacity: 1; transform: none; }
.touch { position: absolute; left: 50%; top: 210px; width: 230px; margin-left: -115px; padding: 18px 16px 16px; border-radius: 18px; display: grid; justify-items: center; gap: 10px; text-align: center; z-index: 30;
  background: rgba(36,36,44,.94); box-shadow: inset 0 0 0 .5px rgba(255,255,255,.25), 0 24px 50px rgba(0,0,0,.5); font: 600 13px/1.3 var(--font); opacity: 0; transform: scale(.9); transition: opacity .25s, transform .45s var(--spring); }
.touch.on { opacity: 1; transform: none; }
.touch svg circle { fill: none; stroke: rgba(255,255,255,.18); stroke-width: 3; }
.touch svg .ring { stroke: rgb(var(--warm)); stroke-dasharray: 151; stroke-dashoffset: 151; transform: rotate(-90deg); transform-origin: 50% 50%; transition: stroke-dashoffset .9s var(--soft); }
.touch.ok svg .ring { stroke-dashoffset: 0; }
.touch small { font-weight: 500; color: rgba(245,245,247,.65); }
.wipe-hud { position: absolute; left: 50%; top: 60px; transform: translate(-50%, -10px); display: flex; align-items: center; gap: 12px; padding: 9px 9px 9px 16px; border-radius: 14px; z-index: 30; white-space: nowrap;
  background: rgba(36,36,44,.94); box-shadow: inset 0 0 0 .5px rgba(255,255,255,.25), 0 18px 40px rgba(0,0,0,.45); font: 600 13px/1 var(--font); opacity: 0; transition: opacity .3s, transform .5s var(--spring); overflow: hidden; }
.wipe-hud.on { opacity: 1; transform: translate(-50%, 0); }
.wipe-hud b { padding: 7px 11px; border-radius: 8px; background: rgba(255,255,255,.14); font-weight: 600; transition: background-color .15s; }
.wipe-hud b.press { background: rgba(var(--warm), .9); color: #3A1D00; }
.wipe-hud .bar5 { position: absolute; left: 0; bottom: 0; height: 2px; width: 100%; background: rgb(var(--warm)); transform-origin: 0 50%; }

/* beauty scene */
.bt-panel { position: absolute; left: 14px; top: 36px; bottom: 14px; width: 150px; z-index: 10; padding: 12px; border-radius: 14px; display: grid; align-content: start; gap: 6px;
  background: rgba(30,30,40,.72); box-shadow: inset 0 0 0 .5px rgba(255,255,255,.22); font: 600 12px/1 var(--font); }
.bt-panel .row { display: flex; align-items: center; justify-content: space-between; padding: 8px 9px; border-radius: 8px; color: rgba(245,245,247,.7); transition: background-color .25s, color .25s; }
.bt-panel .row.on { background: rgba(var(--warm), .2); color: #FFF; }
.bt-panel .row i { width: 26px; height: 4px; border-radius: 2px; background: rgba(255,255,255,.2); position: relative; overflow: hidden; }
.bt-panel .row i::after { content: ""; position: absolute; inset: 0; width: var(--v, 30%); background: rgb(var(--warm)); border-radius: inherit; transition: width .6s var(--soft); }
.bt-panel h4 { margin: 0 0 4px; font: 700 13px/1 var(--font-display); color: #FFF; }
.bt-canvas { position: absolute; left: 180px; top: 36px; right: 14px; bottom: 74px; border-radius: 12px; overflow: hidden; display: grid; place-items: center; box-shadow: inset 0 0 0 .5px rgba(255,255,255,.2); }
.bt-bgs { position: absolute; inset: 0; }
.bt-bgs i { position: absolute; inset: 0; opacity: 0; transition: opacity .9s ease; }
.bt-bgs i.on { opacity: 1; }
.bt-shot { position: relative; width: 300px; border-radius: var(--r, 4px); overflow: hidden; transform: scale(var(--k, 1.18)); box-shadow: var(--sh, none);
  transition: transform .9s var(--spring), border-radius .6s, box-shadow .8s; }
.bt-chrome { height: 0; display: flex; align-items: center; gap: 5px; padding-inline: 9px; background: #2A2C3A; overflow: hidden; transition: height .5s var(--soft); }
.bt-chrome.on { height: 22px; }
.bt-chrome i { width: 8px; height: 8px; border-radius: 50%; flex: none; }
.bt-chrome .url { flex: 1; height: 13px; margin-left: 8px; border-radius: 4px; background: rgba(255,255,255,.12); font: 500 8px/13px var(--font); color: rgba(255,255,255,.6); padding-left: 6px; opacity: 0; transition: opacity .3s; }
.bt-chrome.browser .url { opacity: 1; }
.bt-shot img { display: block; width: 100%; }
.bt-describe { position: absolute; left: 180px; right: 14px; bottom: 16px; height: 44px; display: flex; align-items: center; gap: 10px; padding-inline: 14px; border-radius: 12px; z-index: 12;
  background: rgba(30,30,40,.8); box-shadow: inset 0 0 0 .5px rgba(255,255,255,.25); font: 500 13.5px/1 var(--font); color: rgba(245,245,247,.55); }
.bt-describe .typed { color: #FFF; white-space: nowrap; overflow: hidden; }
.bt-describe kbd { margin-left: auto; color: rgba(255,255,255,.7); background: rgba(255,255,255,.12); box-shadow: none; }
.bt-vars { position: absolute; left: 180px; right: 14px; bottom: 74px; height: 96px; display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; padding: 8px; z-index: 11; border-radius: 12px; background: rgba(20,20,28,.85); box-shadow: inset 0 0 0 .5px rgba(255,255,255,.2); opacity: 0; transform: translateY(16px); transition: opacity .35s, transform .6s var(--spring); }
.bt-vars.on { opacity: 1; transform: none; }
.bt-vars i { border-radius: 8px; display: grid; place-items: center; transform: scale(.85); opacity: 0; transition: transform .6s var(--spring), opacity .4s; }
.bt-vars.on i { transform: none; opacity: 1; }
.bt-vars.on i:nth-child(2) { transition-delay: .07s; } .bt-vars.on i:nth-child(3) { transition-delay: .14s; } .bt-vars.on i:nth-child(4) { transition-delay: .21s; }
.bt-vars i b { width: 62%; aspect-ratio: 4 / 3; border-radius: 4px; background: #1E2030; box-shadow: 0 4px 10px rgba(0,0,0,.35); }

/* ---------- river ---------- */
.river { position: relative; margin-inline: calc(50% - 50vw); height: clamp(620px, 96vh, 900px); padding: 0; overflow: hidden; color: #F5F5F7; isolation: isolate;
  --hz: 54%; background: linear-gradient(180deg, #05061A 0%, #0D1240 calc(var(--hz) - 6%), #1A1650 var(--hz), #0A0D2C calc(var(--hz) + 10%), #04050F 100%); }
.river-sky { position: absolute; inset: 0 0 calc(100% - var(--hz)) 0; background:
  radial-gradient(1px 1px at 12% 18%, rgba(255,255,255,.7), transparent 60%), radial-gradient(1px 1px at 28% 8%, rgba(255,255,255,.5), transparent 60%),
  radial-gradient(1px 1px at 46% 22%, rgba(255,255,255,.6), transparent 60%), radial-gradient(1px 1px at 63% 12%, rgba(255,255,255,.5), transparent 60%),
  radial-gradient(1px 1px at 78% 26%, rgba(255,255,255,.7), transparent 60%), radial-gradient(1px 1px at 90% 10%, rgba(255,255,255,.5), transparent 60%),
  radial-gradient(60% 50% at 50% 100%, rgba(var(--warm), .22), transparent 70%); }
.river-scene { position: absolute; inset: 0; z-index: 1; --glass: rgba(70,64,96,.55); --glass-edge: rgba(255,255,255,.45); }
.river-scene::before { content: ""; position: absolute; left: 0; right: 0; top: var(--hz); height: 1px; background: linear-gradient(90deg, transparent, rgba(var(--warm), .5), transparent); }
.ripple { position: absolute; left: -10%; width: 120%; height: 1.5px; border-radius: 2px; background: linear-gradient(90deg, transparent, rgba(255,255,255,.12) 30%, rgba(255,255,255,.04) 60%, transparent); }
.boat { position: absolute; left: 0; top: 0; }
.bob, .sway { position: relative; }
.boat .card { box-shadow: inset 0 0 0 .5px var(--glass-edge), 0 10px 24px rgba(0,0,0,.4); }
.boat .refl { position: absolute; left: 0; right: 0; top: 100%; margin-top: 4px; transform: scaleY(-1); opacity: .22; }
.boat .refl::after { content: ""; position: absolute; inset: 0; z-index: 2; background: linear-gradient(0deg, rgba(8,10,34,0) 0%, #080A22 70%); }
.boat .pool { position: absolute; left: 50%; top: 100%; width: 260%; height: 90%; transform: translate(-50%, -20%); border-radius: 50%; background: radial-gradient(closest-side, rgba(var(--warm), .38), rgba(var(--warm), 0)); pointer-events: none; }
.river-copy { position: relative; z-index: 3; max-width: 700px; margin: 0 auto; padding: clamp(80px, 12vh, 130px) 20px 0; text-align: center; display: grid; justify-items: center; gap: 16px; }
.river-copy .eyebrow { color: #FFB36B; }
.river-copy .tag { color: #FFB36B; background: rgba(var(--warm), .18); }
.river-copy p:not(.eyebrow) { margin: 0; color: rgba(245,245,247,.72); font-size: 17px; max-width: 56ch; text-wrap: pretty; }
.river-copy mark.hl { --hl: rgba(255, 170, 90, .4); }

/* ---------- bento ---------- */
.bento { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
.tile { position: relative; display: grid; align-content: start; gap: 8px; padding: 18px 18px 20px; border-radius: 22px; background: var(--surface); box-shadow: var(--shadow); overflow: hidden; isolation: isolate; }
.tile.t-wide { grid-column: span 2; }
.tile::before { content: ""; position: absolute; inset: 0; z-index: -1; opacity: 0; transition: opacity .4s; background: radial-gradient(260px circle at var(--mx, 50%) var(--my, 0%), rgba(var(--warm), .22), transparent 70%); }
.tile:hover::before { opacity: 1; }
.tile h3 { font-size: 17px; font-weight: 600; letter-spacing: -.015em; margin-top: 6px; }
.tile p { margin: 0; color: var(--muted); font-size: 14.5px; text-wrap: pretty; }
.tile-art { position: relative; height: 128px; border-radius: 14px; background: var(--bg-2); overflow: hidden; display: grid; place-items: center; }

.art-drag { justify-items: start; grid-template-columns: auto 1fr; gap: 18px; padding-inline: 22px; }
.dg-card { width: 86px; aspect-ratio: 128 / 99; border-radius: 10px; background: linear-gradient(135deg, #2B2466, #6E3566); box-shadow: 0 0 0 4px rgba(255,255,255,.7), 0 10px 24px rgba(0,0,0,.18); animation: dg 6s var(--soft) infinite; }
@keyframes dg { 0%, 10% { transform: none; } 30%, 60% { transform: translate(12px, -6px) rotate(-4deg); } 80%, 100% { transform: none; } }
.dg-pills { display: grid; gap: 7px; }
.dg-pills span { justify-self: start; padding: 6px 10px; border-radius: 999px; font: 600 12px/1 var(--font); color: var(--ink); background: var(--surface); box-shadow: 0 0 0 .5px var(--line); white-space: nowrap; opacity: .4; animation: pill 6s infinite; }
.dg-pills span i { font-style: normal; }
.dg-pills span:nth-child(2) { animation-delay: 2s; } .dg-pills span:nth-child(3) { animation-delay: 4s; }
.dg-pills span { position: relative; }
.dg-pills span::after { content: ""; position: absolute; inset: 0; border-radius: inherit; box-shadow: 0 0 0 1.5px rgb(var(--warm)), 0 6px 18px -6px rgba(var(--warm), .9); opacity: 0; animation: pillring 6s infinite; animation-delay: inherit; }
@keyframes pill { 0%, 33% { opacity: 1; transform: translateX(4px); } 34%, 100% { opacity: .4; transform: none; } }
@keyframes pillring { 0%, 33% { opacity: 1; } 34%, 100% { opacity: 0; } }
.art-stack i { position: absolute; width: 96px; aspect-ratio: 128 / 99; border-radius: 10px; background: #FFF; box-shadow: 0 6px 16px rgba(0,0,0,.14), 0 0 0 .5px rgba(0,0,0,.12); transition: transform .6s var(--spring); }
.art-stack i:nth-child(1) { transform: translateY(10px) scale(.86); background: #E7E7EC; }
.art-stack i:nth-child(2) { transform: translateY(5px) scale(.93); background: #F1F1F4; }
.art-stack i:nth-child(3) { background: linear-gradient(#1E2030 0 100%); }
.art-stack b { position: absolute; left: calc(50% + 36px); top: calc(50% - 46px); width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; font: 700 12px/1 var(--font); background: rgb(var(--warm)); color: #3A1D00; z-index: 2; }
.tile:hover .art-stack i:nth-child(1) { transform: translate(-58px, 0) rotate(-8deg); }
.tile:hover .art-stack i:nth-child(2) { transform: translate(58px, 0) rotate(8deg); }
.art-actions { align-content: center; gap: 7px; }
.art-actions span { padding: 7px 12px; border-radius: 999px; font: 600 12.5px/1 var(--font); background: var(--surface); box-shadow: 0 0 0 .5px var(--line), 0 4px 10px rgba(0,0,0,.05); animation: actpop 4.5s var(--soft) infinite; }
.art-actions span:nth-child(2) { animation-delay: .25s; } .art-actions span:nth-child(3) { animation-delay: .5s; }
@keyframes actpop { 0% { opacity: 0; transform: translateY(8px) scale(.95); } 12%, 85% { opacity: 1; transform: none; } 100% { opacity: 0; } }
.art-wave { grid-auto-flow: column; gap: 4px; place-content: center; }
.art-wave i { width: 5px; height: 44px; border-radius: 3px; background: rgb(var(--warm)); transform: scaleY(.25); animation: wave 1.2s ease-in-out infinite; }
.art-wave i:nth-child(2n) { animation-delay: -.3s; } .art-wave i:nth-child(3n) { animation-delay: -.6s; } .art-wave i:nth-child(5n) { animation-delay: -.9s; }
@keyframes wave { 50% { transform: scaleY(1); } }
.art-wave kbd { margin-left: 14px; }
.art-watch { place-items: center; }
.wt-region { position: relative; padding: 16px 22px; border-radius: 8px; border: 1.5px dashed rgba(var(--warm), .9); font: 600 15px/1 ui-monospace, "SF Mono", Menlo, monospace; }
.wt-region b { color: #28A745; opacity: 0; animation: wtword 5s infinite; }
@keyframes wtword { 0%, 35% { opacity: 0; } 40%, 100% { opacity: 1; } }
.wt-dot { position: absolute; left: 50%; top: -5px; width: 8px; height: 8px; margin-left: -4px; border-radius: 50%; background: rgb(var(--warm)); box-shadow: 0 0 8px rgb(var(--warm)); animation: breathe 1.7s ease-in-out infinite; }
.wt-toast { position: absolute; right: 14px; top: 12px; display: flex; align-items: center; gap: 8px; padding: 7px 11px 7px 7px; border-radius: 12px; background: var(--surface); box-shadow: 0 0 0 .5px var(--line), 0 8px 20px rgba(0,0,0,.1); font: 600 12px/1 var(--font); opacity: 0; animation: toast 5s var(--soft) infinite; }
.wt-toast img { width: 20px; height: 20px; border-radius: 5px; }
@keyframes toast { 0%, 42% { opacity: 0; transform: translateX(20px); } 50%, 90% { opacity: 1; transform: none; } 100% { opacity: 0; } }
.art-table { grid-template-columns: repeat(4, 38px); grid-auto-rows: 20px; gap: 3px; place-content: center; place-items: stretch; }
.art-table i { position: relative; border-radius: 3px; background: var(--surface); box-shadow: 0 0 0 .5px var(--line); }
.art-table i::after { content: ""; position: absolute; inset: 0; border-radius: inherit; box-shadow: 0 0 0 1.5px rgb(var(--warm)); opacity: 0; animation: cell 4s infinite; animation-delay: inherit; }
.art-table i:nth-child(-n+4) { background: var(--chip); }
.art-table i { animation-delay: 0s; }
.art-table i:nth-child(1) { animation-delay: 0s; } .art-table i:nth-child(2) { animation-delay: .08s; } .art-table i:nth-child(3) { animation-delay: .16s; } .art-table i:nth-child(4) { animation-delay: .24s; }
.art-table i:nth-child(5) { animation-delay: .32s; } .art-table i:nth-child(6) { animation-delay: .4s; } .art-table i:nth-child(7) { animation-delay: .48s; } .art-table i:nth-child(8) { animation-delay: .56s; }
.art-table i:nth-child(9) { animation-delay: .64s; } .art-table i:nth-child(10) { animation-delay: .72s; } .art-table i:nth-child(11) { animation-delay: .8s; } .art-table i:nth-child(12) { animation-delay: .88s; }
@keyframes cell { 0%, 20%, 100% { opacity: 0; } 10% { opacity: 1; } }
.art-rule { align-content: center; justify-items: start; gap: 8px; padding-inline: 18px; }
.art-rule code { padding: 7px 10px; border-radius: 8px; background: var(--surface); box-shadow: 0 0 0 .5px var(--line); font: 500 12.5px/1 ui-monospace, "SF Mono", Menlo, monospace; white-space: nowrap; }
.art-rule code b { color: var(--warm-ink); margin-right: 4px; }
.art-rule code:last-child { margin-left: 22px; }
.art-share { grid-auto-flow: column; place-content: center; }
.av { width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; margin-left: -10px; font: 700 16px/1 var(--font); color: #FFF; box-shadow: 0 0 0 3px var(--bg-2); transition: transform .5s var(--spring); }
.a1 { background: #5E5CE6; } .a2 { background: #E07A3F; } .a3 { background: var(--chip); color: var(--muted); }
.tile:hover .a1 { transform: translateX(-8px); } .tile:hover .a3 { transform: translateX(8px); }
.art-bug { grid-auto-flow: column; gap: 10px; place-content: center; }
.art-bug span { width: 52px; height: 40px; border-radius: 7px; display: grid; place-items: end start; padding: 4px 6px; font: 700 11px/1 var(--font); background: var(--surface); box-shadow: 0 0 0 .5px var(--line), 0 4px 10px rgba(0,0,0,.06); position: relative; }
.art-bug .diff::after { content: ""; position: absolute; right: 6px; top: 6px; width: 22px; height: 14px; border-radius: 5px; box-shadow: 0 0 0 2px #E5533D; animation: breathe 1.7s ease-in-out infinite; }
.art-src { grid-auto-flow: column; gap: 10px; place-content: center; }
.art-src .url { padding: 8px 12px; border-radius: 999px; background: var(--surface); box-shadow: 0 0 0 .5px var(--line); font: 500 12.5px/1 var(--font); }
.art-src .arrow { width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; background: rgb(var(--warm)); color: #3A1D00; font-weight: 700; transition: transform .5s var(--spring); }
.tile:hover .art-src .arrow { transform: rotate(-40deg) scale(1.08); }
.art-notch { background: #0B1030; place-items: start center; }
.art-notch .nt { width: 120px; height: 26px; border-radius: 0 0 14px 14px; background: #000; animation: notch 4s var(--soft) infinite; }
.art-notch .nt-card { position: absolute; left: 50%; top: 80px; width: 48px; aspect-ratio: 128 / 99; margin-left: -24px; border-radius: 6px; background: linear-gradient(135deg, #FFF4E2, #FFC27A); box-shadow: 0 0 20px rgba(var(--warm), .8); animation: intonotch 4s var(--soft) infinite; }
@keyframes intonotch { 0% { transform: translateY(30px) scale(1.2); opacity: 0; } 15% { opacity: 1; } 45% { transform: translateY(-78px) scale(.3); opacity: 1; } 55%, 100% { transform: translateY(-78px) scale(.3); opacity: 0; } }
@keyframes notch { 0%, 42% { transform: scaleX(1); } 52% { transform: scaleX(1.25); } 70%, 100% { transform: scaleX(1); } }
.art-snooze { grid-auto-flow: column; gap: 14px; place-content: center; }
.sz-card { width: 72px; aspect-ratio: 128 / 99; border-radius: 9px; background: linear-gradient(135deg, #2B2466, #6E3566); animation: dimout 4s ease-in-out infinite; }
@keyframes dimout { 0%, 100% { opacity: 1; } 50% { opacity: .35; } }
.sz-pill { padding: 7px 11px; border-radius: 999px; font: 600 12.5px/1 var(--font); background: var(--surface); box-shadow: 0 0 0 .5px var(--line); white-space: nowrap; }
.art-devices { grid-auto-flow: column; gap: 24px; place-content: center; }
.phone { width: 52px; height: 100px; border-radius: 12px; background: #111; box-shadow: inset 0 0 0 2px #333; position: relative; }
.phone i { position: absolute; inset: 5px; border-radius: 8px; background: linear-gradient(135deg, #FFF4E2, #FFC27A); animation: dimout 3s ease-in-out infinite; }
.dv-list { display: grid; gap: 6px; }
.dv-list b { padding: 7px 12px; border-radius: 8px; font: 600 12.5px/1 var(--font); background: var(--surface); box-shadow: 0 0 0 .5px var(--line); }
.dv-list b:first-child { background: #0A84FF; color: #FFF; box-shadow: none; }
.art-focus span { width: 64px; height: 64px; border-radius: 50%; display: grid; place-items: center; font-size: 28px; color: #FFF; background: #5E5CE6; box-shadow: 0 10px 26px -8px #5E5CE6; }

/* ---------- pricing ---------- */
.plans { margin: 0 auto; max-width: 800px; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; align-items: start; }
.plan { background: var(--surface); border-radius: 22px; padding: 28px; box-shadow: var(--shadow); display: grid; gap: 22px; }
.plan h3 { font-size: 15px; font-weight: 600; color: var(--muted); }
.amount { margin: 6px 0 0; font: 700 44px/1.1 var(--font-display); letter-spacing: -.03em; }
.amount small { font: 500 15px var(--font); letter-spacing: 0; color: var(--muted); }
.plan ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; font-size: 15px; }
.plan li { position: relative; padding-left: 24px; }
.plan li::before { content: ""; position: absolute; left: 2px; top: .5em; width: 9px; height: 5px; border-left: 1.6px solid currentColor; border-bottom: 1.6px solid currentColor; transform: rotate(-45deg); opacity: .55; }
.plan-pro { position: relative; overflow: hidden; }
.plan-pro::before { content: ""; position: absolute; right: -90px; top: -120px; width: 320px; height: 320px; border-radius: 50%; background: radial-gradient(closest-side, rgba(var(--warm), .42), rgba(var(--warm), 0)); pointer-events: none; animation: breathe 5s ease-in-out infinite; }
.plan-pro > * { position: relative; }
.plan .fine { text-align: center; margin-top: -8px; }
.plans-single { grid-template-columns: minmax(0, 480px); justify-content: center; }
.amount del { font: 500 22px var(--font); letter-spacing: 0; color: var(--muted); margin-right: 4px; vertical-align: 6px; }
.amount del[hidden] { display: none; }
.launch { margin: 8px 0 0; font-size: 13px; font-weight: 600; color: var(--warm-ink); }
.plan .buy { display: grid; gap: 10px; }
.refund { margin: 0; text-align: center; font-size: 14px; font-weight: 500; color: var(--ink); }
.plan .fine a { color: inherit; text-decoration: underline; text-underline-offset: 2px; }

/* ---------- faq ---------- */
.faq { max-width: 760px; margin: 0 auto; }
.faq h2 { margin-bottom: 32px; text-align: center; }
details { border-bottom: 1px solid var(--line); }
.faq details:first-of-type { border-top: 1px solid var(--line); }
summary { list-style: none; cursor: pointer; padding: 18px 36px 18px 0; position: relative; font-weight: 600; }
summary::-webkit-details-marker { display: none; }
summary::after { content: "+"; position: absolute; right: 4px; top: 50%; transform: translateY(-50%); font: 400 22px/1 var(--font); color: var(--muted); transition: transform .35s var(--spring); }
details[open] summary::after { transform: translateY(-50%) rotate(45deg); }
details p { margin: 0 0 20px; color: var(--muted); max-width: 62ch; }
details[open] > :not(summary) { animation: open .5s var(--soft); }
@keyframes open { from { opacity: 0; transform: translateY(-6px); } }

/* ---------- closing ---------- */
.closing { position: relative; margin: 40px 0 72px; padding: clamp(96px, 14vw, 160px) 20px; border-radius: 32px; overflow: hidden; isolation: isolate; text-align: center; color: #F5F5F7;
  background: radial-gradient(70% 60% at 50% 110%, rgba(var(--warm), .32), transparent 70%), linear-gradient(180deg, #05061A, #0D1240 70%, #1A1650); }
.closing-sky { position: absolute; inset: 0; z-index: -1; --glass: rgba(70,64,96,.55); --glass-edge: rgba(255,255,255,.45); }
.closing-copy { display: grid; justify-items: center; gap: 24px; }
.closing img { border-radius: 24px; filter: drop-shadow(0 18px 40px rgba(255,170,80,.45)); }
.closing h2 { font-size: clamp(34px, 5.6vw, 64px); }
.closing .fine { color: rgba(245,245,247,.6); }
.closing mark.hl { --hl: rgba(255, 170, 90, .4); }
.riser { position: absolute; left: 0; bottom: -120px; }
.riser .card { padding: 4px; border-radius: 10px; box-shadow: inset 0 0 0 .5px var(--glass-edge), 0 8px 20px rgba(0,0,0,.35); }
.riser .photo { border-radius: 6px; }

/* ---------- footer ---------- */
.foot {
  max-width: 1160px; margin: 0 auto; padding: 28px 20px 40px; display: flex; flex-wrap: wrap; align-items: center; gap: 10px 22px;
  font-size: 13px; color: var(--muted); border-top: 1px solid var(--line);
}
.foot a { text-decoration: none; }
.foot a:hover { color: var(--ink); }
.lang { margin-left: auto; display: inline-flex; padding: 2px; border-radius: 8px; background: var(--chip); }
.lang button { appearance: none; border: 0; background: transparent; color: var(--muted); font: 600 12px/1 var(--font); padding: 6px 9px; border-radius: 6px; cursor: pointer; }
.lang button[aria-pressed="true"] { background: var(--surface); color: var(--ink); box-shadow: 0 1px 2px rgba(0,0,0,.1); }

/* ---------- small screens ---------- */
@media (max-width: 980px) {
  .bento { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .chapter { grid-template-columns: 1fr; }
  .chapter.flip .ch-text { order: 0; }
  .ch-text { max-width: 640px; }
}
@media (max-width: 820px) {
  .state-row { display: flex; flex-wrap: wrap; justify-content: center; row-gap: 22px; }
  .state { flex: 0 0 calc((100% - 24px) / 3); }
  .win-code { left: 4%; width: 70%; top: 44%; }
  .win-chat { right: 4%; width: 46%; top: 36%; }
  .nav-links { display: none; }
  .nav.scrolled .nav-pill { width: min(420px, 100%); }
  .story-track { height: 460vh; }
}
@media (max-width: 600px) {
  .mb-left span:nth-of-type(n+3) { display: none; }
  .bento { grid-template-columns: 1fr; }
  .tile.t-wide { grid-column: auto; }
  .art-drag { grid-template-columns: 1fr; justify-items: center; padding: 12px; gap: 10px; }
  .art-drag .dg-card { display: none; }
  .plans { grid-template-columns: 1fr; }
  .plan { padding: 24px; }
  .state-row { padding-inline: 8px; gap: 18px 8px; }
  .state { flex-basis: calc((100% - 16px) / 3); }
  .pen { height: 96px; }
  .demo-bar { justify-content: center; }
  .hint { width: 100%; text-align: center; }
  .foot .lang { margin-left: 0; }
  .hero { padding-top: 112px; }
  .story-captions { height: 128px; }
  .story-sticky { padding-top: 72px; grid-template-rows: auto auto auto; align-content: center; gap: 28px; }
  .closing { border-radius: 24px; }
  .river { --hz: 66%; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .body, .hud, .glow, .wash, .dim { transition: none; }
  .lantern.dying .glow, .chip-dot, .glowword, .plan-pro::before, .scroll-cue span { animation: none; }
  .mq-row { animation: none; }
  .marquee { overflow-x: auto; }
  .js [data-reveal] { transition: opacity .3s; transform: none; }
  .js .hero h1 .w { animation: none; opacity: 1; transform: none; }
  .js .state-row .lantern { opacity: 1; }
  .state-row.in .lantern, .state-row.in .glow { animation: none; }
  .tile-art *, .tile-art { animation: none !important; }
  .wt-region b, .wt-toast, .art-actions span { opacity: 1; }
  mark.hl { transition: none; }
}
