/* ==================== RANKING PAGE ==================== */
.ranking-page {
    max-width: 1180px;
}

.back-btn {
    color: var(--neon-cyan);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 600;
    padding: 6px 12px;
    border: 1px solid rgba(0, 240, 255, 0.3);
    border-radius: 8px;
    transition: all 0.2s;
    white-space: nowrap;
}

.back-btn:hover {
    background: rgba(0, 240, 255, 0.1);
    box-shadow: 0 0 10px rgba(0, 240, 255, 0.2);
}

.ranking-page header {
    margin-bottom: 22px;
}

.ranking-page .subtitle {
    color: rgba(255, 213, 92, 0.75);
    letter-spacing: 0.18em;
    text-transform: uppercase;
}

/* ==================== TABS ==================== */
.ranking-tabs {
    display: flex;
    gap: 0;
    margin-bottom: 22px;
    border-radius: 18px;
    padding: 6px;
    background: rgba(255, 194, 77, 0.06);
    border: 1px solid rgba(255, 194, 77, 0.12);
    box-shadow: inset 0 0 20px rgba(255, 194, 77, 0.04);
}

.rank-tab-btn {
    flex: 1;
    background: transparent;
    border: none;
    color: rgba(255, 245, 225, 0.66);
    font-family: 'Kanit', sans-serif;
    font-size: 1rem;
    font-weight: 600;
    padding: 14px 24px;
    cursor: pointer;
    transition: all 0.25s ease;
    border-radius: 14px;
}

.rank-tab-btn:hover {
    color: #fff6db;
    background: rgba(255, 206, 102, 0.08);
}

.rank-tab-btn.active {
    color: #3a1f00;
    background: linear-gradient(135deg, #fff0bc, #f8c957 58%, #d7911b 100%);
    box-shadow: 0 10px 28px rgba(255, 196, 64, 0.28);
}

.ranking-round-select {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 24px;
    flex-wrap: wrap;
}

.ranking-round-select[hidden] {
    display: none !important;
}

.ranking-round-select label {
    color: rgba(255, 244, 220, 0.88);
    font-weight: 600;
}

.ranking-round-select-wrap {
    position: relative;
    min-width: 260px;
}

.ranking-round-select-wrap::after {
    content: '▾';
    position: absolute;
    top: 50%;
    right: 16px;
    transform: translateY(-50%);
    color: #ffd983;
    pointer-events: none;
    font-size: 0.95rem;
}

.ranking-round-dropdown {
    width: 100%;
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    border: 1px solid rgba(255, 207, 107, 0.26);
    border-radius: 14px;
    padding: 12px 44px 12px 16px;
    background:
        linear-gradient(135deg, rgba(255, 240, 188, 0.14), rgba(248, 201, 87, 0.08) 58%, rgba(215, 145, 27, 0.08) 100%),
        rgba(22, 16, 24, 0.92);
    background-image:
        linear-gradient(135deg, rgba(255, 240, 188, 0.14), rgba(248, 201, 87, 0.08) 58%, rgba(215, 145, 27, 0.08) 100%);
    background-color: rgba(22, 16, 24, 0.96);
    color: #fff4da;
    font-family: 'Kanit', sans-serif;
    font-size: 0.95rem;
    font-weight: 600;
    line-height: 1.2;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06), 0 10px 24px rgba(0, 0, 0, 0.22);
    outline: none;
    cursor: pointer;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.ranking-round-dropdown:hover,
.ranking-round-dropdown:focus {
    border-color: rgba(255, 215, 128, 0.42);
    box-shadow: 0 0 0 3px rgba(255, 205, 88, 0.12), 0 12px 28px rgba(0, 0, 0, 0.24);
}

.ranking-round-dropdown::-ms-expand {
    display: none;
}

.ranking-round-dropdown option {
    color: #fff4da;
    background: #17111d;
}

/* ==================== LEADERBOARD SHELL ==================== */
.leaderboard-shell {
    display: grid;
    grid-template-columns: minmax(320px, 0.95fr) minmax(320px, 1.05fr);
    grid-template-areas:
        'podium best'
        'table table';
    gap: 20px;
    align-items: stretch;
}

.rank-tab-hidden {
    display: none;
}

.ranking-loading,
.ranking-empty {
    grid-column: 1 / -1;
    text-align: center;
    color: rgba(255, 242, 214, 0.75);
    padding: 48px 20px;
    font-size: 0.95rem;
    background: rgba(33, 20, 6, 0.55);
    border: 1px solid rgba(255, 204, 94, 0.14);
    border-radius: 24px;
}

.leaderboard-card {
    position: relative;
    overflow: hidden;
    border-radius: 24px;
    padding: 22px;
    background:
        radial-gradient(circle at top left, rgba(255, 255, 255, 0.2), transparent 28%),
        linear-gradient(160deg, rgba(255, 234, 180, 0.3) 0%, rgba(248, 195, 77, 0.18) 34%, rgba(115, 61, 0, 0.24) 100%),
        rgba(38, 21, 5, 0.82);
    border: 1px solid rgba(255, 212, 110, 0.18);
    box-shadow: 0 18px 44px rgba(0, 0, 0, 0.32), inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.leaderboard-card::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.1), transparent 35%, transparent 65%, rgba(255, 255, 255, 0.06));
    pointer-events: none;
}

.leaderboard-card::after {
    content: '';
    position: absolute;
    top: -40%;
    right: -10%;
    width: 220px;
    height: 220px;
    background: radial-gradient(circle, rgba(255, 238, 182, 0.26), transparent 60%);
    pointer-events: none;
}

.leaderboard-card-header {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 18px;
}

.leaderboard-card-title {
    margin: 0;
    color: #fff5dc;
    font-family: 'Orbitron', sans-serif;
    font-size: 1.2rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.leaderboard-card-subtitle {
    margin: 3px 0 0;
    color: rgba(255, 244, 220, 0.68);
    font-size: 0.75rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.leaderboard-mini-label {
    color: rgba(255, 246, 229, 0.8);
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.18em;
}

/* ==================== PODIUM ==================== */
.leaderboard-podium {
    grid-area: podium;
    min-height: 100%;
}

.leaderboard-trophy-row {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    margin-bottom: 18px;
}

.trophy-pill {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 7px 10px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.18);
    color: #fff8e7;
    font-family: 'Orbitron', sans-serif;
    font-size: 0.78rem;
    font-weight: 700;
}

.leaderboard-podium-grid {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    align-items: end;
}

.podium-slot {
    padding: 14px 12px 16px;
    border-radius: 20px;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.18), rgba(255, 225, 156, 0.05));
    border: 1px solid rgba(255, 255, 255, 0.18);
    text-align: center;
    min-height: 220px;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    gap: 10px;
}

.podium-slot.is-first {
    min-height: 260px;
    background: linear-gradient(180deg, rgba(255, 251, 223, 0.28), rgba(255, 204, 92, 0.12));
    box-shadow: 0 10px 30px rgba(255, 210, 92, 0.18);
}

.podium-slot-rank {
    font-family: 'Orbitron', sans-serif;
    font-size: 1.65rem;
    font-weight: 900;
    color: #fff8df;
    text-shadow: 0 0 16px rgba(255, 240, 192, 0.28);
}

.podium-avatar {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid rgba(255, 252, 228, 0.42);
    margin: 0 auto;
    box-shadow: 0 10px 18px rgba(0, 0, 0, 0.24);
}

.podium-slot.is-first .podium-avatar {
    width: 92px;
    height: 92px;
}

.podium-name {
    color: #fff7e3;
    font-weight: 700;
    line-height: 1.3;
    word-break: break-word;
}

.podium-meta {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    color: rgba(255, 244, 217, 0.72);
    font-size: 0.78rem;
}

.podium-points {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto;
    min-width: 72px;
    padding: 7px 12px;
    border-radius: 12px;
    background: rgba(136, 74, 5, 0.42);
    color: #fff2c1;
    font-family: 'Orbitron', sans-serif;
    font-size: 0.86rem;
    font-weight: 700;
}

.podium-avatar-btn {
    display: inline-flex;
    padding: 0;
    border: none;
    background: transparent;
    border-radius: 999px;
    cursor: pointer;
}

.podium-avatar-btn:focus-visible {
    outline: 2px solid rgba(0, 240, 255, 0.45);
    outline-offset: 6px;
}

.podium-avatar-btn:hover .podium-avatar,
.podium-avatar-btn:focus-visible .podium-avatar {
    transform: scale(1.03);
    border-color: rgba(0, 240, 255, 0.55);
}

/* ==================== TABLE ==================== */
.leaderboard-table-card {
    grid-area: table;
    min-height: 100%;
}

.leaderboard-table {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.leaderboard-table-head,
.leaderboard-row {
    display: grid;
    grid-template-columns: 76px 58px minmax(0, 1fr) 104px;
    gap: 12px;
    align-items: center;
}

.leaderboard-table-head {
    padding: 0 14px 8px;
    color: rgba(255, 245, 214, 0.76);
    font-size: 0.74rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.leaderboard-table-head-metric {
    text-align: right;
}

.leaderboard-row {
    padding: 12px 14px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.1);
    animation: fadeInUp 0.4s ease-out both;
}

.leaderboard-row.is-top-1 {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.28), rgba(255, 212, 102, 0.18));
}

.leaderboard-row-main {
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
}

.leaderboard-row-main > div {
    min-width: 0;
}

.leaderboard-rank-logo-wrap {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 54px;
    height: 54px;
    flex-shrink: 0;
}

.leaderboard-rank-logo {
    width: 54px;
    height: 54px;
    object-fit: contain;
    filter: drop-shadow(0 0 14px color-mix(in srgb, var(--tier-color, #888) 54%, transparent));
}

.leaderboard-rank-logo.customer-rank-logo-fallback {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
}

.podium-rank-logo-wrap {
    margin: 0 auto -2px;
}

.podium-rank-logo-wrap .leaderboard-rank-logo {
    width: 62px;
    height: 62px;
}

.podium-slot.is-first .podium-rank-logo-wrap .leaderboard-rank-logo {
    width: 74px;
    height: 74px;
}

.leaderboard-row-avatar,
.best-player-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid rgba(255, 252, 228, 0.38);
    box-shadow: 0 8px 18px rgba(0, 0, 0, 0.24);
    flex-shrink: 0;
}

.leaderboard-row-avatar-btn,
.best-player-avatar-btn {
    display: inline-flex;
    padding: 0;
    border: none;
    background: transparent;
    border-radius: 50%;
    cursor: pointer;
}

.leaderboard-row-avatar-btn:hover .leaderboard-row-avatar,
.leaderboard-row-avatar-btn:focus-visible .leaderboard-row-avatar,
.best-player-avatar-btn:hover .best-player-avatar,
.best-player-avatar-btn:focus-visible .best-player-avatar {
    transform: scale(1.04);
    border-color: rgba(0, 240, 255, 0.55);
}

.leaderboard-row-avatar-btn:focus-visible,
.best-player-avatar-btn:focus-visible {
    outline: 2px solid rgba(0, 240, 255, 0.42);
    outline-offset: 5px;
}

.leaderboard-row-rank {
    color: #fff9e8;
    font-family: 'Orbitron', sans-serif;
    font-size: 1rem;
    font-weight: 900;
}

.leaderboard-row-name {
    color: #fff7e5;
    font-weight: 700;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.leaderboard-row-sub {
    display: flex;
    align-items: center;
    gap: 6px;
    min-width: 0;
    color: rgba(255, 242, 213, 0.66);
    font-size: 0.72rem;
    margin-top: 2px;
}

.leaderboard-row-sub > span:last-child {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.leaderboard-row-points {
    text-align: right;
    color: #fff1ba;
    font-family: 'Orbitron', sans-serif;
    font-weight: 900;
    letter-spacing: 0.04em;
}

/* ==================== BEST PLAYER ==================== */
.leaderboard-best-card {
    grid-area: best;
    min-height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    background:
        radial-gradient(circle at top right, rgba(0, 240, 255, 0.16), transparent 28%),
        radial-gradient(circle at top left, rgba(255, 248, 214, 0.22), transparent 30%),
        linear-gradient(160deg, rgba(255, 228, 150, 0.28) 0%, rgba(171, 103, 16, 0.22) 52%, rgba(31, 25, 58, 0.84) 100%),
        rgba(24, 18, 42, 0.88);
}

.best-player-inner {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    gap: 16px;
    height: 100%;
}

.best-player-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
}

.best-player-rank-block {
    display: flex;
    align-items: center;
    gap: 14px;
    flex: 1;
}

.best-player-rank {
    width: 84px;
    height: 84px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(180deg, #fffef4, #ffe9a8);
    color: #8a5200;
    border-radius: 20px;
    font-family: 'Orbitron', sans-serif;
    font-size: 2.6rem;
    font-weight: 900;
    box-shadow: inset 0 -10px 24px rgba(255, 184, 41, 0.22);
}

.best-player-label {
    color: #fff6de;
    font-family: 'Orbitron', sans-serif;
    font-size: 1.35rem;
    line-height: 1.05;
    text-transform: uppercase;
}

.best-player-avatar-wrap {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

.best-player-avatar {
    width: 92px;
    height: 92px;
    border-width: 3px;
}

.best-player-avatar-caption {
    color: rgba(255, 244, 220, 0.72);
    font-size: 0.72rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    text-align: center;
}

.best-player-score-wrap {
    padding: 14px 16px;
    border-radius: 18px;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.14), rgba(255, 255, 255, 0.06));
    border: 1px solid rgba(255, 255, 255, 0.16);
    text-align: center;
}

.best-player-score-label {
    color: rgba(255, 245, 214, 0.72);
    font-size: 0.75rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.best-player-score {
    margin-top: 4px;
    color: #fff6d0;
    font-family: 'Orbitron', sans-serif;
    font-size: 2rem;
    font-weight: 900;
}

.best-player-tier {
    display: flex;
    justify-content: center;
    margin-top: 10px;
}

.best-player-rank-logo-wrap {
    width: 86px;
    height: 86px;
}

.best-player-rank-logo-wrap .leaderboard-rank-logo {
    width: 86px;
    height: 86px;
}

.customer-tier-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0;
    max-width: 100%;
    min-width: 0;
    padding: 8px 14px;
    border-radius: 8px;
    background:
        radial-gradient(circle at 30% 15%, color-mix(in srgb, var(--tier-color, #888) 30%, transparent), transparent 46%),
        color-mix(in srgb, var(--tier-color, #888) 16%, rgba(255, 255, 255, 0.1));
    border: 1px solid color-mix(in srgb, var(--tier-color, #888) 52%, rgba(255, 255, 255, 0.12));
    color: #fff8df;
    font-family: 'Kanit', sans-serif;
    font-size: 0.9rem;
    font-weight: 800;
    line-height: 1.1;
    box-shadow: 0 0 22px color-mix(in srgb, var(--tier-color, #888) 24%, transparent);
}

.customer-tier-badge span:last-child {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
}

.customer-tier-logo {
    width: 40px;
    height: 40px;
    object-fit: contain;
    flex-shrink: 0;
    filter: drop-shadow(0 0 12px color-mix(in srgb, var(--tier-color, #888) 50%, transparent));
}

.customer-tier-logo.customer-rank-logo-fallback {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.35rem;
}

.podium-tier-badge {
    justify-content: center;
    padding: 10px 14px;
    font-size: 0.95rem;
}

.podium-tier-badge .customer-tier-logo {
    width: 58px;
    height: 58px;
}

.best-player-tier-badge {
    padding: 12px 16px;
    font-size: 1rem;
}

.best-player-tier-badge .customer-tier-logo {
    width: 68px;
    height: 68px;
}

.best-player-name {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 54px;
    padding: 12px 14px;
    border-radius: 16px;
    background: linear-gradient(135deg, rgba(145, 82, 6, 0.34), rgba(0, 240, 255, 0.08));
    color: #fff7dd;
    font-size: 1.05rem;
    font-weight: 700;
    text-align: center;
    word-break: break-word;
}

.best-player-meta {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
}

.best-player-chip {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 10px 12px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.1);
    color: rgba(255, 245, 220, 0.88);
    font-size: 0.86rem;
}

.best-player-chip:last-child:nth-child(odd) {
    grid-column: 1 / -1;
}

.best-player-chip strong {
    color: #fff2b2;
    font-family: 'Orbitron', sans-serif;
}

/* ==================== RESPONSIVE ==================== */
@media (max-width: 1080px) {
    .leaderboard-shell {
        grid-template-columns: 1fr;
        grid-template-areas:
            'podium'
            'best'
            'table';
    }

    .best-player-meta {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 640px) {
    .ranking-page header {
        margin-bottom: 16px;
    }

    .ranking-page .logo-area {
        gap: 12px;
        align-items: flex-start;
    }

    .ranking-page .logo-area h1 {
        font-size: 1.18rem;
        line-height: 1.15;
        letter-spacing: 0.03em;
    }

    .ranking-page .subtitle {
        font-size: 0.82rem;
        letter-spacing: 0.14em;
    }

    .ranking-tabs {
        flex-direction: column;
        margin-bottom: 16px;
        padding: 4px;
        border-radius: 16px;
    }

    .ranking-round-select {
        align-items: stretch;
        gap: 10px;
        margin-bottom: 18px;
    }

    .ranking-round-select-wrap {
        min-width: 0;
        width: 100%;
    }

    .rank-tab-btn {
        padding: 11px 14px;
        font-size: 0.92rem;
        text-align: left;
    }

    .leaderboard-card {
        padding: 16px;
        border-radius: 18px;
    }

    .leaderboard-card-header {
        margin-bottom: 14px;
        align-items: flex-start;
        flex-direction: column;
    }

    .leaderboard-card-title {
        font-size: 1rem;
        letter-spacing: 0.06em;
    }

    .leaderboard-card-subtitle,
    .leaderboard-mini-label {
        font-size: 0.66rem;
    }

    .leaderboard-podium-grid {
        grid-template-columns: 1fr;
        gap: 10px;
    }

    .leaderboard-trophy-row {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        margin-bottom: 12px;
    }

    .trophy-pill {
        font-size: 0.68rem;
        padding: 6px 8px;
    }

    .podium-slot,
    .podium-slot.is-first {
        min-height: unset;
        padding: 12px 12px 14px;
        border-radius: 16px;
    }

    .podium-slot-rank {
        font-size: 1.3rem;
    }

    .podium-avatar {
        width: 68px;
        height: 68px;
    }

    .podium-slot.is-first .podium-avatar {
        width: 80px;
        height: 80px;
    }

    .podium-name {
        font-size: 0.95rem;
    }

    .podium-meta {
        gap: 5px;
        font-size: 0.72rem;
    }

    .leaderboard-table-head,
    .leaderboard-row {
        grid-template-columns: 42px 42px minmax(0, 1fr) 72px;
        gap: 8px;
    }

    .leaderboard-table-head {
        padding: 0 4px 4px;
        font-size: 0.6rem;
    }

    .leaderboard-row {
        padding: 10px 9px;
        border-radius: 12px;
    }

    .leaderboard-row-rank,
    .leaderboard-row-points {
        font-size: 0.78rem;
    }

    .leaderboard-row-avatar {
        width: 40px;
        height: 40px;
    }

    .leaderboard-rank-logo-wrap,
    .leaderboard-rank-logo {
        width: 40px;
        height: 40px;
    }

    .podium-rank-logo-wrap .leaderboard-rank-logo {
        width: 50px;
        height: 50px;
    }

    .podium-slot.is-first .podium-rank-logo-wrap .leaderboard-rank-logo {
        width: 58px;
        height: 58px;
    }

    .leaderboard-row-name {
        font-size: 0.84rem;
    }

    .leaderboard-row-sub {
        font-size: 0.66rem;
    }

    .customer-tier-badge {
        gap: 7px;
        padding: 6px 8px;
        font-size: 0.72rem;
    }

    .customer-tier-logo {
        width: 30px;
        height: 30px;
    }

    .podium-tier-badge .customer-tier-logo {
        width: 44px;
        height: 44px;
    }

    .best-player-tier-badge .customer-tier-logo {
        width: 50px;
        height: 50px;
    }

    .best-player-top {
        flex-direction: column;
        align-items: flex-start;
    }

    .best-player-rank-block {
        width: 100%;
    }

    .best-player-avatar-wrap {
        width: 100%;
        align-items: flex-start;
    }

    .best-player-meta {
        grid-template-columns: 1fr;
    }

    .best-player-rank {
        width: 70px;
        height: 70px;
        font-size: 2.1rem;
    }

    .best-player-label {
        font-size: 1.05rem;
    }

    .best-player-avatar {
        width: 78px;
        height: 78px;
    }

    .best-player-rank-logo-wrap,
    .best-player-rank-logo-wrap .leaderboard-rank-logo {
        width: 72px;
        height: 72px;
    }

    .best-player-score-wrap {
        padding: 12px 14px;
        border-radius: 14px;
    }

    .best-player-score {
        font-size: 1.6rem;
    }

    .best-player-name {
        min-height: 48px;
        padding: 10px 12px;
        font-size: 0.94rem;
    }

    .best-player-chip {
        padding: 9px 10px;
        border-radius: 12px;
        font-size: 0.76rem;
    }
}

@media (max-width: 480px) {
    .ranking-page {
        padding: 10px 12px 18px;
    }

    .ranking-page .logo-area {
        gap: 8px;
    }

    .ranking-page .logo-icon {
        display: none;
    }

    .back-btn {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        min-height: 40px;
        padding: 8px 12px;
        font-size: 0.78rem;
    }

    .leaderboard-shell {
        gap: 12px;
    }

    .ranking-loading,
    .ranking-empty {
        padding: 28px 14px;
        border-radius: 18px;
        font-size: 0.84rem;
    }

    .leaderboard-card {
        padding: 14px;
    }

    .leaderboard-card-title {
        font-size: 0.94rem;
    }

    .leaderboard-card-subtitle,
    .leaderboard-mini-label {
        font-size: 0.62rem;
        letter-spacing: 0.08em;
    }

    .leaderboard-trophy-row {
        gap: 6px;
    }

    .trophy-pill {
        gap: 4px;
        font-size: 0.62rem;
    }

    .leaderboard-table-head {
        display: none;
    }

    .leaderboard-row {
        grid-template-columns: 42px minmax(0, 1fr);
        grid-template-areas:
            'rank points'
            'logo main';
        gap: 6px 10px;
        align-items: start;
        padding: 10px 10px 11px;
    }

    .leaderboard-row-rank {
        grid-area: rank;
        align-self: center;
    }

    .leaderboard-row-rank-logo-wrap {
        grid-area: logo;
        align-self: start;
        width: 38px;
        height: 38px;
    }

    .leaderboard-row-rank-logo-wrap .leaderboard-rank-logo {
        width: 38px;
        height: 38px;
    }

    .leaderboard-row-main {
        grid-area: main;
        align-items: flex-start;
        gap: 8px;
    }

    .leaderboard-row-avatar {
        width: 36px;
        height: 36px;
    }

    .leaderboard-row-name {
        white-space: normal;
        line-height: 1.3;
    }

    .leaderboard-row-sub {
        flex-wrap: wrap;
        row-gap: 4px;
    }

    .leaderboard-row-sub > span:last-child {
        white-space: normal;
        overflow: visible;
        text-overflow: clip;
    }

    .leaderboard-row-points {
        grid-area: points;
        justify-self: end;
        text-align: right;
        font-size: 0.84rem;
        line-height: 1.2;
    }

    .best-player-top {
        gap: 12px;
    }

    .best-player-chip {
        flex-direction: column;
        align-items: flex-start;
        gap: 4px;
    }

    .best-player-chip strong {
        word-break: break-word;
    }
}

@media (max-width: 360px) {
    .podium-avatar {
        width: 58px;
        height: 58px;
    }

    .podium-slot.is-first .podium-avatar {
        width: 70px;
        height: 70px;
    }

    .best-player-rank {
        width: 62px;
        height: 62px;
        font-size: 1.85rem;
    }

    .best-player-avatar {
        width: 70px;
        height: 70px;
    }

    .best-player-rank-logo-wrap,
    .best-player-rank-logo-wrap .leaderboard-rank-logo {
        width: 62px;
        height: 62px;
    }
}
