/* Prelanders (docs/prelanders.md): dark "aurora" product pages in one 440px column. Themes are variables on <body>; old theme keys are aliases. */
:root { --pad: 24px; --ease-out: cubic-bezier(0.23, 1, 0.32, 1); --spring: cubic-bezier(0.32, 0.72, 0, 1); --sans: ui-sans-serif, -apple-system, "SF Pro Display", "SF Pro Text", system-ui, Roboto, "Segoe UI", sans-serif; }
*, *::before, *::after { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
/* In-app browsers (TikTok): no pull-to-refresh or close from the page edge. */
html, body { overscroll-behavior: none; }

/* Themes. --tile0..2 are the icon tiles; --g1..3 the fog of "reveal"; --glow-* the three lights; --mood-a/b the two ends of "mood". */
.theme-aurora, .theme-ink, .theme-mint {
  --outer: #04070d; --bg: #070b14; --bg-rgb: 7 11 20; --ink: #f3f6fb; --muted: #9eabbf; --surface: rgb(255 255 255 / 0.06); --surface-2: rgb(255 255 255 / 0.11); --line: rgb(255 255 255 / 0.12);
  --accent: #34d399; --cta-1: #5eead4; --cta-2: #34d399; --on-cta: #04201a; --cta-glow: rgb(52 211 153 / 0.42); --glow-a: #14b8a6; --glow-b: #2563eb; --glow-c: #10b981; --glow-o: 0.5;
  --tile0: linear-gradient(140deg, #14b8a6, #0ea5e9); --tile1: linear-gradient(140deg, #34d399, #14b8a6); --tile2: linear-gradient(140deg, #38bdf8, #2563eb);
  --g1: #2a7f8f; --g2: #2d5fa8; --g3: #2a8f74; --sheet: #0e1626; --mood-a: linear-gradient(140deg, #0e7490, #1e40af); --mood-b: linear-gradient(140deg, #34d399, #facc15);
  --h1-a: #ffffff; --h1-b: #b4c3d8; --shadow: 0 18px 40px -18px rgb(0 0 0 / 0.7);
}
.theme-sunset {
  --outer: #0a0406; --bg: #12080b; --bg-rgb: 18 8 11; --ink: #fff4ee; --muted: #c9a79d; --surface: rgb(255 255 255 / 0.06); --surface-2: rgb(255 255 255 / 0.11); --line: rgb(255 255 255 / 0.13);
  --accent: #ff7a59; --cta-1: #ffbd6e; --cta-2: #ff6b57; --on-cta: #2a0d06; --cta-glow: rgb(255 107 87 / 0.42); --glow-a: #ff6b57; --glow-b: #ff3d81; --glow-c: #ffb347; --glow-o: 0.46;
  --tile0: linear-gradient(140deg, #ff7a59, #ff3d81); --tile1: linear-gradient(140deg, #ffb347, #ff7a59); --tile2: linear-gradient(140deg, #ff3d81, #c2410c);
  --g1: #b4533e; --g2: #a8365f; --g3: #b9772f; --sheet: #1d0f13; --mood-a: linear-gradient(140deg, #9f1239, #7c2d12); --mood-b: linear-gradient(140deg, #ffb347, #ff3d81);
  --h1-a: #ffffff; --h1-b: #f0c9bd; --shadow: 0 18px 40px -18px rgb(0 0 0 / 0.7);
}
.theme-ocean, .theme-sky {
  --outer: #02080f; --bg: #04101b; --bg-rgb: 4 16 27; --ink: #eef8ff; --muted: #93b3c7; --surface: rgb(255 255 255 / 0.06); --surface-2: rgb(255 255 255 / 0.11); --line: rgb(255 255 255 / 0.12);
  --accent: #22d3ee; --cta-1: #67e8f9; --cta-2: #3b82f6; --on-cta: #03121f; --cta-glow: rgb(34 211 238 / 0.4); --glow-a: #06b6d4; --glow-b: #2563eb; --glow-c: #0ea5e9; --glow-o: 0.5;
  --tile0: linear-gradient(140deg, #06b6d4, #2563eb); --tile1: linear-gradient(140deg, #22d3ee, #0ea5e9); --tile2: linear-gradient(140deg, #0ea5e9, #1d4ed8);
  --g1: #137a8c; --g2: #1f4fa3; --g3: #0f6d8f; --sheet: #0a1a2b; --mood-a: linear-gradient(140deg, #0e7490, #1e3a8a); --mood-b: linear-gradient(140deg, #22d3ee, #a3e635);
  --h1-a: #ffffff; --h1-b: #b3d3e6; --shadow: 0 18px 40px -18px rgb(0 0 0 / 0.7);
}
.theme-paper, .theme-stone, body.pl.tpl-ai {
  --outer: #e6e9ee; --bg: #f6f7f9; --bg-rgb: 246 247 249; --ink: #0f1720; --muted: #566273; --surface: #ffffff; --surface-2: #ffffff; --line: rgb(15 23 32 / 0.1);
  --accent: #0b7f61; --cta-1: #0b8f6a; --cta-2: #0a7a8c; --on-cta: #ffffff; --cta-glow: rgb(11 127 97 / 0.3); --glow-a: #7ee0c3; --glow-b: #9fd0ff; --glow-c: #ffd7a8; --glow-o: 0.55;
  --tile0: linear-gradient(140deg, #10b981, #0ea5a4); --tile1: linear-gradient(140deg, #f59e0b, #f97316); --tile2: linear-gradient(140deg, #3b82f6, #06b6d4);
  --g1: #bfe9dc; --g2: #cfe3fb; --g3: #fde6c8; --sheet: #ffffff; --mood-a: linear-gradient(140deg, #9fd0ff, #7ee0c3); --mood-b: linear-gradient(140deg, #ffd7a8, #ff9f7a);
  --h1-a: #0f1720; --h1-b: #0f1720; --shadow: 0 12px 28px -16px rgb(15 23 32 / 0.25);
}

body.pl { margin: 0; min-height: 100vh; min-height: -webkit-fill-available; min-height: 100dvh; background: var(--outer); color: var(--ink); font: 16px/1.5 var(--sans); -webkit-font-smoothing: antialiased; }
.app { position: relative; z-index: 0; max-width: 440px; min-height: 100vh; min-height: -webkit-fill-available; min-height: 100dvh; margin: 0 auto; display: flex; flex-direction: column; background: var(--bg); padding-top: env(safe-area-inset-top); }
@media (min-width: 480px) { .app { box-shadow: 0 0 0 1px var(--line), 0 24px 70px rgb(0 0 0 / 0.35); } }
.screen { position: relative; z-index: 1; flex: 1; display: flex; flex-direction: column; padding: 20px var(--pad) 8px; }
/* The footer and the browser hint stay visible whatever a generated page's own CSS says. */
.legal { display: block !important; visibility: visible !important; opacity: 1 !important; position: static !important; padding: 14px var(--pad) calc(18px + env(safe-area-inset-bottom)); font-size: 12px; line-height: 1.45; text-align: center; color: var(--muted); }
[hidden] { display: none !important; }

/* Aurora: three soft lights drifting very slowly (transform only, no blur filter). */
.aurora { position: absolute; inset: 0; overflow: hidden; pointer-events: none; z-index: -1; }
.aurora i { position: absolute; width: 440px; height: 440px; border-radius: 50%; opacity: var(--glow-o); will-change: transform; animation: drift 26s ease-in-out infinite alternate; }
.aurora i:nth-child(1) { top: -170px; left: -150px; background: radial-gradient(closest-side, var(--glow-a), transparent); }
.aurora i:nth-child(2) { top: 26%; right: -230px; background: radial-gradient(closest-side, var(--glow-b), transparent); animation-duration: 32s; animation-delay: -9s; }
.aurora i:nth-child(3) { top: 40%; left: -260px; width: 380px; height: 380px; background: radial-gradient(closest-side, var(--glow-c), transparent); animation-duration: 29s; animation-delay: -16s; }
@keyframes drift { to { transform: translate3d(60px, 46px, 0) scale(1.12); } }
.tpl-ai .aurora { display: none; }

h1, h2 { margin: 0; text-wrap: balance; }
h1 { margin-top: 22px; font: 750 34px/1.06 var(--sans); letter-spacing: -0.034em; color: var(--ink); }
@supports (-webkit-background-clip: text) or (background-clip: text) {
  h1 { background: linear-gradient(180deg, var(--h1-a) 35%, var(--h1-b)); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; color: transparent; }
}
h2 { font-size: 20px; line-height: 1.25; font-weight: 680; letter-spacing: -0.015em; }
p { margin: 0; }
.sub { margin-top: 12px; font-size: 17px; line-height: 1.45; color: var(--muted); text-wrap: pretty; }
.muted { display: block; color: var(--muted); font-size: 14px; line-height: 1.4; }
.small { font-size: 12.5px; }
.eyebrow { margin-top: 18px; font-size: 12.5px; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; color: var(--accent); }
ul, ol { list-style: none; margin: 0; padding: 0; }
b { font-weight: 680; }

/* Entrance: a short rise, CSS only, so it also plays without JS. */
@keyframes rise { from { opacity: 0; transform: translateY(10px); } }
.screen > * { animation: rise 460ms var(--ease-out) backwards; }
.screen > :nth-child(2) { animation-delay: 50ms; }
.screen > :nth-child(3) { animation-delay: 100ms; }
.screen > :nth-child(4) { animation-delay: 150ms; }

/* Glass: a translucent card with a thin edge; blur only where supported and only on small cards. */
.glass { background: linear-gradient(180deg, rgb(255 255 255 / 0.07), rgb(255 255 255 / 0.03)); background-color: var(--surface); box-shadow: inset 0 0 0 1px var(--line); }
.theme-paper .glass, .theme-stone .glass, .tpl-ai .glass { background: var(--surface); box-shadow: inset 0 0 0 1px var(--line), var(--shadow); }
@supports ((-webkit-backdrop-filter: blur(1px)) or (backdrop-filter: blur(1px))) {
  .cand, .card, .tcard, .opt, .chat-head { -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); }
}

/* Icons, tiles, photos */
.ico { width: 22px; height: 22px; flex: none; }
.tile { display: grid; place-items: center; flex: none; width: 44px; height: 44px; border-radius: 14px; color: #fff; background: var(--tile0); box-shadow: inset 0 1px 0 rgb(255 255 255 / 0.3), 0 6px 14px -8px rgb(0 0 0 / 0.5); }
.tile-1 { background: var(--tile1); }
.tile-2 { background: var(--tile2); }
.tile-sm { width: 38px; height: 38px; border-radius: 12px; }
.tile-sm .ico { width: 20px; height: 20px; }
.tile-lg { width: 56px; height: 56px; border-radius: 18px; }
.tile-lg .ico { width: 26px; height: 26px; }
.ph { display: block; width: 100%; height: 100%; object-fit: cover; background: var(--surface); }
.ph-fallback { display: grid; place-items: center; color: #fff; background: var(--tile0); }
.ph-1 { background: var(--tile1); }
.ph-2 { background: var(--tile2); }
.ph-fallback .ico { width: 42%; height: auto; max-width: 96px; aspect-ratio: 1; }
.av-lg { flex: none; width: 68px; height: 68px; border-radius: 20px; overflow: hidden; box-shadow: inset 0 1px 0 rgb(255 255 255 / 0.3); }
.mark { display: grid; place-items: center; overflow: hidden; flex: none; width: 40px; height: 40px; border-radius: 12px; color: #fff; background: var(--tile0); box-shadow: inset 0 1px 0 rgb(255 255 255 / 0.3); }
.mark img { width: 100%; height: 100%; object-fit: cover; }
.mark-sm { width: 28px; height: 28px; border-radius: 8px; }
.mark-sm .ico { width: 16px; height: 16px; }
.mark-av { width: 44px; height: 44px; border-radius: 14px; }
.mark-orb { position: relative; width: 92px; height: 92px; border-radius: 26px; box-shadow: 0 0 0 1px rgb(255 255 255 / 0.18), 0 16px 40px -10px var(--cta-glow); }
.mark-orb .ico { width: 40px; height: 40px; }

/* Orbit: the hero without a photo, the app icon in a glowing ring with three small icons floating round it. */
.orbit { position: relative; display: grid; place-items: center; width: 230px; height: 230px; margin: 4px auto 0; }
.orbit::before { content: ""; position: absolute; inset: -30px; border-radius: 50%; background: radial-gradient(closest-side, var(--cta-glow), transparent); opacity: 0.7; }
.orbit-ring { position: absolute; border-radius: 50%; border: 1px solid var(--line); }
.r1 { inset: 28px; }
.r2 { inset: 0; border-style: dashed; animation: spin 80s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.sat { position: absolute; animation: float 7s ease-in-out infinite alternate; }
.s1 { top: 10px; left: 18px; }
.s2 { top: 30px; right: 6px; animation-delay: -2.5s; }
.s3 { bottom: 12px; left: 56px; animation-delay: -4.5s; }
@keyframes float { to { transform: translate3d(0, -8px, 0); } }

/* Buttons */
.btn { position: relative; overflow: hidden; display: flex; align-items: center; justify-content: center; gap: 8px; width: 100%; min-height: 56px; padding: 0 24px; border: 0; border-radius: 18px; color: var(--on-cta); background: linear-gradient(135deg, var(--cta-1), var(--cta-2)); box-shadow: inset 0 1px 0 rgb(255 255 255 / 0.4), 0 10px 28px -10px var(--cta-glow); font: inherit; font-size: 17px; font-weight: 680; letter-spacing: -0.005em; text-decoration: none; cursor: pointer; touch-action: manipulation; transition: transform 160ms var(--ease-out), filter 160ms ease; }
.btn::after { content: ""; position: absolute; top: 0; bottom: 0; left: -60%; width: 40%; background: linear-gradient(100deg, transparent, rgb(255 255 255 / 0.45), transparent); transform: translate3d(0, 0, 0) skewX(-18deg); animation: sheen 1100ms var(--ease-out) 1100ms 1 backwards; opacity: 0; }
@keyframes sheen { from { opacity: 1; transform: translate3d(0, 0, 0) skewX(-18deg); } to { opacity: 0; transform: translate3d(520%, 0, 0) skewX(-18deg); } }
.btn:active { transform: scale(0.97); }
.btn-ghost { width: auto; flex: none; color: var(--ink); background: var(--surface-2); box-shadow: inset 0 0 0 1px var(--line); }
.btn-ghost::after { display: none; }
.btn:focus-visible, .chip:focus-visible, .opt:focus-visible, .card:focus-visible, .track:focus-visible { outline: 2px solid var(--cta-1); outline-offset: 3px; }
@media (hover: hover) and (pointer: fine) {
  .btn:hover { filter: brightness(1.08); }
  .btn:hover::after { opacity: 1; animation: sheen 900ms var(--ease-out) 1; }
  .chip:hover, .opt:hover, .card:hover { box-shadow: inset 0 0 0 1px var(--accent); }
}
.dock { position: sticky; bottom: env(safe-area-inset-bottom, 0px); margin: auto calc(var(--pad) * -1) 0; padding: 22px var(--pad) 10px; background: linear-gradient(to top, rgb(var(--bg-rgb) / 0.82) 55%, rgb(var(--bg-rgb) / 0)); }
.dock-row { display: flex; gap: 10px; }
.dock-row .btn:last-child { flex: 1; }

/* minimal */
.solo { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding-bottom: 24px; }
.solo h1 { margin-top: 8px; }
.solo .btn { margin-top: 28px; }

/* features */
.hero { position: relative; margin-top: 4px; min-height: 250px; display: grid; place-items: center; }
.hero:has(.hero-img) { aspect-ratio: 4 / 3.1; border-radius: 30px; overflow: hidden; box-shadow: inset 0 0 0 1px var(--line); }
.hero-img { position: absolute; inset: 0; }
.hero:has(.hero-img)::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, rgb(var(--bg-rgb) / 0.78), rgb(var(--bg-rgb) / 0) 55%); }
.brandchip { position: absolute; left: 12px; bottom: 12px; z-index: 1; display: flex; align-items: center; gap: 8px; padding: 5px 14px 5px 5px; border-radius: 999px; background: rgb(var(--bg-rgb) / 0.72); box-shadow: inset 0 0 0 1px var(--line); font-size: 14px; font-weight: 650; }
.hero:not(:has(.hero-img)) .brandchip { display: none; }
.feats { display: grid; gap: 12px; margin: 24px 0 8px; }
.feats li { display: flex; gap: 14px; align-items: center; padding: 14px; border-radius: 22px; }
.feats b { display: block; font-size: 16.5px; }

/* chat */
.chat-head { display: flex; align-items: center; gap: 12px; padding: 10px 14px 10px 10px; border-radius: 22px; }
.chat-who { display: grid; line-height: 1.25; }
.chat-name { font-weight: 680; }
.log { display: flex; flex-direction: column; align-items: flex-start; gap: 8px; padding: 18px 0 12px; }
.msg { max-width: 84%; padding: 11px 15px; border-radius: 20px; font-size: 16px; line-height: 1.4; }
.them { background: var(--surface-2); border-bottom-left-radius: 6px; box-shadow: inset 0 0 0 1px var(--line); }
.me { align-self: flex-end; color: var(--on-cta); background: linear-gradient(135deg, var(--cta-1), var(--cta-2)); border-bottom-right-radius: 6px; font-weight: 550; }
.typing { display: flex; gap: 5px; padding: 15px 16px; }
.typing i { width: 7px; height: 7px; border-radius: 50%; background: var(--muted); animation: blink 1.1s ease-in-out infinite; }
.typing i:nth-child(2) { animation-delay: 0.15s; }
.typing i:nth-child(3) { animation-delay: 0.3s; }
@keyframes blink { 0%, 80%, 100% { opacity: 0.3; } 40% { opacity: 1; } }
.replies { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 8px; margin: 4px 0 8px; }
.chip { display: inline-flex; align-items: center; min-height: 44px; padding: 0 17px; border-radius: 22px; background: var(--surface-2); box-shadow: inset 0 0 0 1px var(--line); color: var(--ink); font-size: 15px; font-weight: 600; text-decoration: none; touch-action: manipulation; transition: transform 160ms var(--ease-out), box-shadow 160ms ease; }
.chip:active { transform: scale(0.97); }
/* JS mode: staged items stay hidden until the script reveals them. */
.js [data-step]:not(.is-in) { display: none; }
.is-in { animation: rise 300ms var(--ease-out) backwards; }

/* quiz */
.qbar { display: flex; align-items: center; gap: 12px; }
.qbar .prog { flex: 1; }
.prog { height: 5px; border-radius: 3px; background: var(--surface-2); overflow: hidden; }
.prog i { display: block; height: 100%; border-radius: 3px; background: linear-gradient(90deg, var(--cta-1), var(--cta-2)); transform-origin: left; transform: scaleX(0.333); transition: transform 280ms var(--ease-out); }
.prog[data-s="2"] i { transform: scaleX(0.667); }
.prog[data-s="3"] i { transform: scaleX(1); }
.qhead { margin-bottom: 6px; }
.js .qhead { display: none; }
.step { margin-top: 26px; }
.step-result > .muted { margin-top: 6px; font-size: 15px; }
.step > h2 { font: 720 27px/1.15 var(--sans); letter-spacing: -0.028em; }
.js .step:not(.is-active) { display: none; }
.step-q, .step-search { margin: auto 0; padding-bottom: 12vh; }
.step-result { flex: 1; display: flex; flex-direction: column; }
.js .step { animation: rise 300ms var(--ease-out) backwards; }
html:not(.js) .step-q, html:not(.js) .step-search { display: none; }
.opts { display: grid; gap: 10px; margin-top: 18px; }
.opt { display: flex; align-items: center; gap: 14px; min-height: 64px; padding: 0 16px 0 12px; border: 0; border-radius: 20px; color: var(--ink); font: inherit; font-size: 16.5px; font-weight: 600; text-align: left; cursor: pointer; touch-action: manipulation; transition: transform 160ms var(--ease-out), box-shadow 160ms ease; }
.opt:active { transform: scale(0.98); }
.opt.is-picked { box-shadow: inset 0 0 0 1.5px var(--accent); background-color: var(--surface-2); }
.step.is-locked .opt { pointer-events: none; }
.spin { display: block; margin-bottom: 22px; }
.spin .tile { animation: pulse 1.8s ease-in-out infinite; }
@keyframes pulse { 50% { transform: scale(1.08); } }
.meter { display: block; height: 8px; margin: 22px 0 16px; border-radius: 4px; background: var(--surface-2); overflow: hidden; }
.meter i { display: block; height: 100%; background: linear-gradient(90deg, var(--cta-1), var(--cta-2)); transform-origin: left; transform: scaleX(0); }
@keyframes fill { to { transform: scaleX(1); } }
.is-active .meter i { animation: fill 2400ms linear forwards; }
.status { display: grid; }
.status [data-line] { grid-area: 1 / 1; opacity: 0; transition: opacity 200ms ease; }
.status [data-line].is-on { opacity: 1; }
html:not(.js) .status [data-line] { display: none; }
.cands { display: grid; gap: 10px; margin: 20px 0 6px; }
.cand { display: flex; align-items: center; gap: 14px; padding: 10px; border-radius: 24px; }
.cand b { display: block; font-size: 17px; }
.is-active .cand { animation: rise 360ms var(--ease-out) backwards; }
.is-active .cand:nth-child(2) { animation-delay: 70ms; }
.is-active .cand:nth-child(3) { animation-delay: 140ms; }

/* topics (template "characters") */
.cast { display: grid; gap: 12px; margin: 22px 0 8px; }
.card { position: relative; display: flex; align-items: center; gap: 14px; padding: 12px 14px 12px 12px; border-radius: 24px; color: var(--ink); text-decoration: none; touch-action: manipulation; transition: transform 160ms var(--ease-out), box-shadow 160ms ease; }
.card:active { transform: scale(0.98); }
.card-text { flex: 1; min-width: 0; }
.card-text b { display: block; font-size: 18px; }
.tick { flex: none; color: var(--accent); opacity: 0; transform: scale(0.8); transition: opacity 160ms ease, transform 200ms var(--ease-out); }
.tick-bg { fill: none; }
.card.is-selected { box-shadow: inset 0 0 0 2px var(--accent); background-color: var(--surface-2); }
.card.is-selected .tick { opacity: 1; transform: scale(1); }
.btn [data-label] { display: block; transition: opacity 140ms ease, filter 140ms ease; }
.btn [data-label].is-swap { opacity: 0; filter: blur(2px); }

/* steps */
.track { position: relative; display: flex; gap: 12px; margin: 22px 0 -12px; padding: 4px 0 24px; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; overscroll-behavior-x: contain; }
.track::-webkit-scrollbar { display: none; }
.slide { position: relative; flex: 0 0 84%; scroll-snap-align: center; min-height: 290px; padding: 26px 24px; border-radius: 30px; }
.slide .tile { margin-bottom: 38px; }
.slide-num { position: absolute; top: 18px; right: 24px; font: 800 58px/1 var(--sans); color: transparent; -webkit-text-stroke: 1px var(--line); }
.slide h2 { margin-bottom: 8px; }
.slide .muted { font-size: 16px; }
.dots { display: flex; justify-content: center; gap: 8px; margin: 10px 0 4px; }
.dots i { width: 8px; height: 8px; border-radius: 50%; background: var(--muted); opacity: 0.3; transition: opacity 200ms ease, transform 200ms var(--ease-out); }
.dots i.is-on { opacity: 1; transform: scale(1.25); background: var(--accent); }

/* Gesture pages: every gesture has a visible hint and a plain link; without JS only the link stays. */
html:not(.js) .gesture-block, .no-gesture .gesture-block { display: none; }
.nojs { display: inline; }
.onjs { display: none; }
.js .pl:not(.is-done) .alt { min-height: 44px; color: var(--muted); background: transparent; box-shadow: none; font-size: 15px; font-weight: 600; text-decoration: underline; text-underline-offset: 3px; }
.js .pl:not(.is-done) .alt::after { display: none; }
.js .pl:not(.is-done) .alt .nojs { display: none; }
.js .pl:not(.is-done) .alt .onjs { display: inline; }
@media (hover: hover) and (pointer: fine) { .js .pl:not(.is-done) .alt:hover { color: var(--ink); filter: none; } }
.stage { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding-bottom: 8px; }
.stage h1 { margin-top: 18px; }
.gesture-block { width: 100%; margin-top: 30px; }

/* slide */
.slide-track { position: relative; height: 64px; border-radius: 32px; overflow: hidden; }
.slide-fill { position: absolute; inset: 0; border-radius: inherit; background: linear-gradient(90deg, rgb(255 255 255 / 0.04), var(--cta-glow)); transform: translate3d(-100%, 0, 0); }
.slide-label { position: absolute; inset: 0; display: grid; place-items: center; padding-left: 52px; font-weight: 650; color: var(--muted); }
.slide-handle { position: absolute; top: 4px; left: 4px; display: grid; place-items: center; width: 56px; height: 56px; border-radius: 50%; color: var(--on-cta); background: linear-gradient(135deg, var(--cta-1), var(--cta-2)); box-shadow: inset 0 1px 0 rgb(255 255 255 / 0.4), 0 6px 16px -6px var(--cta-glow); cursor: grab; touch-action: none; user-select: none; -webkit-user-select: none; -webkit-touch-callout: none; animation: nudge 1200ms var(--ease-out) 900ms 2; }
.slide-handle:focus-visible { outline: 2px solid var(--cta-1); outline-offset: 3px; }
.slide-track:not(.is-dragging) :is(.slide-handle, .slide-fill) { transition: transform 360ms var(--spring); }
.slide-track:not(.is-dragging) .slide-label { transition: opacity 240ms ease; }
.slide-track.is-dragging .slide-handle { animation: none; cursor: grabbing; }
@keyframes nudge { 40% { transform: translate3d(14px, 0, 0); } }

/* hold */
.hold-wrap { display: grid; justify-items: center; gap: 26px; }
.hold { position: relative; width: 176px; height: 176px; padding: 0; border: 0; border-radius: 50%; background: none; color: var(--on-cta); font: inherit; cursor: pointer; touch-action: none; user-select: none; -webkit-user-select: none; -webkit-touch-callout: none; }
.hold:focus-visible { outline: 2px solid var(--cta-1); outline-offset: 4px; }
.hold-pulse { position: absolute; inset: 12px; border-radius: 50%; background: var(--cta-glow); animation: halo 2.8s ease-out infinite; }
@keyframes halo { from { opacity: 0.8; transform: scale(1); } to { opacity: 0; transform: scale(1.5); } }
.hold-ring { position: absolute; inset: 0; width: 100%; height: 100%; transform: rotate(-90deg); fill: none; stroke-width: 6; }
.ring-bg { stroke: var(--surface-2); }
.ring-fg { stroke: url(#hg); stroke-linecap: round; stroke-dasharray: 528; stroke-dashoffset: 528; transition: stroke-dashoffset 260ms var(--ease-out); }
.stop-a { stop-color: var(--cta-1); }
.stop-b { stop-color: var(--cta-2); }
.hold-core { position: absolute; inset: 14px; display: grid; place-items: center; border-radius: 50%; background: linear-gradient(135deg, var(--cta-1), var(--cta-2)); box-shadow: inset 0 1px 0 rgb(255 255 255 / 0.4), 0 14px 34px -12px var(--cta-glow); font-size: 20px; font-weight: 700; transition: transform 200ms var(--ease-out); }
.hold-wrap.is-holding .hold-core { transform: scale(0.93); }
.hold-wrap.is-holding .ring-fg { stroke-dashoffset: 0; transition: stroke-dashoffset 1200ms linear; }
.hold-wrap.is-holding .hold-pulse { animation: none; opacity: 0; }
.hold-wrap.is-done .hold-core { transform: scale(1.04); }
.hold-notes { display: grid; margin: 0; }
.hold-notes span { grid-area: 1 / 1; transition: opacity 160ms ease; }
.note-b { opacity: 0; }
.hold-wrap.is-holding .note-a { opacity: 0; }
.hold-wrap.is-holding .note-b { opacity: 1; }

/* reveal */
.reveal { position: relative; aspect-ratio: 4 / 4.6; margin-top: 22px; border-radius: 30px; overflow: hidden; touch-action: none; user-select: none; -webkit-user-select: none; -webkit-touch-callout: none; cursor: grab; box-shadow: inset 0 0 0 1px var(--line); }
.reveal:focus-visible { outline: 2px solid var(--cta-1); outline-offset: 3px; }
.reveal-img { position: absolute; inset: 0; }
.reveal-cap { position: absolute; inset: auto 0 0; display: grid; gap: 4px; padding: 64px 22px 22px; color: #fff; background: linear-gradient(to top, rgb(0 0 0 / 0.7), rgb(0 0 0 / 0)); }
.cap-label { font-size: 12px; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; opacity: 0.85; }
.cap-topic { font: 760 32px/1.05 var(--sans); letter-spacing: -0.03em; }
.cap-text { font-size: 15px; line-height: 1.4; opacity: 0.92; }
.fog { position: absolute; inset: 0; width: 100%; height: 100%; transition: opacity 420ms ease-out; }
.fog-hint { z-index: 1; position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; gap: 10px; margin: 0; width: auto; font-size: 18px; font-weight: 680; color: #fff; text-shadow: 0 1px 12px rgb(0 0 0 / 0.35); pointer-events: none; transition: opacity 200ms ease; }
.reveal.is-started .fog-hint { opacity: 0; }
.reveal.is-revealed .fog { opacity: 0; pointer-events: none; }
.reveal.is-revealed .fog-hint { display: none; }

/* pull */
.pull-stage { position: relative; flex: 1; min-height: 400px; margin: 18px calc(var(--pad) * -1) 0; overflow: hidden; }
.sheet { --peek: 138px; position: absolute; inset: 0; display: flex; flex-direction: column; border-radius: 30px 30px 0 0; background: var(--sheet); box-shadow: inset 0 1px 0 var(--line), 0 -14px 40px rgb(0 0 0 / 0.25); transform: translate3d(0, calc(100% - var(--peek)), 0); }
.sheet { user-select: none; -webkit-user-select: none; }
.sheet:not(.is-dragging) { transition: transform 420ms var(--spring); }
.sheet.is-open { transform: none; }
.grip { display: grid; justify-items: center; align-content: start; gap: 10px; height: var(--peek); margin: 0 var(--pad); padding-top: 10px; cursor: grab; touch-action: none; user-select: none; -webkit-user-select: none; -webkit-touch-callout: none; }
.grip:focus-visible { outline: 2px solid var(--cta-1); outline-offset: -4px; border-radius: 28px; }
.grip-bar { width: 44px; height: 5px; border-radius: 3px; background: var(--line); }
.grip-hint { display: flex; align-items: center; gap: 4px; width: auto; margin: 0; font-size: 14px; font-weight: 650; color: var(--accent); animation: bob 1600ms ease-in-out infinite; }
.sheet.is-open .grip-hint { opacity: 0; animation: none; }
@keyframes bob { 50% { transform: translate3d(0, -4px, 0); } }
.sheet-title { font: 740 22px/1.2 var(--sans); letter-spacing: -0.02em; text-align: center; padding: 0 20px; }
.sheet-list { display: grid; gap: 10px; padding: 8px var(--pad) 20px; }
html:not(.js) .sheet, .no-gesture .sheet { position: static; transform: none; border-radius: 30px; }
html:not(.js) .pull-stage, .no-gesture .pull-stage { min-height: 0; margin: 18px 0 0; overflow: visible; }
html:not(.js) .grip, .no-gesture .grip { height: auto; margin: 0; padding-bottom: 8px; }

/* drag */
.drag-area { margin-top: 22px; }
.zone { display: grid; align-content: center; min-height: 190px; padding: 16px; border-radius: 28px; box-shadow: inset 0 0 0 1.5px var(--line); background-image: none; transition: box-shadow 160ms ease, background-color 160ms ease; }
.zone.is-over { box-shadow: inset 0 0 0 2px var(--accent); background-color: var(--surface-2); }
.zone-hint { display: flex; flex-direction: column; align-items: center; gap: 10px; text-align: center; font-weight: 650; color: var(--muted); }
.zone-hint .ico { width: 30px; height: 30px; opacity: 0.8; }
.zone.is-filled .zone-hint { display: none; }
.zone-log { display: flex; flex-direction: column; gap: 8px; }
.zone-log .msg { max-width: 90%; }
.tray { display: grid; gap: 10px; margin-top: 16px; }
.tcard { display: flex; align-items: center; gap: 14px; min-height: 62px; padding: 0 16px 0 12px; border-radius: 20px; font-weight: 650; font-size: 16.5px; cursor: grab; touch-action: none; user-select: none; -webkit-user-select: none; -webkit-touch-callout: none; position: relative; transition: transform 360ms var(--spring), opacity 200ms ease, box-shadow 160ms ease; }
.tcard:focus-visible { outline: 2px solid var(--cta-1); outline-offset: 3px; }
.grab { margin-left: auto; width: 14px; height: 14px; background: radial-gradient(circle, var(--muted) 1.4px, transparent 1.6px) 0 0 / 7px 7px; opacity: 0.7; }
.tcard.is-lifted { z-index: 5; transition: none; box-shadow: inset 0 0 0 1.5px var(--accent), 0 18px 34px -10px rgb(0 0 0 / 0.55); cursor: grabbing; }
.tcard.is-flying { z-index: 5; transition: transform 260ms var(--ease-out), opacity 260ms ease-out; opacity: 0; }
.tcard.is-spent { opacity: 0.4; pointer-events: none; }

/* mood */
.mood-card { margin-top: 22px; border-radius: 30px; overflow: hidden; }
.mood-art { position: relative; height: 160px; overflow: hidden; }
.fx-a, .fx-b { position: absolute; inset: 0; }
.fx-a { background: var(--mood-a); }
.fx-b { background: var(--mood-b); opacity: 0.5; }
.orb { position: absolute; left: 50%; top: 50%; display: grid; place-items: center; width: 84px; height: 84px; margin: -42px 0 0 -42px; border-radius: 50%; color: #fff; background: rgb(255 255 255 / 0.22); box-shadow: inset 0 0 0 1px rgb(255 255 255 / 0.5), 0 10px 30px rgb(0 0 0 / 0.2); }
.orb .ico { width: 34px; height: 34px; }
.mood-body { padding: 18px 20px 22px; min-height: 108px; }
.mood-body .muted { margin-top: 6px; font-size: 15px; }
.mood-slider { margin-top: 18px; }
.range { display: block; width: 100%; height: 44px; margin: 0; background: transparent; -webkit-appearance: none; appearance: none; touch-action: pan-y; cursor: grab; }
.range:focus-visible { outline: 2px solid var(--cta-1); outline-offset: 2px; border-radius: 8px; }
.range::-webkit-slider-runnable-track { height: 8px; border-radius: 4px; background: linear-gradient(90deg, var(--cta-1), var(--cta-2)); }
.range::-moz-range-track { height: 8px; border-radius: 4px; background: linear-gradient(90deg, var(--cta-1), var(--cta-2)); }
.range::-webkit-slider-thumb { -webkit-appearance: none; width: 32px; height: 32px; margin-top: -12px; border: 0; border-radius: 50%; background: #fff; box-shadow: 0 0 0 4px var(--cta-glow), 0 4px 12px rgb(0 0 0 / 0.35); }
.range::-moz-range-thumb { width: 28px; height: 28px; border: 0; border-radius: 50%; background: #fff; box-shadow: 0 0 0 4px var(--cta-glow), 0 4px 12px rgb(0 0 0 / 0.35); }
.range-labels { display: flex; justify-content: space-between; font-size: 13.5px; font-weight: 650; color: var(--muted); }

.intent-hint:not([hidden]) { display: block !important; }
.intent-hint { position: static !important; opacity: 1 !important; visibility: visible !important; margin: 0 var(--pad) 8px; padding: 10px 14px; border-radius: 12px; background: var(--surface-2); box-shadow: inset 0 0 0 1px var(--line); font-size: 13.5px; line-height: 1.4; text-align: center; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-delay: 0ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; scroll-behavior: auto !important; }
  .aurora i, .orbit-ring, .sat, .hold-pulse, .grip-hint, .spin .tile { animation: none !important; }
}

/* One-action pages: the gesture is the only way on (and Enter/Space); the plain button shows without JS or without Pointer Events */
.gesture-fallback { display: none; }
html:not(.js) .gesture-fallback, .no-gesture .gesture-fallback { display: block; }
@media (prefers-reduced-motion: reduce) { .hold-wrap.is-holding .ring-fg { stroke-dashoffset: 528; } }

.mark-card { width: 88px; height: 88px; border-radius: 26px; box-shadow: 0 0 0 1px rgb(255 255 255 / 0.18), 0 16px 40px -12px var(--cta-glow); }
.mark-card .ico { width: 38px; height: 38px; }
.flick-hint { display: flex; align-items: center; justify-content: center; gap: 8px; margin-top: 22px; font-size: 14px; font-weight: 600; text-align: center; }
.flick-hint .ico { width: 20px; height: 20px; }
.flick-area, .cord-area, .dial-area, .toggle-area, .snap-area, .trace-area { display: flex; flex: 1; flex-direction: column; align-items: center; justify-content: center; margin-top: 0; padding-bottom: 5vh; }

/* swipe / swipeup: one card, flicked away sideways or up; a faint stack sits behind it */
.deck { position: relative; width: 100%; height: 300px; }
.deck-up { height: 380px; }
.deck::before, .deck::after { content: ""; position: absolute; left: 0; right: 0; top: 0; bottom: 0; border-radius: 30px; background: var(--surface-2); box-shadow: inset 0 0 0 1px var(--line); }
.deck::before { transform: translate3d(0, 12px, 0) scale(0.95); opacity: 0.7; }
.deck::after { transform: translate3d(0, 24px, 0) scale(0.9); opacity: 0.4; }
.flick-card { position: absolute; inset: 0; z-index: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; padding: 24px; border-radius: 30px; text-align: center; touch-action: none; user-select: none; -webkit-user-select: none; -webkit-touch-callout: none; cursor: grab; background-color: var(--sheet); transform-origin: 50% 90%; transition: transform 380ms var(--spring), opacity 260ms ease; will-change: transform; }
.flick-card.is-dragging { transition: none; cursor: grabbing; }
.flick-card.is-leaving { transition: transform 300ms var(--ease-out), opacity 300ms ease; opacity: 0; }
.flick-card:focus-visible { outline: 2px solid var(--cta-1); outline-offset: 3px; }
.flick-title { font: 760 28px/1.1 var(--sans); letter-spacing: -0.03em; }
.deck-up .flick-card { background-image: var(--mood-a); background-blend-mode: soft-light; }

/* cord: a bead on a cord above a dark card; pull it down and the card lights up */
.cord-stage { position: relative; display: flex; flex-direction: column; align-items: center; width: 100%; height: 360px; }
.cord-anchor { width: 18px; height: 6px; border-radius: 3px; background: var(--line); }
.cord-line { width: 2px; height: 90px; background: linear-gradient(var(--line), var(--muted)); transform-origin: top; transition: transform 420ms var(--spring); }
.cord-bead { position: relative; z-index: 2; display: block; width: 44px; height: 44px; margin-top: -2px; border-radius: 50%; background: linear-gradient(135deg, var(--cta-1), var(--cta-2)); box-shadow: inset 0 1px 0 rgb(255 255 255 / 0.5), 0 8px 18px -6px var(--cta-glow); cursor: grab; touch-action: none; user-select: none; -webkit-user-select: none; -webkit-touch-callout: none; transition: transform 420ms var(--spring); }
.cord-bead::after { content: ""; position: absolute; inset: -12px; }
.cord-bead:focus-visible { outline: 2px solid var(--cta-1); outline-offset: 4px; }
.cord-stage.is-dragging :is(.cord-line, .cord-bead) { transition: none; cursor: grabbing; }
.lamp { position: absolute; left: 0; right: 0; bottom: 0; height: 190px; display: grid; place-items: center; border-radius: 30px; overflow: hidden; }
.lamp::before { content: ""; position: absolute; inset: 0; background: radial-gradient(closest-side at 50% 45%, var(--cta-glow), transparent); opacity: 0; transition: opacity 360ms ease-out; }
.lamp .mark { position: relative; opacity: 0.3; transform: scale(0.92); transition: opacity 360ms ease-out, transform 360ms var(--spring); }
.lamp.is-lit::before { opacity: 1; }
.lamp.is-lit .mark { opacity: 1; transform: scale(1.06); }

/* dial: a round knob turned clockwise through 270 degrees */
.dial { position: relative; width: 220px; height: 220px; touch-action: none; user-select: none; -webkit-user-select: none; -webkit-touch-callout: none; cursor: grab; border-radius: 50%; }
.dial:focus-visible { outline: 2px solid var(--cta-1); outline-offset: 6px; }
.dial-arc { position: absolute; inset: 0; width: 100%; height: 100%; fill: none; stroke-width: 7; stroke-linecap: round; }
.dial-arc circle { transform-box: fill-box; transform-origin: center; transform: rotate(135deg); stroke-dasharray: 434 579; }
.arc-bg { stroke: var(--surface-2); }
.arc-fg { stroke: url(#dg); stroke-dashoffset: 434; }
.dial.is-lit .arc-fg { filter: drop-shadow(0 0 6px var(--cta-glow)); }
.knob { position: absolute; inset: 24px; border-radius: 50%; background: linear-gradient(160deg, var(--surface-2), rgb(255 255 255 / 0.02)), var(--sheet); box-shadow: inset 0 0 0 1px var(--line), inset 0 1px 0 rgb(255 255 255 / 0.2), var(--shadow); transform: rotate(-135deg); transition: transform 420ms var(--spring); will-change: transform; }
.knob-mark { position: absolute; top: 14px; left: 50%; width: 10px; height: 26px; margin-left: -5px; border-radius: 5px; background: linear-gradient(var(--cta-1), var(--cta-2)); box-shadow: 0 0 12px var(--cta-glow); }
.dial.is-dragging .knob, .dial.is-dragging .arc-fg { transition: none; }
.arc-fg { transition: stroke-dashoffset 420ms var(--spring); }

/* toggle: a big switch, dragged or tapped to ON */
.switch { position: relative; width: 220px; height: 112px; border-radius: 56px; overflow: hidden; touch-action: none; user-select: none; -webkit-user-select: none; -webkit-touch-callout: none; cursor: pointer; background-color: var(--surface-2); box-shadow: inset 0 0 0 1px var(--line); }
.switch:focus-visible { outline: 2px solid var(--cta-1); outline-offset: 4px; }
.switch-fill { position: absolute; inset: 0; background: linear-gradient(135deg, var(--cta-1), var(--cta-2)); opacity: 0; }
.switch-label { position: absolute; top: 0; bottom: 0; display: grid; place-items: center; font-size: 17px; font-weight: 720; letter-spacing: 0.04em; text-transform: uppercase; pointer-events: none; }
.switch-label.off { right: 28px; color: var(--muted); }
.switch-label.on { left: 28px; color: var(--on-cta); opacity: 0; transition: opacity 200ms ease; }
.switch.is-on .switch-label.on { opacity: 1; }
.switch.is-on .switch-label.off { opacity: 0; }
.switch-knob { position: absolute; top: 8px; left: 8px; display: grid; place-items: center; width: 96px; height: 96px; border-radius: 50%; color: var(--ink); background: #fff; box-shadow: 0 6px 18px rgb(0 0 0 / 0.35); transition: transform 420ms var(--spring); will-change: transform; }
.switch-knob .ico { width: 34px; height: 34px; color: #1c2430; }
.switch-fill { transition: opacity 420ms var(--spring); }
.switch.is-dragging :is(.switch-knob, .switch-fill) { transition: none; }

/* dock (template "dock"): drag the app icon into the glowing circle */
.snap-area { gap: 0; }
.snap-target { position: relative; display: grid; place-items: center; width: 150px; height: 150px; border-radius: 50%; color: var(--accent); }
.snap-target::before { content: ""; position: absolute; inset: 0; border-radius: 50%; border: 2px dashed var(--accent); opacity: 0.7; animation: spin 40s linear infinite; }
.snap-target::after { content: ""; position: absolute; inset: -26px; border-radius: 50%; background: radial-gradient(closest-side, var(--cta-glow), transparent); opacity: 0.5; transition: opacity 200ms ease; z-index: -1; }
.snap-target .ico { width: 34px; height: 34px; opacity: 0.6; }
.snap-target.is-over::after, .snap-target.is-lit::after { opacity: 1; }
.snap-icon { margin-top: 56px; touch-action: none; user-select: none; -webkit-user-select: none; -webkit-touch-callout: none; cursor: grab; transition: transform 380ms var(--spring); will-change: transform; border-radius: 26px; }
.snap-icon:focus-visible { outline: 2px solid var(--cta-1); outline-offset: 6px; }
.snap-icon.is-dragging { transition: none; cursor: grabbing; z-index: 3; }
.snap-icon.is-snapped { transition: transform 260ms var(--ease-out); }

/* trace: a finger runs along the dotted path from dot to dot */
.trace { display: block; width: 100%; max-width: 340px; height: auto; touch-action: none; user-select: none; -webkit-user-select: none; -webkit-touch-callout: none; overflow: visible; }
.trace:focus:not(:focus-visible) { outline: none; }
.trace:focus-visible { outline: 2px solid var(--cta-1); outline-offset: 6px; border-radius: 20px; }
.trace-bg { fill: none; stroke: var(--muted); stroke-width: 4; stroke-linecap: round; stroke-dasharray: 2 12; opacity: 0.7; }
.trace-fg { fill: none; stroke: url(#tg); stroke-width: 7; stroke-linecap: butt; stroke-dasharray: 1000; stroke-dashoffset: 1000; filter: drop-shadow(0 0 6px var(--cta-glow)); }
.trace-fg:not(.is-dragging) { transition: stroke-dashoffset 380ms var(--spring); }
.trace-start { fill: var(--cta-1); }
.trace-end { fill: none; stroke: var(--accent); stroke-width: 3; }
.trace-end.is-lit { fill: var(--cta-2); }
.tr-a { stop-color: var(--cta-1); }
.tr-b { stop-color: var(--cta-2); }
