:root {
  --cream: #fff7ec;
  --ink: #3d302a;
  --ink-soft: #7c6b5f;
  --pink: #ff8fb1;
  --gold: #f6b73c;
  --mint: #7fd8c5;
  --line: rgba(93, 64, 46, .12);
  --font: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans SC", system-ui, -apple-system, sans-serif;
  --font-display: "Yuanti SC", "YouYuan", "PingFang SC", "Hiragino Sans GB", "Noto Sans SC", system-ui, sans-serif;
  --shadow-soft: 0 24px 70px -40px rgba(82, 51, 32, .6);
}

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

[hidden] {
  display: none !important;
}

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

body {
  margin: 0;
  min-height: 100dvh;
  color: var(--ink);
  font-family: var(--font);
  background: radial-gradient(1200px 800px at 20% 0%, #fff9ef, #ffeef2 45%, #eaf8f4 100%) fixed;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

body.modal-open {
  overflow: hidden;
}

::selection {
  background: rgba(255, 143, 177, .35);
  color: var(--ink);
}

h1, h2, h3, p {
  margin-top: 0;
}

button,
input {
  font: inherit;
}

a {
  color: inherit;
}

.svg-defs {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

.skip-link {
  position: fixed;
  top: 10px;
  left: 10px;
  z-index: 100;
  padding: 10px 16px;
  border-radius: 12px;
  background: #fff;
  color: var(--ink);
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
  box-shadow: var(--shadow-soft);
  transform: translateY(-160%);
  transition: transform .2s ease;
}

.skip-link:focus {
  transform: translateY(0);
}

/* ---------- background ---------- */

.sky {
  position: fixed;
  inset: 0;
  z-index: -2;
  overflow: hidden;
  pointer-events: none;
}

.sky-svg {
  display: block;
  width: 100%;
  height: 100%;
}

.veil {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background: radial-gradient(58% 48% at 50% 20%, rgba(255, 255, 255, .55), transparent 72%);
}

.cloud {
  transform-box: fill-box;
  transform-origin: center;
  animation: drift 18s ease-in-out infinite alternate;
}

.cloud-2 { animation-duration: 24s; animation-delay: -6s; }
.cloud-3 { animation-duration: 20s; animation-delay: -11s; }
.cloud-4 { animation-duration: 26s; animation-delay: -3s; }

.balloon-group {
  transform-box: fill-box;
  transform-origin: center;
  animation: floaty 7s ease-in-out infinite;
}

.balloon-b { animation-duration: 9s; animation-delay: -2s; }
.balloon-c { animation-duration: 8s; animation-delay: -4s; }
.balloon-d { animation-duration: 10s; animation-delay: -1s; }

.sparkles use {
  transform-box: fill-box;
  transform-origin: center;
  animation: twinkle 4s ease-in-out infinite;
}

.sparkles use:nth-child(2) { animation-delay: -1.1s; }
.sparkles use:nth-child(3) { animation-delay: -2.3s; }
.sparkles use:nth-child(4) { animation-delay: -.6s; }
.sparkles use:nth-child(5) { animation-delay: -3.1s; }

/* ---------- topbar ---------- */

.topbar {
  position: sticky;
  top: 0;
  z-index: 40;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: calc(12px + env(safe-area-inset-top)) clamp(16px, 4vw, 48px) 12px;
  background: linear-gradient(180deg, rgba(255, 248, 238, .92), rgba(255, 248, 238, .55) 65%, transparent);
  border-bottom: 1px solid rgba(255, 255, 255, .55);
  -webkit-backdrop-filter: blur(16px) saturate(1.25);
  backdrop-filter: blur(16px) saturate(1.25);
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--ink);
  border-radius: 18px;
}

.brand:focus-visible {
  outline: 3px solid rgba(255, 143, 177, .5);
  outline-offset: 4px;
}

.brand-badge {
  width: 46px;
  height: 46px;
  border-radius: 16px;
  display: grid;
  place-items: center;
  background: #fff;
  border: 1.5px solid #f0dccb;
  box-shadow: 0 8px 18px -10px rgba(120, 80, 50, .55);
  transform: rotate(-4deg);
  transition: transform .3s cubic-bezier(.34, 1.56, .64, 1);
}

.brand:hover .brand-badge {
  transform: rotate(4deg) scale(1.04);
}

.brand-badge img {
  width: 40px;
  height: 40px;
  object-fit: contain;
}

.brand-text {
  display: flex;
  flex-direction: column;
  gap: 3px;
  font-size: 18px;
  font-weight: 900;
  line-height: 1;
  letter-spacing: .03em;
  font-family: var(--font-display);
}

.brand-text small {
  font-family: var(--font);
  font-size: 8.5px;
  font-weight: 800;
  letter-spacing: .22em;
  color: var(--ink-soft);
}

.top-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.total-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 14px;
  border-radius: 999px;
  background: rgba(255, 255, 255, .74);
  border: 1px solid rgba(255, 255, 255, .95);
  box-shadow: 0 10px 22px -18px rgba(90, 55, 35, .8);
  font-size: 12.5px;
  font-weight: 600;
  color: var(--ink-soft);
  white-space: nowrap;
}

.total-chip b {
  font-size: 15px;
  color: var(--ink);
  font-weight: 900;
}

.icon-btn {
  width: 44px;
  height: 44px;
  border-radius: 14px;
  border: 1.5px solid rgba(61, 48, 42, .1);
  background: rgba(255, 255, 255, .8);
  color: var(--ink);
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: transform .22s ease, background .22s ease, box-shadow .22s ease;
}

.icon-btn:hover {
  transform: translateY(-2px);
  background: #fff;
  box-shadow: 0 10px 20px -14px rgba(80, 50, 30, .7);
}

.icon-btn:active {
  transform: translateY(0) scale(.96);
}

.icon-btn:focus-visible {
  outline: 3px solid rgba(255, 143, 177, .45);
  outline-offset: 2px;
}

.icon-btn svg {
  width: 21px;
  height: 21px;
}

.icon-btn .sound-off {
  display: none;
}

.icon-btn[aria-pressed="false"] .sound-on {
  display: none;
}

.icon-btn[aria-pressed="false"] .sound-off {
  display: block;
}

/* ---------- layout ---------- */

#app {
  position: relative;
  z-index: 1;
}

.view {
  animation: viewIn .5s ease both;
}

.view-home {
  max-width: 1180px;
  margin: 0 auto;
  padding: clamp(14px, 3.6vw, 36px) clamp(16px, 4vw, 40px) 56px;
}

.view-play {
  --c1: #43c6b8;
  --c2: #9be3cf;
  --soft: #e7faf4;
  max-width: 940px;
  margin: 0 auto;
  padding: clamp(10px, 2.4vw, 22px) clamp(14px, 4vw, 32px) 72px;
}

/* ---------- hero ---------- */

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(300px, .8fr);
  align-items: center;
  gap: clamp(20px, 4vw, 54px);
  padding: clamp(22px, 4.6vw, 54px) 0 clamp(30px, 5vw, 58px);
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 0;
  padding: 8px 15px;
  border-radius: 999px;
  background: rgba(255, 255, 255, .7);
  border: 1px solid rgba(255, 255, 255, .95);
  box-shadow: 0 10px 24px -18px rgba(90, 55, 35, .8);
  font-size: 11.5px;
  font-weight: 800;
  letter-spacing: .16em;
  color: var(--ink-soft);
}

.eyebrow span {
  color: var(--pink);
  font-size: 12px;
}

h1 {
  margin: 20px 0 18px;
  font-family: var(--font-display);
  font-size: clamp(42px, 6.2vw, 76px);
  font-weight: 900;
  line-height: 1.06;
  letter-spacing: -.02em;
}

h1 .grad {
  position: relative;
  background: linear-gradient(100deg, #ff7aa8 0%, #ff9966 32%, #ffc94d 58%, #58cbb8 100%);
  background-size: 220% auto;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: gradientShift 6s ease-in-out infinite;
  filter: drop-shadow(0 6px 12px rgba(255, 150, 120, .18));
}

.lede {
  margin-bottom: 0;
  max-width: 29em;
  font-size: clamp(14.5px, 1.5vw, 16.5px);
  line-height: 1.9;
  color: var(--ink-soft);
  font-weight: 500;
}

.hero-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 26px;
}

.hero-badges span {
  padding: 8px 14px;
  border-radius: 999px;
  background: #fff;
  border: 1px solid #f1e2d4;
  box-shadow: 0 10px 20px -16px rgba(90, 60, 40, .8);
  font-size: 12px;
  font-weight: 700;
  color: var(--ink-soft);
}

.hero-art {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 390px;
  isolation: isolate;
}

.hero-scene {
  position: relative;
  width: 100%;
  border-radius: 34px;
  overflow: hidden;
  background: linear-gradient(165deg, #fff, #f2fbf6);
  border: 2px solid #fff;
  box-shadow: 0 42px 70px -40px rgba(80, 50, 30, .65), inset 0 0 0 1px rgba(214, 180, 150, .22);
  animation: sceneFloat 8s ease-in-out infinite;
}

.hero-scene img {
  display: block;
  width: 100%;
  height: auto;
}

.hero-scene::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(62% 44% at 50% 0%, rgba(255, 255, 255, .3), transparent 70%);
  pointer-events: none;
}

.hero-float-dog {
  position: absolute;
  right: -3%;
  bottom: -10%;
  width: clamp(90px, 18%, 128px);
  height: auto;
  --r: 7deg;
  filter: drop-shadow(0 18px 22px rgba(80, 50, 30, .3));
  animation: floaty 5.5s ease-in-out infinite;
}

.mini-gift {
  position: absolute;
  width: 76px;
  height: 62px;
  border-radius: 16px;
  background: linear-gradient(150deg, var(--g-hi), var(--g-c));
  box-shadow: inset 0 -7px 0 rgba(90, 40, 30, .08), 0 18px 28px -18px rgba(90, 50, 40, .7);
  animation: floaty 6.5s ease-in-out infinite;
}

.mini-gift.gift-a {
  --g-hi: #ffd9e3;
  --g-c: #ff9fba;
  --r: 8deg;
  top: -22px;
  left: 16px;
  z-index: 2;
}

.mini-gift.gift-b {
  --g-hi: #d8f6ec;
  --g-c: #7fd8c5;
  --r: -8deg;
  bottom: 10%;
  left: 0;
  width: 62px;
  height: 52px;
  animation-delay: -2s;
}

.mini-gift.gift-c {
  --g-hi: #e9e3ff;
  --g-c: #b8a9ff;
  --r: -4deg;
  top: -18px;
  right: 58px;
  width: 56px;
  height: 48px;
  animation-delay: -4s;
  z-index: 2;
}

.mg-lid {
  position: absolute;
  left: -4px;
  right: -4px;
  top: -6px;
  height: 16px;
  border-radius: 10px;
  background: linear-gradient(160deg, #fff, var(--g-hi));
  box-shadow: 0 4px 0 rgba(90, 40, 30, .07);
}

.mg-ribbon {
  position: absolute;
  top: -6px;
  bottom: -6px;
  left: 50%;
  width: 10px;
  transform: translateX(-50%);
  border-radius: 4px;
  background: rgba(255, 255, 255, .85);
}

.mg-bow {
  position: absolute;
  top: -23px;
  left: 50%;
  transform: translateX(-50%) rotate(-6deg);
  font-size: 20px;
  filter: drop-shadow(0 3px 3px rgba(90, 40, 30, .18));
}

.hero-spark {
  position: absolute;
  color: #fff;
  font-size: 20px;
  text-shadow: 0 0 14px rgba(255, 255, 255, .9), 0 4px 10px rgba(255, 150, 150, .35);
  animation: twinkle 3.6s ease-in-out infinite;
}

.hero-spark.sp-a { top: 16%; left: 8%; font-size: 24px; }
.hero-spark.sp-b { bottom: 24%; right: 12%; font-size: 17px; animation-delay: -1.2s; }
.hero-spark.sp-c { top: 40%; left: 2%; font-size: 13px; animation-delay: -2.2s; }

.hero-note {
  position: absolute;
  left: 2%;
  bottom: -16px;
  white-space: nowrap;
  padding: 8px 15px;
  border-radius: 999px;
  background: rgba(255, 255, 255, .92);
  border: 1px solid #fff;
  box-shadow: 0 12px 24px -18px rgba(90, 55, 35, .8);
  font-size: 11.5px;
  font-weight: 700;
  color: var(--ink-soft);
  z-index: 3;
}

/* ---------- section / entry cards ---------- */

.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  margin: 4px 0 22px;
}

.section-head h2 {
  margin: 0 0 4px;
  font-family: var(--font-display);
  font-size: clamp(23px, 3vw, 30px);
  letter-spacing: .01em;
}

.section-head p {
  margin: 0;
  font-size: 13px;
  color: var(--ink-soft);
}

.section-tip {
  font-size: 11.5px;
  font-weight: 700;
  color: var(--ink-soft);
  padding: 7px 13px;
  border-radius: 999px;
  background: rgba(255, 255, 255, .55);
  border: 1px dashed rgba(140, 105, 80, .28);
  white-space: nowrap;
}

.entry-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(14px, 2vw, 22px);
}

.entry-skeleton {
  min-height: clamp(160px, 22vw, 210px);
  border-radius: clamp(22px, 3vw, 30px);
  background: linear-gradient(120deg, rgba(255, 255, 255, .55) 30%, rgba(255, 255, 255, .85) 50%, rgba(255, 255, 255, .55) 70%);
  background-size: 200% 100%;
  box-shadow: 0 14px 34px -24px rgba(80, 50, 30, .15), inset 0 0 0 1px rgba(255, 255, 255, .6);
  animation: shimmer 1.6s ease-in-out infinite;
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: clamp(18px, 2.4vw, 26px);
}

.entry-skeleton span {
  border-radius: 999px;
  background: rgba(190, 180, 170, .18);
}

.entry-skeleton span:nth-child(1) {
  width: 48px;
  height: 48px;
}

.entry-skeleton span:nth-child(2) {
  width: 58%;
  height: 18px;
  margin-top: auto;
}

.entry-skeleton span:nth-child(3) {
  width: 80%;
  height: 12px;
}

@keyframes shimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

.entry-card {
  --c1: #ff9fba;
  --c2: #ffd3e0;
  --soft: #ffeef4;
  position: relative;
  overflow: hidden;
  isolation: isolate;
  display: flex;
  flex-direction: column;
  min-height: 220px;
  padding: 22px 22px 18px;
  border-radius: 28px;
  background: var(--soft);
  background: linear-gradient(152deg, #fff 0%, var(--soft) 56%, #fff 100%);
  border: 1.5px solid rgba(255, 255, 255, .95);
  box-shadow: 0 20px 44px -30px rgba(90, 60, 40, .65), inset 0 1px 0 rgba(255, 255, 255, .95);
  color: var(--ink);
  text-decoration: none;
  transition: transform .35s cubic-bezier(.2, .8, .2, 1), box-shadow .35s ease, border-color .35s ease;
}

.entry-card::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: radial-gradient(120% 90% at 88% -10%, color-mix(in srgb, var(--c1) 28%, transparent), transparent 62%);
  opacity: .9;
}

.entry-card::after {
  content: "";
  position: absolute;
  z-index: 2;
  top: -45%;
  left: -70%;
  width: 42%;
  height: 190%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, .72), transparent);
  transform: rotate(18deg);
  transition: left .8s ease;
  pointer-events: none;
}

.entry-card:hover {
  transform: translateY(-7px) rotate(-.4deg);
  border-color: color-mix(in srgb, var(--c1) 38%, #fff);
  box-shadow: 0 30px 56px -28px color-mix(in srgb, var(--c1) 55%, rgba(90, 60, 40, .3));
}

.entry-card:hover::after {
  left: 135%;
}

.entry-card:focus-visible {
  outline: 3px solid color-mix(in srgb, var(--c1) 60%, #fff);
  outline-offset: 4px;
}

.entry-card > * {
  position: relative;
  z-index: 1;
}

.entry-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
}

.entry-emoji {
  width: 60px;
  height: 60px;
  border-radius: 21px;
  display: grid;
  place-items: center;
  font-size: 29px;
  background: var(--soft);
  background: linear-gradient(160deg, #fff, color-mix(in srgb, var(--c1) 20%, #fff));
  box-shadow: 0 12px 20px -14px var(--c1), inset 0 0 0 1.5px rgba(255, 255, 255, .9);
  transform: rotate(-4deg);
  transition: transform .35s cubic-bezier(.34, 1.56, .64, 1);
}

.entry-card:hover .entry-emoji {
  transform: rotate(5deg) scale(1.06);
}

.entry-emoji img {
  width: 82%;
  height: 82%;
  object-fit: contain;
}

.entry-spark {
  color: var(--c1);
  font-size: 17px;
  opacity: .75;
  animation: twinkle 4s ease-in-out infinite;
}

.entry-card h3 {
  margin: 18px 0 6px;
  font-family: var(--font-display);
  font-size: 20.5px;
  letter-spacing: .01em;
}

.entry-card p {
  margin: 0;
  font-size: 12.5px;
  line-height: 1.65;
  color: var(--ink-soft);
}

.entry-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-top: auto;
  padding-top: 18px;
}

.entry-count {
  padding: 5px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, .72);
  border: 1px solid rgba(255, 255, 255, .95);
  font-size: 11px;
  font-weight: 700;
  color: var(--ink-soft);
}

.entry-go {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 12.5px;
  font-weight: 900;
  color: var(--c1);
}

.entry-go b {
  font-weight: 900;
  transition: transform .3s ease;
}

.entry-card:hover .entry-go b {
  transform: translateX(4px);
}

.foot {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-top: clamp(34px, 6vw, 56px);
  padding-top: 18px;
  border-top: 1px dashed rgba(120, 90, 70, .18);
  font-size: 11.5px;
  color: var(--ink-soft);
}

/* ---------- play view ---------- */

.play-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: clamp(14px, 2.5vw, 22px);
}

.back-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 15px;
  border-radius: 999px;
  background: rgba(255, 255, 255, .78);
  border: 1px solid rgba(255, 255, 255, .95);
  box-shadow: 0 10px 22px -18px rgba(90, 55, 35, .8);
  font-size: 12.5px;
  font-weight: 800;
  color: var(--ink-soft);
  text-decoration: none;
  transition: transform .22s ease, background .22s ease;
}

.back-btn:hover {
  transform: translateX(-3px);
  background: #fff;
  color: var(--ink);
}

.back-btn:focus-visible {
  outline: 3px solid color-mix(in srgb, var(--c1) 55%, #fff);
  outline-offset: 3px;
}

.play-stats {
  display: flex;
  gap: 8px;
}

.stat-chip {
  padding: 8px 13px;
  border-radius: 999px;
  background: rgba(255, 255, 255, .78);
  border: 1px solid rgba(255, 255, 255, .95);
  box-shadow: 0 10px 22px -18px rgba(90, 55, 35, .8);
  font-size: 11.5px;
  font-weight: 700;
  color: var(--ink-soft);
  white-space: nowrap;
}

.stat-chip b {
  font-size: 14px;
  font-weight: 900;
  color: var(--c1);
}

.play-heading {
  display: flex;
  align-items: center;
  gap: clamp(12px, 2.5vw, 18px);
  padding: 0 4px clamp(16px, 3vw, 24px);
}

.play-emoji {
  flex: 0 0 auto;
  width: clamp(62px, 9vw, 84px);
  aspect-ratio: 1;
  border-radius: 26px;
  display: grid;
  place-items: center;
  font-size: clamp(30px, 4.6vw, 41px);
  background: var(--soft);
  background: linear-gradient(160deg, #fff, var(--soft));
  box-shadow: 0 18px 32px -22px var(--c1), inset 0 0 0 1.5px #fff;
  transform: rotate(-4deg);
}

.play-kicker {
  margin: 0 0 4px;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .2em;
  color: var(--c1);
}

.play-copy h2 {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(25px, 4.2vw, 38px);
  line-height: 1.1;
  letter-spacing: .01em;
}

.play-copy p:last-child {
  margin: 6px 0 0;
  font-size: 12.5px;
  color: var(--ink-soft);
}

.play-paw {
  margin-left: auto;
  width: clamp(44px, 8vw, 74px);
  color: var(--c1);
  opacity: .2;
}

.play-paw svg {
  display: block;
  width: 100%;
  height: auto;
  transform: rotate(12deg);
}

/* ---------- panel ---------- */

.panel {
  position: relative;
  padding: clamp(18px, 3.8vw, 36px);
  border-radius: clamp(26px, 4vw, 38px);
  background: linear-gradient(165deg, rgba(255, 255, 255, .94), rgba(255, 255, 255, .7));
  border: 1.5px solid rgba(255, 255, 255, .98);
  box-shadow: 0 44px 90px -56px rgba(80, 50, 30, .7), inset 0 1px 0 #fff;
  -webkit-backdrop-filter: blur(18px) saturate(1.2);
  backdrop-filter: blur(18px) saturate(1.2);
}

.panel::before {
  content: "";
  position: absolute;
  top: 0;
  left: 9%;
  right: 9%;
  height: 4px;
  border-radius: 0 0 6px 6px;
  background: linear-gradient(90deg, transparent, var(--c1), var(--c2), transparent);
  opacity: .9;
}

.panel-head {
  text-align: center;
  margin-bottom: clamp(14px, 2.8vw, 22px);
}

.panel-title {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 18px;
  border-radius: 999px;
  background: var(--soft);
  background: linear-gradient(100deg, #fff, var(--soft), #fff);
  border: 1px solid rgba(255, 255, 255, .95);
  box-shadow: 0 10px 24px -20px var(--c1), inset 0 0 0 1px rgba(255, 255, 255, .7);
  font-size: clamp(11.5px, 1.5vw, 13px);
  font-weight: 900;
  letter-spacing: .08em;
  color: var(--ink);
}

.panel-hint {
  margin: 10px 0 0;
  font-size: 12px;
  color: var(--ink-soft);
}

.box-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(8px, 1.8vw, 18px);
  width: 100%;
  max-width: 610px;
  margin: clamp(18px, 3.6vw, 32px) auto 0;
}

/* ---------- gift boxes ---------- */

.box {
  --b-hi: #ffe1ea;
  --b-1: #ffa8c0;
  --b-2: #f26e96;
  --b-glow: rgba(242, 110, 150, .55);
  position: relative;
  aspect-ratio: 1;
  perspective: 800px;
}

.box-body {
  position: absolute;
  inset: 12% 7% 3%;
  z-index: 1;
  border-radius: 18%;
  background: linear-gradient(155deg, var(--b-hi) 0%, var(--b-1) 44%, var(--b-2) 100%);
  box-shadow:
    inset 0 -8px 0 rgba(80, 40, 20, .09),
    inset 0 3px 0 rgba(255, 255, 255, .6),
    0 14px 22px -14px rgba(87, 52, 33, .55);
  transition: transform .32s cubic-bezier(.34, 1.56, .64, 1), box-shadow .32s ease, filter .32s ease;
}

.box-lid {
  position: absolute;
  left: -4%;
  right: -4%;
  top: -8%;
  height: 27%;
  z-index: 2;
  border-radius: 14px;
  background: linear-gradient(150deg, var(--b-hi), var(--b-1));
  box-shadow: 0 5px 0 rgba(80, 40, 20, .12), inset 0 2px 0 rgba(255, 255, 255, .65);
  transform-origin: 50% 100%;
  transition: transform .5s cubic-bezier(.34, 1.56, .64, 1);
}

.box-lid::after {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: 50%;
  width: 15%;
  transform: translateX(-50%);
  border-radius: 4px;
  background: linear-gradient(180deg, rgba(255, 255, 255, .95), rgba(255, 255, 255, .55));
  opacity: .9;
}

.box-ribbon-v {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 50%;
  width: 15%;
  transform: translateX(-50%);
  background: linear-gradient(180deg, rgba(255, 255, 255, .92), rgba(255, 255, 255, .55));
  opacity: .9;
}

.box-ribbon-h {
  position: absolute;
  top: 46%;
  left: 0;
  right: 0;
  height: 13%;
  background: linear-gradient(90deg, rgba(255, 255, 255, .9), rgba(255, 255, 255, .55));
  opacity: .9;
}

.box-bow {
  position: absolute;
  left: 50%;
  top: -18%;
  z-index: 3;
  width: 28%;
  aspect-ratio: 1.9;
  transform: translateX(-50%) rotate(-2deg);
  filter: drop-shadow(0 4px 4px rgba(80, 40, 20, .16));
}

.box-bow::before,
.box-bow::after {
  content: "";
  position: absolute;
  top: 0;
  width: 46%;
  height: 100%;
  border-radius: 60% 60% 50% 50% / 70% 70% 40% 40%;
  background: linear-gradient(160deg, #fff, var(--b-hi));
  border: 2px solid rgba(255, 255, 255, .9);
}

.box-bow::before {
  left: 0;
  transform: rotate(-14deg);
}

.box-bow::after {
  right: 0;
  transform: rotate(14deg);
}

.box-bow span {
  position: absolute;
  z-index: 1;
  left: 50%;
  top: 50%;
  width: 26%;
  aspect-ratio: 1;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  background: linear-gradient(160deg, #fff, var(--b-1));
  box-shadow: 0 2px 4px rgba(80, 40, 20, .2);
}

.box-mark {
  position: absolute;
  z-index: 4;
  left: 50%;
  top: 53%;
  width: 35%;
  aspect-ratio: 1;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: rgba(255, 255, 255, .94);
  box-shadow: 0 6px 14px -8px rgba(80, 40, 20, .55), inset 0 0 0 3px rgba(255, 255, 255, .6);
  color: var(--b-2);
  font-family: var(--font-display);
  font-size: clamp(18px, 3.2vw, 26px);
  font-weight: 900;
  transition: transform .3s cubic-bezier(.34, 1.56, .64, 1), background .3s ease, color .3s ease, box-shadow .3s ease;
}

.box-mark::before {
  content: "?";
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  transition: opacity .25s ease, transform .25s ease;
}

.box-mark::after {
  content: "🐾";
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  font-size: .86em;
  opacity: 0;
  transform: scale(.4) rotate(-18deg);
  transition: opacity .25s ease, transform .3s cubic-bezier(.34, 1.56, .64, 1);
}

.box-spark {
  position: absolute;
  inset: 0;
  z-index: 5;
  pointer-events: none;
}

.box-spark::before,
.box-spark::after {
  content: "✦";
  position: absolute;
  color: #fff;
  opacity: 0;
  transform: scale(.3);
  text-shadow: 0 0 12px rgba(255, 255, 255, .95);
  transition: opacity .2s ease, transform .25s ease;
}

.box-spark::before {
  top: 5%;
  left: 4%;
  font-size: clamp(11px, 1.8vw, 16px);
}

.box-spark::after {
  right: 4%;
  bottom: 6%;
  font-size: clamp(9px, 1.5vw, 13px);
}

.box.is-lit .box-body {
  transform: translateY(-6%) scale(1.045);
  filter: saturate(1.12) brightness(1.04);
  box-shadow:
    inset 0 -6px 0 rgba(80, 40, 20, .07),
    inset 0 3px 0 rgba(255, 255, 255, .8),
    0 0 0 4px rgba(255, 255, 255, .7),
    0 0 32px 9px var(--b-glow),
    0 20px 28px -16px rgba(87, 52, 33, .55);
}

.box.is-lit .box-lid {
  animation: lidWiggle .5s ease;
}

.box.is-lit .box-bow {
  animation: bowWiggle .45s ease;
}

.box.is-lit .box-mark {
  background: var(--b-2);
  color: #fff;
  transform: translate(-50%, -50%) scale(1.12) rotate(-6deg);
  box-shadow: 0 0 0 5px rgba(255, 255, 255, .55), 0 0 22px var(--b-glow);
}

.box.is-lit .box-mark::before {
  opacity: 0;
  transform: scale(.5);
}

.box.is-lit .box-mark::after {
  opacity: 1;
  transform: scale(1) rotate(0);
}

.box.is-lit .box-spark::before {
  opacity: 1;
  transform: scale(1);
  animation: twinkle .5s ease-in-out infinite alternate;
}

.box.is-lit .box-spark::after {
  opacity: .9;
  transform: scale(1);
  animation: twinkle .62s ease-in-out infinite alternate-reverse;
}

.box.is-win .box-lid {
  transform: translateY(-38%) rotate(-10deg);
}

.box.is-win .box-body {
  transform: translateY(-9%) scale(1.06);
}

.box.is-win::after {
  content: "";
  position: absolute;
  inset: 1%;
  z-index: 6;
  border-radius: 28%;
  border: 2.5px solid var(--b-2);
  opacity: 0;
  animation: ringBurst .95s ease-out forwards;
  pointer-events: none;
}

/* 空奖：中奖盒子只掀开一点，里面确实什么都没有 */
.box-grid.is-empty .box.is-win .box-mark::after {
  content: "🫧";
}

.box-grid.is-empty .box.is-win .box-body {
  filter: saturate(.45) brightness(1.02);
}

.box-grid.is-empty .box.is-win .box-lid {
  transform: translateY(-24%) rotate(-4deg);
}

.box-grid.is-empty .box.is-win::after {
  border-color: #9fb0c2;
}

/* ---------- draw button ---------- */

.draw-area {
  text-align: center;
  margin-top: clamp(20px, 3.4vw, 30px);
}

.busy-dog {
  display: block;
  width: clamp(78px, 11vw, 104px);
  height: auto;
  margin: 0 auto 10px;
  filter: drop-shadow(0 14px 18px rgba(80, 50, 30, .26));
  animation: bob 2.2s ease-in-out infinite;
}

.draw-btn {
  position: relative;
  display: inline-flex;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: none;
  cursor: pointer;
  outline-offset: 5px;
}

.draw-btn:focus-visible {
  outline: 3px solid color-mix(in srgb, var(--c1) 55%, #fff);
}

.draw-btn-inner {
  position: relative;
  overflow: hidden;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 16px clamp(36px, 6.6vw, 62px);
  border-radius: 999px;
  font-family: var(--font-display);
  font-size: clamp(17px, 2.3vw, 20px);
  font-weight: 900;
  letter-spacing: .12em;
  color: #fff;
  background: linear-gradient(100deg, #ff7aa8, #ff9a62 52%, #ffc84a);
  background-size: 180% auto;
  box-shadow:
    0 20px 34px -16px rgba(255, 120, 150, .85),
    inset 0 2px 0 rgba(255, 255, 255, .5),
    inset 0 -4px 0 rgba(150, 50, 40, .12);
  transition: transform .25s ease, box-shadow .25s ease, background-position .5s ease, filter .25s ease;
}

.draw-btn:hover .draw-btn-inner {
  transform: translateY(-3px);
  background-position: 100% 50%;
  box-shadow:
    0 26px 42px -18px rgba(255, 120, 150, .95),
    inset 0 2px 0 rgba(255, 255, 255, .5),
    inset 0 -4px 0 rgba(150, 50, 40, .12);
}

.draw-btn:active .draw-btn-inner {
  transform: translateY(1px) scale(.99);
}

.draw-btn[disabled] {
  cursor: wait;
}

.draw-btn[disabled] .draw-btn-inner {
  filter: saturate(.78);
}

.draw-btn.is-busy .draw-paw {
  animation: pawJump .65s ease-in-out infinite;
}

.draw-btn-shine {
  position: absolute;
  top: -40%;
  left: -30%;
  width: 24%;
  height: 180%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, .7), transparent);
  transform: rotate(16deg);
  animation: btnShine 3.4s ease-in-out infinite;
}

.draw-tip {
  margin: 12px 0 0;
  font-size: 11px;
  color: var(--ink-soft);
  opacity: .85;
}

/* ---------- recent ---------- */

.recent {
  margin-top: 26px;
  padding-top: 18px;
  border-top: 1px dashed rgba(120, 90, 70, .18);
}

.recent-title {
  margin: 0 0 10px;
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: .18em;
  color: var(--ink-soft);
}

.recent-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.recent-list li {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 7px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, .85);
  border: 1px solid rgba(255, 255, 255, .95);
  box-shadow: 0 8px 16px -14px rgba(80, 50, 30, .7);
  font-size: 12px;
}

.recent-list .r-emoji {
  font-size: 15px;
  line-height: 1;
}

.recent-list li.is-empty {
  background: rgba(240, 244, 248, .92);
  color: var(--ink-soft);
  opacity: .85;
}

.recent-list time {
  font-size: 10px;
  color: var(--ink-soft);
}

.source-note {
  margin: 16px 0 0;
  text-align: center;
  font-size: 10.5px;
  color: var(--ink-soft);
  opacity: .8;
}

/* ---------- modal ---------- */

.modal-layer {
  position: fixed;
  inset: 0;
  z-index: 60;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(64, 38, 28, .34);
  -webkit-backdrop-filter: blur(10px) saturate(1.1);
  backdrop-filter: blur(10px) saturate(1.1);
  animation: fadeIn .28s ease both;
}

.confetti-wrap {
  position: fixed;
  inset: 0;
  z-index: 1;
  pointer-events: none;
}

.confetti-wrap canvas {
  display: block;
  width: 100%;
  height: 100%;
}

.modal-card {
  --r1: #7fd8c5;
  --r2: #3fbfa3;
  --rglow: rgba(63, 191, 163, .45);
  position: relative;
  z-index: 2;
  width: min(430px, 100%);
  max-height: calc(100dvh - 40px);
  overflow: auto;
  padding: clamp(26px, 5vw, 38px) clamp(20px, 4.4vw, 32px) 24px;
  border-radius: 36px;
  text-align: center;
  background:
    radial-gradient(120% 90% at 50% 0%, #fffdf8, #fff4ec 55%, #ffe9f0);
  border: 2px solid rgba(255, 255, 255, .98);
  box-shadow: 0 44px 100px -34px rgba(70, 35, 25, .65), inset 0 1px 0 #fff;
  animation: modalIn .5s cubic-bezier(.2, 1.35, .4, 1) both;
  scrollbar-width: none;
}

.modal-card::-webkit-scrollbar {
  display: none;
}

.modal-card.rarity-rare {
  --r1: #a7b8ff;
  --r2: #7161ea;
  --rglow: rgba(113, 97, 234, .45);
}

.modal-card.rarity-legendary {
  --r1: #ffe08a;
  --r2: #e8961f;
  --rglow: rgba(232, 150, 31, .5);
}

.modal-card.rarity-empty {
  --r1: #cdd8e3;
  --r2: #7b8b9e;
  --rglow: rgba(123, 139, 158, .38);
}

.modal-card.rarity-empty {
  background: radial-gradient(120% 90% at 50% 0%, #fdfefe, #f2f6fa 55%, #eaf0f6);
}

.rarity-empty .prize-rays {
  opacity: .22;
}

.rarity-empty .prize-emoji {
  background: radial-gradient(circle at 35% 28%, #fff, #eff4f8);
  box-shadow: 0 14px 26px -18px var(--rglow), 0 0 0 6px rgba(255, 255, 255, .5);
}

.rarity-empty .modal-dog {
  filter: grayscale(1) opacity(.72) drop-shadow(0 12px 16px rgba(80, 90, 100, .2));
  transform: rotate(4deg);
}

.rarity-empty .primary-btn {
  background: linear-gradient(100deg, #8fa0b3, #b7c6d6);
  box-shadow: 0 16px 26px -16px rgba(120, 140, 160, .8), inset 0 2px 0 rgba(255, 255, 255, .35);
}

.modal-close {
  position: absolute;
  top: 14px;
  right: 14px;
  z-index: 5;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid rgba(61, 48, 42, .08);
  background: rgba(255, 255, 255, .8);
  color: var(--ink-soft);
  font-size: 22px;
  line-height: 1;
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: transform .2s ease, background .2s ease;
}

.modal-close:hover {
  transform: rotate(90deg);
  background: #fff;
  color: var(--ink);
}

.modal-close:focus-visible {
  outline: 3px solid var(--r1);
  outline-offset: 2px;
}

.prize-rays {
  position: absolute;
  top: 138px;
  left: 50%;
  z-index: 0;
  width: 290px;
  height: 290px;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  background: repeating-conic-gradient(from 0deg, var(--rglow) 0deg 8deg, transparent 8deg 24deg);
  opacity: .5;
  animation: spinSlow 22s linear infinite;
  -webkit-mask-image: radial-gradient(circle, transparent 0 30%, #000 32% 62%, transparent 64%);
  mask-image: radial-gradient(circle, transparent 0 30%, #000 32% 62%, transparent 64%);
  pointer-events: none;
}

.rarity-legendary .prize-rays {
  opacity: .75;
  animation-duration: 14s;
}

.rarity-badge {
  position: relative;
  z-index: 2;
  display: inline-flex;
  padding: 7px 14px;
  border-radius: 999px;
  background: linear-gradient(100deg, var(--r2), var(--r1));
  box-shadow: 0 10px 22px -14px var(--r2), inset 0 1px 0 rgba(255, 255, 255, .4);
  color: #fff;
  font-size: 10.5px;
  font-weight: 900;
  letter-spacing: .18em;
}

.prize-emoji {
  position: relative;
  z-index: 2;
  width: 96px;
  height: 96px;
  margin: 18px auto 10px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  font-size: 48px;
  background: radial-gradient(circle at 35% 28%, #fff, #fff7ee);
  box-shadow: 0 18px 32px -18px var(--rglow), 0 0 0 8px rgba(255, 255, 255, .55);
  animation: prizePop .65s .08s cubic-bezier(.2, 1.6, .4, 1) both;
}

.rarity-legendary .prize-emoji {
  animation: prizePop .65s .08s cubic-bezier(.2, 1.6, .4, 1) both, legendaryGlow 2.2s .7s ease-in-out infinite;
}

.prize-kicker {
  position: relative;
  z-index: 2;
  margin: 0 0 4px;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .18em;
  color: var(--ink-soft);
}

.modal-card h2 {
  position: relative;
  z-index: 2;
  margin: 0 0 8px;
  font-family: var(--font-display);
  font-size: clamp(27px, 5vw, 35px);
  line-height: 1.2;
  letter-spacing: .01em;
  background: linear-gradient(100deg, var(--r2), var(--r1));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.modal-card.rarity-legendary h2 {
  filter: drop-shadow(0 4px 10px rgba(240, 161, 44, .2));
}

.prize-desc {
  position: relative;
  z-index: 2;
  margin: 0 auto;
  max-width: 19em;
  font-size: 13px;
  line-height: 1.75;
  color: var(--ink-soft);
}

.modal-dog {
  position: relative;
  z-index: 2;
  display: block;
  width: clamp(98px, 27vw, 126px);
  height: auto;
  margin: 14px auto 0;
  transform: rotate(-6deg);
  filter: drop-shadow(0 14px 18px rgba(80, 50, 30, .22));
  animation: prizePop .6s .16s cubic-bezier(.2, 1.6, .4, 1) both;
}

.modal-actions {
  position: relative;
  z-index: 2;
  display: flex;
  gap: 10px;
  margin-top: 24px;
}

.primary-btn {
  flex: 1;
  padding: 14px 16px;
  border: 0;
  border-radius: 16px;
  cursor: pointer;
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 900;
  letter-spacing: .04em;
  color: #fff;
  background: linear-gradient(100deg, var(--r2), var(--r1));
  box-shadow: 0 16px 26px -16px var(--r2), inset 0 2px 0 rgba(255, 255, 255, .35);
  transition: transform .2s ease, box-shadow .2s ease;
}

.primary-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 20px 30px -16px var(--r2), inset 0 2px 0 rgba(255, 255, 255, .35);
}

.primary-btn:active {
  transform: translateY(1px) scale(.99);
}

.primary-btn:focus-visible {
  outline: 3px solid var(--r1);
  outline-offset: 3px;
}

.ghost-btn {
  flex: 1;
  display: grid;
  place-items: center;
  padding: 14px 16px;
  border-radius: 16px;
  background: rgba(255, 255, 255, .82);
  border: 1.5px solid rgba(61, 48, 42, .1);
  color: var(--ink);
  font-size: 13.5px;
  font-weight: 800;
  text-decoration: none;
  transition: background .2s ease, transform .2s ease;
}

.ghost-btn:hover {
  background: #fff;
  transform: translateY(-2px);
}

.ghost-btn:focus-visible {
  outline: 3px solid var(--r1);
  outline-offset: 3px;
}

.modal-note {
  position: relative;
  z-index: 2;
  margin: 16px 0 0;
  font-size: 10.5px;
  color: var(--ink-soft);
  opacity: .8;
}

/* ---------- toast ---------- */

.toast {
  position: fixed;
  left: 50%;
  bottom: calc(24px + env(safe-area-inset-bottom));
  z-index: 80;
  padding: 10px 18px;
  border-radius: 999px;
  background: rgba(61, 48, 42, .9);
  color: #fff;
  font-size: 12px;
  font-weight: 600;
  box-shadow: 0 16px 30px -18px rgba(0, 0, 0, .6);
  opacity: 0;
  transform: translate(-50%, 12px);
  pointer-events: none;
  transition: opacity .25s ease, transform .25s ease;
}

.toast.show {
  opacity: 1;
  transform: translate(-50%, 0);
}

/* ---------- keyframes ---------- */

@keyframes viewIn {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes gradientShift {
  0%, 100% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
}

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

@keyframes drift {
  from { transform: translate3d(-12px, 0, 0); }
  to { transform: translate3d(26px, -8px, 0); }
}

@keyframes floaty {
  0%, 100% { transform: translateY(0) rotate(var(--r, 0deg)); }
  50% { transform: translateY(-11px) rotate(var(--r, 0deg)); }
}

@keyframes bob {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-9px); }
}

@keyframes sceneFloat {
  0%, 100% { transform: translateY(0) rotate(-1deg); }
  50% { transform: translateY(-11px) rotate(.7deg); }
}

@keyframes twinkle {
  0%, 100% { opacity: .35; transform: scale(.82); }
  50% { opacity: 1; transform: scale(1.08); }
}

@keyframes btnShine {
  0%, 55% { left: -30%; }
  100% { left: 130%; }
}

@keyframes lidWiggle {
  0% { transform: rotate(0); }
  30% { transform: rotate(-4deg) translateY(-2px); }
  65% { transform: rotate(3deg); }
  100% { transform: rotate(0); }
}

@keyframes bowWiggle {
  0%, 100% { transform: translateX(-50%) rotate(-2deg); }
  40% { transform: translateX(-50%) rotate(4deg) scale(1.04); }
  70% { transform: translateX(-50%) rotate(-5deg); }
}

@keyframes pawJump {
  0%, 100% { transform: translateY(0) rotate(-6deg); }
  50% { transform: translateY(-5px) rotate(8deg); }
}

@keyframes ringBurst {
  0% { opacity: .9; transform: scale(.72); }
  70% { opacity: .45; }
  100% { opacity: 0; transform: scale(1.28); }
}

@keyframes modalIn {
  from { opacity: 0; transform: translateY(18px) scale(.9); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes prizePop {
  from { opacity: 0; transform: scale(.4) rotate(-16deg); }
  to { opacity: 1; transform: scale(1) rotate(0); }
}

@keyframes legendaryGlow {
  0%, 100% { box-shadow: 0 18px 32px -18px var(--rglow), 0 0 0 8px rgba(255, 255, 255, .55), 0 0 26px 4px rgba(255, 210, 90, .18); }
  50% { box-shadow: 0 18px 32px -18px var(--rglow), 0 0 0 8px rgba(255, 255, 255, .55), 0 0 44px 12px rgba(255, 210, 90, .38); }
}

/* ---------- responsive ---------- */

@media (max-width: 900px) {
  .hero {
    grid-template-columns: 1fr;
    padding-bottom: 30px;
  }

  .hero-art {
    min-height: 300px;
    margin-top: 10px;
  }

  .hero-float-dog {
    width: clamp(84px, 22%, 116px);
  }

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

@media (max-width: 720px) {
  .topbar {
    padding-left: 16px;
    padding-right: 16px;
  }

  .total-chip {
    padding: 8px 12px;
    font-size: 11.5px;
  }

  .section-head {
    align-items: flex-start;
    flex-direction: column;
    gap: 8px;
  }

  .section-tip {
    display: none;
  }

  .hero {
    gap: 12px;
    padding-top: 18px;
  }

  .hero-art {
    min-height: 260px;
  }

  .hero-note {
    font-size: 10.5px;
    bottom: -12px;
  }

  .mini-gift {
    width: 60px;
    height: 50px;
  }

  .play-paw {
    display: none;
  }

  .play-heading {
    align-items: flex-start;
  }

  .foot {
    flex-direction: column;
    gap: 4px;
  }

  .modal-actions {
    flex-direction: column-reverse;
  }
}

@media (max-width: 560px) {
  .brand-text {
    font-size: 16px;
  }

  .brand-badge {
    width: 42px;
    height: 42px;
    border-radius: 14px;
  }

  .brand-badge svg {
    width: 35px;
    height: 35px;
  }

  .total-chip {
    display: none;
  }

  h1 {
    font-size: clamp(38px, 11.6vw, 52px);
  }

  .lede br {
    display: none;
  }

  .hero-badges {
    gap: 8px;
  }

  .hero-badges span {
    padding: 7px 11px;
    font-size: 11px;
  }

  .entry-grid {
    grid-template-columns: 1fr;
  }

  .entry-card {
    min-height: 190px;
  }

  .play-bar {
    margin-bottom: 12px;
  }

  .stat-chip {
    padding: 7px 11px;
    font-size: 10.5px;
  }

  .play-copy p:last-child {
    font-size: 11.5px;
  }

  .panel {
    padding: 16px 14px 20px;
  }

  .box-grid {
    gap: 8px;
  }

  .draw-btn {
    width: 100%;
  }

  .draw-btn-inner {
    width: 100%;
    padding: 15px 20px;
  }

  .draw-tip {
    font-size: 10px;
  }

  .modal-layer {
    padding: 12px;
  }

  .modal-card {
    border-radius: 28px;
    padding: 24px 18px 20px;
  }

  .prize-rays {
    top: 128px;
    width: 240px;
    height: 240px;
  }

  .prize-emoji {
    width: 84px;
    height: 84px;
    font-size: 42px;
  }
}

@media (max-width: 380px) {
  .play-stats {
    gap: 5px;
  }

  .stat-chip {
    padding: 6px 9px;
  }

  .play-emoji {
    width: 56px;
    border-radius: 20px;
  }

  .box-grid {
    gap: 6px;
  }
}

@media (hover: none) {
  .entry-card:hover {
    transform: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
  }
}
