* { box-sizing: border-box; }
/* iOS Safari 无视 user-scalable=no, 连点会触发双击缩放, 缩放后 fixed 弹窗命中区错位导致公告关不掉 */
* { touch-action: manipulation; }
html, body { margin: 0; padding: 0; background: #f7f8fa; -webkit-tap-highlight-color: transparent; }
#app { max-width: 640px; margin: 0 auto; min-height: 100vh; background: #f7f8fa; }
.page { padding-bottom: 60px; position: relative; z-index: 0; }   /* 关住 buy-ticker(z-index:20) 等浮层, 不让它盖到底部菜单上 */

/* 钱包条 */
.wallet-bar {
  background: linear-gradient(135deg, #7232dd, #4a2b9c);
  color: #fff; padding: 14px 16px; display: flex; align-items: center; justify-content: space-between;
}
.wallet-bar .bal { font-size: 22px; font-weight: bold; }
.wallet-bar .label { font-size: 12px; opacity: .85; }
.wallet-bar .role { font-size: 12px; opacity: .9; text-align: right; }

/* 首页: 左分类右商品 */
.mall-body { display: flex; height: calc(100vh - 110px); }
.cat-side { width: 90px; background: #f2f3f5; overflow-y: auto; flex-shrink: 0; }
.cat-item { padding: 14px 6px; text-align: center; font-size: 13px; color: #333; border-left: 3px solid transparent; }
.cat-item.active { background: #fff; color: #7232dd; border-left-color: #7232dd; font-weight: bold; }
.prod-side { flex: 1; overflow-y: auto; padding: 10px; }
/* ⚠️ z-index:0 是必需的, 不是多余的:
   它让 .prod-card 成为一个**层叠上下文**, 把里面的角标(倍数胶囊/不可用绑定币标)全部关在卡片内部。
   否则角标的 z-index(2) 会跑到根层级, 而 Vant 的 van-tabbar 默认 z-index 只有 1
   → 滚动时角标会**盖在底部菜单上面**。父级只写 position:relative 是不够的(z-index:auto 不创建层叠上下文)。 */
.prod-card { background: #fff; border-radius: 8px; margin-bottom: 10px; overflow: hidden; display: flex; padding: 10px; position: relative; z-index: 0; }
.prod-card .thumb { width: 76px; height: 76px; border-radius: 6px; object-fit: cover; background: #eee; flex-shrink: 0; }
.prod-card .thumb.ph { display: flex; align-items: center; justify-content: center; color: #ccc; font-size: 12px; }
.prod-card .info { flex: 1; padding-left: 10px; display: flex; flex-direction: column; justify-content: space-between; min-width: 0; }
.prod-card .name { font-size: 15px; color: #222; font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.prod-card .price { color: #ee0a24; font-size: 17px; font-weight: bold; }
.prod-card .price small { font-size: 12px; }

.rich { padding: 12px 16px; background: #fff; line-height: 1.7; word-break: break-word; }
.rich img { max-width: 100%; height: auto; }

/* 进入商城弹框公告正文 (Quill 输出的富文本) */
.notice-body { font-size: 14px; color: #323233; }
.notice-body p { margin: 0 0 6px; }
.notice-body ul, .notice-body ol { padding-left: 20px; margin: 6px 0; }

.enter-tip { padding: 60px 30px; text-align: center; color: #969799; }
.enter-tip .big { font-size: 60px; margin-bottom: 16px; }

.section-title { font-size: 14px; color: #969799; padding: 12px 16px 6px; }

/* 妖狐币图标 (替代 ¥) */
.coin{width:1em;height:1em;vertical-align:-0.15em;display:inline-block;margin-right:1px}

/* 首页热销推荐横滑条 */
.hot-bar { background: #fff; padding: 10px 0 10px 12px; margin-bottom: 8px; }
.hot-title { font-size: 14px; font-weight: bold; color: #ee0a24; margin-bottom: 8px; }
.hot-scroll { display: flex; gap: 10px; overflow-x: auto; padding-bottom: 4px; -webkit-overflow-scrolling: touch; }
.hot-scroll::-webkit-scrollbar { display: none; }
.hot-card { flex: 0 0 auto; width: 88px; position: relative; z-index: 0; }   /* 同上: 关住内部角标 */
.hot-thumb { width: 88px; height: 88px; border-radius: 6px; object-fit: cover; background: #eee; box-sizing: border-box; }
.hot-thumb.hot-ph { display: flex; align-items: center; justify-content: center; color: #ccc; font-size: 12px; }
.hot-name { font-size: 12px; color: #323233; margin-top: 4px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hot-price { font-size: 13px; color: #ee0a24; font-weight: bold; }
.hot-sold { font-size: 11px; color: #969799; }

/* 购物车项: 勾选框/操作区垂直居中 */
.cart-item { display: flex; align-items: center; background: #fff; margin: 10px; border-radius: 8px; padding: 12px 10px; }
.cart-cb { flex: 0 0 auto; margin-right: 8px; }
.cart-thumb { width: 70px; height: 70px; border-radius: 6px; object-fit: cover; background: #eee; flex-shrink: 0; }
.cart-thumb.cart-ph { display: flex; align-items: center; justify-content: center; color: #ccc; font-size: 12px; }
.cart-info { flex: 1; min-width: 0; padding: 0 10px; }
.cart-name { font-size: 14px; color: #323233; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; margin-bottom: 2px; }
.cart-price { color: #ee0a24; font-size: 16px; font-weight: bold; margin-top: 2px; }
.cart-ops { flex: 0 0 auto; display: flex; flex-direction: column; align-items: center; justify-content: center; }

/* 购物车删除按钮: 与上方数量器等宽, 视觉整齐 */
.cart-del { margin-top: 10px; width: 100%; min-width: 96px; }

/* 购物车数量加减器配色: 紫色加减按钮 + 白底数字 */
.cart-ops .van-stepper__minus,
.cart-ops .van-stepper__plus { background: #7232dd; color: #fff; border-radius: 4px; }
.cart-ops .van-stepper__minus--disabled,
.cart-ops .van-stepper__plus--disabled { background: #d5c4f2; color: #fff; }
.cart-ops .van-stepper__input { background: #f7f8fa; color: #323233; margin: 0 3px; }

/* 首页购买滚动喇叭: 左上角, 每条独立玻璃胶囊, 多条无缝向上滚动 + 上下渐隐 */
.buy-ticker {
  position: absolute; top: 8px; left: 8px; z-index: 20;
  max-width: 66%; height: 150px; overflow: hidden;
  pointer-events: none;  /* 纯展示浮层, 点击穿透到下方(搜索/钱包栏) */
  /* 上下边缘轻微渐隐(只淡最边缘, 中间清晰): 胶囊滚入时"从透明到出现" */
  -webkit-mask-image: linear-gradient(to bottom, transparent, #000 12%, #000 88%, transparent);
  mask-image: linear-gradient(to bottom, transparent, #000 12%, #000 88%, transparent);
}
.buy-ticker-track { display: block; }
.buy-ticker-track.scroll { animation: buyTickerScroll 16s linear infinite; }
.buy-ticker-item {
  display: block; width: -webkit-fit-content; width: fit-content; max-width: 100%;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  margin-bottom: 6px;
  line-height: 22px; padding: 3px 14px;
  font-size: 13px; font-weight: 500; color: #fff;
  text-shadow: 0 1px 2px rgba(0,0,0,.55);
  border-radius: 999px;
  background: rgba(38, 38, 48, 0.6);
  -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px);
  box-shadow: 0 1px 5px rgba(0,0,0,.25);
  border: 1px solid rgba(255,255,255,.22);
}
.buy-ticker-item .buy-role { color: #ffd062; font-weight: bold; }
@keyframes buyTickerScroll {
  from { transform: translateY(0); }
  to   { transform: translateY(-50%); }
}

/* 商品图倍数角标 (贴右下角, 橙色胶囊) */
.prod-card .thumb-wrap { position: relative; z-index: 0; flex-shrink: 0; width: 76px; height: 76px; }
.mult-badge {
  position: absolute; right: 2px; bottom: 2px; z-index: 2;
  background: linear-gradient(135deg,#ff9a2e,#ee6a00); color: #fff;
  font-size: 11px; font-weight: 700; line-height: 1;
  padding: 2px 6px; border-radius: 9px;
  box-shadow: 0 1px 3px rgba(0,0,0,.3); border: 1px solid rgba(255,255,255,.5);
}

/* 购物车缩略图倍数角标 */
.cart-thumb-wrap { position: relative; z-index: 0; flex-shrink: 0; width: 70px; height: 70px; }
.cart-thumb-wrap .mult-badge { right: 2px; bottom: 2px; }

/* 订单明细缩略图 + 倍数角标 */
.ord-thumb-wrap { position: relative; z-index: 0; flex-shrink: 0; width: 44px; height: 44px; margin-right: 10px; }
.ord-thumb { width: 44px; height: 44px; border-radius: 5px; object-fit: cover; background: #eee; box-sizing: border-box; }
.ord-thumb.ord-ph { display: flex; align-items: center; justify-content: center; color: #ccc; font-size: 10px; }
.ord-thumb-wrap .mult-badge { right: -3px; bottom: -3px; font-size: 10px; padding: 1px 5px; }

/* ===== 会员权益 ===== */
.member-badge { display: inline-block; padding: 1px 9px; border-radius: 10px; background: linear-gradient(135deg, #f7d774, #e6b422); color: #5b3a00; font-size: 12px; font-weight: 700; white-space: nowrap; box-shadow: 0 1px 4px rgba(230,180,34,.45); }
.member-banner { display: flex; justify-content: space-between; align-items: center; margin: 8px 10px 0; padding: 9px 14px; border-radius: 10px; background: linear-gradient(135deg, #fdf3d0, #f9e29c); color: #5b3a00; font-size: 13px; font-weight: 600; }
.member-banner b { color: #b8860b; font-size: 13px; flex-shrink: 0; margin-left: 8px; }
.member-card { margin: 10px; padding: 16px 14px; border-radius: 12px; background: linear-gradient(135deg, #f7d774, #e6a422); color: #5b3a00; box-shadow: 0 3px 12px rgba(230,164,34,.35); }
.member-type-card { margin: 10px; padding: 14px; border-radius: 12px; background: linear-gradient(135deg, #fdf3d0, #f9e29c); border: 1px solid #f0d17a; }
.reddot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: #ee0a24; margin-left: 5px; vertical-align: 1px; }

/* ===== 角色交易 ===== */
.role-card { background: #fff; margin: 10px; border-radius: 10px; padding: 12px 14px; }
.role-pick { border: 1px solid #ebedf0; border-radius: 8px; padding: 8px 12px; cursor: pointer; min-width: 90px; }
.role-pick.active { border-color: #7232dd; background: #f5f0ff; }
.role-item { display: inline-flex; align-items: center; border: 1.5px solid #ebedf0; border-radius: 5px; padding: 2px 7px; font-size: 12px; background: #fafafa; }
.role-banner { display: flex; justify-content: space-between; align-items: center; margin: 8px 10px 0; padding: 9px 14px; border-radius: 10px; background: linear-gradient(135deg, #e8f0ff, #d4e4ff); color: #2b4a8c; font-size: 13px; font-weight: 600; }
.role-banner b { color: #409eff; flex-shrink: 0; margin-left: 8px; }
