﻿/* ============ The Road to 14.12 ============ */
:root {
  --bg1: #ffe5ec;
  --bg2: #ffd6a5;
  --ink: #3b1f2b;
  --muted: #8a6b75;
  --pink: #ff6f91;
  --pink-d: #e0527a;
  --plum: #6e1f4a;
  --sage: #a9c3a0;
  --gold: #f6c453;
  --cream: #fff8f0;
  --radius: 22px;
  --shadow: 0 6px 0 rgba(110, 31, 74, .12), 0 12px 30px rgba(110, 31, 74, .12);
  --shadow-s: 0 3px 0 rgba(110, 31, 74, .12), 0 6px 14px rgba(110, 31, 74, .1);
  --hand: 'Caveat', cursive;
}

* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; }

/* ---------- scrollbars: a slim pink pill on a clear track, everywhere ---------- */
/* Chrome, Edge, Safari (scrollbar-color is left unset there, because it would switch off these rounded styles) */
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: transparent; margin: 14px; }
::-webkit-scrollbar-thumb { background: rgba(255, 111, 145, .55); border-radius: 999px; border: 3px solid transparent; background-clip: padding-box; }
::-webkit-scrollbar-thumb:hover { background-color: var(--pink); }
::-webkit-scrollbar-thumb:active { background-color: var(--pink-d); }
::-webkit-scrollbar-button { display: none; width: 0; height: 0; }
::-webkit-scrollbar-corner { background: transparent; }
/* Firefox */
@supports not selector(::-webkit-scrollbar) {
  * { scrollbar-width: thin; scrollbar-color: rgba(255, 111, 145, .6) transparent; }
}
body {
  font-family: 'Baloo 2', 'Noto Sans Sinhala', system-ui, sans-serif;
  color: var(--ink);
  background: linear-gradient(180deg, var(--bg1), var(--bg2)) fixed;
  -webkit-tap-highlight-color: transparent;
  overflow-x: hidden;
}
#app { max-width: 480px; margin: 0 auto; min-height: 100vh; padding: 0 16px 48px; }
button { font: inherit; color: inherit; cursor: pointer; }
a { color: var(--plum); }
[hidden] { display: none !important; }
h1, h2, h3 { line-height: 1.15; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .4em;
  border: 0; border-radius: 999px; padding: .7em 1.4em;
  background: var(--pink); color: #fff; font-weight: 800; font-size: 1rem;
  box-shadow: 0 5px 0 var(--pink-d); text-decoration: none; user-select: none;
  transition: transform .08s, box-shadow .08s;
}
.btn:active { transform: translateY(4px); box-shadow: 0 1px 0 var(--pink-d); }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.btn.ghost { background: #fff; color: var(--plum); box-shadow: 0 5px 0 #e7c9d4; }
.btn.big { font-size: 1.2rem; padding: .8em 1.8em; }
.btn.small { font-size: .85rem; padding: .45em 1em; box-shadow: 0 3px 0 var(--pink-d); }
.btn.ghost.small { box-shadow: 0 3px 0 #e7c9d4; }
.link { background: none; border: 0; color: var(--plum); text-decoration: underline; padding: 0; font-weight: 600; }
.link.center { display: block; margin: 14px auto 0; }

.icon-btn {
  width: 44px; height: 44px; flex: none; border-radius: 50%; border: 0; background: #fff;
  box-shadow: var(--shadow-s); font-size: 1.3rem; display: grid; place-items: center;
  text-decoration: none; color: var(--plum); position: relative; font-weight: 800;
}
.wallet-btn b {
  position: absolute; top: -4px; right: -4px; background: var(--pink); color: #fff;
  font-size: .7rem; border-radius: 999px; min-width: 18px; height: 18px; display: grid; place-items: center; padding: 0 4px;
}

/* ---------- generic ---------- */
.screen { animation: fadeIn .35s ease; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.topbar {
  position: sticky; top: 0; z-index: 10; display: flex; align-items: center; gap: 8px;
  padding: 12px 0; margin: 0 -16px 6px; padding-left: 16px; padding-right: 16px;
  background: rgba(255, 229, 236, .85); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
}
@media (max-width: 400px) { .topbar { gap: 6px; } .topbar .icon-btn { width: 38px; height: 38px; font-size: 1.1rem; } }
.topbar h2 { flex: 1; margin: 0; font-size: 1.05rem; text-align: center; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: var(--plum); }
.sub { color: var(--muted); text-align: center; margin: 4px 0 14px; }
.small { font-size: .9rem; color: var(--muted); }
.bubble {
  background: #fff; border-radius: 18px; padding: 10px 14px; box-shadow: var(--shadow-s);
  font-size: 1rem; line-height: 1.35; position: relative;
}
.bubble.wide { width: 100%; text-align: center; }
.pop { animation: popIn .35s; }
@keyframes popIn { from { transform: scale(.85); opacity: .4; } }
.shake { animation: shake .4s; }
@keyframes shake { 20%, 60% { transform: translateX(-6px); } 40%, 80% { transform: translateX(6px); } }
.preview-badge { background: #fff3c4; border: 2px dashed var(--gold); border-radius: 12px; padding: 4px 10px; text-align: center; font-size: .85rem; margin-bottom: 8px; }
.float-text { position: absolute; font-weight: 800; color: var(--plum); pointer-events: none; animation: floatUp .9s forwards; }
@keyframes floatUp { to { transform: translateY(-40px); opacity: 0; } }

/* ---------- intro ---------- */
.intro { text-align: center; padding-top: 28px; padding-bottom: 28px; display: flex; flex-direction: column; align-items: center; gap: 6px; position: relative; overflow: hidden; }
.clouds span { position: absolute; font-size: 2.4rem; opacity: .8; animation: drift 18s linear infinite; }
.clouds span:nth-child(1) { top: 6px; left: -10%; }
.clouds span:nth-child(2) { top: 70px; left: -30%; animation-duration: 24s; animation-delay: -8s; font-size: 1.8rem; }
.clouds span:nth-child(3) { top: 130px; left: -20%; animation-duration: 30s; animation-delay: -15s; }
@keyframes drift { to { transform: translateX(140vw); } }
.kicker { margin: 0; font-weight: 700; color: var(--pink); letter-spacing: .04em; text-transform: uppercase; font-size: .85rem; position: relative; }
.intro .title { font-size: clamp(2.3rem, 11vw, 3.3rem); margin: 0; color: var(--plum); text-shadow: 0 3px 0 #fff; position: relative; }
.title .num { color: var(--pink); display: inline-block; animation: wobble 2.4s ease-in-out infinite; }
@keyframes wobble { 50% { transform: rotate(-4deg) scale(1.06); } }
.subtitle { margin: 0; font-size: 1.1rem; color: var(--muted); }
.car-wrap { width: 100%; max-width: 340px; margin-top: 8px; animation: bob 1.2s ease-in-out infinite; position: relative; z-index: 1; }
.car-wrap svg { width: 100%; height: auto; }
.car-wrap { cursor: pointer; }
.car-wrap.honk { animation: honk .5s; }
@keyframes honk { 20% { transform: scale(1.06, .94); } 40% { transform: scale(.97, 1.04) translateY(-6px); } 70% { transform: scale(1.02, .98); } }
.car-wrap.drive-off { animation: driveOff 1.1s ease-in forwards; }
@keyframes bob { 50% { transform: translateY(-4px); } }
@keyframes driveOff { 20% { transform: translateX(-12px); } to { transform: translateX(120vw); } }
.wheel { transform-box: fill-box; transform-origin: center; animation: spin .9s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.road-strip { width: calc(100% + 32px); height: 30px; background: #4a4f5c; position: relative; margin-top: -20px; }
.road-strip::after {
  content: ''; position: absolute; left: 0; right: 0; top: 13px; height: 4px;
  background: repeating-linear-gradient(90deg, #fff 0 22px, transparent 22px 44px);
  animation: roadMove .5s linear infinite;
}
@keyframes roadMove { to { background-position: -44px 0; } }
.cast { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; width: 100%; margin: 14px 0 10px; }
.cast div { background: #fff; border-radius: 16px; padding: 8px; box-shadow: var(--shadow-s); }
.cast b { display: block; color: var(--plum); font-size: 1.1rem; }
.cast small { color: var(--muted); font-size: .8rem; line-height: 1.2; display: block; }

/* ---------- map ---------- */
.banner { background: #fff; border-radius: var(--radius); padding: 12px 16px; text-align: center; box-shadow: var(--shadow); margin: 4px 0 18px; font-size: 1.05rem; }
.road { position: relative; padding: 4px 0 10px; }
.road::before { content: ''; position: absolute; left: 50%; top: 0; bottom: 0; width: 58px; transform: translateX(-50%); background: #4a4f5c; border-radius: 29px; }
.road::after { content: ''; position: absolute; left: 50%; top: 22px; bottom: 22px; width: 4px; transform: translateX(-50%); background: repeating-linear-gradient(#fff 0 18px, transparent 18px 36px); }
.road-start, .road-end { position: relative; z-index: 1; margin: 6px auto 18px; width: max-content; background: var(--plum); color: #fff; padding: 6px 16px; border-radius: 999px; font-weight: 800; }
.road-end { margin: 6px auto 0; background: var(--pink); }
.stop { position: relative; z-index: 1; display: flex; align-items: center; width: 100%; border: 0; background: none; padding: 0; margin: 0 0 16px; min-height: 78px; text-align: left; }
.stop .pin {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); width: 56px; height: 56px; border-radius: 50%;
  background: #fff; display: grid; place-items: center; font-size: 1.6rem; box-shadow: 0 0 0 4px var(--gold), var(--shadow-s); z-index: 2;
}
.stop .label { width: calc(50% - 40px); background: #fff; border-radius: 16px; padding: 8px 12px; box-shadow: var(--shadow-s); display: flex; flex-direction: column; line-height: 1.2; }
.stop.l .label { margin-right: auto; }
.stop.r .label { margin-left: auto; }
.label small { color: var(--muted); font-weight: 700; font-size: .78rem; }
.label b { font-size: .98rem; color: var(--plum); }
.label em { font-style: normal; font-size: .78rem; color: var(--pink); font-weight: 700; margin-top: 2px; }
.stop.locked .pin { box-shadow: 0 0 0 4px #d8c4cc, var(--shadow-s); }
.stop.locked .label { opacity: .78; }
.stop.locked .label b { color: var(--muted); }
.stop.done .pin { box-shadow: 0 0 0 4px var(--pink), var(--shadow-s); }
.stop.open:not(.done) .pin { animation: pulse 1.6s infinite; }
@keyframes pulse { 50% { box-shadow: 0 0 0 10px rgba(246, 196, 83, .45), var(--shadow-s); } }
/* saga map (Candy-Crush style) */
.saga { position: relative; width: 100%; border-radius: 28px; overflow: hidden; box-shadow: var(--shadow); }
.saga::after { content: ''; position: absolute; top: 0; right: 0; bottom: 0; left: 0; inset: 0; border: 5px solid #fff; border-radius: inherit; pointer-events: none; z-index: 5; box-shadow: inset 0 0 24px rgba(110, 31, 74, .12); }
.saga-bg { position: absolute; top: 0; right: 0; bottom: 0; left: 0; inset: 0; width: 100%; height: 100%; display: block; }
.saga-bg text { text-anchor: middle; dominant-baseline: middle; transform-box: fill-box; }
.saga-bg .lm { filter: drop-shadow(0 4px 3px rgba(0, 0, 0, .2)); }
.saga-bg .bob { animation: floaty 3s ease-in-out infinite; }
.saga-bg .drift-x { animation: drift 9s ease-in-out infinite alternate; }
.trail-dash { animation: trail 1.1s linear infinite; }
@keyframes trail { to { stroke-dashoffset: -26; } }
.saga-sky { position: absolute; left: 0; right: 0; top: 0; height: 120px; pointer-events: none; }
.saga-sky span { position: absolute; }
.saga-sky .sun { right: 16px; top: 12px; font-size: 2.4rem; animation: glowPulse 3s ease-in-out infinite; }
.saga-sky .sx { font-size: 1.6rem; opacity: .9; animation: cloudDrift 26s linear infinite; }
.saga-sky .sx.a { top: 14px; } .saga-sky .sx.b { top: 56px; font-size: 1.2rem; animation-duration: 34s; animation-delay: -15s; }
.t-night .saga-sky .sx { animation: twinkle 2s ease-in-out infinite; } .t-night .saga-sky .sx.a { left: 18%; } .t-night .saga-sky .sx.b { left: 46%; }
.saga-finish { position: absolute; left: 50%; transform: translate(-50%, -50%); display: flex; flex-direction: column; align-items: center; z-index: 2; pointer-events: none; }
.saga-finish .cake { font-size: 4.2rem; line-height: 1; filter: drop-shadow(0 6px 6px rgba(0, 0, 0, .3)); }
.saga-finish .balloon { position: absolute; top: -18px; font-size: 2rem; animation: floaty2 2.6s ease-in-out infinite; }
.saga-finish .balloon.l { left: -38px; } .saga-finish .balloon.r { right: -38px; animation-delay: -1.3s; }
.saga-finish b { margin-top: 2px; background: var(--pink); color: #fff; padding: 4px 16px; border-radius: 999px; box-shadow: 0 4px 0 var(--pink-d); white-space: nowrap; }
.saga-finish small { margin-top: 6px; background: #fff; color: var(--plum); font-weight: 800; font-size: .75rem; padding: 0 10px; border-radius: 999px; box-shadow: var(--shadow-s); }
.saga-finish.all-done .cake { animation: pulse2 1s ease-in-out infinite; }
/* start gate: a banner on two posts over a checkered line across the road */
.saga-start { position: absolute; left: 50%; transform: translate(-50%, -50%); z-index: 2; pointer-events: none; display: flex; align-items: center; gap: 8px;
  padding: 4px 10px; background: linear-gradient(180deg, #8a2d60, var(--plum)); color: #fff; border: 3px solid #fff; border-radius: 12px;
  box-shadow: 0 4px 0 #4a1231, 0 8px 14px rgba(0, 0, 0, .22); animation: gateSway 3s ease-in-out infinite; }
.saga-start::before, .saga-start::after { content: ''; width: 16px; height: 16px; border-radius: 3px; border: 2px solid #fff;
  background: conic-gradient(#3b1f2b 25%, #fff 0 50%, #3b1f2b 0 75%, #fff 0) 0 0 / 8px 8px; }
.saga-start b { font-weight: 800; font-size: .9rem; letter-spacing: .14em; text-transform: uppercase; text-shadow: 0 2px 0 rgba(0, 0, 0, .25); }
@keyframes gateSway { 50% { transform: translate(-50%, -50%) rotate(-1.5deg); } }
.saga-sign { position: absolute; transform: translate(-50%, -50%); z-index: 1; pointer-events: none; }
.saga-sign span { display: block; position: relative; background: #ffd166; color: #3b1f2b; font-weight: 800; font-size: .68rem; padding: 3px 9px; border-radius: 6px; border: 2px solid #3b1f2b; transform: rotate(-4deg); white-space: nowrap; }
.saga-sign span::after { content: ''; position: absolute; left: 50%; top: 100%; width: 4px; height: 12px; background: #7a5a4a; transform: translateX(-50%); }
.lv { position: absolute; transform: translate(-50%, -50%); width: 66px; height: 66px; border: 0; background: none; padding: 0; z-index: 3; -webkit-tap-highlight-color: transparent; }
.lv-ball { position: relative; display: grid; place-items: center; width: 66px; height: 66px; border-radius: 50%; font-size: 1.8rem; border: 3px solid #fff;
  background: radial-gradient(circle at 34% 28%, #fff 0 7%, #ffb3c6 8%, #ff6f91 55%, #d63c6b);
  box-shadow: 0 6px 0 #b02a55, 0 10px 16px rgba(0, 0, 0, .25), inset 0 -5px 0 rgba(0, 0, 0, .12); transition: transform .15s; }
.lv:active .lv-ball { transform: translateY(4px); box-shadow: 0 2px 0 #b02a55, inset 0 -5px 0 rgba(0, 0, 0, .12); }
.lv.done .lv-ball { background: radial-gradient(circle at 34% 28%, #fff 0 7%, #ffe9a8 8%, #f6c453 55%, #d99a1e); box-shadow: 0 6px 0 #a8730f, 0 10px 16px rgba(0, 0, 0, .25), inset 0 -5px 0 rgba(0, 0, 0, .1); }
.lv.locked .lv-ball { font-size: 1.4rem; background: radial-gradient(circle at 34% 28%, #fff 0 7%, #eee8f0 8%, #c9c0cd 60%, #a69cab); box-shadow: 0 6px 0 #857b8a, 0 8px 12px rgba(0, 0, 0, .2); }
.lv-ball i { position: absolute; right: -8px; bottom: -6px; display: grid; place-items: center; width: 26px; height: 26px; border-radius: 50%; border: 2px solid #fff;
  background: var(--plum); color: #fff; font-style: normal; font-weight: 800; font-size: .78rem; }
.lv.current .lv-ball { animation: lvPulse 1.5s ease-in-out infinite; }
@keyframes lvPulse { 50% { transform: scale(1.08); box-shadow: 0 6px 0 #b02a55, 0 0 0 10px rgba(255, 209, 102, .55), 0 10px 16px rgba(0, 0, 0, .25); } }
.lv-stars { position: absolute; left: 50%; top: 100%; transform: translate(-50%, 2px); display: flex; font-size: .95rem; filter: drop-shadow(0 2px 1px rgba(0, 0, 0, .3)); }
.lv-stars b:nth-child(2) { transform: translateY(5px) scale(1.2); }
.lv-tag { position: absolute; top: 50%; transform: translateY(-50%); width: 122px; background: #fff; border-radius: 14px; padding: 5px 10px; box-shadow: var(--shadow-s);
  display: flex; flex-direction: column; text-align: left; line-height: 1.15; pointer-events: none; }
.lv-tag.to-left { right: calc(100% + 12px); } .lv-tag.to-right { left: calc(100% + 12px); }
.lv-tag small { color: var(--muted); font-weight: 700; font-size: .7rem; }
.lv-tag b { font-size: .85rem; color: var(--plum); }
.lv-tag em { font-style: normal; font-size: .7rem; color: var(--pink); font-weight: 800; margin-top: 1px; }
.lv.locked .lv-tag { background: rgba(255, 255, 255, .82); box-shadow: none; border: 2px dashed #d8c4cc; } .lv.locked .lv-tag b { color: var(--muted); }
.lv.locked .lv-tag em { color: var(--plum); white-space: nowrap; }
.lv.done .lv-tag { border-left: 4px solid var(--gold); } .lv.done .lv-tag em { color: #4f9a45; }
.lv.current.open:not(.done) .lv-tag { box-shadow: 0 0 0 3px var(--gold), var(--shadow-s); }
.lv-now { position: absolute; top: -10px; right: 8px; background: var(--gold); color: var(--ink); font-size: .62rem; font-weight: 800; padding: 1px 8px; border-radius: 999px; box-shadow: 0 2px 0 #c99a2e; animation: pulseBtn 1.2s ease-in-out infinite; }
.avatar { position: absolute; z-index: 4; transform: translate(-50%, calc(-100% - 40px)); transition: left 1.6s ease-in-out, top 1.6s cubic-bezier(.5, 0, .3, 1); pointer-events: none; }
.avatar.no-anim { transition: none; }
.av-bubble { display: flex; align-items: flex-end; gap: 0; background: #fff; border-radius: 999px; padding: 3px 7px 0; border: 3px solid var(--pink); box-shadow: 0 4px 10px rgba(0, 0, 0, .25);
  position: relative; animation: bob 1.1s ease-in-out infinite; }
.av-bubble::after { content: ''; position: absolute; left: 50%; top: 100%; transform: translateX(-50%); border: 8px solid transparent; border-top-color: var(--pink); }
.avatar.hopping .av-bubble { animation: hop .4s ease-in-out infinite; }
@keyframes hop { 50% { transform: translateY(-14px); } }

/* map: greeting, journey bar, landscape, landmarks, signs, driving car, finish arch */
.greet { display: flex; align-items: center; gap: 8px; width: 100%; border: 0; background: none; padding: 0; margin: 0 0 10px; text-align: left; cursor: pointer; }
.greet-face { flex: none; animation: bob 2.4s ease-in-out infinite; }
.greet .bubble { flex: 1; font-size: .95rem; }
.greet .bubble::before { content: ''; position: absolute; left: -7px; top: 50%; border: 7px solid transparent; border-right-color: #fff; border-left: 0; transform: translateY(-50%); }
.journey { display: flex; align-items: center; gap: 8px; margin-top: 10px; }
.journey .track { position: relative; flex: 1; height: 10px; background: #f3dfe6; border-radius: 999px; }
.journey .track i { position: absolute; left: 0; top: 0; bottom: 0; background: linear-gradient(90deg, var(--pink), var(--gold)); border-radius: 999px; transition: width .8s; }
.journey .track b { position: absolute; top: -22px; transform: translateX(-50%); transition: left .8s; }
.land { position: relative; border-radius: 28px; overflow: hidden; box-shadow: var(--shadow); background: linear-gradient(180deg, #c9eab0, #a9d98c 40%, #9bd17a); padding-bottom: 8px; }
.land.t-night { background: linear-gradient(180deg, #4f7a5a, #3e6649 50%, #355b40); }
.land.t-evening { background: linear-gradient(180deg, #d9e6a0, #b5d98c 40%, #9bc97a); }
.sky-band { position: relative; height: 92px; overflow: hidden; background: linear-gradient(180deg, #87ceeb, #d6f0ff); border-bottom: 6px solid rgba(255, 255, 255, .35); }
.t-morning .sky-band { background: linear-gradient(180deg, #ffd6a5, #bde8ff); }
.t-evening .sky-band { background: linear-gradient(180deg, #ff9a8b, #ffd6a5); }
.t-night .sky-band { background: linear-gradient(180deg, #151842, #3a2a6b); }
.sky-band span { position: absolute; }
.sky-band .sun { right: 18px; top: 12px; font-size: 2.6rem; animation: glowPulse 3s ease-in-out infinite; }
@keyframes glowPulse { 50% { transform: scale(1.08); filter: drop-shadow(0 0 10px rgba(255, 230, 120, .8)); } }
.sky-band .cl { font-size: 2rem; opacity: .9; animation: cloudDrift 22s linear infinite; }
.sky-band .c1 { top: 10px; } .sky-band .c2 { top: 44px; font-size: 1.5rem; animation-duration: 30s; animation-delay: -12s; } .sky-band .c3 { top: 24px; font-size: 1.2rem; animation-duration: 36s; animation-delay: -24s; }
@keyframes cloudDrift { from { left: -15%; } to { left: 105%; } }
.sky-band .bird { top: 30px; animation: cloudDrift 14s linear infinite; font-size: 1.1rem; }
.sky-band .st { font-size: .9rem; animation: twinkle 2s ease-in-out infinite; }
.st.s1 { left: 12%; top: 18px; } .st.s2 { left: 34%; top: 48px; animation-delay: -.6s; } .st.s3 { left: 56%; top: 14px; animation-delay: -1.2s; } .st.s4 { left: 74%; top: 56px; animation-delay: -.3s; }
.land .road { padding-top: 18px; }
.road-deco { position: absolute; top: 0; right: 0; bottom: 0; left: 0; inset: 0; pointer-events: none; }
.road-deco span { position: absolute; opacity: .85; }
.t-night .road-deco span { opacity: .55; }
.road::after { animation: roadMove 1.2s linear infinite; }
@keyframes roadMove { to { background-position: 0 36px; } }
.landmark { position: absolute; top: 50%; transform: translateY(-50%); font-size: 2rem; filter: drop-shadow(0 3px 2px rgba(0, 0, 0, .15)); }
.stop.l .landmark { right: 4px; } .stop.r .landmark { left: 4px; }
.landmark.hidden-lm { opacity: .45; font-size: 1.4rem; }
.road-sign { position: relative; z-index: 1; display: flex; margin: -6px 0 10px; }
.road-sign.l { justify-content: flex-start; padding-left: 8px; } .road-sign.r { justify-content: flex-end; padding-right: 8px; }
.road-sign span { position: relative; background: #ffd166; color: #3b1f2b; font-weight: 800; font-size: .72rem; padding: 4px 10px; border-radius: 6px; border: 2px solid #3b1f2b; transform: rotate(-3deg); }
.road-sign.r span { transform: rotate(3deg); }
.road-sign span::after { content: ''; position: absolute; left: 50%; top: 100%; width: 4px; height: 14px; background: #7a5a4a; transform: translateX(-50%); }
.road-car { position: absolute; z-index: 3; left: calc(50% + 34px); top: 0; transition: top 1.8s cubic-bezier(.5, 0, .3, 1), left 1.8s ease-in-out; pointer-events: none; }
.road-car.no-anim { transition: none; }
.road-car svg { display: block; animation: bob 1s ease-in-out infinite; }
.road-car.flip svg { transform: scaleX(-1); }
.road-car.driving svg { animation: bob .25s ease-in-out infinite; }
.finish { position: relative; text-align: center; padding: 6px 0 12px; }
.finish .arch { display: inline-flex; align-items: center; gap: 6px; background: var(--pink); color: #fff; padding: 8px 18px; border-radius: 999px 999px 14px 14px; box-shadow: 0 5px 0 var(--pink-d); font-size: 1rem; }
.finish .arch span { font-size: 1.4rem; animation: floaty2 2.4s ease-in-out infinite; } .finish .arch .b2 { animation-delay: -1.2s; }
@keyframes floaty2 { 50% { transform: translateY(-6px) rotate(6deg); } }
.finish small { display: block; margin-top: 8px; font-weight: 700; color: #3b1f2b; }
.t-night .finish small { color: #fff; }
.finish.party .arch { animation: pulse2 1s ease-in-out infinite; }
@keyframes pulse2 { 50% { transform: scale(1.06); } }
.car-marker { position: absolute; top: 50%; transform: translateY(-50%); animation: bob 1s ease-in-out infinite; }
.stop.l .car-marker { right: 0; }
.stop.r .car-marker { left: 0; }
.stop.r .car-marker svg { transform: scaleX(-1); }
.foot { text-align: center; color: var(--muted); margin-top: 28px; font-size: .9rem; display: flex; flex-direction: column; gap: 4px; align-items: center; }

/* ---------- chapter ---------- */
.scene { position: relative; height: 300px; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.scene-art { position: absolute; top: 0; right: 0; bottom: 0; left: 0; inset: 0; }
.scene-art svg { display: block; width: 100%; height: 100%; }
.prop { position: absolute; font-size: 2.2rem; animation: float 4s ease-in-out infinite; }
.p0 { left: 7%; top: 18%; }
.p1 { right: 8%; top: 10%; animation-delay: -1s; }
.p2 { left: 20%; top: 44%; font-size: 1.6rem; animation-delay: -2s; }
.p3 { right: 18%; top: 42%; font-size: 1.6rem; animation-delay: -3s; }
@keyframes float { 50% { transform: translateY(-8px) rotate(5deg); } }
.place { position: absolute; left: 10px; top: 10px; background: rgba(255, 255, 255, .88); border-radius: 999px; padding: 2px 10px; font-size: .82rem; font-weight: 700; }
.actors { position: absolute; left: 0; right: 0; bottom: 4px; display: flex; justify-content: center; align-items: flex-end; }
.actor-wrap { position: relative; cursor: pointer; -webkit-tap-highlight-color: transparent; }
.actors.enter .actor-wrap:first-child { animation: walkInL 1s cubic-bezier(.3, 1.3, .6, 1) backwards; }
.actors.enter .actor-wrap:last-child { animation: walkInR 1s .15s cubic-bezier(.3, 1.3, .6, 1) backwards; }
@keyframes walkInL { from { transform: translateX(-160px) rotate(-8deg); opacity: 0; } 60% { opacity: 1; } }
@keyframes walkInR { from { transform: translateX(160px) rotate(8deg); opacity: 0; } 60% { opacity: 1; } }
.actor { transform-origin: bottom center; }
.actor svg { display: block; transform-origin: bottom center; }
.actor:not(.talking) svg { animation: idle 2.8s ease-in-out infinite; }
.actor-wrap:last-child .actor:not(.talking) svg { animation-delay: -1.4s; }
@keyframes idle { 50% { transform: scaleY(.985) translateY(1px); } }
.actor.talking { animation: talk .45s ease-in-out infinite alternate; }
@keyframes talk { to { transform: translateY(-6px) scale(1.03); } }
.react-bubble { position: absolute; left: 50%; top: -6px; transform: translateX(-50%); white-space: nowrap; background: #fff; border-radius: 14px; padding: 4px 10px;
  font-size: .85rem; font-weight: 800; color: var(--plum); box-shadow: var(--shadow-s); animation: reactPop 1.8s forwards; pointer-events: none; z-index: 3; }
@keyframes reactPop { 0% { opacity: 0; transform: translate(-50%, 10px) scale(.6); } 12% { opacity: 1; transform: translate(-50%, 0) scale(1.05); } 80% { opacity: 1; transform: translate(-50%, -4px); } 100% { opacity: 0; transform: translate(-50%, -14px); } }
.heart-float { position: absolute; font-size: 1.1rem; pointer-events: none; animation: heartUp 1.8s ease-out forwards; z-index: 2; }
@keyframes heartUp { from { opacity: 0; transform: translateY(0) scale(.5); } 15% { opacity: 1; } to { opacity: 0; transform: translateY(-90px) translateX(var(--dx, 0)) scale(1.2); } }
.title-card { position: absolute; top: 0; right: 0; bottom: 0; left: 0; inset: 0; z-index: 5; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px;
  background: rgba(59, 31, 43, .78); color: #fff; text-align: center; animation: titleCard 2s forwards; pointer-events: none; }
.title-card small { font-weight: 800; letter-spacing: .12em; color: var(--gold); font-size: .85rem; }
.title-card b { font-size: 1.7rem; line-height: 1.1; padding: 0 16px; }
.title-card span { font-size: 2.2rem; }
@keyframes titleCard { 0% { opacity: 0; transform: scale(1.08); } 15%, 72% { opacity: 1; transform: none; } 100% { opacity: 0; visibility: hidden; } }
/* living backgrounds (SVG groups) */
.scene-art g, .scene-art circle, .scene-art path, .scene-art text { transform-box: fill-box; }
.scene-art .drift { animation: drift 14s ease-in-out infinite alternate; }
@keyframes drift { from { transform: translateX(-14px); } to { transform: translateX(22px); } }
.scene-art .sway { transform-origin: 50% 100%; animation: sway 4s ease-in-out infinite alternate; }
@keyframes sway { from { transform: rotate(-2.5deg); } to { transform: rotate(2.5deg); } }
.scene-art .twinkle { animation: twinkle 2.4s ease-in-out infinite; }
@keyframes twinkle { 50% { opacity: .25; } }
.scene-art .glow { transform-origin: center; animation: glow 3s ease-in-out infinite; }
@keyframes glow { 50% { transform: scale(1.12); opacity: .25; } }
.scene-art .floaty { animation: floaty 3.4s ease-in-out infinite; }
@keyframes floaty { 50% { transform: translateY(-9px); } }
.scene-art .steam { animation: steam 2.2s ease-in-out infinite; }
@keyframes steam { 0% { transform: translateY(6px); opacity: 0; } 40% { opacity: .8; } 100% { transform: translateY(-10px); opacity: 0; } }
.scene-art .wave { animation: wave .7s steps(2) infinite alternate; }
@keyframes wave { to { transform: translateY(-2px); } }
.scene-art .swim { animation: swim 7s ease-in-out infinite alternate; }
@keyframes swim { from { transform: translateX(-18px) translateY(2px); } to { transform: translateX(18px) translateY(-3px); } }
.scene-art .rise { animation: riseUp 5s linear infinite; }
@keyframes riseUp { from { transform: translateY(20px); opacity: 0; } 20% { opacity: .7; } to { transform: translateY(-60px); opacity: 0; } }
.scene-art .flutter { animation: flutter 3s ease-in-out infinite; }
@keyframes flutter { 25% { transform: translate(8px, -6px) rotate(8deg); } 50% { transform: translate(14px, 2px); } 75% { transform: translate(4px, 6px) rotate(-6deg); } }
.scene-art .moon { cursor: pointer; }
/* blinking characters */
.blink { transform-box: fill-box; transform-origin: center; animation: blink 4.6s infinite; }
@keyframes blink { 0%, 93%, 100% { transform: scaleY(1); } 96% { transform: scaleY(.1); } }
.dialog { background: #fff; border-radius: var(--radius); padding: 16px 16px 14px; margin-top: 18px; box-shadow: var(--shadow); position: relative; }
.speaker { position: absolute; top: -14px; left: 16px; padding: 2px 14px; border-radius: 999px; color: #fff; font-weight: 800; font-size: .9rem; }
.speaker.koko { background: #5f7d58; }
.speaker.malak { background: var(--plum); }
.line { min-height: 4.4em; margin: .3em 0 .6em; font-size: 1.1rem; line-height: 1.45; }
.dialog-actions { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.dots { display: flex; align-items: center; gap: 4px; min-width: 0; flex: 0 1 auto; }
.dots i { flex: 0 1 8px; min-width: 4px; aspect-ratio: 1; border-radius: 50%; background: #eedde4; } /* shrink rather than wrap when a story is long */
.dialog-actions .btn { flex: none; max-width: 70%; }
.dots i.on { background: var(--pink); }

/* ---------- play ---------- */
.how { background: rgba(255, 255, 255, .75); border-radius: 14px; padding: 8px 12px; margin: 0 0 12px; font-size: .95rem; text-align: center; }
.how.flash { animation: howFlash 1.2s ease; }
@keyframes howFlash { 0%, 100% { background: rgba(255, 255, 255, .75); transform: none; } 20% { background: #fff; transform: scale(1.03); box-shadow: 0 0 0 3px var(--pink); } }
.how-intro { background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); padding: 28px 20px 24px; margin-top: 8px;
  text-align: center; display: flex; flex-direction: column; align-items: center; gap: 10px; animation: howIn .35s ease; }
.how-intro-icon { font-size: 3rem; line-height: 1; }
.how-intro h2 { margin: 0; color: var(--plum); }
.how-intro p { margin: 0 0 8px; font-size: 1.1rem; line-height: 1.5; max-width: 32ch; }
@keyframes howIn { from { opacity: 0; transform: translateY(10px) scale(.97); } }
.stage { display: flex; flex-direction: column; align-items: center; gap: 12px; }
.stage[hidden], .how[hidden] { display: none; }
.hud { width: 100%; display: flex; justify-content: space-between; align-items: center; gap: 10px; background: #fff; border-radius: 999px; padding: 6px 16px; box-shadow: var(--shadow-s); font-weight: 700; }
.progress { flex: 1; height: 10px; background: #f3dfe6; border-radius: 999px; overflow: hidden; }
.progress i { display: block; height: 100%; width: 0; background: linear-gradient(90deg, var(--pink), var(--gold)); transition: width .3s; }
.game-canvas { border-radius: 18px; box-shadow: var(--shadow); touch-action: none; display: block; max-width: 100%; }
.pad { display: flex; gap: 18px; }
.pad-btn { width: 88px; height: 58px; font-size: 1.4rem; }

/* memory */
.mm-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; width: 100%; }
.mm-card { aspect-ratio: 3 / 4; border: 0; background: none; padding: 0; perspective: 600px; }
.mm-inner { position: relative; display: block; width: 100%; height: 100%; transition: transform .45s; transform-style: preserve-3d; }
.mm-card.flip .mm-inner, .mm-card.match .mm-inner { transform: rotateY(180deg); }
.mm-front, .mm-back { position: absolute; top: 0; right: 0; bottom: 0; left: 0; inset: 0; border-radius: 14px; display: grid; place-items: center; backface-visibility: hidden; -webkit-backface-visibility: hidden; font-size: 2rem; box-shadow: var(--shadow-s); }
.mm-front { background: linear-gradient(135deg, var(--pink), var(--plum)); color: #fff; font-size: 1.4rem; }
.mm-back { background: #fff; transform: rotateY(180deg); }
.mm-card.match .mm-back { background: #fff3c4; box-shadow: 0 0 0 3px var(--gold); }
.mm-caption { min-height: 2.6em; text-align: center; font-weight: 800; color: var(--plum); margin: 0; font-size: 1.1rem; }

/* cook */
.cook { width: 100%; display: flex; flex-direction: column; gap: 10px; }
.recipe-card { background: #fffdf5; border: 2px dashed #e8c99b; border-radius: 16px; padding: 8px 14px; }
.recipe-card h3 { margin: 0; font-size: 1.05rem; color: var(--plum); }
.recipe-card ol { margin: 4px 0 0; padding-left: 1.4em; columns: 2; column-gap: 18px; font-size: .88rem; }
.recipe-card li.done { text-decoration: line-through; color: #6aa95b; }
.kitchen { display: flex; align-items: center; gap: 8px; }
.kitchen .bubble { flex: 1; font-size: .95rem; }
.chef { flex: none; }
.recipe-card h4 { margin: 6px 0 0; font-size: .85rem; color: var(--pink); }
.marinade-list { list-style: none; margin: 2px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 2px 10px; font-size: .88rem; }
.marinade-list li.done, .marinade-list.done li { text-decoration: line-through; color: #6aa95b; }
.cook-area { position: relative; display: flex; flex-direction: column; align-items: center; }
.bowl-wrap { position: relative; width: min(220px, 62vw); transition: all .6s ease; z-index: 2; }
.bowl-wrap .bowl { display: block; width: 100%; height: auto; touch-action: none; overflow: visible; }
.bowl-wrap.bump .bowl, .bowl.bump { animation: potBump .35s; }
.bowl-wrap.stir-me .bowl { cursor: grab; filter: drop-shadow(0 0 10px rgba(255, 209, 102, .9)); }
.bowl-spoon { display: none; position: absolute; font-size: 2rem; transform: translate(-50%, -70%) rotate(-30deg); pointer-events: none; transition: left .08s, top .08s; }
.bowl-label { position: absolute; left: 50%; bottom: -4px; transform: translateX(-50%); font-size: .72rem; font-weight: 800; color: var(--plum); background: #fff; border-radius: 999px; padding: 1px 8px; box-shadow: var(--shadow-s); white-space: nowrap; opacity: 0; transition: opacity .4s; }
/* once the marinade is ready, the bowl moves aside next to the stove */
.cook-area.marinating .stove-wrap { display: none; }
.cook-area.marinating .bowl-wrap { margin: 10px 0 6px; }
.bowl-wrap.ready { position: absolute; right: 0; bottom: 6px; width: 92px; }
.bowl-wrap.ready .bowl-label { opacity: 1; }
.bowl-wrap.pouring { transform: translate(-50px, -40px) rotate(-35deg); }
.bowl-wrap.empty { opacity: 0; transform: scale(.5); }
.rest { margin: 0; font-weight: 800; color: var(--plum); animation: pulseBtn 1.2s ease-in-out infinite; }
.recipe-card li.now { font-weight: 800; color: var(--plum); background: #fff3c4; border-radius: 6px; }
.stove-wrap { position: relative; display: flex; justify-content: center; }
.stove { width: min(300px, 82vw); height: auto; touch-action: none; overflow: visible; }
.stove .flames { opacity: 0; transform-box: fill-box; transform-origin: 50% 100%; transform: scaleY(.2); transition: opacity .4s, transform .5s cubic-bezier(.3, 1.6, .5, 1); }
.stove-wrap.on .flames { opacity: 1; transform: scaleY(1); }
.stove .flame { transform-box: fill-box; transform-origin: 50% 100%; animation: flicker .35s ease-in-out infinite alternate; }
@keyframes flicker { to { transform: scale(.85, 1.15); } }
.stove .knob { cursor: pointer; }
.stove-wrap.on .knob-mark { transform: rotate(90deg); transform-box: fill-box; transform-origin: 50% 90%; }
.stove .boil { transform-box: fill-box; transform-origin: center; animation: boil 1.4s ease-in infinite; }
@keyframes boil { 0% { transform: scale(.2); opacity: 0; } 50% { opacity: 1; } 100% { transform: scale(1.3); opacity: 0; } }
.pot-steam path { animation: steam 2.2s ease-in-out infinite; transform-box: fill-box; }
.stove.bump { animation: potBump .35s; }
@keyframes potBump { 50% { transform: scale(1.04) rotate(-2deg); } }
.stove-wrap.stir-me .stove { cursor: grab; filter: drop-shadow(0 0 10px rgba(255, 209, 102, .9)); }
.fx-layer { position: absolute; top: 0; right: 0; bottom: 0; left: 0; inset: 0; pointer-events: none; overflow: visible; }
.drop { position: absolute; width: 8px; height: 8px; border-radius: 50%; animation: dropFly .65s ease-out forwards; }
@keyframes dropFly { to { transform: translate(var(--dx), var(--dy)) scale(.4); opacity: 0; } }
.pot-float { position: absolute; top: 30%; font-size: 1.5rem; animation: heartUp 2s ease-out forwards; }
.cook-ctl { display: flex; flex-direction: column; align-items: center; gap: 6px; min-height: 8px; }
.cook-ctl:empty { display: none; }
.pulse-btn { animation: pulseBtn 1.2s ease-in-out infinite; }
@keyframes pulseBtn { 50% { transform: scale(1.06); } }
.stir-bar { width: 70%; flex: none; height: 12px; }
.stir-hint { margin: 0; font-size: .8rem; color: var(--muted); }
.taster { display: flex; align-items: center; gap: 12px; }
.served { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; justify-content: center; animation: popIn .5s; }
.served .plate { font-size: 3.4rem; } .served .rice { font-size: 2.4rem; }
.served b { width: 100%; text-align: center; color: var(--plum); font-family: var(--hand); font-size: 1.4rem; }
.pot { font-size: 3.2rem; position: relative; line-height: 1; flex: none; }
.pot .steam { position: absolute; top: -22px; left: 50%; transform: translateX(-50%); font-size: 1.4rem; animation: steam 1.5s infinite; }
.pot.bump { animation: bump .35s; }
@keyframes bump { 50% { transform: scale(1.2) rotate(-6deg); } }
@keyframes steam { from { opacity: .8; } to { transform: translate(-50%, -14px); opacity: 0; } }
.shelf { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.ingredient { border: 0; background: #fff; border-radius: 14px; padding: 8px 2px 6px; font-size: 1.8rem; box-shadow: var(--shadow-s); display: flex; flex-direction: column; align-items: center; }
.ingredient small { font-size: .66rem; line-height: 1.1; margin-top: 2px; font-weight: 700; color: var(--muted); }
.ingredient:disabled { opacity: .25; }
.flyer { position: fixed; z-index: 50; font-size: 2rem; pointer-events: none; transition: transform .55s cubic-bezier(.5, -.4, .6, 1), opacity .55s; }

/* cricket */
.pitch { position: relative; width: 100%; height: 230px; border-radius: 18px; overflow: hidden; background: linear-gradient(#8fd3ff 0 38%, #5cb85c 38%); box-shadow: var(--shadow); }
.pitch::after { content: ''; position: absolute; left: 10%; right: 10%; bottom: 0; height: 34%; background: #d9c38f; border-radius: 8px 8px 0 0; opacity: .7; }
.crowd { position: absolute; top: 8px; width: 100%; text-align: center; font-size: 1.2rem; letter-spacing: 3px; animation: bob .8s infinite; }
.batter { position: absolute; left: 10%; bottom: 2px; z-index: 2; }
.batter .bat { position: absolute; right: -16px; bottom: 56px; font-size: 2rem; transform-origin: bottom left; }
.batter.swing .bat { animation: swingBat .35s; }
@keyframes swingBat { 50% { transform: rotate(-80deg); } }
.bowler { position: absolute; right: 8%; bottom: 46px; z-index: 2; }
.ball { position: absolute; width: 16px; height: 16px; border-radius: 50%; background: #c1121f; box-shadow: inset -3px -3px 0 rgba(0, 0, 0, .25); right: 18%; bottom: 60px; z-index: 3; }
.ball.six { animation: six 1s ease-out forwards; }
.ball.four { animation: four 1s ease-out forwards; }
.ball.miss { animation: miss .8s linear forwards; }
@keyframes six { 0% { right: 18%; bottom: 60px; } 25% { right: 70%; bottom: 66px; } 100% { right: -10%; bottom: 260px; transform: scale(.4); } }
@keyframes four { 0% { right: 18%; bottom: 60px; } 25% { right: 70%; bottom: 60px; } 100% { right: -10%; bottom: 14px; } }
@keyframes miss { to { right: 104%; bottom: 40px; } }
.shot-text { position: absolute; top: 34%; left: 0; right: 0; text-align: center; font-size: 1.6rem; font-weight: 800; color: #fff; text-shadow: 0 2px 0 var(--plum), 0 0 12px rgba(0, 0, 0, .3); opacity: 0; z-index: 4; }
.shot-text.show { animation: shotText 1.1s; }
@keyframes shotText { 15% { opacity: 1; transform: scale(1.25); } 80% { opacity: 1; transform: scale(1); } 100% { opacity: 0; } }
.meter { position: relative; width: 100%; height: 30px; background: #f3dfe6; border-radius: 999px; overflow: hidden; box-shadow: inset 0 2px 4px rgba(0, 0, 0, .1); }
.meter .z4 { position: absolute; top: 0; bottom: 0; background: #ffd59e; }
.meter .z6 { position: absolute; top: 0; bottom: 0; background: #7bd389; }
.meter .needle { position: absolute; top: 0; bottom: 0; width: 6px; margin-left: -3px; background: var(--plum); border-radius: 3px; }
.balls i { display: inline-block; width: 14px; height: 14px; border-radius: 50%; border: 2px solid var(--pink); margin-left: 4px; vertical-align: middle; }
.balls i.on { background: var(--pink); }
.reason-card { width: 100%; background: #fff; border-radius: 16px; padding: 12px 14px; box-shadow: var(--shadow); text-align: center; font-size: 1.05rem; min-height: 4.6em; }
.reason-card small { display: block; color: var(--pink); font-weight: 800; }

/* quiz */
.quiz { width: 100%; display: flex; flex-direction: column; gap: 12px; }
.quiz-host { display: flex; align-items: center; gap: 8px; width: 100%; }
.quiz-host .bubble { flex: 1; }
.q { margin: 4px 0; font-size: 1.3rem; text-align: center; color: var(--plum); }
.clue { font-size: 3rem; text-align: center; letter-spacing: 6px; }
.hint { margin: -6px 0 0; text-align: center; color: var(--muted); }
.options { display: grid; gap: 8px; width: 100%; }
.opt { border: 0; background: #fff; border-radius: 16px; padding: 12px 16px; font-weight: 700; font-size: 1rem; box-shadow: var(--shadow-s); text-align: left; }
.opt.right { background: #c8f2c2; }
.opt.wrong { background: #ffd0d6; }
.opt:disabled { cursor: default; }
.opt.mono { font-family: ui-monospace, 'Cascadia Code', Consolas, monospace; font-size: .9rem; }
.after { display: flex; flex-direction: column; align-items: center; gap: 10px; }
.after:empty { display: none; }
.dedication { font-family: var(--hand); font-size: 1.4rem; text-align: center; margin: 0; color: var(--plum); }

/* graduation (Day 5): convocation walk, exam paper, results + certificate */
.convo { width: 100%; display: flex; flex-direction: column; align-items: center; gap: 12px; }
.convo .progress { flex: none; width: 100%; }
.convo-stage { position: relative; width: 100%; height: 300px; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); background: #f3e2bf; cursor: pointer; touch-action: manipulation; }
.convo-mc { position: absolute; z-index: 3; top: 10px; left: 50%; transform: translateX(-50%); width: max-content; max-width: calc(100% - 24px); min-height: 1.4em;
  background: rgba(125, 20, 48, .92); color: #fff; font-weight: 800; font-size: .9rem; padding: 6px 14px; border-radius: 999px; text-align: center; box-shadow: var(--shadow-s); }
.convo-carpet { position: absolute; left: 0; right: 0; bottom: 0; height: 34px; background: linear-gradient(180deg, #b3121c, #7d1430); border-top: 4px solid #f2c14e; }
.convo-podium { position: absolute; z-index: 1; bottom: 30px; left: 62%; width: 54px; height: 66px; border-radius: 8px 8px 0 0; background: linear-gradient(180deg, #a87443, #7a5232); border-top: 5px solid #f2c14e; }
.convo-podium::after { content: '🎓'; position: absolute; left: 50%; top: 16px; transform: translateX(-50%); font-size: 1.4rem; }
.convo-scroll { position: absolute; left: 50%; top: -16px; width: 40px; height: 11px; margin-left: -20px; border-radius: 6px; background: #e3262f;
  box-shadow: inset 6px 0 0 #b3121c, inset -6px 0 0 #b3121c, inset 9px 0 0 #f2c14e, inset -9px 0 0 #f2c14e; transition: transform .6s cubic-bezier(.3, 1.5, .5, 1), opacity .6s .3s; }
.convo-scroll.given { transform: translate(-70px, -30px) rotate(-30deg) scale(1.2); opacity: 0; }
.convo-koko, .convo-lily { position: absolute; z-index: 2; bottom: 18px; }
.convo-koko { transition: left .45s ease-out; }
.convo-koko.hop svg { animation: hop .45s ease-out; }
.convo-lily { right: 3%; }
.convo-koko svg, .convo-lily svg { display: block; }
.react-bubble.stay { animation: none; top: -10px; }
.convo-lily .react-bubble.stay { left: auto; right: 0; transform: none; }
.react-bubble.stay.pop { animation: popIn .35s; }

.quiz.exam .paper { position: relative; background: #fffdf6; border-radius: 6px 6px 16px 16px; padding: 14px 16px 16px 30px; box-shadow: var(--shadow-s);
  background-image: linear-gradient(90deg, transparent 22px, #ffb3c6 22px 24px, transparent 24px), repeating-linear-gradient(180deg, transparent 0 27px, #dbe7f5 27px 28px); }
.paper-head { display: flex; flex-direction: column; align-items: center; text-align: center; border-bottom: 2px double #7d1430; padding-bottom: 6px; margin-bottom: 8px; }
.paper-head b { color: #7d1430; letter-spacing: .08em; text-transform: uppercase; font-size: .95rem; }
.paper-head small { color: var(--muted); font-size: .75rem; font-weight: 700; }
.paper-q { margin: 0; font-family: var(--hand); font-size: 1.6rem; line-height: 1.15; color: #23305e; }
.paper-q span { font-weight: 700; color: #7d1430; }
.paper-q em { font-family: 'Baloo 2', sans-serif; font-style: normal; font-size: .75rem; color: var(--muted); white-space: nowrap; }
.quiz.exam .opt { position: relative; display: flex; align-items: center; gap: 10px; }
.quiz.exam .opt b { flex: none; display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; border: 2px solid #7d1430; color: #7d1430; font-size: .85rem; }
.quiz.exam .opt.right b { background: #2f8f4e; border-color: #2f8f4e; color: #fff; }
.opt .mark { position: absolute; right: 14px; top: 50%; transform: translateY(-50%) rotate(-8deg); font-family: var(--hand); font-style: normal; font-size: 2rem; font-weight: 700; color: #d62839; animation: popIn .3s; }

.results { width: 100%; display: flex; flex-direction: column; align-items: center; gap: 14px; }
.results-card { display: flex; flex-direction: column; align-items: center; background: #fff; border-radius: var(--radius); padding: 12px 22px; box-shadow: var(--shadow); animation: popIn .5s; }
.results-card small { font-weight: 800; color: var(--pink); text-transform: uppercase; letter-spacing: .08em; font-size: .78rem; }
.results-card > b { font-size: 2.2rem; line-height: 1.1; color: #7d1430; }
.grade-stamp { margin-top: 4px; padding: 3px 12px; border: 3px double #7d1430; border-radius: 10px; color: #7d1430; font-weight: 800; transform: rotate(-3deg); animation: stamp .5s .4s backwards; }
@keyframes stamp { from { transform: rotate(-3deg) scale(2.4); opacity: 0; } }
.cert-roll { position: relative; width: 100%; max-width: 420px; display: flex; flex-direction: column; align-items: stretch; }
.cert-sheet { overflow: hidden; box-shadow: 0 10px 24px rgba(59, 31, 43, .25); }
.cert-sheet img, .cert-sheet canvas { display: block; width: 100%; height: auto; }
.cert-roll.open .cert-sheet { animation: unroll 1.8s cubic-bezier(.3, .7, .3, 1) both; }
@keyframes unroll { from { max-height: 0; } to { max-height: 1000px; } }
.cert-rod { position: relative; z-index: 1; height: 16px; margin: 0 -10px -6px; border-radius: 8px; background: linear-gradient(180deg, #ff5a5f, #e3262f 45%, #9b0e18);
  box-shadow: inset 14px 0 0 #b3121c, inset -14px 0 0 #b3121c, inset 18px 0 0 #f2c14e, inset -18px 0 0 #f2c14e, 0 3px 6px rgba(0, 0, 0, .25); }
.cert-rod.bottom { margin: -6px -10px 0; }
.cert-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; }
.cert-actions[hidden] { display: none; }
@media (prefers-reduced-motion: reduce) { .cert-roll.open .cert-sheet, .grade-stamp, .convo-koko.hop svg { animation: none; } }

/* penalty */
.pk-field { position: relative; width: 100%; height: 400px; border-radius: 18px; overflow: hidden; background: repeating-linear-gradient(#5cb85c 0 40px, #53a853 40px 80px); box-shadow: var(--shadow); }
.goal {
  position: absolute; left: 8%; top: 6%; width: 84%; height: 46%; border: 6px solid #fff; border-bottom: 0; border-radius: 4px 4px 0 0;
  background: repeating-linear-gradient(45deg, rgba(255, 255, 255, .35) 0 2px, transparent 2px 14px), repeating-linear-gradient(-45deg, rgba(255, 255, 255, .35) 0 2px, transparent 2px 14px);
  display: grid; grid-template-columns: repeat(3, 1fr); grid-template-rows: repeat(2, 1fr);
}
.goal.net-shake { animation: shake .4s; }
.pk-zone { border: 0; background: transparent; border-radius: 8px; position: relative; z-index: 3; }
.pk-zone:hover, .pk-zone:focus-visible { background: rgba(255, 255, 255, .25); outline: 2px dashed #fff; }
.keeper { position: absolute; left: 50%; top: 62%; transform: translate(-50%, -50%); transition: left .45s ease-out, top .45s ease-out; pointer-events: none; z-index: 2; display: flex; align-items: center; }
.keeper .glove { font-size: 1.3rem; }
.pk-spot { position: absolute; left: 50%; top: 86%; width: 10px; height: 10px; margin: -5px 0 0 -5px; background: #fff; border-radius: 50%; opacity: .8; }
.pk-ball { position: absolute; left: 50%; top: 86%; transform: translate(-50%, -50%); font-size: 2.2rem; pointer-events: none; z-index: 4; line-height: 1; }
.pk-ball.shot { transition: left .5s ease-out, top .5s ease-out, font-size .5s; font-size: 1.3rem; }

/* nails */
.nails { width: 100%; display: flex; flex-direction: column; align-items: center; gap: 10px; }
.hand { width: min(250px, 68vw); height: auto; filter: drop-shadow(0 8px 10px rgba(110, 31, 74, .14)); }
.hand .nail { cursor: pointer; transition: fill .2s; stroke: rgba(0, 0, 0, .08); stroke-width: 1; }
.palette { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; }
.swatch { width: 40px; height: 40px; border-radius: 50%; border: 3px solid #fff; box-shadow: var(--shadow-s); padding: 0; }
.swatch.glitter { background: linear-gradient(135deg, #ffd6e0, #f6c453, #cdb4db); }
.swatch.on { outline: 3px solid var(--plum); outline-offset: 2px; }
.salon-steps { display: flex; gap: 4px; list-style: none; margin: 0; padding: 0; flex-wrap: wrap; justify-content: center; }
.salon-steps li { font-size: .75rem; font-weight: 800; color: var(--muted); background: rgba(255, 255, 255, .55); border-radius: 999px; padding: 3px 10px; }
.salon-steps li.done { color: var(--plum); background: #fff; }
.salon-steps li.done::after { content: ' ✓'; }
.salon-steps li.done span { display: none; }
.tool-tab { white-space: nowrap; }
.nails .tool-tabs:has(> :nth-child(4)) .tool-tab { padding: 6px 9px; font-size: .82rem; }
.salon-steps li.on { color: #fff; background: var(--pink); box-shadow: 0 2px 0 var(--pink-d); }
/* the salon table: a soft-lit station with a striped towel under the hand */
.station { position: relative; width: min(340px, 92vw); padding: 34px 10px 0; border-radius: 28px; overflow: hidden; display: flex; justify-content: center;
  background: radial-gradient(ellipse at 50% 30%, #fff 0, #fff5f7 50%, #fbdfe8 100%); box-shadow: var(--shadow-s); }
.station::before { content: ''; position: absolute; left: 7%; right: 7%; bottom: -18px; height: 46%; border-radius: 24px 24px 0 0;
  background: repeating-linear-gradient(90deg, #ffd3de 0 14px, #ffe6ec 14px 28px); box-shadow: inset 0 7px 0 rgba(255, 255, 255, .65), 0 -3px 0 #f7b8ca; }
.station .hand-wrap { position: relative; z-index: 1; }
.station-tag { position: absolute; top: 9px; left: 50%; transform: translateX(-50%); z-index: 2; white-space: nowrap; font-size: .75rem; font-weight: 800; color: var(--plum);
  background: #fff; border: 2px dashed var(--pink); border-radius: 999px; padding: 1px 10px; }
.station.drying::after { content: '💨'; position: absolute; right: 6%; top: 22%; z-index: 2; font-size: 2.2rem; animation: wind .7s linear infinite; }
@keyframes wind { from { transform: translateX(30px); opacity: 0; } 40% { opacity: 1; } to { transform: translateX(-120px); opacity: 0; } }
.hand .nail.wet { animation: brush .45s ease-out; }
@keyframes brush { from { clip-path: inset(100% 0 0 0); } to { clip-path: inset(0 0 0 0); } }
/* polish bottles standing on a shelf */
.polish-shelf { display: grid; grid-template-columns: repeat(6, 46px); row-gap: 10px; justify-content: center; }
.bottle { width: 100%; height: 60px; border: 0; border-radius: 0; padding: 0; background: none; display: flex; align-items: flex-end; justify-content: center;
  border-bottom: 6px solid #f0cdb6; box-shadow: 0 3px 0 #ddb294; }
.bottle svg { width: 26px; height: 40px; transition: transform .2s; }
.bottle.on svg { transform: translateY(-10px) rotate(-10deg); filter: drop-shadow(0 5px 3px rgba(110, 31, 74, .25)); }
.bottle.on { background: radial-gradient(ellipse at 50% 85%, rgba(255, 111, 145, .25), transparent 65%); }
.remover-pad { font-size: 1.6rem; line-height: 40px; transition: transform .2s; }
.bottle.on .remover-pad { display: inline-block; transform: translateY(-8px); }
.hand .deco { pointer-events: none; }
.hand.shake { animation: shake .4s; }
.hand-wrap { display: flex; flex-direction: column; align-items: center; transition: transform .4s; }
.hand-wrap.polaroid { background: #fff; padding: 10px 10px 6px; border-radius: 6px; box-shadow: 0 10px 28px rgba(0, 0, 0, .18); transform: rotate(-3deg); animation: popIn .4s; }
.polaroid-cap { margin: 2px 0 0; font-family: var(--hand); font-size: 1.4rem; text-align: center; color: var(--plum); line-height: 1.1; }
.polaroid-cap .rating { color: var(--gold); letter-spacing: 3px; font-family: sans-serif; font-size: 1rem; }
.nail-controls { width: 100%; display: flex; flex-direction: column; align-items: center; gap: 10px; }
.tool-tabs { display: flex; gap: 6px; background: #fff; border-radius: 999px; padding: 4px; box-shadow: var(--shadow-s); }
.tool-tab { border: 0; background: none; border-radius: 999px; padding: 6px 12px; font-weight: 800; color: var(--plum); font-size: .9rem; }
.tool-tab.on { background: var(--pink); color: #fff; }
.swatch.remover { background: #fff; font-size: 1.1rem; }
/* nail art: a sticker sheet of designs, plus the colour they're drawn in */
.art-sheet { display: grid; grid-template-columns: repeat(5, 54px); gap: 8px; justify-content: center; padding: 10px; background: #fff; border-radius: 18px; box-shadow: var(--shadow-s); }
.art-tile { height: 62px; border: 0; border-radius: 14px; background: #fdf0f4; display: grid; place-items: center; padding: 0; transition: transform .15s; }
.art-tile svg { width: 30px; height: 43px; }
.art-tile span { font-size: 1.3rem; font-weight: 800; color: var(--plum); }
.art-tile.on { background: #ffe0e8; outline: 3px solid var(--pink); outline-offset: -3px; transform: translateY(-3px); }
.ink-row { display: flex; align-items: center; gap: 8px; font-size: .8rem; font-weight: 800; color: var(--plum); }
.ink-dot { width: 26px; height: 26px; border-radius: 50%; border: 3px solid #fff; padding: 0; box-shadow: 0 0 0 1px rgba(110, 31, 74, .2), var(--shadow-s); }
.ink-dot.on { outline: 3px solid var(--plum); outline-offset: 1px; }
.dry-bar { width: 80%; flex: none; height: 14px; }
.btn.blowing { transform: translateY(4px) scale(.97); box-shadow: 0 1px 0 var(--pink-d); }
.tip-row { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; }
.saree-model { position: relative; z-index: 1; display: flex; justify-content: center; min-height: 292px; animation: popIn .4s; }
/* saree boutique: a spotlit fitting room with a pelmet, curtains that close for each change, and a podium */
.boutique { position: relative; width: min(340px, 92vw); padding: 36px 0 10px; border-radius: 28px; overflow: hidden; display: flex; justify-content: center;
  background: radial-gradient(ellipse at 50% 35%, #fffaf0 0, #ffeedd 45%, #f7d2bd 100%); box-shadow: var(--shadow-s); }
.boutique::before { content: ''; position: absolute; top: 0; left: 0; right: 0; height: 18px; z-index: 3; background: #5a1a3c; border-bottom: 3px solid var(--gold); }
.curtain { position: absolute; top: 0; width: 17%; height: 88%; z-index: 2; transition: width .45s ease-in-out, height .45s ease-in-out, border-radius .45s;
  background: repeating-linear-gradient(90deg, #8e2a5c 0 7px, #6e1f4a 7px 14px); box-shadow: 0 4px 10px rgba(59, 31, 43, .25); }
.curtain.l { left: 0; border-radius: 0 0 100% 0 / 0 0 70% 0; }
.curtain.r { right: 0; border-radius: 0 0 0 100% / 0 0 0 70%; }
.boutique.closed .curtain { width: 51%; height: 100%; border-radius: 0; }
.boutique .station-tag { z-index: 4; }
.peek-sign { position: absolute; top: 45%; left: 50%; z-index: 4; transform: translate(-50%, -50%) scale(0); transition: transform .3s; white-space: nowrap;
  background: #fff; color: var(--plum); border: 2px dashed var(--pink); border-radius: 999px; padding: 4px 14px; font-weight: 800; }
.boutique.peek .peek-sign { transform: translate(-50%, -50%) rotate(-4deg) scale(1); }
.podium { position: absolute; left: 50%; bottom: 6px; width: 62%; height: 30px; transform: translateX(-50%); border-radius: 50%;
  background: linear-gradient(#ffd6e0, #f7a8bd); box-shadow: 0 5px 0 #e58aa4, 0 10px 18px rgba(110, 31, 74, .2); }
.fabric-rack { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; }
.fabric { position: relative; width: 44px; height: 50px; border: 0; padding: 0; background: none; transition: transform .15s; }
.fabric svg { width: 40px; height: 44px; filter: drop-shadow(0 3px 2px rgba(110, 31, 74, .2)); }
.fabric.on { transform: translateY(-6px) scale(1.08); }
.fabric.on::after { content: ''; position: absolute; left: 30%; right: 30%; bottom: -6px; height: 4px; border-radius: 2px; background: var(--plum); }
.fabric .match { position: absolute; top: -6px; right: -4px; font-size: .8rem; background: #fff; border-radius: 50%; width: 20px; height: 20px; display: grid; place-items: center; box-shadow: var(--shadow-s); }
.ribbons { display: flex; gap: 10px; justify-content: center; }
.ribbon { border: 0; padding: 6px; border-radius: 12px; background: #fff; box-shadow: var(--shadow-s); }
.ribbon svg { display: block; width: 64px; height: 16px; }
.ribbon.on { outline: 3px solid var(--plum); outline-offset: 1px; }
.nails .pick-label span { color: var(--pink-d); }
.fabric svg[viewBox="0 0 40 30"] { height: 30px; margin-top: 10px; }
/* the photo shoot: a polaroid that flashes, then tilts like a developed print */
.photo-frame { position: relative; overflow: hidden; background: #fff; padding: 10px 10px 4px; border-radius: 6px; box-shadow: 0 10px 28px rgba(0, 0, 0, .18); transition: transform .5s; animation: popIn .4s; }
.photo-frame.developed { transform: rotate(-3deg) scale(1.03); }
.photo { position: relative; display: block; width: min(300px, 80vw); aspect-ratio: 4 / 3.4; overflow: hidden; border-radius: 3px; background: #ffe0ec; }
.photo-couple { position: absolute; left: 0; right: 0; bottom: 4px; z-index: 1; display: flex; justify-content: center; align-items: flex-end; }
.tool-tabs.backdrops { display: grid; grid-template-columns: 1fr 1fr; border-radius: 22px; }
.photo-cap { margin: 4px 0 0; font-family: var(--hand); font-size: 1.4rem; text-align: center; color: var(--plum); }
.flash { position: absolute; top: 0; right: 0; bottom: 0; left: 0; inset: 0; z-index: 5; background: #fff; pointer-events: none; animation: flash .7s ease-out forwards; }
@keyframes flash { to { opacity: 0; } }
.pick-label { margin: 0; font-weight: 800; color: var(--plum); }

/* books */
.bookcase { width: 100%; background: #8b5a3c; padding: 10px 8px 0; border-radius: 14px; box-shadow: var(--shadow); display: flex; flex-direction: column; gap: 10px; }
.shelf-row { display: flex; align-items: flex-end; gap: 3px; height: 112px; border-bottom: 9px solid #5e3a22; padding: 0 4px; }
.book {
  flex: 1; min-width: 0; border: 0; border-radius: 3px 3px 1px 1px; position: relative; padding: 6px 0 12px;
  box-shadow: inset -3px 0 0 rgba(0, 0, 0, .18), inset 3px 0 0 rgba(255, 255, 255, .15);
  display: flex; justify-content: center; transition: transform .2s; overflow: hidden;
}
.spine-title { writing-mode: vertical-rl; transform: rotate(180deg); font-size: .56rem; color: #fff; line-height: 1.05; overflow: hidden; max-height: 100%; font-weight: 700; text-shadow: 0 1px 0 rgba(0, 0, 0, .3); }
.tiny-heart { position: absolute; bottom: 2px; left: 50%; transform: translateX(-50%); font-style: normal; font-size: .6rem; color: #ffd1dc; }
.book.found { transform: translateY(-8px); box-shadow: 0 0 0 2px var(--gold); }
.book.wiggle { animation: wiggle .4s; }
.book.hint { animation: hintPulse .5s 3; }
@keyframes wiggle { 25% { transform: rotate(-5deg); } 75% { transform: rotate(5deg); } }
@keyframes hintPulse { 50% { transform: translateY(-10px); box-shadow: 0 0 0 3px #fff, 0 0 16px var(--gold); } }
.book-open { text-align: center; }
.book-open h2 { color: var(--plum); margin: .2em 0; }

/* aquarium & bird park */
.find-chips i { font-style: normal; font-size: 1.2rem; margin-left: 4px; opacity: .45; filter: grayscale(1); }
.find-chips i.now { opacity: 1; filter: none; }
.find-chips i.got { opacity: 1; filter: none; text-shadow: 0 0 8px var(--gold); }
.find-now { font-weight: 800; color: var(--plum); font-size: 1.1rem; }
.find-now b { font-size: 1.8rem; vertical-align: middle; }
.tank { position: relative; width: 100%; height: 330px; border-radius: 18px; overflow: hidden; box-shadow: var(--shadow), inset 0 0 0 6px rgba(255, 255, 255, .5);
  background: linear-gradient(180deg, #8ee6f5, #2b8fc4 55%, #17628f); touch-action: none; }
/* glass glare over the front of the aquarium */
.tank.water::after { content: ''; position: absolute; top: 0; right: 0; bottom: 0; left: 0; inset: 0; border-radius: inherit; pointer-events: none;
  background: linear-gradient(115deg, rgba(255, 255, 255, .16) 0 10%, transparent 10% 16%, rgba(255, 255, 255, .08) 16% 19%, transparent 19%); }
.tank-decor { position: absolute; top: 0; right: 0; bottom: 0; left: 0; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.tank.water .critter { filter: drop-shadow(0 4px 3px rgba(0, 40, 70, .25)); }
.aq-weed { transform-box: fill-box; transform-origin: 50% 100%; animation: aqSway 3.5s ease-in-out infinite alternate; }
@keyframes aqSway { from { transform: rotate(-7deg); } to { transform: rotate(7deg); } }
.aq-rays { animation: aqRays 5s ease-in-out infinite alternate; }
@keyframes aqRays { from { opacity: .5; } to { opacity: 1; } }
.aq-surface { animation: aqWave 3s linear infinite; }
@keyframes aqWave { to { transform: translateX(-100px); } }
.aq-twinkle { animation: aqTwinkle 1.8s ease-in-out infinite alternate; }
@keyframes aqTwinkle { from { opacity: .6; } to { opacity: 1; } }
.tank.birds { background: linear-gradient(180deg, #9fd8ff, #d8f1ff 55%, #fff4d9); }
.tank.birds .critter { filter: drop-shadow(0 4px 3px rgba(40, 70, 30, .22)); }
.bp-cloud { animation: bpDrift 18s ease-in-out infinite alternate; }
@keyframes bpDrift { from { transform: translateX(-20px); } to { transform: translateX(24px); } }
.bp-sun { transform-box: fill-box; transform-origin: center; animation: bpGlow 3s ease-in-out infinite alternate; }
@keyframes bpGlow { to { transform: scale(1.15); opacity: .3; } }
.bp-boat { transform-box: fill-box; transform-origin: center; animation: bpBob 2.4s ease-in-out infinite alternate; }
@keyframes bpBob { from { transform: translate(-6px, 0) rotate(-1deg); } to { transform: translate(6px, -2px) rotate(1deg); } }
.bp-ripple { animation: aqRays 2s ease-in-out infinite alternate; }
/* the school kids storming through the tank tunnel */
.tank.rumble { animation: rumble 1.6s; }
@keyframes rumble { 10%, 30%, 50%, 70% { transform: translate(-5px, 2px); } 20%, 40%, 60%, 80% { transform: translate(5px, -2px); } 90% { transform: translate(-2px, 0); } }
.kids { position: absolute; bottom: 6%; left: -75%; z-index: 2; font-size: 34px; white-space: nowrap; pointer-events: none; animation: kidsRun 3s linear forwards; }
@keyframes kidsRun { 0%, 100% { transform: translateY(0); } 25%, 75% { transform: translateY(-6px); } to { left: 105%; } }
.echo { position: absolute; left: 50%; top: 38%; z-index: 2; font-weight: 800; font-size: 2.2rem; color: #fff; text-shadow: 0 2px 0 #e0527a, 0 0 14px rgba(0, 0, 0, .3);
  pointer-events: none; transform: translate(-50%, -50%); animation: echoOut 1.4s ease-out both; }
@keyframes echoOut { from { transform: translate(-50%, -50%) scale(.6); opacity: 1; } to { transform: translate(-50%, -50%) scale(2.2); opacity: 0; } }
/* photo round: a viewfinder snaps around the tapped creature; the camera roll fills in as a checklist */
.viewfinder { position: absolute; left: 0; top: 0; z-index: 3; width: 60px; height: 60px; pointer-events: none; animation: viewfinder .7s forwards;
  background: linear-gradient(#fff, #fff) 0 0 / 14px 3px, linear-gradient(#fff, #fff) 0 0 / 3px 14px, linear-gradient(#fff, #fff) 100% 0 / 14px 3px, linear-gradient(#fff, #fff) 100% 0 / 3px 14px,
    linear-gradient(#fff, #fff) 0 100% / 14px 3px, linear-gradient(#fff, #fff) 0 100% / 3px 14px, linear-gradient(#fff, #fff) 100% 100% / 14px 3px, linear-gradient(#fff, #fff) 100% 100% / 3px 14px; background-repeat: no-repeat; }
@keyframes viewfinder { 0% { scale: 1.6; opacity: 0; } 30% { scale: 1; opacity: 1; background-color: rgba(255, 255, 255, .55); } 45% { background-color: transparent; } 100% { opacity: 0; } }
.critter.snapped { opacity: .35; pointer-events: none; transition: opacity .6s .3s; }
.roll { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; }
.roll i { width: 36px; height: 42px; padding-bottom: 6px; display: grid; place-items: center; font-style: normal; font-size: 20px; border-radius: 4px;
  background: rgba(255, 255, 255, .45); box-shadow: inset 0 0 0 2px rgba(110, 31, 74, .15); filter: grayscale(1); opacity: .5; }
.roll i.got { background: #fff; box-shadow: var(--shadow-s); filter: none; opacity: 1; animation: popIn .3s; }
/* bubble round: a pastel dream, and soap bubbles with a rainbow sheen */
.tank.dreamy { background: linear-gradient(180deg, #ffd6e8, #ead9ff 55%, #cfe6ff); }
.critter.soap { width: 56px; height: 56px; border-radius: 50%; border: 2px solid rgba(255, 255, 255, .8);
  background: radial-gradient(circle at 32% 28%, rgba(255, 255, 255, .95) 0 9%, rgba(255, 182, 220, .3) 24%, rgba(170, 225, 255, .25) 60%, rgba(255, 240, 180, .35) 90%); }
.critter.popped { animation: popped .3s forwards; pointer-events: none; }
@keyframes popped { to { opacity: 0; scale: 1.5; } }
.critter { position: absolute; left: 0; top: 0; border: 0; background: none; font-size: 34px; line-height: 1; padding: 4px; cursor: pointer; will-change: transform; }
.critter.caught { animation: caught .6s forwards; pointer-events: none; }
@keyframes caught { to { opacity: 0; font-size: 60px; } }
.critter.hint { animation: critterGlow .6s 4; }
@keyframes critterGlow { 50% { filter: drop-shadow(0 0 6px #fff) drop-shadow(0 0 14px var(--gold)); } }
.critter.wiggle { animation: critterNope .5s; }
@keyframes critterNope { 50% { opacity: .3; } }
.bubble-dot { position: absolute; bottom: 20%; width: 10px; height: 10px; border-radius: 50%; border: 2px solid rgba(255, 255, 255, .7); animation: rise 4s linear infinite; }
@keyframes rise { from { transform: translateY(0); opacity: 1; } to { transform: translateY(-260px); opacity: 0; } }

/* game day (Day 4): the half-time scoreboard between the cricket and the penalties */
.sb-board { width: 100%; background: #1d2b3a; color: #fff; border-radius: 18px; padding: 12px 16px; box-shadow: var(--shadow); text-align: center; }
.sb-board > small { color: var(--gold); letter-spacing: 3px; font-weight: 800; }
.sb-row { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 2px 10px; text-align: left; padding: 8px 0; border-top: 1px dashed rgba(255, 255, 255, .2); }
.sb-row b { font-size: 1.5rem; color: var(--gold); font-variant-numeric: tabular-nums; }
.sb-row em { grid-column: 1 / -1; font-size: .85rem; opacity: .75; }
.sb-row.dim b { color: #fff; opacity: .6; }
.sb-swap { display: flex; align-items: flex-end; justify-content: center; gap: 4px; }
.sb-arrow, .sb-vs { font-size: 1.4rem; font-weight: 800; color: var(--plum); align-self: center; }
.sb-vs { margin: 0 6px; color: var(--pink); }

/* galle face (Day 6) */
/* round 1: inside the 100 bus, the street sliding past the window */
.gf-ticket { font-size: .85rem; color: var(--plum); }
.gf-bus { position: relative; width: 100%; height: 300px; border-radius: 18px; overflow: hidden; box-shadow: var(--shadow); background: linear-gradient(#f4ead8, #e8d8bd); }
.gf-window { position: absolute; left: 4%; right: 4%; top: 6%; height: 34%; border-radius: 14px; overflow: hidden; border: 6px solid #d9dde4; box-shadow: inset 0 0 0 2px #fff; background: #ffd8b0; }
.gf-street { display: flex; width: 200%; height: 100%; animation: gfStreet 4s linear infinite; }
.gf-street svg { width: 50%; height: 100%; display: block; }
.gf-street.stopped { animation-play-state: paused; }
@keyframes gfStreet { to { transform: translateX(-50%); } }
.gf-stop { position: absolute; top: 8%; left: 100%; display: flex; align-items: center; gap: 4px; background: #2a9d8f; color: #fff; font-weight: 800; padding: 4px 10px; border-radius: 8px; border: 2px solid #fff; white-space: nowrap; box-shadow: var(--shadow-s); }
.gf-stop i { font-style: normal; }
.gf-stop.pass { animation: gfPass 2.9s linear forwards; }
.gf-stop.stay { animation: none; left: 50%; transform: translateX(-50%) scale(1.1); background: var(--pink); }
@keyframes gfPass { from { left: 100%; } to { left: -60%; } }
.gf-rail { position: absolute; left: 0; right: 0; top: 43%; height: 6px; background: #c9ced6; }
.gf-seats { position: absolute; left: 0; right: 0; bottom: 0; height: 56%; display: flex; justify-content: space-around; align-items: flex-end; }
.gf-seat { position: relative; width: 40%; display: flex; justify-content: center; overflow: visible; }
.gf-seat .char { margin-bottom: -10px; will-change: transform; }
/* the seat back in front of each of them */
.gf-seat::after { content: ''; position: absolute; left: 4%; right: 4%; bottom: 0; height: 58px; border-radius: 16px 16px 4px 4px;
  background: repeating-linear-gradient(90deg, #2f6f9f 0 10px, #2a6290 10px 20px); box-shadow: inset 0 6px 0 #4b8fc4; }
.gf-phone { position: absolute; right: 4%; bottom: 52%; font-size: 1.4rem; z-index: 2; animation: bob 1.2s infinite; }
.gf-frame { position: absolute; left: 50%; top: -8px; width: 86px; height: 92px; transform: translateX(-50%); border: 3px dashed rgba(255, 255, 255, .95); border-radius: 10px; z-index: 2; box-shadow: 0 0 0 2px rgba(0, 0, 0, .15); transition: border-color .15s; }
.gf-frame.ok { border-style: solid; border-color: #7ee081; box-shadow: 0 0 12px #7ee081; }
.gf-flash { position: absolute; top: 0; right: 0; bottom: 0; left: 0; inset: 0; background: #fff; opacity: 0; pointer-events: none; z-index: 5; }
.gf-flash.go { animation: gfFlash .45s; }
@keyframes gfFlash { 10% { opacity: .9; } }
.gf-snap { position: absolute; right: 10px; top: 46%; z-index: 4; background: #fff; padding: 4px 4px 2px; border-radius: 3px; transform: rotate(6deg); box-shadow: var(--shadow-s); text-align: center; }
.gf-snap span { display: block; background: #ffd8b0; }
.gf-snap small { font-family: var(--hand); font-size: .95rem; color: var(--plum); }

/* round 2: the food carts along the promenade */
.gf-carts { width: 100%; display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.gf-cart { position: relative; border: 0; background: #fff8ee; border-radius: 12px; padding: 30px 4px 8px; box-shadow: var(--shadow-s); cursor: pointer; display: flex; flex-direction: column; align-items: center; gap: 2px; font: inherit; color: var(--ink); }
.gf-umb { position: absolute; left: 6px; right: 6px; top: 4px; height: 20px; border-radius: 60px 60px 6px 6px; background: repeating-linear-gradient(90deg, #ff6f91 0 14px, #fff 14px 28px); }
.gf-cart:nth-child(3n+2) .gf-umb { background: repeating-linear-gradient(90deg, #2a9d8f 0 14px, #fff 14px 28px); }
.gf-cart:nth-child(3n) .gf-umb { background: repeating-linear-gradient(90deg, #f4a261 0 14px, #fff 14px 28px); }
.gf-food { font-size: 2rem; line-height: 1.2; }
.gf-cart b { font-size: .85rem; line-height: 1.15; }
.gf-cart.got { background: #fff; box-shadow: 0 0 0 3px var(--gold), var(--shadow-s); }
.gf-cart.got::after { content: '✓'; position: absolute; right: 6px; bottom: 4px; color: #2a9d8f; font-weight: 800; }
.gf-cart.wiggle { animation: wiggle .4s; }
.gf-plate { font-weight: 800; color: var(--plum); background: #fff; border-radius: 999px; padding: 6px 16px; box-shadow: var(--shadow-s); min-height: 44px; display: flex; align-items: center; gap: 6px; }
.gf-plate i { font-style: normal; font-size: 1.5rem; }

/* round 3: the sunset over the sea; the dusk layer fades in and the sun sinks as he goes */
.gf-sea { position: relative; width: 100%; height: 340px; border-radius: 18px; overflow: hidden; box-shadow: var(--shadow); touch-action: none;
  background: linear-gradient(180deg, #5b7fb5 0%, #a9bede 38%, #ffc08a 58%); }
.gf-dusk { position: absolute; top: 0; right: 0; bottom: 0; left: 0; inset: 0; opacity: 0; background: linear-gradient(180deg, #1b2550 0%, #4a3f78 40%, #c8738a 58%); transition: opacity .6s; }
.gf-sun { position: absolute; left: 62%; top: 16%; width: 46px; height: 46px; margin-left: -23px; border-radius: 50%; background: #ffcf7a; box-shadow: 0 0 30px 12px rgba(255, 207, 122, .6); transition: top .8s ease; }
.gf-water { position: absolute; left: 0; right: 0; top: 58%; bottom: 0; background: linear-gradient(#4f78a8, #24466f); }
.gf-water i { position: absolute; left: -10%; width: 120%; height: 8px; border-top: 3px solid rgba(255, 255, 255, .7); border-radius: 50%; animation: gfWave 2.4s ease-in-out infinite alternate; }
.gf-water i:nth-child(1) { top: 18%; }
.gf-water i:nth-child(2) { top: 38%; animation-delay: -.8s; }
.gf-water i:nth-child(3) { top: 58%; animation-delay: -1.6s; }
@keyframes gfWave { to { transform: translateX(6%); } }
.gf-rocks { position: absolute; left: 0; right: 0; bottom: 0; height: 18%;
  background: radial-gradient(circle at 8% 40%, #2b2f36 18px, transparent 19px), radial-gradient(circle at 26% 30%, #3a3f48 22px, transparent 23px), radial-gradient(circle at 46% 44%, #2b2f36 20px, transparent 21px),
    radial-gradient(circle at 66% 32%, #3a3f48 24px, transparent 25px), radial-gradient(circle at 86% 42%, #2b2f36 20px, transparent 21px), linear-gradient(transparent 40%, #2b2f36 40%); }
.gf-us { position: absolute; left: 50%; bottom: 6%; transform: translateX(-50%); display: flex; align-items: flex-end; gap: 0; z-index: 2; pointer-events: none; }
.gf-snack { position: absolute; left: 50%; bottom: -10px; transform: translateX(-50%); font-size: 1rem; white-space: nowrap; background: #fff3d6; border: 2px solid #e8d3a6; border-radius: 999px; padding: 0 8px; }
.gf-kite { position: absolute; z-index: 3; border: 0; background: none; font-size: 34px; cursor: pointer; padding: 4px; animation: gfKite 3s ease-in-out infinite alternate; }
.gf-kite.k0 { left: 10%; top: 8%; }
.gf-kite.k1 { left: 70%; top: 4%; animation-delay: -1s; font-size: 28px; }
.gf-kite.k2 { left: 38%; top: 24%; animation-delay: -2s; font-size: 24px; }
.gf-kite.flown { filter: drop-shadow(0 0 6px #fff) drop-shadow(0 0 14px var(--gold)); }
.gf-kite.loop { animation: gfLoop .8s; }
@keyframes gfKite { from { transform: rotate(-10deg) translateY(0); } to { transform: rotate(12deg) translateY(10px); } }
@keyframes gfLoop { 50% { transform: translateY(-24px) rotate(180deg) scale(1.3); } to { transform: rotate(360deg); } }
.gf-bub { z-index: 4; }

/* the bus: passengers walking down the aisle, the brakes, the jolt */
.gf-pax { position: absolute; left: 0; bottom: 18px; font-size: 92px; line-height: 1; z-index: 3; pointer-events: none; will-change: transform; filter: drop-shadow(0 4px 4px rgba(0, 0, 0, .2)); }
.gf-pax.sit { opacity: 0; transition: opacity .5s; }
.gf-frame.blocked { border-color: #ff5f56; border-style: solid; box-shadow: 0 0 12px #ff5f56; }
.gf-brake { position: absolute; left: 50%; top: 46%; transform: translateX(-50%) scale(.6); z-index: 6; background: #ff5f56; color: #fff; font-weight: 800; padding: 4px 14px; border-radius: 999px; opacity: 0; pointer-events: none; }
.gf-brake.show { animation: gfBrake 1.1s; }
@keyframes gfBrake { 15%, 70% { opacity: 1; transform: translateX(-50%) scale(1.1); } }
/* the break between the photo and the bell: a card over the bus */
.gf-intermission { position: absolute; top: 10px; right: 10px; bottom: 10px; left: 10px; inset: 10px; z-index: 7; background: rgba(255, 248, 240, .97); border-radius: 16px; box-shadow: var(--shadow);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; padding: 12px; text-align: center; }
.gf-intermission > b { font-size: 1.25rem; color: var(--plum); }
.gf-intermission p { margin: 0; line-height: 1.4; }
.gf-mini-polaroid { background: #fff; padding: 6px 6px 2px; border-radius: 3px; box-shadow: var(--shadow-s); transform: rotate(-4deg); display: flex; flex-direction: column; align-items: center; }
.gf-mini-polaroid svg { background: #ffd8b0; display: block; }
.gf-mini-polaroid small { font-family: var(--hand); font-size: 1rem; color: var(--plum); }
.gf-bus.jolt { animation: gfJolt .6s; }
@keyframes gfJolt { 20% { transform: translateX(-10px) rotate(-1deg); } 45% { transform: translateX(7px) rotate(.6deg); } 70% { transform: translateX(-3px); } }

/* the photo rewards: a real photo developing like a polaroid */
.gf-polaroid.tall { width: min(78%, 300px); }
.gf-pic.tall { aspect-ratio: 3 / 4; }
.gf-polaroid.develop img { animation: gfDevelop 2.4s ease-out; }
@keyframes gfDevelop { from { filter: sepia(1) brightness(1.8) blur(6px); opacity: .3; } 40% { filter: sepia(.6) brightness(1.3) blur(2px); opacity: 1; } }
.gf-polaroid.tall.develop { animation: gfDrop .6s ease-out; }
@keyframes gfDrop { from { transform: translateY(-30px) rotate(-8deg); opacity: 0; } }
.gf-stack { position: relative; width: 100%; display: flex; justify-content: center; padding: 10px 0 6px; }
.gf-stack .back { position: absolute; top: 4px; transform: rotate(7deg) translateX(28px); opacity: .95; }
.gf-stack .front { position: relative; transform: rotate(-3deg) translateX(-12px); }

/* round 4: after dark, the skyline waits to be switched on; the ice creams first */
.gf-night { position: relative; width: 100%; height: 320px; border-radius: 18px; overflow: hidden; box-shadow: var(--shadow); background: linear-gradient(#0d1838, #2a2f5e 70%, #3c3a6b); }
.gf-moon { position: absolute; right: 8%; top: 6%; font-size: 1.8rem; }
.gf-bld { position: absolute; bottom: 18%; border: 0; padding: 0; cursor: pointer; border-radius: 4px 4px 0 0; transition: background .4s, box-shadow .4s;
  background: repeating-linear-gradient(0deg, transparent 0 10px, rgba(255, 255, 255, .05) 10px 13px), #1e2340; }
.gf-bld:disabled { cursor: default; }
.gf-bld.lit { background: repeating-linear-gradient(90deg, transparent 0 6px, #262b4a 6px 9px), repeating-linear-gradient(0deg, transparent 0 9px, #ffd166 9px 12px), #262b4a; box-shadow: 0 0 22px rgba(255, 209, 102, .55); }
.gf-bld.tw { border-radius: 46% 46% 0 0 / 8% 8% 0 0; background: repeating-linear-gradient(-28deg, transparent 0 10px, rgba(255, 255, 255, .05) 10px 13px), #1e2340; }
.gf-bld.tw.lit { background: repeating-linear-gradient(-28deg, transparent 0 8px, #ffe29a 8px 11px), #1e2340; box-shadow: 0 0 26px rgba(255, 226, 154, .7); }
.gf-bld:not(:disabled):not(.lit) { animation: gfHint 1.4s ease-in-out infinite; }
@keyframes gfHint { 50% { box-shadow: 0 0 0 3px rgba(255, 255, 255, .35); } }
.gf-prom { position: absolute; left: 0; right: 0; bottom: 0; height: 18%; background: linear-gradient(#3b3a52, #2a2940); border-top: 3px solid #4d4b68; }
.gf-ices { position: absolute; left: 0; right: 0; bottom: 6%; display: flex; justify-content: center; gap: 28px; z-index: 2; transition: opacity .5s, transform .5s; }
.gf-ices.away { opacity: 0; transform: translateY(30px); pointer-events: none; }
.gf-ice { position: relative; width: 74px; height: 170px; border: 0; background: none; cursor: pointer; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; font: inherit; }
.gf-ice small { color: #fff; font-weight: 800; margin-top: 30px; }
/* the bar under the wrapper: chocolate on a stick */
.gf-cone { width: 46px; height: 96px; border-radius: 22px 22px 8px 8px; background: linear-gradient(90deg, #5a3320, #7a4a2e 40%, #5a3320); position: relative; }
.gf-cone::after { content: ''; position: absolute; left: 50%; bottom: -26px; width: 10px; height: 28px; margin-left: -5px; border-radius: 0 0 4px 4px; background: #e8cf9c; }
.gf-wrap { position: absolute; left: 50%; bottom: 56px; width: 58px; height: 108px; margin-left: -29px; border-radius: 10px; display: grid; place-items: center; z-index: 1;
  background: linear-gradient(180deg, #2b8fd6 0 22%, #6b3a22 22% 78%, #2b8fd6 78%); color: #fff; font-weight: 800; font-size: .8rem; line-height: 1.1; box-shadow: var(--shadow-s); transition: transform .5s, opacity .5s; }
.gf-ice.open .gf-wrap { transform: translateY(60px) rotate(25deg); opacity: 0; }
.gf-ice.open .gf-cone { animation: popIn .4s; }

/* the selfie: a phone camera frame over the night scene, then a polaroid */
.gf-cam { width: 100%; background: #1c1c22; border-radius: 26px; padding: 10px 10px 14px; box-shadow: var(--shadow); display: flex; flex-direction: column; align-items: center; gap: 10px; }
.gf-view, .gf-pic { position: relative; width: 100%; aspect-ratio: 4 / 3; overflow: hidden; border-radius: 16px; background: #0d1838; }
.gf-pic { border-radius: 2px; }
.gf-pic img { width: 100%; height: 100%; object-fit: cover; display: block; }
.gf-cam-us { position: absolute; left: 0; right: 0; bottom: 0; display: flex; justify-content: center; }
.gf-cam-us svg { width: auto; height: 82%; max-height: 220px; }
.gf-count { position: absolute; top: 0; right: 0; bottom: 0; left: 0; inset: 0; display: grid; place-items: center; font-size: 4rem; font-weight: 800; color: #fff; text-shadow: 0 4px 12px rgba(0, 0, 0, .5); pointer-events: none; }
.gf-shutter { width: 62px; height: 62px; border-radius: 50%; border: 5px solid #fff; background: var(--pink); cursor: pointer; box-shadow: 0 0 0 3px #1c1c22, 0 0 0 5px rgba(255, 255, 255, .4); }
.gf-shutter:active { transform: scale(.92); }
.gf-shutter:disabled { opacity: .6; }
.gf-polaroid { width: 92%; background: #fff; padding: 10px 10px 14px; border-radius: 4px; box-shadow: var(--shadow); transform: rotate(-2deg); text-align: center; }
.gf-polaroid b { display: block; margin-top: 8px; font-family: var(--hand); font-size: 1.6rem; color: var(--plum); }
@media (prefers-reduced-motion: reduce) { .gf-street, .gf-kite, .gf-water i, .gf-bld { animation: none !important; } }

/* christmas shopping */
/* the snowy panel the whole game sits in, with fairy lights along the top */
.stage.xm-stage { position: relative; overflow: hidden; padding: 30px 12px 16px; border-radius: var(--radius);
  background: radial-gradient(120% 60% at 50% 0, #1f6b4a, transparent 70%), linear-gradient(180deg, #0f3d2c, #0b2a20 60%, #3b0d14);
  box-shadow: var(--shadow), inset 0 0 0 4px rgba(246, 196, 83, .35); }
.stage.xm-stage::before { content: ''; position: absolute; left: 0; right: 0; top: 4px; height: 18px; pointer-events: none;
  background: radial-gradient(circle at 12px 11px, #ffd166 4px, transparent 5px) 0 0 / 72px 18px repeat-x,
    radial-gradient(circle at 36px 13px, #ff5d8f 4px, transparent 5px) 0 0 / 72px 18px repeat-x,
    radial-gradient(circle at 60px 11px, #7bdff2 4px, transparent 5px) 0 0 / 72px 18px repeat-x,
    radial-gradient(ellipse 50% 30% at 50% 0, transparent 70%, #2b3a2f 72%, transparent 80%) 0 -2px / 24px 12px repeat-x;
  filter: drop-shadow(0 0 4px rgba(255, 220, 140, .9)); animation: xmTwinkle 1.6s steps(2) infinite; }
.stage.xm-stage::after { content: ''; position: absolute; top: 0; right: 0; bottom: 0; left: 0; inset: 0; pointer-events: none; opacity: .7;
  background-image: radial-gradient(circle, #fff 1.5px, transparent 2px), radial-gradient(circle, #fff 1px, transparent 1.5px), radial-gradient(circle, rgba(255, 255, 255, .8) 2px, transparent 2.5px);
  background-size: 90px 110px, 60px 70px, 130px 150px; background-position: 10px 0, 40px 20px, 70px 50px; animation: xmSnow 9s linear infinite; }
.xm-stage > * { position: relative; z-index: 1; }
@keyframes xmTwinkle { 50% { filter: drop-shadow(0 0 1px rgba(255, 220, 140, .4)) brightness(.8); } }
@keyframes xmSnow { to { background-position: 10px 330px, 40px 300px, 70px 500px; } }

.xm-host { display: flex; align-items: center; gap: 8px; width: 100%; }
.xm-host [data-face] { flex: none; filter: drop-shadow(0 3px 0 rgba(0, 0, 0, .25)); }
.xm-say { flex: 1; font-size: .95rem; box-shadow: 0 0 0 3px #c1121f, 0 4px 0 3px #8f0d17; }
.xm-say::before { content: ''; position: absolute; left: -9px; top: 50%; border: 8px solid transparent; border-right-color: #c1121f; border-left: 0; transform: translateY(-50%); }

/* Lily's handwritten list, pinned with a red bow */
.xm-note { position: relative; width: 100%; padding: 12px 14px 8px; border-radius: 6px; transform: rotate(-1deg); color: #3b1f2b;
  background: repeating-linear-gradient(180deg, #fffaf0 0 25px, #f3dcc4 25px 26px); box-shadow: 0 6px 14px rgba(0, 0, 0, .35); }
.xm-note::before { content: '🎀'; position: absolute; top: -14px; left: 50%; transform: translateX(-50%); font-size: 1.5rem; }
.xm-note b { display: block; text-align: center; font-family: var(--hand); font-size: 1.5rem; line-height: 1; color: #c1121f; margin-bottom: 2px; }
.xm-note small { display: block; text-align: center; font-family: var(--hand); font-size: 1.05rem; line-height: 1; color: #8a6b75; margin-bottom: 2px; }
.xm-note small s { text-decoration-color: #c1121f; text-decoration-thickness: 2px; }
.xm-note ul { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 0 10px; }
.xm-note li { font-family: var(--hand); font-size: 1.2rem; line-height: 26px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; display: flex; align-items: center; gap: 4px; }
.xm-note li:last-child:nth-child(odd) { grid-column: 1 / -1; }
.xm-box { flex: none; width: 14px; height: 14px; border: 2px solid #8a6b75; border-radius: 3px; position: relative; }
.xm-note li.done { color: #8a6b75; text-decoration: line-through 2px #c1121f; }
.xm-note li.done .xm-box { border-color: #1f7a4a; }
.xm-note li.done .xm-box::after { content: '✓'; position: absolute; left: 0; top: -9px; font: 800 1.1rem/1 'Baloo 2', sans-serif; color: #1f7a4a; }

/* the cart: one gift box per thing on the list */
.xm-cart { width: 100%; display: flex; align-items: center; gap: 6px; padding: 6px 12px; border-radius: 999px; color: #fff; font-weight: 800;
  background: linear-gradient(180deg, #d62839, #a4161a); box-shadow: 0 4px 0 #6a0f15; }
.xm-cart > span { font-size: 1.3rem; }
.xm-cart b { margin-left: auto; }
.xm-cart b.xm-merry { margin: 0 auto; font-family: var(--hand); font-size: 1.5rem; line-height: 1; animation: popIn .5s; }
.xm-cart i { flex: 1; max-width: 32px; height: 28px; border-radius: 8px; border: 2px dashed rgba(255, 255, 255, .55); font-style: normal; font-size: 1.05rem;
  display: grid; place-items: center; }
.xm-cart i:not(:empty) { border: 0; background: #fff; animation: popIn .35s; }

/* Edy's shop front: sign, striped awning, wooden shelves with a garland */
.xm-shop { width: 100%; border-radius: 16px 16px 10px 10px; background: #fff4e3; padding: 8px 8px 10px; box-shadow: 0 8px 18px rgba(0, 0, 0, .35); }
.xm-sign { display: flex; justify-content: center; align-items: center; gap: 10px; margin: 0 auto 6px; width: fit-content; padding: 2px 18px; border-radius: 10px;
  background: #c1121f; color: #fff; font-weight: 800; font-size: 1.25rem; letter-spacing: 3px; box-shadow: 0 0 0 3px var(--gold); }
.xm-sign span { font-size: 1rem; letter-spacing: 0; }
.xm-awning { height: 22px; margin: 0 -8px; background: repeating-linear-gradient(90deg, #c1121f 0 20px, #fff 20px 40px);
  -webkit-mask: linear-gradient(#000 0 0) top / 100% 11px no-repeat, radial-gradient(circle at 10px 11px, #000 10px, transparent 10.5px) 0 0 / 20px 22px repeat-x;
  mask: linear-gradient(#000 0 0) top / 100% 11px no-repeat, radial-gradient(circle at 10px 11px, #000 10px, transparent 10.5px) 0 0 / 20px 22px repeat-x; }
.xm-shelf { margin-top: 6px; padding: 10px 8px 0; border-radius: 8px; position: relative;
  background: radial-gradient(80% 60% at 50% 30%, #7a4a2c, #4a2a18); box-shadow: inset 0 0 0 5px #8b5a3c, inset 0 8px 16px rgba(0, 0, 0, .4); }
.xm-shelf::before { content: ''; position: absolute; left: 0; right: 0; top: -4px; height: 14px; border-radius: 8px;
  background: radial-gradient(circle at 8px 7px, #ff3b6b 2.5px, transparent 3px) 0 0 / 34px 14px repeat-x,
    radial-gradient(circle at 25px 7px, #ffd166 2.5px, transparent 3px) 0 0 / 34px 14px repeat-x,
    radial-gradient(circle at 50% 50%, #1f7a4a 7px, transparent 7.5px) 0 0 / 12px 14px repeat-x; }
.xm-row { display: grid; grid-template-columns: repeat(5, 1fr); gap: 4px; padding: 4px 2px 0; border-bottom: 9px solid #a8744d; box-shadow: 0 3px 0 #6e4128; margin-bottom: 10px; }
.xm-item { aspect-ratio: 1; border: 0; padding: 0; background: none; cursor: pointer; display: grid; place-items: end center; }
.xm-item span { font-size: 2rem; line-height: 1; padding-bottom: 2px; filter: drop-shadow(0 3px 2px rgba(0, 0, 0, .45)); transition: transform .15s; }
.xm-item:active span { transform: scale(1.15) translateY(-4px); }
.xm-item.got { pointer-events: none; }
.xm-item.got span { width: 34px; height: 34px; margin-bottom: 4px; padding: 0; border-radius: 50%; display: grid; place-items: center; font-size: 1.2rem; font-weight: 800;
  color: #fff; background: #1f7a4a; box-shadow: 0 0 0 3px #fff, 0 0 12px #ffd166; filter: none; animation: popIn .3s; }
.xm-item.wiggle span { animation: wiggle .4s; }
.xm-item.hint span { animation: critterGlow .6s 4; }
.xm-hint { color: #ffd166; }
.xm-tree { position: relative; width: min(100%, 300px); aspect-ratio: 100 / 120; border-radius: 18px; overflow: hidden;
  background: linear-gradient(180deg, #13324a, #2f5d7c 85%, #eef6fb 85%); box-shadow: 0 8px 18px rgba(0, 0, 0, .35), 0 0 0 4px #fff4e3; }
.xm-tree svg { position: absolute; top: 0; right: 0; bottom: 0; left: 0; inset: 0; width: 100%; height: 100%; }
.xm-lights { opacity: .3; transition: opacity .6s; }
.xm-tree.lit .xm-lights { opacity: 1; animation: critterGlow 1.2s infinite; }
.xm-spot, .xm-star { position: absolute; translate: -50% -50%; width: 34px; height: 34px; border-radius: 50%; padding: 0; cursor: pointer;
  border: 2px dashed rgba(255, 255, 255, .8); background: rgba(255, 255, 255, .15); font-size: 1.3rem; line-height: 1; animation: critterGlow 1.4s infinite; }
.xm-spot.on { border: 0; background: none; animation: popIn .3s; pointer-events: none; }
.xm-star { width: 44px; height: 44px; font-size: 1.8rem; opacity: .35; filter: grayscale(1); animation: none; }
.xm-star.ready { opacity: 1; filter: none; animation: hintPulse .8s infinite; border-radius: 50%; }
.xm-actions:empty { display: none; }
.xm-wand { position: absolute; translate: -50% -50%; z-index: 3; font-style: normal; font-size: 1.9rem; pointer-events: none;
  filter: drop-shadow(0 0 6px #fff) drop-shadow(0 0 14px #ffd166); }
.xm-trail { position: absolute; translate: -50% -50%; z-index: 2; font-style: normal; font-size: 1.1rem; color: #fff3b0; pointer-events: none;
  text-shadow: 0 0 6px #ffd166; animation: xmTrail .7s forwards; }
@keyframes xmTrail { to { opacity: 0; transform: translateY(8px) scale(.4); } }
.xm-extra { position: absolute; translate: -50% -50%; font-style: normal; font-size: 1rem; line-height: 1; pointer-events: none; animation: xmPop .45s cubic-bezier(.3, 1.8, .5, 1); }
@keyframes xmPop { from { transform: scale(0) rotate(-180deg); } }
.xm-tinsel { stroke-dasharray: 1; stroke-dashoffset: 1; }
.xm-tree.magic .xm-tinsel { transition: stroke-dashoffset 1.4s ease-out; stroke-dashoffset: 0; }
.xm-tree.magic { box-shadow: 0 0 30px rgba(255, 209, 102, .7), 0 0 0 4px #fff4e3; }
.xm-bulb { position: absolute; translate: -50% -50%; width: 7px; height: 9px; border-radius: 50% 50% 45% 45%; pointer-events: none;
  background: var(--c); box-shadow: 0 0 6px 2px var(--c); animation: xmPop .3s, xmBulb 1.2s ease-in-out infinite alternate; }
@keyframes xmBulb { to { opacity: .5; box-shadow: 0 0 2px var(--c); } }
/* after the magic, the tree slides over and the two of us walk in next to it */
.xm-scene { position: relative; width: min(100%, 300px); display: flex; align-items: flex-end; border-radius: 18px; transition: width .8s, transform .5s; }
.xm-scene .xm-tree { flex: none; width: 100%; transition: width .8s; }
.xm-us { width: 0; overflow: hidden; display: flex; justify-content: center; align-items: flex-end; }
.xm-us svg { width: 100%; height: auto; }
.xm-scene.with-us { width: 100%; overflow: hidden; background: linear-gradient(180deg, #13324a, #2f5d7c 85%, #eef6fb 85%); box-shadow: 0 8px 18px rgba(0, 0, 0, .35), 0 0 0 4px #fff4e3; }
.xm-scene.with-us .xm-tree { width: 56%; background: none; box-shadow: none; border-radius: 0; }
.xm-scene.with-us .xm-us { width: 44%; padding: 0 2% 4%; animation: xmWalkIn 1s ease-out; }
@keyframes xmWalkIn { from { transform: translateX(70%); opacity: 0; } }
.xm-scene.developed { transform: rotate(-2deg) scale(1.02); }
/* the living night scene behind the tree and us */
.xm-sky { position: absolute; top: 0; right: 0; bottom: 0; left: 0; inset: 0; z-index: 0; overflow: hidden; pointer-events: none; animation: fadeIn 1s; }
.xm-front { position: absolute; top: 0; right: 0; bottom: 0; left: 0; inset: 0; z-index: 2; overflow: hidden; pointer-events: none; }
.xm-tree.lit .xm-star.on { z-index: 2; }
.xm-sky svg { position: absolute; top: 0; right: 0; bottom: 0; left: 0; inset: 0; width: 100%; height: 100%; }
.xm-scene.with-us .xm-tree, .xm-scene.with-us .xm-us { position: relative; z-index: 1; }
.xm-tw { animation: xmTw 2.2s ease-in-out infinite alternate; }
@keyframes xmTw { to { opacity: .25; } }
.xm-moonglow { transform-box: fill-box; transform-origin: center; animation: xmMoon 3s ease-in-out infinite alternate; }
@keyframes xmMoon { to { transform: scale(1.35); opacity: .08; } }
.xm-shoot { position: absolute; top: 10%; left: 30%; width: 70px; height: 2px; border-radius: 2px; opacity: 0;
  background: linear-gradient(90deg, transparent, #fff); rotate: -20deg; animation: xmShoot 7s ease-in 2s infinite; }
@keyframes xmShoot { 0% { opacity: 0; transform: translateX(0); } 3% { opacity: 1; } 10%, 100% { opacity: 0; transform: translateX(220px); } }
.xm-flake { position: absolute; top: -8%; z-index: 2; font-style: normal; color: #fff; opacity: .85; line-height: 1;
  animation-name: xmFall, xmDrift; animation-timing-function: linear, ease-in-out; animation-iteration-count: infinite; animation-direction: normal, alternate; }
@keyframes xmFall { to { top: 104%; } }
@keyframes xmDrift { from { translate: -10px 0; } to { translate: 10px 0; } }
.xm-gift { position: absolute; bottom: 3%; z-index: 2; font-style: normal; font-size: 1.6rem; line-height: 1; transform-origin: 50% 100%; animation: xmGift 2.4s ease-in-out infinite; }
.xm-gift.small { font-size: 1.1rem; }
@keyframes xmGift { 0%, 70%, 100% { transform: none; } 78% { transform: rotate(-8deg) translateY(-3px); } 86% { transform: rotate(8deg) translateY(-3px); } }
.xm-scene.with-us .xm-tree { transform-origin: 50% 100%; animation: xmSway 4s ease-in-out infinite alternate; }
@keyframes xmSway { from { transform: rotate(-1.2deg); } to { transform: rotate(1.2deg); } }
.xm-tree.lit .xm-extra, .xm-tree.lit .xm-spot.on { transform-origin: 50% 0; animation: xmSwing 2.2s ease-in-out infinite alternate; }
.xm-tree.lit .xm-extra:nth-of-type(2n), .xm-tree.lit .xm-spot.on:nth-of-type(2n) { animation-delay: -1.1s; }
.xm-tree.lit .xm-extra:nth-of-type(3n) { animation-duration: 1.7s; }
@keyframes xmSwing { from { rotate: -10deg; } to { rotate: 10deg; } }
.xm-tree.lit .xm-star.on { animation: popIn .4s, xmStarPulse 2.4s ease-in-out .4s infinite; }
@keyframes xmStarPulse { 50% { transform: scale(1.18) rotate(10deg); filter: drop-shadow(0 0 18px #ffd166) brightness(1.25); } }
.xm-tree.lit .xm-star.on::after { content: ''; position: absolute; top: -16px; right: -16px; bottom: -16px; left: -16px; inset: -16px; z-index: -1; border-radius: 50%;
  background: repeating-conic-gradient(rgba(255, 230, 150, .55) 0 8deg, transparent 8deg 30deg);
  -webkit-mask: radial-gradient(circle, #000 20%, transparent 70%); mask: radial-gradient(circle, #000 20%, transparent 70%); animation: xmRays 8s linear infinite; }
@keyframes xmRays { to { transform: rotate(360deg); } }
.xm-us svg { transform-origin: 50% 100%; animation: xmBob 1.8s ease-in-out infinite alternate; }
@keyframes xmBob { from { transform: translateY(0) scaleY(1); } to { transform: translateY(-3px) scaleY(1.01); } }
.xm-us { position: relative; overflow: visible !important; }
.xm-heart { position: absolute; bottom: 60%; z-index: 3; font-style: normal; font-size: 1.1rem; pointer-events: none; animation: xmHeart 3s ease-out forwards; }
@keyframes xmHeart { 0% { opacity: 0; transform: translateY(0) scale(.5); } 15% { opacity: 1; } 100% { opacity: 0; transform: translateY(-90px) translateX(12px) scale(1.2); } }
/* after the snap: a white polaroid strip with the caption, above every layer of the scene */
.xm-scene .photo-cap { position: absolute; left: 0; right: 0; bottom: 0; z-index: 5; margin: 0; padding: 6px 8px 4px; background: #fff;
  color: var(--plum); font-size: 1.5rem; line-height: 1.1; box-shadow: 0 -4px 12px rgba(0, 0, 0, .15); animation: xmCapUp .5s ease-out; }
@keyframes xmCapUp { from { transform: translateY(100%); } }
.xm-star.on { opacity: 1; filter: drop-shadow(0 0 10px var(--gold)); border: 0; background: none; animation: popIn .4s; }

/* pipeline */
.term { width: 100%; background: #0f1720; color: #d6e2ee; border-radius: 14px; box-shadow: var(--shadow); overflow: hidden; font-family: ui-monospace, 'Cascadia Code', Consolas, monospace; font-size: .8rem; }
.term-bar { display: flex; align-items: center; gap: 6px; padding: 8px 10px; background: #1c2733; }
.term-bar i { width: 10px; height: 10px; border-radius: 50%; background: #ff5f56; }
.term-bar i:nth-child(2) { background: #ffbd2e; }
.term-bar i:nth-child(3) { background: #27c93f; }
.term-bar span { margin-left: 8px; color: #8aa0b4; font-size: .72rem; }
.yaml { margin: 0; padding: 10px 12px; white-space: pre-wrap; line-height: 1.55; font: inherit; }
.yaml .ln { display: block; border-radius: 3px; padding: 0 4px; }
.yaml .bug { background: rgba(255, 95, 86, .15); }
.yaml .cur { background: rgba(255, 95, 86, .38); outline: 1px solid #ff5f56; }
.yaml .ok { background: rgba(39, 201, 63, .16); color: #9ff0a8; }
.log { min-height: 70px; max-height: 190px; overflow: auto; padding: 10px 12px; white-space: pre-wrap; }
.log .g { color: #7ee787; }
.log .r { color: #ff7b72; }
.log .y { color: #f2cc60; }
.pl-q { width: 100%; display: flex; flex-direction: column; gap: 8px; align-items: center; }
.pl-title, .pl-ok { margin: 0; font-weight: 800; color: var(--plum); text-align: center; }

/* birthday */
.bday {
  width: 100%; border-radius: 22px; padding: 18px 14px 22px; text-align: center; color: #fff;
  background: radial-gradient(circle at 50% 0, #4a2460, #0b1026 75%); box-shadow: var(--shadow);
  position: relative; overflow: hidden; display: flex; flex-direction: column; align-items: center; gap: 8px;
}
.bday > * { position: relative; }
.stars {
  position: absolute !important; top: 0; right: 0; bottom: 0; left: 0; inset: 0; opacity: .8; animation: twinkle 3s ease-in-out infinite alternate;
  background-image:
    radial-gradient(2px 2px at 10% 15%, #fff, transparent), radial-gradient(1.5px 1.5px at 30% 40%, #fff, transparent),
    radial-gradient(2px 2px at 55% 10%, #fff, transparent), radial-gradient(1.5px 1.5px at 75% 30%, #fff, transparent),
    radial-gradient(2px 2px at 90% 12%, #fff, transparent), radial-gradient(1.5px 1.5px at 20% 70%, #fff, transparent),
    radial-gradient(2px 2px at 85% 60%, #fff, transparent), radial-gradient(1.5px 1.5px at 45% 85%, #fff, transparent);
}
@keyframes twinkle { to { opacity: .35; } }
.bday-h { margin: 0; font-size: 1.6rem; }
.bday-sub { margin: 0; opacity: .85; }
.cake { width: min(300px, 88%); height: auto; }
.candle { cursor: pointer; }
.flame { transform-box: fill-box; transform-origin: 50% 100%; animation: flicker .25s ease-in-out infinite alternate; }
.candle.out .flame { display: none; }
.smoke { opacity: 0; }
.candle.out .smoke { animation: smoke 1s forwards; }
@keyframes flicker { to { transform: scale(.88, 1.12) rotate(4deg); } }
@keyframes smoke { 0% { opacity: .7; } 100% { opacity: 0; transform: translateY(-20px) scale(2); } }
.party { min-height: 520px; }
.balloons { position: absolute !important; top: 0; right: 0; bottom: 0; left: 0; inset: 0; pointer-events: none; }
.balloons span { position: absolute; bottom: -60px; font-size: 2.4rem; animation: rise 7s linear infinite; }
.balloons span:nth-child(1) { left: 6%; }
.balloons span:nth-child(2) { left: 26%; animation-delay: -2s; filter: hue-rotate(90deg); }
.balloons span:nth-child(3) { left: 48%; animation-delay: -4s; filter: hue-rotate(200deg); }
.balloons span:nth-child(4) { left: 70%; animation-delay: -1s; filter: hue-rotate(280deg); }
.balloons span:nth-child(5) { left: 88%; animation-delay: -5s; filter: hue-rotate(40deg); }
@keyframes rise { to { transform: translateY(-700px) rotate(10deg); } }
.hb { font-size: clamp(1.8rem, 9vw, 2.4rem); line-height: 1.1; margin: .2em 0 0; }
.hb .l { display: inline-block; animation: jump 1s ease-in-out infinite; color: var(--gold); }
.hb .l:nth-child(odd) { color: #ff8fab; }
@keyframes jump { 50% { transform: translateY(-8px); } }
.hb-name { color: #fff; font-size: 1.2em; }
.age-badge { background: rgba(255, 255, 255, .14); border: 1px solid rgba(255, 255, 255, .3); border-radius: 999px; padding: 3px 12px; font-family: ui-monospace, Consolas, monospace; font-size: .8rem; }
.couple { display: flex; justify-content: center; align-items: flex-end; animation: bob 1.4s ease-in-out infinite; }
.song-card { display: flex; gap: 10px; align-items: center; background: rgba(255, 255, 255, .12); border-radius: 16px; padding: 10px 14px; text-align: left; width: 100%; }
.song-card small { display: block; opacity: .85; }
.vinyl { font-size: 2.2rem; animation: spin 3s linear infinite; }
.yt { width: 100%; aspect-ratio: 16 / 9; border-radius: 14px; overflow: hidden; }
.yt iframe { width: 100%; height: 100%; border: 0; }
.envelope { font-size: 3rem; text-align: center; animation: popIn .5s; }
.letter {
  font-family: var(--hand); font-size: 1.4rem; line-height: 32px; text-align: left; max-height: 58vh; overflow: auto;
  background: #fffdf7 repeating-linear-gradient(transparent 0 31px, #f0d9e2 31px 32px); padding: 4px 16px; border-radius: 12px;
}
.letter p { margin: 0 0 32px; }
.letter p:last-child { margin: 0; color: var(--pink); }
.photo-reveal { text-align: center; }
.photo-reveal p { font-family: var(--hand); font-size: 1.5rem; margin: 0 0 10px; color: var(--plum); }
.photo-reveal img { width: 100%; border-radius: 16px; border: 8px solid #fff; box-shadow: var(--shadow); transform: rotate(-2deg); }

/* ---------- modal ---------- */
.modal-back { position: fixed; top: 0; right: 0; bottom: 0; left: 0; inset: 0; z-index: 40; background: rgba(59, 31, 43, .45); display: grid; place-items: center; padding: 16px; animation: fadeIn .25s; }
.modal { background: var(--cream); border-radius: 24px; padding: 20px; max-width: 420px; width: 100%; max-height: 90vh; overflow: auto; box-shadow: 0 20px 60px rgba(0, 0, 0, .3); animation: popIn .3s; }
/* close button: stays in the top corner while a long note scrolls */
.modal-x { position: sticky; top: 0; float: right; z-index: 2; margin: -8px -8px -28px 0; width: 36px; height: 36px; padding: 0; border: 0; border-radius: 50%;
  background: #fff; color: var(--plum); font-size: 1.05rem; font-weight: 800; line-height: 1; cursor: pointer; box-shadow: var(--shadow-s); }
.modal-x:active { transform: scale(.92); }
.modal-actions { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; margin-top: 18px; }
.win { text-align: center; }
.win-icon { font-size: 3rem; line-height: 1; }
.win h2 { margin: .2em 0 .5em; color: var(--plum); }
.note { font-family: var(--hand); font-size: 1.45rem; line-height: 1.3; background: #fff; border-radius: 16px; padding: 14px 16px; text-align: left; box-shadow: inset 0 0 0 2px #f6dbe4; margin: 0; }
.note p { margin: 0; }
.sign { display: block; text-align: right; margin-top: 6px; color: var(--pink); }
.coupon-mini { display: flex; align-items: center; gap: 10px; margin-top: 12px; background: linear-gradient(90deg, #fff3c4, #ffe0ec); border: 2px dashed var(--pink); border-radius: 14px; padding: 10px 12px; text-align: left; }
.coupon-mini span { font-size: 2rem; }
.coupon-mini.scratchable { position: relative; overflow: hidden; min-height: 64px; }
.coupon-mini canvas.scratch { position: absolute; top: 0; right: 0; bottom: 0; left: 0; inset: 0; width: 100%; height: 100%; touch-action: none; cursor: grab; border-radius: 12px; transition: opacity .6s; }
.coupon-mini canvas.scratch.gone { opacity: 0; pointer-events: none; }
.wa-btn { margin-top: 12px; background: #25d366 !important; color: #fff !important; box-shadow: 0 3px 0 #1da851 !important; }
.voice-btn { margin-top: 12px; }
.choices { display: grid; gap: 8px; margin: .4em 0 .6em; }
.choices .opt { text-align: center; }
.tap-hint { text-align: center; color: var(--muted); font-size: .8rem; margin: 8px 0 0; }
.coupon-mini small { display: block; color: var(--pink); font-weight: 800; }

/* ---------- wallet ---------- */
.coupons { display: flex; flex-direction: column; gap: 12px; }
.coupon { position: relative; display: flex; align-items: center; gap: 12px; background: #fff; border-radius: 18px; padding: 12px 14px; box-shadow: var(--shadow-s); border-left: 8px dotted var(--pink); }
.coupon .c-icon { font-size: 2.2rem; flex: none; }
.c-body { flex: 1; min-width: 0; }
.c-body small { color: var(--muted); font-weight: 700; font-size: .75rem; }
.c-body b { display: block; font-size: 1.1rem; color: var(--plum); }
.c-body p { margin: 2px 0 0; font-size: .9rem; line-height: 1.3; }
.coupon.mystery { opacity: .6; border-left-color: #d8c4cc; }
.coupon .btn { flex: none; }
.stamp { flex: none; transform: rotate(-12deg); border: 3px solid #2a9d8f; color: #2a9d8f; font-weight: 800; font-size: .85rem; padding: 2px 8px; border-radius: 8px; text-align: center; line-height: 1.1; }
.stamp small { font-size: .7rem; }
.coupon.redeemed .c-body { opacity: .6; }

/* ---------- radio ---------- */
.radio h2 { text-align: center; color: var(--plum); margin: 0; }
.songs { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 8px; }
.songs li { display: flex; gap: 10px; align-items: center; background: #fff; border-radius: 12px; padding: 8px 12px; box-shadow: var(--shadow-s); }
.songs li span { font-size: .75rem; color: var(--muted); font-weight: 700; flex: none; width: 46px; }
.songs a { text-decoration: none; font-weight: 700; }

.hb-si { margin: -4px 0 2px; font-family: 'Noto Sans Sinhala', sans-serif; font-weight: 700; font-size: 1.25rem; color: #ffd166; position: relative; animation: popIn .6s .6s backwards; }

/* ---------- scrapbook ---------- */
.scrap-btn { display: flex; margin: -6px auto 16px; gap: 8px; }
.scrap-btn b { background: var(--pink); color: #fff; border-radius: 999px; padding: 0 8px; font-size: .8rem; }
.scrapbook { background: repeating-linear-gradient(transparent 0 27px, rgba(110, 31, 74, .06) 27px 28px); border-radius: var(--radius); padding-bottom: 24px; }

/* cover: hand-lettered title + a row of hearts that fill in as memories are collected */
.scrap-cover { position: relative; margin: 4px 6px 22px; padding: 16px 14px 14px; text-align: center; background: #fffdf9; border-radius: 6px;
  box-shadow: 0 6px 18px rgba(59, 31, 43, .12); transform: rotate(-.6deg); }
.scrap-cover::before, .scrap-cover::after { content: ''; position: absolute; top: -8px; width: 62px; height: 18px; background: rgba(255, 111, 145, .35);
  background-image: repeating-linear-gradient(45deg, transparent 0 6px, rgba(255, 255, 255, .45) 6px 9px); }
.scrap-cover::before { left: 14px; transform: rotate(-8deg); }
.scrap-cover::after { right: 14px; transform: rotate(7deg); }
.scrap-kicker { margin: 0; font-size: .75rem; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); font-weight: 800; }
.scrap-title { margin: 2px 0 8px; font-family: var(--hand); font-size: 2.3rem; font-weight: 700; color: var(--plum); line-height: 1; }
.scrap-meter { display: flex; justify-content: center; flex-wrap: wrap; gap: 3px; margin-bottom: 6px; }
.scrap-meter i { font-style: normal; font-size: 1rem; line-height: 1; color: #e7c9d4; }
.scrap-meter i.on { color: var(--pink); animation: popIn .4s backwards; }
.scrap-cover .sub { margin: 4px 0 10px; }
.scrap-cover .sub:last-child { margin-bottom: 0; }
.scrap-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; }
.scrap-actions:empty { display: none; }

/* ---------- the scrapbook as a PDF (only exists while printing) ---------- */
#print-book { display: none; }
@media print {
  @page { size: A5 portrait; margin: 0; }
  html, body { background: #fff !important; }
  body > *:not(#print-book) { display: none !important; }
  #print-book { display: block; font-family: 'Baloo 2', sans-serif; color: var(--ink); }
  #print-book * { -webkit-print-color-adjust: exact; print-color-adjust: exact; animation: none !important; }
  .print-page { position: relative; width: 148mm; height: 210mm; overflow: hidden; padding: 12mm 13mm 10mm 16mm; text-align: center; break-after: page; page-break-after: always;
    background-color: #fffaf3; background-image: linear-gradient(90deg, rgba(110, 31, 74, .12), transparent 7mm), repeating-linear-gradient(transparent 0 27px, rgba(110, 31, 74, .05) 27px 28px); }
  .print-page:last-child { break-after: auto; page-break-after: auto; }
  .print-page .memory-photo { margin: 6mm 4mm 3mm; }
  .print-page .memory-photo .cap { font-size: 1.9rem; }
  .print-page .memory-note { box-shadow: none; border: 1px solid #f0e2d6; }
  .print-page .memory-note p { font-size: 1.25rem; }
  .print-extras { margin: 0; color: var(--muted); font-size: .8rem; font-weight: 700; }
  .print-cover { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4mm; color: var(--gold);
    background: radial-gradient(circle at 30% 20%, rgba(255, 255, 255, .12), transparent 55%), linear-gradient(90deg, #4f1235 0 8mm, var(--plum) 8mm);
    box-shadow: inset 0 0 0 5mm rgba(246, 196, 83, .25); }
  .print-cover.cover-art { gap: 2mm; padding: 16mm 14mm; box-shadow: none; }
  .print-cover .cv-frame { top: 9mm; right: 8mm; bottom: 9mm; left: 14mm; inset: 9mm 8mm 9mm 14mm; }
  .print-cover .cv-ribbon { right: 22mm; width: 7mm; }
  .print-cover .cover-kicker { font-size: 1rem; }
  .print-cover .cover-title { font-size: 4.4rem; }
  .print-cover .cv-portrait { width: 58%; border-width: 7px; margin: 5mm 0 3mm; }
  .print-cover .cover-sub { font-size: 2.2rem; }
  .print-cover .cv-plate { font-size: .9rem; }
  .print-cover .cv-count { font-size: .85rem; }
  .print-end p { margin: 0; font-family: var(--hand); font-size: 2.2rem; line-height: 1.2; color: #ffe3a3; }
}

.scrap-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 22px 14px; padding: 6px 4px; }
@media (min-width: 640px) { .scrap-grid { grid-template-columns: repeat(3, 1fr); } }
.polaroid-card { position: relative; display: flex; flex-direction: column; align-items: center; gap: 2px; border: 0; background: #fff; padding: 8px 8px 10px; cursor: pointer;
  border-radius: 4px; box-shadow: 0 1px 0 rgba(0, 0, 0, .04), 0 6px 16px rgba(59, 31, 43, .18); transform: rotate(var(--tilt, 0deg));
  transition: transform .25s cubic-bezier(.3, 1.6, .5, 1), box-shadow .25s; animation: dropIn .5s calc(var(--i, 0) * 45ms) backwards; }
/* a faint paper grain on the frame */
.polaroid-card:not(.empty)::after { content: ''; position: absolute; top: 0; right: 0; bottom: 0; left: 0; inset: 0; border-radius: inherit; pointer-events: none;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0) 55%, rgba(255, 240, 230, .5)); }
@media (hover: hover) { .polaroid-card:not(.empty):hover { transform: rotate(0deg) translateY(-6px) scale(1.03); box-shadow: 0 14px 28px rgba(59, 31, 43, .25); z-index: 2; } }
.polaroid-card:not(.empty):active { transform: rotate(0deg) scale(1.04); }
.polaroid-card:focus-visible { outline: 3px solid var(--pink); outline-offset: 4px; }
@keyframes dropIn { from { transform: translateY(-14px) rotate(calc(var(--tilt, 0deg) * 3)) scale(.92); opacity: 0; } }

/* washi tape: a few colours, either across the top or on two corners */
.tape { position: absolute; z-index: 3; top: -9px; left: 50%; width: 56px; height: 18px; transform: translateX(-50%) rotate(-3deg); background: rgba(255, 214, 165, .88);
  background-image: repeating-linear-gradient(90deg, transparent 0 8px, rgba(255, 255, 255, .3) 8px 10px); box-shadow: 0 1px 2px rgba(0, 0, 0, .06); }
.tape.pink { background-color: rgba(255, 158, 184, .8); }
.tape.mint { background-color: rgba(152, 222, 196, .8); }
.tape.lilac { background-color: rgba(196, 172, 240, .8); }
.tape.lemon { background-color: rgba(255, 226, 120, .82); }
.tape.peach { background-color: rgba(255, 200, 150, .85); }
.tape.tl { top: -4px; left: -12px; width: 42px; transform: rotate(-40deg); }
.tape.br { top: auto; bottom: -4px; left: auto; right: -12px; width: 42px; transform: rotate(-40deg); }

.polaroid-card .snap, .memory-photo .snap { position: relative; display: block; width: 100%; aspect-ratio: 4 / 3; overflow: hidden; border-radius: 2px; box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .05); }
.polaroid-card .snap-couple, .memory-photo .snap-couple { position: absolute; left: 0; right: 0; bottom: 2px; display: flex; justify-content: center; align-items: flex-end; }
.polaroid-card .cap { font-family: var(--hand); font-size: 1.2rem; color: var(--plum); line-height: 1.1; margin-top: 4px; text-align: center; }
.polaroid-card small { color: var(--muted); font-size: .72rem; font-weight: 700; }
.polaroid-card .sticker { position: absolute; z-index: 3; right: -8px; top: 44%; font-size: 1.5rem; transform: rotate(var(--s, 0deg)); filter: drop-shadow(0 2px 2px rgba(0, 0, 0, .18)); pointer-events: none; }
.polaroid-card:nth-child(odd) .sticker { right: auto; left: -8px; }
.new-badge { position: absolute; z-index: 4; top: 6px; right: 4px; background: var(--pink); color: #fff; font-family: var(--hand); font-size: 1.05rem; font-weight: 700;
  padding: 0 8px; border-radius: 999px; transform: rotate(10deg); box-shadow: 0 2px 6px rgba(224, 82, 122, .4); animation: badgeBob 1.6s ease-in-out infinite; }
@keyframes badgeBob { 50% { transform: rotate(-4deg) scale(1.08); } }
.polaroid-card.fresh { box-shadow: 0 0 0 3px rgba(255, 111, 145, .45), 0 8px 20px rgba(59, 31, 43, .2); }

.polaroid-card.empty { background: rgba(255, 255, 255, .45); box-shadow: none; border: 2px dashed #e7c9d4; cursor: default; }
.polaroid-card.empty .snap { display: grid; place-items: center; background: repeating-linear-gradient(-45deg, rgba(255, 255, 255, .6) 0 8px, rgba(231, 201, 212, .18) 8px 16px); }
.polaroid-card.empty .ghost-icon { font-size: 2rem; opacity: .55; filter: grayscale(.5); }
.polaroid-card.empty .cap { color: var(--muted); }
.scrap-end { font-family: var(--hand); font-size: 1.6rem; text-align: center; color: var(--plum); margin: 26px 8px 0; animation: popIn .6s backwards; }

/* ---------- the scrapbook book: a cover, paper leaves, and a page turn on the spine ---------- */
.book-view { text-align: center; }
.book { position: relative; height: min(70vh, 600px); margin: 26px 10px 18px 18px; perspective: 1800px; }
/* the hard back cover peeking out behind the pages, with a stitched spine on the left */
.book::before { content: ''; position: absolute; top: -8px; right: -8px; bottom: -8px; left: -14px; inset: -8px -8px -8px -14px; border-radius: 6px 14px 14px 6px;
  background: linear-gradient(90deg, #4f1235 0 12px, var(--plum) 12px); box-shadow: 0 14px 30px rgba(59, 31, 43, .35); }
.book::after { content: ''; position: absolute; top: 6px; bottom: 6px; left: -8px; border-left: 2px dashed rgba(246, 196, 83, .6); }
/* page edges: a few sheets stacked under the top one */
.book-stack { position: absolute; top: 0; right: 0; bottom: 0; left: 0; inset: 0; border-radius: 2px 10px 10px 2px; box-shadow: 2px 2px 0 #f1e3d6, 4px 4px 0 #e8d6c6, 6px 6px 0 #dfcab8; }

.leaf { position: absolute; top: 0; right: 0; bottom: 0; left: 0; inset: 0; transform-origin: left center; transform-style: preserve-3d; }
.face { position: absolute; top: 0; right: 0; bottom: 0; left: 0; inset: 0; border-radius: 2px 10px 10px 2px; backface-visibility: hidden; -webkit-backface-visibility: hidden; }
.face.front { overflow-y: auto; overscroll-behavior: contain; padding: 12px 14px 22px 22px; text-align: center; background-color: #fffaf3;
  background-image: linear-gradient(90deg, rgba(110, 31, 74, .14), transparent 18px), repeating-linear-gradient(transparent 0 27px, rgba(110, 31, 74, .05) 27px 28px); }
.face.back { transform: rotateY(180deg); background: linear-gradient(270deg, rgba(110, 31, 74, .16), transparent 30px), #f5e9dd; }
.leaf.turn { animation: leafTurn .75s cubic-bezier(.45, .05, .35, 1) forwards; }
.leaf.return { animation: leafReturn .75s cubic-bezier(.45, .05, .35, 1) forwards; }
@keyframes leafTurn { 0% { transform: rotateY(0); } 80% { opacity: 1; } 100% { transform: rotateY(-180deg); opacity: 0; } }
@keyframes leafReturn { 0% { transform: rotateY(-180deg); opacity: 0; } 20% { opacity: 1; } 100% { transform: rotateY(0); } }

/* the cover she opens first: plum linen, a gold-foil frame, a portrait of us, a ribbon bookmark */
.cover-art { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; padding: 22px 20px; overflow: hidden; color: var(--gold);
  background:
    radial-gradient(ellipse at 30% 15%, rgba(255, 255, 255, .14), transparent 55%),
    radial-gradient(ellipse at 80% 100%, rgba(0, 0, 0, .25), transparent 60%),
    repeating-linear-gradient(0deg, rgba(255, 255, 255, .025) 0 1px, transparent 1px 3px),
    repeating-linear-gradient(90deg, rgba(0, 0, 0, .05) 0 1px, transparent 1px 3px),
    linear-gradient(90deg, #4a1032 0 12px, rgba(0, 0, 0, .18) 12px 14px, #7a2453 14px, var(--plum)); }
.cover-front.cover-art { cursor: pointer; }
.cv-frame { position: absolute; top: 14px; right: 12px; bottom: 14px; left: 26px; inset: 14px 12px 14px 26px; border: 2px solid rgba(246, 196, 83, .75); border-radius: 8px; pointer-events: none;
  box-shadow: 0 0 0 4px rgba(246, 196, 83, .14), inset 0 0 0 4px rgba(246, 196, 83, .14); }
/* little foil corner ornaments */
.cv-frame i { position: absolute; width: 18px; height: 18px; border: 2px solid var(--gold); background: var(--plum); transform: rotate(45deg); }
.cv-frame i::after { content: ''; position: absolute; top: 4px; right: 4px; bottom: 4px; left: 4px; inset: 4px; background: var(--gold); border-radius: 50%; }
.cv-frame i:nth-child(1) { top: -10px; left: -10px; }
.cv-frame i:nth-child(2) { top: -10px; right: -10px; }
.cv-frame i:nth-child(3) { bottom: -10px; left: -10px; }
.cv-frame i:nth-child(4) { bottom: -10px; right: -10px; }
.cv-ribbon { position: absolute; z-index: 2; top: 0; right: 40px; width: 16px; height: 62%; background: linear-gradient(90deg, #e0527a, var(--pink) 45%, #e0527a);
  clip-path: polygon(0 0, 100% 0, 100% 100%, 50% calc(100% - 9px), 0 100%); box-shadow: 0 0 6px rgba(0, 0, 0, .3); opacity: .92; }

.cover-kicker { position: relative; font-size: .72rem; letter-spacing: .2em; text-transform: uppercase; font-weight: 800; color: #ffe3a3; }
.cover-kicker em { font-family: var(--hand); font-style: normal; font-size: 1.15rem; letter-spacing: 0; color: var(--pink); text-transform: none; }
.cover-title { position: relative; font-family: var(--hand); font-size: 3rem; line-height: .95; color: var(--gold);
  text-shadow: 0 1px 0 #fff2c4, 0 -1px 0 rgba(0, 0, 0, .35), 0 3px 8px rgba(0, 0, 0, .35); }
.cover-heart { font-size: 2.4rem; }
/* an arched window with the two of us holding hands at sunset */
.cv-portrait { position: relative; display: block; width: 62%; aspect-ratio: 4 / 5; margin: 8px 0 6px; overflow: hidden; border-radius: 999px 999px 10px 10px;
  border: 5px solid #fff8ea; box-shadow: 0 0 0 2px var(--gold), 0 10px 22px rgba(0, 0, 0, .35); }
.cv-sky { position: absolute; top: 0; right: 0; bottom: 0; left: 0; inset: 0; background:
  radial-gradient(circle at 50% 58%, #fff3c4 0 14%, rgba(255, 243, 196, 0) 15%),
  radial-gradient(ellipse at 50% 120%, #a9c3a0 0 34%, transparent 35%),
  linear-gradient(180deg, #ffd6e0 0%, #ffc9a8 45%, #ffe4b5 70%); }
.cv-us { position: absolute; left: 0; right: 0; bottom: 2px; display: flex; justify-content: center; }
.cv-us svg { width: 88%; height: auto; }
.cv-hearts i { position: absolute; font-style: normal; color: #ff6f91; font-size: .9rem; animation: cvFloat 3.6s ease-in-out infinite; }
.cv-hearts i:nth-child(1) { left: 14%; top: 22%; }
.cv-hearts i:nth-child(2) { right: 16%; top: 14%; font-size: .7rem; animation-delay: -1.2s; }
.cv-hearts i:nth-child(3) { right: 26%; top: 34%; font-size: .6rem; animation-delay: -2.4s; }
@keyframes cvFloat { 50% { transform: translateY(-6px) scale(1.15); } }
.cover-sub { position: relative; font-family: var(--hand); font-size: 1.5rem; color: #ffe3a3; line-height: 1; }
.cv-plate { position: relative; margin-top: 6px; padding: 3px 14px; border-radius: 4px; font-size: .68rem; font-weight: 800; letter-spacing: .14em; text-transform: uppercase;
  color: var(--plum); background: linear-gradient(180deg, #ffe7a3, var(--gold) 55%, #d9a63a); box-shadow: 0 2px 0 rgba(0, 0, 0, .25); }
.cv-count { position: relative; margin-top: 4px; font-size: .68rem; font-weight: 700; letter-spacing: .1em; color: rgba(255, 227, 163, .75); }
.cv-hint { position: absolute; bottom: 22px; left: 0; right: 0; font-family: var(--hand); font-size: 1.05rem; color: rgba(255, 227, 163, .7); animation: cvBlink 1.4s ease-in-out infinite; }
@keyframes cvBlink { 50% { opacity: .3; } }
/* the inside of the front cover, seen while it swings open */
.face.cover-back { background: linear-gradient(270deg, rgba(0, 0, 0, .2), transparent 30px), repeating-linear-gradient(45deg, #fbe3ea 0 10px, #fff2f5 10px 20px); }

.page-head { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 4px; }
.page-date { font-family: var(--hand); font-size: 1.7rem; font-weight: 700; color: var(--plum); line-height: 1; }
.page-head small { color: var(--muted); font-size: .72rem; font-weight: 700; }
/* the dog-eared corner: tap it to turn the page */
.page-corner { position: absolute; z-index: 2; right: 0; bottom: 0; width: 38px; height: 38px; border: 0; padding: 0; border-radius: 0 0 10px 0;
  backface-visibility: hidden; -webkit-backface-visibility: hidden;
  background: linear-gradient(135deg, transparent 50%, #e6d3c1 50%, #f7ede3 75%); filter: drop-shadow(-2px -2px 2px rgba(59, 31, 43, .12)); transition: width .2s, height .2s; }
.page-corner:hover { width: 46px; height: 46px; }
.page-blank { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 14px; min-height: 80%; color: var(--muted); }
.blank-frame { display: grid; place-items: center; width: 78%; aspect-ratio: 4 / 3; font-size: 2.6rem; border: 2px dashed #e7c9d4; border-radius: 4px; transform: rotate(-2deg);
  background: repeating-linear-gradient(-45deg, rgba(255, 255, 255, .7) 0 8px, rgba(231, 201, 212, .2) 8px 16px); }
.blank-frame { filter: grayscale(.4); }
.page-blank p { margin: 0; font-family: var(--hand); font-size: 1.35rem; line-height: 1.2; }

.memory-photo { position: relative; display: block; margin: 12px 4px 6px; background: #fff; padding: 9px 9px 7px; border-radius: 4px;
  box-shadow: 0 8px 20px rgba(59, 31, 43, .2); transform: rotate(var(--tilt, 0deg)); }
.memory-photo .cap { display: block; font-family: var(--hand); font-size: 1.55rem; color: var(--plum); line-height: 1.1; margin-top: 6px; }
.memory-date { margin: 2px 0 10px; color: var(--muted); font-size: .75rem; font-weight: 700; }
.memory-note { position: relative; text-align: left; background: #fff; border-radius: 10px; padding: 12px 14px 10px; margin: 0 2px 12px;
  background-image: repeating-linear-gradient(transparent 0 25px, rgba(110, 31, 74, .07) 25px 26px); box-shadow: 0 3px 10px rgba(59, 31, 43, .08); }
.memory-note b { display: block; color: var(--plum); margin-bottom: 4px; }
.memory-note p { margin: 0; font-family: var(--hand); font-size: 1.3rem; line-height: 26px; color: #4a2a38; }
.memory-note .sign { display: block; text-align: right; font-family: var(--hand); font-size: 1.25rem; color: var(--pink-d); }
.memory-extras { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin-bottom: 12px; }
.memory-extras .btn { width: min(100%, 280px); white-space: normal; line-height: 1.3; text-align: center; }
.memory-extras .coupon-chip { cursor: default; }
.memory-extras .coupon-chip:active { transform: none; box-shadow: 0 3px 0 #e7c9d4; }
.memory-nav { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.memory-nav .icon-btn { font-size: 1.6rem; }
.memory-nav .icon-btn:disabled { opacity: .3; cursor: default; }
.memory-dots { display: flex; flex-wrap: wrap; justify-content: center; gap: 5px; }
.memory-dots i { width: 7px; height: 7px; border-radius: 50%; background: #e7c9d4; transition: transform .2s; }
.memory-dots i.got { background: #f7a8bd; }
.memory-dots i.on { background: var(--pink); transform: scale(1.5); }
@media (prefers-reduced-motion: reduce) {
  .polaroid-card, .new-badge, .scrap-meter i.on, .cover-heart, .cv-hearts i, .cv-hint { animation: none !important; }
  .leaf.turn, .leaf.return { animation-duration: .01s; } /* still ends, so the page swap happens */
}

/* ---------- arcade evenings (Day 7) ---------- */
.ar-bar { flex: 1; height: 10px; border-radius: 99px; background: #f3dfe6; overflow: hidden; }
.ar-bar i { display: block; height: 100%; width: 0; border-radius: 99px; background: var(--pink); }
.ar-tray { width: 100%; display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; }
.ar-hold { touch-action: none; -webkit-touch-callout: none; }
.ar-hold.held { transform: translateY(4px); box-shadow: 0 1px 0 var(--pink-d); }
/* round 1: the street */
.ar-street, .ar-night, .ar-square { position: relative; width: 100%; height: 290px; border-radius: 18px; overflow: hidden; box-shadow: var(--shadow); }
.ar-street { background: linear-gradient(#ffd1a6, #ffe9cf 60%, #b9b2ab 60%); }
.ar-street.jolt { animation: gfJolt .6s; }
.ar-far, .ar-near { position: absolute; left: 0; right: 0; }
.ar-far { bottom: 40%; height: 130px; background: linear-gradient(90deg, #c9a7b8 0 44px, transparent 44px 60px, #b795b0 60px 118px, transparent 118px 136px, #d6b3ad 136px 190px, transparent 190px 210px) 0 0 / 210px 100%; opacity: .6; }
.ar-near { bottom: 28%; height: 100px; border-bottom: 10px solid #8c857f; background:
  repeating-linear-gradient(#0000 0 14px, rgba(255, 255, 255, .25) 14px 20px),
  linear-gradient(90deg, #e9c46a 0 86px, transparent 86px 110px, #8ecae6 110px 190px, transparent 190px 214px, #f4a261 214px 290px, transparent 290px 320px) 0 0 / 320px 100%; }
.ar-us { position: absolute; left: 50%; bottom: 4%; transform: translateX(-50%); }
.ar-us.walking svg { animation: arStep .42s ease-in-out infinite alternate; transform-origin: 50% 100%; }
@keyframes arStep { from { transform: rotate(-2.5deg); } to { transform: rotate(2.5deg) translateY(-5px); } }
.ar-light { position: absolute; right: 14px; top: 14px; display: grid; gap: 6px; padding: 8px; border-radius: 14px; background: #2b2d3a; z-index: 2; }
.ar-light i { width: 28px; height: 28px; border-radius: 50%; opacity: .2; }
.ar-light .r { background: #ff3b4e; } .ar-light .y { background: #ffc93c; } .ar-light .g { background: #4cd97b; }
.ar-light[data-on=stop] .r, .ar-light[data-on=slow] .y, .ar-light[data-on=go] .g { opacity: 1; box-shadow: 0 0 14px rgba(255, 255, 255, .6); }
.ar-tuk { position: absolute; bottom: 0; right: -60px; font-size: 3rem; z-index: 3; }
.ar-tuk.cross { animation: arCross 2s linear forwards; }
@keyframes arCross { to { right: 110%; } }
/* round 2: hide and seek */
.ar-square { height: 330px; }
.ar-spots { position: absolute; top: auto; right: 4px; bottom: 8px; left: 4px; inset: auto 4px 8px; display: grid; grid-template-columns: repeat(6, 1fr); gap: 2px; }
.ar-spot { position: relative; height: 150px; border: 0; padding: 0; background: none; overflow: hidden; touch-action: manipulation; }
.ar-pillar { position: absolute; left: 14%; right: 14%; bottom: 0; height: 84px; border-radius: 6px 6px 0 0; background: linear-gradient(90deg, #fffaf0, #e6ddcc 60%, #c4b9a4); box-shadow: inset 0 8px 0 #c4b9a4, inset 0 -8px 0 #c4b9a4; pointer-events: none; }
.ar-peek { position: absolute; left: 50%; bottom: 10px; transform: translate(-50%, 0); transition: transform .18s; pointer-events: none; }
.ar-peek svg { display: block; }
.ar-peek em { font-style: normal; font-size: 2.4rem; }
.ar-spot.up .ar-peek { transform: translate(-50%, -62px); }
/* round 3: the crepe */
.ar-pan { width: min(72vw, 270px); aspect-ratio: 1; touch-action: none; cursor: pointer; filter: drop-shadow(0 6px 8px rgba(0, 0, 0, .2)); }
.ar-pan svg { width: 100%; height: 100%; display: block; pointer-events: none; }
.ar-pan.flip { animation: arFlip .9s; }
@keyframes arFlip { 50% { transform: translateY(-40px) rotateX(180deg); } 100% { transform: rotateX(360deg); } }
.ar-batter { fill: #fff6db; }
.ar-batter path { opacity: 0; }
.ar-batter path.on { opacity: 1; }
.ar-heat { position: relative; width: 100%; height: 18px; border-radius: 99px; background: linear-gradient(90deg, #fff6db 0 44%, #e2a042 50% 72%, #4a2e1c 88%); box-shadow: var(--shadow-s); }
.ar-heat i { position: absolute; top: -5px; width: 6px; height: 28px; margin-left: -3px; border-radius: 4px; background: var(--plum); }
.ar-fills { width: 100%; display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.ar-fill { border: 0; border-radius: 14px; background: #fff; padding: 8px 4px; box-shadow: var(--shadow-s); display: flex; flex-direction: column; align-items: center; }
.ar-fill span { font-size: 1.7rem; }
.ar-fill.got { opacity: .4; }
/* round 4: the fries */
.ar-table { width: 100%; border-radius: 18px; padding: 16px 12px 0; background: linear-gradient(#ffe9d2 62%, #c98f5f 62%); box-shadow: var(--shadow); }
.ar-eaters { display: flex; justify-content: space-around; }
.ar-eater { position: relative; border: 4px solid transparent; border-radius: 22px; background: rgba(255, 255, 255, .6); padding: 24px 18px 4px; display: flex; flex-direction: column; align-items: center; touch-action: manipulation; }
.ar-eater.open { border-color: var(--pink); background: #fff; }
.ar-aaa { position: absolute; top: -8px; background: var(--pink); color: #fff; font-weight: 800; border-radius: 99px; padding: 2px 12px; visibility: hidden; }
.ar-eater.open .ar-aaa { visibility: visible; animation: popIn .25s; }
.ar-box { position: relative; width: 130px; height: 150px; margin: 8px auto 0; }
.ar-fries { position: absolute; top: 0; right: 14px; bottom: 30px; left: 14px; inset: 0 14px 30px; display: flex; justify-content: center; align-items: flex-end; }
.ar-fries i { width: 11px; height: var(--h); margin: 0 -.5px 30px; border-radius: 3px; background: linear-gradient(90deg, #ffe08a, #f2b632); border: 1px solid #d99a1e; transform: rotate(var(--r)); transform-origin: 50% 100%; }
.ar-carton { position: absolute; left: 10px; right: 10px; bottom: 8px; height: 72px; background: #e63946; color: #fff; display: grid; place-items: center; font-size: 1.8rem; clip-path: polygon(0 0, 50% 14%, 100% 0, 86% 100%, 14% 100%); }
/* round 5: the walk to the bus stand */
.ar-night { background: linear-gradient(#141a3c, #4b3f78 72%); }
.ar-moon { position: absolute; left: 45%; top: 2px; font-size: 2rem; }
.ar-city { position: absolute; left: 0; right: 0; bottom: 24%; height: 110px; opacity: .8; background:
  radial-gradient(circle, #ffd166 1.6px, transparent 2px) 0 0 / 16px 18px,
  linear-gradient(90deg, #1f2248 0 50px, #282a57 50px 90px, #1a1d40 90px 150px) 0 0 / 150px 100%; }
/* Independence Square, which we always just walk past */
.ar-hall { position: absolute; left: 3%; width: 31%; bottom: 24%; height: 84px; background: repeating-linear-gradient(90deg, #c9a982 0 7px, #5b4636 7px 18px) 0 100% / 100% 48px no-repeat; }
.ar-hall::before { content: ''; position: absolute; left: -4px; right: -4px; top: 14px; height: 24px; background: #8f4631; clip-path: polygon(14% 0, 86% 0, 100% 100%, 0 100%); }
.ar-hall b { position: absolute; left: 22%; right: 22%; top: 0; height: 15px; background: #a8533a; clip-path: polygon(18% 0, 82% 0, 100% 100%, 0 100%); }
/* our campus, behind the middle lamps */
.ar-campus { position: absolute; left: 38%; width: 40%; bottom: 24%; height: 96px; display: flex; justify-content: space-evenly; align-items: flex-end; padding-top: 34px; background: linear-gradient(#e0c9a6, #b59a78); border-radius: 6px 6px 0 0; border-top: 8px solid #8f4631; }
.ar-campus b { position: absolute; z-index: 1; pointer-events: none; top: 4px; left: 3%; right: 3%; text-align: center; background: #7d1430; color: #ffd166; border-radius: 6px; font-size: .68rem; line-height: 1.9; white-space: nowrap; }
.ar-kiss { position: absolute; left: 50%; top: 10%; font-size: 1.8rem; pointer-events: none; animation: arKiss 1.4s ease-out forwards; }
@keyframes arKiss { from { transform: translate(-50%, 0) scale(.4); } 30% { scale: 1.2; } to { transform: translate(calc(-50% + var(--dx)), -80px) scale(1); opacity: 0; } }
.ar-campus i { width: 15%; height: 42px; border-radius: 99px 99px 0 0; background: #ffd98a; }
.ar-pave { position: absolute; left: 0; right: 0; bottom: 0; height: 24%; background: #6f6b80; border-top: 5px solid #8d889f; }
.ar-lamp { position: absolute; bottom: 20%; width: 52px; height: 190px; margin-left: -26px; border: 0; background: linear-gradient(#20222f, #20222f) 50% 100% / 6px 160px no-repeat; padding: 0; }
.ar-lamp i { position: absolute; left: 50%; top: 10px; width: 24px; height: 24px; margin-left: -12px; border-radius: 50%; background: #55566a; border: 3px solid #20222f; }
.ar-lamp.now i { animation: arPulse .9s infinite alternate; }
@keyframes arPulse { to { background: #bfae78; transform: scale(1.2); } }
.ar-lamp.lit i { background: #ffe29a; box-shadow: 0 0 18px 8px rgba(255, 220, 130, .6); }
.ar-us.small { bottom: 6%; transition: left 1.2s ease-in-out; z-index: 2; pointer-events: none; }
.ar-stand { position: absolute; right: 2%; bottom: 20%; font-size: 2.2rem; }
.ar-bus { position: absolute; bottom: 0; right: -90px; font-size: 4rem; z-index: 3; }
.ar-bus.arrive { animation: arArrive 1.1s ease-out forwards; }
.ar-bus.leave { animation: arLeave 2.4s ease-in forwards; }
@keyframes arArrive { to { right: 4%; } }
@keyframes arLeave { from { right: 4%; } to { right: 110%; } }

/* ---------- from interns to us (Day 2) ---------- */
.in-opts { width: 100%; display: flex; flex-direction: column; gap: 10px; min-height: 60px; }
.in-room { position: relative; width: 100%; height: 230px; border-radius: 18px; overflow: hidden; background: linear-gradient(#e3f0f8 78%, #c9a27e 78%); box-shadow: var(--shadow); }
.in-board { position: absolute; left: 14px; top: 16px; width: 60%; padding: 10px 14px; background: #fff; border: 4px solid #b9c3cc; border-radius: 8px; display: flex; flex-direction: column; gap: 4px; font-size: .85rem; }
.in-board b { color: #2a6f97; }
.in-board .ok { opacity: .55; text-decoration: line-through; }
.in-him { position: absolute; right: 16px; bottom: 4px; }
/* the laptop */
.in-desk { width: 100%; display: grid; grid-template-columns: 1fr 1.1fr 1fr; gap: 10px; align-items: center; }
.in-col { display: flex; flex-direction: column; gap: 10px; }
.in-plug { border: 3px solid transparent; border-radius: 14px; background: #fff; padding: 8px 4px; font-weight: 700; font-size: .85rem; box-shadow: var(--shadow-s); min-height: 58px; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.in-plug i { font-style: normal; font-size: 1.3rem; }
.in-plug.port { background: #2b2d3a; color: #fff; }
.in-plug.sel { border-color: var(--pink); }
.in-plug.got { opacity: .4; }
.in-plug.wiggle, .in-face.wiggle { animation: wiggle .3s; }
.in-screen { height: 150px; border-radius: 12px; border: 8px solid #2b2d3a; border-bottom-width: 18px; background: #264653; color: #fff; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; font-size: 2.4rem; padding: 6px; }
.in-screen small { font-size: .85rem; }
.in-screen .ar-bar { flex: none; width: 100%; background: #14303c; }
.in-screen.shake { animation: shake .3s; }
/* the crowd */
.in-crowd { width: 100%; padding: 10px 4px; border-radius: 18px; background: linear-gradient(#dfeaf1, #cbb79f); box-shadow: var(--shadow); display: grid; grid-template-columns: repeat(6, 1fr); row-gap: 2px; overflow: hidden; }
.in-crowd.busy { grid-template-columns: repeat(7, 1fr); }
.in-face { border: 0; background: none; padding: 0; display: grid; place-items: center; min-height: 56px; translate: var(--x) var(--y); touch-action: manipulation; }
.in-crowd.busy .in-face { animation: inMill 2.2s var(--d) ease-in-out infinite alternate; }
@keyframes inMill { from { transform: translate(-9px, 3px); } to { transform: translate(9px, -3px); } }
.in-face.found svg { transform: scale(1.4); filter: drop-shadow(0 0 8px var(--pink)); }
/* the chat */
.in-chat { width: 100%; height: 300px; overflow-y: auto; border-radius: 18px; padding: 14px; background: #efe7de; box-shadow: var(--shadow); display: flex; flex-direction: column; gap: 8px; }
.in-chat p { margin: 0; max-width: 78%; padding: 8px 14px; border-radius: 16px; background: #fff; align-self: flex-start; animation: popIn .25s; }
.in-chat p.me { align-self: flex-end; background: #dcf8c6; }
.in-chat p.date { align-self: center; max-width: 100%; background: #d9e8f5; font-size: .8rem; padding: 3px 14px; border-radius: 99px; }
.in-chat p.typing { color: var(--muted); letter-spacing: 2px; }
/* two coffees */
.in-cafe { position: relative; width: 100%; height: 290px; border-radius: 18px; overflow: hidden; background: linear-gradient(#e8d3b5 74%, #8b5e3c 74%); box-shadow: var(--shadow); transition: filter 1.2s; }
.in-cafe.dim { filter: saturate(.55) brightness(.82); }
.in-cafe.warm { filter: saturate(1.2) brightness(1.06); }
.in-sign { position: absolute; left: 50%; top: 14px; transform: translateX(-50%); background: #4a2e1c; color: #ffe29a; font-weight: 800; padding: 2px 22px; border-radius: 8px; }
.in-lampshade { position: absolute; left: 50%; top: 50px; width: 180px; height: 170px; margin-left: -90px; background: radial-gradient(closest-side, rgba(255, 236, 170, .75), transparent); }
.in-pair { position: absolute; left: 0; right: 0; bottom: 38px; display: flex; justify-content: center; align-items: flex-end; gap: 70px; }
.in-tabletop { position: absolute; left: 22%; right: 22%; bottom: 0; height: 66px; border-radius: 12px 12px 0 0; background: linear-gradient(#b98050 12px, #8f5c37 12px); transition: opacity .8s; }
.in-cup { position: absolute; bottom: 60px; font-size: 2rem; line-height: 1; transition: opacity 1.2s; }
.in-cup.a { left: 38%; } .in-cup.b { right: 38%; }
.in-cup.empty, .in-cafe.warm .in-tabletop { opacity: 0; }
/* our places */
.in-places { width: 100%; display: grid; grid-template-columns: repeat(6, 1fr); gap: 10px; }
.in-place { grid-column: span 2; border: 3px solid transparent; border-radius: 16px; background: #fff; padding: 10px 2px 8px; min-height: 104px; box-shadow: var(--shadow-s); display: flex; flex-direction: column; align-items: center; line-height: 1.2; }
.in-place:nth-child(7) { grid-column: 3 / span 2; }
.in-place i { font-style: normal; font-size: 1.9rem; }
.in-place b { font-size: .85rem; }
.in-place em { font-style: normal; font-size: .7rem; min-height: 1em; margin-top: 4px; }
.in-place.got { border-color: var(--pink); background: #fff0f5; }
.in-place.wiggle { animation: wiggle .3s; }
/* the walk */
.in-street { height: 320px; }
.in-apart { display: flex; gap: 34px; }
.btn.in-now { animation: inNow .6s infinite alternate; }
@keyframes inNow { to { box-shadow: 0 5px 0 var(--pink-d), 0 0 0 6px rgba(255, 111, 145, .35); } }
.in-puddle { position: absolute; left: 0; bottom: 4%; width: 64px; height: 18px; border-radius: 50%; background: #6fb7e0; border: 3px solid #a9dcf5; }
.in-kade { position: absolute; left: 12px; bottom: 28%; width: 120px; height: 100px; background: linear-gradient(#c1121f 30px, #fff3d6 30px 62px, #8b5e3c 62px); border-radius: 8px 8px 0 0; text-align: center; color: #fff; }
.in-card { position: absolute; top: 12px; right: 12px; bottom: 12px; left: 12px; inset: 12px; z-index: 4; background: rgba(255, 248, 240, .97); border-radius: 16px; padding: 14px; display: flex; flex-direction: column; justify-content: center; gap: 9px; text-align: center; }
.ar-us.in-back { transition: left 3.4s linear; left: -24% !important; }
.in-wave { position: absolute; left: 34%; top: 34%; line-height: 0; }

/* ---------- the book fair (Day 9) ---------- */
.bf-want { text-align: center; min-height: 2.2em; display: flex; align-items: center; justify-content: center; gap: 6px; flex-wrap: wrap; }
.bf-want b { font-size: 1.1rem; }
.bf-late { color: #d62839; animation: inNow .5s infinite alternate; }
.bf-stall { position: relative; width: 100%; padding: 12px 10px; border-radius: 18px; overflow: hidden; background: linear-gradient(#a8703f, #7a4c28); box-shadow: var(--shadow); }
.bf-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 9px; }
.bf-cover { border: 0; border-radius: 3px 9px 9px 3px; height: 84px; padding: 4px 4px 4px 9px; color: #fff; font-weight: 700; font-size: .7rem; line-height: 1.15; box-shadow: inset 5px 0 0 rgba(0, 0, 0, .18), 0 3px 5px rgba(0, 0, 0, .3); display: grid; place-items: center; text-align: center; overflow-wrap: anywhere; touch-action: manipulation; }
.bf-cover.wiggle { animation: wiggle .3s; }
.bf-pass { position: absolute; left: -80px; font-size: 4.6rem; line-height: 1; pointer-events: none; animation: bfPass 3.4s linear forwards; }
.bf-pass.rev { animation-direction: reverse; }
@keyframes bfPass { from { left: -80px; } to { left: 105%; } }
.bf-row { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; align-items: center; }
.bf-sw { width: 46px; height: 58px; border-radius: 4px 10px 10px 4px; border: 4px solid #fff; box-shadow: var(--shadow-s); }
.bf-ic { width: 48px; height: 48px; border-radius: 50%; border: 3px solid transparent; background: #fff; font-size: 1.5rem; box-shadow: var(--shadow-s); padding: 0; }
.bf-sw.bf-on, .bf-ic.bf-on, .opt.bf-on { outline: 3px solid var(--pink); }
.bf-book-cover { position: relative; width: 198px; height: 260px; margin: 0 auto; border-radius: 6px 16px 16px 6px; color: #fff; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; padding: 24px 24px 24px 32px; text-align: center; box-shadow: inset 10px 0 0 rgba(0, 0, 0, .15), inset 0 0 0 9px transparent, var(--shadow); }
.bf-book-cover::after { content: ''; position: absolute; top: 14px; right: 12px; bottom: 14px; left: 20px; inset: 14px 12px 14px 20px; border: 2px solid var(--gold); border-radius: 8px; pointer-events: none; }
.bf-book-cover i { font-style: normal; font-size: 3rem; line-height: 1; }
.bf-book-cover b { font-size: 1.35rem; line-height: 1.1; overflow-wrap: anywhere; }
.bf-book-cover small { font-family: var(--hand); font-size: 1.2rem; }
.bf-picks { width: 100%; display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.bf-picks .opt { padding: 8px 10px; font-size: .9rem; line-height: 1.2; min-height: 48px; }
.bf-input { width: 100%; font: inherit; font-size: 16px; padding: .7em 1em; border-radius: 14px; border: 2px dashed var(--pink); background: #fff; color: var(--ink); }
.bf-view { width: 100%; perspective: 1200px; }
.bf-view > * { transform-origin: 0 50%; }
.bf-view.fwd > * { animation: bfFwd .45s ease-out; }
.bf-view.rev > * { animation: bfRev .45s ease-out; }
@keyframes bfFwd { from { transform: rotateY(60deg); opacity: .2; } }
@keyframes bfRev { from { transform: rotateY(-60deg); opacity: .2; } }
.bf-page { width: 100%; min-height: 400px; background: #fffaf0; border-radius: 6px 16px 16px 6px; padding: 18px 18px 14px 24px; box-shadow: inset 10px 0 14px -8px rgba(0, 0, 0, .18), var(--shadow); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; text-align: center; }
.bf-page.small { min-height: 0; padding: 12px 14px 10px 20px; }
.bf-page.small .bf-us svg { height: 110px; width: auto; }
.bf-page small { color: var(--muted); font-weight: 700; }
.bf-page b { color: var(--plum); font-size: 1.4rem; line-height: 1.15; overflow-wrap: anywhere; }
.bf-page p { margin: 0; font-family: var(--hand); font-size: 1.45rem; line-height: 1.15; }
.bf-page.end i { font-style: normal; font-size: 3rem; }
.bf-pic { position: relative; width: 100%; aspect-ratio: 4 / 3; border-radius: 10px; overflow: hidden; }
.bf-page.small .bf-pic { aspect-ratio: 2 / 1; }
.bf-us { position: absolute; top: auto; right: 0; bottom: 4px; left: 0; inset: auto 0 4px; display: flex; justify-content: center; }
.bf-num { min-width: 70px; text-align: center; font-weight: 700; color: var(--muted); }
.bf-saved { width: 100%; border-radius: 12px; box-shadow: var(--shadow); }

/* ---------- devops night (Day 11) ---------- */
.dv-out { height: 300px; overflow-y: auto; padding: 10px 12px; line-height: 1.5; }
.dv-out div { white-space: pre-wrap; overflow-wrap: anywhere; }
.dv-out .y { color: #ffd166; } .dv-out .g { color: #8ff0a4; } .dv-out .r { color: #ff8f87; } .dv-out .c { color: #7bdff2; }
.dv-line { display: flex; align-items: center; gap: 8px; padding: 8px 12px; border-top: 1px solid #243342; margin: 0; }
.dv-line b { color: #27c93f; }
.dv-line input { flex: 1; min-width: 0; background: none; border: 0; outline: 0; color: #fff; font: inherit; font-size: 16px; }
.dv-chips { width: 100%; display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; min-height: 44px; }
.dv-chip { border: 0; border-radius: 10px; background: #1c2733; color: #8ff0a4; font-family: ui-monospace, Consolas, monospace; font-size: .85rem; padding: 10px 14px; box-shadow: var(--shadow-s); }
.dv-pager { width: 100%; min-height: 190px; border-radius: 20px; padding: 18px; background: #0f1720; color: #fff; box-shadow: var(--shadow); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; text-align: center; border: 4px solid #ffbd2e; }
.dv-pager.p1 { border-color: #ff5f56; }
.dv-pager.ok { border-color: #27c93f; }
.dv-pager.late { opacity: .6; }
.dv-pager.ring { animation: shake .4s; }
.dv-pager small { background: #ff5f56; border-radius: 6px; padding: 0 10px; font-weight: 800; }
.dv-pager small:empty { display: none; }
.dv-pager b { font-size: 1.45rem; line-height: 1.15; }
.dv-pager p { margin: 0; color: #9fb2c4; }
.dv-fuse { width: 100%; height: 8px; border-radius: 9px; background: #243342; overflow: hidden; margin-bottom: 8px; }
.dv-fuse i { display: block; height: 100%; width: 100%; background: #ffd166; }
.dv-fixes { width: 100%; display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.dv-fix { border: 0; border-radius: 16px; background: #fff; font-weight: 800; padding: 10px; box-shadow: var(--shadow-s); display: flex; align-items: center; justify-content: center; gap: 8px; touch-action: manipulation; }
.dv-fix i { font-style: normal; font-size: 1.6rem; }
.dv-fix.wiggle { animation: wiggle .3s; }
.dv-report { position: relative; width: 100%; background: #fffdf6; border-radius: 10px; padding: 18px; box-shadow: var(--shadow); }
.dv-report small { color: var(--muted); font-weight: 700; }
.dv-report > b { display: block; font-size: 1.3rem; color: var(--plum); line-height: 1.2; margin: 4px 0 8px; }
.dv-report table { width: 100%; border-collapse: collapse; }
.dv-report td { padding: 4px 0; border-bottom: 1px dashed #e7c9d4; }
.dv-report td:last-child { text-align: right; font-weight: 800; }
.dv-report p { margin: 8px 0 0; }
.dv-stamp { display: inline-block; margin-top: 14px; border: 3px solid #2f8f4e; color: #2f8f4e; font-weight: 800; padding: 2px 12px; border-radius: 8px; transform: rotate(-4deg); }

/* ---------- the garden and the bouquet (Day 12) ---------- */
.fl-garden { width: 100%; border-radius: 18px; padding: 10px 8px 16px; background: linear-gradient(#bfe8f7 46%, #b5e09a 46%, #8cc96e); box-shadow: var(--shadow); display: grid; grid-template-columns: repeat(3, 1fr); row-gap: 8px; }
.fl-pot { position: relative; height: 150px; border: 0; background: none; padding: 0; touch-action: manipulation; }
.fl-clay { position: absolute; left: 50%; bottom: 0; width: 66px; height: 50px; margin-left: -33px; background: linear-gradient(#b9623d 14px, #cf7a50 14px); clip-path: polygon(0 0, 100% 0, 100% 14px, 92% 14px, 80% 100%, 20% 100%, 8% 14px, 0 14px); }
.fl-plant { position: absolute; left: 0; right: 0; bottom: 48px; display: flex; flex-direction: column-reverse; align-items: center; line-height: 1; }
.fl-plant em { font-style: normal; font-size: 2.1rem; }
.fl-plant svg { display: block; margin-bottom: -10px; filter: drop-shadow(0 2px 2px rgba(0, 0, 0, .18)); }
.fl-stem { width: 5px; height: 34px; border-radius: 4px; background: #4f9a3e; }
.fl-bud { width: 22px; height: 30px; border-radius: 50% 50% 46% 46%; background: linear-gradient(#ff8fab 55%, #5fae4d 55%); }
.fl-ask { position: absolute; right: 8px; top: 2px; font-size: 1.5rem; z-index: 1; }
.fl-pot.wants .fl-ask { animation: bob .8s infinite; }
.fl-pot.wiggle { animation: wiggle .3s; }
.fl-pot.drink .fl-plant, .fl-pot.bloom .fl-plant { animation: popIn .4s; }
.fl-note { width: 100%; background: #fffaf0; border-radius: 16px; padding: 12px 14px; box-shadow: var(--shadow-s); display: flex; flex-wrap: wrap; gap: 10px; align-items: center; justify-content: center; }
.fl-note > div { flex: 1; min-width: 180px; }
.fl-note b { color: var(--plum); }
.fl-note p { margin: 0; font-family: var(--hand); font-size: 1.4rem; line-height: 1.15; }
.fl-art { display: flex; justify-content: center; filter: drop-shadow(0 6px 8px rgba(110, 31, 74, .2)); }
.fl-kinds { width: 100%; display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.fl-kind { border: 0; border-radius: 14px; background: #fff; padding: 6px 2px; box-shadow: var(--shadow-s); display: flex; flex-direction: column; align-items: center; touch-action: manipulation; }
.fl-kind b { font-size: .85rem; line-height: 1.2; }
.fl-sw { width: 50px; height: 50px; border-radius: 50%; border: 4px solid #fff; box-shadow: var(--shadow-s); }
.fl-sw.bf-on { outline: 3px solid var(--pink); }
.fl-final { position: relative; width: 100%; border-radius: 18px; padding: 10px 14px 18px; background: linear-gradient(#ffe5ec, #fff6e8); box-shadow: var(--shadow); }
.fl-card { width: 74%; margin: 4px auto 0 0; background: #fffdf6; border: 2px solid var(--gold); border-radius: 12px; padding: 10px; text-align: center; transform: rotate(-2deg); }
.fl-card p { margin: 0; font-family: var(--hand); font-size: 1.5rem; line-height: 1.1; color: var(--plum); overflow-wrap: anywhere; }
.fl-her { position: absolute; right: 10px; bottom: 8px; line-height: 0; }

/* ---------- toast & confetti ---------- */
#toast {
  position: fixed; left: 50%; bottom: 24px; transform: translate(-50%, 140px); z-index: 60;
  background: var(--plum); color: #fff; padding: 10px 18px; border-radius: 999px; font-weight: 700;
  box-shadow: 0 8px 24px rgba(0, 0, 0, .25); transition: transform .3s; max-width: calc(100% - 32px); text-align: center;
  pointer-events: none; /* never block taps on whatever is underneath */
}
#toast.show { transform: translate(-50%, 0); }
/* during a game: a small bubble that pops in over the top of the game board (top is set in FX.toast) */
#toast.in-game { bottom: auto; opacity: 0; transform: translate(-50%, -10px) scale(.9);
  transition: opacity .25s, transform .25s; background: rgba(110, 31, 74, .9); font-size: .9rem; padding: 8px 16px; }
#toast.in-game.show { opacity: 1; transform: translate(-50%, 0) scale(1); }
#confetti { position: fixed; top: 0; right: 0; bottom: 0; left: 0; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 70; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; }
}

/* ---------- older iPhones (iOS 14): translate/rotate as transforms ---------- */
@supports not (translate: 1px) {
  .xm-spot, .xm-star, .xm-wand, .xm-trail, .xm-extra, .xm-bulb { transform: translate(-50%, -50%); }
  .in-face { transform: translate(var(--x), var(--y)); }
}
