:root {
  --red: #e1251b;
  --red-dark: #c41018;
  --text: #222;
  --muted: #888;
  --line: #eee;
  --bg: #f5f6f8;
}

* { box-sizing: border-box; }

html, body { margin: 0; padding: 0; }

body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  color: var(--text);
  background: var(--bg);
  font-family: "PingFang SC", "Microsoft YaHei", "Noto Sans SC", sans-serif;
  font-size: 14px;
}

main { flex: 1; }

a { color: #333; text-decoration: none; }
a:hover { color: var(--red); }

button, input, select { font-family: inherit; }

.wrap { width: min(1200px, calc(100% - 32px)); margin: 0 auto; }
.page { padding: 8px 0 48px; }
.page-flash { padding-top: 16px; }

.flash {
  background: #fff;
  border: 1px solid var(--line);
  border-left: 4px solid var(--red);
  padding: 10px 14px;
}

.topbar { background: #f7f7f7; color: #777; font-size: 12px; }
.topbar-inner, .subnav-inner { display: flex; align-items: center; justify-content: space-between; min-height: 36px; gap: 12px; }
.top-links, .logout-form { display: flex; align-items: center; gap: 8px; }
.top-links a { color: #666; }
.sep { color: #ddd; }
.who { max-width: 180px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.logout-form { margin: 0; }
.logout-form button { background: none; border: 0; padding: 0; color: #666; cursor: pointer; }
.logout-form button:hover { color: var(--red); }

.mast { background: #fff; border-bottom: 1px solid var(--line); }
.mast-inner { display: flex; align-items: stretch; min-height: 96px; }
.brand { display: flex; align-items: center; padding: 8px 16px 8px 0; color: inherit; }
.brand:hover { color: inherit; }
.brand-logo { display: block; height: 80px; width: auto; }
.cats { flex: 1; background: var(--red); display: flex; align-items: center; flex-wrap: wrap; padding: 0 8px; }
.cats a { color: #fff; padding: 8px 14px; font-size: 15px; }
.cats a:hover { color: #fff; background: rgba(255,255,255,.14); }

.subnav { background: #fff; border-bottom: 1px solid var(--line); }
.subnav nav { display: flex; gap: 4px; }
.subnav nav a { padding: 14px 16px; }
.subnav nav a.active { color: var(--red); font-weight: 600; box-shadow: inset 0 -2px 0 var(--red); }
.search { display: flex; }
.search input { width: 220px; height: 34px; border: 1px solid #e5e5e5; padding: 0 10px; }
.search button { height: 34px; padding: 0 16px; background: var(--red); color: #fff; border: 0; cursor: pointer; }
.search button:hover { background: var(--red-dark); }

.site-foot { background: #fff; border-top: 1px solid var(--line); margin-top: 12px; }
.foot-grid { display: grid; grid-template-columns: 1fr 1fr 1.4fr; gap: 24px; padding: 28px 0; }
.foot-grid h4 { margin: 0 0 10px; font-size: 15px; }
.foot-grid a, .foot-grid p { display: block; color: #777; margin: 6px 0; line-height: 1.6; }
.copy { border-top: 1px solid var(--line); text-align: center; color: #999; font-size: 12px; padding: 12px; }

.hero { display: grid; grid-template-columns: 1.4fr .8fr; gap: 20px; background: #fff; border: 1px solid var(--line); padding: 28px; margin: 16px 0 8px; }
.hero h1 { font-size: 28px; margin: 0 0 10px; }
.hero p { color: #666; line-height: 1.7; margin: 0; }
.hero-actions { display: flex; gap: 10px; margin-top: 18px; }
.hero-side { background: #fff7f6; padding: 16px 18px; }
.hero-side h2 { margin: 0 0 8px; font-size: 16px; }
.hero-side ol { margin: 0; padding-left: 18px; color: #444; }
.hero-side li { margin: 8px 0; }
.stats { display: flex; gap: 22px; margin-top: 18px; }
.stats b { display: block; color: var(--red); font-size: 26px; line-height: 1.1; }
.stats span { color: var(--muted); font-size: 12px; }

.section-head { display: flex; justify-content: space-between; align-items: baseline; margin: 18px 0 10px; }
.section-head h2 { font-size: 18px; margin: 0; }
.section-head a { color: var(--red); font-size: 13px; }

.filters { background: #fff; border: 1px solid var(--line); padding: 12px 14px; margin: 16px 0 12px; }
.status-tabs, .cat-tabs { display: flex; flex-wrap: wrap; gap: 8px; }
.cat-tabs { margin-top: 10px; }
.status-tabs a, .cat-tabs a { padding: 6px 12px; background: #f6f6f6; color: #444; font-size: 13px; }
.status-tabs a.on, .cat-tabs a.on { background: var(--red); color: #fff; }
.result-line { color: var(--muted); font-size: 13px; margin: 0 0 10px; }

.lot-card {
  display: grid;
  grid-template-columns: 180px 1fr auto;
  gap: 16px;
  align-items: center;
  background: #fff;
  border: 1px solid var(--line);
  padding: 12px;
  margin-bottom: 12px;
  color: inherit;
}
.lot-card:hover { color: inherit; border-color: var(--red); }
.lot-card:hover h3 { color: var(--red); }
.lot-cover { position: relative; height: 112px; display: flex; align-items: flex-end; padding: 8px; color: #fff; overflow: hidden; }
.lot-cover > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.lot-cover > span { position: relative; z-index: 1; text-shadow: 0 1px 2px rgba(0,0,0,.65); }
.lot-cover em {
  position: absolute; left: 8px; top: 8px; font-style: normal;
  background: #8a8a8a; color: #fff; font-size: 12px; padding: 2px 6px;
}
.lot-cover em.live { background: var(--red); }
.lot-cover em.upcoming { background: #f5a623; }
.lot-body h3 { font-size: 16px; margin: 0 0 6px; line-height: 1.4; }
.muted, .lot-line, .lot-time { margin: 0; color: var(--muted); font-size: 13px; }
.lot-line { margin-top: 8px; }
.lot-time { margin-top: 6px; color: #555; }
.lot-side { text-align: right; min-width: 140px; }
.lot-now label { display: block; color: var(--muted); font-size: 12px; }
.lot-now strong { color: var(--red); font-size: 26px; font-weight: 700; font-variant-numeric: tabular-nums; }
.lot-now small { color: #666; margin-left: 4px; }
.lot-side .btn-line { margin-top: 8px; }

.btn-bid, .btn-line, .btn-muted {
  display: inline-flex; align-items: center; justify-content: center;
  height: 40px; padding: 0 18px; font-size: 15px; cursor: pointer; border: 1px solid transparent;
}
.btn-bid { background: var(--red); color: #fff; border-color: var(--red); }
.btn-bid:hover { background: var(--red-dark); color: #fff; }
.btn-line { background: #fff; color: var(--red); border-color: var(--red); }
.btn-line:hover { background: #fff5f5; color: var(--red); }
.btn-muted { background: #f5f5f5; color: #999; border-color: #e5e5e5; cursor: default; }
.btn-block { width: 100%; }

.meet-head, .panel, .tab-body, .auth-card, .pay-card {
  background: #fff; border: 1px solid var(--line);
}
.meet-head { display: flex; justify-content: space-between; gap: 20px; padding: 16px 18px; margin-bottom: 16px; }
.meet-head h1, .meet-head h2 { font-size: 20px; margin: 8px 0; }
.meet-head p { margin: 2px 0; color: #666; }
.sync { display: inline-block; background: #f5a623; color: #fff; font-size: 12px; padding: 2px 6px; }
.meet-lots { display: flex; gap: 12px; overflow-x: auto; max-width: 520px; }
.meet-lot { width: 120px; flex: none; text-align: center; color: #666; font-size: 12px; }
.meet-lot:hover { color: var(--red); }
.meet-lot .mini { height: 72px; margin-bottom: 6px; position: relative; }
.meet-lot.on .mini { outline: 2px solid var(--red); outline-offset: 1px; }
.meet-lot.on span { color: var(--red); }
.meet-lot i {
  position: absolute; left: 0; right: 0; bottom: 0;
  background: rgba(0,0,0,.5); color: #fff; font-style: normal; font-size: 12px; padding: 2px 0;
}
.crumb { font-size: 13px; color: #888; margin: 14px 0; }
.crumb a { color: #888; }

.detail-grid, .bid-layout, .split { display: grid; gap: 16px; align-items: start; }
.detail-grid { grid-template-columns: 1.15fr .85fr; }
.bid-layout { grid-template-columns: 1.15fr .85fr; }
.split { grid-template-columns: .9fr 1.1fr; }

.gallery-main {
  height: 360px; display: flex; align-items: center; justify-content: center;
  color: rgba(255,255,255,.95); font-size: 22px; letter-spacing: 1px;
  position: relative; overflow: hidden;
}
.gallery-main img { width: 100%; height: 100%; object-fit: contain; background: #f3f3f3; }
.thumbs { display: flex; gap: 8px; margin-top: 8px; flex-wrap: wrap; }
.thumb { width: 76px; height: 56px; border: 2px solid transparent; color: #fff; cursor: pointer; padding: 0; overflow: hidden; }
.thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.thumb.on { border-color: var(--red); }
.watch { color: #888; font-size: 13px; margin: 8px 0 0; }

.panel { padding: 16px 18px 20px; }
.status-row { display: flex; align-items: center; gap: 10px; color: #666; flex-wrap: wrap; }
.badge { display: inline-block; background: #8d8d8d; color: #fff; border-radius: 12px; padding: 2px 10px; font-size: 13px; }
.badge.live { background: var(--red); }
.badge.upcoming { background: #f5a623; }
.price-line { margin: 14px 0 4px; }
.price-line span { color: #666; margin-right: 8px; }
.price-num { color: var(--red); font-size: 36px; font-weight: 700; font-variant-numeric: tabular-nums; line-height: 1; }
.price-line small { margin-left: 4px; color: #666; }
.premium { margin: 4px 0 0; color: #666; }
.premium b { color: var(--red); font-weight: 600; }
.lead-no { margin: 6px 0 0; color: #444; }
.note { margin-top: 12px; background: #fff7f6; color: #a8071a; padding: 8px 10px; font-size: 13px; line-height: 1.6; }
.clock { margin-top: 12px; background: #fafafa; padding: 10px 12px; display: flex; justify-content: space-between; align-items: center; }
.clock b { font-size: 22px; font-variant-numeric: tabular-nums; color: var(--red); letter-spacing: 1px; }
.spec-grid { display: flex; flex-wrap: wrap; gap: 8px 18px; margin-top: 14px; font-size: 13px; }
.spec-grid div { color: #444; white-space: nowrap; }
.spec-grid label { color: #888; margin-right: 4px; }
.spec-grid .wide { grid-column: 1 / -1; }
.actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 16px; }
.gate { margin-top: 12px; color: #a8071a; }

.tabs { display: flex; background: #fff; border: 1px solid var(--line); border-bottom: 1px solid var(--red); margin-top: 18px; overflow-x: auto; }
.tabs a { padding: 12px 18px; white-space: nowrap; color: #333; }
.tabs a.on { color: var(--red); font-weight: 600; box-shadow: inset 0 -2px 0 var(--red); }
.tab-body { border: 1px solid var(--line); border-top: 0; padding: 18px 22px 28px; min-height: 200px; }
.prose { line-height: 1.8; color: #444; }
.prose ol { padding-left: 20px; }
.prose li { margin: 8px 0; }
.pre { white-space: pre-wrap; }

.steps { display: flex; list-style: none; padding: 0; margin: 16px 0; gap: 8px; }
.steps li { flex: 1; text-align: center; background: #fff; color: #999; border: 1px solid var(--line); font-size: 13px; padding: 8px 4px; }
.steps li.on { background: var(--red); color: #fff; border-color: var(--red); }

.brief { display: flex; gap: 12px; background: #fff; border: 1px solid var(--line); padding: 12px; margin-bottom: 16px; color: inherit; }
.brief:hover { color: inherit; border-color: var(--red); }
.brief .mini { width: 84px; height: 60px; flex: none; }
.brief p { margin: 4px 0 0; color: #888; font-size: 13px; }
.brief strong { font-size: 16px; }

.auth-wrap { max-width: 560px; margin: 24px auto 8px; }
.auth-card, .pay-card { padding: 28px 32px 32px; }
.auth-card h1, .pay-card h1, .page h1 { font-size: 22px; margin: 0 0 16px; }
.kind-switch { display: flex; margin-bottom: 18px; border-bottom: 1px solid var(--line); }
.kind-switch a { flex: 1; text-align: center; padding: 10px; color: #666; }
.kind-switch a.on { color: var(--red); font-weight: 600; box-shadow: inset 0 -2px 0 var(--red); }
.field { margin-bottom: 14px; }
.field label, .agree { display: block; margin-bottom: 6px; color: #333; }
.field input, .field select { width: 100%; height: 40px; border: 1px solid #ddd; padding: 0 12px; background: #fff; }
.field input:focus { border-color: var(--red); outline: none; }
.hint { color: #999; font-size: 12px; margin: -6px 0 12px; }
.form-error { background: #fff2f0; color: #c41912; padding: 8px 12px; margin-bottom: 12px; font-size: 13px; }
.demo-tip { background: #fafafa; border: 1px dashed #e5e5e5; padding: 12px; margin-top: 16px; font-size: 13px; color: #666; }
.demo-tip p { margin: 4px 0; }
.agree { display: flex; gap: 8px; align-items: flex-start; margin: 8px 0 16px; }
.agree input { margin-top: 3px; }
.kv { display: grid; grid-template-columns: 88px 1fr; gap: 8px 12px; margin: 0 0 16px; }
.kv dt { color: #888; }
.kv dd { margin: 0; }

.pay-opt { display: flex; gap: 10px; border: 1px solid var(--line); padding: 12px; margin-bottom: 10px; cursor: pointer; }
.pay-opt b { display: block; }
.pay-opt small { color: #888; }
.bank { background: #fafafa; padding: 12px; margin: 8px 0 16px; color: #444; }
.bank p { margin: 4px 0; }
.paid-box { background: #fff7f6; padding: 16px; margin-bottom: 16px; }
.paid-box b { color: var(--red); font-size: 28px; }

.stepper { display: flex; align-items: center; gap: 8px; margin: 12px 0; }
.stepper button { width: 40px; height: 40px; border: 1px solid #ddd; background: #fff; cursor: pointer; font-size: 18px; }
.stepper input { width: 180px; height: 40px; border: 1px solid #ddd; padding: 0 10px; font-size: 18px; }
.stepper span { color: #666; }

.bid-table { width: 100%; border-collapse: collapse; background: #fff; }
.bid-table th { background: #fafafa; font-weight: 500; color: #666; }
.bid-table td, .bid-table th { border-bottom: 1px solid var(--line); padding: 10px 12px; text-align: left; font-size: 13px; white-space: nowrap; }
.bid-table tr.mine { background: #fff7f6; }
.tag-lead { color: var(--red); font-weight: 600; }
.tag-out { color: #999; }
.tag-mine { margin-left: 6px; color: #d46b08; font-size: 12px; }
.table-wrap { overflow-x: auto; background: #fff; }
.empty { background: #fff; border: 1px dashed #ddd; color: #888; text-align: center; padding: 36px 16px; }
.links { display: flex; flex-wrap: wrap; gap: 12px; }
.links a { color: var(--red); }
.mine-head { background: #fff; border: 1px solid var(--line); padding: 16px 18px; margin: 16px 0; }
.mine-head p { margin: 4px 0; color: #666; }

.tone-1 { background: linear-gradient(160deg, #8ea184, #3d4a38); }
.tone-2 { background: linear-gradient(160deg, #d7a15a, #7a4a22); }
.tone-3 { background: linear-gradient(160deg, #d9d4c8, #8d877c); }
.tone-4 { background: linear-gradient(160deg, #5d6a72, #242c32); }
.tone-5 { background: linear-gradient(160deg, #8ea0b3, #3c4754); }
.tone-6 { background: linear-gradient(160deg, #7d8c90, #2e383c); }
.mini { position: relative; overflow: hidden; background: #ccc; }
.mini img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }

@media (max-width: 760px) {
  .topbar-inner, .subnav-inner { flex-wrap: wrap; align-items: center; }
  .mast-inner, .hero, .detail-grid, .bid-layout, .split, .foot-grid, .meet-head { display: block; }
  .brand { padding: 8px 0; }
  .brand-logo { height: 72px; }
  .cats { min-height: 44px; }
  .subnav nav { flex-wrap: wrap; }
  .subnav nav a { white-space: nowrap; padding: 10px 12px; }
  .search { width: 100%; margin: 0 0 10px; }
  .search input { flex: 1; width: auto; }
  .hero-side, .meet-lots { margin-top: 16px; }
  .lot-card { grid-template-columns: 1fr; }
  .lot-side { text-align: left; }
  .gallery-main { height: 220px; }
  .spec-grid div { white-space: normal; }
  .steps { flex-wrap: wrap; }
  .steps li { flex: 1 1 40%; }
  .auth-card, .pay-card { padding: 20px 16px; }
}
