:root {
  --bg: #080606;
  --surface: #131111;
  --surface-2: #22120f;
  --text: #f8f4ea;
  --muted: #c98d4d;
  --gold: #d8b24a;
  --gold-2: #ffdf79;
  --accent: #8f1f1f;
  --border: rgba(216, 178, 74, 0.28);
}

* { box-sizing: border-box; }
body {
  margin: 0;
  font-family: 'Inter', sans-serif;
  background: radial-gradient(circle at top, rgba(143, 31, 31, 0.2), transparent 28%), var(--bg);
  color: var(--text);
  line-height: 1.6;
}
.dashboard-page {
  display: flex;
  min-height: 100vh;
  background: var(--bg);
  overflow: hidden;
}
.dashboard-drawer {
  flex: 0 0 250px;
  width: 250px;
  min-width: 250px;
  padding: 1.5rem 1.1rem 1.25rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  background: rgba(10, 8, 6, 0.98);
  border-right: 1px solid rgba(216, 178, 74, 0.2);
  transition: width 0.25s ease, min-width 0.25s ease, padding 0.25s ease;
  position: fixed;
  top: 0;
  left: 0;
  height: 100vh;
  z-index: 40;
}
.dashboard-drawer.is-collapsed {
  width: 82px;
  min-width: 82px;
  padding-inline: 0.8rem;
}
.dashboard-drawer.is-collapsed + .dashboard-main {
  margin-left: 82px;
}
.drawer-brand {
  font-size: 1.1rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gold-2);
  padding-bottom: 1rem;
  border-bottom: 1px solid rgba(216, 178, 74, 0.16);
}
.drawer-nav {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  margin-top: 1.25rem;
}
.drawer-link,
.drawer-logout {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  padding: 0.8rem 0.95rem;
  border-radius: 12px;
  color: var(--text);
  transition: background 0.2s ease, color 0.2s ease;
}
.drawer-link:hover,
.drawer-link.active,
.drawer-logout:hover {
  background: rgba(216, 178, 74, 0.14);
  color: var(--gold-2);
}
.drawer-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.45rem;
  height: 1.45rem;
  font-size: 1rem;
  line-height: 1;
}
.drawer-label {
  white-space: nowrap;
}
.dashboard-drawer.is-collapsed .drawer-label,
.dashboard-drawer.is-collapsed .drawer-brand {
  display: none;
}
.dashboard-drawer.is-collapsed .drawer-link,
.dashboard-drawer.is-collapsed .drawer-logout {
  justify-content: center;
  padding-inline: 0.7rem;
}
.drawer-logout {
  margin-top: 1rem;
  text-align: center;
  background: rgba(143, 31, 31, 0.18);
  border: 1px solid rgba(143, 31, 31, 0.32);
  color: #ffd7d7;
}
.dashboard-main {
  flex: 1 1 auto;
  min-width: 0;
  display: flex;
  flex-direction: column;
  margin-left: 250px;
  transition: margin-left 0.25s ease;
}
a { color: inherit; text-decoration: none; }
button, input { font: inherit; }

.topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.1rem 2rem;
  background: rgba(7, 7, 7, 0.8);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 20;
}
.dashboard-topbar {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 1.75rem;
  background: rgba(12, 9, 6, 0.94);
  border-bottom: 1px solid rgba(216, 178, 74, 0.22);
  box-sizing: border-box;
}
.dashboard-left {
  display: flex;
  align-items: center;
  gap: 1rem;
}
.hamburger {
  display: inline-flex;
  flex-direction: column;
  justify-content: center;
  gap: 0.35rem;
  width: 2.4rem;
  height: 2.4rem;
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 16px;
  background: rgba(20, 18, 15, 0.8);
  color: var(--text);
  cursor: pointer;
}
.hamburger span {
  display: block;
  height: 2px;
  background: var(--text);
  border-radius: 999px;
}
.dashboard-title {
  font-size: 1.05rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}
.dashboard-balance {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.55rem 0.85rem;
  border-radius: 16px;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.1);
  min-width: 170px;
  margin: 0 auto;
  white-space: nowrap;
}
.wallet-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.9rem;
  height: 1.9rem;
  border-radius: 50%;
  background: rgba(255,255,255,0.08);
  color: var(--gold-2);
}
.dashboard-balance strong {
  font-size: 1rem;
  color: var(--gold-2);
}
.dashboard-user {
  position: relative;
}
.dropdown-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  padding: 0.8rem 1rem;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,0.15);
  background: rgba(20, 18, 15, 0.8);
  color: var(--text);
  cursor: pointer;
}
.user-name {
  display: inline-block;
}
.user-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2rem;
  height: 2rem;
  border-radius: 50%;
  background: rgba(255,255,255,0.08);
}
.dropdown-menu {
  display: none;
  position: absolute;
  right: 0;
  top: calc(100% + 0.65rem);
  min-width: 180px;
  background: rgba(18, 15, 11, 0.98);
  border: 1px solid rgba(216, 178, 74, 0.22);
  border-radius: 16px;
  padding: 0.75rem 0;
  box-shadow: 0 18px 50px rgba(0,0,0,0.35);
  z-index: 30;
}
.dropdown-menu a {
  display: block;
  padding: 0.85rem 1rem;
  color: var(--text);
  font-size: 0.95rem;
}
.dropdown-menu a:hover {
  background: rgba(255,255,255,0.05);
}
.dropdown.open .dropdown-menu {
  display: block;
}
.dashboard-shell {
  padding: 2rem 1.75rem 3rem;
  min-height: calc(100vh - 76px);
  background:
    linear-gradient(90deg, rgba(8, 6, 6, 0.84) 0%, rgba(8, 6, 6, 0.7) 55%, rgba(8, 6, 6, 0.85) 100%),
    url('../assets/images/sabongB.jpeg') center/cover no-repeat;
}
.game-shell {
  padding: 1rem 0 0;
}
.game-event-header {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.2rem 1.4rem;
  background: rgba(18, 14, 10, 0.82);
  border: 1px solid rgba(216, 178, 74, 0.2);
  border-radius: 0;
  backdrop-filter: blur(8px);
  position: relative;
  left: 0;
  margin: 0;
  box-sizing: border-box;
}
.event-left,
.event-center,
.event-status {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  min-width: 0;
}
.event-left {
  flex: 1 1 0;
  justify-content: flex-start;
}
.event-center {
  flex: 1 1 0;
  justify-content: center;
  color: #d8cca0;
  font-size: 0.98rem;
}
.event-status {
  flex: 1 1 0;
  justify-content: flex-end;
  color: #d2f2d5;
  font-weight: 700;
}
.event-badge {
  display: inline-flex;
  padding: 0.3rem 0.65rem;
  border-radius: 999px;
  background: rgba(216, 178, 74, 0.15);
  color: var(--gold-2);
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  white-space: nowrap;
}
.event-name {
  margin: 0;
  font-size: 0.98rem;
  line-height: 1.15;
  text-transform: uppercase;
  white-space: nowrap;
}
.status-dot {
  width: 0.72rem;
  height: 0.72rem;
  border-radius: 50%;
  background: #48c96d;
  box-shadow: 0 0 0 4px rgba(72, 201, 109, 0.16);
}
.game-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.65fr) minmax(0, 1fr);
  gap: 0;
  align-items: start;
  padding: 0 0 1rem;
}
.stream-wrap {
  min-width: 0;
  margin: 0;
}
.stream-player {
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: 0;
  overflow: hidden;
  background: linear-gradient(160deg, rgba(20, 20, 20, 0.9), rgba(10, 10, 10, 0.95));
  border: 1px solid rgba(216, 178, 74, 0.2);
  box-shadow: none;
}
.recent-activity-card {
  grid-column: 1 / -1;
  width: 100%;
  margin-top: 0.85rem;
  padding: 1rem;
  background: rgba(10, 10, 10, 0.86);
  border: 1px solid rgba(216, 178, 74, 0.2);
  border-radius: 8px;
  box-sizing: border-box;
}
.recent-activity-card h3 {
  margin: 0 0 0.9rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid #1e293b;
  color: #94a3b8;
  font-size: 0.66rem;
  font-weight: 900;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}
.recent-activity-list {
  max-height: 18.75rem;
  overflow-y: auto;
}
.recent-activity-list p {
  margin: 0;
  text-align: center;
  color: #94a3b8;
  font-size: 0.75rem;
  font-style: italic;
}
.stream-placeholder {
  width: 100%;
  height: 100%;
  display: grid;
  place-items: center;
  font-size: 1.2rem;
  font-weight: 800;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--gold-2);
}
.betting-panel {
  width: auto;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0;
  align-content: start;
  align-items: start;
}
.betting-amount-control {
  grid-column: 1 / -1;
  display: grid;
  gap: 0.7rem;
  padding: 0.9rem;
  background: rgba(10, 10, 10, 0.86);
  border: 1px solid rgba(216, 178, 74, 0.2);
  box-sizing: border-box;
}
.betting-amount-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
}
.betting-amount-title {
  font-size: 0.92rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.betting-amount-hint {
  font-size: 0.74rem;
  color: #d8cca0;
}
.betting-draw-header {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: auto auto auto 1fr auto;
  align-items: center;
  gap: 0.75rem;
  padding: 0.55rem 0.8rem;
  border: 1px solid rgba(52, 211, 153, 0.24);
  border-radius: 0;
  background: rgba(52, 211, 153, 0.08);
  box-sizing: border-box;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.68rem;
  font-weight: 800;
}
.draw-header-title {
  color: #34d399;
}
.draw-header-payout {
  color: #f8fafc;
}
.draw-header-meta {
  color: #d8cca0;
  font-size: 0.62rem;
  letter-spacing: 0.08em;
}
.draw-header-amount {
  justify-self: end;
  color: #f8fafc;
  font-size: 0.64rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: none;
}
.draw-header-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  padding: 0.45rem 0.7rem;
  border: none;
  border-radius: 0;
  background: rgba(16, 185, 129, 0.18);
  color: #d1fae5;
  font-size: 0.64rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  cursor: pointer;
}
.draw-header-button .action-icon {
  width: 1.2rem;
  height: 1.2rem;
  font-size: 0.78rem;
}
.amount-chip-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 0.45rem;
}
.amount-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.65rem 0.5rem;
  border: 1px solid rgba(255,255,255,0.14);
  background: rgba(255,255,255,0.06);
  color: var(--text);
  border-radius: 12px;
  font-weight: 700;
  cursor: pointer;
}
.amount-chip-max {
  border-color: rgba(216, 178, 74, 0.55);
  background: rgba(216, 178, 74, 0.18);
  color: var(--gold-2);
}
.amount-input-wrap {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  width: 100%;
  padding: 0.7rem 0.85rem;
  border: 1px solid rgba(255,255,255,0.14);
  background: rgba(255,255,255,0.04);
  border-radius: 12px;
}
.amount-input-wrap span {
  color: var(--gold-2);
  font-weight: 800;
}
.amount-input-wrap input {
  width: 100%;
  border: none;
  outline: none;
  background: transparent;
  color: var(--text);
  font-size: 0.95rem;
}
.trend-map {
  grid-column: 1 / -1;
  display: grid;
  gap: 0.7rem;
  padding: 0.9rem;
  background: rgba(10, 10, 10, 0.86);
  border: 1px solid rgba(216, 178, 74, 0.2);
  box-sizing: border-box;
}
.trend-map-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
}
.trend-map-title {
  font-size: 0.78rem;
  font-weight: 800;
  color: #c7cfe0;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.trend-map-legend {
  display: flex;
  gap: 0.6rem;
  flex-wrap: wrap;
}
.legend-item {
  font-size: 0.72rem;
  font-weight: 800;
}
.legend-meron { color: #f87171; }
.legend-wala { color: #60a5fa; }
.legend-draw { color: #34d399; }
.trend-grid {
  display: grid;
  grid-template-columns: repeat(24, minmax(0, 1fr));
  gap: 0.2rem;
  min-height: 10rem;
  padding: 0.4rem;
  background-image:
    linear-gradient(rgba(255,255,255,0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.03) 1px, transparent 1px);
  background-size: 18px 18px;
}
.trend-dot {
  display: inline-grid;
  place-items: center;
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 50%;
  font-size: 0.48rem;
  font-weight: 800;
}
.trend-meron {
  background: rgba(239, 68, 68, 0.95);
  color: white;
}
.trend-wala {
  background: rgba(59, 130, 246, 0.95);
  color: white;
}
.trend-draw {
  background: rgba(16, 185, 129, 0.95);
  color: white;
}
.game-grid-history {
  grid-column: 1 / -1;
  display: grid;
  gap: 0.65rem;
  padding: 0.9rem;
 background: rgba(10, 10, 10, 0.86);
  border: 1px solid rgba(216, 178, 74, 0.2);
  box-sizing: border-box;
}
.game-grid-header {
  padding-bottom: 0.35rem;
  border-bottom: 1px solid rgba(148, 163, 184, 0.22);
}
.game-grid-title {
  font-size: 0.72rem;
  font-weight: 900;
  color: #94a3b8;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
.history-grid {
  display: grid;
  gap: 0.2rem;
  overflow-x: auto;
}
.history-row {
  display: grid;
  grid-template-columns: repeat(15, minmax(0, 1fr));
  gap: 0.18rem;
}
.history-cell {
  display: grid;
  place-items: center;
  min-height: 1.35rem;
  aspect-ratio: 1 / 1;
  border-radius: 50%;
  font-size: 0.48rem;
  font-weight: 800;
  color: #f8fafc;
}
.history-cell.M { background: #dc2626; }
.history-cell.W { background: #2563eb; }
.history-cell.D { background: #10b981; }
.history-cell.C { background: #64748b; }
.betting-card {
  display: flex;
  flex-direction: column;
  gap: 0;
  padding: 0;
  min-height: auto;
  box-shadow: 0 18px 50px rgba(0,0,0,0.2);
}
.betting-card-meron {
  background: linear-gradient(180deg, rgba(129, 20, 20, 0.95), rgba(65, 11, 11, 0.98));
  border: 1px solid rgba(255, 138, 138, 0.35);
}
.betting-card-wala {
  background: linear-gradient(180deg, rgba(17, 51, 103, 0.95), rgba(8, 21, 50, 0.98));
  border: 1px solid rgba(119, 165, 255, 0.35);
}
.betting-card-top {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  width: 100%;
  height: 3.5rem;
}
.betting-label {
  font-size: 1.05rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.betting-badge {
  display: inline-flex;
  align-items: center;
  padding: 0.35rem 0.55rem;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.26);
  font-size: 0.75rem;
}
.betting-stats {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 0;
  background: rgba(0, 0, 0, 0.895);
  border: 1px solid rgba(255,255,255,0.08);
  box-sizing: border-box;
}

#totalBets {
  font-size: 1.5rem;
}

#userBet {
  background: rgba(255, 255, 255, 0.366);
  border-radius: 1.5rem;
  width: fit-content;
  gap: 0.5rem;
  padding: 0.5rem;
  font-size: 0.8rem;
}

#userPays {
    background: rgba(255, 255, 255, 0.227);
  border-radius: 1.5rem;
  width: fit-content;
  gap: 0.5rem;
  font-size: 0.7rem;
  padding: 0.3rem;
  margin-bottom: 0.35rem;
}
.stats-row {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  min-height: 2rem;
}
.stats-row strong {
  color: #ffffff;
  font-size: 1rem;
  font-weight: 800;
}
.betting-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  width: 100%;
  padding: 0.8rem 0.9rem;
  border: none;
  border-radius: 0;
  background: transparent;
  color: var(--text);
  font-weight: 700;
  cursor: pointer;
}
.action-icon {
  display: inline-grid;
  place-items: center;
  width: 1.5rem;
  height: 1.5rem;
  border-radius: 50%;
  background: rgba(255,255,255,0.15);
  font-size: 1rem;
  font-weight: 800;
}
.dashboard-category {
  max-width: 1060px;
  margin: 0 auto;
}
.category-header {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  padding-bottom: 1rem;
  color: var(--text);
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
.live-dot {
  width: 0.75rem;
  height: 0.75rem;
  border-radius: 50%;
  background: #e34d4d;
  box-shadow: 0 0 0 5px rgba(227,77,77,0.12);
}
.live-game-card {
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: 1rem;
  padding: 1.3rem;
  background: rgba(25, 15, 14, 0.9);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 28px;
  box-shadow: 0 24px 70px rgba(0,0,0,0.25);
}
.card-thumb {
  border-radius: 24px;
  overflow: hidden;
  min-width: 120px;
  min-height: 120px;
}
.card-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.card-content {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 0.75rem;
}
.card-top {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  flex-wrap: wrap;
}
.pill {
  display: inline-flex;
  align-items: center;
  padding: 0.4rem 0.75rem;
  border-radius: 999px;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.pill-live {
  background: #2b5934;
  color: #e8f8e9;
}
.card-meta {
  color: #b9a86c;
  font-size: 0.9rem;
}
.live-game-card h2 {
  margin: 0;
  font-size: clamp(1.5rem, 2vw, 2rem);
  line-height: 1.05;
}
.card-date {
  margin: 0;
  color: #d4c9a1;
  font-size: 0.95rem;
}
.card-button {
  width: fit-content;
  padding: 0.85rem 1.15rem;
}
@media (max-width: 860px) {
  .game-layout {
    grid-template-columns: 1fr;
    gap: 0.9rem;
  }
  .stream-wrap,
  .betting-panel {
    width: 100%;
  }
  .betting-panel {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 0.75rem;
  }
  .betting-card {
    min-width: 0;
  }
  .stream-wrap {
    display: grid;
    gap: 0.85rem;
  }
  .game-event-header {
    flex-direction: column;
    align-items: stretch;
    gap: 0.7rem;
  }
  .event-left,
  .event-center,
  .event-status {
    flex: 0 0 auto;
    justify-content: flex-start;
    width: 100%;
  }
  .event-center {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.4rem;
  }
  .event-name {
    white-space: normal;
  }
  .live-game-card {
    grid-template-columns: 1fr;
  }
  .card-thumb {
    min-width: 0;
    width: 100%;
    min-height: 0;
  }
  .card-thumb img {
    width: 100%;
    height: auto;
    object-fit: cover;
  }
}
.brand {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.24em;
  text-transform: uppercase;
}
.brand-mark {
  display: inline-grid;
  place-items: center;
  width: 2.2rem;
  height: 2.2rem;
  border-radius: 50%;
  overflow: hidden;
  background: linear-gradient(135deg, var(--gold), var(--gold-2));
  border: 1px solid rgba(255,255,255,0.16);
  box-shadow: 0 8px 24px rgba(0,0,0,0.35);
}
.brand-mark img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.topbar-nav { display: flex; gap: 1.2rem; color: #e9ddc2; }
.auth-actions { display: flex; gap: 0.8rem; align-items: center; }
.welcome { color: var(--muted); font-size: 0.95rem; }

.btn, .ghost-btn, .primary-btn {
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 0.75rem 1.1rem;
  cursor: pointer;
  transition: transform 180ms ease, background 180ms ease, color 180ms ease;
}
.btn:hover, .ghost-btn:hover, .primary-btn:hover { transform: translateY(-2px); }
.btn-primary, .primary-btn {
  background: linear-gradient(135deg, var(--gold), var(--accent));
  color: #090909;
  font-weight: 700;
}
.btn-secondary, .ghost-btn {
  background: transparent;
  color: var(--text);
}

.hero-shell {
  min-height: calc(100vh - 84px);
  display: flex;
  align-items: center;
  padding: 4rem 2rem 3rem;
  background:
    linear-gradient(90deg, rgba(8, 6, 6, 0.9) 0%, rgba(8, 6, 6, 0.7) 42%, rgba(8, 6, 6, 0.3) 100%),
    url('../assets/images/sabongB.png') center/cover no-repeat;
    
}
.hero-copy {
  max-width: 620px;
  padding: 2rem;
  border: 1px solid var(--border);
  border-radius: 24px;
  background: rgba(10, 10, 10, 0.76);
  backdrop-filter: blur(10px);
  box-shadow: 0 20px 60px rgba(0,0,0,0.35);
}
.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.3em;
  color: var(--gold);
  font-weight: 700;
  margin-bottom: 0.4rem;
}
.hero-copy h1 {
  font-size: clamp(2.4rem, 5vw, 4.2rem);
  margin: 0 0 0.8rem;
  letter-spacing: 0.08em;
}
.hero-text { max-width: 620px; color: #ddd2b5; font-size: 1.05rem; }
.hero-actions { display: flex; gap: 1rem; margin-top: 1.6rem; }
.hero-visual img {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 24px;
  box-shadow: 0 20px 60px rgba(0,0,0,0.35);
}
.flash-message {
  margin-top: 1rem;
  display: inline-block;
  padding: 0.7rem 1rem;
  border-radius: 999px;
  background: rgba(216, 178, 74, 0.14);
  border: 1px solid var(--border);
  color: var(--gold-2);
}

.cards, .about-panel {
  max-width: 1200px;
  margin: 0 auto;
  padding: 1rem 2rem 3rem;
}
.cards {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}
.card, .about-panel {
  background: linear-gradient(145deg, rgba(20, 20, 20, 0.96), rgba(10, 10, 10, 0.95));
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 1.2rem;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.04);
}
.about-panel { display: grid; grid-template-columns: 1.2fr 0.8fr; gap: 2rem; }
.about-panel ul { margin: 0; padding-left: 1.2rem; color: #e3d7b2; }

.footer {
  text-align: center;
  color: #9c8a4e;
  padding: 0 2rem 2rem;
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.62);
  display: none;
  z-index: 40;
}
.modal {
  position: fixed;
  top: 50%;
  right: 2rem;
  transform: translateY(-50%) scale(0.95);
  width: min(92vw, 440px);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 1.4rem;
  display: none;
  z-index: 50;
  box-shadow: 0 24px 90px rgba(0,0,0,0.45);
}
.modal.open, .modal-backdrop.open { display: block; }
.modal-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 1rem; }
.modal-close { background: transparent; border: none; color: var(--text); cursor: pointer; font-size: 1.1rem; }
.auth-form { display: flex; flex-direction: column; gap: 0.8rem; }
.auth-form input {
  width: 100%;
  padding: 0.8rem 0.9rem;
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,0.12);
  background: #1b1b1b;
  color: var(--text);
}
.auth-form button { margin-top: 0.3rem; }

@media (max-width: 860px) {
  .hero-shell { padding: 2rem 1rem 2.5rem; }
  .hero-copy { padding: 1.5rem; }
  .topbar { flex-wrap: wrap; gap: 0.8rem; }
  .modal {
    right: 1rem;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    width: auto;
  }
  .dashboard-topbar {
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 1rem;
  }
  .dashboard-left {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    flex: 1 1 100%;
  }
  .dashboard-title {
    text-align: left;
    font-size: 1rem;
  }
  .dashboard-balance {
    order: 2;
    width: 100%;
    justify-content: center;
    margin: 0.5rem 0;
    min-width: auto;
  }
  .dashboard-user {
    order: 3;
    width: 100%;
    display: flex;
    justify-content: flex-end;
  }
  .dropdown-toggle {
    width: auto;
  }
}

@media (max-width: 560px) {
  .hero-shell { padding: 1.5rem 0.75rem 2rem; }
  .hero-copy { padding: 1.3rem; }
  .dashboard-topbar {
    padding: 0.85rem 1rem;
    flex-wrap: nowrap;
    justify-content: space-between;
    gap: 0.5rem;
  }
  .dashboard-left {
    gap: 0.6rem;
  }
  .dashboard-title {
    font-size: 0.95rem;
  }
  .dashboard-balance {
    min-width: 140px;
    padding: 0.5rem 0.75rem;
    gap: 0.4rem;
  }
  .dashboard-balance strong {
    font-size: 0.95rem;
  }
  .dashboard-user {
    order: 0;
  }
  .dropdown-toggle {
    width: auto;
    padding: 0.65rem 0.75rem;
  }
  .user-name {
    display: none;
  }
  .betting-panel {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 0.6rem;
  }
  .betting-card {
    min-width: 0;
  }
  .amount-chip-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .history-cell {
    min-height: 1.15rem;
    font-size: 0.42rem;
  }
}
