/* ==========================================================================
   FALCONSOFT GAMES - GLOBAL LEADERBOARD & PLAYER STATS MODAL STYLES
   Adheres to Rule 8 Glassmorphism & Rule 11 Unified Scaling Standards
   ========================================================================== */

dialog.leaderboard-modal {
  border: none;
  background: transparent;
  padding: 0;
  max-width: 92vw;
  width: 460px;
  border-radius: 20px;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.75), 0 0 30px rgba(0, 243, 255, 0.15);
  margin: auto;
  overflow: visible;
}

dialog.leaderboard-modal::backdrop {
  background: rgba(3, 7, 18, 0.82);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.lb-content {
  background: linear-gradient(165deg, rgba(14, 21, 44, 0.95), rgba(7, 11, 25, 0.98));
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 20px;
  padding: 1.25rem 1.1rem;
  color: #f0f4fc;
  font-family: 'Prompt', -apple-system, BlinkMacSystemFont, sans-serif;
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

.lb-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  padding-bottom: 0.6rem;
}

.lb-header h2 {
  font-family: 'Outfit', sans-serif;
  font-size: 1.15rem;
  font-weight: 800;
  color: #fff;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  margin: 0;
}

.lb-close-btn {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #8ca0be;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  font-size: 1.1rem;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
}

.lb-close-btn:hover {
  background: rgba(255, 255, 255, 0.2);
  color: #fff;
}

/* Player Info Banner inside Modal */
.lb-player-strip {
  background: rgba(0, 243, 255, 0.06);
  border: 1px solid rgba(0, 243, 255, 0.2);
  border-radius: 12px;
  padding: 0.55rem 0.8rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.78rem;
}

.lb-player-name-wrap {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  font-weight: 600;
}

.lb-player-name-wrap span.name {
  color: #00f3ff;
  font-weight: 700;
}

.lb-btn-rename {
  background: transparent;
  border: none;
  color: #8ca0be;
  cursor: pointer;
  font-size: 0.8rem;
  padding: 2px 4px;
  border-radius: 4px;
}

.lb-btn-rename:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.1);
}

.lb-my-best {
  font-size: 0.75rem;
  color: #ffd700;
  font-weight: 700;
}

/* Leaderboard Table List */
.lb-table-wrap {
  max-height: 280px;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.2) transparent;
}

.lb-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.8rem;
}

.lb-table th {
  text-align: left;
  padding: 0.4rem 0.5rem;
  color: #8ca0be;
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.lb-table td {
  padding: 0.55rem 0.5rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}

.lb-table tr:hover {
  background: rgba(255, 255, 255, 0.04);
}

/* Top 3 Medals */
.rank-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  border-radius: 6px;
  font-weight: 800;
  font-size: 0.72rem;
}

.rank-1 {
  background: linear-gradient(135deg, #ffd700, #ffaa00);
  color: #050814;
  box-shadow: 0 0 10px rgba(255, 215, 0, 0.5);
}

.rank-2 {
  background: linear-gradient(135deg, #e2e8f0, #94a3b8);
  color: #050814;
}

.rank-3 {
  background: linear-gradient(135deg, #cd7f32, #a0522d);
  color: #fff;
}

.rank-other {
  color: #8ca0be;
}

.lb-player-cell {
  font-weight: 600;
  color: #f1f5f9;
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.lb-score-cell {
  text-align: right;
  font-family: 'Outfit', sans-serif;
  font-weight: 800;
  color: #00e5a3;
  font-size: 0.9rem;
}

.lb-offline-notice {
  text-align: center;
  padding: 0.8rem;
  color: #8ca0be;
  font-size: 0.76rem;
  background: rgba(255, 255, 255, 0.03);
  border-radius: 10px;
}
