/*
Theme Name: lotto
Theme URI: http://tungweb.io.vn
Description: Flatsome Child Theme for Lotto 
Author: Thanh Tung
Author URI: http://tungweb.io.vn
Template: flatsome
Version: 2.4.2
Text Domain: lotto
*/

/* ==========================================================================
   Lotto 535 Hub - Core Stylesheet
   ========================================================================== */

:root {
  --ink: #064e3b;
  --blue: #059669;
  --line: #bbf7d0;
  --muted: #f0fdf4;
  --gold: #ffc700;
  --pink: #ff3366;
}

body {
  color: var(--ink);
  background: #f5f8ff;
  font-family: 'Roboto', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  font-size: 14px;
}

/* --------------------------------------------------
   Flatsome Header Customization (controlled by Flatsome)
   -------------------------------------------------- */
/* Header Main Navigation Spacing & Style */
.header-nav.header-nav-main {
  margin-left: 24px;
}

.header-nav.header-nav-main > li {
  margin: 0 16px !important;
}

.header-nav.header-nav-main > li > a {
  padding: 10px 4px !important;
  letter-spacing: 0.3px;
  transition: color 0.2s ease, opacity 0.2s ease;
}

.header-nav > li > a {
  transition: color 0.2s ease, opacity 0.2s ease;
}

.header-nav > li > a:hover {
  color: #059669 !important;
  background: transparent !important;
}

.header-nav > li.menu-item.current-menu-item > a,
.header-nav > li.menu-item.active > a {
  color: #059669 !important;
  font-weight: 700 !important;
  background: transparent !important;
  box-shadow: none !important;
  border: none !important;
}

/* Brand balls icon in Header / Footer */
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  white-space: nowrap;
  text-decoration: none;
  color: #fff;
}
.brand strong {
  font-size: 20px;
  letter-spacing: -0.3px;
  font-weight: 900;
}
.brand em {
  font-style: normal;
  color: #ffcc00;
}
.brand small {
  display: block;
  font-size: 11px;
  color: #c8ddff;
  font-weight: 400;
  margin-top: 2px;
}

.brand-balls {
  width: 42px;
  height: 40px;
  position: relative;
  display: inline-block;
  flex-shrink: 0;
}
.brand-balls i {
  position: absolute;
  border-radius: 50%;
  width: 22px;
  height: 22px;
  background: radial-gradient(circle at 35% 20%, white, #72d3ff 35%, #0085db 70%);
  top: 1px;
  left: 12px;
  box-shadow: inset -2px -2px 3px rgba(0, 57, 120, 0.4);
}
.brand-balls i:nth-child(2) {
  top: 16px;
  left: 0;
  background: radial-gradient(circle at 35% 20%, #fff9ad, #ffcc00 40%, #f69500 75%);
}
.brand-balls i:nth-child(3) {
  top: 16px;
  left: 24px;
  background: radial-gradient(circle at 35% 20%, #ffdfdf, #fa314a 40%, #b00029 75%);
}

/* --------------------------------------------------
   Lottery Balls
   -------------------------------------------------- */
.ball {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  flex-shrink: 0;
  border-radius: 50%;
  width: 26px;
  height: 26px;
  font-weight: 700;
  color: #071b38;
  background: linear-gradient(180deg, #ffffff 0%, #edf8ff 100%);
  border: 2px solid #51b9e9;
  box-shadow: 0 2px 0 #1682b9;
  line-height: 1;
  font-family: Arial, sans-serif;
  font-variant-numeric: tabular-nums;
  text-shadow: none;
}

.ball.gold {
  background: linear-gradient(180deg, #fffbe3, #ffe58a);
  border-color: #efb817;
  box-shadow: 0 2px 0 #c88b00;
  margin-left: 5px;
}

.ball.pink {
  background: linear-gradient(180deg, #fff, #fff0f3);
  border-color: #f3a1b2;
  box-shadow: 0 1px 0 #dc7890;
}

.ball.matched {
  background: linear-gradient(180deg, #e3f5ff, #8ad4ff);
  border-color: #0082e6;
  color: #003666;
  box-shadow: 0 2px 0 #005fad;
}

.ball.unmatched {
  border-color: #ced8e6;
  background: #fff;
  color: #7b899d;
  box-shadow: none;
}

/* --------------------------------------------------
   Hero Section & Elements
   -------------------------------------------------- */
.lotto-hero {
  color: #ffffff;
  background: linear-gradient(135deg, rgba(2, 32, 21, 0.95), rgba(6, 78, 59, 0.92)), url('assets/images/hero-bg.png') center 57%/cover no-repeat;
  overflow: hidden;
  border-radius: 0;
  padding: 24px 0 30px;
}

.hero-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 25px;
  width: 100%;
}

.hero-main h1 {
  font-size: 34px;
  font-weight: 900;
  letter-spacing: -0.4px;
  color: #ffffff;
  margin: 0 0 6px;
  line-height: 1.2;
}

.hero-main p {
  font-size: 15px;
  color: #d1fae5;
  margin: 0 0 18px;
}

.hero-draw {
  display: flex;
  align-items: center;
  gap: 25px;
  margin-top: 14px;
}

.game-badge {
  flex: 0 0 145px;
  min-height: 100px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 12px 18px;
  border: 1px solid rgba(134, 239, 172, 0.45);
  border-radius: 16px;
  background: linear-gradient(145deg, rgba(6, 78, 59, 0.85), rgba(2, 36, 22, 0.75));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.game-badge-label {
  color: #a7f3d0;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 4px;
  padding-left: 4px;
}

.game-badge strong {
  color: #fff;
  font-size: 37px;
  line-height: 1.15;
  font-weight: 900;
  letter-spacing: -1px;
}

.game-badge strong span {
  color: #ffd45a;
  padding: 0 3px;
  font-weight: 500;
}

.game-badge small {
  color: #a7f3d0;
  font-size: 9px;
  letter-spacing: 1px;
  margin-top: 5px;
}

.draw-date {
  border: 1px solid #6ee7b7;
  border-radius: 30px;
  text-align: center;
  padding: 6px 14px;
  font-weight: 600;
  background: rgba(4, 120, 87, 0.65);
  width: max-content;
  margin-bottom: 12px;
  font-size: 13px;
  color: #ecfdf5;
}

.hero-numbers {
  display: flex;
  align-items: center;
  gap: 8px;
}

.hero-numbers .ball {
  width: 58px;
  height: 58px;
  font-size: 30px;
  border-width: 3px;
  box-shadow: 0 3px 0 #1682b9;
}

.hero-numbers .gold {
  margin-left: 8px;
  border-color: #efb817;
  box-shadow: 0 3px 0 #c88b00;
}

/* Jackpot Badge */
.jackpot {
  min-width: 310px;
  text-align: center;
  filter: drop-shadow(0 0 16px rgba(255, 179, 24, 0.5));
  padding-top: 15px;
}

.crown {
  font-size: 58px;
  color: #ffe85c;
  height: 48px;
  line-height: 1;
  text-shadow: 0 0 12px #ff9b00;
}

.jackpot-label {
  background: linear-gradient(#ff511b, #ba0600);
  font-size: 24px;
  font-weight: 800;
  color: #ffffff;
  border: 2px solid #ffce5a;
  border-bottom: 0;
  border-radius: 20px 20px 0 0;
  padding: 8px 20px 4px;
  margin: 0 22px;
  letter-spacing: 0.5px;
}

.jackpot > strong {
  display: block;
  font-size: 32px;
  letter-spacing: -1px;
  color: #c90900;
  background: linear-gradient(#fff9b9, #ffd65f);
  border: 2px solid #ffe090;
  border-radius: 14px;
  padding: 8px 10px;
  text-shadow: 1px 1px #fff;
  font-weight: 900;
}

.jackpot small {
  font-size: 24px;
}

.podium {
  height: 14px;
  border-radius: 50%;
  margin: 14px 0 -2px;
  background: linear-gradient(#ffdf83, #ed82ff 40%, #2914ba 60%);
  box-shadow: 0 7px 0 #2b057f, 0 9px 0 #b567e1, 0 0 22px #ffc745;
}

/* --------------------------------------------------
   Shortcuts Bar
   -------------------------------------------------- */
.shortcuts {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  border: 1px solid var(--line);
  background: linear-gradient(120deg, white, #f4f7fe);
  border-radius: 15px;
  padding: 12px 0;
  margin-bottom: 18px;
  box-shadow: 0 3px 8px rgba(25, 62, 124, 0.04);
}

.shortcuts > a,
.shortcuts > button {
  display: flex;
  align-items: center;
  flex-direction: column;
  border-right: 1px solid var(--line);
  gap: 4px;
  text-align: center;
  padding: 4px 6px;
  text-decoration: none;
  background: none;
  border-top: 0;
  border-left: 0;
  border-bottom: 0;
  cursor: pointer;
  color: var(--ink);
  transition: transform 0.2s;
}

.shortcuts > :last-child {
  border-right: 0;
}

.shortcuts > a:hover,
.shortcuts > button:hover {
  transform: translateY(-2px);
}

.shortcuts span {
  font-size: 28px;
  color: var(--blue);
  height: 34px;
  line-height: 1;
}

.shortcuts strong {
  font-size: 14px;
  font-weight: 700;
}

.shortcuts small {
  font-size: 11px;
  color: #6a7d9c;
}

/* --------------------------------------------------
   Cards & Content Elements
   -------------------------------------------------- */
.card {
  padding: 10px 15px;
  border: 1px solid #bfd2fc;
  border-radius: 15px;
  background: linear-gradient(120deg, #fff, #f4f8ff);
  box-shadow: 0 2px 4px rgba(24, 62, 124, 0.04);
  min-width: 0;
  margin-bottom: 16px;
}

.section-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 10px;
}

.section-heading h2 {
  font-size: 20px;
  margin: 0;
  line-height: 1.3;
  letter-spacing: -0.4px;
  color: var(--ink);
}

.section-heading h2 span {
  color: #0067ff;
  font-size: 24px;
  vertical-align: -2px;
  margin-right: 6px;
}

.section-heading h2 small {
  font-size: 13px;
  font-weight: 400;
  color: #637599;
}

.text-link {
  font-size: 12px;
  color: #004cff;
  white-space: nowrap;
  padding: 2px 4px;
  text-decoration: none;
  background: none;
  border: 0;
  cursor: pointer;
  font-weight: 600;
}

.text-link:hover {
  text-decoration: underline;
}

/* Tables */
.table-scroll {
  overflow-x: auto;
}

table.results-table {
  border-collapse: collapse;
  width: 100%;
  white-space: nowrap;
  font-size: 14px;
  margin: 0;
}

table.results-table th {
  background: linear-gradient(180deg, #f0fdf4 0%, #dcfce7 100%) !important;
  font-size: 13px;
  font-weight: 700;
  padding: 12px 10px;
  color: #064e3b !important;
  border: 0;
  border-bottom: 2px solid #86efac !important;
  vertical-align: middle !important;
  letter-spacing: 0.3px;
}

table.results-table th:first-child {
  border-radius: 9px 0 0 9px;
}

table.results-table th:last-child {
  border-radius: 0 9px 9px 0;
}

table.results-table td {
  padding: 11px 10px !important;
  border-bottom: 1px solid #e2f4e9 !important;
  border-top: 0;
  vertical-align: middle !important;
  font-size: 14px !important;
  line-height: 1.4;
  color: #374151;
}

table.results-table tr:hover td {
  background: #f0fdf4 !important;
}

table.results-table tr:last-child td {
  border-bottom: 0;
}

table.results-table td:first-child {
  font-weight: 700;
  color: #059669 !important;
}

table.results-table td:last-child {
  font-weight: 800;
  color: #d80000;
  font-size: 15px !important;
}

table.results-table td button.text-link {
  font-size: 14px !important;
  font-weight: 700 !important;
  color: #059669 !important;
  background: none !important;
  border: none !important;
  padding: 0 !important;
  margin: 0 !important;
  cursor: pointer !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  vertical-align: middle !important;
  line-height: 1 !important;
  box-shadow: none !important;
  text-decoration: none !important;
}

table.results-table td button.text-link:hover {
  text-decoration: underline !important;
  color: #047857 !important;
}

table.results-table .result-balls {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  vertical-align: middle !important;
  gap: 6px !important;
  line-height: 1 !important;
}

table.results-table .result-balls .ball {
  width: 32px !important;
  height: 32px !important;
  font-size: 14px !important;
  font-weight: 700 !important;
  border-radius: 50% !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  vertical-align: middle !important;
  line-height: 1 !important;
  margin: 0 !important;
  background: linear-gradient(180deg, #ffffff 0%, #edf8ff 100%) !important;
  border: 2px solid #51b9e9 !important;
  box-shadow: 0 2px 0 #1682b9 !important;
  color: #071b38 !important;
}

table.results-table .result-balls .ball.gold {
  background: linear-gradient(180deg, #fffbe3, #ffe58a) !important;
  border-color: #efb817 !important;
  box-shadow: 0 2px 0 #c88b00 !important;
  color: #78350f !important;
  margin-left: 6px !important;
}

/* Number Highlighting Interaction (xsmn.mobi style) */
.results-table .result-balls .ball,
.history-row .result-balls .ball,
.hero-numbers .ball,
.lotto-live-balls .ball {
  cursor: pointer !important;
  transition: all 0.18s cubic-bezier(0.34, 1.56, 0.64, 1) !important;
}

.results-table .result-balls .ball:hover,
.history-row .result-balls .ball:hover,
.hero-numbers .ball:hover,
.lotto-live-balls .ball:hover {
  transform: scale(1.12) !important;
  box-shadow: 0 0 8px rgba(0, 102, 255, 0.4) !important;
}

/* Any highlighted ball becomes vibrant red-orange with solid white text */
.ball.ball-highlight,
.result-balls .ball.ball-highlight,
.result-balls .ball.gold.ball-highlight,
table.results-table .result-balls .ball.ball-highlight,
table.results-table .result-balls .ball.gold.ball-highlight,
.history-row .result-balls .ball.ball-highlight,
.history-row .result-balls .ball.gold.ball-highlight,
.hero-numbers .ball.ball-highlight,
.hero-numbers .ball.gold.ball-highlight,
.lotto-live-balls .ball.ball-highlight,
.lotto-live-balls .ball.gold.ball-highlight {
  opacity: 1 !important;
  filter: none !important;
  background: #d84315 !important;
  border: 2px solid #bf360c !important;
  color: #ffffff !important;
  box-shadow: 0 2px 5px rgba(191, 54, 12, 0.4) !important;
  font-weight: 800 !important;
  transform: scale(1.08) !important;
  z-index: 5 !important;
}

/* --------------------------------------------------
   01-35 Number Selector Card (xsmn.mobi style)
   -------------------------------------------------- */
.lotto-stats-selector-card {
  position: relative;
  background: #f1f8f3;
  border: 1px solid #d2e7d7;
  border-radius: 12px;
  padding: 36px 16px 14px;
  margin: 26px 0 20px;
  text-align: center;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.03);
}

.lotto-stats-header-ribbon {
  position: absolute;
  top: -1px;
  left: 50%;
  transform: translateX(-50%);
  background: linear-gradient(180deg, #247a44 0%, #1a6536 100%);
  color: #ffffff;
  font-weight: 700;
  font-size: 14px;
  line-height: 1.4;
  padding: 5px 36px 6px;
  clip-path: polygon(0 0, 100% 0, calc(100% - 15px) 100%, 15px 100%);
  letter-spacing: 0.3px;
  white-space: nowrap;
  box-shadow: 0 3px 8px rgba(26, 101, 54, 0.25);
  z-index: 2;
}

.lotto-num-rows-wrap {
  display: flex;
  flex-direction: column;
  gap: 7px;
  align-items: center;
  justify-content: center;
  margin-top: 16px;
  margin-bottom: 8px;
}

.lotto-num-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: center;
  align-items: center;
  max-width: 100%;
}

.lotto-num-btn {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 1px solid #c9d8cc;
  background: #ffffff;
  color: #1e293b;
  font-size: 13px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.18s cubic-bezier(0.34, 1.56, 0.64, 1);
  padding: 0;
  margin: 0 !important;
  line-height: 1;
  box-sizing: border-box;
  user-select: none;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.lotto-num-btn:hover {
  background: #eaf5ed;
  border-color: #247a44;
  color: #1a6536;
  transform: translateY(-2px);
  box-shadow: 0 3px 8px rgba(36, 122, 68, 0.2);
}

.lotto-num-btn.active {
  background: #d84315 !important;
  border-color: #bf360c !important;
  color: #ffffff !important;
  transform: translateY(-2px) scale(1.1) !important;
  box-shadow: 0 4px 10px rgba(191, 54, 12, 0.45) !important;
}

.lotto-stats-selector-footer {
  margin-top: 8px;
  font-size: 13px;
  color: #b45309;
  font-style: italic;
  text-align: center;
}



/* Frequency Chart Bar Highlight */
#frequency-chart .bar {
  cursor: pointer;
  transition: all 0.2s ease;
}

#frequency-chart .bar.bar-highlight {
  background: linear-gradient(180deg, #f59e0b 0%, #d97706 100%) !important;
  box-shadow: 0 0 14px rgba(245, 158, 11, 0.8) !important;
  filter: brightness(1.15);
  transform: scaleY(1.03);
}

#frequency-chart .bar.bar-highlight span {
  color: #d97706 !important;
  font-weight: 800 !important;
}

/* Ranking Row & Overdue Item Highlights */
.ranking tbody tr {
  transition: background 0.2s ease;
}

.ranking tbody tr.row-highlight {
  background: #fffbeb !important;
  box-shadow: inset 3px 0 0 #f59e0b !important;
}

.ranking tbody tr.row-highlight .ball {
  background: linear-gradient(180deg, #fffbeb 0%, #ffd026 100%) !important;
  border-color: #f59e0b !important;
  color: #78350f !important;
  box-shadow: 0 0 10px rgba(245, 158, 11, 0.8) !important;
  transform: scale(1.1);
}

.overdue-item {
  transition: all 0.2s ease;
}

.overdue-item.item-highlight {
  background: #fffbeb !important;
  border-color: #f59e0b !important;
  box-shadow: 0 0 10px rgba(245, 158, 11, 0.4) !important;
  transform: scale(1.06);
}

.overdue-item.item-highlight .ball {
  background: linear-gradient(180deg, #fffbeb 0%, #ffd026 100%) !important;
  border-color: #f59e0b !important;
  color: #78350f !important;
  box-shadow: 0 0 10px rgba(245, 158, 11, 0.8) !important;
}

/* Compact Load More Button */
.results-load-more-wrap {
  text-align: center;
  margin-top: 16px;
}

.lotto-load-more-btn {
  background: linear-gradient(135deg, #059669 0%, #047857 100%) !important;
  color: #ffffff !important;
  border: none !important;
  border-radius: 20px !important;
  padding: 7px 22px !important;
  font-weight: 500 !important;
  font-size: 13px !important;
  line-height: 1.4 !important;
  cursor: pointer !important;
  box-shadow: 0 2px 8px rgba(5, 150, 105, 0.25) !important;
  transition: all 0.25s ease !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  text-decoration: none !important;
}

.lotto-load-more-btn:hover {
  background: linear-gradient(135deg, #10b981 0%, #059669 100%) !important;
  box-shadow: 0 4px 12px rgba(5, 150, 105, 0.35) !important;
  transform: translateY(-1px);
  color: #ffffff !important;
}

.lotto-load-more-btn:active {
  transform: translateY(0);
  box-shadow: 0 2px 6px rgba(5, 150, 105, 0.2) !important;
}

/* Frequency Chart Modern Segmented Tabs */
.tabs {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  background: #f0fdf4 !important;
  border: 1px solid #bbf7d0 !important;
  border-radius: 24px !important;
  padding: 3px !important;
  gap: 3px !important;
  box-shadow: inset 0 1px 2px rgba(6, 78, 59, 0.04) !important;
  white-space: nowrap !important;
  box-sizing: border-box !important;
  line-height: 1 !important;
  margin: 0 !important;
}

.tabs button {
  margin: 0 !important;
  padding: 6px 16px !important;
  border: none !important;
  border-radius: 20px !important;
  background: transparent !important;
  font-weight: 600 !important;
  font-size: 13px !important;
  line-height: 1 !important;
  cursor: pointer !important;
  color: #064e3b !important;
  transition: all 0.2s ease !important;
  outline: none !important;
  user-select: none !important;
  text-transform: none !important;
  letter-spacing: 0.2px !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  vertical-align: middle !important;
  box-sizing: border-box !important;
  height: auto !important;
}

.tabs button:hover:not(.selected) {
  color: #059669 !important;
  background: rgba(5, 150, 105, 0.08) !important;
}

.tabs button.selected {
  background: linear-gradient(135deg, #059669 0%, #047857 100%) !important;
  color: #ffffff !important;
  box-shadow: 0 2px 7px rgba(5, 150, 105, 0.32) !important;
}

.chart-wrap {
  display: flex;
  gap: 10px;
  margin: 24px 0 16px;
  padding-right: 4px;
}

.axis {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  font-size: 11px;
  text-align: right;
  width: 28px;
  height: 120px;
  margin-top: -6px;
  color: #7b8ea8;
}

.chart {
  display: flex;
  gap: 12px;
  align-items: flex-end;
  height: 120px;
  flex: 1;
  border-left: 1px solid #b5c9ef;
  border-bottom: 1px solid #b5c9ef;
  background: repeating-linear-gradient(to top, transparent 0, transparent calc(20% - 1px), #d8e4f7 calc(20% - 1px), #d8e4f7 20%);
  padding: 0 12px;
}

.bar {
  flex: 1;
  min-width: 0;
  height: var(--height);
  background: linear-gradient(110deg, #0099ff, #0067ff 60%, #003aef);
  border-radius: 4px 4px 0 0;
  position: relative;
  box-shadow: inset 1px 0 3px #8cceff;
  transition: height 0.3s;
}

.bar b {
  position: absolute;
  top: -22px;
  text-align: center;
  left: 0;
  right: 0;
  font-size: 15px;
  font-weight: 800;
  color: #073582;
}

.bar span {
  position: absolute;
  bottom: -22px;
  text-align: center;
  left: 0;
  right: 0;
  font-weight: 700;
  font-size: 13px;
  color: #1a396b;
}

/* Rankings (Hot & Cold) */
.ranking {
  font-size: 13px;
  width: 100%;
  border-collapse: collapse;
}

.ranking th {
  font-size: 12px;
  padding: 5px;
  background: #eef4fc;
  color: #4a638b;
  border: 0;
}

.ranking td {
  padding: 4px 6px;
  border-bottom: 1px solid #e1ecfa;
  vertical-align: middle;
}

.ranking tr:last-child td {
  border-bottom: 0;
}

.ranking td:nth-child(3) {
  width: 55%;
}

.meter-cell {
  display: flex;
  align-items: center;
  gap: 10px;
  justify-content: space-between;
}

.meter {
  height: 12px;
  flex: 1;
  background: #dce6f6;
  border-radius: 4px;
  overflow: hidden;
}

.meter i {
  display: block;
  height: 100%;
  background: linear-gradient(#ff8192, #ed273d);
  border-radius: 4px;
}

.cold .meter i {
  background: linear-gradient(#00a1ff, #004eff);
}

.meter-cell b {
  font-weight: 600;
  min-width: 42px;
  text-align: right;
  font-size: 12px;
}

.pink-text {
  color: #ff5377 !important;
}

/* Overdue numbers list */
.overdue-list {
  display: grid;
  grid-template-columns: repeat(10, 1fr);
  gap: 6px;
  margin-top: 8px;
}

.overdue-item {
  text-align: center;
  background: linear-gradient(white, #fbdce0);
  border: 1px solid #ffc3cc;
  border-radius: 9px;
  padding: 6px 0 8px;
}

.overdue-item .ball {
  background: linear-gradient(180deg, #fff, #fff0f3);
  border-color: #f3a1b2;
  box-shadow: 0 1px 0 #dc7890;
  width: 29px;
  height: 29px;
  font-size: 15px;
}

.overdue-item b {
  display: block;
  color: #ce0900;
  font-size: 12px;
  margin-top: 5px;
  font-weight: 700;
}

/* --------------------------------------------------
   Sidebar Widgets
   -------------------------------------------------- */
.schedule-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 15px;
  margin-top: 10px;
}

.times {
  border-radius: 10px;
  background: linear-gradient(180deg, #f0fdf4 0%, #dcfce7 100%);
  border: 1px solid #bbf7d0;
  flex: 1;
  overflow: hidden;
}

.times > div {
  padding: 8px 12px;
  white-space: nowrap;
  font-size: 18px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.times > div + div {
  border-top: 1px solid #dcfce7;
}

.times b {
  font-size: 15px;
  color: #064e3b;
}

.times strong {
  font-size: 22px;
  color: #059669;
}

.calendar-art {
  width: 92px;
  background: #fff;
  border: 4px solid #ffb628;
  border-radius: 12px;
  transform: rotate(6deg);
  text-align: center;
  box-shadow: 3px 5px 0 #ef8e19, 5px 7px 8px rgba(140, 83, 6, 0.2);
  overflow: hidden;
}

.calendar-art div {
  background: #ef3f51;
  color: white;
  font-size: 10px;
  padding: 6px 2px;
  font-weight: bold;
  letter-spacing: 0.5px;
}

.calendar-art > strong {
  font-size: 38px;
  display: block;
  line-height: 1.1;
  color: #0755d1;
}

.calendar-art > span {
  font-size: 9px;
  font-weight: 700;
  display: block;
  padding: 3px;
  color: #333;
}

.center-text {
  text-align: center;
  font-size: 12px;
  color: #637599;
  margin-bottom: 10px;
}

.number-inputs {
  display: flex;
  gap: 6px;
  margin: 14px 0 14px;
}

.number-inputs input {
  width: 0;
  min-width: 0;
  flex: 1;
  height: 40px;
  border: 1px solid #b9cdf7;
  border-radius: 8px;
  text-align: center;
  background: #fff;
  color: var(--ink);
  font-weight: 700;
  font-size: 18px;
}

.primary-button {
  width: 100%;
  background: linear-gradient(110deg, #059669, #047857) !important;
  color: white !important;
  border: 0;
  border-radius: 10px;
  font-weight: 600;
  font-size: 15px;
  padding: 10px;
  cursor: pointer;
  box-shadow: 0 3px 8px rgba(5, 150, 105, 0.3) !important;
  transition: all 0.2s;
}

.primary-button:hover {
  filter: brightness(1.1);
  color: #fff !important;
  box-shadow: 0 4px 12px rgba(5, 150, 105, 0.45) !important;
}

#check-result {
  line-height: 1.6;
  font-size: 13px;
  background: #f0fdf4;
  padding: 10px;
  border-radius: 8px;
  margin-top: 12px;
  border-left: 3px solid #059669;
}

/* News List */
.news-item {
  display: flex;
  width: 100%;
  text-align: left;
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px solid #d6e2f6;
  background: none;
  border-top: 0;
  border-left: 0;
  border-right: 0;
  cursor: pointer;
  color: inherit;
  transition: background 0.2s;
  text-decoration: none !important;
}

.news-item:hover b {
  color: var(--blue) !important;
}

.news-item:last-child {
  border-bottom: 0;
  padding-bottom: 2px;
}

.news-item img {
  width: 88px;
  height: 62px;
  object-fit: cover;
  border: 1px solid #cad8f0;
  border-radius: 7px;
  flex-shrink: 0;
}

.news-item b {
  font-size: 13px;
  line-height: 1.35;
  display: block;
  color: var(--ink);
}

.news-item time {
  font-size: 11px;
  display: block;
  margin-top: 5px;
  color: #72849e;
}

/* --------------------------------------------------
   Promo Section & Benefits
   -------------------------------------------------- */
.promo {
  display: flex;
  align-items: center;
  gap: 30px;
  margin-top: 18px;
  margin-bottom: 18px;
  border-radius: 16px;
  padding: 16px 35px;
  min-height: 120px;
  overflow: hidden;
  color: white;
  background: linear-gradient(135deg, rgba(2, 32, 21, 0.95), rgba(6, 78, 59, 0.92)), url('assets/images/hero-bg.png') center 70%/cover no-repeat;
}

.promo .lotto-mark {
  display: flex;
  align-items: center;
  min-width: 158px;
}

.promo .ball {
  width: 76px;
  height: 76px;
  font-size: 40px;
  border-width: 5px;
  transform: rotate(-10deg);
}

.promo .ball.pink {
  margin-left: -20px;
  margin-top: 24px;
  transform: rotate(8deg);
}

.promo h2 {
  font-size: 22px;
  color: #fff;
  line-height: 1.3;
  margin: 0;
}

.promo ul {
  list-style: none;
  padding: 0;
  margin: 0;
  font-size: 13px;
  line-height: 2;
  white-space: nowrap;
}

.promo li:before {
  content: '✓';
  background: #00b69a;
  border-radius: 50%;
  padding: 2px 5px;
  margin-right: 10px;
  font-size: 11px;
  font-weight: bold;
}

.phone {
  align-self: flex-start;
  background: linear-gradient(#006cff, #072e9d);
  border: 5px solid #051630;
  border-radius: 22px;
  width: 155px;
  min-width: 155px;
  height: 160px;
  transform: rotate(10deg);
  margin-left: auto;
  text-align: center;
  box-shadow: 0 0 0 2px #aaa;
  padding: 4px 7px;
  box-sizing: border-box;
}

.phone > span {
  color: #051630;
  font-size: 10px;
  display: block;
}

.phone b {
  display: block;
  margin: 8px 0;
  font-size: 14px;
  color: #fff;
}

.phone small,
.phone > div {
  display: block;
  background: white;
  color: #032459;
  font-size: 10px;
  padding: 6px 1px;
}

.phone > div {
  margin-top: 6px;
  font-weight: bold;
  border-radius: 4px;
}

.benefits {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  padding: 16px 10px;
  background: rgba(255, 255, 255, 0.85);
  border-radius: 14px;
  margin-top: 16px;
  margin-bottom: 12px;
  box-shadow: 0 2px 6px #d8e5f6;
  border: 1px solid #d4e3f7;
}

.benefits > div {
  display: flex;
  align-items: center;
  justify-content: center;
  border-right: 1px solid var(--line);
  gap: 14px;
  padding: 0 10px;
}

.benefits > div:last-child {
  border-right: 0;
}

.benefits span {
  font-size: 32px;
  color: #008aff;
}

.benefits b {
  font-size: 14px;
  display: block;
  color: var(--ink);
}

.benefits small {
  display: block;
  font-size: 11px;
  color: #637599;
  margin-top: 3px;
}

.demo-note {
  font-size: 11px;
  color: #637599;
  text-align: center;
  margin: 12px 0 0;
}

/* --------------------------------------------------
   Footer UX Block
   -------------------------------------------------- */
.lotto-footer-block {
  background: linear-gradient(180deg, #071933 0%, #030d1d 100%) !important;
  color: #ffffff !important;
  border-top: 1px solid rgba(59, 130, 246, 0.25) !important;
  position: relative;
  overflow: hidden;
}

.lotto-footer-block::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(56, 189, 248, 0.6), transparent);
}

.lotto-footer-block p:has(.footer-logo-link),
.footer-col-brand > p:first-child,
.footer-col-brand > p:first-of-type {
  margin-bottom: 8px !important;
  margin-top: 0 !important;
  line-height: 1 !important;
  padding: 0 !important;
}

.footer-logo-link {
  display: inline-block;
  margin-bottom: 8px !important;
  margin-top: 0 !important;
  padding: 0 !important;
  line-height: 1 !important;
  transition: opacity 0.2s ease;
}

.footer-logo-link:hover {
  opacity: 0.9;
}

.footer-logo-img {
  max-height: 48px;
  width: auto;
  display: block;
  filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.3));
  margin: 0 !important;
}

.footer-col-brand p:empty {
  display: none !important;
  margin: 0 !important;
  padding: 0 !important;
}

.footer-brand-desc {
  font-size: 13px !important;
  color: #94a3b8 !important;
  line-height: 1.6 !important;
  margin: 0 0 14px !important;
  padding-top: 0 !important;
}

.footer-trust-badges {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.trust-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 11.5px;
  color: #cbd5e1;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  padding: 4px 10px;
  border-radius: 6px;
  width: fit-content;
}

.trust-badge .badge-icon {
  font-style: normal;
}

.footer-col-title {
  font-size: 14px !important;
  font-weight: 700 !important;
  color: #ffffff !important;
  text-transform: uppercase !important;
  letter-spacing: 0.6px !important;
  margin: 0 0 16px !important;
  position: relative;
  padding-bottom: 8px;
}

.footer-col-title::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 28px;
  height: 2px;
  background: #38bdf8;
  border-radius: 2px;
}

.footer-links-list {
  list-style: none !important;
  padding: 0 !important;
  margin: 0 !important;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.footer-links-list li {
  margin: 0 !important;
  padding: 0 !important;
  height: 25px !important;
  min-height: 25px !important;
  line-height: 25px !important;
  display: flex !important;
  align-items: center !important;
}

.lotto-footer-block button {
  text-transform: none !important;
  font-weight: 500 !important;
  letter-spacing: normal !important;
  box-shadow: none !important;
}

.footer-links-list a,
.footer-links-list button {
  display: inline-flex !important;
  align-items: center !important;
  gap: 6px !important;
  color: #94a3b8 !important;
  font-size: 13px !important;
  font-family: inherit !important;
  font-weight: 500 !important;
  line-height: 25px !important;
  height: 25px !important;
  min-height: 0 !important;
  max-height: 25px !important;
  text-decoration: none !important;
  text-transform: none !important;
  letter-spacing: normal !important;
  background: none !important;
  border: 0 !important;
  padding: 0 !important;
  margin: 0 !important;
  cursor: pointer !important;
  box-shadow: none !important;
  transition: all 0.2s ease !important;
}

.footer-links-list .link-arrow {
  color: #38bdf8;
  font-size: 14px;
  font-weight: 700;
  transition: transform 0.2s ease;
}

.footer-links-list a:hover,
.footer-links-list button:hover {
  color: #ffffff !important;
}

.footer-links-list a:hover .link-arrow,
.footer-links-list button:hover .link-arrow {
  transform: translateX(3px);
  color: #fbbf24;
}

.footer-contact-info {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 12px;
}

.footer-contact-info p {
  margin: 0 !important;
  font-size: 12.5px !important;
  color: #94a3b8 !important;
  line-height: 1.5 !important;
  display: flex;
  align-items: baseline;
  gap: 6px;
}

.footer-contact-info .contact-icon {
  font-size: 13px;
  flex-shrink: 0;
}

.footer-contact-info strong {
  color: #cbd5e1;
}

.footer-contact-info a {
  color: #38bdf8 !important;
  text-decoration: none !important;
}

.footer-contact-info a:hover {
  text-decoration: underline !important;
}

.footer-disclaimer-note {
  display: block;
  font-size: 11px !important;
  color: #64748b !important;
  line-height: 1.5 !important;
  font-style: italic;
}

.footer-separator {
  height: 1px;
  background: rgba(255, 255, 255, 0.08);
  margin: 28px 0 18px;
  width: 100%;
}

.footer-bottom-bar {
  display: flex !important;
  justify-content: space-between !important;
  align-items: center !important;
  flex-wrap: wrap !important;
  gap: 12px !important;
  font-size: 12px !important;
  color: #64748b !important;
  padding: 0 !important;
}

.footer-copyright {
  font-size: 12px;
  color: #94a3b8;
}

.footer-legal-links {
  display: flex !important;
  align-items: center !important;
  gap: 8px !important;
  flex-wrap: wrap !important;
  color: #475569 !important;
  font-size: 12.5px !important;
}

.footer-legal-links a,
.footer-legal-links button {
  background: none !important;
  border: 0 !important;
  color: #94a3b8 !important;
  font-size: 12.5px !important;
  font-weight: 500 !important;
  padding: 3px 6px !important;
  border-radius: 4px !important;
  cursor: pointer !important;
  text-decoration: none !important;
  transition: all 0.2s ease !important;
  line-height: 1.4 !important;
  display: inline-block !important;
}

.footer-legal-links a:hover,
.footer-legal-links a:focus,
.footer-legal-links button:hover,
.footer-legal-links button:focus {
  color: #ffffff !important;
  background: rgba(255, 255, 255, 0.08) !important;
  text-decoration: none !important;
}

.footer-legal-links .legal-sep,
.legal-sep {
  color: #475569 !important;
  font-size: 13px !important;
  user-select: none !important;
}

.footer-col {
  border-right: none !important;
  padding-right: 15px !important;
}

/* --------------------------------------------------
   Modal Dialog
   -------------------------------------------------- */
dialog#info-dialog {
  border: 1px solid #bfd2fc;
  border-radius: 16px;
  max-width: 520px;
  width: calc(100% - 32px);
  color: var(--ink);
  padding: 26px;
  box-shadow: 0 20px 80px rgba(0, 30, 76, 0.35);
  background: #ffffff;
}

dialog::backdrop {
  background: rgba(0, 27, 75, 0.5);
  backdrop-filter: blur(4px);
}

dialog h2 {
  margin: 0 0 15px;
  padding-right: 24px;
  font-size: 20px;
  color: #073582;
}

#dialog-content {
  line-height: 1.7;
  font-size: 13px;
  color: #384d6e;
}

.dialog-close {
  position: absolute;
  right: 14px;
  top: 10px;
  font-size: 28px;
  background: none;
  border: 0;
  cursor: pointer;
  color: #72849e;
  line-height: 1;
}

.dialog-close:hover {
  color: #ce0900;
}

/* --------------------------------------------------
   Subpages Specific Styles
   -------------------------------------------------- */
.page-hero {
  background: linear-gradient(135deg, #022015 0%, #064434 45%, #046347 80%, #057a55 100%) !important;
  color: white;
  padding: 24px 0 32px;
  border-bottom: 1px solid rgba(52, 211, 153, 0.3);
}

/* ==========================================================================
   Results Page Hero Redesign ([lotto_results_hero])
   ========================================================================== */
.lotto-results-hero-section {
  background: linear-gradient(135deg, #022015 0%, #064434 45%, #046347 80%, #057a55 100%) !important;
  color: #ffffff !important;
  position: relative !important;
  overflow: hidden !important;
  border-radius: 16px !important;
  border: 1px solid rgba(52, 211, 153, 0.3) !important;
  box-shadow: 0 10px 30px rgba(2, 32, 21, 0.35) !important;
}

.lotto-results-hero-section::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -10%;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(74, 222, 128, 0.18) 0%, transparent 70%);
  pointer-events: none;
  z-index: 0;
}

.lotto-results-hero-section::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(74, 222, 128, 0.6), transparent);
}

.results-hero-container {
  width: 100%;
  margin: 0 auto;
  padding: 30px 32px !important;
  position: relative;
  z-index: 1;
  box-sizing: border-box;
}

.results-hero-grid {
  display: grid;
  grid-template-columns: 1fr 360px;
  gap: 32px;
  align-items: center;
}

.results-hero-main {
  min-width: 0;
}

.results-hero-main .breadcrumb-nav {
  margin-bottom: 12px;
  font-size: 13px;
  color: #a7f3d0;
  display: flex;
  align-items: center;
  gap: 8px;
}

.results-hero-main .breadcrumb-nav a {
  color: #d1fae5;
  text-decoration: none;
  transition: color 0.2s ease;
}

.results-hero-main .breadcrumb-nav a:hover {
  color: #ffffff;
  text-decoration: underline;
}

.results-hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(134, 239, 172, 0.35);
  color: #ffd026;
  font-size: 11.5px;
  font-weight: 800;
  letter-spacing: 0.8px;
  padding: 4px 12px;
  border-radius: 20px;
  margin-bottom: 12px;
  text-transform: uppercase;
  backdrop-filter: blur(4px);
}

.results-hero-badge .badge-ping {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #22c55e;
  box-shadow: 0 0 8px #22c55e;
}

.results-hero-main h1 {
  font-size: 30px;
  font-weight: 900;
  color: #ffffff;
  margin: 0 0 10px;
  line-height: 1.25;
  letter-spacing: -0.5px;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.25);
}

.results-hero-main p {
  font-size: 14.5px;
  color: #d1fae5;
  line-height: 1.6;
  margin: 0 0 16px;
  max-width: 680px;
}

.results-hero-highlights {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.results-hero-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 600;
  color: #ecfdf5;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(134, 239, 172, 0.25);
  padding: 5px 12px;
  border-radius: 8px;
  backdrop-filter: blur(4px);
}

/* Right Glance Card */
.results-hero-glance {
  background: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(134, 239, 172, 0.25);
  border-radius: 16px;
  padding: 18px 20px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25);
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.glance-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  padding-bottom: 10px;
}

.glance-header-title {
  font-size: 13px;
  font-weight: 700;
  color: #ffffff;
  display: flex;
  align-items: center;
  gap: 6px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.glance-badge {
  background: #ef4444;
  color: #ffffff;
  font-size: 11px;
  font-weight: 800;
  padding: 2px 8px;
  border-radius: 6px;
  letter-spacing: 0.5px;
}

.glance-meta {
  font-size: 12.5px;
  color: #94a3b8;
  display: flex;
  justify-content: space-between;
}

.glance-meta strong {
  color: #e2e8f0;
}

.glance-balls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}

.glance-balls .glance-ball {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 800;
  background: linear-gradient(135deg, #ffffff 0%, #dbeafe 100%);
  color: #0f172a;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
}

.glance-balls .glance-ball.gold {
  background: linear-gradient(135deg, #fef08a 0%, #f59e0b 100%);
  color: #78350f;
  box-shadow: 0 0 10px rgba(245, 158, 11, 0.6);
}

.glance-jackpot-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: rgba(0, 0, 0, 0.25);
  padding: 8px 12px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.glance-jackpot-label {
  font-size: 11.5px;
  color: #94a3b8;
  font-weight: 600;
  text-transform: uppercase;
}

.glance-jackpot-value {
  font-size: 14px;
  font-weight: 800;
  color: #fde047;
}

/* Mobile Responsive: Hide Hero & Promo on Mobile & Tablet */
@media (max-width: 850px) {
  .lotto-results-hero-section,
  .promo {
    display: none !important;
  }
  .results-hero-grid {
    grid-template-columns: 1fr !important;
    gap: 16px !important;
  }
  .results-hero-container {
    padding: 20px 14px 22px !important;
  }
  .results-hero-main h1 {
    font-size: 22px !important;
  }
  .results-hero-main p {
    font-size: 13px !important;
    margin-bottom: 12px !important;
  }
  .results-hero-highlights {
    gap: 6px !important;
  }
  .results-hero-chip {
    font-size: 11px !important;
    padding: 4px 10px !important;
  }
  .results-hero-glance {
    padding: 14px 16px !important;
  }
  .glance-balls .glance-ball {
    width: 32px !important;
    height: 32px !important;
    font-size: 13px !important;
  }
}

.breadcrumb-nav {
  display: flex;
  gap: 8px;
  font-size: 12px;
  color: #d7e5ff;
  margin-bottom: 16px;
}

.breadcrumb-nav a {
  color: #d7e5ff;
  text-decoration: none;
}

.breadcrumb-nav a:hover {
  text-decoration: underline;
  color: #fff;
}

.eyebrow {
  display: block;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.5px;
  color: #316ad1;
  margin-bottom: 8px;
  text-transform: uppercase;
}

.page-hero .eyebrow {
  color: #accdff;
}

.page-hero h1 {
  font-size: 32px;
  margin: 0 0 8px;
  letter-spacing: -0.6px;
  color: #fff;
  font-weight: 900;
}

.page-hero p {
  color: #e1ebff;
  font-size: 14px;
  line-height: 1.6;
  margin: 0;
}

.subpage-container {
  padding-top: 20px;
  padding-bottom: 30px;
}

.data-notice {
  display: flex;
  align-items: center;
  gap: 9px;
  color: #586b8f;
  font-size: 12px;
  margin-bottom: 18px;
}

.status-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #4484eb;
  flex-shrink: 0;
}

.page-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 285px;
  gap: 22px;
}

.latest-draw {
  padding: 22px !important;
  border-top: 3px solid #1674ff !important;
  background: linear-gradient(110deg, #fff, #eff5ff) !important;
}

.status-chip {
  font-size: 11px;
  padding: 5px 10px;
  background: #e0f6ed;
  color: #08704a;
  border-radius: 20px;
  white-space: nowrap;
  font-weight: 600;
}

.latest-content {
  display: flex;
  gap: 24px;
  align-items: center;
  justify-content: space-between;
  margin-top: 18px;
}

.latest-content .ball {
  width: 44px;
  height: 44px;
  font-size: 22px;
}

.prize-total {
  text-align: right;
}

.prize-total > span {
  font-size: 12px;
  color: #70809b;
  display: block;
  margin-bottom: 4px;
}

.prize-total strong {
  font-size: 24px;
  color: #d52116;
  white-space: nowrap;
  letter-spacing: -0.8px;
  font-weight: 900;
}

.filter-bar {
  display: flex;
  gap: 12px;
  align-items: flex-end;
  margin: 20px 0;
}

.filter-bar label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  color: #506384;
  font-size: 12px;
  font-weight: 600;
  flex: 1;
}

.filter-bar select,
.filter-bar input[type="date"] {
  border: 1px solid #cbdaf2;
  background: #fafcff;
  color: #162d54;
  border-radius: 8px;
  padding: 9px 12px;
  font-size: 13px;
  min-height: 40px;
}

.secondary-button {
  border: 1px solid #cbdaf2;
  border-radius: 8px;
  background: #fff;
  padding: 9px 14px;
  min-height: 40px;
  font-size: 13px;
  white-space: nowrap;
  cursor: pointer;
  font-weight: 600;
  color: #1d4076;
  transition: all 0.2s;
}

.secondary-button:hover {
  background: #edf5ff;
}

/* History Container */
.lotto-history-container {
  margin-top: 20px;
  padding: 24px;
  border-radius: 12px;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
  box-sizing: border-box;
}

/* History Filter Bar - Perfectly Aligned, Sleek & Modern */
.lotto-history-filter-form {
  display: grid !important;
  grid-template-columns: 1fr 1.35fr 1fr auto !important;
  gap: 14px !important;
  align-items: start !important;
  margin-bottom: 20px !important;
  background: #f8fafc !important;
  padding: 18px 20px !important;
  border-radius: 12px !important;
  border: 1px solid #e2e8f0 !important;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.03) !important;
  box-sizing: border-box !important;
}

.lotto-history-filter-form .filter-field {
  display: flex !important;
  flex-direction: column !important;
  justify-content: flex-start !important;
  margin: 0 !important;
  padding: 0 !important;
}

.lotto-history-filter-form label {
  display: block !important;
  font-size: 12px !important;
  font-weight: 600 !important;
  color: #475569 !important;
  margin-bottom: 6px !important;
  line-height: 16px !important;
  height: 16px !important;
  white-space: nowrap !important;
}

.lotto-history-filter-form input[type="date"],
.lotto-history-filter-form select,
.lotto-history-filter-form input[type="text"] {
  width: 100% !important;
  height: 42px !important;
  line-height: 40px !important;
  padding: 0 12px !important;
  border: 1px solid #cbd5e1 !important;
  border-radius: 8px !important;
  font-size: 13px !important;
  color: #1e293b !important;
  background-color: #ffffff !important;
  box-sizing: border-box !important;
  margin: 0 !important;
  outline: none !important;
  transition: all 0.2s ease !important;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03) !important;
}

.lotto-history-filter-form select {
  cursor: pointer !important;
  appearance: none !important;
  -webkit-appearance: none !important;
  -moz-appearance: none !important;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%2364748b' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E") !important;
  background-repeat: no-repeat !important;
  background-position: right 12px center !important;
  padding-right: 32px !important;
  white-space: nowrap !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
}

.lotto-history-filter-form input[type="date"]:focus,
.lotto-history-filter-form select:focus,
.lotto-history-filter-form input[type="text"]:focus {
  border-color: #059669 !important;
  box-shadow: 0 0 0 3px rgba(5, 150, 105, 0.15) !important;
}

.lotto-history-filter-form .filter-buttons-group {
  display: flex !important;
  gap: 8px !important;
  align-items: center !important;
  height: 42px !important;
}

/* Modern Filter Buttons - No Basic/Dull Colors */
.lotto-btn-filter {
  height: 42px !important;
  margin: 0 !important;
  padding: 0 18px !important;
  border-radius: 8px !important;
  font-size: 13px !important;
  font-weight: 600 !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 7px !important;
  border: none !important;
  background: linear-gradient(135deg, #059669 0%, #047857 100%) !important;
  color: #ffffff !important;
  box-shadow: 0 3px 10px rgba(5, 150, 105, 0.28) !important;
  cursor: pointer !important;
  transition: all 0.2s ease !important;
  text-transform: none !important;
  letter-spacing: normal !important;
  line-height: 1 !important;
  box-sizing: border-box !important;
  white-space: nowrap !important;
}

.lotto-btn-filter:hover {
  background: linear-gradient(135deg, #10b981 0%, #059669 100%) !important;
  box-shadow: 0 5px 15px rgba(5, 150, 105, 0.4) !important;
  transform: translateY(-1px);
  color: #ffffff !important;
}

.lotto-btn-filter:active {
  transform: translateY(0);
  box-shadow: 0 2px 6px rgba(5, 150, 105, 0.2) !important;
}

.lotto-btn-reset {
  height: 42px !important;
  margin: 0 !important;
  padding: 0 16px !important;
  border-radius: 8px !important;
  font-size: 13px !important;
  font-weight: 600 !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 6px !important;
  border: 1px solid #cbd5e1 !important;
  background: #ffffff !important;
  color: #475569 !important;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05) !important;
  cursor: pointer !important;
  transition: all 0.2s ease !important;
  text-transform: none !important;
  letter-spacing: normal !important;
  line-height: 1 !important;
  box-sizing: border-box !important;
  white-space: nowrap !important;
}

.lotto-btn-reset:hover {
  background: #f1f5f9 !important;
  border-color: #94a3b8 !important;
  color: #0f172a !important;
  transform: translateY(-1px);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.08) !important;
}

.lotto-btn-reset:active {
  transform: translateY(0);
  background: #e2e8f0 !important;
}

/* History Table Header and Row Layout - Perfectly Aligned and Centered */
.lotto-history-header {
  display: grid;
  grid-template-columns: 230px 1fr 160px 92px;
  align-items: center;
  gap: 16px;
  background: linear-gradient(180deg, #f0fdf4 0%, #dcfce7 100%) !important;
  border: 1px solid #86efac !important;
  border-radius: 8px;
  padding: 10px 16px;
  font-size: 12px;
  font-weight: 700;
  color: #064e3b !important;
  letter-spacing: 0.3px;
  margin-bottom: 8px;
  box-sizing: border-box;
}

.lotto-history-header .history-hdr-draw {
  text-align: left;
}

.lotto-history-header .history-hdr-balls {
  text-align: center;
}

.lotto-history-header .history-hdr-prize {
  text-align: right;
}

.lotto-history-header .history-hdr-action {
  text-align: center;
}

.history-row {
  display: grid !important;
  grid-template-columns: 230px 1fr 160px 92px !important;
  align-items: center !important;
  gap: 16px !important;
  border-top: 1px solid #e3ebf8 !important;
  padding: 12px 16px !important;
  box-sizing: border-box !important;
}

.history-row .history-draw-col {
  display: flex !important;
  align-items: center !important;
  gap: 8px !important;
  white-space: nowrap !important;
  line-height: 1 !important;
}

.history-row .history-draw-id {
  color: #059669 !important;
  font-size: 15px !important;
  font-weight: 700 !important;
  line-height: 1 !important;
}

.history-row .history-draw-datetime {
  color: #64748b !important;
  font-size: 12px !important;
  font-weight: 500 !important;
  line-height: 1 !important;
}

.history-row .result-balls {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 6px !important;
  line-height: 1 !important;
  margin: 0 !important;
  padding: 0 !important;
}

.history-row .result-balls .ball {
  width: 32px !important;
  height: 32px !important;
  font-size: 14px !important;
  font-weight: 700 !important;
  border-radius: 50% !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  line-height: 1 !important;
  margin: 0 !important;
  background: linear-gradient(180deg, #ffffff 0%, #edf8ff 100%) !important;
  border: 2px solid #51b9e9 !important;
  box-shadow: 0 2px 0 #1682b9 !important;
  color: #071b38 !important;
  box-sizing: border-box !important;
}

.history-row .result-balls .ball.gold {
  background: linear-gradient(180deg, #fffbe3, #ffe58a) !important;
  border-color: #efb817 !important;
  box-shadow: 0 2px 0 #c88b00 !important;
  color: #78350f !important;
  margin-left: 6px !important;
}

.history-row .history-prize {
  display: flex !important;
  align-items: center !important;
  justify-content: flex-end !important;
  text-align: right !important;
  line-height: 1 !important;
}

.history-row .history-prize-mobile-label {
  display: none;
}

.history-row .history-prize-val {
  color: #d6221c !important;
  font-size: 14px !important;
  font-weight: 700 !important;
  white-space: nowrap !important;
  line-height: 1 !important;
}

.history-row .history-action {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  margin: 0 !important;
  padding: 0 !important;
  line-height: 1 !important;
  align-self: center !important;
}

.history-row .lotto-toggle-detail-btn {
  margin: 0 !important;
  padding: 0 8px !important;
  width: 92px !important;
  min-width: 92px !important;
  max-width: 92px !important;
  height: 32px !important;
  min-height: 32px !important;
  max-height: 32px !important;
  font-size: 12px !important;
  font-weight: 600 !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  text-align: center !important;
  white-space: nowrap !important;
  border-radius: 6px !important;
  border: 1px solid #86efac !important;
  background: linear-gradient(135deg, #f0fdf4 0%, #dcfce7 100%) !important;
  color: #047857 !important;
  cursor: pointer !important;
  box-sizing: border-box !important;
  line-height: 1 !important;
  box-shadow: 0 1px 2px rgba(4, 120, 87, 0.08) !important;
  transition: all 0.2s ease !important;
  text-transform: none !important;
  align-self: center !important;
  vertical-align: middle !important;
}

.history-row .lotto-toggle-detail-btn:hover {
  background: linear-gradient(135deg, #059669 0%, #047857 100%) !important;
  border-color: #047857 !important;
  color: #ffffff !important;
  box-shadow: 0 3px 8px rgba(5, 150, 105, 0.25) !important;
  transform: translateY(-1px);
}

.history-row .lotto-toggle-detail-btn.is-active {
  background: #fef2f2 !important;
  border-color: #fecaca !important;
  color: #dc2626 !important;
  box-shadow: 0 1px 2px rgba(220, 38, 38, 0.08) !important;
}

.history-row .lotto-toggle-detail-btn.is-active:hover {
  background: #dc2626 !important;
  border-color: #b91c1c !important;
  color: #ffffff !important;
  box-shadow: 0 3px 8px rgba(220, 38, 38, 0.25) !important;
}

.lotto-history-tier-drawer {
  background: #f8fdf9 !important;
  border: 1px solid #bbf7d0 !important;
  padding: 10px 3px !important;
  box-sizing: border-box !important;
}

.lotto-history-tier-drawer h4 {
  margin: 0 0 8px 3px !important;
  font-size: 13px !important;
  color: #064e3b !important;
}

.lotto-history-tier-drawer .table-scroll {
  border: none !important;
  box-shadow: none !important;
  border-radius: 6px !important;
  overflow: hidden !important;
}

/* Tier structure table cell padding - 3px horizontal margin from table borders */
.table-vietlott-structure th,
.lotto-tier-table th {
  background: linear-gradient(180deg, #f0fdf4 0%, #dcfce7 100%) !important;
  color: #064e3b !important;
  border-bottom: 1px solid #86efac !important;
  padding: 8px 3px !important;
  vertical-align: middle !important;
  box-sizing: border-box !important;
}

.table-vietlott-structure td,
.lotto-tier-table td {
  padding: 8px 3px !important;
  vertical-align: middle !important;
  box-sizing: border-box !important;
  border-bottom: 1px solid #e2f4e9 !important;
}

.table-vietlott-structure tr:hover td,
.lotto-tier-table tr:hover td {
  background: #f0fdf4 !important;
}

.table-vietlott-structure th:first-child,
.table-vietlott-structure td:first-child,
.lotto-tier-table th:first-child,
.lotto-tier-table td:first-child {
  padding-left: 3px !important;
}

.table-vietlott-structure th:last-child,
.table-vietlott-structure td:last-child,
.lotto-tier-table th:last-child,
.lotto-tier-table td:last-child {
  padding-right: 3px !important;
  text-align: right !important;
}

@media (max-width: 900px) {
  .lotto-history-filter-form {
    grid-template-columns: 1fr 1fr !important;
  }
  .filter-field.filter-actions {
    grid-column: 1 / -1;
  }
  .filter-field.filter-actions .filter-actions-label {
    display: none !important;
  }
  .filter-buttons-group {
    width: 100%;
  }
  .filter-buttons-group button {
    flex: 1;
  }
}

@media (max-width: 767px) {
  .lotto-history-container {
    padding: 10px 6px !important;
    margin-top: 14px !important;
    border-radius: 10px !important;
  }

  .lotto-history-filter-form {
    grid-template-columns: 1fr 1fr !important;
    gap: 10px 8px !important;
    padding: 12px 10px !important;
    margin-bottom: 14px !important;
    border-radius: 10px !important;
  }

  .filter-field.filter-date {
    grid-column: 1 / 2 !important;
  }

  .filter-field.filter-time {
    grid-column: 2 / 3 !important;
  }

  .filter-field.filter-search {
    grid-column: 1 / -1 !important;
  }

  .filter-field.filter-actions {
    grid-column: 1 / -1 !important;
  }

  .filter-field label {
    font-size: 11px !important;
    margin-bottom: 4px !important;
  }

  .filter-buttons-group {
    display: flex !important;
    gap: 8px !important;
    width: 100% !important;
    height: auto !important;
  }

  .lotto-btn-filter,
  .lotto-btn-reset {
    flex: 1 !important;
    height: 40px !important;
    font-size: 13px !important;
    padding: 0 10px !important;
  }

  .lotto-history-header {
    display: none !important;
  }

  .history-row {
    display: grid !important;
    grid-template-columns: 1fr auto !important;
    align-items: center !important;
    row-gap: 8px !important;
    column-gap: 6px !important;
    padding: 10px 8px !important;
    border-top: 1px solid #eef2f6 !important;
    box-sizing: border-box !important;
  }

  .history-row .history-draw-col {
    grid-column: 1 / -1 !important;
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    width: 100% !important;
    line-height: 1.2 !important;
  }

  .history-row .history-draw-id {
    font-size: 14px !important;
    color: #0055ff !important;
    font-weight: 800 !important;
  }

  .history-row .history-draw-datetime {
    font-size: 11px !important;
    color: #64748b !important;
  }

  .history-row .result-balls {
    grid-column: 1 / -1 !important;
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    gap: 5px !important;
    width: 100% !important;
    padding: 3px 0 !important;
  }

  .history-row .result-balls .ball {
    width: 32px !important;
    height: 32px !important;
    font-size: 13.5px !important;
    flex: 0 0 32px !important;
    margin: 0 !important;
  }

  .history-row .result-balls .ball.gold {
    margin-left: 3px !important;
  }

  .history-row .history-prize {
    grid-column: 1 / 2 !important;
    display: flex !important;
    align-items: baseline !important;
    justify-content: flex-start !important;
    text-align: left !important;
    min-width: 0 !important;
    overflow: hidden !important;
  }

  .history-row .history-prize-mobile-label {
    display: inline !important;
    color: #64748b !important;
    font-size: 11px !important;
    font-weight: 500 !important;
    margin-right: 4px !important;
    white-space: nowrap !important;
  }

  .history-row .history-prize-val {
    color: #d80000 !important;
    font-size: 13px !important;
    font-weight: 700 !important;
    white-space: nowrap !important;
  }

  .history-row .history-action {
    grid-column: 2 / 3 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: flex-end !important;
  }

  .history-row .lotto-toggle-detail-btn {
    width: 72px !important;
    min-width: 72px !important;
    max-width: 72px !important;
    height: 28px !important;
    min-height: 28px !important;
    max-height: 28px !important;
    font-size: 11px !important;
    padding: 0 4px !important;
    border-radius: 6px !important;
  }

  .lotto-history-container {
    padding: 10px 4px !important;
  }

  .history-row {
    padding: 10px 4px !important;
  }

  .lotto-history-tier-drawer {
    grid-column: 1 / -1 !important;
    margin-left: -4px !important;
    margin-right: -4px !important;
    width: calc(100% + 8px) !important;
    padding: 8px 3px !important;
    margin-top: 6px !important;
    overflow-x: hidden !important;
    box-sizing: border-box !important;
    border-radius: 6px !important;
  }

  .lotto-history-tier-drawer h4 {
    font-size: 12.5px !important;
    margin: 0 0 6px 0 !important;
    padding-left: 2px !important;
  }

  .lotto-history-tier-drawer .table-scroll {
    overflow-x: hidden !important;
    width: 100% !important;
    margin: 0 !important;
    border: none !important;
    border-radius: 4px !important;
    padding: 0 !important;
  }
}

.empty-state {
  text-align: center;
  background: #f5f8fe;
  padding: 30px 15px;
  border-radius: 12px;
  color: #536d94;
}

/* Dò vé subpage */
.ticket-inputs {
  display: flex;
  gap: 12px;
  margin: 18px 0 24px;
}

.ticket-inputs input {
  width: 0;
  flex: 1;
  min-width: 0;
  height: 72px;
  text-align: center;
  font-size: 30px;
  font-weight: 700;
  border: 2px solid #d6e4fa;
  border-radius: 12px;
  background: #f8fbff;
  color: #0c3775;
}

.ticket-feedback {
  margin-top: 24px;
  padding: 22px;
  background: #f0f7ff;
  border: 1px solid #b9d8ff;
  border-radius: 12px;
}

.ticket-feedback.invalid {
  color: #b52427;
  background: #fff2f2;
  border-color: #efb9bd;
}

.checked-balls {
  display: flex;
  gap: 8px;
  margin: 10px 0;
}

.checked-balls .ball {
  width: 42px;
  height: 42px;
  font-size: 20px;
}

/* Thống kê & Chu kỳ số grids */
.metric-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin: 20px 0 24px;
}

.metric {
  padding: 16px 14px;
  border: 1px solid #dce8fa;
  border-radius: 11px;
  background: linear-gradient(130deg, #f3f8ff, #fff);
}

.metric strong {
  display: block;
  font-size: 26px;
  color: #075be6;
  margin-bottom: 5px;
  font-weight: 900;
}

.metric span {
  font-size: 12px;
  color: #607594;
}

.number-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 10px;
  margin: 20px 0;
}

.number-tile {
  text-align: center;
  border: 1px solid #d3e3fb;
  border-radius: 11px;
  padding: 12px 6px;
  background: #f7fbff;
}

.number-tile .ball {
  width: 34px;
  height: 34px;
  font-size: 16px;
}

.number-tile > b {
  display: block;
  font-size: 13px;
  margin: 8px 0 4px;
}

.number-tile > span:not(.ball) {
  display: block;
  font-size: 10px;
  color: #6b7f9e;
}

.tile-meter {
  height: 3px;
  background: #dce8f9;
  border-radius: 3px;
  margin: 8px 3px 0;
  overflow: hidden;
}

.tile-meter i {
  display: block;
  height: 100%;
  background: #1479fa;
}

.number-tile.not-seen {
  background: #f6f7fa;
  border-color: #dfe4ed;
}

.number-tile.not-seen .ball {
  border-color: #ced6e2;
  color: #6d7d96;
}

.number-tile.just-seen {
  background: #effaf6;
  border-color: #b8e1d2;
}

.number-tile.just-seen .ball {
  border-color: #78c9af;
  color: #087753;
}

.number-tile.waiting {
  background: #fffaf1;
  border-color: #eadbbf;
}

.number-picker {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 8px;
  margin: 18px 0;
}

.number-picker button {
  border: 1px solid #cbdcf5;
  border-radius: 8px;
  background: #f6faff;
  min-height: 40px;
  font-size: 15px;
  font-weight: 700;
  color: #23508a;
  cursor: pointer;
}

.number-picker button[aria-pressed="true"] {
  background: #075def !important;
  color: white !important;
  border-color: #075def !important;
}

/* --------------------------------------------------
   Responsive Media Queries
   -------------------------------------------------- */
@media (max-width: 960px) {
  .hero-inner {
    padding: 10px 15px;
  }
  .hero-draw .game-badge {
    display: none;
  }
  .jackpot {
    min-width: 260px;
  }
  .promo .phone {
    display: none;
  }
  .page-layout {
    grid-template-columns: 1fr;
  }
  .footer-top-grid {
    grid-template-columns: 1fr 1fr;
    gap: 20px;
  }
  .footer-col:nth-child(2) {
    border-right: 0;
  }
  .shortcuts {
    grid-template-columns: repeat(3, 1fr);
    row-gap: 12px;
  }
  .shortcuts > :nth-child(3) {
    border-right: 0;
  }
  .overdue-list {
    grid-template-columns: repeat(5, 1fr);
  }
  .benefits {
    grid-template-columns: repeat(2, 1fr);
    row-gap: 14px;
  }
  .benefits > div:nth-child(2) {
    border-right: 0;
  }
}

@media (max-width: 600px) {
  .hero-inner {
    flex-direction: column;
    text-align: center;
    gap: 15px;
  }
  .hero-draw {
    justify-content: center;
  }
  .draw-date {
    margin: 0 auto 10px;
  }
  .hero-numbers {
    justify-content: center !important;
    gap: 6px !important;
    margin: 0 auto !important;
    width: 100% !important;
    flex-wrap: nowrap !important;
  }
  .hero-numbers .ball {
    width: 44px !important;
    height: 44px !important;
    font-size: 20px !important;
    border-width: 2.5px !important;
    flex: 0 0 44px !important;
    margin: 0 !important;
  }
  .hero-numbers .gold {
    margin-left: 4px !important;
  }
  .shortcuts {
    grid-template-columns: repeat(2, 1fr);
  }
  .shortcuts > :nth-child(2n) {
    border-right: 0;
  }
  .footer-col {
    border-right: 0 !important;
    border-bottom: 0 !important;
    padding-bottom: 12px;
  }
  .footer-bottom-bar {
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 12px !important;
    text-align: center !important;
    width: 100% !important;
  }
  .footer-copyright {
    width: 100% !important;
    text-align: center !important;
    font-size: 12px !important;
    line-height: 1.5 !important;
  }
  .footer-legal-links {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    flex-wrap: wrap !important;
    gap: 6px 12px !important;
    width: 100% !important;
    text-align: center !important;
    margin: 0 auto !important;
    color: #475569 !important;
  }
  .footer-legal-links a,
  .footer-legal-links button {
    font-size: 12px !important;
    color: #94a3b8 !important;
    padding: 3px 6px !important;
    white-space: nowrap !important;
    line-height: 1.4 !important;
    text-decoration: none !important;
    border-radius: 4px !important;
  }
  .footer-legal-links a:hover,
  .footer-legal-links a:focus,
  .footer-legal-links button:hover,
  .footer-legal-links button:focus {
    color: #ffffff !important;
    background: rgba(255, 255, 255, 0.08) !important;
  }
  .footer-legal-links .legal-sep {
    display: none !important;
  }
  .number-grid {
    grid-template-columns: repeat(4, 1fr);
  }
  .metric-grid {
    grid-template-columns: 1fr;
  }
  .history-row {
    grid-template-columns: 1fr;
    gap: 10px;
  }
  .history-prize {
    text-align: left;
  }
}

/* Prize Table Column Labels */
.prize-th-short {
  display: none;
}

/* Matched Balls Patterns (Vietlott standard) - Vertically Aligned Special Balls */
.lotto-match-pattern {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  vertical-align: middle;
}

.lotto-match-main {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 5px;
  width: 90px;
  flex-shrink: 0;
}

.lotto-match-special {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  width: 29px;
  flex-shrink: 0;
}

.lotto-dot {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  display: inline-block;
  flex-shrink: 0;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.16);
}

.lotto-dot-main {
  background: radial-gradient(circle at 35% 35%, #22c55e 0%, #15803d 100%);
}

.lotto-dot-special {
  background: radial-gradient(circle at 35% 35%, #fb923c 0%, #ea580c 100%);
}

.lotto-dot-plus {
  font-size: 13px;
  font-weight: 700;
  color: #64748b;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 10px;
}

.lotto-match-kk-wrap {
  display: inline-flex;
  flex-direction: column;
  gap: 4px;
  vertical-align: middle;
  padding: 2px 0;
}

.lotto-dot-empty {
  width: 14px;
  height: 14px;
  display: inline-block;
  visibility: hidden;
}

/* ==========================================================================
   Live Arena Box & Large Highlight Balls
   ========================================================================== */
.lotto-live-balls-arena {
  background: linear-gradient(135deg, #022015 0%, #064434 45%, #046347 80%, #057a55 100%) !important;
  border-radius: 16px !important;
  padding: 26px 20px !important;
  text-align: center !important;
  color: #ffffff !important;
  margin-bottom: 22px !important;
  box-shadow: 0 8px 26px rgba(2, 32, 21, 0.28), inset 0 1px 2px rgba(255, 255, 255, 0.35) !important;
  border: 1px solid rgba(52, 211, 153, 0.35) !important;
  position: relative !important;
  overflow: hidden !important;
}

.lotto-live-balls-arena::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle at 50% 25%, rgba(255, 255, 255, 0.18) 0%, transparent 60%);
  pointer-events: none;
}

#lotto-live-status-text {
  color: #ffffff !important;
  font-size: 16px !important;
  font-weight: 700 !important;
  margin-bottom: 18px !important;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.3) !important;
  position: relative;
  z-index: 1;
}

#lotto-live-status-text strong {
  color: #ffffff !important;
  letter-spacing: 0.3px;
}

.lotto-live-balls {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 14px !important;
  flex-wrap: wrap !important;
  position: relative !important;
  z-index: 1 !important;
}

.lotto-live-balls .ball {
  width: 54px !important;
  height: 54px !important;
  font-size: 26px !important;
  font-weight: 800 !important;
  border-radius: 50% !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  background: linear-gradient(180deg, #ffffff 0%, #edf8ff 100%) !important;
  color: #071b38 !important;
  border: 3px solid #38bdf8 !important;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.25), inset 0 2px 4px #ffffff !important;
  line-height: 1 !important;
  font-family: Arial, sans-serif !important;
  transition: transform 0.2s ease, box-shadow 0.2s ease !important;
}

.lotto-live-balls .ball:hover {
  transform: scale(1.08) !important;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.35), inset 0 2px 4px #ffffff !important;
}

.lotto-live-balls .ball.gold {
  background: linear-gradient(180deg, #fffbeb 0%, #fde047 50%, #f59e0b 100%) !important;
  border-color: #d97706 !important;
  color: #78350f !important;
  box-shadow: 0 4px 16px rgba(245, 158, 11, 0.45), inset 0 2px 4px #ffffff !important;
  margin-left: 8px !important;
}

/* Live Card Active Drawing Glow */
.lotto-live-card.is-drawing {
  border: 2px solid #ef4444 !important;
  box-shadow: 0 0 25px rgba(239, 68, 68, 0.22), 0 4px 16px rgba(0, 0, 0, 0.06) !important;
  position: relative;
}

/* Live Badge with Ping Indicator */
.lotto-badge-live.pulse-glow {
  background: linear-gradient(135deg, #ef4444 0%, #b91c1c 100%) !important;
  color: #ffffff !important;
  padding: 5px 14px !important;
  border-radius: 20px !important;
  font-size: 13px !important;
  font-weight: 800 !important;
  letter-spacing: 0.5px !important;
  display: inline-flex !important;
  align-items: center !important;
  gap: 7px !important;
  box-shadow: 0 0 14px rgba(239, 68, 68, 0.55) !important;
  animation: liveGlowBadge 1.5s infinite alternate !important;
}

@keyframes liveGlowBadge {
  0% { box-shadow: 0 0 8px rgba(239, 68, 68, 0.4); }
  100% { box-shadow: 0 0 20px rgba(239, 68, 68, 0.9); }
}

.live-dot-ping {
  width: 8px;
  height: 8px;
  background: #ffffff;
  border-radius: 50%;
  display: inline-block;
  position: relative;
}
.live-dot-ping::after {
  content: '';
  position: absolute;
  top: -4px;
  left: -4px;
  right: -4px;
  bottom: -4px;
  border-radius: 50%;
  border: 2px solid #ffffff;
  animation: livePingRing 1.2s cubic-bezier(0, 0, 0.2, 1) infinite;
}
@keyframes livePingRing {
  0% { transform: scale(0.6); opacity: 1; }
  100% { transform: scale(2.2); opacity: 0; }
}

.live-dot-pulse {
  width: 7px;
  height: 7px;
  background: #ef4444;
  border-radius: 50%;
  display: inline-block;
  animation: liveDotBlink 0.9s infinite alternate;
}
@keyframes liveDotBlink {
  0% { transform: scale(0.8); opacity: 0.5; }
  100% { transform: scale(1.3); opacity: 1; }
}

/* Animated 3 Loading Dots (Live Load Waves) */
.live-dots-loading,
.live-dots-loading.is-white,
.live-dots-loading.white {
  background: transparent !important;
  background-color: transparent !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 4px !important;
  height: 16px !important;
  vertical-align: middle !important;
  padding: 0 4px !important;
}

.live-dots-loading i {
  width: 5px !important;
  height: 5px !important;
  background-color: #ef4444 !important;
  border-radius: 50% !important;
  display: inline-block !important;
  animation: liveDotPulse 1.2s infinite ease-in-out both !important;
}

.live-dots-loading i:nth-child(1) {
  animation-delay: -0.32s !important;
}

.live-dots-loading i:nth-child(2) {
  animation-delay: -0.16s !important;
}

.live-dots-loading i:nth-child(3) {
  animation-delay: 0s !important;
}

@keyframes liveDotPulse {
  0%, 80%, 100% {
    transform: scale(0.6);
    opacity: 0.3;
  }
  40% {
    transform: scale(1.2);
    opacity: 1;
  }
}

.live-dots-loading.is-white i,
.live-dots-loading.white i {
  background-color: #ffffff !important;
}

/* Status Wait Chip in Prize Table */
.live-wait-chip {
  background: #fef2f2 !important;
  color: #dc2626 !important;
  border: 1px solid #fecaca !important;
  border-radius: 20px !important;
  padding: 3px 10px !important;
  font-size: 12px !important;
  font-weight: 700 !important;
  display: inline-flex !important;
  align-items: center !important;
  gap: 6px !important;
  white-space: nowrap !important;
  box-shadow: 0 1px 3px rgba(220, 38, 38, 0.08) !important;
}

.live-equalizer {
  display: inline-flex;
  align-items: flex-end;
  gap: 2.5px;
  height: 12px;
  margin-right: 2px;
}
.live-equalizer i {
  width: 2.5px;
  background: #dc2626;
  border-radius: 2px;
  display: inline-block;
  animation: liveBarWave 0.8s ease-in-out infinite alternate;
}
.live-equalizer i:nth-child(1) { height: 5px; animation-delay: 0.1s; }
.live-equalizer i:nth-child(2) { height: 12px; animation-delay: 0.35s; }
.live-equalizer i:nth-child(3) { height: 7px; animation-delay: 0.6s; }

@keyframes liveBarWave {
  0% { height: 3px; opacity: 0.45; }
  50% { height: 12px; opacity: 1; }
  100% { height: 4px; opacity: 0.6; }
}

/* Live Jackpot Tags */
.live-jp-tag {
  background: #fee2e2;
  color: #b91c1c;
  font-size: 11px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 12px;
  margin-left: 6px;
  display: inline-block;
  vertical-align: middle;
  animation: liveTagPulse 1.2s infinite alternate;
}
.live-table-tag {
  background: #ffffff;
  color: #d80000;
  font-size: 11px;
  font-weight: 800;
  padding: 2px 8px;
  border-radius: 12px;
  margin-left: 8px;
  display: inline-block;
  vertical-align: middle;
}
.live-badge-estimate {
  display: block !important;
  font-size: 11px !important;
  color: #ef4444 !important;
  font-weight: 600 !important;
  margin-top: 2px !important;
}
@keyframes liveTagPulse {
  0% { opacity: 0.8; transform: scale(0.98); }
  100% { opacity: 1; transform: scale(1.04); }
}

/* Live Broadcast Ticker in Arena */
.live-status-stream {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: transparent !important;
  border: none !important;
  padding: 0 !important;
  margin: 0 !important;
  max-width: 100%;
}
.live-stream-badge {
  background: #ef4444;
  color: #ffffff;
  padding: 4px 14px;
  border-radius: 20px;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.5px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  box-shadow: 0 0 12px rgba(239, 68, 68, 0.7);
}
.live-stream-msg {
  display: none !important;
}
@media (max-width: 600px) {
  .live-status-stream {
    flex-direction: row;
    padding: 0 !important;
    margin: 0 !important;
  }
  .live-stream-msg {
    display: none !important;
  }
}

/* Rolling and Tumbling Balls */
.lotto-live-balls .ball.ball-rolling {
  background: radial-gradient(circle at 35% 35%, #60a5fa 0%, #1e40af 70%, #0f172a 100%) !important;
  color: #ffffff !important;
  border-color: #93c5fd !important;
  box-shadow: 0 4px 18px rgba(37, 99, 235, 0.5), inset 0 2px 4px rgba(255, 255, 255, 0.6) !important;
  animation: ballTumbleShake 0.12s infinite alternate, ballTumblePulse 1.2s infinite ease-in-out !important;
  position: relative !important;
}

.lotto-live-balls .ball.gold.ball-rolling {
  background: radial-gradient(circle at 35% 35%, #fef08a 0%, #f59e0b 60%, #92400e 100%) !important;
  color: #451a03 !important;
  border-color: #fde047 !important;
  box-shadow: 0 4px 22px rgba(245, 158, 11, 0.65), inset 0 2px 4px #ffffff !important;
  animation: ballTumbleShake 0.12s infinite alternate, ballGoldPulse 1.2s infinite ease-in-out !important;
}

.lotto-live-balls .ball.ball-revealed-pop {
  animation: ballRevealPop 0.6s cubic-bezier(0.175, 0.885, 0.32, 1.275) !important;
}

@keyframes ballTumbleShake {
  0% { transform: translateY(-1.5px) rotate(-1deg); }
  100% { transform: translateY(1.5px) rotate(1deg); }
}

@keyframes ballTumblePulse {
  0% { box-shadow: 0 4px 14px rgba(37, 99, 235, 0.4); }
  100% { box-shadow: 0 6px 26px rgba(59, 130, 246, 0.8); }
}

@keyframes ballGoldPulse {
  0% { box-shadow: 0 4px 16px rgba(245, 158, 11, 0.5); }
  100% { box-shadow: 0 8px 30px rgba(251, 191, 36, 0.95); }
}

@keyframes ballRevealPop {
  0% { transform: scale(0.3); opacity: 0.2; }
  65% { transform: scale(1.22); }
  100% { transform: scale(1); opacity: 1; }
}

@media (max-width: 580px) {
  .lotto-live-balls {
    gap: 8px !important;
  }
  .lotto-live-balls .ball {
    width: 44px !important;
    height: 44px !important;
    font-size: 20px !important;
    border-width: 2.5px !important;
  }
  .lotto-live-balls .ball.gold {
    margin-left: 4px !important;
  }
}

@media (max-width: 380px) {
  .lotto-live-balls {
    gap: 6px !important;
  }
  .lotto-live-balls .ball {
    width: 38px !important;
    height: 38px !important;
    font-size: 17px !important;
    border-width: 2px !important;
  }
  .hero-numbers {
    gap: 4px !important;
  }
  .hero-numbers .ball {
    width: 38px !important;
    height: 38px !important;
    font-size: 17px !important;
    border-width: 2px !important;
    flex: 0 0 38px !important;
  }
  .hero-numbers .gold {
    margin-left: 3px !important;
  }
}

/* ==========================================================================
   COMPREHENSIVE STATISTICS PAGE STYLES ([lotto_statistics_page])
   ========================================================================== */

.lotto-stats-page-wrap {
  width: 100%;
  padding: 10px 0 50px;
  box-sizing: border-box;
}

/* Hero Section */
.lotto-stats-hero {
  background: linear-gradient(135deg, #022015 0%, #064434 45%, #046347 80%, #057a55 100%) !important;
  color: #ffffff;
  padding: 30px 32px;
  border-radius: 16px;
  margin-bottom: 24px;
  box-shadow: 0 10px 30px rgba(2, 32, 21, 0.25);
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(52, 211, 153, 0.3);
}

.lotto-stats-hero .breadcrumb-nav {
  margin-bottom: 12px;
  font-size: 13px;
  color: #a7f3d0;
}

.lotto-stats-hero .breadcrumb-nav a {
  color: #d1fae5;
  text-decoration: none;
}

.lotto-stats-hero .breadcrumb-nav a:hover {
  color: #ffffff;
}

.lotto-stats-hero .lotto-eyebrow {
  display: inline-block;
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(134, 239, 172, 0.35);
  color: #ffd026;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 1px;
  padding: 4px 12px;
  border-radius: 20px;
  margin-bottom: 10px;
  text-transform: uppercase;
}

.lotto-stats-hero h1 {
  font-size: 26px;
  font-weight: 800;
  color: #ffffff;
  margin: 0 0 10px;
  line-height: 1.3;
}

.lotto-stats-hero p {
  font-size: 14.5px;
  color: #d1fae5;
  margin: 0;
  max-width: 800px;
  line-height: 1.6;
}

/* Toolbar */
.lotto-stats-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 12px 18px;
  margin-bottom: 22px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.lotto-filter-label {
  font-size: 13px;
  font-weight: 700;
  color: #475569;
  margin-right: 6px;
}

.lotto-stats-scope-tabs {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
}

.lotto-scope-btn {
  background: #f1f5f9;
  border: 1px solid #cbd5e1;
  color: #334155;
  font-size: 13px;
  font-weight: 600;
  padding: 6px 14px;
  border-radius: 20px;
  cursor: pointer;
  transition: all 0.2s ease;
  line-height: 1.2;
}

.lotto-scope-btn:hover {
  background: #e2e8f0;
  color: #0f172a;
}

.lotto-scope-btn.active {
  background: linear-gradient(135deg, #059669 0%, #047857 100%) !important;
  color: #ffffff !important;
  border-color: #047857 !important;
  box-shadow: 0 2px 6px rgba(5, 150, 105, 0.35) !important;
}

.lotto-stats-time-filter-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
}

.lotto-stats-select {
  appearance: none !important;
  -webkit-appearance: none !important;
  -moz-appearance: none !important;
  display: inline-block !important;
  width: auto;
  height: 40px !important;
  min-height: 40px !important;
  line-height: 38px !important;
  padding: 0 38px 0 14px !important;
  border: 1px solid #cbd5e1 !important;
  border-radius: 8px !important;
  font-size: 13.5px !important;
  font-weight: 600 !important;
  color: #1e293b !important;
  background-color: #ffffff !important;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%23475569' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E") !important;
  background-repeat: no-repeat !important;
  background-position: right 12px center !important;
  background-size: 16px 16px !important;
  margin: 0 !important;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04) !important;
  cursor: pointer !important;
  transition: all 0.2s ease !important;
  vertical-align: middle !important;
  box-sizing: border-box !important;
}

.lotto-stats-select:focus {
  outline: none !important;
  border-color: #059669 !important;
  box-shadow: 0 0 0 3px rgba(5, 150, 105, 0.18) !important;
  background-color: #ffffff !important;
}

.lotto-stats-select:hover {
  border-color: #94a3b8 !important;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.06) !important;
}

/* KPI Summary Grid */
.lotto-stats-kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  margin-bottom: 24px;
}

.lotto-kpi-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 16px;
  display: flex;
  align-items: center;
  gap: 14px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.03);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.lotto-kpi-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.06);
}

.lotto-kpi-card.highlight-hot {
  border-top: 3px solid #ea580c;
}

.lotto-kpi-card.highlight-cold {
  border-top: 3px solid #0284c7;
}

.lotto-kpi-card.highlight-overdue {
  border-top: 3px solid #8b5cf6;
}

.kpi-icon {
  font-size: 28px;
  line-height: 1;
}

.kpi-info {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
}

.kpi-title {
  font-size: 12px;
  font-weight: 600;
  color: #64748b;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.kpi-value {
  font-size: 18px;
  font-weight: 800;
  color: #0f172a;
  line-height: 1.2;
}

.kpi-val-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.kpi-val-row .ball {
  width: 28px !important;
  height: 28px !important;
  font-size: 13px !important;
}

.kpi-sub {
  font-size: 11.5px;
  color: #94a3b8;
  white-space: normal;
  line-height: 1.35;
  word-break: break-word;
}

/* Number Deep-Dive Drawer */
.stats-number-drawer {
  background: linear-gradient(180deg, #fffaf6 0%, #ffffff 100%);
  border: 2px solid #ea580c;
  border-radius: 14px;
  padding: 20px 24px;
  margin-bottom: 24px;
  box-shadow: 0 8px 25px rgba(234, 88, 12, 0.12);
  animation: lotto-fade-in 0.25s ease-out;
}

.drawer-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid #fed7aa;
  padding-bottom: 14px;
  margin-bottom: 16px;
}

.drawer-title-group {
  display: flex;
  align-items: center;
  gap: 12px;
}

.drawer-badge-ball {
  width: 42px !important;
  height: 42px !important;
  font-size: 18px !important;
}

.drawer-header h3 {
  font-size: 18px;
  font-weight: 800;
  color: #9a3412;
  margin: 0;
}

.drawer-subtitle {
  font-size: 13px;
  color: #7c2d12;
}

.drawer-close-btn {
  background: #ffedd5;
  border: 1px solid #fdba74;
  color: #9a3412;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  font-size: 14px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
}

.drawer-close-btn:hover {
  background: #ea580c;
  color: #ffffff;
  border-color: #ea580c;
}

.drawer-metrics-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-bottom: 18px;
}

.drawer-metric {
  background: #ffffff;
  border: 1px solid #ffedd5;
  border-radius: 10px;
  padding: 12px 14px;
  text-align: center;
}

.drawer-metric small {
  display: block;
  font-size: 12px;
  color: #7c2d12;
  font-weight: 600;
  margin-bottom: 4px;
}

.drawer-metric strong {
  font-size: 20px;
  color: #ea580c;
  font-weight: 800;
}

.drawer-recent-draws-wrap h4 {
  font-size: 14px;
  font-weight: 700;
  color: #1e293b;
  margin: 0 0 10px;
}

.drawer-draws-table-wrap {
  background: #ffffff;
  border: 1px solid #fed7aa;
  border-radius: 8px;
  overflow: hidden;
}

.drawer-results-table {
  width: 100%;
  margin: 0;
  font-size: 13px;
}

.drawer-results-table th {
  background: #fff7ed;
  color: #9a3412;
  padding: 8px 12px;
  font-weight: 700;
  border-bottom: 1px solid #fed7aa;
}

.drawer-results-table td {
  padding: 8px 12px;
  border-bottom: 1px solid #ffedd5;
}

/* Drawer Recent Draws (Card row layout identical to ket-qua history rows) */
.drawer-history-list {
  display: flex;
  flex-direction: column;
  background: #ffffff;
  border: 1px solid #fed7aa;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.drawer-history-row {
  display: grid !important;
  grid-template-columns: 210px 1fr 180px !important;
  align-items: center !important;
  gap: 12px !important;
  border-top: 1px solid #ffedd5 !important;
  padding: 10px 16px !important;
  box-sizing: border-box !important;
  transition: background 0.15s ease;
}

.drawer-history-row:first-child {
  border-top: none !important;
}

.drawer-history-row:hover {
  background: #fffaf5;
}

.drawer-history-row .history-draw-col {
  display: flex !important;
  align-items: center !important;
  gap: 8px !important;
  white-space: nowrap !important;
  line-height: 1 !important;
}

.drawer-history-row .history-draw-id {
  color: #0758e4 !important;
  font-size: 14.5px !important;
  font-weight: 700 !important;
}

.drawer-history-row .history-draw-datetime {
  color: #64748b !important;
  font-size: 12px !important;
}

.drawer-history-row .result-balls {
  display: flex !important;
  justify-content: center !important;
  align-items: center !important;
  gap: 6px !important;
  flex-wrap: nowrap !important;
}

.drawer-history-row .result-balls .ball {
  width: 32px !important;
  height: 32px !important;
  font-size: 13.5px !important;
  flex: 0 0 32px !important;
  margin: 0 !important;
}

.drawer-history-row .result-balls .ball.gold {
  margin-left: 2px !important;
}

.drawer-history-row .history-prize {
  display: flex !important;
  align-items: center !important;
  justify-content: flex-end !important;
  gap: 4px !important;
  text-align: right !important;
  white-space: nowrap !important;
}

.drawer-history-row .history-prize-mobile-label {
  display: none !important;
}

.drawer-history-row .history-prize-val {
  color: #dc2626 !important;
  font-size: 13.5px !important;
  font-weight: 700 !important;
}

/* Main Nav Tabs */
.lotto-stats-main-nav {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 20px;
  border-bottom: 2px solid #e2e8f0;
  padding-bottom: 10px;
}

.stats-nav-btn {
  background: #f8fafc;
  border: 1px solid #cbd5e1;
  color: #475569;
  font-size: 14px;
  font-weight: 700;
  padding: 10px 20px;
  border-radius: 30px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: all 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.stats-nav-btn:hover {
  background: #f1f5f9;
  color: #0f172a;
}

.stats-nav-btn.active {
  background: linear-gradient(135deg, #059669 0%, #047857 100%) !important;
  color: #ffffff !important;
  border-color: #047857 !important;
  box-shadow: 0 4px 12px rgba(5, 150, 105, 0.35) !important;
}

/* Tab Panes */
.stats-tab-pane {
  display: none;
}

.stats-tab-pane.active {
  display: block;
  animation: lotto-fade-in 0.25s ease-out;
}

/* Section Cards */
.stats-section-card {
  margin-bottom: 24px;
  padding: 24px;
  border-radius: 14px;
}

/* Frequency Bar Chart */
.stats-chart-wrap {
  display: flex;
  gap: 16px;
  height: 240px;
  align-items: flex-end;
  padding-top: 24px;
  margin-top: 10px;
}

.stats-chart-axis {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  height: 190px;
  font-size: 11px;
  color: #94a3b8;
  font-weight: 600;
  text-align: right;
  padding-right: 8px;
  border-right: 1px dashed #cbd5e1;
}

.stats-chart-bars {
  display: flex;
  flex: 1;
  gap: 12px;
  align-items: flex-end;
  height: 190px;
}

.stats-bar {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  height: 100%;
  justify-content: flex-end;
  cursor: pointer;
  transition: transform 0.2s ease;
}

.stats-bar:hover {
  transform: translateY(-4px);
}

.bar-count {
  font-size: 13px;
  font-weight: 700;
  color: #0055ff;
  margin-bottom: 6px;
}

.bar-fill {
  width: 100%;
  max-width: 44px;
  height: var(--bar-height, 20%);
  background: linear-gradient(180deg, #38bdf8 0%, #0284c7 100%);
  border-radius: 6px 6px 0 0;
  transition: height 0.4s ease-out;
}

.stats-bar.bar-highlight .bar-fill {
  background: linear-gradient(180deg, #ea580c 0%, #c2410c 100%) !important;
}

.stats-bar.bar-highlight .bar-count {
  color: #ea580c !important;
}

.bar-num {
  font-size: 13px;
  font-weight: 700;
  color: #1e293b;
  margin-top: 8px;
}

/* 3-Column Rankings */
.lotto-rankings-row {
  margin-bottom: 24px;
}

.ranking-card {
  padding: 0;
  overflow: hidden;
  border-radius: 12px;
  height: 100%;
}

.ranking-card-header {
  padding: 12px 18px;
}

.ranking-card-header h3 {
  margin: 0;
  font-size: 15px;
  font-weight: 800;
  display: flex;
  align-items: center;
  gap: 8px;
}

.hot-header {
  background: #fff7ed;
  border-bottom: 2px solid #ffedd5;
  color: #c2410c;
}

.cold-header {
  background: #f0f9ff;
  border-bottom: 2px solid #e0f2fe;
  color: #0369a1;
}

.overdue-header {
  background: #faf5ff;
  border-bottom: 2px solid #f3e8ff;
  color: #7e22ce;
}

.ranking-table-wrap {
  padding: 6px 0;
}

.ranking-table {
  width: 100%;
  margin: 0;
  font-size: 13px;
  border-collapse: collapse;
}

.ranking-table th {
  padding: 8px 14px;
  font-size: 12px;
  font-weight: 700;
  color: #64748b;
  background: transparent;
  border-bottom: 1px solid #f1f5f9;
}

.ranking-table td {
  padding: 8px 14px;
  border-bottom: 1px solid #f8fafc;
}

.rank-ball-cell {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.rank-badge {
  display: inline-block;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  font-size: 11px;
  font-weight: 800;
  text-align: center;
  line-height: 20px;
  background: #f1f5f9;
  color: #64748b;
}

.rank-badge.top-1 { background: #ffd026; color: #78350f; }
.rank-badge.top-2 { background: #e2e8f0; color: #334155; }
.rank-badge.top-3 { background: #fed7aa; color: #9a3412; }

/* Sort Controls */
.stats-table-sort-controls {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.stats-sort-pill {
  background: #f1f5f9;
  border: 1px solid #cbd5e1;
  color: #334155;
  font-size: 12px;
  font-weight: 600;
  padding: 4px 12px;
  border-radius: 16px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.stats-sort-pill.active {
  background: #059669 !important;
  color: #ffffff !important;
  border-color: #047857 !important;
}

/* Master Statistics Table */
.lotto-master-stats-table {
  width: 100%;
  margin: 0;
  font-size: 13.5px;
  border-collapse: collapse;
}

.lotto-master-stats-table th {
  background: linear-gradient(180deg, #f0fdf4 0%, #dcfce7 100%) !important;
  color: #064e3b !important;
  padding: 10px 14px;
  font-weight: 700;
  border-bottom: 2px solid #86efac !important;
}

.lotto-master-stats-table td {
  padding: 10px 14px;
  border-bottom: 1px solid #e2f4e9 !important;
  vertical-align: middle;
}

.lotto-master-stats-table tr:hover td {
  background-color: #f0fdf4 !important;
}

.meter-bar-wrap {
  width: 100%;
}

.meter-bar {
  display: block;
  width: 100%;
  height: 8px;
  background: #e2e8f0;
  border-radius: 4px;
  overflow: hidden;
}

.meter-bar i {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, #38bdf8, #0070f3);
  border-radius: 4px;
  transition: width 0.4s ease;
}

.meter-bar.special i {
  background: linear-gradient(90deg, #fde047, #ea580c);
}

.gap-tag {
  display: inline-block;
  font-size: 11.5px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 12px;
}

.mobile-sub-rate {
  display: none;
}

.gap-tag.just-seen {
  background: #dcfce7;
  color: #15803d;
}

.gap-tag.recent {
  background: #eff6ff;
  color: #1d4ed8;
}

.gap-tag.normal {
  background: #f1f5f9;
  color: #475569;
}

.gap-tag.deep-cold {
  background: #fee2e2;
  color: #b91c1c;
}

.pair-balls-wrap {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.pair-plus {
  color: #94a3b8;
  font-weight: 700;
}

/* Distribution Grid */
.dist-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.dist-list.tails-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}

.dist-row {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.dist-label-row {
  display: flex;
  justify-content: space-between;
  font-size: 13px;
  color: #334155;
}

.sum-stats-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-top: 6px;
}

.sum-stat-box {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 14px;
  text-align: center;
}

.sum-stat-box.highlight {
  background: #f0fdf4;
  border-color: #bbf7d0;
}

.sum-stat-box small {
  display: block;
  font-size: 12px;
  color: #64748b;
  margin-bottom: 4px;
}

.sum-stat-box strong {
  font-size: 22px;
  font-weight: 800;
  color: #0f172a;
}

.sum-stat-box.highlight strong {
  color: #15803d;
}

/* Responsive adjustments */
@media (max-width: 900px) {
  .lotto-stats-kpi-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .drawer-metrics-row {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 600px) {
  .lotto-stats-hero {
    padding: 20px 18px;
  }
  .lotto-stats-hero h1 {
    font-size: 20px;
  }
  .lotto-stats-kpi-grid {
    grid-template-columns: 1fr;
  }
  .drawer-metrics-row {
    grid-template-columns: 1fr 1fr;
  }
  .stats-chart-wrap {
    height: 200px;
  }
  .stats-chart-axis {
    height: 150px;
  }
  .stats-chart-bars {
    height: 150px;
    gap: 6px;
  }
  .dist-list.tails-grid {
    grid-template-columns: 1fr;
  }
}

/* ==========================================================================
   COMPREHENSIVE CYCLE & GAN LÔ PAGE STYLES ([lotto_cycle_page])
   ========================================================================== */

.lotto-cycle-page-wrap {
  width: 100%;
  padding: 10px 0 50px;
  box-sizing: border-box;
}

/* Hero Section */
.lotto-cycle-hero {
  background: linear-gradient(135deg, #022015 0%, #064434 45%, #046347 80%, #057a55 100%) !important;
  color: #ffffff;
  padding: 30px 32px;
  border-radius: 16px;
  margin-bottom: 24px;
  box-shadow: 0 10px 30px rgba(2, 32, 21, 0.25);
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(52, 211, 153, 0.3);
}

.lotto-cycle-hero .breadcrumb-nav {
  margin-bottom: 12px;
  font-size: 13px;
  color: #a7f3d0;
}

.lotto-cycle-hero .breadcrumb-nav a {
  color: #d1fae5;
  text-decoration: none;
}

.lotto-cycle-hero .breadcrumb-nav a:hover {
  color: #ffffff;
}

.lotto-cycle-hero .lotto-eyebrow {
  display: inline-block;
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(134, 239, 172, 0.35);
  color: #ffd026;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 1.5px;
  padding: 4px 10px;
  border-radius: 20px;
  margin-bottom: 12px;
}

.lotto-cycle-hero h1 {
  font-size: 28px;
  font-weight: 800;
  margin: 0 0 10px;
  color: #ffffff;
  letter-spacing: -0.5px;
}

.lotto-cycle-hero p {
  font-size: 14px;
  color: #e2e8f0;
  max-width: 780px;
  line-height: 1.6;
  margin: 0;
}

/* Toolbar & Scope Tabs */
.lotto-cycle-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 12px 18px;
  margin-bottom: 22px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.lotto-cycle-scope-tabs {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.lotto-cycle-scope-btn {
  background: #f1f5f9;
  border: 1px solid #cbd5e1;
  color: #334155;
  font-size: 13px;
  font-weight: 600;
  padding: 6px 14px;
  border-radius: 20px;
  cursor: pointer;
  transition: all 0.2s ease;
  line-height: 1.2;
}

.lotto-cycle-scope-btn:hover {
  background: #e2e8f0;
  color: #0f172a;
}

.lotto-cycle-scope-btn.active {
  background: linear-gradient(135deg, #059669 0%, #047857 100%) !important;
  border-color: #047857 !important;
  color: #ffffff !important;
  box-shadow: 0 2px 6px rgba(5, 150, 105, 0.35) !important;
}

.lotto-cycle-filters-right {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}
  flex-wrap: wrap;
}

.lotto-cycle-select {
  appearance: none !important;
  -webkit-appearance: none !important;
  -moz-appearance: none !important;
  display: inline-block !important;
  width: auto;
  height: 40px !important;
  min-height: 40px !important;
  line-height: 38px !important;
  padding: 0 38px 0 14px !important;
  border: 1px solid #cbd5e1 !important;
  border-radius: 8px !important;
  font-size: 13.5px !important;
  font-weight: 600 !important;
  color: #1e293b !important;
  background-color: #ffffff !important;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%23475569' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E") !important;
  background-repeat: no-repeat !important;
  background-position: right 12px center !important;
  background-size: 16px 16px !important;
  margin: 0 !important;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04) !important;
  cursor: pointer !important;
  transition: all 0.2s ease !important;
  vertical-align: middle !important;
  box-sizing: border-box !important;
}

.lotto-cycle-select:focus {
  outline: none !important;
  border-color: #059669 !important;
  box-shadow: 0 0 0 3px rgba(5, 150, 105, 0.18) !important;
  background-color: #ffffff !important;
}

.lotto-cycle-select:hover {
  border-color: #94a3b8 !important;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.06) !important;
}

/* 4 KPI Summary Cards */
.lotto-cycle-kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-bottom: 24px;
}

.lotto-cycle-kpi-grid .lotto-kpi-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 18px 20px;
  display: flex;
  align-items: center;
  gap: 16px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.03);
  transition: transform 0.2s, box-shadow 0.2s;
}

.lotto-cycle-kpi-grid .lotto-kpi-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.06);
}

.lotto-cycle-kpi-grid .lotto-kpi-card.highlight-gan {
  border-top: 4px solid #ef4444;
}

.lotto-cycle-kpi-grid .lotto-kpi-card.highlight-streak {
  border-top: 4px solid #f59e0b;
}

.lotto-cycle-kpi-grid .lotto-kpi-card.highlight-avg,
.lotto-cycle-kpi-grid .lotto-kpi-card:nth-child(3),
.lotto-kpi-card.highlight-avg {
  border-top: 4px solid #0284c7;
}

.lotto-cycle-kpi-grid .lotto-kpi-card.highlight-alert {
  border-top: 4px solid #dc2626;
}

/* Card General Wrapper */
.lotto-cycle-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  padding: 24px;
  margin-bottom: 24px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.03);
}

.cycle-card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 20px;
}

.cycle-card-header h2 {
  font-size: 18px;
  font-weight: 800;
  color: #0f172a;
  margin: 0 0 6px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.cycle-sub-desc {
  font-size: 13px;
  color: #64748b;
  margin: 0;
  line-height: 1.5;
}

.cycle-legend {
  display: flex;
  align-items: center;
  gap: 16px;
  font-size: 12px;
  font-weight: 600;
  color: #475569;
}

.legend-item {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.legend-box {
  display: inline-block;
  width: 14px;
  height: 14px;
  border-radius: 3px;
}

.cur-gap-box {
  background: linear-gradient(90deg, #f97316, #ef4444);
}

.max-gap-box {
  background: #e2e8f0;
  border: 1px dashed #94a3b8;
}

/* Visual Top 15 Bar Chart */
.cycle-bar-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.cycle-bar-row {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 10px 14px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.cycle-bar-row:hover {
  background: #f0fdf4;
  border-color: #86efac;
  transform: translateX(4px);
}

.bar-num-col {
  flex-shrink: 0;
}

.bar-track-col {
  flex-grow: 1;
}

.bar-labels {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 6px;
  font-size: 13px;
}

.bar-name {
  color: #0f172a;
  font-weight: 700;
}

.bar-metrics {
  font-size: 12px;
  color: #64748b;
}

.metric-gap {
  color: #dc2626;
  font-weight: 800;
}

.metric-divider {
  margin: 0 6px;
  color: #cbd5e1;
}

.bar-visual-track {
  position: relative;
  height: 20px;
  background: #e2e8f0;
  border-radius: 10px;
  overflow: hidden;
}

.bar-max-marker {
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  background: rgba(148, 163, 184, 0.25);
  border-right: 2px dashed #64748b;
  z-index: 1;
}

.bar-cur-fill {
  position: relative;
  height: 100%;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  padding-right: 8px;
  z-index: 2;
  transition: width 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.bar-cur-fill.fill-extreme {
  background: linear-gradient(90deg, #f97316, #ef4444);
}

.bar-cur-fill.fill-alert {
  background: linear-gradient(90deg, #fbbf24, #f97316);
}

.bar-cur-fill.fill-normal {
  background: linear-gradient(90deg, #38bdf8, #0284c7);
}

.bar-cur-fill.fill-fresh {
  background: linear-gradient(90deg, #4ade80, #16a34a);
}

.bar-val-text {
  font-size: 11px;
  font-weight: 800;
  color: #ffffff;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.4);
  white-space: nowrap;
}

/* Matrix Visual Grid */
.matrix-filter-pills {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.matrix-pill {
  background: #f1f5f9;
  border: 1px solid #cbd5e1;
  color: #475569;
  font-size: 12px;
  font-weight: 700;
  padding: 6px 12px;
  border-radius: 16px;
  cursor: pointer;
  transition: all 0.2s;
}

.matrix-pill:hover {
  background: #e2e8f0;
}

.matrix-pill.active {
  background: #0f172a;
  border-color: #0f172a;
  color: #ffffff;
}

.matrix-pill.pill-danger.active {
  background: #dc2626;
  border-color: #dc2626;
  color: #fff;
}

.matrix-pill.pill-warning.active {
  background: #ea580c;
  border-color: #ea580c;
  color: #fff;
}

.matrix-pill.pill-normal.active {
  background: #0284c7;
  border-color: #0284c7;
  color: #fff;
}

.matrix-pill.pill-fresh.active {
  background: #16a34a;
  border-color: #16a34a;
  color: #fff;
}

.cycle-matrix-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(138px, 1fr));
  gap: 12px;
}

.matrix-tile {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 12px;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.matrix-tile:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.08);
}

.matrix-tile.tile-extreme {
  border-color: #fca5a5;
  background: #fff5f5;
}

.matrix-tile.tile-alert {
  border-color: #fed7aa;
  background: #fffaf0;
}

.matrix-tile.tile-fresh {
  border-color: #bbf7d0;
  background: #f0fdf4;
}

.matrix-tile-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.matrix-badge {
  font-size: 11px;
  font-weight: 800;
  padding: 3px 8px;
  border-radius: 12px;
}

.matrix-badge.badge-extreme {
  background: #fee2e2;
  color: #b91c1c;
  border: 1px solid #f87171;
}

.matrix-badge.badge-alert {
  background: #ffedd5;
  color: #c2410c;
  border: 1px solid #fb923c;
}

.matrix-badge.badge-normal {
  background: #f1f5f9;
  color: #334155;
  border: 1px solid #cbd5e1;
}

.matrix-badge.badge-fresh {
  background: #dcfce7;
  color: #15803d;
  border: 1px solid #86efac;
}

.tile-stat-row {
  display: flex;
  justify-content: space-between;
  font-size: 11px;
  color: #64748b;
  margin-bottom: 2px;
}

.tile-progress-bar {
  height: 4px;
  background: #e2e8f0;
  border-radius: 2px;
  overflow: hidden;
  margin-top: 4px;
}

.tile-progress-fill {
  height: 100%;
}

.tile-progress-fill.fill-extreme {
  background: #ef4444;
}

.tile-progress-fill.fill-alert {
  background: #f97316;
}

.tile-progress-fill.fill-normal {
  background: #0284c7;
}

.tile-progress-fill.fill-fresh {
  background: #16a34a;
}

/* Master Cycle Table */
.cycle-table-responsive {
  overflow-x: auto;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  background: #ffffff;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.02);
}

.cycle-master-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  font-size: 13px;
  min-width: 760px;
}

.cycle-master-table thead th {
  background: linear-gradient(180deg, #f0fdf4 0%, #dcfce7 100%) !important;
  color: #064e3b !important;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 13px 10px;
  border-bottom: 2px solid #86efac !important;
  user-select: none;
  white-space: nowrap;
  vertical-align: middle;
}

.cycle-th-short {
  display: none;
}

.cycle-master-table thead th.th-sortable {
  cursor: pointer;
  transition: all 0.2s ease;
}

.cycle-master-table thead th.th-sortable:hover {
  background: #dcfce7 !important;
  color: #064e3b !important;
}

.cycle-master-table thead th.active-sort {
  color: #059669 !important;
  border-bottom: 2px solid #059669 !important;
  background: #ecfdf5 !important;
}

.cycle-master-table thead th.active-sort .sort-icon {
  color: #059669 !important;
  font-weight: 900;
}

.cycle-master-table tbody tr {
  transition: background 0.15s ease;
}

.cycle-master-table tbody tr:nth-child(even) {
  background: #fcfdfe;
}

.cycle-master-table tbody tr:hover {
  background: #f0fdf4 !important;
}

.cycle-master-table tbody td {
  padding: 10px 10px;
  border-bottom: 1px solid #f1f5f9;
  vertical-align: middle;
  color: #1e293b;
}

.cycle-master-table tbody tr:last-child td {
  border-bottom: none;
}

/* Cell content styling */
.cycle-master-table .ball {
  width: 32px;
  height: 32px;
  font-size: 14px;
  font-weight: 800;
  margin: 0 auto;
}

.cycle-table-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 4px 10px;
  border-radius: 14px;
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}

.cycle-table-badge.badge-extreme {
  background: #fee2e2;
  color: #b91c1c;
  border: 1px solid #fca5a5;
}

.cycle-table-badge.badge-alert {
  background: #ffedd5;
  color: #c2410c;
  border: 1px solid #fdba74;
}

.cycle-table-badge.badge-normal {
  background: #f1f5f9;
  color: #334155;
  border: 1px solid #cbd5e1;
}

.cycle-table-badge.badge-fresh {
  background: #dcfce7;
  color: #15803d;
  border: 1px solid #86efac;
}

.cycle-last-draw-cell {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
}

.cycle-link-draw,
#cycle-drawer .cycle-link-draw {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  background: #eff6ff !important;
  border: 1px solid #bfdbfe !important;
  color: #1d4ed8 !important;
  font-weight: 700 !important;
  font-size: 11.5px !important;
  padding: 0 8px !important;
  min-width: 58px !important;
  height: 24px !important;
  min-height: 24px !important;
  max-height: 24px !important;
  line-height: 22px !important;
  letter-spacing: 0 !important;
  margin: 0 !important;
  border-radius: 5px !important;
  cursor: pointer !important;
  text-decoration: none !important;
  white-space: nowrap !important;
  box-sizing: border-box !important;
  appearance: none !important;
  -webkit-appearance: none !important;
  transition: all 0.15s ease !important;
}

.cycle-link-draw:hover,
#cycle-drawer .cycle-link-draw:hover {
  background: #1d4ed8 !important;
  color: #ffffff !important;
  border-color: #1d4ed8 !important;
}

.cycle-draw-meta {
  font-size: 11px;
  color: #64748b;
  white-space: nowrap;
}

.cycle-max-cell {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
}

.cycle-max-value strong {
  font-size: 13px;
  color: #0f172a;
}

.cycle-max-value small {
  color: #64748b;
  font-size: 11px;
}

.table-progress-wrap {
  width: 80px;
  height: 5px;
  background: #e2e8f0;
  border-radius: 999px;
  overflow: hidden;
  margin: 1px 0;
}

.table-progress-fill {
  height: 100%;
  border-radius: 999px;
  transition: width 0.3s ease;
}

.table-progress-fill.fill-extreme {
  background: linear-gradient(90deg, #f97316, #ef4444);
}

.table-progress-fill.fill-alert {
  background: linear-gradient(90deg, #fbbf24, #f97316);
}

.table-progress-fill.fill-normal {
  background: linear-gradient(90deg, #38bdf8, #0284c7);
}

.table-progress-fill.fill-fresh {
  background: linear-gradient(90deg, #4ade80, #16a34a);
}

.table-progress-sub {
  font-size: 10px;
  color: #64748b;
  font-weight: 600;
  white-space: nowrap;
}

.cycle-avg-cell strong {
  font-size: 13px;
  color: #0f172a;
}

.cycle-avg-cell small {
  color: #64748b;
  font-size: 11px;
}

.cycle-count-cell {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  white-space: nowrap;
}

.cycle-count-cell strong {
  font-size: 13px;
  color: #0f172a;
}

.cycle-count-cell small {
  color: #64748b;
  font-size: 11px;
}

.cycle-rate-badge {
  background: #f1f5f9;
  color: #475569;
  font-size: 10px;
  font-weight: 700;
  padding: 1px 5px;
  border-radius: 8px;
}

.cycle-inspect-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  white-space: nowrap !important;
  background: #f0fdfa;
  border: 1px solid #99f6e4;
  color: #0d9488;
  font-size: 12px;
  font-weight: 700;
  padding: 5px 14px;
  border-radius: 18px;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03);
}

.cycle-inspect-btn:hover {
  background: #00897b;
  border-color: #00897b;
  color: #ffffff;
  transform: translateY(-1px);
  box-shadow: 0 2px 6px rgba(0, 137, 123, 0.25);
}

.cycle-search-field {
  border: 1px solid #cbd5e1;
  border-radius: 20px;
  padding: 8px 16px;
  font-size: 13px;
  width: 230px;
  background: #f8fafc;
  transition: all 0.2s;
}

.cycle-search-field:focus {
  outline: none;
  border-color: #00897b;
  background: #ffffff;
  box-shadow: 0 0 0 3px rgba(0, 137, 123, 0.15);
}

/* Cycle Deep-Dive Drawer */
.cycle-drawer-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(15, 23, 42, 0.45);
  backdrop-filter: blur(2px);
  z-index: 99998;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.cycle-drawer-overlay.open {
  opacity: 1;
  pointer-events: auto;
}

.cycle-drawer {
  position: fixed;
  top: 0;
  right: -520px;
  width: 480px;
  max-width: 90vw;
  height: 100vh;
  background: #ffffff;
  box-shadow: -10px 0 35px rgba(0, 0, 0, 0.15);
  z-index: 99999;
  display: flex;
  flex-direction: column;
  transition: right 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

.cycle-drawer.open {
  right: 0;
}

.cycle-drawer-header {
  padding: 20px 24px;
  background: #0f172a;
  color: #ffffff;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.drawer-title-row {
  display: flex;
  align-items: center;
  gap: 14px;
}

.drawer-title-row h3 {
  font-size: 16px;
  font-weight: 800;
  margin: 0;
  color: #ffffff;
}

.drawer-meta {
  font-size: 12px;
  color: #94a3b8;
}

.drawer-close-btn {
  background: rgba(255, 255, 255, 0.1);
  border: none;
  color: #ffffff;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  font-size: 16px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s;
}

.drawer-close-btn:hover {
  background: rgba(255, 255, 255, 0.25);
}

.cycle-drawer-body {
  padding: 24px;
  overflow-y: auto;
  flex-grow: 1;
}

.drawer-kpi-row {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  margin-bottom: 24px;
}

.drawer-kpi-item {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.drawer-kpi-item span {
  font-size: 12px;
  color: #64748b;
}

.drawer-kpi-item strong {
  font-size: 18px;
  font-weight: 800;
  color: #0f172a;
}

.drawer-section-title h4 {
  font-size: 14px;
  font-weight: 800;
  color: #0f172a;
  margin: 0 0 12px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.drawer-table-wrap {
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  overflow: hidden;
  background: #ffffff;
}

.drawer-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
  table-layout: fixed;
}

.drawer-table th {
  background: #f1f5f9;
  color: #475569;
  padding: 8px 10px;
  font-weight: 700;
  border-bottom: 1px solid #e2e8f0;
}

.drawer-table td {
  padding: 8px 10px;
  border-bottom: 1px solid #f1f5f9;
  vertical-align: middle;
}

.drawer-th-draw, .drawer-col-draw { width: 17%; text-align: center; }
.drawer-th-date, .drawer-col-date { width: 21%; text-align: center; }
.drawer-th-gap, .drawer-col-gap { width: 17%; text-align: center; }
.drawer-th-balls, .drawer-col-balls { width: 45%; text-align: center; }

.drawer-date-short { display: none; }
.drawer-date-full { display: inline; font-size: 12px; color: #1e293b; }
.drawer-draw-time { display: inline; font-size: 11px; color: #64748b; margin-left: 2px; }

.th-text-short { display: none; }
.th-text-full { display: inline; }

.cycle-drawer-balls-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: nowrap;
  gap: 3px;
  width: 100%;
}

.cycle-drawer-balls-wrap .ball {
  width: 25px;
  height: 25px;
  font-size: 11.5px;
  font-weight: 700;
  flex: 0 0 25px;
  margin: 0;
}

.interval-badge {
  background: #e0f2fe;
  color: #0369a1;
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 11px;
  white-space: nowrap;
}

/* Educational Guide Box */
.lotto-cycle-guide-box {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  padding: 24px;
  margin-top: 30px;
}

.lotto-cycle-guide-box h3 {
  font-size: 18px;
  font-weight: 800;
  color: #0f172a;
  margin: 0 0 18px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.guide-content-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}

.guide-item h4 {
  font-size: 14px;
  font-weight: 700;
  color: #0f766e;
  margin: 0 0 8px;
}

.guide-item p {
  font-size: 13px;
  line-height: 1.6;
  color: #475569;
  margin: 0;
}

/* Responsive Breakpoints & Mobile Overrides */
@media (max-width: 992px) {
  .lotto-cycle-kpi-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .guide-content-grid {
    grid-template-columns: 1fr;
  }
}

/* Remove Flatsome 30px padding on mobile & tablet */
@media (max-width: 849px) {
  #content.page-wrapper,
  .page-wrapper,
  .content-area {
    padding-top: 5px !important;
    padding-bottom: 20px !important;
  }

  .page-wrapper .container {
    padding-left: 10px !important;
    padding-right: 10px !important;
    max-width: 100% !important;
  }

  .col,
  .columns {
    padding-bottom: 0 !important;
  }

  .lotto-cycle-page-wrap,
  .lotto-stats-page-wrap,
  .subpage-container {
    padding-left: 0 !important;
    padding-right: 0 !important;
    padding-top: 0 !important;
    padding-bottom: 25px !important;
  }
}

/* Optimized Mobile Tab & Toolbar Layout */
@media (max-width: 640px) {
  .lotto-cycle-hero,
  .lotto-stats-hero {
    padding: 20px 14px !important;
    border-radius: 12px !important;
    margin-bottom: 16px !important;
  }

  .lotto-cycle-hero h1,
  .lotto-stats-hero h1 {
    font-size: 20px !important;
  }

  /* Toolbar Container */
  .lotto-cycle-toolbar,
  .lotto-stats-toolbar {
    padding: 14px 12px !important;
    gap: 14px !important;
    flex-direction: column !important;
    align-items: stretch !important;
    border-radius: 12px !important;
    margin-bottom: 18px !important;
  }

  /* Scope tabs (Phạm vi) - Balanced Segmented Grid */
  .lotto-cycle-scope-tabs,
  .lotto-stats-scope-tabs {
    display: flex !important;
    flex-wrap: wrap !important;
    gap: 6px !important;
    width: 100% !important;
  }

  .lotto-cycle-scope-tabs .lotto-filter-label,
  .lotto-stats-scope-tabs .lotto-filter-label {
    display: block !important;
    width: 100% !important;
    font-size: 11px !important;
    font-weight: 800 !important;
    color: #64748b !important;
    text-transform: uppercase !important;
    letter-spacing: 0.6px !important;
    margin-bottom: 2px !important;
  }

  .lotto-cycle-scope-btn,
  .lotto-scope-btn {
    flex: 1 1 calc(33.333% - 6px) !important;
    min-width: calc(33.333% - 6px) !important;
    text-align: center !important;
    padding: 9px 4px !important;
    font-size: 13px !important;
    font-weight: 700 !important;
    border-radius: 8px !important;
    white-space: nowrap !important;
    box-sizing: border-box !important;
  }

  /* Filters Right (Khung giờ & Loại bóng) */
  .lotto-cycle-filters-right,
  .lotto-stats-time-filter-wrap {
    display: flex !important;
    flex-direction: column !important;
    gap: 10px !important;
    width: 100% !important;
  }

  .lotto-filter-group {
    display: flex !important;
    flex-direction: column !important;
    gap: 4px !important;
    width: 100% !important;
  }

  .lotto-filter-group .lotto-filter-label,
  .lotto-stats-time-filter-wrap .lotto-filter-label {
    font-size: 11px !important;
    font-weight: 800 !important;
    color: #64748b !important;
    text-transform: uppercase !important;
    letter-spacing: 0.6px !important;
    margin-bottom: 2px !important;
  }

  .lotto-cycle-select,
  .lotto-stats-select {
    width: 100% !important;
    height: 44px !important;
    min-height: 44px !important;
    line-height: 42px !important;
    padding: 0 38px 0 14px !important;
    font-size: 13.5px !important;
    border-radius: 8px !important;
  }

  /* Matrix Filter Pills on Cycle Page - Horizontal Scroll Chips */
  .matrix-header-flex {
    flex-direction: column !important;
    align-items: stretch !important;
    gap: 10px !important;
  }

  .matrix-filter-pills {
    display: flex !important;
    flex-wrap: nowrap !important;
    overflow-x: auto !important;
    -webkit-overflow-scrolling: touch !important;
    scrollbar-width: none !important;
    gap: 6px !important;
    padding-bottom: 4px !important;
    width: 100% !important;
  }

  .matrix-filter-pills::-webkit-scrollbar {
    display: none !important;
  }

  .matrix-pill {
    flex: 0 0 auto !important;
    font-size: 12px !important;
    padding: 7px 14px !important;
    border-radius: 20px !important;
    white-space: nowrap !important;
  }

  /* Main Navigation Tabs on Stats Page - 2x2 Full Width Balanced Grid (No Horizontal Scroll) */
  .lotto-stats-main-nav,
  .stats-nav-tabs {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 8px !important;
    width: 100% !important;
    overflow: visible !important;
    padding-bottom: 4px !important;
    margin-bottom: 16px !important;
    border-bottom: 1px solid #e2e8f0 !important;
    box-sizing: border-box !important;
  }

  .lotto-stats-main-nav::-webkit-scrollbar,
  .stats-nav-tabs::-webkit-scrollbar {
    display: none !important;
  }

  .lotto-stats-main-nav .stats-nav-btn,
  .stats-nav-btn {
    width: 100% !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    text-align: center !important;
    font-size: 12px !important;
    font-weight: 700 !important;
    padding: 9px 4px !important;
    white-space: normal !important;
    border-radius: 10px !important;
    line-height: 1.25 !important;
    box-sizing: border-box !important;
    min-height: 44px !important;
  }

  /* Cards & Grids on Mobile */
  .lotto-cycle-card,
  .stats-section-card {
    padding: 16px 5px !important;
    border-radius: 12px !important;
    margin-bottom: 16px !important;
  }

  /* 2x2 KPI Grids on Mobile for compact screen efficiency */
  .lotto-cycle-kpi-grid,
  .lotto-stats-kpi-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 8px !important;
    margin-bottom: 16px !important;
    width: 100% !important;
    box-sizing: border-box !important;
  }

  .lotto-cycle-kpi-grid .lotto-kpi-card,
  .lotto-stats-kpi-grid .lotto-kpi-card,
  .lotto-kpi-card {
    padding: 10px 8px !important;
    gap: 8px !important;
    border-radius: 10px !important;
    min-width: 0 !important;
    box-sizing: border-box !important;
    width: 100% !important;
    align-items: flex-start !important;
  }

  .lotto-kpi-card .kpi-icon {
    font-size: 20px !important;
    flex-shrink: 0 !important;
    margin-top: 2px !important;
  }

  .lotto-kpi-card .kpi-info {
    min-width: 0 !important;
    flex: 1 1 0% !important;
  }

  .lotto-kpi-card .kpi-title {
    font-size: 10px !important;
    margin-bottom: 2px !important;
    white-space: normal !important;
    line-height: 1.25 !important;
    word-break: break-word !important;
  }

  .lotto-kpi-card .kpi-val-row {
    min-width: 0 !important;
    flex-wrap: wrap !important;
    gap: 4px !important;
  }

  .lotto-kpi-card .kpi-value {
    font-size: 14px !important;
    white-space: nowrap !important;
  }

  .lotto-kpi-card .kpi-sub {
    font-size: 10px !important;
    white-space: normal !important;
    overflow: visible !important;
    text-overflow: clip !important;
    display: block !important;
    width: 100% !important;
    max-width: 100% !important;
    line-height: 1.35 !important;
    word-break: break-word !important;
  }

  .lotto-kpi-card .ball {
    width: 22px !important;
    height: 22px !important;
    font-size: 11px !important;
    flex-shrink: 0 !important;
  }

  /* 01-35 Number Selector Card on Mobile (5 rows x 7 balls) */
  .lotto-stats-selector-card {
    padding: 42px 10px 14px !important;
    margin: 20px 0 16px !important;
    border-radius: 12px !important;
  }

  .lotto-stats-header-ribbon {
    font-size: 13px !important;
    padding: 5px 24px 6px !important;
    white-space: nowrap !important;
    clip-path: polygon(0 0, 100% 0, calc(100% - 12px) 100%, 12px 100%) !important;
  }

  .lotto-num-rows-wrap {
    display: grid !important;
    grid-template-columns: repeat(7, 38px) !important;
    justify-content: center !important;
    gap: 8px 6px !important;
    max-width: 100% !important;
    margin: 14px auto 0 !important;
  }

  .lotto-num-row {
    display: contents !important;
  }

  .lotto-num-btn {
    width: 38px !important;
    height: 38px !important;
    font-size: 13px !important;
    border-radius: 50% !important;
    margin: 0 !important;
    padding: 0 !important;
    box-sizing: border-box !important;
  }

  @media (max-width: 360px) {
    .lotto-num-rows-wrap {
      grid-template-columns: repeat(7, 34px) !important;
      gap: 6px 4px !important;
    }
    .lotto-num-btn {
      width: 34px !important;
      height: 34px !important;
      font-size: 12px !important;
    }
  }

  .lotto-stats-selector-footer {
    margin-top: 10px !important;
    font-size: 11.5px !important;
  }

  /* Number Deep-Dive Drawer on Mobile */
  .stats-number-drawer {
    padding: 14px 10px !important;
    margin-bottom: 16px !important;
    border-radius: 12px !important;
  }

  .drawer-header {
    margin-bottom: 12px !important;
  }

  .drawer-header h3 {
    font-size: 14px !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    line-height: 1.25 !important;
  }

  .drawer-subtitle {
    font-size: 11px !important;
  }

  .drawer-metrics-row {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 8px !important;
    margin-bottom: 12px !important;
  }

  .drawer-metric {
    padding: 8px 10px !important;
    border-radius: 8px !important;
  }

  .drawer-metric small {
    font-size: 11px !important;
  }

  .drawer-metric strong {
    font-size: 16px !important;
  }

  /* Drawer Recent Draws Row Layout on Mobile (identical to ket-qua history rows) */
  .drawer-history-list {
    border-radius: 8px !important;
    border-color: #fed7aa !important;
    width: 100% !important;
    overflow: hidden !important;
  }

  .drawer-history-row {
    display: flex !important;
    flex-direction: column !important;
    align-items: stretch !important;
    gap: 6px !important;
    padding: 10px 10px !important;
    border-top: 1px solid #ffedd5 !important;
    box-sizing: border-box !important;
    width: 100% !important;
  }

  .drawer-history-row .history-draw-col {
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    width: 100% !important;
    line-height: 1.2 !important;
  }

  .drawer-history-row .history-draw-id {
    font-size: 13.5px !important;
    color: #0055ff !important;
    font-weight: 800 !important;
  }

  .drawer-history-row .history-draw-datetime {
    font-size: 11px !important;
    color: #64748b !important;
  }

  .drawer-history-row .result-balls {
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    gap: 5px !important;
    width: 100% !important;
    padding: 4px 0 !important;
    flex-wrap: nowrap !important;
  }

  .drawer-history-row .result-balls .ball {
    width: 32px !important;
    height: 32px !important;
    font-size: 13px !important;
    flex: 0 0 32px !important;
    margin: 0 !important;
  }

  .drawer-history-row .result-balls .ball.gold {
    margin-left: 2px !important;
  }

  .drawer-history-row .history-prize {
    display: flex !important;
    justify-content: flex-start !important;
    align-items: baseline !important;
    width: 100% !important;
    gap: 4px !important;
    margin-top: 2px !important;
  }

  .drawer-history-row .history-prize-mobile-label {
    display: inline !important;
    color: #64748b !important;
    font-size: 11px !important;
    font-weight: 500 !important;
    white-space: nowrap !important;
  }

  .drawer-history-row .history-prize-val {
    color: #d80000 !important;
    font-size: 12.5px !important;
    font-weight: 700 !important;
    white-space: nowrap !important;
  }

  .drawer-draws-table-wrap {
    overflow-x: auto !important;
    -webkit-overflow-scrolling: touch !important;
    width: 100% !important;
    border-radius: 8px !important;
  }

  .drawer-results-table {
    min-width: 0 !important;
    width: 100% !important;
  }

  .drawer-results-table th,
  .drawer-results-table td {
    padding: 6px 8px !important;
    font-size: 12px !important;
  }

  .drawer-results-table .ball {
    width: 24px !important;
    height: 24px !important;
    font-size: 11px !important;
    margin: 0 1px !important;
  }

  /* Frequency Bar Chart on Mobile */
  .stats-chart-wrap {
    overflow-x: hidden !important;
    height: 200px !important;
    padding-bottom: 6px !important;
    width: 100% !important;
  }

  .stats-chart-axis {
    height: 150px !important;
    flex: 0 0 auto !important;
  }

  .stats-chart-bars {
    min-width: 0 !important;
    width: 100% !important;
    height: 150px !important;
    gap: 4px !important;
  }

  /* 3-Column Rankings on Mobile */
  .lotto-rankings-row .col {
    margin-bottom: 12px !important;
  }

  .ranking-card {
    border-radius: 10px !important;
  }

  .ranking-card-header {
    padding: 10px 14px !important;
  }

  .ranking-card-header h3 {
    font-size: 14px !important;
  }

  .ranking-table th,
  .ranking-table td {
    padding: 6px 10px !important;
    font-size: 12px !important;
  }

  /* Master Frequency Tables & Sort Controls - 100% Full Width (No Horizontal Scroll) */
  .stats-table-sort-controls {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 6px !important;
    width: 100% !important;
    margin-top: 8px !important;
    overflow: visible !important;
    box-sizing: border-box !important;
  }

  .stats-table-sort-controls span {
    grid-column: 1 / -1 !important;
    font-size: 11px !important;
    font-weight: 700 !important;
    color: #64748b !important;
    text-transform: uppercase !important;
    margin-bottom: 2px !important;
  }

  .stats-sort-pill {
    width: 100% !important;
    text-align: center !important;
    justify-content: center !important;
    font-size: 12px !important;
    font-weight: 600 !important;
    padding: 7px 4px !important;
    white-space: nowrap !important;
    border-radius: 8px !important;
    box-sizing: border-box !important;
  }

  .table-scroll {
    overflow-x: visible !important;
    width: 100% !important;
    box-sizing: border-box !important;
  }

  .lotto-master-stats-table {
    min-width: 0 !important;
    width: 100% !important;
    table-layout: fixed !important;
    border-collapse: collapse !important;
  }

  .lotto-master-stats-table th,
  .lotto-master-stats-table td {
    padding: 8px 4px !important;
    font-size: 12px !important;
    box-sizing: border-box !important;
  }

  /* Columns hidden on mobile to eliminate horizontal scrolling */
  .lotto-master-stats-table .col-meter,
  .lotto-master-stats-table .col-rate {
    display: none !important;
  }

  /* Column widths for Main 35 Numbers Table */
  .lotto-master-stats-table .col-num {
    width: 44px !important;
    text-align: center !important;
  }

  .lotto-master-stats-table .col-count {
    width: 54px !important;
    text-align: center !important;
  }

  .lotto-master-stats-table .col-gap {
    width: 76px !important;
    text-align: center !important;
  }

  .lotto-master-stats-table .col-last {
    text-align: right !important;
    font-size: 11.5px !important;
  }

  /* Special Balls Table Column widths */
  .lotto-special-table .col-num {
    width: 60px !important;
    text-align: center !important;
  }

  .lotto-special-table .col-count {
    width: 75px !important;
    text-align: center !important;
  }

  .lotto-special-table .col-gap {
    text-align: center !important;
  }

  /* Pairs Table Column widths */
  .lotto-pairs-table .col-rank {
    width: 32px !important;
    text-align: center !important;
  }

  .lotto-pairs-table .col-pair {
    width: 82px !important;
    text-align: center !important;
  }

  .lotto-pairs-table .col-count {
    width: 65px !important;
    text-align: center !important;
  }

  .lotto-pairs-table .col-last {
    text-align: right !important;
    font-size: 11px !important;
  }

  .mobile-sub-rate {
    display: block !important;
    font-size: 10.5px !important;
    line-height: 1 !important;
    margin-top: 2px !important;
  }

  .lotto-master-stats-table .ball {
    width: 28px !important;
    height: 28px !important;
    font-size: 12px !important;
    margin: 0 auto !important;
    flex: 0 0 28px !important;
  }

  .lotto-master-stats-table .gap-tag {
    font-size: 10.5px !important;
    padding: 3px 5px !important;
    white-space: nowrap !important;
    border-radius: 8px !important;
  }

  .pair-balls-wrap {
    display: inline-flex !important;
    align-items: center !important;
    gap: 2px !important;
    justify-content: center !important;
  }

  .pair-balls-wrap .ball {
    width: 25px !important;
    height: 25px !important;
    font-size: 11px !important;
    margin: 0 !important;
    flex: 0 0 25px !important;
  }

  .pair-plus {
    font-size: 10px !important;
    margin: 0 1px !important;
    color: #94a3b8 !important;
  }

  .cycle-matrix-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 8px !important;
  }

  /* Cycle Detail Drawer Mobile Optimization */
  .cycle-drawer {
    width: 100vw !important;
    max-width: 100vw !important;
    right: -100vw !important;
    left: auto !important;
    box-shadow: none !important;
    border-radius: 0 !important;
  }

  .cycle-drawer.open {
    right: 0 !important;
    left: 0 !important;
  }

  .cycle-drawer-header {
    padding: 12px 14px !important;
  }

  .cycle-drawer-header .drawer-title-row {
    gap: 10px !important;
    flex: 1 1 auto !important;
    min-width: 0 !important;
  }

  .cycle-drawer-header .drawer-title-row .ball {
    width: 32px !important;
    height: 32px !important;
    font-size: 14px !important;
    flex-shrink: 0 !important;
  }

  .cycle-drawer-header h3 {
    font-size: 14px !important;
    line-height: 1.3 !important;
    margin: 0 !important;
    color: #ffffff !important;
    word-break: break-word !important;
  }

  .cycle-drawer-header .drawer-meta {
    font-size: 11px !important;
    line-height: 1.25 !important;
    color: #94a3b8 !important;
    display: block !important;
    margin-top: 2px !important;
  }

  .cycle-drawer-header .drawer-close-btn {
    width: 30px !important;
    height: 30px !important;
    font-size: 14px !important;
    flex-shrink: 0 !important;
    margin-left: 8px !important;
  }

  .cycle-drawer-body {
    padding: 14px 10px 40px !important;
  }

  .drawer-kpi-row {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 8px !important;
    margin-bottom: 14px !important;
  }

  .drawer-kpi-item {
    padding: 8px 10px !important;
    border-radius: 8px !important;
    gap: 2px !important;
  }

  .drawer-kpi-item span {
    font-size: 10.5px !important;
  }

  .drawer-kpi-item strong {
    font-size: 15px !important;
  }

  .drawer-section-title h4 {
    font-size: 12.5px !important;
    margin: 0 0 8px !important;
  }

  .drawer-table-wrap {
    border: 1px solid #e2e8f0 !important;
    border-radius: 8px !important;
    overflow: hidden !important;
    width: 100% !important;
  }

  .drawer-table {
    table-layout: fixed !important;
    width: 100% !important;
    font-size: 11px !important;
  }

  .drawer-th-draw, .drawer-col-draw {
    width: 17% !important;
    text-align: center !important;
    padding: 7px 2px !important;
  }

  .drawer-th-date, .drawer-col-date {
    width: 18% !important;
    text-align: center !important;
    padding: 7px 2px !important;
  }

  .drawer-th-gap, .drawer-col-gap {
    width: 17% !important;
    text-align: center !important;
    padding: 7px 2px !important;
  }

  .drawer-th-balls, .drawer-col-balls {
    width: 48% !important;
    text-align: center !important;
    padding: 7px 2px !important;
  }

  .th-text-short {
    display: inline !important;
  }

  .th-text-full {
    display: none !important;
  }

  .drawer-date-short {
    display: block !important;
    font-weight: 500 !important;
    font-size: 11px !important;
    color: #1e293b !important;
    line-height: 1.2 !important;
  }

  .drawer-date-full {
    display: none !important;
  }

  .drawer-draw-time {
    display: block !important;
    font-size: 9.5px !important;
    color: #64748b !important;
    line-height: 1.1 !important;
  }

  .cycle-link-draw,
  #cycle-drawer .cycle-link-draw {
    font-size: 11px !important;
    padding: 0 6px !important;
    min-width: 54px !important;
    height: 22px !important;
    min-height: 22px !important;
    max-height: 22px !important;
    line-height: 20px !important;
    letter-spacing: 0 !important;
    margin: 0 !important;
    background: #eff6ff !important;
    color: #2563eb !important;
    border: 1px solid #bfdbfe !important;
    border-radius: 4px !important;
    font-weight: 700 !important;
  }

  .interval-badge {
    font-size: 10px !important;
    padding: 2px 4px !important;
    border-radius: 4px !important;
    white-space: nowrap !important;
  }

  .cycle-drawer-balls-wrap {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    flex-wrap: nowrap !important;
    gap: 2.5px !important;
    width: 100% !important;
  }

  .cycle-drawer-balls-wrap .ball {
    width: 21px !important;
    height: 21px !important;
    font-size: 10px !important;
    font-weight: 700 !important;
    flex: 0 0 21px !important;
    margin: 0 !important;
    border-width: 1.5px !important;
  }

  .cycle-drawer-balls-wrap .ball.gold {
    margin-left: 1.5px !important;
  }

  /* ==========================================================================
     Results Page (/ket-qua/) Mobile Responsive Enhancements
     ========================================================================== */
  .page-hero {
    padding: 20px 16px 24px !important;
  }

  .page-hero h1 {
    font-size: 20px !important;
    margin-bottom: 6px !important;
  }

  .page-hero p {
    font-size: 13px !important;
    line-height: 1.5 !important;
  }

  .page-layout {
    grid-template-columns: 1fr !important;
    gap: 14px !important;
  }

  .page-content {
    min-width: 0 !important;
    width: 100% !important;
  }

  .page-aside {
    min-width: 0 !important;
    width: 100% !important;
    margin-top: 10px !important;
  }

  .page-aside .card {
    padding: 14px 12px !important;
    border-radius: 12px !important;
    margin-bottom: 12px !important;
  }

  .time-block {
    display: flex !important;
    justify-content: space-between !important;
    padding: 8px 10px !important;
    font-size: 13px !important;
  }

  /* Live Draw Card on Results Page */
  .lotto-live-card {
    padding: 14px 10px !important;
    border-radius: 12px !important;
    margin-bottom: 14px !important;
  }

  .lotto-live-header {
    flex-direction: column !important;
    align-items: flex-start !important;
    gap: 6px !important;
    padding-bottom: 10px !important;
    margin-bottom: 10px !important;
  }

  .lotto-live-title h2 {
    font-size: 15px !important;
    flex-wrap: wrap !important;
    gap: 6px !important;
    line-height: 1.35 !important;
  }

  .lotto-live-period-tag {
    font-size: 15px !important;
  }

  .lotto-live-meta {
    flex-direction: column !important;
    align-items: flex-start !important;
    gap: 5px !important;
    font-size: 12px !important;
    margin-bottom: 12px !important;
  }

  .lotto-live-balls-arena {
    padding: 16px 8px !important;
    border-radius: 12px !important;
    margin-bottom: 14px !important;
  }

  #lotto-live-status-text {
    font-size: 13px !important;
    margin-bottom: 10px !important;
  }

  .lotto-live-balls {
    gap: 6px !important;
    justify-content: center !important;
  }

  .lotto-live-balls .ball {
    width: 40px !important;
    height: 40px !important;
    font-size: 18px !important;
    border-width: 2.5px !important;
    flex: 0 0 40px !important;
  }

  .lotto-live-balls .ball.gold {
    margin-left: 2px !important;
  }

  .lotto-prize-header-bar {
    padding: 8px 10px !important;
    font-size: 13.5px !important;
    border-radius: 8px 8px 0 0 !important;
  }
  .lotto-prize-header-bar span:first-child {
    font-size: 13px !important;
  }
  .lotto-prize-header-bar #live-table-jp {
    font-size: 14px !important;
  }

  .lotto-prize-structure-wrap .table-scroll,
  .lotto-popup-content .table-scroll,
  .lotto-history-tier-drawer .table-scroll {
    overflow-x: hidden !important;
    width: 100% !important;
    margin: 0 !important;
    border: none !important;
    border-radius: 4px !important;
    padding: 0 !important;
  }

  .card.lotto-history-container,
  .lotto-history-container {
    padding: 12px 6px !important;
  }

  .history-row {
    padding: 10px 4px !important;
  }

  .lotto-history-tier-drawer {
    grid-column: 1 / -1 !important;
    margin-left: -4px !important;
    margin-right: -4px !important;
    width: calc(100% + 8px) !important;
    padding: 8px 3px !important;
    margin-top: 6px !important;
    overflow-x: hidden !important;
    box-sizing: border-box !important;
    border-radius: 6px !important;
  }

  /* Modal Dialog on Mobile */
  dialog#info-dialog {
    width: calc(100% - 20px) !important;
    max-width: 100% !important;
    padding: 14px 10px !important;
    border-radius: 12px !important;
    box-sizing: border-box !important;
  }
  dialog#info-dialog #dialog-title {
    font-size: 14.5px !important;
    padding-right: 40px !important;
    margin: 0 0 12px 0 !important;
    line-height: 1.35 !important;
    color: #173265 !important;
    font-weight: 800 !important;
    display: block !important;
  }
  dialog#info-dialog button.dialog-close,
  dialog#info-dialog .dialog-close {
    padding: 0 !important;
    margin: 0 !important;
    min-height: 0 !important;
    min-width: 0 !important;
    line-height: 1 !important;
    box-sizing: border-box !important;
    position: absolute !important;
    right: 10px !important;
    top: 10px !important;
    font-size: 19px !important;
    width: 26px !important;
    height: 26px !important;
    border-radius: 50% !important;
    background: #f1f5f9 !important;
    border: none !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    color: #64748b !important;
    cursor: pointer !important;
    z-index: 10 !important;
  }
  .lotto-dialog-balls {
    margin: 10px 0 16px !important;
  }
  .lotto-dialog-balls .ball {
    width: 32px !important;
    height: 32px !important;
    font-size: 14px !important;
    flex: 0 0 32px !important;
  }

  .table-vietlott-structure {
    min-width: 0 !important;
    width: 100% !important;
    table-layout: fixed !important;
    border-collapse: collapse !important;
  }

  .table-vietlott-structure th,
  .table-vietlott-structure td {
    padding: 6px 2px !important;
    font-size: 11.5px !important;
    line-height: 1.2 !important;
  }

  .table-vietlott-structure th {
    white-space: normal !important;
    font-size: 10.5px !important;
    line-height: 1.15 !important;
    padding: 6px 2px !important;
    vertical-align: middle !important;
  }
  .prize-th-full {
    display: none !important;
  }
  .prize-th-short {
    display: inline !important;
  }

  .table-vietlott-structure th:nth-child(1),
  .table-vietlott-structure td:nth-child(1) {
    width: 23% !important;
    text-align: left !important;
  }
  .table-vietlott-structure th:nth-child(2),
  .table-vietlott-structure td:nth-child(2) {
    width: 30% !important;
    text-align: center !important;
  }
  .table-vietlott-structure th:nth-child(3),
  .table-vietlott-structure td:nth-child(3) {
    width: 18% !important;
    text-align: center !important;
  }
  .table-vietlott-structure th:nth-child(4),
  .table-vietlott-structure td:nth-child(4) {
    width: 29% !important;
    text-align: right !important;
    white-space: nowrap !important;
    font-weight: 700 !important;
  }

  .table-vietlott-structure .lotto-dot {
    width: 7.5px !important;
    height: 7.5px !important;
  }
  .table-vietlott-structure .lotto-dot-plus {
    font-size: 7.5px !important;
    width: 4.5px !important;
  }
  .table-vietlott-structure .lotto-match-pattern {
    gap: 1px !important;
  }
  .table-vietlott-structure .lotto-match-main {
    width: 44px !important;
    gap: 1px !important;
  }

  /* Homepage Results Table on Mobile: Card Layout with Zero Horizontal Overflow */
  #results .table-scroll {
    overflow-x: visible !important;
    border: none !important;
    padding: 0 !important;
  }
  table.results-table {
    display: block !important;
    width: 100% !important;
  }
  table.results-table thead {
    display: none !important;
  }
  table.results-table tbody {
    display: flex !important;
    flex-direction: column !important;
    gap: 10px !important;
    width: 100% !important;
  }
  table.results-table tr {
    display: flex !important;
    flex-wrap: wrap !important;
    align-items: center !important;
    justify-content: space-between !important;
    background: #ffffff !important;
    border: 1px solid #e2edfa !important;
    border-radius: 10px !important;
    padding: 10px 12px !important;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.03) !important;
    margin: 0 !important;
    box-sizing: border-box !important;
  }
  table.results-table td {
    border: none !important;
    padding: 0 !important;
    box-sizing: border-box !important;
  }
  table.results-table td.col-draw-id {
    order: 1 !important;
    flex: 0 0 auto !important;
  }
  table.results-table td.col-draw-id button.text-link {
    font-size: 15px !important;
    font-weight: 800 !important;
    color: #0055ff !important;
  }
  table.results-table td.col-draw-date {
    order: 2 !important;
    flex: 0 0 auto !important;
    font-size: 13px !important;
    color: #64748b !important;
    margin-left: auto !important;
  }
  table.results-table td.col-draw-time {
    order: 3 !important;
    flex: 0 0 auto !important;
    font-size: 13px !important;
    color: #94a3b8 !important;
    margin-left: 6px !important;
  }
  table.results-table td.col-draw-balls {
    order: 4 !important;
    flex: 0 0 100% !important;
    margin: 8px 0 6px 0 !important;
    text-align: center !important;
  }
  table.results-table td.col-draw-balls .result-balls {
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    gap: 6px !important;
    width: 100% !important;
  }
  table.results-table td.col-draw-balls .ball {
    width: 32px !important;
    height: 32px !important;
    font-size: 14px !important;
    flex: 0 0 32px !important;
    margin: 0 !important;
  }
  table.results-table td.col-draw-balls .ball.gold {
    margin-left: 4px !important;
  }
  table.results-table td.col-draw-prize {
    order: 5 !important;
    flex: 0 0 100% !important;
    display: flex !important;
    justify-content: flex-end !important;
    align-items: center !important;
    gap: 6px !important;
    font-size: 13.5px !important;
    color: #d80000 !important;
    font-weight: 700 !important;
    padding-top: 6px !important;
    border-top: 1px dashed #f1f5f9 !important;
  }
  table.results-table td.col-draw-prize::before {
    content: "Giải Độc Đắc: ";
    font-size: 12px;
    font-weight: 500;
    color: #64748b;
    margin-right: auto;
  }

  /* Cycle Master Table on Mobile: Fits 100% Width Without Horizontal Scroll */
  .cycle-table-responsive {
    overflow-x: hidden !important;
    width: 100% !important;
    border-radius: 8px !important;
  }
  .cycle-master-table {
    min-width: 0 !important;
    width: 100% !important;
    table-layout: fixed !important;
  }
  .cycle-master-table thead th {
    white-space: normal !important;
    word-break: normal !important;
    font-size: 11px !important;
    line-height: 1.2 !important;
    padding: 8px 2px !important;
    vertical-align: middle !important;
    letter-spacing: 0 !important;
  }
  .cycle-master-table thead th.active-sort {
    border-bottom: 2px solid #00897b !important;
  }
  .cycle-master-table td {
    padding: 8px 3px !important;
    font-size: 11.5px !important;
  }
  .cycle-th-full {
    display: none !important;
  }
  .cycle-th-short {
    display: inline !important;
  }
  .cycle-master-table .th-cycle-avg,
  .cycle-master-table .col-cycle-avg,
  .cycle-master-table .th-cycle-count,
  .cycle-master-table .col-cycle-count,
  .cycle-master-table .th-cycle-btn,
  .cycle-master-table .col-cycle-btn {
    display: none !important;
  }
  .cycle-master-table .th-cycle-num,
  .cycle-master-table .col-cycle-num {
    width: 18% !important;
    text-align: center !important;
  }
  .cycle-master-table .th-cycle-gap,
  .cycle-master-table .col-cycle-gap {
    width: 28% !important;
    text-align: center !important;
  }
  .cycle-master-table .th-cycle-max,
  .cycle-master-table .col-cycle-max {
    width: 27% !important;
    text-align: center !important;
  }
  .cycle-master-table .th-cycle-last,
  .cycle-master-table .col-cycle-last {
    width: 27% !important;
    text-align: center !important;
  }
  .cycle-master-table .ball {
    width: 28px !important;
    height: 28px !important;
    font-size: 13px !important;
  }
  .cycle-table-badge {
    padding: 3px 6px !important;
    font-size: 11px !important;
  }
}



/* ==========================================================================
   COMPREHENSIVE TICKET CHECKER PAGE (DÒ VÉ SỐ LOTTO 5/35) - COMPACT & REFINED
   ========================================================================== */

.lotto-checker-page-wrap {
  width: 100%;
  margin: 0 auto;
  padding: 10px 15px 50px;
  box-sizing: border-box;
}

/* Hero Section */
.lotto-checker-hero {
  background: linear-gradient(135deg, #064e3b 0%, #065f46 60%, #047857 100%);
  border-radius: 16px;
  padding: 24px 28px;
  color: #ffffff;
  margin-bottom: 20px;
  box-shadow: 0 10px 25px -5px rgba(6, 78, 59, 0.25);
  box-sizing: border-box;
}

.lotto-checker-hero .breadcrumb-nav {
  font-size: 12.5px;
  color: rgba(255, 255, 255, 0.75);
  margin-bottom: 6px;
}

.lotto-checker-hero .breadcrumb-nav a {
  color: #a7f3d0;
  text-decoration: none;
}

.lotto-checker-hero .lotto-eyebrow {
  display: inline-block;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.25);
  padding: 3px 12px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.5px;
  margin-bottom: 8px;
  color: #a7f3d0;
}

.lotto-checker-hero h1 {
  font-size: 24px;
  font-weight: 800;
  margin: 0 0 8px 0;
  color: #ffffff;
  line-height: 1.25;
}

.lotto-checker-hero p {
  font-size: 14px;
  line-height: 1.55;
  color: rgba(255, 255, 255, 0.9);
  margin: 0 0 14px 0;
  max-width: 900px;
}

.checker-hero-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.checker-hero-badge {
  background: rgba(0, 0, 0, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.18);
  padding: 5px 12px;
  border-radius: 20px;
  font-size: 12px;
  color: #ecfdf5;
  font-weight: 500;
}

/* 2-Column Responsive Layout */
.lotto-checker-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 20px;
  align-items: start;
}

/* Console Card (Left Column) - COMPACT */
#checker-console-card {
  background: #ffffff;
  border-radius: 16px;
  border: 1px solid #e2e8f0;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.04);
  padding: 20px 22px;
  margin-bottom: 20px;
  box-sizing: border-box;
}

/* Mode Switcher Tabs (Segmented Control style - COMPACT) */
.checker-mode-tabs {
  display: flex;
  background: #f1f5f9;
  padding: 4px;
  border-radius: 10px;
  gap: 4px;
  border: none;
  margin-bottom: 16px;
}

.checker-mode-btn {
  flex: 1;
  padding: 8px 14px;
  border-radius: 8px;
  border: none !important;
  background: transparent;
  font-size: 13px;
  font-weight: 600;
  color: #475569;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: all 0.2s ease;
  box-shadow: none !important;
}

.checker-mode-btn:hover {
  color: #064e3b;
  background: rgba(255, 255, 255, 0.6);
}

.checker-mode-btn.active {
  background: #ffffff !important;
  color: #064e3b !important;
  font-weight: 800 !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06) !important;
  border: 1px solid rgba(0, 0, 0, 0.04) !important;
}

/* Filter Controls - COMPACT & FIXED SELECT BUG */
.checker-filter-row {
  display: flex;
  align-items: flex-end;
  gap: 12px;
  margin-bottom: 18px;
  flex-wrap: wrap;
}

.checker-filter-group.flex-grow {
  flex: 1;
  min-width: 240px;
}

.checker-field-label {
  display: block;
  font-size: 13px;
  font-weight: 700;
  color: #334155;
  margin-bottom: 6px;
}

.checker-select-wrap {
  position: relative;
  width: 100%;
}

/* Fixed select: no clipping, perfect line-height, clean chevron icon */
#checker-console-card select.checker-select,
.checker-select {
  width: 100% !important;
  height: 38px !important;
  min-height: 38px !important;
  max-height: 38px !important;
  line-height: normal !important;
  padding: 0 32px 0 12px !important;
  font-size: 13.5px !important;
  font-weight: 600 !important;
  color: #0f172a !important;
  background-color: #ffffff !important;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%23475569'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M19 9l-7 7-7-7'%3E%3C/path%3E%3C/svg%3E") !important;
  background-repeat: no-repeat !important;
  background-position: right 10px center !important;
  background-size: 14px !important;
  border: 1.5px solid #cbd5e1 !important;
  border-radius: 8px !important;
  outline: none !important;
  -webkit-appearance: none !important;
  -moz-appearance: none !important;
  appearance: none !important;
  box-sizing: border-box !important;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

#checker-console-card select.checker-select:focus,
.checker-select:focus {
  border-color: #059669 !important;
  box-shadow: 0 0 0 3px rgba(5, 150, 105, 0.15) !important;
}

.checker-select-sm {
  height: 36px !important;
  padding: 0 28px 0 10px !important;
  border-radius: 8px !important;
  border: 1.5px solid #cbd5e1 !important;
  font-size: 13px !important;
  font-weight: 600 !important;
  color: #0f172a !important;
  background: #ffffff !important;
  outline: none;
}

/* Action pill matches select height 38px */
.checker-action-pill {
  height: 38px !important;
  min-height: 38px !important;
  max-height: 38px !important;
  line-height: 36px !important;
  padding: 0 14px !important;
  border-radius: 8px !important;
  border: 1.5px solid #a7f3d0 !important;
  background: #ecfdf5 !important;
  color: #065f46 !important;
  font-size: 13px !important;
  font-weight: 700 !important;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.2s ease;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  box-sizing: border-box;
}

.checker-action-pill:hover {
  background: #059669 !important;
  color: #ffffff !important;
  border-color: #059669 !important;
  transform: translateY(-1px);
}

.checker-scope-pills {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.checker-scope-pill {
  height: 34px;
  line-height: 32px;
  padding: 0 14px;
  border-radius: 18px;
  border: 1.5px solid #cbd5e1;
  background: #f8fafc;
  font-size: 12.5px;
  font-weight: 600;
  color: #334155;
  cursor: pointer;
  transition: all 0.15s ease;
  box-sizing: border-box;
}

.checker-scope-pill:hover {
  border-color: #059669;
  color: #059669;
  background: #f0fdf4;
}

.checker-scope-pill.active {
  background: #059669;
  color: #ffffff;
  border-color: #059669;
  font-weight: 700;
}

/* ==========================================================================
   TICKET BALL INPUTS (COMPACT & 3D SPHERES)
   ========================================================================== */
.checker-inputs-section {
  background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
  border-radius: 14px;
  padding: 16px 18px;
  border: 1.5px solid #e2e8f0;
  margin-bottom: 16px;
}

.checker-inputs-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
  flex-wrap: wrap;
  gap: 6px;
}

.checker-inputs-hint {
  font-size: 12px;
  color: #64748b;
  font-weight: 500;
  background: #ffffff;
  padding: 3px 8px;
  border-radius: 6px;
  border: 1px solid #e2e8f0;
}

.ticket-ball-inputs-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap;
  margin: 6px 0 2px 0;
}

.ticket-main-inputs {
  display: flex;
  gap: 8px;
}

/* Compact 50px spherical ball inputs */
#checker-console-card .ticket-ball-inputs-wrap input[type="text"].ticket-ball-input,
.ticket-ball-inputs-wrap .ticket-ball-input {
  width: 50px !important;
  min-width: 50px !important;
  max-width: 50px !important;
  height: 50px !important;
  min-height: 50px !important;
  max-height: 50px !important;
  border-radius: 50% !important;
  padding: 0 !important;
  margin: 0 !important;
  text-align: center !important;
  font-family: inherit !important;
  font-size: 19px !important;
  font-weight: 800 !important;
  line-height: 46px !important;
  border: 2px solid #38bdf8 !important;
  background: radial-gradient(circle at 35% 30%, #ffffff 0%, #f0f9ff 70%, #e0f2fe 100%) !important;
  color: #0284c7 !important;
  box-shadow: 0 4px 10px rgba(2, 132, 199, 0.12), inset 0 2px 3px rgba(255, 255, 255, 0.9) !important;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1) !important;
  outline: none !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  box-sizing: border-box !important;
}

#checker-console-card .ticket-ball-inputs-wrap input[type="text"].ticket-ball-input:focus,
.ticket-ball-inputs-wrap .ticket-ball-input:focus {
  transform: translateY(-2px) scale(1.06) !important;
  border-color: #0284c7 !important;
  box-shadow: 0 8px 18px rgba(2, 132, 199, 0.25), 0 0 0 3px rgba(56, 189, 248, 0.2) !important;
}

#checker-console-card .ticket-ball-inputs-wrap input[type="text"].ticket-ball-input.filled,
.ticket-ball-inputs-wrap .ticket-ball-input.filled {
  background: radial-gradient(circle at 35% 30%, #ffffff 0%, #e0f2fe 65%, #bae6fd 100%) !important;
  border-color: #0284c7 !important;
  color: #0369a1 !important;
  box-shadow: 0 5px 14px rgba(2, 132, 199, 0.2), inset 0 -2px 3px rgba(2, 132, 199, 0.18) !important;
}

.ticket-plus-separator {
  font-size: 20px !important;
  font-weight: 900 !important;
  color: #94a3b8 !important;
  margin: 0 2px !important;
  line-height: 1 !important;
}

.ticket-special-input-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
}

#checker-console-card .ticket-ball-inputs-wrap input[type="text"].ticket-ball-input.special-ball,
.ticket-ball-inputs-wrap .ticket-ball-input.special-ball {
  border-color: #f59e0b !important;
  color: #b45309 !important;
  background: radial-gradient(circle at 35% 30%, #ffffff 0%, #fffbeb 70%, #fef3c7 100%) !important;
  box-shadow: 0 4px 10px rgba(245, 158, 11, 0.15), inset 0 2px 3px rgba(255, 255, 255, 0.9) !important;
}

#checker-console-card .ticket-ball-inputs-wrap input[type="text"].ticket-ball-input.special-ball:focus,
.ticket-ball-inputs-wrap .ticket-ball-input.special-ball:focus {
  transform: translateY(-2px) scale(1.06) !important;
  border-color: #d97706 !important;
  box-shadow: 0 8px 18px rgba(217, 119, 6, 0.28), 0 0 0 3px rgba(251, 191, 36, 0.2) !important;
}

#checker-console-card .ticket-ball-inputs-wrap input[type="text"].ticket-ball-input.special-ball.filled,
.ticket-ball-inputs-wrap .ticket-ball-input.special-ball.filled {
  background: radial-gradient(circle at 35% 30%, #fffdf5 0%, #fef3c7 65%, #fde68a 100%) !important;
  border-color: #d97706 !important;
  color: #92400e !important;
  box-shadow: 0 5px 14px rgba(217, 119, 6, 0.22), inset 0 -2px 3px rgba(217, 119, 6, 0.18) !important;
}

.special-badge-label {
  background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
  color: #92400e;
  border: 1px solid #fcd34d;
  font-size: 9.5px;
  font-weight: 800;
  padding: 1px 6px;
  border-radius: 999px;
  margin-top: 4px;
  letter-spacing: 0.4px;
  text-transform: uppercase;
}

.ticket-error-msg {
  margin-top: 10px;
  padding: 8px 14px;
  background: #fef2f2;
  border: 1px solid #fecaca;
  color: #dc2626;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  text-align: center;
}

/* ==========================================================================
   INTERACTIVE KEYPAD (COMPACT 35px SPHERICAL BALLS)
   ========================================================================== */
.checker-keypad-section {
  margin-bottom: 16px;
  border-radius: 12px;
  border: 1px solid #e2e8f0;
  overflow: hidden;
  background: #ffffff;
}

.checker-keypad-toggle-row {
  background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
  border-bottom: 1px solid #e2e8f0;
}

.checker-toggle-keypad-btn {
  width: 100%;
  padding: 10px 16px;
  border: none;
  background: transparent;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 700;
  color: #1e293b;
  text-align: left;
}

.checker-toggle-keypad-btn small {
  color: #64748b;
  font-size: 11.5px;
  font-weight: normal;
  margin-left: 4px;
}

.keypad-arrow-icon {
  margin-left: auto;
  font-size: 10px;
  color: #64748b;
  transition: transform 0.2s ease;
}

.checker-keypad-section.is-collapsed .keypad-arrow-icon {
  transform: rotate(-90deg);
}

.checker-keypad-section.is-collapsed .checker-keypad-body {
  display: none;
}

.checker-keypad-body {
  padding: 14px 16px;
}

.keypad-group {
  margin-bottom: 12px;
}

.keypad-group:last-child {
  margin-bottom: 0;
}

.keypad-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12.5px;
  font-weight: 700;
  color: #334155;
  margin-bottom: 8px;
}

.keypad-count {
  font-size: 11.5px;
  color: #059669;
  font-weight: 700;
  background: #ecfdf5;
  border: 1px solid #a7f3d0;
  padding: 1px 8px;
  border-radius: 10px;
}

.keypad-balls-grid {
  display: flex !important;
  flex-wrap: wrap !important;
  justify-content: center !important;
  gap: 7px !important;
}

/* Compact 35px Keypad Ball */
.keypad-ball {
  width: 35px !important;
  height: 35px !important;
  min-width: 35px !important;
  max-width: 35px !important;
  border-radius: 50% !important;
  background: radial-gradient(circle at 35% 30%, #ffffff 0%, #f8fafc 70%, #e2e8f0 100%) !important;
  border: 1.5px solid #cbd5e1 !important;
  font-size: 12.5px !important;
  font-weight: 700 !important;
  color: #1e293b !important;
  cursor: pointer;
  transition: all 0.15s ease;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  padding: 0 !important;
  margin: 0 auto !important;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04), inset 0 1px 1px rgba(255, 255, 255, 0.9) !important;
}

.keypad-ball:hover {
  border-color: #38bdf8 !important;
  color: #0284c7 !important;
  background: #f0f9ff !important;
  transform: translateY(-1px) scale(1.05) !important;
}

.keypad-ball.active {
  background: radial-gradient(circle at 35% 30%, #38bdf8 0%, #0284c7 60%, #0369a1 100%) !important;
  color: #ffffff !important;
  border-color: #0284c7 !important;
  transform: scale(1.08) !important;
  box-shadow: 0 4px 12px rgba(2, 132, 199, 0.35) !important;
  font-weight: 800 !important;
}

.keypad-ball.special {
  background: radial-gradient(circle at 35% 30%, #fffdf5 0%, #fef3c7 70%, #fde68a 100%) !important;
  border-color: #fcd34d !important;
  color: #92400e !important;
}

.keypad-ball.special:hover {
  border-color: #f59e0b !important;
  color: #78350f !important;
  transform: translateY(-1px) scale(1.05) !important;
}

.keypad-ball.special.active {
  background: radial-gradient(circle at 35% 30%, #fde047 0%, #f59e0b 60%, #d97706 100%) !important;
  color: #ffffff !important;
  border-color: #d97706 !important;
  transform: scale(1.08) !important;
  box-shadow: 0 4px 12px rgba(217, 119, 6, 0.35) !important;
  font-weight: 800 !important;
}

/* ==========================================================================
   QUICK TOOLS BAR (COMPACT, SLIM, SINGLE-LINE PILLS)
   ========================================================================== */
.checker-tools-bar {
  display: flex;
  gap: 8px;
  margin-bottom: 16px;
  flex-wrap: nowrap;
}

.checker-tool-btn {
  flex: 1 1 0px !important;
  min-width: unset !important;
  height: 36px !important;
  min-height: 36px !important;
  max-height: 36px !important;
  line-height: 34px !important;
  padding: 0 10px !important;
  border-radius: 8px !important;
  font-size: 12.5px !important;
  font-weight: 700 !important;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  white-space: nowrap !important;
  transition: all 0.15s ease;
  box-sizing: border-box !important;
}

#btn-tool-quickpick {
  background: #f5f3ff;
  color: #6d28d9;
  border: 1.5px solid #ddd6fe;
}

#btn-tool-quickpick:hover {
  background: #ede9fe;
  border-color: #c4b5fd;
  transform: translateY(-1px);
}

#btn-tool-hot {
  background: #fff7ed;
  color: #c2410c;
  border: 1.5px solid #fed7aa;
}

#btn-tool-hot:hover {
  background: #ffedd5;
  border-color: #fdba74;
  transform: translateY(-1px);
}

#btn-tool-overdue {
  background: #ecfeff;
  color: #0e7490;
  border: 1.5px solid #a5f3fc;
}

#btn-tool-overdue:hover {
  background: #cffafe;
  border-color: #67e8f9;
  transform: translateY(-1px);
}

#btn-tool-reset {
  background: #fff1f2;
  color: #e11d48;
  border: 1.5px solid #fecdd3;
}

#btn-tool-reset:hover {
  background: #ffe4e6;
  border-color: #fda4af;
  transform: translateY(-1px);
}

/* ==========================================================================
   MAIN CTA BUTTON (COMPACT & SLIM EMERALD GRADIENT)
   ========================================================================== */
.checker-submit-button {
  width: 100%;
  height: 44px !important;
  min-height: 44px !important;
  max-height: 44px !important;
  line-height: 44px !important;
  padding: 0 20px !important;
  border-radius: 10px !important;
  border: none !important;
  background: linear-gradient(135deg, #059669 0%, #047857 50%, #064e3b 100%) !important;
  color: #ffffff !important;
  font-size: 14px !important;
  font-weight: 800 !important;
  letter-spacing: 0.4px !important;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  box-shadow: 0 4px 14px rgba(5, 150, 105, 0.35) !important;
  transition: all 0.2s ease !important;
  box-sizing: border-box !important;
}

.checker-submit-button:hover {
  background: linear-gradient(135deg, #047857 0%, #065f46 60%, #022c22 100%) !important;
  transform: translateY(-1px) !important;
  box-shadow: 0 6px 18px rgba(5, 150, 105, 0.45) !important;
}

/* ==========================================================================
   INITIAL PLACEHOLDER & RESULTS DISPLAY
   ========================================================================== */
.checker-initial-card {
  text-align: center;
  padding: 36px 24px;
  background: radial-gradient(circle at 50% 30%, #ffffff 0%, #f8fafc 100%);
  border-radius: 16px;
  border: 1.5px dashed #cbd5e1;
  margin-top: 10px;
}

.checker-initial-card .initial-icon {
  font-size: 40px;
  margin-bottom: 10px;
}

.checker-initial-card h3 {
  font-size: 18px;
  font-weight: 800;
  color: #1e293b;
  margin: 0 0 8px 0;
}

.checker-initial-card p {
  font-size: 13.5px;
  color: #64748b;
  line-height: 1.55;
  max-width: 580px;
  margin: 0 auto 16px;
}

.initial-quick-examples {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  font-size: 12.5px;
  color: #64748b;
}

.example-num-pill {
  padding: 8px 16px;
  border-radius: 20px;
  border: 1.5px solid #a7f3d0;
  background: linear-gradient(135deg, #ecfdf5 0%, #d1fae5 100%);
  color: #065f46;
  font-size: 12.5px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 0 2px 8px rgba(5, 150, 105, 0.1);
}

.example-num-pill:hover {
  background: #059669;
  color: #ffffff;
  border-color: #059669;
  transform: translateY(-1px);
}

/* Announcement Card (Result) */
.checker-announcement-card {
  border-radius: 16px;
  padding: 22px;
  margin-bottom: 20px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.checker-announcement-card.winner {
  background: linear-gradient(135deg, #f0fdf4 0%, #ecfdf5 40%, #fef3c7 100%);
  border: 2px solid #86efac;
  box-shadow: 0 10px 25px -5px rgba(5, 150, 105, 0.15);
}

.checker-announcement-card.non-winner {
  background: #f8fafc;
  border: 1.5px solid #e2e8f0;
}

.announcement-icon {
  font-size: 40px;
  margin-bottom: 8px;
}

.announcement-badge {
  display: inline-block;
  padding: 4px 14px;
  border-radius: 20px;
  font-size: 11.5px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 6px;
}

.winner .announcement-badge {
  background: #059669;
  color: #ffffff;
}

.non-winner .announcement-badge {
  background: #64748b;
  color: #ffffff;
}

.announcement-title {
  font-size: 22px;
  font-weight: 900;
  margin: 0 0 4px;
}

.winner .announcement-title {
  color: #065f46;
}

.non-winner .announcement-title {
  color: #334155;
}

.announcement-prize {
  font-size: 30px;
  font-weight: 900;
  color: #dc2626;
  margin: 8px 0;
  letter-spacing: 0.5px;
}

.announcement-desc {
  font-size: 13.5px;
  color: #475569;
  margin: 0;
}

/* Compare Arena */
.checker-compare-arena {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  margin-bottom: 20px;
  background: #ffffff;
  border-radius: 14px;
  padding: 18px;
  border: 1px solid #e2e8f0;
}

.arena-box {
  background: #f8fafc;
  border-radius: 10px;
  padding: 14px;
  text-align: center;
  border: 1px solid #e2e8f0;
}

.arena-box-title {
  font-size: 13px;
  font-weight: 700;
  color: #334155;
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.arena-balls-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  flex-wrap: wrap;
}

.arena-ball {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 800;
  background: #ffffff;
  border: 1.5px solid #cbd5e1;
  color: #64748b;
  position: relative;
  transition: all 0.2s;
}

.arena-ball.matched {
  background: radial-gradient(circle at 35% 30%, #38bdf8 0%, #0284c7 60%, #0369a1 100%);
  border-color: #0284c7;
  color: #ffffff;
  box-shadow: 0 4px 10px rgba(2, 132, 199, 0.3);
  transform: scale(1.05);
}

.arena-ball.matched::after {
  content: "✓";
  position: absolute;
  top: -5px;
  right: -5px;
  width: 15px;
  height: 15px;
  border-radius: 50%;
  background: #10b981;
  color: #fff;
  font-size: 10px;
  font-weight: 900;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1.5px solid #fff;
}

.arena-ball.special {
  border-color: #fde68a;
  background: #fffbeb;
  color: #b45309;
}

.arena-ball.special.matched {
  background: radial-gradient(circle at 35% 30%, #fde047 0%, #f59e0b 60%, #d97706 100%);
  border-color: #d97706;
  color: #ffffff;
  box-shadow: 0 4px 10px rgba(217, 119, 6, 0.3);
  transform: scale(1.05);
}

/* Detailed Tiers Table */
.checker-tiers-card {
  background: #ffffff;
  border-radius: 14px;
  border: 1px solid #e2e8f0;
  padding: 18px;
  margin-bottom: 20px;
}

.checker-tiers-card h3 {
  font-size: 15px;
  font-weight: 800;
  color: #0f172a;
  margin: 0 0 12px 0;
}

.checker-tiers-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}

.checker-tiers-table th {
  background: #f1f5f9;
  color: #334155;
  padding: 9px 12px;
  font-weight: 700;
  text-align: left;
  border-bottom: 2px solid #cbd5e1;
}

.checker-tiers-table td {
  padding: 9px 12px;
  border-bottom: 1px solid #f1f5f9;
  vertical-align: middle;
}

.checker-tiers-table tr.winning-row td {
  background: #ecfdf5 !important;
  font-weight: 700;
  color: #064e3b;
  border-left: 4px solid #059669;
}

.checker-tier-status-pill {
  display: inline-block;
  padding: 3px 8px;
  border-radius: 10px;
  font-size: 11px;
  font-weight: 700;
}

.checker-tier-status-pill.won {
  background: #059669;
  color: #ffffff;
}

.checker-tier-status-pill.miss {
  background: #f1f5f9;
  color: #94a3b8;
}

/* Smart Ticket Insights Grid */
.checker-insights-card {
  background: #ffffff;
  border-radius: 14px;
  border: 1px solid #e2e8f0;
  padding: 18px;
  margin-bottom: 20px;
}

.checker-insights-card h3 {
  font-size: 15px;
  font-weight: 800;
  color: #0f172a;
  margin: 0 0 12px 0;
}

.checker-insights-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 12px;
}

.checker-insight-box {
  background: #f8fafc;
  border-radius: 10px;
  border: 1px solid #e2e8f0;
  padding: 12px;
  text-align: center;
}

.checker-insight-box .insight-title {
  font-size: 11px;
  font-weight: 700;
  color: #64748b;
  text-transform: uppercase;
  margin-bottom: 4px;
}

.checker-insight-box .insight-val {
  font-size: 18px;
  font-weight: 800;
  color: #0f172a;
  margin-bottom: 2px;
}

.checker-insight-box .insight-sub {
  font-size: 11px;
  color: #475569;
}

/* Multi-Mode KPI & Hits Table */
.multi-kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  margin-bottom: 18px;
}

.multi-kpi-card {
  background: #ffffff;
  border-radius: 12px;
  border: 1px solid #e2e8f0;
  padding: 14px;
  text-align: center;
}

.multi-kpi-card .kpi-label {
  font-size: 11px;
  font-weight: 700;
  color: #64748b;
  text-transform: uppercase;
  margin-bottom: 4px;
}

.multi-kpi-card .kpi-val {
  font-size: 20px;
  font-weight: 900;
  color: #059669;
}

.multi-kpi-card.prize-kpi .kpi-val {
  color: #dc2626;
}

.multi-kpi-card .kpi-sub {
  font-size: 11px;
  color: #94a3b8;
  margin-top: 2px;
}

.multi-hits-card {
  background: #ffffff;
  border-radius: 14px;
  border: 1px solid #e2e8f0;
  padding: 18px;
  margin-bottom: 20px;
}

.multi-hits-card h3 {
  font-size: 15px;
  font-weight: 800;
  color: #0f172a;
  margin: 0 0 12px 0;
}

.multi-hits-table-wrap {
  overflow-x: auto;
}

.multi-hits-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}

.multi-hits-table th {
  background: #f1f5f9;
  color: #334155;
  padding: 9px 12px;
  font-weight: 700;
  border-bottom: 2px solid #cbd5e1;
  text-align: left;
}

.multi-hits-table td {
  padding: 9px 12px;
  border-bottom: 1px solid #f1f5f9;
  vertical-align: middle;
}

.multi-hits-table tr:hover td {
  background: #f8fafc;
}

/* ==========================================================================
   SIDEBAR CARDS (COMPACT & CLEAN)
   ========================================================================== */
.checker-sidebar-card {
  background: #ffffff;
  border-radius: 14px;
  border: 1px solid #e2e8f0;
  padding: 18px;
  margin-bottom: 18px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.02);
  box-sizing: border-box;
}

.sb-card-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
  border-bottom: 1.5px solid #f1f5f9;
  padding-bottom: 8px;
}

.sb-card-header h3 {
  font-size: 15px;
  font-weight: 800;
  color: #0f172a;
  margin: 0;
}

.prize-rule-item {
  padding: 8px 0;
  border-bottom: 1px solid #f1f5f9;
}

.prize-rule-item:last-child {
  border-bottom: none;
}

.prize-rule-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 3px;
}

.prize-rule-head strong {
  font-size: 13px;
  color: #1e293b;
}

.prize-badge {
  font-size: 11.5px;
  font-weight: 700;
  color: #059669;
  background: #ecfdf5;
  border: 1px solid #a7f3d0;
  padding: 1px 7px;
  border-radius: 6px;
}

.jackpot-badge {
  color: #dc2626 !important;
  background: #fef2f2 !important;
  border-color: #fecaca !important;
}

.prize-rule-pattern {
  font-size: 11.5px;
  color: #64748b;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.pattern-balls {
  font-size: 10.5px;
  color: #0284c7;
  letter-spacing: 2px;
}

.pattern-balls .gold-dot {
  color: #d97706;
}

.sb-sub-text {
  font-size: 12.5px;
  color: #475569;
  margin: 0 0 10px 0;
  line-height: 1.45;
}

.sb-time-badges {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin: 10px 0;
}

.sb-time-badge {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 8px;
  text-align: center;
}

.sb-time-badge .time-label {
  display: block;
  font-size: 11px;
  color: #64748b;
  margin-bottom: 2px;
}

.sb-time-badge strong {
  font-size: 15px;
  color: #059669;
}

.sb-countdown-box {
  background: linear-gradient(135deg, #064e3b 0%, #065f46 100%);
  color: #ffffff;
  border-radius: 10px;
  padding: 10px;
  text-align: center;
  margin-top: 10px;
}

.sb-countdown-box .cd-title {
  display: block;
  font-size: 11.5px;
  color: #a7f3d0;
  margin-bottom: 2px;
}

.cd-timer {
  font-size: 22px;
  font-weight: 900;
  letter-spacing: 1.5px;
  color: #fde047;
  font-family: monospace;
}

.sb-guide-list {
  margin: 0;
  padding-left: 16px;
  font-size: 12.5px;
  color: #475569;
  line-height: 1.55;
}

.sb-guide-list li {
  margin-bottom: 6px;
}

/* ==========================================================================
   RESPONSIVE RULES
   ========================================================================== */
@media (max-width: 950px) {
  .lotto-checker-layout {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 600px) {
  .lotto-checker-hero {
    padding: 18px 16px !important;
  }
  .lotto-checker-hero h1 {
    font-size: 20px !important;
  }
  #checker-console-card {
    padding: 14px !important;
  }
  .ticket-ball-inputs-wrap {
    gap: 6px !important;
  }
  .ticket-main-inputs {
    gap: 4px !important;
  }
  #checker-console-card .ticket-ball-inputs-wrap input[type="text"].ticket-ball-input,
  .ticket-ball-inputs-wrap .ticket-ball-input {
    width: 42px !important;
    min-width: 42px !important;
    max-width: 42px !important;
    height: 42px !important;
    min-height: 42px !important;
    max-height: 42px !important;
    font-size: 15px !important;
    line-height: 38px !important;
  }
  .checker-tools-bar {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 6px !important;
  }
  .checker-tool-btn {
    width: 100% !important;
    height: 34px !important;
    font-size: 12px !important;
  }
  .checker-compare-arena {
    grid-template-columns: 1fr;
  }
  .multi-kpi-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* ==========================================================================
   Lotto FAQ / Q&A Section - Standard SEO & Accessible Accordion UI
   ========================================================================== */
.lotto-faq-section {
  width: 100%;
  margin-top: 36px;
  margin-bottom: 30px;
  box-sizing: border-box;
  clear: both;
}

.lotto-faq-card {
  background: #ffffff;
  border-radius: 16px;
  border: 1px solid #e2e8f0;
  box-shadow: 0 4px 20px -2px rgba(15, 23, 42, 0.04);
  padding: 28px 30px;
  box-sizing: border-box;
}

.lotto-faq-header {
  margin-bottom: 22px;
}

.lotto-faq-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #ecfdf5;
  color: #047857;
  border: 1px solid #a7f3d0;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 11.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 10px;
}

.lotto-faq-badge svg {
  color: #059669;
}

.lotto-faq-title {
  font-size: 21px;
  font-weight: 700;
  color: #0f172a;
  margin: 0 0 8px 0;
  line-height: 1.35;
}

.lotto-faq-desc {
  font-size: 14px;
  color: #64748b;
  margin: 0;
  line-height: 1.55;
}

.lotto-faq-accordion {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.lotto-faq-item {
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  background: #f8fafc;
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  overflow: hidden;
}

.lotto-faq-item:hover {
  border-color: #cbd5e1;
  background: #ffffff;
}

.lotto-faq-item[open] {
  border-color: #10b981;
  background: #ffffff;
  box-shadow: 0 4px 16px -2px rgba(16, 185, 129, 0.08);
}

.lotto-faq-question {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 18px;
  cursor: pointer;
  list-style: none;
  gap: 12px;
  user-select: none;
  font-weight: 600;
  transition: color 0.2s ease;
}

.lotto-faq-question::-webkit-details-marker,
.lotto-faq-question::marker {
  display: none !important;
}

.faq-q-number {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: #e2e8f0;
  color: #475569;
  font-size: 12px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: all 0.2s ease;
}

.lotto-faq-item[open] .faq-q-number {
  background: #047857;
  color: #ffffff;
}

.faq-q-text {
  flex: 1;
  font-size: 14.5px;
  color: #1e293b;
  line-height: 1.45;
  transition: color 0.2s ease;
}

.lotto-faq-item[open] .faq-q-text {
  color: #047857;
}

.faq-q-icon {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: #f1f5f9;
  color: #64748b;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1), background-color 0.2s ease, color 0.2s ease;
}

.lotto-faq-item[open] .faq-q-icon {
  transform: rotate(180deg);
  background: #ecfdf5;
  color: #047857;
}

.lotto-faq-answer {
  padding: 0 18px 16px 56px;
  box-sizing: border-box;
}

.faq-answer-inner {
  font-size: 13.5px;
  color: #475569;
  line-height: 1.65;
  border-top: 1px dashed #e2e8f0;
  padding-top: 12px;
}

.faq-answer-inner p {
  margin: 0 0 8px 0;
}

.faq-answer-inner p:last-child {
  margin-bottom: 0;
}

.faq-answer-inner ul {
  margin: 8px 0 8px 18px;
  padding: 0;
}

.faq-answer-inner li {
  margin-bottom: 6px;
}

.faq-answer-inner strong {
  color: #0f172a;
}

.lotto-faq-footer-note {
  margin-top: 20px;
  padding: 12px 16px;
  background: #f8fafc;
  border-radius: 10px;
  border: 1px solid #f1f5f9;
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 12.5px;
  color: #64748b;
  line-height: 1.5;
}

.faq-note-icon {
  font-size: 15px;
  line-height: 1;
}

.faq-note-text a {
  color: #047857;
  font-weight: 600;
  text-decoration: underline;
}

.faq-note-text a:hover {
  color: #065f46;
}

@media (max-width: 767px) {
  .lotto-faq-card {
    padding: 20px 16px;
  }
  .lotto-faq-title {
    font-size: 18px;
  }
  .lotto-faq-desc {
    font-size: 13px;
  }
  .lotto-faq-question {
    padding: 12px 14px;
    gap: 10px;
  }
  .faq-q-text {
    font-size: 13.5px;
  }
  .lotto-faq-answer {
    padding: 0 14px 14px 14px;
  }
  .faq-answer-inner {
    padding-top: 10px;
    font-size: 13px;
  }
}

/* ==========================================================================
   Home Page Ticket Checker Widget (Compact Sidebar Widget)
   ========================================================================== */
.home-checker-card {
  background: #ffffff;
  border-radius: 16px;
  border: 1px solid #e2e8f0;
  box-shadow: 0 4px 16px rgba(15, 23, 42, 0.04);
  padding: 20px 20px 18px !important;
  margin-bottom: 20px;
}

.home-checker-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 4px;
}

.home-checker-title {
  font-size: 17px !important;
  font-weight: 700 !important;
  color: #0f172a !important;
  margin: 0 !important;
  display: flex;
  align-items: center;
  gap: 6px;
}

.home-checker-badge {
  background: #ecfdf5;
  color: #047857;
  border: 1px solid #a7f3d0;
  border-radius: 10px;
  font-size: 11px;
  font-weight: 700;
  padding: 2px 7px;
  letter-spacing: 0.3px;
}

.home-checker-subtitle {
  font-size: 12.5px;
  color: #64748b;
  margin: 0 0 14px 0;
  line-height: 1.4;
}

.home-checker-draw-row {
  margin-bottom: 12px;
}

.home-checker-draw-label {
  display: block;
  font-size: 11.5px;
  font-weight: 600;
  color: #475569;
  margin-bottom: 4px;
}

.home-checker-select-wrap {
  position: relative;
  width: 100%;
}

.home-checker-select {
  width: 100% !important;
  height: 36px !important;
  min-height: 36px !important;
  max-height: 36px !important;
  line-height: normal !important;
  padding: 0 32px 0 10px !important;
  border: 1px solid #cbd5e1 !important;
  border-radius: 8px !important;
  background-color: #ffffff !important;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23475569' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E") !important;
  background-repeat: no-repeat !important;
  background-position: right 10px center !important;
  font-size: 12.5px !important;
  font-weight: 600 !important;
  color: #1e293b !important;
  box-sizing: border-box !important;
  appearance: none !important;
  -webkit-appearance: none !important;
  cursor: pointer;
  outline: none !important;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.home-checker-select:focus {
  border-color: #059669 !important;
  box-shadow: 0 0 0 3px rgba(5, 150, 105, 0.15) !important;
}

.home-checker-inputs-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12px;
  font-weight: 600;
  color: #334155;
  margin-bottom: 8px;
}

.home-checker-inputs-hint {
  font-size: 11px;
  color: #94a3b8;
  font-weight: 400;
}

.home-checker-inputs-container {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 10px 8px 12px;
  margin-bottom: 10px;
  box-sizing: border-box;
}

.home-checker-mains-group {
  display: flex;
  align-items: center;
  gap: 4px;
}

/* 3D Circular Ball Inputs for Home Checker */
.home-checker-ball-input {
  width: 38px !important;
  min-width: 38px !important;
  max-width: 38px !important;
  height: 38px !important;
  min-height: 38px !important;
  max-height: 38px !important;
  border-radius: 50% !important;
  text-align: center !important;
  font-size: 14.5px !important;
  font-weight: 700 !important;
  color: #0369a1 !important;
  background: radial-gradient(circle at 35% 30%, #ffffff 0%, #e0f2fe 65%, #bae6fd 100%) !important;
  border: 2px solid #38bdf8 !important;
  box-shadow: 0 3px 8px rgba(2, 132, 199, 0.18), inset 0 -2px 3px rgba(2, 132, 199, 0.15) !important;
  padding: 0 !important;
  margin: 0 !important;
  line-height: 34px !important;
  outline: none !important;
  box-sizing: border-box !important;
  transition: transform 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease !important;
}

.home-checker-ball-input:focus {
  transform: translateY(-2px) scale(1.08) !important;
  border-color: #0284c7 !important;
  box-shadow: 0 6px 14px rgba(2, 132, 199, 0.25), 0 0 0 3px rgba(56, 189, 248, 0.2) !important;
}

.home-checker-plus {
  font-size: 15px;
  font-weight: 800;
  color: #94a3b8;
  padding: 0 1px;
}

.home-checker-special-group {
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
}

.home-checker-ball-input.special-ball {
  color: #92400e !important;
  background: radial-gradient(circle at 35% 30%, #fffdf5 0%, #fef3c7 65%, #fde68a 100%) !important;
  border: 2px solid #f59e0b !important;
  box-shadow: 0 3px 8px rgba(245, 158, 11, 0.2), inset 0 -2px 3px rgba(217, 119, 6, 0.15) !important;
}

.home-checker-ball-input.special-ball:focus {
  transform: translateY(-2px) scale(1.08) !important;
  border-color: #d97706 !important;
  box-shadow: 0 6px 14px rgba(217, 119, 6, 0.28), 0 0 0 3px rgba(251, 191, 36, 0.2) !important;
}

.home-checker-special-tag {
  font-size: 9px;
  font-weight: 800;
  color: #b45309;
  background: #fef3c7;
  border: 1px solid #fde68a;
  border-radius: 4px;
  padding: 0 4px;
  margin-top: 2px;
  line-height: 1.2;
}

/* Quick Tools */
.home-checker-tools {
  display: flex;
  gap: 8px;
  margin-bottom: 10px;
}

.home-checker-tool-btn {
  flex: 1;
  height: 32px !important;
  min-height: 32px !important;
  line-height: 32px !important;
  border: 1px solid #e2e8f0 !important;
  background: #f8fafc !important;
  color: #475569 !important;
  font-size: 11.5px !important;
  font-weight: 600 !important;
  border-radius: 6px !important;
  cursor: pointer !important;
  padding: 0 6px !important;
  text-align: center !important;
  margin: 0 !important;
  transition: all 0.15s ease !important;
}

.home-checker-tool-btn:hover {
  background: #f1f5f9 !important;
  color: #0f172a !important;
  border-color: #cbd5e1 !important;
}

/* Submit CTA */
.home-checker-submit-btn {
  width: 100% !important;
  height: 40px !important;
  min-height: 40px !important;
  line-height: 40px !important;
  border-radius: 8px !important;
  font-size: 13.5px !important;
  font-weight: 700 !important;
  background: linear-gradient(135deg, #059669 0%, #047857 100%) !important;
  border: none !important;
  color: #ffffff !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 6px !important;
  box-shadow: 0 4px 12px rgba(4, 120, 87, 0.22) !important;
  cursor: pointer !important;
  margin: 0 0 10px 0 !important;
  transition: all 0.2s ease !important;
}

.home-checker-submit-btn:hover {
  background: linear-gradient(135deg, #047857 0%, #065f46 100%) !important;
  box-shadow: 0 6px 16px rgba(4, 120, 87, 0.3) !important;
  transform: translateY(-1px) !important;
}

/* Result Card */
.home-check-result-card {
  border-radius: 10px;
  padding: 12px;
  margin-top: 10px;
  margin-bottom: 6px;
  box-sizing: border-box;
  animation: fadeIn 0.25s ease;
}

.home-check-result-card.won {
  background: #ecfdf5;
  border: 1.5px solid #10b981;
}

.home-check-result-card.jackpot {
  background: #fef2f2;
  border: 1.5px solid #ef4444;
}

.home-check-result-card.lost {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
}

.home-check-result-card.error-card {
  background: #fff7ed;
  border: 1px solid #fdba74;
  color: #c2410c;
  font-size: 12px;
  font-weight: 600;
}

.h-res-header.error {
  display: flex;
  align-items: center;
  gap: 6px;
}

.h-res-badge-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 6px;
}

.h-res-status-badge {
  font-size: 11.5px;
  font-weight: 700;
  border-radius: 6px;
  padding: 2px 7px;
}

.h-res-status-badge.won {
  background: #047857;
  color: #ffffff;
}

.h-res-status-badge.jackpot {
  background: #dc2626;
  color: #ffffff;
}

.h-res-status-badge.lost {
  background: #64748b;
  color: #ffffff;
}

.h-res-draw-tag {
  font-size: 11px;
  font-weight: 700;
  color: #64748b;
}

.h-res-prize-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  background: rgba(255, 255, 255, 0.7);
  padding: 6px 8px;
  border-radius: 6px;
  margin-bottom: 6px;
}

.h-prize-label {
  font-size: 11.5px;
  font-weight: 600;
  color: #475569;
}

.h-prize-val {
  font-size: 15px;
  font-weight: 800;
}

.text-emerald {
  color: #047857;
}

.text-jackpot {
  color: #dc2626;
}

.text-gold {
  color: #b45309;
}

.h-res-summary {
  font-size: 12px;
  color: #334155;
  margin-bottom: 8px;
}

.h-res-balls-row {
  margin-bottom: 8px;
}

.h-res-balls-label {
  font-size: 10.5px;
  font-weight: 600;
  color: #64748b;
  margin-bottom: 4px;
}

.h-res-balls-wrap {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-wrap: wrap;
}

.h-res-ball {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 11.5px;
  font-weight: 700;
  position: relative;
  box-sizing: border-box;
}

.h-res-ball.hit {
  background: #0284c7;
  color: #ffffff;
  border: 1.5px solid #0369a1;
  box-shadow: 0 2px 6px rgba(2, 132, 199, 0.35);
}

.h-res-ball.gold.hit {
  background: #f59e0b;
  color: #ffffff;
  border: 1.5px solid #d97706;
  box-shadow: 0 2px 6px rgba(245, 158, 11, 0.4);
}

.h-res-ball.miss {
  background: #e2e8f0;
  color: #64748b;
  border: 1px solid #cbd5e1;
}

.h-res-ball .hit-icon {
  position: absolute;
  top: -4px;
  right: -4px;
  width: 13px;
  height: 13px;
  background: #10b981;
  color: #fff;
  border-radius: 50%;
  font-size: 8px;
  font-weight: 900;
  font-style: normal;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid #fff;
}

.h-res-draw-ref {
  border-top: 1px dashed #cbd5e1;
  padding-top: 6px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 4px;
}

.h-ref-label {
  font-size: 10.5px;
  color: #64748b;
  font-weight: 500;
}

.h-ref-balls {
  display: flex;
  gap: 3px;
  align-items: center;
}

.h-draw-mini-ball {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: #e0f2fe;
  color: #0369a1;
  font-size: 10px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.h-draw-mini-ball.gold {
  background: #fef3c7;
  color: #b45309;
}

/* Footer Link */
.home-checker-footer {
  border-top: 1px dashed #e2e8f0;
  padding-top: 10px;
  margin-top: 6px;
  text-align: center;
}

.home-checker-deep-link {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 12px;
  font-weight: 600;
  color: #047857;
  text-decoration: none;
  transition: color 0.15s ease;
}

.home-checker-deep-link:hover {
  color: #065f46;
  text-decoration: underline;
}

/* ==========================================================================
   Custom Draw Search Styles (Homepage Sidebar & Comprehensive Checker Page)
   ========================================================================== */

/* 1. Homepage Sidebar Custom Search */
.home-checker-draw-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 4px;
}

.home-checker-toggle-search-btn {
  background: none !important;
  border: none !important;
  padding: 0 !important;
  font-size: 11.5px !important;
  font-weight: 600 !important;
  color: #0284c7 !important;
  cursor: pointer !important;
  display: inline-flex !important;
  align-items: center !important;
  gap: 3px !important;
  transition: color 0.15s ease !important;
}

.home-checker-toggle-search-btn:hover {
  color: #0369a1 !important;
  text-decoration: underline !important;
}

.home-checker-custom-box {
  margin-top: 6px;
  background: #f8fafc;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  padding: 8px 10px;
  animation: fadeIn 0.2s ease;
}

.home-checker-custom-input-wrap {
  display: flex;
  align-items: center;
  gap: 6px;
}

.home-checker-custom-hash {
  font-size: 13px;
  font-weight: 800;
  color: #64748b;
}

.home-checker-custom-input {
  flex: 1;
  height: 32px !important;
  min-height: 32px !important;
  line-height: 32px !important;
  border: 1px solid #cbd5e1 !important;
  border-radius: 6px !important;
  padding: 0 8px !important;
  font-size: 12px !important;
  background: #ffffff !important;
  color: #0f172a !important;
}

.home-checker-custom-input:focus {
  border-color: #0284c7 !important;
  outline: none !important;
}

.home-checker-search-submit-btn {
  height: 32px !important;
  min-height: 32px !important;
  line-height: 32px !important;
  padding: 0 10px !important;
  font-size: 11.5px !important;
  font-weight: 700 !important;
  background: #0284c7 !important;
  color: #ffffff !important;
  border: none !important;
  border-radius: 6px !important;
  cursor: pointer !important;
  transition: background 0.15s ease !important;
}

.home-checker-search-submit-btn:hover {
  background: #0369a1 !important;
}

.home-checker-search-cancel-btn {
  height: 32px !important;
  width: 32px !important;
  padding: 0 !important;
  background: #e2e8f0 !important;
  color: #475569 !important;
  border: none !important;
  border-radius: 6px !important;
  font-size: 12px !important;
  cursor: pointer !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
}

.home-checker-search-cancel-btn:hover {
  background: #cbd5e1 !important;
  color: #0f172a !important;
}

.home-checker-custom-feedback {
  margin-top: 6px;
  font-size: 11px;
  line-height: 1.35;
  padding: 4px 6px;
  border-radius: 4px;
}

.home-checker-custom-feedback.success {
  background: #ecfdf5;
  border: 1px solid #a7f3d0;
  color: #065f46;
  font-weight: 600;
}

.home-checker-custom-feedback.error {
  background: #fef2f2;
  border: 1px solid #fecaca;
  color: #991b1b;
  font-weight: 500;
}

.home-checker-custom-feedback.loading {
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  color: #1d4ed8;
  font-style: italic;
}

/* 2. Checker Page Custom Search Panel */
.checker-action-pill.checker-search-draw-pill {
  background: #eff6ff !important;
  border: 1px solid #bfdbfe !important;
  color: #1d4ed8 !important;
}

.checker-action-pill.checker-search-draw-pill:hover {
  background: #dbeafe !important;
  color: #1e40af !important;
}

.checker-custom-search-panel {
  background: #f8fafc;
  border: 1px solid #cbd5e1;
  border-radius: 12px;
  padding: 14px 16px;
  margin-bottom: 18px;
  animation: fadeIn 0.2s ease;
}

.checker-custom-tabs {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
  border-bottom: 1px solid #e2e8f0;
  padding-bottom: 8px;
}

.checker-custom-tab {
  background: none !important;
  border: none !important;
  font-size: 13px !important;
  font-weight: 600 !important;
  color: #64748b !important;
  padding: 5px 12px !important;
  border-radius: 6px !important;
  cursor: pointer !important;
  transition: all 0.15s ease !important;
}

.checker-custom-tab.active {
  background: #ffffff !important;
  color: #0284c7 !important;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08) !important;
  font-weight: 700 !important;
}

.checker-custom-tab-close {
  margin-left: auto !important;
  background: none !important;
  border: none !important;
  color: #94a3b8 !important;
  font-size: 12px !important;
  font-weight: 600 !important;
  cursor: pointer !important;
  padding: 4px 8px !important;
}

.checker-custom-tab-close:hover {
  color: #ef4444 !important;
}

.checker-custom-form-inline {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.custom-input-with-icon {
  display: flex;
  align-items: center;
  background: #ffffff;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  padding: 0 12px;
  flex: 1;
  min-width: 240px;
  height: 38px;
}

.custom-input-with-icon .custom-icon {
  font-weight: 800;
  color: #64748b;
  margin-right: 6px;
}

.custom-input-with-icon input {
  border: none !important;
  padding: 0 !important;
  height: 100% !important;
  outline: none !important;
  font-size: 13px !important;
  width: 100% !important;
  background: transparent !important;
  box-shadow: none !important;
}

.checker-date-input,
.checker-time-select {
  height: 38px !important;
  min-height: 38px !important;
  max-height: 38px !important;
  line-height: normal !important;
  border: 1px solid #cbd5e1 !important;
  border-radius: 8px !important;
  padding: 0 10px !important;
  font-size: 13px !important;
  background-color: #ffffff !important;
  color: #1e293b !important;
}

.checker-custom-btn-submit {
  height: 38px !important;
  min-height: 38px !important;
  line-height: 38px !important;
  padding: 0 16px !important;
  background: #0284c7 !important;
  color: #ffffff !important;
  border: none !important;
  border-radius: 8px !important;
  font-size: 13px !important;
  font-weight: 700 !important;
  cursor: pointer !important;
  transition: all 0.15s ease !important;
}

.checker-custom-btn-submit:hover {
  background: #0369a1 !important;
}

.checker-custom-search-status {
  margin-top: 10px;
  padding: 8px 12px;
  border-radius: 6px;
  font-size: 12.5px;
  line-height: 1.4;
}

.checker-custom-search-status.success {
  background: #ecfdf5;
  border: 1px solid #a7f3d0;
  color: #065f46;
}

.checker-custom-search-status.error {
  background: #fef2f2;
  border: 1px solid #fecaca;
  color: #991b1b;
}

.checker-custom-search-status.loading {
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  color: #1d4ed8;
  font-style: italic;
}

/* ==========================================================================
   DATE-SPECIFIC RESULTS PAGE (/ket-qua/dd-mm-yyyy)
   ========================================================================== */

.lotto-date-view {
  width: 100% !important;
  max-width: 1220px !important;
  margin: 0 auto !important;
}

/* 1. Hero Section */
.lotto-date-hero {
  background: linear-gradient(135deg, #064e3b 0%, #022c22 100%);
  border-radius: 18px;
  padding: 24px 28px 20px;
  color: #ffffff;
  margin-bottom: 24px;
  box-shadow: 0 10px 30px -5px rgba(6, 78, 59, 0.25);
  position: relative;
  overflow: hidden;
}

.lotto-date-hero::after {
  content: '';
  position: absolute;
  top: -50px;
  right: -50px;
  width: 220px;
  height: 220px;
  background: radial-gradient(circle, rgba(16, 185, 129, 0.25) 0%, transparent 70%);
  border-radius: 50%;
  pointer-events: none;
}

.lotto-date-hero .breadcrumb-nav {
  margin-bottom: 12px;
}

.lotto-date-hero .breadcrumb-nav a {
  color: #a7f3d0;
  text-decoration: none;
  font-size: 13px;
}

.lotto-date-hero .breadcrumb-nav a:hover {
  color: #ffffff;
  text-decoration: underline;
}

.lotto-date-hero .breadcrumb-nav span {
  color: #6ee7b7;
  font-size: 13px;
}

.lotto-date-badge {
  background: rgba(16, 185, 129, 0.2);
  border: 1px solid rgba(52, 211, 153, 0.35);
  color: #a7f3d0;
  font-size: 11.5px;
  font-weight: 700;
  border-radius: 20px;
  padding: 3px 12px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  letter-spacing: 0.5px;
  margin-bottom: 8px;
}

.lotto-date-badge .badge-dot {
  width: 7px;
  height: 7px;
  background: #34d399;
  border-radius: 50%;
  box-shadow: 0 0 8px #34d399;
}

.lotto-date-title {
  font-size: 26px !important;
  font-weight: 800 !important;
  color: #ffffff !important;
  margin: 0 0 8px !important;
  line-height: 1.3 !important;
}

.lotto-date-subtitle {
  font-size: 13.5px;
  color: #d1fae5;
  margin: 0 0 16px;
  line-height: 1.5;
  max-width: 820px;
}

/* 2. Date Navigation Toolbar */
.lotto-date-toolbar {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  gap: 12px !important;
  background: rgba(2, 44, 34, 0.75) !important;
  backdrop-filter: blur(8px) !important;
  border: 1px solid rgba(52, 211, 153, 0.3) !important;
  border-radius: 12px !important;
  padding: 10px 16px !important;
  flex-wrap: wrap !important;
}

.date-toolbar-btn {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 6px !important;
  font-size: 13px !important;
  font-weight: 600 !important;
  color: #ffffff !important;
  text-decoration: none !important;
  padding: 0 16px !important;
  height: 38px !important;
  min-height: 38px !important;
  max-height: 38px !important;
  border-radius: 8px !important;
  background: rgba(255, 255, 255, 0.12) !important;
  border: 1px solid rgba(255, 255, 255, 0.2) !important;
  white-space: nowrap !important;
  flex-shrink: 0 !important;
  margin: 0 !important;
  box-sizing: border-box !important;
  transition: all 0.2s ease !important;
}

.btn-text-short {
  display: none !important;
}

.btn-text-full {
  display: inline !important;
}

.date-toolbar-btn:hover {
  background: rgba(255, 255, 255, 0.22) !important;
  color: #ffffff !important;
  transform: translateY(-1px) !important;
}

.date-toolbar-btn.disabled {
  opacity: 0.4 !important;
  cursor: not-allowed !important;
  pointer-events: none !important;
}

.date-toolbar-btn.today-btn {
  background: #059669 !important;
  border-color: #10b981 !important;
  font-weight: 700 !important;
}

.date-toolbar-btn.today-btn:hover {
  background: #047857 !important;
}

.date-toolbar-center {
  display: inline-flex !important;
  align-items: center !important;
  gap: 10px !important;
  white-space: nowrap !important;
  flex-shrink: 0 !important;
  margin: 0 !important;
  padding: 0 !important;
  height: 38px !important;
  min-height: 38px !important;
  max-height: 38px !important;
  box-sizing: border-box !important;
}

.date-picker-label {
  font-size: 13.5px !important;
  font-weight: 700 !important;
  color: #a7f3d0 !important;
  display: inline-flex !important;
  align-items: center !important;
  gap: 6px !important;
  margin: 0 !important;
  white-space: nowrap !important;
  flex-shrink: 0 !important;
  line-height: 1 !important;
  height: 38px !important;
}

.date-toolbar-input {
  background: #ffffff !important;
  color: #0f172a !important;
  border: 1px solid #cbd5e1 !important;
  border-radius: 8px !important;
  padding: 0 10px !important;
  font-size: 13px !important;
  font-weight: 700 !important;
  height: 38px !important;
  min-height: 38px !important;
  max-height: 38px !important;
  width: 145px !important;
  max-width: 145px !important;
  min-width: 130px !important;
  margin: 0 !important;
  margin-bottom: 0 !important;
  vertical-align: middle !important;
  cursor: pointer !important;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1) !important;
  flex-shrink: 0 !important;
  box-sizing: border-box !important;
}

/* 3. Date Page Draw Cards */
.lotto-date-draw-card {
  background: #ffffff !important;
  border: 1px solid #e5e7eb !important;
  border-radius: 14px !important;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.04) !important;
  padding: 20px !important;
  margin-bottom: 24px !important;
}

.lotto-date-draw-card .lotto-live-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid #f1f5f9;
  padding-bottom: 12px;
  margin-bottom: 14px;
  flex-wrap: wrap;
  gap: 8px;
}

/* 4. Balls Display - Standard 3D Spheres */
.date-balls-display {
  display: flex !important;
  justify-content: center !important;
  align-items: center !important;
  gap: 10px !important;
  padding: 16px 10px !important;
  flex-wrap: wrap !important;
}

.date-balls-display .ball {
  width: 48px !important;
  height: 48px !important;
  font-size: 21px !important;
  font-weight: 800 !important;
  border-radius: 50% !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  background: radial-gradient(circle at 35% 30%, #ffffff 0%, #edf8ff 60%, #38bdf8 100%) !important;
  color: #0369a1 !important;
  border: 2px solid #51b9e9 !important;
  box-shadow: 0 4px 12px rgba(14, 165, 233, 0.35), inset 0 2px 4px #ffffff !important;
  line-height: 1 !important;
  transition: transform 0.18s ease !important;
}

.date-balls-display .ball:hover {
  transform: scale(1.08) !important;
}

.date-balls-display .ball.gold {
  background: radial-gradient(circle at 35% 30%, #fffdf5 0%, #fef3c7 60%, #f59e0b 100%) !important;
  color: #78350f !important;
  border: 2px solid #f59e0b !important;
  box-shadow: 0 4px 14px rgba(245, 158, 11, 0.5), inset 0 2px 4px #ffffff !important;
  margin-left: 8px !important;
}

/* 5. Stats Row */
.draw-card-stats-row {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
  margin: 12px 0 16px;
  flex-wrap: wrap;
}

.stat-pill {
  font-size: 12.5px;
  font-weight: 500;
  color: #475569;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 20px;
  padding: 4px 14px;
}

.stat-pill strong {
  color: #0f172a;
  font-weight: 700;
}

/* 6. Card Action Footer */
.draw-card-footer {
  display: flex;
  align-items: center;
  gap: 12px;
  border-top: 1px dashed #e2e8f0;
  padding-top: 16px;
  margin-top: 16px;
  flex-wrap: wrap;
}

.card-action-btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 8px 16px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 700;
  text-decoration: none !important;
  transition: all 0.2s ease;
}

.card-action-btn.primary {
  background-color: #059669 !important;
  color: #ffffff !important;
  border: 1px solid #059669 !important;
  box-shadow: 0 2px 6px rgba(5, 150, 105, 0.25) !important;
}

.card-action-btn.primary span {
  color: #ffffff !important;
}

.card-action-btn.primary svg {
  stroke: #ffffff !important;
}

.card-action-btn.primary:hover {
  background-color: #047857 !important;
  color: #ffffff !important;
  border-color: #047857 !important;
  transform: translateY(-1px);
}

.card-action-btn.outline {
  background: #f8fafc;
  border: 1px solid #cbd5e1;
  color: #334155 !important;
}

.card-action-btn.outline:hover {
  background: #f1f5f9;
  color: #0f172a !important;
}

/* 7. Notice Cards */
.lotto-date-notice-card {
  background: #ffffff;
  border-radius: 14px;
  padding: 32px 24px;
  text-align: center;
  box-shadow: 0 4px 16px rgba(15, 23, 42, 0.05);
  margin-bottom: 24px;
}

.lotto-date-notice-card.future-card {
  border: 1px solid #fef08a;
  background: #fefce8;
}

.lotto-date-notice-card.nodata-card {
  border: 1px solid #e2e8f0;
  background: #f8fafc;
}

.upcoming-notice-card {
  background: #f0fdf4 !important;
  border: 1px dashed #34d399 !important;
  text-align: center;
  padding: 24px !important;
}

.notice-icon {
  font-size: 40px;
  margin-bottom: 10px;
}

.lotto-date-notice-card h3,
.upcoming-notice-card h3 {
  font-size: 18px !important;
  font-weight: 800 !important;
  color: #0f172a !important;
  margin: 0 0 8px !important;
}

.lotto-date-notice-card p,
.upcoming-notice-card p {
  font-size: 13.5px;
  color: #475569;
  max-width: 580px;
  margin: 0 auto 16px;
  line-height: 1.5;
}

.notice-actions {
  display: flex;
  gap: 10px;
  justify-content: center;
  flex-wrap: wrap;
}

.date-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px 18px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 700;
  text-decoration: none !important;
  transition: all 0.2s ease;
}

.date-btn.primary-btn {
  background: #059669;
  color: #ffffff !important;
}

.date-btn.primary-btn:hover {
  background: #047857;
  color: #ffffff !important;
}

.date-btn.outline-btn {
  background: #ffffff;
  border: 1px solid #cbd5e1;
  color: #334155 !important;
}

.date-btn.outline-btn:hover {
  background: #f1f5f9;
  color: #0f172a !important;
}

.date-btn.submit-btn {
  background: #0284c7;
  color: #ffffff !important;
  border: none;
  cursor: pointer;
}

.date-btn.submit-btn:hover {
  background: #0369a1;
}

/* 8. Error Card (Invalid Date like 31-09 or 30-02) */
.date-error-container {
  padding: 30px 15px 40px;
  display: flex;
  justify-content: center;
}

.date-error-card {
  max-width: 620px;
  width: 100%;
  background: #ffffff;
  border: 1px solid #fecaca;
  border-radius: 16px;
  box-shadow: 0 10px 25px rgba(220, 38, 38, 0.08);
  padding: 34px 28px;
  text-align: center;
}

.date-error-icon {
  font-size: 44px;
  margin-bottom: 8px;
}

.date-error-badge {
  font-size: 11px;
  font-weight: 800;
  color: #b91c1c;
  background: #fee2e2;
  border-radius: 20px;
  padding: 3px 12px;
  display: inline-block;
  margin-bottom: 10px;
  letter-spacing: 0.5px;
}

.date-error-title {
  font-size: 23px !important;
  font-weight: 800 !important;
  color: #991b1b !important;
  margin: 0 0 10px 0 !important;
}

.date-error-desc {
  font-size: 15px;
  font-weight: 600;
  color: #b91c1c;
  margin: 0 0 6px 0;
  line-height: 1.5;
}

.date-error-sub {
  font-size: 13.5px;
  color: #64748b;
  margin: 0 0 20px 0;
}

.date-error-actions {
  display: flex;
  gap: 10px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 22px;
}

.date-error-picker-box {
  border-top: 1px dashed #e2e8f0;
  padding-top: 18px;
}

.date-error-picker-box label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: #475569;
  margin-bottom: 8px;
}

.date-picker-inline {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.date-picker-inline input[type="date"] {
  height: 36px !important;
  border: 1px solid #cbd5e1 !important;
  border-radius: 6px !important;
  padding: 0 10px !important;
  font-size: 13px !important;
}

/* 9. FAQ Section on Date Page */
.lotto-date-faq-wrap {
  margin-top: 10px;
}

/* Responsive adjustments */
@media (max-width: 880px) {
  .lotto-date-hero {
    padding: 18px 14px 16px !important;
  }
  .lotto-date-title {
    font-size: 20px !important;
  }
  .lotto-date-toolbar {
    display: grid !important;
    grid-template-columns: 1fr 1fr !important;
    gap: 10px !important;
    padding: 12px !important;
    background: rgba(2, 44, 34, 0.85) !important;
    border-radius: 12px !important;
    box-sizing: border-box !important;
    width: 100% !important;
  }
  .date-toolbar-btn.prev-btn {
    grid-column: 1 / 2 !important;
    grid-row: 1 !important;
    width: 100% !important;
    justify-content: center !important;
    text-align: center !important;
    padding: 8px 6px !important;
    box-sizing: border-box !important;
    font-size: 13px !important;
  }
  .date-toolbar-btn.next-btn {
    grid-column: 2 / 3 !important;
    grid-row: 1 !important;
    width: 100% !important;
    justify-content: center !important;
    text-align: center !important;
    padding: 8px 6px !important;
    box-sizing: border-box !important;
    font-size: 13px !important;
  }
  .btn-text-full {
    display: none !important;
  }
  .btn-text-short {
    display: inline !important;
    white-space: nowrap !important;
  }
  .date-toolbar-center {
    grid-column: 1 / -1 !important;
    grid-row: 2 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 8px !important;
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 !important;
    padding: 6px 10px !important;
    background: rgba(0, 0, 0, 0.28) !important;
    border: 1px solid rgba(52, 211, 153, 0.25) !important;
    border-radius: 8px !important;
    box-sizing: border-box !important;
  }
  .date-picker-label {
    display: inline-flex !important;
    align-items: center !important;
    gap: 6px !important;
    color: #a7f3d0 !important;
    font-size: 13px !important;
    font-weight: 700 !important;
    white-space: nowrap !important;
    margin: 0 !important;
    flex-shrink: 0 !important;
  }
  .date-picker-label svg {
    flex-shrink: 0 !important;
  }
  .date-toolbar-input {
    flex: 1 1 auto !important;
    min-width: 0 !important;
    width: auto !important;
    max-width: 160px !important;
    height: 36px !important;
    min-height: 36px !important;
    margin: 0 !important;
    margin-bottom: 0 !important;
    padding: 4px 8px !important;
    border: 1px solid #cbd5e1 !important;
    border-radius: 6px !important;
    background: #ffffff !important;
    color: #0f172a !important;
    font-size: 13px !important;
    font-weight: 700 !important;
    box-sizing: border-box !important;
    text-align: center !important;
    cursor: pointer !important;
  }
  .date-toolbar-btn.today-btn {
    grid-column: 1 / -1 !important;
    grid-row: 3 !important;
    width: 100% !important;
    justify-content: center !important;
    text-align: center !important;
    padding: 9px 12px !important;
    box-sizing: border-box !important;
    font-size: 13.5px !important;
    border-radius: 8px !important;
  }
  .date-balls-display .ball {
    width: 38px !important;
    height: 38px !important;
    font-size: 16px !important;
  }
}

/* ==========================================================================
   Lotto History Grouped By Date - Compact & Clean Edition
   ========================================================================== */
.lotto-history-header {
  display: grid !important;
  grid-template-columns: 160px 1fr 130px 80px !important;
  align-items: center !important;
  gap: 10px !important;
  background: linear-gradient(180deg, #f0fdf4 0%, #dcfce7 100%) !important;
  border: 1px solid #86efac !important;
  border-radius: 8px !important;
  padding: 8px 14px !important;
  font-size: 12px !important;
  font-weight: 700 !important;
  color: #064e3b !important;
  letter-spacing: 0.3px !important;
  margin-bottom: 6px !important;
  box-sizing: border-box !important;
}

.lotto-history-header .history-hdr-draw {
  text-align: left !important;
}

.lotto-history-header .history-hdr-balls {
  text-align: center !important;
}

.lotto-history-header .history-hdr-prize {
  text-align: right !important;
}

.lotto-history-header .history-hdr-action {
  text-align: right !important;
}

.lotto-history-list {
  display: flex !important;
  flex-direction: column !important;
  gap: 8px !important;
}

.history-date-group {
  background: #ffffff !important;
  border: 1px solid #e2e8f0 !important;
  border-radius: 8px !important;
  overflow: hidden !important;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.03) !important;
  transition: all 0.15s ease !important;
  box-sizing: border-box !important;
}

.history-date-group:hover {
  border-color: #cbd5e1 !important;
}

/* 1 Dòng link ngày - Tinh gọn, thanh lịch */
.history-date-header {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  background: #f8fafc !important;
  border-bottom: 1px solid #f1f5f9 !important;
  padding: 8px 14px !important;
  gap: 10px !important;
  box-sizing: border-box !important;
}

.history-date-left {
  display: flex !important;
  align-items: center !important;
  gap: 8px !important;
  flex-wrap: wrap !important;
}

.history-date-title {
  display: inline-flex !important;
  align-items: center !important;
  gap: 6px !important;
  font-size: 13.5px !important;
  font-weight: 700 !important;
  color: #1e293b !important;
  text-decoration: none !important;
  transition: color 0.15s ease !important;
}

.history-date-title:hover {
  color: #059669 !important;
}

.history-date-calendar-icon {
  font-size: 14px !important;
  line-height: 1 !important;
}

.history-date-badge {
  display: none !important;
}

.history-date-right {
  display: flex !important;
  align-items: center !important;
  flex-shrink: 0 !important;
}

.history-date-link-btn {
  font-size: 12.5px !important;
  font-weight: 600 !important;
  color: #059669 !important;
  text-decoration: none !important;
  padding: 2px 4px !important;
  transition: color 0.15s ease !important;
  white-space: nowrap !important;
}

.history-date-link-btn:hover {
  color: #047857 !important;
  text-decoration: underline !important;
}

/* Các dòng con (sub-rows) */
.history-date-subrows {
  display: flex !important;
  flex-direction: column !important;
}

.history-row,
.history-date-subrows .history-sub-row {
  display: grid !important;
  grid-template-columns: 160px 1fr 130px 80px !important;
  align-items: center !important;
  gap: 10px !important;
  border-top: 1px solid #f1f5f9 !important;
  padding: 9px 14px !important;
  background: #ffffff;
  box-sizing: border-box !important;
  transition: background-color 0.15s ease !important;
}

.history-date-subrows .history-sub-row:first-child {
  border-top: none !important;
}

.history-date-subrows .history-sub-row:hover {
  background-color: #f8fafc !important;
}

/* Col 1: Mã kỳ quay & giờ quay */
.history-row .history-draw-col {
  display: flex !important;
  align-items: center !important;
  gap: 8px !important;
  white-space: nowrap !important;
  line-height: 1 !important;
}

.history-row .history-draw-id {
  color: #059669 !important;
  font-size: 14px !important;
  font-weight: 700 !important;
}

.history-draw-tag {
  font-size: 11.5px !important;
  font-weight: 600 !important;
  padding: 2px 6px !important;
  border-radius: 4px !important;
  display: inline-flex !important;
  align-items: center !important;
  white-space: nowrap !important;
  line-height: 1 !important;
}

.history-draw-tag.time-evening {
  background: #f3e8ff !important;
  color: #7e22ce !important;
  border: none !important;
}

.history-draw-tag.time-noon {
  background: #fef3c7 !important;
  color: #92400e !important;
  border: none !important;
}

/* Col 2: Balls */
.history-row .result-balls {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 5px !important;
  line-height: 1 !important;
  margin: 0 !important;
  padding: 0 !important;
}

.history-row .result-balls .ball {
  width: 30px !important;
  height: 30px !important;
  font-size: 13px !important;
}

/* Col 3: Prize */
.history-row .history-prize {
  display: flex !important;
  align-items: center !important;
  justify-content: flex-end !important;
  text-align: right !important;
  line-height: 1 !important;
}

.history-row .history-prize-val {
  color: #d80000 !important;
  font-size: 14px !important;
  font-weight: 700 !important;
  white-space: nowrap !important;
}

/* Col 4: Action button */
.history-row .history-action {
  display: flex !important;
  align-items: center !important;
  justify-content: flex-end !important;
  margin: 0 !important;
  padding: 0 !important;
}

.history-row .lotto-toggle-detail-btn {
  width: 76px !important;
  min-width: 76px !important;
  max-width: 76px !important;
  height: 28px !important;
  min-height: 28px !important;
  font-size: 11.5px !important;
  font-weight: 600 !important;
  border-radius: 4px !important;
  padding: 0 !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  background: #f0fdf4 !important;
  border: 1px solid #bbf7d0 !important;
  color: #15803d !important;
  transition: all 0.15s ease !important;
}

.history-row .lotto-toggle-detail-btn:hover {
  background: #15803d !important;
  border-color: #15803d !important;
  color: #ffffff !important;
}

.history-row .lotto-toggle-detail-btn.is-active {
  background: #fee2e2 !important;
  border-color: #fca5a5 !important;
  color: #b91c1c !important;
}

/* Responsive adjustment for Mobile */
@media (max-width: 900px) {
  .lotto-history-header {
    display: none !important;
  }
  .history-date-header {
    padding: 8px 10px !important;
    flex-direction: row !important;
    align-items: center !important;
    justify-content: space-between !important;
  }
  .history-row,
  .history-date-subrows .history-sub-row {
    grid-template-columns: 1fr auto !important;
    gap: 8px !important;
    padding: 10px 10px !important;
  }
}




