/* 补充样式：按原站实测计算值还原（1280 视口取样） */

html, body { height: 100%; }
#main.main {
  display: flex; flex-direction: column; height: 100%;
  background: #f2f2f2; overflow: hidden;
}

/* ---------- header ---------- */
#header_show.header {
  height: 56px; flex: none; background: #fff;
  border-bottom: 1px solid #e5e5e5; position: relative; z-index: 20;
}
#header_show .box_header { display: flex; align-items: center; height: 100%; padding: 0 8px; }
#header_show .btn_home { width: 36px; height: 36px; flex: none; display: flex; align-items: center; justify-content: center; }
#header_show .btn_home svg { width: 22px; height: 22px; fill: #19805c; }
#header_show #div_showtype { flex: 1; overflow: hidden; height: 100%; }
#header_show #showtype_scroll { height: 100%; overflow-x: auto; }
#header_show #showtype_scroll::-webkit-scrollbar { display: none; }
#header_show #showtype_total { display: flex; height: 100%; align-items: center; white-space: nowrap; }
#header_show .btn_header {
  padding: 0 12px; height: 34px; line-height: 34px; font-size: 14px;
  color: rgba(0,0,0,.64); border-radius: 4px; display: flex; align-items: center; gap: 3px;
}
#header_show .btn_header.on { color: #19805c; font-weight: 700; background: rgba(25,128,92,.08); }
#header_show .btn_hot i svg { width: 12px; height: 12px; fill: #e54545; }
#header_show .nav_header { display: flex; align-items: center; gap: 6px; flex: none; }
#header_show .btn_myGame .icon_star svg { width: 12px; height: 12px; fill: #ffb400; }
#header_show .num_betslip {
  display: inline-block; min-width: 16px; height: 16px; line-height: 16px; margin-left: 4px;
  padding: 0 4px; border-radius: 8px; background: #e54545; color: #fff; font-size: 11px; text-align: center;
}
#header_show .text_money { display: flex; align-items: baseline; gap: 4px; }
#header_show .text_currency { font-size: 11px; color: rgba(0,0,0,.48); }
#header_show .text_credit { font-size: 15px; font-weight: 700; color: #19805c; }
#header_show .btn_acc { position: relative; width: 34px; height: 34px; display: flex; align-items: center; justify-content: center; }
#header_show .btn_acc i svg { width: 20px; height: 20px; fill: rgba(0,0,0,.56); }
#header_show .dot_red.on {
  position: absolute; top: 6px; right: 6px; width: 7px; height: 7px;
  border-radius: 50%; background: #e54545;
}

/* ---------- 体育栏 ---------- */
#sport_content { flex: 1; display: flex; flex-direction: column; overflow: hidden; }
#sport_menu.sport_scroll {
  flex: none; height: 48px; background: #fff; border-bottom: 1px solid #e5e5e5;
  overflow-x: auto; overflow-y: hidden;
}
#sport_menu::-webkit-scrollbar { display: none; }
#sport_scroll.menu_sport { display: flex; height: 100%; align-items: center; padding: 0 4px; }
#sport_scroll label { display: flex; height: 100%; }
.btn_le_sport {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  min-width: 56px; height: 100%; padding: 0 8px; gap: 2px;
  font-size: 11px; color: rgba(0,0,0,.56);
}
.btn_le_sport i { width: 18px; height: 18px; display: block; }
.btn_le_sport i svg { width: 18px; height: 18px; fill: rgba(0,0,0,.56); }
.btn_le_sport.on { color: #19805c; font-weight: 700; position: relative; }
.btn_le_sport.on i svg { fill: #19805c; }
.btn_le_sport.on:after {
  content: ''; position: absolute; bottom: 0; left: 20%; width: 60%; height: 2px; background: #19805c;
}

/* ---------- 玩法 tab ---------- */
#tab_menu.tab_scroll {
  flex: none; height: 40px; background: #fff; border-bottom: 1px solid #e5e5e5;
  overflow-x: auto; overflow-y: hidden;
}
#tab_menu::-webkit-scrollbar { display: none; }
#tab_scroll.dragscroll_tab { display: flex; height: 100%; align-items: center; padding: 0 8px; }
#tab_total { display: flex; height: 100%; align-items: center; }
.btn_filter {
  padding: 0 12px; height: 28px; line-height: 28px; margin-right: 6px;
  font-size: 13px; color: rgba(0,0,0,.56); white-space: nowrap;
  border: 1px solid #e0e0e0; border-radius: 14px; background: #fff;
}
.btn_filter.on { color: #19805c; border-color: #19805c; background: rgba(25,128,92,.06); font-weight: 700; }

/* ---------- 赛事区 ---------- */
#main_content.content_sport { flex: 1; overflow-y: auto; padding: 8px; }
.btn_title_le {
  display: flex; align-items: center; justify-content: space-between;
  height: 40px; padding: 4px 8px; background: #fff;
  font-size: 14px; font-weight: 700; color: #000; border-radius: 4px 4px 0 0;
}
.btn_title_le .icon_flag {
  width: 16px; height: 12px; display: block; flex: none;
  background-repeat: no-repeat; background-size: contain; background-position: center;
  border: 1px solid rgba(0,0,0,.06); border-radius: 1px;
}

.box_lebet { display: block; margin-bottom: 4px; background: #fff; overflow: hidden; }
.box_lebet_top {
  display: flex; align-items: flex-start; background: #fff; min-height: 148px;
  border-bottom: 1px solid #f0f0f0;
}
.box_lebet_l {
  display: grid; grid-template-columns: 40px 1fr; grid-template-rows: 40px 100px;
  padding: 0 8px; width: 238px; flex: none; height: 140px;
}
.box_lebet_r {
  display: grid; grid-auto-flow: column; grid-auto-columns: 68px;
  grid-template-rows: 140px; gap: 4px; padding: 0 0 8px; height: 148px;
  flex: 1; overflow: hidden; justify-content: flex-start;
}
.box_lebet_odd { display: flex; flex-direction: column; gap: 4px; height: 140px; min-width: 0; }
.head_lebet {
  flex: none; display: flex; align-items: center; justify-content: center;
  height: 36px; padding: 4px 0 0; font-size: 12px; color: rgba(0,0,0,.56);
  line-height: 14px; white-space: nowrap; overflow: hidden;
}
.head_lebet span, .head_lebet tt { display: block; }
.btn_lebet_odd {
  flex: 1 1 auto; display: flex; flex-direction: column;
  align-items: center; justify-content: center; min-height: 0; padding: 2px;
  background: #fff; border: 1px solid #ebebeb; border-radius: 3px;
  overflow: hidden; cursor: pointer; transition: background .12s ease, border-color .12s ease;
}
.btn_lebet_odd > span:first-child { display: flex; align-items: center; justify-content: center; gap: 2px; }
.text_ballou, .text_ballhead { font-size: 13px; color: #000; line-height: 16px; }
.text_odds {
  display: block; font-size: 14px; font-weight: 700; color: #c8250a;
  line-height: 16px; text-align: center;
}
.btn_lebet_odd:hover { background: #f7f7f7; }
.btn_lebet_odd.on { background: #19805c; border-color: #19805c; }
.btn_lebet_odd.on .text_odds,
.btn_lebet_odd.on .text_ballou,
.btn_lebet_odd.on .text_ballhead { color: #fff; }

.box_state {
  display: grid; grid-template-columns: 1fr 20px; align-items: center;
  height: 32px; margin: 4px 0; font-size: 12px; color: rgba(0,0,0,.64);
}
.text_time { display: block; margin: 0 8px 0 0; font-size: 12px; line-height: 16px; color: #000; }
.text_time i { font-style: normal; }
.icon_inplay {
  display: block; width: 5px; height: 5px; border-radius: 50%; background: #4ad07f;
  box-shadow: 0 0 0 2px rgba(74,208,127,.25);
}
.btn_inn_team { display: block; }
.box_cup_flag { display: none; }
.text_team {
  display: block; font-size: 13px; line-height: 17px; color: #000;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.text_team.strong_team { font-weight: 700; }
.box_star { display: none; }
.btn_game_more { display: flex; align-items: center; justify-content: space-between; }
.btn_total { display: flex; align-items: center; gap: 2px; font-size: 11px; color: rgba(0,0,0,.4); }
.icon_arrow svg { width: 10px; height: 10px; fill: rgba(0,0,0,.32); }

/* ---------- 注单面板 ---------- */
#order_panel.ord_qkslip {
  position: fixed; top: 0; right: 0; bottom: 0; width: 340px; max-width: 340px;
  background: #fff; border-left: 1px solid #e5e5e5; display: flex; flex-direction: column;
  z-index: 30; box-shadow: -4px 0 16px rgba(0,0,0,.06);
}
.ord_qkslip .ord_fullslip { flex: 1; display: flex; flex-direction: column; overflow: hidden; }
.ord_qkslip .ord_title {
  display: flex; align-items: center; justify-content: space-between;
  height: 48px; padding: 0 12px; background: #fff; border-bottom: 1px solid #eee;
}
.ord_qkslip .ord_info { display: flex; align-items: center; gap: 8px; }
.ord_qkslip .title_txt { font-size: 15px; font-weight: 700; color: #000; }
.ord_qkslip .title_txt code {
  display: inline-block; min-width: 18px; height: 18px; line-height: 18px;
  margin-left: 4px; padding: 0 5px; border-radius: 9px;
  background: #19805c; color: #fff; font-size: 11px; text-align: center;
}
.ord_qkslip .balance { font-size: 14px; font-weight: 700; color: #19805c; }
.ord_qkslip .ord_empty {
  flex: 1; display: flex; align-items: center; justify-content: center;
  font-size: 13px; color: rgba(0,0,0,.32);
}
.ord_qkslip .ord_total {
  border-top: 1px solid #eee; padding: 10px 12px; background: #fafafa;
}
.ord_qkslip .ord_total_title {
  display: flex; justify-content: space-between; font-size: 12px; color: rgba(0,0,0,.56);
}
.ord_qkslip .ord_total_amount {
  display: flex; justify-content: space-between; margin-top: 4px;
  font-size: 16px; font-weight: 700;
}
.ord_qkslip .ord_total_amount .word_green { color: #2fae68; }
.ord_qkslip .ord_order_button {
  display: flex; align-items: center; gap: 8px; padding: 10px 12px;
  border-top: 1px solid #eee; background: #fff;
}
.ord_qkslip .btn_ord_betterbet {
  width: 36px; height: 44px; flex: none; border: 1px solid #e0e0e0;
  border-radius: 6px; background: #fff; display: flex; align-items: center; justify-content: center;
}
.ord_qkslip .btn_ord_betterbet svg { width: 18px; height: 18px; fill: rgba(0,0,0,.56); }
.ord_qkslip .btn_ord_pLacebet {
  flex: 1; height: 44px; border: 0; border-radius: 6px; background: #19805c;
  color: #fff; display: flex; align-items: center; justify-content: center; gap: 8px;
  font-size: 15px; font-weight: 700;
}
.ord_qkslip .btn_ord_pLacebet .status_db { display: inline-block; }
.ord_qkslip .btn_ord_del { background: none; border: 0; padding: 4px; }
.ord_qkslip .btn_ord_del svg { width: 16px; height: 16px; fill: rgba(0,0,0,.4); }
.ord_qkslip .ord_collapse { display: none; }

/* 主区避让注单面板 */
@media (min-width: 900px) {
  #main.main { padding-right: 340px; }
  #order_panel.ord_qkslip { display: flex; }
}

/* 手机端：面板改成底部抽屉 */
@media (max-width: 899px) {
  #order_panel.ord_qkslip {
    width: 100%; max-width: 100%; top: auto; height: 46%;
    border-left: 0; border-top: 1px solid #e5e5e5; border-radius: 12px 12px 0 0;
  }
  .box_lebet_l { width: 150px; grid-template-columns: 1fr; grid-template-rows: 32px 1fr; }
  .box_lebet_r { grid-auto-columns: 62px; }
  #main.main { padding-right: 0; padding-bottom: 46%; }
}
/* ---------- 比分与队名（滚球卡片） ---------- */
.box_lebet_l > label {
  grid-column: 1 / -1;
  grid-row: 2;
  display: block;
  min-width: 0;
  width: 100%;
}
.btn_inn_team { position: relative; padding-right: 18px; }
.box_score {
  position: absolute; right: 0; top: 0; width: 18px;
  display: flex; flex-direction: column; align-items: flex-end;
  height: auto;
}
.text_point {
  display: block; width: 100%; text-align: right;
  font-size: 14px; font-weight: 700; color: #000; line-height: 17px;
}
.text_point .text_total { display: none; }
.icon_redcard, .icon_serve { display: none !important; }
.box_team { height: 17px; }

/* 时间里的比赛时钟 */
.text_time b { display: inline-block; width: 4px; }
.txt_bk { font-style: normal; }

/* ---------- 注单条目 ---------- */
.ord_list { flex: 1; overflow-y: auto; padding: 4px 0; }
.ord_slip_model { position: relative; border-bottom: 1px solid #f0f0f0; padding: 8px 12px 10px; }
.ord_slip_model .btn_ord_miniclose {
  position: absolute; top: 6px; right: 8px; width: 20px; height: 20px;
  padding: 3px; border: 0; background: none; cursor: pointer;
}
.ord_slip_model .btn_ord_miniclose svg { width: 100%; height: 100%; fill: rgba(0,0,0,.32); }
.ord_slip_info .ord_odd_txt { display: block; padding-right: 24px; }
.ord_slip_info .ord_odd_txt li { font-size: 12px; line-height: 18px; color: rgba(0,0,0,.72); }
.ord_slip_info .ord_odd_txt li.type { display: flex; align-items: center; gap: 4px; font-size: 13px; color: #000; }
.ord_slip_info .ord_odd_txt li.word_gray { color: rgba(0,0,0,.48); }
.word_yellow { color: #d99b00; }
.word_red { color: #c8250a; }
.word_green { color: #2fae68; }
.ord_amount { margin-top: 6px; }
.ord_amount_enter input {
  width: 100%; height: 34px; padding: 0 8px; font-size: 14px;
  border: 1px solid #e0e0e0; border-radius: 4px; background: #fafafa; outline: none;
}
.ord_amount_enter input:focus { border-color: #19805c; background: #fff; }

/* ===== 手机端：375 / 390 / 414 三档 ===== */
@media (max-width: 480px) {
  #header_show.header { height: 48px; }
  #header_show .box_header { padding: 0 4px; }
  #header_show .btn_home { width: 30px; }
  #header_show .btn_header { padding: 0 8px; font-size: 13px; height: 30px; line-height: 30px; }
  #header_show .text_credit { font-size: 13px; }
  #header_show .text_currency { font-size: 10px; }
  #header_show .btn_myGame, #header_show .btn_todaywagers { display: none; }
  #header_show .btn_acc { width: 30px; height: 30px; }

  #sport_menu.sport_scroll { height: 44px; }
  .btn_le_sport { min-width: 48px; font-size: 10px; padding: 0 6px; }
  .btn_le_sport i, .btn_le_sport i svg { width: 16px; height: 16px; }

  #tab_menu.tab_scroll { height: 36px; }
  #tab_scroll.dragscroll_tab { padding: 0 6px; }
  .btn_filter { height: 24px; line-height: 24px; font-size: 12px; padding: 0 10px; margin-right: 4px; border-radius: 12px; }

  #main_content.content_sport { padding: 4px; }
  .btn_title_le { height: 34px; font-size: 13px; padding: 2px 6px; }
  .btn_title_le .icon_flag { width: 14px; height: 10px; }

  .box_lebet { margin-bottom: 3px; }
  .box_lebet_top { min-height: 132px; }
  .box_lebet_l { width: 130px; grid-template-columns: 1fr; grid-template-rows: 28px 1fr; padding: 0 6px; height: 124px; }
  .box_lebet_l > label { grid-column: 1; grid-row: 2; }
  .box_state { height: 28px; margin: 2px 0; grid-template-columns: 1fr 8px; }
  .text_time { font-size: 11px; line-height: 14px; margin-right: 4px; }
  .text_team { font-size: 12px; line-height: 15px; }
  .box_team { height: 15px; }
  .btn_inn_team { padding-right: 14px; }
  .text_point { font-size: 13px; line-height: 15px; }
  .box_score { width: 14px; }
  .btn_total { font-size: 10px; }
  .icon_arrow svg { width: 8px; height: 8px; }

  .box_lebet_r { grid-auto-columns: 58px; grid-template-rows: 124px; height: 132px; padding: 0 0 4px; gap: 3px; }
  .box_lebet_odd { height: 124px; gap: 3px; }
  .head_lebet { height: 30px; font-size: 11px; line-height: 12px; padding-top: 2px; }
  .head_lebet tt, .head_lebet span { max-width: 58px; overflow: hidden; text-overflow: ellipsis; }
  .btn_lebet_odd { border-radius: 2px; padding: 1px; }
  .text_odds { font-size: 13px; line-height: 14px; }
  .text_ballou, .text_ballhead { font-size: 11px; line-height: 13px; }

  #order_panel.ord_qkslip { height: 42%; border-radius: 10px 10px 0 0; }
  #main.main { padding-bottom: 42%; }
  .ord_qkslip .ord_title { height: 40px; padding: 0 8px; }
  .ord_qkslip .title_txt { font-size: 14px; }
  .ord_qkslip .btn_ord_pLacebet { height: 40px; font-size: 14px; }
  .ord_qkslip .ord_total { padding: 8px; }
  .ord_qkslip .ord_total_amount { font-size: 15px; }
  .ord_slip_model { padding: 6px 8px 8px; }
}

/* 小屏（375）压得更紧 */
@media (max-width: 380px) {
  .box_lebet_l { width: 118px; }
  .box_lebet_r { grid-auto-columns: 54px; }
  .text_team { font-size: 11px; }
  .btn_filter { padding: 0 8px; font-size: 11px; }
  .btn_le_sport { min-width: 44px; }
}

/* 大屏（414+）松一点 */
@media (min-width: 400px) and (max-width: 480px) {
  .box_lebet_l { width: 140px; }
  .box_lebet_r { grid-auto-columns: 62px; }
  .text_team { font-size: 13px; }
}
