

.cookie-canvas {
  outline: none;
}


.cookie-canvas:focus-visible {
  outline: 4px solid var(--gold);
  outline-offset: 4px;
}


/* ==================== MEMORY GAME ==================== */
.memory-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
  max-width: 500px;
  margin: 0 auto;
}


.memory-card {
  aspect-ratio: 1;
  border-radius: 15px;
  cursor: pointer;
  position: relative;
  perspective: 600px;
  min-height: 80px;
}


.memory-card-inner {
  width: 100%;
  height: 100%;
  transition: transform 0.5s ease;
  -webkit-transform-style: preserve-3d;
  transform-style: preserve-3d;
  border-radius: 15px;
}


.memory-card.flipped .memory-card-inner {
  transform: rotateY(180deg);
}


.memory-card-front, .memory-card-back {
  position: absolute;
  width: 100%;
  height: 100%;
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
  border-radius: 15px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.5rem;
}


.memory-card-front {
  background: linear-gradient(135deg, var(--red), var(--red-dark));
  color: white;
  box-shadow: 0 4px 10px var(--shadow);
}


.memory-card-back {
  background: linear-gradient(135deg, var(--cream), white);
  transform: rotateY(180deg);
  border: 3px solid var(--gold);
  box-shadow: 0 4px 10px var(--shadow);
}


.memory-card.matched .memory-card-inner {
  transform: rotateY(180deg);
}


.memory-card.matched .memory-card-back {
  background: linear-gradient(135deg, #C8E6C9, #A5D6A7);
  border-color: var(--green);
}


/* ==================== ADVENT CALENDAR ==================== */
.advent-status {
  text-align: center;
  margin-bottom: 1.25rem;
  font-family: 'Fredoka One', cursive;
  font-size: 1.15rem;
  color: var(--red);
}


.advent-today {
  display: block;
  margin-top: 0.25rem;
  font-size: 0.95rem;
  color: var(--green);
}


.advent-door.locked .advent-door-front {
  animation: advent-shake 0.4s ease;
}


.advent-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 1rem;
  max-width: 760px;
  margin: 0 auto;
}


.advent-door {
  max-height: 210px;
  min-height: 130px;
  aspect-ratio: 3 / 4;
  border-radius: 15px;
  cursor: pointer;
  position: relative;
  perspective: 900px;
  background: none;
  border: none;
  padding: 0;
}


.advent-door-picture {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border-radius: 15px;
  background: linear-gradient(135deg, var(--cream), white);
  border: 3px solid var(--gold);
  box-shadow: 0 4px 12px var(--shadow);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  padding: 0.4rem;
  text-align: center;
  overflow: hidden;
}


.advent-picture {
  font-size: 2.8rem;
  line-height: 1.1;
  text-shadow: 0 3px 6px rgba(0,0,0,0.12);
}


.advent-picture-name {
  font-family: 'Fredoka One', cursive;
  font-size: 0.72rem;
  line-height: 1.15;
  color: var(--red);
}


.advent-door-front {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  transform-origin: bottom center;
  transition: transform 0.7s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  border-radius: 15px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.2rem;
  background: linear-gradient(135deg, var(--red), var(--red-dark));
  color: white;
  box-shadow: 0 4px 12px var(--shadow);
  border: 3px solid rgba(255,255,255,0.35);
  z-index: 2;
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
}


.advent-door-green .advent-door-front {
  background: linear-gradient(135deg, var(--green), #1E6B4E);
}


.advent-door-gold .advent-door-front {
  background: linear-gradient(135deg, var(--gold-dark), #B8860B);
}


.advent-door-sky .advent-door-front {
  background: linear-gradient(135deg, #4A90D9, #2A5FA8);
}


.advent-door.open .advent-door-front {
  transform: rotateX(100deg);
}


.advent-door-front::after {
  content: '';
  position: absolute;
  left: 50%;
  top: 0;
  bottom: 0;
  width: 1px;
  background: rgba(255,255,255,0.12);
}


.advent-door-wreath {
  position: relative;
  width: 30px;
  height: 30px;
  margin-bottom: 0.15rem;
}


.advent-door-wreath::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 7px solid #2E8B57;
  box-shadow: 0 2px 4px rgba(0,0,0,0.3);
}


.advent-wreath-berry {
  position: absolute;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--red);
  box-shadow: 0 1px 1px rgba(0,0,0,0.35);
  z-index: 1;
}


.advent-wreath-berry.b1 { top: 1px; left: 50%; transform: translateX(-50%); }

.advent-wreath-berry.b2 { right: 1px; top: 50%; transform: translateY(-50%); }

.advent-wreath-berry.b3 { bottom: 1px; left: 50%; transform: translateX(-50%); }

.advent-wreath-berry.b4 { left: 1px; top: 50%; transform: translateY(-50%); }


.advent-door-day {
  font-family: 'Fredoka One', cursive;
  font-size: 2.3rem;
  line-height: 1;
  text-shadow: 1px 1px 0 rgba(0,0,0,0.25);
}


.advent-door-knob {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: rgba(255,255,255,0.85);
  box-shadow: 0 2px 4px rgba(0,0,0,0.3);
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
}


/* ==================== COOKIE DECORATOR ==================== */
.cookie-canvas-wrapper {
  text-align: center;
}


.cookie-canvas {
  border: 4px solid var(--brown);
  border-radius: 20px;
  background: #D2B48C;
  cursor: crosshair;
  touch-action: none;
  width: 100%;
  max-width: 600px;
  height: auto;
  aspect-ratio: 3 / 2;
  box-shadow: 0 4px 15px rgba(0,0,0,0.15);
}


/* ==================== SORTING GAME ==================== */
.sorting-game {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  width: 100%;
}


/* ==================== SANTA ROUTE ==================== */
.route-map {
  position: relative;
  width: 100%;
  height: 400px;
  background: linear-gradient(180deg, #1a237e 0%, #283593 30%, #1565C0 70%, white 70%, #E3F2FD 100%);
  border-radius: 20px;
  overflow: hidden;
  border: 4px solid var(--brown);
}


.route-point {
  position: absolute;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  cursor: pointer;
  transition: transform 0.3s ease;
  z-index: 2;
}


.route-point:hover {
  transform: scale(1.2);
}


.route-point.active {
  box-shadow: 0 0 0 4px var(--gold), 0 0 20px rgba(255,215,0,0.5);
  animation: pulse 1.5s infinite;
}


.route-point.correct {
  background: var(--green) !important;
}


.route-point.wrong {
  background: var(--red) !important;
  animation: shake 0.5s ease;
}


/* ==================== STORY BUILDER ==================== */
.story-container {
  text-align: center;
}


.story-illustration {
  font-size: 5rem;
  margin: 1rem 0;
}


.story-text {
  font-size: 1.2rem;
  line-height: 1.8;
  color: var(--text-dark);
  max-width: 600px;
  margin: 0 auto 1.5rem;
  padding: 1.5rem;
  background: var(--cream);
  border-radius: 15px;
  border-left: 5px solid var(--gold);
}


.story-choices {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
}


.story-choice {
  padding: 1rem 2rem;
  border-radius: 15px;
  border: 3px solid var(--red);
  background: white;
  cursor: pointer;
  font-family: 'Fredoka One', cursive;
  font-size: 1rem;
  color: var(--red);
  transition: all 0.3s ease;
  max-width: 250px;
}


.story-choice:hover {
  background: var(--red);
  color: white;
  transform: translateY(-3px);
}


/* ==================== QUIZ ==================== */
.quiz-container {
  max-width: 600px;
  margin: 0 auto;
}


.quiz-question {
  font-size: 1.3rem;
  text-align: center;
  margin-bottom: 1.5rem;
  color: var(--brown);
}


.quiz-image {
  text-align: center;
  font-size: 5rem;
  margin-bottom: 1rem;
}


.quiz-feedback {
  text-align: center;
  font-family: 'Fredoka One', cursive;
  font-size: 1.2rem;
  color: var(--red);
  background: var(--cream);
  border-radius: 15px;
  border-left: 5px solid var(--gold);
  padding: 1rem;
  margin-top: 1.5rem;
}


.quiz-options {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}


.quiz-option {
  padding: 1rem;
  border-radius: 15px;
  border: 3px solid var(--cream-dark);
  background: white;
  cursor: pointer;
  font-weight: 700;
  font-size: 1.1rem;
  transition: all 0.3s ease;
  text-align: center;
}


.quiz-option:hover {
  border-color: var(--red);
  transform: scale(1.03);
}


.quiz-option.correct {
  border-color: var(--green);
  background: #E8F5E9;
}


.quiz-option.wrong {
  border-color: var(--red);
  background: #FFEBEE;
}


.quiz-progress {
  width: 100%;
  height: 12px;
  background: var(--cream-dark);
  border-radius: 10px;
  margin-bottom: 1.5rem;
  overflow: hidden;
}


.quiz-progress-bar {
  height: 100%;
  background: linear-gradient(90deg, var(--green), var(--gold));
  border-radius: 10px;
  transition: width 0.5s ease;
}


/* ==================== ADVENT LOCKED POPUP ==================== */
.advent-locked-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100vh;
  height: 100dvh;
  min-height: 100vh;
  min-height: 100dvh;
  background: rgba(0,0,0,0.55);
  z-index: 10001;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
  box-sizing: border-box;
  padding: 1.5rem;
}


.advent-locked-overlay.show {
  opacity: 1;
  pointer-events: all;
}


.advent-locked-popup {
  background: linear-gradient(135deg, #FFF8E1, white);
  border-radius: 25px;
  padding: 2rem 1.75rem;
  text-align: center;
  box-shadow: 0 15px 50px rgba(0,0,0,0.35);
  border: 4px solid var(--gold);
  max-width: 360px;
  width: 88%;
  position: relative;
  margin: auto;
  transform: scale(0);
  transition: transform 0.45s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}


.advent-locked-overlay.show .advent-locked-popup {
  transform: scale(1);
}


.advent-locked-close {
  position: absolute;
  top: 10px;
  right: 14px;
  background: none;
  border: none;
  font-size: 1.8rem;
  line-height: 1;
  color: var(--brown);
  cursor: pointer;
  padding: 0;
}


.advent-locked-icon {
  font-size: 4rem;
  line-height: 1;
  margin-bottom: 0.75rem;
  filter: drop-shadow(0 2px 4px rgba(0,0,0,0.2));
}


.advent-locked-text {
  font-family: 'Fredoka One', cursive;
  font-size: 1.15rem;
  line-height: 1.45;
  color: var(--red);
  margin-bottom: 1.25rem;
}


.advent-locked-button {
  display: inline-block;
  background: linear-gradient(135deg, var(--green), #1E6B4E);
  color: white;
  font-family: 'Fredoka One', cursive;
  font-size: 1.1rem;
  padding: 0.6rem 2rem;
  border-radius: 50px;
  border: none;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(0,0,0,0.25);
}


.advent-locked-button:hover {
  filter: brightness(1.1);
}


/* ==================== TOUCH IMPROVEMENTS ==================== */
button, a, .memory-card, .advent-door, .sort-item, .route-point, .quiz-option, .story-choice, .color-swatch, .brush-size, select, input {
  touch-action: manipulation;
  -webkit-tap-highlight-color: rgba(255,215,0,0.35);
}


  .route-point {
    width: 55px;
    height: 55px;
    font-size: 1.7rem;
  }


  .memory-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 0.75rem;
    max-width: 100%;
  }


  .advent-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 0.65rem;
  }


  .advent-door-day {
    font-size: 1.6rem;
  }


  .advent-door-wreath {
    width: 22px;
    height: 22px;
    border-width: 5px;
  }


  .advent-door-wreath::before {
    border-width: 5px;
  }


  .advent-wreath-berry {
    width: 4px;
    height: 4px;
  }


  .advent-picture {
    font-size: 1.9rem;
  }


  .advent-picture-name {
    font-size: 0.6rem;
  }


  .advent-door-knob {
    width: 10px;
    height: 10px;
    right: 8px;
  }


  .quiz-options {
    grid-template-columns: 1fr;
  }


  .route-map {
    height: 320px;
  }


  .route-point {
    width: 60px;
    height: 60px;
    font-size: 1.8rem;
  }


  .story-text {
    font-size: 1.05rem;
    padding: 1.1rem;
  }


.memory-grid {
    grid-template-columns: repeat(3, 1fr);
  }


  .advent-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 0.5rem;
  }


  .advent-door-day {
    font-size: 1.35rem;
  }


  .advent-door-wreath {
    width: 18px;
    height: 18px;
  }


  .advent-door-wreath::before {
    border-width: 4px;
  }


  .advent-wreath-berry {
    width: 3px;
    height: 3px;
  }


  .advent-picture {
    font-size: 1.5rem;
  }


  .advent-picture-name {
    font-size: 0.52rem;
  }


  .advent-door-knob {
    width: 8px;
    height: 8px;
    right: 6px;
  }


  .memory-card {
    min-height: 65px;
  }


  .memory-card-front, .memory-card-back {
    font-size: 1.8rem;
  }


  .route-map {
    height: 280px;
  }


  .route-point {
    width: 52px;
    height: 52px;
    font-size: 1.5rem;
  }


  .story-choice {
    max-width: 100%;
    width: 100%;
    padding: 1rem;
  }


  .story-choices {
    flex-direction: column;
    gap: 0.6rem;
  }


  .quiz-image {
    font-size: 3.5rem;
  }


  .quiz-question {
    font-size: 1.1rem;
  }


  .cookie-canvas {
    border-radius: 15px;
  }


  .advent-grid {
    grid-template-columns: repeat(2, 1fr);
  }


  .advent-door-day {
    font-size: 1.2rem;
  }


  .advent-door-wreath {
    width: 16px;
    height: 16px;
  }


  .advent-door-wreath::before {
    border-width: 4px;
  }


  .advent-wreath-berry {
    width: 3px;
    height: 3px;
  }


  .advent-picture {
    font-size: 1.3rem;
  }


  .advent-picture-name {
    font-size: 0.48rem;
  }


  .memory-card-front, .memory-card-back {
    font-size: 1.5rem;
  }


  .route-point {
    width: 46px;
    height: 46px;
    font-size: 1.3rem;
  }


/* ==================== SLEIGH LOAD PHYSICS ==================== */
.sleigh-stage {
  position: relative;
  width: 100%;
  max-width: 720px;
  height: 340px;
  min-height: 340px;
  height: clamp(300px, 54vh, 440px);
  margin: 0 auto;
  background: linear-gradient(180deg, #4FC3F7 0%, #81D4FA 34%, #B3E5FC 42%, #6d4c26 42%, #5d3f1c 100%);
  border-radius: 28px;
  overflow: hidden;
  touch-action: manipulation;
}


.sleigh-belt {
  position: absolute;
  left: 0;
  right: 0;
  top: 56%;
  height: 30px;
  background: repeating-linear-gradient(90deg, #7b6a57 0 16px, #635241 16px 32px);
  border-top: 4px solid #9c876f;
  border-bottom: 4px solid #4d3e30;
  box-shadow: 0 2px 8px rgba(0,0,0,0.25);
}


.sleigh-sack {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  bottom: 0;
  width: 36%;
  height: 48%;
  background: #C62828;
  border: 4px solid #8E1D1D;
  border-top: none;
  border-radius: 0 0 50% 50% / 0 0 100% 100%;
  box-shadow: inset 0 20px 40px rgba(0,0,0,0.25), 0 4px 14px rgba(0,0,0,0.35);
  z-index: 2;
}


.sleigh-sack::before {
  content: '';
  position: absolute;
  top: -12px;
  left: -6px;
  right: -6px;
  height: 24px;
  background: white;
  border-radius: 50%;
  border: 3px solid #8E1D1D;
}


.sleigh-sack-fill {
  position: absolute;
  bottom: calc(100% - 10px);
  left: 50%;
  transform: translateX(-50%);
  font-size: 22px;
  white-space: nowrap;
  display: flex;
  gap: 2px;
  pointer-events: none;
  z-index: 3;
}


.sleigh-sack-fill > span {
  display: inline-block;
  animation: sleighPopIn .3s ease-out forwards;
}


.sleigh-sack--wiggle {
  animation: sleighWiggle 0.35s ease-in-out;
}


.sleigh-toy {
  position: absolute;
  top: 52%;
  transform: translate(-50%, -50%);
  font-size: 58px;
  z-index: 5;
  visibility: hidden;
  will-change: left, top, transform;
}


.sleigh-controls {
  text-align: center;
  margin-top: 1.4rem;
}


.sleigh-drop-btn {
  width: 150px;
  height: 150px;
  font-size: 1.6rem;
  width: clamp(110px, 28vw, 160px);
  height: clamp(110px, 28vw, 160px);
  font-size: clamp(1.4rem, 4.5vw, 1.8rem);
  border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #EF5350, #B71C1C 72%);
  color: white;
  font-weight: 900;
  font-family: 'Fredoka One', cursive, sans-serif;
  border: 6px solid #7B1616;
  box-shadow: 0 8px 0 #6a1212, 0 14px 24px rgba(0,0,0,0.3);
  cursor: pointer;
  touch-action: manipulation;
  user-select: none;
  -webkit-user-select: none;
  outline: none;
}


.sleigh-drop-btn:focus-visible {
  box-shadow: 0 0 0 4px white, 0 0 0 7px #1976D2, 0 8px 0 #6a1212, 0 14px 24px rgba(0,0,0,0.3);
}


.sleigh-drop-btn:active {
  transform: translateY(6px);
  box-shadow: 0 0 0 #6a1212, 0 2px 6px rgba(0,0,0,0.3);
}


.sleigh-bubble {
  position: absolute;
  transform: translate(-50%, -50%);
  background: white;
  border: 2px solid #5D4037;
  border-radius: 50%;
  padding: 0.4rem 0.7rem;
  font-size: 1rem;
  font-weight: 700;
  color: #5D4037;
  pointer-events: none;
  z-index: 20;
  opacity: 0;
  animation: sleighBubbleUp .85s ease-out forwards;
}


.sleigh-spark {
  position: absolute;
  font-size: 1.4rem;
  pointer-events: none;
  z-index: 20;
  opacity: 1;
  animation: sleighSpark .6s ease-out forwards;
}


/* ===== Magic Snow Globe ===== */
.globe-game-area {
  max-width: 560px;
  margin: 0 auto;
}


.globe-shake {
  position: relative;
  width: 90vw;
  max-width: 420px;
  margin: 0 auto 0.25rem;
  cursor: pointer;
  touch-action: manipulation;
  user-select: none;
  -webkit-user-select: none;
}

.globe-shake:focus-visible {
  outline: 3px dashed #C62828;
  outline-offset: 6px;
  border-radius: 50%;
}


.globe-scene {
  position: absolute;
  inset: 0;
  z-index: 1;
}

.globe-scene::before {
  content: '';
  position: absolute;
  left: -25%;
  right: -25%;
  bottom: -42%;
  height: 70%;
  background: radial-gradient(ellipse at 50% 100%, #FFFFFF 25%, #D9F1FC 62%, rgba(217,241,252,0) 70%);
  z-index: 1;
}


.globe-snow {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
  z-index: 3;
}


.globe-bg {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
  z-index: 1;
}


.globe-house {
  position: absolute;
  top: 16%;
  left: 50%;
  transform: translateX(-50%);
  width: 80%;
  max-width: 290px;
  opacity: 0.95;
  pointer-events: none;
  z-index: 1;
}

.globe-house svg {
  width: 100%;
  height: auto;
  display: block;
}


.globe-char {
  position: absolute;
  bottom: 10%;
  left: 50%;
  margin: 0 0 0 -1.4rem;
  padding: 0;
  border: 0;
  background: transparent;
  font-family: inherit;
  cursor: pointer;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
  z-index: 2;
}

.globe-char span {
  display: block;
  font-size: 3rem;
  line-height: 1;
  filter: drop-shadow(0 4px 4px rgba(0,0,0,0.18));
}

.globe-char em {
  display: block;
  font-style: normal;
  font-weight: 700;
  font-size: 0.78rem;
  color: #1E5573;
  text-shadow: 0 1px 0 rgba(255,255,255,0.8);
  margin-top: 2px;
}

.globe-char-snowman { left: 22%; }

.globe-char-elf     { left: 50%; }

.globe-char-penguin { left: 78%; }


.globe-char-snowman.is-dancing { animation: globe-waddle 0.5s ease-in-out infinite; }

.globe-char-elf.is-dancing     { animation: globe-twirl 0.85s ease-in-out infinite; }

.globe-char-penguin.is-dancing { animation: globe-slide 0.55s ease-in-out infinite; }


.globe-shake.is-shaking .globe { animation: globe-jiggle 0.65s ease-in-out; }


.globe-spark {
  position: absolute;
  pointer-events: none;
  z-index: 8;
  animation: globe-spark-fly 0.8s ease-out forwards;
}


.globe-stand {
  width: 62vw;
  max-width: 260px;
  height: 34px;
  margin: -8px auto 0;
  background: linear-gradient(180deg, #C62828, #8E1414);
  border-radius: 0 0 16px 16px;
  box-shadow: 0 8px 16px rgba(0,0,0,0.25);
  text-align: center;
  line-height: 34px;
}

.globe-stand span {
  font-family: 'Fredoka One', cursive;
  color: #FFD54F;
  font-size: 0.85rem;
  letter-spacing: 0.06em;
}


.globe-controls {
  text-align: center;
  margin-top: 1.25rem;
}

.globe-controls .btn { margin: 0.35rem 0.4rem 0.6rem; }


/* === Splat the Naughty Elf === */
.splat-stage {
  position: relative;
  width: 100%;
  max-width: 520px;
  margin: 0 auto;
  height: 400px;
  min-height: 400px;
  height: clamp(380px, 72vw, 520px);
  overflow: hidden;
  border-radius: 22px;
  background: linear-gradient(180deg, #1B2E6B 0%, #2C4A9E 45%, #6B8BD6 78%, #EAF4FF 100%);
  box-shadow: 0 14px 30px rgba(0, 0, 0, 0.25);
  touch-action: manipulation;
}

.splat-star {
  position: absolute;
  color: #FFF3B0;
  opacity: 0.85;
  z-index: 0;
  pointer-events: none;
  animation: splat-twinkle 2s ease-in-out infinite;
}

.splat-ground {
  position: absolute;
  left: -6%;
  right: -6%;
  bottom: -20px;
  height: 42%;
  background: linear-gradient(180deg, #FFFFFF, #DCEBFF);
  border-radius: 50% 50% 0 0 / 26% 26% 0 0;
  z-index: 1;
}

.splat-tree {
  position: absolute;
  bottom: 22%;
  width: 0;
  height: 0;
  border-left: 26px solid transparent;
  border-right: 26px solid transparent;
  border-bottom: 58px solid #2E7D32;
  z-index: 1;
  opacity: 0.95;
}

.splat-tree::after {
  content: '';
  position: absolute;
  left: -7px;
  top: 48px;
  width: 14px;
  height: 16px;
  background: #6D4C41;
  border-radius: 0 0 4px 4px;
}

.splat-tree--left { left: 5%; }

.splat-tree--right { right: 5%; }

.splat-jar {
  position: absolute;
  left: 12px;
  bottom: 10px;
  z-index: 2;
  min-width: 86px;
  max-width: 40%;
  background: rgba(255, 255, 255, 0.92);
  border: 3px solid #5D4037;
  border-radius: 12px;
  padding: 6px 8px 8px;
  text-align: center;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.18);
}

.splat-jar-fill {
  font-size: 15px;
  line-height: 1.3;
  min-height: 19px;
  letter-spacing: 0.05em;
  word-break: break-all;
}

.splat-jar-label {
  display: block;
  font-size: 10px;
  color: #5D4037;
  font-weight: 700;
  letter-spacing: 0.05em;
  margin-top: 2px;
}

.splat-bowl {
  position: absolute;
  left: 50%;
  bottom: 12px;
  transform: translateX(-50%);
  z-index: 2;
  width: 58px;
  height: 52px;
  background: #C62828;
  border: 3px solid #7A1226;
  border-radius: 8px 8px 18px 18px;
  text-align: center;
  line-height: 48px;
  font-size: 26px;
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.22);
  pointer-events: none;
}

.splat-elfbtn {
  position: absolute;
  left: 50%;
  top: 20%;
  width: 76px;
  min-width: 76px;
  width: clamp(64px, 13vw, 88px);
  height: 88px;
  min-height: 88px;
  height: clamp(76px, 16vw, 104px);
  transform: translate(-50%, -50%);
  border: none;
  background: transparent;
  cursor: pointer;
  z-index: 3;
  touch-action: manipulation;
  display: none;
  padding: 0;
}

.splat-elfbtn .splat-elf-emoji {
  display: block;
  width: 100%;
  height: 100%;
  font-size: 64px;
  font-size: clamp(58px, 12vw, 80px);
  line-height: 1.1;
  filter: drop-shadow(0 8px 8px rgba(0, 0, 0, 0.35));
  user-select: none;
  animation: splat-bob 1.6s ease-in-out infinite;
}

.splat-elfbtn.is-in { display: block; }

.splat-elfbtn.is-in.animate-pop { animation: splat-pop-in 0.22s ease-out; }

.splat-elfbtn.is-shock .splat-elf-emoji { animation: splat-shock 0.3s ease-in-out; }

.splat-elfbtn:focus-visible { outline: 3px solid #FFD54F; outline-offset: 2px; border-radius: 12px; }

.splat-candy {
  position: absolute;
  z-index: 4;
  width: 32px;
  height: 34px;
  margin-left: -16px;
  margin-top: -17px;
  font-size: 30px;
  line-height: 1;
  text-align: center;
  pointer-events: none;
  transition: left 0.32s cubic-bezier(0.2, 0.7, 0.3, 1), top 0.32s cubic-bezier(0.2, 0.7, 0.3, 1);
}

.splat-splash {
  position: absolute;
  z-index: 5;
  width: 74px;
  height: 74px;
  margin-left: -37px;
  margin-top: -37px;
  border-radius: 50%;
  pointer-events: none;
  background: radial-gradient(circle, #FFD54F 0%, #F48FB1 48%, rgba(255, 255, 255, 0) 72%);
  transform: scale(0);
  animation: splat-splash 0.45s ease-out forwards;
}

.splat-drop {
  position: absolute;
  z-index: 5;
  width: 11px;
  height: 11px;
  border-radius: 50%;
  pointer-events: none;
  opacity: 0;
  transition: transform 0.5s ease-out, opacity 0.5s ease-out;
}

.splat-bubble {
  position: absolute;
  z-index: 6;
  background: #FFFFFF;
  color: #B71C1C;
  font-weight: 700;
  padding: 7px 11px;
  border-radius: 14px;
  font-size: 13px;
  box-shadow: 0 5px 12px rgba(0, 0, 0, 0.22);
  white-space: nowrap;
  pointer-events: none;
  animation: splat-tip 0.9s ease-out forwards;
}

.splat-bubble::after {
  content: '';
  position: absolute;
  left: 18px;
  bottom: -8px;
  border-left: 8px solid transparent;
  border-right: 8px solid transparent;
  border-top: 10px solid #FFFFFF;
}