#app {
  min-height: 100%;
  background: #f7cf4b;
  color: #241b12;
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", sans-serif;
}

button {
  box-sizing: border-box;
}

button::after { border: 0; }

/* Every illustrated sticker gets the same paper-cut white edge. */
.sticker-art {
  filter:
    drop-shadow(calc(min(100vw, 440px) * -3 / 750) calc(min(100vw, 440px) * -3 / 750) 0 #fffdf4)
    drop-shadow(calc(min(100vw, 440px) * 3 / 750) calc(min(100vw, 440px) * -3 / 750) 0 #fffdf4)
    drop-shadow(calc(min(100vw, 440px) * -3 / 750) calc(min(100vw, 440px) * 3 / 750) 0 #fffdf4)
    drop-shadow(calc(min(100vw, 440px) * 3 / 750) calc(min(100vw, 440px) * 3 / 750) 0 #fffdf4)
    drop-shadow(calc(min(100vw, 440px) * 6 / 750) calc(min(100vw, 440px) * 8 / 750) 0 rgba(37, 28, 19, .14)) !important;
}

.safe-top { height: env(safe-area-inset-top); }

.primary-button {
  height: calc(min(100vw, 440px) * 104 / 750);
  border-radius: calc(min(100vw, 440px) * 52 / 750);
  display: flex;
  align-items: center;
  justify-content: center;
  border: calc(min(100vw, 440px) * 4 / 750) solid #2a2119;
  color: #fffaf0;
  font-size: calc(min(100vw, 440px) * 30 / 750);
  font-weight: 700;
  letter-spacing: calc(min(100vw, 440px) * 2 / 750);
  background: #2a2119;
  box-shadow: 0 calc(min(100vw, 440px) * 12 / 750) 0 #fff1c2;
}

.primary-button[disabled] { opacity: 0.55; }

.ghost-button {
  height: calc(min(100vw, 440px) * 88 / 750);
  border-radius: calc(min(100vw, 440px) * 44 / 750);
  border: calc(min(100vw, 440px) * 3 / 750) solid #2a2119;
  background: #fff8e7;
  color: #2a2119;
  font-size: calc(min(100vw, 440px) * 28 / 750);
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Shared one-shot sheen for card surfaces. */
.quick-shine {
  position: relative;
  overflow: hidden;
}

.quick-shine::after {
  content: '';
  position: absolute;
  z-index: 30;
  top: -20%;
  bottom: -20%;
  left: -45%;
  width: 36%;
  border: 0;
  pointer-events: none;
  opacity: 0;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,.42), transparent);
  transform: translate3d(-180%, 0, 0) skewX(-14deg);
  animation: quick-card-shine 680ms 100ms ease-out both;
}

@keyframes quick-card-shine {
  0% { opacity: 0; transform: translate3d(-180%, 0, 0) skewX(-14deg); }
  24% { opacity: .9; }
  100% { opacity: 0; transform: translate3d(520%, 0, 0) skewX(-14deg); }
}

.hub-scroll {
  width: 100%;
  height: 100vh;
  background: #f7cf4b;
  color: #251c13;
}

.hub-page {
  position: relative;
  height: 100%;
  min-height: 0;
  box-sizing: border-box;
  padding: calc(min(100vw, 440px) * 16 / 750) calc(min(100vw, 440px) * 20 / 750) calc(calc(min(100vw, 440px) * 18 / 750) + env(safe-area-inset-bottom));
  overflow: hidden;
}

.paper-grain {
  position: absolute;
  inset: 0;
  opacity: .1;
  background-image: radial-gradient(#251c13 calc(min(100vw, 440px) * 1 / 750), transparent calc(min(100vw, 440px) * 1 / 750));
  background-size: calc(min(100vw, 440px) * 18 / 750) calc(min(100vw, 440px) * 18 / 750);
  pointer-events: none;
}

.sticker-stage {
  position: relative;
  z-index: 2;
  width: calc(min(100vw, 440px) * 660 / 750);
  max-width: 100%;
  height: 100%;
  min-height: 0;
  margin: 0 auto;
}

.sticker-entry {
  position: absolute;
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  line-height: 1;
  overflow: visible;
  display: flex;
  flex-direction: column;
  align-items: center;
  transition: transform .14s ease, filter .14s ease;
}

.sticker-entry::after { border: 0; }
.sticker-entry-pressed { filter: brightness(.96); }
.entry-sticker { width: 100%; height: calc(100% - calc(min(100vw, 440px) * 48 / 750)); }
.entry-title { height: calc(min(100vw, 440px) * 48 / 750); line-height: calc(min(100vw, 440px) * 48 / 750); color: #251c13; font-size: calc(min(100vw, 440px) * 27 / 750); font-weight: 950; letter-spacing: calc(min(100vw, 440px) * 2 / 750); white-space: nowrap; text-shadow: calc(min(100vw, 440px) * 2 / 750) calc(min(100vw, 440px) * 2 / 750) 0 rgba(255, 247, 223, .7); }

.sticker-cake {
  top: calc(min(100vw, 440px) * 10 / 750);
  left: calc(min(100vw, 440px) * 15 / 750);
  width: calc(min(100vw, 440px) * 270 / 750);
  height: calc(min(100vw, 440px) * 310 / 750);
  transform: rotate(-5deg);
  animation: float-cake 3.8s ease-in-out infinite;
}

.sticker-cake.sticker-entry-pressed { transform: rotate(-5deg) scale(.94); }

.sticker-answer {
  top: calc(min(100vw, 440px) * 210 / 750);
  right: calc(min(100vw, 440px) * 15 / 750);
  width: calc(min(100vw, 440px) * 255 / 750);
  height: calc(min(100vw, 440px) * 305 / 750);
  transform: rotate(6deg);
  animation: float-answer 4.4s ease-in-out .2s infinite;
}

.sticker-answer.sticker-entry-pressed { transform: rotate(6deg) scale(.94); }

.sticker-letter {
  top: calc(min(100vw, 440px) * 410 / 750);
  left: calc(min(100vw, 440px) * 5 / 750);
  width: calc(min(100vw, 440px) * 280 / 750);
  height: calc(min(100vw, 440px) * 320 / 750);
  transform: rotate(4deg);
  animation: float-letter 4s ease-in-out .5s infinite;
}

.sticker-letter.sticker-entry-pressed { transform: rotate(4deg) scale(.94); }

.sticker-bored {
  top: calc(min(100vw, 440px) * 610 / 750);
  right: calc(min(100vw, 440px) * 5 / 750);
  width: calc(min(100vw, 440px) * 275 / 750);
  height: calc(min(100vw, 440px) * 310 / 750);
  transform: rotate(-5deg);
  animation: float-bored 4.5s ease-in-out .9s infinite;
}

.sticker-bored.sticker-entry-pressed { transform: rotate(-5deg) scale(.94); }

.sticker-smoke {
  top: calc(min(100vw, 440px) * 810 / 750);
  left: calc(min(100vw, 440px) * 0 / 750);
  width: calc(min(100vw, 440px) * 315 / 750);
  height: calc(min(100vw, 440px) * 320 / 750);
  transform: rotate(-3deg);
  animation: float-smoke 4.3s ease-in-out .4s infinite;
}

.sticker-smoke.sticker-entry-pressed { transform: rotate(-3deg) scale(.94); }

.sticker-chat {
  top: calc(min(100vw, 440px) * 1010 / 750);
  right: calc(min(100vw, 440px) * 0 / 750);
  width: calc(min(100vw, 440px) * 300 / 750);
  height: calc(min(100vw, 440px) * 325 / 750);
  transform: rotate(4deg);
  animation: float-chat 4.1s ease-in-out .25s infinite;
}

.sticker-chat.sticker-entry-pressed { transform: rotate(4deg) scale(.94); }

.hub-state {
  position: relative;
  z-index: 3;
  min-height: calc(min(100vw, 440px) * 900 / 750);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: calc(min(100vw, 440px) * 24 / 750);
  padding: 0 calc(min(100vw, 440px) * 38 / 750);
  text-align: center;
  font-size: calc(min(100vw, 440px) * 23 / 750);
  font-weight: 800;
}

.parcel-loader {
  width: calc(min(100vw, 440px) * 88 / 750);
  height: calc(min(100vw, 440px) * 88 / 750);
  border: calc(min(100vw, 440px) * 4 / 750) solid #251c13;
  border-radius: calc(min(100vw, 440px) * 20 / 750);
  background: #fff7df;
  box-shadow: calc(min(100vw, 440px) * 7 / 750) calc(min(100vw, 440px) * 7 / 750) 0 #251c13;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: calc(min(100vw, 440px) * 48 / 750);
  animation: wobble .8s infinite alternate;
}

@keyframes float-cake { 0%, 100% { margin-top: 0; } 50% { margin-top: calc(min(100vw, 440px) * -9 / 750); } }
@keyframes float-answer { 0%, 100% { margin-top: 0; } 50% { margin-top: calc(min(100vw, 440px) * 9 / 750); } }
@keyframes float-letter { 0%, 100% { margin-top: 0; } 50% { margin-top: calc(min(100vw, 440px) * -8 / 750); } }
@keyframes float-bored { 0%, 100% { margin-top: 0; } 50% { margin-top: calc(min(100vw, 440px) * 7 / 750); } }
@keyframes float-smoke { 0%, 100% { margin-top: 0; } 50% { margin-top: calc(min(100vw, 440px) * 8 / 750); } }
@keyframes float-chat { 0%, 100% { margin-top: 0; } 50% { margin-top: calc(min(100vw, 440px) * -9 / 750); } }
@keyframes wobble { from { transform: rotate(-6deg); } to { transform: rotate(6deg); } }

/* Keep birthday directory stickers at their native aspect ratio. */
.entry-sticker.sticker-art { object-fit: contain; }
