/* ============================================
   GameTracker — Main Stylesheet
   Professional Dark Gaming Theme
   Developed by templuxo.com
   ============================================ */

/* ─── CSS Variables ─── */
:root {
    /* Backgrounds */
    --bg-body:       #080c14;
    --bg-surface:    #0e1420;
    --bg-card:       #111927;
    --bg-card-hover: #151f33;
    --bg-input:      #0a1018;
    --bg-elevated:   #182035;
    
    /* Borders */
    --border:        #1c2a42;
    --border-light:  #243352;
    --border-focus:  #00d4ff;
    
    /* Accent Colors */
    --accent:        #00d4ff;
    --accent-hover:  #33dfff;
    --accent-rgb:    0, 212, 255;
    --accent2:       #6d5bff;
    --accent2-rgb:   109, 91, 255;
    --accent3:       #00c97b;
    --accent4:       #ffb020;
    --danger:        #ff4757;
    --danger-rgb:    255, 71, 87;
    --success:       #00c97b;
    --warning:       #ffb020;
    
    /* Text */
    --text:          #e4e9f2;
    --text-secondary:#8492a6;
    --text-muted:    #4d5c72;
    --text-dark:     #0a0e17;
    
    /* Gradients */
    --gradient-accent: linear-gradient(135deg, #00d4ff, #6d5bff);
    --gradient-warm:   linear-gradient(135deg, #ff6b6b, #ffb020);
    --gradient-gold:   linear-gradient(135deg, #ffb020, #ff6b6b);
    
    /* Shadows */
    --shadow-sm:   0 1px 3px rgba(0,0,0,0.3);
    --shadow-md:   0 4px 12px rgba(0,0,0,0.4);
    --shadow-lg:   0 8px 30px rgba(0,0,0,0.5);
    --shadow-glow: 0 0 20px rgba(var(--accent-rgb), 0.15);
    
    /* Spacing & Radius */
    --radius-sm: 4px;
    --radius:    8px;
    --radius-lg: 12px;
    --radius-xl: 16px;
    
    /* Fonts */
    --font-body:  'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    --font-head:  'Rajdhani', sans-serif;
    --font-mono:  'JetBrains Mono', 'Fira Code', monospace;
    
    /* Layout */
    --container-max: 1400px;
    --header-h: 60px;
    --topbar-h: 32px;
}

/* ─── Light Mode ─── */
[data-theme="light"] {
    --bg-body:       #f0f2f5;
    --bg-surface:    #e8ebf0;
    --bg-card:       #ffffff;
    --bg-card-hover: #f5f7fa;
    --bg-input:      #f0f2f5;
    --bg-elevated:   #ffffff;
    --border:        #d1d9e6;
    --border-light:  #e2e8f0;
    --border-focus:  #0088cc;
    --accent:        #0088cc;
    --accent-hover:  #006da3;
    --accent-rgb:    0, 136, 204;
    --accent2:       #5a46e0;
    --accent2-rgb:   90, 70, 224;
    --accent3:       #00a366;
    --accent4:       #e09000;
    --danger:        #e03e4e;
    --danger-rgb:    224, 62, 78;
    --success:       #00a366;
    --warning:       #e09000;
    --text:          #1a202c;
    --text-secondary:#4a5568;
    --text-muted:    #94a3b8;
    --text-dark:     #0a0e17;
    --gradient-accent: linear-gradient(135deg, #0088cc, #5a46e0);
    --shadow-sm:   0 1px 3px rgba(0,0,0,0.08);
    --shadow-md:   0 4px 12px rgba(0,0,0,0.1);
    --shadow-lg:   0 8px 30px rgba(0,0,0,0.12);
    --shadow-glow: 0 0 20px rgba(0,136,204,0.1);
}

[data-theme="light"] body::before { display: none; }

[data-theme="light"] .topbar { background: #dde1e8; border-color: #c8cdd6; }

[data-theme="light"] .header { background: rgba(255,255,255,0.9); backdrop-filter: blur(12px); border-color: #d1d9e6; }

[data-theme="light"] .hero { background: linear-gradient(135deg, #dce3ed, #e8ecf4); border-color: #c8d0de; }

[data-theme="light"] .footer { background: #1a202c; }

[data-theme="light"] .server-table thead th { background: #f0f2f5; color: #4a5568; border-color: #d1d9e6; }

[data-theme="light"] .server-table tbody td { border-color: #e2e8f0; }

[data-theme="light"] .server-table tbody tr:hover td { background: rgba(0,136,204,0.04); }

[data-theme="light"] .form-control { background: #f0f2f5; border-color: #d1d9e6; color: #1a202c; }

[data-theme="light"] .btn-ghost { color: #4a5568; border-color: #d1d9e6; }
[data-theme="light"] .btn-ghost:hover { background: rgba(0,136,204,0.06); color: #0088cc; }

[data-theme="light"] .nav-link { color: #4a5568; }
[data-theme="light"] .nav-link.active, [data-theme="light"] .nav-link:hover { color: #0088cc; }

[data-theme="light"] .alert { border-color: #d1d9e6; }

[data-theme="light"] .sidebar-card, [data-theme="light"] .card { border-color: #d1d9e6; }

[data-theme="light"] .dropdown-menu { background: #ffffff; border-color: #d1d9e6; }

[data-theme="light"] #heroCanvas { opacity: 0.3; }

/* ─── Light Mode: Comprehensive Text & Background Fixes ─── */
[data-theme="light"] .logo-name { color: #1a202c; }
[data-theme="light"] .logo-sub { color: #64748b; }
/* Footer is always dark - keep its text white in both themes */
[data-theme="light"] .footer .logo-name { color: #f0f4f8; }
[data-theme="light"] .footer .logo-sub  { color: #94a3b8; }
[data-theme="light"] .footer .footer-desc { color: #94a3b8; }
[data-theme="light"] .footer .footer-col h4 { color: #e2e8f0; }
[data-theme="light"] .footer .footer-col a  { color: #94a3b8; }
[data-theme="light"] .footer .footer-col a:hover { color: #60c8f0; }
[data-theme="light"] .footer .footer-bottom p { color: #64748b; }
[data-theme="light"] .footer .footer-links a  { color: #64748b; }
[data-theme="light"] .footer .footer-links a:hover { color: #60c8f0; }
[data-theme="light"] .footer .topbar-stat { color: #94a3b8; }
[data-theme="light"] .topbar-stat { color: #4a5568; }
[data-theme="light"] .topbar-stat span { color: #1a202c; }
[data-theme="light"] .user-btn { color: #1a202c; border-color: #d1d9e6; background: #f0f2f5; }
[data-theme="light"] .user-name { color: #1a202c; }
[data-theme="light"] .user-avatar { background: #0088cc; color: #fff; }
[data-theme="light"] .dropdown-menu a { color: #4a5568; }
[data-theme="light"] .dropdown-menu a:hover { color: #0088cc; background: rgba(0,136,204,0.06); }

/* Tables */
[data-theme="light"] .server-name { color: #1a202c; }
[data-theme="light"] .server-rank { color: #4a5568; }
[data-theme="light"] .server-rank.top1 { color: #b8860b; }
[data-theme="light"] .server-rank.top2 { color: #888; }
[data-theme="light"] .server-rank.top3 { color: #a0522d; }
[data-theme="light"] .votes-count { color: #1a202c; }
[data-theme="light"] .players-text { color: #1a202c; }
[data-theme="light"] .server-ip { color: #4a5568; background: #f0f2f5; border-color: #d1d9e6; }
[data-theme="light"] .map-name span { color: #4a5568; }
[data-theme="light"] .country-flag { color: #1a202c; }
[data-theme="light"] .tag { background: rgba(0,136,204,0.08); color: #0088cc; }
[data-theme="light"] .game-badge { border: 1px solid rgba(0,0,0,0.06); }

/* Stat cards */
[data-theme="light"] .stat-card { background: rgba(0,0,0,0.03); border-color: #d1d9e6; }
[data-theme="light"] .stat-card-value { color: #0088cc; }
[data-theme="light"] .stat-card-label { color: #64748b; }

/* Info rows */
[data-theme="light"] .info-row { border-color: #e2e8f0; }
[data-theme="light"] .info-row .label { color: #64748b; }
[data-theme="light"] .info-row .value { color: #1a202c; }

/* Card headers */
[data-theme="light"] .card-header { border-color: #e2e8f0; }
[data-theme="light"] .card-header h3 { color: #1a202c; }

/* Auth */
[data-theme="light"] .auth-title { color: #1a202c; }
[data-theme="light"] .auth-footer { color: #4a5568; }
[data-theme="light"] .form-label { color: #1a202c; }
[data-theme="light"] .form-help { color: #94a3b8; }

/* Buttons */
[data-theme="light"] .btn-primary { background: var(--gradient-accent); color: #fff; }
[data-theme="light"] .btn-vote { color: #b8860b; border-color: #e0c97b; }
[data-theme="light"] .btn-danger { color: #fff; }

/* Misc */
[data-theme="light"] .text-muted, [data-theme="light"] .text-sm.text-muted { color: #94a3b8 !important; }
[data-theme="light"] .font-mono.text-muted { color: #94a3b8; }
[data-theme="light"] .empty-text { color: #64748b; }
[data-theme="light"] .mobile-nav { background: #fff; border-color: #d1d9e6; }
[data-theme="light"] .mobile-nav-link { color: #4a5568; }
[data-theme="light"] .mobile-nav-link.active { color: #0088cc; }
[data-theme="light"] .pagination .pg-btn { color: #4a5568; border-color: #d1d9e6; background: #fff; }
[data-theme="light"] .pagination .pg-btn.active { color: #fff; background: #0088cc; }
[data-theme="light"] .status-online { color: #00a366; }
[data-theme="light"] .status-offline { color: #e03e4e; }

/* Copy toast */
[data-theme="light"] .copy-toast { background: #fff; border-color: #d1d9e6; color: #1a202c; }

/* Notification panel */
[data-theme="light"] .notif-panel { background: #fff; border-color: #d1d9e6; }
[data-theme="light"] .notif-panel-header { border-color: #e2e8f0; }
[data-theme="light"] .notif-item { color: #1a202c; }
[data-theme="light"] .notif-item.unread { background: rgba(0,136,204,0.04); }
[data-theme="light"] .notif-item-title { color: #1a202c; }

/* Server card items */
[data-theme="light"] .server-card-item { background: #fff; border-color: #d1d9e6; }
[data-theme="light"] .server-card-item:hover { background: #f8fafc; border-color: #b8c5d6; }
[data-theme="light"] .server-card-name { color: #1a202c; }
[data-theme="light"] .server-card-players { color: #0088cc; }
[data-theme="light"] .server-card-footer { border-color: #e2e8f0; }

/* View toggle */
[data-theme="light"] .view-toggle { background: #f0f2f5; border-color: #d1d9e6; }
[data-theme="light"] .view-toggle-btn.active { background: rgba(0,136,204,0.1); color: #0088cc; }

/* Section titles */
[data-theme="light"] .section-title { color: #1a202c; }
[data-theme="light"] .section-link { color: #0088cc; }

/* ─── Reset ─── */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
    font-family: var(--font-body);
    font-size: 14px;
    line-height: 1.6;
    color: var(--text);
    background: var(--bg-body);
    -webkit-font-smoothing: antialiased;
    min-height: 100vh;
}

body::before {
    content: '';
    position: fixed; inset: 0;
    background:
        radial-gradient(ellipse at 15% 0%, rgba(var(--accent-rgb), 0.04) 0%, transparent 55%),
        radial-gradient(ellipse at 85% 100%, rgba(var(--accent2-rgb), 0.03) 0%, transparent 55%);
    pointer-events: none;
    z-index: 0;
}

a { color: var(--accent); text-decoration: none; transition: color 0.2s; }
a:hover { color: var(--accent-hover); }

img { max-width: 100%; display: block; }

/* ─── Container ─── */
.container {
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 24px;
}

/* ─── Topbar ─── */
.topbar {
    background: rgba(0,0,0,0.5);
    border-bottom: 1px solid rgba(255,255,255,0.03);
    height: var(--topbar-h);
    position: relative; z-index: 101;
}

.topbar-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 100%;
}

.topbar-left, .topbar-right { display: flex; align-items: center; gap: 16px; }

.topbar-stat {
    font-size: 11px;
    color: var(--text-muted);
    display: flex; align-items: center; gap: 5px;
    font-weight: 500;
}

.topbar-stat i { font-size: 10px; color: var(--accent); }
.topbar-stat span { color: var(--text-secondary); font-weight: 600; }

/* ─── Header ─── */
.header {
    background: rgba(14, 20, 32, 0.9);
    backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--border);
    height: var(--header-h);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 100%;
}

/* Logo */
.logo {
    display: flex; align-items: center; gap: 10px;
    text-decoration: none; color: var(--text);
}

.logo-icon {
    width: 36px; height: 36px;
    background: var(--gradient-accent);
    border-radius: var(--radius);
    display: flex; align-items: center; justify-content: center;
    font-size: 16px; color: var(--text-dark);
    box-shadow: 0 0 15px rgba(var(--accent-rgb), 0.3);
}

.logo-text { display: flex; flex-direction: column; }
.logo-name {
    font-family: var(--font-head);
    font-size: 20px; font-weight: 700;
    line-height: 1.1; letter-spacing: 0.5px;
}
.logo-sub {
    font-size: 10px; color: var(--text-muted);
    letter-spacing: 0.5px; font-weight: 500;
}

.accent { color: var(--accent); }

/* Nav */
.nav { display: flex; align-items: center; gap: 2px; }

.nav-link {
    font-size: 13px; font-weight: 600;
    color: var(--text-secondary);
    padding: 8px 14px;
    border-radius: var(--radius);
    transition: all 0.2s;
    text-decoration: none;
    display: flex; align-items: center; gap: 6px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.nav-link:hover { color: var(--text); background: rgba(255,255,255,0.04); }
.nav-link.active { color: var(--accent); background: rgba(var(--accent-rgb), 0.08); }
.nav-link i { font-size: 12px; }

/* Header Actions */
.header-actions { display: flex; align-items: center; gap: 8px; }

.user-dropdown { position: relative; }

.user-btn {
    display: flex; align-items: center; gap: 8px;
    background: rgba(255,255,255,0.04);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 5px 12px 5px 5px;
    color: var(--text);
    cursor: pointer;
    font-family: var(--font-body);
    font-size: 13px; font-weight: 500;
    transition: all 0.2s;
}
.user-btn:hover { border-color: var(--accent); }
.user-btn i { font-size: 10px; color: var(--text-muted); }

.user-avatar {
    width: 28px; height: 28px;
    border-radius: 50%;
    background: var(--gradient-accent);
    display: flex; align-items: center; justify-content: center;
    font-size: 12px; font-weight: 700;
    color: var(--text-dark);
}

.user-name { max-width: 100px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.dropdown-menu {
    position: absolute;
    top: calc(100% + 6px); right: 0;
    background: var(--bg-elevated);
    border: 1px solid var(--border-light);
    border-radius: var(--radius);
    min-width: 200px;
    padding: 6px;
    box-shadow: var(--shadow-lg);
    display: none;
    z-index: 200;
}
.dropdown-menu.show { display: block; }
.dropdown-menu a {
    display: flex; align-items: center; gap: 8px;
    padding: 8px 12px;
    font-size: 13px;
    color: var(--text-secondary);
    border-radius: var(--radius-sm);
    transition: all 0.15s;
}
.dropdown-menu a:hover { background: rgba(var(--accent-rgb), 0.08); color: var(--text); }
.dropdown-menu a i { width: 16px; text-align: center; font-size: 12px; }
.dropdown-divider { height: 1px; background: var(--border); margin: 4px 0; }
.text-danger { color: var(--danger) !important; }

.mobile-toggle {
    display: none;
    background: none; border: none;
    color: var(--text); font-size: 20px;
    cursor: pointer; padding: 4px;
}

/* Mobile Nav */
.mobile-nav {
    display: none;
    flex-direction: column;
    background: var(--bg-surface);
    border-bottom: 1px solid var(--border);
    padding: 8px 24px;
}
.mobile-nav.open { display: flex; }
.mobile-nav-link {
    padding: 10px 0;
    color: var(--text-secondary);
    font-size: 14px; font-weight: 500;
    border-bottom: 1px solid var(--border);
    display: flex; align-items: center; gap: 10px;
}
.mobile-nav-link:last-child { border-bottom: none; }
.mobile-nav-link.active { color: var(--accent); }

/* ─── Buttons ─── */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 6px;
    font-family: var(--font-body);
    font-size: 13px; font-weight: 600;
    padding: 9px 18px;
    border-radius: var(--radius);
    border: none;
    cursor: pointer;
    transition: all 0.2s;
    text-decoration: none;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    white-space: nowrap;
    line-height: 1.4;
}
.btn i { font-size: 12px; }

.btn-primary {
    background: var(--gradient-accent);
    color: var(--text-dark);
    box-shadow: 0 0 12px rgba(var(--accent-rgb), 0.2);
}
.btn-primary:hover {
    box-shadow: 0 0 25px rgba(var(--accent-rgb), 0.4);
    transform: translateY(-1px);
    color: var(--text-dark);
}

.btn-ghost {
    background: rgba(255,255,255,0.04);
    color: var(--text);
    border: 1px solid var(--border);
}
.btn-ghost:hover { border-color: var(--accent); color: var(--accent); }

.btn-vote {
    background: rgba(255,176,32,0.08);
    color: var(--accent4);
    border: 1px solid rgba(255,176,32,0.25);
}
.btn-vote:hover { background: rgba(255,176,32,0.15); box-shadow: 0 0 10px rgba(255,176,32,0.15); }
.btn-vote.voted { background: rgba(255,176,32,0.18); border-color: var(--accent4); }

.btn-danger {
    background: rgba(var(--danger-rgb), 0.1);
    color: var(--danger);
    border: 1px solid rgba(var(--danger-rgb), 0.25);
}

.btn-success {
    background: rgba(0,201,123,0.1);
    color: var(--success);
    border: 1px solid rgba(0,201,123,0.25);
}

.btn-sm { padding: 6px 12px; font-size: 12px; }
.btn-lg { padding: 12px 28px; font-size: 14px; }
.btn-block { width: 100%; }

/* ─── Forms ─── */
.form-group { margin-bottom: 16px; }

.form-label {
    display: block;
    font-size: 12px; font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 6px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.form-control {
    width: 100%;
    font-family: var(--font-body);
    font-size: 14px;
    color: var(--text);
    background: var(--bg-input);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 10px 14px;
    outline: none;
    transition: border-color 0.2s, box-shadow 0.2s;
}
.form-control:focus {
    border-color: var(--border-focus);
    box-shadow: 0 0 0 3px rgba(var(--accent-rgb), 0.08);
}
.form-control::placeholder { color: var(--text-muted); }

select.form-control {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12'%3E%3Cpath fill='%238492a6' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    padding-right: 34px;
    cursor: pointer;
}

textarea.form-control { resize: vertical; min-height: 80px; }

.form-row { display: flex; gap: 12px; }
.form-row > * { flex: 1; }

.form-help { font-size: 11px; color: var(--text-muted); margin-top: 4px; }
.form-error { font-size: 12px; color: var(--danger); margin-top: 4px; }

/* ─── Cards ─── */
.card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    overflow: hidden;
    transition: border-color 0.2s, box-shadow 0.2s;
}
.card:hover { border-color: var(--border-light); }

.card-header {
    padding: 16px 20px;
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.card-header h3 {
    font-family: var(--font-head);
    font-size: 16px; font-weight: 700;
    display: flex; align-items: center; gap: 8px;
}
.card-body { padding: 20px; }

/* ─── Alerts ─── */
.alert {
    padding: 12px 16px;
    border-radius: var(--radius);
    font-size: 13px;
    display: flex; align-items: center; gap: 10px;
    margin: 12px 0;
    position: relative;
}
.alert i { font-size: 14px; }
.alert-close {
    position: absolute; right: 12px; top: 50%; transform: translateY(-50%);
    background: none; border: none; color: inherit; cursor: pointer;
    font-size: 18px; opacity: 0.6;
}
.alert-success { background: rgba(0,201,123,0.08); border: 1px solid rgba(0,201,123,0.2); color: var(--success); }
.alert-error   { background: rgba(var(--danger-rgb),0.08); border: 1px solid rgba(var(--danger-rgb),0.2); color: var(--danger); }
.alert-warning { background: rgba(255,176,32,0.08); border: 1px solid rgba(255,176,32,0.2); color: var(--warning); }
.alert-info    { background: rgba(var(--accent-rgb),0.08); border: 1px solid rgba(var(--accent-rgb),0.2); color: var(--accent); }

/* ─── Tables (Server List) ─── */
.table-wrap {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    overflow: hidden;
}

.server-table {
    width: 100%;
    border-collapse: collapse;
}

.server-table thead th {
    font-family: var(--font-head);
    font-size: 11px; font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--text-muted);
    padding: 12px 14px;
    text-align: left;
    background: rgba(0,0,0,0.25);
    border-bottom: 1px solid var(--border);
    white-space: nowrap;
    cursor: pointer;
    user-select: none;
    transition: color 0.15s;
}
.server-table thead th:hover { color: var(--text-secondary); }
.server-table thead th .sort-icon { font-size: 9px; margin-left: 4px; color: var(--accent); }

.server-table tbody td {
    padding: 10px 14px;
    border-bottom: 1px solid rgba(28,42,66,0.4);
    font-size: 13px;
    vertical-align: middle;
}
.server-table tbody tr { transition: background 0.15s; }
.server-table tbody tr:hover td { background: rgba(var(--accent-rgb), 0.015); }
.server-table tbody tr:last-child td { border-bottom: none; }

.server-rank {
    font-family: var(--font-mono);
    font-size: 12px;
    color: var(--text-muted);
    width: 45px;
}
.server-rank.top1 { color: #ffd700; font-weight: 700; }
.server-rank.top2 { color: #c0c0c0; font-weight: 700; }
.server-rank.top3 { color: #cd7f32; font-weight: 700; }

.server-name-cell { min-width: 240px; }
.server-name {
    font-weight: 600;
    color: var(--text);
    cursor: pointer;
    transition: color 0.15s;
    display: block;
}
.server-name:hover { color: var(--accent); }

.server-tags {
    display: flex; gap: 4px; margin-top: 3px; flex-wrap: wrap;
}
.tag {
    font-size: 9px;
    font-weight: 600;
    padding: 1px 6px;
    border-radius: 3px;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    background: rgba(var(--accent-rgb), 0.08);
    color: var(--accent);
}

.server-ip {
    font-family: var(--font-mono);
    font-size: 12px;
    color: var(--text-secondary);
    cursor: pointer;
    transition: color 0.15s;
}
.server-ip:hover { color: var(--accent); }

.game-badge {
    display: inline-flex; align-items: center; gap: 4px;
    padding: 3px 8px;
    border-radius: var(--radius-sm);
    font-size: 11px; font-weight: 700;
    white-space: nowrap;
    letter-spacing: 0.3px;
}

.map-name { font-size: 12px; color: var(--text-secondary); }

.players-cell { white-space: nowrap; }
.players-text { font-size: 13px; font-weight: 500; }
.players-bar {
    width: 80px; height: 3px;
    background: rgba(255,255,255,0.06);
    border-radius: 2px;
    margin-top: 4px;
    overflow: hidden;
}
.players-bar-fill {
    height: 100%; border-radius: 2px;
    transition: width 0.4s ease;
}

.status-dot {
    width: 8px; height: 8px;
    border-radius: 50%;
    display: inline-block;
    margin-right: 4px;
}
.status-online { background: var(--success); box-shadow: 0 0 6px rgba(0,201,123,0.5); color: var(--success); }
.status-offline { background: var(--danger); box-shadow: 0 0 6px rgba(var(--danger-rgb),0.5); color: var(--danger); }
.status-unknown { background: var(--text-muted); color: var(--text-muted); }
/* When used as text (not dot), remove background/shadow */
span.status-online:not(.status-dot),
span.status-offline:not(.status-dot),
span.status-unknown:not(.status-dot) {
    background: none;
    box-shadow: none;
}

.ping { font-family: var(--font-mono); font-size: 12px; }
.ping-good { color: var(--success); }
.ping-medium { color: var(--warning); }
.ping-bad { color: var(--danger); }
.ping-na { color: var(--text-muted); }

.country-flag { font-size: 16px; cursor: default; }

.votes-cell { display: flex; align-items: center; gap: 8px; }
.votes-count {
    font-family: var(--font-head);
    font-size: 17px; font-weight: 700;
    color: var(--accent4);
    min-width: 35px;
}

/* ─── Pagination ─── */
.pagination {
    display: flex; align-items: center; justify-content: center;
    gap: 4px; padding: 20px 0;
}
.pg-btn {
    display: flex; align-items: center; justify-content: center;
    min-width: 36px; height: 36px;
    padding: 0 10px;
    border-radius: var(--radius);
    background: var(--bg-card);
    border: 1px solid var(--border);
    color: var(--text-secondary);
    font-family: var(--font-body);
    font-size: 13px; font-weight: 600;
    text-decoration: none;
    transition: all 0.15s;
}
.pg-btn:hover { border-color: var(--accent); color: var(--accent); }
.pg-btn.active {
    background: rgba(var(--accent-rgb), 0.1);
    border-color: var(--accent);
    color: var(--accent);
}
.pg-dots { color: var(--text-muted); padding: 0 4px; }

/* ─── Section ─── */
.section { margin-bottom: 36px; }

.section-header {
    display: flex; align-items: center; justify-content: space-between;
    margin-bottom: 16px;
}

.section-title {
    font-family: var(--font-head);
    font-size: 20px; font-weight: 700;
    display: flex; align-items: center; gap: 10px;
}

.section-icon {
    width: 30px; height: 30px;
    border-radius: var(--radius);
    display: flex; align-items: center; justify-content: center;
    font-size: 13px;
}
.section-icon.cyan    { background: rgba(var(--accent-rgb),0.1); color: var(--accent); }
.section-icon.gold    { background: rgba(255,176,32,0.1); color: var(--accent4); }
.section-icon.green   { background: rgba(0,201,123,0.1); color: var(--accent3); }
.section-icon.purple  { background: rgba(var(--accent2-rgb),0.1); color: var(--accent2); }

.section-link {
    font-size: 13px; font-weight: 500;
    color: var(--accent);
    display: flex; align-items: center; gap: 4px;
}
.section-link:hover { color: var(--accent-hover); }

/* ─── Filter Bar ─── */
.filter-bar {
    display: flex; gap: 10px;
    align-items: center;
    margin-bottom: 18px;
    flex-wrap: wrap;
}
.filter-bar .form-control { width: auto; min-width: 160px; }
.filter-bar .search-input { min-width: 260px; }

/* ─── Footer ─── */
.footer {
    border-top: 1px solid var(--border);
    padding: 48px 0 0;
    margin-top: 60px;
    background: rgba(0,0,0,0.3);
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr 1fr;
    gap: 40px;
    padding-bottom: 40px;
}

.footer-desc { font-size: 13px; color: var(--text-muted); line-height: 1.7; max-width: 320px; }

.footer-col h4 {
    font-family: var(--font-head);
    font-size: 14px; font-weight: 700;
    color: var(--text);
    margin-bottom: 14px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.footer-col a {
    display: block;
    font-size: 13px;
    color: var(--text-muted);
    padding: 3px 0;
    transition: color 0.15s;
}
.footer-col a:hover { color: var(--accent); }

.footer-bottom {
    border-top: 1px solid var(--border);
    padding: 20px 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.footer-bottom p { font-size: 12px; color: var(--text-muted); }

.footer-links { display: flex; gap: 20px; }
.footer-links a { font-size: 12px; color: var(--text-muted); }
.footer-links a:hover { color: var(--accent); }

/* ─── Main Content ─── */
.main-content {
    min-height: calc(100vh - var(--header-h) - var(--topbar-h) - 200px);
    position: relative; z-index: 1;
}

.main-content > .container { padding-top: 24px; padding-bottom: 24px; }

/* ─── Responsive ─── */
@media (max-width: 1024px) {
    .footer-grid { grid-template-columns: 1fr 1fr; gap: 30px; }
}

@media (max-width: 768px) {
    .nav { display: none; }
    .mobile-toggle { display: block; }
    .topbar-left .topbar-stat:nth-child(n+3) { display: none; }
    .header-inner { padding: 0 16px; }
    .container { padding: 0 16px; }
    .footer-grid { grid-template-columns: 1fr; gap: 24px; }
    .footer-bottom { flex-direction: column; gap: 12px; text-align: center; }
    .filter-bar { flex-direction: column; }
    .filter-bar .form-control,
    .filter-bar .search-input { width: 100%; min-width: 0; }
    .form-row { flex-direction: column; }
    .server-table { font-size: 12px; }
    .user-name { display: none; }
}

/* ─── Utility ─── */
.text-center { text-align: center; }
.text-right { text-align: right; }
.text-muted { color: var(--text-muted); }
.text-accent { color: var(--accent); }
.text-sm { font-size: 12px; }
.text-xs { font-size: 11px; }
.mt-1 { margin-top: 8px; }
.mt-2 { margin-top: 16px; }
.mt-3 { margin-top: 24px; }
.mb-1 { margin-bottom: 8px; }
.mb-2 { margin-bottom: 16px; }
.mb-3 { margin-bottom: 24px; }
.gap-1 { gap: 8px; }
.gap-2 { gap: 16px; }
.d-flex { display: flex; }
.align-center { align-items: center; }
.justify-between { justify-content: space-between; }
.flex-wrap { flex-wrap: wrap; }
.font-mono { font-family: var(--font-mono); }
.font-head { font-family: var(--font-head); }
.fw-700 { font-weight: 700; }

.tooltip-text {
    font-size: 10px; color: var(--accent);
    animation: fadeInUp 0.2s ease;
}

@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(4px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ─── Lucide Icons ─── */
[data-lucide] {
    width: 16px;
    height: 16px;
    stroke-width: 2;
    vertical-align: middle;
    display: inline-block;
}
.nav-link [data-lucide], .mobile-nav-link [data-lucide] { width: 14px; height: 14px; }
.btn [data-lucide] { width: 14px; height: 14px; }
.btn-sm [data-lucide] { width: 12px; height: 12px; }
.btn-lg [data-lucide] { width: 16px; height: 16px; }
.logo-icon [data-lucide] { width: 18px; height: 18px; }
.section-icon [data-lucide] { width: 14px; height: 14px; }
.topbar-stat [data-lucide] { width: 12px; height: 12px; }
.alert [data-lucide] { width: 15px; height: 15px; flex-shrink: 0; }
.dropdown-menu a [data-lucide] { width: 14px; height: 14px; }
.user-btn [data-lucide] { width: 12px; height: 12px; }

/* ─── Animations ─── */
@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(16px); }
    to { opacity: 1; transform: translateY(0); }
}
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}
@keyframes slideInLeft {
    from { opacity: 0; transform: translateX(-20px); }
    to { opacity: 1; transform: translateX(0); }
}
@keyframes pulseGlow {
    0%, 100% { box-shadow: 0 0 5px rgba(var(--accent-rgb), 0.2); }
    50% { box-shadow: 0 0 20px rgba(var(--accent-rgb), 0.4); }
}
@keyframes shimmer {
    0% { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}

.hero { animation: fadeInUp 0.5s ease-out; }
.card, .table-wrap, .sidebar-card { animation: fadeIn 0.4s ease-out; }
.section { animation: fadeInUp 0.5s ease-out backwards; }
.section:nth-child(2) { animation-delay: 0.1s; }
.section:nth-child(3) { animation-delay: 0.2s; }

.server-table tbody tr {
    animation: fadeIn 0.3s ease-out backwards;
}
.server-table tbody tr:nth-child(1) { animation-delay: 0.05s; }
.server-table tbody tr:nth-child(2) { animation-delay: 0.1s; }
.server-table tbody tr:nth-child(3) { animation-delay: 0.15s; }
.server-table tbody tr:nth-child(4) { animation-delay: 0.2s; }
.server-table tbody tr:nth-child(5) { animation-delay: 0.25s; }

.game-card, .game-list-card {
    animation: fadeInUp 0.4s ease-out backwards;
}
.game-card:nth-child(1), .game-list-card:nth-child(1) { animation-delay: 0.05s; }
.game-card:nth-child(2), .game-list-card:nth-child(2) { animation-delay: 0.1s; }
.game-card:nth-child(3), .game-list-card:nth-child(3) { animation-delay: 0.15s; }
.game-card:nth-child(4), .game-list-card:nth-child(4) { animation-delay: 0.2s; }

.btn-primary { transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1); }
.btn-primary:hover { transform: translateY(-2px); }
.btn-primary:active { transform: translateY(0) scale(0.98); }

.btn-vote { transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1); }
.btn-vote:hover { transform: scale(1.05); }

.status-dot.status-online { animation: pulseGlow 2s ease-in-out infinite; }

.stat-card { transition: all 0.2s ease; }
.stat-card:hover { transform: translateY(-3px); border-color: var(--border-light); }

.hero-stat-val { transition: color 0.3s; }

/* ─── Premium Server Badge ─── */
.premium-badge {
    display: inline-flex; align-items: center; gap: 4px;
    padding: 2px 8px;
    border-radius: 4px;
    background: linear-gradient(135deg, rgba(255,176,32,0.12), rgba(255,107,107,0.08));
    border: 1px solid rgba(255,176,32,0.2);
    color: var(--accent4);
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    animation: shimmer 3s linear infinite;
    background-size: 200% 100%;
    background-image: linear-gradient(90deg, rgba(255,176,32,0.08) 0%, rgba(255,176,32,0.2) 50%, rgba(255,176,32,0.08) 100%);
}
.premium-badge [data-lucide] { width: 10px; height: 10px; color: var(--accent4); }

.premium-row td { background: rgba(255,176,32,0.02) !important; }
.premium-row:hover td { background: rgba(255,176,32,0.04) !important; }

/* Smooth page transitions */
.main-content { animation: fadeIn 0.3s ease-out; }
