.world-picker{margin:0 0 26px}.world-picker h2{font-family:Georgia,serif;font-size:30px;margin:8px 0 16px}.world-select-label{max-width:340px;margin-bottom:15px}.world-cards{display:grid;grid-template-columns:repeat(6,minmax(0,1fr));gap:12px}.world-card{display:flex;flex-direction:column;align-items:center;gap:8px;padding:12px 10px;background:#fffdf5;box-shadow:0 4px 12px #617b5410;border:2px solid #dce5d1;text-align:center}.world-card img{width:100%;height:100px;object-fit:contain}.world-card strong{font-size:13px;line-height:1.25}.world-card span{font-size:10px;color:#738470;font-weight:500}.world-card[aria-pressed=true]{border-color:#448271;background:#e8f3e7;box-shadow:0 0 0 3px #80b09b30}.world-card:hover{transform:translateY(-3px);transition:transform .2s}.hero h1{font-size:clamp(38px,4vw,64px);letter-spacing:-2px}body:not([data-world=dragon]) .hero-art{background:radial-gradient(ellipse,#fff5c0,#d4eee440 68%);border-radius:25px;height:340px;min-height:0}body:not([data-world=dragon]) .hero-art img{object-fit:contain;padding:12px 20px 40px;box-shadow:none}body:not([data-world=dragon]) .modal-icon{background-size:contain;background-repeat:no-repeat;background-position:center}
body:not([data-world=dragon]) .battle.arena{height:330px}body:not([data-world=dragon]) .dragon-target{display:none}body:not([data-world=dragon]) .arena .knights{left:2%;width:96%;top:62px;bottom:12px;gap:12px}body:not([data-world=dragon]) .arena-caption{max-width:95%}body:not([data-world=dragon]) .arena .world-player{padding:8px 7px 9px;border-radius:18px;border:1px solid #ffffffc0;border-bottom:4px solid var(--team);background:linear-gradient(#ffffff60,#fffff5aa);min-width:0}body:not([data-world=dragon]) .arena-ground{background:linear-gradient(#cee2d3,#e7eee0)}
.world-stage{height:170px;position:relative;isolation:isolate}.world-character{position:absolute;left:0;bottom:5px;height:65%;width:36%;object-fit:contain;z-index:4;transform-origin:50% 90%;animation:worker-idle 3s infinite ease-in-out}.goal-stage{position:absolute;right:0;bottom:0;height:100%;width:70%}.goal-art,.goal-ghost{position:absolute;width:100%;height:100%;object-fit:contain;inset:0}.goal-ghost{opacity:.12;filter:grayscale(1)}.goal-art{clip-path:inset(100% 0 0);transition:clip-path .65s ease-out}.world-score{font-size:12px;font-weight:800;margin:3px 0 7px}.world-progress{height:6px;background:#c5d5c270;border-radius:5px;overflow:hidden}.world-progress>div{height:100%;width:0;background:var(--team);transition:width .5s}.world-stage-label{font-size:10px;line-height:1.3;margin-top:5px;min-height:26px;color:#53715c}.world-action{position:absolute;top:25%;left:0;right:0;text-align:center;z-index:10;font-size:18px;color:#34603f;font-weight:900;text-shadow:0 2px white,2px 0 white,-2px 0 white;opacity:0;pointer-events:none}.world-hit .world-action{animation:gain-word 1.15s both}.world-hit .world-character{animation:worker-work .8s}.world-particles{position:absolute;inset:0;overflow:hidden;pointer-events:none;z-index:9}.reward-flight{position:absolute;left:5%;top:50%;width:18px;height:18px;background:linear-gradient(135deg,#fff,#efd788,#cd9b39);border-radius:5px;box-shadow:0 0 8px white;animation:reward-delivery 1s both}.rocket-fire,.candle-flame,.castle-gate,.castle-flag{display:none}.world-player .place-label{top:36px;left:10%;right:10%;font-size:18px;animation:place-arrive .4s 2s both}.world-finish{height:155px;position:relative;display:flex;justify-content:center;align-items:end}.world-finish img{object-fit:contain;width:45%;height:125px}.world-finish strong{position:absolute;top:0;left:0;right:0;font-size:14px;color:#44705a}.finish-character{animation:happy-knight .8s infinite alternate}.world-confetti{position:absolute;left:calc(5% + var(--n) * 8%);top:-10px;background:var(--team);width:7px;height:12px;animation:world-confetti 2.6s calc(var(--n) * .06s) both}.world-confetti:nth-child(2n){background:#eabd56}.world-confetti:nth-child(3n){background:#8ad5cd}
body[data-world=space]{background:linear-gradient(#e8ebfb,#f4f6fc)}body[data-world=space] .arena-sky{background:radial-gradient(circle at 90% 17%,#fff7b9 0 12px,transparent 13px),radial-gradient(circle at 25% 30%,white 0 3px,transparent 4px),radial-gradient(circle at 60% 25%,white 0 2px,transparent 3px),linear-gradient(#d6def6,#e7ecfb)}body[data-world=space] .arena-ground{background:linear-gradient(#bfc8de,#dbe2f1)}.world-space .goal-stage{height:95%;width:60%;right:2%}.world-space.world-won .world-character{animation:astronaut-board 1.2s forwards}.world-space.world-won .goal-stage{animation:rocket-launch 3s 1.2s forwards}.world-space .rocket-fire{position:absolute;left:44%;top:90%;width:16%;height:35%;background:linear-gradient(#fffcd2,#ffca5c,#fa814c00);clip-path:polygon(0 0,100% 0,90% 65%,50% 100%,10% 60%);transform-origin:50% 0}.world-space.world-won .rocket-fire{display:block;animation:flame-flicker .2s infinite alternate}.world-space.world-won:after{content:'Gelanceerd!';position:absolute;left:10%;right:10%;top:52%;text-align:center;color:#55728f;font-weight:800;opacity:0;animation:place-arrive .5s 3.5s forwards}.world-finish.world-space .finish-goal{animation:rocket-orbit 3s infinite ease-in-out}
body[data-world=ocean]{background:linear-gradient(#dff3f5,#eef9ee)}body[data-world=ocean] .arena-sky{background:radial-gradient(circle at 13% 25%,#ffffff90 0 6px,transparent 7px),radial-gradient(circle at 76% 42%,#ffffff70 0 10px,transparent 11px),linear-gradient(#bce7ed,#85ccd3)}body[data-world=ocean] .arena-ground{background:linear-gradient(#eee1b2,#faf0d1)}.world-ocean .goal-ghost,.world-animals .goal-ghost{display:none}.world-ocean .goal-stage{height:auto;aspect-ratio:1280/1224;width:72%;bottom:0}.world-ocean .world-character{width:55%;height:50%;bottom:45%;left:-3%;animation:diver-swim 3s infinite ease-in-out}.world-ocean .goal-collection{position:absolute;left:26%;top:46%;width:60%;height:17%;display:flex;flex-wrap:wrap;align-content:flex-end;gap:1px;transform:rotate(-4deg);overflow:hidden}.collected-pearl{flex:0 0 11%;aspect-ratio:1;border-radius:50%;background:radial-gradient(circle at 30% 25%,white 0 18%,#fde5e7 40%,#b7d8df 80%,#7baeb5);box-shadow:0 0 2px white;animation:pearl-pop .6s}.reward-ocean{border-radius:50%;background:radial-gradient(circle at 30% 25%,white,#ffe9ee,#a2d6dd)}.world-ocean.world-hit .world-character{animation:diver-fetch 1s}.world-ocean.world-won .goal-stage{filter:drop-shadow(0 0 9px #fff4a5);animation:treasure-glow 1.5s infinite alternate}.world-ocean.world-won .world-character{animation:diver-lap 3s infinite ease-in-out}.world-ocean .world-progress{background:#c0e1df}
body[data-world=animals] .arena-sky{background:linear-gradient(#e2f2d9,#d0e6ac)}body[data-world=animals] .arena-ground{background:linear-gradient(#b7cf7f,#d7e6a2)}.world-animals .goal-stage{height:auto;aspect-ratio:3/2;width:88%;bottom:20%;right:0}.world-animals .world-character{height:53%;width:40%;bottom:0;left:-2%}.world-animals .goal-collection{position:absolute;left:23%;right:-1%;bottom:-23%;height:57%;display:grid;grid-template-columns:repeat(6,minmax(0,1fr));align-content:end;gap:1px}.rescued-animal{width:100%;height:27px;object-fit:contain;animation:animal-arrive .9s both;z-index:3}.reward-animals{width:45px;height:40px;object-fit:contain;background:none;box-shadow:none;animation:animal-cross 1.05s both}.world-animals.world-won .rescued-animal{animation:animal-parade 1.2s calc(var(--n) * .08s) infinite alternate}.world-animals.world-won .world-character{animation:happy-knight 1s infinite alternate}
body[data-world=cake]{background:linear-gradient(#fff1e9,#fdf7ed)}body[data-world=cake] .arena-sky{background:repeating-linear-gradient(90deg,#fbe9e5 0 35px,#fff6ed 35px 70px)}body[data-world=cake] .arena-ground{background:linear-gradient(#e7c4a4,#f6dfc6);height:28%;border-radius:0}.world-cake .goal-stage{width:60%;height:100%;right:0}.world-cake .world-character{height:70%;width:43%;left:-3%}.world-cake.world-hit .world-character{animation:baker-stir .7s}.world-cake.world-won .world-character{animation:baker-present 1.2s infinite alternate}.world-cake.world-won .goal-art{filter:drop-shadow(0 0 8px #ffe793)}.world-cake .candle-flame{position:absolute;left:49%;top:0;width:8%;height:9%;background:radial-gradient(ellipse at 50% 75%,#fffed0,#ffd15b 50%,#ee823100 72%);border-radius:60% 40% 50% 50%}.world-cake.world-won .candle-flame{display:block;animation:flame-flicker .45s infinite alternate}
body[data-world=castle] .arena-sky{background:linear-gradient(#e2edff,#f5ebd7)}body[data-world=castle] .arena-ground{background:linear-gradient(#cad9a3,#e2e7b7)}.world-castle .goal-stage{width:74%;height:auto;aspect-ratio:1204/1280;bottom:0;right:0}.world-castle .world-character{height:64%;width:36%;bottom:0;left:calc(var(--progress) * 12%)}.world-castle .castle-gate{position:absolute;left:40%;top:56%;width:20%;height:24%;background:#352d39;border-radius:48% 48% 0 0;overflow:hidden;perspective:200px;opacity:0}.world-castle.world-won .castle-gate{display:flex;opacity:1}.castle-gate span{width:50%;height:100%;background:repeating-linear-gradient(90deg,#ab753f 0 5px,#785127 6px 7px);border:1px solid #d6b375;transform-origin:left;animation:gate-open-left 1.2s forwards}.castle-gate span+span{transform-origin:right;animation-name:gate-open-right}.world-castle.world-won .world-character{animation:knight-enter 2.5s 1s forwards}.world-castle .castle-flag{position:absolute;left:51%;top:-8%;width:20%;height:12%;border-left:2px solid #9e7949;background:var(--team);clip-path:polygon(0 0,100% 0,80% 45%,100% 90%,10% 90%,10% 100%,0 100%);transform-origin:left}.world-castle.world-won .castle-flag{display:block;animation:flag-wave .65s infinite alternate}
.storm .world-player:not(.world-won) .world-character{filter:drop-shadow(0 0 6px #ffdc7b)}body:not([data-world=dragon]) .world-won .place-label{background:#fff3bc}body:not([data-world=dragon]) .team-finished .question{height:80px}
@keyframes worker-idle{50%{transform:translateY(-3px)}}@keyframes worker-work{30%{transform:rotate(-8deg)}65%{transform:translateX(9px) rotate(5deg)}}@keyframes reward-delivery{0%{opacity:0;transform:scale(.5)}20%{opacity:1}100%{left:65%;top:36%;transform:rotate(130deg) scale(.4);opacity:0}}@keyframes astronaut-board{to{transform:translate(90%, -32%) scale(.2);opacity:0}}@keyframes rocket-launch{10%{transform:translateY(2px) rotate(-2deg)}20%{transform:translateY(0) rotate(2deg)}35%{transform:translateY(-15px)}100%{transform:translateY(-330px) scale(.5);opacity:0}}@keyframes flame-flicker{to{transform:scaleY(.75) scaleX(1.2)}}@keyframes rocket-orbit{50%{transform:translateY(-15px) rotate(8deg)}}@keyframes diver-swim{50%{transform:translate(7px,-5px) rotate(3deg)}}@keyframes diver-fetch{50%{transform:translate(20%,-8px) rotate(10deg)}}@keyframes diver-lap{50%{transform:translate(40%,-20%) rotate(-12deg)}}@keyframes treasure-glow{to{filter:drop-shadow(0 0 18px #fff5b0)}}@keyframes pearl-pop{from{transform:translateY(-25px) scale(.2)}to{transform:none}}@keyframes animal-arrive{from{transform:translateX(-60px);opacity:0}to{transform:none;opacity:1}}@keyframes animal-cross{0%{left:0;top:65%;opacity:0}20%{opacity:1}100%{left:75%;top:75%;opacity:0}}@keyframes animal-parade{to{transform:translate(5px,-5px) rotate(3deg)}}@keyframes baker-stir{25%{transform:rotate(-6deg)}75%{transform:rotate(7deg)}}@keyframes baker-present{to{transform:translateY(-5px) rotate(-5deg)}}@keyframes gate-open-left{to{transform:rotateY(-85deg)}}@keyframes gate-open-right{to{transform:rotateY(85deg)}}@keyframes knight-enter{to{transform:translate(90%,-4%) scale(.25);opacity:0}}@keyframes flag-wave{to{transform:skewY(8deg) scaleX(.85)}}@keyframes world-confetti{0%{opacity:0}15%{opacity:1}100%{top:100%;transform:rotate(300deg);opacity:0}}
@media(max-width:1000px){.world-cards{grid-template-columns:repeat(3,minmax(0,1fr))}.world-card img{height:80px}body:not([data-world=dragon]) .arena .knights{gap:6px}.world-stage{height:160px}.world-score{font-size:10px}.world-stage-label{font-size:9px}.world-player .place-label{font-size:14px}.world-action{font-size:13px}.world-finish{height:120px}.world-finish img{height:95px}}
@media(max-height:760px) and (min-width:1000px){body:not([data-world=dragon]) .battle.arena{height:275px}body:not([data-world=dragon]) .arena .knights{top:55px;bottom:8px}.world-stage{height:128px}.world-stage-label{min-height:22px}.world-finish{height:110px}.world-finish img{height:85px}}
@media(prefers-reduced-motion:reduce){.world-space.world-won .goal-stage{opacity:1;transform:none}.world-space.world-won .world-character,.world-castle.world-won .world-character{opacity:1}.world-action{opacity:1}.reward-flight,.world-confetti{display:none}.castle-gate span{transform:rotateY(-85deg)}.castle-gate span+span{transform:rotateY(85deg)}}
.world-animals .goal-collection{grid-template-rows:repeat(var(--collection-rows,2),minmax(0,1fr));height:68%;bottom:-25%}.rescued-animal{height:100%;min-height:0}.world-ocean .goal-collection{display:grid;grid-template-columns:repeat(6,minmax(0,1fr));grid-template-rows:repeat(var(--collection-rows,2),minmax(0,1fr));gap:1px}.collected-pearl{width:100%;height:100%;min-height:0;aspect-ratio:auto;max-width:12px;max-height:12px}
@keyframes astronaut-board{to{transform:translate(140%,-48%) scale(.2);opacity:0}}
.world-castle .goal-stage{aspect-ratio:1208/1302}.world-ocean .goal-stage{aspect-ratio:1286/1223}.world-animals.world-won .goal-collection{animation:parade-march 3s infinite alternate ease-in-out}@keyframes parade-march{from{transform:translateX(-8%)}to{transform:translateX(18%)}}
/* Bound proportional scenery by both dimensions, including its decorations. */
.world-ocean .world-stage,.world-animals .world-stage,.world-castle .world-stage{container-type:size}
.world-ocean .goal-stage{width:min(72%,calc(100cqh * 1286 / 1223))}
.world-animals .goal-stage{width:min(88%,calc(80cqh * 3 / 2))}
.world-castle .goal-stage{width:min(74%,calc(92cqh * 1208 / 1302))}
/* The dragon's shield must follow its height, not a wide two-team column. */
.personal-dragon{container-type:size}
.personal-shield{width:min(100%,100cqh);margin-inline:auto}

/* Ten pearls fit in the opening; each next ten form a higher layer. */
.world-ocean .goal-collection{display:block;left:0;top:0;width:100%;height:100%;transform:none;overflow:visible}
.world-ocean .collected-pearl{position:absolute;width:8%;height:auto;aspect-ratio:1.2;max-width:none;max-height:none;min-height:0}
body[data-world=space] .movement-card{background:#f1f3ff}body[data-world=ocean] .movement-card{background:#ecfafb}body[data-world=cake] .movement-card{background:#fff5ef}

.world-cards{grid-template-columns:repeat(auto-fit,minmax(130px,1fr))}
body[data-world=tug] .arena .knights{display:none}
body[data-world=tug] .arena-ground{background:linear-gradient(#c4d993,#e5efc7)}
body[data-world=tug] .arena-sky{background:linear-gradient(#cbeaf1,#f3fbfc)}
.tug-scene{position:absolute;inset:65px 0 0;overflow:hidden}
.tug-motion{position:absolute;inset:40px 0 16px;transition:transform .8s cubic-bezier(.2,.7,.3,1)}
.tug-players{position:absolute;top:0;width:24%;height:100%;object-fit:contain;z-index:3}
.tug-players-left{left:24%}.tug-players-right{right:24%}
.tug-rope{position:absolute;inset:0;width:100%;height:100%;overflow:visible;z-index:2;pointer-events:none}.tug-rope path{fill:none;stroke:#966027;stroke-width:7;stroke-linecap:round;vector-effect:non-scaling-stroke;transition:d .75s ease-in}.tug-rope use{fill:none;stroke:#e7c38a;stroke-width:3;stroke-dasharray:4 3;vector-effect:non-scaling-stroke;pointer-events:none}
.tug-ribbon{position:absolute;left:calc(50% - 6px);top:48%;width:12px;height:28px;background:#e44e58;clip-path:polygon(0 0,100% 0,100% 100%,50% 78%,0 100%);z-index:4;transform:rotate(-8deg)}
.tug-center-line{position:absolute;top:34px;bottom:9px;left:calc(50% - 2px);width:4px;background:repeating-linear-gradient(white 0 12px,#ffffff40 12px 18px);box-shadow:0 0 2px #8aac70}
.tug-center-line span{position:absolute;bottom:0;left:50%;transform:translateX(-50%);font-size:9px;letter-spacing:1px;white-space:nowrap;color:#536c48;background:#fffde9;padding:3px 7px;border-radius:5px}
.tug-label{position:absolute;top:0;width:40%;text-align:center;display:flex;justify-content:center;align-items:center;gap:10px;font-size:14px}.tug-label-left{left:4%;color:#9d4c28}.tug-label-right{right:4%;color:#237d99}.tug-label span{background:#fff9;padding:4px 10px;border-radius:20px;font-size:12px}.tug-scene[data-ending="released"][data-winner="0"] .tug-players-left,.tug-scene[data-ending="released"][data-winner="1"] .tug-players-right{animation:tug-cheer .55s .75s 5 alternate}.tug-scene[data-winner="0"] .tug-players-right,.tug-scene[data-winner="1"] .tug-players-left{animation:tug-stumble .35s .2s 7 alternate}.tug-scene[data-winner="0"] .tug-motion,.tug-scene[data-winner="1"] .tug-motion{transition-duration:2.8s}
@keyframes tug-cheer{to{translate:0 -12px}}@keyframes tug-stumble{to{rotate:4deg}}
@media(max-height:760px){body[data-world=tug] .battle.arena{height:260px}.tug-scene{inset:60px 0 0}.tug-motion{inset:30px 0 14px}}
@media(prefers-reduced-motion:reduce){.tug-motion{transition:none!important}.tug-players{animation:none!important}}

.tug-scene[data-ending="released"] .tug-ribbon{top:89%;height:12px;rotate:65deg;transition:top .75s ease-in,rotate .75s,height .75s}.tug-scene[data-ending="released"] .tug-players-right,.tug-scene[data-ending="released"] .tug-players-left{animation-name:none}
.tug-scene[data-ending="released"][data-winner="0"] .tug-players-left,.tug-scene[data-ending="released"][data-winner="1"] .tug-players-right{animation-name:tug-cheer}
