/* Voorwerpen staan op het toneel, achter de letters en zonder inhoudsvenster. */
.scene {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden
}

.automaat {
  position: absolute;
  width: 29vh;
  height: 25vh;
  left: 26vw;
  bottom: 11vh;
  filter: drop-shadow(0 1vh 0 #2e176025)
}

.snoeppot {
  position: absolute;
  right: 26vw;
  bottom: 12vh;
  width: 15vh;
  height: 18vh;
  border: .4vh solid var(--inkt);
  border-radius: 2vh 2vh 4vh 4vh;
  background: #fffbff77;
  box-shadow: inset 1vh .5vh 0 #ffffff80
}

.pot-vulling {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 100%;
  transform: scaleY(0);
  transform-origin: bottom;
  border-radius: 0 0 3vh 3vh;
  background: radial-gradient(circle at 1vh 1vh, var(--citroen) .8vh, transparent .9vh) 0 0/2.6vh 2.6vh, var(--suikerspin);
  transition: transform .3s
}

.pot-streepjes {
  position: absolute;
  inset: 1vh;
  width: calc(100% - 2vh);
  height: calc(100% - 2vh)
}

.pot-streepjes path {
  stroke: var(--inkt);
  stroke-width: 1
}

.pot-deksel {
  position: absolute;
  left: -1vh;
  right: -1vh;
  height: 2vh;
  top: -6vh;
  border-radius: 2vh;
  background: var(--land);
  box-shadow: 0 .5vh 0 var(--inkt);
  opacity: 0;
  transition: transform .3s
}

.scene-klaar .pot-deksel {
  opacity: 1;
  transform: translateY(4.5vh)
}

.automaat-snoep {
  position: absolute;
  left: 37vw;
  bottom: 17vh;
  width: 5vh;
  height: 5vh;
  animation: pot-vlucht .65s ease-in forwards
}

@keyframes pot-vlucht {
  45% {
    transform: translate(12vw, -18vh) rotate(90deg)
  }

  to {
    transform: translate(28vw, 0) rotate(180deg);
    opacity: 0
  }
}

.toneel[data-soort=drill] .speler .poppetje {
  left: 26vw;
  bottom: 16vh;
  height: 26vh
}

.huppel-rij {
  position: absolute;
  left: 25vw;
  top: 82vh;
  height: 8vh;
  transition: transform .55s ease-in-out
}

.huppel-wolk {
  position: absolute;
  width: 22vh;
  height: 8vh
}

.huppel-prijs {
  position: absolute;
  width: 6vh;
  height: 6vh;
  left: 8vh;
  top: -5vh
}

.huppel-sprong .poppetje {
  animation: huppel .55s var(--veer)
}

.huppel-buit {
  position: absolute;
  left: 32vw;
  top: 64vh;
  width: 5vh;
  height: 5vh;
  animation: buit .65s ease-in forwards
}

@keyframes huppel {
  50% {
    transform: translateY(-14vh) rotate(8deg)
  }
}

@keyframes buit {
  to {
    transform: translate(50vw, -60vh) scale(.2);
    opacity: 0
  }
}

.vang-mand {
  position: absolute;
  left: 19vw;
  bottom: 12vh;
  width: 10vh;
  height: 7vh;
  border: .4vh solid var(--inkt);
  border-radius: 1vh 1vh 5vh 5vh;
  background: repeating-linear-gradient(90deg, #ffd2ad 0 1.2vh, #bd86ad 1.3vh 1.5vh)
}

.flits-pak {
  position: absolute;
  left: 50%;
  top: 22vh;
  width: 48vh;
  height: 30vh;
  transform: translateX(-50%);
  transition: transform .25s var(--veer)
}

.scene-flits:not(.pak-open) .flits-pak {
  transform: translateX(-50%) scaleX(.72)
}

.ster-slinger {
  position: absolute;
  left: 22vw;
  right: 10vw;
  top: 12vh;
  height: 18vh
}

.ster-slinger svg {
  width: 100%;
  height: 100%;
  overflow: visible
}

.ster-slinger g path {
  stroke: #b99ad6;
  stroke-width: 2;
  fill: none
}

.ster-slinger g .sterretje {
  fill: var(--lila)
}

.ster-slinger .licht path {
  stroke: var(--citroen);
  stroke-width: 3
}

.ster-slinger .licht .sterretje {
  fill: var(--citroen);
  filter: drop-shadow(0 0 .8vh #fff);
  animation: plop .35s var(--veer);
  transform-box: fill-box;
  transform-origin: center
}

.zitwolk {
  position: absolute;
  left: 7vw;
  bottom: 6vh;
  width: 25vh;
  height: 8vh
}

.vallende-ster {
  position: absolute;
  left: 24vw;
  top: 20vh;
  width: 6vh;
  height: 6vh;
  animation: vallende-ster .85s ease-in forwards
}

.slinger-klaar {
  animation: twinkel .5s
}

@keyframes vallende-ster {
  to {
    transform: translate(65vw, 26vh) rotate(180deg);
    opacity: 0
  }
}

.race-laag {
  position: absolute;
  inset: 0;
}

.race-laag-0 {
  color: var(--citroen);
  font-size: 3vh;
}

.race-laag-1 { opacity: .55; }
.race-camera .landdecor .decor { animation: none; }
.level-wereld.race-camera > .laag-lucht:not(.lucht-uit),
.race-camera :is(.race-schip, .race-finish, .tempo-wolk, .schimraket) { transition: none; }

.race-laag>span {
  left: 0;
  position: absolute;
  width: 8vh;
  height: 5vh
}

.race-laag-1>span {
  width: min(22vh, 22vw);
  height: 12vh
}

.race-laag-2>span {
  top: 78vh !important
}

.baas-raket {
  position: absolute;
  left: 26vw;
  bottom: 24vh;
  width: 28vh;
  height: 17vh;
  z-index: 2
}

.race-vlam {
  position: absolute;
  right: 23vh;
  top: 6vh;
  width: 18vh;
  transform-origin: right;
  transform: scaleX(var(--vlam-schaal, .167));
  height: 5vh;
  background: var(--mint);
  border-radius: 100% 30% 30% 100%;
  transition: transform .15s
}

.scene-race[data-trede='2'] .race-vlam {
  background: var(--citroen)
}

.scene-race[data-trede='3'] .race-vlam {
  background: var(--suikerspin)
}

.scene-race[data-trede='4'] .race-vlam {
  background: linear-gradient(#FF5A6E, #FFCF33, #3FCF7F, #3FA9F5, #A25DDC)
}

.tempo-wolk {
  position: absolute;
  bottom: 24vh;
  width: 19vh;
  height: 12vh;
  left: 0;
  transition: transform .1s linear
}

.schimraket {
  position: absolute;
  bottom: 43vh;
  width: 17vh;
  height: 10vh;
  opacity: .45;
  left: 0;
  transition: transform .1s linear
}

.schimraket>span:last-child {
  position: absolute;
  top: 9vh;
  white-space: nowrap;
  font-size: 2.2vh
}

.race-finish {
  position: absolute;
  bottom: 18vh;
  right: 2vw;
  width: 17vh;
  height: 30vh;
  transition: transform .2s
}

.toneel[data-soort=baas] .speler .poppetje {
  left: 22vw;
  bottom: 24vh;
  height: 28vh;
  clip-path: inset(0 0 38% 0)
}

.baas-raket {
  left: 20vw;
  bottom: 18vh
}

.toneel[data-soort=baas] .woorden {
  right: 34vw;
  top: 10vh
}

.toneel[data-soort=baas] .woord.straks {
  transform: translateX(calc(-50% + 22vw)) translateY(-10vh) scale(.3)
}

.kauwgombaasje {
  position: absolute;
  right: 18vw;
  top: 27vh;
  width: 32vh;
  height: 32vh;
  animation: dein 3s infinite alternate
}

.baas-gezicht {
  display: none
}

.baas-bellen {
  position: absolute;
  right: 10vw;
  top: 22vh;
  width: 60vh;
  height: 40vh
}

.baas-bel {
  position: absolute;
  width: var(--belmaat);
  height: var(--belmaat);
  border-radius: 50%;
  background: color-mix(in srgb, var(--belkleur) 50%, #fffbff88);
  box-shadow: inset .5vh .5vh 0 #fffbff99, 0 .4vh 0 #7b4ddb88
}

.baas-bel>.spel-beeld {
  opacity: .65
}

.baas-bel.geknapt {
  animation: knal .3s forwards
}

.bel-zwelt {
  animation: bel-zwelt .4s
}

.baas-oeps {
  animation: schud .4s
}

.baas-schot {
  position: absolute;
  width: 5vh;
  height: 4vh;
  left: 29vw;
  top: 60vh;
  animation: baas-schot .45s ease-in forwards
}

.baas-teller {
  position: absolute;
  right: 27vw;
  top: 65vh;
  font-family: var(--titel);
  font-size: 3vh
}

.kleur-lint {
  position: absolute;
  right: 28vw;
  top: 40vh;
  width: 3vh;
  height: 23vh;
  background: var(--land);
  border-radius: 50%;
  opacity: 0
}

.scene-klaar .kleur-lint {
  animation: lint-omhoog 1s ease-out forwards
}

@keyframes bel-zwelt {
  50% {
    transform: scale(1.3)
  }
}

@keyframes baas-schot {
  50% {
    transform: translate(calc(var(--schot-x, 30vw)*.5), calc(var(--schot-y, -20vh)*.5 - 12vh)) rotate(90deg)
  }

  to {
    transform: translate(var(--schot-x, 30vw), var(--schot-y, -20vh)) rotate(180deg);
    opacity: 0
  }
}

@keyframes lint-omhoog {
  from {
    opacity: 1;
    transform: rotate(25deg)
  }

  to {
    opacity: 0;
    transform: translateY(-70vh) rotate(-30deg)
  }
}

.vertrek-wolk {
  position: absolute;
  left: 6vw;
  bottom: 5vh;
  width: 29vh;
  height: 8vh
}

.geparkeerde-raket {
  position: absolute;
  right: 17vw;
  bottom: 10vh;
  width: 24vh;
  height: 16vh;
  opacity: .8
}

/* Stripjes: één groot moment in dezelfde wereld; pijltje en spatie voeren verder. */
.strip-laag {
  background: #cdb4ff;
  backdrop-filter: none;
  isolation: isolate
}

.stripboek {
  position: absolute;
  inset: 0
}

.stripboek h2 {
  position: absolute;
  top: 9vh;
  left: 15vw;
  right: 15vw;
  text-align: center;
  font-size: 6vh
}

.strip-plaatjes {
  position: absolute;
  inset: 19vh 0 18vh
}

.strip-plaatje {
  position: absolute;
  inset: 0;
  animation: camera-in .7s var(--veer)
}

.strip-scene {
  position: absolute;
  inset: 0
}

.strip-land {
  position: absolute;
  left: 18vw;
  bottom: 0;
  width: 52vh;
  height: 40vh;
  filter: grayscale(.8)
}

.strip-bel {
  position: absolute;
  width: 13vh;
  height: 14vh;
  left: calc(18vw + var(--i)*14vw);
  top: calc(4vh + var(--i)*6vh);
  border-radius: 50%;
  background: #fffbff66;
  box-shadow: inset .8vh .8vh 0 #fffbff99;
  animation: zweef 3s infinite alternate
}

.strip-baas {
  position: absolute;
  left: 30vw;
  bottom: 0;
  width: 44vh;
  height: 44vh;
  animation: dein 2s infinite alternate
}

.strip-raket {
  position: absolute;
  left: 28vw;
  bottom: 0;
  width: 40vh;
  height: 25vh;
  animation: zweef 3s infinite alternate
}

.strip-raket>.poppetje {
  left: 12vh;
  bottom: 10vh;
  height: 27vh;
  clip-path: inset(0 0 35% 0)
}

.strip-raket>.spel-beeld {
  position: absolute;
  inset: 0
}

.strip-raket>.strip-meevlieger {
  left: 35vh;
  top: -4vh;
  width: 22vh;
  height: 22vh
}

.strip-wolk {
  left: 59vw;
  bottom: 26vh;
  max-width: 29vw;
  font-size: 3.4vh
}

.stripboek>button {
  position: absolute;
  left: 50%;
  bottom: 7vh;
  transform: translateX(-50%)
}

[data-strip-status] {
  position: absolute;
  bottom: 17vh;
  left: 45vw;
  font-size: 2.5vh
}

/* Resultaat: de beloningen zelf zijn het decor. */
.resultaat-toneel {
  position: absolute;
  inset: 0
}

.resultaat-titel {
  position: absolute;
  left: 15vw;
  right: 15vw;
  top: 12vh;
  text-align: center;
  font-size: 7vh
}

.resultaat-dagreeks {
  position: absolute;
  left: 12vw;
  top: 3vh;
  display: flex;
  align-items: center;
  gap: 1vw;
  font-family: var(--titel);
  font-size: 3vh
}

.resultaat-dagreeks>.spel-beeld {
  width: 5vh;
  height: 6vh
}

.resultaat-moment {
  position: absolute;
  inset: 25vh 12vw 19vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2vh;
  text-align: center;
  font-size: 3vh
}

.resultaat-moment h2 {
  font-size: 5vh
}

.resultaat-moment>.medaille {
  height: 26vh
}

.resultaat-acties {
  position: absolute;
  bottom: 7vh;
  left: 10vw;
  right: 10vw;
  display: flex;
  justify-content: center;
  gap: 2vw
}

.grote-sterren {
  display: flex;
  gap: 3vw;
  color: #d6bade;
}

.grote-sterren .verdiend {
  color: var(--citroen);
  animation: ster-plof .6s var(--veer) backwards;
  animation-delay: calc(var(--volgorde)*.3s)
}

@keyframes ster-plof {
  from {
    transform: translateY(-35vh) scale(2);
    opacity: 0
  }

  to {
    transform: translateY(0) scale(1);
    opacity: 1
  }
}

.resultaat-getallen {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  display: flex;
  justify-content: space-around;
  gap: 5vw
}

.resultaat-getallen p {
  display: flex;
  flex-direction: column;
  gap: 2vh;
  max-width: 20vw
}

.resultaat-getallen strong {
  font-size: 7vh
}

.resultaat-getallen span {
  font-size: 2.7vh
}

.cadeau {
  position: relative;
  width: 34vh;
  height: 30vh;
  margin: 2vh
}

.cadeau.dicht {
  animation: cadeau-val .6s var(--veer)
}

.cadeau.open>.spel-beeld {
  transform: translateY(5vh)
}

.cadeau-vriend {
  position: absolute !important;
  width: 24vh !important;
  height: 24vh !important;
  left: 5vh !important;
  top: -3vh;
  animation: vriend-cadeau .6s var(--veer)
}

.cadeau-terugval {
  display: none
}

.glanzend,
.glansrand {
  filter: drop-shadow(0 0 1.2vh var(--citroen))
}

.glanzend:after,
.glansrand:after {
  content: '✦';
  position: absolute;
  right: 0;
  top: 0;
  color: var(--citroen);
  font-size: 5vh;
  animation: twinkel 1.5s infinite
}

.stralenkrans {
  position: absolute;
  inset: -12vh;
  background: repeating-conic-gradient(#fff5 0 12deg, transparent 12deg 30deg);
  border-radius: 50%;
  animation: stralen 24s linear infinite;
  z-index: -1
}

@keyframes stralen {
  to {
    transform: rotate(360deg)
  }
}

@keyframes cadeau-val {
  from {
    transform: translateY(-80vh) rotate(-12deg)
  }

  to {
    transform: translateY(0)
  }
}

@keyframes vriend-cadeau {
  from {
    transform: translateY(15vh) scale(.1)
  }

  to {
    transform: translateY(0)
  }
}

.grafiek {
  font-size: 2vh;
  text-align: center
}

.grafiek h2 {
  font-size: 3vh
}

.grafiek p {
  font-size: 2vh
}

.staafjes {
  display: flex;
  align-items: flex-end;
  justify-content: center;
  gap: 1.3vw;
  height: 19vh;
  padding-top: 2vh
}

.staaf {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: .4vh;
  font-size: 1.8vh
}

.staaf i {
  width: 2.5vw;
  max-width: 4vh;
  border-radius: 2vh 2vh .7vh .7vh;
  background: linear-gradient(var(--mint), #95c2f7);
  box-shadow: inset .5vh .3vh 0 #fff7
}

.staaf small {
  font-size: 1.8vh
}

.oefenbaan-scherm {
  overflow: clip;
}

.oefenwereld {
  position: absolute;
  inset: 0
}

.oefenwereld>.knoppen {
  position: absolute;
  bottom: 10vh;
  left: 35vw;
  right: 8vw
}

.oefenwereld>.grafiek {
  position: absolute;
  top: 46vh;
  left: 40vw;
  right: 7vw
}

.oefenwereld .maatje .praat {
  left: 34vw;
  bottom: 60vh
}

/* Speelhalspellen gebruiken de hele wereld; modelcoördinaten blijven onveranderd. */
.typespel-toneel {
  position: absolute;
  inset: 0;
  overflow: hidden
}

.typespel-teller,
.typespel-reeks {
  font-family: var(--titel);
  font-size: 3.5vh;
  color: var(--melk);
  -webkit-text-stroke: .16em var(--inkt);
  paint-order: stroke fill
}

.typespel-reeks {
  font-size: 2.8vh
}

.spel-hartjes {
  display: inline-flex;
  gap: .5vh
}

.spel-hartjes svg {
  width: 3.8vh;
  height: 3.8vh
}

.regen-zone {
  position: absolute;
  inset: 14vh 0 18vh
}

.regen-snoep {
  position: absolute;
  transform: translateX(-50%);
  width: 22vw;
  height: 16vh;
  text-align: center
}

.regen-snoep>.spel-beeld {
  width: 13vh;
  height: 10vh;
  animation: zweef 2s infinite alternate
}

.regen-woord {
  display: flex;
  justify-content: center;
  white-space: pre;
  font-family: var(--typ);
  font-weight: var(--typgewicht, 800);
  font-size: clamp(34px, 6vh, 64px);
  position: absolute;
  top: 8vh;
  left: 50%;
  transform: translateX(-50%)
}

.regen-snoep.doel {
  filter: drop-shadow(0 0 2vh #fffbff)
}

.regen-maatje .poppetje {
  height: 25vh;
  left: 4vw;
  bottom: 3vh
}

.sprint-baan {
  position: absolute;
  inset: 52vh 0 15vh
}

.sprint-schip {
  position: absolute;
  bottom: 0;
  width: 30vh;
  height: 18vh;
  left: 0;
  transition: transform .15s
}

.sprint-schip .poppetje {
  height: 24vh;
  left: 8vh;
  bottom: 8vh;
  clip-path: inset(0 0 38% 0)
}

.sprint-schip>.spel-beeld {
  z-index: 2
}

.sprint-record {
  position: absolute;
  top: 0;
  bottom: 0;
  border-left: .6vh dashed var(--citroen);
  padding-left: 1vh;
  font-size: 2.5vh
}

.sprint-woord {
  position: absolute;
  top: 30vh;
  left: 50%;
  transform: translateX(-50%)
}

.typespel-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  z-index: 9;
  background: #cdb4ff20;
  pointer-events: none
}

.spel-startwolk {
  max-width: 55vw;
  text-align: center
}

.type-start-beeld {
  height: 22vh;
  margin-bottom: 2vh
}

.typespel-uitslag {
  text-align: center;
  max-width: 85vw;
  max-height: 80vh;
  overflow: auto;
  padding: 2vh;
  font-size: 2.8vh
}

.typespel-uitslag h2 {
  font-size: 7vh;
  color: var(--melk);
  -webkit-text-stroke: .15em var(--inkt);
  paint-order: stroke fill
}

.spel-scores {
  display: flex;
  gap: 2vw;
  justify-content: center;
  flex-wrap: wrap;
  margin: 2vh
}

.spel-medailles {
  display: flex;
  gap: 1vw;
  justify-content: center
}

.spel-medailles .medaille {
  height: 9vh
}

.typespel-uitslag .knoppen {
  margin-top: 2vh
}

.wiebel {
  animation: schud .3s
}

.is-gepauzeerd * {
  animation-play-state: paused !important
}

@media(max-aspect-ratio:4/3) {
  .strip-wolk {
    left: 44vw;
    max-width: 50vw;
    bottom: 39vh
  }

  .resultaat-titel {
    font-size: 5vh;
    top: 14vh
  }

  .resultaat-getallen strong {
    font-size: 7vh
  }

  .spel-startwolk {
    max-width: 90vw
  }

  .regen-woord {
    font-size: 4vh
  }

  .typespel-teller {
    font-size: 2.5vh
  }
}

@media(prefers-reduced-motion:reduce) {

  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important
  }

  .baas-bel.geknapt {
    visibility: hidden
  }

  .vliegende-munt,
  .automaat-snoep,
  .huppel-buit,
  .baas-schot,
  .vallende-ster {
    display: none
  }
}

.vang-buit {
  position: absolute;
  width: 8vh;
  height: 8vh;
  z-index: 6;
  animation: vang-buit .65s ease-in forwards
}

.vang-buit img {
  width: 100%;
  height: 100%;
  object-fit: contain
}

@keyframes vang-buit {
  to {
    transform: translate(var(--vang-x), var(--vang-y)) scale(.5) rotate(180deg);
    opacity: 0
  }
}

.typespel-overlay>section {
  pointer-events: auto
}

.is-gepauzeerd .typespel-overlay {
  backdrop-filter: blur(1vh)
}

.resultaat-moment:has(.cadeau) .cadeau {
  position: absolute;
  bottom: -3vh;
  left: calc(50% - 17vh);
  margin: 0
}

.resultaat-moment:has(.cadeau)>h2 {
  position: absolute;
  top: 0
}

.resultaat-moment:has(.cadeau)>p {
  position: absolute;
  top: 9vh
}

.resultaat-moment:has(.cadeau)>p+p {
  top: 14vh
}

/* Grondvoorwerpen passen rechts van de handen en binnen de speelstukzone.
   Het dashboard gebruikt 52vw, zodat ook tijdens nieuw de pot zichtbaar blijft. */
.automaat {
  left: 76vw;
  bottom: var(--zone-grond);
  width: 5vw;
  height: 19vh;
}

.snoeppot {
  left: 82vw;
  right: auto;
  bottom: var(--zone-grond);
  width: 2vw;
  height: 13vh;
}

.automaat-snoep {
  left: 79vw;
  bottom: 17vh;
}

@keyframes pot-vlucht {
  45% {
    transform: translate(1.5vw, -10vh) rotate(90deg);
  }

  to {
    transform: translate(3vw, 0) rotate(180deg);
    opacity: 0;
  }
}

.toneel[data-soort=drill] .speler .poppetje,
.toneel[data-soort=baas] .speler .poppetje {
  left: var(--zone-pop-links);
  bottom: var(--zone-grond);
  height: var(--zone-pop-hoogte);
  clip-path: none;
}

.huppel-rij {
  left: 3vw;
  top: 87vh;
  width: 14vw;
  overflow: hidden;
}

.baas-raket {
  left: 68vw;
  bottom: 9vh;
  width: 22vh;
  height: 14vh;
}

.tempo-wolk {
  bottom: 22vh;
}

.schimraket {
  bottom: 30vh;
}

.race-finish {
  left: 72vw;
  right: auto;
  bottom: var(--zone-grond);
  height: 23vh;
}

.toneel[data-soort=baas] .woord.straks {
  transform: translateX(calc(-50% + 30vw)) translateY(3vh) scale(.42);
}

.kauwgombaasje {
  left: 68vw;
  right: auto;
  top: auto;
  bottom: 10vh;
  width: 22vh;
  height: 22vh;
}

.baas-bellen {
  left: 67vw;
  right: auto;
  top: auto;
  bottom: 8vh;
  width: 60vh;
  height: 40vh;
  transform: scale(.48);
  transform-origin: left bottom;
}

.baas-teller {
  left: 67vw;
  right: auto;
  top: auto;
  bottom: 6vh;
  width: 16ch;
  font-variant-numeric: tabular-nums;
}

.flits-pak {
  left: 73vw;
  top: auto;
  bottom: var(--zone-grond);
  width: 24vh;
  height: 16vh;
}

.ster-slinger {
  top: 47vh;
  left: 48vw;
  right: 16vw;
  height: 10vh;
}

.typespel-scherm,
.spel-scherm,
.oefenbaan-scherm {
  --typ: 'Baloo 2', system-ui, sans-serif !important;
  --typgewicht: 800 !important;
}

.typespel-teller {
  width: 22ch;
  min-width: 22ch;
  display: flex;
  justify-content: flex-end;
  gap: 1vw;
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.typespel-reeks {
  min-width: 12ch;
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.regen-snoep {
  top: 0;
}

/* De eerste sterren hebben meteen een vaste plek. Alleen hun vulling en schaal veranderen. */
.resultaat-titel { top: 7vh; font-size: 6.5vh; animation: titel-landt .3s ease-out; }
@keyframes titel-landt { from { transform: translateY(-4vh); } }
.resultaat-zin { position: absolute; top: 17vh; left: 16vw; right: 16vw; text-align: center; font-size: 3vh; }
.resultaat-pop .poppetje { left: 6vw; bottom: 8vh; height: 40vh; width: min(24vw, 36vh); }
.resultaat-sterren {
  position: absolute; left: 20vw; right: 20vw; top: 23vh; height: 14vh;
  display: flex; justify-content: center;
}
.ster-plek {
  display: block;
  width: 13vh;
  height: 13vh;
  fill: currentColor;
  stroke: var(--inkt);
  stroke-width: 4;
  stroke-linejoin: round;
}
.resultaat-sterren .geplofd { animation: resultaat-plof .28s ease-out; }
@keyframes resultaat-plof { 40% { transform: scale(1.2); } }
.resultaat-getallen {
  position: absolute; left: 23vw; right: 23vw; top: 39vh; bottom: auto;
  height: 13vh; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1vw; text-align: center;
}
.resultaat-getallen p { max-width: none; gap: 0; }
.resultaat-getallen strong { font-size: 7vh; line-height: 1.18; font-variant-numeric: tabular-nums; }
.resultaat-getallen span { font-size: 2.4vh; }
.resultaat-getallen .opdracht-klaar { grid-column: 1 / -1; font-size: 2.2vh; }
.resultaat-moment { inset: 55vh 23vw 17vh; font-size: 2.7vh; }
.resultaat-moment:has(.cadeau) { inset: 58vh 6vw 9vh 62vw; }
.resultaat-moment:has(.cadeau) .cadeau { width: 25vh; height: 22vh; bottom: 0; left: calc(50% - 12.5vh); }
.resultaat-moment:has(.cadeau)>h2 { top: 0; font-size: 3.2vh; }
.resultaat-versneld :is(.ster-plek, .cadeau.dicht) { animation: none; }
.resultaat-moment .cadeau-vriend {
  width: 16vh !important;
  height: 16vh !important;
  left: 3vh !important;
  top: 0;
  animation: vriend-cadeau .6s var(--veer), zweef 2s .6s ease-in-out infinite alternate;
}

.resultaat-moment>.medaille {
  height: 15vh;
}

.resultaat-moment>h2 {
  font-size: 3vh;
}

.resultaat-acties {
  bottom: 6vh;
}

.resultaat-keuzes {
  position: absolute;
  left: 23vw;
  right: 10vw;
  top: 57vh;
  text-align: center;
}

.resultaat-keuzes h2 {
  font-size: 3.6vh;
  margin-bottom: 2vh;
}

.spelkeuzes {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 3vw;
}

.spelkeuze {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1vh;
  background: none;
  padding: 0;
  font-size: 2.5vh;
}

.spelkeuze .dok-rond {
  width: 10vh;
  height: 10vh;
}

.spelkeuze .dok-rond .spel-beeld {
  height: 8vh;
  width: 8vh;
}

.spelkeuzes.alle-spellen {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr)) auto;
  gap: 1vh 1vw;
}

.alle-spellen .spelkeuze {
  font-size: min(2.2vh, 1.7vw);
}

.alle-spellen .dok-rond {
  width: 7vh;
  height: 7vh;
}

.alle-spellen #naar-kaart {
  grid-column: 5;
  grid-row: 1 / span 2;
}

.resultaat-tank .tank {
  top: auto;
  bottom: 3vh;
  left: 28vw;
  right: 20vw;
  font-size: 1.9vh;
  height: auto;
}

.resultaat-tank .tank p { margin: 0; line-height: 1.3; }
.resultaat-tank .tank .snoepknop { height: 4.8vh; font-size: 2.2vh; }

.resultaat-toneel:not(:has(.resultaat-keuzes:not([hidden]))) .resultaat-tank {
  display: none;
}

/* Race: één piloot en raket, onder de vaste tekstzone. */
.race-schip {
  position: absolute;
  left: 26vw;
  bottom: 24vh;
  width: 26vh;
  height: 17vh;
  z-index: 2;
  transition: transform .2s linear;
}

.race-schip .speler .poppetje {
  left: 8vh;
  bottom: 7vh;
  width: 13vh;
  height: 20vh;
  clip-path: inset(0 0 35% 0);
}

.race-schip > .spel-beeld { z-index: 2; }

.toneel[data-soort=race] > .praat {
  left: 3vw;
  top: var(--zone-praat-top);
  bottom: auto;
  width: 27vw;
  max-width: 27vw;
}

.level-wereld .toneel[data-soort=race] #oefenvlak {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: clamp(24px, 7vh, 76px);
}

.tempometer {
  position: absolute;
  top: 19vh;
  right: 2vw;
  width: 10vw;
  height: 21vh;
  text-align: center;
}

.tempometer svg { display: block; width: 100%; height: 7vh; }
.tempometer .getal {
  display: block;
  width: 100%;
  font-size: clamp(40px, 7vh, 76px);
  line-height: 1.1;
  font-variant-numeric: tabular-nums;
}
.tempometer small { display: block; font-size: max(14px, 2vh); }
.meter-vulling { transition: stroke-dashoffset .15s; }

/* De raket deint onafhankelijk van zijn horizontale racepositie. */
.race-schip .speler {
  position: absolute;
  inset: 0;
  animation: race-deint 3.2s ease-in-out infinite;
}
@keyframes race-deint { 50% { translate: 0 -.45vh; } }
@media(prefers-reduced-motion:reduce) {
  .race-schip .speler { animation: none; }
}

.drill-pot {
  position: absolute;
  left: 69vw;
  bottom: 9vh;
  width: 12vh;
  height: 14vh;
  display: flex;
  align-content: flex-start;
  flex-flow: row wrap-reverse;
  padding: 1vh;
  border: .55vh solid #9867ac;
  border-top: .9vh solid #cf9bd3;
  border-radius: 2vh 2vh 4vh 4vh;
  background: #fff9;
}
.pot-snoep { width: calc(100% / var(--kolommen)); height: calc(100% / var(--rijen)); visibility: hidden; }
.pot-snoep.binnen { visibility: visible; animation: plop .35s ease-out; }
.groep-buit {
  position: absolute;
  left: 51vw;
  top: 43vh;
  width: 6vh;
  height: 6vh;
  --reis-x: 19vw;
  animation: groep-valt .6s ease-in forwards;
}
.groep-buit.naar-vriend { --reis-x: 39vw; }
@keyframes groep-valt { to { transform: translate(var(--reis-x), 36vh) rotate(110deg); opacity: .1; } }
.toneel[data-soort=drill] .vriend-bel { opacity: calc(.6 - .4 * var(--groep-vrij, 0)); transition: opacity .4s; }
.oefenbaan-scherm .oefenwereld .maatje .praat {
  left: 6vw; top: auto; bottom: 47vh; max-width: 28vw;
}

.scene-drill .automaat, .scene-drill .drill-vriend, .drill-raket {
  position: absolute; left: 69vw; bottom: 9vh; width: 17vh; height: 19vh;
}
.scene-drill .drill-vriend .vriend-bel { opacity: calc(1 - var(--vrij) * .8); }
.drill-raket .piloot { display: block; height: 83%; }
.raket-tank { height: 2.5vh; border-radius: 2vh; border: .4vh solid var(--inkt); background: #fff9; overflow: hidden; }
.raket-tank i { display: block; height: 100%; background: var(--mint); transform-origin: left; transform: scaleX(var(--brandstof, 0)); transition: transform .25s; }
