/* =========================================
   CLASSEMENT
   Extension de la charte principale MPX
========================================= */

.leaderboard-page {
    background:
        radial-gradient(
            circle at 84% 12%,
            rgba(42,51,42,.18),
            transparent 28%
        ),
        #080B08;
}


/* =========================================
   HERO
========================================= */

.ranking-hero {
    position: relative;

    min-height: 570px;

    display: flex;
    align-items: flex-end;

    overflow: hidden;

    border-bottom:
        1px solid var(--line-soft);

    background:
        linear-gradient(
            90deg,
            rgba(8,11,8,.97) 0%,
            rgba(8,11,8,.82) 42%,
            rgba(8,11,8,.36) 100%
        ),
        linear-gradient(
            0deg,
            #080B08 0%,
            rgba(8,11,8,.18) 42%,
            rgba(8,11,8,.05) 100%
        ),
        url("/assets/images/heros-hllv.png")
        center 43% / cover no-repeat;
}

.ranking-hero::after {
    content: "RANK";

    position: absolute;

    right: -35px;
    bottom: -80px;

    color:
        rgba(232,228,214,.025);

    font-size:
        clamp(180px, 28vw, 420px);

    font-weight: 900;
    line-height: .8;

    letter-spacing: -.08em;

    pointer-events: none;
}

.ranking-hero-inner {
    position: relative;

    z-index: 2;

    padding-top: 110px;
    padding-bottom: 58px;
}

.ranking-kicker {
    display: flex;
    align-items: center;

    gap: 13px;

    margin-bottom: 22px;

    color: var(--muted);

    font-size: 12px;
    font-weight: 800;

    letter-spacing: 2.3px;
}

.ranking-kicker span {
    width: 34px;
    height: 1px;

    background:
        var(--orange);
}

.ranking-title {
    position: relative;
}

.ranking-title h1 {
    margin: 0;

    color: var(--ivory);

    font-size:
        clamp(76px, 11vw, 156px);

    font-weight: 900;

    line-height: .78;

    letter-spacing: -.065em;
}

.ranking-title-outline {
    position: absolute;

    left: 51%;
    top: -32px;

    z-index: -1;

    color: transparent;

    -webkit-text-stroke:
        1px rgba(232,228,214,.10);

    font-size:
        clamp(150px, 23vw, 330px);

    font-weight: 900;

    line-height: .8;

    letter-spacing: -.08em;
}

.ranking-intro {
    margin-top: 48px;

    padding-top: 20px;

    border-top:
        1px solid var(--line);

    display: flex;

    align-items: flex-start;
    justify-content: space-between;

    gap: 40px;
}

.ranking-intro p {
    max-width: 560px;

    margin: 0;

    color: var(--muted);

    font-size: 14px;

    line-height: 1.7;
}

#lbGeneratedAt {
    color: var(--ash);

    font-size: 11px;

    letter-spacing: 1.8px;
}


/* =========================================
   FILTERS
========================================= */

.ranking-filters {
    border-bottom:
        1px solid var(--line-soft);
}

.ranking-filter-inner {
    min-height: 105px;

    display: flex;

    align-items: center;
    justify-content: space-between;

    gap: 50px;
}

.ranking-filter-group {
    display: flex;

    align-items: center;

    gap: 23px;
}

.ranking-filter-label {
    color: var(--ash);

    font-size: 11px;
    font-weight: 800;

    letter-spacing: 1.8px;
}

.ranking-filter-buttons,
.ranking-sort-buttons {
    display: flex;

    flex-wrap: wrap;

    align-items: center;

    gap: 4px;
}

.ranking-filter,
.lb-sort {
    appearance: none;

    padding: 12px 15px;

    color: var(--muted);

    background: transparent;

    border:
        1px solid transparent;

    cursor: pointer;

    font-family: inherit;

    font-size: 12px;
    font-weight: 800;

    letter-spacing: 1.2px;

    transition:
        color .18s ease,
        border-color .18s ease,
        background .18s ease;
}

.ranking-filter:hover,
.lb-sort:hover {
    color: var(--ivory);
}

.ranking-filter.active,
.lb-sort.active {
    color: var(--ivory);

    border-color:
        rgba(198,100,63,.42);

    background:
        rgba(198,100,63,.08);
}

.ranking-filter.active::before,
.lb-sort.active::before {
    content: "";

    display: inline-block;

    width: 4px;
    height: 4px;

    margin-right: 8px;

    background:
        var(--orange);
}


/* =========================================
   SECTIONS
========================================= */

.ranking-podium-section,
.ranking-table-section {
    padding:
        100px 0;
}

.ranking-table-section {
    padding-top: 45px;
}

.ranking-section-heading {
    margin-bottom: 45px;
}

.ranking-section-heading h2 {
    margin:
        7px 0 0;

    color: var(--ivory);

    font-size:
        clamp(42px, 5vw, 72px);

    line-height: .88;

    letter-spacing: -.045em;
}

.ranking-section-heading .section-number {
    color: var(--orange);
}

.ranking-section-heading .eyebrow {
    color: var(--ash);
}


/* =========================================
   PODIUM
========================================= */

.ranking-podium {
    display: grid;

    grid-template-columns:
        1fr 1.15fr 1fr;

    align-items: end;

    gap: 1px;

    background:
        var(--line-soft);

    border-top:
        1px solid var(--line);

    border-bottom:
        1px solid var(--line);
}

.lb-podium-item {
    position: relative;

    min-height: 225px;

    padding: 30px;

    display: flex;
    flex-direction: column;

    justify-content: flex-end;

    background:
        rgba(8,11,8,.96);

    overflow: hidden;
}

.lb-podium-item.first {
    min-height: 290px;

    background:
        linear-gradient(
            180deg,
            rgba(198,100,63,.07),
            transparent 72%
        ),
        rgba(8,11,8,.98);
}

.lb-podium-item::after {
    content:
        attr(data-rank);

    position: absolute;

    right: 18px;
    top: 5px;

    color:
        rgba(232,228,214,.035);

    font-size: 135px;

    font-weight: 900;

    line-height: 1;
}

.lb-position {
    position: relative;

    z-index: 2;

    margin-bottom: auto;

    color: var(--orange);

    font-size: 12px;
    font-weight: 900;

    letter-spacing: 1.8px;
}

.lb-podium-name {
    position: relative;

    z-index: 2;

    color: var(--ivory);

    overflow: hidden;

    text-overflow: ellipsis;

    white-space: nowrap;

    font-size:
        clamp(24px, 3vw, 44px);

    font-weight: 900;

    letter-spacing: -.04em;
}

.lb-podium-value {
    position: relative;

    z-index: 2;

    margin-top: 10px;

    color: var(--muted);

    font-size: 12px;
    font-weight: 700;

    letter-spacing: 1.4px;
}


/* =========================================
   SORT
========================================= */

.ranking-sortbar {
    min-height: 68px;

    display: flex;

    align-items: center;
    justify-content: space-between;

    gap: 30px;

    border-top:
        1px solid var(--line-soft);
}


/* =========================================
   TABLE
========================================= */

.ranking-table-wrap {
    overflow-x: auto;

    border-top:
        1px solid var(--line);

    border-bottom:
        1px solid var(--line);
}

.ranking-table {
    width: 100%;

    min-width: 1120px;

    border-collapse: collapse;
}

.ranking-table th {
    padding:
        16px 13px;

    color: var(--ash);

    border-bottom:
        1px solid var(--line);

    text-align: right;

    font-size: 11px;

    font-weight: 800;

    letter-spacing: 1.4px;
}

.ranking-table th:first-child,
.ranking-table th:nth-child(2) {
    text-align: left;
}

.ranking-table td {
    padding:
        18px 13px;

    color: var(--muted);

    border-bottom:
        1px solid var(--line-soft);

    text-align: right;

    font-size: 12px;
}

.ranking-table tbody tr {
    transition:
        background .16s ease;
}

.ranking-table tbody tr:hover {
    background:
        rgba(42,51,42,.17);
}

.ranking-table tbody tr:last-child td {
    border-bottom: 0;
}

.ranking-table td:first-child {
    width: 55px;

    color: var(--ash);

    text-align: left;

    font-size: 12px;
    font-weight: 800;
}

.ranking-table td:nth-child(2) {
    min-width: 250px;

    text-align: left;
}

.lb-player {
    display: flex;

    align-items: center;

    gap: 13px;
}

.lb-player-rankmark {
    width: 2px;
    height: 30px;

    background:
        var(--tactical);
}

.ranking-table
tbody
tr:nth-child(-n+3)
.lb-player-rankmark {
    background:
        var(--orange);
}

.lb-player-name {
    color: var(--ivory);

    font-size: 13px;

    font-weight: 800;
}

.lb-player-platform {
    margin-top: 4px;

    color: var(--ash);

    font-size: 11px;

    letter-spacing: 1.1px;
}

.lb-kd {
    color:
        var(--ivory) !important;

    font-weight: 900;
}

.lb-loading {
    padding:
        70px 20px !important;

    color:
        var(--ash) !important;

    text-align:
        center !important;

    font-size: 12px !important;

    letter-spacing:
        1.8px !important;
}


/* =========================================
   EMPTY
========================================= */

.lb-empty {
    padding:
        75px 20px;

    text-align: center;
}

.lb-empty strong {
    color: var(--ivory);

    font-size: 48px;

    letter-spacing: -.03em;
}

.lb-empty p {
    color: var(--muted);
}


/* =========================================
   NOTE
========================================= */

.ranking-note {
    margin-top: 30px;

    display: flex;

    align-items: flex-start;

    gap: 12px;
}

.ranking-note > span {
    width: 28px;
    height: 1px;

    margin-top: 8px;

    flex: 0 0 auto;

    background:
        var(--orange);
}

.ranking-note p {
    max-width: 520px;

    margin: 0;

    color: var(--ash);

    font-size: 12px;

    line-height: 1.65;

    letter-spacing: .6px;
}


/* =========================================
   RESPONSIVE
========================================= */

@media (max-width: 900px) {

    .ranking-hero {
        min-height: 520px;
    }

    .ranking-hero-inner {
        padding-top: 80px;
    }

    .ranking-title-outline {
        display: none;
    }

    .ranking-intro {
        flex-direction: column;
    }

    .ranking-filter-inner {
        padding:
            25px 0;

        align-items: flex-start;

        flex-direction: column;
    }

    .ranking-filter-group {
        width: 100%;

        align-items: flex-start;

        flex-direction: column;

        gap: 12px;
    }

    .ranking-podium {
        grid-template-columns: 1fr;
    }

    .lb-podium-item,
    .lb-podium-item.first {
        min-height: 180px;
    }

    .ranking-sortbar {
        padding:
            20px 0;

        align-items: flex-start;

        flex-direction: column;
    }

}


/* =========================================
   PLAYER LIVE STATUS
========================================= */

.lb-player-name-row {
    display: flex;
    align-items: center;
    gap: 9px;
}

.lb-status-dot {
    display: inline-block;

    width: 7px;
    height: 7px;

    flex: 0 0 7px;

    border-radius: 50%;
}

.lb-status-dot.online {
    background: var(--green);

    box-shadow:
        0 0 0 0 rgba(133,158,103,.45);

    animation:
        mpx-online-pulse 1.8s ease-out infinite;
}

.lb-status-dot.offline {
    background: #A34A43;

    opacity: .72;

    box-shadow:
        0 0 5px rgba(163,74,67,.18);
}

.lb-podium-name {
    display: flex;
    align-items: center;
    gap: 11px;
}


@keyframes mpx-online-pulse {

    0% {
        box-shadow:
            0 0 0 0 rgba(133,158,103,.48);
    }

    65% {
        box-shadow:
            0 0 0 7px rgba(133,158,103,0);
    }

    100% {
        box-shadow:
            0 0 0 0 rgba(133,158,103,0);
    }

}


/* =========================================
   SMOOTH LEADERBOARD LOADING
========================================= */

.ranking-table-wrap,
.ranking-podium {
    transition:
        opacity .24s ease,
        transform .24s ease,
        filter .24s ease;
}

.ranking-table-wrap.is-loading,
.ranking-podium.is-loading {
    opacity: .42;

    transform:
        translateY(3px);

    filter:
        saturate(.65);

    pointer-events: none;
}

.lb-skeleton-row {
    pointer-events: none;
}

.lb-skeleton-name,
.lb-skeleton-small,
.lb-skeleton-line {
    position: relative;

    overflow: hidden;

    background:
        rgba(232,228,214,.055);
}

.lb-skeleton-name {
    width: 145px;
    height: 13px;

    margin-bottom: 8px;
}

.lb-skeleton-small {
    width: 65px;
    height: 6px;
}

.lb-skeleton-line {
    width: 100%;
    height: 9px;
}

.lb-skeleton-name::after,
.lb-skeleton-small::after,
.lb-skeleton-line::after {
    content: "";

    position: absolute;

    inset: 0;

    transform:
        translateX(-100%);

    background:
        linear-gradient(
            90deg,
            transparent,
            rgba(232,228,214,.09),
            transparent
        );

    animation:
        mpx-skeleton 1.35s ease-in-out infinite;
}


@keyframes mpx-skeleton {

    100% {
        transform:
            translateX(100%);
    }

}


@media (prefers-reduced-motion: reduce) {

    .lb-status-dot.online,
    .lb-skeleton-name::after,
    .lb-skeleton-small::after,
    .lb-skeleton-line::after {
        animation: none;
    }

    .ranking-table-wrap,
    .ranking-podium {
        transition: none;
    }

}

.lb-player-link {
    text-decoration: none;

    transition:
        color .18s ease;
}

.lb-player-link:hover {
    color: var(--orange);
}

/* =========================================
   CLASSEMENT // SERVEUR UNIQUE
========================================= */

.ranking-filters {
    justify-content: flex-end;
}

