/* 萌猫小店合成记 —— 竖屏合成经营 */
:root {
  --brand: #FF8A3D;
  --brand-2: #FFB35E;
  --brand-deep: #D95F16;
  --brand-glow: rgba(255, 150, 60, .45);
  --ink: #5B341B;
  --ink-soft: #8A613B;
  --cream: #FFF8E8;
  --cream-2: #FFEFCF;
  --gold: #F5B53B;
  --gold-deep: #B96A0A;
  --green: #62BD45;
  --green-deep: #2F7C22;
  --wood-a: #E8B36D;
  --wood-b: #C98B4D;
  --wood-c: #A96833;
  --wood-edge: #7B451F;
  --tile-a: #FCEBCB;
  --tile-b: #F1D2A0;
  --tile-edge: #D9AC72;
  --danger: #D9523B;
  --safe-top: env(safe-area-inset-top, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body {
  margin: 0; padding: 0; height: 100%;
  overflow: hidden;
  overscroll-behavior: none;
  background: #5d351b;
}
body {
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans SC", "Helvetica Neue", sans-serif;
  color: var(--ink);
  display: flex;
  align-items: center;
  justify-content: center;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  user-select: none;
  -webkit-user-select: none;
}
button { font-family: inherit; cursor: pointer; border: 0; background: none; padding: 0; color: inherit; }
img { display: block; }

/* ---------- 背景 ---------- */
.bg-wash {
  position: fixed; inset: 0; z-index: 0; overflow: hidden;
  background:
    radial-gradient(110% 60% at 50% 0%, #CBEAF7 0%, #FBE4B8 34%, #F0C184 60%, #C9925D 100%),
    #D9874C;
}
.bg-wash::before {
  content: ""; position: absolute; inset: -10%;
  background: url("images/gen/scene.png") center 30% / cover no-repeat;
  filter: blur(32px) saturate(1.22) brightness(.92);
  opacity: .78;
  transform: scale(1.07);
}
.bg-wash::after {
  content: ""; position: absolute; inset: 0;
  background:
    radial-gradient(120% 70% at 50% 0%, rgba(255, 245, 210, .45) 0%, transparent 56%),
    linear-gradient(180deg, rgba(65, 34, 12, .04) 0%, rgba(86, 44, 17, .18) 55%, rgba(53, 26, 8, .5) 100%);
}
.bg-sparkles { position: fixed; inset: 0; z-index: 1; pointer-events: none; overflow: hidden; }
.bg-sparkles i {
  position: absolute; width: 8px; height: 8px; border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 250, 210, .95), rgba(255, 214, 130, 0));
  animation: drift 12s linear infinite;
  opacity: .55;
}
.bg-sparkles i:nth-child(1) { left: 8%; top: 74%; animation-delay: -1s; }
.bg-sparkles i:nth-child(2) { left: 22%; top: 38%; width: 5px; height: 5px; animation-delay: -5s; }
.bg-sparkles i:nth-child(3) { left: 82%; top: 66%; width: 6px; height: 6px; animation-delay: -8s; }
.bg-sparkles i:nth-child(4) { left: 68%; top: 22%; width: 4px; height: 4px; animation-delay: -3s; }
.bg-sparkles i:nth-child(5) { left: 46%; top: 88%; width: 5px; height: 5px; animation-delay: -9s; }
.bg-sparkles i:nth-child(6) { left: 92%; top: 32%; width: 7px; height: 7px; animation-delay: -6s; }
.bg-sparkles i:nth-child(7) { left: 12%; top: 16%; width: 4px; height: 4px; animation-delay: -2s; }
.bg-sparkles i:nth-child(8) { left: 58%; top: 76%; width: 4px; height: 4px; animation-delay: -11s; }

/* ---------- 应用外壳 ---------- */
.app {
  position: relative; z-index: 2;
  width: 100%; max-width: 460px;
  height: 100vh; height: 100dvh;
  margin: 0 auto;
  display: flex; flex-direction: column;
  gap: 8px;
  padding: 0 12px calc(var(--safe-bottom) + 8px);
  isolation: isolate;
}

/* ---------- 店铺场景（顶部整幅） ---------- */
.stage {
  position: relative; flex: 0 0 auto;
  height: clamp(196px, 25.5vh, 240px);
  margin: 0 -12px;
  border-radius: 0 0 30px 30px;
  overflow: hidden;
  background: #D9A46B;
  border-bottom: 3px solid #FFE7BC;
  box-shadow: 0 9px 24px rgba(64, 32, 10, .34);
  isolation: isolate;
}
.stage::before {
  content: ""; position: absolute; left: 0; right: 0; top: 0; height: 104px; z-index: 2;
  background: linear-gradient(180deg, rgba(58, 31, 13, .46) 0%, rgba(58, 31, 13, .18) 55%, transparent 100%);
  pointer-events: none;
}
.scene-art {
  position: absolute; inset: 0;
  background: url("images/gen/scene.png") center 34% / cover no-repeat;
  transform: scale(1.015);
  transition: filter .45s ease, transform .6s ease;
}
.scene-vignette {
  position: absolute; inset: 0;
  background:
    linear-gradient(180deg, rgba(70, 35, 10, .1), transparent 34%, rgba(70, 35, 10, .26) 100%),
    radial-gradient(125% 95% at 50% 16%, transparent 52%, rgba(84, 42, 12, .2));
}
.scene-glint {
  position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(115deg, transparent 24%, rgba(255, 244, 210, .16) 36%, transparent 48%);
  mix-blend-mode: screen;
  animation: glint 7.5s ease-in-out infinite;
}

/* ---------- 顶部玩家栏（浮在场景上） ---------- */
.hud {
  position: absolute; z-index: 30;
  top: calc(var(--safe-top) + 10px); left: 12px; right: 12px;
  display: flex; align-items: center; gap: 6px;
  min-height: 44px;
}
.profile-btn { position: relative; flex: 0 0 auto; width: 44px; height: 44px; border-radius: 50%; }
.avatar-frame {
  display: block; width: 44px; height: 44px; border-radius: 50%;
  padding: 2px;
  background: linear-gradient(145deg, #FFF3BE, #F4B146 62%, #C77816);
  box-shadow: 0 2px 0 #8C4B17, 0 5px 12px rgba(50, 25, 5, .42);
}
.avatar-frame img {
  width: 100%; height: 100%; border-radius: 50%; object-fit: cover;
  border: 2px solid #FFF8E6; background: #FFE3B8;
}
.level-chip {
  position: absolute; left: 50%; bottom: -5px; transform: translateX(-50%);
  height: 16px; padding: 0 6px; border-radius: 8px;
  background: linear-gradient(#FFC15E, #FF7C25);
  border: 1.5px solid #FFE6B4;
  box-shadow: 0 2px 0 #A94D0B;
  color: #fff; font-size: 8.5px; font-weight: 900; line-height: 14px;
  white-space: nowrap; letter-spacing: .2px;
}
.level-chip b { font-size: 9.5px; }
.who { min-width: 0; flex: 1 1 auto; display: flex; flex-direction: column; gap: 3px; padding-left: 2px; }
.who-top { display: flex; align-items: center; gap: 5px; min-width: 0; }
.who-name {
  font-size: 12.5px; font-weight: 900; color: #FFF8E7;
  text-shadow: 0 1.5px 2px rgba(62, 29, 7, .8);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  line-height: 1.1; max-width: 88px;
}
.shop-tag {
  display: inline-flex; align-items: center; gap: 3px;
  height: 14px; padding: 0 6px; border-radius: 7px;
  background: rgba(79, 42, 17, .48);
  border: 1px solid rgba(255, 224, 173, .32);
  color: #FFE5B9; font-size: 7.5px; font-weight: 800;
  white-space: nowrap; flex: 0 0 auto;
}
.online-dot { width: 4px; height: 4px; border-radius: 50%; background: #A8F27A; box-shadow: 0 0 5px #A8F27A; flex: 0 0 auto; }
.level-track {
  position: relative; height: 14px; border-radius: 8px;
  background: linear-gradient(180deg, rgba(57, 30, 12, .86), rgba(43, 22, 8, .92));
  border: 1.5px solid rgba(255, 223, 168, .72);
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, .28), 0 1px 0 rgba(255, 255, 255, .18);
  overflow: hidden;
  min-width: 0;
}
.level-track > i {
  position: absolute; left: 0; top: 0; bottom: 0; width: 0%;
  background: linear-gradient(90deg, #FFB23E, #FFD76A 58%, #FFE9A3);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .55);
  border-radius: 8px;
  transition: width .45s cubic-bezier(.22, 1, .36, 1);
}
.level-track > em {
  position: absolute; inset: 0; z-index: 2;
  display: flex; align-items: center; justify-content: center;
  font-style: normal; font-size: 8px; font-weight: 900; color: #FFF8E2;
  letter-spacing: .3px; text-shadow: 0 1px 1px rgba(80, 38, 8, .9);
  font-variant-numeric: tabular-nums;
}
.level-star {
  position: absolute; left: -1px; top: 50%; transform: translateY(-50%);
  z-index: 3; width: 19px; height: 19px; border-radius: 50%; overflow: hidden;
  border: 1.5px solid #FFE7A9; background: #F5B53B;
  box-shadow: 0 1px 2px rgba(70, 30, 4, .4);
}
.level-star img { width: 100%; height: 100%; object-fit: cover; }
.level-track > em { padding-left: 16px; }
.coin-pill {
  margin-left: 1px; flex: 0 0 auto;
  display: flex; align-items: center; gap: 4px;
  height: 33px; padding: 0 9px 0 3px;
  border-radius: 999px;
  background: linear-gradient(180deg, #7B4A24, #4D2813);
  border: 2px solid #E9BB72;
  box-shadow: 0 3px 0 #2F1809, inset 0 1px 0 rgba(255, 231, 185, .32);
}
.coin-face {
  width: 25px; height: 25px; border-radius: 50%;
  background: radial-gradient(circle at 34% 28%, #FFF6BC, #FFCE48 55%, #EE9B14);
  border: 1.5px solid #B96A0A;
  display: grid; place-items: center; color: #A25B08;
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, .8);
}
.coin-face .mp-icon { width: 14px; height: 14px; }
#coinNum {
  font-size: 14px; font-weight: 900; color: #FFF4D2;
  font-variant-numeric: tabular-nums; letter-spacing: .2px;
  text-shadow: 0 1px 0 rgba(0, 0, 0, .35);
  min-width: 26px; text-align: center;
}
.hud-btns { display: flex; gap: 4px; flex: 0 0 auto; }
.round-btn {
  width: 30px; height: 30px; border-radius: 50%;
  background: linear-gradient(180deg, rgba(255, 249, 230, .97), rgba(255, 224, 172, .95));
  border: 1.5px solid #EFC17D;
  box-shadow: 0 2px 0 rgba(120, 72, 26, .55), inset 0 1px 0 #fff;
  color: #A0612A; display: grid; place-items: center;
  overflow: hidden;
}
.round-btn:active { transform: translateY(1px); box-shadow: 0 1px 0 rgba(120, 72, 26, .55); }
.round-btn .mp-icon { width: 17px; height: 17px; }
.gear-btn {
  border-radius: 10px; border-color: #B97B38;
  background: #E9BB7B;
  box-shadow: 0 2px 0 rgba(110, 62, 20, .55), 0 0 0 1.5px rgba(255, 235, 194, .5);
}
.gear-btn img { width: 100%; height: 100%; object-fit: cover; }
.gear-btn:active { transform: translateY(1px); }

/* ---------- 离线产出 ---------- */
.offline-card {
  position: absolute; left: 10px; bottom: 10px; z-index: 5;
  display: flex; align-items: center; gap: 5px;
  padding: 5px 6px 5px 5px; border-radius: 15px;
  background: linear-gradient(180deg, rgba(255, 251, 238, .98), rgba(255, 226, 174, .98));
  border: 2px solid rgba(255, 241, 209, .98);
  box-shadow: 0 3px 0 rgba(125, 68, 22, .4), 0 7px 16px rgba(50, 24, 6, .22);
  text-align: left;
  max-width: 158px;
}
.offline-card:active { transform: translateY(1px); box-shadow: 0 2px 0 rgba(125, 68, 22, .4); }
.offline-card.ready .offline-thumb { animation: readyPulse 2.6s ease-in-out infinite; }
.offline-thumb {
  position: relative; width: 40px; height: 40px; flex: 0 0 auto;
  border-radius: 10px; overflow: hidden;
  border: 1.5px solid #E0AB61; background: #FFE3B2;
}
.offline-thumb img { width: 100%; height: 100%; object-fit: cover; object-position: 52% 46%; }
.zzz {
  position: absolute; right: 1px; top: 1px;
  font-size: 6.5px; font-weight: 900; color: #855527;
  background: rgba(255, 247, 224, .94); border-radius: 5px; padding: 0 2px; line-height: 1.45;
}
.offline-copy { display: flex; flex-direction: column; line-height: 1.05; gap: 2px; min-width: 0; }
.offline-copy b { font-size: 10px; color: #6E3E1D; letter-spacing: .2px; white-space: nowrap; }
.offline-copy span { font-size: 8px; color: #A27241; font-weight: 700; white-space: nowrap; }
.offline-side { display: flex; flex-direction: column; align-items: flex-end; gap: 2px; flex: 0 0 auto; }
.offline-reward { display: flex; align-items: center; gap: 1px; color: #B4600F; font-size: 11px; font-weight: 900; }
.mini-coin {
  width: 11px; height: 11px; border-radius: 50%; display: inline-block; flex: 0 0 auto;
  background: radial-gradient(circle at 34% 30%, #FFF6BC, #FFCE48 58%, #EE9B14);
  border: 1px solid #B96A0A;
}
.offline-play {
  width: 20px; height: 20px; flex: 0 0 auto; border-radius: 50%;
  background: linear-gradient(#82D6FF, #2A99E6);
  border: 1.5px solid #EAF8FF;
  box-shadow: 0 2px 0 #12638F;
  color: #fff; display: grid; place-items: center;
  animation: playPulse 2.4s ease-in-out infinite;
}
.offline-play .mp-icon { width: 12px; height: 12px; }

/* ---------- 顾客气泡 ---------- */
.scene-customer {
  position: absolute; right: 10px; bottom: 9px; z-index: 5;
  display: flex; flex-direction: column; align-items: flex-end; gap: 3px;
}
.speech {
  position: relative;
  width: 156px; padding: 6px 7px 6px;
  border-radius: 14px;
  background: linear-gradient(180deg, #FFFDF4, #FFF0CE);
  border: 2px solid #F3D29B;
  box-shadow: 0 3px 0 rgba(120, 66, 20, .27), inset 0 1px 0 #fff;
  display: flex; flex-direction: column; gap: 3px;
}
.speech::after {
  content: ""; position: absolute; right: 15px; bottom: -6px;
  width: 9px; height: 9px; transform: rotate(45deg);
  background: #FFF0CE;
  border-right: 2px solid #F3D29B; border-bottom: 2px solid #F3D29B;
}
.speech-tag { font-size: 8.5px; font-weight: 900; color: #9C6734; line-height: 1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.speech-wants { display: flex; align-items: center; gap: 5px; min-height: 24px; }
.speech-want { display: flex; align-items: center; gap: 2px; }
.speech-want img {
  width: 24px; height: 24px; border-radius: 6px; object-fit: cover;
  background: #F7D9A8; border: 1px solid #E5B77A;
}
.speech-want span { font-size: 8.5px; font-weight: 900; color: #6E421F; line-height: 1; }
.speech-want span.lack { color: #C24A38; }
.speech-want span.ok { color: #4F9A3A; }
.speech-foot { display: flex; align-items: center; justify-content: space-between; gap: 4px; }
.speech-reward { display: flex; align-items: center; gap: 2px; font-size: 10px; font-weight: 900; color: #B4600F; }
.speech-btn {
  height: 21px; padding: 0 9px; border-radius: 7px;
  border: 1.5px solid #DD9E4C;
  background: linear-gradient(#FFF3D2, #F6D394);
  color: #985517; font-size: 9.5px; font-weight: 900;
  box-shadow: 0 2px 0 #C4833B;
  white-space: nowrap;
}
.speech-btn:active { transform: translateY(1px); box-shadow: 0 1px 0 #C4833B; }
.speech-btn.ready {
  background: linear-gradient(#9BE87F, #54B93C);
  border-color: #3F9230; color: #fff;
  box-shadow: 0 2px 0 #2F7522;
  animation: readyPulse 1.6s ease-in-out infinite;
}
.customer-face {
  width: 39px; height: 39px; border-radius: 50%; overflow: hidden; margin-right: 2px;
  border: 2px solid #FFF2D2; background: #FFE4BD;
  box-shadow: 0 2px 0 rgba(100, 50, 15, .45);
}
.customer-face img { width: 100%; height: 100%; object-fit: cover; }

/* ---------- 棋盘 ---------- */
.board-wrap {
  flex: 1 1 auto; min-height: 0;
  display: flex; flex-direction: column; align-items: center; gap: 4px;
  margin-top: -9px;
  position: relative; z-index: 3;
}
.board-hint {
  flex: 0 0 auto; max-width: 96%;
  display: flex; align-items: center; gap: 4px;
  height: 21px; padding: 0 11px; border-radius: 999px;
  background: rgba(255, 247, 228, .9);
  border: 1px solid rgba(226, 187, 127, .9);
  box-shadow: 0 1px 0 rgba(255, 255, 255, .7), 0 2px 7px rgba(70, 35, 10, .16);
  color: #8A5A2E; font-size: 9.5px; font-weight: 800;
  white-space: nowrap; overflow: hidden;
}
.board-hint .mp-icon { width: 11px; height: 11px; color: #E58A2B; flex: 0 0 auto; }
#hintText { overflow: hidden; text-overflow: ellipsis; }
.board-stage {
  flex: 1 1 auto; width: 100%; min-height: 0;
  display: flex; align-items: center; justify-content: center;
  padding: 1px 0;
}
.board {
  position: relative;
  display: grid; gap: 6px; padding: 9px;
  border-radius: 23px;
  background:
    radial-gradient(circle at 9px 9px, rgba(91, 52, 24, .9) 0 1.4px, transparent 2.4px),
    radial-gradient(circle at calc(100% - 9px) 9px, rgba(91, 52, 24, .9) 0 1.4px, transparent 2.4px),
    radial-gradient(circle at 9px calc(100% - 9px), rgba(91, 52, 24, .9) 0 1.4px, transparent 2.4px),
    radial-gradient(circle at calc(100% - 9px) calc(100% - 9px), rgba(91, 52, 24, .9) 0 1.4px, transparent 2.4px),
    linear-gradient(155deg, var(--wood-a), var(--wood-b) 58%, var(--wood-c));
  border: 2px solid var(--wood-edge);
  box-shadow:
    0 0 0 3px #FFE4B0,
    0 7px 0 #74401C,
    0 16px 28px rgba(55, 27, 7, .38),
    inset 0 2px 0 rgba(255, 231, 190, .55);
  touch-action: none;
  user-select: none; -webkit-user-select: none;
  transition: box-shadow .2s;
}
.board::before {
  content: ""; position: absolute; inset: 4px; border-radius: 18px;
  border: 1px solid rgba(255, 227, 185, .26);
  pointer-events: none;
}
.board.shake { animation: shake .32s ease; }
.cell {
  position: relative; min-width: 0; min-height: 0;
  border-radius: 12px;
  border: 1.5px solid var(--tile-edge);
  background:
    radial-gradient(120% 100% at 22% 12%, rgba(255, 255, 255, .55), transparent 55%),
    linear-gradient(150deg, var(--tile-a), var(--tile-b) 74%, #E9C48D);
  box-shadow: inset 0 2px 3px rgba(255, 250, 235, .85), inset 0 -3px 4px rgba(150, 100, 50, .18);
  display: flex; align-items: center; justify-content: center;
  overflow: hidden;
  transition: transform .12s ease, box-shadow .15s ease, background .15s ease;
  touch-action: none;
}
.cell img.item {
  width: 93%; height: 93%; object-fit: contain;
  filter: drop-shadow(0 2px 2px rgba(90, 50, 20, .28));
  pointer-events: none;
  -webkit-user-drag: none;
}
.cell .tier-pips {
  position: absolute; left: 4px; bottom: 3px;
  display: flex; gap: 1.5px; pointer-events: none;
}
.cell .tier-pips i {
  width: 3.5px; height: 3.5px; border-radius: 50%;
  background: var(--pip, #C7863E);
  box-shadow: 0 0 0 .5px rgba(255, 245, 220, .6);
}
.cell.empty {
  background: linear-gradient(150deg, rgba(251, 231, 198, .5), rgba(232, 197, 146, .4));
  border-style: dashed;
  border-color: rgba(173, 122, 70, .5);
  box-shadow: inset 0 2px 4px rgba(120, 70, 30, .1);
}
.cell.empty::before, .cell.empty::after {
  content: ""; position: absolute; border-radius: 2px;
  background: linear-gradient(#D8A063, #C18748); opacity: .5;
}
.cell.empty::before { width: 15px; height: 3px; }
.cell.empty::after { width: 3px; height: 15px; }
.cell.selected {
  background: linear-gradient(150deg, #FFF6D5, #F9D89E);
  box-shadow: 0 0 0 2.5px #FFD264, 0 0 18px rgba(255, 177, 55, .9), inset 0 2px 4px rgba(255, 255, 255, .9);
  transform: scale(.94);
  z-index: 2;
}
.cell.drop-target {
  background: linear-gradient(150deg, #FFF9E1, #FCE1AD);
  box-shadow: 0 0 0 2.5px #FFA62E, 0 0 20px rgba(255, 154, 40, .85), inset 0 2px 5px rgba(255, 255, 255, .9);
  transform: scale(.96);
}
.cell.merge-pop img.item { animation: itemPop .36s cubic-bezier(.2, 1.7, .4, 1); }
.cell.merge-pop { animation: cellFlash .5s ease; }
.cell.deny { animation: shake .3s ease; }
.drag-ghost {
  position: fixed; z-index: 50; width: 62px; height: 62px;
  object-fit: contain; pointer-events: none;
  filter: drop-shadow(0 8px 8px rgba(60, 30, 5, .35));
  transform: translate(-50%, -58%) scale(1.08) rotate(-4deg);
  transition: none;
}
.drag-ghost.over-merge { transform: translate(-50%, -58%) scale(1.18) rotate(0deg); filter: drop-shadow(0 0 12px rgba(255, 190, 70, .9)); }

/* ---------- 顾客订单 ---------- */
.orders {
  flex: 0 0 auto;
  display: flex; flex-direction: column; gap: 4px;
  padding: 6px 6px 7px;
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(255, 250, 238, .97), rgba(255, 235, 202, .96));
  border: 2px solid #EFCB97;
  box-shadow: 0 4px 0 rgba(132, 80, 30, .28), 0 9px 18px rgba(55, 27, 7, .2), inset 0 1px 0 #fff;
}
.orders-head { display: flex; align-items: center; justify-content: space-between; padding: 0 4px; }
.orders-head h2 {
  margin: 0; display: flex; align-items: center; gap: 4px;
  font-size: 12px; font-weight: 900; color: #6B3E1E;
  letter-spacing: .3px;
}
.orders-head h2 .mp-icon { width: 15px; height: 15px; color: #E58A2B; }
.orders-head > span { font-size: 8.5px; font-weight: 700; color: #A27241; }
.order-list {
  display: flex; gap: 5px;
  overflow-x: auto; overflow-y: hidden;
  padding: 0;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}
.order-list::-webkit-scrollbar { display: none; }
.order-card {
  flex: 1 1 0; min-width: 0;
  position: relative;
  border-radius: 12px; padding: 4px 5px 5px;
  background: linear-gradient(180deg, #FFFDF6, #FFF2D8);
  border: 1.5px solid #EAC78F;
  box-shadow: inset 0 1px 0 #fff;
  display: flex; flex-direction: column; gap: 3px;
}
.order-card.ready {
  border-color: #94D780;
  background: linear-gradient(180deg, #FCFFEF, #E9F8D2);
  box-shadow: 0 0 12px rgba(150, 225, 100, .3), inset 0 1px 0 #fff;
}
.order-card.enter { animation: orderIn .4s cubic-bezier(.2, 1.2, .4, 1); }
.oc-head { display: flex; align-items: center; gap: 3px; min-width: 0; }
.oc-face { width: 19px; height: 19px; border-radius: 50%; object-fit: cover; border: 1.5px solid #F3C98B; background: #FFE5BB; flex: 0 0 auto; }
.oc-name { font-size: 9px; font-weight: 900; color: #6B3E1E; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.oc-reward { margin-left: auto; display: flex; align-items: center; gap: 1px; font-size: 9px; font-weight: 900; color: #B4600F; flex: 0 0 auto; }
.oc-wants { display: flex; gap: 3px; flex: 1 1 auto; min-height: 32px; }
.oc-want {
  flex: 1 1 0; min-width: 0;
  display: flex; align-items: center; justify-content: center; gap: 1px;
  background: rgba(255, 255, 255, .6);
  border: 1px solid rgba(221, 182, 125, .6);
  border-radius: 7px; padding: 1px 1px;
}
.oc-want img { width: 24px; height: 24px; object-fit: cover; border-radius: 5px; background: #F8DDAD; flex: 0 0 auto; }
.oc-want span { font-size: 8px; font-weight: 900; color: #7A4A23; line-height: 1; white-space: nowrap; }
.oc-want span.lack { color: #C24A38; }
.oc-want span.ok { color: #4F9A3A; }
.oc-btn {
  height: 21px; flex: 0 0 auto;
  border-radius: 7px; border: 1.5px solid #E0A85C;
  background: linear-gradient(#FFF4D6, #F6D89E);
  color: #9A5B1D; font-size: 9px; font-weight: 900;
  display: flex; align-items: center; justify-content: center; gap: 2px;
  box-shadow: 0 2px 0 #C78B45;
  white-space: nowrap;
}
.oc-btn:active { transform: translateY(1px); box-shadow: 0 1px 0 #C78B45; }
.order-card.ready .oc-btn {
  background: linear-gradient(#9BE87F, #54B93C);
  border-color: #3F9230; color: #fff;
  box-shadow: 0 2px 0 #2F7522;
  animation: readyPulse 1.6s ease-in-out infinite;
}
.order-card.ready .oc-btn:active { box-shadow: 0 1px 0 #2F7522; }

/* ---------- 底部操作 ---------- */
.dock { flex: 0 0 auto; display: flex; gap: 6px; align-items: stretch; padding-top: 1px; }
.dock-btn {
  position: relative; flex: 1 1 0; min-width: 0; height: 58px;
  border-radius: 17px;
  border: 2px solid #EFCB97;
  background: linear-gradient(180deg, #FFFBF0, #FFE8BF);
  box-shadow: 0 4px 0 #C58B49, inset 0 1px 0 #fff;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1px;
  color: #7B4A22; padding: 3px 2px 4px;
  overflow: hidden;
}
.dock-btn::before {
  content: ""; position: absolute; left: 6px; right: 6px; top: 2px; height: 42%;
  border-radius: 12px 12px 40% 40%;
  background: linear-gradient(180deg, rgba(255, 255, 255, .5), transparent);
  pointer-events: none;
}
.dock-btn:active { transform: translateY(2px); box-shadow: 0 2px 0 #C58B49; }
.dock-btn.upgrade {
  flex: 1.28 1 0;
  background: linear-gradient(180deg, #A8EB7C, #58BE3B);
  border-color: #A6E886;
  box-shadow: 0 4px 0 #2F7C22, inset 0 1px 0 rgba(255, 255, 255, .55);
  color: #fff; text-shadow: 0 1px 1px rgba(40, 90, 20, .5);
}
.dock-btn.upgrade:active { box-shadow: 0 2px 0 #2F7C22; }
.dock-ico { display: grid; place-items: center; width: 30px; height: 30px; color: #A8642A; position: relative; z-index: 1; }
.dock-ico .mp-icon { width: 22px; height: 22px; }
.dock-ico img {
  width: 30px; height: 30px; object-fit: cover; border-radius: 8px;
  filter: drop-shadow(0 1px 1px rgba(90, 48, 12, .2));
}
.dock-btn.upgrade .dock-ico img { width: 31px; height: 31px; }
.restock-ico img {
  width: 30px; height: 28px; object-fit: cover; border-radius: 7px;
  border: 1px solid #D7A15E; background: #FFE3B0;
}
.dock-txt { font-size: 10px; font-weight: 900; line-height: 1; white-space: nowrap; position: relative; z-index: 1; }
.dock-cost { display: flex; align-items: center; gap: 2px; font-size: 8.5px; font-weight: 900; line-height: 1; color: #FFF7C9; position: relative; z-index: 1; }
.dock-cost .mini-coin { width: 9px; height: 9px; }
.cd-track {
  position: absolute; left: 11px; right: 11px; bottom: 4px; height: 3px;
  border-radius: 2px; background: rgba(150, 95, 40, .16); overflow: hidden;
}
.cd-track i { display: block; height: 100%; width: 0%; border-radius: 2px; background: linear-gradient(90deg, #FFC15C, #FF7A2E); }
.dock-btn.cooling { filter: saturate(.76) brightness(.98); }
.dock-btn.cooling .restock-ico img { filter: grayscale(.35) brightness(.9); }
.dock-btn.poor .dock-cost { color: #FFD7C9; }

/* ---------- 提示 & 特效 ---------- */
.toast {
  position: fixed; left: 50%; top: calc(var(--safe-top) + 70px);
  transform: translate(-50%, -8px);
  z-index: 60; max-width: 82vw;
  padding: 8px 15px; border-radius: 999px;
  background: rgba(73, 41, 19, .95);
  border: 1px solid rgba(255, 218, 160, .34);
  color: #FFF6E0; font-size: 11.5px; font-weight: 800;
  text-align: center; line-height: 1.3;
  opacity: 0; pointer-events: none;
  transition: opacity .2s ease, transform .2s ease;
  box-shadow: 0 8px 22px rgba(40, 18, 4, .35);
  backdrop-filter: blur(6px);
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.fx-layer { position: fixed; inset: 0; z-index: 55; pointer-events: none; overflow: hidden; }
.spark {
  position: absolute; width: 7px; height: 7px; border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #FFF8C9, #FFC23E 60%, #F0831E);
  box-shadow: 0 0 8px rgba(255, 196, 80, .8);
  animation: sparkFly .65s ease-out forwards;
}
.spark.star { border-radius: 2px; transform: rotate(45deg); }
.float-gain {
  position: absolute; font-size: 13px; font-weight: 900; color: #FFE27A;
  text-shadow: 0 2px 0 #A65A0F, 0 0 10px rgba(255, 190, 60, .6);
  animation: floatUp .9s ease-out forwards; white-space: nowrap;
}
.coin-fly {
  position: fixed; width: 16px; height: 16px; border-radius: 50%; z-index: 58;
  background: radial-gradient(circle at 34% 30%, #FFF6BC, #FFCE48 58%, #EE9B14);
  border: 1.5px solid #B96A0A;
  box-shadow: 0 0 8px rgba(255, 200, 60, .7);
}
.confetti {
  position: absolute; width: 6px; height: 9px; border-radius: 2px;
  animation: confettiFall 1s ease-out forwards;
}
.screen-glow {
  position: fixed; inset: 0; z-index: 54; pointer-events: none;
  background: radial-gradient(circle at 50% 45%, rgba(255, 226, 140, .45), transparent 62%);
  animation: glowFade .8s ease-out forwards;
}

/* ---------- 弹层 ---------- */
.sheet-mask {
  position: fixed; inset: 0; z-index: 70;
  background: rgba(45, 24, 10, .5);
  backdrop-filter: blur(2px);
  opacity: 0; pointer-events: none; transition: opacity .22s ease;
}
.sheet-mask.show { opacity: 1; pointer-events: auto; }
.sheet {
  position: fixed; left: 50%; bottom: 0; z-index: 80;
  width: min(100%, 460px); max-height: 86dvh; overflow-y: auto;
  transform: translate(-50%, 104%);
  transition: transform .3s cubic-bezier(.22, 1, .36, 1);
  background: linear-gradient(180deg, #FFF9EC, #FFF0D2 78%, #FFE9C2);
  border: 2px solid #F0CF98; border-bottom: 0;
  border-radius: 26px 26px 0 0;
  box-shadow: 0 -14px 44px rgba(60, 30, 10, .38);
  padding-bottom: calc(16px + var(--safe-bottom));
  -webkit-overflow-scrolling: touch;
}
.sheet.show { transform: translate(-50%, 0); }
.sheet-grip { width: 40px; height: 4px; border-radius: 2px; background: #E5C28C; margin: 8px auto 4px; }
.sheet-body { padding: 5px 18px 10px; }
.sheet-title { display: flex; align-items: center; gap: 7px; margin: 2px 0 4px; font-size: 18px; font-weight: 900; color: #5A3218; letter-spacing: .2px; }
.sheet-title .mp-icon { width: 21px; height: 21px; color: var(--brand); }
.sheet-sub { margin: 0 0 13px; font-size: 11px; line-height: 1.55; color: #94704B; }
.sheet-close {
  position: absolute; top: 10px; right: 12px; z-index: 2;
  width: 28px; height: 28px; border-radius: 50%;
  background: #F4E1C0; color: #9A713F;
  display: grid; place-items: center;
}
.sheet-close .mp-icon { width: 16px; height: 16px; }
.primary-btn {
  width: 100%; height: 48px; border-radius: 15px;
  border: 2px solid #FFC06A;
  background: linear-gradient(180deg, #FFB154, #FF7A2E);
  box-shadow: 0 5px 0 #C45213, inset 0 2px 0 rgba(255, 255, 255, .38);
  color: #fff; font-size: 14.5px; font-weight: 900; letter-spacing: .5px;
  display: flex; align-items: center; justify-content: center; gap: 5px;
  text-shadow: 0 1px 1px rgba(160, 70, 10, .4);
}
.primary-btn:active { transform: translateY(2px); box-shadow: 0 3px 0 #C45213; }
.primary-btn.green {
  border-color: #A6E886;
  background: linear-gradient(180deg, #A8EB7C, #58BE3B);
  box-shadow: 0 5px 0 #2F7C22, inset 0 2px 0 rgba(255, 255, 255, .45);
}
.primary-btn.green:active { box-shadow: 0 3px 0 #2F7C22; }
.primary-btn:disabled { filter: grayscale(.6) brightness(.92); opacity: .72; }
.ghost-btn {
  width: 100%; height: 42px; border-radius: 13px;
  background: #F7E4C2; border: 1px solid #E8C795;
  color: #92663A; font-size: 12.5px; font-weight: 900;
}
.ghost-btn:active { transform: translateY(1px); }
.sheet-actions { display: flex; flex-direction: column; gap: 8px; margin-top: 13px; }
.sheet-note { margin-top: 8px; font-size: 9.5px; line-height: 1.5; color: #A57D52; text-align: center; }

/* 升级面板 */
.level-hero {
  display: flex; align-items: center; justify-content: center; gap: 12px;
  padding: 10px 0 12px;
}
.level-badge {
  width: 62px; height: 62px; border-radius: 20px;
  display: grid; place-items: center;
  background: linear-gradient(155deg, #FFD684, #F09A28);
  border: 3px solid #FFF1C8;
  box-shadow: 0 5px 0 #B96A0A, inset 0 2px 0 rgba(255, 255, 255, .55);
  color: #fff; font-size: 13px; font-weight: 900; text-shadow: 0 1px 1px rgba(130, 65, 5, .5);
}
.level-badge b { display: block; font-size: 22px; line-height: 1; }
.level-arrow { color: #D8A258; }
.level-arrow .mp-icon { width: 26px; height: 26px; }
.level-badge.next { background: linear-gradient(155deg, #C4F49A, #62C144); box-shadow: 0 5px 0 #2F7C22, inset 0 2px 0 rgba(255, 255, 255, .5); }
.benefit-list { display: flex; flex-direction: column; gap: 7px; margin: 4px 0 13px; }
.benefit-row {
  display: flex; align-items: center; gap: 8px;
  padding: 8px 10px; border-radius: 11px;
  background: rgba(255, 255, 255, .55);
  border: 1px solid rgba(224, 189, 134, .65);
  font-size: 10.5px; font-weight: 700; color: #7E5730;
}
.benefit-row .mp-icon { width: 17px; height: 17px; color: #E38A2B; flex: 0 0 auto; }
.benefit-row b { color: #B45F14; }

/* 装修 */
.decor-list { display: flex; flex-direction: column; gap: 8px; }
.decor-item {
  display: flex; align-items: center; gap: 10px;
  padding: 7px; border-radius: 14px;
  background: rgba(255, 255, 255, .55);
  border: 1.5px solid rgba(224, 189, 134, .7);
  text-align: left;
}
.decor-item.current { border-color: #7DCB5E; background: rgba(238, 255, 225, .8); box-shadow: 0 0 0 1px #B7E9A4; }
.decor-preview {
  width: 58px; height: 46px; border-radius: 10px; overflow: hidden; flex: 0 0 auto;
  border: 1.5px solid #E7BF85; background: #FFE4B8;
}
.decor-preview img { width: 100%; height: 100%; object-fit: cover; object-position: center 30%; }
.decor-info { min-width: 0; flex: 1; display: flex; flex-direction: column; gap: 2px; }
.decor-info b { font-size: 12px; font-weight: 900; color: #60391D; }
.decor-info span { font-size: 9px; color: #9A7148; }
.decor-act { flex: 0 0 auto; }
.decor-act .mini-btn {
  height: 28px; padding: 0 11px; border-radius: 9px;
  background: linear-gradient(#FFE6AE, #FFC261);
  border: 1.5px solid #E3A64A;
  box-shadow: 0 2px 0 #B47824;
  color: #8A5115; font-size: 10px; font-weight: 900;
  display: flex; align-items: center; gap: 2px;
}
.decor-act .mini-btn.owned { background: #EAF6E1; border-color: #B6DB9F; color: #5E9444; box-shadow: none; }
.decor-act .mini-btn.current { background: #DDF3D2; border-color: #9BD184; color: #4E8B37; box-shadow: none; }

/* 扩建 */
.expand-visual { display: flex; align-items: center; justify-content: center; gap: 14px; padding: 8px 0 14px; }
.mini-grid { display: grid; gap: 3px; padding: 6px; border-radius: 10px; background: linear-gradient(155deg, var(--wood-a), var(--wood-b)); box-shadow: 0 3px 0 #74401C; }
.mini-grid i { width: 16px; height: 13px; border-radius: 3px; background: linear-gradient(#FBE7C4, #EBC58F); border: 1px solid #D4A56B; }
.mini-grid i.new { background: linear-gradient(#C8F3A9, #8DD970); border-color: #6DB554; }
.expand-meta { text-align: center; }
.expand-meta b { display: block; font-size: 20px; font-weight: 900; color: #B45F14; }
.expand-meta span { font-size: 10px; color: #9A7148; }

/* 离线 */
.offline-hero {
  position: relative; height: 108px; margin: 2px 0 10px; border-radius: 16px; overflow: hidden;
  border: 2px solid #F0CD94; background: linear-gradient(180deg, #FFE9C4, #FFD79E);
}
.offline-hero img { width: 100%; height: 100%; object-fit: cover; object-position: center 52%; }
.offline-hero::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 50%, rgba(90, 45, 12, .3)); }
.offline-stats { display: flex; gap: 7px; margin-bottom: 13px; }
.offline-stat {
  flex: 1; padding: 8px 4px; border-radius: 12px; text-align: center;
  background: rgba(255, 255, 255, .6);
  border: 1px solid rgba(224, 189, 134, .7);
}
.offline-stat b { display: block; font-size: 15px; font-weight: 900; color: #B45F14; line-height: 1.2; }
.offline-stat span { font-size: 8.5px; color: #98724B; font-weight: 700; }
.offline-items { display: flex; gap: 5px; flex-wrap: wrap; margin-bottom: 12px; }
.offline-items img { width: 31px; height: 31px; object-fit: cover; border-radius: 7px; border: 1px solid #E5B77A; background: #F8DDAD; }

/* 档案 */
.profile-hero { display: flex; align-items: center; gap: 12px; padding: 4px 0 14px; }
.profile-avatar {
  width: 64px; height: 64px; border-radius: 50%; overflow: hidden; flex: 0 0 auto;
  border: 3px solid #FFE6B0; background: #FFE4BA;
  box-shadow: 0 4px 0 #B97A2E;
}
.profile-avatar img { width: 100%; height: 100%; object-fit: cover; }
.profile-meta b { display: block; font-size: 16px; font-weight: 900; color: #5A3218; }
.profile-meta span { font-size: 10px; color: #9A7148; }
.profile-stats { display: flex; gap: 7px; margin: 0 0 13px; }
.profile-stat { flex: 1; text-align: center; padding: 9px 3px; border-radius: 12px; background: rgba(255, 255, 255, .58); border: 1px solid rgba(224, 189, 134, .7); }
.profile-stat b { display: block; font-size: 15px; font-weight: 900; color: #B45F14; }
.profile-stat span { font-size: 8.5px; color: #98724B; font-weight: 700; }
.field { margin-bottom: 11px; }
.field label { display: block; font-size: 10px; font-weight: 900; color: #8C6038; margin-bottom: 5px; }
.field input {
  width: 100%; height: 42px; padding: 0 13px; border-radius: 12px;
  border: 1.5px solid #E4C08A; background: #FFFCF4;
  color: #5A3218; font-size: 13px; font-weight: 700; outline: none;
}
.field input:focus { border-color: #F0A548; box-shadow: 0 0 0 3px rgba(255, 170, 70, .16); }
.field input:disabled { color: #9E7B55; background: #F6EAD5; }

/* 玩法说明 */
.help-list { display: flex; flex-direction: column; gap: 7px; }
.help-row { display: flex; gap: 9px; align-items: flex-start; padding: 8px 9px; border-radius: 12px; background: rgba(255, 255, 255, .55); border: 1px solid rgba(224, 189, 134, .62); }
.help-step {
  width: 22px; height: 22px; flex: 0 0 auto; border-radius: 50%;
  background: linear-gradient(#FFC15E, #FF8A3D);
  color: #fff; font-size: 11px; font-weight: 900; display: grid; place-items: center;
  box-shadow: 0 2px 0 #B95A16;
}
.help-row b { display: block; font-size: 11.5px; color: #5F381D; margin-bottom: 1px; }
.help-row p { margin: 0; font-size: 9.5px; line-height: 1.5; color: #96724D; }

/* 确认小条 */
.confirm-strip {
  display: flex; align-items: center; gap: 6px; justify-content: center;
  padding: 9px; border-radius: 11px; margin-bottom: 10px;
  background: rgba(255, 255, 255, .55); border: 1px dashed #E2BC85;
  color: #8C6038; font-size: 10.5px; font-weight: 800;
}
.confirm-strip .mini-coin { width: 14px; height: 14px; }

/* ---------- 主题装饰 ---------- */
body[data-decor="sakura"] {
  --brand: #FF6F9C; --brand-2: #FFA8C6; --brand-deep: #C93F6C; --brand-glow: rgba(255, 120, 160, .45);
  --wood-a: #E7B58E; --wood-b: #C18373; --wood-c: #A8695D; --wood-edge: #8D5148;
  --tile-a: #FFEBE5; --tile-b: #F5CDBF; --tile-edge: #DCAE9C;
}
body[data-decor="sakura"] .scene-art { filter: hue-rotate(-15deg) saturate(1.1) brightness(1.03); }
body[data-decor="sakura"] .dock-btn.upgrade { background: linear-gradient(180deg, #FFB4CE, #F46E9D); border-color: #FFD3E2; box-shadow: 0 4px 0 #B93C69, inset 0 1px 0 rgba(255, 255, 255, .55); }
body[data-decor="sakura"] .dock-btn.upgrade:active { box-shadow: 0 2px 0 #B93C69; }
body[data-decor="sakura"] .level-chip { background: linear-gradient(#FFA8C6, #F45C90); box-shadow: 0 2px 0 #B13B66; }
body[data-decor="mint"] {
  --brand: #35B98A; --brand-2: #78DDB5; --brand-deep: #1E8A64; --brand-glow: rgba(90, 215, 160, .45);
  --wood-a: #CFCF87; --wood-b: #9CA25C; --wood-c: #7E8346; --wood-edge: #666B36;
  --tile-a: #F3F4D4; --tile-b: #DDE3AE; --tile-edge: #BDC58A;
}
body[data-decor="mint"] .scene-art { filter: hue-rotate(28deg) saturate(.95) brightness(1.03); }
body[data-decor="mint"] .dock-btn.upgrade { background: linear-gradient(180deg, #9AE9C5, #41B98A); border-color: #ACECCF; box-shadow: 0 4px 0 #1E7E5C, inset 0 1px 0 rgba(255, 255, 255, .55); }
body[data-decor="mint"] .dock-btn.upgrade:active { box-shadow: 0 2px 0 #1E7E5C; }
body[data-decor="mint"] .level-chip { background: linear-gradient(#8FE5BF, #2EA77A); box-shadow: 0 2px 0 #1E7E5C; }

/* ---------- 动画 ---------- */
@keyframes drift {
  0% { transform: translate3d(0, 0, 0) scale(.8); opacity: 0; }
  15% { opacity: .75; }
  85% { opacity: .65; }
  100% { transform: translate3d(16px, -120px, 0) scale(1.25); opacity: 0; }
}
@keyframes glint {
  0%, 100% { transform: translateX(-12%); opacity: .5; }
  50% { transform: translateX(12%); opacity: 1; }
}
@keyframes playPulse {
  0%, 100% { transform: scale(1); box-shadow: 0 2px 0 #12638F; }
  50% { transform: scale(1.09); box-shadow: 0 2px 0 #12638F, 0 0 12px rgba(120, 210, 255, .8); }
}
@keyframes readyPulse {
  0%, 100% { filter: brightness(1); }
  50% { filter: brightness(1.1); }
}
@keyframes itemPop {
  0% { transform: scale(.55) rotate(-8deg); }
  60% { transform: scale(1.14) rotate(2deg); }
  100% { transform: scale(1) rotate(0); }
}
@keyframes cellFlash {
  0% { box-shadow: 0 0 0 0 rgba(255, 220, 100, .9), inset 0 2px 3px rgba(255, 250, 235, .85); }
  55% { box-shadow: 0 0 0 8px rgba(255, 220, 100, 0), inset 0 2px 3px rgba(255, 250, 235, .85); }
  100% { box-shadow: 0 0 0 0 rgba(255, 220, 100, 0), inset 0 2px 3px rgba(255, 250, 235, .85); }
}
@keyframes shake {
  0%, 100% { transform: translateX(0); }
  20% { transform: translateX(-4px) rotate(-1deg); }
  40% { transform: translateX(4px) rotate(1deg); }
  60% { transform: translateX(-3px); }
  80% { transform: translateX(3px); }
}
@keyframes orderIn {
  0% { opacity: 0; transform: translateY(8px) scale(.94); }
  100% { opacity: 1; transform: translateY(0) scale(1); }
}
@keyframes sparkFly {
  0% { opacity: 1; transform: translate(0, 0) scale(1); }
  100% { opacity: 0; transform: translate(var(--dx), var(--dy)) scale(.25); }
}
@keyframes floatUp {
  0% { opacity: 0; transform: translate(-50%, 4px) scale(.8); }
  20% { opacity: 1; transform: translate(-50%, -4px) scale(1); }
  100% { opacity: 0; transform: translate(-50%, -32px) scale(1.05); }
}
@keyframes confettiFall {
  0% { opacity: 1; transform: translate(0, 0) rotate(0); }
  100% { opacity: 0; transform: translate(var(--cx), var(--cy)) rotate(var(--cr)); }
}
@keyframes glowFade {
  0% { opacity: 0; }
  25% { opacity: 1; }
  100% { opacity: 0; }
}

/* ---------- 小屏适配 ---------- */
@media (max-height: 740px) {
  .app { gap: 6px; padding-bottom: calc(var(--safe-bottom) + 6px); }
  .stage { height: 184px; }
  .hud { top: calc(var(--safe-top) + 8px); }
  .profile-btn, .avatar-frame { width: 41px; height: 41px; }
  .offline-card { transform: scale(.94); transform-origin: left bottom; }
  .speech { width: 148px; }
  .board { gap: 5px; padding: 8px; }
  .order-card { padding: 4px; }
  .oc-wants { min-height: 29px; }
  .oc-want img { width: 21px; height: 21px; }
  .dock-btn { height: 54px; }
  .dock-ico, .dock-ico img { width: 27px; height: 27px; }
  .restock-ico img { width: 27px; height: 25px; }
  .orders { padding: 5px 5px 6px; }
}
@media (max-width: 360px) {
  .app { padding-left: 9px; padding-right: 9px; }
  .stage { margin-left: -9px; margin-right: -9px; }
  .hud { left: 9px; right: 9px; }
  .shop-tag { display: none; }
  .who-name { max-width: 76px; font-size: 11.5px; }
  .round-btn { width: 28px; height: 28px; }
  .coin-pill { height: 31px; padding-right: 7px; }
  .coin-face { width: 23px; height: 23px; }
  #coinNum { font-size: 13px; min-width: 23px; }
  .offline-card { gap: 3px; padding-right: 5px; max-width: 140px; }
  .offline-thumb { width: 35px; height: 35px; }
  .offline-copy b { font-size: 9.5px; }
  .offline-copy span { font-size: 7.5px; }
  .offline-reward { font-size: 9.5px; }
  .offline-reward .mini-coin { width: 9px; height: 9px; }
  .offline-play { width: 17px; height: 17px; }
  .speech { width: 140px; }
  .speech-want img { width: 21px; height: 21px; }
  .orders-head > span { display: none; }
  .oc-name { font-size: 8.5px; }
  .oc-want img { width: 22px; height: 22px; }
  .oc-want span { font-size: 7.5px; }
  .oc-btn { font-size: 8.5px; }
  .dock { gap: 5px; }
  .dock-btn { height: 55px; border-radius: 15px; }
  .dock-txt { font-size: 9.5px; }
}
@media (min-width: 520px) {
  body { padding: 14px 0; }
  .app {
    height: min(calc(100dvh - 28px), 940px);
    border-radius: 30px;
    padding-left: 15px; padding-right: 15px;
    box-shadow: 0 24px 70px rgba(35, 16, 4, .5), 0 0 0 1px rgba(255, 231, 190, .28);
    background: linear-gradient(180deg, rgba(255, 226, 184, .1), rgba(90, 46, 18, .06));
  }
  .stage { margin-left: -15px; margin-right: -15px; border-radius: 28px 28px 30px 30px; }
  .hud { left: 15px; right: 15px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; }
}
