/* ============================================================
   拍得利 · 网页竞价大厅
   仅对已开通竞拍权限的竞买人开放；数据与小程序同源（/api/bids/*、/ws）
   ============================================================ */
:root {
  --red: #C22E2E;
  --red-l: #E8544F;
  --red-ll: #FDECEC;
  --o: #F0894A;
  --ink: #2B2118;
  --ink2: #5C5044;
  --muted: #7A6A5C;
  --muted2: #9A8C7E;
  --bg: #FDFAF7;
  --card: #FFFFFF;
  --line: #EDE5DA;
  --line2: #F5EEE5;
  --green: #2F7D46;
  --green-l: #EAF7EE;
  --shadow: 0 2px 10px rgba(48, 33, 20, .06);
  --shadow-lg: 0 14px 40px rgba(48, 33, 20, .13);
  --r: 14px;
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { height: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", "Segoe UI", sans-serif;
  font-size: 14px; line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}
button { font-family: inherit; cursor: pointer; }
input { font-family: inherit; }
[hidden] { display: none !important; }

/* 细滚动条：Windows 默认 15px 宽，会把滚动容器内容整体挤偏，
   窄窗口下单列布局就会表现为「右边留白比左边大」，看着不居中 */
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: rgba(122, 106, 92, .26); border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: rgba(122, 106, 92, .44); }
/* 注意：不要再加 scrollbar-width:thin —— Chrome 一旦识别该标准属性就会禁用 ::-webkit-scrollbar，
   反而回退到 15px 系统滚动条 */

/* ---------------- 登录 / 无权限 ---------------- */
.gate {
  min-height: 100vh; display: flex; align-items: center; justify-content: center;
  padding: 24px 16px;
  background:
    radial-gradient(900px 420px at 50% -10%, #FFE7E0 0%, rgba(255, 231, 224, 0) 70%),
    var(--bg);
}
.gate-card {
  width: 100%; max-width: 400px; background: var(--card);
  border-radius: 20px; padding: 32px 28px 26px; box-shadow: var(--shadow-lg);
  border: 1px solid var(--line2);
}
.gate-brand { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }
/* 图片 LOGO：登录卡片 32px，顶部栏 26px；宽高自适应保持等比 */
.brand-logo {
  flex: none; display: block; width: auto;
  height: 36px; object-fit: contain;
  /* 深蓝主色在米白底上略沉，加极轻的投影让图形有层次 */
  filter: drop-shadow(0 1px 1px rgba(40, 48, 136, .10));
}
.gate-brand .brand-logo { height: 40px; }
.brand-mark {
  font-size: 20px; font-weight: 800; letter-spacing: 1px; color: var(--red);
}
.brand-sub { font-size: 13px; color: var(--muted2); letter-spacing: .5px; }
.gate-desc { margin: 8px 0 22px; font-size: 13px; color: var(--muted); line-height: 1.7; }

/* 登录 / 注册 切换 */
.gate-tabs {
  display: flex; gap: 4px; margin: 16px 0 18px; padding: 4px;
  background: #F6F1EB; border-radius: 11px;
}
.gtab {
  flex: 1; height: 36px; border: none; background: none; border-radius: 8px;
  font-size: 14px; font-weight: 600; color: var(--muted);
  transition: background .15s, color .15s, box-shadow .15s;
}
.gtab:hover { color: var(--ink2); }
.gtab.is-on { background: #FFF; color: var(--red); box-shadow: 0 1px 3px rgba(0, 0, 0, .07); }
.gpanel > .gate-desc { margin: 0 0 16px; }

/* 个人 / 机构 分段选择 */
.seg { display: flex; gap: 8px; }
.seg-i {
  flex: 1; height: 44px; border: 1px solid var(--line); border-radius: 11px;
  background: #FFFDFB; color: var(--ink2); font-size: 14px; font-weight: 500;
  transition: border-color .15s, background .15s, color .15s;
}
.seg-i:hover { border-color: var(--o); }
.seg-i.is-on {
  border-color: var(--red); background: var(--red-ll); color: var(--red); font-weight: 700;
}

.fld { display: block; margin-bottom: 14px; }
.fld-k { display: block; font-size: 12px; color: var(--muted2); margin-bottom: 6px; }
.fld input {
  width: 100%; height: 46px; padding: 0 14px; font-size: 16px;
  border: 1px solid var(--line); border-radius: 11px; background: #FFFDFB;
  outline: none; transition: border-color .15s, box-shadow .15s;
}
.fld input:focus { border-color: var(--o); box-shadow: 0 0 0 3px rgba(240, 137, 74, .13); }
.fld-row { display: flex; gap: 10px; }
.fld-row input { flex: 1; min-width: 0; }
.btn-code {
  flex: none; width: 118px; height: 46px; border-radius: 11px;
  border: 1px solid var(--line); background: #FFF; color: var(--ink2);
  font-size: 13px; font-weight: 600; transition: all .15s;
}
.btn-code:hover:not(:disabled) { border-color: var(--o); color: var(--o); }
.btn-code:disabled { color: var(--muted2); background: #F7F3EE; cursor: default; }

.btn-primary {
  width: 100%; height: 48px; margin-top: 6px; border: none; border-radius: 12px;
  background: linear-gradient(135deg, var(--red-l), var(--red)); color: #fff;
  font-size: 16px; font-weight: 700; letter-spacing: 2px;
  box-shadow: 0 8px 20px rgba(194, 46, 46, .26); transition: transform .12s, box-shadow .15s;
}
.btn-primary:hover { box-shadow: 0 10px 26px rgba(194, 46, 46, .32); }
.btn-primary:active { transform: translateY(1px); }
.btn-primary:disabled { opacity: .6; box-shadow: none; cursor: default; }
.btn-plain {
  width: 100%; height: 44px; margin-top: 10px; border: none; background: none;
  color: var(--muted2); font-size: 13px;
}
.gate-foot { margin: 16px 0 0; font-size: 12px; color: var(--muted2); line-height: 1.7; text-align: center; }
.gate-err {
  margin: -4px 0 12px; padding: 10px 12px; border-radius: 9px;
  background: var(--red-ll); color: var(--red); font-size: 13px;
}
.gate-icon { font-size: 40px; text-align: center; margin-bottom: 6px; }
.gate-title { margin: 0 0 6px; font-size: 20px; text-align: center; }
.gate-steps { margin: 20px 0 22px; display: grid; gap: 10px; }
.step {
  display: flex; gap: 10px; align-items: flex-start;
  padding: 11px 13px; background: #FCF8F4; border-radius: 10px; font-size: 13px; color: var(--ink2);
}
.step b {
  flex: none; width: 20px; height: 20px; border-radius: 50%; background: var(--o); color: #fff;
  font-size: 12px; display: flex; align-items: center; justify-content: center;
}

/* ---------------- 顶栏 ---------------- */
/* 大厅整体限宽居中：出价面板不应贴到屏幕最右边。
   ≥1400 时按「视口宽 - 160」收缩，保证任何桌面窗口两侧都有 80px 留白
   （只写 max-width:1560 的话，1440/1536 的笔记本窗口等于没变）；
   再宽则封顶 1560，两侧留白随视口增大。 */
.hall {
  display: flex; flex-direction: column; height: 100vh; height: 100dvh;
  width: 100%; max-width: 1560px; margin: 0 auto;
  background: #fff;
  box-shadow: 0 0 0 1px var(--line2), 0 0 48px rgba(48, 33, 20, .05);
}
@media (min-width: 1400px) {
  .hall { width: calc(100% - 160px); }
  body { background: #F2EAE1; }
}
.topbar {
  flex: none; height: 54px; padding: 0 18px;
  display: flex; align-items: center; justify-content: space-between;
  background: #fff; border-bottom: 1px solid var(--line2); z-index: 10;
}
.topbar-l { display: flex; align-items: center; gap: 9px; }
.topbar-l .brand-logo { height: 30px; }
.topbar-r { display: flex; align-items: center; gap: 12px; }
.me-chip {
  font-size: 12px; color: var(--ink2); background: #FBF6F1;
  padding: 5px 11px; border-radius: 999px; font-variant-numeric: tabular-nums;
}
.conn { display: flex; align-items: center; gap: 5px; font-size: 12px; color: var(--muted2); }
.conn i { width: 7px; height: 7px; border-radius: 50%; background: #CBBFB2; }
.conn[data-state="on"] i { background: #35B36B; box-shadow: 0 0 0 3px rgba(53, 179, 107, .16); }
.conn[data-state="on"] em { color: var(--green); }
.conn[data-state="warn"] i { background: var(--o); }
.conn[data-state="warn"] em { color: var(--o); }
.conn[data-state="off"] i { background: #D9534F; }
.conn em { font-style: normal; }
.btn-quiet {
  border: 1px solid var(--line); background: #fff; color: var(--muted);
  font-size: 12px; padding: 5px 12px; border-radius: 999px;
}
.btn-quiet:hover { border-color: var(--red); color: var(--red); }

/* ---------------- 布局 ---------------- */
.layout {
  flex: 1; min-height: 0;
  display: grid; grid-template-columns: 316px minmax(0, 1fr);
}
.sidebar {
  display: flex; flex-direction: column; min-height: 0;
  background: #fff; border-right: 1px solid var(--line2);
}
.tabs { flex: none; display: flex; gap: 4px; padding: 10px 10px 6px; }
.tab {
  flex: 1; border: none; background: none; padding: 8px 4px 9px; border-radius: 9px;
  font-size: 13px; color: var(--muted); font-weight: 500; position: relative;
}
.tab.is-on { background: var(--red-ll); color: var(--red); font-weight: 700; }
.tab em {
  font-style: normal; font-size: 11px; margin-left: 2px; opacity: .75;
  font-variant-numeric: tabular-nums;
}
.lot-list { flex: 1; min-height: 0; overflow-y: auto; padding: 4px 10px 14px; }
.list-empty { padding: 40px 0; text-align: center; color: var(--muted2); font-size: 13px; }

.lot {
  display: flex; gap: 10px; padding: 9px; border-radius: 11px; margin-bottom: 4px;
  border: 1px solid transparent; cursor: pointer; transition: background .14s, border-color .14s;
}
.lot:hover { background: #FCF8F4; }
.lot.is-on { background: var(--red-ll); border-color: #F3C9C4; }
.lot-img {
  flex: none; width: 62px; height: 62px; border-radius: 8px; overflow: hidden;
  background: #F2EAE1; position: relative;
}
.lot-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.lot-body { flex: 1; min-width: 0; display: flex; flex-direction: column; justify-content: space-between; }
.lot-t {
  font-size: 13px; font-weight: 600; line-height: 1.35; color: var(--ink);
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.lot-b { display: flex; align-items: center; justify-content: space-between; gap: 6px; }
.lot-p { font-size: 13px; font-weight: 700; color: var(--red); font-variant-numeric: tabular-nums; }
.lot-p i { font-style: normal; font-size: 10px; font-weight: 500; color: var(--muted2); margin-right: 2px; }
.lot-s { font-size: 11px; color: var(--muted2); font-variant-numeric: tabular-nums; }
.badge {
  display: inline-block; font-size: 10px; font-weight: 700; padding: 1px 6px;
  border-radius: 5px; letter-spacing: .3px; vertical-align: 1px;
}
.bg-bidding { background: var(--red); color: #fff; }
.bg-soon { background: #FDF0E3; color: #B96A16; }
.bg-ended { background: #F1EDE8; color: var(--muted2); }

/* ---------------- 舞台 ---------------- */
/* hall 改为白底后，舞台要显式用页底色，保持「左侧白栏 + 右侧米白舞台」的层次 */
.stage { min-width: 0; min-height: 0; overflow: hidden; background: var(--bg); }
.stage-empty {
  height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 10px; color: var(--muted2);
}
.se-ico { font-size: 44px; opacity: .5; }
.stage-body {
  height: 100%; display: grid; grid-template-columns: minmax(0, 1fr) 424px;
  gap: 0; overflow: hidden;
}

/* 图集 */
.gallery {
  min-width: 0; padding: 18px; display: flex; flex-direction: column; gap: 10px;
  overflow: hidden; justify-content: center;
}
.gal-main {
  flex: 1; min-height: 0; width: 100%;
  border-radius: 16px; overflow: hidden; background: #F3EBE2;
  display: flex; align-items: center; justify-content: center; box-shadow: var(--shadow);
}
/* 宽屏才按图片比例收缩（比例由 fitGallery 写入）：窄屏图片区本身就矮，撑满更合适 */
@media (min-width: 1181px) {
  .gal-main { flex: 0 1 auto; max-height: 100%; aspect-ratio: 4 / 3; }
}
/* 主图按自身比例在容器内居中：用 max-* + auto 而非 100%/100%，
   低分辨率图不会被强行放大到容器宽度（放大只会发虚），高分辨率图仍等比缩放到容器内 */
.gal-main img {
  max-width: 100%; max-height: 100%; width: auto; height: auto;
  object-fit: contain; display: block;
}
.gal-main.is-empty { display: flex; align-items: center; justify-content: center; }
.gal-main.is-empty img { display: none; }
.gal-main.is-empty::after { content: "暂无图片"; color: #BCA992; font-size: 13px; letter-spacing: 1px; }
.gal-thumbs { flex: none; display: flex; gap: 8px; overflow-x: auto; padding-bottom: 2px; }
.gal-thumbs img {
  width: 58px; height: 58px; object-fit: cover; border-radius: 8px; cursor: pointer;
  border: 2px solid transparent; opacity: .72; transition: all .14s; flex: none;
}
.gal-thumbs img:hover { opacity: 1; }
.gal-thumbs img.is-on { border-color: var(--red); opacity: 1; }

/* 小程序码：固定在图片下方的一个位置。
   - 码图放 assets/miniprogram-qr.png 即自动填充（app.js 加载成功才显示，失败退回虚线占位框）；
   - 占位框与真码同为 88×88，换图时布局不跳动；
   - 整块白底卡片、居中、自适应宽度，不占满图片区，避免主图被压得过小 */
.gal-qr {
  flex: none; align-self: center; max-width: 100%;
  display: flex; align-items: center; gap: 14px;
  padding: 11px 16px 11px 11px;
  background: var(--card); border: 1px solid var(--line);
  border-radius: 14px; box-shadow: var(--shadow);
}
.qr-box {
  flex: none; width: 88px; height: 88px; border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  overflow: hidden; background: #fff;
  border: 1px dashed #DCCBB8;
}
.gal-qr.has-img .qr-box { border-style: solid; border-color: var(--line); }
.qr-box img { width: 100%; height: 100%; object-fit: contain; display: block; }
/* 码图未加载成功时整块让位给占位框（用 class 控制，不用 hidden 属性 —— 会被上面的 display 覆盖） */
.gal-qr:not(.has-img) .qr-box img { display: none; }
.gal-qr.has-img .qr-ph { display: none; }
.qr-ph {
  display: flex; flex-direction: column; align-items: center; gap: 5px;
  color: #C4B2A0;
}
.qr-ph svg { width: 26px; height: 26px; }
.qr-ph span { font-size: 10px; letter-spacing: 1px; }
.qr-txt { min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.qr-txt b { font-size: 13px; font-weight: 700; color: var(--ink); white-space: nowrap; }
.qr-txt span { font-size: 11px; line-height: 1.45; color: var(--muted2); max-width: 190px; }

/* 右侧面板 */
.panel {
  min-width: 0; overflow-y: auto; padding: 18px;
  display: flex; flex-direction: column; gap: 14px;
}
.p-head { display: flex; flex-direction: column; gap: 8px; }
.p-title { margin: 0; font-size: 19px; line-height: 1.35; font-weight: 700; word-break: break-word; }
.p-meta { display: flex; flex-wrap: wrap; gap: 6px; }
.chip {
  font-size: 11px; padding: 2px 9px; border-radius: 999px;
  background: #F7F2EC; color: var(--muted);
}

/* 价格卡 */
.pricebox {
  border-radius: 16px; padding: 16px 18px; color: #fff;
  background: linear-gradient(135deg, var(--red-l), var(--red));
  box-shadow: 0 10px 26px rgba(194, 46, 46, .24);
  display: flex; align-items: flex-end; justify-content: space-between; gap: 14px;
}
.pricebox-l { min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.pricebox-r { flex: none; text-align: right; display: flex; flex-direction: column; gap: 2px; }
.pb-lab { font-size: 12px; color: rgba(255, 255, 255, .85); }
.pb-cur {
  font-size: 34px; font-weight: 800; line-height: 1.12; letter-spacing: -.5px;
  font-variant-numeric: tabular-nums; word-break: break-all;
}
.pb-cur.masked { letter-spacing: 3px; opacity: .8; }
.pb-lead { font-size: 12px; color: #FFE3B0; min-height: 17px; }
.pb-lead.is-self { color: #C8F7D8; font-weight: 700; }
.pb-time {
  font-size: 22px; font-weight: 700; line-height: 1.2;
  font-variant-numeric: tabular-nums; letter-spacing: .5px;
}
.pb-time.is-soon { color: #FFE08A; }
.pb-count { font-size: 11px; color: rgba(255, 255, 255, .8); }

/* 出价区 */
.bidzone {
  border: 1px solid var(--line2); border-radius: 16px; padding: 14px; background: #fff;
  display: flex; flex-direction: column; gap: 11px; box-shadow: var(--shadow);
}
.bz-hint { font-size: 13px; color: var(--ink2); }
.bz-hint b { color: var(--red); font-variant-numeric: tabular-nums; }

/* 加价器：与小程序竞价大厅同构 —— 左「－」右「＋」，中间是「当前价 + 幅度×次数」的预览 */
.bz-op { display: flex; align-items: stretch; gap: 10px; }
.bz-step {
  flex: 1; min-width: 0; display: flex; align-items: center; gap: 4px;
  padding: 5px; border: 1px solid var(--line); border-radius: 12px; background: #FFFDFB;
  transition: opacity .14s;
}
.bz-step.is-off { opacity: .55; }
.bz-sym {
  flex: none; width: 38px; height: 40px; border: none; border-radius: 9px;
  background: #FBF3EC; color: #B4522C; font-size: 19px; font-weight: 700; line-height: 1;
  display: flex; align-items: center; justify-content: center; transition: background .13s;
}
.bz-sym:hover:not(:disabled) { background: #FDEDE4; }
.bz-sym:active:not(:disabled) { transform: translateY(1px); }
.bz-sym:disabled { opacity: .4; cursor: default; }
.bz-mid { flex: 1; min-width: 0; text-align: center; }
.bz-val {
  font-size: 21px; font-weight: 800; line-height: 1.18; color: var(--red);
  font-variant-numeric: tabular-nums; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.bz-val .bz-yen { font-size: 13px; font-weight: 600; margin-right: 2px; }
.bz-sub { font-size: 11px; color: var(--muted2); margin-top: 1px; }
.bz-sub b { color: var(--ink2); font-variant-numeric: tabular-nums; }

.btn-bid {
  flex: none; width: 118px; border: none; border-radius: 12px;
  background: linear-gradient(135deg, var(--red-l), var(--red)); color: #fff;
  font-size: 17px; font-weight: 800; letter-spacing: 2px;
  box-shadow: 0 8px 18px rgba(194, 46, 46, .25);
}
.btn-bid:disabled { opacity: .5; box-shadow: none; cursor: default; }
/* 不可出价原因：位置与小程序 actbar-tip 一致（操作条下方） */
.bz-tip {
  font-size: 12px; color: #B4522C; background: #FDF1E7;
  border-radius: 9px; padding: 7px 11px;
}
.bz-note { font-size: 11px; color: var(--muted2); line-height: 1.6; }

/* ---- 竞价时间规则（自由竞价 / 限时竞价 / 延时重置），与小程序 cdinfo 同构 ---- */
.timerule {
  padding: 13px 14px 12px; border-radius: var(--r);
  background: #FFFDFA; border: 1px solid var(--line2); box-shadow: var(--shadow);
  display: flex; flex-direction: column; gap: 9px;
}
.tr-head { display: flex; align-items: center; gap: 8px; }
/* 阶段标签配色与小程序 .stg-free / .stg-limited 完全一致 */
.tr-stage {
  display: inline-flex; align-items: center; height: 22px; padding: 0 9px;
  border-radius: 7px; background: #FDE7E7; color: #C22E2E;
  font-size: 11px; font-weight: 800; letter-spacing: .3px;
}
.tr-stage.is-free { background: #EAF3EC; color: #2F7D46; }
.tr-stage.is-idle { background: #F3EDE4; color: var(--muted); }
.tr-flag {
  display: inline-flex; align-items: center; height: 22px; padding: 0 8px;
  border-radius: 7px; background: #FFF6EC; color: #CE6E2C;
  border: 1px solid #F7DFC8;
  font-size: 11px; font-weight: 700; font-variant-numeric: tabular-nums;
}
.tr-cells { display: grid; grid-template-columns: repeat(3, 1fr); gap: 7px; }
.tr-cell {
  padding: 9px 4px 8px; border-radius: 10px; text-align: center;
  background: #FBF8F3; border: 1px solid #EFE7DA;
}
.tr-k { font-size: 10px; color: var(--muted); line-height: 1.3; white-space: nowrap; }
.tr-v {
  margin-top: 3px; font-size: 14px; font-weight: 800; color: var(--ink);
  font-variant-numeric: tabular-nums; letter-spacing: -.2px;
}
.tr-note { font-size: 11px; color: var(--muted); line-height: 1.65; }
.tr-note b { color: #C9662A; font-weight: 800; font-variant-numeric: tabular-nums; }
/* 「重置为 N 秒」整体不拆行，避免窄栏下只剩数字孤零零掉到第二行 */
.tr-keep { white-space: nowrap; }

@media (max-width: 1180px) {
  .tr-k { font-size: 10px; }
  .tr-v { font-size: 13px; }
}

/* ---------------- 出价确认层 ---------------- */
.mask {
  position: fixed; inset: 0; z-index: 80; background: rgba(30, 22, 15, .44);
  display: flex; align-items: flex-end; justify-content: center;
}
.sheet {
  width: 100%; max-width: 430px; background: #fff;
  border-radius: 18px 18px 0 0; padding: 18px 20px 22px;
  box-shadow: 0 -12px 44px rgba(40, 30, 20, .2);
}
@media (min-width: 721px) {
  .mask { align-items: center; }
  .sheet { border-radius: 18px; }
}
.sheet-h {
  display: flex; align-items: center; justify-content: space-between;
  font-size: 16px; font-weight: 700;
}
.sheet-x {
  border: none; background: none; color: var(--muted2); font-size: 17px;
  padding: 4px 6px; line-height: 1;
}
.sheet-big {
  margin: 16px 0 12px; font-size: 34px; font-weight: 800; color: var(--red);
  line-height: 1.15; font-variant-numeric: tabular-nums; word-break: break-all;
}
.sheet-big .sheet-yen { font-size: 16px; font-weight: 600; }
.sheet-row {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 9px 0; border-bottom: 1px solid var(--line2);
  font-size: 13px; color: var(--ink2);
}
.sheet-row b {
  color: var(--ink); font-variant-numeric: tabular-nums;
  flex: none; white-space: nowrap;
}
.sheet-warn {
  margin: 12px 0 14px; padding: 10px 12px; border-radius: 10px;
  background: #FDF3E9; color: #B4522C; font-size: 12px; line-height: 1.65;
}
.sheet-ok {
  width: 100%; height: 48px; border: none; border-radius: 12px;
  background: linear-gradient(135deg, var(--red-l), var(--red)); color: #fff;
  font-size: 17px; font-weight: 800; letter-spacing: 1px;
  box-shadow: 0 8px 20px rgba(194, 46, 46, .26);
}
.sheet-ok:disabled { opacity: .6; box-shadow: none; cursor: default; }

/* 不可出价提示 */
.lockzone {
  border: 1px dashed #E4D6C6; border-radius: 16px; padding: 16px; background: #FBF7F2;
  font-size: 13px; color: var(--ink2); line-height: 1.7;
}
.lockzone b { color: var(--red); }
.lockzone .lk-t { font-weight: 700; margin-bottom: 4px; color: var(--ink); }

/* 记录 */
.records {
  flex: 1; min-height: 180px; display: flex; flex-direction: column;
  border: 1px solid var(--line2); border-radius: 16px; background: #fff; overflow: hidden;
  box-shadow: var(--shadow);
}
.rec-head {
  flex: none; padding: 11px 14px; font-size: 13px; font-weight: 700;
  border-bottom: 1px solid var(--line2); display: flex; justify-content: space-between; align-items: center;
}
.rec-head em { font-style: normal; font-size: 11px; color: var(--muted2); font-weight: 500; }
.rec-list { flex: 1; min-height: 0; overflow-y: auto; padding: 4px 0; }
.rec {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 9px 14px; font-size: 13px; border-bottom: 1px dashed var(--line2);
}
.rec:last-child { border-bottom: none; }
.rec-l { display: flex; align-items: center; gap: 8px; min-width: 0; }
.rec-no {
  font-size: 11px; font-weight: 700; padding: 1px 7px; border-radius: 5px;
  background: #F3EDE6; color: var(--muted); font-variant-numeric: tabular-nums;
}
.rec-no.is-me { background: var(--red-ll); color: var(--red); }
.rec-p { font-weight: 700; font-variant-numeric: tabular-nums; }
.rec-p.is-me { color: var(--red); }
.rec-t { font-size: 11px; color: var(--muted2); flex: none; font-variant-numeric: tabular-nums; }
.rec-empty { padding: 30px 14px; text-align: center; color: var(--muted2); font-size: 13px; }
.rec-new { animation: flash .7s ease-out; }
@keyframes flash {
  from { background: #FFF3E2; }
  to { background: transparent; }
}

/* ---------------- Toast ---------------- */
.toast {
  position: fixed; left: 50%; bottom: 44px; transform: translateX(-50%);
  max-width: min(88vw, 460px); padding: 11px 20px; border-radius: 12px;
  background: rgba(38, 30, 24, .93); color: #fff; font-size: 13.5px; line-height: 1.55;
  box-shadow: 0 10px 30px rgba(0, 0, 0, .22); z-index: 999; text-align: center;
  animation: toastIn .18s ease-out;
}
.toast.ok { background: rgba(37, 108, 66, .95); }
.toast.err { background: rgba(160, 40, 40, .95); }
@keyframes toastIn { from { opacity: 0; transform: translate(-50%, 8px); } }

/* ---------------- 响应式 ---------------- */
@media (max-width: 1180px) {
  .layout { grid-template-columns: 272px minmax(0, 1fr); }
  .stage-body { grid-template-columns: minmax(0, 1fr) 372px; }
  .pb-cur { font-size: 30px; }
  /* 图片区变窄，扫码块收成「码 + 一行标题」，说明文字让位给主图 */
  .gal-qr { gap: 10px; padding: 8px 12px 8px 8px; }
  .qr-box { width: 68px; height: 68px; }
  .qr-txt b { font-size: 12px; }
  .qr-txt span { display: none; }
}

@media (max-width: 900px) {
  .layout { grid-template-columns: minmax(0, 1fr); grid-template-rows: auto minmax(0, 1fr); }
  .sidebar {
    min-width: 0;
    border-right: none; border-bottom: 1px solid var(--line2);
    max-height: 174px;
  }
  .lot-list { display: flex; gap: 8px; overflow-x: auto; overflow-y: hidden; padding: 0 10px 10px; }
  .lot { flex: none; width: 232px; margin: 0; }
  .stage { min-width: 0; }
  .stage-body {
    grid-template-columns: minmax(0, 1fr); grid-template-rows: 210px minmax(0, 1fr);
    overflow-y: auto;
  }
  .gallery { padding: 12px; min-width: 0; }
  .gal-thumbs { display: none; }
  /* 窄屏图片区固定 210px 高，再放码会把主图压到看不清；
     且此时用户基本在微信内直接打开，扫码这一步本身多余 */
  .gal-qr { display: none; }
  .panel { padding: 0 12px 18px; overflow: visible; min-width: 0; }
  .pb-cur { font-size: 28px; }
  .topbar { padding: 0 12px; }
  .me-chip { display: none; }
}

@media (max-width: 480px) {
  .pb-cur { font-size: 26px; }
  .bz-sym { width: 34px; height: 38px; font-size: 17px; }
  .bz-val { font-size: 19px; }
  .btn-bid { width: 88px; letter-spacing: 1px; font-size: 15px; }
  .gate-card { padding: 26px 20px 22px; }
}
