:root {
  --bg-cream: #f8f2ea;
  --card-bg: #fffdf9;
  --border-ink: #4a3125;
  --text-main: #3f281e;
  --text-sub: #7b5e4f;
  --accent-pink: #ee8ca3;
  --accent-pink-dark: #d96c87;
  --accent-mint: #8fd3c9;
  --accent-gold: #ffd166;
  --danger: #e05252;
}

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

html, body {
  margin: 0;
  padding: 0;
  width: 100%;
  height: 100%;
  background: #ece3d8;
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  color: var(--text-main);
  overflow: hidden;
}

.hidden {
  display: none !important;
}

.app-shell {
  width: 100%;
  max-width: 460px;
  height: 100vh;
  height: 100dvh;
  margin: 0 auto;
  background: var(--bg-cream);
  border-left: 1.5px solid rgba(74, 49, 37, 0.16);
  border-right: 1.5px solid rgba(74, 49, 37, 0.16);
  display: flex;
  flex-direction: column;
  padding: max(env(safe-area-inset-top, 0px), 62px) 12px max(env(safe-area-inset-bottom, 0px), 12px);
  position: relative;
  overflow: hidden;
}

/* 顶部通用状态栏（右侧预留 92px 避开小程序胶囊按钮） */
.top-hud {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 4px 92px 8px 4px;
  border-bottom: 1.5px solid rgba(74, 49, 37, 0.25);
  flex-shrink: 0;
  gap: 8px;
  position: relative;
  z-index: 20;
}

.coin-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #fff;
  border: 2px solid var(--border-ink);
  border-radius: 999px;
  padding: 4px 12px;
  font-weight: 900;
  font-size: 13.5px;
  box-shadow: 0 2px 0 rgba(74, 49, 37, 0.12);
}

.coin-dot {
  width: 15px;
  height: 15px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, #fff3b0, #e59858);
  border: 1.5px solid var(--border-ink);
  display: inline-block;
}

.hud-right-group {
  display: flex;
  align-items: center;
  gap: 6px;
}

.mini-btn {
  background: #fff;
  border: 2px solid var(--border-ink);
  border-radius: 10px;
  padding: 4px 10px;
  font-size: 12px;
  font-weight: 800;
  color: var(--text-main);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  box-shadow: 0 2px 0 rgba(74, 49, 37, 0.1);
}

.mini-btn:active {
  transform: translateY(1px);
}

/* 全局统一悬浮 Toast */
.float-toast {
  position: absolute;
  top: 44%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: rgba(63, 40, 30, 0.92);
  color: #fff;
  padding: 8px 18px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 800;
  z-index: 99;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.2s;
  white-space: nowrap;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.15);
}

.float-toast.show {
  opacity: 1;
}

/* 独立视图容器 */
.view-screen {
  display: none;
  flex: 1;
  flex-direction: column;
  min-height: 0;
  overflow: hidden;
  position: relative;
  z-index: 15;
}

.view-screen.active {
  display: flex;
}

/* ==================== 1. 首页 ==================== */
#viewCover {
  justify-content: flex-start;
  padding-top: 10px;
  padding-bottom: 10px;
}

.welcome-banner {
  background: linear-gradient(90deg, #ffe5ec 0%, #fff3cd 100%);
  border: 2px solid var(--border-ink);
  border-radius: 999px;
  padding: 7px 14px;
  text-align: center;
  font-size: 12.5px;
  font-weight: 800;
  flex-shrink: 0;
}

.title-block {
  text-align: center;
  margin: 12px 0 10px;
  flex-shrink: 0;
}

.tag-pill {
  display: inline-block;
  background: var(--accent-mint);
  color: #fff;
  border: 2px solid var(--border-ink);
  border-radius: 999px;
  padding: 2px 12px;
  font-size: 11px;
  font-weight: 800;
}

.main-title {
  margin: 6px 0 3px;
  font-size: 28px;
  font-weight: 900;
  letter-spacing: 2px;
  cursor: default;
}

.sub-title {
  margin: 0;
  font-size: 12.5px;
  color: var(--text-sub);
  font-weight: 600;
}

/* 首页 Banner */
.cover-banner-box {
  width: 100%;
  flex: 0 0 auto;
  aspect-ratio: 2.15 / 1;
  background: #f5ead9;
  border: 2.5px solid var(--border-ink);
  border-radius: 18px;
  position: relative;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  overflow: hidden;
  margin: 4px 0 14px;
  box-shadow: 0 3px 0 rgba(74, 49, 37, 0.12);
}

.cover-banner-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: fill;
  z-index: 5;
  display: none;
}

.cover-banner-img.loaded {
  display: block;
}

.cover-fallback-duo {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  gap: 14px;
  width: 100%;
  padding: 10px 12px 12px;
}

.cover-sheep {
  height: 132px;
  width: auto;
  max-width: 34%;
  object-fit: contain;
  animation: gentleBob 2.6s ease-in-out infinite;
}

.cover-sheep.right {
  animation-delay: 0.7s;
}

.cover-mini-table {
  width: 68px;
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 4px;
  flex-shrink: 0;
}

.cover-mini-table .top {
  width: 66px;
  height: 11px;
  background: #e5be96;
  border: 2px solid var(--border-ink);
  border-radius: 6px;
}

.cover-mini-table .leg {
  width: 8px;
  height: 30px;
  background: #cfa276;
  border-left: 2px solid var(--border-ink);
  border-right: 2px solid var(--border-ink);
}

.level-card {
  background: #fff;
  border: 2.5px solid var(--border-ink);
  border-radius: 18px;
  padding: 13px 12px;
  margin-bottom: 14px;
  flex-shrink: 0;
}

.level-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
  font-size: 12px;
  font-weight: 800;
}

.record-text {
  color: var(--text-sub);
  font-size: 11px;
  font-weight: 700;
}

.level-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}

.lvl-btn {
  background: #faf6f0;
  border: 2px solid rgba(74, 49, 37, 0.25);
  border-radius: 999px;
  padding: 8px 4px;
  font-size: 12px;
  font-weight: 800;
  color: var(--text-sub);
  cursor: pointer;
  text-align: center;
}

.lvl-btn.unlocked {
  background: #fff;
  border-color: var(--border-ink);
  color: var(--text-main);
}

.lvl-btn.selected {
  background: #ffe3e8;
  border-color: var(--border-ink);
  color: var(--text-main);
  box-shadow: 0 2px 0 var(--border-ink);
}

.cover-actions {
  display: grid;
  grid-template-columns: 1.25fr 1fr;
  gap: 10px;
  margin-bottom: 8px;
  flex-shrink: 0;
  position: relative;
  z-index: 25;
}

.big-btn {
  border: 2.5px solid var(--border-ink);
  border-radius: 16px;
  padding: 12px 10px;
  font-size: 15px;
  font-weight: 900;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  box-shadow: 0 3px 0 var(--border-ink);
  touch-action: manipulation;
}

.big-btn:active {
  transform: translateY(2px);
  box-shadow: 0 1px 0 var(--border-ink);
}

.btn-pink {
  background: var(--accent-pink);
  color: #fff;
}

.btn-cream {
  background: #fff3d6;
  color: var(--text-main);
}

/* ==================== 2. 营业游戏页 ==================== */
.play-stats-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  padding: 6px 4px;
  border-bottom: 1.5px solid rgba(74, 49, 37, 0.25);
  flex-shrink: 0;
}

.stat-box {
  background: #fff;
  border: 2px solid var(--border-ink);
  border-radius: 12px;
  padding: 4px 4px;
  text-align: center;
  line-height: 1.25;
  box-shadow: 0 2px 0 rgba(74, 49, 37, 0.08);
}

.stat-box .line1 {
  font-size: 11px;
  font-weight: 800;
  color: var(--text-main);
}

.stat-box .line2 {
  font-size: 13.5px;
  font-weight: 900;
  color: var(--text-main);
  margin-top: 1px;
}

.stat-box.danger {
  background: #ffe8e8;
  border-color: var(--danger);
  color: var(--danger);
}

.stat-box.danger .line1,
.stat-box.danger .line2 {
  color: var(--danger);
}

/* 咖啡馆主舞台 */
.cafe-scene {
  flex: 1;
  min-height: 205px;
  max-height: 345px;
  border-bottom: 2px solid var(--border-ink);
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: box-shadow 0.3s ease;
  background:
    repeating-linear-gradient(
      90deg,
      rgba(210, 182, 146, 0.2) 0px,
      rgba(210, 182, 146, 0.2) 2px,
      transparent 2px,
      transparent 24px
    ),
    linear-gradient(180deg, #faf2e6 0%, #f5ebd9 100%);
}

.cafe-scene.fever-active {
  box-shadow: inset 0 0 28px rgba(238, 140, 163, 0.75);
  background:
    repeating-linear-gradient(
      90deg,
      rgba(238, 140, 163, 0.16) 0px,
      rgba(238, 140, 163, 0.16) 2px,
      transparent 2px,
      transparent 24px
    ),
    linear-gradient(180deg, #fff0f4 0%, #ffe3eb 100%);
}

.fever-banner-pill {
  position: absolute;
  top: 6px;
  right: 10px;
  background: linear-gradient(90deg, #ff758f, #ff9ebb);
  color: #fff;
  border: 1.8px solid var(--border-ink);
  border-radius: 999px;
  padding: 2px 10px;
  font-size: 10.5px;
  font-weight: 900;
  z-index: 15;
  display: none;
  box-shadow: 0 2px 0 rgba(74, 49, 37, 0.2);
  animation: pulseFever 0.7s ease-in-out infinite alternate;
}

.cafe-scene.fever-active .fever-banner-pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.cafe-scene.has-awning .fever-banner-pill {
  top: 42px;
}

.cafe-wainscot {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 18px;
  height: 56%;
  background: linear-gradient(180deg, #edd8be 0%, #e1c39f 100%);
  border-top: 2px solid rgba(74, 49, 37, 0.32);
  z-index: 1;
  pointer-events: none;
}

.cafe-sign-board {
  position: absolute;
  top: 10px;
  left: 52%;
  transform: translateX(-50%);
  background: #fffaf1;
  border: 2px solid rgba(74, 49, 37, 0.35);
  border-radius: 10px;
  padding: 5px 16px;
  box-shadow: 0 2px 0 rgba(74, 49, 37, 0.08);
  text-align: center;
  pointer-events: none;
}

.cafe-sign-board .en {
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 1.8px;
  color: rgba(74, 49, 37, 0.65);
  line-height: 1.1;
}

.cafe-sign-board .cn {
  font-size: 9.5px;
  font-weight: 700;
  color: rgba(74, 49, 37, 0.45);
  margin-top: 2px;
}

.cafe-floor-strip {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 20px;
  background: #d6b48e;
  border-top: 1.5px solid rgba(74, 49, 37, 0.25);
  z-index: 2;
  pointer-events: none;
}

.decor-awning {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 40px;
  object-fit: cover;
  z-index: 9;
  pointer-events: none;
  filter: drop-shadow(0 2px 2px rgba(74, 49, 37, 0.14));
}

.decor-frame {
  position: absolute;
  top: 41%;
  left: 14px;
  width: 94px;
  height: 110px;
  object-fit: contain;
  z-index: 3;
  pointer-events: none;
  filter: drop-shadow(0 3px 3px rgba(74, 49, 37, 0.16));
}

.cafe-scene.has-awning .decor-frame {
  top: 46%;
}

.decor-lamp {
  position: absolute;
  bottom: 72px;
  right: 2px;
  width: 72px;
  height: 124px;
  object-fit: contain;
  z-index: 3;
  pointer-events: none;
  filter: drop-shadow(0 2px 3px rgba(74, 49, 37, 0.15));
}

/* 订单气泡卡片 */
.order-zone {
  position: relative;
  z-index: 10;
  padding: 8px 12px 0;
  display: flex;
  justify-content: center;
  transition: padding-top 0.15s ease;
}

.cafe-scene.has-awning .order-zone {
  padding-top: 42px;
}

.order-bubble {
  width: 100%;
  max-width: 348px;
  background: #fff;
  border: 2.5px solid var(--border-ink);
  border-radius: 16px;
  padding: 6px 12px 8px;
  box-shadow: 0 3px 0 rgba(74, 49, 37, 0.12);
}

.order-bubble.rush-order {
  background: #fff9e6;
  border-color: #d97706;
}

.order-top-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  font-size: 12px;
  font-weight: 800;
}

.order-type-pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: #fff4ec;
  border: 1.5px solid var(--border-ink);
  border-radius: 999px;
  padding: 2px 8px;
  font-size: 10.5px;
  font-weight: 800;
}

.order-reward-text {
  font-size: 12.5px;
  font-weight: 900;
  color: var(--text-main);
}

.order-countdown-pill {
  background: #ffe5e5;
  color: var(--danger);
  border: 1.5px solid var(--danger);
  border-radius: 999px;
  padding: 1px 9px;
  font-size: 11.5px;
  font-weight: 900;
}

.order-countdown-pill.normal {
  background: #f5efe6;
  color: var(--text-main);
  border-color: var(--border-ink);
}

.order-countdown-pill.fever {
  background: #ffe3ec;
  color: #d96c87;
  border-color: #d96c87;
}

.order-drink-name {
  text-align: center;
  font-size: 14.5px;
  font-weight: 900;
  margin: 3px 0 5px;
  color: var(--text-main);
}

.order-req-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  flex-wrap: wrap;
}

.order-req-badge {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  background: #fff;
  border: 2px solid var(--border-ink);
  border-radius: 10px;
  padding: 2px 7px;
  font-size: 11px;
  font-weight: 800;
}

.order-req-badge img, .order-req-badge .emoji-ic {
  width: 17px;
  height: 17px;
  object-fit: contain;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  mix-blend-mode: multiply;
}

/* ==================== 核心吧台区 ==================== */
.bar-workspace {
  position: relative;
  width: 100%;
  height: 162px;
  z-index: 4;
  flex-shrink: 0;
}

.staff-behind-bar {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 60px;
  height: 112px;
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  padding: 0 74px 0 72px;
  z-index: 4;
  pointer-events: none;
}

.staff-sheep {
  height: 110px;
  width: auto;
  object-fit: contain;
}

.staff-sheep.making {
  animation: bounceWork 0.35s ease;
}

.partner-wrap {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.delivery-head-bar {
  position: absolute;
  top: -28px;
  left: 50%;
  transform: translateX(-50%);
  width: 82px;
  background: #fff;
  border: 2px solid var(--border-ink);
  border-radius: 999px;
  padding: 2px 4px;
  box-shadow: 0 2px 0 rgba(74, 49, 37, 0.15);
  display: none;
  flex-direction: column;
  align-items: center;
  z-index: 12;
}

.delivery-head-bar.active {
  display: flex;
}

.delivery-label {
  font-size: 9.5px;
  font-weight: 900;
  line-height: 1.1;
  margin-bottom: 2px;
  white-space: nowrap;
}

.delivery-track {
  width: 100%;
  height: 6px;
  background: #f1e4d3;
  border-radius: 999px;
  overflow: hidden;
}

.delivery-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, #8fd3c9, #52b788);
  border-radius: 999px;
  transition: width 0.1s linear;
}

.partner-sheep.sprinting {
  animation: sprintDash 0.45s ease-in-out infinite alternate;
}

.counter-top-props {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 76px;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  padding: 0 8px;
  z-index: 8;
  pointer-events: none;
}

.prop-coffee {
  width: 62px;
  height: 62px;
  object-fit: contain;
  filter: drop-shadow(0 2px 2px rgba(74, 49, 37, 0.18));
}

.prop-display-case {
  width: 94px;
  height: 70px;
  object-fit: contain;
  margin-bottom: -2px;
  filter: drop-shadow(0 3px 3px rgba(74, 49, 37, 0.18));
}

.prop-register {
  width: 60px;
  height: 60px;
  object-fit: contain;
  filter: drop-shadow(0 2px 2px rgba(74, 49, 37, 0.18));
}

.wooden-counter-unit {
  position: absolute;
  left: 4px;
  right: 4px;
  bottom: 6px;
  height: 84px;
  z-index: 6;
  display: flex;
  flex-direction: column;
}

.counter-tabletop {
  width: 100%;
  height: 14px;
  background: linear-gradient(180deg, #f4d6b2 0%, #e0b17f 100%);
  border: 2.5px solid var(--border-ink);
  border-radius: 9px 9px 3px 3px;
  box-shadow: 0 2px 0 rgba(74, 49, 37, 0.16);
  position: relative;
  z-index: 7;
}

.counter-cabinet-body {
  flex: 1;
  margin: -2px 3px 0;
  background: linear-gradient(180deg, #d8a979 0%, #c6915c 100%);
  border: 2.5px solid var(--border-ink);
  border-top: none;
  border-radius: 0 0 12px 12px;
  display: grid;
  grid-template-columns: 1fr 0.85fr 1fr;
  overflow: hidden;
  box-shadow: 0 3px 0 rgba(74, 49, 37, 0.18);
}

.cabinet-panel {
  padding: 6px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  align-items: center;
  position: relative;
}

.cabinet-panel::before {
  content: "";
  position: absolute;
  inset: 6px 8px 28px;
  border: 1.5px solid rgba(74, 49, 37, 0.22);
  border-radius: 5px;
  background: rgba(255, 248, 238, 0.12);
}

.cabinet-panel.left {
  border-right: 2px solid rgba(74, 49, 37, 0.45);
}

.cabinet-panel.right {
  border-left: 2px solid rgba(74, 49, 37, 0.45);
}

.cabinet-center-wood {
  background:
    repeating-linear-gradient(
      90deg,
      transparent 0px,
      transparent 16px,
      rgba(74, 49, 37, 0.18) 16px,
      rgba(74, 49, 37, 0.18) 18px
    ),
    linear-gradient(180deg, #cf9d6b 0%, #bd8651 100%);
}

.station-pill {
  position: relative;
  z-index: 2;
  background: #fff;
  border: 1.8px solid var(--border-ink);
  border-radius: 999px;
  padding: 2.5px 9px;
  font-size: 10.5px;
  font-weight: 800;
  color: var(--text-main);
  white-space: nowrap;
  box-shadow: 0 1.5px 0 rgba(74, 49, 37, 0.14);
}

/* 底部操作台 */
.workbench {
  background: var(--bg-cream);
  padding: 7px 4px 2px;
  display: flex;
  flex-direction: column;
  gap: 7px;
  flex-shrink: 0;
}

.tray-row {
  display: flex;
  align-items: center;
  gap: 7px;
}

.tray-box {
  flex: 1;
  min-height: 44px;
  background: #fff;
  border: 2px solid var(--border-ink);
  border-radius: 14px;
  padding: 4px 8px;
  display: flex;
  align-items: center;
  gap: 5px;
  flex-wrap: wrap;
  font-size: 11.5px;
  font-weight: 700;
  color: var(--text-sub);
}

.cup-placeholder {
  width: 22px;
  height: 28px;
  border: 2px solid var(--border-ink);
  border-top-width: 3px;
  border-radius: 3px 3px 7px 7px;
  background: #fff9f2;
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.cup-placeholder::before {
  content: "";
  position: absolute;
  top: -6px;
  right: -2px;
  width: 10px;
  height: 2px;
  background: var(--border-ink);
  transform: rotate(-35deg);
}

.tray-item {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  background: #fff9f0;
  border: 1.5px solid var(--border-ink);
  border-radius: 8px;
  padding: 2px 6px;
  font-size: 11px;
  font-weight: 800;
  color: var(--text-main);
}

.tray-item img, .tray-item .emoji-ic {
  width: 16px;
  height: 16px;
  object-fit: contain;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  mix-blend-mode: multiply;
}

.tray-actions {
  display: flex;
  gap: 6px;
  flex-shrink: 0;
}

.act-btn {
  border: 2px solid var(--border-ink);
  border-radius: 13px;
  padding: 7px 11px;
  font-size: 12.5px;
  font-weight: 900;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  touch-action: manipulation;
}

.act-btn.trash {
  background: #fff;
  color: var(--text-main);
}

.act-btn.serve {
  background: var(--accent-pink);
  color: var(--text-main);
}

.ingredients-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 6px;
}

.ing-btn {
  background: #fff;
  border: 2px solid var(--border-ink);
  border-radius: 13px;
  padding: 4px 2px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  cursor: pointer;
  box-shadow: 0 2px 0 rgba(74, 49, 37, 0.12);
  min-height: 46px;
  touch-action: manipulation;
}

.ing-btn:active:not(.locked) {
  transform: translateY(2px);
  box-shadow: none;
}

.ing-btn.locked {
  background: #e5dfd7;
  border-color: rgba(74, 49, 37, 0.45);
  color: var(--text-sub);
  cursor: not-allowed;
  opacity: 0.72;
  box-shadow: none;
}

.ing-btn img, .ing-btn .emoji-ic {
  width: 22px;
  height: 22px;
  object-fit: contain;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  mix-blend-mode: multiply;
}

.ing-btn span.label {
  font-size: 10.5px;
  font-weight: 800;
  color: var(--text-main);
  line-height: 1.1;
}

.ing-btn.locked span.label {
  font-size: 9.5px;
  color: var(--text-sub);
}

/* ==================== 3. 装修铺页 ==================== */
.shop-scroll {
  flex: 1;
  overflow-y: auto;
  padding: 8px 2px 12px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.shop-section-title {
  font-size: 13px;
  font-weight: 900;
  margin: 4px 0 2px;
}

.shop-item-card {
  background: #fff;
  border: 2px solid var(--border-ink);
  border-radius: 16px;
  padding: 10px 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.shop-item-left {
  display: flex;
  align-items: center;
  gap: 10px;
}

.shop-icon-box {
  width: 44px;
  height: 44px;
  background: #fcf6ee;
  border: 1.5px solid var(--border-ink);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.shop-icon-box img {
  width: 34px;
  height: 34px;
  object-fit: contain;
  mix-blend-mode: multiply;
}

.shop-info h4 {
  margin: 0 0 3px;
  font-size: 13.5px;
  font-weight: 900;
}

.shop-info p {
  margin: 0;
  font-size: 11px;
  color: var(--text-sub);
  font-weight: 700;
  line-height: 1.35;
}

.buy-btn {
  background: var(--accent-gold);
  border: 2px solid var(--border-ink);
  border-radius: 12px;
  padding: 7px 11px;
  font-size: 11.5px;
  font-weight: 900;
  color: var(--text-main);
  cursor: pointer;
  white-space: nowrap;
  flex-shrink: 0;
}

.buy-btn.owned {
  background: #e9e2d8;
  color: var(--text-sub);
  cursor: default;
}

/* 结算弹窗 */
.modal-mask {
  position: absolute;
  inset: 0;
  background: rgba(63, 40, 30, 0.45);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 18px;
  z-index: 50;
}

.modal-mask.show {
  display: flex;
}

.modal-card {
  width: 100%;
  max-width: 340px;
  background: #fffdf9;
  border: 2.5px solid var(--border-ink);
  border-radius: 22px;
  padding: 18px 16px;
  text-align: center;
  box-shadow: 0 6px 0 var(--border-ink);
}

.modal-card h3 {
  margin: 0 0 8px;
  font-size: 20px;
  font-weight: 900;
}

.modal-card p {
  margin: 5px 0;
  font-size: 13.5px;
  font-weight: 700;
  color: var(--text-sub);
}

.modal-btns {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 14px;
}

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

@keyframes bounceWork {
  0% { transform: scale(1); }
  50% { transform: scale(1.07, 0.94); }
  100% { transform: scale(1); }
}

@keyframes sprintDash {
  0% { transform: translateX(0) rotate(-2deg); }
  100% { transform: translateX(6px) rotate(3deg); }
}

@keyframes pulseFever {
  0% { transform: scale(1); }
  100% { transform: scale(1.05); }
}

/* ==================== 新增玩法样式 ==================== */
.lvl-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  line-height: 1.2;
  gap: 2px;
}

.lvl-stars {
  font-size: 9px;
  letter-spacing: 1px;
  color: #e69d2c;
  min-height: 11px;
}

/* 特殊订单卡片样式 */
.order-bubble.blogger-order {
  background: linear-gradient(180deg, #fffdf0 0%, #fff4c2 100%);
  border-color: #d97706;
  box-shadow: 0 3px 0 rgba(217, 119, 6, 0.25);
}

.order-bubble.blogger-order .order-type-pill {
  background: #ffe082;
  border-color: #b45309;
  color: #78350f;
}

.order-bubble.riddle-order {
  background: linear-gradient(180deg, #f8f5ff 0%, #efe7ff 100%);
  border-color: #7c3aed;
  box-shadow: 0 3px 0 rgba(124, 58, 237, 0.2);
}

.order-bubble.riddle-order .order-type-pill {
  background: #e9d5ff;
  border-color: #6d28d9;
  color: #4c1d95;
}

.riddle-hint-box {
  background: rgba(255, 255, 255, 0.85);
  border: 1.8px dashed #7c3aed;
  border-radius: 10px;
  padding: 4px 10px;
  font-size: 11.5px;
  font-weight: 800;
  color: #4c1d95;
  text-align: center;
  line-height: 1.35;
}

/* 舞台飘字特效 */
.coin-pop {
  position: absolute;
  left: 50%;
  top: 52%;
  transform: translate(-50%, 0);
  z-index: 30;
  pointer-events: none;
  font-size: 14px;
  font-weight: 900;
  color: #b45309;
  background: #fffbeb;
  border: 2px solid var(--border-ink);
  border-radius: 999px;
  padding: 2px 10px;
  white-space: nowrap;
  box-shadow: 0 2px 0 rgba(74, 49, 37, 0.16);
  animation: floatCoinUp 1.05s ease-out forwards;
}

.coin-pop.delivery {
  left: 74%;
  top: 46%;
  background: #e6fffa;
  color: #0f766e;
}

.coin-pop.minus {
  background: #ffe8e8;
  color: var(--danger);
  border-color: var(--danger);
}

@keyframes floatCoinUp {
  0% {
    opacity: 0;
    transform: translate(-50%, 8px) scale(0.88);
  }
  18% {
    opacity: 1;
    transform: translate(-50%, -6px) scale(1.04);
  }
  100% {
    opacity: 0;
    transform: translate(-50%, -44px) scale(0.96);
  }
}

/* 肉鸽已选秘籍状态条 */
.active-perks-bar {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 4px 4px;
  overflow-x: auto;
  flex-shrink: 0;
  background: #fff8ec;
  border-bottom: 1.5px solid rgba(74, 49, 37, 0.2);
}

.perk-chip {
  background: #fff;
  border: 1.5px solid var(--border-ink);
  border-radius: 999px;
  padding: 2px 8px;
  font-size: 10.5px;
  font-weight: 800;
  color: var(--text-main);
  white-space: nowrap;
  flex-shrink: 0;
}

/* 肉鸽三选一弹窗 */
.perk-modal-card {
  max-width: 360px;
}

.perk-subtitle {
  margin: 0 0 10px !important;
  font-size: 12px !important;
}

.perk-choices {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 8px;
}

.perk-choice-btn {
  width: 100%;
  text-align: left;
  background: #fff;
  border: 2.2px solid var(--border-ink);
  border-radius: 14px;
  padding: 10px 12px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 10px;
  box-shadow: 0 3px 0 rgba(74, 49, 37, 0.14);
  transition: transform 0.1s ease, background 0.15s ease;
  touch-action: manipulation;
}

.perk-choice-btn:hover {
  background: #fff7e6;
}

.perk-choice-btn:active {
  transform: translateY(2px);
  box-shadow: 0 1px 0 rgba(74, 49, 37, 0.14);
}

.perk-choice-icon {
  font-size: 24px;
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: #fff4ec;
  border: 1.5px solid var(--border-ink);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.perk-choice-text h4 {
  margin: 0 0 2px;
  font-size: 13.5px;
  font-weight: 900;
  color: var(--text-main);
}

.perk-choice-text p {
  margin: 0;
  font-size: 11.5px;
  font-weight: 700;
  color: var(--text-sub);
  line-height: 1.3;
}

/* 结算星级 */
.result-stars {
  font-size: 22px;
  letter-spacing: 4px;
  margin: 2px 0 6px;
  min-height: 26px;
}

/* 店长隐藏后厨弹窗 */
.secret-actions {
  display: flex;
  flex-direction: column;
  gap: 9px;
  margin-top: 12px;
}

.secret-reset-btn {
  justify-content: center;
  color: var(--danger);
  border-color: var(--danger);
  padding: 7px 10px;
}
