/* ==========================================================================
   HAXSCIPT - LİDER TABLOSU VE İSTATİSTİK SAYFASI (DARK CYBER-ESPORTS THEME)
   ========================================================================== */

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: "Poppins", sans-serif;
}

:root {
    --bg: #0f0f10;
    --panel: #161618;
    --card-bg: rgba(22, 22, 26, 0.88);
    --card-border: rgba(255, 216, 77, 0.2);
    --accent: #ffd84d;
    --accent-hover: #ffea62;
    --muted: #a0a0a5;
    --danger: #ff4757;
    --success: #2ed573;
    --thead-bg: #1d1d23;
}

html, body {
    min-height: 100%;
}

body {
    background-image: url("../İmages/BG.png");
    background-size: cover;
    background-position: center top;
    background-attachment: fixed;
    background-color: #0e0e10;
    color: #ffffff;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

/* ==================== UNIFIED HEADER & NAVBAR ==================== */
.navbar {
    width: 100%;
    padding: 40px 0;
    position: absolute;
    top: 0;
    left: 0;
    z-index: 100;
    background: transparent !important;
}

.nav-container {
    width: 90%;
    max-width: 1360px;
    margin: auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo img {
    width: 64px;
    height: auto;
    display: block;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 32px;
    margin-left: 55px;
}

.nav-links a {
    color: #ffffff;
    text-decoration: none;
    font-weight: 600;
    font-size: 15px;
    transition: 0.3s;
}

.nav-links a.active {
    font-weight: 700;
    text-shadow: 0 0 8px rgba(255, 255, 255, 0.24), 0 0 14px rgba(255, 255, 255, 0.23);
    color: #ffffff;
    border-bottom: 2px solid var(--accent);
    padding-bottom: 4px;
}

.nav-links a:hover {
    color: var(--accent-hover);
}

/* BUTTONS */
.nav-buttons {
    display: flex;
    align-items: center;
    gap: 10px;
}

.nav-buttons a {
    padding: 8px 18px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 14px;
    text-decoration: none;
    transition: 0.3s;
}

.login-btn {
    border: 2px solid var(--accent);
    color: var(--accent);
    background: transparent;
}

.login-btn:hover {
    color: black;
    background-color: var(--accent-hover);
}

.register-btn {
    border: 2px solid var(--accent);
    background-color: var(--accent);
    color: black;
}

.register-btn:hover {
    border: 2px solid var(--accent);
    color: var(--accent);
    background: transparent;
}

.menu-toggle {
    display: none;
    font-size: 30px;
    cursor: pointer;
    color: white;
}

/* ==================== LEADERBOARD SECTION ==================== */
.leaderboard-wrapper {
    width: 90%;
    max-width: 1360px;
    margin: 145px auto 40px;
    flex: 1;
}

/* HEADER */
.leaderboard-header-section {
    text-align: center;
    margin-bottom: 28px;
}

.leaderboard-title {
    font-size: 32px;
    font-weight: 900;
    text-transform: uppercase;
    color: #ffffff;
    letter-spacing: 0.5px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin-bottom: 6px;
    text-shadow: 0 0 20px rgba(255, 216, 77, 0.2);
}

.title-trophy {
    font-size: 34px;
}

.leaderboard-subtitle {
    font-size: 14px;
    font-weight: 500;
    color: var(--muted);
    max-width: 660px;
    margin: 0 auto;
    line-height: 1.5;
}

/* ==================== TOP 3 PODIUM CARDS ==================== */
.podium-cards-container {
    display: grid;
    grid-template-columns: 1fr 1.15fr 1fr;
    gap: 20px;
    align-items: center;
    margin-bottom: 24px;
}

.podium-card {
    background: var(--card-bg);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border: 1.5px solid var(--card-border);
    border-radius: 18px;
    padding: 26px 20px 22px;
    text-align: center;
    position: relative;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.45);
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.podium-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 35px rgba(0, 0, 0, 0.6);
    border-color: rgba(255, 216, 77, 0.45);
}

/* Center Elevated Gold Card (#1) */
.podium-card-1 {
    border: 2px solid var(--accent);
    box-shadow: 0 0 30px rgba(255, 216, 77, 0.28);
    padding: 32px 20px 26px;
    background: linear-gradient(180deg, rgba(32, 28, 16, 0.95) 0%, rgba(20, 20, 24, 0.95) 100%);
    transform: translateY(-4px);
}

.podium-crown {
    position: absolute;
    top: 10px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 22px;
}

.podium-rank-badge {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 17px;
    font-weight: 900;
    margin: 0 auto 12px;
    letter-spacing: -0.5px;
}

.rank-badge-1 {
    background: radial-gradient(circle, #ffe366 0%, #ffd84d 100%);
    color: #000;
    box-shadow: 0 0 18px rgba(255, 216, 77, 0.45);
}

.rank-badge-2 {
    background: radial-gradient(circle, #cbd5e1 0%, #64748b 100%);
    color: #000;
    box-shadow: 0 0 14px rgba(100, 116, 139, 0.3);
}

.rank-badge-3 {
    background: radial-gradient(circle, #fdba74 0%, #ea580c 100%);
    color: #000;
    box-shadow: 0 0 14px rgba(234, 88, 12, 0.35);
}

.podium-player-name {
    font-size: 19px;
    font-weight: 800;
    color: #ffffff;
    margin-bottom: 4px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.podium-player-name.text-gold {
    color: var(--accent);
}

.podium-player-level {
    font-size: 13px;
    font-weight: 600;
    color: var(--muted);
    margin-bottom: 14px;
}

.podium-player-level.text-gold {
    color: var(--accent);
}

.podium-player-stats {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    font-size: 12.5px;
    font-weight: 700;
    color: #ffffff;
    flex-wrap: wrap;
}

.podium-player-stats span {
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.podium-player-stats strong {
    color: var(--accent);
}

/* ==================== CONTROLS & FILTER BAR ==================== */
.leaderboard-top {
    background: var(--card-bg);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border: 1.5px solid var(--card-border);
    border-radius: 16px;
    padding: 10px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 18px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.4);
    gap: 16px;
    flex-wrap: wrap;
    position: relative;
    z-index: 50;
}

.season-select {
    position: relative;
    display: inline-block;
    z-index: 100;
}

.season-select button {
    font-family: "Poppins", sans-serif;
    font-weight: 700;
    font-size: 12.5px;
    background: #17171a;
    border: 1.5px solid var(--card-border);
    color: #ffffff;
    padding: 8px 16px;
    border-radius: 10px;
    cursor: pointer;
    transition: 0.2s;
    text-transform: uppercase;
}

.season-select button:hover {
    border-color: var(--accent);
    color: var(--accent);
}

.dropdown-content {
    display: none;
    position: absolute;
    top: calc(100% + 6px);
    left: 0;
    background-color: #17171a;
    min-width: 220px;
    box-shadow: 0 14px 40px rgba(0, 0, 0, 0.9);
    z-index: 9999;
    border-radius: 12px;
    border: 1.5px solid var(--card-border);
    overflow: hidden;
}

.dropdown-content a {
    color: #ffffff;
    padding: 11px 16px;
    text-decoration: none;
    display: block;
    font-size: 13.5px;
    font-weight: 600;
    transition: 0.15s;
}

.dropdown-content a:hover {
    background-color: var(--accent);
    color: #000000;
}

.dropdown-content.show {
    display: block;
}

.player-count {
    font-family: "Poppins", sans-serif;
    font-weight: 800;
    color: var(--accent);
    font-size: 15px;
    letter-spacing: 0.3px;
}

.leaderboard-controls {
    display: flex;
    align-items: center;
    gap: 12px;
}

.player-search-box {
    display: flex;
    align-items: center;
    background: #17171a;
    border: 1.5px solid var(--card-border);
    border-radius: 10px;
    padding: 6px 14px;
    gap: 8px;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.player-search-box:focus-within {
    border-color: var(--accent);
    box-shadow: 0 0 10px rgba(255, 216, 77, 0.25);
}

.player-search-box input {
    background: transparent;
    border: none;
    outline: none;
    color: #ffffff;
    font-family: "Poppins", sans-serif;
    font-size: 13px;
    font-weight: 500;
    width: 140px;
    transition: width 0.2s ease;
}

.player-search-box input:focus {
    width: 180px;
}

.player-search-box input::placeholder {
    color: var(--muted);
}

.search-icon {
    font-size: 13px;
    opacity: 0.7;
}

.clear-search-btn {
    background: transparent;
    border: none;
    color: var(--muted);
    cursor: pointer;
    font-size: 13px;
    padding: 0;
    line-height: 1;
}

.clear-search-btn:hover {
    color: var(--danger);
}

.pagination {
    display: flex;
    align-items: center;
    gap: 4px;
}

.pagination button {
    font-family: "Poppins", sans-serif;
    font-weight: 700;
    font-size: 11px;
    background: #17171a;
    border: 1.5px solid var(--card-border);
    color: #ffffff;
    padding: 6px 10px;
    border-radius: 8px;
    cursor: pointer;
    transition: 0.15s;
}

.pagination button:hover {
    background: var(--accent);
    color: #000;
    border-color: var(--accent);
}

.pagination span {
    font-family: "Poppins", sans-serif;
    font-weight: 700;
    font-size: 12.5px;
    color: #ffffff;
    margin: 0 6px;
    white-space: nowrap;
}

/* ==================== TABLE CONTAINER ==================== */
.leaderboard-box {
    background: rgba(14, 14, 18, 0.92);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border: 2px solid var(--card-border);
    border-radius: 18px;
    overflow: hidden;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.6);
    position: relative;
    z-index: 1;
}

table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
}

thead {
    background: var(--thead-bg);
    color: #ffffff;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

thead th {
    font-family: "Poppins", sans-serif;
    font-weight: 700;
    font-size: 11px;
    letter-spacing: 0.6px;
    text-transform: uppercase;
    text-align: center;
    padding: 14px 6px;
    border: none;
    white-space: nowrap;
    user-select: none;
}

thead th.sortable {
    cursor: pointer;
    transition: background-color 0.15s ease, color 0.15s ease;
}

thead th.sortable:hover {
    background-color: #272730;
    color: var(--accent);
}

/* Active Highlighted Header Tab */
thead th.sort-active {
    background-color: var(--accent) !important;
    color: #000000 !important;
    border-radius: 6px 6px 0 0;
    box-shadow: 0 -2px 10px rgba(255, 216, 77, 0.25);
}

.th-content {
    display: inline-flex;
    align-items: center;
    gap: 3px;
}

.sort-icon {
    font-size: 9px;
    margin-left: 2px;
}

/* Tbody Rows */
tbody tr {
    background: rgba(18, 18, 22, 0.65);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    transition: background-color 0.12s ease;
}

tbody tr:last-child {
    border-bottom: none;
}

tbody tr:hover {
    background: rgba(255, 216, 77, 0.07);
}

tbody td {
    padding: 12px 6px;
    text-align: center;
    vertical-align: middle;
    font-size: 13px;
    font-weight: 600;
    color: #d1d5db;
    white-space: nowrap;
}

/* Rank column */
td.Sira {
    font-weight: 800;
    font-size: 13px;
    color: #9ca3af;
}

td.Sira.rank-1 {
    color: var(--accent);
    font-size: 14px;
}

td.Sira.rank-2 {
    color: #cbd5e1;
    font-size: 13.5px;
}

td.Sira.rank-3 {
    color: #fdba74;
    font-size: 13.5px;
}

/* Level column */
td.Level {
    font-weight: 700;
    color: var(--accent);
}

/* Rank Badge column */
td.rank {
    text-align: center;
}

.rank-badge {
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 6px;
    padding: 3px 8px;
    font-size: 11.5px;
    font-weight: 600;
    color: #ffffff;
    display: inline-flex;
    align-items: center;
    gap: 3px;
}

.rank-points {
    color: var(--accent);
    font-weight: 700;
}

/* Name column */
td.Name {
    font-weight: 800;
    color: #ffffff;
    text-align: left;
    padding-left: 14px;
    font-size: 13.5px;
}

.player-profile-link {
    color: #ffffff;
    text-decoration: none;
    transition: all 0.18s ease;
    display: inline-block;
    cursor: pointer;
}

.player-profile-link:hover {
    color: var(--accent);
    text-decoration: underline;
    text-underline-offset: 3px;
    transform: translateX(2px);
}

.podium-link {
    color: inherit;
    text-decoration: none;
    transition: all 0.18s ease;
    display: inline-block;
}

.podium-link:hover {
    color: var(--accent);
    text-decoration: underline;
    text-underline-offset: 4px;
    transform: scale(1.03);
}

/* Stats columns */
td.stat-g {
    color: var(--success);
    font-weight: 700;
}

td.stat-m {
    color: var(--danger);
    font-weight: 700;
}

td.stat-mvp {
    color: var(--accent);
    font-weight: 700;
}

td.stat-gol {
    color: var(--accent);
    font-weight: 800;
    font-size: 13.5px;
}

td.stat-time {
    font-size: 12px;
    color: var(--muted);
    font-weight: 500;
    text-align: left;
    padding-left: 10px;
}

/* Notice Bar at Bottom */
.leaderboard-notice-bar {
    text-align: center;
    margin-top: 16px;
    font-size: 12.5px;
    color: var(--muted);
}

/* ==================== FOOTER ==================== */
.site-footer {
    width: 100%;
    background: transparent;
    padding: 30px 0;
    margin-top: auto;
    display: flex;
    justify-content: space-around;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px;
    font-size: 13px;
    color: var(--muted);
}

.site-footer .footer-left,
.site-footer .footer-right {
    display: flex;
    align-items: center;
    gap: 12px;
}

.footer-logo {
    height: 32px;
}

.social-links {
    display: flex;
    gap: 16px;
}

.social-links a {
    color: var(--muted);
    text-decoration: none;
    font-weight: 600;
    transition: 0.2s;
}

.social-links a:hover {
    color: var(--accent);
}

/* ==================== RESPONSIVE ==================== */
@media (max-width: 992px) {
    .podium-cards-container {
        grid-template-columns: 1fr;
        gap: 14px;
    }
    .podium-card-1 {
        order: -1;
        transform: none;
    }
    .leaderboard-box {
        overflow-x: auto;
    }
    .nav-links {
        display: none;
    }
    .menu-toggle {
        display: block;
    }
}