:root {
  --bg: #14110d;
  --ink: #f4ece0;
  --muted: #b8a78f;
  --paper: #2a2218;
  --accent: #f0b429;
  --ok: #3ecf8e;
  --bad: #e85d4c;
  --wood: #b87a3a;
  --tape: #f0c14a;
}

* {
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
}

html,
body {
  margin: 0;
  min-height: 100%;
  background: var(--bg);
  color: var(--ink);
  font-family: "Segoe UI", system-ui, sans-serif;
}

body {
  min-height: 100dvh;
  overflow: hidden;
}

.scene {
  position: fixed;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(80vw 50vh at 50% -8%, #3a2a16 0%, transparent 60%),
    repeating-linear-gradient(90deg, transparent 0 46px, rgba(240, 193, 74, 0.05) 46px 48px),
    #14110d;
}

.scene-lamp {
  position: absolute;
  inset: 8% 18% auto;
  height: 40%;
  background: radial-gradient(ellipse at 50% 0, rgba(255, 210, 90, 0.16), transparent 70%);
}

.scene-dust i {
  position: absolute;
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: #ffe7a8;
  opacity: 0.25;
  animation: mote 8s linear infinite;
}

.hud {
  position: fixed;
  z-index: 49;
  top: max(8px, env(safe-area-inset-top));
  left: max(8px, env(safe-area-inset-left));
  width: max-content;
  max-width: calc(100% - 16px);
  display: flex;
  gap: 8px;
  align-items: center;
}

.back,
.chip,
.play,
.ghost,
.dock-btn,
.room,
.job,
.pick,
.shop-tab,
.shop-btn,
.jobs-tab,
.way-hide,
.truck,
.good,
.cart-buy,
.cart-toggle,
.cart-line,
.reset,
.menu-btn,
.set-sound,
.sound-btn {
  border: 0;
  font: inherit;
  color: inherit;
}

.back {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  padding: 0 0 3px;
  border-radius: 12px;
  background: #2a2218;
  color: var(--tape);
  font-size: 28px;
  font-weight: 700;
  line-height: 1;
  cursor: pointer;
}

.chip {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 6px;
  min-height: 44px;
  padding: 0 12px;
  border-radius: 12px;
  background: #2a2218;
  font-weight: 800;
}

.chip.coin {
  min-width: 108px;
}

body.aim-coins .chip.rate,
body.aim-coins .chip.wood {
  opacity: 0.16;
  pointer-events: none;
}

body.aim-coins #hud-coin {
  z-index: 50;
  box-shadow: 0 0 0 2px #f0b429, 0 0 14px rgba(240, 180, 41, 0.5);
}

.chip.coin i {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #fff3b0, #f0b429 55%, #a66a10);
  box-shadow: 0 0 8px rgba(240, 180, 41, 0.5);
}

.chip.coin.debt {
  color: #e85d4c;
}

.chip.coin.debt i {
  background: radial-gradient(circle at 35% 30%, #ffd0c8, #e85d4c 55%, #8a2818);
  box-shadow: 0 0 8px rgba(232, 93, 76, 0.45);
}

.chip.rate {
  padding: 0 10px;
  gap: 5px;
}

.chip.rate i {
  width: 16px;
  height: 16px;
  background: linear-gradient(180deg, #ffe08a, #f0b429);
  clip-path: polygon(50% 0, 61% 35%, 98% 35%, 68% 57%, 79% 91%, 50% 70%, 21% 91%, 32% 57%, 2% 35%, 39% 35%);
}

.chip.rate.low {
  color: #e85d4c;
}

.chip.rate.low i {
  background: linear-gradient(180deg, #f0a090, #e85d4c);
}

.chip.rate.ok i {
  filter: drop-shadow(0 0 4px rgba(240, 180, 41, 0.55));
}

.chip.rate.hot {
  color: #ffe08a;
}

.chip.rate.hot i {
  background: linear-gradient(180deg, #fff3b0, #f0b429);
  filter: drop-shadow(0 0 6px rgba(255, 210, 90, 0.7));
}

.chip.catch {
  animation: pop 0.35s cubic-bezier(0.2, 1.5, 0.3, 1);
}

.toast {
  position: fixed;
  z-index: 26;
  left: 50%;
  bottom: 18%;
  transform: translateX(-50%) translateY(12px);
  max-width: 86vw;
  padding: 10px 14px;
  border-radius: 12px;
  background: #3a2f22;
  opacity: 0;
  pointer-events: none;
  font-weight: 700;
}

.toast.show {
  opacity: 1;
  transform: translateX(-50%);
  transition: 0.25s ease;
}

.shop-btn {
  position: fixed;
  z-index: 10;
  top: max(8px, env(safe-area-inset-top));
  right: max(8px, env(safe-area-inset-right));
  display: none;
  align-items: center;
  justify-content: center;
  height: 44px;
  min-width: 108px;
  padding: 0 14px;
  border-radius: 12px;
  background:
    linear-gradient(180deg, #ffe08a 0%, #f0b429 52%, #c48a14 100%);
  color: #1a1410;
  font-weight: 800;
  letter-spacing: 0.08em;
  box-shadow:
    0 6px 14px rgba(0, 0, 0, 0.35),
    inset 0 1px 0 rgba(255, 244, 200, 0.7),
    inset 0 -2px 0 rgba(120, 70, 8, 0.28);
  cursor: pointer;
}

body.on-floor .hud {
  max-width: calc(100% - 128px);
}

body.on-floor .shop-btn {
  display: flex;
}

.shop-btn:active {
  transform: scale(0.97);
}

.truck {
  position: fixed;
  z-index: 10;
  top: max(8px, env(safe-area-inset-top));
  right: calc(max(8px, env(safe-area-inset-right)) + 118px);
  display: none;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  width: 52px;
  padding: 4px 4px 4px;
  border-radius: 12px;
  background: #2a2218;
  box-shadow: 0 6px 14px rgba(0, 0, 0, 0.35);
  cursor: pointer;
}

.truck.show {
  display: flex;
}

.truck:active {
  transform: scale(0.97);
}

.truck em {
  min-width: 38px;
  padding: 0 5px;
  border-radius: 6px;
  background: #16120e;
  font-style: normal;
  font-weight: 800;
  color: var(--accent);
  font-size: 11px;
}

.truck-art {
  position: relative;
  width: 43px;
  height: 23px;
}

.truck-draw {
  position: absolute;
  top: 0;
  left: 43px;
  width: 64px;
  height: 34px;
  transform: scale(-0.667, 0.667);
  transform-origin: top left;
  animation: truckIdle 2.2s ease-in-out infinite;
}

.truck-art .shade {
  position: absolute;
  left: 8px;
  right: 6px;
  bottom: 1px;
  height: 5px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.4);
  filter: blur(2px);
}

.truck-art .rail {
  position: absolute;
  left: 6px;
  right: 8px;
  bottom: 8px;
  height: 4px;
  background: linear-gradient(180deg, #3a342c, #1c1814);
}

.truck-art .box {
  position: absolute;
  left: 3px;
  bottom: 11px;
  width: 36px;
  height: 18px;
  border-radius: 1px 1px 0 1px;
  background:
    linear-gradient(90deg, rgba(0, 0, 0, 0.22) 0 3px, transparent 3px),
    linear-gradient(180deg, #b7a27a 0%, #8d7754 42%, #6d5a3c 100%);
  box-shadow:
    inset 0 1px 0 rgba(255, 240, 210, 0.2),
    inset 0 -1px 0 rgba(0, 0, 0, 0.22);
}

.truck-art .box::after {
  content: "";
  position: absolute;
  left: 5px;
  right: 4px;
  top: 3px;
  bottom: 3px;
  background:
    repeating-linear-gradient(
      90deg,
      transparent 0 5px,
      rgba(70, 50, 28, 0.18) 5px 6px
    );
}

.truck-art .cab {
  position: absolute;
  left: 38px;
  bottom: 11px;
  width: 20px;
  height: 15px;
  border-radius: 1px 4px 1px 0;
  background:
    linear-gradient(180deg, #d8c6a2 0%, #b39a74 50%, #8a7352 100%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.22);
}

.truck-art .cab::before {
  content: "";
  position: absolute;
  left: 1px;
  top: -5px;
  width: 18px;
  height: 6px;
  border-radius: 3px 5px 0 0;
  background: linear-gradient(180deg, #c4b089, #9a8560);
}

.truck-art .glass {
  position: absolute;
  left: 44px;
  bottom: 17px;
  width: 11px;
  height: 7px;
  border-radius: 1px 3px 1px 0;
  background:
    linear-gradient(160deg, rgba(210, 230, 235, 0.55), #3d5a62 40%, #243840);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.28);
}

.truck-art .mirror {
  position: absolute;
  left: 56px;
  bottom: 20px;
  width: 3px;
  height: 4px;
  border-radius: 1px;
  background: #6a5a46;
}

.truck-art .lamp {
  position: absolute;
  left: 56px;
  bottom: 13px;
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: #f3d27a;
  box-shadow: 0 0 4px rgba(243, 210, 122, 0.7);
}

.truck-art .whl {
  position: absolute;
  bottom: 3px;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background:
    radial-gradient(circle at 32% 30%, #9a8c7a 0 16%, #2c261e 17% 38%, #0e0c0a 39%);
  animation: wheelSpin 1.1s linear infinite;
}

.truck-art .whl.a { left: 12px; }
.truck-art .whl.b { left: 42px; }

.ship-pane {
  position: fixed;
  inset: 0;
  z-index: 18;
  display: none;
  justify-content: flex-end;
  align-items: flex-start;
  padding: calc(62px + env(safe-area-inset-top)) 12px 16px;
  background: rgba(8, 6, 4, 0.46);
}

.ship-pane.show {
  display: flex;
}

.ship-box {
  width: min(300px, 86vw);
  padding: 16px 14px 10px;
  border-radius: 16px;
  background: #241c14;
  box-shadow: 0 16px 32px rgba(0, 0, 0, 0.4);
  animation: shopIn 0.28s ease both;
}

.ship-box h2 {
  margin: 0 0 4px;
}

.ship-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin: 10px 0;
}

.ship-row {
  display: grid;
  grid-template-columns: 1fr auto;
  grid-template-rows: auto auto;
  gap: 0 10px;
  padding: 10px 12px;
  border-radius: 12px;
  background: #2f261c;
}

.ship-row b {
  font-size: 16px;
}

.ship-row small {
  grid-column: 1;
  color: var(--muted);
}

.ship-row em {
  grid-row: 1 / span 2;
  align-self: center;
  font-style: normal;
  font-weight: 800;
  color: var(--accent);
  font-size: 20px;
}

.screen {
  position: fixed;
  inset: 0;
  display: none;
  align-items: stretch;
  justify-content: center;
  padding: calc(62px + env(safe-area-inset-top)) 12px 16px;
}

.screen.show {
  display: flex;
}

#boot.show,
#rent.show {
  align-items: center;
  justify-content: center;
}

.home,
.panel,
.yard,
.sheet {
  width: min(520px, 100%);
}

.home,
.panel {
  max-width: 520px;
  margin-inline: auto;
  align-self: center;
}

.home {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  animation: up 0.45s ease both;
}

.home-art {
  position: relative;
  width: 220px;
  height: 140px;
  margin-bottom: 8px;
}

.fork {
  position: absolute;
  left: 18px;
  bottom: 28px;
  width: 70px;
  height: 18px;
  border-radius: 4px;
  background: #f0b429;
  transform: rotate(-12deg);
  animation: fork 2.8s ease-in-out infinite;
}

.fork::before {
  content: "";
  position: absolute;
  left: -10px;
  top: -8px;
  width: 22px;
  height: 34px;
  border: 3px solid #f0b429;
  border-right: 0;
  border-radius: 6px 0 0 6px;
}

.home-pal {
  position: absolute;
  right: 24px;
  bottom: 18px;
  width: 86px;
  padding: 6px 6px 8px;
  border-radius: 6px;
  background: #8a5a28;
  box-shadow: 0 8px 0 #5a3816;
}

.home-pal i {
  display: block;
  height: 16px;
  margin-bottom: 3px;
  border-radius: 3px;
  background: #4aa3d9;
}

.home-pal.p2 {
  right: 78px;
  bottom: 54px;
  transform: scale(0.78);
  opacity: 0.7;
}

.home-pal.p2 i {
  background: #e07a3a;
}

h1 {
  margin: 6px 0 0;
  font-size: 44px;
  letter-spacing: 0.04em;
}

.tag,
.lead,
.sheet-hint,
.more {
  color: var(--muted);
}

.play {
  margin-top: 22px;
  width: min(280px, 100%);
  min-height: 58px;
  border-radius: 16px;
  background: var(--accent);
  color: #1a1410;
  font-size: 22px;
  font-weight: 800;
  cursor: pointer;
  animation: playPulse 1.8s ease-in-out infinite;
}

.more {
  margin-top: 16px;
  font-size: 14px;
}

.reset {
  margin-top: 12px;
  width: min(280px, 100%);
  color: #c9a090;
}

.panel {
  display: flex;
  flex-direction: column;
  gap: 10px;
  animation: up 0.4s ease both;
}

.panel h2 {
  margin: 0 0 4px;
  font-size: 22px;
  line-height: 1.2;
}

.rooms {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 8px;
}

.room {
  display: block;
  padding: 0;
  overflow: hidden;
  text-align: left;
  border-radius: 16px;
  background: var(--paper);
  cursor: pointer;
  animation: up 0.4s ease both;
}

.room img {
  display: block;
  width: 100%;
  height: 128px;
  object-fit: cover;
}

.room-meta {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
  padding: 8px 8px 10px;
}

.room b {
  font-size: 15px;
}

.room em {
  font-style: normal;
  font-weight: 800;
  color: var(--accent);
}

.room.ready {
  box-shadow:
    inset 0 0 0 2px var(--accent),
    0 0 22px rgba(240, 180, 41, 0.35);
}

.room.ready img {
  filter: saturate(1.15) brightness(1.06);
}

.room.poor {
  opacity: 1;
  filter: grayscale(0.85) brightness(0.55);
}

.room.poor em {
  color: #8a7a66;
}

.room:active {
  transform: scale(0.98);
}

.room.bought {
  animation: pop 0.4s cubic-bezier(0.2, 1.5, 0.3, 1);
}

.ghost {
  margin-top: 6px;
  min-height: 46px;
  border-radius: 12px;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
}

.yard {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 0;
  flex: 1;
  animation: up 0.35s ease both;
}

.yard-name {
  margin: 0 0 8px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--tape);
}

.slots {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 10px;
  min-height: 160px;
}

.slot {
  position: relative;
  min-height: 150px;
  border-radius: 14px;
  background:
    linear-gradient(180deg, rgba(240, 193, 74, 0.08), transparent 30%),
    #1d1813;
  box-shadow: inset 0 0 0 2px rgba(240, 193, 74, 0.28);
  overflow: hidden;
}

.slot.empty::after {
  content: "пусто";
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: #6d5c48;
  font-weight: 700;
}

.pallet {
  position: absolute;
  left: 12%;
  right: 12%;
  bottom: 10px;
  padding: 7px 7px 9px;
  border-radius: 7px;
  background: var(--wood);
  box-shadow: 0 7px 0 #6a4218;
  animation: drop 0.45s cubic-bezier(0.2, 1.3, 0.3, 1);
}

.pallet i {
  display: block;
  height: 15px;
  margin-bottom: 3px;
  border-radius: 3px;
}

.pallet.sku-water i { background: #4aa3d9; }
.pallet.sku-cola i { background: #8b3a2a; }
.pallet.sku-lemon i { background: #d4c04a; }
.pallet.sku-orange i { background: #e07a3a; }
.pallet.sku-grape i { background: #7b4aa8; }
.pallet.sku-cherry i { background: #c43a4a; }
.pallet.sku-cans i { background: #e07a3a; }
.pallet.sku-grain i { background: #d4b35a; }

.pallet b {
  display: block;
  margin-top: 4px;
  font-size: 12px;
  text-align: center;
}

.jobs {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  padding: 12px 2px 8px;
}

.job {
  position: relative;
  flex: 0 0 148px;
  display: grid;
  grid-template-columns: 1fr auto;
  grid-template-areas:
    "kind clock"
    "who who"
    "mix mix"
    "note pay";
  gap: 6px 10px;
  padding: 14px 14px 12px 18px;
  border-radius: 16px;
  background:
    linear-gradient(180deg, rgba(255, 236, 200, 0.08), transparent 42%),
    #32281e;
  text-align: left;
  cursor: pointer;
  box-shadow:
    0 10px 18px rgba(0, 0, 0, 0.28),
    inset 0 1px 0 rgba(255, 236, 200, 0.1);
  animation: up 0.35s ease both;
  overflow: visible;
}

.job::before {
  content: "";
  position: absolute;
  left: 0;
  top: 10px;
  bottom: 10px;
  width: 4px;
  border-radius: 0 3px 3px 0;
  background: #8dcc7a;
}

.job:active {
  transform: scale(0.98);
}

.job-kind {
  grid-area: kind;
  margin: 0;
  font-size: 11px;
  font-style: normal;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #8dcc7a;
}

.job-clock {
  grid-area: clock;
  align-self: start;
  padding: 2px 8px;
  border-radius: 999px;
  background: #e45a32;
  color: #1a100c;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.04em;
}

.job-client {
  grid-area: who;
  margin: 0;
  color: #cbb896;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.02em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.job-mix {
  grid-area: mix;
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin: 0;
  font-size: 14px;
  font-weight: 800;
  line-height: 1.25;
}

.job-sku {
  display: inline-flex;
  padding: 3px 8px;
  border-radius: 8px;
  background: rgba(8, 4, 0, 0.28);
  font-size: 12px;
  font-weight: 800;
}

.job-note {
  grid-area: note;
  margin: 2px 0 0;
  color: #b8a78f;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.3;
}

.job-pal {
  grid-area: note;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  width: max-content;
  margin: 2px 0 0;
  padding: 6px 10px 6px 8px;
  border-radius: 12px;
  background: rgba(8, 4, 0, 0.32);
}

.job-pal b {
  display: block;
  min-width: 1.4em;
  font-size: 22px;
  font-weight: 900;
  line-height: 1;
  text-align: center;
  letter-spacing: -0.02em;
}

.job-pal.plus {
  background: rgba(62, 207, 142, 0.16);
  box-shadow: inset 0 0 0 1px rgba(62, 207, 142, 0.4);
}

.job-pal.plus b {
  color: #5ee0a4;
  text-shadow: 0 0 10px rgba(62, 207, 142, 0.45);
}

.job-pal.minus {
  background: rgba(232, 93, 76, 0.16);
  box-shadow: inset 0 0 0 1px rgba(232, 93, 76, 0.4);
}

.job-pal.minus b {
  color: #ff7a6c;
  text-shadow: 0 0 10px rgba(232, 93, 76, 0.4);
}

.job-pal-pic {
  position: relative;
  display: block;
  width: 34px;
  height: 22px;
  flex: 0 0 34px;
  filter: drop-shadow(0 3px 3px rgba(8, 3, 0, 0.45));
}

.job-pal-pic i {
  position: absolute;
  left: 0;
  right: 0;
  height: 5px;
  border-radius: 1px;
  background:
    linear-gradient(180deg, #f3d7a0, #c48a40 55%, #7a4214);
  box-shadow:
    inset 0 1px 0 rgba(255, 244, 210, 0.55),
    0 1px 0 #4a2c10;
}

.job-pal-pic i:nth-child(1) { top: 2px; transform: scaleX(0.96); }
.job-pal-pic i:nth-child(2) { top: 9px; }
.job-pal-pic i:nth-child(3) { top: 16px; transform: scaleX(0.96); }

.job-pal-pic::after {
  content: "";
  position: absolute;
  left: 3px;
  right: 3px;
  bottom: 0;
  height: 6px;
  background: repeating-linear-gradient(90deg, #5a3210 0 6px, transparent 6px 12px);
  opacity: 0.9;
}

.job.rush .job-pal.plus {
  animation: palGift 1.1s ease-in-out infinite;
}

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

.job-pay {
  grid-area: pay;
  align-self: end;
  color: #f0b429;
  font-size: 18px;
  font-weight: 800;
  letter-spacing: 0.02em;
  text-shadow: 0 0 12px rgba(240, 180, 41, 0.28);
}

.job.easy::before,
.job.mid::before {
  background: #8dcc7a;
}
.job.easy .job-kind,
.job.mid .job-kind { color: #8dcc7a; }

.job.hard::before { background: #e08a3a; }
.job.hard .job-kind { color: #e08a3a; }

.job.wild::before { background: #d48ad0; }
.job.wild .job-kind { color: #d48ad0; }

.job.rush {
  background:
    linear-gradient(160deg, rgba(255, 120, 64, 0.22), transparent 46%),
    #3a2418;
  animation: up 0.35s ease both, rushPulse 1.2s ease-in-out 0.4s infinite;
}
.job.rush::before { background: #f08a62; }
.job.rush .job-kind { color: #f08a62; }

.job.bulk {
  background:
    linear-gradient(160deg, rgba(232, 197, 106, 0.16), transparent 48%),
    #322818;
}
.job.bulk::before { background: #e8c56a; }
.job.bulk .job-kind { color: #e8c56a; }

.job.empty {
  grid-template-areas:
    "mix mix"
    "note note";
  cursor: default;
}
.job.empty::before { background: #8a7a62; }

@keyframes rushPulse {
  0%, 100% { box-shadow: 0 10px 18px rgba(0, 0, 0, 0.28), 0 0 0 1px rgba(232, 90, 48, 0.18); }
  50% { box-shadow: 0 10px 18px rgba(0, 0, 0, 0.28), 0 0 18px rgba(232, 90, 48, 0.4); }
}

.dock {
  width: min(520px, 100%);
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  padding-bottom: env(safe-area-inset-bottom);
}

.dock-btn {
  min-height: 58px;
  border-radius: 14px;
  background: var(--accent);
  color: #1a1410;
  cursor: pointer;
}

.dock-btn small {
  display: block;
  font-weight: 700;
}

.dock-btn.dim {
  background: #3a3228;
  color: var(--muted);
}

.sheet {
  align-self: center;
  padding: 18px 16px 10px;
  border-radius: 20px;
  background: #2a2218;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.35);
  animation: pop 0.4s cubic-bezier(0.2, 1.4, 0.3, 1);
}

.sheet-kicker {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}

.sheet h2 {
  margin: 4px 0 0;
}

.sheet-pay {
  margin: 4px 0 12px;
  color: var(--ok);
  font-size: 28px;
  font-weight: 800;
}

.crate {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  min-height: 64px;
  margin-bottom: 10px;
}

.cell {
  width: 56px;
  height: 70px;
  border-radius: 7px;
  background: #1a1510;
  box-shadow: inset 0 0 0 2px #4a3c2c;
  overflow: hidden;
}

.cell.on {
  background: transparent;
  box-shadow: none;
  overflow: visible;
  animation: pop 0.28s cubic-bezier(0.2, 1.6, 0.3, 1);
}

.cell .pak {
  width: 100%;
  height: 68px;
}

.picks {
  display: flex;
  gap: 8px;
  overflow-x: auto;
}

.pick {
  min-width: 92px;
  padding: 10px 8px;
  border-radius: 12px;
  background: #1d1813;
  cursor: pointer;
}

.pick.on {
  box-shadow: inset 0 0 0 2px var(--accent);
}

.pick.dim {
  opacity: 0.4;
}

.shake {
  animation: shake 0.35s ease;
}

@keyframes up {
  from { transform: translateY(16px); opacity: 0; }
  to { transform: none; opacity: 1; }
}

@keyframes pop {
  from { transform: scale(0.7); opacity: 0; }
  to { transform: none; opacity: 1; }
}

@keyframes drop {
  from { transform: translateY(-40px); opacity: 0; }
  to { transform: none; opacity: 1; }
}

@keyframes fallIn {
  from { transform: translateY(-70vh); opacity: 0; }
  to { transform: none; opacity: 1; }
}

@keyframes truckIdle {
  0%, 100% { transform: scale(-0.667, 0.667) translateY(0); }
  50% { transform: scale(-0.667, 0.667) translateY(-1px); }
}

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

@keyframes puff {
  0% { transform: translate(0, 0) scale(0.6); opacity: 0.4; }
  100% { transform: translate(-10px, -10px) scale(1.4); opacity: 0; }
}

@keyframes lampBlink {
  50% { opacity: 0.45; }
}

@keyframes playPulse {
  50% { transform: scale(1.03); box-shadow: 0 0 22px rgba(240, 180, 41, 0.35); }
}

@keyframes fork {
  50% { transform: rotate(-12deg) translate(10px, -6px); }
}

@keyframes mote {
  to { transform: translateY(-40vh); opacity: 0; }
}

@keyframes shake {
  25% { transform: translateX(-5px); }
  75% { transform: translateX(5px); }
}

body.on-floor .scene {
  opacity: 0.18;
}

#floor {
  flex-direction: column;
  padding-right: 0;
}

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

.inside.can-pan {
  pointer-events: auto;
  overflow-x: auto;
  overflow-y: hidden;
  -webkit-overflow-scrolling: touch;
  touch-action: pan-x;
  scrollbar-width: none;
}

.inside.can-pan::-webkit-scrollbar {
  display: none;
}

.inside.is-drag {
  overflow: hidden;
  touch-action: none;
}

.inside-stage {
  position: relative;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.inside-pic {
  position: absolute;
  inset: 0;
  background: #1a1410 center / cover no-repeat;
}

body.in-hangar .inside-pic,
body.in-depot .inside-pic {
  background:
    radial-gradient(ellipse at 50% 18%, rgba(255, 210, 90, 0.16), transparent 42%),
    linear-gradient(#2a2218, #14110d);
}

.shelves {
  display: none;
  position: absolute;
  top: 18%;
  width: 16%;
  height: 52%;
  border-left: 6px solid #6a4218;
  border-right: 6px solid #6a4218;
  background:
    repeating-linear-gradient(
      180deg,
      transparent 0 18%,
      #8a5a28 18% 20%
    );
  opacity: 0.55;
}

.shelves.left { left: 4%; }
.shelves.right { right: 4%; }

body.in-hangar .shelves,
body.in-depot .shelves {
  display: block;
}

body.in-garage .lantern {
  display: none;
}

.lantern {
  position: absolute;
  left: 50%;
  top: 6%;
  width: 18px;
  height: 28px;
  transform: translateX(-50%);
  border-radius: 0 0 40% 40%;
  background: radial-gradient(circle at 50% 40%, #fff6c4, #f0b429 55%, #8a5a10);
  box-shadow: 0 10px 28px rgba(255, 200, 80, 0.45);
  animation: sway 3.6s ease-in-out infinite;
}

.lantern::before {
  content: "";
  position: absolute;
  left: 50%;
  bottom: 100%;
  width: 2px;
  height: 22px;
  background: #2a2218;
  transform: translateX(-50%);
}

.lantern-glow {
  position: absolute;
  left: 12%;
  right: 12%;
  top: 10%;
  height: 70%;
  background: radial-gradient(ellipse at 50% 12%, rgba(255, 214, 110, 0.34), transparent 62%);
  animation: flicker 2.4s ease-in-out infinite;
}

.floor-lit {
  position: absolute;
  left: 16%;
  right: 16%;
  bottom: 0;
  height: 42%;
  background: radial-gradient(ellipse at 50% 78%, rgba(255, 200, 90, 0.28), transparent 70%);
  animation: flicker 2.4s ease-in-out infinite;
}

.lamp-shade {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  background:
    radial-gradient(ellipse 62% 54% at 50% 18%, transparent 0 48%, rgba(16, 8, 0, 0.1) 78%, rgba(8, 3, 0, 0.28) 100%),
    linear-gradient(90deg, rgba(10, 4, 0, 0.32) 0%, transparent 22%, transparent 78%, rgba(10, 4, 0, 0.32) 100%);
  mix-blend-mode: multiply;
}

body.in-garage .lantern-glow,
body.in-garage .floor-lit {
  opacity: 0.22;
}

.floor-row {
  position: relative;
  z-index: 1;
  width: min(560px, 100%);
  flex: 1;
  display: flex;
  align-items: stretch;
  gap: 6px;
  min-height: 0;
  pointer-events: none;
}

.floor-row .yard {
  min-width: 0;
}

.yard-name {
  text-shadow: 0 1px 8px rgba(0, 0, 0, 0.7);
}

body.shipping .yard-name {
  opacity: 0;
}

.slot {
  background:
    linear-gradient(180deg, rgba(20, 16, 10, 0.28), rgba(20, 16, 10, 0.5)),
    transparent;
}

.jobs-tab {
  position: fixed;
  z-index: 20;
  top: calc(max(8px, env(safe-area-inset-top)) + 52px);
  right: max(8px, env(safe-area-inset-right));
  display: none;
  align-items: center;
  justify-content: center;
  height: 44px;
  min-width: 108px;
  padding: 0 14px;
  border-radius: 12px;
  background: #2f261c;
  color: var(--tape);
  font-weight: 800;
  letter-spacing: 0.08em;
  box-shadow:
    0 6px 14px rgba(0, 0, 0, 0.35),
    inset 0 1px 0 rgba(255, 236, 200, 0.08);
  cursor: pointer;
  overflow: visible;
}

body.on-floor .jobs-tab {
  display: flex;
}

body.shipping .jobs-tab {
  display: none;
}

body.shipping:not(.loading):not(.gone):not(.bulk-ship) .jobs-tab {
  display: flex;
}

.jobs-tab.can-unload {
  background: linear-gradient(180deg, #f3d27a, #d4a017);
  color: #2a1c10;
  animation: pop 0.4s cubic-bezier(0.2, 1.5, 0.3, 1);
}

.jobs-tab.has-rush {
  box-shadow:
    0 6px 14px rgba(0, 0, 0, 0.35),
    0 0 0 1px rgba(240, 138, 98, 0.55),
    0 0 16px rgba(232, 90, 48, 0.28);
}

.jobs-tab:active {
  transform: scale(0.97);
}

.jobs-rush {
  position: absolute;
  right: calc(100% + 8px);
  top: 50%;
  display: flex;
  align-items: center;
  height: 34px;
  padding: 0 10px;
  border-radius: 10px;
  background: linear-gradient(180deg, #ff9a6a 0%, #e45a32 100%);
  color: #1a100c;
  font-style: normal;
  font-weight: 800;
  letter-spacing: 0.04em;
  white-space: nowrap;
  box-shadow:
    0 6px 14px rgba(180, 50, 20, 0.4),
    inset 0 1px 0 rgba(255, 220, 190, 0.45);
  opacity: 0;
  transform: translate(14px, -50%);
  pointer-events: none;
  transition: opacity 0.22s ease, transform 0.28s cubic-bezier(0.2, 0.85, 0.2, 1);
}

.jobs-tab.has-rush .jobs-rush {
  opacity: 1;
  transform: translate(0, -50%);
}

.shop-tab {
  border-radius: 14px 0 0 14px;
  background: var(--accent);
  color: #1a1410;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  writing-mode: vertical-rl;
  transform: rotate(180deg);
  cursor: pointer;
  box-shadow: -6px 0 18px rgba(0, 0, 0, 0.28);
}

.shop-tab:active {
  transform: rotate(180deg) scale(0.97);
}

.shop-pane {
  position: fixed;
  inset: 0;
  z-index: 18;
  display: none;
  justify-content: flex-end;
  background: rgba(8, 6, 4, 0.46);
}

.shop-pane.show {
  display: flex;
}

.jobs-pane {
  position: fixed;
  inset: 0;
  z-index: 18;
  display: none;
  justify-content: flex-end;
  background: rgba(8, 6, 4, 0.46);
}

.jobs-pane.show {
  display: flex;
}

.jobs-card {
  width: min(340px, 84vw);
  height: 100%;
  padding: calc(70px + env(safe-area-inset-top)) 14px 16px;
  background: #241c14;
  box-shadow: -12px 0 32px rgba(0, 0, 0, 0.4);
  overflow: auto;
  animation: jobsIn 0.32s ease both;
}

.jobs-card h2 {
  margin: 0 0 4px;
}

.jobs-card .lead {
  margin: 0 0 12px;
  font-size: 13px;
}

.jobs-card .jobs {
  flex-direction: column;
  overflow: visible;
  padding: 4px 0 8px;
  gap: 12px;
}

.jobs-card .job {
  flex: none;
  width: 100%;
}

.shop-card {
  display: flex;
  flex-direction: column;
  width: min(340px, 84vw);
  height: 100%;
  padding: calc(70px + env(safe-area-inset-top)) 14px 16px;
  background: #f3ead8;
  color: #2a2218;
  box-shadow: -12px 0 32px rgba(0, 0, 0, 0.28);
  overflow: hidden;
  animation: shopIn 0.32s ease both;
}

.shop-card h2 {
  margin: 0 0 4px;
  color: #2a2218;
}

.shop-card .lead {
  margin: 0 0 12px;
  font-size: 13px;
  color: #6e5c48;
}

.shop-card .ghost {
  color: #6e5c48;
}

.shop-card .goods {
  flex: 1 1 0;
  min-height: 0;
  overflow-x: hidden;
  overflow-y: scroll;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
  padding: 2px 2px 10px;
  align-content: start;
}

.shop-card .good {
  position: relative;
  min-height: unset;
  height: auto;
  background: #fff8ec;
  color: #2a2218;
  box-shadow: 0 2px 0 rgba(80, 56, 24, 0.08);
  animation: none;
}

.shop-stand {
  position: relative;
  width: 72px;
  margin: 0 auto 16px;
}

.shop-stand::after {
  content: "";
  position: absolute;
  left: 4%;
  right: 4%;
  bottom: -6px;
  height: 16px;
  border-radius: 50%;
  background: rgba(40, 24, 8, 0.38);
  filter: blur(6px);
  z-index: 0;
  pointer-events: none;
}

.shop-card .good .pal-live {
  position: relative;
  z-index: 1;
  height: auto;
  width: 100%;
  overflow: visible;
  transform: perspective(280px) rotateX(8deg);
  transform-origin: 50% 100%;
  transform-style: preserve-3d;
  margin: 0;
  background: transparent;
}

.shop-card .good-meta {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
}

.shop-card .good small {
  color: #7a6a58;
}

.shop-card .good-meta em {
  color: #b07a12;
}

.shop-card .good.ready {
  box-shadow:
    inset 0 0 0 2px #d4a017,
    0 0 12px rgba(212, 160, 23, 0.2);
}

.shop-card .good.poor .good-meta em {
  color: #9a8a74;
}

.good .qty {
  position: absolute;
  top: 8px;
  right: 8px;
  min-width: 22px;
  height: 22px;
  padding: 0 6px;
  border-radius: 999px;
  background: #d4a017;
  color: #1a1410;
  font-size: 12px;
  font-style: normal;
  font-weight: 800;
  line-height: 22px;
  text-align: center;
}

.cart {
  flex: 0 0 auto;
  margin: 10px 0 6px;
  padding: 8px 10px 10px;
  border-radius: 14px;
  background: #fff8ec;
  box-shadow: 0 2px 10px rgba(60, 40, 16, 0.08);
}

.cart-toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  min-height: 36px;
  padding: 0 2px;
  background: transparent;
  text-align: left;
  cursor: pointer;
}

.cart-toggle span {
  font-weight: 800;
  color: #2a2218;
}

.cart-toggle span::after {
  content: " ▾";
  color: #8a7a66;
  font-weight: 700;
}

.cart.open .cart-toggle span::after {
  content: " ▴";
}

.cart-toggle em {
  font-style: normal;
  font-weight: 800;
  color: #b07a12;
}

.cart-body {
  display: none;
  max-height: 28vh;
  margin: 6px 0 8px;
  overflow-x: hidden;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

.cart.open .cart-body {
  display: block;
}

.cart-lines {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.cart-fee {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin: 0 0 8px;
  padding: 0 4px;
  color: #6e5c48;
  font-size: 13px;
  font-weight: 700;
}

.cart-fee[hidden] {
  display: none;
}

.cart-fee em {
  font-style: normal;
  font-weight: 800;
  color: #b07a12;
}

.cart-empty {
  margin: 0;
  color: #7a6a58;
  font-size: 13px;
}

.cart-line {
  display: grid;
  grid-template-columns: 1fr auto;
  grid-template-rows: auto auto;
  gap: 0 10px;
  width: 100%;
  padding: 8px 10px;
  border-radius: 10px;
  background: #f3ead8;
  text-align: left;
  cursor: pointer;
  animation: none;
}

.cart-line b {
  color: #2a2218;
}

.cart-line small {
  grid-column: 1;
  color: #8a7a66;
  font-size: 11px;
}

.cart-line em {
  grid-row: 1 / span 2;
  align-self: center;
  font-style: normal;
  font-weight: 800;
  color: #b07a12;
}

.cart-buy {
  width: 100%;
  min-height: 48px;
  border-radius: 12px;
  background: #d4a017;
  color: #1a1410;
  font-weight: 800;
  cursor: pointer;
}

.cart-buy:disabled {
  background: #e0d4bc;
  color: #8a7a66;
  cursor: default;
}

.cart-buy:not(:disabled):active {
  transform: scale(0.98);
}

.goods {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.good {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  width: 100%;
  min-height: 0;
  padding: 10px 8px 8px;
  border-radius: 14px;
  background: #2f261c;
  text-align: left;
  cursor: pointer;
  animation: up 0.3s ease both;
}

.good .pal-live {
  height: 198px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  margin: 0 auto 8px;
  width: 92%;
  overflow: visible;
}

.good .pak-layer {
  display: flex;
}

.good .bots {
  display: flex;
  flex-direction: row;
}

.good .bot {
  display: flex;
  flex-direction: column;
}

.good.boxes {
  grid-column: 1 / -1;
  flex-direction: row;
  align-items: center;
  gap: 10px;
  min-height: 64px;
}

.box-draw {
  position: relative;
  flex: 0 0 68px;
  width: 68px;
  height: 54px;
}

.box-draw i {
  position: absolute;
  width: 34px;
  height: 26px;
  border-radius: 3px;
  background:
    linear-gradient(180deg, #e0c08a, #b88840);
  box-shadow:
    inset 0 0 0 2px #8a5a28,
    0 3px 0 #6a4218;
}

.box-draw i:nth-child(1) { left: 2px; bottom: 0; }
.box-draw i:nth-child(2) { right: 2px; bottom: 8px; }
.box-draw i:nth-child(3) { left: 17px; bottom: 20px; }

.good > span {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.good small {
  color: var(--muted);
}

.good-meta em {
  font-style: normal;
  font-weight: 800;
  color: var(--accent);
}

.good.ready {
  box-shadow:
    inset 0 0 0 2px var(--accent),
    0 0 16px rgba(240, 180, 41, 0.28);
}

.good.poor {
  filter: grayscale(0.85) brightness(0.55);
}

.good.locked {
  filter: none;
}

.shop-card .good.locked {
  background: linear-gradient(180deg, #fff1ea, #f6d4c6);
  box-shadow:
    inset 0 0 0 2px #e22718,
    0 4px 0 rgba(160, 20, 10, 0.1);
}

.good.locked .shop-stand .pal-live {
  filter: grayscale(0.88) brightness(0.72);
}

.lock-mark {
  position: absolute;
  left: 50%;
  top: 42%;
  z-index: 3;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background:
    radial-gradient(circle at 32% 28%, #ff7a68 0%, #ee2a1a 55%, #9c100c 100%);
  box-shadow:
    0 7px 16px rgba(170, 16, 8, 0.5),
    inset 0 2px 0 rgba(255, 230, 210, 0.5),
    inset 0 -3px 0 rgba(90, 0, 0, 0.28);
  transform: translate(-50%, -50%);
  animation: lockPulse 1.4s ease-in-out infinite;
  pointer-events: none;
}

.lock-mark::before {
  content: "";
  position: absolute;
  inset: 6px;
  border-radius: 50%;
  border: 5px solid #fff6ee;
  box-shadow: 0 0 0 1px rgba(90, 0, 0, 0.18);
}

.lock-mark::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 6px;
  height: 36px;
  margin: -18px 0 0 -3px;
  border-radius: 3px;
  background: #fff6ee;
  transform: rotate(-42deg);
  box-shadow: 0 1px 0 rgba(80, 0, 0, 0.28);
}

@keyframes lockPulse {
  0%, 100% { transform: translate(-50%, -50%) scale(1); }
  50% { transform: translate(-50%, -50%) scale(1.07); }
}

.unlock-pay {
  display: block;
  margin: -4px 0 8px;
  padding: 7px 8px 8px;
  border-radius: 12px;
  background: linear-gradient(180deg, #ff6a4a 0%, #e22718 52%, #b01410 100%);
  color: #fff7ee;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.01em;
  line-height: 1.15;
  text-align: center;
  text-shadow: 0 1px 0 rgba(80, 0, 0, 0.4);
  box-shadow:
    0 4px 0 #7a0c0c,
    0 8px 14px rgba(180, 20, 10, 0.32),
    inset 0 1px 0 rgba(255, 220, 190, 0.5);
}

.good.locked .good-meta {
  justify-content: center;
}

.good.locked .good-meta b {
  color: #7a2a20;
}

.good.poor .good-meta em {
  color: #8a7a66;
}

.good:active {
  transform: scale(0.98);
}

.buy-fx {
  position: fixed;
  inset: 0;
  z-index: 40;
  display: none;
  place-items: center;
  background: rgba(8, 6, 4, 0.78);
}

.buy-fx.show {
  display: grid;
}

.buy-shot {
  position: relative;
  width: min(340px, 86vw);
  height: 230px;
  overflow: hidden;
  border-radius: 16px;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.45);
}

.buy-shot img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.door {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 50%;
  background:
    linear-gradient(90deg, #2a1c12, #3a2a1c 40%, #1a1410);
  transition: transform 0.7s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.door.left {
  left: 0;
  border-right: 2px solid var(--accent);
}

.door.right {
  right: 0;
  border-left: 2px solid var(--accent);
}

.buy-fx.open .door.left {
  transform: translateX(-102%);
}

.buy-fx.open .door.right {
  transform: translateX(102%);
}

.buy-stamp {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 2;
  padding: 6px 12px;
  border: 3px solid var(--ok);
  border-radius: 8px;
  color: var(--ok);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  opacity: 0;
  transform: translate(-50%, -50%) scale(1.5) rotate(-12deg);
}

.buy-fx.stamp .buy-stamp {
  opacity: 1;
  transform: translate(-50%, -50%) rotate(-12deg);
  animation: pop 0.35s cubic-bezier(0.2, 1.5, 0.3, 1);
}

@keyframes shopIn {
  from { transform: translateX(24px); opacity: 0; }
  to { transform: none; opacity: 1; }
}

@keyframes jobsIn {
  from { transform: translateX(24px); opacity: 0; }
  to { transform: none; opacity: 1; }
}

@keyframes flicker {
  0%, 100% { opacity: 1; }
  45% { opacity: 0.82; }
  55% { opacity: 0.94; }
}

@keyframes sway {
  50% { transform: translateX(-50%) rotate(3deg); }
}

.floor-pals {
  position: absolute;
  left: 0;
  right: 0;
  top: calc(34% + 20px);
  bottom: calc(28% - 20px);
  z-index: 4;
  width: auto;
  overflow: visible;
  pointer-events: none;
}

body.in-garage .floor-pals {
  display: flex;
  justify-content: center;
  align-items: flex-end;
  gap: 3px;
  padding: 0 16px 15px;
}

.pal-spot {
  pointer-events: auto;
  min-height: 128px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  align-items: center;
}

body.in-garage .pal-spot {
  position: relative;
  flex: 0 0 108px;
}

.build-spot,
.recv-spot {
  position: absolute;
  bottom: 5%;
  z-index: 5;
  width: 140px;
  min-height: 148px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  align-items: center;
  pointer-events: auto;
}

.build-spot {
  left: 38%;
  margin-left: -70px;
}

.recv-spot {
  left: auto;
  right: 22%;
  margin-left: 0;
}

.build-spot em,
.recv-spot em {
  display: block;
  margin-top: 6px;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-shadow: 0 1px 6px #000;
  opacity: 0.85;
}

.build-spot:not(.has-pal)::after,
.recv-spot:not(.has-pal)::after {
  content: "";
  position: absolute;
  left: 14%;
  right: 14%;
  bottom: 28px;
  height: 16px;
  border-radius: 50%;
  background: rgba(40, 22, 6, 0.28);
  box-shadow: 0 0 0 1px rgba(180, 130, 60, 0.18);
  filter: blur(1px);
}

.build-spot.ship-on:not(.has-pal)::after,
.build-spot.hot:not(.has-pal)::after,
.recv-spot.hot:not(.has-pal)::after {
  background: rgba(240, 180, 41, 0.35);
  box-shadow: 0 0 16px rgba(240, 180, 41, 0.45);
}

.build-spot .pal-stand,
.recv-spot .pal-stand {
  position: relative;
  left: auto;
  bottom: 0;
  margin-left: 0;
}

.build-spot .pal-stand .pal-live,
.recv-spot .pal-stand .pal-live {
  position: relative;
  width: 72px;
  margin: 0 auto;
  transform: perspective(340px) rotateX(10deg) scale(1.5);
  transform-origin: 50% 100%;
}

.build-spot .pal-wood,
.recv-spot .pal-wood {
  margin-left: -20px;
  width: calc(100% + 40px);
}

.build-spot .pal-wood::before,
.recv-spot .pal-wood::before {
  height: 13px;
}

.build-spot .pal-stand::after,
.recv-spot .pal-stand::after {
  content: "";
  position: absolute;
  left: -38%;
  right: -38%;
  bottom: -18px;
  height: 52px;
  border-radius: 50%;
  background: radial-gradient(
    ellipse at 50% 50%,
    rgba(0, 0, 0, 0.95) 0%,
    rgba(4, 1, 0, 0.72) 32%,
    rgba(8, 3, 0, 0.32) 58%,
    transparent 78%
  );
  filter: blur(12px);
  z-index: 0;
  pointer-events: none;
}

body:not(.in-garage) .pal-spot {
  position: absolute;
  width: 108px;
  margin-left: -54px;
}

.pal-spot:not(.has-pal)::after {
  content: "";
  position: absolute;
  left: 12%;
  right: 12%;
  bottom: 8px;
  height: 14px;
  border-radius: 50%;
  background: rgba(40, 22, 6, 0.28);
  box-shadow: 0 0 0 1px rgba(180, 130, 60, 0.18);
  filter: blur(1px);
}

.pal-spot.hot:not(.has-pal)::after {
  background: rgba(240, 180, 41, 0.35);
  box-shadow: 0 0 16px rgba(240, 180, 41, 0.45);
}

body.guide-place .pal-spot:not(.has-pal) {
  z-index: 48;
}

body.guide-place .pal-spot:not(.has-pal)::before {
  content: "";
  position: absolute;
  left: 6px;
  right: 6px;
  top: 10px;
  bottom: 4px;
  border: 2px dashed rgba(243, 210, 122, 0.9);
  border-radius: 14px;
  pointer-events: none;
  animation: dropPulse 1.1s ease-in-out infinite;
}

body.guide-place .pal-spot:not(.has-pal)::after {
  background: rgba(240, 180, 41, 0.48);
  box-shadow:
    0 0 18px rgba(240, 180, 41, 0.55),
    0 0 0 2px rgba(243, 210, 122, 0.45);
  filter: none;
  height: 18px;
  animation: dropPulse 1.1s ease-in-out infinite;
}

@keyframes dropPulse {
  0%, 100% { opacity: 0.72; }
  50% { opacity: 1; }
}

.menu-btn {
  flex: 0 0 44px;
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: #2a2218;
  cursor: pointer;
  position: relative;
}

.menu-btn i,
.menu-btn i::before,
.menu-btn i::after {
  display: block;
  width: 18px;
  height: 3px;
  border-radius: 2px;
  background: var(--tape);
}

.menu-btn i {
  position: relative;
  margin: 21px auto 0;
}

.menu-btn i::before,
.menu-btn i::after {
  content: "";
  position: absolute;
  left: 0;
}

.menu-btn i::before {
  top: -6px;
}

.menu-btn i::after {
  top: 6px;
}

.menu-btn:active {
  transform: scale(0.97);
}

.set-pane {
  position: fixed;
  inset: 0;
  z-index: 52;
  display: none;
  align-items: flex-start;
  justify-content: flex-end;
  padding: calc(62px + env(safe-area-inset-top)) max(12px, env(safe-area-inset-right)) 16px;
  background: rgba(8, 6, 4, 0.46);
}

.set-pane.show {
  display: flex;
}

.set-card {
  width: min(300px, 86vw);
  padding: 16px 14px 10px;
  border-radius: 16px;
  background: #241c14;
  box-shadow: 0 16px 32px rgba(0, 0, 0, 0.4);
  animation: shopIn 0.28s ease both;
}

.set-card h2 {
  margin: 0 0 12px;
  font-size: 20px;
}

.set-sound {
  position: relative;
  display: grid;
  grid-template-columns: 36px 1fr auto;
  gap: 12px;
  align-items: center;
  width: 100%;
  min-height: 56px;
  margin: 0 0 12px;
  padding: 10px 12px;
  border-radius: 14px;
  background: #2f261c;
  text-align: left;
  cursor: pointer;
}

.set-sound strong {
  font-size: 16px;
}

.spk {
  position: relative;
  width: 28px;
  height: 24px;
}

.spk b {
  position: absolute;
  left: 0;
  top: 8px;
  width: 7px;
  height: 8px;
  border-radius: 2px 0 0 2px;
  background: var(--tape);
}

.spk i {
  position: absolute;
  left: 5px;
  top: 2px;
  width: 12px;
  height: 20px;
  background: var(--tape);
  clip-path: polygon(0 7px, 100% 0, 100% 100%, 0 13px);
}

.spk::before,
.spk::after {
  content: "";
  position: absolute;
  border: 2px solid var(--tape);
  border-left: 0;
  border-radius: 0 40px 40px 0;
}

.spk::before {
  left: 18px;
  top: 8px;
  width: 6px;
  height: 8px;
  margin-top: 0;
}

.spk::after {
  left: 18px;
  top: 4px;
  width: 11px;
  height: 16px;
  margin-top: 0;
  opacity: 0.55;
}

.set-sound.is-off .spk::before,
.set-sound.is-off .spk::after {
  opacity: 0;
}

.set-sound.is-off .spk {
  opacity: 0.55;
}

.set-sound.is-off::after {
  content: "";
  position: absolute;
  left: 16px;
  top: 27px;
  width: 22px;
  height: 2px;
  background: #e85d4c;
  transform: rotate(-28deg);
  box-shadow: 0 0 0 1px #241c14;
}

.sw {
  display: block;
  width: 46px;
  height: 26px;
  border-radius: 999px;
  background: #1a1410;
  box-shadow: inset 0 1px 4px rgba(0, 0, 0, 0.45);
  font-style: normal;
}

.sw::after {
  content: "";
  display: block;
  width: 20px;
  height: 20px;
  margin: 3px 0 0 3px;
  border-radius: 50%;
  background: #b8a78f;
  transition: transform 0.2s ease, background 0.2s ease;
}

.set-sound:not(.is-off) .sw {
  background: #3a6a32;
}

.set-sound:not(.is-off) .sw::after {
  background: #f0c14a;
  transform: translateX(20px);
}

.chip.wood i {
  width: 18px;
  height: 12px;
  border-radius: 1px;
  background:
    repeating-linear-gradient(90deg, #e0b46a 0 4px, #8a5a28 4px 5px),
    linear-gradient(180deg, #d4a05a, #8a4a18);
  box-shadow: 0 2px 0 #4a2c10;
}

.wood-stack {
  position: absolute;
  left: max(6px, env(safe-area-inset-left));
  bottom: max(10px, env(safe-area-inset-bottom));
  z-index: 6;
  width: 92px;
  min-height: 88px;
  padding: 18px 8px 10px;
  pointer-events: auto;
  touch-action: none;
}

.wood-stack .stack-layer {
  position: relative;
  height: 18px;
  margin-top: -10px;
  transform: translateY(calc((var(--i, 0) * -7px)));
  filter: drop-shadow(0 4px 6px rgba(8, 3, 0, 0.45));
}

.wood-stack .stack-layer .pal-live {
  transform: perspective(240px) rotateX(18deg) scale(0.72);
  transform-origin: 50% 100%;
}

.wood-stack .stack-layer.top {
  z-index: 2;
}

.wood-stack .stack-layer.gift-in .pal-live {
  animation: giftPal 0.55s cubic-bezier(0.2, 1.4, 0.3, 1);
}

@keyframes giftPal {
  from {
    transform: perspective(240px) rotateX(18deg) scale(0.4) translateY(-22px);
    opacity: 0;
  }
  to {
    transform: perspective(240px) rotateX(18deg) scale(0.72);
    opacity: 1;
  }
}

.wood-stack b {
  display: block;
  font-size: 11px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  text-align: center;
  text-shadow: 0 1px 6px #000;
}

.wood-stack em {
  display: block;
  margin-top: 8px;
  font-size: 12px;
  font-weight: 800;
  text-align: center;
  text-shadow: 0 1px 6px #000;
}

.wood-stack.hot {
  filter: drop-shadow(0 0 10px rgba(240, 180, 41, 0.55));
}

.wood-stack.empty em {
  color: var(--muted);
}

.in-dock {
  position: absolute;
  right: -72%;
  bottom: 10%;
  z-index: 6;
  width: min(220px, 50vw);
  height: 282px;
  pointer-events: none;
  transition: right 0.7s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.in-dock.show {
  right: -38%;
  pointer-events: auto;
}

.in-dock.away {
  right: -78%;
  pointer-events: none;
}

@media (min-width: 600px) {
  .in-dock.show {
    right: -100px;
  }

  .recv-spot {
    right: 18%;
  }
}

.in-dock.show:not(.open) .in-box {
  animation: truckHop 0.55s ease-in-out infinite;
}

.in-box {
  position: absolute;
  inset: 18px 0 28px;
  border-radius: 8px 0 0 6px;
  background:
    linear-gradient(90deg, #4a3a2c 0 14%, #6a5340 14% 72%, #3a2c22 72%),
    linear-gradient(180deg, #7a6250, #3a2c22);
  box-shadow: -12px 14px 22px rgba(0, 0, 0, 0.45);
}

.in-cab {
  position: absolute;
  right: 0;
  top: 18%;
  width: 28%;
  height: 46%;
  border-radius: 0 6px 2px 0;
  background: linear-gradient(180deg, #c4b089, #8a7352 60%, #5a4a38);
}

.in-glass {
  position: absolute;
  right: 6%;
  top: 24%;
  width: 16%;
  height: 18%;
  border-radius: 2px;
  background: linear-gradient(160deg, rgba(210, 230, 235, 0.45), #3d5a62);
}

.in-door {
  position: absolute;
  top: 10%;
  bottom: 22%;
  width: 28%;
  background:
    linear-gradient(90deg, #5a4636, #2e241c);
  box-shadow: inset 0 0 0 2px rgba(0, 0, 0, 0.28);
  transform-origin: left center;
  transition: transform 0.45s ease;
}

.in-door.l { left: 4%; }
.in-door.r {
  left: 32%;
  transform-origin: right center;
}

.in-dock.open .in-door.l { transform: rotateY(68deg); }
.in-dock.open .in-door.r { transform: rotateY(-68deg); }

.in-hold {
  position: absolute;
  left: 8%;
  width: 46%;
  top: 18%;
  bottom: 26%;
  overflow: visible;
  pointer-events: none;
}

.in-pipe {
  position: absolute;
  left: 7%;
  bottom: calc(20% - 45px);
  width: 12px;
  height: 9px;
  border-radius: 2px 0 0 2px;
  background: linear-gradient(180deg, #4a4036, #1a1410);
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.35);
}

.in-smoke {
  position: absolute;
  left: 2%;
  bottom: calc(26% - 45px);
  width: 28px;
  height: 52px;
  pointer-events: none;
}

.in-smoke i {
  position: absolute;
  left: 4px;
  bottom: 0;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: rgba(200, 190, 170, 0.45);
  filter: blur(2px);
  opacity: 0;
}

.in-dock.show:not(.open) .in-smoke i {
  animation: exhaust 1.4s ease-out infinite;
}

.in-dock.show:not(.open) .in-smoke i:nth-child(2) {
  left: 10px;
  animation-delay: 0.45s;
}

.in-dock.show:not(.open) .in-smoke i:nth-child(3) {
  left: 1px;
  animation-delay: 0.9s;
}

.in-bumper {
  position: absolute;
  left: 3%;
  right: 18%;
  bottom: 8%;
  height: 10px;
  border-radius: 2px;
  background: #1a1410;
}

.in-whl {
  position: absolute;
  z-index: 1;
  bottom: 6px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background:
    radial-gradient(circle at 50% 50%, transparent 0 58%, #2c261e 59% 68%, #0c0a08 69% 100%),
    radial-gradient(circle at 32% 28%, #4a443c 0 18%, #1a1612 40%, #080706 100%);
  box-shadow:
    inset 0 2px 3px rgba(255, 255, 255, 0.14),
    inset 0 -5px 6px rgba(0, 0, 0, 0.55),
    0 5px 0 #080604,
    0 8px 10px rgba(0, 0, 0, 0.4);
}

.in-whl b,
.in-whl em {
  display: block;
  font-style: normal;
}

.in-whl b {
  position: absolute;
  inset: 20%;
  border-radius: 50%;
  background:
    conic-gradient(from 18deg, #c8b89a, #6a5a46 18%, #d4c4a8 36%, #5a4a38 54%, #c8b89a 72%, #4a3c30 90%, #c8b89a);
  box-shadow:
    inset 0 0 0 2px #2a2218,
    inset 0 1px 2px rgba(255, 255, 255, 0.35);
}

.in-whl em {
  position: absolute;
  inset: 34%;
  border-radius: 50%;
  background: radial-gradient(circle at 36% 30%, #efe4cc, #9a8a70 52%, #3a3228);
  box-shadow:
    0 0 0 1px #2a2218,
    8px 0 0 -6px #d4c4a4,
    -8px 0 0 -6px #d4c4a4,
    0 8px 0 -6px #d4c4a4,
    0 -8px 0 -6px #d4c4a4,
    6px 6px 0 -6px #b8a888,
    -6px -6px 0 -6px #b8a888;
}

.in-whl.a { left: 16%; }
.in-whl.b { right: 22%; }

.in-go {
  position: absolute;
  left: -10px;
  top: 38%;
  z-index: 8;
  height: 46px;
  padding: 0 16px;
  border: 0;
  border-radius: 12px;
  background: linear-gradient(180deg, #ffe08a 0%, #f0b429 52%, #c48a14 100%);
  color: #1a1410;
  font-weight: 800;
  letter-spacing: 0.06em;
  box-shadow:
    0 6px 16px rgba(0, 0, 0, 0.45),
    inset 0 1px 0 rgba(255, 244, 200, 0.7);
  pointer-events: auto;
  cursor: pointer;
  animation: pop 0.4s cubic-bezier(0.2, 1.5, 0.3, 1);
}

.in-go:active {
  transform: scale(0.97);
}

.in-go[hidden],
.in-dock:not(.show) .in-go,
.in-dock.open .in-go,
.in-dock.away .in-go {
  display: none;
}

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

@keyframes exhaust {
  0% { transform: translate(0, 0) scale(0.6); opacity: 0; }
  20% { opacity: 0.55; }
  100% { transform: translate(-10px, -40px) scale(1.6); opacity: 0; }
}

.dock-pak {
  position: absolute;
  left: 0;
  bottom: 2%;
  width: 52px;
  height: 82px;
  padding: 0;
  border: 0;
  background: none;
  pointer-events: auto;
  touch-action: none;
  transform: translateX(-22px);
  transform-origin: bottom center;
}

.dock-pak.peek {
  animation: peekOut 0.38s ease-out forwards;
}

@keyframes peekOut {
  from { transform: translateX(24px); opacity: 0; }
  to { transform: translateX(-22px); opacity: 1; }
}

.pal-stand.hot {
  filter: drop-shadow(0 0 12px rgba(240, 180, 41, 0.55));
}

.pal-stand.ship-now {
  outline: 2px solid rgba(240, 180, 41, 0.55);
  outline-offset: 4px;
  border-radius: 8px;
}

.pal-load.into-truck {
  animation: palOut 0.6s ease forwards;
  pointer-events: none;
}

@keyframes palOut {
  60% { transform: translateX(40px) scale(0.92); opacity: 0.4; }
  100% { transform: translateX(80px) scale(0.8); opacity: 0; }
}

.good.woods {
  grid-column: 1 / -1;
  flex-direction: row;
  align-items: center;
  gap: 10px;
}

.wood-draw {
  flex: 0 0 72px;
  width: 72px;
}

.wood-draw .pal-wood {
  transform: perspective(200px) rotateX(16deg);
}

.load-bay {
  display: none !important;
}

.pal-stand {
  --cast-x: 0px;
  --cast-y: 8px;
  --dim: 0;
  --shade-l: 0.12;
  --shade-r: 0.12;
  position: absolute;
  width: 108px;
  margin-left: -54px;
  pointer-events: auto;
  touch-action: none;
  user-select: none;
}

body.in-garage .pal-stand,
.pal-spot .pal-stand {
  position: relative;
  left: auto;
  bottom: 0;
  margin-left: 0;
  flex: none;
}

.floor-pals .pal-stand .pal-live {
  position: relative;
  width: 72px;
  margin: 0 auto;
  transform: perspective(340px) rotateX(10deg) scale(1.5);
  transform-origin: 50% 100%;
  filter:
    drop-shadow(calc(var(--cast-x) * 0.55) 16px 18px rgba(8, 3, 0, 0.62))
    drop-shadow(calc(var(--cast-x) * 0.28) 7px 8px rgba(8, 3, 0, 0.5))
    brightness(calc(1 - var(--dim) * 0.4));
}

body.shipping .pal-stand.can-take {
  touch-action: none;
}

.floor-pals .pal-stand::before,
.floor-pals .pal-stand .pal-shade {
  display: none;
}

.floor-pals .pal-stand::after {
  content: "";
  position: absolute;
  left: -32%;
  right: -32%;
  bottom: -16px;
  height: 46px;
  border-radius: 50%;
  background: radial-gradient(
    ellipse at 50% 50%,
    rgba(6, 2, 0, 0.78) 0%,
    rgba(8, 3, 0, 0.4) 36%,
    rgba(8, 3, 0, 0.12) 62%,
    transparent 80%
  );
  filter: blur(15px);
  transform: translateX(calc(var(--cast-x) * 0.5)) scale(calc(1.08 + var(--dim) * 0.28));
  z-index: 0;
  pointer-events: none;
}

.floor-pals .pak-layer.lift-0 {
  filter: brightness(0.68);
}

.floor-pals .pak-layer.lift-1 {
  filter: brightness(0.84);
}

.floor-pals .pak-layer.lift-2 {
  filter: brightness(1);
}

.pal-stand .pal-live,
.pal-stand em {
  z-index: 1;
}

.pal-stand em {
  position: absolute;
  left: 0;
  right: 0;
  bottom: -15px;
  font-size: 11px;
  font-weight: 800;
  text-align: center;
  text-shadow: 0 1px 6px #000;
}

.pal-stand.drop-in {
  animation: fallIn 0.7s cubic-bezier(0.2, 1.05, 0.3, 1);
}

.pal-stand.drop-bounce {
  animation: palBounce 0.42s cubic-bezier(0.2, 0.85, 0.2, 1);
}

@keyframes palBounce {
  0% { transform: translateY(-10px) scale(1.04); }
  55% { transform: translateY(3px) scale(0.97); }
  100% { transform: translateY(0) scale(1); }
}

.drop-puff {
  position: fixed;
  z-index: 38;
  width: 54px;
  height: 22px;
  margin: -11px 0 0 -27px;
  border-radius: 50%;
  background: radial-gradient(ellipse at 50% 60%, rgba(160, 140, 110, 0.45), rgba(90, 70, 45, 0.12) 55%, transparent 72%);
  pointer-events: none;
  animation: dropPuff 0.5s ease-out forwards;
}

.drop-puff.drop-puff-pal {
  border-radius: 50%;
  background:
    radial-gradient(ellipse at 50% 55%, rgba(120, 100, 70, 0.55) 0%, rgba(80, 65, 45, 0.22) 38%, transparent 72%),
    radial-gradient(ellipse at 28% 60%, rgba(150, 130, 95, 0.35) 0%, transparent 52%),
    radial-gradient(ellipse at 74% 58%, rgba(100, 85, 60, 0.32) 0%, transparent 50%);
  filter: blur(0.6px);
  animation: dropPuffPal 0.62s cubic-bezier(0.2, 0.7, 0.2, 1) forwards;
}

.drop-puff::before,
.drop-puff::after {
  content: "";
  position: absolute;
  bottom: 2px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: rgba(140, 120, 90, 0.4);
  animation: dropMote 0.48s ease-out forwards;
}

.drop-puff.drop-puff-pal::before,
.drop-puff.drop-puff-pal::after {
  display: none;
}

.drop-puff::before { left: 8px; }
.drop-puff::after { right: 8px; animation-delay: 0.04s; }

.drop-dust-mote {
  position: fixed;
  z-index: 39;
  border-radius: 50%;
  background: radial-gradient(circle at 40% 40%, rgba(190, 170, 130, 0.85), rgba(90, 75, 50, 0.35) 70%, transparent 100%);
  pointer-events: none;
  margin: 0;
  transform: translate(-50%, -50%);
  animation: dropDustMote 0.62s cubic-bezier(0.15, 0.75, 0.25, 1) forwards;
}

@keyframes dropPuff {
  from { opacity: 0.85; transform: scaleX(0.55) scaleY(0.4); }
  to { opacity: 0; transform: scaleX(1.35) scaleY(0.85) translateY(-6px); }
}

@keyframes dropPuffPal {
  0% { opacity: 0; transform: scaleX(0.35) scaleY(0.25); }
  18% { opacity: 0.85; transform: scaleX(0.95) scaleY(0.7); }
  55% { opacity: 0.45; transform: scaleX(1.25) scaleY(0.85) translateY(-3px); }
  100% { opacity: 0; transform: scaleX(1.55) scaleY(0.55) translateY(-8px); }
}

@keyframes dropMote {
  from { opacity: 0.7; transform: translateY(0) scale(1); }
  to { opacity: 0; transform: translateY(-14px) scale(0.4); }
}

@keyframes dropDustMote {
  0% {
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.4);
  }
  12% {
    opacity: 0.9;
    transform: translate(-50%, -50%) scale(1);
  }
  100% {
    opacity: 0;
    transform: translate(calc(-50% + var(--dx, 0px)), calc(-50% + var(--dy, -12px))) scale(0.25);
  }
}

.pal-stand .pal-live {
  transform: perspective(340px) rotateX(10deg);
  transform-origin: 50% 100%;
  transform-style: preserve-3d;
  background: transparent;
}

.pal-live {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  background: none;
  overflow: visible;
}

.pal-load {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  align-items: center;
  gap: 0;
  width: 100%;
  height: 162px;
  background: none;
  overflow: visible;
}

.pak-layer {
  display: flex;
  justify-content: center;
  gap: 2px;
  margin-bottom: -8px;
}

.pal-live .pak-layer {
  position: absolute;
  left: 0;
  right: 0;
  margin: 0;
  gap: 1px;
  --lift: 0;
  --back: 0;
  bottom: calc(1px + min(1, var(--lift)) * 55px + max(0, var(--lift) - 1) * 55px);
  transform: scale(calc(1.055 - var(--back) * 0.065));
  transform-origin: 50% 100%;
  z-index: calc(var(--lift) * 3 + (2 - var(--back)));
}

.pal-live .pak-layer.lift-0 { --lift: 0; }
.pal-live .pak-layer.lift-1 { --lift: 1; }
.pal-live .pak-layer.lift-2 { --lift: 2; }
.pal-live .pak-layer.depth-0 { --back: 2; }
.pal-live .pak-layer.depth-1 { --back: 1; }
.pal-live .pak-layer.depth-2 { --back: 0; }

.pak-layer:last-child {
  margin-bottom: 0;
}

.pak-layer.vacant {
  display: none;
}

.pal-banner {
  position: absolute;
  left: -10%;
  right: -10%;
  top: 4%;
  bottom: 2%;
  z-index: 12;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: visible;
  pointer-events: none;
}

.pal-banner span {
  display: block;
  width: 175%;
  padding: 5px 0 4px;
  background: linear-gradient(
    180deg,
    rgba(18, 10, 4, 0.12),
    rgba(12, 6, 2, 0.48) 42%,
    rgba(18, 10, 4, 0.12)
  );
  box-shadow:
    0 0 0 1px rgba(255, 236, 200, 0.18),
    inset 0 1px 0 rgba(255, 255, 255, 0.12);
  color: rgba(255, 240, 214, 0.78);
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.16em;
  line-height: 1;
  text-align: center;
  text-transform: uppercase;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.55);
  white-space: nowrap;
  transform: rotate(-38deg);
}

.shop-stand .pal-banner {
  display: none;
}

.pak.empty {
  visibility: hidden;
}

.pak {
  position: relative;
  display: block;
  flex: 0 0 35px;
  width: 35px;
  height: 64px;
  background: transparent;
  cursor: grab;
}

.bots {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 5px;
  display: flex;
  justify-content: center;
  align-items: flex-end;
  gap: 1px;
  background: transparent;
}

.bots.near {
  z-index: 1;
  height: 51px;
}

.bots.rear {
  left: 2px;
  right: -1px;
  z-index: 0;
  height: 52px;
  opacity: 0.84;
}

.bot {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  width: 10px;
  height: 100%;
  font-style: normal;
  background: transparent;
}

.bot-cap {
  flex: 0 0 4px;
  width: 40%;
  height: 4px;
  border-radius: 1px 1px 0 0;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.28), transparent 70%),
    var(--cap);
}

.bot-n {
  flex: 0 0 7px;
  width: 18%;
  height: 7px;
  background: linear-gradient(90deg, rgba(210, 230, 236, 0.2), rgba(255, 255, 255, 0.55), rgba(190, 214, 222, 0.18));
}

.bot-g {
  position: relative;
  flex: 1 1 auto;
  width: 88%;
  overflow: hidden;
  border-radius: 42% 42% 16% 16% / 12% 12% 20% 20%;
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.32) 0 14%, transparent 28%, transparent 76%, rgba(0, 0, 0, 0.12)),
    linear-gradient(180deg, rgba(230, 240, 242, 0.38) 0 12%, var(--liq) 18% 100%);
}

.bot-g em {
  position: absolute;
  left: 6%;
  right: 6%;
  top: 28%;
  height: 36%;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  border-radius: 1px;
  background: var(--paper);
  color: var(--ink);
  font-size: 5px;
  font-style: normal;
  font-weight: 800;
  letter-spacing: 0.02em;
  line-height: 1;
}

.bots.rear .bot-g em {
  opacity: 0.55;
}

.pak-skin {
  position: absolute;
  left: 0;
  right: -1px;
  top: 5px;
  bottom: 5px;
  z-index: 2;
  display: block;
  width: auto;
  height: auto;
  overflow: visible;
  pointer-events: none;
  background: none;
}

.pak-edge {
  fill: none;
  stroke: rgba(255, 255, 255, 0.58);
  stroke-width: 1.15;
  vector-effect: non-scaling-stroke;
}

.pak-glare {
  fill: rgba(255, 255, 255, 0.28);
  mix-blend-mode: screen;
}

.pak-tray {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 3;
  height: 5px;
  border-radius: 0 0 2px 2px;
  background:
    repeating-linear-gradient(90deg, transparent 0 6px, rgba(0, 0, 0, 0.08) 6px 7px),
    linear-gradient(180deg, #d2a86a, #8a5a28);
  box-shadow: 0 1px 0 #5a3816;
}

.pal-wood {
  position: relative;
  padding: 0 1px;
  cursor: grab;
}

.pal-wood::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 100%;
  height: 3px;
  background:
    repeating-linear-gradient(90deg, transparent 0 8px, rgba(70, 40, 12, 0.22) 8px 9px),
    linear-gradient(180deg, #c9a056, #8a5a28 70%, #6a4218);
  clip-path: polygon(14% 0, 86% 0, 100% 100%, 0 100%);
  box-shadow: inset 0 1px 0 rgba(255, 220, 160, 0.28);
}

.pal-plate {
  position: absolute;
  left: 8%;
  right: 8%;
  bottom: 6px;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 13px;
  padding: 0 8px;
  border-radius: 1px;
  background:
    linear-gradient(180deg, #f3e2b8, #c9a056 55%, #a07830);
  box-shadow:
    0 1px 0 #3a2410,
    inset 0 1px 0 rgba(255, 244, 210, 0.55);
  color: #2a1c10;
}

.pal-plate i {
  position: absolute;
  top: 50%;
  width: 4px;
  height: 4px;
  margin-top: -2px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #e8e8e8, #6a6a6a 55%, #2a2a2a);
  box-shadow: 0 1px 0 rgba(0, 0, 0, 0.4);
}

.pal-plate i:first-child { left: 3px; }
.pal-plate i:nth-child(2) { right: 3px; }

.pal-plate b {
  overflow: hidden;
  font-size: 7px;
  font-weight: 800;
  letter-spacing: 0.04em;
  line-height: 1;
  text-transform: uppercase;
  white-space: nowrap;
}

.pal-boards {
  display: flex;
  gap: 2px;
  height: 8px;
  padding: 0 1px;
  background: #4a2c10;
}

.pal-boards i {
  flex: 1;
  background:
    repeating-linear-gradient(90deg, transparent 0 4px, rgba(80, 40, 10, 0.18) 4px 5px),
    linear-gradient(180deg, #e0b46a, #b87a3a 55%, #7a4a1c);
  box-shadow: inset 0 1px 0 rgba(255, 220, 160, 0.35);
}

.pal-stringers {
  display: flex;
  justify-content: space-between;
  height: 11px;
  padding: 0 2px;
}

.pal-stringers i {
  width: 14%;
  background:
    linear-gradient(90deg, #5a3816, #c48a40 40%, #6a4218);
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.22);
}

.pal-base {
  display: flex;
  justify-content: space-between;
  height: 5px;
  padding: 0 1px;
}

.pal-base i {
  width: 28%;
  background: linear-gradient(180deg, #8a5a28, #4a2c10);
}

.pick .pal-live {
  width: 92px;
  margin: 0 auto 4px;
  overflow: visible;
}

.pick .pak-layer {
  margin-bottom: -5px;
}

.pick .pak {
  height: 30px;
}

.pick .bots {
  bottom: 3px;
}

.pick .bots.near {
  height: 22px;
}

.pick .bots.rear {
  height: 23px;
}

.pick .bot-n {
  flex-basis: 4px;
  height: 4px;
}

.pick .pak-skin {
  top: 3px;
  bottom: 3px;
}

.pick .bot-g em {
  font-size: 4px;
  height: 34%;
}

.pal-stand.can-take {
  cursor: grab;
}

.pal-stand.no-take {
  filter: grayscale(0.35) brightness(0.82);
}

.pal-stand.bulk-ok {
  cursor: grab;
  filter:
    drop-shadow(0 0 10px rgba(240, 180, 40, 0.55))
    brightness(1.06);
  animation: bulkGlow 1.1s ease-in-out infinite;
}

body.bulk-ship .pal-stand:not(.bulk-ok) {
  filter: grayscale(0.28) brightness(0.86);
}

@keyframes bulkGlow {
  0%, 100% { filter: drop-shadow(0 0 8px rgba(240, 180, 40, 0.4)) brightness(1.04); }
  50% { filter: drop-shadow(0 0 16px rgba(240, 180, 40, 0.7)) brightness(1.1); }
}

.waybill {
  position: absolute;
  left: 50%;
  top: calc(56px + env(safe-area-inset-top));
  z-index: 6;
  display: none;
  width: min(280px, 78vw);
  padding: 10px 14px 12px;
  border-radius: 2px;
  background:
    repeating-linear-gradient(180deg, transparent 0 22px, rgba(80, 50, 20, 0.05) 22px 23px),
    #f7f0de;
  color: #2a2218;
  box-shadow:
    0 12px 26px rgba(0, 0, 0, 0.38),
    3px 4px 0 #d4c6a8;
  transform: translateX(-50%) rotate(-1.4deg);
  transform-origin: 50% 0;
}

.waybill.show {
  display: block;
  animation: paperLay 0.72s cubic-bezier(0.2, 1.05, 0.3, 1);
}

.waybill.ready {
  box-shadow:
    0 12px 26px rgba(0, 0, 0, 0.38),
    3px 4px 0 #d4c6a8,
    0 0 0 2px rgba(212, 160, 23, 0.55);
}

.waybill.big {
  top: 18%;
  z-index: 32;
  width: min(92vw, 380px);
  min-height: 42vh;
  padding: 22px 20px 18px;
  animation: none;
  transform: translateX(-50%) rotate(0);
  transition:
    top 0.42s ease,
    width 0.42s ease,
    min-height 0.42s ease,
    padding 0.42s ease,
    transform 0.42s ease;
}

.waybill.big .way-pay {
  margin-top: 18px;
  font-size: 34px;
  text-align: center;
}

.waybill.fly {
  animation: paperFly 0.55s ease-in forwards;
}

.ship-go {
  position: fixed;
  z-index: 34;
  left: 50%;
  bottom: calc(18px + env(safe-area-inset-bottom));
  display: none;
  width: min(280px, 78vw);
  margin: 0;
  padding: 12px 14px;
  border: 0;
  border-radius: 12px;
  background: linear-gradient(180deg, #f3d27a, #d4a017);
  color: #2a1c10;
  font-size: 15px;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  cursor: pointer;
  transform: translateX(-50%);
  box-shadow: 0 10px 22px rgba(0, 0, 0, 0.4);
  animation: pop 0.32s cubic-bezier(0.2, 1.6, 0.3, 1);
}

body.shipping:not(.loading):not(.gone):not(.bulk-ship) .ship-go:not([hidden]) {
  display: block;
}

.ship-go:active {
  transform: translateX(-50%) scale(0.97);
}

.ship-go[hidden] {
  display: none !important;
}

.way-head {
  margin: 0 0 8px;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #7a5a32;
}

.way-from {
  margin: 0 0 8px;
  font-size: 13px;
  font-weight: 800;
  color: #4a3820;
}

.way-hide {
  display: block;
  width: 100%;
  margin: 12px 0 0;
  padding: 9px 12px;
  border: 0;
  border-radius: 8px;
  background: #2a2218;
  color: #f4ece0;
  font: inherit;
  font-size: 14px;
  font-weight: 800;
  cursor: pointer;
}

.way-hide[hidden] {
  display: none;
}

.waybill.big .way-hide,
.waybill.fly .way-hide {
  display: none;
}

.way-lines {
  margin: 0;
  padding: 0;
  list-style: none;
}

.way-lines li {
  display: grid;
  grid-template-columns: 1fr auto 22px;
  gap: 8px;
  align-items: center;
  min-height: 24px;
  border-bottom: 1px dashed rgba(80, 50, 20, 0.16);
  font-weight: 700;
}

.way-lines li.ok {
  color: #2f7a48;
}

.way-lines .tick {
  font-style: normal;
  font-weight: 800;
  color: #2f7a48;
}

.way-lines li.ok .tick {
  animation: none;
}

.way-pay {
  margin: 8px 0 0;
  font-weight: 800;
  color: #b07a12;
  text-align: right;
}

.way-gift {
  display: none;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: max-content;
  margin: 10px 0 0 auto;
  padding: 6px 10px 6px 8px;
  border-radius: 12px;
  background: rgba(46, 120, 72, 0.12);
  box-shadow: inset 0 0 0 1px rgba(46, 120, 72, 0.28);
}

.waybill.rush .way-gift:not([hidden]) {
  display: inline-flex;
}

.way-gift b {
  font-size: 20px;
  font-weight: 900;
  color: #2f7a48;
  letter-spacing: -0.02em;
}

.waybill.big .way-gift {
  margin: 22px auto 0;
  padding: 10px 16px;
  transform: scale(1.35);
  transform-origin: 50% 50%;
}

.waybill.big .way-gift b {
  font-size: 28px;
}

.rush-gift {
  position: fixed;
  z-index: 50;
  width: 88px;
  margin-left: -44px;
  pointer-events: none;
  transform-origin: 50% 80%;
  transition:
    left 0.62s cubic-bezier(0.2, 1.05, 0.3, 1),
    top 0.62s cubic-bezier(0.2, 1.05, 0.3, 1),
    transform 0.62s cubic-bezier(0.2, 1.05, 0.3, 1);
  filter: drop-shadow(0 10px 16px rgba(0, 0, 0, 0.45));
}

.rush-gift em {
  display: block;
  margin: 0 0 4px;
  font-size: 22px;
  font-style: normal;
  font-weight: 900;
  text-align: center;
  color: #5ee0a4;
  text-shadow: 0 0 12px rgba(62, 207, 142, 0.7);
}

.rush-gift .pal-live {
  transform: perspective(280px) rotateX(12deg) scale(1.05);
  transform-origin: 50% 100%;
}

.rush-gift.to-stack em {
  opacity: 0;
  transition: opacity 0.2s ease;
}

.load-bay {
  position: absolute;
  left: 50%;
  bottom: calc(7% - 25px);
  z-index: 5;
  display: none;
  width: 132px;
  transform: translateX(-50%);
}

.load-bay.show {
  display: block;
  animation: loadUp 0.46s cubic-bezier(0.2, 1.15, 0.3, 1);
}

.load-bay.hot .load-pal {
  filter: drop-shadow(0 0 12px rgba(240, 180, 41, 0.55));
}

.load-bay.into-truck {
  animation: loadIn 0.62s ease forwards;
}

.load-bay.away {
  opacity: 0;
}

.load-pal {
  width: 100%;
  pointer-events: auto;
}

.load-pal .pal-live {
  transform: perspective(280px) rotateX(8deg);
  transform-origin: 50% 100%;
  transform-style: preserve-3d;
  background: transparent;
}

.ship-pal .pal-wood {
  z-index: 0;
}

.ship-pal .pal-load {
  position: relative;
  z-index: 1;
}

.load-hint {
  margin: 6px 0 0;
  font-size: 12px;
  font-weight: 800;
  text-align: center;
  text-shadow: 0 1px 6px #000;
}

.out-truck {
  position: absolute;
  right: -72%;
  bottom: 5%;
  z-index: 7;
  width: min(220px, 48vw);
  height: 288px;
  pointer-events: none;
  transition: right 0.7s cubic-bezier(0.2, 0.8, 0.2, 1);
}

body.shipping.loading .out-truck {
  right: -38%;
}

body.shipping.gone .out-truck {
  right: -80%;
  transition-duration: 0.55s;
}

body.bulk-ship .out-truck {
  right: -18%;
  z-index: 12;
  pointer-events: auto;
}

@media (min-width: 600px) {
  body.shipping.loading .out-truck {
    right: -100px;
  }
  body.bulk-ship .out-truck {
    right: -40px;
  }
}

.out-truck.hot .out-box {
  box-shadow:
    -8px 10px 18px rgba(0, 0, 0, 0.4),
    0 0 0 3px #f0b429,
    0 0 22px rgba(240, 180, 40, 0.45);
}

.out-box {
  position: absolute;
  inset: 8px 0 22px;
  border-radius: 6px 0 0 4px;
  background:
    linear-gradient(180deg, #6a5340, #3a2c22 40%, #2a2018);
  box-shadow: -8px 10px 18px rgba(0, 0, 0, 0.4);
}

.out-door {
  position: absolute;
  top: 8%;
  bottom: 18%;
  width: 42%;
  background:
    linear-gradient(90deg, #4a3a2c, #2e241c);
  box-shadow: inset 0 0 0 2px rgba(0, 0, 0, 0.28);
  transition: transform 0.4s ease;
}

.out-door.l { left: 6%; }
.out-door.r { right: 6%; }

body.shipping.loading .out-door.l { transform: rotateY(62deg); }
body.shipping.loading .out-door.r { transform: rotateY(-62deg); }

.out-bumper {
  position: absolute;
  left: 4%;
  right: 8%;
  bottom: 8%;
  height: 10px;
  border-radius: 2px;
  background: #1a1410;
}

.out-whl {
  position: absolute;
  bottom: -20px;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background:
    radial-gradient(circle at 50% 50%, transparent 0 58%, #2c261e 59% 68%, #0c0a08 69% 100%),
    radial-gradient(circle at 32% 28%, #4a443c 0 18%, #1a1612 40%, #080706 100%);
  box-shadow:
    inset 0 2px 3px rgba(255, 255, 255, 0.14),
    inset 0 -5px 6px rgba(0, 0, 0, 0.55),
    0 4px 0 #080604,
    0 7px 8px rgba(0, 0, 0, 0.4);
}

.out-whl b {
  position: absolute;
  inset: 20%;
  border-radius: 50%;
  background:
    conic-gradient(from 18deg, #c8b89a, #6a5a46 18%, #d4c4a8 36%, #5a4a38 54%, #c8b89a 72%, #4a3c30 90%, #c8b89a);
  box-shadow: inset 0 0 0 2px #2a2218;
}

.out-whl em {
  position: absolute;
  inset: 34%;
  border-radius: 50%;
  background: radial-gradient(circle at 36% 30%, #efe4cc, #9a8a70 52%, #3a3228);
  box-shadow: 0 0 0 1px #2a2218;
}

.out-whl.a { left: 18%; }
.out-whl.b { right: 16%; }

.drag-ghost {
  position: fixed;
  z-index: 40;
  width: 35px;
  margin: 0;
  background: transparent;
  pointer-events: none;
}

.drag-ghost .pak {
  background: transparent;
}

.drag-ghost.is-pack {
  width: 48px;
  margin: 0;
  filter: drop-shadow(0 6px 8px rgba(0, 0, 0, 0.4));
}

.drag-ghost.is-pack .ghost-pack,
.drag-ghost.is-pack .iso-pack {
  display: block;
  width: 100%;
  height: auto;
  position: relative !important;
  left: auto !important;
  bottom: auto !important;
  margin: 0 !important;
  outline: none;
}

.drag-ghost.is-pack img {
  display: block;
  width: 100%;
  height: auto;
}

.drag-ghost.is-pal {
  width: 108px;
  margin: 0;
}

.drag-ghost.is-pal .pal-live {
  width: 72px;
  margin: 0 auto;
  transform: perspective(340px) rotateX(10deg) scale(1.5);
  transform-origin: 50% 100%;
}

@keyframes paperLay {
  from {
    opacity: 0;
    transform: translateX(-50%) translateY(-72px) rotate(-16deg) scale(0.72);
  }
  58% {
    opacity: 1;
    transform: translateX(-50%) translateY(10px) rotate(2.6deg) scale(1.05);
  }
  to {
    opacity: 1;
    transform: translateX(-50%) rotate(-1.4deg) scale(1);
  }
}

@keyframes paperFly {
  to {
    opacity: 0;
    transform: translateX(-50%) translateY(-130px) rotate(14deg) scale(0.18);
  }
}

@keyframes loadUp {
  from { opacity: 0; transform: translateX(-50%) translateY(48px); }
  to { opacity: 1; transform: translateX(-50%); }
}

@keyframes loadIn {
  to { transform: translateX(42vw) translateY(-6px) scale(0.72); }
}

.coin-fly {
  position: fixed;
  z-index: 50;
  width: 16px;
  height: 16px;
  margin: -8px 0 0 -8px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #fff3b0, #f0b429 55%, #a66a10);
  box-shadow: 0 0 8px rgba(240, 180, 41, 0.55);
  pointer-events: none;
  animation: coinFly 0.72s cubic-bezier(0.2, 0.75, 0.2, 1) forwards;
}

@keyframes coinFly {
  0% { transform: translate(0, 0) scale(0.5); opacity: 1; }
  18% { transform: translate(calc(var(--dx) * 0.12), calc(var(--dy) * 0.08 - 28px)) scale(1.15); }
  100% { transform: translate(var(--dx), var(--dy)) scale(0.35); opacity: 0.15; }
}

.guide {
  position: fixed;
  inset: 0;
  z-index: 46;
  pointer-events: none;
}

.guide.show {
  display: block;
}

.guide-spot {
  position: fixed;
  z-index: 46;
  border-radius: 16px;
  box-shadow: 0 0 0 200vmax rgba(6, 3, 0, 0.62);
  pointer-events: none;
}

.guide-card {
  position: fixed;
  z-index: 47;
  pointer-events: auto;
  width: min(268px, calc(100vw - 16px));
  padding: 16px 16px 14px;
  border-radius: 16px;
  background:
    linear-gradient(180deg, rgba(255, 244, 210, 0.55), transparent 28%),
    repeating-linear-gradient(180deg, transparent 0 22px, rgba(80, 50, 20, 0.04) 22px 23px),
    #f6edd4;
  color: #2a1c10;
  box-shadow:
    0 0 0 1px rgba(212, 160, 23, 0.35),
    0 16px 36px rgba(0, 0, 0, 0.5),
    inset 0 1px 0 rgba(255, 255, 255, 0.7);
  transform-origin: 50% 0;
  animation: guideLure 1.8s ease-in-out infinite;
}

.guide-card::before {
  content: "";
  position: absolute;
  left: 18px;
  right: 18px;
  top: 0;
  height: 4px;
  border-radius: 0 0 4px 4px;
  background: linear-gradient(180deg, #f3d27a, #d4a017);
  box-shadow: 0 1px 0 rgba(255, 244, 200, 0.5);
}

.guide-kicker {
  display: block;
  margin: 4px 0 6px;
  color: #b07a12;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.guide-card[data-side="down"] {
  transform-origin: 50% 100%;
}

.guide-card[data-side="left"] {
  transform-origin: 0 50%;
}

.guide-card[data-side="right"] {
  transform-origin: 100% 50%;
}

.guide-card p {
  margin: 0 0 12px;
  font-size: 16px;
  font-weight: 800;
  line-height: 1.35;
}

.guide-pay {
  display: none;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin: 8px 0 18px;
  font-weight: 800;
  color: #b07a12;
}

.guide-pay[hidden] {
  display: none !important;
}

.guide-pay i {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #fff3b0, #f0b429 55%, #a66a10);
  box-shadow: 0 0 12px rgba(240, 180, 41, 0.55);
}

.guide-pay b {
  font-size: 34px;
  letter-spacing: 0.02em;
}

.guide-card.hero {
  left: 50% !important;
  top: 50% !important;
  min-height: 50vh;
  padding: 28px 22px 22px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  transform: translate(-50%, -50%);
  animation: guideHeroIn 0.72s cubic-bezier(0.2, 1.05, 0.3, 1);
}

.guide-card.hero .guide-pay:not([hidden]) {
  display: flex;
}

.guide-card.hero .guide-arrow {
  display: none;
}

.guide-card.hero p {
  margin: 0 0 16px;
  font-size: 22px;
  text-align: center;
}

.guide-card.settle {
  animation: none;
  transition:
    left 0.45s ease,
    top 0.45s ease,
    width 0.45s ease,
    min-height 0.45s ease,
    padding 0.45s ease,
    transform 0.45s ease;
}

.guide-card.still {
  animation: none;
}

@keyframes guideHeroIn {
  from {
    opacity: 0;
    transform: translate(-50%, -50%) translateY(28px) rotate(-8deg) scale(0.82);
  }
  58% {
    opacity: 1;
    transform: translate(-50%, -50%) translateY(-6px) rotate(1.8deg) scale(1.04);
  }
  to {
    opacity: 1;
    transform: translate(-50%, -50%);
  }
}

.guide-ok {
  display: block;
  width: 100%;
  min-height: 42px;
  border: 0;
  border-radius: 11px;
  background: linear-gradient(180deg, #ffe08a 0%, #f0b429 52%, #c48a14 100%);
  color: #1a1410;
  font: inherit;
  font-size: 15px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  cursor: pointer;
  box-shadow:
    0 6px 14px rgba(0, 0, 0, 0.22),
    inset 0 1px 0 rgba(255, 244, 200, 0.7),
    inset 0 -2px 0 rgba(120, 70, 8, 0.28);
}

.guide-ok:active {
  transform: scale(0.97);
}

.guide-arrow {
  position: absolute;
  width: 0;
  height: 0;
  border: 11px solid transparent;
  filter: drop-shadow(0 -1px 0 rgba(212, 160, 23, 0.35));
}

.guide-card[data-side="up"] .guide-arrow {
  top: -20px;
  border-bottom-color: #f6edd4;
}

.guide-card[data-side="down"] .guide-arrow {
  bottom: -20px;
  border-top-color: #f6edd4;
}

.guide-card[data-side="left"] .guide-arrow {
  border-right-color: #f6edd4;
}

.guide-card[data-side="right"] .guide-arrow {
  border-left-color: #f6edd4;
}

.guide-on {
  z-index: 48;
}

.chip.guide-on,
.room.guide-on,
.good.guide-on {
  position: relative;
}

.chip.coin.wobble,
.chip.wobble,
.shop-btn.wobble,
.cart-buy.wobble,
.jobs-tab.wobble,
.good.woods.wobble,
.wood-stack.wobble,
.truck.wobble,
.dock-pak.wobble {
  animation: hintWobble 0.7s ease-in-out infinite;
}

.build-spot.wobble {
  animation: hintWobble 0.7s ease-in-out infinite;
}

.ship-go.wobble {
  animation: hintWobbleShip 0.7s ease-in-out infinite;
}

body.guide-build .build-spot {
  z-index: 48;
}

body.guide-build .build-spot:not(.has-pal)::before {
  content: "";
  position: absolute;
  left: 8px;
  right: 8px;
  top: 8px;
  bottom: 22px;
  border: 2px dashed rgba(243, 210, 122, 0.9);
  border-radius: 14px;
  pointer-events: none;
  animation: dropPulse 1.1s ease-in-out infinite;
}

body.guide-build .build-spot:not(.has-pal)::after {
  background: rgba(240, 180, 41, 0.48);
  box-shadow:
    0 0 18px rgba(240, 180, 41, 0.55),
    0 0 0 2px rgba(243, 210, 122, 0.45);
  filter: none;
  animation: dropPulse 1.1s ease-in-out infinite;
}

@keyframes hintWobble {
  0%, 100% { transform: rotate(-4deg) translateY(0); }
  50% { transform: rotate(5deg) translateY(-3px); }
}

@keyframes hintWobbleShip {
  0%, 100% { transform: translateX(-50%) rotate(-4deg) translateY(0); }
  50% { transform: translateX(-50%) rotate(5deg) translateY(-3px); }
}

@keyframes hintWobbleJobs {
  0%, 100% { transform: translateX(-50%) rotate(-4deg) translateY(0); }
  50% { transform: translateX(-50%) rotate(5deg) translateY(-3px); }
}

@keyframes guideLure {
  0%, 100% { transform: translateY(0) rotate(-1.5deg) scale(1); }
  35% { transform: translateY(-7px) rotate(1.8deg) scale(1.03); }
  62% { transform: translateY(-3px) rotate(-1deg) scale(1.01); }
}

.guide-gift {
  position: fixed;
  z-index: 48;
  width: 72px;
  margin: -20px 0 0 -36px;
  pointer-events: none;
  transition: left 0.62s cubic-bezier(0.2, 0.8, 0.2, 1), top 0.62s cubic-bezier(0.2, 0.8, 0.2, 1), transform 0.62s ease;
  filter: drop-shadow(0 10px 16px rgba(0, 0, 0, 0.45));
}

.guide-gift .pal-live {
  transform: perspective(280px) rotateX(12deg) scale(1.35);
  transform-origin: 50% 100%;
}

.guide-gift.fly {
  transform: scale(0.55);
}

body.iso-yard {
  --bg: #c9b48a;
}

body.iso-yard .scene {
  background:
    radial-gradient(80vw 40vh at 70% 90%, rgba(180, 150, 80, 0.35), transparent 55%),
    #b8a06a;
}

body.iso-yard .scene-lamp,
body.iso-yard .lantern,
body.iso-yard .lantern-glow,
body.iso-yard .floor-lit,
body.iso-yard .lamp-shade,
body.iso-yard .shelves {
  display: none !important;
}

body.iso-yard .inside {
  pointer-events: auto;
  display: block;
  overflow-x: hidden;
  overflow-y: hidden;
  touch-action: none;
  background: #0c0a08;
}

body.iso-yard .inside.can-pan {
  overflow-x: auto;
  overflow-y: hidden;
  -webkit-overflow-scrolling: touch;
  touch-action: pan-x;
  scrollbar-width: none;
}

body.iso-yard .inside.can-pan::-webkit-scrollbar {
  display: none;
}

body.iso-yard .inside.is-drag {
  overflow: hidden;
  touch-action: none;
}

body.iso-yard .inside.yard-locked {
  overflow: hidden;
  touch-action: none;
}

body.iso-yard .inside-pic {
  background:
    url("art/yard.jpg?v=245") center center / 100% 100% no-repeat,
    #c4b48c;
}

body.iso-yard .pal-spot.drag-source,
body.iso-yard .pal-stand.drag-source,
body.iso-yard .wood-stack.drag-source {
  opacity: 0;
  pointer-events: none;
}

body.iso-yard .inside-stage {
  position: relative;
  display: block;
  flex: none;
  width: auto;
  height: 100%;
  min-width: 0;
  max-width: none;
  margin: 0 auto;
  pointer-events: none;
}

body.iso-yard .floor-pals,
body.iso-yard .build-spot,
body.iso-yard .recv-spot,
body.iso-yard .wood-stack {
  pointer-events: auto;
}

body.iso-yard .floor-pals {
  display: block;
  left: 0;
  right: 0;
  top: 0;
  bottom: 0;
  z-index: 4;
}

body.iso-yard .pal-spot {
  position: absolute;
  flex: none;
  width: var(--pal-w, 9.442%);
  height: var(--pal-h, calc(5.354 / 56 * 100%));
  margin-left: 0;
  min-height: 0;
  padding: 0;
  box-sizing: border-box;
  transform-origin: 50% 100%;
  touch-action: none;
  cursor: grab;
}

body.iso-yard .pal-spot .pal-stand,
body.iso-yard .wood-stack .stack-layer.top {
  position: relative;
  touch-action: none;
  cursor: grab;
  -webkit-user-select: none;
  user-select: none;
}

/* Larger grab pad around the pallet sprite (still smaller than old -40% that stole neighbors). */
body.iso-yard .pal-spot.has-pal {
  pointer-events: auto;
}

body.iso-yard .pal-spot .pal-stand::before,
body.iso-yard .wood-stack::before {
  content: "";
  position: absolute;
  left: -28%;
  right: -28%;
  top: -12%;
  bottom: -22%;
  z-index: 3;
  pointer-events: auto;
}

body.iso-yard .pal-spot .pal-stand > *:not(.pal-shade) {
  position: relative;
  z-index: 2;
  pointer-events: none;
}

body.iso-yard .pal-spot .pal-stand .pak,
body.iso-yard .pal-spot .pal-stand .iso-mix {
  pointer-events: auto;
}

body.iso-yard .pal-spot .pal-stand,
body.iso-yard .wood-stack,
body.iso-yard .wood-stack .stack-layer.top {
  pointer-events: auto;
}

body.iso-yard .wood-stack {
  touch-action: none;
  padding: 0;
  margin: 0;
  box-sizing: border-box;
}

body.is-holding,
body.is-holding .inside {
  touch-action: none !important;
  overflow: hidden !important;
}

body.is-holding .drag-ghost.is-pal,
body.is-holding .drag-ghost.is-pack {
  z-index: 80;
  filter: drop-shadow(0 10px 14px rgba(0, 0, 0, 0.45));
}

body.iso-yard .drag-ghost.is-pal.is-lift {
  z-index: 90;
  filter:
    drop-shadow(0 8px 10px rgba(0, 0, 0, 0.5))
    drop-shadow(0 2px 0 rgba(0, 0, 0, 0.35));
  animation: palLiftIn 0.16s cubic-bezier(0.2, 0.9, 0.2, 1) both;
}

body.iso-yard .drag-ghost.is-pal.is-lift .iso-pal,
body.iso-yard .drag-ghost.is-pal.is-lift .pal-live {
  transform: rotate(var(--pal-rot, 0deg));
  transform-origin: 50% 55%;
}

@keyframes palLiftIn {
  from {
    opacity: 0.7;
    transform: scale(1.12);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

body.iso-yard .build-spot,
body.iso-yard .recv-spot {
  width: var(--pal-w, 9.442%);
  height: var(--pal-h, calc(5.354 / 56 * 100%));
  margin-left: 0;
  min-height: 0;
  box-sizing: border-box;
  transform-origin: 50% 100%;
}

body.iso-yard .build-spot {
  left: 40%;
  top: calc(26.5 / 56 * 100%);
  bottom: auto;
  z-index: 3000;
}

body.iso-yard .recv-spot {
  right: auto;
  left: 68%;
  top: calc(24.5 / 56 * 100%);
  bottom: auto;
  z-index: 2800;
}

body.iso-yard .wood-stack {
  position: absolute;
  left: 34%;
  top: 58%;
  bottom: auto;
  width: var(--pal-w, 9.442%);
  height: var(--pal-h, calc(5.354 / 56 * 100%));
  min-height: 0;
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  transform-origin: 50% 100%;
  z-index: 2000;
  touch-action: none;
}

body.iso-yard .iso-pal {
  position: relative;
  width: 100%;
  height: 100%;
  display: block;
  background: none;
  overflow: visible;
  transform: rotate(var(--pal-rot, 0deg));
  transform-origin: 50% 55%;
  /* No drop-shadow — ground contact shade does the work (avoids floating blob). */
  filter: none;
}

body.iso-yard .iso-img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: 50% 100%;
  pointer-events: none;
}

body.iso-yard .iso-pal .iso-base,
body.iso-yard .iso-pal .iso-goods {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  top: 0;
}

body.iso-yard .iso-pal.stacked .iso-base {
  z-index: 1;
}

body.iso-yard .iso-pal.stacked .iso-goods {
  z-index: 2;
  transform: translateY(-18%);
  clip-path: inset(calc((1 - var(--fill, 1)) * 62%) 0 0 0);
}

body.iso-yard .iso-pal.stacked.full .iso-goods {
  clip-path: none;
}

body.iso-yard .iso-mix {
  position: absolute;
  inset: 0;
  z-index: 3;
  transform: none;
  pointer-events: auto;
  overflow: visible;
}

body.iso-yard .pal-stand,
body.iso-yard .build-spot .pal-stand,
body.iso-yard .recv-spot .pal-stand,
body.iso-yard .floor-pals .pal-stand,
body.iso-yard .wood-stack .stack-layer {
  width: 100%;
  height: 100%;
}

body.iso-yard .pal-stand .pal-live,
body.iso-yard .build-spot .pal-stand .pal-live,
body.iso-yard .recv-spot .pal-stand .pal-live,
body.iso-yard .floor-pals .pal-stand .pal-live,
body.iso-yard .wood-stack .stack-layer .pal-live {
  width: 100%;
  height: 100%;
  transform: none;
  margin: 0;
}

body.iso-yard .drag-ghost.is-pal {
  width: min(28vw, 150px);
  height: auto;
  aspect-ratio: 9.442 / 5.354;
}

body.iso-yard .drag-ghost.is-pal .pal-live,
body.iso-yard .drag-ghost .iso-pal {
  width: 100%;
  height: 100%;
  transform: none;
}

body.iso-yard .fork,
.home .fork {
  display: none !important;
}

.layout-banner {
  position: fixed;
  z-index: 60;
  left: 50%;
  bottom: max(10px, env(safe-area-inset-bottom));
  transform: translateX(-50%);
  max-width: calc(100vw - 24px);
  padding: 8px 14px;
  border-radius: 999px;
  background: rgba(20, 14, 8, 0.88);
  color: #ffe7a8;
  font-size: 12px;
  font-weight: 700;
  text-align: center;
  pointer-events: none;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
}

body.layout-test .shop-btn,
body.layout-test #jobs-tab,
body.layout-test #truck,
body.layout-test .build-spot,
body.layout-test .recv-spot,
body.layout-test .in-dock,
body.layout-test .waybill,
body.layout-test .ship-go,
body.layout-test .out-truck {
  display: none !important;
}

body.layout-test .wood-stack {
  display: block !important;
  pointer-events: auto;
}

body.iso-yard .wood-stack {
  min-height: 0;
  overflow: visible;
}

body.iso-yard .wood-stack .stack-layer {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  width: 100%;
  height: 100%;
  margin: 0;
  /* Each next pallet −1.0 cell up (of pallet box height). */
  transform: translateY(calc(var(--i, 0) * var(--stack-step, 1.0) / 5.354 * -100%));
  filter: drop-shadow(0 3px 4px rgba(8, 3, 0, 0.4));
}

body.iso-yard .wood-stack em {
  position: absolute;
  left: 50%;
  top: calc(100% + 4px);
  transform: translateX(-50%);
  margin: 0;
  white-space: nowrap;
  pointer-events: none;
}

body.iso-yard .wood-stack b {
  display: none;
}

body.iso-yard .iso-pack.pak {
  position: absolute !important;
  flex: none !important;
  height: auto !important;
  margin: 0 !important;
  background: transparent;
  outline: none;
  z-index: calc(2 + var(--dep, 0) + var(--lay, 0) * 6 + var(--col, 0));
  transition: left 0.28s cubic-bezier(0.2, 0.85, 0.2, 1), bottom 0.28s cubic-bezier(0.2, 0.85, 0.2, 1), transform 0.28s ease;
  pointer-events: auto;
}

body.iso-yard .iso-pack.pak::after {
  display: none;
}

body.iso-yard .iso-pack img {
  display: block;
  width: 100%;
  height: auto;
  filter: drop-shadow(0 2px 3px rgba(0, 0, 0, 0.35));
}

body.iso-yard .out-truck {
  right: -80%;
  bottom: 4%;
  width: min(200px, 48vw);
  height: auto;
  z-index: 7;
  opacity: 0;
  pointer-events: none;
}

body.iso-yard.shipping.loading .out-truck,
body.iso-yard.bulk-ship .out-truck {
  right: 6%;
  opacity: 1;
  pointer-events: auto;
}

body.iso-yard .out-truck .out-box,
body.iso-yard .out-truck .out-door,
body.iso-yard .out-truck .out-bumper,
body.iso-yard .out-truck .out-whl {
  display: none;
}

.iso-truck {
  display: none;
}

body.iso-yard .iso-truck {
  display: block;
  width: 100%;
  height: auto;
  filter: drop-shadow(0 10px 14px rgba(0, 0, 0, 0.35));
  pointer-events: none;
}

body.iso-yard .in-dock {
  right: -80%;
  bottom: 8%;
  width: min(220px, 52vw);
  transform: none;
  opacity: 0;
}

body.iso-yard .in-dock:not([hidden]) {
  right: 4%;
  opacity: 1;
}

body.iso-yard .yard-name {
  color: #3a2a14;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.35);
}

body.iso-yard .build-spot em,
body.iso-yard .recv-spot em,
body.iso-yard .wood-stack b,
body.iso-yard .wood-stack em {
  color: #2c1c0c;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.4);
}

body.iso-yard .pal-spot:not(.has-pal)::after,
body.iso-yard .build-spot:not(.has-pal)::after,
body.iso-yard .recv-spot:not(.has-pal)::after {
  display: none !important;
}

/* One flat contact ellipse glued to the feet — no second blob, no float gap. */
body.iso-yard .pal-shade {
  display: block !important;
  position: absolute;
  left: 18%;
  right: 18%;
  top: auto;
  bottom: 0;
  height: 12%;
  border-radius: 50%;
  background: radial-gradient(
    ellipse at 50% 45%,
    rgba(10, 6, 0, 0.5) 0%,
    rgba(10, 6, 0, 0.22) 48%,
    transparent 78%
  );
  filter: blur(0.8px);
  transform: translate(calc(var(--cast-x, 0px) * 0.2), 1%) scaleY(0.55);
  transform-origin: 50% 100%;
  z-index: 0;
  pointer-events: none;
}

body.iso-yard .pal-stand::after,
body.iso-yard .build-spot .pal-stand::after,
body.iso-yard .recv-spot .pal-stand::after,
body.iso-yard .floor-pals .pal-stand::after,
body.iso-yard .wood-stack .stack-layer::after {
  display: none !important;
}

body.iso-yard .wood-stack .stack-layer .pal-shade {
  opacity: 0.85;
  bottom: 0;
}

body.iso-yard .pal-spot.hot:not(.has-pal)::before {
  content: "";
  position: absolute;
  left: 50%;
  bottom: 10px;
  width: 64px;
  height: 32px;
  margin-left: -32px;
  border-radius: 50%;
  background: rgba(255, 220, 120, 0.28);
  box-shadow: 0 0 0 2px rgba(255, 200, 80, 0.45);
  transform: scaleY(0.55);
  pointer-events: none;
  animation: snapPulse 0.9s ease-in-out infinite;
}

@keyframes snapPulse {
  0%, 100% { opacity: 0.55; transform: scaleY(0.55) scaleX(0.95); }
  50% { opacity: 1; transform: scaleY(0.55) scaleX(1.05); }
}

body.iso-yard .iso-pal.sealed:not(.sealed-art)::after {
  content: "";
  position: absolute;
  inset: 6% 8% 14%;
  border-radius: 4px;
  box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.22);
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.12), transparent 40%, rgba(40, 30, 10, 0.08));
  pointer-events: none;
}

/* Full sealed wrap: one sprite, feet glued to the same bottom as empty wood. */
body.iso-yard .iso-pal.sealed-art,
.shop-stand .iso-pal.sealed-art {
  overflow: visible;
}

/*
  Sealed: tall art, feet on spot bottom, overflow up.
  Grid 100×56: shrink whole sprite by 0.5 cells on X (−0.25 left, −0.25 right), center stays.
  Spot is GRID.palW = 9.442 cells → insets as % of spot.
*/
body.iso-yard .iso-pal.sealed-art > .iso-sealed.iso-img {
  position: absolute !important;
  left: calc(0.25 / 9.442 * 100%) !important;
  right: auto !important;
  bottom: 0 !important;
  top: auto !important;
  width: calc((1 - 0.5 / 9.442) * 100%) !important;
  height: auto !important;
  max-width: none !important;
  max-height: none !important;
  object-fit: contain !important;
  object-position: 50% 100% !important;
  display: block !important;
  pointer-events: auto !important;
  transform: none !important;
  transform-origin: 50% 100%;
}

@keyframes wrapSealIn {
  from {
    opacity: 0.35;
    filter: brightness(1.25);
  }
  to {
    opacity: 1;
    filter: none;
  }
}

body.iso-yard .iso-pal.sealed-art.wrap-in > .iso-sealed.iso-img {
  animation: wrapSealIn 0.42s ease both;
}

.shop-stand .iso-pal.sealed-art {
  position: relative;
  width: 100%;
  aspect-ratio: 9.442 / 12;
}

.shop-stand .iso-pal.sealed-art .iso-sealed {
  position: relative;
  width: 100%;
  height: auto;
}
