/* Leaderboard Page Styling */
.leaderboard-header {
  background: linear-gradient(135deg, #1b5e20 0%, #2e7d32 100%);
  border-radius: 1rem;
  padding: 2rem;
  margin-bottom: 2rem;
  text-align: center;
  color: white;
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1);
}

.leaderboard-header h1 {
  font-size: 2.5rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-bottom: 0.5rem;
}

.leaderboard-header p {
  font-size: 1.1rem;
  opacity: 0.9;
}

/* Points System Badge */
.points-system {
  background: white;
  border-radius: 1rem;
  padding: 1.5rem;
  margin-bottom: 2rem;
  box-shadow: 0 4px 6px -2px rgba(0, 0, 0, 0.05);
  border: 1px solid #e5e7eb;
}

.points-system h3 {
  font-size: 1.25rem;
  font-weight: 600;
  color: #1f2937;
  margin-bottom: 1rem;
}

.points-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.75rem;
}

.point-badge {
  background: #f3f4f6;
  padding: 0.5rem 1rem;
  border-radius: 2rem;
  font-size: 0.875rem;
  font-weight: 500;
  color: #374151;
  transition: all 0.2s;
}

.point-badge i {
  margin-right: 0.5rem;
  color: #2e7d32;
}

.point-badge:hover {
  background: #e5e7eb;
  transform: translateY(-2px);
}

/* Leaderboard Table */
.leaderboard-table {
  background: white;
  border-radius: 1.5rem;
  overflow: hidden;
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.05), 0 10px 10px -5px rgba(0, 0, 0, 0.01);
}

.leaderboard-table table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
}

.leaderboard-table th {
  background: #f9fafb;
  padding: 1rem 1.5rem;
  font-weight: 600;
  text-transform: uppercase;
  font-size: 0.75rem;
  letter-spacing: 0.05em;
  color: #6b7280;
  border-bottom: 1px solid #e5e7eb;
}

.leaderboard-table td {
  padding: 1rem 1.5rem;
  border-bottom: 1px solid #f3f4f6;
  vertical-align: middle;
}

.leaderboard-table tr:last-child td {
  border-bottom: none;
}

.leaderboard-table tbody tr {
  transition: background-color 0.2s;
}

.leaderboard-table tbody tr:hover {
  background-color: #fefce8;
}

/* Rank styling */
.rank-cell {
  font-weight: 700;
  font-size: 1.125rem;
}

.rank-1 {
  color: #f59e0b;
  text-shadow: 0 0 2px rgba(245, 158, 11, 0.3);
}

.rank-2 {
  color: #9ca3af;
}

.rank-3 {
  color: #b45309;
}

/* Medal badges */
.medal {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2rem;
  height: 2rem;
  border-radius: 9999px;
  font-weight: 700;
}

.medal-gold {
  background: linear-gradient(135deg, #fbbf24, #f59e0b);
  color: white;
}

.medal-silver {
  background: linear-gradient(135deg, #cbd5e1, #94a3b8);
  color: white;
}

.medal-bronze {
  background: linear-gradient(135deg, #fed7aa, #ea580c);
  color: white;
}

/* User info */
.user-info {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.user-avatar {
  width: 2.5rem;
  height: 2.5rem;
  background: linear-gradient(135deg, #2e7d32, #1b5e20);
  border-radius: 9999px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-weight: 600;
  font-size: 1rem;
}

.user-name {
  font-weight: 600;
  color: #1f2937;
}

.user-username {
  font-size: 0.75rem;
  color: #6b7280;
}

/* Points cell */
.points-cell {
  font-weight: 700;
  color: #2e7d32;
  font-size: 1.125rem;
}

/* Loading & error states */
.loading-state, .error-state {
  text-align: center;
  padding: 3rem;
  color: #6b7280;
}

/* Responsive */
@media (max-width: 640px) {
  .leaderboard-header h1 {
    font-size: 1.75rem;
  }
  .leaderboard-table th,
  .leaderboard-table td {
    padding: 0.75rem 1rem;
  }
  .user-avatar {
    width: 2rem;
    height: 2rem;
    font-size: 0.75rem;
  }
  .user-name {
    font-size: 0.875rem;
  }
}