/* =========================================================================
   world.css — Kido World (home map + destinations)
   The world fills the screen; app chrome floats over it as a light HUD.
   Hit areas are transparent buttons laid over the SVG art by world.js.
   ========================================================================= */

.sr-only {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

/* ---------- Chrome icons (js/icons.js) ---------- */
.kido-icon { width: 1em; height: 1em; display: block; flex: 0 0 auto; }
.avatar { font-size: 38px; overflow: hidden; }
.avatar .kido-icon { width: 38px; height: 36px; margin-top: 3px; }
.star-count { cursor: pointer; border: 0; font-size: 18px; min-height: 46px; }
.star-count__icon .kido-icon { width: 24px; height: 24px; }
.topbar__music .kido-icon { width: 24px; height: 24px; }
.tab__icon .kido-icon { width: 27px; height: 27px; }
.star-count:focus-visible, .topbar__music:focus-visible, .topbar__parent:focus-visible,
.avatar:focus-visible, .topbar__back:focus-visible { outline: 4px solid var(--sky); outline-offset: 3px; }

/* ---------- World view chrome: the HUD floats over the art ---------- */
body.is-worldview .topbar {
  position: absolute; top: 0; left: 0; right: 0; z-index: 6;
  background: transparent; pointer-events: none;
}
body.is-worldview .topbar > * { pointer-events: auto; }
body.is-worldview .topbar__text { display: none; }
/* The identity block is only a spacer here (its text is hidden): let taps through
   to the map's button under it in the landscape HUD row — only the avatar is live. */
body.is-worldview .topbar__id { flex: 1 1 auto; pointer-events: none; }
body.is-worldview .topbar__id > * { pointer-events: auto; }
body.is-worldview .screen { padding: 0; overflow: hidden; }
body.is-worldview .screen > .kw-root { animation: none; }

/* ---------- Stage ---------- */
.kw-root {
  position: relative; width: 100%; height: 100%; overflow: hidden;
  background: linear-gradient(180deg, #9ED6FF 0%, #D8F0FF 40%, #A9DB8A 41%, #86C872 100%);
  touch-action: manipulation;
}
.kw-zoom { position: absolute; inset: 0; will-change: auto; }
.kw-root.is-travelling .kw-zoom { will-change: transform; }
.kw-art { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.kw-layer { position: absolute; pointer-events: none; }
.kw-layer > * { pointer-events: auto; }
.kw-veil { position: absolute; inset: 0; opacity: 0; pointer-events: none; z-index: 8; }
.kw-root.is-travelling { pointer-events: none; }

/* ---------- Hit areas + name plates ---------- */
.kw-hit {
  position: absolute; padding: 0; margin: 0; border: 0; background: transparent;
  border-radius: 28px; cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
/* Guarantee a >=56px touch target without moving the box: grow evenly
   around the drawn object when the world is scaled down. */
.kw-hit::before {
  content: ""; position: absolute; border-radius: inherit;
  left: min(0px, calc(50% - 28px)); right: min(0px, calc(50% - 28px));
  top: min(0px, calc(50% - 28px)); bottom: min(0px, calc(50% - 28px));
}
.kw-hit:focus-visible { outline: 4px solid #FFFFFF; box-shadow: 0 0 0 8px rgba(76,50,168,.55); }
.kw-plate {
  position: absolute; left: 50%; top: 100%;
  transform: translate(-50%, -30%);
  display: inline-flex; align-items: center; gap: 6px;
  padding: 5px 12px 5px 13px; border-radius: 999px;
  background: rgba(255, 253, 248, .94);
  box-shadow: 0 3px 0 rgba(76,50,168,.16), 0 8px 18px rgba(43,33,81,.18);
  font-family: var(--font-display); font-weight: 700; color: var(--ink);
  /* Plates shrink with the world (so neighbours never collide), never below 12px. */
  font-size: clamp(12px, calc(17px * var(--kw-s, 1)), 17px); line-height: 1.1;
  white-space: nowrap; pointer-events: none;
  transition: transform .2s cubic-bezier(.34,1.56,.64,1);
  z-index: 4;   /* labels stay readable even when Momo (z 3) stands in front of a place */
}
.kw-hit:hover .kw-plate, .kw-hit:focus-visible .kw-plate { transform: translate(-50%, -45%) scale(1.05); }
.kw-hit:active .kw-plate { transform: translate(-50%, -30%) scale(.94); }
.kw-plate .kido-icon { width: 17px; height: 17px; }
.kw-pips { display: inline-flex; gap: 3px; }
.kw-pips i { width: 7px; height: 7px; border-radius: 99px; background: #DCD3F2; }
.kw-pips i.on { background: #FFB020; box-shadow: 0 0 0 1.5px rgba(229,154,18,.45); }
.kw-plate--locked { background: rgba(43,33,81,.78); color: #FFF3C4; gap: 4px; padding: 5px 11px; }
.kw-plate--spot { font-size: clamp(12px, calc(16px * var(--kw-s, 1)), 16px); }
.kw-hit--spot.is-played .kw-plate { background: rgba(236,255,240,.95); }

/* ---------- Momo in the world ---------- */
.kw-momo.actor {
  position: absolute !important;
  width: clamp(46px, calc(66px * var(--kw-s, 1)), 96px) !important;
  height: clamp(55px, calc(79px * var(--kw-s, 1)), 115px) !important;
  translate: -50% -100%;
  cursor: pointer; z-index: 3;
  filter: drop-shadow(0 6px 6px rgba(35,48,74,.28));
}
.kw-momo:focus-visible { outline: 4px solid #FFFFFF; outline-offset: 2px; border-radius: 20px; }
.kw-bubble {
  position: absolute; z-index: 4; pointer-events: none;
  translate: var(--ax, -50%) calc(-100% - clamp(58px, calc(84px * var(--kw-s, 1)), 122px));
  max-width: min(64vw, 280px); width: max-content;
  padding: 10px 16px; border-radius: 20px;
  background: #FFFFFF; color: var(--ink);
  font-family: var(--font-display); font-weight: 700; font-size: clamp(15px, 1vw + 11px, 19px); line-height: 1.2;
  box-shadow: 0 10px 26px rgba(43,33,81,.2);
  opacity: 0; transform: scale(.7); transform-origin: 50% 100%;
  transition: opacity .2s ease, transform .25s cubic-bezier(.34,1.56,.64,1);
}
.kw-bubble.is-on { opacity: 1; transform: scale(1); }

/* ---------- Continue / More / title ---------- */
.kw-continue {
  position: absolute; z-index: 5; left: 50%; bottom: calc(14px + var(--kido-sa-bottom));
  translate: -50% 0;
  display: flex; align-items: center; gap: 12px;
  min-height: 66px; max-width: min(430px, calc(100% - 28px)); width: max-content;
  padding: 8px 10px 8px 8px; border-radius: 999px;
  background: linear-gradient(135deg, #FFBE3B 0%, #FF9A1F 55%, #FF7A1A 100%);
  color: #FFFFFF; font-family: var(--font-display); text-align: left;
  border: 3px solid rgba(255,255,255,.92);
  box-shadow: 0 5px 0 #D46A12, 0 14px 30px rgba(212,106,18,.35);
  transition: transform .18s cubic-bezier(.34,1.56,.64,1);
}
.kw-continue:hover { transform: translateY(-3px); }
.kw-continue:active { transform: translateY(3px) scale(.97); box-shadow: 0 2px 0 #D46A12, 0 8px 18px rgba(212,106,18,.3); }
.kw-continue:focus-visible { outline: 4px solid var(--grape); outline-offset: 3px; }
.kw-continue__thumb {
  width: 48px; height: 48px; flex: 0 0 auto; border-radius: 50%;
  background: radial-gradient(circle at 40% 35%, #FFFFFF 0%, #EAF6FF 100%);
  box-shadow: inset 0 0 0 2px rgba(255,255,255,.9);
  display: grid; place-items: center; overflow: hidden;
}
.kw-continue__thumb svg { width: 44px; height: 40px; }
.kw-continue__thumb svg *, .kw-continue__thumb svg { animation: none !important; }
.kw-continue__thumb img { width: 100%; height: 100%; object-fit: cover; }
.kw-continue__text { display: flex; flex-direction: column; min-width: 0; }
.kw-continue__text b { font-size: 21px; font-weight: 800; line-height: 1.05; text-shadow: 0 1px 2px rgba(150,70,0,.35);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.kw-continue__text small { font-size: 14px; font-weight: 600; opacity: .95; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.kw-continue__go {
  width: 44px; height: 44px; flex: 0 0 auto; border-radius: 50%;
  background: rgba(255,255,255,.28); display: grid; place-items: center; font-size: 22px; color: #FFFFFF;
}
/* Room for the More pill on the left: 14px edge + ~113px pill + 9px gap + this pill's own 14px right edge. */
.kw-continue--realm { left: auto; right: 14px; translate: none; max-width: calc(100% - 150px); }

.kw-more {
  position: absolute; z-index: 5; left: 14px; bottom: calc(14px + var(--kido-sa-bottom));
  display: flex; align-items: center; gap: 8px; min-height: 60px; min-width: 60px; padding: 6px 18px 6px 12px;
  border-radius: 999px; background: rgba(255,253,248,.95); color: var(--ink);
  font-family: var(--font-display); font-weight: 700; font-size: 18px;
  box-shadow: 0 4px 0 rgba(76,50,168,.16), 0 10px 22px rgba(43,33,81,.2);
}
.kw-more .kido-icon { width: 34px; height: 34px; }
.kw-more:active { transform: scale(.95); }
.kw-more:focus-visible { outline: 4px solid var(--grape); outline-offset: 3px; }
@media (max-width: 360px) {
  .kw-more { padding: 6px 12px; }
  .kw-more span { display: none; }
  .kw-continue--realm { max-width: calc(100% - 100px); }
  .kw-continue__text b { font-size: 19px; }
}

/* Wide / landscape: controls sit in the free middle of the HUD row. */
.kw-root.is-wide .kw-continue,
.kw-root.is-wide .kw-more {
  top: calc(var(--kido-sa-top) + 9px); bottom: auto; min-height: 50px;
}
.kw-root.is-wide .kw-continue { max-width: calc(100% - 480px); padding: 3px 6px 3px 3px; gap: 9px; border-width: 2px; }
.kw-root.is-wide .kw-continue__thumb { width: 40px; height: 40px; }
.kw-root.is-wide .kw-continue__thumb svg { width: 36px; height: 33px; }
.kw-root.is-wide .kw-continue__go { width: 36px; height: 36px; }
.kw-root.is-wide .kw-continue__text b { font-size: 18px; }
.kw-root.is-wide .kw-continue__text small { font-size: 13px; }
/* The topbar is centred and capped at var(--maxw) (responsive.css), so on wide screens its back + avatar
   buttons move inward. --kw-hud-x is where those buttons start inside .kw-root; the realm HUD follows it. */
.kw-root.is-wide { --kw-hud-x: calc(max(0px, (100% - var(--maxw)) / 2) + var(--gutter)); }
.kw-root.is-wide .kw-more { left: calc(var(--kw-hud-x) + 124px); min-width: 50px; padding: 4px 14px 4px 8px; font-size: 16px; }
.kw-root.is-wide .kw-more .kido-icon { width: 28px; height: 28px; }
.kw-root.is-wide .kw-continue--realm { left: calc(var(--kw-hud-x) + 250px); right: auto; translate: none; max-width: calc(100% - 2 * var(--kw-hud-x) - 460px); }
.kw-root.is-wide .kw-title { top: 70px; }
.kw-root.is-wide .kw-plate { padding: 4px 10px 4px 11px; }
@media (max-height: 620px) { .kw-plate { padding: 3px 9px 3px 10px; gap: 4px; } .kw-pips i { width: 6px; height: 6px; } }
@media (max-width: 700px) {
  .kw-root.is-wide .kw-more span { display: none; }
  .kw-root.is-wide .kw-continue--realm { left: 216px; max-width: calc(100% - 216px - 236px); }
  /* No room for words between the HUD buttons: the button is its picture + play (the label stays in aria-label). */
  .kw-root.is-wide .kw-continue__text { display: none; }
  .kw-root.is-wide .kw-continue { gap: 4px; }
  .kw-root.is-wide .kw-continue__go { width: 32px; height: 32px; }
}

.kw-title {
  position: absolute; z-index: 5; left: 50%; top: 74px; translate: -50% 0;
  padding: 8px 22px; border-radius: 999px; pointer-events: none;
  background: rgba(255,253,248,.92); color: var(--ink);
  font-family: var(--font-display); font-weight: 800; font-size: clamp(20px, 1.5vw + 14px, 28px);
  box-shadow: 0 10px 26px rgba(43,33,81,.18);
  animation: pop-in .45s cubic-bezier(.34,1.56,.64,1) .25s both;
  transition: opacity .6s ease, transform .6s ease;
}
.kw-title.is-gone { opacity: 0; transform: translateY(-10px); }

/* ---------- Today's Adventure sheet (Village notice board) ---------- */
.kw-sheet {
  position: absolute; inset: 0; z-index: 9;
  background: rgba(43,33,81,.38); display: flex; align-items: flex-end; justify-content: center;
  animation: screen-in .25s ease both;
}
.kw-sheet__card {
  position: relative; width: min(540px, 100%); max-height: 86%; overflow-y: auto;
  background: var(--surface); border-radius: 30px 30px 0 0;
  padding: 22px 18px calc(22px + var(--kido-sa-bottom));
  box-shadow: 0 -10px 40px rgba(43,33,81,.25);
}
.kw-sheet__title { font-size: 26px; margin: 2px 56px 14px 4px; }
.kw-sheet__close {
  position: absolute; top: 14px; right: 14px; width: 48px; height: 48px; border-radius: 50%;
  background: var(--grape-soft); color: var(--grape-deep); display: grid; place-items: center; font-size: 20px;
}
.kw-sheet__close:focus-visible { outline: 4px solid var(--sky); outline-offset: 2px; }
.kw-sheet .journey-step { width: 100%; text-align: left; min-height: 64px; }
.kw-sheet .journey-step__dot { overflow: hidden; display: grid; place-items: center; }
.kw-sheet .journey-step__dot img { width: 100%; height: 100%; object-fit: cover; }
.kw-sheet .journey-step__dot .kido-icon { width: 70%; height: 70%; }
.kw-sheet .journey-step:disabled { cursor: default; }

/* =========================================================================
   Ambient life (subtle; halted by reduced motion)
   ========================================================================= */
.kw-art .kw-cloud { animation: kw-drift 46s ease-in-out infinite alternate; }
.kw-art .kw-cloud--b { animation-duration: 60s; animation-delay: -20s; }
.kw-art .kw-cloud--c { animation-duration: 54s; animation-delay: -34s; }
.kw-art .kw-birds { animation: kw-birds 40s linear infinite; }
.kw-art .kw-bfly { animation: kw-flutter 16s ease-in-out infinite; }
.kw-art .kw-bfly--b { animation-duration: 21s; animation-direction: reverse; }
.kw-art .kw-wings { transform-box: fill-box; transform-origin: center; animation: kw-flap .26s ease-in-out infinite alternate; }
.kw-art .kw-canopy { transform-box: fill-box; transform-origin: 50% 100%; animation: kw-sway 5.5s ease-in-out infinite alternate; }
.kw-art .kw-crown { transform-box: fill-box; transform-origin: 50% 60%; animation: kw-sway 4.2s ease-in-out infinite alternate; }
.kw-art .kw-vine, .kw-art .kw-banner, .kw-art .kw-swing, .kw-art .kw-trunk-swing {
  transform-box: fill-box; transform-origin: 50% 0; animation: kw-sway 3.8s ease-in-out infinite alternate;
}
.kw-art .kw-vine--b { animation-duration: 4.6s; }
.kw-art .kw-seaweed { transform-box: fill-box; transform-origin: 50% 100%; animation: kw-sway-lg 3.4s ease-in-out infinite alternate; }
.kw-art .kw-seaweed--b { animation-duration: 4.4s; }
.kw-art .kw-smoke { animation: kw-smoke 3.6s ease-out infinite; }
.kw-art .kw-flag { transform-box: fill-box; transform-origin: 0 50%; animation: kw-flag 1.3s ease-in-out infinite alternate; }
.kw-art .kw-fall { animation: kw-shimmer 1.1s linear infinite; }
.kw-art .kw-flow > path, .kw-art .kw-trail > path { animation: kw-dash 2.8s linear infinite; }
.kw-art .kw-wave { animation: kw-wave 3.2s ease-in-out infinite alternate; }
.kw-art .kw-bob { transform-box: fill-box; transform-origin: 50% 100%; animation: kw-bob 3.2s ease-in-out infinite; }
.kw-art .kw-tw { animation: kw-tw 2.6s ease-in-out infinite; }
.kw-art .kw-float { animation: kw-float 5s ease-in-out infinite; }
.kw-art .kw-blink { animation: kw-blink 1.8s steps(2, jump-none) infinite; }
.kw-art .kw-pulse, .kw-art .kw-lamp, .kw-art .kw-beam, .kw-art .kw-screen-glow { animation: kw-pulse 3s ease-in-out infinite; }
.kw-art .kw-rays { animation: kw-rays 6s ease-in-out infinite alternate; }
.kw-art .kw-win { animation: kw-flicker 6s ease-in-out infinite; }
.kw-art .kw-fizz { animation: kw-fizz 1.9s ease-in infinite; }
.kw-art .kw-arm { transform-box: fill-box; transform-origin: 50% 0; animation: kw-armwave 2.6s ease-in-out infinite; }
.kw-art .kw-breathe { transform-box: fill-box; transform-origin: 50% 100%; animation: kw-breathe 3.4s ease-in-out infinite; }
.kw-art .kw-paddle { animation: kw-paddle 6s ease-in-out infinite alternate; }
.kw-art .kw-notes { animation: kw-notes 2.6s ease-in-out infinite; }
.kw-art .kw-bubbles { animation: kw-rise 4.2s linear infinite; }
.kw-art .kw-school { animation: kw-school 9s ease-in-out infinite alternate; }
.kw-art .kw-swim { animation: kw-swim 16s linear infinite; }
.kw-art .kw-comet { animation: kw-comet 11s linear infinite; }
.kw-art .kw-wave-line { animation: kw-wave 1.4s ease-in-out infinite alternate; }
.kw-art .kw-tilt { transform-box: fill-box; transform-origin: 50% 0; animation: kw-tilt 4s ease-in-out infinite alternate; }
.kw-art .kw-ripple-amb { transform-box: fill-box; transform-origin: center; animation: kw-ripple 3.2s ease-out infinite; }
.kw-art .kw-spin { transform-box: fill-box; transform-origin: center; animation: kw-spin 14s linear infinite; }
.kw-art .kw-flowdown > path { animation: kw-fall-dash 1.1s linear infinite; }
.kw-art .kw-jet { animation: kw-shimmer .9s ease-in-out infinite; }
.kw-art .kw-swim-slow { animation: kw-swim 34s linear infinite; }
@keyframes kw-spin { to { transform: rotate(360deg); } }
@keyframes kw-fall-dash { to { stroke-dashoffset: -32; } }

@keyframes kw-drift   { from { transform: translateX(-26px); } to { transform: translateX(34px); } }
@keyframes kw-birds   { from { transform: translate(-180px, 12px); } to { transform: translate(300px, -24px); } }
@keyframes kw-flutter { 0%,100% { transform: translate(0,0); } 25% { transform: translate(40px,-26px); } 50% { transform: translate(70px,6px); } 75% { transform: translate(24px,22px); } }
@keyframes kw-flap    { to { transform: scaleX(.3); } }
@keyframes kw-sway    { from { transform: rotate(-1.5deg); } to { transform: rotate(1.7deg); } }
@keyframes kw-sway-lg { from { transform: rotate(-6deg); } to { transform: rotate(6deg); } }
@keyframes kw-smoke   { 0% { transform: translateY(4px); opacity: 0; } 30% { opacity: 1; } 100% { transform: translateY(-12px); opacity: 0; } }
@keyframes kw-flag    { from { transform: scaleX(1) skewY(0deg); } to { transform: scaleX(.8) skewY(-7deg); } }
@keyframes kw-shimmer { 50% { opacity: .6; } }
@keyframes kw-dash    { to { stroke-dashoffset: -40; } }
@keyframes kw-wave    { from { transform: translateX(-6px); } to { transform: translateX(6px); } }
@keyframes kw-bob     { 50% { transform: translateY(-2.5px) rotate(2deg); } }
@keyframes kw-tw      { 50% { opacity: .2; } }
@keyframes kw-float   { 50% { transform: translateY(-4px); } }
@keyframes kw-blink   { 50% { opacity: .25; } }
@keyframes kw-pulse   { 50% { opacity: .5; } }
@keyframes kw-rays    { from { opacity: .5; } to { opacity: 1; } }
@keyframes kw-flicker { 0%, 90%, 100% { opacity: 1; } 94% { opacity: .55; } }
@keyframes kw-fizz    { 0% { transform: translateY(2px); opacity: 0; } 40% { opacity: 1; } 100% { transform: translateY(-6px); opacity: 0; } }
@keyframes kw-armwave { 0%, 60%, 100% { transform: rotate(0deg); } 70% { transform: rotate(-40deg); } 80% { transform: rotate(-10deg); } 90% { transform: rotate(-40deg); } }
@keyframes kw-breathe { 50% { transform: scaleY(1.018); } }
@keyframes kw-paddle  { from { transform: translateX(-8px); } to { transform: translateX(8px); } }
@keyframes kw-notes   { 0% { transform: translateY(6px); opacity: 0; } 30% { opacity: 1; } 100% { transform: translateY(-14px); opacity: 0; } }
@keyframes kw-rise    { 0% { transform: translateY(24px); opacity: 0; } 20% { opacity: 1; } 100% { transform: translateY(-46px); opacity: 0; } }
@keyframes kw-school  { from { transform: translateX(-40px); } to { transform: translateX(46px); } }
@keyframes kw-swim    { from { transform: translateX(340px); } to { transform: translateX(-340px); } }
@keyframes kw-comet   { 0% { transform: translate(560px, 40px); opacity: 0; } 4% { opacity: 1; } 22% { transform: translate(140px, 150px); opacity: 0; } 100% { transform: translate(140px, 150px); opacity: 0; } }
@keyframes kw-tilt    { from { transform: rotate(-4deg); } to { transform: rotate(4deg); } }
@keyframes kw-ripple  { 0% { opacity: .9; transform: scale(.4); } 100% { opacity: 0; transform: scale(1.7); } }

/* ---------- Hidden discoveries (tap-triggered) ---------- */
.kw-disc { cursor: pointer; }
.kw-d-critter, .kw-d-ripple, .kw-d-fish, .kw-d-spark, .kw-d-bub { opacity: 0; }
.kw-disc.is-on .kw-d-shake { transform-box: fill-box; transform-origin: 50% 100%; animation: kw-rustle .6s ease-in-out; }
.kw-disc.is-on.has-extra .kw-d-critter { animation: kw-peek 1.8s ease-in-out; }
.kw-disc.is-on .kw-d-bird { transform-box: fill-box; transform-origin: center; animation: kw-flyaway 2.4s ease-in forwards; }
.kw-disc:not(.is-on) .kw-d-bird { animation: kw-fadein .9s ease; }
.kw-disc.is-on .kw-d-ripple { transform-box: fill-box; transform-origin: center; animation: kw-ripple 1.5s ease-out; }
.kw-disc.is-on.has-extra .kw-d-fish { transform-box: fill-box; transform-origin: center; animation: kw-jump 1.3s ease-in-out; }
.kw-disc.is-on .kw-d-spark { transform-box: fill-box; transform-origin: center; animation: kw-sparkle 1.5s ease-out; }
.kw-disc.is-on .kw-school { animation: kw-dart 1.2s ease-out; }
.kw-disc.is-on .kw-d-head { transform-box: fill-box; transform-origin: 50% 100%; animation: kw-headtilt .9s ease-in-out; }
.kw-disc.is-on .kw-eyes { animation: kw-blink .25s steps(2, jump-none) 4; }
.kw-disc.is-on .kw-d-bub { animation: kw-rise 1.8s ease-out; }

@keyframes kw-rustle  { 20% { transform: rotate(-4deg); } 45% { transform: rotate(4deg); } 70% { transform: rotate(-2.5deg); } }
@keyframes kw-peek    { 0% { opacity: 0; transform: translateY(14px); } 25%, 72% { opacity: 1; transform: translateY(-8px); } 100% { opacity: 0; transform: translateY(14px); } }
@keyframes kw-flyaway { 0% { transform: translate(0,0); } 12% { transform: translate(-3px,-6px); } 100% { transform: translate(-170px,-230px) scale(.7); opacity: 0; } }
@keyframes kw-fadein  { from { opacity: 0; } to { opacity: 1; } }
@keyframes kw-jump    { 0% { opacity: 0; transform: translate(0,8px) rotate(0deg); } 20% { opacity: 1; } 50% { transform: translate(-12px,-30px) rotate(-30deg); } 88% { opacity: 1; } 100% { opacity: 0; transform: translate(-24px,6px) rotate(-75deg); } }
@keyframes kw-sparkle { 0% { opacity: 0; transform: scale(.4); } 30% { opacity: 1; transform: scale(1.1); } 100% { opacity: 0; transform: scale(.8); } }
@keyframes kw-dart    { 40% { transform: translate(-70px,-16px); } 100% { transform: translate(0,0); } }
@keyframes kw-headtilt { 30% { transform: rotate(-12deg); } 65% { transform: rotate(9deg); } }

/* ---------- Landmark + spot feedback ---------- */
.kw-place.is-shake { transform-box: fill-box; transform-origin: 50% 100%; animation: kw-rustle .5s ease-in-out; }
.kw-place.is-new { transform-box: fill-box; transform-origin: 50% 100%; animation: kw-hello 1s cubic-bezier(.34,1.56,.64,1) 2; }
/* Idle "tap me": an unplayed spot hops now and then, one at a time (world.js staggers
   --nudge-at); played spots stay still, and the tap's is-pop below takes over. */
.kw-spot.is-nudge { transform-box: fill-box; transform-origin: 50% 100%; animation: kw-nudge 15s ease-in-out var(--nudge-at, 2s) infinite; }
@keyframes kw-nudge { 0%, 6%, 100% { transform: none; } 1.5% { transform: scale(1.05, .93); } 3% { transform: scale(.97, 1.1); } 4.5% { transform: scale(1.03, .97); } }
.kw-spot.is-pop { transform-box: fill-box; transform-origin: 50% 100%; animation: kw-hello .35s cubic-bezier(.34,1.56,.64,1); }
@keyframes kw-hello { 50% { transform: scale(1.07); } }

/* ---------- Reduced motion: stop the ambient life, keep everything usable ---------- */
html.reduce-motion .kw-art .kw-cloud, html.reduce-motion .kw-art .kw-birds, html.reduce-motion .kw-art .kw-bfly,
html.reduce-motion .kw-art .kw-wings, html.reduce-motion .kw-art .kw-canopy, html.reduce-motion .kw-art .kw-crown,
html.reduce-motion .kw-art .kw-vine, html.reduce-motion .kw-art .kw-banner, html.reduce-motion .kw-art .kw-swing,
html.reduce-motion .kw-art .kw-trunk-swing, html.reduce-motion .kw-art .kw-seaweed, html.reduce-motion .kw-art .kw-smoke,
html.reduce-motion .kw-art .kw-flag, html.reduce-motion .kw-art .kw-fall, html.reduce-motion .kw-art .kw-flow > path,
html.reduce-motion .kw-art .kw-trail > path, html.reduce-motion .kw-art .kw-wave, html.reduce-motion .kw-art .kw-bob,
html.reduce-motion .kw-art .kw-tw, html.reduce-motion .kw-art .kw-float, html.reduce-motion .kw-art .kw-blink,
html.reduce-motion .kw-art .kw-pulse, html.reduce-motion .kw-art .kw-lamp, html.reduce-motion .kw-art .kw-beam,
html.reduce-motion .kw-art .kw-screen-glow, html.reduce-motion .kw-art .kw-rays, html.reduce-motion .kw-art .kw-win,
html.reduce-motion .kw-art .kw-fizz, html.reduce-motion .kw-art .kw-arm, html.reduce-motion .kw-art .kw-breathe,
html.reduce-motion .kw-art .kw-paddle, html.reduce-motion .kw-art .kw-notes, html.reduce-motion .kw-art .kw-bubbles,
html.reduce-motion .kw-art .kw-school, html.reduce-motion .kw-art .kw-swim, html.reduce-motion .kw-art .kw-comet,
html.reduce-motion .kw-art .kw-wave-line, html.reduce-motion .kw-art .kw-tilt, html.reduce-motion .kw-art .kw-ripple-amb,
html.reduce-motion .kw-art .kw-spin, html.reduce-motion .kw-art .kw-flowdown > path, html.reduce-motion .kw-art .kw-jet,
html.reduce-motion .kw-art .kw-swim-slow,
html.reduce-motion .kw-art .kw-disc [class*="kw-d-"], html.reduce-motion .kw-place, html.reduce-motion .kw-spot {
  animation: none !important;
}
html.reduce-motion .kw-art .kw-comet { opacity: 0; }
@media (prefers-reduced-motion: reduce) {
  .kw-art * { animation-duration: .001s !important; animation-iteration-count: 1 !important; }
  .kw-art .kw-comet { opacity: 0; }
}
