/**
 * ╔═══════════════════════════════════════════════════════════════════════════╗
 * ║                    MINECRAFT STATISTICS WEBSITE STYLES                     ║
 * ╚═══════════════════════════════════════════════════════════════════════════╝
 */

/* ═══════════════════════════════════════════════════════════════════════════
   CSS VARIABLES
   ═══════════════════════════════════════════════════════════════════════════ */
:root {
    /* Colors */
    --primary: #00d9ff;
    --primary-dark: #00a8c6;
    --primary-glow: rgba(0, 217, 255, 0.3);
    
    --secondary: #7c3aed;
    --secondary-dark: #5b21b6;
    --secondary-glow: rgba(124, 58, 237, 0.3);
    
    --accent: #22c55e;
    --accent-dark: #16a34a;
    
    --gold: #fbbf24;
    --silver: #9ca3af;
    --bronze: #d97706;
    
    --danger: #ef4444;
    --warning: #f59e0b;
    --success: #22c55e;
    --info: #3b82f6;
    
    /* Backgrounds */
    --bg-darkest: #020617;
    --bg-darker: #0f172a;
    --bg-dark: #1e293b;
    --bg-card: #1e293b;
    --bg-hover: #334155;
    
    /* Text */
    --text-primary: #f8fafc;
    --text-secondary: #94a3b8;
    --text-muted: #64748b;
    
    /* Borders */
    --border-color: rgba(148, 163, 184, 0.1);
    --border-light: rgba(148, 163, 184, 0.2);
    
    /* Gradients */
    --gradient-primary: linear-gradient(135deg, var(--primary), var(--secondary));
    --gradient-card: linear-gradient(180deg, rgba(30, 41, 59, 0.8), rgba(15, 23, 42, 0.9));
    --gradient-gold: linear-gradient(135deg, #fbbf24, #f59e0b);
    --gradient-silver: linear-gradient(135deg, #e5e7eb, #9ca3af);
    --gradient-bronze: linear-gradient(135deg, #f59e0b, #d97706);
    
    /* Shadows */
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.4);
    --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 10px 25px rgba(0, 0, 0, 0.5);
    --shadow-xl: 0 20px 40px rgba(0, 0, 0, 0.6);
    --shadow-glow: 0 0 30px var(--primary-glow);
    
    /* Spacing */
    --container-width: 1400px;
    --section-gap: 4rem;
    --card-gap: 1.5rem;
    
    /* Border Radius */
    --radius-sm: 0.375rem;
    --radius-md: 0.75rem;
    --radius-lg: 1rem;
    --radius-xl: 1.5rem;
    
    /* Transitions */
    --transition-fast: 0.15s ease;
    --transition-normal: 0.3s ease;
    --transition-slow: 0.5s ease;
    
    /* Typography */
    --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --font-mono: 'JetBrains Mono', 'Fira Code', monospace;
}

/* ═══════════════════════════════════════════════════════════════════════════
   RESET & BASE STYLES
   ═══════════════════════════════════════════════════════════════════════════ */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: var(--font-sans);
    font-size: 16px;
    line-height: 1.6;
    color: var(--text-primary);
    background: var(--bg-darkest);
    min-height: 100vh;
    overflow-x: hidden;
}

a {
    color: var(--primary);
    text-decoration: none;
    transition: color var(--transition-fast);
}

a:hover {
    color: var(--primary-dark);
}

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

button {
    font-family: inherit;
    cursor: pointer;
}

/* ═══════════════════════════════════════════════════════════════════════════
   ANIMATED BACKGROUND
   ═══════════════════════════════════════════════════════════════════════════ */
.bg-animation {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: -1;
    overflow: hidden;
}

.bg-gradient {
    position: absolute;
    inset: 0;
    background: 
        radial-gradient(ellipse 80% 50% at 50% -20%, rgba(0, 217, 255, 0.15), transparent),
        radial-gradient(ellipse 60% 40% at 100% 0%, rgba(124, 58, 237, 0.1), transparent),
        radial-gradient(ellipse 50% 30% at 0% 100%, rgba(34, 197, 94, 0.08), transparent);
}

.bg-particles {
    position: absolute;
    inset: 0;
    background-image: 
        radial-gradient(2px 2px at 20px 30px, rgba(255,255,255,0.1), transparent),
        radial-gradient(2px 2px at 40px 70px, rgba(255,255,255,0.08), transparent),
        radial-gradient(2px 2px at 50px 160px, rgba(255,255,255,0.1), transparent),
        radial-gradient(2px 2px at 90px 40px, rgba(255,255,255,0.06), transparent),
        radial-gradient(2px 2px at 130px 80px, rgba(255,255,255,0.08), transparent);
    background-size: 200px 200px;
    animation: particles 60s linear infinite;
}

@keyframes particles {
    from { transform: translateY(0); }
    to { transform: translateY(-200px); }
}

/* ═══════════════════════════════════════════════════════════════════════════
   CONTAINER & LAYOUT
   ═══════════════════════════════════════════════════════════════════════════ */
.container {
    width: 100%;
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 1.5rem;
}

.main-content {
    min-height: calc(100vh - 200px);
    padding: 2rem 0;
}

.section {
    margin-bottom: var(--section-gap);
}

.section-header {
    margin-bottom: 2rem;
    text-align: center;
}

.section-title {
    font-size: 2rem;
    font-weight: 700;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 0.5rem;
}

.section-subtitle {
    color: var(--text-secondary);
    font-size: 1.1rem;
}

/* ═══════════════════════════════════════════════════════════════════════════
   NAVIGATION
   ═══════════════════════════════════════════════════════════════════════════ */
.navbar {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: rgba(15, 23, 42, 0.85);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border-color);
    padding: 0.75rem 0;
}

.navbar .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
}

.navbar-brand {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-primary);
    transition: transform var(--transition-fast);
}

.navbar-brand:hover {
    color: var(--text-primary);
    transform: scale(1.02);
}

.navbar-logo {
    width: 40px;
    height: 40px;
}

.navbar-menu {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.625rem 1rem;
    color: var(--text-secondary);
    font-weight: 500;
    border-radius: var(--radius-md);
    transition: all var(--transition-fast);
}

.nav-link:hover,
.nav-link.active {
    color: var(--text-primary);
    background: var(--bg-hover);
}

.nav-link.active {
    background: rgba(0, 217, 255, 0.1);
    color: var(--primary);
}

.nav-link i {
    font-size: 1rem;
}

.navbar-toggle {
    display: none;
    background: none;
    border: none;
    color: var(--text-primary);
    font-size: 1.5rem;
    padding: 0.5rem;
}

/* Navbar Search */
.navbar-search {
    display: flex;
    align-items: center;
    background: var(--bg-dark);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    overflow: hidden;
    transition: border-color var(--transition-fast);
}

.navbar-search:focus-within {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px var(--primary-glow);
}

.navbar-search input {
    background: transparent;
    border: none;
    padding: 0.625rem 1rem;
    color: var(--text-primary);
    font-size: 0.875rem;
    width: 200px;
    outline: none;
}

.navbar-search input::placeholder {
    color: var(--text-muted);
}

.navbar-search button {
    background: none;
    border: none;
    padding: 0.625rem 1rem;
    color: var(--text-muted);
    transition: color var(--transition-fast);
}

.navbar-search button:hover {
    color: var(--primary);
}

/* ═══════════════════════════════════════════════════════════════════════════
   HERO SECTION
   ═══════════════════════════════════════════════════════════════════════════ */
.hero {
    text-align: center;
    padding: 3rem 0 4rem;
    position: relative;
}

.hero-title {
    font-size: clamp(2.5rem, 5vw, 4rem);
    font-weight: 800;
    margin-bottom: 1rem;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: 0 0 60px var(--primary-glow);
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto 2rem;
}

/* Server Stats Cards */
.server-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-top: 2rem;
}

.stat-card {
    background: var(--gradient-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    text-align: center;
    transition: all var(--transition-normal);
}

.stat-card:hover {
    transform: translateY(-5px);
    border-color: var(--primary);
    box-shadow: var(--shadow-glow);
}

.stat-card-icon {
    font-size: 2rem;
    margin-bottom: 0.75rem;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.stat-card-value {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--text-primary);
    font-family: var(--font-mono);
}

.stat-card-label {
    font-size: 0.875rem;
    color: var(--text-muted);
    margin-top: 0.25rem;
}

/* ═══════════════════════════════════════════════════════════════════════════
   CARDS
   ═══════════════════════════════════════════════════════════════════════════ */
.card {
    background: var(--gradient-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    overflow: hidden;
    transition: all var(--transition-normal);
}

.card:hover {
    border-color: rgba(0, 217, 255, 0.3);
    box-shadow: var(--shadow-lg);
}

.card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid var(--border-color);
    background: rgba(0, 0, 0, 0.2);
}

.card-title {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--text-primary);
}

.card-title i {
    color: var(--primary);
}

.card-body {
    padding: 1.5rem;
}

.card-footer {
    padding: 1rem 1.5rem;
    border-top: 1px solid var(--border-color);
    background: rgba(0, 0, 0, 0.1);
}

/* ═══════════════════════════════════════════════════════════════════════════
   LEADERBOARD
   ═══════════════════════════════════════════════════════════════════════════ */
.leaderboard-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(380px, 1fr));
    gap: var(--card-gap);
}

.leaderboard-card {
    background: var(--gradient-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    overflow: hidden;
    transition: all var(--transition-normal);
}

.leaderboard-card:hover {
    border-color: rgba(0, 217, 255, 0.3);
    transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
}

.leaderboard-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1.25rem 1.5rem;
    background: rgba(0, 0, 0, 0.2);
    border-bottom: 1px solid var(--border-color);
}

.leaderboard-icon {
    width: 42px;
    height: 42px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--gradient-primary);
    border-radius: var(--radius-md);
    font-size: 1.125rem;
    color: white;
}

.leaderboard-title {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--text-primary);
}

.leaderboard-body {
    padding: 0.75rem 0;
}

/* Leaderboard Entry */
.lb-entry {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.75rem 1.5rem;
    transition: background var(--transition-fast);
    cursor: pointer;
}

.lb-entry:hover {
    background: rgba(255, 255, 255, 0.03);
}

.lb-rank {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.875rem;
    border-radius: var(--radius-sm);
    flex-shrink: 0;
}

.lb-rank.rank-1 {
    background: var(--gradient-gold);
    color: #000;
}

.lb-rank.rank-2 {
    background: var(--gradient-silver);
    color: #000;
}

.lb-rank.rank-3 {
    background: var(--gradient-bronze);
    color: #000;
}

.lb-rank.rank-default {
    background: var(--bg-hover);
    color: var(--text-muted);
}

.lb-player {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex: 1;
    min-width: 0;
}

.lb-avatar {
    width: 36px;
    height: 36px;
    border-radius: var(--radius-sm);
    flex-shrink: 0;
    image-rendering: pixelated;
}

.lb-name {
    font-weight: 500;
    color: var(--text-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.lb-value {
    font-family: var(--font-mono);
    font-weight: 600;
    color: var(--primary);
    font-size: 0.9rem;
    white-space: nowrap;
}

/* ═══════════════════════════════════════════════════════════════════════════
   PLAYER PROFILE
   ═══════════════════════════════════════════════════════════════════════════ */
.profile-header {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 3rem 2rem;
    background: var(--gradient-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    margin-bottom: 2rem;
    position: relative;
    overflow: hidden;
}

.profile-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 150px;
    background: var(--gradient-primary);
    opacity: 0.1;
}

.profile-skin {
    position: relative;
    z-index: 1;
    margin-bottom: 1.5rem;
}

.profile-skin img {
    image-rendering: pixelated;
    filter: drop-shadow(0 10px 30px rgba(0, 0, 0, 0.5));
}

.profile-info {
    position: relative;
    z-index: 1;
}

.profile-name {
    font-size: 2rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.profile-uuid {
    font-family: var(--font-mono);
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-bottom: 1rem;
    word-break: break-all;
}

.profile-status {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    border-radius: var(--radius-lg);
    font-size: 0.875rem;
    font-weight: 500;
}

.profile-status.online {
    background: rgba(34, 197, 94, 0.15);
    color: var(--accent);
}

.profile-status.offline {
    background: rgba(239, 68, 68, 0.15);
    color: var(--danger);
}

.profile-status i {
    font-size: 0.5rem;
}

/* Profile Meta */
.profile-meta {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 2rem;
    margin-top: 1.5rem;
}

.profile-meta-item {
    text-align: center;
}

.profile-meta-value {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-primary);
}

.profile-meta-label {
    font-size: 0.8rem;
    color: var(--text-muted);
}

/* ═══════════════════════════════════════════════════════════════════════════
   STATS GRID
   ═══════════════════════════════════════════════════════════════════════════ */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: var(--card-gap);
}

.stats-section {
    margin-bottom: 3rem;
}

.stats-section-title {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 1.5rem;
}

.stats-section-title i {
    color: var(--primary);
}

/* Stat Item */
.stat-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.875rem 0;
    border-bottom: 1px solid var(--border-color);
}

.stat-item:last-child {
    border-bottom: none;
}

.stat-label {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.stat-value {
    font-family: var(--font-mono);
    font-weight: 600;
    color: var(--text-primary);
}

/* Stat Bar */
.stat-bar {
    margin-top: 0.5rem;
}

.stat-bar-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 0.5rem;
}

.stat-bar-label {
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.stat-bar-value {
    font-family: var(--font-mono);
    font-size: 0.875rem;
    color: var(--primary);
}

.progress-bar {
    height: 8px;
    background: var(--bg-dark);
    border-radius: 4px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    border-radius: 4px;
    transition: width var(--transition-slow);
}

.progress-primary {
    background: var(--gradient-primary);
}

.progress-secondary {
    background: linear-gradient(90deg, var(--secondary), var(--primary));
}

.progress-accent {
    background: linear-gradient(90deg, var(--accent), var(--primary));
}

/* ═══════════════════════════════════════════════════════════════════════════
   TABLES
   ═══════════════════════════════════════════════════════════════════════════ */
.data-table {
    width: 100%;
    border-collapse: collapse;
}

.data-table th,
.data-table td {
    padding: 0.875rem 1rem;
    text-align: left;
}

.data-table th {
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-muted);
    background: rgba(0, 0, 0, 0.2);
    border-bottom: 1px solid var(--border-color);
}

.data-table td {
    color: var(--text-secondary);
    border-bottom: 1px solid var(--border-color);
}

.data-table tr:hover td {
    background: rgba(255, 255, 255, 0.02);
}

.data-table tr:last-child td {
    border-bottom: none;
}

/* ═══════════════════════════════════════════════════════════════════════════
   BADGES & TAGS
   ═══════════════════════════════════════════════════════════════════════════ */
.badge {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.25rem 0.625rem;
    font-size: 0.75rem;
    font-weight: 500;
    border-radius: var(--radius-sm);
}

.badge-primary {
    background: rgba(0, 217, 255, 0.15);
    color: var(--primary);
}

.badge-success {
    background: rgba(34, 197, 94, 0.15);
    color: var(--accent);
}

.badge-danger {
    background: rgba(239, 68, 68, 0.15);
    color: var(--danger);
}

.badge-warning {
    background: rgba(245, 158, 11, 0.15);
    color: var(--warning);
}

/* Status Badge */
.status-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.375rem 0.75rem;
    font-size: 0.8rem;
    font-weight: 500;
    border-radius: var(--radius-lg);
}

.status-online {
    background: rgba(34, 197, 94, 0.15);
    color: var(--accent);
}

.status-online i {
    animation: pulse 2s infinite;
}

.status-offline {
    background: rgba(100, 116, 139, 0.15);
    color: var(--text-muted);
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

/* Rank Badge */
.rank-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 28px;
    height: 28px;
    padding: 0 0.5rem;
    font-size: 0.75rem;
    font-weight: 700;
    border-radius: var(--radius-sm);
}

.rank-gold {
    background: var(--gradient-gold);
    color: #000;
}

.rank-silver {
    background: var(--gradient-silver);
    color: #000;
}

.rank-bronze {
    background: var(--gradient-bronze);
    color: #000;
}

.rank-default {
    background: var(--bg-hover);
    color: var(--text-muted);
}

/* ═══════════════════════════════════════════════════════════════════════════
   BUTTONS
   ═══════════════════════════════════════════════════════════════════════════ */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    font-size: 0.9rem;
    font-weight: 500;
    border: none;
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all var(--transition-fast);
}

.btn-primary {
    background: var(--gradient-primary);
    color: white;
    box-shadow: 0 4px 15px var(--primary-glow);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px var(--primary-glow);
}

.btn-secondary {
    background: var(--bg-hover);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
}

.btn-secondary:hover {
    background: var(--bg-dark);
    border-color: var(--primary);
}

.btn-ghost {
    background: transparent;
    color: var(--text-secondary);
}

.btn-ghost:hover {
    color: var(--text-primary);
    background: var(--bg-hover);
}

/* ═══════════════════════════════════════════════════════════════════════════
   PLAYER LIST
   ═══════════════════════════════════════════════════════════════════════════ */
.player-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1rem;
}

.player-card {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem 1.25rem;
    background: var(--gradient-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    transition: all var(--transition-fast);
    cursor: pointer;
    text-decoration: none;
}

.player-card:hover {
    border-color: var(--primary);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.player-card-avatar {
    width: 48px;
    height: 48px;
    border-radius: var(--radius-sm);
    image-rendering: pixelated;
    flex-shrink: 0;
}

.player-card-info {
    flex: 1;
    min-width: 0;
}

.player-card-name {
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.25rem;
}

.player-card-meta {
    font-size: 0.8rem;
    color: var(--text-muted);
}

.player-card-status {
    flex-shrink: 0;
}

/* ═══════════════════════════════════════════════════════════════════════════
   SEARCH
   ═══════════════════════════════════════════════════════════════════════════ */
.search-box {
    max-width: 500px;
    margin: 0 auto 2rem;
}

.search-input-wrapper {
    display: flex;
    background: var(--bg-card);
    border: 2px solid var(--border-color);
    border-radius: var(--radius-xl);
    overflow: hidden;
    transition: border-color var(--transition-fast);
}

.search-input-wrapper:focus-within {
    border-color: var(--primary);
    box-shadow: 0 0 0 4px var(--primary-glow);
}

.search-input-wrapper input {
    flex: 1;
    padding: 1rem 1.5rem;
    background: transparent;
    border: none;
    color: var(--text-primary);
    font-size: 1rem;
    outline: none;
}

.search-input-wrapper input::placeholder {
    color: var(--text-muted);
}

.search-input-wrapper button {
    padding: 1rem 1.5rem;
    background: var(--gradient-primary);
    border: none;
    color: white;
    font-size: 1.1rem;
}

/* ═══════════════════════════════════════════════════════════════════════════
   TABS
   ═══════════════════════════════════════════════════════════════════════════ */
.tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 2rem;
    padding: 0.5rem;
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-color);
}

.tab {
    padding: 0.75rem 1.25rem;
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-secondary);
    background: transparent;
    border: none;
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all var(--transition-fast);
}

.tab:hover {
    color: var(--text-primary);
    background: var(--bg-hover);
}

.tab.active {
    color: white;
    background: var(--gradient-primary);
}

/* ═══════════════════════════════════════════════════════════════════════════
   PAGINATION
   ═══════════════════════════════════════════════════════════════════════════ */
.pagination {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    margin-top: 2rem;
}

.pagination a,
.pagination span {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 40px;
    padding: 0 0.75rem;
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-secondary);
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    transition: all var(--transition-fast);
}

.pagination a:hover {
    color: var(--text-primary);
    border-color: var(--primary);
}

.pagination .active {
    color: white;
    background: var(--gradient-primary);
    border-color: transparent;
}

.pagination .disabled {
    opacity: 0.5;
    pointer-events: none;
}

/* ═══════════════════════════════════════════════════════════════════════════
   FOOTER
   ═══════════════════════════════════════════════════════════════════════════ */
.footer {
    margin-top: auto;
    padding: 2rem 0;
    background: rgba(15, 23, 42, 0.5);
    border-top: 1px solid var(--border-color);
}

.footer-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
    text-align: center;
}

.footer-brand {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--text-primary);
}

.footer-logo {
    width: 32px;
    height: 32px;
}

.footer-links {
    display: flex;
    gap: 2rem;
}

.footer-links a {
    color: var(--text-secondary);
    font-size: 0.9rem;
    transition: color var(--transition-fast);
}

.footer-links a:hover {
    color: var(--primary);
}

.footer-info {
    color: var(--text-muted);
    font-size: 0.8rem;
}

.footer-credits {
    margin-top: 0.5rem;
}

.footer-credits a {
    color: var(--primary);
}

/* ═══════════════════════════════════════════════════════════════════════════
   ERROR PAGES
   ═══════════════════════════════════════════════════════════════════════════ */
.error-page {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 60vh;
    text-align: center;
    padding: 2rem;
}

.error-code {
    font-size: 8rem;
    font-weight: 800;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    line-height: 1;
    margin-bottom: 1rem;
}

.error-title {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.error-message {
    color: var(--text-secondary);
    margin-bottom: 2rem;
}

/* ═══════════════════════════════════════════════════════════════════════════
   LOADING
   ═══════════════════════════════════════════════════════════════════════════ */
.loading {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 3rem;
}

.loading-spinner {
    width: 40px;
    height: 40px;
    border: 3px solid var(--border-color);
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* ═══════════════════════════════════════════════════════════════════════════
   EMPTY STATE
   ═══════════════════════════════════════════════════════════════════════════ */
.empty-state {
    text-align: center;
    padding: 3rem 2rem;
    color: var(--text-muted);
}

.empty-state-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
    opacity: 0.5;
}

.empty-state-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
}

/* ═══════════════════════════════════════════════════════════════════════════
   TOOLTIPS
   ═══════════════════════════════════════════════════════════════════════════ */
[data-tooltip] {
    position: relative;
}

[data-tooltip]::after {
    content: attr(data-tooltip);
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    padding: 0.5rem 0.75rem;
    font-size: 0.75rem;
    font-weight: 500;
    white-space: nowrap;
    color: var(--text-primary);
    background: var(--bg-dark);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    opacity: 0;
    visibility: hidden;
    transition: all var(--transition-fast);
    z-index: 1000;
}

[data-tooltip]:hover::after {
    opacity: 1;
    visibility: visible;
    bottom: calc(100% + 8px);
}

/* ═══════════════════════════════════════════════════════════════════════════
   RESPONSIVE
   ═══════════════════════════════════════════════════════════════════════════ */
@media (max-width: 1024px) {
    .leaderboard-grid {
        grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
    }
}

@media (max-width: 768px) {
    :root {
        --section-gap: 2.5rem;
    }
    
    .navbar .container {
        flex-wrap: wrap;
    }
    
    .navbar-toggle {
        display: block;
    }
    
    .navbar-menu {
        display: none;
        width: 100%;
        flex-direction: column;
        padding-top: 1rem;
        order: 3;
    }
    
    .navbar-menu.active {
        display: flex;
    }
    
    .navbar-search {
        width: 100%;
    }
    
    .navbar-search input {
        width: 100%;
    }
    
    .nav-link {
        width: 100%;
        justify-content: flex-start;
    }
    
    .hero-title {
        font-size: 2rem;
    }
    
    .leaderboard-grid {
        grid-template-columns: 1fr;
    }
    
    .profile-header {
        padding: 2rem 1.5rem;
    }
    
    .profile-meta {
        gap: 1.5rem;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .server-stats {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .tabs {
        overflow-x: auto;
        flex-wrap: nowrap;
    }
    
    .footer-links {
        flex-wrap: wrap;
        justify-content: center;
        gap: 1rem 2rem;
    }
}

@media (max-width: 480px) {
    .server-stats {
        grid-template-columns: 1fr;
    }
    
    .player-grid {
        grid-template-columns: 1fr;
    }
    
    .lb-entry {
        padding: 0.75rem 1rem;
    }
    
    .pagination {
        flex-wrap: wrap;
    }
}

/* ═══════════════════════════════════════════════════════════════════════════
   UTILITIES
   ═══════════════════════════════════════════════════════════════════════════ */
.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.text-primary { color: var(--primary); }
.text-secondary { color: var(--text-secondary); }
.text-muted { color: var(--text-muted); }
.text-success { color: var(--accent); }
.text-danger { color: var(--danger); }
.text-warning { color: var(--warning); }

.font-mono { font-family: var(--font-mono); }
.font-bold { font-weight: 700; }

.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mt-4 { margin-top: 2rem; }

.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.mb-4 { margin-bottom: 2rem; }

.gap-1 { gap: 0.5rem; }
.gap-2 { gap: 1rem; }
.gap-3 { gap: 1.5rem; }

.flex { display: flex; }
.flex-col { flex-direction: column; }
.items-center { align-items: center; }
.justify-center { justify-content: center; }
.justify-between { justify-content: space-between; }

.hidden { display: none; }
.visible { visibility: visible; }
.invisible { visibility: hidden; }

/* ═══════════════════════════════════════════════════════════════════════════
   MINECRAFT ICONS
   ═══════════════════════════════════════════════════════════════════════════ */
.mc-icon {
    display: inline-block;
    vertical-align: middle;
    image-rendering: pixelated;
    image-rendering: -moz-crisp-edges;
    image-rendering: crisp-edges;
    flex-shrink: 0;
}

.stat-with-icon {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.stat-with-icon .mc-icon {
    border-radius: 4px;
    background: rgba(0, 0, 0, 0.2);
    padding: 2px;
}

.card-title .mc-icon {
    margin-right: 0.25rem;
}

/* Leaderboard mit Icons */
.lb-entry .mc-icon {
    border-radius: 4px;
}

/* Icon Hover Effects */
.stat-with-icon:hover .mc-icon {
    transform: scale(1.1);
    transition: transform var(--transition-fast);
}

/* Icon Sizes */
.mc-icon-sm { width: 16px; height: 16px; }
.mc-icon-md { width: 24px; height: 24px; }
.mc-icon-lg { width: 32px; height: 32px; }
.mc-icon-xl { width: 48px; height: 48px; }

/* Button Icons */
.btn .mc-icon {
    margin-right: 0.5rem;
}

.btn-icon-only .mc-icon {
    margin: 0;
}

/* Print Styles */
@media print {
    .navbar,
    .footer,
    .bg-animation {
        display: none;
    }
    
    body {
        background: white;
        color: black;
    }
    
    .card,
    .leaderboard-card {
        border: 1px solid #ccc;
        box-shadow: none;
    }
    
    .mc-icon {
        filter: grayscale(100%);
    }
}
