/* 清洗導航 (order/cleaning/index.html): the repair walkthrough's frame (css/order.css) in the cleaning
 * site's light mint (Eddie 2026-10-05: repair is all dark; cleaning is the new light water-green).
 * Palette from sites/cleaning/css/clean.css. Type as on the repair page: reading text never under
 * 16px on phones. Phones: words on top, the picture under them, a thumb nav at the bottom with
 * Fixes Baby in its right corner. Desktop: words left, picture right. */

:root {
  --bg: #e4f3ee;
  --surface: #f2faf7;
  --ink: #0f2a2e;
  --ink-2: #33504f;
  --ink-3: #5c7774;
  --line: #c6e0d7;
  --accent: #0e9f97;
  --accent-deep: #0b7f79;
  --soft: #cfeee6;
  --addon: #ffd76a;
  --grime: #7a5a34;
  --warn: #e5533d;
  --win: #072328;
  --glass: rgba(242, 250, 247, 0.82);
  --cta: linear-gradient(100deg, #0e9f97 0%, #14b8a6 55%, #3cc9b8 100%);
  --cta-glow: 0 0 0 1px rgba(14, 159, 151, 0.35), 0 12px 34px -10px rgba(14, 140, 132, 0.55);
  --sans: "Noto Sans TC", "PingFang HK", "PingFang TC", "Microsoft JhengHei", system-ui, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, monospace;
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
  --pop: cubic-bezier(0.34, 1.56, 0.64, 1);
  --safe-t: env(safe-area-inset-top, 0px);
  --safe-b: env(safe-area-inset-bottom, 0px);
  --nav-h: 72px;
  --top-h: 60px;
  --baby: 80px;
  --fxc-bottom: calc(var(--safe-b) + 4px);
  --fxc-right: 12px;
  color-scheme: light;
}
.fxc-teaser { display: none !important; }

* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; overflow: hidden; background: var(--bg); color: var(--ink); font-family: var(--sans); -webkit-font-smoothing: antialiased; }
body { overscroll-behavior: none; -webkit-tap-highlight-color: transparent; -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; }
img, svg { -webkit-user-drag: none; }
button { font: inherit; color: inherit; -webkit-user-select: none; user-select: none; }
h1, h2, h3 { margin: 0; }

/* ---------------------------------------------------------------- */
/* Background: mint with soft light, a faint water grid in the steps   */
/* ---------------------------------------------------------------- */

.bg { position: fixed; inset: 0; background: linear-gradient(170deg, #eef9f5 0%, #e4f3ee 55%, #d9efe8 100%); }
.bg i { position: absolute; border-radius: 50%; filter: blur(70px); opacity: 0.55; }
.bg-a { width: 70vmax; height: 70vmax; left: -28vmax; top: -36vmax; background: radial-gradient(circle, #bff3ea 0%, transparent 62%); }
.bg-b { width: 70vmax; height: 70vmax; right: -28vmax; bottom: -40vmax; background: radial-gradient(circle, #c9f0ff 0%, transparent 62%); }
body[data-part="flow"] .bg::after { content: ""; position: absolute; inset: 0; background-image: linear-gradient(rgba(14, 120, 115, 0.06) 1px, transparent 1px), linear-gradient(90deg, rgba(14, 120, 115, 0.06) 1px, transparent 1px); background-size: 36px 36px; mask-image: radial-gradient(80% 70% at 50% 50%, #000 30%, transparent 100%); -webkit-mask-image: radial-gradient(80% 70% at 50% 50%, #000 30%, transparent 100%); }

.flash { position: fixed; inset: 0; z-index: 30; pointer-events: none; opacity: 0; background: radial-gradient(circle at 50% 45%, #ffffff 0%, rgba(220, 255, 248, 0.8) 30%, rgba(160, 240, 230, 0) 70%); }
.flash.go { animation: flash 1s var(--ease) forwards; }
@keyframes flash { 0% { opacity: 0; } 18% { opacity: var(--a, 0.6); } 100% { opacity: 0; } }

/* ---------------------------------------------------------------- */
/* Fixes Baby: the end folds into it                                   */
/* ---------------------------------------------------------------- */

body.collapsing :is(.end-copy, .bg, .top, .nav) { transform-origin: var(--bx, 90%) var(--by, 90%); animation: suck 1s cubic-bezier(0.6, 0, 0.8, 0.3) both; }
body.collapsed :is(.end-copy, .bg, .top, .nav) { visibility: hidden; }
@keyframes suck { 0% { transform: none; opacity: 1; } 100% { transform: scale(0.02); opacity: 0; filter: blur(8px); } }
body.collapsed { background: #072d30; transition: background 0.6s; }
body.baby-glow::after { content: ""; position: fixed; z-index: 9999; left: var(--bx); top: var(--by); width: 140px; height: 140px; margin: -70px 0 0 -70px; border-radius: 50%; pointer-events: none;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.95), rgba(60, 201, 184, 0.55) 30%, rgba(110, 240, 255, 0) 70%); animation: glowpop 1s var(--ease) forwards; }
@keyframes glowpop { 0% { transform: scale(0.2); opacity: 1; } 100% { transform: scale(3.2); opacity: 0; } }
.sparks { position: fixed; inset: 0; z-index: 40; pointer-events: none; }
.sparks i { position: absolute; left: 0; top: 0; width: 10px; height: 10px; margin: -5px 0 0 -5px; border-radius: 50%; background: #fff; box-shadow: 0 0 12px 4px rgba(60, 201, 184, 0.8), 0 0 30px 8px rgba(110, 220, 255, 0.5); opacity: 0;
  animation: spark 1.1s cubic-bezier(0.3, 0, 0.3, 1) both; }
@keyframes spark { 0% { transform: translate(var(--x0), var(--y0)) scale(0.4); opacity: 0; } 20% { opacity: 1; } 100% { transform: translate(var(--x1), var(--y1)) scale(1.2); opacity: 0; } }

/* ---------------------------------------------------------------- */
/* Top bar and bottom nav                                             */
/* ---------------------------------------------------------------- */

.top { position: fixed; z-index: 20; top: 0; left: 0; right: 0; height: calc(var(--top-h) + var(--safe-t)); padding: var(--safe-t) 16px 0; display: flex; align-items: center; gap: 14px; }
.logo { flex: none; display: block; }
.logo img { display: block; height: 28px; width: auto; }
.track { flex: 1; display: flex; max-width: 300px; margin-left: auto; }
.track i { flex: 1; height: 2px; background: rgba(14, 100, 95, 0.16); transition: background 0.4s; }
.track i.done { background: rgba(14, 159, 151, 0.6); }
.track i.now { height: 3px; border-radius: 3px; background: var(--accent); box-shadow: 0 0 8px rgba(14, 159, 151, 0.6); }
.top-btn { flex: none; min-height: 40px; border: 1px solid var(--line); background: var(--glass); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border-radius: 99px; padding: 8px 14px; font-size: 15px; font-weight: 700; color: var(--ink); cursor: pointer; }
.top-btn .short, .top-btn .tiny { display: none; }
.lang { flex: none; display: flex; padding: 3px; gap: 2px; border-radius: 99px; border: 1px solid var(--line); background: var(--glass); }
.lang button { min-width: 34px; height: 30px; padding: 0 8px; border: 0; border-radius: 99px; background: none; font-size: 13px; font-weight: 700; color: var(--ink-2); cursor: pointer; }
.lang button[aria-pressed="true"] { background: var(--accent); color: #fff; }
.snd { flex: none; display: inline-flex; align-items: center; gap: 6px; min-height: 36px; padding: 0 12px 0 10px; border-radius: 99px; border: 1px solid var(--line); background: var(--glass); color: var(--ink-2); font-size: 13px; font-weight: 700; cursor: pointer; }
.snd svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; }
.snd .spk { fill: currentColor; stroke: none; }
.snd .waves { display: none; }
.snd.on { color: #fff; background: var(--accent); border-color: transparent; }
.snd.on .waves { display: inline; }
.snd.on .mute { display: none; }

.nav { position: fixed; z-index: 20; left: 0; right: 0; bottom: 0; height: calc(var(--nav-h) + var(--safe-b)); padding: 0 var(--baby) var(--safe-b) 14px; display: flex; align-items: center; gap: 10px; transition: opacity 0.4s; }
body[data-part="hero"] .nav, body[data-part="end"] .nav { opacity: 0; pointer-events: none; }
.nav-btn { position: relative; width: 50px; height: 50px; flex: none; padding: 0; border-radius: 50%; border: 1px solid var(--line); background: rgba(255, 255, 255, 0.85); color: var(--ink); cursor: pointer; display: grid; place-items: center; transition: transform 0.15s, opacity 0.3s; }
.nav-btn:active { transform: scale(0.94); }
.nav-btn > svg { width: 24px; height: 24px; display: block; fill: none; stroke: currentColor; stroke-width: 2.6; stroke-linecap: round; stroke-linejoin: round; }
.nav-btn.next { background: var(--cta); color: #fff; border: 0; box-shadow: var(--cta-glow); }
/* In the steps the next button breathes once the step has played: the reader moves on by hand. */
body[data-part="flow"]:not(.last-flow) .nav-btn.next { animation: nudge 2.6s 3s var(--ease) infinite; }
@keyframes nudge { 0%, 70%, 100% { transform: none; } 80% { transform: translateX(4px) scale(1.06); } 90% { transform: none; } }
.nav-btn:disabled { opacity: 0.3; cursor: default; }
.nav-btn.play { width: 58px; height: 58px; border: 0; background: var(--ink); color: #fff; }
.play .ring { position: absolute; inset: 0; width: 100%; height: 100%; transform: rotate(-90deg); pointer-events: none; }
.play .ring circle { fill: none; stroke-width: 3; }
.play .ring-bg { stroke: rgba(255, 255, 255, 0.2); }
.play .ring-fg { stroke: #5eead4; stroke-linecap: round; stroke-dasharray: 157.08; stroke-dashoffset: 157.08; }
.nav:not(.auto) .play .ring-fg { opacity: 0; }
.play .ico { position: absolute; left: 50%; top: 50%; width: 22px; height: 22px; margin: -11px 0 0 -11px; fill: #fff; stroke: none; transition: opacity 0.2s, transform 0.25s var(--pop); }
.play .ico-play { opacity: 0; transform: scale(0.6); margin-left: -10px; }
.play.is-paused .ico-pause { opacity: 0; transform: scale(0.6); }
.play.is-paused .ico-play { opacity: 1; transform: none; }
.play.is-paused { box-shadow: 0 0 0 3px #5eead4; }
.nav-mid { flex: 1; min-width: 0; display: flex; flex-direction: column; align-items: flex-start; gap: 2px; margin-left: 4px; font-size: 15px; line-height: 1.25; color: var(--ink-2); }
#navLabel { display: flex; flex-direction: column; }
.nav-mid b { font-weight: 700; color: var(--ink); white-space: nowrap; }
.nav-mid small { font-size: 14px; white-space: nowrap; }
.nav-state { display: none; font-size: 13px; font-weight: 700; color: var(--accent-deep); }
body.paused .nav-state { display: block; }
body.paused *, body.paused *::before, body.paused *::after { animation-play-state: paused !important; }
.pause-flash { position: fixed; z-index: 30; left: 50%; top: 45%; width: 88px; height: 88px; margin: -44px 0 0 -44px; border-radius: 50%; background: rgba(15, 42, 46, 0.55); backdrop-filter: blur(8px); display: grid; place-items: center; opacity: 0; pointer-events: none; }
.pause-flash svg { grid-area: 1 / 1; width: 40px; height: 40px; fill: #fff; }
.pause-flash .ico-play, .pause-flash.is-paused .ico-pause { display: none; }
.pause-flash.is-paused .ico-play { display: block; }
.pause-flash.go { animation: pause-flash 0.7s var(--ease) both; animation-play-state: running !important; }
@keyframes pause-flash { 0% { opacity: 0; transform: scale(0.7); } 25% { opacity: 1; transform: scale(1); } 100% { opacity: 0; transform: scale(1.25); } }

/* ---------------------------------------------------------------- */
/* Scenes and type                                                    */
/* ---------------------------------------------------------------- */

.deck { position: fixed; inset: 0; z-index: 5; }
.sc { position: absolute; inset: calc(var(--top-h) + var(--safe-t)) 0 calc(var(--nav-h) + var(--safe-b)); padding: 8px 20px 14px; display: flex; flex-direction: column; justify-content: flex-end; gap: 16px;
  opacity: 0; visibility: hidden; transition: opacity 0.5s var(--ease), visibility 0s 0.5s; }
.sc.on { opacity: 1; visibility: visible; transition: opacity 0.5s var(--ease), visibility 0s; }
.sc.overfull { justify-content: flex-start; }
.sc-hero { inset: 0; padding: calc(var(--top-h) + var(--safe-t)) 20px calc(24px + var(--safe-b)); }

.kicker { margin: 0 0 12px; font-size: 16px; letter-spacing: 0.06em; color: var(--accent-deep); font-weight: 700; display: flex; align-items: center; flex-wrap: wrap; gap: 8px 10px; }
.sc-story .kicker::before, .sc-hero .kicker::before { content: ""; width: 28px; height: 2px; background: currentColor; }
.step { min-width: 28px; height: 28px; padding: 0 6px; border-radius: 99px; display: inline-grid; place-items: center; background: var(--accent); color: #fff; font-size: 14px; letter-spacing: 0; }
.clk { font-family: var(--mono); font-size: 14px; padding: 3px 9px; border-radius: 99px; background: #fff; border: 1px solid var(--line); color: var(--ink-2); letter-spacing: 0; }
.copy h1 { font-size: clamp(40px, min(10.4vw, 12vh), 84px); line-height: 1.12; font-weight: 900; text-wrap: balance; }
.copy h2 { font-size: clamp(30px, 8.6vw, 56px); line-height: 1.2; font-weight: 900; text-wrap: balance; }
.copy p { margin: 16px 0 0; font-size: 17.5px; line-height: 1.7; color: var(--ink-2); max-width: 32em; }
.copy .lead { font-size: 18px; }
.copy > * { opacity: 0; transform: translateY(14px); transition: opacity 0.35s var(--ease), transform 0.35s var(--ease); }
.sc.told .copy > * { opacity: 1; transform: none; transition: opacity 0.7s var(--ease), transform 0.9s var(--ease); }
.sc.told .copy > *:nth-child(2) { transition-delay: 0.2s; }
.sc.told .copy > *:nth-child(3) { transition-delay: 0.45s; }
.sc.told .copy > *:nth-child(4) { transition-delay: 0.7s; }
.sc-flow.told .copy > *:nth-child(n) { transition-delay: 0s; }
.sc-flow.told .copy > *:nth-child(2) { transition-delay: 0.12s; }
.sc-flow.told .copy > *:nth-child(3) { transition-delay: 0.24s; }
html[lang="en"] .copy h1 { font-size: clamp(32px, min(8.4vw, 9.5vh), 62px); }
html[lang="ja"] .copy h1 { font-size: clamp(32px, min(8.4vw, 9.5vh), 62px); }
html[lang="en"] .copy h2, html[lang="ja"] .copy h2 { font-size: clamp(26px, 7vw, 48px); }

.cta { position: relative; min-height: 58px; border: 0; border-radius: 99px; padding: 16px 30px; font-size: 19px; font-weight: 900; letter-spacing: 0.03em; color: #fff; cursor: pointer; background: var(--cta); box-shadow: var(--cta-glow); overflow: hidden; isolation: isolate; transition: transform 0.2s var(--pop); }
.cta span { position: relative; z-index: 1; }
.cta::before { content: ""; position: absolute; inset: -2px; background: linear-gradient(115deg, transparent 30%, rgba(255, 255, 255, 0.6) 45%, transparent 60%); transform: translateX(-120%); animation: sheen 3.4s ease-in-out infinite; z-index: 0; }
@keyframes sheen { 0%, 55% { transform: translateX(-120%); } 85%, 100% { transform: translateX(120%); } }
.cta:active { transform: scale(0.97); }
.sc-ai .cta { margin-top: 20px; }

/* Ways in: big thumb-sized cards. 1 (the cleaning) is the bright one. */
.routes { display: grid; gap: 12px; margin-top: 24px; max-width: 520px; }
.route { position: relative; display: grid; grid-template-columns: auto 1fr auto; grid-template-rows: auto auto; align-items: center; column-gap: 14px; min-height: 70px; padding: 12px 14px 12px 12px; text-align: left; cursor: pointer; color: var(--ink);
  border-radius: 20px; border: 1px solid var(--line); background: rgba(255, 255, 255, 0.82); transition: border-color 0.25s, transform 0.2s var(--pop); overflow: hidden; }
.route .rn { grid-row: 1 / span 2; width: 42px; height: 42px; border-radius: 50%; display: grid; place-items: center; font-style: normal; font-size: 20px; font-weight: 900; border: 1.5px solid var(--line); color: var(--accent-deep); }
.route b { grid-column: 2; font-size: 19px; font-weight: 800; text-wrap: balance; }
.route small { grid-column: 2; font-size: 15px; color: var(--ink-3); margin-top: 2px; }
.route .ra, .route > i:last-child:not(.rn) { grid-column: 3; grid-row: 1 / span 2; width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; border: 1px solid var(--line); font-style: normal; font-size: 22px; }
.route .ra svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2.6; stroke-linecap: round; stroke-linejoin: round; }
.route:hover { border-color: var(--accent); }
.route:active { transform: scale(0.98); }
.route.r1 { min-height: 94px; border: 0; color: #fff; background: var(--cta); box-shadow: var(--cta-glow), 0 18px 46px -18px rgba(14, 159, 151, 0.7); }
.route.r1 .rn { width: 52px; height: 52px; font-size: 26px; border: 0; background: #fff; color: var(--accent-deep); }
.route.r1 b { font-size: 24px; font-weight: 900; }
.route.r1 small { color: rgba(255, 255, 255, 0.85); font-weight: 600; }
.route.r1 .ra { width: 44px; height: 44px; border: 0; background: rgba(255, 255, 255, 0.2); }
.route.r1::after { content: ""; position: absolute; inset: 0; pointer-events: none; background: linear-gradient(105deg, transparent 35%, rgba(255, 255, 255, 0.45) 50%, transparent 65%); transform: translateX(-120%); animation: sheen 3.6s 1.2s var(--ease) infinite; }

.textver { display: inline-flex; align-items: center; gap: 6px; margin-top: 14px; padding: 6px 4px; font-size: 15px; font-weight: 600; color: var(--ink-2); text-decoration: none; }
.textver svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linejoin: round; }
.textver:hover { color: var(--accent-deep); }

/* Hero: the drop, still murky, clears on its two-hour ring. */
.sc-hero { justify-content: flex-end; }
/* Sized to the space the copy leaves (cqh), not the viewport, so the ring never rides up into the header on short screens. */
.hero-drop { position: relative; flex: 1; min-height: 180px; display: flex; flex-direction: column; align-items: center; }
.hero-box { --ring: min(60vw, 94cqh, 340px); position: relative; flex: 1; width: 100%; min-height: 110px; display: grid; place-items: center; container-type: size; }
/* The drop talks, as on the cleaning site's hero: a busy phrase, then one line per stage. */
.hero-bub { position: relative; z-index: 2; width: min(100%, 420px); min-height: 64px; margin: 4px 0 14px; display: flex; align-items: center; justify-content: center; text-align: center; padding: 9px 16px; border-radius: 18px; background: #fff; border: 2px solid #16393f; box-shadow: 4px 5px 0 #16393f; }
.hero-bub::after { content: ""; position: absolute; left: 50%; bottom: -11px; width: 18px; height: 18px; margin-left: -9px; background: #fff; border-right: 2px solid #16393f; border-bottom: 2px solid #16393f; transform: rotate(45deg); }
.hero-bub p { margin: 0; font-size: 16px; font-weight: 800; line-height: 1.4; color: var(--ink); animation: bubin 0.35s var(--pop); }
.hb-busy { display: none; align-items: center; gap: 4px; color: var(--accent-deep); font-weight: 800; font-size: 15px; }
.hb-busy em { font-style: normal; margin-left: 6px; }
.hb-busy i { width: 7px; height: 7px; border-radius: 50%; background: currentColor; animation: hbdots 1s infinite; }
.hb-busy i:nth-child(2) { animation-delay: 0.15s; }
.hb-busy i:nth-child(3) { animation-delay: 0.3s; }
.hero-bub.thinking .hb-busy { display: flex; }
.hero-bub.thinking p { display: none; }
@keyframes hbdots { 0%, 60%, 100% { transform: translateY(0); opacity: 0.4; } 30% { transform: translateY(-4px); opacity: 1; } }
@keyframes bubin { from { opacity: 0; transform: translateY(4px) scale(0.97); } }
/* while the drop speaks, its hands talk too */
.drop.talk .ipa-l { animation: ipa-float 0.9s ease-in-out infinite; }
.drop.talk .ipa-r { animation: ipa-wave 0.9s ease-in-out infinite 0.2s; }
.hero-drop .drop { width: min(42vw, 62cqh, 240px); }
.hero-ring { position: absolute; width: var(--ring); height: auto; transform: rotate(-90deg); }
/* The clock on the ring's shoulder: the two hours the ring stands for, spelled out. */
.hero-clock { position: absolute; left: min(calc(50% + var(--ring) * 0.2), calc(100% - 150px)); top: calc(50% - var(--ring) * 0.38); translate: 0 -50%; display: flex; align-items: center; gap: 8px; padding: 6px 12px 6px 6px; border-radius: 99px; background: rgba(255, 255, 255, 0.92); border: 1.5px solid rgba(14, 159, 151, 0.35); box-shadow: 0 10px 24px -12px rgba(14, 80, 75, 0.55); white-space: nowrap; }
.hero-clock svg { width: 40px; height: 40px; flex: none; }
.hc-face { fill: #fff; stroke: var(--ink); stroke-width: 2.4; }
.hc-tick { stroke: var(--ink); stroke-width: 2; stroke-linecap: round; }
.hc-sweep { fill: rgba(14, 159, 151, 0.22); }
.hc-h, .hc-m { stroke: var(--ink); stroke-linecap: round; transform-origin: 24px 24px; }
.hc-h { stroke-width: 3.4; }
.hc-m { stroke-width: 2.4; stroke: var(--accent-deep); }
.hero-clock b { display: block; font: 800 20px/1 var(--mono); color: var(--ink); letter-spacing: 0.02em; }
.hero-clock small { display: block; margin-top: 3px; font-size: 12px; font-weight: 700; color: var(--ink-3); }
.hero-clock.done { border-color: var(--accent); }
.hero-clock.done b { color: var(--accent-deep); }
.hr-bg { fill: none; stroke: rgba(14, 120, 115, 0.12); stroke-width: 3; }
.hr-fg { fill: none; stroke: var(--accent); stroke-width: 3.5; stroke-linecap: round; stroke-dasharray: 100; stroke-dashoffset: 100; transition: stroke-dashoffset 0.25s linear; }
.sc-hero .copy { max-width: 680px; }

/* The drop's own moves (as on the cleaning site). */
.ip-anim svg { display: block; width: 100%; height: auto; overflow: visible; }
.ip-anim svg g { transform-box: fill-box; transform-origin: center; }
.ip-anim .ipa-body { animation: ipa-bob 2.6s ease-in-out infinite; }
.ip-anim .ipa-shadow { animation: ipa-shadow 2.6s ease-in-out infinite; }
.ip-anim .ipa-l { animation: ipa-float 1.7s ease-in-out infinite; }
.ip-anim .ipa-r { animation: ipa-wave 1.7s ease-in-out infinite 0.35s; }
.ip-anim .ipa-eyes { animation: ipa-blink 4.2s infinite; }
.ip-anim .ipa-tuft { transform-origin: 50% 100%; animation: ipa-sway 2.2s ease-in-out infinite; }
.ip-anim .ipa-spark { animation: ipa-twinkle 1.4s ease-in-out infinite; }
.ip-anim .ipa-sweat { animation: ipa-sweat 1.6s ease-in infinite; }
@keyframes ipa-bob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-6px); } }
@keyframes ipa-shadow { 0%, 100% { transform: scaleX(1); opacity: 0.12; } 50% { transform: scaleX(0.86); opacity: 0.08; } }
@keyframes ipa-float { 0%, 100% { transform: translate(0, 0); } 50% { transform: translate(-2px, -8px); } }
@keyframes ipa-wave { 0%, 100% { transform: translate(0, 0) rotate(0); } 30% { transform: translate(3px, -9px) rotate(-12deg); } 60% { transform: translate(-1px, -3px) rotate(10deg); } }
@keyframes ipa-blink { 0%, 90%, 100% { transform: scaleY(1); } 94% { transform: scaleY(0.12); } }
@keyframes ipa-sway { 0%, 100% { transform: rotate(-8deg); } 50% { transform: rotate(10deg); } }
@keyframes ipa-twinkle { 0%, 100% { opacity: 1; transform: scale(1); } 50% { opacity: 0.5; transform: scale(0.85); } }
@keyframes ipa-sweat { 0% { transform: translateY(0); opacity: 0; } 20% { opacity: 1; } 100% { transform: translateY(14px); opacity: 0; } }

/* ---------------------------------------------------------------- */
/* Part A: the story's drawings                                        */
/* ---------------------------------------------------------------- */

.sc-story .art { flex: 1; min-height: 0; display: grid; place-items: center; container-type: size; }
.sc-story .art svg { width: min(100%, 560px); max-height: 100cqh; height: auto; overflow: visible; }
.st text { font: 700 17px var(--sans); fill: var(--ink); }
.st .city .ping { fill: none; stroke: var(--accent); stroke-width: 2; transform-box: fill-box; transform-origin: center; }
.sc.on .st .city .ping { animation: ping 1.8s var(--ease) infinite; }
@keyframes ping { from { transform: scale(1); opacity: 0.9; } to { transform: scale(3.4); opacity: 0; } }
.st .route { stroke-dashoffset: 0; }
.st .flyer { offset-rotate: auto; }
.sc.on .st-japan .flyer { offset-path: path("M118 238 Q245 14 372 104"); animation: fly 2.2s 0.3s var(--ease) both; }
.sc.on .st-back .flyer { offset-path: path("M372 104 Q245 14 118 238"); animation: fly 2.2s 0.3s var(--ease) both; }
.st-ai .flyer { display: none; }
@keyframes fly { from { offset-distance: 0%; opacity: 0; } 10% { opacity: 1; } to { offset-distance: 100%; opacity: 1; } }
.st .fuji { opacity: 0.9; }
.st-ai .ci { stroke-dasharray: 8 10; }
.sc.on .st-ai .ci { animation: dash 1.4s linear infinite; animation-delay: calc(var(--i) * 0.2s); }
@keyframes dash { to { stroke-dashoffset: -36; } }
.st .chip-t { font: 900 18px var(--mono); fill: #5eead4; }
.sc.on .st-ai .chip { animation: glow 1.6s ease-in-out infinite; }
@keyframes glow { 50% { filter: drop-shadow(0 0 10px rgba(94, 234, 212, 0.9)); } }
.sc.on .st-repair .rec rect { animation: rise 0.6s var(--pop) both; }
.st-repair .rec rect:nth-child(2) { animation-delay: 0.4s !important; }
.st-repair .rec rect:nth-child(3) { animation-delay: 0.8s !important; }
@keyframes rise { from { opacity: 0; transform: translateY(20px); } }
.sc.on .st-repair .spanner { animation: turn 1.6s 0.4s var(--ease) both; transform-box: fill-box; transform-origin: 50% 90%; }
@keyframes turn { 0% { opacity: 0; rotate: -40deg; } 60% { opacity: 1; rotate: 12deg; } 100% { rotate: 0deg; } }
.st-found .gfill { stroke-dasharray: 100; stroke-dashoffset: 100; }
.sc.on .st-found .gfill { animation: gauge 1.8s 0.4s var(--ease) forwards; }
@keyframes gauge { to { stroke-dashoffset: 10; } }
.st .g-num { font: 900 34px var(--mono); fill: var(--accent-deep); }
.st .g-lbl { font-size: 15px; fill: var(--ink-2); }
.st-nodis .pt { transform-box: fill-box; }
.sc.on .st-nodis .pt { animation: apart 2.6s var(--ease) both; animation-delay: calc(var(--i) * 0.05s); }
@keyframes apart { 0% { translate: 0 0; rotate: 0deg; opacity: 0; } 12% { opacity: 1; } 35%, 62% { translate: var(--dx) var(--dy); rotate: var(--r); opacity: 1; } 100% { translate: 0 0; rotate: 0deg; opacity: 0; } }
.st-nodis .warn { opacity: 0; transform-box: fill-box; transform-origin: center; }
.st-nodis .warn text { fill: var(--warn); font-size: 16px; }
.sc.on .st-nodis .warn { animation: warn 2.6s var(--pop) both; }
.sc.on .st-nodis .w-noise { animation-delay: 0.38s; }
.sc.on .st-nodis .w-shake { animation-delay: 0.76s; }
.sc.on .st-nodis .w-loose { animation-delay: 1.14s; }
@keyframes warn { 0% { opacity: 0; scale: 0.5; } 15%, 55% { opacity: 1; scale: 1; } 75%, 100% { opacity: 0.18; scale: 0.92; } }
.st-nodis .ok { opacity: 0; }
.sc.on .st-nodis .ok { animation: ok 0.8s 2.4s var(--pop) both; transform-box: fill-box; transform-origin: center; }
@keyframes ok { from { opacity: 0; scale: 0.6; } to { opacity: 1; scale: 1; } }

/* ---------------------------------------------------------------- */
/* Part B: the steps                                                  */
/* ---------------------------------------------------------------- */

.sc-flow { justify-content: flex-start; }
.sc-flow .copy { flex: none; }
.sc-flow .vis { flex: 1; min-height: 0; display: grid; place-items: start center; position: relative; }
.vis > .fit { width: 100%; display: grid; justify-items: center; transform-origin: 50% 0; }
.sc.measure .vis > .fit { transform: none !important; margin-bottom: 0 !important; }
.duo { width: min(100%, 560px); display: grid; gap: 12px; justify-items: center; }
.note, .quote { margin: 0; width: min(100%, 460px); padding: 12px 16px; border-radius: 16px; background: #fff; border: 1px solid var(--line); box-shadow: 0 10px 30px -18px rgba(14, 100, 95, 0.5); font-size: 15.5px; line-height: 1.55; color: var(--ink-2); }
.note b { display: block; font-size: 16.5px; color: var(--ink); margin-bottom: 2px; }
.warn-note { border-color: #f6c2b6; background: #fff8f5; }
.warn-note b { color: #b23a26; }
.quote { font-weight: 700; color: var(--accent-deep); background: var(--soft); border-color: transparent; text-align: center; }
.sc.on .note, .sc.on .quote { animation: rise 0.6s 0.9s var(--pop) both; }

/* Checklists */
.chk { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; width: min(100%, 420px); }
.chk li { display: flex; align-items: center; gap: 10px; padding: 9px 12px; border-radius: 12px; background: rgba(255, 255, 255, 0.7); border: 1px solid var(--line); font-size: 16px; transition: background 0.3s, border-color 0.3s; }
.chk li i { flex: none; width: 22px; height: 22px; border-radius: 50%; border: 2px solid var(--line); display: grid; place-items: center; transition: background 0.3s, border-color 0.3s; }
.chk li.lit { background: #fff; border-color: var(--accent); }
.chk li.lit i { background: var(--accent); border-color: var(--accent); }
.chk li.lit i::after { content: ""; width: 9px; height: 5px; border: solid #fff; border-width: 0 0 2.5px 2.5px; transform: translateY(-1px) rotate(-45deg); }

/* ---------- The washer cutaway ---------- */
.wxw { position: relative; width: min(100%, 360px); --wc: #9fe3dc; }
.wx { display: block; width: 100%; height: auto; overflow: visible; }
.wx text { font: 700 14px var(--sans); fill: var(--ink); }
.wx .wx-lcd { font: 700 13px var(--mono); fill: #5eead4; }
.wx .wx-tag { font-size: 12px; fill: #fff; }
.wx-water { fill: var(--wc); opacity: 0.85; transform: translateY(280px); transition: transform 1.4s var(--ease), fill 1.2s var(--ease); }
.wx-water.in { opacity: 0.55; }
.wx-level, .wx-labels .lb, .wx-temp, .wx-pour, .wx-foam, .wx-scope, .wx-wand { opacity: 0; transition: opacity 0.5s; }
.wx-scope, .wx-wand { opacity: 1; }
.wxw.show-level .wx-level { opacity: 1; }
.wxw.level-ok .wx-level path { stroke-width: 4; filter: drop-shadow(0 0 6px rgba(14, 159, 151, 0.9)); }
.wx-labels .lb path { fill: none; stroke: var(--ink); stroke-width: 1.6; }
.wx-labels .lb text { font-size: 14px; }
.wxw.lb-drawer .lb-drawer, .wxw.lb-dhose .lb-dhose, .wxw.lb-gap .lb-gap, .wxw.lb-holes .lb-holes, .wxw.lb-sump .lb-sump, .wxw.lb-pump .lb-pump, .wxw.lb-float .lb-float { opacity: 1; }
.wx-grime { opacity: 0; transition: opacity 0.6s; }
.wx-grime path { fill: #4e3118; stroke: #24160a; stroke-width: 1.4; }
.wx-grime .gb { filter: drop-shadow(0 1px 0 rgba(255, 220, 170, 0.35)); }
.wxw.dirty .wx-grime { opacity: 1; }
.gb { transition: transform 1.2s cubic-bezier(0.5, 0, 0.8, 0.6), opacity 1.2s, filter 1s; }
.gb.soft path { fill: #8a6338; }
.gb.hit { transform: translate(var(--fx), var(--fy)); opacity: 0; }
.gb.big path { fill: #3f2711; }
.gb.shake { animation: shake 0.12s linear infinite; }
@keyframes shake { 0%, 100% { translate: 0 0; } 25% { translate: 1.5px -1px; } 75% { translate: -1.5px 1px; } }
.wx-wet { transition: opacity 1s; }
.wxw.wet .wx-wet { opacity: 0.25; }
.wx-drum { transform-box: view-box; transform-origin: 200px 236px; }
.wxw.spin .wx-drum { animation: spin 3.2s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.wxw.rock .wx-drum { animation: rock 0.5s ease-in-out 3; }
@keyframes rock { 25% { transform: rotate(-7deg); } 75% { transform: rotate(7deg); } }
.wxw.lock .wx-cab { stroke: var(--accent); }
.wxw.hot .wx-temp { opacity: 1; }
.wx-temp text { font: 900 13px var(--mono); fill: #fff; }
.wxw.pouring .wx-pour { opacity: 1; }
.wx-pour circle { fill: #fff; stroke: var(--ink); stroke-width: 1; opacity: 0; }
.wxw.pouring .wx-pour circle { animation: fall 0.8s linear infinite; animation-delay: var(--d); }
@keyframes fall { 0% { opacity: 0; transform: translateY(-10px); } 20% { opacity: 1; } 100% { opacity: 0; transform: translateY(110px); } }
.wx-bubbles circle { fill: #fff; opacity: 0; }
.wxw.fizz .wx-bubbles circle { animation: fizz 1.6s ease-in infinite; animation-delay: var(--d); }
@keyframes fizz { 0% { opacity: 0; transform: translateY(0); } 30% { opacity: 0.95; } 100% { opacity: 0; transform: translateY(-26px); } }
.wx-foam circle { fill: #fff; stroke: #a7dcd4; stroke-width: 1.4; }
.wxw.foam .wx-foam { opacity: 1; }
.wx-flow { opacity: 0; }
.wxw.draining .wx-flow { opacity: 1; animation: flow 0.6s linear infinite; stroke: var(--wc); }
@keyframes flow { to { stroke-dashoffset: -32; } }
.wxw.draining .wx-imp { animation: spin 0.4s linear infinite; transform-box: fill-box; transform-origin: center; }
.wxw.hose-flow .wx-dhose-in { stroke: #4fb6c8; stroke-dasharray: 5 9; animation: flow 0.5s linear infinite; }
.wxw.hose-flow .wx-drawer rect { stroke: var(--accent); stroke-width: 3.4; }
.wx-fball { transition: transform 0.6s var(--pop), fill 0.3s; }
.wxw.float-up .wx-fball { transform: translateY(-8px); fill: var(--warn); }
.wxw.what-if .wx-level path { stroke: var(--warn); }
.wxw.what-if .wx-lcd { fill: #ff8a7a; }
.wx-scope .beam { animation: beam 1.2s ease-in-out infinite; }
@keyframes beam { 50% { opacity: 0.25; } }
.wx-wand .spray path { stroke: #7fe3f0; stroke-width: 5; stroke-linecap: round; stroke-dasharray: 6 8; animation: flow 0.25s linear infinite; }
.wxw.focus .wx-wand .spray path { stroke: #fff; stroke-width: 9; filter: drop-shadow(0 0 6px #7fe3f0); }
.wx-burst circle { fill: none; stroke: #fff; stroke-width: 4; opacity: 0; }
.wx-burst path { stroke: var(--addon); stroke-width: 4; stroke-linecap: round; opacity: 0; }
.wx-burst.go circle { animation: ring 0.7s var(--ease) both; animation-delay: calc(var(--i) * 0.08s); }
.wx-burst.go path { animation: ray 0.5s var(--ease) both; }
@keyframes ring { from { opacity: 1; r: 4; } to { opacity: 0; r: 34; } }
@keyframes ray { from { opacity: 1; } to { opacity: 0; } }
.sc.shake .vis { animation: scshake 0.4s linear; }
@keyframes scshake { 20% { transform: translate(-4px, 2px); } 40% { transform: translate(4px, -2px); } 60% { transform: translate(-3px, 1px); } 80% { transform: translate(2px, -1px); } }
.hit { position: absolute; left: 22%; top: 66%; margin: 0; pointer-events: none; opacity: 0; }
.hit b { display: block; padding: 6px 18px; border-radius: 12px; background: var(--addon); color: #2a1a00; font-size: 26px; font-weight: 900; transform: rotate(-6deg); box-shadow: 0 10px 24px -10px rgba(0, 0, 0, 0.5); }
.hit.go { animation: hitpop 1.2s var(--pop) both; }
@keyframes hitpop { 0% { opacity: 0; transform: translate(-50%, 10px) scale(0.4); } 20% { opacity: 1; transform: translate(-50%, 0) scale(1.1); } 70% { opacity: 1; transform: translate(-50%, 0) scale(1); } 100% { opacity: 0; transform: translate(-50%, -10px) scale(1); } }
.sc-jet .duo { position: relative; }

/* Oxy timer */
.timer { position: absolute; z-index: 2; left: 4%; top: 4%; display: flex; align-items: center; gap: 6px; padding: 6px 12px 6px 6px; border-radius: 99px; background: var(--ink); color: #fff; font: 700 16px var(--mono); }
.timer svg { width: 26px; height: 26px; transform: rotate(-90deg); }
.timer circle { fill: none; stroke: rgba(255, 255, 255, 0.25); stroke-width: 4; }
.timer .tm { stroke: #5eead4; stroke-dasharray: 100; }

/* Rinse samples: each drain fills a test tube in a rack, near black, then brown, then clear. */
.rack { position: relative; display: grid; justify-items: center; padding: 0 10px; }
.tubes { list-style: none; margin: 0; padding: 0; display: flex; gap: 20px; align-items: end; }
.tubes li { display: grid; justify-items: center; gap: 8px; font: 800 15px var(--mono); color: var(--ink-3); transition: color 0.3s; }
.tube { position: relative; width: 34px; height: 150px; border: 2.5px solid var(--ink); border-top: 0; border-radius: 0 0 17px 17px; overflow: hidden; background: linear-gradient(90deg, rgba(255, 255, 255, 0.85), rgba(255, 255, 255, 0.45) 40%, rgba(255, 255, 255, 0.8)); }
.tube::before { content: ""; position: absolute; left: -4px; right: -4px; top: 0; height: 6px; border: 2.5px solid var(--ink); border-radius: 4px; background: #fff; z-index: 2; }
.tube::after { content: ""; position: absolute; left: 4px; top: 14px; bottom: 14px; width: 4px; border-radius: 4px; background: rgba(255, 255, 255, 0.9); z-index: 2; }
.tube u { position: absolute; right: 0; top: 30px; width: 8px; height: 90px; z-index: 2; background: repeating-linear-gradient(180deg, var(--ink) 0 1.5px, transparent 1.5px 18px); opacity: 0.45; }
.tube .liq { position: absolute; left: 0; right: 0; bottom: 0; height: 0; transition: height 1.1s var(--ease); }
.tube .liq s { position: absolute; width: 5px; height: 5px; border-radius: 50%; background: rgba(255, 255, 255, 0.55); bottom: 0; left: calc(var(--x, 50) * 1%); opacity: 0; }
.tube .liq s:nth-child(1) { --x: 20; animation-delay: 0s; } .tube .liq s:nth-child(2) { --x: 60; animation-delay: 0.3s; }
.tube .liq s:nth-child(3) { --x: 40; animation-delay: 0.6s; } .tube .liq s:nth-child(4) { --x: 70; animation-delay: 0.9s; }
.tube .liq s:nth-child(5) { --x: 30; animation-delay: 1.2s; }
.tubes li.full .liq s { animation: tubebub 1.6s ease-out infinite; }
@keyframes tubebub { 0% { opacity: 0; transform: translateY(0); } 20% { opacity: 1; } 100% { opacity: 0; transform: translateY(-110px); } }
.tube .sed { position: absolute; left: 0; right: 0; bottom: 0; height: 0; background: #1b120b; border-radius: 0 0 14px 14px; transition: height 1.6s 0.8s var(--ease); }
.tubes li.full .liq { height: 82%; }
.tubes li.g0 .liq { background: linear-gradient(180deg, #4a3220, #1e140c); }
.tubes li.g0.full .sed { height: 22px; }
.tubes li.g0 .liq s { background: rgba(160, 120, 80, 0.8); }
.tubes li.g1 .liq { background: linear-gradient(180deg, #a2805a, #6b4a2a); }
.tubes li.g1.full .sed { height: 8px; background: #3d2a18; }
.tubes li.g2 .liq { background: linear-gradient(180deg, #e3f8f4, #bfeee6); }
.tubes li.full { color: var(--ink); }
.rack-bar { width: 100%; height: 12px; margin-top: -78px; margin-bottom: 66px; border-radius: 4px; background: #9fd8cf; border: 2px solid var(--ink); position: relative; z-index: 3; pointer-events: none; }

/* Viewfinder (arrival) */
.vf { width: min(100%, 380px); display: grid; gap: 10px; }
/* The technician's phone camera: a dark screen, corner marks, an autofocus square that hunts
 * (yellow, the picture soft) then locks (green, sharp) before each of the four photos. */
.vf-screen { position: relative; aspect-ratio: 4 / 3.6; border-radius: 26px; overflow: hidden; background: #0f2a2e; border: 7px solid #0f2a2e; box-shadow: 0 30px 60px -30px rgba(14, 80, 75, 0.7); }
.vf-scene { position: absolute; inset: 0 0 52px; overflow: hidden; background: #e7f3ef; border-radius: 18px 18px 6px 6px; }
.vf-scene svg { position: absolute; inset: 0; width: 100%; height: 100%; transform: scale(var(--s, 1)) translate(var(--tx, 0%), var(--ty, 0%)); transition: transform 0.9s var(--ease), filter 0.4s; }
.vf.hunt .vf-scene svg { filter: blur(2.4px); }
.vf-c { position: absolute; width: 22px; height: 22px; border: 0 solid rgba(255, 255, 255, 0.95); filter: drop-shadow(0 0 2px rgba(0, 0, 0, 0.4)); }
.vf-c.tl { left: 12px; top: 12px; border-width: 3px 0 0 3px; border-top-left-radius: 6px; }
.vf-c.tr { right: 12px; top: 12px; border-width: 3px 3px 0 0; border-top-right-radius: 6px; }
.vf-c.bl { left: 12px; bottom: 64px; border-width: 0 0 3px 3px; border-bottom-left-radius: 6px; }
.vf-c.br { right: 12px; bottom: 64px; border-width: 0 3px 3px 0; border-bottom-right-radius: 6px; }
.vf-af { position: absolute; left: 50%; top: calc(50% - 26px); width: 22%; aspect-ratio: 1; translate: -50% -50%; border: 2px solid #ffd76a; border-radius: 6px; opacity: 0; box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.15); }
.vf-af::before, .vf-af::after { content: ""; position: absolute; left: 50%; top: 50%; width: 10px; height: 2px; background: currentColor; color: #ffd76a; translate: -50% -50%; }
.vf-af::after { width: 2px; height: 10px; }
.vf.hunt .vf-af { opacity: 1; animation: afhunt 0.7s var(--ease) both; }
.vf.lock .vf-af { opacity: 1; border-color: #5eead4; scale: 0.86; transition: scale 0.2s, border-color 0.2s; }
.vf.lock .vf-af::before, .vf.lock .vf-af::after { color: #5eead4; }
@keyframes afhunt { 0% { scale: 1.6; opacity: 0; } 40% { scale: 0.92; opacity: 1; } 60% { scale: 1.06; } 80% { scale: 0.97; } 100% { scale: 1; } }
.vf-tag { position: absolute; top: 14px; left: 50%; translate: -50% 0; display: flex; align-items: center; gap: 6px; padding: 3px 10px; border-radius: 99px; background: rgba(15, 42, 46, 0.72); color: #fff; font: 700 12px var(--mono); }
.vf-tag i { width: 7px; height: 7px; border-radius: 50%; background: #ff6b5a; animation: twinkle 1s ease-in-out infinite; }
.vf-bar { position: absolute; left: 0; right: 0; bottom: 0; height: 52px; display: flex; align-items: center; justify-content: space-between; padding: 0 18px; }
.vf-thumb { width: 30px; height: 30px; border-radius: 7px; background: #3c5a5e; border: 2px solid #fff; transition: background 0.2s; }
.vf.snap .vf-thumb { animation: thumb 0.6s ease-out; }
@keyframes thumb { 0% { background: #fff; scale: 1.25; } 100% { scale: 1; } }
.vf-shutter { width: 40px; height: 40px; border-radius: 50%; background: #fff; box-shadow: 0 0 0 3px #0f2a2e, 0 0 0 6px #fff; }
.vf.snap .vf-shutter { animation: shut 0.3s ease-out; }
@keyframes shut { 50% { scale: 0.86; } }
.vf-swap { width: 30px; height: 30px; border-radius: 50%; border: 2px solid rgba(255, 255, 255, 0.6); }
.vf-flash { position: absolute; inset: 0; background: #fff; opacity: 0; pointer-events: none; }
.vf.snap .vf-flash { animation: snap 0.4s ease-out; }
@keyframes snap { 0% { opacity: 0.9; } 100% { opacity: 0; } }
.vf-shots { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; }
.vf-shots li { padding: 8px 4px; border-radius: 10px; text-align: center; font-size: 14px; background: rgba(255, 255, 255, 0.7); border: 1px solid var(--line); transition: background 0.3s, color 0.3s; }
.vf-shots li.lit { background: var(--accent); color: #fff; border-color: var(--accent); }

/* Endoscope phone */
.scope-phone { width: min(100%, 220px); display: grid; gap: 6px; justify-items: center; }
.scope-phone.big { width: min(100%, 340px); }
.sp-screen { position: relative; width: 100%; aspect-ratio: 16 / 10; border-radius: 18px; border: 6px solid #0f2a2e; overflow: hidden; background: #2b3634; }
.sp-feed { position: absolute; inset: 0; --pan: 0%;
  background:
    radial-gradient(circle at 20% 30%, #c8d6d4 0 3px, transparent 4px) 0 0 / 34px 34px,
    linear-gradient(180deg, #8fa3a0, #c5d4d1 45%, #7f9592);
  background-position: var(--pan) 0, 0 0; transition: background-position 0.2s linear; }
.sp-feed.dirty::after { content: ""; position: absolute; inset: 0; background:
    radial-gradient(ellipse 30px 16px at 18% 40%, #3f2711 80%, transparent 82%),
    radial-gradient(ellipse 40px 18px at 52% 64%, #5a3a1c 80%, transparent 82%),
    radial-gradient(ellipse 26px 14px at 80% 30%, #3f2711 80%, transparent 82%),
    radial-gradient(ellipse 34px 12px at 34% 82%, #5a3a1c 80%, transparent 82%),
    radial-gradient(ellipse 20px 12px at 70% 86%, #3f2711 80%, transparent 82%);
  background-size: 200% 100%; background-position: var(--pan) 0; opacity: 0.92; }
.sp-clock { position: absolute; right: 8px; bottom: 6px; padding: 2px 8px; border-radius: 6px; background: rgba(0, 0, 0, 0.55); color: #fff; font: 700 13px var(--mono); }
.sp-rec { position: absolute; left: 8px; top: 6px; font: 700 12px var(--mono); color: #ff7a6a; }
.sp-cap { margin: 0; font-size: 14px; color: var(--ink-3); }
.sp-spot { position: absolute; left: 44%; top: 40%; width: 64px; height: 30px; border-radius: 50%; background: #4b2f14; transition: opacity 0.8s, transform 0.8s; }
.sp-jet { position: absolute; left: -10%; top: 48%; width: 60%; height: 10px; border-radius: 6px; background: linear-gradient(90deg, transparent, #e9fbff); opacity: 0; }
.sp-ok { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%) scale(0.6); padding: 6px 16px; border-radius: 99px; background: var(--accent); color: #fff; font-weight: 900; font-size: 18px; opacity: 0; transition: opacity 0.4s, transform 0.5s var(--pop); }
.scope-phone[data-beat="1"] .sp-spot { box-shadow: 0 0 0 4px #ffd76a; }
.scope-phone[data-beat="2"] .sp-jet { opacity: 1; animation: jetin 0.5s linear infinite; }
@keyframes jetin { from { transform: translateX(-30%); } to { transform: translateX(30%); } }
.scope-phone[data-beat="2"] .sp-spot { transform: scale(0.6); opacity: 0.5; }
.scope-phone[data-beat="3"] .sp-spot { opacity: 0; }
.scope-phone[data-beat="3"] .sp-feed { filter: brightness(1.25) saturate(1.1); }
.scope-phone[data-beat="3"] .sp-ok { opacity: 1; transform: translate(-50%, -50%) scale(1); }
.sc-flow .duo:has(.scope-phone) { grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); align-items: center; }

/* Door seal */
.art-seal { width: min(100%, 340px); }
.mx { display: block; width: 100%; height: auto; overflow: visible; }
.seal .fold { transform-box: fill-box; transform-origin: 50% 0; transition: transform 0.8s var(--ease); }
.art-seal.lift .fold { transform: translateY(26px) scaleY(1.2); }
.seal .hand { opacity: 0; transition: opacity 0.4s, transform 0.8s var(--ease); }
.art-seal.lift .hand { opacity: 1; transform: translateY(10px); }
.seal .mould { opacity: 0.25; transition: opacity 0.6s; }
.art-seal.lift .mould { opacity: 1; }
.seal .mk circle { fill: #fff; stroke: var(--ink); stroke-width: 2; transition: fill 0.3s; }
.seal .mk text { font: 900 16px var(--mono); fill: var(--ink); }
.art-seal.m6 .m6 circle, .art-seal.m3 .m3 circle, .art-seal.m9 .m9 circle { fill: var(--accent); }
.art-seal.m6 .m6 text, .art-seal.m3 .m3 text, .art-seal.m9 .m9 text { fill: #fff; }
.art-seal.m12 .m12 circle { fill: var(--addon); animation: pulse 0.9s ease-in-out 3; }
@keyframes pulse { 50% { stroke-width: 6; } }
.seal .flash circle { opacity: 0; }
.art-seal.snap .flash circle { animation: snap 0.4s ease-out; }

/* Molecules */
.mx .at-t { font: 900 13px var(--sans); fill: #fff; pointer-events: none; }
.mx .at-t.sm { font-size: 11px; }
.mx .at-O .at-t, .mx .at-C .at-t, .mx .at-Na .at-t { fill: #fff; }
.mx .chg { font: 900 14px var(--mono); fill: var(--ink); }
.mx .mx-name { font: 900 22px var(--mono); fill: var(--ink); }
.mx .mx-lbl { font: 700 14px var(--sans); fill: var(--ink-2); }
.mx .mx-cap { font: 900 16px var(--mono); fill: var(--ink); }
.mx .mx-cap.sm { font: 700 14px var(--sans); }
.mx .mx-plus { font: 900 28px var(--mono); fill: var(--ink); }
.mx .dim text { font: 700 14px var(--mono); fill: var(--accent-deep); }
.duo.mol { grid-template-columns: 1fr; }
.art-crystal { width: min(100%, 460px); }
.art-crystal svg { overflow: hidden; }
.crystal .cell, .crystal .pfree { transform-box: fill-box; transition: transform 1.6s var(--ease), opacity 1.6s; }
.crystal .hb { transition: opacity 0.8s; }
.crystal .cx-heat { opacity: 0.25; transition: opacity 0.5s; }
.duo.mol.heat .cx-heat { opacity: 1; }
.duo.mol.melt .cell { transform: translate(calc((var(--k) - 4) * 10px), 26px) scale(0.92); opacity: 0.35; }
.duo.mol.melt .hb { opacity: 0; }
.duo.mol.melt .pfree { transform: translateY(-40px) rotate(calc((var(--i) - 2) * 14deg)); }
.duo.mol.melt .pfree .mol { filter: drop-shadow(0 0 8px rgba(255, 90, 95, 0.55)); }
.mcard { display: flex; align-items: center; gap: 12px; width: min(100%, 460px); padding: 10px 14px; border-radius: 18px; background: #fff; border: 1px solid var(--line); opacity: 0; transform: translateY(14px); transition: opacity 0.5s, transform 0.6s var(--pop); }
.duo.mol.card .mcard { opacity: 1; transform: none; }
.mcard .art-h2o2 { flex: none; width: 150px; }
.mcard p { margin: 0; font-size: 15px; line-height: 1.5; color: var(--ink-2); }
.mcard b { display: block; font-size: 18px; color: var(--ink); }

.art-react { width: min(100%, 480px); }
.react .atk { transition: transform 1.1s var(--ease), opacity 0.6s; }
.react .a1 { transform: translate(-40px, -80px); opacity: 0; }
.react .a2 { transform: translate(60px, -80px); opacity: 0; }
.art-react[data-beat="1"] .atk, .art-react[data-beat="2"] .atk, .art-react[data-beat="3"] .atk { opacity: 1; }
.art-react[data-beat="1"] .a1, .art-react[data-beat="2"] .a1 { transform: translate(-36px, 80px); }
.art-react[data-beat="1"] .a2, .art-react[data-beat="2"] .a2 { transform: translate(-2px, 112px); }
.art-react[data-beat="3"] .atk { opacity: 0; }
.react .zap circle { fill: #fff59a; stroke: #ffb84d; stroke-width: 3; opacity: 0; transform-box: fill-box; transform-origin: center; }
.art-react[data-beat="2"] .zap circle { animation: zap 0.5s ease-out both; }
.art-react[data-beat="2"] .z2 circle { animation-delay: 0.4s; }
@keyframes zap { 0% { opacity: 1; transform: scale(0.4); } 100% { opacity: 0; transform: scale(2.2); } }
.react .lk.cut { transition: opacity 0.3s; }
.art-react[data-beat="2"] .lk.cut, .art-react[data-beat="3"] .lk.cut { opacity: 0; }
.react .seg, .react .lk:not(.cut) { transition: transform 1.6s var(--ease), opacity 1.6s; }
.react .anchors { transition: opacity 0.6s; }
.art-react[data-beat="3"] .anchors { opacity: 0; }
.art-react[data-beat="3"] .s1 { transform: translate(-20px, -150px) rotate(-8deg); opacity: 0.2; }
.art-react[data-beat="3"] .s2 { transform: translate(0, -180px); opacity: 0.2; }
.art-react[data-beat="3"] .s3 { transform: translate(20px, -140px) rotate(8deg); opacity: 0.2; }
.art-react[data-beat="3"] .chain > .lk:not(.cut) { opacity: 0; }
.react .bub { opacity: 0; }
.art-react[data-beat="3"] .bub { animation: bubup 1.8s ease-out both; animation-delay: calc(var(--i) * 0.12s); }
@keyframes bubup { 0% { opacity: 0; transform: translateY(0); } 20% { opacity: 1; } 100% { opacity: 0; transform: translateY(-190px); } }
.react .soda { animation: bob 2.8s ease-in-out infinite; }
@keyframes bob { 50% { transform: translateY(-8px); } }
.eqs { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; width: min(100%, 480px); }
.eqs li { padding: 10px 14px; border-radius: 14px; background: rgba(255, 255, 255, 0.7); border: 1px solid var(--line); opacity: 0.45; transition: opacity 0.4s, border-color 0.4s; }
.eqs li.lit { opacity: 1; border-color: var(--accent); background: #fff; }
.eqs b { display: block; font: 700 17px var(--mono); color: var(--ink); }
.eqs span { font-size: 15px; color: var(--ink-2); }

.art-break { width: min(100%, 460px); }
.brk .rhs, .brk .arr { opacity: 0; transition: opacity 0.6s; }
.art-break[data-beat="1"] .arr, .art-break[data-beat="2"] .arr, .art-break[data-beat="2"] .rhs { opacity: 1; }
.art-break[data-beat="2"] .lhs { opacity: 0.35; transition: opacity 0.6s; }
.art-break[data-beat="2"] .o2up { animation: o2up 2.4s ease-in-out infinite; }
@keyframes o2up { 50% { transform: translateY(-14px); } }
.safe { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; width: min(100%, 460px); }
.safe li { display: grid; padding: 10px 14px 10px 46px; position: relative; border-radius: 14px; background: #fff; border: 1px solid var(--line); opacity: 0; transform: translateY(10px); transition: opacity 0.4s, transform 0.5s var(--pop); }
.safe li::before { content: "✓"; position: absolute; left: 12px; top: 50%; translate: 0 -50%; width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; background: var(--accent); color: #fff; font-weight: 900; font-size: 14px; }
.safe li.lit { opacity: 1; transform: none; }
.safe b { font-size: 16.5px; }
.safe span { font-size: 15px; color: var(--ink-2); }

.art-drawer { width: min(100%, 470px); }
/* Step 9: the drawer pulls out half, the release tab is pressed, it comes out, lifts and explodes
 * (the siphon cap pops up); brushed, then the bay; photos before and after. Beats from main.js. */
.drawer .dw, .drawer .dw-capg, .drawer .dw-cap { transition: transform 0.9s var(--ease); }
.art-drawer:not([data-beat="0"]) :is(.dw, .dw-capg) { transform: translate(-147.2px, 63px); }
.drawer .dw-names text { font: 800 13px var(--sans); fill: var(--accent-deep); text-anchor: middle; }
html:not([lang^="zh"]) .drawer .dw-names text { font-size: 10px; }
.drawer .dw-names { opacity: 0; transition: opacity 0.4s 0.4s; }
.art-drawer:is([data-beat="3"], [data-beat="4"], [data-beat="5"], [data-beat="6"]) .dw-names { opacity: 1; }
.art-drawer:is([data-beat="3"], [data-beat="4"], [data-beat="5"], [data-beat="6"]) .dw-cap { transform: translateY(-46px); transition-delay: 0.5s; }
.drawer .dw-tab { transition: fill 0.3s; }
.art-drawer[data-beat="2"] .dw-tab { animation: tabpush 0.5s ease-in-out 3; }
@keyframes tabpush { 50% { fill: #ff9f1c; } }
.drawer .dw-lcd { font: 700 10px var(--mono); fill: #5eead4; }
.drawer :is(.dw-muck, .dw-bay-muck) { transition: opacity 1.4s; }
.art-drawer:is([data-beat="5"], [data-beat="6"]) .dw-muck, .art-drawer[data-beat="6"] .dw-bay-muck { opacity: 0; }
.drawer .dw-brush { opacity: 0; transform: translate(137px, 180px); transition: transform 0.6s var(--ease), opacity 0.3s; }
.art-drawer[data-beat="4"] .dw-brush { opacity: 1; animation: scrub1 0.5s ease-in-out infinite; }
.art-drawer[data-beat="5"] .dw-brush { opacity: 1; animation: scrub2 0.5s ease-in-out infinite; }
@keyframes scrub1 { 0%, 100% { transform: translate(112px, 192px); } 50% { transform: translate(162px, 168px); } }
@keyframes scrub2 { 0%, 100% { transform: translate(200px, 186px); } 50% { transform: translate(256px, 168px); } }
.drawer .dw-spark { opacity: 0; }
.art-drawer[data-beat="6"] .dw-spark { opacity: 1; animation: twinkle 1s ease-in-out infinite; }
.drawer .dw-labels .dl { opacity: 0; transition: opacity 0.4s; }
.drawer .dl path { fill: none; stroke: var(--ink); stroke-width: 1.4; }
.drawer .dl circle { fill: var(--accent); stroke: #fff; stroke-width: 1.4; }
.drawer .dl text { font: 800 14px var(--sans); fill: var(--ink); paint-order: stroke; stroke: rgba(240, 250, 247, 0.9); stroke-width: 4px; }
.art-drawer[data-beat="2"] .dl:has([data-art="tab"]) { opacity: 1; }
.art-drawer:is([data-beat="3"], [data-beat="4"], [data-beat="5"]) .dl { opacity: 1; }
.art-drawer:is([data-beat="3"], [data-beat="4"], [data-beat="5"]) .dl:nth-child(2) { transition-delay: 0.1s; }
.art-drawer[data-beat="2"] .dl:has([data-art="tab"]) text { fill: #b45309; }
.drawer .shot { opacity: 0; transition: opacity 0.4s; }
.drawer .shot rect { fill: #fff; stroke: var(--ink); stroke-width: 2; }
.art-drawer:is([data-beat="3"], [data-beat="4"], [data-beat="5"], [data-beat="6"]) .s1, .art-drawer[data-beat="6"] .s2 { opacity: 1; }
.art-drawer[data-beat="3"] .s1 rect, .art-drawer[data-beat="6"] .s2 rect { animation: shotflash 0.5s ease-out; }
@keyframes twinkle { 50% { opacity: 0.4; } }
@keyframes shotflash { 0% { fill: #fff59a; } }

.art-foam { width: min(100%, 480px); border-radius: 20px; overflow: hidden; border: 1px solid var(--line); }
.foam .fb { fill: rgba(255, 255, 255, 0.9); stroke: #a7dcd4; stroke-width: 1.6; opacity: 0; transform-box: fill-box; transform-origin: center; transform: scale(0.2); transition: opacity 0.8s, transform 1.2s var(--pop); transition-delay: calc(var(--i) * 0.03s); }
.art-foam:not([data-beat="0"]) .fb { opacity: 1; transform: none; }
.foam .fl path { fill: #6b4724; stroke: #2e1d0d; stroke-width: 1.4; }
.foam .cl circle { fill: rgba(255, 255, 255, 0.95); stroke: #a7dcd4; stroke-width: 1.6; opacity: 0; transition: opacity 0.6s; }
.art-foam[data-beat="2"] .cl circle, .art-foam[data-beat="3"] .cl circle { opacity: 1; }
.foam .fl { transition: transform 2.2s var(--ease); transition-delay: calc(var(--i) * 0.12s); }
.art-foam[data-beat="3"] .fl { transform: translate(var(--sx), var(--up)); }

.art-rig { width: min(100%, 480px); }
.rig .flow { opacity: 0; }
.art-rig[data-beat="1"] .f1, .art-rig[data-beat="2"] .f1, .art-rig[data-beat="3"] .f1, .art-rig[data-beat="3"] .f2 { opacity: 1; animation: flow 0.6s linear infinite; }
.rig .needle { transform-box: view-box; transform-origin: 262px 196px; transition: transform 0.8s var(--pop); }
.art-rig[data-beat="2"] .needle, .art-rig[data-beat="3"] .needle { transform: rotate(130deg); }
.art-rig[data-beat="2"] .pw, .art-rig[data-beat="3"] .pw { animation: buzz 0.12s linear infinite; }
@keyframes buzz { 50% { transform: translate(0.6px, -0.6px); } }
.rig .mist path { opacity: 0; }
.art-rig[data-beat="3"] .mist path { animation: mist 0.5s linear infinite; animation-delay: calc(var(--i) * 0.1s); }
@keyframes mist { 0% { opacity: 0; } 30% { opacity: 1; } 100% { opacity: 0; transform: translate(6px, -4px); } }

/* Before / after (real case) */
.ba { margin: 0; width: min(100%, 400px); display: grid; gap: 8px; }
/* Before and after side by side, each labelled, an arrow between: before shows first. */
.ba-two { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 6px; }
.ba-p { position: relative; aspect-ratio: 1; border-radius: 16px; overflow: hidden; border: 1px solid var(--line); box-shadow: 0 24px 48px -28px rgba(14, 80, 75, 0.6); }
.ba-p img { display: block; width: 100%; height: 100%; object-fit: cover; }
.ba-tag { position: absolute; left: 8px; right: 8px; bottom: 8px; padding: 4px 8px; border-radius: 10px; text-align: center; background: rgba(120, 30, 20, 0.82); color: #fff; font-size: 14px; font-weight: 800; }
.ba-tag::before { content: "✕ "; }
.ba-tag.ok { background: rgba(11, 127, 121, 0.92); }
.ba-tag.ok::before { content: "✓ "; }
.ba-arrow svg { display: block; width: 26px; height: 26px; fill: none; stroke: var(--accent-deep); stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; }
.ba-a, .ba-arrow { opacity: 0; transform: translateX(-10px); transition: opacity 0.6s, transform 0.7s var(--pop); }
.ba[data-beat="1"] .ba-arrow { opacity: 1; transform: none; }
.ba[data-beat="1"] .ba-a { opacity: 1; transform: none; transition-delay: 0.35s; }
.ba-shine { position: absolute; inset: 0; background: linear-gradient(115deg, transparent 35%, rgba(255, 255, 255, 0.7) 50%, transparent 65%); transform: translateX(-120%); }
.ba[data-beat="1"] .ba-shine { transition: transform 1.2s var(--ease) 0.9s; transform: translateX(120%); }
.ba figcaption { display: flex; justify-content: space-between; align-items: center; gap: 8px; font-size: 14px; color: var(--ink-3); }
.ba .tag { padding: 4px 12px; border-radius: 99px; background: var(--addon); color: #2a1a00; font-size: 15px; }

/* Done */
.duo.done { grid-template-columns: auto minmax(0, 1fr); align-items: center; }
.done-drop { position: relative; width: 150px; aspect-ratio: 1; display: grid; place-items: center; }
.done-drop .drop { width: 64%; }
.done-ring { position: absolute; inset: 0; width: 100%; height: 100%; transform: rotate(-90deg); }
.done-ring .hr-fg { transition: stroke-dashoffset 1.4s var(--ease); }
.done-time { position: absolute; bottom: -6px; padding: 2px 10px; border-radius: 99px; background: var(--ink); color: #5eead4; font: 700 14px var(--mono); }

/* Prices */
.prices { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 10px; width: min(100%, 520px); }
.prices > li { display: grid; gap: 2px; padding: 14px; border-radius: 18px; background: #fff; border: 1px solid var(--line); opacity: 0; transform: translateY(12px) scale(0.96); transition: opacity 0.4s, transform 0.5s var(--pop); }
.prices > li.in { opacity: 1; transform: none; }
.prices > li > small { font-size: 14px; color: var(--ink-3); font-weight: 700; }
.prices > li > b { font: 900 28px var(--mono); color: var(--ink); letter-spacing: -0.02em; }
.prices > li > span { font-size: 14px; color: var(--ink-2); }
.prices .main { grid-column: 1 / -1; background: var(--cta); border: 0; color: #fff; }
.prices .main small, .prices .main span { color: rgba(255, 255, 255, 0.9); }
.prices .main b { color: #fff; font-size: 40px; }
.prices .minus b { color: var(--accent-deep); }
.prices .add { background: #fffaf0; border-color: #f2dc9c; }
/* The special-model card: full width, an arrow points at it, then it opens to say what counts. */
.prices .special { grid-column: 1 / -1; position: relative; grid-template-columns: auto 1fr; column-gap: 12px; align-items: baseline; transition: opacity 0.4s, transform 0.5s var(--pop), box-shadow 0.4s, border-color 0.4s; }
.prices .special small { grid-column: 1 / -1; }
.prices .special > span { grid-column: 2; }
.prices .special.hl { border: 2px solid var(--accent); box-shadow: 0 0 0 6px rgba(14, 159, 151, 0.14); }
.pr-arrow { position: absolute; right: 14px; top: -34px; width: 70px; height: 54px; overflow: visible; fill: none; stroke: #e8590c; stroke-width: 5; stroke-linecap: round; stroke-linejoin: round; opacity: 0; }
.pr-arrow path { stroke-dasharray: 140; stroke-dashoffset: 140; }
.special.hl .pr-arrow { opacity: 1; animation: nudge 1.4s ease-in-out 0.8s infinite; }
.special.hl .pr-arrow path { transition: stroke-dashoffset 0.6s var(--ease); stroke-dashoffset: 0; }
.special.hl .pr-arrow path + path { transition-delay: 0.45s; }
.spx { grid-column: 1 / -1; display: grid; grid-template-rows: 0fr; transition: grid-template-rows 0.6s var(--ease), margin 0.6s; }
.spx-in { overflow: hidden; min-height: 0; }
.special.open .spx { grid-template-rows: 1fr; margin-top: 8px; }
.spx-h { margin: 0; padding-top: 8px; border-top: 1px dashed var(--line-2, rgba(15, 42, 46, 0.2)); font-weight: 800; color: var(--accent-deep); font-size: 15px; }
.spx-list { margin: 4px 0 0; padding-left: 1.2em; font-size: 14px; color: var(--ink-2); line-height: 1.5; }
.spx-no { width: min(100%, 520px); margin: 10px 0 0; padding: 10px 14px; border-radius: 14px; background: #fff3f0; border: 1px solid #f3c4b8; font-size: 14px; color: var(--ink-2); opacity: 0; transform: translateY(8px); transition: opacity 0.4s, transform 0.5s var(--pop); }
.spx-no b { margin-right: 8px; color: #c2410c; }
.spx-no.in { opacity: 1; transform: none; }

/* Chat */
.phone { width: min(360px, 100%); display: flex; flex-direction: column; border-radius: 26px; overflow: hidden; background: rgba(255, 255, 255, 0.85); border: 1px solid #fff; box-shadow: 0 30px 70px -30px rgba(14, 90, 85, 0.5); }
.phone-head { display: flex; align-items: center; gap: 10px; padding: 12px 16px; font-weight: 700; font-size: 16px; background: linear-gradient(90deg, #0b5c58, #0e9f97); color: #fff; }
.bb-av { position: relative; width: 38px; height: 38px; border-radius: 50%; overflow: hidden; background: #fff; flex: none; }
.bb-av img { width: 100%; height: 100%; display: block; }
.bb-dot { position: absolute; right: 1px; bottom: 1px; width: 10px; height: 10px; border-radius: 50%; background: #3ddc84; border: 2px solid #fff; }
.bb-t { display: flex; flex-direction: column; line-height: 1.25; }
.bb-t small { font-size: 13px; font-weight: 500; opacity: 0.85; }
.chat { list-style: none; margin: 0; padding: 14px 12px 16px; display: flex; flex-direction: column; gap: 8px; }
.chat li { position: relative; max-width: 86%; padding: 10px 13px; border-radius: 16px; font-size: 16px; line-height: 1.5; visibility: hidden; opacity: 0; transform: translateY(10px) scale(0.96); transition: opacity 0.35s, transform 0.45s var(--pop); }
.chat li.in, .chat li.typing { visibility: visible; opacity: 1; transform: none; }
.chat .me { align-self: flex-end; background: #d9fdd3; color: #111b21; border-bottom-right-radius: 4px; }
.chat .bot { align-self: flex-start; background: #fff; color: #111b21; border-bottom-left-radius: 4px; box-shadow: 0 2px 8px rgba(30, 80, 75, 0.1); }
.chat li.typing { color: transparent; }
.chat li.typing::after { content: "•••"; position: absolute; left: 13px; top: 8px; color: var(--ink-3); letter-spacing: 3px; animation: typing 1s steps(3) infinite; }
@keyframes typing { 50% { opacity: 0.3; } }
.sc.measure .chat li { visibility: visible !important; }

/* ---------------------------------------------------------------- */
/* End                                                                 */
/* ---------------------------------------------------------------- */

.sc-end { justify-content: center; }
.end-copy { text-align: center; }
.end-copy p { margin-inline: auto; }
.finale { position: fixed; inset: 0; z-index: 25; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 30px; padding: calc(var(--top-h) + var(--safe-t)) 20px calc(90px + var(--safe-b)); pointer-events: none; visibility: hidden; }
body.finale-on .finale { visibility: visible; pointer-events: auto; }
.emblem { position: relative; width: min(84vw, 560px); }
.emblem-in { position: relative; }
.emblem-in img { display: block; width: 100%; height: auto; }
.sheen { position: absolute; inset: 0; pointer-events: none; -webkit-mask: url(../images/fixes-logo-dark-hi.webp) center / 100% 100% no-repeat; mask: url(../images/fixes-logo-dark-hi.webp) center / 100% 100% no-repeat;
  background: linear-gradient(115deg, transparent 20%, rgba(94, 234, 212, 0.7) 42%, rgba(255, 255, 255, 0.95) 48%, rgba(94, 234, 212, 0.6) 56%, transparent 75%); background-size: 260% 100%; background-position: 120% 0; animation: emblem-sheen 3.6s 1.2s ease-in-out infinite; }
@keyframes emblem-sheen { 0% { background-position: 120% 0; } 45%, 100% { background-position: -40% 0; } }
body.finale-on .emblem-in { animation: emblem-in 1.6s var(--ease) both; }
@keyframes emblem-in { 0% { opacity: 0; clip-path: circle(0% at 12% 50%); } 40% { opacity: 1; clip-path: circle(35% at 12% 50%); } 100% { opacity: 1; clip-path: circle(150% at 12% 50%); } }
.end-tag { margin: -10px 0 0; font-size: 18px; font-weight: 700; letter-spacing: 0.12em; color: var(--ink-2); text-align: center; opacity: 0; }
body.finale-on .end-tag { opacity: 1; transition: opacity 1s var(--ease) 1.4s; }
.finale-acts { width: min(440px, 100%); display: grid; gap: 4px; opacity: 0; transform: translateY(20px); }
body.finale-on .finale-acts { opacity: 1; transform: none; transition: opacity 0.8s var(--ease) 2.2s, transform 0.9s var(--ease) 2.2s; }
.finale-acts .cta { width: 100%; }
.finale-acts .routes { margin-top: 12px; grid-template-columns: 1fr 1fr; }
.finale-acts .route { min-height: 64px; grid-template-columns: 1fr auto; padding: 10px 12px; }
.finale-acts .route b { grid-column: 1; font-size: 17px; }
.finale-acts .route small { grid-column: 1; }
.finale-acts .route > i { grid-column: 2; }
.end-links { display: flex; justify-content: center; align-items: center; gap: 18px; margin: 10px 0 0; }
.end-links a { color: var(--accent-deep); font-weight: 700; font-size: 15px; text-decoration: none; }
.end-links .textver { margin: 0; color: var(--ink-2); }

/* The finale: the page has gone into Fixes Baby; what comes out is clean water. Deep teal water,
   light coming down through it, bubbles rising, the logo in white with a mint sheen. */
.fin-sea { position: fixed; inset: 0; z-index: -1; overflow: hidden; opacity: 0; background: radial-gradient(90% 70% at 50% 30%, #13837c 0%, #0b5552 40%, #072d30 78%, #051c1f 100%); }
body.finale-on .fin-sea { opacity: 1; transition: opacity 1.2s var(--ease); }
.fin-rays { position: absolute; left: 50%; top: -30%; width: 160vmax; height: 120vmax; translate: -50% 0; background: repeating-conic-gradient(from 160deg at 50% 0%, rgba(160, 255, 240, 0.075) 0deg 3deg, transparent 3deg 9deg); -webkit-mask: radial-gradient(60% 70% at 50% 0%, #000 20%, transparent 75%); mask: radial-gradient(60% 70% at 50% 0%, #000 20%, transparent 75%); animation: rays 14s ease-in-out infinite alternate; }
@keyframes rays { from { rotate: -4deg; } to { rotate: 4deg; } }
.fin-glow { position: absolute; left: 50%; top: 40%; width: min(900px, 120vw); aspect-ratio: 2.2; translate: -50% -50%; border-radius: 50%; background: radial-gradient(closest-side, rgba(94, 234, 212, 0.38), rgba(94, 234, 212, 0.08) 60%, transparent); animation: breathe 5s ease-in-out infinite; }
@keyframes breathe { 50% { scale: 1.08; opacity: 0.8; } }
.fin-bub i { position: absolute; bottom: -40px; left: var(--x); width: var(--s); height: var(--s); border-radius: 50%; border: 1.5px solid rgba(200, 255, 248, 0.55); background: radial-gradient(circle at 32% 30%, rgba(255, 255, 255, 0.85) 0 14%, rgba(160, 255, 240, 0.12) 22%, transparent 70%); animation: finrise var(--d) linear var(--w) infinite; }
@keyframes finrise { 0% { transform: translate(0, 0); opacity: 0; } 10% { opacity: 1; } 50% { transform: translate(14px, -55vh); } 90% { opacity: 0.9; } 100% { transform: translate(-8px, -112vh); opacity: 0; } }
body.finale-on .emblem { filter: drop-shadow(0 16px 30px rgba(0, 20, 22, 0.45)) drop-shadow(0 0 22px rgba(94, 234, 212, 0.25)); }
body.finale-on .emblem::after { content: ""; position: absolute; inset: -30% -12%; pointer-events: none; background: radial-gradient(closest-side, rgba(255, 255, 255, 0.85), rgba(94, 234, 212, 0.35) 45%, transparent); opacity: 0; animation: emblem-flare 1.6s var(--ease); }
@keyframes emblem-flare { 0% { opacity: 0; transform: scale(0.6); } 30% { opacity: 1; } 100% { opacity: 0; transform: scale(1.1); } }
/* The logo in its four colours, standing out (Eddie 10:12Z: it melted into the teal): a dark pool
   of water behind it, a thin bright rim, and the repair finale's light, blended over the logo so
   its colours stay true. */
.finale .sheen { -webkit-mask-image: url(../images/fixes-logo-white-hi.webp); mask-image: url(../images/fixes-logo-white-hi.webp);
  background: linear-gradient(115deg, transparent 20%, rgba(111, 247, 255, 0.55) 40%, rgba(255, 255, 255, 0.95) 48%, rgba(233, 255, 122, 0.6) 56%, transparent 75%);
  background-size: 260% 100%; mix-blend-mode: overlay; }
.finale .emblem::before { content: ""; position: absolute; inset: -34% -14%; z-index: -1; pointer-events: none; border-radius: 50%; background: radial-gradient(closest-side, rgba(2, 20, 24, 0.78), rgba(2, 20, 24, 0.45) 55%, transparent); }
body.finale-on .finale .emblem { filter: drop-shadow(0 0 1.5px rgba(255, 255, 255, 0.85)) drop-shadow(0 0 18px rgba(120, 200, 255, 0.45)) drop-shadow(0 18px 34px rgba(0, 10, 12, 0.6)); }
.fin-badge { display: flex; align-items: center; justify-content: center; gap: 12px; margin-top: -12px; }
.fin-drop { width: 64px; flex: none; opacity: 0; transform: translateY(16px) scale(0.6); }
body.finale-on .fin-drop { opacity: 1; transform: none; transition: opacity 0.6s var(--ease) 1.2s, transform 0.8s var(--pop) 1.2s; }
.finale .end-tag { margin: 0; color: #c9fff6; text-shadow: 0 2px 14px rgba(0, 40, 40, 0.5); }
body.finale-on { background: #072d30; }
.finale .route { background: rgba(255, 255, 255, 0.08); border-color: rgba(200, 255, 248, 0.25); color: #fff; -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); }
.finale .route small { color: rgba(220, 255, 250, 0.7); }
/* ------------------------------------------------------------------ */
/* The stage: every process step filmed like step 1 (Eddie 2026-10-05: "same standard as step 1").
 * A dark-bezelled screen with the scene behind it, a camera (--s, --tx, --ty, set by main.js) that
 * moves to what the step is about, a REC tag, and the step's beats as chips underneath.          */
/* ------------------------------------------------------------------ */
.stg { width: min(100%, 390px); min-width: 0; display: grid; gap: 10px; }

.stg-screen { position: relative; aspect-ratio: var(--ar, 4 / 3); border-radius: 26px; overflow: hidden; background: #0f2a2e; border: 7px solid #0f2a2e; box-shadow: 0 30px 60px -30px rgba(14, 80, 75, 0.7); isolation: isolate; }
.stg-screen::after { content: ""; position: absolute; inset: 0; border-radius: 19px; pointer-events: none; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.08), inset 0 0 46px rgba(6, 30, 32, 0.28); z-index: 3; }
.stg-cam { position: absolute; inset: 0; overflow: hidden; border-radius: 19px; transform: scale(var(--s, 1)) translate(var(--tx, 0%), var(--ty, 0%)); transition: transform 1.1s var(--ease), opacity 0.45s; will-change: transform;
  background: linear-gradient(180deg, #f1f9f6 0 80%, #c7ddd6 80% 100%); }
.stg-cam.cut { transition: none; }
.stg-cam > svg { position: absolute; inset: 0; display: block; width: 100%; height: 100%; }
.stg-cam .wxw { position: absolute; left: 50%; top: 2%; height: 98%; width: auto; aspect-ratio: 400 / 452; translate: -50% 0; }
.stg-cam .wx { width: 100%; height: 100%; }
.stg[data-k="wash"] .stg-cam { background:
  repeating-linear-gradient(90deg, transparent 0 49px, rgba(195, 222, 214, 0.55) 49px 50px),
  repeating-linear-gradient(180deg, transparent 0 49px, rgba(195, 222, 214, 0.55) 49px 50px),
  linear-gradient(180deg, #f1f9f6 0 88%, #c7ddd6 88% 100%); }
.stg-tag { position: absolute; z-index: 4; top: 12px; left: 50%; translate: -50% 0; display: flex; align-items: center; gap: 6px; padding: 3px 11px; border-radius: 99px; background: rgba(15, 42, 46, 0.74); color: #fff; font: 700 12px var(--sans); white-space: nowrap; backdrop-filter: blur(4px); }
.stg-tag i { width: 7px; height: 7px; border-radius: 50%; background: #ff6b5a; animation: twinkle 1s ease-in-out infinite; }
.stg-tag em { font: 800 12px var(--mono); font-style: normal; color: #5eead4; }
.stg-steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(var(--n, 4), 1fr); gap: 6px; }
.stg-steps li { min-width: 0; display: flex; align-items: center; justify-content: center; gap: 6px; padding: 8px 4px; border-radius: 10px; text-align: center; font-size: 14px; line-height: 1.2; background: rgba(255, 255, 255, 0.7); border: 1px solid var(--line); transition: background 0.3s, color 0.3s, border-color 0.3s, transform 0.4s var(--pop); }
.stg-steps li.lit { background: var(--accent); color: #fff; border-color: var(--accent); }
.stg-steps li.now { transform: translateY(-3px); }
.stg-flash { position: absolute; inset: 0; z-index: 5; background: #fff; opacity: 0; pointer-events: none; }
.stg.snap .stg-flash { animation: snap 0.4s ease-out; }
.stg-sub { position: absolute; z-index: 4; left: 50%; bottom: 12px; translate: -50% 0; margin: 0; max-width: calc(100% - 24px); }
.stg-sub b { display: none; padding: 5px 12px; border-radius: 10px; background: rgba(15, 42, 46, 0.8); color: #fff; font-size: 14px; font-weight: 700; text-align: center; white-space: nowrap; animation: rise 0.4s var(--pop) both; }
.stg-sub b.on { display: block; }
.stg-duo { justify-items: center; }
.stg .timer { opacity: 0; transform: scale(0.8); transition: opacity 0.4s, transform 0.5s var(--pop); left: 12px; top: 12px; z-index: 4; font-size: 15px; }
.stg.clock-on .timer { opacity: 1; transform: none; }
.stg[data-k="front"], .stg[data-k="drawer"] { --ar: 400 / 340; }
.stg[data-k="front"] .stg-tag, .stg[data-k="foam"] .stg-tag, .stg[data-k="rig"] .stg-tag, .stg[data-k="wash"] .stg-tag, .stg[data-k="drawer"] .stg-tag { left: auto; right: 12px; translate: 0 0; }
.stg .hit { left: 30%; top: 62%; z-index: 4; }

/* The machine from the front (steps 2, 5, 9) */
.front text { font-family: var(--sans); }
.front .fr-lcd { font: 700 12px var(--mono); fill: #5eead4; }
.front .fr-temp text { font: 900 8px var(--mono); fill: #fff; }
.front .fr-tag { font: 700 11px var(--sans); fill: #fff; }
.fr-drum { transform-box: view-box; transform-origin: 200px 166px; }
.stg.spin .fr-drum { animation: spin 4s linear infinite; }
/* Step 2 (Eddie 10:12Z): the door starts open; the hand rocks the drum hard (twice the swing),
   then swings the door shut and it locks. */
.fr-door { transform-box: view-box; transform-origin: 124px 166px; transition: transform 0.9s var(--ease); }
.stg.open .fr-door { transform: scaleX(-0.42); }
.stg.rock .fr-drum, .stg.rock .fr-hrock { animation: rock2 0.8s ease-in-out 3; }
.fr-hrock { transform-box: view-box; transform-origin: 200px 166px; }
@keyframes rock2 { 25% { transform: rotate(-16deg); } 75% { transform: rotate(16deg); } }
.fr-hand { opacity: 0; transform: translate(30px, 40px); transition: opacity 0.4s, transform 0.7s var(--ease); }
.stg.hand .fr-hand { opacity: 1; transform: none; }
.stg.grab .fr-hand { transform: translate(-188px, -14px); }
.stg.shut .fr-hand { transform: translate(28px, -14px); transition: opacity 0.4s, transform 0.9s var(--ease); }
.fr-lock rect { fill: #9fb7b4; transition: fill 0.3s; }
.fr-lock path { transition: transform 0.3s var(--pop); transform: translateY(-3px); }
.stg.lock .fr-lock rect { fill: #0e9f97; }
.stg.lock .fr-lock path { transform: none; }
.stg.lock .fr-lock { animation: pop 0.5s var(--pop); transform-box: fill-box; transform-origin: center; }
@keyframes pop { 40% { scale: 1.25; } }
.fr-water { transition: transform 1.8s var(--ease); }
.fr-wave { animation: wave 1.6s linear infinite; }
@keyframes wave { to { transform: translateX(-40px); } }
.fr-level, .fr-temp { opacity: 0; transition: opacity 0.5s; }
.stg.level .fr-level, .stg.hot .fr-temp { opacity: 1; }
.fr-fizz circle { fill: #fff; opacity: 0; }
.stg.fizz .fr-fizz circle { animation: fizz 1.4s ease-in infinite; animation-delay: var(--d); }
.fr-milk { opacity: 0; transition: opacity 3s; }
.stg.milk .fr-milk { opacity: 0.32; }
.fr-dflow { opacity: 0; }
.stg.drain .fr-dflow { opacity: 1; animation: flow 0.6s linear infinite; }
.fr-drawer { transform-box: fill-box; transform-origin: 50% 100%; transition: transform 0.8s var(--ease), opacity 0.5s; }
.fr-dtop { opacity: 0; transition: opacity 0.4s; }
.stg.dr-out .fr-drawer { transform: translateY(17px) scale(1.12); }
.stg.dr-out .fr-dtop { opacity: 1; }
.stg.tab .fr-tab { animation: tabpush 0.4s ease-in-out 3; }
.stg.dr-gone .fr-drawer { opacity: 0; transform: translateY(26px) scale(1.6); }
.stg.dr-clean .fr-dtop ellipse { opacity: 0; }
.fr-baymuck { transition: opacity 1.2s; }
.stg.bay-clean .fr-baymuck { opacity: 0; }
.fr-sparkb, .fr-brush, .fr-pow { opacity: 0; transition: opacity 0.3s; }
.stg.bay-clean .fr-sparkb { opacity: 1; animation: twinkle 1s ease-in-out infinite; }
.stg.bay-scrub .fr-brush { opacity: 1; animation: scrubb 0.4s ease-in-out infinite; }
@keyframes scrubb { 50% { transform: translateX(14px); } }
.stg.pour .fr-pow { opacity: 1; }
.fr-scoop { transform-box: view-box; transform-origin: 136px -12px; transition: transform 0.6s var(--ease); }
.fr-pow { transform: translateY(-20px); transition: opacity 0.3s, transform 0.6s var(--ease); }
.stg.pour .fr-pow { transform: none; }
.stg.pour .fr-scoop { transform: rotate(-38deg); }
.fr-pow circle { fill: #ffffff; stroke: var(--ink); stroke-width: 0.8; opacity: 0; }
.stg.pour .fr-pow circle { animation: powfall 0.7s linear infinite; animation-delay: var(--d); }
@keyframes powfall { 0% { opacity: 0; transform: translateY(0); } 20% { opacity: 1; } 100% { opacity: 0; transform: translate(-4px, 34px); } }

/* The sink close-up (step 9) */
.stg[data-k="drawer"] .cam-b { opacity: 0; }
.stg.cut-b .cam-b { opacity: 1; }
.stg.cut-b .cam-a { opacity: 0; }
.tray text { font: 800 15px var(--sans); fill: var(--accent-deep); text-anchor: middle; paint-order: stroke; stroke: rgba(255, 255, 255, 0.85); stroke-width: 4px; }
.tt-capg { transition: transform 0.9s var(--pop); }
.stg.cap-off .tt-capg { transform: translate(64px, -30px) rotate(14deg); transform-box: fill-box; transform-origin: center; }
.tt-muck { transition: opacity 1.6s; }
.stg.tray-clean .tt-muck { opacity: 0; }
.tt-brush { opacity: 0; transform: translate(120px, 170px); transition: opacity 0.3s; }
.stg.scrub .tt-brush { opacity: 1; animation: scrubt 2.4s ease-in-out infinite; }
@keyframes scrubt { 0% { transform: translate(110px, 170px); } 12% { transform: translate(170px, 160px); } 25% { transform: translate(120px, 150px); } 38% { transform: translate(180px, 90px); } 50% { transform: translate(110px, 80px); } 62% { transform: translate(290px, 100px); } 75% { transform: translate(270px, 180px); } 88% { transform: translate(300px, 140px); } 100% { transform: translate(110px, 170px); } }
.tt-foam circle { opacity: 0; transform-box: fill-box; transform-origin: center; }
.stg.scrub .tt-foam circle { animation: foamy 1.8s ease-out infinite; animation-delay: calc(var(--i) * 0.17s); }
@keyframes foamy { 0% { opacity: 0; transform: scale(0.3); } 30% { opacity: 0.95; } 100% { opacity: 0; transform: scale(1.3) translateY(-8px); } }
.tt-spark { opacity: 0; }
.stg.tray-clean .tt-spark { opacity: 1; animation: twinkle 1s ease-in-out infinite; }
.stg-photo { position: absolute; z-index: 4; left: 12px; top: 12px; display: flex; gap: 6px; }
.stg-photo b { padding: 4px 10px; border-radius: 8px; background: #fff; color: var(--ink); font-size: 13px; font-weight: 800; box-shadow: 0 6px 14px -8px rgba(0, 0, 0, 0.6); opacity: 0; transform: scale(0.6) rotate(-4deg); transition: opacity 0.3s, transform 0.5s var(--pop); }
.stg-photo i { display: none; }
.stg.ph-before .ph-b, .stg.ph-after .ph-a { opacity: 1; transform: rotate(-4deg); }

/* Steps 3 and 15: the washer with the endoscope in, its cable to the phone held upright on the right. */
.fr-probe { display: none; }
.stg.probe .fr-probe { display: inline; }
.fr-ptip circle:first-child { animation: twinkle 1.2s ease-in-out infinite; }
.stg-probe { --ar: 400 / 330; }
.stg-probe .stg-tag { left: 12px; top: auto; bottom: 12px; translate: 0 0; }
.pr-phone { position: absolute; z-index: 4; right: 3.5%; top: 50%; translate: 0 -44%; width: 28%; aspect-ratio: 9 / 18; border-radius: 16px; background: #0b1416; border: 3px solid #0b1416; box-shadow: 0 0 0 2px #46605d, 0 18px 30px -12px rgba(0, 0, 0, 0.6); overflow: hidden; transform: rotate(3deg); }
.pr-phone::before { content: ""; position: absolute; z-index: 3; left: 50%; top: 5px; width: 30%; height: 6px; translate: -50% 0; border-radius: 99px; background: #0b1416; }
.pr-feed { position: absolute; inset: 0; border-radius: 13px; overflow: hidden; }
.pr-feed svg { width: 100%; height: 100%; display: block; transition: transform 1s var(--ease); transform-origin: 50% 70%; }
.stg.af .pr-feed svg { transform: scale(1.45); }
.pr-rec { position: absolute; z-index: 3; left: 50%; top: 16px; translate: -50% 0; display: flex; align-items: center; gap: 4px; padding: 2px 7px; border-radius: 99px; background: rgba(0, 0, 0, 0.55); color: #fff; font: 800 10px var(--mono); white-space: nowrap; }
.pr-rec i { width: 7px; height: 7px; border-radius: 50%; background: #ff3b30; animation: twinkle 1s ease-in-out infinite; }
.pr-rec b { font-weight: 700; }
.pr-cap { position: absolute; z-index: 3; left: 0; right: 0; bottom: 0; padding: 14px 4px 8px; background: linear-gradient(transparent, rgba(0, 0, 0, 0.7)); text-align: center; color: rgba(255, 255, 255, 0.85); font-size: 10px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
html:not([lang^="zh"]) .pr-cap { font-size: 8.5px; }
.pr-phone .stg-af { width: 56%; aspect-ratio: 1.2; top: 62%; }
.pr-phone .stg-ok { font-size: 13px; padding: 4px 10px; white-space: nowrap; }
/* The endoscope's picture (steps 3 and 15) */
.scopev { animation: led 2.6s ease-in-out infinite; }
@keyframes led { 50% { filter: brightness(1.08); } }
.sf-strip { transition: transform 0.25s linear; }
.sf-jet { opacity: 0; transition: opacity 0.3s; }
.stg.jet .sf-jet { opacity: 1; }
.stg.jet .sf-jet path { animation: beamj 0.18s linear infinite; }
@keyframes beamj { 50% { opacity: 0.55; } }
.sf-spot { transition: opacity 1s 0.3s, transform 1.2s var(--ease); transform-box: fill-box; transform-origin: center; }
.stg.blast .sf-spot { opacity: 0; transform: scale(0.5) translateX(20px); }
.sf-bits circle { opacity: 0; }
.stg.blast .sf-bits circle { animation: bits 1.1s var(--ease) both; }
@keyframes bits { 0% { opacity: 1; transform: none; } 100% { opacity: 0; transform: translate(var(--dx), var(--dy)); } }
.stg.clean .scopev { filter: brightness(1.18) saturate(1.1); animation: none; }
.stg-af { position: absolute; z-index: 4; left: 50%; top: 50%; width: 26%; aspect-ratio: 1.6; translate: -50% -50%; border: 2px solid #ffd76a; border-radius: 8px; opacity: 0; box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.2); }
.stg.af .stg-af { opacity: 1; animation: afhunt 0.7s var(--ease) both; }
.stg-clock { position: absolute; z-index: 4; right: 10px; bottom: 10px; padding: 2px 9px; border-radius: 6px; background: rgba(0, 0, 0, 0.6); color: #fff; font: 700 13px var(--mono); }
.stg-mini { position: absolute; z-index: 4; right: 10px; top: 10px; width: 46px; height: 46px; padding: 3px; border-radius: 50%; background: rgba(0, 0, 0, 0.5); }
.stg-mini circle { fill: none; stroke: rgba(255, 255, 255, 0.35); stroke-width: 3; }
.stg-mini .mini-arc { fill: none; stroke: #5eead4; stroke-width: 3.4; stroke-linecap: round; stroke-dasharray: 100; stroke-dashoffset: var(--arc, 100); }
.stg-mini .mini-dot { transform-box: view-box; transform-origin: 20px 20px; transform: rotate(var(--a, 0deg)); }
.stg-mini .mini-dot circle { fill: #ffd76a; stroke: none; }
.stg-ok { position: absolute; z-index: 4; left: 50%; top: 50%; transform: translate(-50%, -50%) scale(0.6); padding: 6px 16px; border-radius: 99px; background: var(--accent); color: #fff; font-weight: 900; font-size: 18px; opacity: 0; transition: opacity 0.4s, transform 0.5s var(--pop); }
.stg.clean .stg-ok { opacity: 1; transform: translate(-50%, -50%) scale(1); }

/* The door seal (step 4), through the same viewfinder as step 1 */
.gk-ok { opacity: 0; transform-box: fill-box; transform-origin: center; transform: scale(0.4); transition: opacity 0.3s, transform 0.5s var(--pop); }
.vf.ok .gk-ok { opacity: 1; transform: none; }

/* Foam, close up (step 10) */
.foam2 .fb { opacity: 0; transform-box: fill-box; transform-origin: center; transform: scale(0.2); transition: opacity 0.8s, transform 1.2s var(--pop); transition-delay: calc(var(--i) * 0.03s); }
.stg[data-beat]:not([data-beat="0"]) .foam2 .fb { opacity: 1; transform: none; }
.stg[data-beat]:not([data-beat="0"]) .foam2 .fb circle { animation: bob 3s ease-in-out infinite; animation-delay: calc(var(--i) * -0.2s); }
.foam2 .cl circle { opacity: 0; transition: opacity 0.6s; }
.stg:is([data-beat="2"], [data-beat="3"]) .foam2 .cl circle { opacity: 1; }
.foam2 .fl { transition: transform 2.4s var(--ease); transition-delay: calc(var(--i) * 0.12s); }
.stg[data-beat="3"] .foam2 .fl { transform: translate(var(--sx), var(--up)); }
.foam2 .mx-lbl { font: 700 14px var(--sans); fill: var(--ink-2); }

/* Tap → pressure washer → wand (step 11) */
.rig2 .flow { opacity: 0; }
.stg:is(.tap-on, .pw-on, .wand-on) .rig2 .f1, .stg.wand-on .rig2 .f2 { opacity: 1; animation: flow 0.6s linear infinite; }
.rig2 .tap-h { transform-box: view-box; transform-origin: 54px 57px; transition: transform 0.6s var(--pop); }
.stg:is(.tap-on, .pw-on, .wand-on) .rig2 .tap-h { transform: rotate(90deg); }
.rig2 .needle { transform-box: view-box; transform-origin: 262px 214px; transition: transform 0.9s var(--pop); }
.stg:is(.pw-on, .wand-on) .rig2 .needle { transform: rotate(130deg); }
.stg:is(.pw-on, .wand-on) .rig2 .pw { animation: buzz 0.12s linear infinite; }
.rig2 .rg-led { transition: fill 0.3s; }
.stg:is(.pw-on, .wand-on) .rig2 .rg-led { fill: #5eead4; }
.rig2 .rg-brand { font: 900 9px var(--mono); fill: #ffd76a; }
.rig2 .mist path { opacity: 0; }
.stg.wand-on .rig2 .mist path { animation: mist 0.5s linear infinite; animation-delay: calc(var(--i) * 0.1s); }
.rig2 .mx-cap.sm { font: 800 14px var(--sans); fill: var(--ink); }

/* Three rinses (step 14): each chip carries the colour of what drained */
.stg-steps .sw { width: 14px; height: 18px; border: 2px solid currentColor; border-top: 0; border-radius: 0 0 6px 6px; background: transparent; transition: background 0.6s; }
.stg-steps li.g0 .sw { background: linear-gradient(180deg, #4a3220, #1e140c); }
.stg-steps li.g1 .sw { background: linear-gradient(180deg, #a2805a, #6b4a2a); }
.stg-steps li.g2 .sw { background: linear-gradient(180deg, #e3f8f4, #bfeee6); }
.stg-steps li.g0.lit { background: #5a3a1c; border-color: #5a3a1c; }
.stg-steps li.g1.lit { background: #a2805a; border-color: #a2805a; }

/* The story's scenes (story.js): bold colour, light, and motion while the scene is on. */
.sx { border-radius: 24px; box-shadow: 0 30px 60px -32px rgba(14, 60, 70, 0.75); background: #0f2a2e; }
.sx text { font: 800 15px var(--sans); }
.sx-pill text { font: 800 14px var(--sans); }
.sx .ip-anim svg g { transform-box: fill-box; transform-origin: center; }
.sc.on .sx-sun { animation: breathe 4s ease-in-out infinite; transform-box: fill-box; transform-origin: center; }
.sc.on .sx-cloud { animation: drift 14s ease-in-out infinite alternate; }
@keyframes drift { to { transform: translateX(26px); } }
.sx-win rect, .sx-star { animation: twinkle 2.6s ease-in-out infinite; animation-delay: var(--d); }
.sc.on .sx-ripple { animation: ripple 2.4s ease-in-out infinite alternate; }
@keyframes ripple { to { transform: translateX(14px); opacity: 0.3; } }
.sc.on .sx-wave { animation: ripple 2s ease-in-out infinite alternate; }
/* repair: the job's details fly into the system, row by row */
.sx-card { offset-path: path("M250 196 C 210 120 150 140 92 76"); offset-rotate: 0deg; opacity: 0; }
.sc.on .sx-card { animation: card 2.4s var(--ease) infinite; animation-delay: calc(0.4s + var(--i) * 0.8s); }
@keyframes card { 0% { offset-distance: 0%; opacity: 0; scale: 0.6; } 15% { opacity: 1; scale: 1; } 80% { opacity: 1; scale: 0.7; } 100% { offset-distance: 100%; opacity: 0; scale: 0.4; } }
.sx-row rect { transform-box: fill-box; transform-origin: 0 50%; transform: scaleX(0.1); opacity: 0.4; }
.sc.on .sx-row rect { animation: row 0.8s var(--ease) both; animation-delay: calc(1.2s + var(--i) * 0.8s); }
@keyframes row { to { transform: none; opacity: 1; } }
.sc.on .sx-spanner { animation: wrench 1.2s ease-in-out infinite; transform-box: fill-box; transform-origin: 50% 90%; }
@keyframes wrench { 50% { rotate: 22deg; } }
.sc.on .sx-spark { animation: twinkle 1.2s ease-in-out infinite; }
/* japan / back: the plane flies the route, blossom falls, stars twinkle */
.sx-flyer { offset-rotate: auto; offset-distance: 0%; }
.sx-to { offset-path: path("M70 230 Q 230 30 372 168"); }
.sx-home { offset-path: path("M410 120 Q 250 10 120 150"); }
.sc.on .sx-flyer { animation: fly2 2.6s 0.3s var(--ease) both; }
@keyframes fly2 { from { offset-distance: 0%; } to { offset-distance: 100%; } }
.sx-route { stroke-dashoffset: 0; }
.sc.on .sx-route { animation: dash 1s linear infinite; }
.sx-petal { opacity: 0; }
.sc.on .sx-petal { animation: petal var(--t) linear infinite; animation-delay: var(--d); }
@keyframes petal { 0% { opacity: 0; transform: translate(0, 0) rotate(0); } 10% { opacity: 1; } 100% { opacity: 0.8; transform: translate(var(--sx), 340px) rotate(540deg); } }
.sc.on .sx-neon path { animation: neon 1.8s steps(2) infinite; }
.sc.on .sx-neon path:nth-child(2n) { animation-delay: 0.6s; }
@keyframes neon { 50% { opacity: 0.35; } }
/* found: the bulb lights, the jet sprays, the gauge fills */
.sx-bulb { transform-box: fill-box; transform-origin: 50% 100%; }
.sc.on .sx-bulb { animation: bulb 0.7s 0.8s var(--pop) both; }
@keyframes bulb { from { scale: 0; opacity: 0; } }
.sc.on .sx-glow { animation: breathe 2.4s ease-in-out infinite; transform-box: fill-box; transform-origin: center; }
.sx-spray path { opacity: 0; }
.sc.on .sx-spray path { animation: mist 0.5s linear infinite; animation-delay: calc(var(--i) * 0.1s); }
.sx-gfill { stroke-dasharray: 100; stroke-dashoffset: 100; }
.sc.on .sx-gfill { animation: gauge 1.8s 0.9s var(--ease) forwards; }
.sx-num { font: 900 26px var(--mono) !important; fill: var(--accent-deep); }
.sx-lbl { font: 700 12.5px var(--sans) !important; fill: var(--ink-2); }
.sc.on .sx-nokit { animation: pop 0.6s 0.4s var(--pop) both; transform-box: fill-box; transform-origin: center; }
/* nodis: the parts fly off with warnings, then come home and it's whole */
.sx-pt { transform-box: view-box; }
.sc.on .sx-pt { animation: apart2 3.2s var(--ease) both; animation-delay: calc(0.3s + var(--i) * 0.04s); }
@keyframes apart2 { 0% { transform: none; } 18%, 66% { transform: translate(var(--dx), var(--dy)) rotate(var(--r)); } 82%, 100% { transform: translate(var(--ex), var(--ey)) rotate(var(--er)); } }
.sx-head { font: 900 17px var(--sans) !important; fill: #ffffff !important; }
html:not([lang^="zh"]) .sx-head { font-size: 14px !important; }
.sx-no { opacity: 0; transform-box: fill-box; transform-origin: center; }
.sc.on .sx-no { animation: ok 0.8s 2.9s var(--pop) both; }
.sx-nodis .sx-warn text { font-size: 15px; }
html:not([lang^="zh"]) .sx-nodis .sx-warn text { font-size: 12.5px; }
.sx-warn { opacity: 0; transform-box: fill-box; transform-origin: center; }
.sx-warn text { fill: #ffffff; font-size: 15px; }
.sc.on .sx-warn { animation: warn2 2.4s var(--pop) both; animation-delay: calc(0.68s + var(--i) * 0.38s); }
@keyframes warn2 { 0% { opacity: 0; scale: 0.3; } 12% { opacity: 1; scale: 1.12; } 20%, 60% { opacity: 1; scale: 1; } 100% { opacity: 0; scale: 0.9; } }
.sc.on .sx-shake { animation: scshake 0.4s linear 4; animation-delay: 0.7s; }
.sx-ok { opacity: 0; transform-box: fill-box; transform-origin: center; }
.sc.on .sx-ok { animation: ok 0.8s 3.4s var(--pop) both; }
/* ai: light runs down the lines, Fixes Baby types */
.sx-flow { stroke-dasharray: 14 160; stroke-dashoffset: 174; }
.sc.on .sx-flow { animation: aiflow 1.8s linear infinite; animation-delay: calc(var(--i) * 0.35s); }
@keyframes aiflow { to { stroke-dashoffset: 0; } }
.sx-chip-t { font: 900 28px var(--mono) !important; fill: #5eead4; }
.sc.on .sx-chip { animation: glow 1.6s ease-in-out infinite; }
.sx-node { animation: twinkle 2s ease-in-out infinite; animation-delay: var(--d); }
.sc.on .sx-dot { animation: typing 1s ease-in-out infinite; animation-delay: calc(var(--i) * 0.15s); }
@keyframes typing { 50% { transform: translateY(-4px); opacity: 0.5; } }

@media (max-width: 480px) { .finale-acts .route b { font-size: 15.5px; white-space: nowrap; } .finale-acts .route small { font-size: 13px; } .finale-acts .route { padding: 10px 10px 10px 14px; column-gap: 8px; } }
.finale .route > i { border-color: rgba(200, 255, 248, 0.35); color: #fff; }
.finale .route:hover { border-color: #5eead4; }
.finale .cta { box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.25) inset, 0 14px 40px -10px rgba(94, 234, 212, 0.8); }
.finale .end-links a { color: #8ff5e6; }
.finale .end-links .textver { color: rgba(220, 255, 250, 0.75); }

/* ---------------------------------------------------------------- */
/* Desktop: words left, picture right                                 */
/* ---------------------------------------------------------------- */

@media (min-width: 900px) {
  :root { --top-h: 76px; --nav-h: 88px; --baby: 110px; --fxc-right: 28px; --fxc-bottom: calc(var(--safe-b) + 12px); }
  .top { padding: 0 40px; }
  .lang { margin-left: 8px; }
  .nav { padding-left: 40px; }
  .nav-mid { flex: 0 1 300px; margin-left: 12px; }
  .sc { padding: 12px 6vw 28px; }
  .sc-hero { padding: calc(var(--top-h) + var(--safe-t) + 8px) 8vw calc(var(--nav-h) + var(--safe-b) - 40px); flex-direction: row-reverse; align-items: center; justify-content: center; gap: 4vw; }
  .sc-hero .copy { flex: 0 1 680px; }
  .hero-drop { flex: 0 1 420px; height: 70%; }
  .hero-drop .drop { width: min(22vw, 34vh, 62cqh, 260px); }
  .hero-drop { justify-content: center; }
  .hero-box { --ring: min(32vw, 52vh, 94cqh, 400px); flex: 0 1 460px; }
  .hero-bub p { font-size: 18px; }
  .routes { grid-template-columns: 1.25fr 1fr; max-width: 720px; }
  .copy p { font-size: 19px; }
  .copy .lead { font-size: 20px; }
  .sc-story { flex-direction: row-reverse; align-items: center; justify-content: center; gap: 5vw; }
  .sc-story .art { flex: 0 1 600px; height: 100%; }
  .sc-story .copy { flex: 0 1 500px; }
  .sc-flow { flex-direction: row; align-items: center; gap: 5vw; justify-content: center; }
  .sc-flow .copy { flex: 0 1 500px; }
  .sc-flow .vis { flex: 0 1 620px; height: 100%; place-items: center; }
  .duo { width: min(100%, 620px); }
  .sc-flow .duo:has(.wxw) { grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); align-items: center; }
  .wxw { width: min(100%, 460px); }
  .duo.mol { grid-template-columns: 1fr; }
  /* Desktop has room: draw the pictures big, fitScene scales down whatever still overflows. */
  .sc-flow .vis { flex: 0 1 760px; }
  .duo { width: min(100%, 760px); }
  .art-seal { width: min(100%, 460px); }
  .vf, .stg { width: min(100%, 540px); }
  .sc-flow .duo.stg-duo { grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); align-items: center; }
  .tube { width: 46px; height: 210px; }
  .tubes { gap: 26px; }
  .rack-bar { margin-top: -110px; margin-bottom: 98px; }
  .ba { width: min(100%, 560px); }
  .scope-phone { width: min(100%, 280px); }
  .art-crystal, .mcard, .art-react, .eqs, .art-break, .safe, .art-drawer, .art-foam, .art-rig { width: min(100%, 680px); }
  .prices { width: min(100%, 620px); }
  .sc-story .art { flex: 0 1 720px; }
  .sc-story .art svg { width: min(100%, 680px); }
  .finale { gap: 40px; }
}
@media (min-width: 1500px) and (min-height: 860px) {
  .sc-story .art { flex-basis: 900px; }
  .sc-story .art svg { width: min(100%, 900px); }
  .sc-hero .copy, .sc-story .copy, .sc-flow .copy { flex-basis: 600px; }
  .copy h2 { font-size: 64px; }
  .copy p { font-size: 21px; }
  .finale-acts { width: min(600px, 100%); }
}

@media (max-width: 899px) {
  .top { gap: 8px; }
  .track { position: absolute; left: 16px; right: 16px; bottom: 0; max-width: none; margin: 0; }
  .lang { margin-left: auto; }
  .lang button { min-width: 30px; height: 28px; padding: 0 6px; }
  .snd { min-height: 34px; padding: 0 8px; }
  .snd span { display: none; }
  .top-btn { min-height: 36px; padding: 6px 12px; font-size: 14px; }
  .top-btn .long { display: none; }
  .top-btn .short { display: inline; }
  .sc-flow { padding-top: 6px; gap: 10px; }
  .sc-flow .copy .kicker { margin-bottom: 6px; }
  .sc-flow .copy h2 { font-size: clamp(27px, 7.6vw, 38px); }
  .sc-flow .copy p { font-size: 16.5px; margin-top: 8px; line-height: 1.6; }
  html[lang="en"] .sc-flow .copy h2, html[lang="ja"] .sc-flow .copy h2 { font-size: clamp(22px, 6.2vw, 32px); }
  html[lang="en"] .sc-flow .copy p, html[lang="ja"] .sc-flow .copy p { font-size: 15px; line-height: 1.5; }
  .sc-story .copy p { font-size: 16.5px; }
  .sc-flow .duo:has(.wxw) { grid-template-columns: 1fr; }
  .wxw { width: min(100%, 300px); }
  .note, .quote { font-size: 14.5px; padding: 10px 14px; }
  .note b { font-size: 15.5px; }
}
@media (max-height: 720px) and (max-width: 899px) {
  .copy h2 { font-size: 27px; }
  .copy p { font-size: 15.5px; line-height: 1.55; }
}
/* Narrow phones (iPhone SE, 320px): the top bar has to fit logo, languages, sound and skip. */
@media (max-width: 379px) {
  .top { gap: 6px; padding-left: 12px; padding-right: 12px; }
  .lang { padding: 2px; }
  .lang button { min-width: 26px; padding: 0 4px; }
  .snd { padding: 0 7px; }
  .top-btn { padding: 6px 10px; font-size: 13px; }
  .top-btn .short { display: none; }
  .top-btn .tiny { display: inline; }
}
/* Phones held upright: the drop on the left, talking to the right, the clock on the ring's foot,
   so the drop keeps its size under the bubble's words. */
@media (max-width: 599px) and (orientation: portrait) {
  .hero-drop { flex-direction: row; align-items: center; gap: 4px; }
  .hero-box { --ring: min(46vw, 84cqh, 260px); flex: 0 0 48%; height: 100%; }
  .hero-drop .drop { width: min(30vw, 56cqh, 170px); }
  .hero-bub { order: 2; flex: 1; width: auto; margin: 0 0 0 8px; padding: 10px 12px; min-height: 92px; }
  .hero-bub::after { left: -11px; bottom: auto; top: 50%; margin: -9px 0 0; border: 0; border-left: 2px solid #16393f; border-bottom: 2px solid #16393f; }
  .hero-bub p { font-size: 15px; }
  html[lang="en"] .hero-bub p, html[lang="ja"] .hero-bub p { font-size: 13.5px; }
  .hb-busy { font-size: 13.5px; flex-wrap: wrap; justify-content: center; }
  .hero-clock { left: 50%; top: calc(50% + var(--ring) * 0.44); translate: -50% -50%; padding: 3px 9px 3px 3px; gap: 6px; }
  .hero-clock svg { width: 28px; height: 28px; }
  .hero-clock b { font-size: 15px; }
  .hero-clock small { font-size: 10.5px; margin-top: 1px; }
}
/* Tablets held upright: more room, so bigger words. */
@media (min-width: 600px) and (max-width: 899px) and (min-height: 800px) {
  .sc { padding-left: 6vw; padding-right: 6vw; }
  .copy h1 { font-size: 64px; }
  .copy h2, .sc-flow .copy h2 { font-size: 44px; }
  html[lang="en"] .sc-flow .copy h2, html[lang="ja"] .sc-flow .copy h2, html[lang="en"] .copy h2, html[lang="ja"] .copy h2 { font-size: 38px; }
  .copy p, .sc-flow .copy p, .sc-story .copy p { font-size: 19px; line-height: 1.65; }
  html[lang="en"] .sc-flow .copy p, html[lang="ja"] .sc-flow .copy p { font-size: 17.5px; }
  .sc-flow .copy .kicker { margin-bottom: 10px; }
  .routes { max-width: 640px; }
}
/* Phones turned sideways: words left, picture right, slimmer bars. */
@media (orientation: landscape) and (max-height: 520px) {
  .sc-flow .duo.stg-duo { grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); align-items: center; }
  .sc-flow .stg-duo :is(.note, .quote), .sc-flow .stg-duo .note :is(b, span) { font-size: 13px; line-height: 1.45; }
  .sc-flow .stg-duo .note { padding: 8px 10px; }
  .stg-steps { gap: 4px; }
  .stg-steps li { font-size: 11px; padding: 5px 1px; white-space: nowrap; letter-spacing: -0.02em; }
  :root { --top-h: 50px; --nav-h: 60px; }
  .top { padding-left: 16px; padding-right: 16px; }
  .sc { padding: 2px 4vw 4px; }
  .sc-hero { padding: calc(var(--top-h) + var(--safe-t)) 5vw calc(10px + var(--safe-b)); flex-direction: row-reverse; align-items: center; justify-content: center; gap: 4vw; }
  .sc-hero .copy { flex: 1 1 60%; }
  .hero-drop { flex: 0 1 36%; height: 100%; }
  .hero-drop .drop { width: min(22vw, 62cqh, 200px); }
  .hero-box { --ring: min(32vw, 94cqh, 300px); }
  .hero-bub { min-height: 48px; margin: 0 0 10px; padding: 6px 12px; }
  .hero-clock { left: 50%; top: calc(50% + var(--ring) * 0.44); translate: -50% -50%; }
  .hero-clock small { display: none; }
  .hero-bub p { font-size: 13px; }
  .hero-clock { padding: 4px 10px 4px 4px; }
  .hero-clock svg { width: 30px; height: 30px; }
  .hero-clock b { font-size: 15px; }
  .routes { grid-template-columns: 1fr; gap: 6px; margin-top: 10px; max-width: 440px; }
  .route { min-height: 46px; padding: 5px 10px; column-gap: 10px; }
  .route .ra, .route > i:last-child:not(.rn) { width: 30px; height: 30px; }
  .textver { margin-top: 4px; }
  .route .rn { width: 34px; height: 34px; font-size: 17px; }
  .route b { font-size: 16px; }
  .route small { font-size: 13px; }
  .sc-story, .sc-flow { flex-direction: row; align-items: center; justify-content: center; gap: 4vw; }
  .sc-story { flex-direction: row-reverse; }
  .sc-story .copy, .sc-flow .copy { flex: 0 1 46%; }
  .sc-story .art { flex: 0 1 50%; height: 100%; }
  .sc-flow .vis { flex: 1 1 50%; height: 100%; place-items: center; }
  .kicker, .sc-flow .copy .kicker { margin-bottom: 6px; font-size: 13px; }
  .copy h1 { font-size: clamp(26px, 9vh, 40px); }
  .copy h2, .sc-flow .copy h2, html[lang="en"] .sc-flow .copy h2, html[lang="ja"] .sc-flow .copy h2, html[lang="en"] .copy h2, html[lang="ja"] .copy h2 { font-size: clamp(20px, 6.6vh, 28px); }
  .copy p, .sc-flow .copy p, .sc-story .copy p, html[lang="en"] .sc-flow .copy p, html[lang="ja"] .sc-flow .copy p { font-size: 14px; line-height: 1.5; margin-top: 6px; }
  .copy .lead { font-size: 14.5px; }
  .cta { min-height: 44px; padding: 10px 22px; font-size: 16px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
}
html:not([lang^="zh"]) .sx-lbl { font-size: 8.5px !important; }
.sx { overflow: hidden; }
html:not([lang^="zh"]) .sx-warn text { font-size: 12px; }
