/* 배팅내역 — 관리자 배팅내역 테이블 레이아웃, 유저(실버) 팔레트 */

/* 미니게임 하부 탭 */
.bl_mini_tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 8px 0 2px;
  padding: 10px;
  border: 1px solid rgba(200, 208, 216, 0.16);
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.25);
}

.bl_mini_tab {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 30px;
  padding: 0 12px;
  border: 1px solid rgba(200, 208, 216, 0.18);
  border-radius: 6px;
  background: linear-gradient(to bottom, #1f2226, #22262b);
  color: #aab3bc;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.bl_mini_tab:hover {
  background: linear-gradient(to bottom, #31363c, #30363c);
  color: #c8d0d8;
}

.bl_mini_tab.is-active {
  background: linear-gradient(to bottom, #6a737d, #616a74);
  border-color: rgba(238, 241, 244, 0.4);
  color: #eef1f5;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 0 6px rgba(200, 208, 216, 0.3);
}

.bl_mini_tab img {
  width: 18px;
  height: 18px;
  object-fit: contain;
}

.bl-mini-caret {
  font-size: 11px;
  margin-left: 2px;
  display: inline-block;
  transition: transform 0.2s ease;
}

.bl_toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
  margin: 5px 0 10px;
}

.bl_status_tabs {
  display: inline-flex;
  gap: 6px;
  flex-wrap: wrap;
}

.bl_status_btn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  min-width: 64px;
  height: 32px;
  padding: 0 12px;
  justify-content: center;
  border: 1px solid rgba(200, 208, 216, 0.2);
  border-radius: 6px;
  background: linear-gradient(to bottom, #22262b, #2b3036);
  color: #aab3bc;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
}

.bl_status_btn:hover,
.bl_status_btn.is-active {
  background: linear-gradient(to bottom, #5a636d, #525a63);
  color: #eef1f4;
  border-color: rgba(200, 208, 216, 0.45);
}

.bl_meta {
  color: #8a929a;
  font-size: 12px;
}

.bl_login_notice,
.bl_loading,
.bl_empty {
  text-align: center;
  padding: 46px 16px;
  color: #aab3bc;
  font-size: 14px;
  border: 1px solid #353535;
  background: rgba(31, 31, 31, 0.35);
}

.bl_login_notice i,
.bl_loading i {
  margin-right: 6px;
  color: #c8d0d8;
}

/* 메인 테이블 */
.bl_table_wrap {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  border: 1px solid #353535;
  background: rgba(26, 26, 26, 0.6);
}

table.bl_table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
  color: #ddd;
}

table.bl_table thead th {
  padding: 10px 8px;
  background: linear-gradient(to bottom, #2a2e33, #1e2226);
  color: #c8d0d8;
  font-weight: 700;
  font-size: 12px;
  white-space: nowrap;
  text-align: center;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.8);
  border-bottom: 1px solid #3e454d;
}

table.bl_table td {
  padding: 9px 8px;
  border-bottom: 1px solid #2c2c2c;
  text-align: center;
  vertical-align: middle;
}

tr.bl-row {
  cursor: pointer;
  transition: background 0.15s;
}

tr.bl-row:hover {
  background: rgba(200, 208, 216, 0.06);
}

tr.bl-row.bl-row--open {
  background: rgba(200, 208, 216, 0.08);
}

.bl-oid {
  font-family: "Consolas", "Menlo", monospace;
  font-size: 12px;
  color: #aab3bc;
}

.bl-category {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: #c8d0d8;
  font-weight: 700;
  white-space: nowrap;
}

.bl-category i {
  font-size: 11px;
  color: #8a929a;
}

.bl-money {
  white-space: nowrap;
}

.bl-money strong {
  color: #eef1f4;
}

.bl-unit {
  margin-left: 2px;
  font-size: 11px;
  color: #8a929a;
}

.bl-rate {
  color: #c8d0d8;
  font-weight: 700;
}

.bl-date {
  color: #aab3bc;
  font-size: 12px;
  white-space: nowrap;
}

/* 종목 아이콘 스택 */
table.bl_table td.bl-col-sport,
table.bl_table th.bl-col-sport {
  text-align: left;
}

.bl-sport-icons {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  flex-wrap: wrap;
  justify-content: flex-start;
  max-width: 150px;
}

.bl-sport-icon-wrap {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: rgba(200, 208, 216, 0.08);
  border: 1px solid rgba(200, 208, 216, 0.18);
}

.bl-sport-icon-wrap img {
  width: 17px;
  height: 17px;
  object-fit: contain;
}

.bl-sport-icon-wrap .bl-sport-ph {
  color: #8a929a;
  font-size: 12px;
}

.bl-sport-icon-wrap--win {
  border-color: rgba(80, 120, 255, 0.65);
}

.bl-sport-icon-wrap--lose {
  border-color: rgba(255, 80, 80, 0.65);
}

.bl-sport-icon-wrap--void {
  border-color: rgba(160, 160, 160, 0.6);
}

.bl-sport-badge {
  position: absolute;
  right: -4px;
  bottom: -4px;
  width: 13px;
  height: 13px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 8px;
  color: #fff;
  background: #555;
}

.bl-sport-icon-wrap--win .bl-sport-badge {
  background: linear-gradient(to bottom, rgba(50, 50, 255, 1), rgba(20, 20, 100, 1));
}

.bl-sport-icon-wrap--lose .bl-sport-badge {
  background: linear-gradient(to bottom, rgba(255, 50, 50, 1), rgba(100, 20, 20, 1));
}

.bl-sport-icon-wrap--void .bl-sport-badge {
  background: #6b7178;
}

/* 상태/결과 배지 — 유저 사이트 기존 icon_base 색상 규칙 유지 */
.bl-badge {
  display: inline-block;
  padding: 3px 8px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 700;
  color: #fff;
  white-space: nowrap;
  text-shadow: 1px 1px 1px rgba(0, 0, 0, 0.7);
  background: linear-gradient(to bottom, rgba(70, 70, 70, 1) 1%, rgba(20, 20, 20, 1) 100%);
}

.bl-badge--win {
  background: linear-gradient(to bottom, rgba(50, 50, 255, 1) 1%, rgba(20, 20, 100, 1) 100%);
}

.bl-badge--lose {
  background: linear-gradient(to bottom, rgba(255, 50, 50, 1) 1%, rgba(100, 20, 20, 1) 100%);
}

.bl-badge--done {
  background: linear-gradient(to bottom, rgba(50, 255, 50, 1) 1%, rgba(20, 100, 20, 1) 100%);
}

.bl-badge--void {
  background: linear-gradient(to bottom, #6b7178, #4a5057);
}

.bl-badge--pending {
  background: linear-gradient(to bottom, #454c54, #3a414a);
  color: #dfe4ea;
}

.bl-toggle-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border: 1px solid rgba(200, 208, 216, 0.25);
  border-radius: 5px;
  background: linear-gradient(to bottom, #2a2e33, #1e2226);
  color: #c8d0d8;
  cursor: pointer;
  font-size: 11px;
  transition: background 0.15s;
}

tr.bl-row:hover .bl-toggle-btn,
tr.bl-row--open .bl-toggle-btn {
  background: linear-gradient(to bottom, #454c54, #3a414a);
  color: #fff;
}

/* 상세(폴더) 행 */
tr.bl-detail-row > td {
  padding: 0;
  border-bottom: 1px solid #3e454d;
  background: #141619;
}

table.bl_legs_table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
  color: #ccc;
}

table.bl_legs_table thead th {
  padding: 7px 6px;
  background: rgba(200, 208, 216, 0.07);
  color: #aab3bc;
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
  text-align: center;
  border-bottom: 1px solid #333;
}

table.bl_legs_table td {
  padding: 8px 6px;
  border: 1px solid rgba(200, 208, 216, 0.12);
  text-align: center;
  vertical-align: middle;
  line-height: 1.35;
}

table.bl_legs_table td > * {
  vertical-align: middle;
}

/* 게임타입/종목/경기시간/배당/스코어/결과 — 내용 폭만 차지 */
table.bl_legs_table th:nth-child(1),
table.bl_legs_table td:nth-child(1),
table.bl_legs_table th:nth-child(2),
table.bl_legs_table td:nth-child(2),
table.bl_legs_table th:nth-child(3),
table.bl_legs_table td:nth-child(3),
table.bl_legs_table th:nth-child(9),
table.bl_legs_table td:nth-child(9),
table.bl_legs_table th:nth-child(10),
table.bl_legs_table td:nth-child(10),
table.bl_legs_table th:nth-child(11),
table.bl_legs_table td:nth-child(11) {
  width: 1%;
  white-space: nowrap;
}

table.bl_legs_table td:nth-child(5),
table.bl_legs_table td:nth-child(7) {
  min-width: 0;
  padding-left: 10px;
  padding-right: 10px;
}

.bl-leg-league {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: #c8d0d8;
  white-space: nowrap;
  max-width: 180px;
  overflow: hidden;
  text-overflow: ellipsis;
}

.bl-leg-league i {
  font-size: 10px;
  color: #77808a;
  flex-shrink: 0;
}

/* 홈: 팀명(좌)-배당(우) / 원정: 배당(좌)-팀명(우) — 관리자 배팅내역과 동일 정렬 */
.bl-leg-side {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  max-width: 100%;
  justify-content: space-between;
  white-space: nowrap;
}

.bl-leg-odds-group {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  flex-shrink: 0;
}

.bl-leg-team {
  color: #e4e8ec;
  overflow: hidden;
  text-overflow: ellipsis;
}

.bl-leg-odd-box {
  display: inline-block;
  min-width: 40px;
  padding: 2px 6px;
  border: 1px solid #3e454d;
  border-radius: 4px;
  background: #1e2226;
  color: #c8d0d8;
  font-weight: 700;
}

.bl-leg-pick {
  color: #eef1f4;
  font-weight: 700;
}

.bl-leg-picked .bl-leg-odd-box {
  border-color: rgba(200, 208, 216, 0.7);
  background: linear-gradient(to bottom, #454c54, #3a414a);
  color: #fff;
}

.bl-bet-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 15px;
  height: 15px;
  border-radius: 3px;
  font-size: 9px;
  font-weight: 700;
  color: #dfe4ea;
  background: #3e454d;
}

.bl-leg-result {
  display: inline-block;
  padding: 2px 7px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 700;
  color: #fff;
  white-space: nowrap;
  text-shadow: 1px 1px 1px rgba(0, 0, 0, 0.7);
  background: linear-gradient(to bottom, #454c54, #3a414a);
}

.bl-leg-result--win {
  background: linear-gradient(to bottom, rgba(50, 50, 255, 1) 1%, rgba(20, 20, 100, 1) 100%);
}

.bl-leg-result--lose {
  background: linear-gradient(to bottom, rgba(255, 50, 50, 1) 1%, rgba(100, 20, 20, 1) 100%);
}

.bl-leg-result--void {
  background: linear-gradient(to bottom, #6b7178, #4a5057);
}

/* 페이징 — cs_center 페이지네이션과 동일 컨셉 */
.bl_pager {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 4px;
  padding: 16px 8px;
  flex-wrap: wrap;
}

.bl_pager .bl-page-link,
.bl_pager .bl-page-current {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 28px;
  height: 28px;
  padding: 0 6px;
  border-radius: 4px;
  font-size: 12px;
  font-weight: bold;
  cursor: pointer;
}

.bl_pager .bl-page-link {
  color: #99a3ad;
  text-decoration: none;
  border: 1px solid #444;
  background: #222;
}

.bl_pager .bl-page-link:hover {
  color: #c8d0d8;
  border-color: #665;
}

.bl_pager .bl-page-current {
  color: #fff;
  background: linear-gradient(to bottom, #454c54, #3a414a);
  border: 1px solid #665;
}

/* 모바일 */
@media (max-width: 767px) {
  .bl_toolbar {
    flex-direction: column;
    align-items: stretch;
  }

  .bl_status_tabs {
    width: 100%;
  }

  .bl_status_btn {
    flex: 1 1 auto;
    min-width: 0;
    padding: 0 8px;
    font-size: 12px;
  }

  table.bl_table .bl-col-oid,
  table.bl_table .bl-col-category,
  table.bl_table .bl-col-rate,
  table.bl_table .bl-col-sport,
  table.bl_table .bl-col-expwin {
    display: none;
  }

  table.bl_table thead th,
  table.bl_table td {
    padding: 8px 4px;
    font-size: 12px;
  }

  .bl-sport-icons {
    max-width: 84px;
  }

  table.bl_legs_table {
    min-width: 680px;
  }
}
