/*--------------------
Leaderboard (supahfunk style)
--------------------*/

body {
  min-height: 450px;
  height: 100vh;
  margin: 0;  
  color: #fff;
  font-family: 'Poppins', sans-serif;  
}
.leaderboard {
  /* On remet le leaderboard dans le flux normal */
  position: relative;
  margin: 60px auto;     /* centre horizontalement */
  width: 285px;
  /* hauteur auto pour laisser le contenu grandir */
  background: linear-gradient(to bottom, #3a404d, #181c26);
  border-radius: 10px;
  box-shadow: 0 7px 30px rgba(62, 9, 11, .3);
  padding-bottom: 10px;
  margin-top: 500px;
}

/* Titre et icône */
.leaderboard h1 {
    font-size: 18px;
    color: #e1e1e1;
    padding: 12px 13px 18px;
    margin: 0;
    display: flex
;
    justify-content: center;
    align-items: center;
}
/* à remplacer dans leaderboard.css */
.leaderboard h1 .ico-cup {
  width: 50px;
  height: 50px;
  vertical-align: middle;
  margin-right: 6px;
}


/* Liste sans puces, remise à zéro du compteur */
.leaderboard ol {
  list-style: none;
  counter-reset: leaderboard;
  margin: 0;
  padding: 0;
}

/* Chaque item */
.leaderboard ol li {
  position: relative;
  z-index: 1;
  counter-increment: leaderboard;
  font-size: 14px;
  padding: 18px 10px 18px 50px;
  cursor: pointer;
  backface-visibility: hidden;
  transform: translateZ(0) scale(1,1);
}

/* Numérotation circulaire */
.leaderboard ol li::before {
  content: counter(leaderboard);
  position: absolute;
  z-index: 2;
  top: 15px;
  left: 15px;
  width: 20px;
  height: 20px;
  line-height: 20px;
  background: #fff;
  border-radius: 50%;
  text-align: center;
  color: #c24448;
}

/* Nom du joueur */
.leaderboard ol li mark {
  position: absolute;
  z-index: 2;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  padding: 18px 10px 18px 50px;
  margin: 0;
  background: none;
  color: #fff;
}

/* Flèches décoratives sous le mark */
.leaderboard ol li mark::before,
.leaderboard ol li mark::after {
  content: '';
  position: absolute;
  z-index: 1;
  bottom: -11px;
  left: -9px;
  border-top: 10px solid #c24448;
  border-left: 10px solid transparent;
  transition: all .1s ease-in-out;
  opacity: 0;
}
.leaderboard ol li mark::after {
  left: auto;
  right: -9px;
  border-left: none;
  border-right: 10px solid transparent;
}

/* Score à droite */
.leaderboard ol li small {
  position: relative;
  z-index: 2;
  display: block;
  text-align: right;
  color: #eee;
}

/* Fond coloré et ombre intérieure */
.leaderboard ol li::after {
  content: '';
  position: absolute;
  z-index: 1;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: #fa6855;
  box-shadow: 0 3px 0 rgba(0,0,0,.08);
  transition: all .3s ease-in-out;
  opacity: 0;
}

/* Couleurs spécifiques aux 5 premiers */
.leaderboard ol li:nth-child(1) {
  background: #fa6855;
  border-radius: 10px 10px 0 0;
}
.leaderboard ol li:nth-child(1)::after {
  background: #fa6855;
}
.leaderboard ol li:nth-child(2) {
  background: #e0574f;
}
.leaderboard ol li:nth-child(2)::after {
  background: #e0574f;
  box-shadow: 0 2px 0 rgba(0,0,0,.08);
}
.leaderboard ol li:nth-child(2) mark::before,
.leaderboard ol li:nth-child(2) mark::after {
  border-top: 6px solid #ba4741;
  bottom: -7px;
}
.leaderboard ol li:nth-child(3) {
  background: #d7514d;
}
.leaderboard ol li:nth-child(3)::after {
  background: #d7514d;
  box-shadow: 0 1px 0 rgba(0,0,0,.11);
}
.leaderboard ol li:nth-child(3) mark::before,
.leaderboard ol li:nth-child(3) mark::after {
  border-top: 2px solid #b0433f;
  bottom: -3px;
}
.leaderboard ol li:nth-child(4) {
  background: #cd4b4b;
}
.leaderboard ol li:nth-child(4)::after {
  background: #cd4b4b;
  box-shadow: 0 -1px 0 rgba(0,0,0,.15);
}
.leaderboard ol li:nth-child(4) mark::before,
.leaderboard ol li:nth-child(4) mark::after {
  top: -7px;
  bottom: auto;
  border-top: none;
  border-bottom: 6px solid #a63d3d;
}
.leaderboard ol li:nth-child(5) {
  background: #c24448;
  border-radius: 0 0 10px 10px;
}
.leaderboard ol li:nth-child(5)::after {
  background: #c24448;
  box-shadow: 0 -2.5px 0 rgba(0,0,0,.12);
  border-radius: 0 0 10px 10px;
}
.leaderboard ol li:nth-child(5) mark::before,
.leaderboard ol li:nth-child(5) mark::after {
  top: -9px;
  bottom: auto;
  border-top: none;
  border-bottom: 8px solid #993639;
}

/* Effets au survol */
.leaderboard ol li:hover {
  z-index: 2;
  overflow: visible;
}
.leaderboard ol li:hover::after {
  opacity: 1;
  transform: scaleX(1.06) scaleY(1.03);
}
.leaderboard ol li:hover mark::before,
.leaderboard ol li:hover mark::after {
  opacity: 1;
  transition: all .35s ease-in-out;
}


.back-btn {
  display: block;
  margin: 20px auto 0;
  padding: 12px 24px;
  background: #5ac8fa;
  color: #121212;
  font-family: 'Poppins', sans-serif;
  font-weight: 600;
  text-transform: uppercase;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.3s, transform 0.2s;
  position: relative;
  z-index: 2;
}

.back-btn:hover {
  background: #3eaee2;
  transform: translateY(-2px);
}

.current-user {
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(4px);
  border-radius: 8px;
  transition: background 0.3s;
}

.current-user mark,
.current-user small {
  color: #ffd700; /* Jaune doré */
  font-weight: 600;
}

/* Effet "hover permanent" sur mon pseudo */
.leaderboard ol li.current-user {
  z-index: 2;
  overflow: visible;
}

.leaderboard ol li.current-user::after {
  opacity: 1;
  transform: scaleX(1.06) scaleY(1.03);
}

.leaderboard ol li.current-user mark::before,
.leaderboard ol li.current-user mark::after {
  opacity: 1;
}

.badge-moi {
  background: #ffd700;
  color: #121212;
  font-size: 10px;
  padding: 2px 6px;
  margin-left: 8px;
  border-radius: 10px;
  text-transform: uppercase;
  font-weight: bold;
  display: inline-block;
  vertical-align: middle;
}
