/* Container for the leaderboard */
.sq-leaderboard {
    color: #fff;
    font-family: Arial, sans-serif;
    width: 100% !important;
}

/* Leaderboard Header */
.sq-leaderboard-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.sq-leaderboard-top-3 {
    display: flex;
    justify-content: space-between;
    width: 100%;
    gap: 20px;
    flex-wrap: wrap;
}

.sq-leaderboard-top-player {
    background-color: #2a2a2a;
    padding: 20px;
    border-radius: 10px;
    text-align: center;
    flex-basis: calc((100% / 3) - 20px);
    flex-grow: 1;
    position: relative;
}

.sq-leaderboard-player-info {
    margin-bottom: 40px;
    justify-content: flex-start;
    display: flex;
    align-items: center;
    flex-direction: row;
    gap: 10px;
    flex-wrap: wrap;
    margin-right: 70px !important;
}

.sq-leaderboard-top-3 .sq-player-avatar {
    margin-right: 0 !important;

}
/* Styling for player avatars */
.sq-player-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    margin-right: 10px;
    border: 2px solid #fff;
}

 .sq-player-name {
    font-size: 18px;
    margin: 0;
    width: fit-content;
    color: #ff4242;
}
/* Player name and rank */
.sq-player-wrapper .sq-player-name {
    font-size: 18px;
    margin: 0;
    width: 100%;
    color: #ff4242;
    white-space: nowrap; /* Prevents the text from wrapping to the next line */
    overflow: hidden;     /* Ensures that the text beyond the available width is hidden */
    text-overflow: ellipsis; /* Adds the ellipsis ("...") if the text is too long */
    max-width: 400px;     /* Adjust the max-width to fit within your design */
    display: inline-block; /* Ensures the element behaves correctly in a block layout */
}

.sq-player-rank {
    font-size: 12px;
    margin: 0;
    font-weight: 900;
    font-family: Arial, sans-serif;
    color: #e0e0e0;
}

/* XP stats */
.sq-leaderboard-stats {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    flex-direction: row;
    text-align: left;
    line-height: 1;
    margin: 0;
}

.sq-leaderboard-stats p {
    font-size: 14px;
    font-weight: 600;
    text-transform: uppercase;
    color: #ffffff60;
    margin: 0;
    line-height: 1.2;
}

/* Trophy Icon */
.sq-trophy-icon {
    position: absolute;
    top: 10px;
    right: 20px;
}

.sq-trophy-icon img {
    width: 60px;
    height: 60px;
}

/* Filters */
.sq-leaderboard-filters {
    display: flex;
    gap: 10px;
    width: 100%;
    max-width: 600px;
    margin-bottom: 20px;
}

.sq-filter-button {
    color: #ffffffc2;
    padding: 5px 10px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 16px;
    font-weight: 500;
    background: rgba(36, 36, 36, 0.5);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(14.8px);
    -webkit-backdrop-filter: blur(14.8px);
    border: 1px solid #242424;
    flex-shrink: 1;
    flex-grow: 1;
}

.sq-filter-button.active {
    background: #ff4242;
}

.sq-filter-button:hover {
    background-color: #555;
}

/* Leaderboard Grid */
.sq-header-row {
    display: flex;
    justify-content: space-between;
    background-color: rgba(255, 255, 255, 0.05);
    padding: 10px;
    border-bottom: 1px solid #444;
    color: #ffffff73;
    text-transform: uppercase;
    font-weight: 700;
    font-size: 14px;
    margin: 0 !important;
    width: 100% !important;
    gap: 0 !important;
}

.sq-header-item {
    display: flex;
    align-items: center;
    flex-shrink: 0;
}

.sq-header-item.sq-place-header {
    flex-basis: 80px; /* Fixed width for place */
    justify-content: center;
}

.sq-header-item.sq-player-header {
    flex-grow: 1;
    flex-basis: 0; /* Takes up remaining space */
}

.sq-header-item.sq-rank-header,
.sq-header-item.sq-xp-header {
    flex-basis: 100px; /* Fixed width for rank and XP */
    justify-content: flex-start;
}

/* Player Row Wrapper */
.sq-player-wrapper {
    display: flex;
    justify-content: space-between;
    padding: 10px;
    border-bottom: 1px solid #444;
    align-items: center;
    background-color: #1a1b1c;
}

/* Player Row Items */
.sq-grid-item {
    display: flex;
    align-items: flex-start;;
    flex-shrink: 0;
}

.sq-grid-item.sq-place {
    flex-basis: 80px; /* Aligns with header */
    justify-content: flex-start;
}

.sq-grid-item.sq-player {
    flex-grow: 1;
    flex-basis: 0; /* Aligns with header */
    gap: 10px;
}

.sq-grid-item.sq-rank,
.sq-grid-item.sq-xp {
    flex-basis: 100px; /* Aligns with header */
    justify-content:flex-start;
}

.sq-place-content {
    display: flex;
    justify-content: center;
    align-items: center;
}

.sq-place-text {
    background: rgb(48, 48, 48);
    border-radius: 50%;
    width: 35px;
    height: 35px;
    display: flex;
    justify-content: center;
    align-items: center;
    font-weight: 900;
    font-size: 15px;
    color: #fff;
}

.sq-rank-content,
.sq-xp-content {
    font-size: 14px;
    font-weight: 600;
    color: #ffffffbb;
    text-align: right;
    margin: 0;
}
 .sq-rank-text{
    color: #ffe70dde;
 }
 .sq-player-content{
    display: flex;
    justify-content: flex-start;
    align-items: center;
    flex-direction: row;
    max-width: 200px;
}  
@media (max-width: 650px) {
.sq-player-wrapper .sq-player-name {
max-width: 150px;
}
}
@media (max-width: 550px) {

    .sq-header-row::before {
        content: "Player Info";
        font-weight: 700;
        font-size: 18px;
  padding: 5px 10px;
        width: 100%;
        color: #ffffff73;
        text-align: center;
        text-transform: uppercase;
        /* margin-right: 10px; */
    }
    .sq-place-content {
        display: flex;
        justify-content: center;
        align-items: center;
    }
    .sq-place-header,.sq-player-header,.sq-rank-header,.sq-xp-header{
        display: none;
    }
    .sq-header-row,
    .sq-player-wrapper {
        flex-direction: row;
        align-items: center;
        flex-wrap: wrap;
        gap:4px;
        position: relative;
    }
  .sq-player-content{
    display: flex;
    justify-content: center;
    align-items: center;
}  
.sq-grid-item.sq-place {
    flex-basis: none;
    width: fit-content;
    justify-content: center;
}
     .sq-place {
        position: absolute;
        left: 10%;
        top: 50%;
        transform: translate(-50%, -50%);
    }  
    .sq-grid-item.sq-place,
    .sq-header-item.sq-place-header {
        /* flex-basis: 100%; */
        justify-content: flex-start;
    }

    .sq-grid-item.sq-player,
    .sq-header-item.sq-player-header {
        /* flex-basis: 100%; */
    }

    .sq-grid-item.sq-rank,
    .sq-grid-item.sq-xp,
    .sq-header-item.sq-rank-header,
    .sq-header-item.sq-xp-header {
         flex-basis: 45%;  
         flex-grow: 1;
      
    }
    .sq-grid-item.sq-rank{
        justify-content: center;
        /* margin-right: 5px; */
        text-transform: uppercase;
        color: #ffe70dde;
    }
    .sq-grid-item.sq-xp{
        /* justify-content: flex-start;
        margin-left: 5px; */
        position: absolute;
        right: 0px;
        top: 50%;
        font-size: 18px;
        transform: translate(-50%, -50%);
    }
    
    .sq-place-text {
        width: 30px;
        height: 30px;
        font-size: 14px;
    }
    .sq-player{
        flex-basis: 100% !important;
        justify-content: center;
    }
    .sq-player-avatar {
        width: 30px;
        height: 30px;
    }

    .sq-player-wrapper .sq-player-name {
        font-size: 16px;
        width: fit-content;
        max-width: 150px;
    }

    .sq-rank-content {
        font-size: 12px;
    }
    .sq-xp-content {
        font-size: 16px;
    }

    .sq-leaderboard-filters {
        flex-direction: column;
        gap: 10px;
    }

    .sq-filter-button {
        padding: 8px 12px;
        font-size: 14px;
    }
} 
