:root {
  --bg-1: #0f172a;
  --bg-2: #1e293b;
  --accent: #ff8a00;
  --accent-2: #ffd166;
  --glass: rgba(255, 255, 255, 0.08);
  --text-main: #f8fafc;
}

body {
  min-height: 100vh;
  font-family: "Outfit", sans-serif;
  color: var(--text-main);
  background: radial-gradient(circle at 15% 15%, #203457 0%, transparent 35%),
              radial-gradient(circle at 85% 5%, #274e6f 0%, transparent 30%),
              linear-gradient(135deg, var(--bg-1), var(--bg-2));
  position: relative;
  overflow-x: hidden;
}

h1,
h2,
h3,
.navbar-brand {
  font-family: "Space Grotesk", sans-serif;
}

.bg-orb {
  position: fixed;
  border-radius: 999px;
  filter: blur(70px);
  opacity: 0.45;
  z-index: -1;
}

.bg-orb-a {
  width: 320px;
  height: 320px;
  background: #ff8a00;
  top: -80px;
  right: -120px;
}

.bg-orb-b {
  width: 340px;
  height: 340px;
  background: #38bdf8;
  bottom: -140px;
  left: -90px;
}

.glass-nav {
  backdrop-filter: blur(12px);
  background: rgba(15, 23, 42, 0.55);
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}

.navbar .nav-link,
.navbar .navbar-brand {
  color: #f8fafc;
}

.navbar-toggler {
  border-color: rgba(248, 250, 252, 0.5);
}

.navbar-toggler:focus {
  box-shadow: 0 0 0 0.2rem rgba(248, 250, 252, 0.18);
}

.navbar .nav-link:hover,
.navbar .navbar-brand:hover {
  color: #fff;
}

.card {
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(15, 23, 42, 0.55);
  color: var(--text-main);
}

.glass-card {
  backdrop-filter: blur(8px);
}

.card-lift {
  transition: transform 180ms ease, box-shadow 180ms ease;
}

.card-lift:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 26px rgba(0, 0, 0, 0.25);
}

.metric-card {
  background: linear-gradient(120deg, rgba(255, 138, 0, 0.22), rgba(255, 209, 102, 0.12));
}

.metric-label {
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  opacity: 0.9;
}

.metric-value {
  font-size: 1.9rem;
  font-weight: 700;
}

.table {
  --bs-table-bg: transparent;
  --bs-table-striped-bg: rgba(255, 255, 255, 0.03);
  --bs-table-hover-bg: rgba(255, 255, 255, 0.05);
  --bs-table-color: #f8fafc;
}

.leaderboard-card {
  background: rgba(248, 250, 252, 0.95);
  border-color: rgba(15, 23, 42, 0.15);
  color: #0f172a;
}

.leaderboard-table {
  --bs-table-color: #0f172a;
  --bs-table-striped-color: #0f172a;
  --bs-table-hover-color: #0f172a;
  --bs-table-striped-bg: rgba(148, 163, 184, 0.18);
  --bs-table-hover-bg: rgba(71, 85, 105, 0.16);
}

.leaderboard-table thead th {
  background: #0f172a;
  color: #f8fafc;
}

.leaderboard-table td,
.leaderboard-table th {
  white-space: nowrap;
}

.leaderboard-viz-card {
  background: rgba(248, 250, 252, 0.96);
  border-color: rgba(15, 23, 42, 0.15);
  color: #0f172a;
}

.leaderboard-card .text-muted,
.leaderboard-viz-card .text-muted {
  color: rgba(51, 65, 85, 0.9) !important;
}

.chart-wrap {
  position: relative;
  width: 100%;
  height: 320px;
}

.chart-wrap-donut {
  height: 320px;
}

.form-control,
.btn,
.alert {
  border-radius: 12px;
}

.form-control {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.form-control:focus {
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  border-color: rgba(255, 209, 102, 0.8);
  box-shadow: 0 0 0 0.25rem rgba(255, 209, 102, 0.15);
}

.btn-primary {
  background: linear-gradient(120deg, var(--accent), #ff6f00);
  border: none;
}

.btn-primary:hover {
  background: linear-gradient(120deg, #ff9800, #ff7b00);
}

.btn-outline-light {
  color: #f8fafc;
  border-color: rgba(248, 250, 252, 0.45);
}

.btn-outline-light:hover {
  background: rgba(248, 250, 252, 0.15);
  color: #fff;
  border-color: rgba(248, 250, 252, 0.65);
}

.selection-side {
  min-width: 132px;
}

.save-selection-bar {
  position: sticky;
  bottom: 0.75rem;
  z-index: 50;
  padding: 0.75rem;
  border: 1px solid rgba(248, 250, 252, 0.15);
  border-radius: 14px;
  background: rgba(15, 23, 42, 0.9);
  backdrop-filter: blur(12px);
}

.drink-row {
  cursor: pointer;
}

.drink-row:hover {
  background: rgba(255, 255, 255, 0.08);
}

.modal-content {
  background: #0f172a;
  border: 1px solid rgba(248, 250, 252, 0.2);
}

.modal-header,
.modal-footer {
  border-color: rgba(248, 250, 252, 0.15);
}

.text-muted {
  color: rgba(226, 232, 240, 0.75) !important;
}

@media (max-width: 768px) {
  .metric-value {
    font-size: 1.5rem;
  }

  .card .btn {
    min-height: 44px;
    font-weight: 600;
  }

  .selection-side {
    min-width: 116px;
  }

  .save-selection-bar {
    bottom: 0.5rem;
  }

  .table {
    font-size: 0.92rem;
  }

  .chart-wrap,
  .chart-wrap-donut {
    height: 260px;
  }
}

@media (max-width: 991.98px) {
  .glass-nav .navbar-collapse {
    margin-top: 0.65rem;
    padding: 0.7rem;
    border-radius: 12px;
    border: 1px solid rgba(248, 250, 252, 0.2);
    background: rgba(15, 23, 42, 0.94);
  }

  .glass-nav .nav-link,
  .glass-nav .text-muted {
    color: rgba(248, 250, 252, 0.95) !important;
  }
}
