/* =========================================================
   Dino-ABC · Styles
   Freundliches Lernabenteuer für die 2. Klasse
   ========================================================= */

@font-face {
  font-family: 'Baloo 2';
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url('fonts/baloo2-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Baloo 2';
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url('fonts/baloo2-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Nunito';
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url('fonts/nunito-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Nunito';
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url('fonts/nunito-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  --cream: #fdf8ea;
  --paper: #fffdf6;
  --ink: #233c30;
  --ink-soft: #52665a;
  --ink-faint: #6b7a70;
  --line: rgba(35, 60, 48, 0.13);
  --line-strong: #dcd2ba;
  --green: #3f8f63;
  --green-dark: #2d6b49;
  --green-deep: #24543b;
  --green-soft: #e5f3df;
  --sun: #ffc94a;
  --sun-dark: #dda62b;
  --sun-soft: #fff4cf;
  --coral: #ef8265;
  --coral-dark: #c9563b;
  --coral-soft: #ffe8df;
  --sky: #bde6df;
  --lavender: #8b79c8;
  --shadow-card: 0 24px 50px -32px rgba(35, 60, 48, 0.55), 0 2px 0 rgba(35, 60, 48, 0.04);
  --shadow-lift: 0 32px 60px -30px rgba(35, 60, 48, 0.5);
  --radius-xl: 34px;
  --radius-lg: 26px;
  --radius-md: 18px;
  --font-display: 'Baloo 2', 'Trebuchet MS', 'Segoe UI', sans-serif;
  --font-body: 'Nunito', 'Segoe UI', Arial, sans-serif;
  --ease-pop: cubic-bezier(0.2, 1.35, 0.4, 1);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--font-body);
  font-size: 17px;
  font-weight: 600;
  line-height: 1.55;
  color: var(--ink);
  background: var(--cream);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

body.is-locked {
  overflow: hidden;
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--ink);
}

p {
  margin: 0 0 1em;
}

img, svg {
  display: block;
  max-width: 100%;
}

a {
  color: var(--green-dark);
}

a,
button {
  touch-action: manipulation;
}

.btn,
.icon-btn,
.ghost-btn,
.answer-btn,
.sort-letter,
.word-card,
.pair-card,
.switch {
  -webkit-user-select: none;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
}

button {
  font: inherit;
  color: inherit;
}

:focus-visible {
  outline: 3px solid #2b6ca3;
  outline-offset: 3px;
  border-radius: 8px;
}

::selection {
  background: #ffe08a;
  color: var(--ink);
}

.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;
}

.skip-link {
  position: fixed;
  top: 10px;
  left: 10px;
  z-index: 999;
  padding: 10px 16px;
  border-radius: 10px;
  background: var(--ink);
  color: #fff;
  font-weight: 800;
  transform: translateY(-160%);
  transition: transform 0.2s;
}
.skip-link:focus {
  transform: translateY(0);
}

[hidden] {
  display: none !important;
}

.task-answers.is-locked .answer-btn:not(.is-correct),
.task-answers.is-locked .word-card:not(.is-correct) {
  opacity: 0.52;
}
.task-answers.is-locked .answer-btn.is-ok,
.task-answers.is-locked .answer-btn.is-correct {
  opacity: 1;
}
.answer-btn[disabled],
.word-card[disabled],
.sort-letter[disabled],
.pair-card[disabled] {
  cursor: default;
  transform: none;
}
.answer-btn.is-correct[disabled],
.word-card.is-correct[disabled] {
  opacity: 1;
}
.order-area.is-locked .sort-pool,
.order-area.is-locked .order-tools {
  pointer-events: none;
}
.order-slots.is-wrong {
  animation: shake 0.42s ease;
}
.order-slot.is-ok {
  border-color: var(--green);
  background: #eaf7e4;
  color: var(--green-deep);
}

.sprite {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

.icon {
  width: 1.15em;
  height: 1.15em;
  flex: 0 0 auto;
  display: inline-block;
  vertical-align: -0.16em;
}

/* ---------- Hintergrund ---------- */

.world {
  position: fixed;
  inset: 0;
  z-index: -1;
  overflow: hidden;
  pointer-events: none;
  background:
    radial-gradient(120% 80% at 78% 0%, rgba(255, 224, 141, 0.65) 0%, rgba(255, 224, 141, 0) 55%),
    linear-gradient(180deg, #fff3d3 0%, #fdf8ea 42%, #edf6e2 72%, #dcefd2 100%);
}

.world::after {
  content: '';
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(35, 60, 48, 0.06) 1px, transparent 1px);
  background-size: 26px 26px;
  opacity: 0.35;
  mask-image: linear-gradient(180deg, transparent 0%, #000 35%, #000 100%);
}

.world__sun {
  position: absolute;
  top: 42px;
  right: 7vw;
  width: clamp(180px, 22vw, 310px);
  aspect-ratio: 1;
  border-radius: 50%;
  background: radial-gradient(circle, #fff1b8 0%, #ffd978 42%, rgba(255, 217, 120, 0) 71%);
  opacity: 0.9;
  animation: breathe 13s ease-in-out infinite;
}

.cloud {
  position: absolute;
  height: 52px;
  width: 170px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.68);
  filter: blur(1px);
  opacity: 0.8;
}
.cloud::before,
.cloud::after {
  content: '';
  position: absolute;
  border-radius: 50%;
  background: inherit;
}
.cloud::before {
  width: 74px;
  height: 74px;
  left: 24px;
  bottom: 8px;
}
.cloud::after {
  width: 96px;
  height: 96px;
  right: 22px;
  bottom: 4px;
}
.cloud--one {
  top: 150px;
  left: -30px;
  transform: scale(0.8);
  animation: drift 44s ease-in-out infinite alternate;
}
.cloud--two {
  top: 76px;
  left: 42%;
  transform: scale(0.55);
  opacity: 0.55;
  animation: drift 56s ease-in-out -12s infinite alternate-reverse;
}
.cloud--three {
  top: 290px;
  right: 28%;
  transform: scale(0.42);
  opacity: 0.45;
  animation: drift 64s ease-in-out -20s infinite alternate;
}

.world__hills {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  width: 100%;
  height: min(52vh, 520px);
}

.world__fern {
  position: absolute;
  bottom: -60px;
  width: 230px;
  height: 440px;
  opacity: 0.22;
  filter: blur(0.3px);
}
.world__fern--left {
  left: -38px;
  transform: rotate(-4deg);
}
.world__fern--right {
  right: -42px;
  transform: scaleX(-1) rotate(-2deg);
}

.leaf {
  position: absolute;
  width: 20px;
  height: 20px;
  color: #6ea17a;
  opacity: 0.5;
  animation: floatLeaf 16s ease-in-out infinite;
}
.leaf--one { top: 22%; left: 6%; animation-delay: -1s; }
.leaf--two { top: 58%; left: 92%; width: 15px; animation-delay: -6s; animation-duration: 19s; }
.leaf--three { top: 78%; left: 12%; width: 13px; animation-delay: -9s; animation-duration: 21s; }
.leaf--four { top: 34%; left: 84%; width: 17px; animation-delay: -13s; animation-duration: 18s; }

/* ---------- Grundbausteine ---------- */

.wrap {
  width: 100%;
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 28px;
}

#app {
  max-width: 1180px;
  margin: 0 auto;
  padding: 34px 28px 84px;
  outline: none;
}

.btn {
  --btn-bg: var(--sun);
  --btn-fg: #3f2d0c;
  --btn-edge: var(--sun-dark);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 54px;
  padding: 14px 26px;
  border: 0;
  border-radius: 999px;
  background: var(--btn-bg);
  color: var(--btn-fg);
  font-family: var(--font-display);
  font-size: 1.12rem;
  font-weight: 800;
  line-height: 1.1;
  text-decoration: none;
  cursor: pointer;
  box-shadow: 0 6px 0 var(--btn-edge), 0 16px 26px -16px rgba(35, 60, 48, 0.55);
  transition: transform 0.16s ease, box-shadow 0.16s ease, filter 0.16s ease;
  -webkit-tap-highlight-color: transparent;
}
.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 0 var(--btn-edge), 0 20px 28px -16px rgba(35, 60, 48, 0.5);
}
.btn:active {
  transform: translateY(4px);
  box-shadow: 0 2px 0 var(--btn-edge), 0 8px 14px -12px rgba(35, 60, 48, 0.5);
}
.btn .icon {
  width: 1.2em;
  height: 1.2em;
}
.btn--secondary {
  --btn-bg: var(--paper);
  --btn-fg: var(--ink);
  --btn-edge: #ddd3bd;
  border: 1.5px solid var(--line);
}
.btn--green {
  --btn-bg: var(--green);
  --btn-fg: #fffdf2;
  --btn-edge: var(--green-deep);
}
.btn--coral {
  --btn-bg: var(--coral);
  --btn-fg: #fffaf2;
  --btn-edge: #b84a30;
}
.btn--small {
  min-height: 44px;
  padding: 10px 18px;
  font-size: 0.98rem;
  box-shadow: 0 4px 0 var(--btn-edge);
}
.btn--small:hover {
  box-shadow: 0 5px 0 var(--btn-edge);
}
.btn--small:active {
  box-shadow: 0 1px 0 var(--btn-edge);
}
.btn[disabled],
.btn.is-disabled {
  cursor: not-allowed;
  filter: grayscale(0.35);
  opacity: 0.72;
  transform: none;
  box-shadow: 0 4px 0 var(--btn-edge);
}

.icon-btn {
  display: inline-grid;
  place-items: center;
  width: 46px;
  height: 46px;
  padding: 0;
  border-radius: 50%;
  border: 1.5px solid var(--line);
  background: var(--paper);
  color: var(--ink);
  cursor: pointer;
  box-shadow: 0 2px 0 rgba(35, 60, 48, 0.08);
  transition: transform 0.16s ease, background 0.16s ease;
  -webkit-tap-highlight-color: transparent;
}
.icon-btn:hover {
  background: #fff;
  transform: translateY(-1px);
}
.icon-btn:active {
  transform: translateY(1px);
}
.icon-btn .icon {
  width: 22px;
  height: 22px;
}

.ghost-btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 42px;
  padding: 8px 13px;
  border: 1.5px solid var(--line);
  border-radius: 999px;
  background: transparent;
  color: var(--ink-soft);
  font-size: 0.88rem;
  font-weight: 800;
  cursor: pointer;
  transition: background 0.16s ease, color 0.16s ease;
}
.ghost-btn:hover {
  background: #f7f1e2;
  color: var(--ink);
}
.ghost-btn .icon {
  width: 17px;
  height: 17px;
}
.ghost-btn[disabled] {
  opacity: 0.5;
  cursor: not-allowed;
  pointer-events: none;
}

.link-btn {
  padding: 0;
  border: 0;
  background: none;
  color: var(--green-dark);
  font-weight: 800;
  text-decoration: underline;
  text-underline-offset: 3px;
  cursor: pointer;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 14px;
  border: 1px solid #cfe4c3;
  border-radius: 999px;
  background: rgba(238, 247, 230, 0.85);
  color: var(--green-dark);
  font-size: 0.75rem;
  font-weight: 900;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}
.eyebrow--coral {
  background: var(--coral-soft);
  border-color: #f2c4b5;
  color: #a8472e;
}
.eyebrow--sun {
  background: var(--sun-soft);
  border-color: #eed592;
  color: #806019;
}

.section {
  margin-top: 66px;
}
.section__head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 22px;
  margin-bottom: 24px;
}
.section__head h2 {
  margin: 0;
  font-size: clamp(1.8rem, 3vw, 2.55rem);
  line-height: 1.05;
}
.section__head p {
  margin: 8px 0 0;
  max-width: 55ch;
  color: var(--ink-soft);
}

/* ---------- Topbar ---------- */

.topbar {
  position: sticky;
  top: 0;
  z-index: 60;
  background: rgba(253, 248, 234, 0.82);
  border-bottom: 1px solid rgba(35, 60, 48, 0.08);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}
.topbar__inner {
  display: flex;
  align-items: center;
  gap: 22px;
  max-width: 1180px;
  margin: 0 auto;
  padding: 12px 28px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--ink);
  text-decoration: none;
  flex: 0 0 auto;
}
.brand__mark {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border-radius: 16px;
  background: var(--green);
  color: #fff8e6;
  box-shadow: 0 4px 0 var(--green-deep), inset 0 1px 0 rgba(255, 255, 255, 0.28);
  transform: rotate(-4deg);
}
.brand__mark .icon {
  width: 25px;
  height: 25px;
  transform: rotate(4deg);
}
.brand__text {
  display: flex;
  flex-direction: column;
  gap: 1px;
  line-height: 1;
}
.brand__text strong {
  font-family: var(--font-display);
  font-size: 1.42rem;
  font-weight: 800;
  letter-spacing: -0.03em;
}
.brand__text small {
  color: var(--ink-faint);
  font-size: 0.66rem;
  font-weight: 800;
  letter-spacing: 0.11em;
  text-transform: uppercase;
}

.topnav {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-left: auto;
}
.topnav a,
.topnav button {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--ink-soft);
  font-size: 0.93rem;
  font-weight: 800;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.16s ease, color 0.16s ease;
}
.topnav a:hover,
.topnav button:hover {
  background: rgba(255, 253, 246, 0.8);
  color: var(--ink);
}
.topnav a.is-active {
  background: var(--paper);
  color: var(--ink);
  box-shadow: inset 0 0 0 1.5px var(--line), 0 2px 0 rgba(35, 60, 48, 0.04);
}
.topnav .icon {
  width: 19px;
  height: 19px;
}

.topbar__right {
  display: flex;
  align-items: center;
  gap: 9px;
}

.star-pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 44px;
  padding: 6px 15px;
  border: 1.5px solid #edd38c;
  border-radius: 999px;
  background: #fff8dd;
  color: #78580f;
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 800;
  box-shadow: 0 2px 0 rgba(221, 166, 43, 0.25);
}
.star-pill .icon {
  width: 21px;
  height: 21px;
  color: #e9ae2b;
}
.star-pill.is-pulsing {
  animation: starPulse 0.6s var(--ease-pop);
}

.mobile-nav {
  display: none;
}

/* ---------- Startseite ---------- */

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  gap: 36px;
  align-items: center;
  padding: 14px 0 32px;
  min-height: min(650px, calc(100vh - 220px));
}

.hero__copy {
  position: relative;
  z-index: 3;
}
.hero h1 {
  margin: 18px 0 18px;
  font-size: clamp(2.7rem, 5.1vw, 4.7rem);
  line-height: 0.98;
  letter-spacing: -0.045em;
  overflow-wrap: break-word;
  text-wrap: balance;
}
.hero h1 .name {
  color: var(--coral-dark);
  overflow-wrap: anywhere;
}
.hero h1 .mark {
  position: relative;
  display: inline-block;
  z-index: 0;
  color: var(--green-dark);
}
.hero h1 .mark::after {
  content: '';
  position: absolute;
  left: -3%;
  right: -3%;
  bottom: 0.07em;
  height: 0.19em;
  z-index: -1;
  border-radius: 999px;
  background: var(--sun);
  transform: rotate(-1.4deg);
}
.hero__lead {
  max-width: 48ch;
  margin: 0 0 28px;
  color: var(--ink-soft);
  font-size: 1.14rem;
  font-weight: 600;
  line-height: 1.6;
}
.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
}
.hero__note {
  display: flex;
  align-items: center;
  gap: 7px;
  margin: 16px 0 0;
  color: var(--ink-faint);
  font-size: 0.85rem;
  font-weight: 700;
}
.hero__note .icon {
  width: 17px;
  height: 17px;
  color: var(--green);
}

.hero__stats {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 34px;
}
.stat {
  display: flex;
  align-items: center;
  gap: 11px;
  min-width: 126px;
  padding: 10px 15px 10px 11px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(255, 253, 246, 0.72);
  backdrop-filter: blur(6px);
}
.stat__icon {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 12px;
  background: var(--tint, var(--green-soft));
  color: var(--tint-ink, var(--green-dark));
}
.stat__icon .icon {
  width: 21px;
  height: 21px;
}
.stat strong {
  display: block;
  font-family: var(--font-display);
  font-size: 1.18rem;
  font-weight: 800;
  line-height: 1.05;
}
.stat span {
  display: block;
  margin-top: 2px;
  color: var(--ink-faint);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.02em;
}

/* Hero-Kunst */

.hero__art {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 480px;
  isolation: isolate;
}
.hero__halo {
  position: absolute;
  width: min(100%, 480px);
  aspect-ratio: 1;
  border-radius: 50%;
  background: radial-gradient(circle at 48% 44%, rgba(255, 242, 190, 0.98) 0%, rgba(255, 233, 168, 0.55) 46%, rgba(255, 233, 168, 0) 70%);
  z-index: -2;
}
.hero__ring {
  position: absolute;
  width: min(86%, 430px);
  aspect-ratio: 1;
  border: 2px dashed rgba(63, 143, 99, 0.28);
  border-radius: 50%;
  animation: spinSlow 80s linear infinite;
  z-index: -1;
}
.hero__ring::before,
.hero__ring::after {
  content: '';
  position: absolute;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--coral);
  box-shadow: 0 0 0 5px var(--paper);
}
.hero__ring::before {
  top: 12%;
  left: 12%;
}
.hero__ring::after {
  bottom: 8%;
  right: 20%;
  background: var(--sun);
}
.hero-svg {
  position: relative;
  z-index: 2;
  width: min(104%, 500px);
  height: auto;
  filter: drop-shadow(0 28px 24px rgba(35, 60, 48, 0.16));
}

.rexi__all {
  transform-origin: 50% 100%;
  animation: rexiBob 4.8s ease-in-out infinite;
}
.rexi__tail {
  transform-box: fill-box;
  transform-origin: 100% 20%;
  animation: tailSway 4.8s ease-in-out infinite;
}
.rexi__arm {
  transform-box: fill-box;
  transform-origin: 12% 100%;
  animation: armWave 3.4s ease-in-out infinite;
}
.rexi__lid {
  transform-box: fill-box;
  transform-origin: center;
  transform: scaleY(0);
  animation: blink 6.4s infinite;
}

.float-letter {
  position: absolute;
  z-index: 3;
  display: grid;
  place-items: center;
  width: 66px;
  height: 66px;
  border-radius: 20px;
  border: 2px solid rgba(35, 60, 48, 0.12);
  background: var(--paper);
  color: var(--green-dark);
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 800;
  box-shadow: 0 6px 0 rgba(35, 60, 48, 0.08), 0 16px 24px -16px rgba(35, 60, 48, 0.35);
  animation: bobble 6s ease-in-out infinite;
}
.float-letter--a {
  top: 8%;
  left: 2%;
  transform: rotate(-9deg);
  color: var(--coral-dark);
  animation-delay: -1.2s;
}
.float-letter--b {
  top: 18%;
  right: 1%;
  transform: rotate(7deg);
  color: var(--lavender);
  animation-delay: -3.7s;
}
.float-letter--c {
  bottom: 16%;
  left: 6%;
  width: 56px;
  height: 56px;
  font-size: 1.7rem;
  transform: rotate(6deg);
  color: #b4791d;
  animation-delay: -2.4s;
}
.hero__egg {
  position: absolute;
  right: 4%;
  bottom: 7%;
  z-index: 3;
  width: 92px;
  transform: rotate(8deg);
  filter: drop-shadow(0 12px 12px rgba(35, 60, 48, 0.16));
  animation: bobble 7s ease-in-out -2s infinite;
}
.hero__egg .egg-svg {
  --egg-shell: #fff4d6;
  --egg-spot: #ef8265;
  width: 100%;
}
.hero__bubble {
  position: absolute;
  top: 2%;
  right: 9%;
  z-index: 4;
  max-width: 180px;
  padding: 12px 17px;
  border: 2px solid var(--ink);
  border-radius: 20px 20px 20px 6px;
  background: var(--paper);
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.15;
  transform: rotate(2.5deg);
  box-shadow: 0 5px 0 rgba(35, 60, 48, 0.09);
}
.hero__bubble::after {
  content: '';
  position: absolute;
  left: 16px;
  bottom: -12px;
  width: 18px;
  height: 18px;
  background: var(--paper);
  border-right: 2px solid var(--ink);
  border-bottom: 2px solid var(--ink);
  transform: skewY(32deg) rotate(10deg);
}

/* Missionen */

.mission-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}
.mission {
  position: relative;
  overflow: hidden;
  padding: 26px 24px 24px;
  border: 1.5px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--paper);
  box-shadow: var(--shadow-card);
}
.mission::after {
  content: '';
  position: absolute;
  top: -38px;
  right: -38px;
  width: 120px;
  height: 120px;
  border-radius: 50%;
  background: var(--tint, var(--green-soft));
  opacity: 0.75;
  z-index: 0;
}
.mission__icon {
  position: relative;
  z-index: 1;
  display: grid;
  place-items: center;
  width: 56px;
  height: 56px;
  border-radius: 17px;
  background: var(--tint, var(--green-soft));
  color: var(--tint-ink, var(--green-dark));
  font-family: var(--font-display);
  font-size: 1.45rem;
  font-weight: 800;
  letter-spacing: -0.06em;
}
.mission h3 {
  position: relative;
  z-index: 1;
  margin: 18px 0 7px;
  font-size: 1.38rem;
}
.mission p {
  position: relative;
  z-index: 1;
  margin: 0;
  color: var(--ink-soft);
  font-size: 0.96rem;
  line-height: 1.5;
}
.mission__chips {
  position: relative;
  z-index: 1;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 16px;
}
.mini-chip {
  display: inline-flex;
  align-items: center;
  padding: 4px 9px;
  border-radius: 8px;
  background: #f5efdf;
  color: var(--ink-soft);
  font-size: 0.76rem;
  font-weight: 800;
}
.mini-chip strong {
  margin-left: 4px;
}

/* Fakt */

.fact-strip {
  position: relative;
  display: flex;
  align-items: center;
  gap: 24px;
  margin-top: 34px;
  padding: 24px 28px;
  border: 1.5px solid #ead8a6;
  border-radius: var(--radius-lg);
  background: linear-gradient(105deg, #fff8e2 0%, #f4f9e9 100%);
  overflow: hidden;
}
.fact-strip__egg {
  flex: 0 0 auto;
  width: 66px;
  transform: rotate(-6deg);
}
.fact-strip__egg .egg-svg {
  --egg-shell: #fff6dc;
  --egg-spot: #e3a33c;
  width: 100%;
}
.fact-strip__copy {
  flex: 1;
}
.fact-strip__label {
  display: block;
  margin-bottom: 3px;
  color: #8a6113;
  font-size: 0.73rem;
  font-weight: 900;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.fact-strip p {
  margin: 0;
  font-size: 1.02rem;
  font-weight: 700;
  line-height: 1.5;
}
.fact-strip__dino {
  flex: 0 0 auto;
  width: 118px;
  opacity: 0.95;
}
.fact-strip__dino .dino-svg {
  width: 100%;
  height: auto;
}
.fact-strip__dino--rexi {
  width: 92px;
  transform: rotate(-3deg);
  opacity: 0.95;
}
.fact-strip__dino--rexi .rexi-head-svg {
  width: 100%;
  height: auto;
}

/* ---------- Unterseiten-Kopf ---------- */

.page-head {
  max-width: 760px;
  padding: 16px 0 26px;
}
.page-head h1 {
  margin: 14px 0 12px;
  font-size: clamp(2.2rem, 4.6vw, 3.9rem);
  line-height: 1;
  letter-spacing: -0.04em;
}
.page-head p {
  max-width: 60ch;
  margin: 0;
  color: var(--ink-soft);
  font-size: 1.08rem;
  line-height: 1.6;
}

/* ---------- Reise / Karte ---------- */

.map-progress {
  display: flex;
  align-items: center;
  gap: 20px;
  max-width: 900px;
  margin: 6px 0 42px;
  padding: 17px 22px;
  border: 1.5px solid var(--line);
  border-radius: 22px;
  background: rgba(255, 253, 246, 0.8);
}
.map-progress__text {
  flex: 0 0 auto;
  font-size: 0.92rem;
  font-weight: 800;
  color: var(--ink-soft);
}
.map-progress__text strong {
  color: var(--ink);
}
.progress-track {
  flex: 1;
  height: 11px;
  min-width: 120px;
  border-radius: 999px;
  background: #ece5d2;
  overflow: hidden;
  box-shadow: inset 0 1px 2px rgba(35, 60, 48, 0.1);
}
.progress-track span {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--green), #86c66d);
  transition: width 0.7s var(--ease-pop);
}
.map-progress__stars {
  display: flex;
  align-items: center;
  gap: 6px;
  flex: 0 0 auto;
  color: #8a6a1a;
  font-size: 0.92rem;
  font-weight: 900;
}
.map-progress__stars .icon {
  width: 19px;
  height: 19px;
  color: #e9ae2b;
}

.trail {
  position: relative;
  max-width: 940px;
  margin: 0 auto;
  padding-left: 104px;
}
.trail::before {
  content: '';
  position: absolute;
  left: 42px;
  top: 50px;
  bottom: 70px;
  width: 0;
  border-left: 3px dashed rgba(63, 143, 99, 0.32);
}
.trail__row {
  position: relative;
  margin-bottom: 26px;
}
.trail__row:last-child {
  margin-bottom: 0;
}
.trail__marker {
  position: absolute;
  top: 22px;
  left: -104px;
  z-index: 2;
  display: grid;
  place-items: center;
  width: 84px;
  height: 84px;
  border: 3px solid var(--line);
  border-radius: 50%;
  background: var(--paper);
  color: var(--ink-soft);
  font-family: var(--font-display);
  font-size: 1.7rem;
  font-weight: 800;
  box-shadow: 0 6px 0 rgba(35, 60, 48, 0.07);
}
.trail__marker > span {
  line-height: 1;
}
.trail__marker .icon {
  width: 30px;
  height: 30px;
}
.trail__marker.is-done {
  border-color: var(--green-dark);
  background: var(--green);
  color: #fff9e8;
}
.trail__marker.is-current {
  border-color: #e1ae35;
  background: var(--sun);
  color: #4a3508;
  animation: markerPulse 2.6s ease-in-out infinite;
}
.trail__marker.is-locked {
  border-color: #d9d1bd;
  background: #f3eddd;
  color: #a49a82;
}
.trail__marker.is-locked .icon {
  width: 25px;
  height: 25px;
}

.level-card {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 192px;
  gap: 22px;
  overflow: hidden;
  padding: 26px 26px 24px 30px;
  border: 1.5px solid var(--line);
  border-radius: var(--radius-xl);
  background: var(--paper);
  box-shadow: var(--shadow-card);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.level-card::before {
  content: '';
  position: absolute;
  inset: 0 auto 0 0;
  width: 9px;
  background: var(--accent, var(--green));
}
.level-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lift);
}
.level-card.is-locked {
  box-shadow: 0 20px 40px -34px rgba(35, 60, 48, 0.4);
}
.level-card.is-locked:hover {
  transform: none;
}
.level-card__body {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  min-width: 0;
}
.level-card__meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  width: 100%;
}
.level-card__num {
  display: inline-flex;
  align-items: center;
  padding: 5px 11px;
  border-radius: 8px;
  background: var(--soft, var(--green-soft));
  color: var(--ink-soft);
  color: color-mix(in srgb, var(--accent, var(--green)) 52%, var(--ink) 48%);
  font-size: 0.71rem;
  font-weight: 900;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}
.level-card__done {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 9px;
  border-radius: 8px;
  background: #edf7e7;
  color: var(--green-dark);
  font-size: 0.71rem;
  font-weight: 900;
  letter-spacing: 0.03em;
}
.level-card__done .icon {
  width: 13px;
  height: 13px;
}
.level-card h2 {
  margin: 10px 0 7px;
  font-size: clamp(1.55rem, 2.4vw, 1.95rem);
  line-height: 1.05;
}
.level-card p {
  margin: 0 0 15px;
  max-width: 54ch;
  color: var(--ink-soft);
  font-size: 0.95rem;
  line-height: 1.5;
}
.level-card__footer {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
  margin-top: auto;
  width: 100%;
}
.level-card__info {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--ink-faint);
  font-size: 0.8rem;
  font-weight: 800;
}
.level-card__info span {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}
.level-card__info .icon {
  width: 15px;
  height: 15px;
}
.level-card__cta {
  margin-left: auto;
}
.stars {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  color: #ded5c0;
}
.stars .icon {
  width: 19px;
  height: 19px;
}
.stars .is-on {
  color: #f0b429;
}
.stars--lg .icon {
  width: 30px;
  height: 30px;
}

.level-card__art {
  position: relative;
  display: grid;
  place-items: center;
  align-self: stretch;
  min-height: 176px;
  border-radius: 24px;
  background: var(--soft, var(--green-soft));
  overflow: hidden;
}
.level-card__art::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(255, 255, 255, 0.75) 2px, transparent 2px);
  background-size: 18px 18px;
  opacity: 0.5;
}
.level-card__art .egg-svg {
  position: relative;
  z-index: 1;
  width: 102px;
  filter: drop-shadow(0 12px 12px rgba(35, 60, 48, 0.14));
  animation: bobble 6s ease-in-out infinite;
}
.level-card__art .dino-svg {
  position: relative;
  z-index: 1;
  width: 178px;
  height: auto;
  filter: drop-shadow(0 10px 12px rgba(35, 60, 48, 0.12));
}
.level-card__lock {
  position: absolute;
  left: 50%;
  bottom: 10px;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(255, 253, 246, 0.92);
  color: #6b5e48;
  font-size: 0.68rem;
  font-weight: 900;
  transform: translateX(-50%);
  white-space: nowrap;
}
.level-card__lock .icon {
  width: 12px;
  height: 12px;
}

.trail__end {
  position: relative;
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 38px 0 0 0;
  padding: 20px 24px;
  border: 1.5px dashed #d8cfb8;
  border-radius: 22px;
  background: rgba(255, 253, 246, 0.6);
  color: var(--ink-soft);
  font-size: 0.92rem;
  font-weight: 700;
}
.trail__end .icon {
  width: 26px;
  height: 26px;
  color: var(--coral);
}

/* ---------- Spiel ---------- */

.game {
  max-width: 900px;
  margin: 0 auto;
  padding-top: 8px;
}
.game__bar {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 20px;
}
.game__progress {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 14px;
}
.game__steps {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}
.step {
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  border: 2px solid #ddd4bf;
  border-radius: 50%;
  background: var(--paper);
  color: transparent;
  transition: transform 0.25s var(--ease-pop), background 0.2s, border-color 0.2s;
}
.step::after {
  content: '';
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #d7cdb6;
}
.step.is-done {
  border-color: var(--green);
  background: var(--green);
}
.step.is-done::after {
  background: #fff6dc;
}
.step.is-now {
  border-color: #e8b23b;
  background: var(--sun-soft);
  transform: scale(1.28);
}
.step.is-now::after {
  background: var(--sun-dark);
  animation: dotPulse 1.6s ease-in-out infinite;
}
.game__count {
  flex: 0 0 auto;
  color: var(--ink-faint);
  font-size: 0.8rem;
  font-weight: 900;
  letter-spacing: 0.02em;
}

.task-card {
  position: relative;
  overflow: hidden;
  padding: clamp(22px, 4vw, 40px);
  border: 1.5px solid var(--line);
  border-radius: var(--radius-xl);
  background: var(--paper);
  box-shadow: var(--shadow-lift);
}
.task-card::before {
  content: '';
  position: absolute;
  top: -80px;
  right: -70px;
  width: 230px;
  height: 230px;
  border-radius: 50%;
  background: var(--task-tint, var(--green-soft));
  opacity: 0.55;
  pointer-events: none;
}
.task-card__top {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 10px;
}
.chip {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 7px 13px;
  border-radius: 999px;
  background: var(--task-tint, var(--green-soft));
  color: var(--ink-soft);
  color: color-mix(in srgb, var(--task-ink, var(--green-dark)) 55%, var(--ink) 45%);
  font-size: 0.71rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.task-card__tools {
  display: flex;
  align-items: center;
  gap: 8px;
}
.task-card h1 {
  position: relative;
  z-index: 1;
  max-width: 26ch;
  margin: 0 0 6px;
  font-size: clamp(1.6rem, 3.5vw, 2.45rem);
  line-height: 1.08;
}
.task-title:focus {
  outline: none;
}
.task-title:focus-visible {
  outline: none;
}
.task-instruction {
  position: relative;
  z-index: 1;
  max-width: 58ch;
  margin: 0 0 22px;
  color: var(--ink-soft);
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.5;
}
.task-visual {
  position: relative;
  z-index: 1;
  margin: 4px 0 26px;
}
.task-answers {
  position: relative;
  z-index: 1;
}
.task-feedback {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 66px;
  margin-top: 22px;
  padding: 10px 14px 10px 10px;
  border: 1px solid transparent;
  border-radius: 20px;
  background: #f8f3e6;
  color: var(--ink-soft);
  font-size: 0.95rem;
  font-weight: 700;
  line-height: 1.4;
}
.task-feedback__rexi {
  flex: 0 0 auto;
  width: 50px;
}
.task-feedback__rexi svg {
  width: 100%;
  height: auto;
}
.task-feedback__text {
  flex: 1;
  min-width: 0;
}
.task-feedback__text strong {
  display: block;
  margin-bottom: 1px;
  font-family: var(--font-display);
  font-size: 1.02rem;
  font-weight: 800;
}
.task-feedback.is-good {
  background: #eaf7e4;
  border-color: #cce8bd;
  color: #286039;
}
.task-feedback.is-oops {
  background: #fff0e8;
  border-color: #f5cbbd;
  color: #a0452b;
}
.task-feedback.is-help {
  background: #f2eefb;
  border-color: #ddd3f2;
  color: #574580;
}
.feedback-icon {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  flex: 0 0 auto;
  border-radius: 14px;
  background: #fffdf5;
  color: var(--green-dark);
}
.feedback-icon .icon {
  width: 24px;
  height: 24px;
}
.task-feedback.is-oops .feedback-icon {
  color: var(--coral-dark);
}
.task-feedback.is-help .feedback-icon {
  color: var(--lavender);
}
.feedback-actions {
  margin-left: auto;
  flex: 0 0 auto;
}
.feedback-actions .btn {
  min-height: 42px;
  padding: 8px 16px;
  font-size: 0.92rem;
}

/* Aufgaben-Visualisierungen */

.letter-row {
  display: flex;
  justify-content: center;
  align-items: stretch;
  gap: clamp(7px, 1.6vw, 13px);
  flex-wrap: wrap;
}
.letter-tile {
  position: relative;
  display: grid;
  place-items: center;
  width: clamp(58px, 9vw, 86px);
  aspect-ratio: 0.86;
  border: 2.5px solid #e0d6c0;
  border-radius: 18px;
  background: #fffcf1;
  color: var(--ink);
  font-family: var(--font-display);
  font-size: clamp(2rem, 5vw, 3.3rem);
  font-weight: 800;
  line-height: 1;
  box-shadow: 0 5px 0 #e9e0cc;
}
.letter-tile.is-blank {
  border: 2.5px dashed #cbbfa4;
  background: #f7f1e2;
  color: #b8ab90;
  box-shadow: none;
}
.letter-tile.is-blank span {
  animation: blankPulse 2s ease-in-out infinite;
}
.letter-tile.is-revealed {
  border-color: var(--green);
  background: #eaf7e4;
  color: var(--green-dark);
  animation: popIn 0.35s var(--ease-pop);
}
.dm-number {
  position: absolute;
  top: 5px;
  left: 8px;
  font-family: var(--font-body);
  font-size: 0.58rem;
  font-weight: 900;
  color: #a89a7f;
  animation: none !important;
}
.letter-tile.is-blank.is-filled {
  border-style: solid;
  border-color: var(--green-dark);
  background: #eaf7e4;
  color: var(--green-deep);
  box-shadow: 0 5px 0 rgba(63, 143, 99, 0.18);
}
.letter-tile.is-blank.is-filled span {
  animation: none;
}
.letter-tile.is-blank.is-filled .dm-number {
  color: var(--green-dark);
}
.letter-tile.is-ok {
  border-color: var(--green-dark);
  background: #dff3d5;
  color: var(--green-deep);
}
.letter-tile.is-wrong {
  border-color: var(--coral);
  background: var(--coral-soft);
  color: #963d24;
  animation: shake 0.42s ease;
}

.beforeafter {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(10px, 2.4vw, 26px);
}
.letter-orb {
  display: grid;
  place-items: center;
  width: clamp(110px, 18vw, 158px);
  aspect-ratio: 1;
  border: 4px solid var(--green);
  border-radius: 50%;
  background: radial-gradient(circle at 35% 28%, #fffdf4 0%, #f7edcc 65%, #f0e2b6 100%);
  color: var(--green-deep);
  font-family: var(--font-display);
  font-size: clamp(3.6rem, 8vw, 5.4rem);
  font-weight: 800;
  line-height: 1;
  box-shadow: 0 10px 0 rgba(63, 143, 99, 0.15), inset 0 -8px 18px rgba(154, 120, 52, 0.08);
}
.direction-bubble {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  color: var(--ink-faint);
  font-size: 0.78rem;
  font-weight: 900;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.direction-bubble__icon {
  display: grid;
  place-items: center;
  width: 66px;
  height: 66px;
  border: 2px dashed #cfc4ab;
  border-radius: 50%;
  background: var(--paper);
  color: var(--coral-dark);
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 800;
  line-height: 1;
}

.order-area {
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.order-tools {
  display: flex;
  justify-content: center;
}
.order-slots {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
}
.order-slot {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-width: 54px;
  height: 54px;
  padding: 0 10px;
  border: 2px dashed #d5cab3;
  border-radius: 15px;
  background: rgba(248, 243, 230, 0.55);
  color: #b5a88e;
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 800;
}
.order-slot::before {
  content: attr(data-number);
  font-family: var(--font-body);
  font-size: 0.65rem;
  font-weight: 900;
  opacity: 0.65;
}
.order-slot.is-filled {
  border-style: solid;
  border-color: var(--green);
  background: #edf8e7;
  color: var(--green-deep);
  font-size: 1.55rem;
  animation: popIn 0.25s var(--ease-pop);
}
.order-slot.is-filled.word-slot {
  max-width: 100%;
  font-family: var(--font-display);
  font-size: 1.05rem;
  gap: 5px;
}
.order-slot.word-slot > span:last-child {
  overflow-wrap: anywhere;
}
.order-slots {
  max-width: 100%;
}
.order-slot .slot-emoji {
  font-size: 1.15rem;
  line-height: 1;
}
.sort-pool {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
}
.sort-letter {
  display: grid;
  place-items: center;
  width: clamp(62px, 9vw, 82px);
  aspect-ratio: 0.92;
  border: 2.5px solid #ded4bd;
  border-radius: 20px;
  background: #fffcf2;
  color: var(--ink);
  font-family: var(--font-display);
  font-size: clamp(2rem, 4.4vw, 2.8rem);
  font-weight: 800;
  cursor: pointer;
  box-shadow: 0 5px 0 #e8dfca;
  transition: transform 0.15s ease, opacity 0.15s ease, background 0.15s ease;
  -webkit-tap-highlight-color: transparent;
}
.sort-letter:hover {
  transform: translateY(-2px);
}
.sort-letter:active {
  transform: translateY(3px);
  box-shadow: 0 1px 0 #e8dfca;
}
.sort-letter.is-picked {
  opacity: 0.28;
  pointer-events: none;
  transform: scale(0.94);
}
.sort-letter.is-wrong {
  border-color: var(--coral);
  background: var(--coral-soft);
  animation: shake 0.42s ease;
}
.sort-letter.is-ok {
  border-color: var(--green);
  background: #eaf7e4;
  color: var(--green-deep);
}

.word-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  max-width: 660px;
  margin: 0 auto;
}
.word-card {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  min-width: 0;
  min-height: 76px;
  padding: 12px 16px;
  border: 2.5px solid #ded4bd;
  border-radius: 20px;
  background: #fffcf2;
  color: var(--ink);
  text-align: left;
  cursor: pointer;
  box-shadow: 0 5px 0 #e8dfca;
  transition: transform 0.15s ease, opacity 0.15s ease, border-color 0.15s ease, background 0.15s ease;
  -webkit-tap-highlight-color: transparent;
}
.word-card:hover {
  transform: translateY(-2px);
}
.word-card:active {
  transform: translateY(3px);
  box-shadow: 0 1px 0 #e8dfca;
}
.word-card__emoji {
  flex: 0 0 auto;
  font-size: 1.75rem;
  line-height: 1;
}
.word-card__word {
  min-width: 0;
  font-family: var(--font-display);
  font-size: clamp(1.15rem, 2.6vw, 1.45rem);
  font-weight: 700;
  letter-spacing: -0.01em;
  overflow-wrap: anywhere;
}
.word-card__word .focus {
  color: var(--coral-dark);
  text-decoration: underline;
  text-decoration-color: rgba(239, 130, 101, 0.5);
  text-underline-offset: 3px;
}
.word-card__badge {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  margin-left: auto;
  flex: 0 0 auto;
  border-radius: 50%;
  background: var(--green);
  color: #fff8e7;
  font-family: var(--font-display);
  font-size: 0.95rem;
  font-weight: 800;
  opacity: 0;
  transform: scale(0.6);
  transition: opacity 0.15s, transform 0.2s var(--ease-pop);
}
.word-card.is-picked {
  opacity: 0.42;
  pointer-events: none;
  transform: scale(0.98);
}
.word-card.is-picked .word-card__badge {
  opacity: 1;
  transform: scale(1);
}
.word-card.is-wrong {
  border-color: var(--coral);
  background: var(--coral-soft);
  animation: shake 0.42s ease;
}
.word-card.is-ok,
.word-card.is-correct {
  border-color: var(--green);
  background: #eaf7e4;
}
.word-card.is-correct {
  color: var(--green-deep);
}

.word-choice-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}
.word-choice-grid .word-card {
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 132px;
  padding: 16px 10px;
  text-align: center;
}
.word-choice-grid .word-card__emoji {
  font-size: 2.5rem;
}
.word-choice-grid .word-card__word {
  font-size: 1.1rem;
}

.choice-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
}
.answer-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-width: 84px;
  min-height: 92px;
  padding: 12px 20px;
  border: 2.5px solid #ded4bd;
  border-radius: 22px;
  background: #fffcf2;
  color: var(--ink);
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 6px 0 #e8dfca;
  transition: transform 0.15s ease, background 0.15s ease, border-color 0.15s ease;
  -webkit-tap-highlight-color: transparent;
}
.answer-btn:hover {
  transform: translateY(-2px);
  border-color: #cbbfa6;
}
.answer-btn:active {
  transform: translateY(4px);
  box-shadow: 0 2px 0 #e8dfca;
}
.answer-btn--letter {
  min-width: clamp(86px, 16vw, 112px);
  min-height: clamp(96px, 17vw, 116px);
  font-size: clamp(2.6rem, 6vw, 3.6rem);
  font-weight: 800;
  padding: 8px;
}
.answer-btn--number {
  min-width: 100px;
  font-size: 2rem;
  font-weight: 800;
}
.answer-btn.is-correct {
  border-color: var(--green-dark);
  background: #dff3d5;
  color: var(--green-deep);
  animation: correctPop 0.4s var(--ease-pop);
}
.answer-btn.is-wrong {
  border-color: var(--coral);
  background: var(--coral-soft);
  color: #963d24;
  animation: shake 0.42s ease;
}
.answer-btn.is-picked {
  opacity: 0.32;
  box-shadow: none;
  transform: scale(0.94);
  pointer-events: none;
}
.answer-btn.is-ok {
  opacity: 1;
  transform: none;
  border-color: var(--green-dark);
  background: #dff3d5;
  color: var(--green-deep);
  box-shadow: 0 6px 0 rgba(63, 143, 99, 0.2);
  pointer-events: none;
}
.answer-btn[disabled] {
  cursor: default;
}

.initial-visual {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}
.emoji-bubble {
  position: relative;
  display: grid;
  place-items: center;
  width: clamp(136px, 22vw, 176px);
  aspect-ratio: 1;
  border: 3px dashed #d6c9a8;
  border-radius: 50%;
  background: radial-gradient(circle at 40% 35%, #fffdf2 0%, #fbf0d0 100%);
  font-size: clamp(4.2rem, 10vw, 6.2rem);
  line-height: 1;
  box-shadow: 0 10px 0 rgba(35, 60, 48, 0.05);
}
.emoji-bubble::before {
  content: '';
  position: absolute;
  inset: 11px;
  border: 1px solid rgba(35, 60, 48, 0.08);
  border-radius: 50%;
}
.initial-word {
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 3.6vw, 2.1rem);
  font-weight: 800;
  letter-spacing: -0.01em;
}
.initial-word small {
  display: block;
  margin-top: 2px;
  color: var(--ink-faint);
  font-family: var(--font-body);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.big-letter-visual {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}
.big-letter {
  display: grid;
  place-items: center;
  width: clamp(110px, 18vw, 150px);
  aspect-ratio: 1;
  border: 4px solid var(--accent, var(--green));
  border-radius: 34% 66% 62% 38% / 45% 38% 62% 55%;
  background: var(--soft, var(--green-soft));
  color: var(--ink);
  font-family: var(--font-display);
  font-size: clamp(3.4rem, 8vw, 5rem);
  font-weight: 800;
  line-height: 1;
  transform: rotate(-3deg);
  box-shadow: 0 9px 0 rgba(35, 60, 48, 0.06);
}
.big-letter-caption {
  color: var(--ink-faint);
  font-size: 0.76rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.pair-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  max-width: 620px;
  margin: 0 auto;
}
.pair-card {
  position: relative;
  display: grid;
  place-items: center;
  aspect-ratio: 1;
  border: 2.5px solid #ded4bd;
  border-radius: 18px;
  background: #fffcf2;
  color: var(--ink);
  font-family: var(--font-display);
  font-size: clamp(1.9rem, 4.4vw, 2.8rem);
  font-weight: 800;
  cursor: pointer;
  box-shadow: 0 5px 0 #e8dfca;
  transition: transform 0.15s ease, background 0.15s ease, border-color 0.15s ease;
  -webkit-tap-highlight-color: transparent;
}
.pair-card[data-kind='upper'] {
  background: #eef8e8;
  border-color: #c9e2bd;
}
.pair-card[data-kind='lower'] {
  background: #fff2e9;
  border-color: #f2cdbd;
}
.pair-card:hover {
  transform: translateY(-2px);
}
.pair-card.is-selected {
  border-color: var(--ink);
  box-shadow: 0 0 0 3px rgba(35, 60, 48, 0.15), 0 5px 0 #e8dfca;
  transform: translateY(-3px) scale(1.02);
}
.pair-card.is-matched {
  opacity: 0.55;
  pointer-events: none;
  border-color: var(--green);
  background: #eaf7e4;
}
.pair-card.is-matched::after {
  content: '✓';
  position: absolute;
  top: 4px;
  right: 7px;
  color: var(--green-dark);
  font-family: var(--font-body);
  font-size: 0.8rem;
  font-weight: 900;
}
.pair-card.is-wrong {
  border-color: var(--coral);
  background: var(--coral-soft);
  animation: shake 0.42s ease;
}

.alphabet-visual {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 5px;
  max-width: 620px;
  margin: 0 auto;
}
.alphabet-visual span {
  display: grid;
  place-items: center;
  width: clamp(30px, 5vw, 42px);
  aspect-ratio: 1;
  border-radius: 11px;
  background: #f8f2e1;
  color: var(--ink-soft);
  font-family: var(--font-display);
  font-size: clamp(0.9rem, 2vw, 1.15rem);
  font-weight: 800;
}
.alphabet-visual span:nth-child(5n + 1) {
  background: #fdf0d2;
  color: #8b6516;
}

/* ---------- Sammlung ---------- */

.collection-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 20px;
}
.collection-count {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  border: 1.5px solid var(--line);
  border-radius: 18px;
  background: rgba(255, 253, 246, 0.75);
  color: var(--ink-soft);
  font-size: 0.88rem;
  font-weight: 800;
}
.collection-count strong {
  color: var(--ink);
  font-family: var(--font-display);
  font-size: 1.3rem;
}
.egg-dots {
  display: flex;
  gap: 4px;
}
.egg-dot {
  width: 12px;
  height: 16px;
  border-radius: 50% 50% 45% 45%;
  background: #e9e0cc;
}
.egg-dot.is-on {
  background: var(--coral);
}

.dino-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 18px;
  margin-top: 30px;
}
.dino-card {
  display: flex;
  flex-direction: column;
  width: calc(33.333% - 12px);
  max-width: 360px;
  min-width: 260px;
  padding: 16px;
  border: 1.5px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--paper);
  box-shadow: var(--shadow-card);
  text-align: left;
}
.dino-card__art {
  position: relative;
  display: grid;
  place-items: center;
  height: 190px;
  border-radius: 20px;
  background: var(--soft, var(--green-soft));
  overflow: hidden;
}
.dino-card__art::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(255, 255, 255, 0.8) 2px, transparent 2px);
  background-size: 18px 18px;
  opacity: 0.45;
}
.dino-card__art .dino-svg {
  position: relative;
  z-index: 1;
  width: 218px;
  height: auto;
  filter: drop-shadow(0 10px 10px rgba(35, 60, 48, 0.12));
}
.dino-card__art .egg-svg {
  position: relative;
  z-index: 1;
  width: 92px;
  filter: drop-shadow(0 10px 10px rgba(35, 60, 48, 0.12));
}
.dino-card.is-locked .dino-card__art {
  background: #f3eddd;
}
.dino-card.is-locked .egg-svg {
  opacity: 0.6;
  filter: grayscale(0.5);
}
.dino-card__level {
  position: absolute;
  top: 10px;
  left: 10px;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 9px;
  border-radius: 8px;
  background: rgba(255, 253, 246, 0.92);
  color: var(--ink-soft);
  font-size: 0.66rem;
  font-weight: 900;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.dino-card__body {
  padding: 15px 4px 4px;
}
.dino-card__body h2 {
  margin: 0;
  font-size: 1.5rem;
  line-height: 1.1;
}
.dino-card__species {
  display: block;
  margin-top: 3px;
  color: var(--ink-soft);
  color: color-mix(in srgb, var(--accent, var(--green-dark)) 50%, var(--ink) 50%);
  font-size: 0.76rem;
  font-weight: 900;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}
.dino-card__fact {
  margin: 11px 0 0;
  color: var(--ink-soft);
  font-size: 0.88rem;
  font-weight: 600;
  line-height: 1.5;
}
.dino-card__hint {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 12px;
  padding: 10px 12px;
  border-radius: 12px;
  background: #f6f0e2;
  color: #8a7c60;
  font-size: 0.83rem;
  font-weight: 800;
}
.dino-card__hint .icon {
  width: 16px;
  height: 16px;
}
.collection-cta {
  display: flex;
  justify-content: center;
  margin-top: 34px;
}

/* ---------- Footer ---------- */

.site-footer {
  margin-top: 40px;
  border-top: 1px solid rgba(35, 60, 48, 0.1);
  background: rgba(253, 248, 234, 0.5);
}
.site-footer__inner {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px 24px;
  max-width: 1180px;
  margin: 0 auto;
  padding: 24px 28px 30px;
  color: var(--ink-faint);
  font-size: 0.8rem;
  font-weight: 700;
}
.site-footer__brand {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin: 0;
  color: var(--ink-soft);
  font-weight: 800;
}
.site-footer__brand .icon {
  width: 17px;
  height: 17px;
  color: var(--green);
}
.site-footer__note {
  margin: 0;
}
.site-footer .link-btn {
  margin-left: auto;
  font-size: 0.8rem;
}

/* ---------- Modal ---------- */

.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 120;
  display: grid;
  place-items: center;
  padding: 20px;
  overflow-y: auto;
  background: rgba(24, 42, 31, 0.52);
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
  animation: fadeIn 0.22s ease;
}
.modal {
  position: relative;
  width: min(780px, 100%);
  max-height: calc(100vh - 40px);
  overflow-y: auto;
  padding: clamp(24px, 4vw, 38px);
  border: 1.5px solid rgba(255, 255, 255, 0.5);
  border-radius: 32px;
  background: var(--paper);
  box-shadow: 0 40px 100px -30px rgba(10, 25, 16, 0.65);
  animation: modalPop 0.3s var(--ease-pop);
}
.modal--wide {
  width: min(860px, 100%);
}
.modal__close {
  position: absolute;
  top: 16px;
  right: 16px;
  z-index: 3;
}
.modal h2 {
  margin: 0 0 8px;
  font-size: clamp(1.8rem, 3.6vw, 2.5rem);
  line-height: 1.05;
}
.modal__lead {
  margin: 0 0 20px;
  color: var(--ink-soft);
  line-height: 1.55;
}

.parent-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  margin: 20px 0;
}
.parent-card {
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: #f9f4e7;
}
.parent-card h3 {
  margin: 0 0 8px;
  font-size: 1.05rem;
}
.parent-card ul {
  margin: 0;
  padding-left: 1.1em;
  color: var(--ink-soft);
  font-size: 0.9rem;
  line-height: 1.55;
}
.parent-card li + li {
  margin-top: 4px;
}
.setting-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px 18px;
  padding: 14px 0;
  border-top: 1px solid var(--line);
}
.setting-row:first-of-type {
  border-top: 0;
}
.setting-row h3 {
  margin: 0;
  font-family: var(--font-body);
  font-size: 0.96rem;
  font-weight: 800;
}
.setting-row p {
  margin: 2px 0 0;
  color: var(--ink-faint);
  font-size: 0.8rem;
  font-weight: 600;
}
.switch {
  position: relative;
  flex: 0 0 auto;
  width: 56px;
  height: 32px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: #ddd4c1;
  cursor: pointer;
  transition: background 0.2s ease;
  -webkit-tap-highlight-color: transparent;
}
.switch::after {
  content: '';
  position: absolute;
  top: 4px;
  left: 4px;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: #fffdf6;
  box-shadow: 0 2px 4px rgba(35, 60, 48, 0.2);
  transition: transform 0.22s var(--ease-pop);
}
.switch[aria-pressed='true'] {
  background: var(--green);
}
.switch[aria-pressed='true']::after {
  transform: translateX(24px);
}
.name-form {
  display: flex;
  gap: 8px;
  align-items: center;
  flex: 0 1 320px;
  min-width: 0;
}
.name-form .input {
  flex: 1 1 140px;
  min-width: 0;
}
.input {
  width: 100%;
  min-height: 46px;
  padding: 10px 14px;
  border: 1.5px solid #d8cfba;
  border-radius: 12px;
  background: #fffdf6;
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 1rem;
  font-weight: 700;
}
.input:focus-visible {
  outline-offset: 2px;
}
.parent-progress {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 6px 0 18px;
}
.parent-progress .mini-chip {
  padding: 6px 11px;
  font-size: 0.8rem;
}
.parent-progress .mini-chip strong {
  color: var(--ink);
}
.danger-zone {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
}
.danger-btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 42px;
  padding: 8px 14px;
  border: 1.5px solid #ecc2b4;
  border-radius: 12px;
  background: #fff3ed;
  color: #a3432a;
  font-size: 0.84rem;
  font-weight: 800;
  cursor: pointer;
}
.danger-btn:hover {
  background: #ffe9e0;
}
.danger-btn.is-confirming {
  background: #c9563b;
  border-color: #b3462e;
  color: #fff;
}
.fineprint {
  margin: 18px 0 0;
  color: var(--ink-faint);
  font-size: 0.76rem;
  line-height: 1.55;
}

/* ---------- Belohnung / Schlüpfen ---------- */

.hatch {
  text-align: center;
  padding-top: 4px;
}
.hatch__label {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin-bottom: 10px;
  padding: 7px 14px;
  border-radius: 999px;
  background: var(--sun-soft);
  color: #85621a;
  font-size: 0.74rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.hatch h2 {
  max-width: 22ch;
  margin: 0 auto 8px;
  font-size: clamp(2rem, 4.6vw, 2.9rem);
}
.hatch__lead {
  max-width: 46ch;
  margin: 0 auto 14px;
  color: var(--ink-soft);
}
.hatch__stage {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 280px;
  margin: 6px 0 10px;
}
.hatch__glow {
  position: absolute;
  width: 330px;
  height: 330px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 216, 112, 0.55) 0%, rgba(255, 216, 112, 0) 68%);
  opacity: 0;
  transform: scale(0.6);
  transition: opacity 0.6s ease, transform 0.7s var(--ease-pop);
}
.hatch__egg-wrap {
  position: relative;
  z-index: 1;
}
.hatch__egg-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  padding: 0;
  border: 0;
  background: none;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.hatch__egg-btn .egg-svg {
  width: clamp(140px, 26vw, 190px);
  filter: drop-shadow(0 18px 18px rgba(35, 60, 48, 0.16));
  transition: transform 0.2s ease;
  --egg-shell: #fff1c8;
  --egg-spot: var(--egg-accent, #ef8265);
}
.hatch__egg-btn:hover .egg-svg {
  transform: rotate(-2deg) scale(1.03);
}
.hatch__egg-btn:active .egg-svg {
  transform: scale(0.98);
}
.hatch__tap {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 8px 15px;
  border-radius: 999px;
  background: var(--sun);
  color: #4d3709;
  font-family: var(--font-display);
  font-size: 0.95rem;
  font-weight: 800;
  box-shadow: 0 4px 0 var(--sun-dark);
  animation: tapPulse 1.8s ease-in-out infinite;
}
.hatch__egg-helper {
  position: absolute;
  top: 2%;
  right: 12%;
  width: 44px;
  color: var(--coral);
  animation: bobble 4s ease-in-out infinite;
}
.egg__cracks {
  opacity: 0;
  transition: opacity 0.18s ease;
}
.hatch.is-cracked .egg__cracks {
  opacity: 1;
}
.hatch.is-cracked .hatch__egg-btn .egg-svg {
  animation: eggShake 0.55s ease;
}
.hatch.is-revealed .hatch__glow {
  opacity: 1;
  transform: scale(1);
}
.hatch.is-revealed .hatch__egg-wrap {
  display: none;
}
.hatch__reveal {
  display: none;
  position: relative;
  z-index: 2;
  width: 100%;
}
.hatch.is-revealed .hatch__reveal {
  display: block;
  animation: revealPop 0.6s var(--ease-pop);
}
.hatch__dino {
  width: clamp(220px, 42vw, 310px);
  margin: 0 auto;
  filter: drop-shadow(0 18px 18px rgba(35, 60, 48, 0.14));
}
.hatch__name {
  margin: 8px 0 0;
  font-family: var(--font-display);
  font-size: clamp(1.9rem, 4vw, 2.7rem);
  font-weight: 800;
  line-height: 1;
}
.hatch__species {
  display: block;
  margin-top: 4px;
  color: var(--ink-soft);
  color: color-mix(in srgb, var(--accent, var(--coral-dark)) 50%, var(--ink) 50%);
  font-size: 0.78rem;
  font-weight: 900;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.hatch__fact {
  max-width: 46ch;
  margin: 12px auto 0;
  color: var(--ink-soft);
  font-size: 0.9rem;
  line-height: 1.55;
}
.hatch__actions {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 22px;
}
.hatch__stars {
  display: flex;
  justify-content: center;
  gap: 5px;
  margin: 4px 0 10px;
}
.hatch__stars .icon {
  width: 34px;
  height: 34px;
  color: #ddd3bd;
}
.hatch__stars .is-on {
  color: #f0b429;
  animation: starPop 0.5s var(--ease-pop) both;
}
.hatch__stars .is-on:nth-child(2) { animation-delay: 0.12s; }
.hatch__stars .is-on:nth-child(3) { animation-delay: 0.24s; }

.result-dino {
  width: 190px;
  margin: 4px auto 6px;
}
.result-dino .dino-svg,
.hatch__dino .dino-svg {
  width: 100%;
  height: auto;
}
.hatch__again {
  flex-basis: 100%;
  margin: 4px 0 0;
  text-align: center;
}
.hatch__again .link-btn {
  font-size: 0.88rem;
}

/* ---------- Toast & Konfetti ---------- */

.toast {
  position: fixed;
  left: 50%;
  bottom: 26px;
  z-index: 210;
  max-width: min(420px, calc(100vw - 32px));
  padding: 12px 20px;
  border-radius: 999px;
  background: var(--green-deep);
  color: #fffbea;
  font-size: 0.9rem;
  font-weight: 800;
  text-align: center;
  box-shadow: 0 14px 30px -12px rgba(10, 30, 18, 0.5);
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, 18px);
  transition: opacity 0.22s ease, transform 0.22s var(--ease-pop);
}
.toast.is-visible {
  opacity: 1;
  transform: translate(-50%, 0);
}

.confetti {
  position: fixed;
  inset: 0;
  z-index: 200;
  overflow: hidden;
  pointer-events: none;
}
.confetti span {
  position: absolute;
  top: -24px;
  left: var(--x);
  width: var(--w);
  height: var(--h);
  border-radius: var(--r);
  background: var(--c);
  opacity: 0;
  animation: confettiFall var(--dur) var(--delay) cubic-bezier(0.22, 0.6, 0.35, 1) forwards;
}

/* ---------- Ladezustand & NoScript ---------- */

.boot {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  min-height: 52vh;
  color: var(--ink-soft);
  font-weight: 700;
}
.boot__egg {
  font-size: 4rem;
  animation: bobble 2.4s ease-in-out infinite;
}
.boot p {
  margin: 0;
}
.noscript {
  position: fixed;
  inset: auto 16px 16px;
  z-index: 300;
  padding: 16px;
  border-radius: 16px;
  background: #fff0e8;
  color: #8b3a23;
  font-weight: 700;
  text-align: center;
}

/* ---------- Animationen ---------- */

@keyframes rexiBob {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-6px); }
}
@keyframes tailSway {
  0%, 100% { transform: rotate(0deg); }
  50% { transform: rotate(-4deg); }
}
@keyframes armWave {
  0%, 100% { transform: rotate(0deg); }
  50% { transform: rotate(-7deg); }
}
@keyframes blink {
  0%, 91%, 100% { transform: scaleY(0); }
  93%, 96% { transform: scaleY(1); }
}
@keyframes bobble {
  0%, 100% { translate: 0 0; }
  50% { translate: 0 -9px; }
}
@keyframes breathe {
  0%, 100% { transform: scale(1); opacity: 0.88; }
  50% { transform: scale(1.06); opacity: 1; }
}
@keyframes drift {
  0% { translate: -20px 0; }
  100% { translate: 40px 12px; }
}
@keyframes floatLeaf {
  0%, 100% { transform: translate3d(0, 0, 0) rotate(0deg); }
  33% { transform: translate3d(16px, -22px, 0) rotate(14deg); }
  66% { transform: translate3d(-12px, -40px, 0) rotate(-8deg); }
}
@keyframes spinSlow {
  to { transform: rotate(360deg); }
}
@keyframes blankPulse {
  0%, 100% { opacity: 0.55; transform: scale(0.96); }
  50% { opacity: 1; transform: scale(1.04); }
}
@keyframes dotPulse {
  0%, 100% { transform: scale(0.85); opacity: 0.7; }
  50% { transform: scale(1.15); opacity: 1; }
}
@keyframes markerPulse {
  0%, 100% { box-shadow: 0 6px 0 rgba(35, 60, 48, 0.07), 0 0 0 0 rgba(255, 201, 74, 0.5); }
  50% { box-shadow: 0 6px 0 rgba(35, 60, 48, 0.07), 0 0 0 13px rgba(255, 201, 74, 0); }
}
@keyframes starPulse {
  0% { transform: scale(1); }
  40% { transform: scale(1.14) rotate(-3deg); }
  100% { transform: scale(1); }
}
@keyframes starPop {
  0% { transform: scale(0.3) rotate(-18deg); opacity: 0; }
  70% { transform: scale(1.15) rotate(4deg); opacity: 1; }
  100% { transform: scale(1) rotate(0); opacity: 1; }
}
@keyframes popIn {
  0% { transform: scale(0.85); opacity: 0; }
  100% { transform: scale(1); opacity: 1; }
}
@keyframes correctPop {
  0% { transform: scale(1); }
  45% { transform: scale(1.06); }
  100% { transform: scale(1); }
}
@keyframes shake {
  0%, 100% { transform: translateX(0); }
  18% { transform: translateX(-6px); }
  36% { transform: translateX(5px); }
  54% { transform: translateX(-4px); }
  72% { transform: translateX(3px); }
}
@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}
@keyframes modalPop {
  0% { transform: translateY(18px) scale(0.96); opacity: 0; }
  100% { transform: translateY(0) scale(1); opacity: 1; }
}
@keyframes revealPop {
  0% { transform: scale(0.65); opacity: 0; }
  65% { transform: scale(1.05); opacity: 1; }
  100% { transform: scale(1); opacity: 1; }
}
@keyframes eggShake {
  0% { transform: rotate(0) scale(1); }
  20% { transform: rotate(-6deg) scale(1.02); }
  40% { transform: rotate(6deg) scale(1.03); }
  60% { transform: rotate(-4deg) scale(1.02); }
  80% { transform: rotate(3deg) scale(1.01); }
  100% { transform: rotate(0) scale(1); }
}
@keyframes tapPulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.04); }
}
@keyframes confettiFall {
  0% { opacity: 0; transform: translate3d(0, -10px, 0) rotate(0deg); }
  10% { opacity: 1; }
  100% { opacity: 1; transform: translate3d(var(--dx), 104vh, 0) rotate(var(--rot)); }
}

/* ---------- Spielhöhle: Startseite & Übersicht ---------- */

.arcade-teaser {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  gap: 24px;
  align-items: center;
  margin-top: 38px;
  padding: 28px 30px;
  border: 1.5px solid #efcdbd;
  border-radius: var(--radius-xl);
  background:
    radial-gradient(90% 130% at 100% 0%, rgba(255, 201, 74, 0.2), transparent 55%),
    linear-gradient(110deg, #fff7e6 0%, #f2f8ea 100%);
  box-shadow: var(--shadow-card);
  overflow: hidden;
}
.arcade-teaser::after {
  content: '';
  position: absolute;
  right: -50px;
  bottom: -80px;
  width: 200px;
  height: 200px;
  border-radius: 50%;
  background: rgba(139, 121, 200, 0.12);
  pointer-events: none;
}
.arcade-teaser__copy {
  position: relative;
  z-index: 1;
}
.arcade-teaser__copy h2 {
  margin: 12px 0 8px;
  font-size: clamp(1.8rem, 3vw, 2.5rem);
}
.arcade-teaser__copy p {
  max-width: 42ch;
  margin: 0 0 18px;
  color: var(--ink-soft);
  font-size: 0.98rem;
  line-height: 1.55;
}
.arcade-teaser__list {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.arcade-teaser__item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 9px 13px;
  border: 1px solid rgba(35, 60, 48, 0.1);
  border-radius: 16px;
  background: rgba(255, 253, 246, 0.8);
}
.arcade-teaser__icon {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  flex: 0 0 auto;
  border-radius: 12px;
  background: #fffdf6;
  font-size: 1.25rem;
  box-shadow: 0 2px 0 rgba(35, 60, 48, 0.06);
}
.arcade-teaser__item strong {
  display: block;
  font-family: var(--font-display);
  font-size: 0.98rem;
  font-weight: 800;
  line-height: 1.15;
}
.arcade-teaser__item small {
  display: block;
  margin-top: 2px;
  color: var(--ink-faint);
  font-size: 0.7rem;
  font-weight: 800;
}

.trail__end-cta {
  margin-left: auto;
  flex: 0 0 auto;
}

/* ---------- Spielhöhle: Übersicht ---------- */

.arcade-head {
  max-width: 820px;
}
.arcade-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 18px;
  margin-top: 28px;
}
.arcade-card {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1.5px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--paper);
  box-shadow: var(--shadow-card);
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}
.arcade-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-lift);
}
.arcade-card__art {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 158px;
  background: var(--soft, var(--green-soft));
  overflow: hidden;
}
.arcade-card__art::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(255, 255, 255, 0.8) 2px, transparent 2px);
  background-size: 18px 18px;
  opacity: 0.55;
}
.arcade-card__art::after {
  content: '';
  position: absolute;
  width: 150px;
  height: 150px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.35);
}
.arcade-card__icon {
  position: relative;
  z-index: 1;
  font-size: 4.2rem;
  line-height: 1;
  filter: drop-shadow(0 10px 10px rgba(35, 60, 48, 0.13));
  transform: rotate(-4deg);
}
.arcade-card__num {
  position: absolute;
  top: 12px;
  left: 12px;
  z-index: 2;
  padding: 4px 9px;
  border-radius: 8px;
  background: rgba(255, 253, 246, 0.9);
  color: var(--ink-soft);
  font-size: 0.65rem;
  font-weight: 900;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}
.arcade-card__body {
  display: flex;
  flex: 1;
  flex-direction: column;
  padding: 20px;
}
.arcade-card__kicker {
  color: var(--ink-soft);
  color: color-mix(in srgb, var(--accent, var(--green)) 50%, var(--ink) 50%);
  font-size: 0.69rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.arcade-card h2 {
  margin: 6px 0 7px;
  font-size: 1.55rem;
  line-height: 1.05;
}
.arcade-card p {
  margin: 0 0 18px;
  color: var(--ink-soft);
  font-size: 0.91rem;
  line-height: 1.5;
}
.arcade-card__footer {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: auto;
}
.arcade-card__best {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 3px;
}
.arcade-card__best small {
  color: var(--ink-faint);
  font-size: 0.69rem;
  font-weight: 800;
}
.medal {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 9px;
  border: 1px solid #e5dcc7;
  border-radius: 999px;
  background: #f6f1e3;
  color: var(--ink-soft);
  font-size: 0.71rem;
  font-weight: 900;
  white-space: nowrap;
}
.medal--gold {
  border-color: #ebd079;
  background: #fff5c9;
  color: #78570d;
}
.medal--silver {
  border-color: #d2d7d4;
  background: #f1f3f2;
  color: #55605a;
}
.medal--bronze {
  border-color: #edc5aa;
  background: #fbe9db;
  color: #88492a;
}
.medal--empty {
  border-color: #e3ddcd;
  background: #f7f3e9;
  color: #7e735f;
}
.arcade-note {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-top: 28px;
  padding: 18px 22px;
  border: 1.5px dashed #d9cfb9;
  border-radius: 22px;
  background: rgba(255, 253, 246, 0.65);
}
.arcade-note__icon {
  width: 58px;
  flex: 0 0 auto;
}
.arcade-note__icon svg {
  width: 100%;
  height: auto;
}
.arcade-note strong {
  display: block;
  margin-bottom: 2px;
  font-family: var(--font-display);
  font-size: 1rem;
}
.arcade-note p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 0.86rem;
  line-height: 1.5;
}
.arcade-note .btn {
  margin-left: auto;
  flex: 0 0 auto;
}

/* ---------- Spielhöhle: Spielansicht ---------- */

.arcade-game .task-card {
  min-height: 0;
}
.arcade-skill {
  display: inline-flex;
  align-items: center;
  padding: 6px 11px;
  border-radius: 8px;
  background: #f6f0e1;
  color: var(--ink-faint);
  font-size: 0.7rem;
  font-weight: 900;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}
.arcade-build {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
}
.arcade-picture {
  display: grid;
  place-items: center;
  width: clamp(110px, 18vw, 140px);
  aspect-ratio: 1;
  border: 3px dashed #d6c9a8;
  border-radius: 50%;
  background: radial-gradient(circle at 40% 35%, #fffdf2 0%, #fbf0d0 100%);
  font-size: clamp(3.5rem, 8vw, 4.8rem);
  line-height: 1;
  box-shadow: 0 10px 0 rgba(35, 60, 48, 0.05);
}
.build-slots {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 8px;
}
.build-slot {
  display: grid;
  place-items: center;
  width: clamp(44px, 7vw, 58px);
  height: clamp(50px, 8vw, 66px);
  border: 2px dashed #d5cab3;
  border-radius: 14px;
  background: rgba(248, 243, 230, 0.65);
  color: #b5a88e;
  font-family: var(--font-display);
  font-size: clamp(1.4rem, 3.4vw, 2rem);
  font-weight: 800;
  line-height: 1;
}
.build-slot.is-filled {
  border-style: solid;
  border-color: var(--green);
  background: #eaf7e4;
  color: var(--green-deep);
  animation: popIn 0.2s var(--ease-pop);
}
.build-slot.is-ok {
  border-color: var(--green-dark);
  background: #dff3d5;
}
.build-slot.is-help {
  border-color: #d9a92e;
  background: #fff4c9;
  color: #78570d;
}
.build-slot.is-wrong {
  border-color: var(--coral);
  background: var(--coral-soft);
  color: #963d24;
  animation: shake 0.4s ease;
}
.build-pool {
  margin-top: 2px;
}
.arcade-build .order-tools {
  margin-top: 0;
}

/* Memory */

.memory-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
}
.memory-count {
  color: var(--ink-soft);
  font-size: 0.84rem;
  font-weight: 800;
}
.memory-count strong {
  color: var(--ink);
  font-family: var(--font-display);
  font-size: 1.05rem;
}
.memory-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  width: 100%;
  max-width: 520px;
  margin: 0 auto;
}
.memory-card {
  position: relative;
  padding: 0;
  border: 0;
  background: none;
  aspect-ratio: 0.92;
  border-radius: 18px;
  perspective: 800px;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.memory-card__inner {
  position: absolute;
  inset: 0;
  transform-style: preserve-3d;
  transition: transform 0.35s var(--ease-pop);
}
.memory-card.is-flipped .memory-card__inner {
  transform: rotateY(180deg);
}
.memory-card__back,
.memory-card__front {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  border-radius: 18px;
  border: 2.5px solid #cfc4ab;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  box-shadow: 0 5px 0 rgba(35, 60, 48, 0.08);
}
.memory-card__back {
  border-color: var(--green-dark);
  background:
    radial-gradient(rgba(255, 255, 255, 0.15) 2px, transparent 2px),
    linear-gradient(150deg, #5aa779, #2d6b49);
  background-size: 16px 16px, auto;
  color: #fff8e7;
}
.memory-card__back > span {
  font-family: var(--font-display);
  font-size: 1.9rem;
  font-weight: 800;
  opacity: 0.9;
}
.memory-card__back .icon {
  position: absolute;
  right: 7px;
  bottom: 6px;
  width: 17px;
  height: 17px;
  opacity: 0.35;
}
.memory-card__front {
  transform: rotateY(180deg);
  background: #fffdf4;
  border-color: #ded4bd;
  color: var(--ink);
}
.memory-card__front--picture .memory-emoji {
  font-size: clamp(2rem, 5vw, 2.8rem);
  line-height: 1;
}
.memory-card__front--letter .memory-letter {
  font-family: var(--font-display);
  font-size: clamp(2rem, 5vw, 2.9rem);
  font-weight: 800;
  line-height: 1;
}
.memory-card.is-matched .memory-card__front {
  border-color: var(--green);
  background: #eaf7e4;
  box-shadow: 0 5px 0 rgba(63, 143, 99, 0.15);
}
.memory-card.is-matched .memory-card__front::after {
  content: '✓';
  position: absolute;
  top: 4px;
  right: 7px;
  color: var(--green-dark);
  font-family: var(--font-body);
  font-size: 0.8rem;
  font-weight: 900;
}
.memory-card:focus-visible {
  outline: 3px solid #2b6ca3;
  outline-offset: 3px;
}

/* Buchstaben-Pfad */

.path-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}
.path-prompt {
  padding: 8px 18px;
  border: 1px solid #ead8a6;
  border-radius: 999px;
  background: #fff8e4;
  color: var(--ink-soft);
  font-family: var(--font-display);
  font-size: clamp(1rem, 2.2vw, 1.22rem);
  font-weight: 700;
  text-align: center;
}
.path-prompt strong {
  color: var(--green-dark);
  font-size: 1.15em;
}
.path-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  width: 100%;
  max-width: 430px;
  margin: 0 auto;
}
.path-cell {
  position: relative;
  display: grid;
  place-items: center;
  aspect-ratio: 1;
  border: 2.5px solid #ded4bd;
  border-radius: 16px;
  background: #fffcf2;
  color: var(--ink);
  font-family: var(--font-display);
  font-size: clamp(1.7rem, 4vw, 2.5rem);
  font-weight: 800;
  line-height: 1;
  cursor: pointer;
  box-shadow: 0 5px 0 #e8dfca;
  transition: transform 0.15s ease, background 0.15s ease, border-color 0.15s ease;
  -webkit-tap-highlight-color: transparent;
}
.path-cell:hover {
  transform: translateY(-2px);
}
.path-cell.is-path {
  border-color: #c3e0b8;
  background: #eaf7e4;
  color: var(--green-deep);
}
.path-cell.is-current {
  border-color: #d9a92e;
  background: #fff4c9;
  box-shadow: 0 0 0 4px rgba(255, 201, 74, 0.24), 0 5px 0 #e8dfca;
}
.path-cell.is-goal {
  border-color: #e1b7a0;
}
.path-cell.is-hint {
  border-color: #d9a92e;
  background: #fff0b5;
  animation: hintPulse 1.15s ease-in-out infinite;
}
.path-cell.is-wrong {
  border-color: var(--coral);
  background: var(--coral-soft);
  color: #963d24;
  animation: shake 0.4s ease;
}
.path-letter {
  position: relative;
  z-index: 1;
}
.path-marker {
  position: absolute;
  top: 4px;
  left: 5px;
  z-index: 2;
  display: grid;
  place-items: center;
  width: 19px;
  height: 19px;
  border-radius: 50%;
  background: var(--green);
  color: #fff8e7;
  box-shadow: 0 2px 0 rgba(35, 60, 48, 0.12);
}
.path-marker .icon {
  width: 11px;
  height: 11px;
}
.path-egg {
  position: absolute;
  right: 5px;
  bottom: 3px;
  z-index: 2;
  font-size: 0.85rem;
  line-height: 1;
}
.path-legend {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 12px;
  color: var(--ink-faint);
  font-size: 0.71rem;
  font-weight: 800;
}
.path-legend span {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.path-legend .icon {
  width: 13px;
  height: 13px;
}

/* Ergebnis */

.arcade-result {
  text-align: center;
}
.arcade-result > *:not(.arcade-result__rexi) {
  position: relative;
  z-index: 1;
}
.arcade-result__medal {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  width: 138px;
  height: 138px;
  margin: 4px auto 14px;
  border: 3px solid #e5dcc7;
  border-radius: 50%;
  background: #f6f1e3;
  box-shadow: 0 8px 0 rgba(35, 60, 48, 0.07), inset 0 2px 0 rgba(255, 255, 255, 0.7);
}
.arcade-result__medal > span {
  font-size: 3.1rem;
  line-height: 1;
}
.arcade-result__medal strong {
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 800;
}
.arcade-result__medal.medal--gold {
  border-color: #e5c263;
  background: radial-gradient(circle at 40% 30%, #fffbe0, #ffe89c);
  color: #78570d;
}
.arcade-result__medal.medal--silver {
  border-color: #c6ccca;
  background: radial-gradient(circle at 40% 30%, #ffffff, #e1e5e3);
  color: #4f5a55;
}
.arcade-result__medal.medal--bronze {
  border-color: #d9a27e;
  background: radial-gradient(circle at 40% 30%, #fff1e4, #f0c4a6);
  color: #7c4224;
}
.arcade-result h1 {
  margin: 12px 0 6px;
  font-size: clamp(1.9rem, 4vw, 2.7rem);
}
.arcade-result__line {
  max-width: 42ch;
  margin: 0 auto 18px;
  color: var(--ink-soft);
  font-size: 0.98rem;
}
.arcade-result__best {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 8px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #faf5e8;
  color: var(--ink-soft);
  font-size: 0.8rem;
  font-weight: 800;
}
.arcade-result__actions {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 20px;
}
.arcade-result__rexi {
  position: absolute;
  right: 4px;
  bottom: -18px;
  width: 125px;
  opacity: 0.95;
  z-index: 0;
  transform: rotate(4deg);
}
.arcade-result__rexi svg {
  width: 100%;
  height: auto;
}

@keyframes hintPulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(217, 169, 46, 0.35), 0 5px 0 #e8dfca; }
  50% { box-shadow: 0 0 0 8px rgba(217, 169, 46, 0), 0 5px 0 #e8dfca; }
}

/* ---------- Buchstaben-Klavier: Teaser ---------- */

.piano-teaser {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  gap: 26px;
  align-items: center;
  margin-top: 38px;
  padding: 28px 30px;
  border: 1.5px solid #efcdbd;
  border-radius: var(--radius-xl);
  background:
    radial-gradient(90% 130% at 100% 0%, rgba(255, 201, 74, 0.22), transparent 55%),
    linear-gradient(110deg, #fff7e6 0%, #f2f8ea 100%);
  box-shadow: var(--shadow-card);
  overflow: hidden;
}
.piano-teaser__copy {
  position: relative;
  z-index: 1;
}
.piano-teaser__copy h2 {
  margin: 12px 0 8px;
  font-size: clamp(1.8rem, 3vw, 2.5rem);
}
.piano-teaser__copy p {
  max-width: 44ch;
  margin: 0 0 18px;
  color: var(--ink-soft);
  font-size: 0.98rem;
  line-height: 1.55;
}
.piano-teaser__cta {
  display: inline-flex;
}
.piano-teaser__art {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 210px;
  padding: 20px 12px 4px;
  border-radius: 26px;
  background: rgba(255, 253, 246, 0.55);
  overflow: hidden;
}
.piano-teaser__rexi {
  position: absolute;
  top: -10px;
  right: 4px;
  width: 104px;
  transform: rotate(5deg);
  filter: drop-shadow(0 8px 8px rgba(35, 60, 48, 0.12));
}
.piano-teaser__rexi svg {
  width: 100%;
  height: auto;
}
.piano-teaser__note {
  position: absolute;
  z-index: 2;
  color: var(--coral-dark);
  font-family: var(--font-display);
  font-weight: 800;
  line-height: 1;
  animation: bobble 4s ease-in-out infinite;
}
.piano-teaser__note--one {
  top: 24%;
  left: 10%;
  font-size: 2.3rem;
  color: var(--lavender);
  animation-delay: -1.4s;
}
.piano-teaser__note--two {
  top: 9%;
  left: 34%;
  font-size: 1.6rem;
  color: #d9a92e;
  animation-delay: -3s;
}
.piano-mini {
  display: flex;
  align-items: flex-end;
  gap: 4px;
  width: min(100%, 330px);
  padding: 14px 14px 0;
  border-radius: 20px 20px 14px 14px;
  background: linear-gradient(#315741, #224334);
  box-shadow: 0 10px 24px -14px rgba(35, 60, 48, 0.55);
  position: relative;
  z-index: 1;
}
.piano-mini__key {
  flex: 1;
  display: grid;
  place-items: end center;
  height: 104px;
  padding-bottom: 10px;
  border: 2px solid #d9cfb8;
  border-top: 10px solid var(--key-color, var(--sun));
  border-radius: 0 0 11px 11px;
  background: linear-gradient(#fffdf4, #f0e8d5);
  color: var(--ink);
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 800;
  box-shadow: 0 4px 0 #c4b79f;
}

/* ---------- Großer Vorlesen-Knopf ---------- */

.speak-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  min-height: 54px;
  padding: 11px 20px;
  border: 2px solid #a93b27;
  border-radius: 999px;
  background: linear-gradient(180deg, #ea654c 0%, #d94f38 100%);
  color: #fff9ee;
  font-family: var(--font-display);
  font-size: 1.08rem;
  font-weight: 800;
  line-height: 1.05;
  cursor: pointer;
  box-shadow: 0 5px 0 #a93b27, 0 14px 24px -14px rgba(169, 59, 39, 0.65);
  transition: transform 0.15s ease, box-shadow 0.15s ease, filter 0.15s ease;
  animation: speakGlow 3.8s ease-in-out infinite;
  -webkit-tap-highlight-color: transparent;
}
.speak-btn .icon {
  width: 25px;
  height: 25px;
}
.speak-btn:hover {
  transform: translateY(-2px);
  filter: brightness(1.04);
  box-shadow: 0 7px 0 #a93b27, 0 18px 26px -14px rgba(169, 59, 39, 0.6);
}
.speak-btn:active {
  transform: translateY(4px);
  box-shadow: 0 1px 0 #a93b27;
}
.speak-btn[disabled] {
  cursor: not-allowed;
  filter: grayscale(0.35);
  opacity: 0.65;
  animation: none;
}
.task-card__tools {
  flex-wrap: wrap;
}

/* ---------- Buchstaben-Klavier: Spiel ---------- */

.piano-panel {
  overflow: hidden;
}
.piano-stage {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 18px;
  margin: 8px 0 24px;
}
.piano-stage__top {
  display: flex;
  align-items: center;
  gap: 18px;
}
.piano-buddy {
  flex: 0 0 auto;
  width: 92px;
}
.piano-buddy svg {
  width: 100%;
  height: auto;
}
.piano-buddy.is-dancing {
  animation: pianoDance 0.55s var(--ease-pop);
}
.piano-song {
  flex: 1;
  min-width: 0;
}
.piano-song__name {
  display: block;
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 800;
  color: var(--green-deep);
}
.piano-notes {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 8px 0 6px;
}
.piano-note {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border: 2px solid #ded3bd;
  border-radius: 12px;
  background: #f8f2e3;
  color: var(--ink-soft);
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 800;
  line-height: 1;
  transition: transform 0.18s var(--ease-pop), background 0.18s, border-color 0.18s;
}
.piano-note.is-current {
  border-color: #d9a92e;
  background: #fff0b5;
  color: #78570d;
  transform: translateY(-3px) scale(1.06);
  box-shadow: 0 4px 0 rgba(217, 169, 46, 0.25);
  animation: notePulse 1.5s ease-in-out infinite;
}
.piano-note.is-done {
  border-color: #8cc47b;
  background: #e6f5dd;
  color: var(--green-deep);
}
.piano-song__hint {
  margin: 0;
  color: var(--ink-faint);
  font-size: 0.78rem;
  font-weight: 700;
  line-height: 1.4;
}
.piano-keys {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: flex-end;
  gap: 6px;
  padding: 14px 14px 12px;
  border-radius: 20px 20px 16px 16px;
  background: linear-gradient(#315741, #224334);
  box-shadow: inset 0 3px 0 rgba(255, 255, 255, 0.16), 0 12px 26px -18px rgba(35, 60, 48, 0.55);
}
.piano-key {
  position: relative;
  display: flex;
  flex: 1;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  min-width: 0;
  height: 164px;
  padding: 0 0 14px;
  border: 2px solid #d9cfb8;
  border-top: 10px solid var(--key-color, var(--sun));
  border-radius: 0 0 14px 14px;
  background: linear-gradient(180deg, #fffdf4 0%, #f0e8d5 100%);
  color: var(--ink);
  cursor: pointer;
  box-shadow: 0 6px 0 #c4b79f;
  transition: transform 0.08s ease, box-shadow 0.08s ease, background 0.12s ease;
  -webkit-tap-highlight-color: transparent;
}
.piano-key__shine {
  position: absolute;
  top: 0;
  left: 9px;
  right: 9px;
  height: 3px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.75);
}
.piano-key__letter {
  font-family: var(--font-display);
  font-size: clamp(1.35rem, 2.6vw, 1.8rem);
  font-weight: 800;
  line-height: 1;
}
.piano-key__dot {
  width: 6px;
  height: 6px;
  margin-top: 7px;
  border-radius: 50%;
  background: var(--key-color, var(--sun));
  opacity: 0.8;
}
.piano-key:hover {
  background: linear-gradient(180deg, #fffefa 0%, #f6eedb 100%);
}
.piano-key.is-pressed {
  transform: translateY(6px);
  background: #f4ecd8;
  box-shadow: 0 1px 0 #c4b79f;
}
.piano-key.is-wrong {
  border-color: var(--coral);
  background: var(--coral-soft);
  color: #8b3a23;
  animation: shake 0.4s ease;
}
.piano-key.is-hint {
  border-color: #d9a92e;
  background: #fff3c9;
  animation: pianoHint 1.1s ease-in-out infinite;
}
.piano-float-layer {
  position: absolute;
  inset: 0;
  z-index: 2;
  overflow: hidden;
  pointer-events: none;
}
.piano-float {
  position: absolute;
  bottom: 70px;
  left: var(--x, 50%);
  color: #d9a92e;
  font-family: var(--font-display);
  font-size: 1.6rem;
  font-weight: 800;
  line-height: 1;
  text-shadow: 0 2px 0 rgba(255, 255, 255, 0.5);
  animation: pianoFloat 1s ease-out forwards;
}

/* Konzert-Ergebnis */

.piano-result {
  text-align: center;
}
.piano-result > *:not(.piano-result__rexi) {
  position: relative;
  z-index: 1;
}
.piano-result__badge {
  margin: 2px auto 6px;
  font-size: 4.2rem;
  line-height: 1;
  animation: bobble 3s ease-in-out infinite;
}
.piano-result h1 {
  margin: 12px 0 8px;
  font-size: clamp(1.9rem, 4vw, 2.8rem);
}
.piano-result__lead {
  max-width: 44ch;
  margin: 0 auto 16px;
  color: var(--ink-soft);
  font-size: 1rem;
}
.piano-result__keys {
  width: min(100%, 340px);
  margin: 0 auto;
  padding-top: 12px;
}
.piano-result__actions {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 22px;
}
.piano-result__rexi {
  position: absolute;
  right: 2px;
  bottom: -16px;
  width: 122px;
  z-index: 0;
  opacity: 0.95;
  transform: rotate(4deg);
}
.piano-result__rexi svg {
  width: 100%;
  height: auto;
}

@keyframes speakGlow {
  0%, 100% { box-shadow: 0 5px 0 #a93b27, 0 14px 24px -14px rgba(169, 59, 39, 0.6), 0 0 0 0 rgba(217, 79, 56, 0.28); }
  50% { box-shadow: 0 5px 0 #a93b27, 0 14px 24px -14px rgba(169, 59, 39, 0.6), 0 0 0 9px rgba(217, 79, 56, 0); }
}
@keyframes notePulse {
  0%, 100% { transform: translateY(-3px) scale(1.06); }
  50% { transform: translateY(-5px) scale(1.1); }
}
@keyframes pianoDance {
  0%, 100% { transform: rotate(0deg) translateY(0); }
  25% { transform: rotate(-7deg) translateY(-7px); }
  60% { transform: rotate(6deg) translateY(-4px); }
}
@keyframes pianoFloat {
  0% { opacity: 0; transform: translateY(0) translateX(0) scale(0.7); }
  20% { opacity: 1; }
  100% { opacity: 0; transform: translateY(-100px) translateX(var(--drift, 0)) scale(1.15) rotate(12deg); }
}
@keyframes pianoHint {
  0%, 100% { box-shadow: 0 0 0 0 rgba(217, 169, 46, 0.35), 0 6px 0 #c4b79f; }
  50% { box-shadow: 0 0 0 8px rgba(217, 169, 46, 0), 0 6px 0 #c4b79f; }
}

/* ---------- Tipp-Knopf (symmetrisch zu Vorlesen) ---------- */

.hint-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  min-height: 54px;
  padding: 11px 20px;
  border: 2px solid #52339a;
  border-radius: 999px;
  background: linear-gradient(180deg, #8d6fe0 0%, #6f4fd2 100%);
  color: #fff9ee;
  font-family: var(--font-display);
  font-size: 1.08rem;
  font-weight: 800;
  line-height: 1.05;
  cursor: pointer;
  box-shadow: 0 5px 0 #52339a, 0 14px 24px -14px rgba(82, 51, 154, 0.6);
  transition: transform 0.15s ease, box-shadow 0.15s ease, filter 0.15s ease;
  -webkit-tap-highlight-color: transparent;
}
.hint-btn .icon {
  width: 24px;
  height: 24px;
}
.hint-btn:hover {
  transform: translateY(-2px);
  filter: brightness(1.04);
  box-shadow: 0 7px 0 #52339a, 0 18px 26px -14px rgba(82, 51, 154, 0.6);
}
.hint-btn:active {
  transform: translateY(4px);
  box-shadow: 0 1px 0 #52339a;
}
.hint-btn[disabled] {
  cursor: not-allowed;
  filter: grayscale(0.35);
  opacity: 0.65;
}

/* ---------- Spiele-Karten (Startseite & Übersicht) ---------- */

.games-teaser {
  margin-top: 40px;
}
.games-teaser__head {
  max-width: 640px;
  margin: 0 auto 24px;
  text-align: center;
}
.games-teaser__head h2 {
  margin: 10px 0 6px;
  font-size: clamp(1.9rem, 3.2vw, 2.7rem);
}
.games-teaser__head p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 1rem;
  line-height: 1.55;
}
.game-card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 20px;
}
.game-card {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1.5px solid var(--line);
  border-radius: 28px;
  background: var(--paper);
  box-shadow: var(--shadow-card);
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}
.game-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-lift);
}
.game-card__art {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 172px;
  padding: 18px;
  background: var(--soft, var(--green-soft));
  overflow: hidden;
}
.game-card__art::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(255, 255, 255, 0.8) 2px, transparent 2px);
  background-size: 18px 18px;
  opacity: 0.55;
}
.game-card__new {
  position: absolute;
  top: 12px;
  left: 12px;
  z-index: 2;
  padding: 5px 11px;
  border-radius: 999px;
  background: var(--sun);
  color: #4d3709;
  font-size: 0.66rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  box-shadow: 0 3px 0 rgba(35, 60, 48, 0.12);
  transform: rotate(-3deg);
}
.game-card__body {
  display: flex;
  flex: 1;
  flex-direction: column;
  padding: 20px 22px 22px;
}
.game-card__tag {
  color: var(--ink-soft);
  color: color-mix(in srgb, var(--accent, var(--green)) 48%, var(--ink) 52%);
  font-size: 0.68rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.game-card h2 {
  margin: 5px 0 7px;
  font-size: 1.6rem;
  line-height: 1.05;
}
.game-card p {
  margin: 0 0 18px;
  color: var(--ink-soft);
  font-size: 0.93rem;
  line-height: 1.5;
}
.game-card .btn {
  align-self: flex-start;
}
.game-card__note {
  position: absolute;
  z-index: 1;
  color: var(--lavender);
  font-family: var(--font-display);
  font-weight: 800;
  line-height: 1;
  animation: bobble 4s ease-in-out infinite;
}
.game-card__note--one {
  top: 14%;
  left: 10%;
  font-size: 2rem;
}
.game-card__note--two {
  top: 6%;
  left: 32%;
  font-size: 1.4rem;
  color: #d9a92e;
  animation-delay: -2s;
}
.game-card__twister {
  position: absolute;
  top: 8%;
  right: 12%;
  z-index: 1;
  font-size: 2.7rem;
  animation: twirl 3.6s linear infinite;
}
.game-card__ball {
  position: relative;
  z-index: 1;
  font-size: 3.4rem;
  line-height: 1;
  animation: ballBob 2s ease-in-out infinite;
}
.game-card__hoop {
  position: absolute;
  right: 14%;
  top: 22%;
  width: 54px;
  height: 8px;
  border: 3px solid #b85c1d;
  border-radius: 999px;
  background: #e0782b;
  transform: rotate(-6deg);
}
.game-card__hoop::before {
  content: '';
  position: absolute;
  left: -5px;
  top: -30px;
  width: 36px;
  height: 27px;
  border: 3px solid #cbbfa9;
  border-radius: 4px;
  background: #fffdf6;
}
.game-card__timer {
  position: absolute;
  left: 12%;
  bottom: 16%;
  z-index: 1;
  padding: 4px 9px;
  border-radius: 8px;
  background: #fff3c9;
  color: #78570d;
  font-size: 0.72rem;
  font-weight: 900;
}
.storm-mini {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
  width: min(100%, 260px);
}
.storm-mini__letter,
.storm-mini__gap {
  display: grid;
  place-items: center;
  height: 44px;
  border-radius: 10px;
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 800;
}
.storm-mini__letter {
  border: 2px solid #d9cfb8;
  background: #fffdf4;
  color: var(--ink);
}
.storm-mini__gap {
  border: 2px dashed #cbbfa4;
  background: #f0ead9;
  color: #a89a7f;
}
.games-note {
  margin-top: 28px;
}

/* ---------- Buchstaben-Sturm: Spiel ---------- */

.storm-panel {
  overflow: hidden;
}
.storm-stage {
  display: flex;
  flex-direction: column;
  gap: 18px;
  margin: 8px 0 24px;
}
.storm-board {
  display: grid;
  grid-template-columns: repeat(13, minmax(0, 1fr));
  gap: 6px;
}
.storm-slot {
  display: grid;
  place-items: center;
  aspect-ratio: 0.82;
  border: 2px solid #ded3bd;
  border-radius: 10px;
  background: #fffcf2;
  color: var(--ink);
  font-family: var(--font-display);
  font-size: clamp(0.78rem, 1.8vw, 1.15rem);
  font-weight: 800;
  line-height: 1;
}
.storm-slot.is-filled {
  border-color: #8cc47b;
  background: #e6f5dd;
  color: var(--green-deep);
  animation: popIn 0.3s var(--ease-pop);
}
.storm-slot.is-empty {
  border: 2px dashed #cbbfa4;
  background: #f7f1e2;
  color: #b5a88e;
}
.storm-slot.is-empty.is-current {
  border-color: #d9a92e;
  background: #fff0b5;
  color: #78570d;
  animation: notePulse 1.5s ease-in-out infinite;
}
.storm-tray {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
}
.storm-tile {
  display: grid;
  place-items: center;
  width: clamp(54px, 8vw, 72px);
  height: clamp(60px, 9vw, 80px);
  border: 2.5px solid #2e7269;
  border-radius: 16px;
  background: #fffdf6;
  color: #1f5f56;
  font-family: var(--font-display);
  font-size: clamp(1.6rem, 4vw, 2.3rem);
  font-weight: 800;
  line-height: 1;
  cursor: pointer;
  box-shadow: 0 5px 0 #27645b;
  transition: transform 0.15s ease, background 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
  -webkit-tap-highlight-color: transparent;
}
.storm-tile:hover {
  transform: translateY(-2px);
}
.storm-tile:active {
  transform: translateY(3px);
  box-shadow: 0 1px 0 #27645b;
}
.storm-tile.is-correct {
  border-color: var(--green-dark);
  background: #dff3d5;
  color: var(--green-deep);
  transform: scale(0.9);
  box-shadow: 0 4px 0 rgba(63, 143, 99, 0.2);
}
.storm-tile.is-wrong {
  border-color: var(--coral);
  background: var(--coral-soft);
  color: #963d24;
  animation: shake 0.4s ease;
}
.storm-fly {
  position: absolute;
  z-index: 5;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border: 2.5px solid var(--green-dark);
  border-radius: 12px;
  background: #dff3d5;
  color: var(--green-deep);
  font-family: var(--font-display);
  font-size: 1.4rem;
  font-weight: 800;
  line-height: 1;
  pointer-events: none;
  box-shadow: 0 8px 16px -8px rgba(35, 60, 48, 0.4);
  transition: transform 0.5s cubic-bezier(0.5, 0, 0.2, 1);
}
.storm-result {
  text-align: center;
}
.storm-result__badge {
  margin: 2px auto 8px;
  font-size: 4.2rem;
  line-height: 1;
  animation: twirl 4.5s linear infinite;
}
.storm-result h1 {
  margin: 12px 0 8px;
  font-size: clamp(1.9rem, 4vw, 2.8rem);
}
.storm-result__lead {
  max-width: 46ch;
  margin: 0 auto 16px;
  color: var(--ink-soft);
  font-size: 1rem;
}
.storm-result__letters {
  display: flex;
  justify-content: center;
  gap: 8px;
}
.storm-result__letters span {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 11px;
  background: #fffdf4;
  border: 2px solid #d9cfb8;
  color: var(--ink);
  font-family: var(--font-display);
  font-weight: 800;
}
.storm-result__letters span:nth-child(2) {
  border-style: dashed;
  background: #f0ead9;
  color: #a89a7f;
}
.storm-result__letters span:last-child {
  border-color: #8cc47b;
  background: #e6f5dd;
  color: var(--green-deep);
}
.storm-result__actions {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 22px;
}

@keyframes twirl {
  0% { transform: rotate(0deg) scale(1); }
  50% { transform: rotate(12deg) scale(1.08); }
  100% { transform: rotate(0deg) scale(1); }
}

/* ---------- Buchstaben-Basketball ---------- */

.basket-panel {
  overflow: hidden;
}
.basket-scoreboard {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin: 2px 0 10px;
  font-size: 0.95rem;
  font-weight: 900;
}
.basket-score strong {
  font-family: var(--font-display);
  font-size: 1.3rem;
}
.basket-score--you strong {
  color: var(--green-dark);
}
.basket-score--rexi strong {
  color: var(--coral-dark);
}
.basket-vs {
  color: var(--ink-faint);
  font-size: 1.4rem;
}
.basket-timer {
  position: relative;
  height: 26px;
  margin-bottom: 14px;
  border: 2px solid var(--line-strong);
  border-radius: 999px;
  background: #f4eee0;
  overflow: hidden;
}
.basket-timer > span {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, #f0b429, #e0782b);
  border-radius: 999px;
  transition: width 0.1s linear;
}
.basket-timer b {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: #5b4208;
  font-size: 0.78rem;
  font-weight: 900;
}
.basket-court {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  min-height: 180px;
  margin: 10px 0 18px;
  padding: 16px;
  border: 1.5px dashed #d9cdb4;
  border-radius: 22px;
  background: linear-gradient(#fdf3dc, #eef6e5);
}
.basket-hoop {
  position: relative;
  flex: 0 0 auto;
  width: 80px;
  height: 112px;
}
.basket-backboard {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 54px;
  height: 40px;
  border: 3px solid #cbbfa9;
  border-radius: 6px;
  background: #fffdf6;
}
.basket-ring {
  position: absolute;
  top: 42px;
  left: 50%;
  transform: translateX(-50%);
  width: 56px;
  height: 8px;
  border: 3px solid #b85c1d;
  border-radius: 999px;
  background: #e0782b;
}
.basket-visual {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 80px;
}
.basket-emoji {
  font-size: 3.6rem;
  line-height: 1;
}
.basket-word {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}
.basket-word__emoji {
  font-size: 2.4rem;
  line-height: 1;
}
.basket-word strong {
  font-family: var(--font-display);
  font-size: 1.8rem;
  letter-spacing: 0.04em;
}
.basket-letter {
  padding: 8px 22px;
  border: 3px solid #d9cfb8;
  border-radius: 18px;
  background: #fffdf6;
  color: var(--green-deep);
  font-family: var(--font-display);
  font-size: 3.4rem;
  font-weight: 800;
  line-height: 1;
  box-shadow: 0 6px 0 #d9cfb8;
}
.basket-rexi {
  flex: 0 0 auto;
  width: 84px;
  opacity: 0.95;
}
.basket-rexi svg {
  width: 100%;
  height: auto;
}
.basket-ball {
  position: absolute;
  bottom: 12px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 2.6rem;
  line-height: 1;
  transition: transform 0.5s cubic-bezier(0.5, 0, 0.2, 1);
}
.basket-ball.is-score {
  transform: translate(-50%, -90px) scale(0.7);
}
.basket-ball.is-miss {
  animation: ballMiss 0.6s ease;
}
.basket-choices {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
}
.basket-choice {
  display: grid;
  place-items: center;
  width: 76px;
  height: 76px;
  border: 2.5px solid #d9cfb8;
  border-radius: 18px;
  background: #fffdf6;
  color: var(--ink);
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 800;
  line-height: 1;
  cursor: pointer;
  box-shadow: 0 6px 0 #d9cfb8;
  transition: transform 0.15s ease, background 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
  -webkit-tap-highlight-color: transparent;
}
.basket-choice:hover {
  transform: translateY(-2px);
}
.basket-choice:active {
  transform: translateY(3px);
  box-shadow: 0 1px 0 #d9cfb8;
}
.basket-choice.is-correct {
  border-color: var(--green-dark);
  background: #dff3d5;
  color: var(--green-deep);
}
.basket-choice.is-wrong {
  border-color: var(--coral);
  background: var(--coral-soft);
  color: #963d24;
  animation: shake 0.4s ease;
}
.basket-result {
  text-align: center;
}
.basket-result__badge {
  margin: 2px auto 8px;
  font-size: 4rem;
  line-height: 1;
  animation: ballBob 2s ease-in-out infinite;
}
.basket-result h1 {
  margin: 12px 0 8px;
  font-size: clamp(1.9rem, 4vw, 2.8rem);
}
.basket-result__lead {
  max-width: 46ch;
  margin: 0 auto 14px;
  color: var(--ink-soft);
  font-size: 1rem;
}
.basket-result__score {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 14px;
  font-size: 1.05rem;
  font-weight: 900;
}
.basket-result__score strong {
  font-family: var(--font-display);
  font-size: 1.9rem;
}
.basket-result__score span:first-child strong {
  color: var(--green-dark);
}
.basket-result__score span:last-child strong {
  color: var(--coral-dark);
}
.basket-result__actions {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 22px;
}

@keyframes ballMiss {
  0% { transform: translate(-50%, 0) rotate(0deg); }
  100% { transform: translate(-50%, 60px) rotate(180deg); }
}
@keyframes ballBob {
  0%, 100% { transform: translateY(0) rotate(-4deg); }
  50% { transform: translateY(-8px) rotate(4deg); }
}

/* ---------- Responsive ---------- */

@media (max-width: 1120px) {
  .mission-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 1040px) {
  .hero {
    grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
    gap: 16px;
  }
  .hero__art {
    min-height: 420px;
  }
  .hero-svg {
    width: min(104%, 440px);
  }
  .dino-card {
    width: calc(50% - 10px);
  }
}

@media (max-width: 900px) {
  .hero {
    grid-template-columns: 1fr;
    min-height: 0;
    padding-top: 4px;
    gap: 8px;
  }
  .arcade-teaser {
    grid-template-columns: 1fr;
  }
  .piano-teaser {
    grid-template-columns: 1fr;
  }
  .hero__art {
    order: -1;
    min-height: 340px;
    margin: 0 auto;
    width: min(100%, 460px);
  }
  .hero-svg {
    width: min(92%, 380px);
  }
  .hero__halo {
    width: min(100%, 380px);
  }
  .hero__ring {
    width: min(80%, 330px);
  }
  .float-letter {
    width: 56px;
    height: 56px;
    font-size: 1.7rem;
    border-radius: 17px;
  }
  .float-letter--c {
    width: 48px;
    height: 48px;
    font-size: 1.45rem;
  }
  .hero__egg {
    width: 76px;
  }
  .hero__bubble {
    top: 3%;
    right: 2%;
    font-size: 0.92rem;
  }
  .hero h1 {
    font-size: clamp(2.4rem, 7vw, 3.7rem);
  }
  .hero__lead {
    font-size: 1.06rem;
  }
  .hero__stats {
    margin-top: 26px;
  }
  .mission-grid {
    grid-template-columns: 1fr;
  }
  .mission {
    padding: 22px;
  }
  .mission__chips {
    margin-top: 12px;
  }
  .fact-strip__dino {
    display: none;
  }
  .trail {
    padding-left: 0;
  }
  .trail::before {
    display: none;
  }
  .trail__row {
    margin-bottom: 18px;
  }
  .trail__marker {
    position: static;
    display: flex;
    align-items: center;
    width: 100%;
    height: auto;
    justify-content: flex-start;
    gap: 8px;
    margin-bottom: 8px;
    padding: 0;
    border: 0;
    background: none !important;
    box-shadow: none;
    color: var(--ink-soft);
    font-family: var(--font-body);
    font-size: 0.74rem;
    font-weight: 900;
    letter-spacing: 0.09em;
    text-transform: uppercase;
    animation: none;
  }
  .trail__marker::before {
    content: 'Level ' attr(data-level);
  }
  .trail__marker > span,
  .trail__marker .icon {
    display: none;
  }
  .trail__marker.is-done {
    color: var(--green-dark);
  }
  .trail__marker.is-current {
    color: #9a7113;
  }
  .trail__marker.is-locked {
    color: #a49a82;
  }
  .level-card {
    grid-template-columns: 1fr 150px;
    padding: 22px 20px 20px 24px;
  }
  .level-card__art {
    min-height: 150px;
  }
  .level-card__art .egg-svg {
    width: 82px;
  }
  .level-card__art .dino-svg {
    width: 148px;
  }
}

@media (max-width: 760px) {
  body {
    padding-bottom: 78px;
  }
  .topbar__inner {
    padding: 9px 16px;
    gap: 10px;
  }
  .topnav {
    display: none;
  }
  .brand__mark {
    width: 40px;
    height: 40px;
    border-radius: 14px;
  }
  .brand__text strong {
    font-size: 1.3rem;
  }
  .brand__text small {
    display: none;
  }
  .topbar__right {
    margin-left: auto;
  }
  .star-pill {
    min-height: 40px;
    padding: 5px 12px;
    font-size: 0.98rem;
  }
  .icon-btn {
    width: 42px;
    height: 42px;
  }
  #app {
    padding: 22px 16px 40px;
  }
  .mobile-nav {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 70;
    display: flex;
    align-items: stretch;
    justify-content: space-around;
    gap: 2px;
    padding: 7px 8px calc(7px + env(safe-area-inset-bottom));
    border-top: 1px solid rgba(35, 60, 48, 0.1);
    background: rgba(253, 248, 234, 0.94);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
  }
  .mobile-nav a,
  .mobile-nav button {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    flex: 1;
    min-width: 0;
    padding: 6px 2px 5px;
    border: 0;
    border-radius: 14px;
    background: transparent;
    color: var(--ink-faint);
    font-size: 0.61rem;
    font-weight: 900;
    text-decoration: none;
    cursor: pointer;
  }
  .mobile-nav .icon {
    width: 21px;
    height: 21px;
  }
  .trail__end {
    flex-wrap: wrap;
  }
  .trail__end-cta {
    width: 100%;
    margin-left: 0;
  }
  .arcade-teaser {
    padding: 22px;
  }
  .arcade-note {
    flex-wrap: wrap;
  }
  .arcade-note .btn {
    width: 100%;
    margin-left: 0;
  }
  .arcade-result__rexi {
    display: none;
  }
  .arcade-skill {
    display: none;
  }
  .piano-teaser {
    padding: 22px;
  }
  .piano-teaser__rexi {
    width: 82px;
  }
  .piano-teaser__art {
    min-height: 180px;
  }
  .piano-mini__key {
    height: 76px;
    border-top-width: 8px;
    font-size: 1.15rem;
  }
  .piano-keys {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 6px;
    padding: 10px;
    border-radius: 16px;
  }
  .piano-key {
    height: 96px;
    padding-bottom: 8px;
    border-top-width: 8px;
    border-radius: 0 0 11px 11px;
  }
  .piano-key__letter {
    font-size: 1.3rem;
  }
  .piano-key__dot {
    width: 5px;
    height: 5px;
    margin-top: 3px;
  }
  .piano-buddy {
    width: 64px;
  }
  .piano-note {
    width: 34px;
    height: 34px;
    border-radius: 10px;
    font-size: 1.05rem;
  }
  .piano-song__name {
    font-size: 1.04rem;
  }
  .piano-result__rexi {
    display: none;
  }
  .piano-result__badge {
    font-size: 3.4rem;
  }
  .game-card-grid {
    grid-template-columns: 1fr;
  }
  .game-card__art {
    min-height: 150px;
  }
  .storm-board {
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 5px;
  }
  .storm-slot {
    aspect-ratio: 0.9;
    border-radius: 8px;
    font-size: 0.82rem;
  }
  .storm-tile {
    width: 52px;
    height: 60px;
    border-radius: 13px;
    font-size: 1.6rem;
  }
  .memory-grid {
    gap: 8px;
    max-width: 400px;
  }
  .path-grid {
    max-width: 370px;
  }
  .path-cell {
    border-radius: 14px;
  }
  .arcade-picture {
    width: 112px;
  }
  .mobile-nav a.is-active {
    background: var(--green-soft);
    color: var(--green-dark);
  }
  .toast {
    bottom: 88px;
  }
  .site-footer {
    margin-top: 20px;
  }
  .site-footer__inner {
    padding: 20px 16px 24px;
  }
  .site-footer .link-btn {
    margin-left: 0;
  }
  .page-head {
    padding-top: 8px;
  }
  .map-progress {
    flex-wrap: wrap;
    margin-bottom: 28px;
    padding: 14px 16px;
    gap: 10px 12px;
  }
  .map-progress__text {
    width: auto;
    flex: 1 1 auto;
  }
  .map-progress__stars {
    order: 2;
    margin-left: auto;
  }
  .map-progress .progress-track {
    order: 3;
    flex: 1 1 100%;
    min-width: 0;
  }
  .level-card {
    grid-template-columns: 1fr;
    padding: 22px 20px;
  }
  .level-card__art {
    grid-row: 1;
    min-height: 150px;
  }
  .level-card__art .dino-svg {
    width: 168px;
  }
  .level-card__body {
    grid-row: 2;
  }
  .level-card__cta {
    margin-left: 0;
  }
  .level-card__footer {
    gap: 12px;
  }
  .dino-card {
    width: 100%;
    max-width: 460px;
  }
  .section {
    margin-top: 46px;
  }
  .section__head {
    display: block;
  }
  .section__head .btn {
    margin-top: 14px;
  }
  .task-feedback {
    flex-wrap: wrap;
  }
  .task-feedback__rexi,
  .feedback-icon {
    width: 42px;
    height: 42px;
  }
  .task-feedback__rexi svg {
    width: 42px;
  }
  .feedback-actions {
    width: 100%;
    margin: 4px 0 0;
  }
  .feedback-actions .btn {
    width: 100%;
  }
  .word-choice-grid {
    grid-template-columns: 1fr;
  }
  .word-choice-grid .word-card {
    flex-direction: row;
    justify-content: flex-start;
    min-height: 74px;
    padding: 12px 16px;
    text-align: left;
  }
  .word-choice-grid .word-card__emoji {
    font-size: 1.8rem;
  }
  .parent-grid {
    grid-template-columns: 1fr;
  }
  .modal-backdrop {
    padding: 10px;
    align-items: start;
  }
  .modal {
    max-height: calc(100vh - 20px);
    margin: auto;
    border-radius: 26px;
    padding: 24px 20px;
  }
  .hatch__stage {
    min-height: 240px;
  }
  .hatch__egg-helper {
    right: 6%;
  }
  .hatch__fact {
    font-size: 0.86rem;
  }
  .dino-grid {
    gap: 14px;
  }
}

@media (max-width: 540px) {
  .hero__art {
    min-height: 258px;
  }
  .hero-svg {
    width: min(84%, 286px);
  }
  .hero__halo {
    width: min(100%, 286px);
  }
  .hero__ring {
    width: min(76%, 250px);
  }
  .hero__bubble {
    top: 0;
    right: 0;
    padding: 9px 12px;
    font-size: 0.82rem;
    border-radius: 16px 16px 16px 5px;
  }
  .float-letter {
    width: 46px;
    height: 46px;
    font-size: 1.45rem;
    border-radius: 14px;
    border-width: 1.5px;
  }
  .float-letter--a { top: 4%; left: 0; }
  .float-letter--b { top: 14%; right: 0; }
  .float-letter--c { display: none; }
  .hero__egg {
    width: 62px;
    right: 1%;
    bottom: 2%;
  }
  .hero__copy > .eyebrow {
    display: none;
  }
  .hero h1 {
    margin: 10px 0 12px;
    font-size: clamp(1.98rem, 8.4vw, 2.65rem);
  }
  .hero__lead {
    font-size: 0.97rem;
    line-height: 1.5;
    margin-bottom: 18px;
  }
  .hero__note {
    display: none;
  }
  .hero__actions .btn {
    flex: 1 1 100%;
  }
  .hero__actions .btn--secondary {
    display: none;
  }
  .sort-pool {
    gap: 8px;
  }
  .sort-letter {
    width: 54px;
    min-width: 54px;
    border-radius: 16px;
    font-size: 2rem;
  }
  .hero__stats {
    gap: 8px;
  }
  .stat {
    flex: 1 1 calc(50% - 4px);
    min-width: 0;
    padding: 8px 10px;
  }
  .stat__icon {
    width: 32px;
    height: 32px;
    border-radius: 10px;
  }
  .stat__icon .icon {
    width: 18px;
    height: 18px;
  }
  .stat strong {
    font-size: 1.06rem;
  }
  .stat span {
    font-size: 0.66rem;
  }
  .fact-strip {
    align-items: flex-start;
    gap: 14px;
    padding: 18px;
  }
  .fact-strip__egg {
    width: 48px;
  }
  .fact-strip p {
    font-size: 0.92rem;
  }
  .map-progress__text {
    font-size: 0.85rem;
  }
  .map-progress__stars {
    font-size: 0.82rem;
  }
  .level-card {
    border-radius: 24px;
    padding: 20px 16px;
  }
  .level-card__art {
    min-height: 130px;
  }
  .level-card__art .dino-svg {
    width: 146px;
  }
  .level-card__info {
    width: 100%;
    gap: 10px;
  }
  .level-card__cta {
    width: 100%;
  }
  .level-card__cta .btn {
    width: 100%;
  }
  .game__bar {
    gap: 8px;
  }
  .game__progress {
    gap: 8px;
  }
  .game__steps {
    gap: 4px;
  }
  .step {
    width: 19px;
    height: 19px;
    border-width: 1.5px;
  }
  .step::after {
    width: 5px;
    height: 5px;
  }
  .game__count {
    font-size: 0.7rem;
  }
  .task-card {
    border-radius: 26px;
  }
  .task-card__tools .ghost-btn span {
    display: none;
  }
  .task-card__tools .ghost-btn {
    padding: 8px 10px;
  }
  .order-slot {
    min-width: 44px;
    height: 46px;
    padding: 0 7px;
    font-size: 0.95rem;
    border-radius: 12px;
  }
  .arcade-result__actions .btn {
    flex: 1 1 100%;
  }
  .arcade-result__medal {
    width: 116px;
    height: 116px;
  }
  .task-card__tools {
    width: 100%;
    justify-content: flex-start;
  }
  .speak-btn {
    flex: 1;
    min-height: 50px;
    padding: 10px 14px;
    font-size: 1rem;
  }
  .speak-btn .icon {
    width: 22px;
    height: 22px;
  }
  .hint-btn {
    flex: 1;
    min-height: 50px;
    padding: 10px 14px;
    font-size: 1rem;
  }
  .hint-btn .icon {
    width: 22px;
    height: 22px;
  }
  .piano-stage__top {
    gap: 10px;
  }
  .piano-buddy {
    width: 54px;
  }
  .piano-key {
    height: 78px;
  }
  .piano-stage {
    gap: 12px;
  }
  .piano-song__hint {
    display: none;
  }
  .piano-result__actions .btn {
    flex: 1 1 100%;
  }
  .piano-teaser__art {
    min-height: 160px;
  }
  .piano-mini {
    width: 100%;
  }
  .game-card__art {
    min-height: 132px;
  }
  .storm-tile {
    width: 46px;
    height: 54px;
    border-radius: 12px;
    font-size: 1.45rem;
  }
  .storm-slot {
    font-size: 0.72rem;
  }
  .storm-result__badge {
    font-size: 3.4rem;
  }
  .basket-court {
    flex-direction: column;
    min-height: 150px;
    padding: 12px;
  }
  .basket-hoop {
    position: absolute;
    top: 10px;
    right: 14px;
    width: 62px;
    height: 80px;
  }
  .basket-rexi {
    position: absolute;
    bottom: 10px;
    left: 12px;
    width: 60px;
  }
  .basket-ball {
    bottom: 8px;
  }
  .basket-choice {
    width: 64px;
    height: 64px;
    border-radius: 15px;
    font-size: 1.7rem;
  }
  .basket-emoji {
    font-size: 2.9rem;
  }
  .basket-word strong {
    font-size: 1.5rem;
  }
  .basket-letter {
    font-size: 2.6rem;
    padding: 6px 18px;
  }
  .basket-result__badge {
    font-size: 3.4rem;
  }
  .basket-result__actions .btn {
    flex: 1 1 100%;
  }
  .arcade-result__medal > span {
    font-size: 2.6rem;
  }
  .build-slot {
    width: 42px;
    height: 48px;
    border-radius: 11px;
    font-size: 1.35rem;
  }
  .memory-card {
    border-radius: 14px;
  }
  .memory-card__back,
  .memory-card__front {
    border-radius: 14px;
  }
  .path-prompt {
    font-size: 0.98rem;
    padding: 7px 13px;
  }
  .path-grid {
    gap: 6px;
  }
  .path-legend {
    gap: 8px;
    font-size: 0.66rem;
  }
  .order-slot.is-filled {
    font-size: 1.3rem;
  }
  .order-slot.is-filled.word-slot {
    font-size: 0.82rem;
  }
  .word-grid {
    gap: 8px;
  }
  .word-card {
    min-height: 66px;
    padding: 10px 12px;
    gap: 8px;
    border-radius: 16px;
  }
  .word-card__emoji {
    font-size: 1.45rem;
  }
  .word-card__badge {
    width: 23px;
    height: 23px;
    font-size: 0.8rem;
  }
  .answer-btn {
    border-radius: 18px;
    min-height: 78px;
    padding: 10px 16px;
  }
  .answer-btn--letter {
    min-width: 0;
    flex: 1 1 calc(50% - 5px);
    max-width: 130px;
    min-height: 92px;
  }
  .answer-btn--number {
    flex: 1 1 calc(50% - 5px);
    min-width: 0;
    max-width: 140px;
    font-size: 1.7rem;
  }
  .pair-grid {
    gap: 7px;
  }
  .pair-card {
    border-radius: 14px;
    font-size: 1.8rem;
  }
  .beforeafter {
    gap: 8px;
  }
  .direction-bubble__icon {
    width: 52px;
    height: 52px;
    font-size: 1.6rem;
  }
  .initial-word {
    font-size: 1.4rem;
  }
  .trail__end {
    padding: 16px;
  }
  .collection-count {
    width: 100%;
    justify-content: space-between;
  }
  .dino-card__art {
    height: 170px;
  }
  .dino-card__art .dino-svg {
    width: 195px;
  }
  .hatch__actions .btn {
    flex: 1 1 100%;
  }
  .parent-card {
    padding: 15px;
  }
  .name-form {
    flex-wrap: wrap;
  }
  .name-form .btn {
    width: 100%;
  }
  .setting-row {
    gap: 12px;
  }
}

@media (max-width: 380px) {
  .mobile-nav a,
  .mobile-nav button {
    font-size: 0.56rem;
  }
  .mobile-nav .icon {
    width: 19px;
    height: 19px;
  }
  .brand__text strong {
    font-size: 1.12rem;
  }
  .brand__mark {
    width: 36px;
    height: 36px;
  }
  .star-pill {
    padding: 5px 9px;
    gap: 4px;
  }
  .hero h1 {
    font-size: 2.05rem;
  }
  .level-card__art {
    display: none;
  }
  .order-slot {
    min-width: 38px;
    height: 42px;
    font-size: 0.9rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  .confetti {
    display: none;
  }
}
