/* ============================================================
   AZ24 KQXS CSS — Bảng kết quả xổ số chuẩn az24.vn
   Thay thế toàn bộ xs-result-table, xs-prize-*, xs-stat-*
   Áp dụng: XSMB (ĐB→G7) + XSMN/XSMT (G8→ĐB) + Đầu/Đuôi
   ============================================================ */

:root {
  --xs-red:        #c8001e;
  --xs-red-bg:     #fff8f0;
  --xs-red-border: #f0d0d0;
  --xs-red-light:  #fff8f8;
  --xs-gray-bg:    #fafafa;
  --xs-line:       #ececec;
  --xs-line-strong:#e8e8e8;
  --xs-muted:      #888;
  --xs-white:      #fff;
  --xs-blue:       #1a56a0;
  --xs-orange:     #e65000;
}

/* ── TABS 3 MIỀN ── */
.xs-region-tabs {
  display: flex;
  background: var(--xs-white);
  border-bottom: 2px solid #e0e0e0;
  overflow-x: auto;
  scrollbar-width: none;
}
.xs-region-tabs::-webkit-scrollbar { display: none; }
.xs-region-tab {
  padding: 10px 18px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  border: none;
  background: transparent;
  color: #555;
  border-bottom: 3px solid transparent;
  margin-bottom: -2px;
  white-space: nowrap;
  flex-shrink: 0;
}
.xs-region-tab.active {
  color: var(--xs-red);
  border-bottom-color: var(--xs-red);
}
.xs-region-tab:hover:not(.active) { color: #333; background: #fafafa; }

/* ── SUB-TABS THEO THỨ ── */
.xs-day-tabs {
  display: flex;
  background: var(--xs-white);
  border-bottom: 1px solid var(--xs-line-strong);
  overflow-x: auto;
  scrollbar-width: none;
}
.xs-day-tabs::-webkit-scrollbar { display: none; }
.xs-day-tab {
  padding: 7px 12px;
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  border: none;
  background: transparent;
  color: #555;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  white-space: nowrap;
  flex-shrink: 0;
}
.xs-day-tab.active {
  color: var(--xs-orange);
  border-bottom-color: var(--xs-orange);
  font-weight: 700;
}
.xs-day-tab:hover:not(.active) { background: #fafafa; }

/* ── HEADER ĐỎ / CAM ── */
.xs-header {
  background: var(--xs-orange);
  color: var(--xs-white);
  text-align: center;
  padding: 10px 10px 9px;
}
.xs-header.xs-header-red { background: var(--xs-red); }
.xs-header.xs-header-purple { background: #4a148c; }
.xs-header h2, .xs-header h3 {
  font-size: 15px;
  font-weight: 700;
  margin-bottom: 3px;
}
.xs-header p, .xs-header .xs-breadlink {
  font-size: 12px;
  opacity: 1;
  margin-top: 3px;
}
.xs-header a { color: #ffd0b0; text-decoration: underline; }
.xs-header .xs-sep { color: #ffd0b0; text-decoration: none; }

/* ── MÃ ĐB ROW ── */
.xs-pills-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 5px 10px;
  background: var(--xs-white);
  border-bottom: 1px solid var(--xs-line);
  font-size: 12px;
}
.xs-pills-label { color: var(--xs-muted); }
.xs-pills-nums  { color: var(--xs-blue); font-weight: 700; letter-spacing: 0.5px; }

/* ── BẢNG XSMB — bảng kết quả chính ── */
.xs-result-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--xs-white);
}
.xs-result-table tr {
  border-bottom: 1px solid var(--xs-line);
}
.xs-result-table tr:last-child { border-bottom: none; }

/* Cột nhãn giải (ĐB, G1...) */
.xs-result-table .xs-gl {
  width: 34px;
  min-width: 34px;
  color: var(--xs-muted);
  font-size: 12px;
  font-weight: 700;
  padding: 0 4px 0 8px;
  text-align: left;
  white-space: nowrap;
  border-right: 1px solid var(--xs-line);
  vertical-align: middle;
  background: var(--xs-white);
}

/* Cột số chung */
.xs-result-table .xs-gn {
  padding: 0;
  vertical-align: middle;
}

/* ── CỠ CHỮ TỪNG GIẢI XSMB ── */
/* ĐB */
.xs-prize-db {
  font-size: 28px;
  font-weight: 700;
  color: var(--xs-red);
  letter-spacing: 3px;
  display: block;
  text-align: center;
  padding: 8px 5px;
}
/* G1 */
.xs-prize-g1 {
  font-size: 18px;
  font-weight: 700;
  color: #333;
  letter-spacing: 2px;
  display: block;
  text-align: center;
  padding: 7px 5px;
}
/* G2: grid 3 ô, ô giữa trống */
.xs-prize-g2-wrap {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  width: 100%;
}
.xs-prize-g2-wrap .xs-cell {
  text-align: center;
  padding: 7px 4px;
  font-size: 16px;
  font-weight: 700;
  color: #333;
  border-left: 1px solid var(--xs-line);
}
.xs-prize-g2-wrap .xs-cell:first-child { border-left: none; }
.xs-prize-g2-wrap .xs-cell.xs-empty { color: transparent; }

/* G3: grid 2 hàng × 3 cột */
.xs-prize-g3-wrap {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  width: 100%;
}
/* G4: grid 1 hàng × 4 cột */
.xs-prize-g4-wrap {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  width: 100%;
}
/* G5: grid 2 hàng × 3 cột */
.xs-prize-g5-wrap {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  width: 100%;
}
/* G6: grid 1 hàng × 3 cột */
.xs-prize-g6-wrap {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  width: 100%;
}
/* G7: grid 1 hàng × 4 cột */
.xs-prize-g7-wrap {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  width: 100%;
}

/* Ô số dùng chung cho G3–G7 */
.xs-cell {
  text-align: center;
  padding: 6px 4px;
  font-size: 15px;
  font-weight: 700;
  color: #333;
  border-left: 1px solid var(--xs-line);
  border-top: 1px solid var(--xs-line);
}
/* Ô đầu tiên của hàng đầu: không có border-left & border-top */
.xs-prize-g3-wrap .xs-cell:nth-child(-n+3),
.xs-prize-g5-wrap .xs-cell:nth-child(-n+3) { border-top: none; }
.xs-prize-g3-wrap .xs-cell:nth-child(3n+1),
.xs-prize-g5-wrap .xs-cell:nth-child(3n+1) { border-left: none; }
.xs-prize-g4-wrap .xs-cell,
.xs-prize-g6-wrap .xs-cell,
.xs-prize-g7-wrap .xs-cell { border-top: none; }
.xs-prize-g4-wrap .xs-cell:first-child,
.xs-prize-g6-wrap .xs-cell:first-child,
.xs-prize-g7-wrap .xs-cell:first-child { border-left: none; }

/* G7 đỏ to */
.xs-prize-g7-wrap .xs-cell {
  font-size: 22px;
  font-weight: 700;
  color: var(--xs-red);
  padding: 6px 4px;
}

/* ── BẢNG XSMN/XSMT — nhiều đài ── */
/* Thứ tự: G8 trên → ĐB dưới */
.xs-mn-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--xs-white);
}
.xs-mn-table thead th {
  padding: 7px 5px;
  font-size: 13px;
  font-weight: 700;
  text-align: center;
  border-bottom: 2px solid var(--xs-line-strong);
  color: var(--xs-blue);
  text-decoration: underline;
  cursor: pointer;
  background: var(--xs-white);
}
.xs-mn-table thead th.xs-gh {
  color: var(--xs-muted);
  font-weight: normal;
  text-decoration: none;
  cursor: default;
  width: 34px;
}
.xs-mn-table td {
  border-bottom: 1px solid #f0f0f0;
  padding: 5px 5px;
  text-align: center;
  vertical-align: middle;
  font-size: 14px;
}
.xs-mn-table tr:last-child td { border-bottom: none; }
.xs-mn-table td.xs-gl2 {
  color: var(--xs-muted);
  font-size: 12px;
  font-weight: 700;
  width: 34px;
  background: #fafafa;
  border-right: 1px solid var(--xs-line);
}
.xs-mn-table tr.xs-row-db td { background: #fff8f0; }
.xs-mn-table tr.xs-row-db td.xs-gl2 { color: var(--xs-red); }

/* Cỡ chữ từng giải MN/MT */
.xs-prize-g8  { font-size: 22px; font-weight: 700; color: var(--xs-red); }
.xs-prize-g7n { font-size: 14px; font-weight: 700; color: #333; }
.xs-prize-g6n { font-size: 13px; color: #333; line-height: 1.9; }
.xs-prize-g5n { font-size: 14px; font-weight: 700; color: #333; }
.xs-prize-g4n { font-size: 13px; color: #333; line-height: 1.9; }
.xs-prize-g3n { font-size: 13px; color: #333; line-height: 1.9; }
.xs-prize-g2n { font-size: 14px; font-weight: 700; color: #333; }
.xs-prize-g1n { font-size: 15px; font-weight: 700; color: #333; }
.xs-prize-db-sm { font-size: 20px; font-weight: 700; color: var(--xs-red); letter-spacing: 1px; }

/* ── RADIO + FILTER BAR ── */
.xs-stat-bar {
  background: #fffbea;
  border-top: 2px solid var(--xs-line-strong);
  padding: 6px 10px;
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  flex-wrap: wrap;
}
.xs-sradio {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  cursor: pointer;
  color: #444;
  user-select: none;
}
.xs-sradio input[type="radio"] { accent-color: var(--xs-red); cursor: pointer; }
.xs-dau-btns { display: flex; gap: 3px; margin-left: auto; }
.xs-dau-btn {
  width: 24px; height: 24px;
  border-radius: 50%;
  background: #e5e5e5;
  color: #333;
  font-size: 11px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  border: none;
  user-select: none;
}
.xs-dau-btn.active, .xs-dau-btn:hover {
  background: var(--xs-red);
  color: var(--xs-white);
}

/* ── BẢNG ĐẦU ĐUÔI XSMB — 2 bảng song song ── */
.xs-dd-wrap {
  display: grid;
  grid-template-columns: 1fr 1fr;
  border-top: 1px solid var(--xs-line-strong);
  background: var(--xs-white);
}
.xs-dd-tbl {
  width: 100%;
  border-collapse: collapse;
}
.xs-dd-tbl:first-child { border-right: 2px solid #ddd; }
.xs-dd-tbl th {
  background: var(--xs-white);
  color: #555;
  font-size: 13px;
  font-weight: 700;
  padding: 7px 10px;
  border-bottom: 1px solid #ddd;
  text-align: left;
}
.xs-dd-tbl th.xs-th-r { text-align: right; }
.xs-dd-tbl td {
  border-bottom: 1px solid #f2f2f2;
  padding: 5px 10px;
  font-size: 13px;
}
.xs-dd-tbl tr:last-child td { border-bottom: none; }
/* Bảng trái: đầu đỏ trái, đuôi đen trái */
.xs-dd-tbl.xs-dd-left td.xs-idx { color: var(--xs-red); font-weight: 700; width: 28px; text-align: left; }
.xs-dd-tbl.xs-dd-left td.xs-vals { text-align: left; color: #333; }
/* Bảng phải: đầu đen phải, đuôi đỏ phải */
.xs-dd-tbl.xs-dd-right td.xs-vals { text-align: right; color: #333; }
.xs-dd-tbl.xs-dd-right td.xs-idx  { color: var(--xs-red); font-weight: 700; width: 28px; text-align: right; }
/* Số xuất hiện nhiều lần */
.xs-hot { color: var(--xs-red); font-weight: 700; }

/* ── BẢNG ĐẦU ĐUÔI XSMN/XSMT — 1 bảng nhiều cột đài ── */
.xs-mn-dd-tbl {
  width: 100%;
  border-collapse: collapse;
  background: var(--xs-white);
  border-top: 1px solid #ddd;
}
.xs-mn-dd-tbl th {
  background: var(--xs-white);
  color: #555;
  font-size: 13px;
  font-weight: 700;
  padding: 7px 8px;
  border-bottom: 1px solid #ddd;
  text-align: center;
}
.xs-mn-dd-tbl th.xs-didx { text-align: left; padding-left: 12px; }
.xs-mn-dd-tbl td {
  border-bottom: 1px solid #f2f2f2;
  padding: 5px 8px;
  font-size: 13px;
  text-align: center;
}
.xs-mn-dd-tbl tr:last-child td { border-bottom: none; }
.xs-mn-dd-tbl td.xs-didx {
  color: var(--xs-red);
  font-weight: 700;
  background: #fafafa;
  border-right: 1px solid var(--xs-line);
  text-align: center;
  width: 36px;
}
.xs-mn-dd-tbl td.xs-dnums { text-align: left; }

/* ── LEGACY: baCol / haiCol / bonCol (plugin cũ) ── */
/* Mỗi số xuống 1 dòng, căn giữa, đúng font */
/* ── TAB CONTENT TOGGLE ── */
.xs-tab-panel        { display: none; }
.xs-tab-panel.active { display: block; }
.xs-sub-panel        { display: none; }
.xs-sub-panel.active { display: block; }

/* ── LINK XEM THÊM ── */
.xs-more-link {
  padding: 7px 12px;
  background: var(--xs-red-light);
  border-top: 1px solid var(--xs-red-border);
  font-size: 12px;
}
.xs-more-link a { color: var(--xs-red); }

/* ── RESPONSIVE ── */
@media (max-width: 480px) {
  .xs-region-tab  { font-size: 12px; padding: 8px 12px; }
  .xs-prize-db    { font-size: 22px; letter-spacing: 2px; }
  .xs-prize-db-sm { font-size: 16px; }
  .xs-prize-g1    { font-size: 16px; }
  .xs-prize-g8    { font-size: 18px; }
  .xs-prize-g7-wrap .xs-cell { font-size: 18px; }
  .xs-header h2, .xs-header h3 { font-size: 13px; }
  .xs-dau-btn     { width: 20px; height: 20px; font-size: 10px; }
}

/* ══════════════════════════════════════
   THEME SYNC — đồng bộ plugin với az24 theme
   ══════════════════════════════════════ */

/* Wrap-head: header đỏ plugin — đồng bộ với .kqh */
.wrap-head {
  background: #c8001e;
  color: #fff;
  text-align: center;
  padding: 10px 14px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.wrap-title { font-size: 15px; font-weight: 700; flex: 1; text-align: center; }
.wrap-date  { font-size: 12px; opacity: .85; flex-shrink: 0; }
.wrap-sub   { background: #a0001a; color: rgba(255,255,255,.9); padding: 4px 14px; font-size: 12px; text-align: center; }
.wrap-sub a { color: #ffd0b0; text-decoration: underline; margin: 0 3px; }
.wrap-border { border: 1px solid #ddd; overflow: hidden; margin-bottom: 10px; border-top: none; }

/* Section tabs — đồng bộ với .dtab */
.section-tabs { display: flex; background: #fff; border: 1px solid #ddd; border-top: none; border-bottom: 2px solid #e0e0e0; }
a.stab, button.stab {
  flex: 1; padding: 9px 8px; border: none; background: #fff; cursor: pointer;
  font-size: 12px; font-weight: 600; color: #555; border-bottom: 2px solid transparent;
  text-align: center; text-decoration: none; display: flex; align-items: center; justify-content: center;
  gap: 4px; font-family: inherit; margin-bottom: -2px;
}
a.stab.active, button.stab.active { color: #e65000; border-bottom-color: #e65000; background: #fff; }
a.stab:hover:not(.active), button.stab:hover:not(.active) { background: #fafafa; color: #333; }

/* Date nav — đồng bộ với .dtab */
.date-nav {
  display: flex; align-items: center; gap: 6px; background: #fff;
  padding: 6px 12px; border: 1px solid #ddd; border-bottom: none;
  overflow-x: auto; scrollbar-width: none;
}
.date-nav::-webkit-scrollbar { display: none; }
.dnav-label { font-weight: 700; color: #888; font-size: 12px; flex-shrink: 0; }
.date-btn {
  padding: 4px 12px; border-radius: 14px; border: 1px solid #ddd;
  background: #fff; cursor: pointer; font-size: 12px; font-family: inherit;
  color: #555; white-space: nowrap; flex-shrink: 0;
}
.date-btn.active, .date-btn:hover { background: #c8001e; color: #fff; border-color: #c8001e; }

/* Daylink — đồng bộ với .sb-link */
.daylink-wrap { background: #fff; border: 1px solid #ddd; overflow: hidden; margin-top: 10px; }
.daylink-head { background: #333; color: #fff; padding: 8px 12px; font-size: 13px; font-weight: 700; }
.daylink-grid { display: grid; grid-template-columns: repeat(3,1fr); }
.daylink-col  { border-right: 1px solid #eee; }
.daylink-col:last-child { border-right: none; }
.daylink-title { padding: 6px 10px; font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .4px; border-bottom: 1px solid #eee; }
.daylink-title.red   { background: #fef5f5; color: #c8001e; }
.daylink-title.sky   { background: #e3f0ff; color: #1a56a0; }
.daylink-title.green { background: #e8f5e9; color: #1b8a4a; }
.daylink { display: flex; align-items: center; padding: 5px 10px; font-size: 12px; color: #333; border-bottom: 1px solid #f0f0f0; text-decoration: none; line-height: 1.5; }
.daylink:last-child { border-bottom: none; }
.daylink:hover { background: #fef5f5; color: #c8001e; }
.daylink.active { background: #fff8e1; color: #c8001e; font-weight: 700; }
.daylink::before { content: "▪"; color: #c8001e; font-size: 12px; margin-right: 5px; flex-shrink: 0; }
@media(max-width:640px) { .daylink-grid { grid-template-columns: 1fr; } }

/* Plugin float columns — mỗi số 1 dòng */
/* Plugin layout containers */
.kqxs-table-wrapper, .lk-mb-wrap { margin: 0; }
.lk-wrap { max-width: 1200px; margin: 0 auto; padding: 0 8px; }
.lk-section { padding: 10px 0; }
.lk-content-with-sidebar { display: grid; grid-template-columns: 1fr 238px; gap: 6px; align-items: start; }
.lk-soicau-card { min-width: 0; }
.lk-soicau-card-body { background: #fff; border: 1px solid #ddd; overflow: visible; margin-bottom: 10px; }
@media(max-width:860px) { .lk-content-with-sidebar { grid-template-columns: 1fr; } }

/* SEO + xem thêm */
.kqxs-bai-viet-seo, .kqxs-ext-seo-block, .kqxs-seo-content, .province-seo-block { padding: 14px 16px; font-size: 13px; line-height: 1.9; color: #444; }
.kqxs-bai-viet-seo h2, .kqxs-ext-seo-block h2 { font-size: 13px; font-weight: 700; color: #333; margin: 12px 0 4px; }
.kqxs-bai-viet-seo p, .kqxs-ext-seo-block p { margin-bottom: 5px; }
.kqxs-xem-them, .xem-them-block { padding: 7px 14px; font-size: 12px; border-top: 1px solid #eee; }
.kqxs-xem-them a { color: #1a56a0; margin-right: 10px; text-decoration: underline; }

/* Sidebar card trong plugin */
.side-card { background: #fff; border: 1px solid #ddd; overflow: hidden; margin-bottom: 6px; }
.side-head  { padding: 8px 10px; font-weight: 700; font-size: 12px; color: #fff; display: flex; align-items: center; gap: 6px; }
.side-head.red  { background: #c8001e; }
.side-head.sky  { background: #1a56a0; }
.side-head.navy { background: #222; }
.res-row { display: flex; justify-content: space-between; align-items: center; padding: 6px 10px; border-bottom: 1px solid #f0f0f0; font-size: 12px; }
.res-row:last-child { border-bottom: none; }
.res-prov { font-weight: 700; color: #333; }
.res-db { font-size: 16px; font-weight: 700; color: #c8001e; letter-spacing: 1px; }
.prov-list { padding: 2px 0; }
.prov-link { display: flex; align-items: center; padding: 5px 10px; font-size: 12px; color: #333; border-bottom: 1px solid #f0f0f0; text-decoration: none; }
.prov-link:last-child { border-bottom: none; }
.prov-link:hover { background: #fef5f5; color: #c8001e; }
.prov-link.active { color: #c8001e; font-weight: 700; }
.prov-link::before { content: "▪"; color: #c8001e; font-size: 12px; margin-right: 5px; }
.prov-dots { display: inline-flex; gap: 3px; margin-left: auto; }
.prov-dots .dot { width: 6px; height: 6px; border-radius: 50%; background: #c8001e; animation: bl 1.2s infinite; }
.prov-dots .dot:nth-child(2) { animation-delay: .2s; }
.prov-dots .dot:nth-child(3) { animation-delay: .4s; }

/* Calendar pagination — đồng bộ màu */
.kqxs-calendar-prev, .kqxs-calendar-next { background: #c8001e; }
.kqxs-calendar-prev:hover, .kqxs-calendar-next:hover { background: #a0001a; }
.kqxs-calendar-table thead th { background: #c8001e; }
.kqxs-calendar-day.kqxs-calendar-selected { background: #c8001e; }
.kqxs-pagination-btn { background: #c8001e; }
.kqxs-pagination-btn:hover { background: #a0001a; }

/* Xổ số các thứ — tab ngày chuẩn */
.xs-thu-tabs { display: flex; background: #fff; border-bottom: 1px solid #e0e0e0; overflow-x: auto; scrollbar-width: none; }
.xs-thu-tabs::-webkit-scrollbar { display: none; }
.xs-thu-tab { padding: 7px 12px; cursor: pointer; font-size: 12px; color: #555; border-bottom: 2px solid transparent; margin-bottom: -1px; white-space: nowrap; flex-shrink: 0; text-decoration: none; display: inline-flex; align-items: center; }
.xs-thu-tab.on, .xs-thu-tab.active { color: #e65000; border-bottom-color: #e65000; font-weight: bold; }
.xs-thu-tab:hover:not(.on):not(.active) { background: #fafafa; }

/* ══ AZ24 STAT TABLE OVERRIDE ══ */
.kqxs-table{width:100%;border-collapse:collapse;background:#fff;font-size:13px}
.kqxs-table th{background:#e65000;color:#fff;padding:9px 10px;text-align:center;font-size:13px;font-weight:700;border:1px solid #c85000}
.kqxs-table th h3{margin:0;font-size:13px;font-weight:700;color:#fff}
.kqxs-table td{border:1px solid #e8e8e8;padding:7px 10px;text-align:center;vertical-align:middle;font-size:13px;color:#333;line-height:1.5}
.kqxs-table tbody tr:nth-child(even) td{background:#fff8f0}
.kqxs-table tbody tr:nth-child(odd) td{background:#fff}
.kqxs-table td strong{display:block;font-size:16px;font-weight:700;color:#c8001e;margin-bottom:2px}
.kqxs-table-wrapper{margin:0 0 14px;overflow-x:auto;-webkit-overflow-scrolling:touch}

/* ══ LKH (lkh-*) TABLE OVERRIDE - az24 stat style ══ */
.lkh-table-wrap{overflow-x:auto;-webkit-overflow-scrolling:touch;margin-bottom:14px}
.lkh-logan-tbl{width:100%;border-collapse:collapse;font-size:13px;background:#fff}
.lkh-logan-tbl th{background:#e65000;color:#fff;padding:8px 10px;text-align:center;font-weight:700;border:1px solid #c85000}
.lkh-logan-tbl td{border:1px solid #eee;padding:7px 10px;text-align:center}
.lkh-logan-tbl tbody tr:nth-child(odd) td{background:#fff}
.lkh-logan-tbl tbody tr:nth-child(even) td{background:#fff8f0}
.lkh-logan-tbl td:first-child{font-size:16px;font-weight:700;color:#c8001e}
.lkh-logan-tbl td strong{color:#c8001e;font-size:16px}
.sr-link-ext {
    display: block !important;
    padding: 4px 0 4px 10px;
    color: #0000FF;
    font-size: 16px;
    text-decoration: none;
    border-bottom: 1px solid #f0eeee;
    width: 100%;
    box-sizing: border-box;
    white-space: normal;
    word-break: break-word;
}
.sr-link-ext:hover { color: #e74c3c; }
.sr-list {
    display: flex !important;
    flex-direction: column !important;
}

/* ============================================================
   THEME-COMPAT — CSS cho các class mà class-kqxs-ext-stats.php
   (kiểu rongbk666) dùng: kqh, dtabs, kq-tbl, gl, mn-tbl, dd-tbl...
   Trên rongbk666 các class này nằm trong theme; ở đây đưa vào
   plugin để soicaulo247.me không phụ thuộc theme.
   ============================================================ */
.kqxs-result-section{background:#fff;border:1px solid #e8e8e8;border-radius:6px;overflow:hidden;margin:0 0 14px;font-family:Arial,Helvetica,sans-serif;color:#333}
.kqxs-result-section .kqh{background:#c8001e;color:#fff;text-align:center;padding:10px 12px}
.kqxs-result-section .kqh.orange{background:#e65000}
.kqxs-result-section .kqh.purple{background:#4a148c}
.kqh .t1{font-size:15px;font-weight:700;line-height:1.3}
.kqh .t2{font-size:12px;margin-top:3px;opacity:.95}
.kqh .t2 a,.kqh .t2 .sep{color:#ffe0c0;text-decoration:none;font-weight:400}
.kqh .t2 a:hover{text-decoration:underline}
.dtabs{display:flex;overflow-x:auto;background:#fff;border-bottom:1px solid #e8e8e8;scrollbar-width:none}
.dtabs::-webkit-scrollbar{display:none}
.dtab{flex:0 0 auto;padding:8px 13px;font-size:13px;font-weight:700;color:#555;text-decoration:none;border-bottom:2px solid transparent;white-space:nowrap}
.dtab:hover{background:#fafafa}
.dtab.on{color:#c8001e;border-bottom-color:#c8001e}
/* bảng 1 tỉnh / XSMB */
.kq-tbl{width:100%;border-collapse:collapse;background:#fff}
.kq-tbl tr{border-bottom:1px solid #ececec}
.kq-tbl tr:last-child{border-bottom:none}
.kq-tbl td.gl,.mn-tbl td.gl2{width:34px;min-width:34px;color:#888;font-size:12px;font-weight:700;padding:0 4px 0 8px;text-align:left;white-space:nowrap;border-right:1px solid #ececec;vertical-align:middle;background:#fff}
.kq-tbl td.db-td{font-size:28px;font-weight:700;color:#c8001e;letter-spacing:3px;text-align:center;padding:8px 5px}
.kq-tbl td.g1-td{font-size:18px;font-weight:700;color:#333;letter-spacing:2px;text-align:center;padding:7px 5px}
.g2-inner,.g3-inner,.g4-inner,.g5-inner,.g6-inner,.g7-inner{display:flex;width:100%}
.gcell,.g2-inner .cell{flex:1 1 0;min-width:0;text-align:center;font-weight:700;color:#333;border-left:1px solid #ececec;padding:6px 2px;font-size:16px}
.gcell:first-child,.g2-inner .cell:first-child{border-left:none}
.g2-inner .cell{font-size:18px}
.g2-inner .cell.empty{color:transparent}
.g3-inner .gcell,.g5-inner .gcell{font-size:16px}
.g4-inner .gcell,.g6-inner .gcell{font-size:16px}
.g7-inner .gcell{font-size:20px;color:#c8001e}
/* bảng nhiều đài MN/MT */
.mn-tbl{width:100%;border-collapse:collapse;background:#fff}
.mn-tbl thead th{padding:7px 5px;font-size:13px;font-weight:700;text-align:center;border-bottom:2px solid #e8e8e8;background:#fff}
.mn-tbl thead th a{color:#1a56a0;text-decoration:underline}
.mn-tbl thead th.glh{width:34px}
.mn-tbl td{border-bottom:1px solid #f0f0f0;padding:5px;text-align:center;vertical-align:middle;font-size:14px}
.mn-tbl tr:last-child td{border-bottom:none}
.mn-tbl td.gl2{background:#fafafa;text-align:center;padding:5px 2px}
.mn-tbl tr.row-db td{background:#fff8f0}
.mn-tbl tr.row-db td.gl2{color:#c8001e}
.mn-tbl .n-g8{font-size:22px;font-weight:700;color:#c8001e;line-height:1.5}
.mn-tbl .n-db{font-size:20px;font-weight:700;color:#c8001e;letter-spacing:1px}
.mn-tbl .n-g7,.mn-tbl .n-g5,.mn-tbl .n-g2m{font-size:14px;font-weight:700;color:#333}
.mn-tbl .n-g1m{font-size:15px;font-weight:700;color:#333}
.mn-tbl .n-g3{font-size:13px;color:#333;line-height:1.9}
/* bảng đầu đuôi MB / 1 tỉnh */
.dd-wrap{display:grid;grid-template-columns:1fr 1fr;background:#fff;border:1px solid #e8e8e8;border-radius:6px;overflow:hidden;margin:0 0 14px}
.dd-tbl{width:100%;border-collapse:collapse}
.dd-tbl.left{border-right:2px solid #ddd}
.dd-tbl th{background:#fff;color:#555;font-size:13px;font-weight:700;padding:7px 10px;border-bottom:1px solid #ddd;text-align:left}
.dd-tbl th.tr{text-align:right}
.dd-tbl td{border-bottom:1px solid #f2f2f2;padding:5px 10px;font-size:13px}
.dd-tbl tr:last-child td{border-bottom:none}
.dd-tbl.left td.idx{color:#c8001e;font-weight:700;width:28px;text-align:left}
.dd-tbl.left td.vals{text-align:left;color:#333}
.dd-tbl.right td.vals{text-align:right;color:#333}
.dd-tbl.right td.idx{color:#c8001e;font-weight:700;width:28px;text-align:right}
.dd-tbl .hot,.mn-dd-tbl .hot{color:#c8001e;font-weight:700}
/* bảng đầu MN/MT */
.mn-dd-tbl{width:100%;border-collapse:collapse;background:#fff;border:1px solid #e8e8e8;margin:0 0 14px}
.mn-dd-tbl th{color:#555;font-size:13px;font-weight:700;padding:7px 8px;border-bottom:1px solid #ddd;text-align:center}
.mn-dd-tbl th.didx{text-align:left;padding-left:12px}
.mn-dd-tbl td{border-bottom:1px solid #f2f2f2;padding:5px 8px;font-size:13px;text-align:center}
.mn-dd-tbl tr:last-child td{border-bottom:none}
.mn-dd-tbl td.didx{color:#c8001e;font-weight:700;background:#fafafa;border-right:1px solid #ececec;width:36px}
.mn-dd-tbl td.dnums{text-align:center}
.mn-dd-tbl th,.mn-dd-tbl td{border-left:1px solid #ececec}
.mn-dd-tbl th:first-child,.mn-dd-tbl td:first-child{border-left:none}
.mn-dd-tbl th{border-bottom:1px solid #ddd}
@media(max-width:480px){.kq-tbl td.db-td{font-size:22px;letter-spacing:2px}.g7-inner .gcell{font-size:18px}.gcell{font-size:14px}.dd-wrap{grid-template-columns:1fr}.dd-tbl.left{border-right:none}}

/* ============================================================
   THEME-COMPAT 2 — tab thống kê, tiêu đề mục, bảng lkh-*, menu
   (các class nằm trong theme của rongbk666, đưa vào plugin)
   ============================================================ */
.xs-stat-tabs{display:flex;flex-wrap:wrap;gap:0;background:#fff;border-bottom:2px solid #c8001e;margin:0 0 8px}
.xs-stat-tab{display:inline-block;padding:8px 14px;font-size:13px;font-weight:700;color:#555;background:#f3f3f3;text-decoration:none;border:1px solid #e3e3e3;border-bottom:none;margin:0 2px -1px 0;border-radius:4px 4px 0 0}
.xs-stat-tab:hover{background:#fff3f3;color:#c8001e}
.xs-stat-tab.on{background:#c8001e;color:#fff;border-color:#c8001e}
.lkh-sec-head{background:#c8001e;color:#fff;font-size:14px;font-weight:700;padding:9px 12px;margin:10px 0 0;line-height:1.35}
.lkh-days-select{display:flex;flex-wrap:wrap;align-items:center;gap:4px;background:#fffbea;border:1px solid #f0e2a8;padding:7px 10px;margin:8px 0;font-size:13px;color:#444}
.lkh-days-select a{text-decoration:none}
.lkh-view-btn{background:#c8001e;color:#fff;border:none;border-radius:3px;padding:5px 12px;font-size:12px;font-weight:700;cursor:pointer;margin-left:6px}
.lkh-view-btn:hover{background:#a50018}
.lkh-tinh-tags{display:flex;flex-wrap:wrap;align-items:center;gap:6px;margin:8px 0;font-size:13px;color:#444}
.lkh-tinh-tag{display:inline-block;padding:3px 10px;background:#f3f3f3;border:1px solid #e0e0e0;border-radius:14px;color:#1a56a0;text-decoration:none;font-size:12px}
.lkh-tinh-tag:hover{background:#c8001e;color:#fff;border-color:#c8001e}
.lkh-db-tbl,.lkh-cham-tbl{width:100%;border-collapse:collapse;background:#fff;font-size:13px}
.lkh-db-tbl th,.lkh-cham-tbl th{background:#e65000;color:#fff;padding:8px 10px;text-align:center;font-weight:700;border:1px solid #c85000}
.lkh-db-tbl td,.lkh-cham-tbl td{border:1px solid #eee;padding:7px 10px;text-align:center}
.lkh-db-tbl tbody tr:nth-child(even) td,.lkh-cham-tbl tbody tr:nth-child(even) td{background:#fff8f0}
.lkh-db-tbl .hi{color:#c8001e;font-weight:700}
.lkh-tansuat-num{display:block;font-size:15px;font-weight:700;color:#c8001e}
.lkh-tansuat-cnt{display:block;font-size:11px;color:#777}
.xs-xem-them-btn{display:block;text-align:center;background:#f3f3f3;border:1px solid #e0e0e0;color:#c8001e;font-weight:700;font-size:12px;padding:8px;text-decoration:none;margin:6px 0 10px}
.xs-xem-them-btn:hover{background:#c8001e;color:#fff}
.giai-db{color:#c8001e;font-weight:700}
@media(max-width:480px){.xs-stat-tab{padding:7px 9px;font-size:12px}}