/**
 * Rank System Panel - Modern Dark Midnight Purple Theme
 * Sleek, responsive design with gradients and smooth animations
 */

:root {
    --primary: #7c3aed;
    --primary-dark: #6d28d9;
    --primary-light: #8b5cf6;
    --secondary: #0f0a1a;
    --accent: #ffe189;
    --background: #020008;
    --background-light: #060212;
    --surface: #0a051a;
    --surface-light: #0f0a20;
    --text-primary: #fff0d5;
    --text-secondary: #c4b5fd;
    --text-muted: #8b5cf6;
    --border: #1a0f2e;
    --success: #10b981;
    --danger: #ef4444;
    --warning: #f59e0b;
    --shadow: rgba(2, 0, 8, 0.9);
    --glow: rgba(167, 139, 250, 0.3);
    --border-top: linear-gradient(to right,rgb(175, 126, 3)  0%,rgb(255, 237, 172) 50%, rgb(175, 126, 3) 100%);
    --header: rgba(33, 29, 52, 0.9);
    --gradient-1: linear-gradient(to right, rgb(119, 114, 128) 0%, rgb(48, 33, 102) 175%);
    --gradient-2: linear-gradient(45deg, rgba(29, 13, 55, 0.7) 0%, rgba(57, 53, 65, 0.9) 50%, rgba(37, 25, 65, 0.7) 100%);
    --modal: linear-gradient(45deg, rgba(25, 14, 60, 0.7) 0%, rgba(54, 50, 44, 0.75) 50%, rgba(25, 14, 60, 0.7) 100%);
    --gradient-blur: radial-gradient(circle at 30% 70%, rgba(35, 16, 68, 0.4) 0%, transparent 50%), 
                     radial-gradient(circle at 70% 30%, rgba(42, 28, 74, 0.3) 0%, transparent 50%),
                     radial-gradient(circle at 50% 50%, rgba(42, 35, 61, 0.2) 0%, transparent 70%);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    /* Simplified background for better iOS Safari compatibility */
    background: 
        var(--gradient-blur),
        linear-gradient(135deg, #020008 0%, #060212 25%, #1a1205 50%, #060212 75%, #020008 100%);
    background-color: #020008;
    background-attachment: fixed;
    color: var(--text-primary);
    min-height: 100vh;
    overflow-x: hidden;
    position: relative;
    /* Removed animation - keeping only transitions */
}

/* Removed fadeIn animation - animations disabled, keeping only transitions */


/* Header */
.header {
    background: 
        var(--header);
    border-bottom: 1px solid rgba(175, 160, 114, 0.8);
    box-shadow: 
        0 4px 20px rgba(0, 0, 0, 0.4),
        0 0 60px rgba(124, 58, 237, 0.15),
        inset 0 -1px 0 rgba(167, 139, 250, 0.1);
    position: sticky;
    top: 0;
    z-index: 100;
    overflow: visible;
}

.header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(ellipse at 30% 0%, rgba(124, 58, 237, 0.15) 0%, transparent 60%),
        radial-gradient(ellipse at 70% 0%, rgba(175, 160, 114, 0.1) 0%, transparent 60%);
    /* Removed blur filter - heavy GPU cost */
    z-index: -1;
    opacity: 0.5;
}

/* Removed headerGlow animation - reduces constant repainting */

.header-content {
    max-width: 1600px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 2rem;
}

.header-title {
    font-size: 1.5rem;
    font-weight: 800;
    letter-spacing: 1.5px;
    display: flex;
    align-items: center;
    gap: 1rem;
    justify-content: center;
    background: linear-gradient(135deg, 
        #ffffff 0%, 
        #d5c38b 30%, 
        #ffe19f 50%, 
        #cfbd87 70%, 
        #ffffff 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: 
        0 0 10px rgba(175, 160, 114, 0.25),
        0 0 20px rgba(250, 215, 139, 0.15);
    position: relative;
    text-transform: uppercase;
    cursor: pointer;
    user-select: none;
}

.header-title:hover {
    filter: brightness(1.15);
}

/* Server Dropdown */
.server-dropdown {
    position: absolute;
    top: calc(100% + 0.5rem);
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(145deg, rgba(20, 20, 30, 0.98), rgba(30, 30, 45, 0.95));
    border: 1px solid rgba(167, 139, 250, 0.3);
    border-radius: 12px;
    padding: 0.5rem 0;
    min-width: 400px;
    box-shadow: 
        0 8px 32px rgba(0, 0, 0, 0.4),
        0 2px 8px rgba(167, 139, 250, 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.05);
    opacity: 0;
    visibility: hidden;
    transform: translateX(-50%) translateY(-10px);
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    z-index: 1000;
    backdrop-filter: blur(10px);
}

.server-dropdown.active {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}

.server-dropdown-item {
    padding: 0.75rem 1.5rem;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 0.95rem;
    font-weight: 600;
    position: relative;
}

.header-title-container {
    position: relative;
}
/* Server Connect Button */
.server-connect-btn {
    position: absolute;
    right: 0;
    margin-right: -4em;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0.75rem;
    background: linear-gradient(135deg, rgba(167, 139, 250, 0.15), rgba(245, 158, 11, 0.1));
    border: 1px solid rgba(167, 139, 250, 0.3);
    border-radius: 8px;
    color: var(--accent);
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    margin-left: 1rem;
}

.server-connect-btn:hover {
    background: linear-gradient(135deg, rgba(167, 139, 250, 0.25), rgba(245, 158, 11, 0.15));
    border-color: rgba(167, 139, 250, 0.5);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(167, 139, 250, 0.3);
}

.server-connect-btn i {
    color: white;
    font-size: 1.3rem;
}

.server-connect-btn:hover i {
    color: var(--accent);
    transform: scale(1.1);
}

.server-dropdown-item::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 3px;
    background: linear-gradient(180deg, var(--primary), var(--accent));
    opacity: 0;
    transition: opacity 0.2s ease;
}

.server-dropdown-item:hover {
    background: linear-gradient(90deg, rgba(167, 139, 250, 0.15), transparent);
    color: var(--text-primary);
}

.server-dropdown-item:hover::before {
    opacity: 1;
}

.server-dropdown-item.active {
    color: var(--accent);
    background: linear-gradient(90deg, rgba(245, 158, 11, 0.1), transparent);
}

.server-dropdown-item.active::before {
    opacity: 1;
    background: var(--accent);
}

.server-dropdown-item i {
    color: var(--primary);
    font-size: 1rem;
    transition: all 0.2s ease;
}

.server-dropdown-item:hover i {
    color: var(--accent);
    transform: scale(1.1);
}

.server-dropdown-item.active i {
    color: var(--accent);
}

/* Removed titleShine animation - reduces constant background-position changes */

.header-title::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: calc(100% + 2rem);
    height: 200%;
    background: radial-gradient(ellipse at center, 
        rgba(175, 160, 114, 0.05) 0%, 
        transparent 70%);
    /* Removed blur filter - heavy GPU cost */
    z-index: -1;
}

/* Removed titleGlow animation - reduces constant scaling */

.header-title i {
    font-size: 2rem;
    background: linear-gradient(135deg, 
        #ffffff 0%, 
        #d5c38b 30%, 
        #ffe19f 50%, 
        #cfbd87 70%, 
        #ffffff 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Removed iconShine and iconPulse animations - reduces constant animation overhead */

.back-btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin: 0.75rem 0;
    padding: 0.75rem 1.5rem;
    background: linear-gradient(135deg, 
        rgba(167, 139, 250, 0.12) 0%, 
        rgba(124, 58, 237, 0.1) 100%);
    border: 1px solid rgba(167, 139, 250, 0.3);
    border-radius: 10px;
    color: var(--text-primary);
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.back-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, 
        transparent, 
        rgba(167, 139, 250, 0.3), 
        transparent);
    transition: left 0.5s ease;
}

.back-btn:hover::before {
    left: 100%;
}

.back-btn:hover {
    background: linear-gradient(135deg, 
        rgba(167, 139, 250, 0.2) 0%, 
        rgba(124, 58, 237, 0.15) 100%);
    border-color: rgba(167, 139, 250, 0.5);
    transform: translateX(-5px);
    box-shadow: 
        0 4px 20px rgba(167, 139, 250, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.back-btn:active {
    transform: translateX(-3px) scale(0.98);
}

.back-btn i {
    transition: transform 0.3s ease;
}

.back-btn:hover i {
    transform: translateX(-3px);
}

.profile-container {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin: 0.75rem 0;
    padding: 0.25rem 1.25rem;
    background: linear-gradient(135deg, 
        rgba(167, 139, 250, 0.15) 0%, 
        rgba(124, 58, 237, 0.12) 100%);
    border-radius: 50px;
    border: 1px solid rgba(167, 139, 250, 0.3);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.profile-container::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 0;
    height: 0;
    background: radial-gradient(circle, 
        rgba(167, 139, 250, 0.2) 0%, 
        transparent 70%);
    border-radius: 50%;
    transition: all 0.5s ease;
    pointer-events: none;
}

.profile-container:hover::before {
    width: 200%;
    height: 200%;
}

.profile-container:hover {
    background: linear-gradient(135deg, 
        rgba(167, 139, 250, 0.25) 0%, 
        rgba(124, 58, 237, 0.2) 100%);
    border-color: rgba(167, 139, 250, 0.5);
    transform: translateY(-2px);
    box-shadow: 
        0 4px 20px rgba(167, 139, 250, 0.15),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.profile-icon {
    font-size: 1.75rem;
    background: linear-gradient(135deg, 
        #fde3b5 0%, 
        #fada8b 50%, 
        #fdeab5 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    transition: all 0.3s ease;
}

.profile-container:hover .profile-icon {
    transform: scale(1.1);
}

.profile-name {
    font-weight: 600;
    color: var(--text-se);
    letter-spacing: 0.3px;
    transition: all 0.3s ease;
}

.logout-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(239, 68, 68, 0.1);
    color: #ef4444;
    border: 1px solid rgba(239, 68, 68, 0.2);
    transition: all 0.3s ease;
    cursor: pointer;
    text-decoration: none;
}

.logout-btn:hover {
    background: rgba(239, 68, 68, 0.2);
    border-color: rgba(239, 68, 68, 0.4);
    transform: scale(1.1);
    color: #dc2626;
}

.logout-btn i {
    font-size: 14px;
}

/* Orange style for login button */
.logout-btn.login {
    background: rgba(251, 146, 60, 0.1);
    color: #fb923c;
    border: 1px solid rgba(251, 146, 60, 0.2);
}

.logout-btn.login:hover {
    background: rgba(251, 146, 60, 0.2);
    border-color: rgba(251, 146, 60, 0.4);
    color: #f97316;
}

/* Main Container */
.main-container {
    max-width: 1600px;
    margin: 0 auto;
    padding: 2rem 0;
    position: relative;
}

.main-container::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(ellipse at 20% 30%, rgba(167, 139, 250, 0.08) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 70%, rgba(245, 158, 11, 0.05) 0%, transparent 50%);
    pointer-events: none;
    z-index: -1;
    opacity: 0.6;
}

/* Stats Section */
.stats-section {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin: 1rem 0 3rem 0;
    /* Removed animation - keeping only transitions */
}

/* Removed slideDown animation */

.stat-card {
    border-radius: 16px;
    padding: 2.5rem 2rem;
    display: flex;
    align-items: center;
    text-align: center;
    justify-content: center;
    flex-direction: column;
    gap: 1rem;
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
    position: relative;
    overflow: hidden;
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
    -webkit-font-smoothing: subpixel-antialiased;
    /* Removed animation - keeping only transitions */
}

/* Removed fadeInUp animation and stagger delays */

.stat-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    width: 60px;
    aspect-ratio: 1/1;
}

/* Total Players Card - Blue Theme */
#stat-total-players {
    background: linear-gradient(135deg, rgba(183, 202, 229, 0.2) 0%, rgba(29, 78, 216, 0.25) 100%);
    border: 1px solid rgba(59, 130, 246, 0.5);
    box-shadow: 0 8px 32px rgba(59, 130, 246, 0.2);
}

#stat-total-players:hover {
    transform: translateY(-4px);
    box-shadow: 
        0 12px 40px rgba(59, 130, 246, 0.25),
        0 5px 20px rgba(0, 0, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
    border-color: rgba(59, 130, 246, 0.8);
}

#stat-total-players .stat-icon {
    background: rgba(59, 130, 246, 0.15);
    border: 1px solid rgba(59, 130, 246, 0.6);
    color: #60a5fa;
    /* Removed drop-shadow filter - heavy GPU cost */
}

/* Total Kills Card - Green Theme */
#stat-online-players {
    background: linear-gradient(135deg, rgba(186, 232, 203, 0.2) 0%, rgba(21, 128, 61, 0.25) 100%);
    border: 1px solid rgba(34, 197, 94, 0.5);
    box-shadow: 0 8px 32px rgba(34, 197, 94, 0.2);
}

#stat-online-players:hover {
    transform: translateY(-4px);
    box-shadow: 
        0 12px 40px rgba(34, 197, 94, 0.25),
        0 5px 20px rgba(0, 0, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
    border-color: rgba(34, 197, 94, 0.8);
}

#stat-online-players .stat-icon {
    background: rgba(34, 197, 94, 0.15);
    border: 1px solid rgba(34, 197, 94, 0.6);
    color: #4ade80;
    /* Removed drop-shadow filter - heavy GPU cost */
}

/* Steam Players Card - Steam Blue Theme */
#stat-steam-players {
    background: linear-gradient(135deg, rgba(186, 232, 203, 0.15) 0%, rgba(0, 29, 56, 0.5) 100%);
    border: 1px solid rgba(102, 192, 244, 0.5);
    box-shadow: 0 8px 32px rgba(66, 123, 156, 0.2);
}

#stat-steam-players:hover {
    transform: translateY(-4px);
    box-shadow: 
        0 12px 40px rgba(66, 124, 158, 0.25),
        0 5px 20px rgba(0, 0, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
    border-color: rgba(93, 168, 212, 0.8);
}

#stat-steam-players .stat-icon {
    background: rgba(27, 40, 56, 0.15);
    border: 1px solid rgba(102, 192, 244, 0.6);
    color: #66c0f4;
    /* Removed drop-shadow filter - heavy GPU cost */
}

/* New Players Card - Red Theme */
#stat-new-players {
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.2) 0%, rgba(127, 29, 29, 0.25) 100%);
    border: 1px solid rgba(239, 68, 68, 0.5);
    box-shadow: 0 8px 32px rgba(239, 68, 68, 0.2);
}

#stat-new-players:hover {
    transform: translateY(-4px);
    box-shadow: 
        0 12px 40px rgba(239, 68, 68, 0.25),
        0 5px 20px rgba(0, 0, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
    border-color: rgba(239, 68, 68, 0.8);
}

#stat-new-players .stat-icon {
    background: rgba(239, 68, 68, 0.15);
    border: 1px solid rgba(239, 68, 68, 0.6);
    color: #ef4444;
    /* Removed drop-shadow filter - heavy GPU cost */
}

/* Average Skill Card - Gold Theme */
#stat-avg-skill {
    background: linear-gradient(135deg, rgba(255, 217, 152, 0.2) 0%, rgba(180, 83, 9, 0.25) 100%);
    border: 1px solid rgba(245, 158, 11, 0.5);
    box-shadow: 0 8px 32px rgba(245, 158, 11, 0.2);
}

#stat-avg-skill:hover {
    transform: translate3d(0, -2px, 0) scale(1.01);
    box-shadow: 
        0 15px 50px rgba(181, 118, 8, 0.3),
        0 5px 20px rgba(0, 0, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
    border-color: rgba(245, 158, 11, 0.8);
}

#stat-avg-skill .stat-icon {
    background: rgba(245, 158, 11, 0.15);
    border: 1px solid rgba(245, 158, 11, 0.6);
    color: #fbbf24;
    /* Removed drop-shadow filter - heavy GPU cost */
}

/* Stat card pseudo-elements and hover styles are now handled individually for each card */

.stat-icon {
    padding: 0.75rem;
    border-radius: 0.5rem;
    font-size: 1.8rem;
    z-index: 1;
    transition: all 0.3s ease;
}

.stat-content {
    flex: 1;
    z-index: 1;
}

.stat-value {
    font-size: 2rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 0.25rem;
}

.stat-label {
    font-size: 0.875rem;
    color: var(--text-primary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Content Wrapper */
.content-wrapper {
    display: flex;
    align-items: stretch;
    justify-content: space-between;
    gap: 2rem;
    /* Removed animation - keeping only transitions */
}

/* Removed fadeInSlide animation */

.sidebar-container {
    flex: 1 1 25%;
    display: flex;
}
/* Sidebar */
.sidebar {
    background: 
        var(--gradient-2);
    border: 1px solid #444;
    border-radius: 16px;
    padding: 1.5rem;
    box-shadow: 0 1em 1em 0 rgba(0, 0, 0, 0.2);
    position: relative;
    overflow: hidden;
    width: 100%;
    display: flex;
    flex-direction: column;
    /* Keep compositing layer active so glow is visible even when not hovered */
    will-change: transform;
}

.sidebar,
.table-container {
    transition: all 0.3s ease;
}

.sidebar:hover,
.table-container:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(232, 224, 255, 0.05), 0 4px 15px rgba(255, 233, 196, 0.07), inset 0 1px 0 rgba(255, 255, 255, 0.05);
    border-color: rgba(139, 92, 246, 0.3);
}

.sidebar::before,
.table-container::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 5px;
    background: var(--border-top);
    border-radius: inherit;
}

.sidebar .hr {
    border-top: 1px solid rgba(255,255, 255, 0.1);
}

.sidebar-section {
    margin-bottom: 0.75rem;
}

.sidebar-section:last-child {
    margin-bottom: 0;
}

.sidebar-section h3 {
    font-size: 0.9rem;
    color: var(--accent);
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.search-box {
    display: flex;
    gap: 0.5rem;
}

.search-box input {
    flex: 1;
    padding: 0.75rem;
    background: rgba(0, 0, 0, 0.5);
    border: 1px solid rgba(167, 139, 250, 0.3);
    border-radius: 8px;
    color: var(--text-primary);
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.search-box input:focus {
    outline: none;
    border-color: rgba(167, 139, 250, 0.5);
    box-shadow: 0 0 0 3px rgba(167, 139, 250, 0.15);
}

.icon-btn {
    padding: 0.75rem;
    background: linear-gradient(135deg, #7c3aed 0%, #8b5cf6 100%);
    border: none;
    border-radius: 8px;
    color: white;
    cursor: pointer;
    transition: all 0.3s ease;
}

.icon-btn:hover {
    background: linear-gradient(135deg, #8b5cf6 0%, #a78bfa 100%);
    transform: scale(1.05);
    box-shadow: 0 4px 15px rgba(167, 139, 250, 0.4);
}

.sidebar-select {
    width: 100%;
    padding: 0.5rem 2.5rem 0.5rem 0.75rem;
    background: linear-gradient(135deg, rgba(15, 10, 30, 0.9) 0%, rgba(25, 15, 45, 0.85) 100%);
    border: 1px solid rgba(167, 139, 250, 0.25);
    border-radius: 10px;
    color: var(--text-primary);
    font-size: 0.9rem;
    font-weight: 500;
    margin-bottom: 0.4rem;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    /* Removed backdrop-filter - extremely expensive, causes major lag */
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    position: relative;
    background-image: 
        url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%23a78bfa' d='M6 8L0 2l1.4-1.4L6 5.2l4.6-4.6L12 2z'/%3E%3C/svg%3E"),
        linear-gradient(135deg, rgba(15, 10, 30, 0.7) 0%, rgba(25, 15, 45, 0.65) 100%);
    background-repeat: no-repeat;
    background-position: right 0.75rem center, 0 0;
}

#flags-input {
    cursor: text;
    padding: 0.6rem 0.75rem;
    background: linear-gradient(135deg, rgba(15, 10, 30, 0.7) 0%, rgba(25, 15, 45, 0.65) 100%);
}

h1, h2, h3, h4, h5, h6, p, div { 
    cursor: default;
}
.sidebar-select:hover {
    border-color: rgba(167, 139, 250, 0.8);
    transform: translateY(-1px);
}

.sidebar-select:focus {
    outline: none;
    border-color: rgba(167, 139, 250, 0.9);
}

.sidebar-select:active {
    transform: translateY(0);
}

.sidebar-select option {
    background: #0f0a1e;
    color: var(--text-primary);
    padding: 0.75rem;
    font-weight: 500;
}

.sidebar-select option:hover,
.sidebar-select option:checked {
    background: rgba(0, 0, 0, 0.7);
    color: var(--accent);
}

.sidebar-select optgroup {
    background: rgb(82, 82, 82);
}

.admin-btn {
    width: 100%;
    padding: 0.875rem;
    background: linear-gradient(135deg, #8666bc 0%, #5a2cc7 100%);
    border: none;
    border-radius: 8px;
    color: white;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.admin-btn.individual {
    background: linear-gradient(135deg, #6683bc 0%, #2c58c7 100%);
}

.admin-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(167, 139, 250, 0.4);
}

.admin-btn.danger {
    background: linear-gradient(135deg, #bf5555 0%, #b90000 100%);
}

.admin-btn.danger:hover {
    box-shadow: 0 6px 20px rgba(250, 139, 139, 0.4);

}
/* Active state for admin toggle buttons */
.admin-btn.active {
    outline: 2px solid rgba(255, 255, 255, 0.18);
    box-shadow: 0 0 0 3px rgba(167, 139, 250, 0.15), 0 6px 20px rgba(167,139,250,0.5);
    filter: saturate(1.1);
}

.admin-btn.active.danger {
    outline: 2px solid rgba(255, 255, 255, 0.18);
    box-shadow: 0 0 0 3px rgba(250, 139, 139, 0.15), 0 6px 20px rgba(250, 139, 139, 0.5);
    filter: saturate(1.1);
}

/* Action column buttons styling */
.col-action { width: 60px; text-align: center; }
.action-btn.manipulate, .action-btn.reset { background: linear-gradient(135deg, #3a61ed 0%, #5c88f6 100%); }
.action-btn.manipulate:hover, .action-btn.reset:hover { background: linear-gradient(135deg, #5c92f6 0%, #8b9cfa 100%); }
.action-btn.remove { background: linear-gradient(135deg, var(--danger) 0%, #dc2626 100%); }
.action-btn.remove:hover { background: linear-gradient(135deg, #dc2626 0%, #ef4444 100%); }

/* Manipulate/Reset/Remove toggle states (row highlight if mode active) */
tbody tr.manipulate-mode { box-shadow: inset 4px 0 0 #7c3aed; }
tbody tr.reset-mode { box-shadow: inset 4px 0 0 #f59e0b; }
tbody tr.remove-mode { box-shadow: inset 4px 0 0 var(--danger); }

/* Modal specific minor additions */
#manipulate-stats-fields { 
    display: flex;
    flex-direction: column;
    gap: 0.75rem; 
}
.manip-group { 
    display: grid; 
    grid-template-columns: repeat(2, 1fr); 
    gap: 0.5rem 1rem;
}
.manip-group h4 {
    display: none;
    grid-column: 1 / -1;
    margin: 0 0 0.5rem 0;
    color: var(--accent);
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.manip-field { 
    font-size: 0.75rem; 
    display: flex;  
    flex-direction: column; 
    gap: 0.25rem; 
    color: var(--text-secondary);
}
.manip-field input { 
    flex: 1 1 40%;
    padding: 0.5rem 0.75rem;
    border: 1px solid rgba(167, 139, 250, 0.3);
    border-radius: 8px;
    background: rgba(15, 10, 26, 0.5);
    color: var(--text-primary);
    font-size: 0.9rem;
    transition: border-color 0.3s 
ease, box-shadow 0.3s 
ease;
}
.manip-field input:focus { 
    outline: none; 
    border-color: rgba(167,139,250,0.5); 
}

/* Players Per Page select special styling when custom revealed */
#items-per-page-custom { margin-top:0.5rem; }

/* Stats Filter Section */
.stats-filter-grid {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.filter-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.25rem;
    margin-bottom: 0.25rem;
}

.filter-item {
    display: flex;
    flex-direction: column;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.filter-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, 
        rgba(167, 139, 250, 0.05) 0%, 
        rgba(139, 92, 246, 0.03) 50%,
        transparent 100%);
    border-radius: inherit;
    z-index: -1;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.filter-item label {
    font-size: 0.7rem;
    font-weight: 700;
    color: var(--accent-primary);
    text-transform: uppercase;
    letter-spacing: 1px;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.filter-row .filter-item.sort label {
    font-size: 0.7rem;
    padding: 0.25rem 0;
}


.range-container {
    position: relative;
    display: flex;
    flex-direction: column;
    padding: 0 0.75rem;
}

.range-slider {
    -webkit-appearance: none;
    appearance: none;
    width: 100%;
    height: 6px;
    background: linear-gradient(90deg, 
        rgba(255, 255, 255, 0.1) 0%, 
        rgba(250, 202, 139, 0.15) 50%, 
        rgba(255, 255, 255, 0.1) 100%);
    border-radius: 8px;
    outline: none;
    cursor: pointer;
    position: relative;
    box-shadow: 
        inset 0 1px 3px rgba(0, 0, 0, 0.3),
        0 1px 0 rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
}

.range-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 20px;
    height: 20px;
    background: #afa072;

    border-radius: 50%;
    cursor: grab;
    border: 3px solid rgba(255, 255, 255, 0.9);
    box-shadow: 
        0 2px 8px rgba(0, 0, 0, 0.4),
        0 0 0 0 rgba(167, 139, 250, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
    transition: all 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative;
}

.range-slider::-webkit-slider-thumb:hover {
    transform: scale(1.15);
    border-color: rgba(255, 255, 255, 1);
}

.range-slider::-webkit-slider-thumb:active {
    cursor: grabbing;
    transform: scale(1.05);
    box-shadow: 
        0 2px 8px rgba(0, 0, 0, 0.6),
        0 0 0 2px rgba(167, 139, 250, 0.5),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.range-slider::-moz-range-thumb {
    width: 20px;
    height: 20px;
    background: #afa072;

    border-radius: 50%;
    cursor: grab;
    border: 3px solid rgba(255, 255, 255, 0.9);
    box-shadow: 
        0 2px 8px rgba(0, 0, 0, 0.4),
        0 0 0 0 rgba(167, 139, 250, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
    transition: all 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative;
}

.range-slider::-moz-range-thumb:hover {
    transform: scale(1.15);
    border-color: rgba(255, 255, 255, 1);
}

.range-slider::-moz-range-thumb:active {
    cursor: grabbing;
    transform: scale(1.05);
}

.range-slider:focus {
    background: linear-gradient(90deg, 
        rgba(167, 139, 250, 0.2) 0%, 
        rgba(167, 139, 250, 0.3) 50%, 
        rgba(167, 139, 250, 0.2) 100%);
    box-shadow: 
        inset 0 1px 3px rgba(0, 0, 0, 0.3),
        0 1px 0 rgba(255, 255, 255, 0.1),
        0 0 0 2px rgba(167, 139, 250, 0.3);
}

.range-slider::-moz-range-track {
    height: 6px;
    background: linear-gradient(90deg, 
        rgba(255, 255, 255, 0.1) 0%, 
        rgba(167, 139, 250, 0.15) 50%, 
        rgba(255, 255, 255, 0.1) 100%);
    border-radius: 8px;
    border: none;
    box-shadow: 
        inset 0 1px 3px rgba(0, 0, 0, 0.3),
        0 1px 0 rgba(255, 255, 255, 0.1);
}

.range-values {
    font-size: 0.85rem;
    color: var(--text-primary);
    text-align: center;
    font-weight: 600;
}

/* Dual-thumb slider styles */
.dual-thumb-slider {
    position: relative;
    width: 100%;
    height: 20px;
    margin: 8px 0 0 0;
}

.dual-track {
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 5px;
    background: linear-gradient(90deg, 
        rgba(255, 255, 255, 0.1) 0%, 
        rgba(250, 202, 139, 0.15) 50%, 
        rgba(255, 255, 255, 0.1) 100%);
    border-radius: 8px;
    transform: translateY(-50%);
    box-shadow: 
        inset 0 1px 3px rgba(0, 0, 0, 0.3),
        0 1px 0 rgba(255, 255, 255, 0.1);
    cursor: pointer;
}

.dual-range {
    position: absolute;
    top: 0;
    height: 100%;
    background: linear-gradient(90deg, 
        rgba(250, 224, 139, 0.6) 0%, 
        rgba(246, 195, 92, 0.8) 50%, 
        rgba(250, 215, 139, 0.6) 100%);
    border-radius: 8px;
    transition: all 0.2s ease;
    pointer-events: none;
}

.dual-thumb {
    position: absolute;
    top: 50%;
    width: 17px;
    height: 17px;
    background: #afa072;
    border-radius: 50%;
    cursor: grab;
    border: 3px solid rgba(255, 255, 255, 0.9);
    box-shadow: 
        0 2px 8px rgba(0, 0, 0, 0.4),
        0 0 0 0 rgba(167, 139, 250, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
    transition: all 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    transform: translate(-50%, -50%);
    z-index: 3;
    user-select: none;
}

.dual-thumb:hover {
    transform: translate(-50%, -50%) scale(1.15);
    border-color: rgba(255, 255, 255, 1);
    box-shadow: 
        0 3px 12px rgba(0, 0, 0, 0.5),
        0 0 0 2px rgba(167, 139, 250, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.dual-thumb.dragging {
    cursor: grabbing;
    transform: translate(-50%, -50%) scale(1.05);
    box-shadow: 
        0 2px 8px rgba(0, 0, 0, 0.6),
        0 0 0 2px rgba(167, 139, 250, 0.5),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.dual-thumb-max {
    z-index: 4;
}

.reset-filters-btn {
    padding: 0.6rem 1rem;
    margin: auto 0;
    background: linear-gradient(135deg, 
        rgba(239, 68, 68, 0.9) 0%, 
        rgba(220, 38, 38, 0.9) 50%,
        rgba(185, 28, 28, 0.9) 100%);
    border: 1px solid rgba(239, 68, 68, 0.4);
    border-radius: 10px;
    color: white;
    font-size: 0.7rem;
    font-weight: 900;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    /* Removed backdrop-filter - extremely expensive */
    position: relative;
    overflow: hidden;
    box-shadow: 
        0 4px 15px rgba(239, 68, 68, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.reset-filters-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, 
        transparent 0%, 
        rgba(255, 255, 255, 0.2) 50%, 
        transparent 100%);
    transition: left 0.6s ease;
}

.reset-filters-btn:hover {
    background: linear-gradient(135deg, 
        rgba(239, 68, 68, 1) 0%, 
        rgba(220, 38, 38, 1) 50%,
        rgba(185, 28, 28, 1) 100%);
    border-color: rgba(239, 68, 68, 0.8);
    transform: translateY(-2px) scale(1.02);
    box-shadow: 
        0 8px 25px rgba(239, 68, 68, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.reset-filters-btn:hover::before {
    left: 100%;
}

.reset-filters-btn:active {
    transform: translateY(-1px) scale(0.98);
    box-shadow: 
        0 4px 15px rgba(239, 68, 68, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.reset-filters-btn i {
    font-size: 0.85rem;
    filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.3));
}

/* Responsive adjustments for filter grid */
@media (max-width: 1200px) {
    .filter-row {
        gap: 0.75rem;
    }
}

.quick-stat {
    display: flex;
    justify-content: space-between;
    padding: 0.75rem;
    background: rgba(0, 0, 0, 0.5);
    border-radius: 8px;
    margin-bottom: 0.5rem;
    border: 1px solid #333;
    /* Removed backdrop-filter - extremely expensive */
    position: relative;
}

.quick-stat::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at 80% 20%, rgba(124, 58, 237, 0.1) 0%, transparent 50%);
    border-radius: inherit;
    z-index: -1;
}

.quick-stat span:first-child {
    color: var(--text-secondary);
    font-size: 0.875rem;
}

.quick-stat span:last-child {
    color: var(--accent);
    font-weight: 600;
}

/* Main Content */
.main-content {
    min-height: 500px;
    flex: 1 1 90%;
    display: flex;
    flex-direction: column;
}

.table-container {
    overflow: hidden;
    background: 
        var(--gradient-2);
    border: 1px solid #444;
    border-radius: 16px;
    padding: 1.5rem;
   box-shadow: 0 1em 1em 0 rgba(0, 0, 0, 0.2);
    /* Removed backdrop-filter - extremely expensive, causes major lag */
    position: relative;
    flex: 1;
}

@keyframes glowMove {
    0%, 100% {
        transform: translate(-50%, -50%) translate(-30%, -30%) scale(1.2);
    }
    25% {
        transform: translate(-50%, -50%) translate(30%, -20%) scale(1.3);
    }
    50% {
        transform: translate(-50%, -50%) translate(20%, 30%) scale(1.2);
    }
    75% {
        transform: translate(-50%, -50%) translate(-20%, 20%) scale(1.25);
    }
}

.table-container::before,
.sidebar::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 140%;
    height: 140%;
    background: radial-gradient(circle at center, rgba(79, 67, 20, 0.5) 0%, transparent 60%);
    animation: glowMove 15s ease-in-out infinite;
    z-index: 0;
    pointer-events: none;
    border-radius: inherit;
    opacity: 0.4;
    will-change: transform;
}

.sidebar::after {
    animation: glowMove 10s ease-in-out infinite;
    top: 50%;
    left: 50%;
    width: 100%;
    height: 100%;
}

.sidebar::after {
    opacity: 0.3;
}

/* Ensure pseudo-element glow stays behind content but above background */
.sidebar > *,
.table-container > * {
    position: relative;
    z-index: 1;
}

/* Removed particleFloat animation - heavy blur + transform causes lag */

.table-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 1rem;
    position: relative;
}

.table-header::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, 
        transparent 0%,
        rgba(250, 202, 139, 0.3) 30%,
        rgba(250, 217, 139, 0.5) 50%,
        rgba(250, 206, 139, 0.3) 70%,
        transparent 100%);
}

.table-header h2 {
    font-size: 1.65rem;
    font-weight: 700;
    color: var(--accent);
    display: flex;
    align-items: center;
    gap: 0.75rem;
    text-shadow: 
        0 0 10px rgba(250, 206, 139, 0.2),
        0 2px 4px rgba(0, 0, 0, 0.15);
    letter-spacing: 0.5px;
    position: relative;
    transition: all 0.3s ease;
}

.table-header h2:hover {
    color: #c4b5fd;
    text-shadow: 
        0 0 15px rgba(167, 139, 250, 0.3),
        0 0 30px rgba(167, 139, 250, 0.15),
        0 2px 4px rgba(0, 0, 0, 0.15);
    transform: translateY(-1px);
}

.table-header h2 i {
    vertical-align: bottom;
    color: var(--accent);
    filter: drop-shadow(0 0 8px rgba(250, 209, 139, 0.15));
    transition: all 0.3s ease;
}

.table-header h2:hover i {
    color: #c4b5fd;
    transform: scale(1.1);
}

.refresh-btn {
    padding: 0.75rem 1.5rem;
    background: linear-gradient(135deg, #7c3aed 0%, #8b5cf6 100%);
    border: none;
    border-radius: 8px;
    color: white;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.refresh-btn:hover {
    background: linear-gradient(135deg, #8b5cf6 0%, #a78bfa 100%);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(167, 139, 250, 0.4);
}

.table-wrapper {
    overflow-x: hidden;
    overflow-y: auto;
    /* Header (~45px) + 15 rows (15 × 38px = 570px) = ~615px total */
    /* Add a bit of buffer for borders and spacing */
    /* Dynamic height will be set via JavaScript based on items per page */
    max-height: 625px;
    border-radius: 16px;
    border: 2px solid rgb(139, 121, 71);
    box-shadow: 0 1em 1em 0 rgba(0, 0, 0, 0.2);
    position: relative;
    /* Smooth scrolling */
    scroll-behavior: smooth;
    /* Custom scrollbar styling */
    scrollbar-width: thin;
    scrollbar-color: rgba(139, 121, 71, 0.6) rgba(0, 0, 0, 0.2);
}

/* Show scrollbar only when needed (more than 15 items per page) */
.table-wrapper.no-scroll {
    overflow-y: hidden;
}

/* Webkit scrollbar styling for Chrome/Safari */
.table-wrapper::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}

.table-wrapper::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.2);
    border-radius: 10px;
}

.table-wrapper::-webkit-scrollbar-thumb {
    background: rgba(139, 121, 71, 0.6);
    border-radius: 10px;
    border: 2px solid rgba(0, 0, 0, 0.2);
}

.table-wrapper::-webkit-scrollbar-thumb:hover {
    background: rgba(139, 121, 71, 0.8);
}

.table-wrapper::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    height: 6px;
    background: linear-gradient(90deg, 
        transparent, 
        rgb(237, 207, 58), 
        rgba(250, 230, 139, 0.8), 
        rgba(246, 226, 92, 0.9),
        rgb(237, 207, 58), 
        transparent);
    border-radius: 16px 16px 0 0;
    filter: blur(2px);
}

.table-wrapper::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: -2px;
    right: -2px;
    height: 6px;
    border-radius: 0 0 16px 16px;
    /* Removed blur filter - heavy GPU cost */
}

/* Removed borderPulse animations - constant filter repainting */

.players-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    font-size: 1rem;
    overflow: hidden;
    border-radius: 8px;
}

.players-table thead {
    position: sticky;
    top: 0;
    background: 
            var(--gradient-1);

    /* Mild glow for player names (follows inline color) */
    .players-table .player-name {
        text-shadow: 0 0 6px currentColor;
    }

    /* Slightly stronger on hover */
    .players-table .player-name:hover {
        text-shadow: 0 0 8px currentColor, 0 0 14px currentColor;
    }
    border-radius: 12px 12px 0 0;
    z-index: 10;
}

.players-table thead::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(ellipse at 20% 0%, rgba(124, 58, 237, 0.4) 0%, transparent 60%),
        radial-gradient(ellipse at 80% 0%, rgba(139, 92, 246, 0.3) 0%, transparent 60%);
    filter: blur(20px);
    z-index: -1;
    border-radius: inherit;
}

.players-table th {
    padding: 0.1rem 0;
    text-align: center;
    color: white;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-size: 0.85rem;
    position: relative;
    text-shadow: 0 0 10px rgba(167, 139, 250, 0.8);
}

.players-table th.sortable {
    cursor: pointer;
    user-select: none;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    overflow: hidden;
}

.players-table th.sortable::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 3px;
    background: linear-gradient(90deg, #a78bfa, #7c3aed, #a78bfa);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 0 10px rgba(167, 139, 250, 0.8);
}

.players-table th.sortable::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, 
        transparent, 
        rgba(167, 139, 250, 0.3), 
        transparent);
    transition: left 0.6s ease;
}

.players-table th.sortable:hover {
    background: 
        radial-gradient(circle at center, rgba(167, 139, 250, 0.4) 0%, rgba(124, 58, 237, 0.2) 100%);
    color: #ffffff;
    text-shadow: 
        0 0 15px rgba(167, 139, 250, 1),
        0 0 30px rgba(124, 58, 237, 0.8);
    transform: translateY(-2px);
    
}

/* Avoid vertical shift on hover for the weapon header specifically,
   since it acts as a hover target for the dropdown. */
.players-table th.col-weapon.sortable:hover {
    transform: none; /* prevent slight 1-2px lift that causes jitter */
}

.players-table th.sortable:hover::before {
    width: 100%;
}

.players-table th.sortable:hover::after {
    left: 100%;
}

.players-table th.sortable i {
    margin-left: 0.5rem;
    font-size: 0.75rem;
    opacity: 0.6;
    transition: all 0.3s ease;
}

.players-table th.sortable:hover i {
    opacity: 1;
    transform: scale(1.2);
}

.players-table tbody tr {
    background: rgba(0, 0, 0, 0.2);
    transition: background 0.2s ease, transform 0.2s ease;
    position: relative;
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
    /* Removed animation - keeping only transitions */
}

/* Removed fadeInRow animation */


.players-table tbody tr:hover::before {
    opacity: 1;
}

.players-table tbody tr:nth-child(odd) {
    background: rgba(0, 0, 0, 0);
}

.players-table tbody tr:hover {
    background: rgba(167, 139, 250, 0.08) !important;

}

.players-table td {
    color: var(--text-secondary);
    transition: all 0.3s ease;
    font-weight: 500;
    cursor: default;
    height: 40px;
}

td div.col { display: inline-block; vertical-align: middle;}

/* Enhanced Stats Styling */
.players-table td p.stats {
    font-size: 0.75rem;
    font-weight: 600;
    color: #c8d3ff;
    background: linear-gradient(135deg, rgba(67, 117, 255, 0.15) 0%, rgba(59, 130, 246, 0.08) 100%);
    border: 1px solid rgba(59, 130, 246, 0.4);
    border-radius: 1.2rem;
    padding: 0.2rem 0.75rem;
    transition: all 0.25s ease;
    position: relative;
    overflow: hidden;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
    letter-spacing: 0.3px;
}

.players-table td p.stats::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s ease;
}

.players-table td p.stats:hover {
    transform: translateY(-1px) scale(1.02);
    box-shadow: 
        0 4px 15px rgba(59, 130, 246, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
    border-color: rgba(59, 130, 246, 0.6);
}

.players-table td p.stats:hover::before {
    left: 100%;
}

.players-table td p.stats i { 
    font-size: 0.65rem;
    margin-right: 0.2rem;
    filter: drop-shadow(0 1px 1px rgba(0, 0, 0, 0.3));
}

/* Deaths Stats - Red Theme */
.players-table td.col-deaths p.stats {
    color: #ffcdd2;
    background: rgba(244, 67, 54, 0.2);
    border: 1px solid rgba(244, 67, 54, 0.65);
}

.players-table td.col-deaths p.stats:hover {
    box-shadow: 
        0 4px 15px rgba(244, 67, 54, 0.35),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
    border-color: rgba(244, 67, 54, 1);
}

/* Headshot Stats - Gold/Orange Theme */
.players-table td.col-hs p.stats {
    color: #fff3cd;
    background: rgba(255, 193, 7, 0.2);
    border: 1px solid rgba(255, 193, 7, 0.65);
}

.players-table td.col-hs p.stats:hover {
    box-shadow: 
        0 4px 15px rgba(255, 193, 7, 0.35),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 193, 7, 1);
}

/* Weapon Stats - Gray/Silver Theme */
.players-table td.col-weapon p.stats {
    color: #e8eaed;
    background: rgba(158, 158, 158, 0.2);
    border: 1px solid rgba(158, 158, 158, 0.65);
}

.players-table td.col-weapon p.stats:hover {
    box-shadow: 
        0 4px 15px rgba(158, 158, 158, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.8);
}

/* Kills Stats - Green Theme (if needed) */
.players-table td.col-kills p.stats {
    color: #c8e6c9;
    background:rgba(76, 175, 80, 0.2);
    border: 1px solid rgba(76, 175, 80, 0.65);
}

.players-table td.col-kills p.stats:hover {
    box-shadow: 
        0 4px 15px rgba(76, 175, 80, 0.35),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
    border-color: rgba(110, 255, 115, 0.8);
}

.loading-cell {
    text-align: center;
    padding: 3rem !important;
    color: var(--text-muted);
    font-size: 1.1rem;
}

/* Column-Specific Styling */

/* Rank Column */
.col-rank {
    padding-left:0.4em;
    text-align: center;
    font-weight: 700;
    color: var(--text-secondary);
}

.col-rank.rank-top {
    font-size: 1.1rem;
}

.col-rank.rank-1{
    color: #ffd700;
}

.col-rank.rank-2 {
    color: #c0c0c0;
}

.col-rank.rank-3 {
    color: #cd7f32;
}

/* Removed bounce animations on top ranks - reduces constant repainting */

/* XP Column */
.col-xp {
    width: 110px;
}

/* Name Column */
.col-name {
    min-width: 350px;
}

.player-info {
    display: flex;
    align-items: center;
}

.player-flag {
    padding-right: 0.5rem;
    transition: all 0.3s ease;
    display: inline-block;
}

.player-flag:hover {
    transform: scale(1.1);
    filter: brightness(1.2);
}

.player-avatar img {
    display: block;
    padding-right: 0.5rem;
    width: 35px;
    transition: all 0.3s ease;
}

.player-avatar img:hover {
    transform: scale(1.1);
}

.player-steam, .player-new {
    padding-left: 0.5rem;
}
.player-steam img,
.player-new img {
    vertical-align: top;
}

.player-new img {
    width: 40px;
}

.player-steam img {
    width: 15px;
}
.player-name {
    font-size: 1.03rem;
    font-weight: 700;
    color: var(--text-primary);
    transition: all 0.3s ease;
    max-width: 280px;
    text-overflow: ellipsis;
    overflow: hidden;
    white-space: nowrap;
}

.player-name:hover {
    overflow: visible;
    color: var(--accent);
    text-shadow: 0 0 10px rgba(167, 139, 250, 0.5);
}
/* Kills Column */
.col-kills {
    text-align: center;
    color: var(--success);
    font-weight: 600;
}

/* Deaths Column */
.col-deaths {
    text-align: center;
    color: var(--danger);
    font-weight: 600;
}

/* K.D. Ratio Column */
.col-kdr {
    text-align: center;
    color: var(--text-primary);
    font-weight: 700;
}

/* Headshot % Column */
td.col-hs,
.hs-container { text-align: center; display: flex; align-items: center; justify-content: center;}
.hs-circle { display: inline-block; vertical-align: middle; margin-left: 6px; margin-top: 5px;}
/* .hs-svg filter removed - heavy GPU cost with drop-shadow */
.hs-bg { stroke: rgba(255,255,255,0.12); }
.hs-fg { stroke: #f59e0b; transform: rotate(-90deg); transform-origin: 50% 50%; stroke-linecap: round; }
.hs-label { fill: #fff; font-weight: 800; font-size: 10px; text-shadow: 0 1px 2px rgba(0,0,0,0.8); }
.hs-count { color: var(--text-secondary); font-weight: 600; }



.skill-badge {
    display: flex;
    padding:1px 0 1px 0;
    align-items: center;
    justify-content: space-between;
    border: 1px solid;
    border-radius: 5px;
    transition: all 0.3s ease;
    line-height: 1.3;
    height: 21px;
    width: 62px;
}

.skill-badge:hover {
    transform: translate3d(0, -1px, 0) scale(1.04);
    box-shadow: 
        inset 0 0 10px rgba(0, 0, 0, 0.2),
        0 0 10px currentColor,
        0 4px 15px rgba(0, 0, 0, 0.1);
}

.skill-level {
    width: 25px;
    text-align: center;
    color: #222;
    font-weight: 900;
}

.skill-range {
    text-align: center;
    background: rgba(255,255,255,0.9);
    width: 32px;
    font-weight: 400;
    font-size: 0.9rem;
    color: #222;
    border-top-right-radius: 5px;
    border-bottom-right-radius: 5px;
}

.number-container {
    background-image: url('../images/xp-border.png');
    background-position: center;
    background-repeat: no-repeat;
    background-size: 85px;
    text-align:center;
    font-size: 0.85rem;
    font-weight: 900;
    height: 2rem;
    display:flex;
    align-items: center;
    justify-content: center;
    font-family: Tahoma, sans-serif;
    font-style: italic;
    transition: all 0.3s ease;
}

.number-container:hover {
    transform: scale(1.05);
    filter: brightness(1.15);
}

.number-container .number {
    margin-left: 0.5em;
    cursor: default;
}

/* Rank Badge Column */
.col-rank-badge {
    width: 0px;
    text-align: center;
}

.col-skill {
    padding: 0 1em;
    width:0;
}

/* Weapon Column */
.col-weapon { text-align: center; }
.weapon-icon { height: 20px;  vertical-align: middle; }
.weapon-kills {color: var(--text-secondary); font-weight: 600; }

/* Weapon header dropdown */
.weapon-header { 
    position: relative; 
    display: inline-block;
}

.weapon-header-icon { 
    filter: brightness(1.2);
    height: 35px; 
    vertical-align: middle;
    transition: all 0.3s ease;
}


.weapon-dropdown { 
    position: fixed; 
    top: 0; 
    left: 0; 
    transform: translateX(-50%) translateY(-12px) scale(0.95);
    background: var(--modal), linear-gradient(135deg, rgba(2, 0, 8, 0.95) 0%, rgba(10, 5, 26, 0.9) 100%);
    border: 1px solid #555;
    border-radius: 16px; 
    padding: 1.25rem; 
    min-width: 320px; 
    display: grid; 
    grid-template-columns: repeat(5, 1fr); 
    gap: 0.75rem;
    box-shadow: 
        0 20px 60px rgba(0, 0, 0, 0.9),
        0 0 0 1px rgba(167, 139, 250, 0.1) inset,
        0 0 40px rgba(124, 58, 237, 0.3);
    z-index: 9999;
    opacity: 0; 
    visibility: hidden; 
    pointer-events: none;
    transition: all 250ms cubic-bezier(0.34, 1.56, 0.64, 1);
    /* Removed backdrop-filter - extremely expensive */
}

.weapon-dropdown::before {
    content: '';
    position: absolute;
    top: -8px;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 0;
    border-left: 10px solid transparent;
    border-right: 10px solid transparent;
    border-bottom: 8px solid rgba(167, 139, 250, 0.3);
    filter: drop-shadow(0 -2px 4px rgba(0, 0, 0, 0.3));
}

.weapon-dropdown::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(circle at 20% 20%, rgba(124, 58, 237, 0.15) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(139, 92, 246, 0.1) 0%, transparent 50%);
    border-radius: inherit;
    pointer-events: none;
    z-index: -1;
}

.weapon-dropdown[aria-hidden="false"] { 
    opacity: 1; 
    visibility: visible; 
    pointer-events: auto; 
    transform: translateX(-50%) translateY(0) scale(1);
}

.weapon-item { 
    display: flex; 
    align-items: center; 
    justify-content: center; 
    flex-direction: column;
    gap: 0.25rem; 
    padding: 0.25rem; 
    border: 1px solid #fff0d53f; 
    background: rgba(0,0,0, 0.15);
    color: var(--text-primary); 
    border-radius: 7px; 
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    position: relative;
    overflow: hidden;
}

.weapon-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, 
        transparent, 
        rgba(167, 139, 250, 0.6), 
        transparent);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.weapon-item:hover::before {
    opacity: 1;
}

.weapon-item:hover { 
    background: linear-gradient(135deg, 
        rgba(167, 139, 250, 0.2) 0%, 
        rgba(139, 92, 246, 0.25) 100%);
    border-color: rgba(167, 139, 250, 0.6);
    transform: translateY(-2px) scale(1.01);
    box-shadow: 
        0 8px 20px rgba(124, 58, 237, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.weapon-item:active {
    transform: translateY(-1px) scale(1.02);
}

.weapon-item img { 
    filter: brightness(1.2);
    height: 32px;
    transition: all 0.3s ease;
}

.weapon-item:hover img {
    filter: drop-shadow(0 4px 8px rgba(167, 139, 250, 0.5));
    transform: scale(1.1);
}

.weapon-item span { 
    font-size: 0.55rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    text-align: center;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
}

.rank-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 7rem;
    height: 2rem;
    background-repeat: no-repeat;
    background-position: center;
    background-size: contain;
    transition: all 0.3s ease;
    border-radius: 4px;
}

.rank-badge:hover {
    transform: translate3d(0, -2px, 0) scale(1.08);
    filter: 
        drop-shadow(0 6px 20px rgba(167, 139, 250, 0.35))
        brightness(1.1);
}

/* Rank badge with no image configured in INI */
.rank-badge.no-image {
    background-image: none !important;
    opacity: 0.5;
}

/* Actions Column */
.col-actions {
    position: relative;
    width: 0;
    text-align: center;
    z-index: 5;
    padding: 0;
    visibility: hidden;
    overflow: hidden;
    transition: width 0.4s cubic-bezier(0.4, 0, 0.2, 1), 
                padding 0.4s cubic-bezier(0.4, 0, 0.2, 1),
                visibility 0s linear 0.4s;
    white-space: nowrap;
}

.col-actions.show {
    width: 60px;
    visibility: visible;
    padding: 0 0.5rem;
    transition: width 0.4s cubic-bezier(0.4, 0, 0.2, 1), 
                padding 0.4s cubic-bezier(0.4, 0, 0.2, 1),
                visibility 0s linear 0s;
}

/* Action buttons inside the column - no fade/scale animations */
.action-btn i {
    margin-right: 0.5em;
}


/* Use inset box-shadow instead of pseudo-elements to avoid layout shifts */
tbody tr.offline {
    box-shadow: inset 4px 0 0 rgb(229, 69, 69);
}

tbody tr.online {
    box-shadow: inset 4px 0 0 rgb(81, 190, 38);
}

tr.top-player::after {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: 
        linear-gradient(90deg, 
            rgba(255, 215, 0, 0.15) 0%, 
            transparent 30%, 
            transparent 70%, 
            rgba(255, 215, 0, 0.075) 100%);
    pointer-events: none;
    /* Removed animation - keeping only transitions */
}

tr.top-player:nth-child(2)::after {
    background: 
        linear-gradient(90deg, 
            rgba(217, 215, 255, 0.15) 0%, 
            transparent 30%, 
            transparent 70%, 
            rgba(221, 220, 255, 0.075) 100%);
}

tr.top-player:nth-child(3)::after {
    background: 
        linear-gradient(90deg, 
            rgba(183, 61, 0, 0.15) 0%, 
            transparent 30%, 
            transparent 70%, 
            rgba(197, 66, 0, 0.075) 100%);
}

/* Removed bounce animation */

/* Removed floatingGradients animation - constant transform/opacity changes cause lag */

/* Removed pulseGlow animation - constant opacity changes */

/* Removed tableGlow animation - heavy box-shadow calculations */

/* Removed borderPulse animation - constant filter blur changes */

.action-btns {
    display: flex;
    gap: 0.5rem;
}

.action-btn {
    position: absolute;
    top:0;
    height: 100%;
    width: 100%;
    padding: 0.5rem 0.25rem;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0.875rem;
    color: white;
    z-index: -1;
}

.action-btn.delete {
    background: var(--danger);
}

.action-btn.delete:hover {
    background: #dc2626;
    transform: scale(1.05);
}

/* Utility */
.hidden { display: none !important; }

/* (Removed) Right action rail overlay styles were deleted as the UI now uses inline per-row action buttons. */

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(167, 139, 250, 0.15);
}

/* Table footer container holding pagination (left) and search (right) */
.table-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1.25rem;
    flex-wrap: wrap;
    margin-top: 1rem;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(167, 139, 250, 0.15);
}

.table-footer .pagination {
    margin-top: 0;
    padding-top: 0;
    border-top: none;
    flex: 1 1 auto;
    justify-content: flex-start;
}

.table-footer .table-search {
    flex: 0 1 320px;
    max-width: 100%;
}

.table-footer .table-search input {
    background: rgba(0,0,0,0.45);
}

@media (max-width: 900px) {
    .table-footer {
        flex-direction: column;
        align-items: stretch;
    }
    .table-footer .pagination {
        justify-content: center;
    }
    .table-footer .table-search {
        flex: 1 1 100%;
    }
}

.page-btn {
    padding: 0.75rem 1rem;
    background: 
        linear-gradient(135deg, rgba(2, 0, 8, 0.7) 0%, rgba(6, 2, 18, 0.6) 100%);
    border: 1px solid rgba(167, 139, 250, 0.3);
    border-radius: 8px;
    color: var(--text-primary);
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 500;
    min-width: 45px;
    text-align: center;
    /* Removed backdrop-filter - extremely expensive */
    position: relative;
}

.page-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at 50% 0%, rgba(124, 58, 237, 0.1) 0%, transparent 70%);
    border-radius: inherit;
    z-index: -1;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.page-btn:hover:not(.active):not(:disabled) {
    background: 
        linear-gradient(135deg, rgba(6, 2, 18, 0.9) 0%, rgba(10, 5, 26, 0.8) 100%);
    border-color: rgba(167, 139, 250, 0.5);
    transform: translate3d(0, -3px, 0) scale(1.05);
    box-shadow: 
        0 4px 15px rgba(167, 139, 250, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.page-btn:hover:not(.active):not(:disabled)::before {
    opacity: 1;
}

.page-btn.active {
    background: linear-gradient(135deg, #7c3aed 0%, #8b5cf6 100%);
    border-color: rgba(167, 139, 250, 0.6);
    box-shadow: 
        0 4px 20px rgba(167, 139, 250, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.15),
        0 0 0 2px rgba(167, 139, 250, 0.1);
    transform: scale(1.05);
}

.page-btn:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

.page-info {
    color: var(--text-secondary);
    font-size: 0.9rem;
    padding: 0 1rem;
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    z-index: 1002;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    /* Removed backdrop-filter - extremely expensive on full-screen overlay */
    /* Removed animation - keeping only transitions */
}

.modal.active {
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-content {
    background: 
        var(--modal),
        linear-gradient(135deg, rgba(2, 0, 8, 0.2) 0%, rgba(10, 5, 26, 0.15) 100%);
    border: 1px solid #333;
    border-radius: 16px;
    width: 90%;
    max-width: 500px;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    box-shadow: 
        0 15px 60px rgba(0, 0, 0, 0.9),
        inset 0 1px 0 rgba(167, 139, 250, 0.2);
    /* Removed animation - keeping only transitions */
    position: relative;
}

.modal-content::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(ellipse at 30% 30%, rgba(124, 58, 237, 0.15) 0%, transparent 70%),
        radial-gradient(ellipse at 70% 70%, rgba(139, 92, 246, 0.1) 0%, transparent 70%);
    filter: blur(40px);
    z-index: -1;
    border-radius: inherit;
}

.modal-header {
    padding: 1rem 1.5rem;
    border-bottom: 1px solid rgba(167, 139, 250, 0.15);
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-shrink: 0;
}

.modal-header h3 {
    font-size: 1.25rem;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.close {
    font-size: 2rem;
    color: var(--text-muted);
    cursor: pointer;
    transition: all 0.3s ease;
    line-height: 1;
}

.close:hover {
    color: var(--accent);
    transform: rotate(90deg);
}

.modal-body {
    padding: 1.5rem;
    overflow-y: auto;
    flex: 1;
    min-height: 0;
}

.form-group:last-child {
    margin-bottom: 0;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    color: var(--text-secondary);
    font-weight: 500;
    font-size: 0.9rem;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

.form-group input {
    width: 100%;
    padding: 0.875rem;
    background: 
        linear-gradient(135deg, rgba(2, 0, 8, 0.9) 0%, rgba(6, 2, 18, 0.8) 100%);
    border: 1px solid rgba(167, 139, 250, 0.3);
    border-radius: 8px;
    color: var(--text-primary);
    font-size: 1rem;
    transition: all 0.3s ease;
    /* Removed backdrop-filter - extremely expensive */
}

.form-group input:focus {
    outline: none;
    border-color: rgba(167, 139, 250, 0.5);
    box-shadow: 0 0 0 3px rgba(167, 139, 250, 0.15);
}

.warning-text {
    color: var(--warning);
    padding: 1rem;
    background: rgba(245, 158, 11, 0.1);
    border-left: 4px solid var(--warning);
    border-radius: 6px;
    margin: 0.75rem 0 1rem 0;
}

/* Manipulate Stats Grid - with labels */
.manipulate-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1em;
    margin-top: 1rem;
}

.manipulate-field {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

@media (max-width: 768px) {
    .manipulate-grid {
        grid-template-columns: 1fr;
    }
}

.manipulate-field label {
    display: block;
    color: var(--text-primary);
    font-weight: 500;
    font-size: 0.75rem;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

.manipulate-field input {
    width: 100%;
    padding: 0.5rem 0.75rem;
    border: 1px solid rgba(167, 139, 250, 0.3);
    border-radius: 8px;
    background: rgba(15, 10, 26, 0.5);
    color: var(--text-primary);
    font-size: 0.9rem;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.manipulate-field input:focus {
    outline: none;
    border-color: rgba(167, 139, 250, 0.6);
    box-shadow: 0 0 0 2px rgba(167, 139, 250, 0.2);
}

.manipulate-field input:read-only {
    opacity: 0.7;
    cursor: not-allowed;
    background: rgba(17, 24, 39, 0.3);
    border-left: 3px solid #666;
}

/* Reset Stats Checkbox List - matches manipulate grid */
.checkbox-list {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.5em;
    margin-top: 1rem;
}

.checkbox-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.5rem 0.75rem;
    background: rgba(15, 10, 26, 0.5);
    border: 1px solid rgba(167, 139, 250, 0.3);
    border-radius: 8px;
    transition: border-color 0.3s ease, background 0.3s ease;
    cursor: pointer;
}

.checkbox-item:hover {
    border-color: rgba(167, 139, 250, 0.5);
    background: rgba(15, 10, 26, 0.7);
}

.checkbox-item input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
    accent-color: #a855f7;
    margin: 0;
}

.checkbox-item label {
    flex: 1;
    color: var(--text-primary);
    font-weight: 500;
    font-size: 0.9rem;
    cursor: pointer;
    margin: 0;
}

@media (max-width: 768px) {
    .checkbox-list {
        grid-template-columns: 1fr;
    }
}

.modal-footer {
    padding: 1rem 1.5rem;
    border-top: 1px solid rgba(167, 139, 250, 0.15);
    display: flex;
    justify-content: flex-end;
    gap: 1rem;
    flex-shrink: 0;
}

.btn {
    padding: 0.875rem 1.5rem;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-cancel {
    background: 
        linear-gradient(135deg, rgba(2, 0, 8, 0.9) 0%, rgba(6, 2, 18, 0.8) 100%);
    color: var(--text-primary);
    border: 1px solid rgba(167, 139, 250, 0.3);
    /* Removed backdrop-filter - extremely expensive */
}

.btn-cancel:hover {
    background: 
        linear-gradient(135deg, rgba(6, 2, 18, 0.9) 0%, rgba(10, 5, 26, 0.8) 100%);
}

.btn-primary {
    background: linear-gradient(135deg, #7c3aed 0%, #8b5cf6 100%);
    color: white;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(167, 139, 250, 0.5);
}

.btn-danger {
    background: linear-gradient(135deg, var(--danger) 0%, #dc2626 100%);
    color: white;
}

.btn-danger:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(239, 68, 68, 0.4);
}

/* Player Name Links */
.player-name {
    transition: all 0.3s ease;
}

.player-name:hover {
    text-shadow: 0 0 8px currentColor;
    transform: translateX(2px);
}

/* Removed fadeIn and slideUp animations */

/* ========================================
   BURGER MENU FOR RESPONSIVE HEADER
   ======================================== */

/* Burger Menu Button - Hidden by default */
.burger-menu {
    display: none;
    flex-direction: column;
    justify-content: space-around;
    width: 30px;
    height: 25px;
    margin: 0.75rem auto;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
    z-index: 200;
    transition: all 0.3s ease;
}

.burger-menu:focus {
    outline: none;
}

.burger-line {
    width: 30px;
    height: 3px;
    background: linear-gradient(90deg, var(--primary), var(--accent));
    border-radius: 10px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    transform-origin: center;
    box-shadow: 0 0 10px rgba(167, 139, 250, 0.5);
}

/* Burger Menu Animation - Active State */
.burger-menu.active .burger-line:nth-child(1) {
    transform: translateY(11px) rotate(45deg);
}

.burger-menu.active .burger-line:nth-child(2) {
    opacity: 0;
    transform: translateX(-20px);
}

.burger-menu.active .burger-line:nth-child(3) {
    transform: translateY(-11px) rotate(-45deg);
}

/* Mobile Menu Container */
.mobile-menu {
    position: fixed;
    top: 0;
    left: -100%;
    width: 280px;
    height: 100vh;
    background: linear-gradient(180deg, 
        rgba(20, 20, 30, 0.98) 0%, 
        rgba(30, 30, 45, 0.98) 100%);
    /* Removed backdrop-filter - extremely expensive on mobile */
    border-right: 1px solid rgba(250, 211, 139, 0.2);
    box-shadow: 0 0 40px rgba(0, 0, 0, 0.5);
    transition: left 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 150;
    overflow: hidden;
    padding: 0;
}

.mobile-menu::after {
    content: "";
    position: absolute;
    top: -20px;
    left: -20px;
    width: calc(100% + 40px);
    height: calc(90% + 40px);
    background: radial-gradient(circle at 20% 20%, rgba(79, 67, 20, 0.15) 0%, transparent 40%), 
                radial-gradient(circle at 80% 80%, rgba(76, 62, 28, 0.12) 0%, transparent 40%), 
                radial-gradient(circle at 50% 10%, rgba(84, 76, 46, 0.08) 0%, transparent 50%), 
                radial-gradient(circle at 10% 90%, rgba(68, 58, 17, 0.1) 0%, transparent 50%), 
                radial-gradient(circle at 90% 50%, rgba(63, 61, 24, 0.09) 0%, transparent 50%);
    filter: blur(60px);
    z-index: -1;
    border-radius: inherit;
    /* Removed animation - keeping only transitions */
}

.mobile-menu.active {
    left: 0;
}

/* Mobile Menu Header with Title */
.mobile-menu-header {
    padding: 1.5rem 0 1rem 0;
    background: linear-gradient(135deg, 
        rgba(167, 139, 250, 0.15) 0%, 
        rgba(124, 58, 237, 0.12) 100%);
    border-bottom: 1px solid rgba(167, 139, 250, 0.2);
    position: relative;
    overflow: visible;
}

.mobile-menu-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(ellipse at 50% 50%, 
        rgba(167, 139, 250, 0.1) 0%, 
        transparent 70%);
    pointer-events: none;
}

.mobile-menu-title {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    gap: 0.75rem;
    font-size: 1.15rem;
    font-weight: 800;
    letter-spacing: 1px;
    text-transform: uppercase;
    position: relative;
    z-index: 1;
    background: linear-gradient(135deg, 
        #ffffff 0%, 
        #d5c38b 30%, 
        #ffe19f 50%, 
        #cfbd87 70%, 
        #ffffff 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    background-size: 200% auto;
    cursor: pointer;
    /* Removed animation - keeping only transitions */
}

.mobile-menu-title:hover {
    opacity: 0.8;
}

/* Mobile Server Dropdown */
.mobile-server-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: rgba(17, 24, 39, 0.98);
    backdrop-filter: blur(10px);
    border-radius: 0 0 12px 12px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 10;
}

.mobile-server-dropdown.active {
    max-height: 300px;
    opacity: 1;
    visibility: visible;
    overflow-y: auto;
}

.mobile-server-dropdown-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem 1.5rem;
    color: #e0e0e0;
    transition: all 0.2s ease;
    cursor: pointer;
    border-bottom: 1px solid rgba(167, 139, 250, 0.1);
}

.mobile-server-dropdown-item:last-child {
    border-bottom: none;
}

.mobile-server-dropdown-item:hover {
    background: rgba(167, 139, 250, 0.15);
    color: #ffffff;
}

.mobile-server-dropdown-item.active {
    background: linear-gradient(90deg, 
        rgba(124, 58, 237, 0.3) 0%, 
        rgba(167, 139, 250, 0.2) 100%);
    color: #ffffff;
    font-weight: 600;
}

.mobile-server-dropdown-item i {
    color: #a78bfa;
    font-size: 1rem;
}

.mobile-server-dropdown-item.active i {
    color: #f59e0b;
}

.mobile-menu-title i {
    font-size: 1.3rem;
    background: linear-gradient(135deg, 
        #ffffff 0%, 
        #d5c38b 30%, 
        #ffe19f 50%, 
        #cfbd87 70%, 
        #ffffff 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    background-size: 200% auto;
    /* Removed animation - keeping only transitions */
}

/* Mobile Menu Overlay */
.mobile-menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: rgba(0, 0, 0, 0.8);
    /* Removed backdrop-filter - extremely expensive on full-screen overlay */
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 140;
}

.mobile-menu-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* Mobile Menu Items */
.mobile-menu-item {
    padding: 1rem 1.5rem;
    margin: 0.5rem 1rem;
    border-radius: 12px;
    transition: all 0.3s ease;
}

.mobile-menu-item:first-of-type {
    margin-top: 1rem;
}

.mobile-menu-item:hover {
    background: rgba(167, 139, 250, 0.1);
    transform: translateX(5px);
}

.mobile-menu-item a {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: var(--text-primary);
    text-decoration: none;
    font-weight: 600;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.mobile-menu-item a i {
    font-size: 1.2rem;
    color: var(--primary);
    min-width: 24px;
    text-align: center;
}

.mobile-menu-item:hover a {
    color: var(--accent);
}

.mobile-menu-item:hover a i {
    transform: scale(1.1);
}

/* Mobile Menu Divider */
.mobile-menu-divider {
    height: 1px;
    background: linear-gradient(90deg, 
        transparent, 
        rgba(167, 139, 250, 0.3), 
        transparent);
    margin: 1rem 1.5rem;
}

/* Mobile Sidebar Content */
.mobile-sidebar-content {
    display: none;
    padding: 0 1.5rem 1.5rem;
}

.mobile-sidebar-content .sidebar-section {
    margin-bottom: 1.5rem;
}

.mobile-sidebar-content .sidebar-section h3 {
    font-size: 0.9rem;
    color: var(--accent);
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.mobile-sidebar-content .sidebar-select,
.mobile-sidebar-content .sidebar-input {
    width: 100%;
    padding: 0.75rem;
    background: rgba(0, 0, 0, 0.5);
    border: 1px solid rgba(167, 139, 250, 0.3);
    border-radius: 8px;
    color: var(--text-primary);
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
}

.reset-filters-btn {
    margin-top: 0.5rem;
    width: 100%;
}

@media (max-width: 1600px) {
    .main-container {
        padding: 2rem 3rem;
    }
    .server-connect-btn,
    .header-title-container {
        display:none!important;
    }
    
    /* Show burger menu */
    .burger-menu {
        display: flex;
    }

    /* Hide desktop menu items and title */
    .header-content .back-btn,
    .header-content .profile-container,
    .header-content .header-title {
        display: none;
    }

    /* Adjust header for burger menu only */
    .header-content {
        justify-content: center;
    }
}
/* Responsive Design */
@media (max-width: 1200px) {
    .content-wrapper {
        grid-template-columns: 280px 1fr;
    }
    
    /* Show burger menu */
    .burger-menu {
        display: flex;
    }

    /* Hide desktop menu items and title */
    .header-content .back-btn,
    .header-content .profile-container,
    .header-content .header-title {
        display: none;
    }

    /* Adjust header for burger menu only */
    .header-content {
        justify-content: center;
    }
}



/* Hide mobile-only elements on desktop */
.mobile-only {
    display: none !important;
}

/* Custom Page Input Modal - Uses default modal styling */

/* Dots button styling */
.page-btn.dots-btn {
    color: var(--text-muted);
    font-weight: bold;
}

.page-btn.dots-btn:hover {
    color: var(--text-primary);
    transform: scale(1.1);
}

/* Removed shake animation */

/* Custom Page Modal - Error state for input */
.form-group input.error {
    border-color: var(--danger);
    background: rgba(239, 68, 68, 0.1);
    /* Removed animation - keeping only transitions */
}

/* =================================
   COLLAPSIBLE ADMIN SIDEBAR
   ================================= */

/* Duplicate admin toggle button CSS removed */

/* Duplicate admin panel CSS removed */

/* removed duplicate admin-panel scrollbar styles (enhanced version kept below) */

/* Admin Panel Header */
/* removed duplicate admin-panel-header (enhanced header kept below) */


/* removed duplicate admin-close-btn (not used or redefined later) */

/* Admin Panel Content */
/* removed duplicate admin-panel content/section styles (enhanced versions kept) */
/* removed duplicate generic .admin-btn block (enhanced button styles kept below) */

/* Enhanced Admin Panel Features */

/* Modern Admin Toggle Button */
.admin-toggle-btn {
    position: fixed;
    top: 50%;
    right: 0;
    transform: translateY(-50%);
    background: linear-gradient(135deg, #667eea 0%, #5c4ba2 100%);
    color: white;
    padding: 1.2rem 0.5rem;
    border-top-left-radius: 16px;
    border-bottom-left-radius: 16px;
    cursor: pointer;
    z-index: 1001;
    box-shadow: 
        -6px 0 20px rgba(102, 126, 234, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
    /* Keep toggle animation in perfect sync with the panel */
    transition: right 0.5s cubic-bezier(0.4, 0, 0.2, 1),
                transform 0.5s cubic-bezier(0.4, 0, 0.2, 1),
                box-shadow 0.5s cubic-bezier(0.4, 0, 0.2, 1),
                background 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    writing-mode: vertical-lr;
    text-orientation: mixed;
    user-select: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    /* Removed backdrop-filter - extremely expensive */
    border: 1px solid rgba(255, 255, 255, 0.18);
    overflow: hidden;
    /* Ensure scaling does not nudge the button away from the panel edge */
    transform-origin: right center;
}

.admin-toggle-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.6s ease;
}

.admin-toggle-btn:hover {
    /* Avoid horizontal nudge so it remains glued to the panel edge */
    transform: translateY(-50%) scale(1.05);
    box-shadow: 
        -8px 0 25px rgba(102, 126, 234, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
    background: linear-gradient(135deg, #8b5cf6 0%, #a855f7 100%);
}

.admin-toggle-btn:hover::before {
    left: 100%;
}

.admin-toggle-text {
    font-size: 0.9rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    display: block;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.admin-toggle-icon {
    font-size: 1rem;
    transition: all 0.3s ease;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.2));
}

.admin-toggle-btn.active {
    right: 350px;
}

.admin-toggle-btn.active .admin-toggle-icon {
    transform: rotate(180deg) scale(1.1);
}

/* Enhanced Admin Panel */
.admin-panel {
    position: fixed;
    top: 0;
    right: -350px;
    width: 350px;
    height: 100vh;
    background: linear-gradient(135deg, #1f1e21 0%, #120c2c 100%);
    /* Removed backdrop-filter - extremely expensive on full-height panel */
    border-left: 2px solid rgba(167, 139, 250, 0.3);
    z-index: 1001;
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    overflow-y: auto;
    box-shadow: 
        -15px 0 40px rgba(0, 0, 0, 0.3),
        inset 1px 0 0 rgba(255, 255, 255, 0.1);
    overflow-x: hidden;
    /* Keep compositing stable so glow is visible without hover */
    will-change: transform;
}

.range-edit-btn {
    background: #ffe1898c;
    padding: 0.2em 0.35em;
    border: 1px solid #333;
    color: white;
    border-radius: 0.5em;
    transition: all 0.3s 
    cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.range-edit-btn:hover {
    cursor: pointer;
    transform: translateY(-1px) scale(1.02);
}
.admin-panel::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grain" width="100" height="100" patternUnits="userSpaceOnUse"><filter id="noise"><feTurbulence baseFrequency="0.9"/></filter><rect width="100%" height="100%" filter="url(%23noise)" opacity="0.03"/></pattern></defs><rect width="100%" height="100%" fill="url(%23grain)"/></svg>');
    pointer-events: none;
}

.admin-panel::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 200%;
    height: 50%;
    background: radial-gradient(circle at center, rgba(56, 20, 79, 0.5) 0%, transparent 60%);
    filter: blur(50px);
    z-index: 0;
    pointer-events: none;
    opacity: 0.6;
    /* Removed animation - keeping only transitions */
}

/* Ensure panel content renders above the glow */
.admin-panel > * {
    position: relative;
    z-index: 1;
}

.admin-panel.active {
    right: 0;
    /* Match transition duration with toggle button */
    /* Removed animation - keeping only transitions */
}

.admin-panel::-webkit-scrollbar {
    width: 8px;
}

.admin-panel::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.3);
}

.admin-panel::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, rgba(167, 139, 250, 0.5) 0%, rgba(124, 58, 237, 0.5) 100%);
    border-radius: 4px;
}

.admin-panel::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(135deg, rgba(167, 139, 250, 0.7) 0%, rgba(124, 58, 237, 0.7) 100%);
}

/* Enhanced Admin Panel Header */
.admin-panel-header {
    padding: 1.5rem;
    background: 
        linear-gradient(135deg, rgba(85, 58, 237, 0.8) 0%, rgba(113, 92, 246, 0.6) 100%),
        linear-gradient(45deg, transparent 30%, rgba(255, 255, 255, 0.1) 50%, transparent 70%);
    border-bottom: 2px solid rgba(167, 139, 250, 0.3);
    text-align: center;
    position: relative;
    overflow: hidden;
}

.admin-panel-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    /* Removed animation - keeping only transitions */
}

.admin-panel-header h3 {
    margin: 0;
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
}

.admin-panel-header h3 i {
    font-size: 1.6rem;
    /* Removed drop-shadow filter - heavy GPU cost */
}

/* Enhanced Admin Panel Content */
.admin-panel-content {
    padding: 2rem;
}

.admin-section {
    margin-bottom: 2.5rem;
    padding: 1.5rem;
    background:  linear-gradient(135deg, rgba(124, 58, 237, 0.2) 0%, rgba(139, 92, 246, 0.1) 100%);
    border-radius: 16px;
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

.admin-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(90deg, #667eea, #764ba2, #667eea);
}


/* Admin Section Colors */
.admin-section:nth-child(1) { background:  linear-gradient(135deg, rgba(58, 79, 237, 0.2) 0%, rgba(92, 131, 246, 0.1)100%); border: 1px solid rgba(139, 189, 250, 0.5); }
.admin-section:nth-child(1) h4 { color: #93c5fd; }
.admin-section:nth-child(1) h4 i { color: #3b82f6; background: linear-gradient(135deg, rgba(139, 161, 250, 0.2) 0%, rgba(58, 82, 237, 0.2) 100%); }
.admin-section:nth-child(1)::before { background: linear-gradient(90deg, #3b82f6, #60a5fa, #3b82f6); }

.admin-section:nth-child(2) { border: 1px solid rgba(180, 139, 250, 0.5);}
.admin-section:nth-child(2) h4 { color: #c084fc; }
.admin-section:nth-child(2) h4 i { color: #a855f7; }
.admin-section:nth-child(2)::before { background: linear-gradient(90deg, #a855f7, #c084fc, #a855f7); }

.admin-section:nth-child(3) { background:  linear-gradient(135deg, rgba(237, 58, 58, 0.2) 0%, rgba(246, 92, 92, 0.1)100%); border: 1px solid rgba(250, 139, 139, 0.5);}
.admin-section:nth-child(3) h4 { color: #fca5a5; }
.admin-section:nth-child(3) h4 i { color: #ef4444; background: linear-gradient(135deg, rgba(250, 139, 139, 0.2) 0%, rgba(237, 58, 58, 0.2) 100%); }
.admin-section:nth-child(3)::before { background: linear-gradient(90deg, #ef4444, #f87171, #ef4444); }

.admin-section:nth-child(4) { background:  linear-gradient(135deg, rgba(58, 237, 58, 0.2) 0%, rgba(118, 246, 92, 0.1)100%);border: 1px solid rgba(139, 250, 141, 0.5); }
.admin-section:nth-child(4) h4 { color: #a5fca6; }
.admin-section:nth-child(4) h4 i { color: #4def44; background: linear-gradient(135deg, rgba(139, 250, 148, 0.2) 0%, rgba(58, 237, 91, 0.2) 100%); }
.admin-section:nth-child(4)::before { background: linear-gradient(90deg, #44ef44, #71f881, #44ef47); }

.admin-section:hover {
    background: 
        rgba(255, 255, 255, 0.04),
        linear-gradient(135deg, rgba(124, 58, 237, 0.08) 0%, rgba(139, 92, 246, 0.05) 100%);
    border-color: rgba(167, 139, 250, 0.3);
    transform: translateY(-2px);
}

.admin-section:last-child {
    margin-bottom: 0;
}

.admin-section h4 {
    margin: 0 0 1.25rem 0;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-primary);
    display: flex;
    align-items: baseline;
    gap: 0.5em;
    text-transform: uppercase;
    letter-spacing: 1px;
    position: relative;
}

.admin-section h4 i {
    font-size: 0.9rem;
    padding: 0.5rem;
    background: linear-gradient(135deg, rgba(167, 139, 250, 0.2) 0%, rgba(124, 58, 237, 0.2) 100%);
    border-radius: 8px;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.2));
}

/* Enhanced Admin Buttons */
.admin-btn {
    width: 100%;
    padding: 0.5rem 1.25rem;
    margin-bottom: 1rem;
    background: linear-gradient(135deg, rgba(167, 139, 250, 0.15) 0%, rgba(124, 58, 237, 0.15) 100%);
    border: 1px solid rgba(167, 139, 250, 0.5);
    border-radius: 12px;
    color: var(--text-primary);
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    align-items: center;
    justify-content: start;
    gap: 0.75rem;
    text-align: left;
    position: relative;
    overflow: hidden;
    /* Removed backdrop-filter - extremely expensive */
}

.admin-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    transition: left 0.6s ease;
}

.admin-btn:hover {
    background: linear-gradient(135deg, rgba(167, 139, 250, 0.25) 0%, rgba(124, 58, 237, 0.25) 100%);
    border-color: rgba(167, 139, 250, 0.7);
    transform: translateX(8px) scale(1.02);
    box-shadow: 
        0 8px 25px rgba(124, 58, 237, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.admin-btn:hover::before {
    left: 100%;
}

.admin-btn:active {
    transform: translateX(8px) scale(0.98);
}

.admin-btn:last-child {
    margin-bottom: 0;
}

.admin-btn i {
    font-size: 1.1rem;
    opacity: 0.9;
    padding: 0.5rem;
    border-radius: 8px;
    transition: all 0.3s ease;
}


/* Enhanced Admin Button Variants */
.admin-btn.danger {
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.15) 0%, rgba(220, 38, 38, 0.15) 100%);
    border-color: rgba(239, 68, 68, 0.5);
}

.admin-btn.danger:hover {
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.25) 0%, rgba(220, 38, 38, 0.25) 100%);
    border-color: rgba(239, 68, 68, 0.7);
    box-shadow: 
        0 8px 25px rgba(239, 68, 68, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
}


.admin-btn.individual {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.15) 0%, rgba(37, 99, 235, 0.15) 100%);
    border-color: rgba(59, 130, 246, 0.5);
}

.admin-btn.individual:hover {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.25) 0%, rgba(37, 99, 235, 0.25) 100%);
    border-color: rgba(59, 130, 246, 0.7);
    box-shadow: 
        0 8px 25px rgba(59, 130, 246, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.admin-btn.check {
    background: linear-gradient(135deg, rgba(59, 246, 59, 0.15) 0%, rgba(44, 235, 37, 0.15) 100%);
    border-color: rgba(62, 246, 59, 0.5);
}

.admin-btn.check:hover {
    background: linear-gradient(135deg, rgba(59, 246, 65, 0.25) 0%, rgba(37, 235, 44, 0.25) 100%);
    border-color: rgba(59, 246, 59, 0.7);
    box-shadow: 
        0 8px 25px rgba(59, 246, 59, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
}



/* Active state for admin buttons */
.admin-btn.active {
    background: linear-gradient(135deg, rgba(34, 197, 94, 0.2) 0%, rgba(21, 128, 61, 0.2) 100%);
    border-color: rgba(34, 197, 94, 0.5);
    box-shadow: 
        0 0 0 2px rgba(34, 197, 94, 0.3),
        0 8px 25px rgba(34, 197, 94, 0.2);
}


/* Enhanced Modal Styling */
/* Removed .modal backdrop-filter - extremely expensive on full-screen overlay */

.modal-content {
    border: 1px solid #333;
    box-shadow: 
        0 25px 80px rgba(0, 0, 0, 0.5),
        inset 0 1px 0 rgba(167, 139, 250, 0.2);
    /* Removed animation - keeping only transitions */
}

.modal-header {
    background: 
        linear-gradient(135deg, rgba(124, 58, 237, 0.3) 0%, rgba(139, 92, 246, 0.2) 100%),
        linear-gradient(45deg, transparent 30%, rgba(255, 255, 255, 0.05) 50%, transparent 70%);
}

/* Removed all animations - adminPanelSlide, headerShimmer, sectionGlow, modalSlide */

/* Enhanced Modal Content Styles */
.loading-message {
    text-align: center;
    padding: 2rem;
    color: var(--text-secondary);
}

.loading-message i {
    font-size: 2rem;
    margin-bottom: 1rem;
    color: var(--primary);
}

.backup-sections {
    display: grid;
    gap: 2rem;
}

.backup-section {
    padding: 1.5rem;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(167, 139, 250, 0.2);
    border-radius: 12px;
    transition: all 0.3s ease;
}

.backup-section:hover {
    background: rgba(255, 255, 255, 0.04);
    border-color: rgba(167, 139, 250, 0.3);
}

.backup-section h4 {
    margin: 0 0 1rem 0;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1.1rem;
}

.backup-section h4 i {
    color: var(--primary);
}

.backup-section p {
    margin-bottom: 1.5rem;
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.form-file-input {
    width: 100%;
    padding: 0.75rem;
    background: rgba(0, 0, 0, 0.3);
    border: 2px dashed rgba(167, 139, 250, 0.3);
    border-radius: 8px;
    color: var(--text-primary);
    font-size: 0.9rem;
    transition: all 0.3s ease;
    cursor: pointer;
}

.form-file-input:hover {
    border-color: rgba(167, 139, 250, 0.5);
    background: rgba(0, 0, 0, 0.4);
}

.form-file-input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(124, 58, 237, 0.15);
}

/* System Stats Styling */
.stats-grid-modal {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin: 1.5rem 0;
}

.stat-item {
    padding: 1rem;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(167, 139, 250, 0.2);
    border-radius: 8px;
    text-align: center;
}

.stat-item-value {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 0.5rem;
}

.stat-item-label {
    font-size: 0.8rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Health Check Styling */
.health-check-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.75rem 1rem;
    margin-bottom: 0.5rem;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(167, 139, 250, 0.1);
    border-radius: 8px;
    transition: all 0.3s ease;
}

.health-check-item:hover {
    background: rgba(255, 255, 255, 0.04);
}

.health-check-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-primary);
}

.health-status {
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.health-status.good {
    background: rgba(34, 197, 94, 0.2);
    color: #4ade80;
}

.health-status.warning {
    background: rgba(245, 158, 11, 0.2);
    color: #fbbf24;
}

.health-status.error {
    background: rgba(239, 68, 68, 0.2);
    color: #f87171;
}

/* Success/Error Messages */
.success-message, .error-message {
    padding: 1rem;
    border-radius: 8px;
    margin: 1rem 0;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-weight: 500;
}

.success-message {
    background: rgba(34, 197, 94, 0.1);
    border: 1px solid rgba(34, 197, 94, 0.3);
    color: #4ade80;
}

.error-message {
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: #f87171;
}

.success-message i, .error-message i {
    font-size: 1.2rem;
}

/* Progress Bar */
.progress-bar {
    width: 100%;
    height: 8px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    overflow: hidden;
    margin: 1rem 0;
}

.progress-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary), var(--primary-light));
    border-radius: 4px;
    transition: width 0.3s ease;
    /* Removed animation - keeping only transitions */
}

/* Removed progressPulse animation */

/* Enhanced Notification System */
.notification-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 2000;
    max-width: 400px;
}

.notification {
    padding: 1rem 1.25rem;
    margin-bottom: 0.75rem;
    border-radius: 12px;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    /* Removed backdrop-filter - extremely expensive */
    border: 1px solid rgba(255, 255, 255, 0.18);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    /* Removed animation - keeping only transitions */
    transition: all 0.3s ease;
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.notification::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: currentColor;
}

.notification:hover {
    transform: translateX(-5px) scale(1.02);
}

.notification.success {
    background: rgba(16, 96, 46, 0.5);
    color: #4ade80;
    border-color: rgba(34, 197, 94, 0.3);
}

.notification.error {
    background: rgba(131, 38, 38, 0.5);
    color: #f87171;
    border-color: rgba(239, 68, 68, 0.3);
}

.notification.warning {
    background: rgba(145, 94, 7, 0.1);
    color: #fbbf24;
    border-color: rgba(245, 158, 11, 0.3);
}

.notification.info {
    background: rgba(21, 47, 90, 0.5);
    color: #60a5fa;
    border-color: rgba(59, 130, 246, 0.3);
}

.notification-icon {
    font-size: 1.25rem;
    flex-shrink: 0;
}

.notification-content {
    flex: 1;
}

.notification-title {
    font-weight: 600;
    margin-bottom: 0.25rem;
    font-size: 0.95rem;
}

.notification-message {
    font-size: 0.85rem;
    opacity: 0.9;
    line-height: 1.4;
}

.notification-close {
    background: none;
    border: none;
    color: currentColor;
    cursor: pointer;
    font-size: 1.1rem;
    padding: 0.25rem;
    border-radius: 4px;
    transition: all 0.2s ease;
    opacity: 0.7;
}

.notification-close:hover {
    opacity: 1;
    background: rgba(255, 255, 255, 0.1);
}

/* Removed notificationSlide animation */

/* Loading Overlay */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    /* Removed backdrop-filter - extremely expensive performance cost */
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1999;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.loading-overlay.active {
    opacity: 1;
    visibility: visible;
}

.loading-content {
    background: 
        linear-gradient(135deg, rgba(15, 10, 26, 0.98) 0%, rgba(18, 12, 44, 0.95) 100%);
    padding: 2rem 3rem;
    border-radius: 16px;
    text-align: center;
    border: 2px solid rgba(167, 139, 250, 0.3);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.loading-spinner {
    font-size: 2.5rem;
    color: var(--primary);
    margin-bottom: 1rem;
    /* Removed animation - keeping only transitions */
}

.loading-text {
    color: var(--text-primary);
    font-size: 1.1rem;
    font-weight: 500;
    margin-bottom: 0.5rem;
}

.loading-subtext {
    color: var(--text-secondary);
    font-size: 0.9rem;
    font-family: 'Courier New', monospace;
    line-height: 1.6;
    max-width: 600px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Removed spin animation */

/* Enhanced Button States */
.btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none !important;
}

.btn.loading {
    position: relative;
    pointer-events: none;
}

.btn.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 16px;
    height: 16px;
    margin: -8px 0 0 -8px;
    border: 2px solid transparent;
    border-top-color: currentColor;
    border-radius: 50%;
    /* Removed animation - keeping only transitions */
}

/* Removed btnSpin animation */

/* Tooltip System */
.tooltip {
    position: relative;
    cursor: help;
}

.tooltip::before {
    content: attr(data-tooltip);
    position: absolute;
    bottom: 125%;
    left: 50%;
    transform: translateX(-50%);
    padding: 0.5rem 0.75rem;
    background: rgba(0, 0, 0, 0.9);
    color: white;
    font-size: 0.75rem;
    border-radius: 6px;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 1000;
    pointer-events: none;
}

.tooltip::after {
    content: '';
    position: absolute;
    bottom: 118%;
    left: 50%;
    transform: translateX(-50%);
    border: 4px solid transparent;
    border-top-color: rgba(0, 0, 0, 0.9);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.tooltip:hover::before,
.tooltip:hover::after {
    opacity: 1;
    visibility: visible;
}

/* Enhanced Stats Cards in Modal */
.modal-stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 1rem;
    margin: 1.5rem 0;
}

.modal-stat-card {
    background: 
        linear-gradient(135deg, rgba(167, 139, 250, 0.1) 0%, rgba(124, 58, 237, 0.05) 100%);
    border: 1px solid rgba(167, 139, 250, 0.2);
    border-radius: 12px;
    padding: 1.25rem 1rem;
    text-align: center;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.modal-stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, var(--primary), var(--primary-light));
}

.modal-stat-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(124, 58, 237, 0.2);
}

.modal-stat-icon {
    font-size: 1.5rem;
    color: var(--primary);
    margin-bottom: 0.75rem;
}

.modal-stat-value {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 0.25rem;
}

.modal-stat-label {
    font-size: 0.8rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .admin-panel {
        width: 300px;
        right: -300px;
    }
    
    .admin-toggle-btn.active {
        right: 300px;
    }
    
    .admin-panel-content {
        padding: 1.5rem 1rem;
    }
    
    .admin-section {
        padding: 1.25rem;
        margin-bottom: 2rem;
    }
}

@media (max-width: 480px) {
    .admin-toggle-btn {
        padding: 0.75rem 0.5rem;
        /* Match the panel transition exactly */
        transition: right 0.5s cubic-bezier(0.4, 0, 0.2, 1),
                    transform 0.5s cubic-bezier(0.4, 0, 0.2, 1),
                    box-shadow 0.5s cubic-bezier(0.4, 0, 0.2, 1),
                    background 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    }
    
    .admin-toggle-text {
        font-size: 0.7rem;
    }
    
    .admin-panel-header h3 {
        font-size: 1.1rem;
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .admin-section h4::after {
        display: none;
    }
    

    .mobile-menu-item {
        padding: 0.85rem 1.25rem;
        margin: 0.4rem 0.85rem;
    }

    .mobile-menu-item a {
        font-size: 0.95rem;
    }
}


@media (max-width: 480px) {
    .modal-content {
        width: 100%;
        max-height: 95vh;
        border-radius: 0;
    }
    
    .modal-header {
        padding: 0.75rem 0.875rem;
    }
    
    .modal-header h3 {
        font-size: 0.95rem;
    }
    
    .modal-body {
        padding: 0.875rem;
    }
    
    .modal-footer {
        padding: 0.75rem 0.875rem;
        gap: 0.5rem;
    }
    
    .modal-footer .btn {
        padding: 0.65rem 1rem;
        font-size: 0.8rem;
    }
    
    .form-columns {
        gap: 0.75rem;
    }
    
    .form-column h4 {
        font-size: 0.9rem;
        margin-bottom: 0.75rem;
    }
    
    .form-column input {
        padding: 0.5rem 0.65rem;
        font-size: 0.8rem;
    }
    
    .manip-field input {
        padding: 0.45rem 0.6rem;
        font-size: 0.75rem;
    }
    
    .large-modal .modal-content {
        max-height: 100vh;
    }
}

/* Index Page Responsive Design */
@media (max-width: 1200px) {
    .stats-section {
        grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    }
    
    .content-wrapper {
        gap: 1.5rem;
    }
}

@media (max-width: 992px) {
    
    .mobile-menu {
        width: 350px!important;
    }
    .stats-section {
        grid-template-columns: repeat(2, 1fr);
        margin: 1rem 0 2.5rem 0;
    }
    
    .stat-card {
        padding: 1.25rem 1rem;
    }
    .stat-card {
        padding: 1rem 0.875rem;
        flex-direction: row;
        align-items: center;
        gap: 1rem;
    }
    .stat-value {
        font-size: 1.5rem;
    }
    .content-wrapper {
        flex-direction: column;
        gap: 1.5rem;
    }
    
    .sidebar-container {
        flex: 1 1 100%;
        width: 100%;
    }
    
    .table-container {
        flex: 1 1 100%;
    }
}

@media (max-width: 1600px) {
    /* Hide desktop sidebar, show in mobile menu */
    .sidebar-container {
        display: none;
    }
    
    .mobile-sidebar-content {
        display: block;
    }
    
    .mobile-menu {
        width: 500px;
        overflow-y: auto;
    }

    .stats-section {
        grid-template-columns: repeat(auto-fit, minmax(195px, 1fr));
    }
}

@media (max-width: 1300px) {
    .col-name {
        min-width: 250px!important;
    }
    .player-name {
        max-width: 150px!important;
    }
}

@media (max-width: 1200px) {
    .player-new img,
    .player-steam img {
        display:none;
    }

    .col-name {
        min-width: 200px!important;
    }
    .player-name {
        max-width: 100px!important;
    }

    .stats-section {
        grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    }

    .mobile-menu {
        width: 400px;
    }

    .stat-card {
        padding: 1rem 0.875rem;
        flex-direction: row;
        align-items: center;
        gap: 1rem;
    }
    
    .stat-icon {
        font-size: 1.75rem;
        margin-bottom: 0;
    }
    
    .stat-content {
        text-align: left;
    }
    
    .stat-value {
        font-size: 1.5rem;
    }
    
    .stat-label {
        font-size: 0.8rem;
    }
}


@media (max-width: 576px) {
    .modal-content {
        width: 98%;
        border-radius: 12px;
    }
    
    .modal-header {
        padding: 0.875rem 1rem;
    }
    
    .modal-header h3 {
        font-size: 1rem;
    }
    
    .modal-close {
        width: 1.75rem;
        height: 1.75rem;
        font-size: 1.25rem;
    }
    
    .modal-body {
        padding: 1rem;
    }
    
    .modal-footer {
        padding: 0.875rem 1rem;
        gap: 0.75rem;
    }
    
    .modal-footer .btn {
        padding: 0.75rem 1.25rem;
        font-size: 0.85rem;
        flex: 1 1 100%;
    }
    
    .form-columns {
        gap: 1rem;
    }
    
    .form-column h4 {
        font-size: 0.95rem;
    }
    
    .form-column input {
        flex: 1 1 100%;
        font-size: 0.85rem;
        padding: 0.6rem 0.75rem;
    }
    
    .manip-group {
        grid-template-columns: 1fr;
        gap: 0.75rem;
    }
    
    .manip-field {
        font-size: 0.8rem;
    }
    
    .modal-stat-card {
        padding: 1rem 0.75rem;
    }
    
    .modal-stat-value {
        font-size: 1.25rem;
    }
    
    .modal-stat-label {
        font-size: 0.75rem;
    }
    .player-name {
        max-width: 150px;
    }
    .stat-card {
        padding: 0.875rem 0.75rem;
    }
    
    .stat-icon {
        font-size: 1.5rem;
    }
    
    .stat-value {
        font-size: 1.25rem;
    }
    
    .stat-label {
        font-size: 0.75rem;
    }
    
    .sidebar {
        padding: 1rem 0.875rem;
        border-radius: 12px;
    }
    
    .sidebar-section {
        margin-bottom: 0.875rem;
    }
    
    .sidebar-section h3 {
        font-size: 0.8rem;
        margin-bottom: 0.625rem;
    }
    
    .search-box input,
    .sidebar-select,
    .sidebar-input {
        padding: 0.625rem 0.75rem;
        font-size: 0.85rem;
    }
    
    .search-btn {
        padding: 0.625rem 0.875rem;
    }
    
    .table-container {
        border-radius: 10px;
    }
    
    .table-header {
        margin-bottom: 0.875rem;
    }
    
    .table-controls {
        gap: 0.625rem;
    }
    
    .sort-btn,
    .weapon-btn {
        padding: 0.5rem 0.875rem;
        font-size: 0.8rem;
    }

    
    .players-table th,
    .players-table td {
        padding: 0.625rem 0.375rem;
    }
    
    /* Stack table cells on very small screens */
    .players-table {
        display: flex;
    }

    .players-table thead {
        max-width: 20%;
    }

    .players-table thead tr {
        display: flex;
        flex-direction: column;
    }

    .players-table thead th {
        display: flex;
        flex-direction: column;
    }

    .players-table td {
        display: flex;
        flex-direction: column;
    }
    
    .pagination {
        gap: 0.375rem;
    }
    
    .page-btn {
        min-width: 32px;
        height: 32px;
        padding: 0.375rem;
        font-size: 0.8rem;
    }
}

@media (max-width: 480px) {
    .stat-card {
        padding: 0.75rem 0.625rem;
    }
    
    .stat-icon {
        font-size: 1.35rem;
    }
    
    
    .sidebar {
        padding: 0.875rem 0.75rem;
    }
}

/* Insert Player Modal Styles */
.large-modal .modal-content {
    width: 90%;
    max-width: 800px;
    max-height: 90vh;
    overflow-y: auto;
}

.insert-player-form {
    padding: 0.5rem 0;
}

.form-columns {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.form-column h4 {
    color: var(--text-primary);
    margin: 0 0 1rem 0;
    padding: 0.5rem 0;
    border-bottom: 2px solid rgba(167, 139, 250, 0.3);
    font-size: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.form-column h4 i {
    color: #a855f7;
}


.form-column label {
    display: block;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
    font-weight: 500;
    font-size: 0.9rem;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

.form-column { display: flex; flex-wrap: wrap; gap: 1em; }
.form-column input {
    flex: 1 1 40%;
    padding: 0.5rem 0.75rem;
    border: 1px solid rgba(167, 139, 250, 0.3);
    border-radius: 8px;
    background: rgba(15, 10, 26, 0.5);
    color: var(--text-primary);
    font-size: 0.9rem;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.form-column input#new-player-name {
    flex: 1 1 100%;
}

.form-column input:focus {
    outline: none;
    border-color: rgba(167, 139, 250, 0.6);
    box-shadow: 0 0 0 2px rgba(167, 139, 250, 0.2);
}

.form-column input:required {
    border-left: 3px solid #a855f7;
}

.form-advanced-section {
    border-top: 1px solid rgba(167, 139, 250, 0.2);
    padding-top: 1.5rem;
    margin-top: 1.5rem;
}

.form-advanced-section h4 {
    color: var(--text-primary);
    margin: 0 0 1rem 0;
    font-size: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.form-advanced-section h4 i {
    color: #a855f7;
}

.advanced-fields-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
}

.info-text {
    background: rgba(59, 130, 246, 0.1);
    border: 1px solid rgba(59, 130, 246, 0.3);
    border-radius: 8px;
    padding: 1rem;
    margin-bottom: 1.5rem;
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.btn-secondary {
    background: rgba(107, 114, 128, 0.2);
    border: 1px solid rgba(107, 114, 128, 0.5);
    color: var(--text-secondary);
}

.btn-secondary:hover {
    background: rgba(107, 114, 128, 0.3);
    border-color: rgba(107, 114, 128, 0.7);
}

/* ==========================================================
   Anti-blur for hover transforms
   ----------------------------------------------------------
   When elements animate with transform/opacity, Windows can
   soften fonts due to layer promotion. Pre-promote common
   hover targets and stabilize rasterization so text stays
   crisp while still allowing the animations.
   ========================================================== */

/* Pre-promote frequently animated components */
.back-btn,
.refresh-btn,
.reset-top-btn,
.reset-filters-btn,
.page-btn,
.stat-card,
.quick-stat,
.admin-btn,
.admin-section,
.rank-badge,
.skill-badge,
.weapon-item,
.notification,
.modal-stat-card,
.players-table th.sortable,
.players-table tbody tr,
.players-table td p.stats,
.player-name {
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
    transform: translateZ(0);
    will-change: transform;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Ensure header labels and icons remain crisp during hover */
.players-table th.sortable span,
.players-table th.sortable i,
.players-table td,
.players-table td p.stats,
.admin-btn,
.page-btn {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
}

/* Provide a stable base transform for elements that scale */
.stat-card,
.action-btn,
.admin-btn,
.page-btn,
.rank-badge,
.skill-badge,
.players-table td p.stats,
.player-name {
    transform: translate3d(0, 0, 0);
}

/* ==========================================================
   RESPONSIVE TABLE - MOBILE VIEW
   ----------------------------------------------------------
   Transform table into card layout with headers on left,
   values on right for screens below 768px
   ========================================================== */

@media (max-width: 992px) {

    .content-wrapper {
        grid-template-columns: 1fr;
    }
    
    .sidebar {
        position: static;
    }
    
}

/* Make table scrollable at 1100px */
@media (max-width: 1100px) {
    .table-wrapper {
        max-height: 450px!important;
        overflow-y: auto!important;
    }
    
    .table-wrapper.no-scroll {
        overflow-y: auto!important;
    }
    .mobile-only {
        display: block !important;
    }
}

@media (max-width: 768px) {
 .table-wrapper {
        max-height: 450px!important;
        overflow-y: auto!important; /* Always scrollable regardless of items-per-page */
    }
    
    /* Override no-scroll class on mobile - always show scrollbar */
    .table-wrapper.no-scroll {
        overflow-y: auto!important;
    }
/* Show mobile-only elements */

    
    .main-container {
        padding: 1rem;
    }
    
    .header-content {
        flex-direction: column;
        gap: 1rem;
    }
    
    .header-title {
        font-size: 1.25rem;
    }
    
    .stats-section {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .players-table {
        font-size: 0.8rem;
    }
    
    .players-table th,
    .players-table td {
        padding: 0.75rem 0.5rem;
    }
    
    .pagination {
        flex-wrap: wrap;
    }
    
    /* Visual feedback for clickable rows on mobile */
    .players-table tbody tr:active {
        background: rgba(167, 139, 250, 0.15) !important;
    }
  .admin-panel {
        width: 70%;
        right: -500px;
    }
    
    .admin-toggle-btn {
        /* Match the panel transition exactly */
        transition: right 0.5s cubic-bezier(0.4, 0, 0.2, 1),
                    transform 0.5s cubic-bezier(0.4, 0, 0.2, 1),
                    box-shadow 0.5s cubic-bezier(0.4, 0, 0.2, 1),
                    background 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    }
    
    .admin-toggle-btn.active {
        right: calc(70% - 0px);
    }
    
    .admin-toggle-text {
        font-size: 0.8rem;
    }
    
    .admin-panel-header {
        padding: 1.5rem 1rem;
    }
    
    .admin-panel-header h3 {
        font-size: 1.2rem;
    }

    .admin-section h4 {
        display: flex;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        text-align: center;
    }
    .admin-btn i {
        font-size: 0.85rem;
    }
    .admin-btn span {
        font-size: 0.8rem;
    }
    .admin-panel-content {
        padding: 1rem;
    }
    
    .admin-section {
        padding: 1rem;
        margin-bottom: 1.5rem;
    }
    
    .admin-btn {
        padding: 0.5rem 1rem;
        font-size: 0.75rem;
        display: flex;
        flex-direction: column;
        gap: 0.5rem;
    }

    .modal-content {
        width: 95%;
        max-width: 95%;
        padding: 0;
    }
    
    .modal-header {
        padding: 1rem 1.25rem;
    }
    
    .modal-header h3 {
        font-size: 1.1rem;
    }
    
    .modal-body {
        padding: 1.25rem;
    }
    
    .modal-footer {
        padding: 1rem 1.25rem;
        flex-wrap: wrap;
    }
    
    .large-modal .modal-content {
        max-width: 95%;
        max-height: 85vh;
    }
    
    .form-columns {
        grid-template-columns: 1fr;
        gap: 1.25rem;
    }
    .stats-section {
        grid-template-columns: 1fr;
    }
    
    .stat-card {
        padding: 1rem 0.875rem;
        flex-direction: row;
        align-items: center;
        gap: 1rem;
    }
    
    .stat-icon {
        font-size: 1.75rem;
        margin-bottom: 0;
    }
    
    .stat-content {
        text-align: left;
    }
    
    .stat-value {
        font-size: 1.5rem;
    }
    
    .stat-label {
        font-size: 0.8rem;
    }

    .form-columns {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .large-modal .modal-content {
        width: 95%;
        margin: 1rem auto;
    }
    
    .advanced-fields-grid {
        grid-template-columns: 1fr;
    }
    .table-container {
        padding: 1rem 0.75rem;
        border-radius: 12px;
    }
    
    .table-header h2 {
        font-size: 1.5rem;
    }
    
    .table-controls {
        flex-direction: column;
        gap: 0.75rem;
        align-items: stretch;
    }
    
    .sort-group,
    .weapon-sort {
        flex-direction: column;
        gap: 0.5rem;
        width: 100%;
    }
    
    .sort-label {
        font-size: 0.85rem;
    }
    
    .sort-btn,
    .weapon-btn {
        padding: 0.6rem 1rem;
        font-size: 0.85rem;
    }
    
    .players-table {
        font-size: 0.8rem;
    }
    
    .players-table th,
    .players-table td {
        padding: 0.75rem 0.5rem;
    }
    
    .pagination {
        flex-wrap: wrap;
        gap: 0.5rem;
    }
    
    .page-btn {
        min-width: 36px;
        height: 36px;
        padding: 0.5rem;
        font-size: 0.85rem;
    }
    
    /* Sidebar adjustments for mobile */
    .content-wrapper {
        flex-direction: column;
    }
    
    .sidebar-container {
        width: 100%;
        margin-bottom: 1.5rem;
    }
    
    /* Main content takes full width */
    .main-content {
        flex: 1 1 100%;
    }
}

@media (max-width: 1100px), (max-width: 768px) {
    .player-new img,
    .player-steam img {
        display:block;
    }

    .col-name {
        min-width: 250px!important;
    }
    .player-name {
        max-width: 150px!important;
    }    
     .table-wrapper {
        border-radius: 0;
    }

    .table-header {
        margin-top: 0.5rem;
        margin-bottom: 1.5rem;
        flex-direction: column;
    }

    .table-header div {
        margin: 1rem auto 0 auto!important;
    }

    /* Animations disabled for rank columns */

    /* Hide table headers on mobile */
    .players-table thead {
        display: none;
    }
    /* Transform table structure */
    .players-table,
    .players-table tbody,
    .players-table tr,
    .players-table td {
        display: block;
        width: 100%;
    }
    
    /* Each row becomes a card */
    .players-table tbody tr {
        margin-bottom: 1.5rem;
        border-radius: 10px;
        padding: 0;
        text-transform: uppercase;
        border: 1px solid rgb(139, 121, 71);
        box-shadow: 0 1em 1em 0 rgba(0, 0, 0, 0.2);
        background: 
            var(--gradient-2);
        overflow: hidden;
    }

    .players-table tbody tr.offline {
        border-left: 4px solid rgb(229, 69, 69);
    }

    .players-table tbody tr.online {
        border-left: 4px solid rgb(81, 190, 38);
    }

    .players-table tbody tr:hover {
        background: 
            linear-gradient(135deg, rgba(167, 139, 250, 0.12) 0%, rgba(124, 58, 237, 0.08) 100%),
            var(--gradient-2);
    }
    

    /* Each cell becomes a row with label on left, value on right */
    .players-table td {
        display: flex;
        font-size: 1rem;
        font-weight: 900;
        justify-content: start;
        flex-direction: row;
        align-items: center;
        text-align: left;
        padding: 0 1rem 0 0 !important;
        min-height: auto;
        background: rgba(0, 0, 0, 0.1);
        height: 40px;
    }

    td.col-name {
        justify-content: center;
    }

    .player-info {
        text-transform: none;
        flex-wrap: wrap;
        justify-content: flex-start;
        flex: 1 1 0;
        min-width: 0;
    }
    
    .player-name {
        flex-shrink: 1;
        min-width: 0;
    }
    
    .player-avatar,
    .player-flag,
    .player-steam,
    .player-new {
        flex-shrink: 0;
    }
    
    /* Hide flag when space is tight (below 500px) */
    @media (max-width: 400px) {
        .player-flag {
            display: none;
        }
    }
    
    /* Hide avatar when space gets even tighter (below 380px) */
    @media (max-width: 350px) {
        .player-avatar {
            display: none;
        }
    }
    
    .players-table td:nth-child(odd) {
        background: rgba(0, 0, 0, 0);
    }

    .players-table td:nth-child(9) {
        border-bottom: none;
    }

    .players-table td:last-child {
        padding: 0!important;;
    }
    
    /* Add labels before each cell */
    .players-table td::before {
        content: attr(data-label);
        font-weight: 700;
        font-size: 0.7rem;
        color: white;
        letter-spacing: 0.5px;
        flex-shrink: 0;
        margin-right: 1rem;
        min-width: 90px;
        background: linear-gradient(to right, rgba(119, 114, 128, 1) 0%, rgba(48, 33, 102, 1) 175%);
        text-align: center;
        padding: 0.75rem 0;
        height: 20px;
    }
    
    /* Weapon column: show weapon icon instead of text on mobile */
    .players-table td.col-weapon::before {
        content: '';
        background-image: var(--weapon-icon-url), linear-gradient(to right, rgba(119, 114, 128, 1) 0%, rgba(48, 33, 102, 1) 175%);
        background-size: 45px auto, 100%;
        background-repeat: no-repeat, no-repeat;
        background-position: center, 0 0;
        height: 15px;
        display: flex;
        align-items: center;
        justify-content: center;
    }
    
    /* Padding animations disabled for action buttons */
    
    /* Removed reducePadding and increasePadding animations */

    
    .table-wrapper::before {
        display:none;
    }
    
    .players-table td.col-rank::before {
        content: "#";
    }
    
    /* XP cell */
    .players-table td.col-xp::before {
        content: "XP";
    }
    
    /* Name cell */
    .players-table td.col-name::before {
        content: "Player";
    }
    
    
    /* Kills cell */
    .players-table td.col-kills::before {
        content: "Kills";
    }
    
    /* Deaths cell */
    .players-table td.col-deaths::before {
        content: "Deaths";
    }
    
    /* K/D Ratio cell */
    .players-table td.col-kdr::before {
        content: "K/D Ratio";
    }
    
    /* Headshots cell */
    .players-table td.col-hs::before {
        content: "Headshots";
    }
    
    
    /* Skill cell */
    .players-table td.col-skill::before {
        content: "Skill";
    }
    
    /* Rank Badge cell */
    .players-table td.col-rank-badge::before {
        content: "Rank";
    }
    
    /* Actions cell - hidden by default on mobile */
    .players-table td.col-actions {
        display: block;
        border-top: unset;
        overflow: hidden;
        width: 100%;
        height: 0;
        padding: 0;
        visibility: hidden;
        transition: height 0.4s cubic-bezier(0.4, 0, 0.2, 1),
                    padding 0.4s cubic-bezier(0.4, 0, 0.2, 1),
                    visibility 0s linear 0.4s;
    }
    
    /* Show actions cell when it has the 'show' class */
    .players-table td.col-actions.show {
        display: block !important;
        height: 40px;
        visibility: visible;
        padding: 0.5rem 0;
        transition: height 0.4s cubic-bezier(0.4, 0, 0.2, 1),
                    padding 0.4s cubic-bezier(0.4, 0, 0.2, 1),
                    visibility 0s linear 0s;
    }
    
    /* Hiding animation */
    .players-table td.col-actions.hiding {
        display: block !important;
        height: 0;
        padding: 0;
        visibility: hidden;
        transition: height 0.4s cubic-bezier(0.4, 0, 0.2, 1),
                    padding 0.4s cubic-bezier(0.4, 0, 0.2, 1),
                    visibility 0s linear 0.4s;
    }
    
    .players-table td.col-actions::before {
        display: none;
    }
    
    .players-table td.col-actions .action-btns {
        display: flex;
        align-items: stretch;
        width: 100%;
        background: rgba(0, 0, 0, 0.3);
        min-height: 100%;
        gap: 0;
        overflow: hidden;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
    }
    
    .players-table td.col-actions .action-btn {
        position: relative;
        width: 100%;
        height: auto;
        padding: 0.7rem 1rem;
        font-size: 0.875rem;
        font-weight: 600;
        text-transform: uppercase;
        letter-spacing: 0.5px;
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 0.5rem;
        flex: 1;
        border: none;
        color: white;
        cursor: pointer;
        z-index: 1;
        transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        border-right: 1px solid rgba(0, 0, 0, 0.3);
        overflow: hidden;
    }
    
    .players-table td.col-actions .action-btn:last-child {
        border-right: none;
    }
    
    /* Gradient backgrounds matching desktop */
    .players-table td.col-actions .action-btn.manipulate,
    .players-table td.col-actions .action-btn.reset {
        background: linear-gradient(135deg, #3a61ed 0%, #5c88f6 100%);
    }
    
    .players-table td.col-actions .action-btn.remove {
        background: linear-gradient(135deg, var(--danger) 0%, #dc2626 100%);
    }
    
    /* Shine effect on mobile buttons */
    .players-table td.col-actions .action-btn::before {
        content: '';
        position: absolute;
        top: 0;
        left: -100%;
        width: 100%;
        height: 100%;
        background: linear-gradient(90deg, 
            transparent 0%, 
            rgba(255, 255, 255, 0.15) 50%, 
            transparent 100%);
        transition: left 0.5s ease;
    }
    
    .players-table td.col-actions .action-btn:hover::before {
        left: 100%;
    }
    
    .players-table td.col-actions .action-btn i {
        font-size: 1.1rem;
        transition: transform 0.3s ease;
    }
    
    .players-table td.col-actions .action-btn:hover {
        transform: scale(1.02);
        filter: brightness(1.15);
        box-shadow: inset 0 0 20px rgba(255, 255, 255, 0.1);
    }
    
    .players-table td.col-actions .action-btn:hover i {
        transform: scale(1.1);
    }
    
    .players-table td.col-actions .action-btn:active {
        transform: scale(0.98);
        filter: brightness(0.95);
    }
    
    /* Hover gradients */
    .players-table td.col-actions .action-btn.manipulate:hover,
    .players-table td.col-actions .action-btn.reset:hover {
        background: linear-gradient(135deg, #5c88f6 0%, #7da3f8 100%);
    }
    
    .players-table td.col-actions .action-btn.remove:hover {
        background: linear-gradient(135deg, #dc2626 0%, #ef4444 100%);
    }
    
    
    /* Adjust player name to wrap on mobile */
    .player-name {
        max-width: 200px;
        font-size: 0.95rem;
    }
    
    /* Adjust number containers and badges for mobile */
    .number-container {
        width: 90px;
        height: 1.75rem;
    }
    
    .rank-badge {
        width: 5rem;
    }
    
    /* Stats badges on mobile */
    .players-table td p.stats {
        font-size: 0.8rem;
        padding: 0.25rem 0.85rem;
    }
    
    
    /* Loading cell on mobile */
    .loading-cell {
        padding: 2rem !important;
    }
    
    /* Adjust table wrapper for mobile */
    .table-wrapper {
        max-height: none;
        overflow-y: visible;
        border: none;
    }
}

@media (max-width: 450px) {
    .player-name {
        max-width: 100px;
    }
    .mobile-menu {
        width: 300px!important;
    }
}

