.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: url("assets/stadium-photo.jpg") center/cover no-repeat;
  filter: blur(6px) brightness(40%);
  transform: scale(1.08);
}

/* three-column title bar: center title, actions right */
.title-container {
  width: 100%;
  display: grid;
  grid-template-columns: 1fr auto 1fr; /* left | title | right */
  align-items: center;
  gap: 1rem;
  padding: 0.5rem 1rem;
}

.title-container-sub-left {
  display: flex;
  justify-content: space-evenly;
  padding-right: 2rem;
}

.title-container-sub-right {
  display: flex;
  justify-content: space-evenly;
}

.title-container a,
.title-container button {
  text-decoration: none;
  opacity: 0.9;
  transition: opacity 0.15s ease, color 0.15s ease;
}
.title-container a:hover,
.title-container button:hover {
  opacity: 1;
  color: var(--accent);
}

.admin-button {
  border: none;
  background-color: transparent;
  font-size: medium;
  cursor: pointer;
}

/* ---------- Leaderboard shell (glass card) ---------- */
.leaderboard {
  opacity: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  animation: fadeUp 0.8s ease-out forwards;
  height: 80vh;

  max-width: min(560px, 92vw);
  width: 100%;

  border-radius: var(--radius-lg);
  border: 1px solid var(--panel-border);
  background: linear-gradient(180deg, var(--panel), rgba(18, 20, 26, 0.7));
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  padding: 2vw 1.5vw 1vw;
  box-shadow: var(--shadow-lg);
  color: var(--main-color-white);
  margin-top: -2rem;
  margin-bottom: 12vw;
  gap: 0.5rem;
}

.leaderboard-title {
  font-weight: 700;
}

.leaderboard-logo-container {
  display: flex;
  justify-content: space-around;
  align-items: center;
  gap: 1.25rem;
  padding: 0.75rem 0 1.25rem;
}
.leaderboard-logo-container img {
  width: 30%;
  height: auto;
  border-radius: 12%;
  filter: drop-shadow(0 1px 12px rgba(0, 0, 0, 0.35));
}

/* title */
.leaderboard-dashboard-title {
  margin: 0 0 0.5rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-weight: 700;
}

.leaderboard-dashboard {
  display: flex;
  flex-direction: column;
  align-items: center;
  height: 58%;
  min-height: 58%;
  gap: 0.5rem;
  width: 100%;
  background: var(--panel-solid);
  border: 1px solid var(--panel-border);
  border-radius: var(--radius-md);
  padding: 14px;
}

.leaderboard-dashboard-good-luck {
  font-size: 0.9rem;
  color: var(--muted);
}

.leaderboard-dashboard-container {
  display: grid;
  grid-template-columns: 1fr 1fr; /* ID | Raffles */
  width: 100%;
  overflow-y: auto;
  position: relative;
  border-radius: var(--radius-md);
  gap: 8px;
  padding: 0px 6px 6px 6px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--panel-border);
}

.leaderboard-dashboard-search {
  width: 65%;
  border-top: none;
  border-left: none;
  border-right: none;
  background-color: transparent;
  color: var(--main-color-white);
  font-size: medium;
  padding: 0.25rem;
}

.leaderboard-dashboard-search:focus {
  outline: none;
}

.leaderboard-dashboard-search:focus::placeholder {
  opacity: 0;
}

/* sticky column headers */
.leaderboard-dashboard-container .head {
  position: sticky;
  top: 0;
  z-index: 2;
  text-align: center;
  padding: 10px 8px;
  background: #0a0d11; /* pure black header */
  color: var(--text);
  border-radius: 8px;
  font-weight: 650;
  letter-spacing: 0.04em;
  border: 1px solid var(--panel-border);
}

/* rows wrapper spans both columns */
.leaderboard-dashboard-container .rows {
  grid-column: 1 / -1;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

/* each row is a 2-col grid that mirrors the header columns */
.leaderboard-dashboard-container .row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  height: var(--row-h);
  column-gap: 8px;
}
/* visible cells */
.leaderboard-dashboard-container .cell {
  display: flex;
  align-items: center;
  padding: 0 10px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--panel-border);
  border-radius: 8px;
  font-size: 13px;
  line-height: 1;
  color: var(--muted);
  overflow-x: auto;
}

/* name cell: single line with ellipsis so rows never grow */
.leaderboard-dashboard-container .cell.name {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  text-align: left;
}

/* raffles cell: right-aligned; tabular numbers for clean columns */
.leaderboard-dashboard-container .cell.raffles {
  justify-content: flex-end;
  font-variant-numeric: tabular-nums;
}

/* rank prefix */
.rank {
  opacity: 0.6;
  margin-right: 0.5rem;
  color: var(--muted);
}

/* leaderboard footer */
.leaderboard-dashboard-footer {
  width: 100%;
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  color: var(--muted);
  font-size: 0.9rem;
  padding: 0.5rem;
  margin-top: auto;
}

/* bottom logo */
.leaderboard-dashboard-footer-img {
  width: 46%;
  max-width: 220px;
  /* padding: 1.25rem 0 0; */
  opacity: 0.9;
}

/* ---------- Subtle, modern scrollbar ---------- */
.leaderboard-dashboard-container {
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.2) transparent;
}
.leaderboard-dashboard-container::-webkit-scrollbar {
  width: 8px;
}
.leaderboard-dashboard-container::-webkit-scrollbar-track {
  background: transparent;
}
.leaderboard-dashboard-container::-webkit-scrollbar-thumb {
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.22),
    rgba(255, 255, 255, 0.12)
  );
  border-radius: 8px;
}

.drop-overlay {
  position: fixed;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.5);
  z-index: 9999;
}
.drop-overlay.show {
  display: flex;
}

.dropzone {
  max-width: min(90vw, 640px);
  height: 75%;
  width: 100%;
  border: 2px dashed var(--main-color-white);
  border-radius: 16px;
  padding: 2rem;
  text-align: center;
  color: var(--main-color-white);
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(4px);
}
.dropzone h2 {
  margin: 0 0 0.5rem;
  font-size: 1.25rem;
}
.muted {
  opacity: 0.85;
  font-size: 0.9rem;
}

.pass-popup {
  position: fixed;
  align-items: center;
  justify-content: center;
  display: none;
  inset: 0;
  z-index: 99999;
  background-color: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(4px);
  padding: 2rem;
}

.pass-popup.show {
  display: flex;
  flex-direction: column;
}

.footer {
  /* might move this to base */
  display: flex;
  flex-direction: column;
  align-items: start;
  gap: 2rem;
  background-color: var(--footer-panel);
  padding: 6rem;
  height: auto;
  width: 92%;
  border-radius: 1rem;
  backdrop-filter: blur(6px);
}

.footer img {
  width: 12vw;
}

.footer-disclaimer {
  font-size: x-small;
  color: var(--muted);
  width: 70%;
  text-align: start;
}

.footer-social-logos {
  display: flex;
  gap: 1vw;
}

.footer-social-logos img {
  width: 2vw;
  transition: color 0.3s ease, transform 0.25s ease; /* smooth color + movement */
  cursor: pointer;
}

.footer-social-logos img:hover {
  color: var(--accent);
  transform: translateY(-3px) scale(1.05);
}

/* small screens */
@media (max-width: 640px) {
  .title-container,
  .admin-button {
    font-size: 3vw;
  }
  .leaderboard {
    max-width: 94vw;
  }
  .leaderboard-logo-container img {
    width: 40%;
  }
  .footer {
    padding: 8vw;
    align-items: center;
    justify-content: center;
  }
  .footer img {
    width: 45vw;
    align-items: center;
  }
  .footer-social-logos img {
    width: 10vw;
  }
  .title-container {
    width: 100%;
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-template-rows: 1fr 1fr;
    align-items: center;
    padding: 0.5rem 1rem;
    row-gap: 0;
    gap: 0;
  }
  .title-container-sub-center {
    grid-column: 1/ -1;
    grid-row: 1;
    font-size: 4vw;
    height: 30vw;
  }
  .title-container-sub-left,
  .title-container-sub-right {
    grid-row: 2;
    height: 1vw;
  }
}
