/* ==========================================================================
   STYLES DU CLASSEMENT EN DIRECT (MOBILE & VIDÉOPROJECTEUR)
   ========================================================================== */

.leaderboard-container {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.leaderboard-hero-card {
  background: linear-gradient(135deg, #1E293B 0%, #0F172A 100%);
  color: white;
  border-radius: var(--radius-xl);
  padding: 26px 20px;
  text-align: center;
  box-shadow: var(--shadow-lg);
  position: relative;
  overflow: hidden;
}

.leaderboard-hero-card::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, rgba(197, 155, 39, 0.15) 0%, transparent 60%);
  pointer-events: none;
}

.hero-tag {
  display: inline-block;
  background: rgba(197, 155, 39, 0.25);
  color: #FDE047;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 1.5px;
  padding: 4px 12px;
  border-radius: 20px;
  border: 1px solid rgba(197, 155, 39, 0.4);
  margin-bottom: 10px;
}

.leaderboard-title {
  font-family: var(--font-serif);
  font-size: 28px;
  color: #F8FAFC;
  margin-bottom: 6px;
}

.leaderboard-subtitle {
  font-size: 13px;
  color: #94A3B8;
  max-width: 500px;
  margin: 0 auto 16px auto;
}

.leaderboard-meta-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  flex-wrap: wrap;
}

.meta-item {
  font-size: 13px;
  display: flex;
  align-items: center;
  gap: 6px;
  color: #E2E8F0;
}

.live-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #22C55E;
  box-shadow: 0 0 8px #22C55E;
  animation: pulseLive 1.5s infinite;
}

@keyframes pulseLive {
  0% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.7); }
  70% { transform: scale(1.1); box-shadow: 0 0 0 6px rgba(34, 197, 94, 0); }
  100% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(34, 197, 94, 0); }
}

/* Bannière personnelle "Mon Rang" */
.my-rank-banner {
  background: white;
  border: 2px solid var(--color-primary);
  border-radius: var(--radius-lg);
  padding: 16px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  box-shadow: var(--shadow-gold);
}

.my-rank-left {
  display: flex;
  align-items: center;
  gap: 14px;
}

.my-rank-badge {
  background: var(--color-primary);
  color: white;
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 800;
  width: 44px;
  height: 44px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 10px rgba(197, 155, 39, 0.3);
}

.my-info .my-name {
  font-size: 16px;
  color: var(--color-text-main);
}

.my-info .my-table {
  font-size: 12px;
  color: var(--color-text-muted);
}

.my-score-right {
  text-align: right;
}

.my-score-right .my-points {
  font-size: 26px;
  font-weight: 800;
  color: var(--color-primary-dark);
  line-height: 1;
}

.my-score-right .pts-label {
  font-size: 11px;
  color: var(--color-text-muted);
  display: block;
}

/* ==========================================================================
   PODIUM TOP 3 (MOBILE)
   ========================================================================== */
.podium-display-wrapper {
  display: flex;
  align-items: flex-end;
  justify-content: center;
  gap: 10px;
  margin-top: 14px;
  padding: 0 4px;
}

.podium-col {
  flex: 1;
  max-width: 140px;
  display: flex;
  flex-direction: column;
  align-items: center;
  cursor: pointer;
  transition: transform 0.2s ease;
  position: relative;
}

.podium-col:hover {
  transform: translateY(-4px);
}

.podium-crown {
  font-size: 24px;
  margin-bottom: -4px;
  animation: floatCrown 2s ease-in-out infinite;
}

@keyframes floatCrown {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-4px); }
}

.podium-avatar-card {
  background: white;
  border-radius: var(--radius-md);
  padding: 12px 6px;
  text-align: center;
  width: 100%;
  border: 1px solid var(--color-border);
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  margin-bottom: 6px;
}

.avatar-circle {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--color-bg-base);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  border: 2px solid #E2E8F0;
}

.avatar-circle.gold-border {
  border-color: #F59E0B;
  box-shadow: 0 0 12px rgba(245, 158, 11, 0.4);
}

.player-podium-name {
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}

.player-podium-score {
  font-size: 13px;
  font-weight: 800;
  color: var(--color-primary-dark);
}

.podium-pedestal {
  width: 100%;
  border-radius: 12px 12px 0 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 800;
  box-shadow: inset 0 2px 4px rgba(255, 255, 255, 0.3);
}

.pedestal-gold {
  height: 90px;
  background: linear-gradient(180deg, #F59E0B 0%, #B45309 100%);
}

.pedestal-silver {
  height: 68px;
  background: linear-gradient(180deg, #94A3B8 0%, #475569 100%);
}

.pedestal-bronze {
  height: 52px;
  background: linear-gradient(180deg, #D97706 0%, #78350F 100%);
}

/* ==========================================================================
   LISTE COMPLÈTE DU CLASSEMENT
   ========================================================================== */
.ranking-list-card {
  background: white;
  border-radius: var(--radius-xl);
  padding: 20px;
  border: 1px solid var(--color-border);
  box-shadow: var(--shadow-sm);
}

.ranking-list-header {
  display: flex;
  flex-direction: column;
  gap: 2px;
  margin-bottom: 16px;
}

.ranking-list-header h3 {
  font-size: 18px;
  font-weight: 700;
}

.ranking-list-header .hint {
  font-size: 12px;
  color: var(--color-text-muted);
}

.ranking-rows-container {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.ranking-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px;
  border-radius: var(--radius-md);
  background: white;
  border: 1px solid var(--color-border);
  cursor: pointer;
  transition: all 0.15s ease;
}

.ranking-row:hover {
  background: var(--color-bg-base);
  border-color: var(--color-primary);
  transform: translateX(2px);
}

.ranking-row.is-current-user {
  background: #FAF4E6;
  border-color: var(--color-primary);
}

.ranking-row-left {
  display: flex;
  align-items: center;
  gap: 10px;
}

.rank-badge-pill {
  font-family: var(--font-display);
  font-size: 12px;
  font-weight: 800;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.rank-num-regular {
  background: #F1F5F9;
  color: #475569;
}

.rank-badge-1 { background: #FEF3C7; color: #B45309; font-weight: 900; }
.rank-badge-2 { background: #E2E8F0; color: #334155; }
.rank-badge-3 { background: #FFEDD5; color: #9A3412; }

.player-avatar-mini {
  font-size: 20px;
}

.player-meta-box {
  display: flex;
  flex-direction: column;
}

.player-name {
  font-size: 14px;
  font-weight: 700;
  color: var(--color-text-main);
}

.you-tag {
  color: var(--color-primary-dark);
  font-size: 12px;
}

.player-table {
  font-size: 11px;
  color: var(--color-text-muted);
}

.ranking-row-right {
  display: flex;
  align-items: center;
  gap: 4px;
}

.score-number {
  font-size: 16px;
  font-weight: 800;
  color: var(--color-text-main);
}

.score-label {
  font-size: 11px;
  color: var(--color-text-muted);
}

.row-arrow {
  font-size: 18px;
  color: #CBD5E1;
  margin-left: 6px;
}

/* Modale Détails Joueur */
.modal-overlay {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(15, 23, 42, 0.65);
  backdrop-filter: blur(8px);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
}

.modal-content {
  background: white;
  border-radius: var(--radius-xl);
  max-width: 480px;
  width: 100%;
  box-shadow: 0 20px 40px rgba(0,0,0,0.3);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.modal-header {
  padding: 18px 20px;
  border-bottom: 1px solid var(--color-border);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.modal-title-with-avatar {
  display: flex;
  align-items: center;
  gap: 12px;
}

.modal-avatar {
  font-size: 32px;
}

.modal-header h3 {
  font-size: 18px;
  font-weight: 700;
}

.modal-subtitle {
  font-size: 12px;
  color: var(--color-text-muted);
}

.btn-close-modal {
  background: none;
  border: none;
  font-size: 24px;
  cursor: pointer;
  color: #94A3B8;
}

.modal-body {
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  max-height: 70vh;
  overflow-y: auto;
}

.modal-total-score-card {
  background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-dark) 100%);
  color: white;
  border-radius: var(--radius-md);
  padding: 16px;
  text-align: center;
}

.total-pts-value {
  font-size: 32px;
  font-weight: 800;
}

.scores-breakdown-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.breakdown-item {
  background: var(--color-bg-base);
  border-radius: var(--radius-sm);
  padding: 10px 12px;
  display: flex;
  align-items: center;
  gap: 10px;
  border: 1px solid var(--color-border);
}

.item-icon { font-size: 22px; }
.item-meta { display: flex; flex-direction: column; }
.item-title { font-size: 11px; color: var(--color-text-muted); }
.item-score { font-size: 14px; font-weight: 700; color: var(--color-text-main); }

.modal-footer {
  padding: 14px 20px;
  border-top: 1px solid var(--color-border);
  background: var(--color-bg-base);
}

/* ==========================================================================
   MODE ÉCRAN GÉANT / VIDÉOPROJECTEUR (FULLSCREEN TV / PROJECTION)
   ========================================================================== */
.projector-overlay {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: #0B0F19;
  color: white;
  z-index: 999999;
  overflow: auto;
  font-family: var(--font-sans);
}

.projector-screen-layout {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  padding: 24px 32px;
  background-image: 
    radial-gradient(circle at 50% 10%, rgba(197, 155, 39, 0.25) 0%, transparent 60%),
    radial-gradient(circle at 10% 90%, rgba(45, 90, 67, 0.2) 0%, transparent 50%);
}

.projector-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 2px solid rgba(197, 155, 39, 0.3);
  padding-bottom: 16px;
  margin-bottom: 24px;
}

.projector-couple-title {
  font-family: var(--font-serif);
  font-size: 32px;
  font-weight: 700;
  color: #FDE047;
  letter-spacing: 1px;
}

.projector-wedding-date {
  font-size: 14px;
  color: #94A3B8;
  text-transform: uppercase;
  letter-spacing: 2px;
}

.live-tag-pulsing {
  background: rgba(220, 38, 38, 0.25);
  border: 1px solid #EF4444;
  color: #FCA5A5;
  font-weight: 800;
  font-size: 13px;
  letter-spacing: 2px;
  padding: 8px 18px;
  border-radius: 30px;
  animation: pulseLive 2s infinite;
}

.btn-proj-action {
  background: rgba(255, 255, 255, 0.12);
  color: white;
  border: 1px solid rgba(255, 255, 255, 0.25);
  padding: 8px 16px;
  border-radius: var(--radius-sm);
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-proj-action:hover {
  background: var(--color-primary);
  border-color: var(--color-primary);
}

.projector-main-grid {
  display: grid;
  grid-template-columns: 1.6fr 1fr;
  gap: 32px;
  flex: 1;
}

@media (max-width: 900px) {
  .projector-main-grid {
    grid-template-columns: 1fr;
  }
}

.projector-podium-section {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.podium-section-title {
  font-family: var(--font-display);
  font-size: 22px;
  color: #FDE047;
  letter-spacing: 3px;
  margin-bottom: 24px;
}

.projector-podium-stage {
  display: flex;
  align-items: flex-end;
  justify-content: center;
  gap: 16px;
  width: 100%;
}

.proj-col {
  flex: 1;
  max-width: 190px;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.proj-crown-anim {
  font-size: 44px;
  margin-bottom: -10px;
  animation: floatCrown 2s infinite ease-in-out;
}

.proj-avatar-box {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: var(--radius-lg);
  padding: 16px 12px;
  width: 100%;
  text-align: center;
  backdrop-filter: blur(10px);
  margin-bottom: 8px;
}

.winner-box {
  border-color: #F59E0B;
  background: rgba(245, 158, 11, 0.12);
  box-shadow: 0 0 30px rgba(245, 158, 11, 0.3);
}

.proj-medal { font-size: 32px; }
.proj-avatar { font-size: 40px; margin: 4px 0; }
.gold-glow { text-shadow: 0 0 16px #F59E0B; }
.proj-name { font-size: 16px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.winner-name { font-size: 19px; color: #FDE047; }
.proj-table { font-size: 12px; color: #94A3B8; }
.proj-score { font-size: 16px; font-weight: 800; color: #CBD5E1; margin-top: 4px; }
.winner-score { font-size: 22px; color: #FBBF24; }

.proj-block {
  width: 100%;
  border-radius: 16px 16px 0 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-size: 38px;
  font-weight: 800;
  color: white;
}

.block-gold { height: 160px; background: linear-gradient(180deg, #F59E0B 0%, #92400E 100%); }
.block-silver { height: 120px; background: linear-gradient(180deg, #94A3B8 0%, #334155 100%); }
.block-bronze { height: 90px; background: linear-gradient(180deg, #D97706 0%, #451A03 100%); }

/* Section Latérale Vidéoprojecteur */
.projector-side-section {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.projector-qr-card {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: var(--radius-lg);
  padding: 20px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}

.qr-card-title {
  font-size: 16px;
  font-weight: 700;
  color: #FDE047;
}

.qr-canvas-holder {
  background: white;
  padding: 10px;
  border-radius: 12px;
  display: inline-flex;
}

.qr-scan-instruction {
  font-size: 12px;
  color: #CBD5E1;
}

.projector-ticker-card {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-lg);
  padding: 16px;
  flex: 1;
}

.ticker-title {
  font-size: 14px;
  font-weight: 700;
  color: #94A3B8;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 12px;
}

.projector-ranking-scroll {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-height: 320px;
  overflow-y: auto;
}

.proj-rank-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 12px;
  background: rgba(255, 255, 255, 0.04);
  border-radius: 8px;
}

.proj-rank-index {
  font-family: var(--font-display);
  font-weight: 800;
  color: #FDE047;
  width: 32px;
}

.proj-row-avatar { font-size: 18px; margin-right: 8px; }
.proj-row-name { font-size: 14px; flex: 1; font-weight: 600; }
.proj-row-pts { font-size: 14px; color: #CBD5E1; }

/* Commutateur d'onglets du classement */
.leaderboard-tab-toggle-bar {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  background: white;
  padding: 6px;
  border-radius: var(--radius-md);
  border: 1px solid var(--color-border);
  box-shadow: var(--shadow-sm);
}

.lb-tab-btn {
  font-family: var(--font-sans);
  font-size: 14px;
  font-weight: 700;
  padding: 10px 16px;
  border-radius: var(--radius-sm);
  border: none;
  background: transparent;
  color: var(--color-text-muted);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: all 0.2s ease;
}

.lb-tab-btn:hover {
  color: var(--color-text-main);
  background: var(--color-bg-base);
}

.lb-tab-btn.active {
  background: var(--color-primary);
  color: white;
  box-shadow: var(--shadow-gold);
}

/* Carte Blind Test séparée dans la modal joueur */
.breakdown-blindtest-card {
  background: #FAF5FF;
  border: 1px solid #E9D5FF;
  border-radius: var(--radius-md);
  padding: 12px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.blindtest-item-left {
  display: flex;
  align-items: center;
  gap: 12px;
}

.blindtest-item-left strong {
  font-size: 14px;
  color: #581C87;
  display: block;
}

.blindtest-item-left .subtext {
  font-size: 11px;
  color: #7E22CE;
}

.item-score-highlight {
  font-size: 16px;
  font-weight: 800;
  color: #7E22CE;
}

