/* V体育 · 折叠屏 · 亮色主题（体育 + 娱乐） */
:root {
  --primary: #f29100;
  --primary-light: #fff7e6;
  --primary-border: #ffd591;
  --bg: #f5f6f8;
  --surface: #fff;
  --surface2: #fafafa;
  --text: #1a1a1a;
  --text2: #666;
  --muted: #999;
  --border: #eee;
  --green: #52c41a;
  --red: #ff4d4f;
  --device-fold: 390px;
  --device-unfold: 900px;
  --radius: 8px;
  --shadow: 0 2px 8px rgba(0,0,0,0.06);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
body.demo {
  min-height: 100vh;
  background: linear-gradient(160deg, #e8eef5, #f0f4f8);
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", sans-serif;
  color: var(--text); font-size: 14px; line-height: 1.4;
  padding: 20px 16px 48px;
}
a { color: inherit; text-decoration: none; }

.demo-head { max-width: 940px; margin: 0 auto 14px; }
.demo-head h1 { font-size: 20px; margin-bottom: 4px; }
.demo-head .sub { font-size: 13px; color: #666; line-height: 1.6; }

.flow-bar { max-width: 940px; margin: 0 auto 10px; display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.flow-step { display: flex; align-items: center; gap: 5px; padding: 5px 11px; border-radius: 16px; font-size: 12px; background: #fff; color: #888; border: 1px solid #e0e0e0; }
.flow-step .num { width: 17px; height: 17px; border-radius: 50%; background: #eee; display: flex; align-items: center; justify-content: center; font-size: 10px; font-weight: 700; }
.flow-step.current { border-color: var(--primary); color: var(--primary); background: var(--primary-light); }
.flow-step.current .num { background: var(--primary); color: #fff; }
.flow-step.done { color: var(--green); border-color: #b7eb8f; background: #f6ffed; }
.flow-step.done .num { background: var(--green); color: #fff; }
.flow-arrow { color: #ccc; font-size: 11px; }

.demo-controls { max-width: 940px; margin: 0 auto 10px; display: flex; gap: 8px; flex-wrap: wrap; }
.demo-btn { padding: 7px 14px; border-radius: 6px; border: 1px solid #ddd; background: #fff; color: #333; font-size: 13px; cursor: pointer; font-family: inherit; }
.demo-btn:hover { border-color: var(--primary); color: var(--primary); }
.demo-btn.active { background: var(--primary); border-color: var(--primary); color: #fff; }

.demo-hint { max-width: 940px; margin: 0 auto 16px; padding: 10px 14px; background: #fff; border: 1px solid var(--primary-border); border-radius: var(--radius); font-size: 13px; color: #555; line-height: 1.65; box-shadow: var(--shadow); }
.demo-hint strong { color: var(--primary); }
.state-tag { max-width: 940px; margin: 0 auto 10px; font-size: 12px; color: #888; text-align: center; }

#foldDevice { max-width: var(--device-unfold); margin: 0 auto; transition: max-width 0.45s; }
#foldDevice.is-folded { max-width: var(--device-fold); }

.device-bezel { background: #2a2a2a; border-radius: 28px; padding: 10px; box-shadow: 0 16px 48px rgba(0,0,0,0.18); position: relative; }
.is-unfolded .device-bezel::after {
  content: ""; position: absolute; top: 12px; bottom: 12px; left: 50%; width: 2px; transform: translateX(-50%);
  background: linear-gradient(180deg, transparent, rgba(255,255,255,0.15) 30%, rgba(255,255,255,0.15) 70%, transparent); pointer-events: none;
}

.device-viewport { position: relative; min-height: 780px; border-radius: 20px; overflow: hidden; background: var(--bg); }

.screen { position: absolute; inset: 0; display: flex; flex-direction: column; background: var(--bg); transition: transform 0.36s cubic-bezier(0.4,0,0.2,1); overflow: hidden; }
.screen-home { z-index: 1; transform: translateX(0); }
.screen-detail { z-index: 2; transform: translateX(100%); }
.has-detail .screen-home { transform: translateX(-30%); pointer-events: none; opacity: 0.6; }
.has-detail .screen-detail { transform: translateX(0); }

.slip-mask { display: none; position: absolute; inset: 0; background: rgba(0,0,0,0.35); z-index: 30; }
.slip-panel {
  display: none; position: absolute; left: 0; right: 0; bottom: 0; z-index: 31;
  background: var(--surface); border-radius: 14px 14px 0 0;
  flex-direction: column; max-height: 78%;
  box-shadow: 0 -4px 24px rgba(0,0,0,0.12);
}
.has-slip .slip-mask { display: block; }
.has-slip .slip-panel { display: flex; }
.has-slip.has-keypad .slip-panel { max-height: 92%; }
.has-slip.is-slip-tall .slip-panel { max-height: 94%; } /* 进行中：接近全屏，对应 H5 跳顶 */

/* 展开内屏：注单仍底部抽屉，但主区改为「左侧注单信息 | 右侧键盘」 */
.is-unfolded.has-slip .slip-panel {
  left: 50%; right: auto; width: min(760px, 96%);
  transform: translateX(-50%);
  max-height: 72%;
}
.is-unfolded.has-slip.has-keypad .slip-panel,
.is-unfolded.has-slip.is-slip-tall .slip-panel { max-height: 82%; }
.is-unfolded.has-keypad .slip-view:not([hidden]) .slip-main {
  display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 0;
  min-height: 0; align-items: stretch;
}
.is-unfolded.has-keypad .slip-view:not([hidden]) .slip-body { border-right: 1px solid var(--border); }
.is-unfolded.has-keypad .slip-view:not([hidden]) .slip-keypad {
  border-top: none; display: flex !important; align-items: stretch;
}
.is-unfolded.has-keypad .kp-grid { flex: 1; }

.slip-view[hidden] { display: none !important; }
.slip-view { display: flex; flex-direction: column; flex: 1; min-height: 0; }

.pane-scroll { flex: 1; overflow-y: auto; overflow-x: hidden; padding-bottom: 110px; }
.pane-scroll::-webkit-scrollbar { width: 3px; }
.pane-scroll::-webkit-scrollbar-thumb { background: rgba(0,0,0,0.12); border-radius: 2px; }

/* 顶栏 */
.topbar { background: var(--surface); border-bottom: 1px solid var(--border); padding: 8px 12px 0; box-shadow: var(--shadow); }
.topbar-row { display: flex; align-items: center; gap: 8px; padding-bottom: 6px; font-size: 12px; }
.topbar-row .menu { font-size: 17px; }
.topbar-row .notice { flex: 1; color: var(--text2); overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font-size: 11px; }
.topbar-row .bal { font-weight: 700; color: var(--primary); white-space: nowrap; }

.main-nav { display: flex; justify-content: space-around; padding: 2px 0 8px; }
.main-nav-item { display: flex; flex-direction: column; align-items: center; gap: 2px; font-size: 10px; color: var(--muted); padding: 4px 6px; cursor: pointer; border: none; background: none; font-family: inherit; }
.main-nav-item.active { color: var(--primary); font-weight: 600; }
.main-nav-item .ico { font-size: 20px; }
.main-nav-item .ico-vsport {
  width: 28px; height: 28px; border-radius: 50%;
  background: linear-gradient(145deg, #f29100, #ffb347);
  color: #fff; font-size: 14px; font-weight: 800;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 2px 6px rgba(242,145,0,0.35);
}

/* 主视图切换 */
.home-view { display: none; }
.home-view.active { display: block; }

/* 首页 Banner：宽度 100% 等比展示整图（折叠/展开、安卓/iOS 一致，无黑边） */
.banner-carousel {
  margin: 8px 10px;
  border-radius: var(--radius);
  overflow: hidden;
  position: relative;
  background: #111;
  width: auto;
  height: auto;
  max-height: none;
  aspect-ratio: auto;
}
.is-unfolded .banner-carousel {
  max-height: none;
}
.banner-track {
  display: flex;
  width: 100%;
  transition: transform 0.4s ease;
  will-change: transform;
}
.banner-slide {
  flex: 0 0 100%;
  min-width: 100%;
  width: 100%;
  user-select: none;
  line-height: 0;
}
.banner-slide img {
  width: 100%;
  height: auto;
  display: block;
  object-fit: unset;
  pointer-events: none;
}
.banner-dots {
  position: absolute;
  left: 0; right: 0; bottom: 8px;
  display: flex; justify-content: center; align-items: center; gap: 5px;
  z-index: 2; pointer-events: none;
}
.banner-dot {
  pointer-events: auto;
  width: 5px; height: 5px; border-radius: 50%;
  border: none; padding: 0; cursor: pointer;
  background: rgba(255,255,255,0.55);
  box-shadow: 0 0 2px rgba(0,0,0,0.35);
  transition: width 0.2s, background 0.2s;
}
.banner-dot.active {
  width: 12px; border-radius: 999px;
  background: rgba(255,255,255,0.95);
}

.promo-banner { margin: 8px 10px; height: 96px; border-radius: var(--radius); display: flex; align-items: center; padding: 0 16px; position: relative; overflow: hidden; }
.promo-banner.wcup {
  background:
    linear-gradient(110deg, rgba(8,20,60,0.75) 0%, rgba(20,40,100,0.4) 45%, rgba(0,0,0,0.15) 100%),
    linear-gradient(135deg, #1a2a6c, #2a5298 40%, #7b2ff7 100%);
  border: none;
}
.promo-banner.wcup .txt { color: #fff; font-size: 18px; font-weight: 800; line-height: 1.35; z-index: 1; text-shadow: 0 2px 8px rgba(0,0,0,0.35); }
.promo-banner.wcup .txt small { display: block; font-weight: 600; font-size: 13px; margin-top: 4px; opacity: 0.95; }
.promo-banner .emoji { position: absolute; right: 14px; font-size: 52px; filter: drop-shadow(0 4px 10px rgba(0,0,0,0.35)); }

.promo-banner.venue { background: linear-gradient(135deg, #fff8e6, #ffe8cc); border: 1px solid #ffd591; min-height: 88px; height: auto; padding: 12px 14px; }
.promo-banner.venue .txt { color: #874d00; font-size: 12px; line-height: 1.6; max-width: 65%; z-index: 1; }
.promo-banner.venue .emoji { font-size: 48px; right: 10px; }

/* Tab */
.market-tabs, .ent-tabs { display: flex; background: var(--surface); border-bottom: 1px solid var(--border); overflow-x: auto; scrollbar-width: none; }
.market-tabs::-webkit-scrollbar, .ent-tabs::-webkit-scrollbar { display: none; }
.market-tab, .ent-tab {
  flex-shrink: 0; padding: 10px 14px; font-size: 13px; color: var(--text2);
  border-bottom: 2px solid transparent; cursor: pointer; white-space: nowrap;
  background: none; border-top: none; border-left: none; border-right: none; font-family: inherit;
}
.market-tab.active, .ent-tab.active { color: var(--primary); border-bottom-color: var(--primary); font-weight: 600; }
.market-tab .cnt { font-size: 11px; margin-left: 2px; }

.ent-tab { padding: 8px 14px; border-radius: 20px; border: 1px solid var(--border); margin: 8px 6px 8px 0; font-size: 12px; background: var(--surface2); border-bottom: 1px solid var(--border); }
.ent-tab:first-child { margin-left: 10px; }
.ent-tab.active { background: var(--primary); color: #fff; border-color: var(--primary); border-bottom-color: var(--primary); }

.ent-tabs-wrap { background: var(--surface); border-bottom: 1px solid var(--border); overflow-x: auto; display: flex; padding-bottom: 2px; }

.sport-chips { display: flex; gap: 4px; padding: 8px 6px; overflow-x: auto; background: var(--surface); border-bottom: 1px solid var(--border); scrollbar-width: none; }
.sport-chips::-webkit-scrollbar { display: none; }
.sport-chip {
  flex-shrink: 0; min-width: 56px; padding: 6px 8px; border-radius: 8px;
  font-size: 11px; background: transparent; color: var(--text2);
  border: none; cursor: pointer; display: flex; flex-direction: column; align-items: center; gap: 2px;
}
.sport-chip .sc-ico { font-size: 22px; line-height: 1; }
.sport-chip.active { color: var(--primary); font-weight: 700; }
.sport-chip.active .sc-ico { filter: drop-shadow(0 0 0 var(--primary)); }

.sub-bar { display: flex; align-items: center; padding: 6px 10px; background: var(--surface); border-bottom: 1px solid var(--border); font-size: 11px; color: var(--muted); gap: 8px; }
.sub-bar .sort {
  margin-left: 0; display: inline-flex; align-items: center; gap: 4px;
  color: var(--text2); white-space: nowrap;
}
.sub-bar .sort::after { content: "⇅"; font-size: 10px; color: var(--muted); }
.sub-bar .wc-chip {
  background: linear-gradient(90deg, #1a237e, #3949ab);
  color: #ffd54f; font-size: 10px; padding: 3px 8px; border-radius: 12px;
  font-weight: 600; white-space: nowrap;
}
.sub-bar .filter-ico { font-size: 14px; color: var(--text2); margin-left: auto; }
.sub-bar .collapse-all {
  border: none; background: none; color: var(--text2); font-size: 11px;
  cursor: pointer; font-family: inherit; padding: 0; flex-shrink: 0;
}

/* 联赛折叠 */
.league-list { padding: 8px 8px 16px; display: flex; flex-direction: column; gap: 8px; background: #f0f1f3; }
.league-block { background: var(--surface); border-radius: 8px; overflow: hidden; box-shadow: var(--shadow); }
.league-hd {
  width: 100%; display: flex; align-items: center; gap: 8px;
  padding: 12px 12px; background: var(--surface); border: none;
  font-family: inherit; font-size: 13px; font-weight: 600; color: var(--text);
  cursor: pointer; text-align: left;
}
.league-ico { font-size: 16px; flex-shrink: 0; }
.league-name { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.league-chev { color: var(--muted); font-size: 12px; transition: transform 0.2s; }
.league-block.open .league-chev { transform: rotate(180deg); }
.league-block:not(.open) .league-body { display: none; }
.league-body { border-top: 1px solid var(--border); }
.list-end { text-align: center; font-size: 12px; color: var(--muted); padding: 12px 0 4px; }

.match-row { background: var(--surface); border-bottom: 1px solid var(--border); padding: 8px 10px 10px; }
.match-row:last-child { border-bottom: none; }
.match-row.is-active { background: var(--primary-light); }
.match-top { display: grid; grid-template-columns: auto auto 1fr auto; align-items: center; gap: 6px; margin-bottom: 6px; }
.time-badge {
  background: #e8e8e8; color: #666; font-size: 11px; font-weight: 600;
  padding: 2px 8px 2px 6px; clip-path: polygon(0 0, 100% 0, 92% 100%, 0 100%);
}
.mkt-more { font-size: 11px; color: var(--muted); }
.odds-hd-row { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; min-width: 148px; justify-self: end; margin-right: 4px; }
.odds-hd-row span { text-align: center; font-size: 10px; color: var(--muted); }
.match-fav { color: #ddd; font-size: 14px; cursor: pointer; }
.match-fav.on { color: var(--primary); }

.match-main { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px; align-items: start; }
.match-teams { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.team-line { display: flex; align-items: center; gap: 5px; font-size: 12px; min-width: 0; }
.team-line .ball { font-size: 12px; opacity: 0.7; flex-shrink: 0; }
.team-link { color: var(--text); cursor: pointer; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; border-bottom: 1px dashed transparent; }
.team-link:hover { color: var(--primary); border-bottom-color: var(--primary); }
.match-score-inline {
  margin-left: auto; min-width: 16px; text-align: right;
  color: var(--primary); font-size: 15px; font-weight: 800;
}
.card-num {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 14px; height: 14px; background: #ffc107; color: #fff;
  border-radius: 2px; font-size: 10px; font-weight: 700;
}
.corner-row { font-size: 11px; color: #e74c3c; margin-top: 2px; }
.period-row { font-size: 10px; color: var(--muted); margin-top: 2px; line-height: 1.4; letter-spacing: 0.2px; }
.odd-btn.locked {
  justify-content: center; color: #bbb; cursor: default; opacity: 0.85;
}
.odd-btn.locked .line { color: #bbb; width: 100%; text-align: center; }
.league-list[hidden] { display: none !important; }

/* 盘口：两列（让球|大小）× 两行，单元格内盘口与赔率横向 */
.odds-area {
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-template-rows: auto auto;
  gap: 4px;
  min-width: 148px;
}
.odd-btn {
  display: flex; flex-direction: row; align-items: center; justify-content: space-between;
  gap: 4px; min-width: 70px;
  background: #f3f3f3; border: none; border-radius: 4px;
  padding: 8px 6px; cursor: pointer; font-family: inherit; line-height: 1.2;
}
.odd-btn:hover { background: var(--primary-light); }
.odd-btn.is-selected { background: var(--primary-light); outline: 2px solid var(--primary); outline-offset: -1px; }
.odd-btn .line { color: var(--text2); font-size: 11px; white-space: nowrap; }
.odd-btn .val { color: var(--text); font-weight: 700; font-size: 12px; white-space: nowrap; }
.odd-btn .val.up { color: var(--red); }
.odd-btn .val.down { color: var(--green); }
.match-dots { display: flex; justify-content: flex-end; gap: 3px; margin-top: 6px; }
.match-dots i { width: 10px; height: 3px; border-radius: 2px; background: #e0e0e0; display: block; }
.match-dots i.on { background: var(--primary); }

.is-unfolded .league-list:not(.is-empty) { display: grid; grid-template-columns: 1fr 1fr; align-content: start; }
.is-unfolded .league-list .list-end,
.is-unfolded .league-list .empty-state { grid-column: 1 / -1; }
.is-unfolded .league-list.is-empty {
  display: flex; flex-direction: column;
  min-height: 420px; padding: 0; background: #fff;
}

.date-chips { display: flex; gap: 6px; padding: 8px 10px; overflow-x: auto; background: var(--surface); border-bottom: 1px solid var(--border); scrollbar-width: none; }
.date-chips::-webkit-scrollbar { display: none; }
.date-chip { flex-shrink: 0; padding: 5px 10px; border-radius: 4px; font-size: 11px; background: var(--surface2); color: var(--text2); border: 1px solid var(--border); cursor: pointer; text-align: center; line-height: 1.3; }
.date-chip.active { background: var(--primary-light); color: var(--primary); border-color: var(--primary-border); font-weight: 600; }

.tab-panel, .ent-panel { display: none; }
.tab-panel.active, .ent-panel.active { display: block; }

/* 今日 / 早盘仍用旧结构，但盘口单元格统一横向 */
.match-list-grid .league-hd {
  display: flex; align-items: center; justify-content: space-between;
  padding: 8px 12px; background: var(--surface2); font-size: 12px; font-weight: 600;
  border-bottom: 1px solid var(--border); width: 100%; border: none; font-family: inherit; text-align: left;
}
.match-meta { display: flex; justify-content: space-between; font-size: 11px; color: var(--muted); margin-bottom: 6px; }
.match-meta .live { color: var(--green); font-weight: 600; }
.match-meta .more { color: var(--primary); }
.match-grid { display: grid; grid-template-columns: 1fr auto; gap: 8px; align-items: start; }
.odds-col-hd { font-size: 10px; color: var(--muted); text-align: center; }
.match-list-grid .odds-area { grid-template-columns: 1fr 1fr; }
.match-list-grid .odds-col-hd { display: block; }
.match-row-foot { display: flex; justify-content: flex-end; margin-top: 4px; }

.is-unfolded .match-list-grid { display: grid; grid-template-columns: 1fr 1fr; }
.is-unfolded .match-list-grid .league-hd { grid-column: 1 / -1; }
.is-unfolded .match-list-grid .match-row { border-right: 1px solid var(--border); }

.empty-state {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  width: 100%; flex: 1;
  padding: 48px 24px 64px; text-align: center;
  background: #fff; min-height: 320px;
}
.empty-illus {
  position: relative; width: 96px; height: 88px; margin-bottom: 18px; opacity: 0.55;
}
.empty-doc {
  position: absolute; left: 18px; top: 8px; width: 52px; height: 64px;
  border: 3px solid #c8c8c8; border-radius: 6px; background: #fafafa;
}
.empty-doc::before, .empty-doc::after {
  content: ""; position: absolute; left: 8px; right: 8px; height: 3px;
  background: #d8d8d8; border-radius: 2px;
}
.empty-doc::before { top: 14px; }
.empty-doc::after { top: 24px; width: 60%; right: auto; }
.empty-glass {
  position: absolute; right: 6px; bottom: 4px; width: 36px; height: 36px;
  border: 3px solid #bdbdbd; border-radius: 50%; background: rgba(255,255,255,0.6);
}
.empty-glass::after {
  content: ""; position: absolute; right: -8px; bottom: -6px;
  width: 14px; height: 3px; background: #bdbdbd; border-radius: 2px;
  transform: rotate(45deg); transform-origin: left center;
}
.empty-title { font-size: 15px; font-weight: 600; color: #8c8c8c; margin-bottom: 8px; }
.empty-desc { font-size: 12px; color: #b0b0b0; line-height: 1.7; max-width: 260px; margin: 0; }
.empty-actions { display: flex; gap: 10px; margin-top: 20px; flex-wrap: wrap; justify-content: center; }
.empty-btn {
  min-width: 108px; height: 34px; padding: 0 14px; border-radius: 17px;
  border: none; background: var(--primary); color: #fff;
  font-size: 13px; font-weight: 600; cursor: pointer; font-family: inherit;
}
.empty-btn.ghost {
  background: #fff; color: var(--primary); border: 1px solid var(--primary-border);
}
.league-list.is-empty { background: #fff; padding: 0; gap: 0; min-height: 300px; }

.champion-wrap { display: flex; background: var(--surface); min-height: 400px; }
.champion-list { flex: 1; overflow-y: auto; }
.champion-letter { padding: 6px 14px; background: var(--surface2); font-size: 13px; font-weight: 700; color: var(--primary); border-bottom: 1px solid var(--border); }
.champion-item { display: block; padding: 12px 14px; font-size: 13px; border-bottom: 1px solid var(--border); cursor: pointer; }
.champion-item:hover { background: var(--primary-light); color: var(--primary); }
.alpha-index { width: 22px; flex-shrink: 0; display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 8px 0; background: rgba(255,255,255,0.9); border-left: 1px solid var(--border); }
.alpha-index span { font-size: 9px; color: var(--primary); width: 16px; height: 16px; display: flex; align-items: center; justify-content: center; }

/* ── 娱乐首页 ── */
.ent-section { padding: 12px 10px 4px; }
.ent-section-hd { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; gap: 8px; }
.ent-section-title { display: flex; align-items: center; gap: 6px; font-size: 15px; font-weight: 700; color: var(--text); }
.ent-section-title::before { content: ""; width: 3px; height: 14px; background: var(--primary); border-radius: 2px; }
.ent-section-tag { font-size: 11px; color: var(--muted); background: var(--surface2); border: 1px solid var(--border); padding: 4px 10px; border-radius: 12px; white-space: nowrap; }

.ent-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; }
.is-unfolded .ent-grid { grid-template-columns: repeat(3, 1fr); }
.is-unfolded .ent-grid.cols-4 { grid-template-columns: repeat(4, 1fr); }

.ent-card {
  background: var(--surface); border-radius: 10px; overflow: hidden;
  border: 1px solid var(--border); box-shadow: var(--shadow);
  min-height: 100px; position: relative; cursor: pointer;
  transition: transform 0.15s, box-shadow 0.15s;
}
.ent-card:hover { transform: translateY(-2px); box-shadow: 0 4px 16px rgba(0,0,0,0.1); }
.ent-card.wide { grid-column: 1 / -1; min-height: 88px; }

.ent-card-label { position: absolute; top: 10px; left: 10px; font-size: 16px; font-weight: 800; color: var(--text); z-index: 2; letter-spacing: 0.5px; }
.ent-card-badge { position: absolute; top: 0; left: 0; background: #1890ff; color: #fff; font-size: 10px; padding: 2px 8px; border-radius: 0 0 6px 0; z-index: 3; font-weight: 600; }

.ent-card-bg {
  position: absolute; inset: 0;
  display: flex; align-items: flex-end; justify-content: flex-end;
  padding: 8px; font-size: 48px; opacity: 0.85;
}
.ent-card-bg.gradient-1 { background: linear-gradient(135deg, #fff5e6, #ffe0b2); }
.ent-card-bg.gradient-2 { background: linear-gradient(135deg, #e6f7ff, #bae7ff); }
.ent-card-bg.gradient-3 { background: linear-gradient(135deg, #f9f0ff, #efdbff); }
.ent-card-bg.gradient-4 { background: linear-gradient(135deg, #f6ffed, #d9f7be); }
.ent-card-bg.gradient-5 { background: linear-gradient(135deg, #fff1f0, #ffccc7); }
.ent-card-bg.gradient-6 { background: linear-gradient(135deg, #e6fffb, #b5f5ec); }

.ent-card-avatar { font-size: 56px; line-height: 1; filter: drop-shadow(0 2px 4px rgba(0,0,0,0.1)); }

/* 底部 */
.dl-bar {
  position: absolute; bottom: 52px; left: 8px; right: 8px;
  background: rgba(45,45,45,0.92); border-radius: 8px;
  display: flex; align-items: center; padding: 8px 12px; gap: 8px;
  font-size: 11px; color: #eee; z-index: 4;
}
.dl-bar .logo { color: #fff; font-weight: 800; letter-spacing: 0.5px; }
.dl-bar .btn { margin-left: auto; background: var(--primary); color: #fff; border: none; padding: 5px 12px; border-radius: 4px; font-size: 12px; cursor: pointer; }
.dl-bar .x { background: none; border: none; color: #aaa; font-size: 16px; cursor: pointer; }

.bottom-nav {
  position: absolute; bottom: 0; left: 0; right: 0;
  background: var(--surface); border-top: 1px solid var(--border);
  display: flex; justify-content: space-around; align-items: center;
  padding: 4px 0 6px; z-index: 4;
}
.bottom-nav a { display: flex; flex-direction: column; align-items: center; gap: 1px; font-size: 9px; color: var(--muted); padding: 2px 8px; position: relative; }
.bottom-nav a .ni { font-size: 20px; }
.bottom-nav a.on { color: var(--primary); }
.bottom-nav a.brand { padding: 0 10px; }
.bottom-nav .brand-mark {
  font-size: 11px; font-weight: 900; letter-spacing: -0.5px;
  color: #1a1a1a; line-height: 1.1; text-align: center;
}
.bottom-nav .dot {
  position: absolute; top: 2px; right: 10px;
  width: 6px; height: 6px; border-radius: 50%; background: var(--red);
}

/* 详情 */
.detail-body { flex: 1; display: flex; flex-direction: column; overflow: hidden; min-height: 0; }
.detail-header { background: linear-gradient(180deg, #fff, #f8f9fb); border-bottom: 1px solid var(--border); padding: 8px 12px 12px; flex-shrink: 0; }
.detail-header.is-bball {
  background:
    linear-gradient(180deg, rgba(20,24,40,0.88), rgba(20,24,40,0.92)),
    linear-gradient(135deg, #1a237e, #311b92);
  color: #fff; border-bottom: none;
}
.detail-header.is-bball .detail-nav .title,
.detail-header.is-bball .detail-nav .acts,
.detail-header.is-bball .detail-nav .back { color: #fff; }
.detail-nav { display: flex; align-items: center; gap: 8px; margin-bottom: 10px; }
.detail-nav .back { font-size: 20px; cursor: pointer; padding: 2px; }
.detail-nav .title { flex: 1; text-align: center; font-size: 13px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.detail-nav .acts { display: flex; gap: 12px; font-size: 17px; color: var(--text2); }
.scoreboard { text-align: center; }
.scoreboard .period-scores { font-size: 11px; color: rgba(255,255,255,0.75); letter-spacing: 0.5px; margin-bottom: 6px; }
.scoreboard .phase { font-size: 12px; color: var(--text2); margin-top: 4px; }
.detail-header.is-bball .phase { color: rgba(255,255,255,0.7); }
.scoreboard .clock { font-size: 13px; font-weight: 600; margin-top: 2px; opacity: 0.9; }
.scoreboard .sub { font-size: 11px; color: var(--muted); }
.scoreboard-main { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; margin: 4px 0; }
.scoreboard-main .team .flag { font-size: 28px; }
.scoreboard-main .team .name { font-size: 12px; margin-top: 4px; font-weight: 600; }
.scoreboard-main .big-score { font-size: 30px; font-weight: 800; letter-spacing: 2px; }
.score-mid { display: flex; flex-direction: column; align-items: center; }
.detail-media { display: flex; justify-content: center; gap: 18px; margin-top: 8px; font-size: 16px; opacity: 0.9; }

.detail-tabs { display: flex; background: #2a2a2a; overflow-x: auto; flex-shrink: 0; scrollbar-width: none; }
.detail-tab { flex-shrink: 0; padding: 10px 14px; font-size: 13px; color: #bbb; border-bottom: 2px solid transparent; cursor: pointer; }
.detail-tab.active { color: var(--primary); border-bottom-color: var(--primary); font-weight: 600; }

.detail-pane { display: none; flex: 1; min-height: 0; flex-direction: column; overflow: hidden; background: #f5f6f8; }
.detail-pane.active { display: flex; }
.detail-pane[hidden] { display: none !important; }

.market-filters {
  display: flex; gap: 6px; padding: 8px 10px; background: #fff;
  border-bottom: 1px solid var(--border); flex-shrink: 0; overflow-x: auto; scrollbar-width: none;
  align-items: center;
}
.market-filters::-webkit-scrollbar { display: none; }
.mf-collapse {
  width: 28px; height: 28px; border-radius: 50%; border: 1px solid var(--border);
  background: #f3f3f3; cursor: pointer; font-size: 12px; flex-shrink: 0; font-family: inherit;
}
.mf-btn {
  flex-shrink: 0; padding: 6px 12px; border-radius: 16px; font-size: 12px;
  border: none; cursor: pointer; background: #2a2a2a; color: #fff; font-family: inherit; white-space: nowrap;
}
.mf-btn.active { background: var(--primary); color: #1a1a1a; font-weight: 700; }

.markets-scroll { flex: 1; overflow-y: auto; padding: 8px 10px 16px; }
.mf-panel[hidden] { display: none !important; }
.markets-scroll .market-block[hidden] { display: none !important; }
.is-unfolded .markets-scroll.mf-panel.active {
  display: grid; grid-template-columns: 1fr 1fr; gap: 8px; align-content: start;
}
.is-unfolded .markets-scroll .market-block { margin-bottom: 0; }
.is-unfolded .markets-scroll .market-block[hidden] { display: none !important; }

.market-block {
  background: var(--surface); border-radius: var(--radius); margin-bottom: 8px;
  overflow: hidden; border: 1px solid var(--border); box-shadow: var(--shadow);
}
.market-title {
  width: 100%; display: flex; align-items: center; gap: 6px;
  padding: 10px 12px; font-size: 13px; font-weight: 600;
  border: none; background: #f2f3f5; cursor: pointer; font-family: inherit; text-align: left; color: var(--text);
}
.market-title .chev { color: var(--muted); transition: transform 0.2s; }
.market-block:not(.open) .market-title .chev { transform: rotate(-90deg); }
.market-title .pin { margin-left: auto; color: var(--muted); font-size: 12px; }
.market-block:not(.open) .market-body { display: none; }
.market-body { padding: 8px 10px 10px; background: #fff; }
.odds-col-labels {
  display: grid; grid-template-columns: 1fr 1fr; gap: 6px; margin-bottom: 6px;
  font-size: 11px; color: var(--primary); font-weight: 600;
}
.odds-col-labels span::before {
  content: ""; display: inline-block; width: 3px; height: 10px; background: var(--primary);
  border-radius: 1px; margin-right: 4px; vertical-align: -1px;
}
.market-odds { display: grid; gap: 6px; }
.market-odds.cols-2 { grid-template-columns: 1fr 1fr; }
.market-odds.digit-grid { grid-template-columns: 1fr 1fr; }
.detail-odd-btn {
  padding: 12px 8px; text-align: center; border: none; background: #f3f3f3;
  border-radius: 6px; cursor: pointer; font-family: inherit;
  display: flex; flex-direction: column; align-items: center; gap: 4px;
}
.detail-odd-btn:hover { background: var(--primary-light); }
.detail-odd-btn.is-selected { background: var(--primary-light); outline: 2px solid var(--primary); outline-offset: -2px; }
.detail-odd-btn .label,
.detail-odd-btn .line { display: block; font-size: 12px; color: var(--text2); }
.detail-odd-btn .val { display: block; font-size: 15px; font-weight: 700; color: var(--text); }
.detail-odd-btn .val.up { color: var(--red); }
.detail-odd-btn .val.down { color: var(--green); }

/* 聊天室（无键盘稿：底部入口条，不 focus 系统键盘） */
.chat-notice {
  flex-shrink: 0; background: #fff8e6; color: #d48806; font-size: 11px;
  padding: 8px 12px; border-bottom: 1px solid #ffe7ba;
}
.chat-body {
  flex: 1; min-height: 0; overflow-y: auto; padding: 16px 12px;
  background: #f0f1f3; display: flex; flex-direction: column; justify-content: flex-end;
}
.chat-bubble {
  align-self: stretch; background: #fff; border-radius: 10px; padding: 10px 12px;
  box-shadow: var(--shadow); max-width: 92%;
}
.chat-name { font-size: 12px; color: var(--primary); font-weight: 700; margin-bottom: 4px; }
.chat-text { font-size: 13px; color: var(--text2); line-height: 1.55; }
.chat-bar {
  flex-shrink: 0; background: #fff; border-top: 1px solid var(--border);
  padding: 8px 10px 10px; display: flex; flex-direction: column; gap: 8px;
}
.chat-input {
  height: 36px; border-radius: 18px; background: #f2f3f5; color: #999;
  display: flex; align-items: center; padding: 0 14px; font-size: 13px; cursor: default;
  user-select: none;
}
.chat-acts { display: flex; justify-content: space-around; gap: 4px; }
.chat-act {
  flex: 1; border: none; background: none; font-size: 10px; color: var(--text2);
  display: flex; flex-direction: column; align-items: center; gap: 2px;
  cursor: pointer; font-family: inherit; padding: 2px;
}
.chat-act span { font-size: 18px; line-height: 1.2; }

.tip-empty { min-height: 360px; background: #f5f6f8; }

/* —— 篮球赛况 —— */
.live-bball {
  flex: 1; min-height: 0; overflow-y: auto; background: #f5f6f8;
  display: flex; flex-direction: column;
}
.live-subnav {
  display: flex; align-items: center; gap: 8px;
  padding: 10px 12px; background: #1a1c1e; flex-shrink: 0;
}
.live-pill {
  border: none; border-radius: 999px; padding: 6px 14px;
  font-size: 13px; font-family: inherit; cursor: pointer;
  background: #2a2d30; color: #fff;
}
.live-pill.active { background: var(--primary); color: #fff; font-weight: 600; }
.live-report {
  margin-left: auto; border: none; background: transparent;
  color: #888; font-size: 14px; cursor: pointer; padding: 4px;
}
.live-subpane { display: none; flex-direction: column; min-height: 0; }
.live-subpane.active { display: flex; }

.q-score-wrap { background: #fff; padding: 4px 0 2px; }
.q-score-table {
  width: 100%; border-collapse: collapse; font-size: 12px;
  table-layout: fixed;
}
.q-score-table th,
.q-score-table td {
  padding: 8px 4px; text-align: center; color: #666;
  border-bottom: 1px solid #f0f0f2;
}
.q-score-table th { font-weight: 500; color: #999; font-size: 11px; }
.q-score-table td.team {
  text-align: left; padding-left: 12px; color: #222; font-weight: 600;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; width: 28%;
}
.q-score-table td.tot { font-weight: 700; color: #222; }
.q-col {
  border: none; background: transparent; color: inherit;
  font: inherit; cursor: pointer; padding: 2px 4px; border-radius: 4px;
}
.q-col.active { color: var(--primary); font-weight: 700; background: #fff4e8; }
.q-score-table td.is-active { color: var(--primary); font-weight: 700; }

.stat-compare { background: #fff; padding: 12px 12px 16px; margin-top: 1px; }
.stat-teams {
  display: flex; justify-content: space-between; align-items: center;
  margin-bottom: 12px; font-size: 13px; font-weight: 600;
}
.stat-team { display: flex; align-items: center; gap: 6px; min-width: 0; }
.stat-team .logo { font-size: 16px; }
.stat-team span:last-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 110px; }
.stat-pair {
  display: flex; justify-content: space-between; font-size: 11px; color: #888;
  margin-bottom: 8px;
}
.stat-pair-l, .stat-pair-r { display: flex; align-items: center; gap: 6px; }
.stat-pair strong { color: #222; font-size: 14px; font-weight: 700; }

.stat-bars { display: flex; flex-direction: column; gap: 10px; margin: 10px 0 14px; }
.stat-bar-row {
  display: grid; grid-template-columns: 28px 1fr auto 1fr 28px;
  align-items: center; gap: 6px; font-size: 12px;
}
.stat-bar-row .n { font-weight: 600; color: #222; text-align: center; }
.stat-bar-row .label {
  grid-column: 3; font-size: 11px; color: #666; text-align: center;
  white-space: nowrap; min-width: 64px;
}
.stat-bar-track {
  height: 6px; border-radius: 3px; background: #f0f1f3; overflow: hidden;
  position: relative;
}
.stat-bar-track.is-home { display: flex; justify-content: flex-end; }
.stat-bar-track.is-away { display: flex; justify-content: flex-start; }
.stat-bar-fill {
  height: 100%; border-radius: 3px; max-width: 100%;
}
.stat-bar-fill.home { background: var(--primary); }
.stat-bar-fill.away { background: #c8c9cc; }

.stat-rings {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px;
  padding-top: 4px;
}
.stat-ring {
  display: flex; flex-direction: column; align-items: center; gap: 4px;
}
.stat-ring-svg { width: 54px; height: 54px; }
.stat-ring-vals {
  display: flex; justify-content: space-between; width: 100%;
  font-size: 11px; font-weight: 600; color: #222; padding: 0 2px;
}
.stat-ring-label { font-size: 10px; color: #888; }

.q-tabs {
  display: grid; grid-template-columns: repeat(4, 1fr);
  background: #e9eaed; margin-top: 8px; flex-shrink: 0;
}
.q-tab {
  border: none; background: transparent; padding: 10px 4px;
  font-size: 13px; font-family: inherit; color: #666; cursor: pointer;
  position: relative;
}
.q-tab.active {
  background: #fff; color: #222; font-weight: 600;
}
.q-tab.active::after {
  content: ''; position: absolute; left: 50%; bottom: -1px;
  transform: translateX(-50%);
  border: 6px solid transparent; border-top-color: #fff;
  /* peek into feed; use top of tab instead as notch into grey above? screenshots show white tab with triangle pointing down into content */
  display: none;
}
.q-feed {
  background: #fff; flex: 1; min-height: 200px;
}
.q-feed-empty { min-height: 220px; }

/* 分析 */
.ana-block { background: #fff; margin-bottom: 8px; padding: 12px 0 4px; }
.ana-hd {
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 12px 8px;
}
.ana-title { font-size: 15px; font-weight: 700; }
.ana-rec { font-size: 12px; color: #999; }
.ana-team-bar {
  display: flex; align-items: center; gap: 8px;
  padding: 8px 12px; background: #f5f6f8; font-size: 13px; font-weight: 600;
}
.ana-team-bar .ana-rec { margin-left: auto; font-weight: 400; }
.ana-team-bar .logo { font-size: 16px; }
.ana-table {
  width: 100%; border-collapse: collapse; font-size: 11px;
}
.ana-table th {
  color: #999; font-weight: 500; padding: 8px 4px; text-align: center;
  border-bottom: 1px solid #f0f0f2;
}
.ana-table th:first-child, .ana-table td:first-child { text-align: left; padding-left: 12px; width: 28%; }
.ana-table td {
  padding: 10px 4px; text-align: center; border-bottom: 1px solid #f5f5f7; color: #222;
  vertical-align: middle;
}
.ana-league { font-size: 11px; color: #333; }
.ana-date { font-size: 10px; color: #999; margin-top: 2px; }
.hl-win { color: #e53935 !important; font-weight: 600; }
.hl-loss { color: #1faa5a !important; font-weight: 600; }
.res-win { color: #e53935; font-weight: 700; }
.res-loss { color: #1faa5a; font-weight: 700; }

.is-unfolded .stat-rings { max-width: 520px; margin: 0 auto; }
.is-unfolded .q-score-wrap,
.is-unfolded .stat-compare { max-width: 720px; margin-left: auto; margin-right: auto; width: 100%; }

/* 更多赛事：折叠单列；展开双列、左对齐 */
.more-list {
  flex: 1; min-height: 0; overflow-y: auto; background: #fff;
  display: flex; flex-direction: column;
}
.is-unfolded .more-list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-content: start;
  justify-items: stretch;
  max-width: none; margin: 0; width: 100%;
}
.more-row {
  width: 100%; display: flex; flex-direction: column; gap: 8px;
  text-align: left; border: none; border-bottom: 1px solid #ececef;
  background: #fff; padding: 12px 12px 14px; cursor: pointer;
  font-family: inherit; color: inherit; box-sizing: border-box;
  min-width: 0;
}
.is-unfolded .more-row {
  border-right: 1px solid #ececef;
}
.is-unfolded .more-row:nth-child(2n) {
  border-right: none;
}
.more-row:hover { background: #fafafa; }
.more-row.is-current { background: #fff8f0; }
.more-top {
  display: flex; align-items: center; gap: 5px; font-size: 11px; line-height: 1.2;
  min-width: 0; justify-content: flex-start;
}
.more-time { color: var(--text); font-weight: 500; flex-shrink: 0; }
.more-st { color: #999; flex-shrink: 0; }
.more-st.live { color: #22a06b; font-weight: 600; }
.more-league {
  flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  color: var(--primary); font-weight: 500; text-align: left;
}
.more-acts {
  display: inline-flex; align-items: center; gap: 6px;
  color: #c0c0c4; flex-shrink: 0; margin-left: auto;
}
.more-acts .ico {
  width: 14px; height: 14px; display: inline-flex; align-items: center; justify-content: center;
  font-size: 11px; line-height: 1;
}
.more-acts .ico.live { color: var(--primary); }
.more-acts .ico.chev { font-size: 13px; color: #d0d0d4; }
.more-acts.muted .ico { color: #d8d8dc; }
/* 队名行：左对齐，不居中推开 */
.more-teams {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 6px;
  font-size: 13px; font-weight: 600; line-height: 1.25;
  min-width: 0;
}
.more-side {
  display: inline-flex; align-items: center; gap: 4px; min-width: 0;
  max-width: calc(50% - 16px);
}
.more-side.is-home,
.more-side.is-away { justify-content: flex-start; }
.more-name {
  min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  text-align: left;
}
.more-side.is-home .more-name,
.more-side.is-away .more-name { text-align: left; }
.more-logo {
  width: 16px; height: 16px; border-radius: 50%; flex-shrink: 0;
  background: #f0f1f3; display: inline-flex; align-items: center; justify-content: center;
  font-size: 10px; line-height: 1;
}
.more-vs {
  color: #666; font-weight: 500; font-size: 12px; flex-shrink: 0;
}

/* 注单 */
.slip-hd { display: flex; align-items: center; gap: 8px; padding: 12px 14px; border-bottom: 1px solid var(--border); flex-shrink: 0; }
.slip-badge { width: 20px; height: 20px; border-radius: 50%; background: var(--primary); color: #fff; font-size: 11px; font-weight: 700; display: flex; align-items: center; justify-content: center; }
.slip-hd .title { font-size: 15px; font-weight: 600; }
.slip-hd .bal { margin-left: auto; font-size: 11px; color: var(--muted); }
.slip-hd .bal strong { color: var(--text); }
.slip-close { background: none; border: none; font-size: 16px; color: #999; cursor: pointer; padding: 0 2px; }
.slip-tabs { display: flex; border-bottom: 1px solid var(--border); padding: 0 14px; flex-shrink: 0; }
.slip-tab { padding: 8px 14px; font-size: 13px; color: var(--muted); border: none; background: none; border-bottom: 2px solid transparent; cursor: pointer; font-family: inherit; }
.slip-tab.active { color: var(--primary); border-bottom-color: var(--primary); font-weight: 600; }

.slip-main { flex: 1; min-height: 0; display: flex; flex-direction: column; overflow: hidden; }
.slip-body { padding: 10px 14px; overflow-y: auto; flex: 1; min-height: 0; }
.slip-card { border: 1px solid var(--border); border-radius: var(--radius); padding: 12px; background: #fff; }
.slip-card-main { display: flex; gap: 10px; align-items: flex-start; }
.slip-card-left { flex: 1; min-width: 0; }
.slip-card-right {
  flex-shrink: 0; width: 88px; text-align: right;
  border-left: 1px dashed #e5e5e5; padding-left: 10px;
}
.slip-pick { font-size: 16px; font-weight: 800; line-height: 1.3; }
.slip-line { color: var(--text); }
.slip-market { font-size: 12px; color: var(--primary); margin: 4px 0 6px; font-weight: 600; }
.slip-match-info { font-size: 11px; color: var(--muted); line-height: 1.55; }
.slip-card-acts { display: flex; justify-content: flex-end; gap: 8px; color: #bbb; font-size: 12px; margin-bottom: 4px; }
.slip-del { background: none; border: none; cursor: pointer; font-size: 14px; padding: 0; }
.slip-odds-type { font-size: 11px; color: var(--muted); }
.slip-odds-big { font-size: 22px; font-weight: 800; margin: 2px 0; }
.slip-win { font-size: 11px; color: var(--muted); }

.slip-stake-row { display: flex; gap: 8px; margin-top: 12px; align-items: center; }
.slip-input {
  flex: 1; display: flex; align-items: center; gap: 6px;
  border: 1px solid var(--border); border-radius: var(--radius);
  padding: 10px 12px; background: var(--surface); cursor: text;
}
.slip-input.is-focus { border-color: var(--primary); box-shadow: 0 0 0 2px rgba(242,145,0,0.15); }
.slip-input .yen { color: var(--primary); font-weight: 800; }
.slip-input input {
  flex: 1; border: none; outline: none; font-size: 14px; font-family: inherit;
  background: transparent; color: var(--text); width: 100%;
  caret-color: var(--primary);
}
.slip-reserve {
  flex-shrink: 0; height: 40px; padding: 0 12px; border-radius: 6px;
  border: 1px solid var(--primary-border); background: var(--primary-light);
  color: var(--primary); font-size: 13px; font-weight: 600;
  cursor: pointer; font-family: inherit; white-space: nowrap;
}

/* 自研键盘：折叠时在注单下方铺开；展开时见上方分栏规则 */
.slip-keypad {
  flex-shrink: 0; border-top: 1px solid var(--border);
  background: #f2f3f5; padding: 8px;
}
.slip-keypad[hidden] { display: none !important; }
.kp-grid {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px;
}
.kp-grid button {
  height: 44px; border: none; border-radius: 6px;
  background: #fff; color: var(--text); font-size: 18px; font-weight: 600;
  cursor: pointer; font-family: inherit; box-shadow: 0 1px 0 rgba(0,0,0,0.04);
}
.kp-grid button:active { background: #eee; }
.kp-grid .kp-dark {
  background: #4a5568; color: #fff; font-size: 13px; font-weight: 700;
}

.slip-summary { padding: 6px 14px; font-size: 11px; color: var(--muted); border-top: 1px solid var(--border); flex-shrink: 0; }
.slip-submit { padding: 8px 14px 14px; flex-shrink: 0; }
.slip-submit button {
  width: 100%; height: 44px; background: var(--primary); color: #fff;
  border: none; border-radius: var(--radius); font-size: 15px; font-weight: 600;
  cursor: pointer; font-family: inherit;
}
.slip-submit button.is-accept { background: #ffb84d; }

/* 预约字段 */
.reserve-fields {
  display: flex; align-items: center; gap: 8px; margin-top: 12px;
}
.reserve-fields .reserve-amt { flex: 1; margin: 0; }
.reserve-fields .at-mark { color: var(--muted); font-weight: 700; flex-shrink: 0; }
.odds-stepper {
  display: flex; align-items: center; gap: 0;
  border: 1px solid var(--border); border-radius: 6px;
  overflow: hidden; flex-shrink: 0; background: #fff; height: 40px;
}
.odds-stepper button {
  width: 34px; height: 40px; border: none; background: #f7f7f7;
  font-size: 18px; color: var(--text2); cursor: pointer; font-family: inherit;
}
.odds-stepper .odds-val {
  min-width: 48px; text-align: center; font-size: 14px; font-weight: 700;
  border-left: 1px solid var(--border); border-right: 1px solid var(--border);
  padding: 0 6px;
}
.reserve-actions {
  display: grid; grid-template-columns: 1fr 1fr; gap: 10px;
  padding: 10px 14px 14px; flex-shrink: 0; border-top: 1px solid var(--border);
}
.reserve-actions .btn-outline {
  height: 44px; border-radius: 6px; border: 1px solid var(--primary);
  background: #fff; color: var(--primary); font-size: 15px; font-weight: 600;
  cursor: pointer; font-family: inherit;
}
.reserve-actions .btn-primary {
  height: 44px; border-radius: 6px; border: none;
  background: #ffb84d; color: #fff; font-size: 15px; font-weight: 600;
  cursor: pointer; font-family: inherit;
}

/* 进行中 */
.ongoing-toolbar {
  display: flex; justify-content: flex-end; padding: 8px 14px 0; flex-shrink: 0;
}
.ongoing-toolbar .link-more {
  border: none; background: none; color: var(--muted); font-size: 12px;
  cursor: pointer; font-family: inherit;
}
.ongoing-body {
  flex: 1; min-height: 0; overflow-y: auto;
  display: flex; align-items: center; justify-content: center; padding: 24px 16px;
}
.ongoing-empty { text-align: center; color: var(--muted); }
.ongoing-empty-ico { font-size: 48px; opacity: 0.35; margin-bottom: 12px; }
.ongoing-empty-title { font-size: 16px; font-weight: 700; color: #999; margin-bottom: 6px; }
.ongoing-empty-sub { font-size: 12px; color: #bbb; }

/* 注单成功页 */
.bet-success {
  display: none; position: absolute; inset: 0; z-index: 40;
  background: rgba(0,0,0,0.45);
  align-items: flex-end; justify-content: center;
}
.has-success .bet-success { display: flex; }
.has-success .slip-panel { display: none !important; }
.has-success .slip-mask { display: none !important; }
.bet-success-panel {
  width: 100%; background: #f5f6f8; border-radius: 14px 14px 0 0;
  padding: 14px 14px 16px; max-height: 92%; overflow-y: auto;
  box-shadow: 0 -4px 24px rgba(0,0,0,0.15);
}
.is-unfolded.has-success .bet-success { align-items: center; }
.is-unfolded.has-success .bet-success-panel {
  width: min(420px, 92%); border-radius: 12px; max-height: 86%;
}

.bet-success-hd { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.ok-title { display: flex; align-items: center; gap: 8px; color: #52c41a; font-size: 16px; font-weight: 700; }
.ok-ico {
  width: 22px; height: 22px; border-radius: 50%; background: #52c41a; color: #fff;
  display: inline-flex; align-items: center; justify-content: center; font-size: 13px;
}
.success-x {
  width: 28px; height: 28px; border-radius: 50%; border: 1px solid #ddd;
  background: #fff; color: #999; font-size: 18px; cursor: pointer; line-height: 1;
}

.ticket-card {
  background: #fff; border-radius: 10px; padding: 12px 14px 14px;
  box-shadow: var(--shadow); position: relative;
}
.ticket-hd {
  display: flex; justify-content: space-between; align-items: center;
  padding-bottom: 10px; margin-bottom: 10px;
  border-bottom: 1px dashed #e5e5e5;
}
.ticket-ok { color: #52c41a; font-size: 13px; font-weight: 600; display: flex; align-items: center; gap: 4px; }
.mini-ok {
  width: 14px; height: 14px; border-radius: 50%; background: #52c41a; color: #fff;
  font-size: 10px; display: inline-flex; align-items: center; justify-content: center;
}
.ticket-bar { color: #333; letter-spacing: -2px; font-size: 12px; }
.ticket-body { display: flex; gap: 10px; }
.ticket-left { flex: 1; min-width: 0; }
.ticket-right {
  flex-shrink: 0; width: 96px; text-align: right;
  border-left: 1px dashed #e5e5e5; padding-left: 10px;
  display: flex; flex-direction: column; justify-content: space-between;
}
.t-match { font-size: 12px; color: var(--text2); margin-bottom: 4px; }
.t-pick { font-size: 15px; font-weight: 800; margin-bottom: 4px; }
.t-market { font-size: 11px; color: var(--muted); margin-bottom: 2px; }
.t-league { font-size: 11px; color: var(--muted); margin-bottom: 8px; }
.t-max { font-size: 12px; color: var(--muted); }
.t-max em { color: var(--primary); font-style: normal; font-weight: 700; }
.t-odds { font-size: 22px; font-weight: 800; }
.t-amt { font-size: 11px; color: var(--muted); margin-top: 8px; }

.ticket-sum {
  margin-top: 10px; background: #fff; border-radius: 10px; padding: 10px 14px;
}
.sum-row {
  display: flex; justify-content: space-between; font-size: 13px;
  color: var(--text2); padding: 4px 0;
}
.sum-row strong { color: var(--primary); font-weight: 700; }

.ticket-actions {
  display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 14px;
}
.btn-keep {
  height: 44px; border: none; border-radius: 6px; background: #4a5568;
  color: #fff; font-size: 15px; font-weight: 600; cursor: pointer; font-family: inherit;
}
.btn-ok {
  height: 44px; border: none; border-radius: 6px; background: var(--primary);
  color: #1a1a1a; font-size: 15px; font-weight: 700; cursor: pointer; font-family: inherit;
}

.click-hint { max-width: 940px; margin: 14px auto 0; text-align: center; font-size: 12px; color: #888; }
.click-hint mark { background: var(--primary-light); color: var(--primary); padding: 1px 6px; border-radius: 3px; }

/* —— 登录活动弹窗 —— */
.act-popup {
  position: absolute; inset: 0; z-index: 80;
  display: flex; align-items: center; justify-content: center;
  background: rgba(0,0,0,0.55);
  padding: 16px 18px;
  box-sizing: border-box;
}
.act-popup[hidden] { display: none !important; }
.act-popup-panel {
  width: min(100%, 340px);
  background: #2a2c30;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 12px 40px rgba(0,0,0,0.45);
}
.is-unfolded .act-popup-panel { width: min(100%, 380px); }
.act-popup-hd {
  display: flex; align-items: stretch; background: #1f2124;
  min-height: 40px;
}
.act-tabs {
  flex: 1; min-width: 0;
  display: grid; grid-template-columns: repeat(3, 1fr);
}
.act-tab {
  border: none; background: #2c2e32; color: #aaa;
  font-size: 12px; font-family: inherit; cursor: pointer;
  padding: 10px 4px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.act-tab.active {
  background: var(--primary); color: #1a1a1a; font-weight: 700;
}
.act-close {
  width: 40px; flex-shrink: 0;
  border: none; background: transparent; color: #ddd;
  font-size: 22px; line-height: 1; cursor: pointer;
}
.act-poster {
  display: block; width: 100%; padding: 0; border: none;
  background: #111; cursor: pointer; line-height: 0;
}
.act-poster img {
  width: 100%; height: auto; display: block;
}
.act-popup-ft {
  display: flex; align-items: center; justify-content: space-between;
  padding: 10px 12px; background: #2a2c30;
}
.act-mute {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 12px; color: #ccc; cursor: pointer; user-select: none;
}
.act-mute input { width: 14px; height: 14px; accent-color: var(--primary); }
.act-dots { display: flex; gap: 5px; align-items: center; }
.act-dot {
  width: 6px; height: 6px; border-radius: 50%; border: none; padding: 0;
  background: #666; cursor: pointer;
}
.act-dot.active { background: var(--primary); width: 8px; height: 8px; }

/* 活动详情占位 */
/* —— 优惠活动列表 —— */
.act-list {
  position: absolute; inset: 0; z-index: 88;
  background: #f0f1f3; display: flex; flex-direction: column;
  pointer-events: auto;
}
.act-list[hidden] { display: none !important; }

/* 顶栏：左右按钮，标题绝对居中 */
.act-list-bar,
.act-detail-bar {
  display: flex; align-items: center;
  justify-content: space-between;
  padding: 0 6px;
  min-height: 48px;
  background: #1a1c1e; color: #fff; flex-shrink: 0;
  position: relative; z-index: 2;
}
.act-list-bar .act-detail-title,
.act-detail-bar .act-detail-title {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  margin: 0;
  max-width: 58%;
  text-align: center;
  font-size: 16px;
  font-weight: 600;
  pointer-events: none;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.act-list-cs {
  margin-left: 0; border: none; background: none; color: #fff;
  font-size: 18px; cursor: pointer; padding: 10px 12px;
  min-width: 44px; min-height: 44px;
  display: inline-flex; align-items: center; justify-content: center;
}
.act-detail-back {
  border: none; background: none; color: #fff; font-size: 28px;
  line-height: 1; cursor: pointer; padding: 8px 12px;
  min-width: 44px; min-height: 44px;
  display: inline-flex; align-items: center; justify-content: center;
  position: relative; z-index: 3;
}

/* 列表：刚性统一卡片，满宽、等高、左右对齐 */
.act-list-body {
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 0;
  margin: 0;
  background: #e8e9eb;
  -webkit-overflow-scrolling: touch;
  display: block;
}
.act-card {
  display: block;
  width: 100% !important;
  max-width: 100% !important;
  box-sizing: border-box;
  padding: 0 !important;
  border: none !important;
  margin: 0 0 8px !important;
  background: #111;
  cursor: pointer;
  border-radius: 0;
  line-height: 0;
  position: relative;
  aspect-ratio: 750 / 300;
  height: auto;
  overflow: hidden;
  -webkit-appearance: none;
  appearance: none;
}
.act-card:last-child { margin-bottom: 0 !important; }
.act-card-media {
  display: block;
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
}
.act-card img {
  position: absolute;
  inset: 0;
  width: 100% !important;
  height: 100% !important;
  max-width: none !important;
  object-fit: cover !important;
  object-position: center center !important;
  display: block;
  border: none;
  border-radius: 0;
}
.is-unfolded .act-list-body {
  display: block;
  max-width: none;
  margin: 0;
  padding: 0;
}
.is-unfolded .act-card {
  margin: 0 0 8px;
  width: 100%;
}

.act-detail {
  position: absolute; inset: 0; z-index: 90;
  background: #07051a; display: flex; flex-direction: column;
  pointer-events: auto;
}
.act-detail[hidden] { display: none !important; }
.act-detail-body {
  flex: 1; overflow-y: auto; overflow-x: hidden;
  -webkit-overflow-scrolling: touch;
  background: #07051a;
}
.act-detail-scroll {
  width: 100%;
  max-width: 100%;
  margin: 0;
  padding: 0;
  background: #07051a;
  line-height: 0;
}
.act-detail-scroll img {
  width: 100% !important;
  max-width: 100% !important;
  height: auto !important;
  display: block !important;
  margin: 0 !important;
  padding: 0 !important;
  border: none !important;
  vertical-align: top;
  object-fit: fill;
}
.act-poster img {
  width: 100%; height: auto; display: block;
  object-fit: cover;
  object-position: center top;
}
