* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: #0d1117;
    color: #e6edf3;
    padding: 20px;
    min-height: 100vh;
}

.container { max-width: 1200px; margin: 0 auto; }

header {
    text-align: center;
    padding: 30px 0 20px;
    border-bottom: 1px solid #30363d;
    margin-bottom: 30px;
}

header h1 {
    font-size: 2rem;
    font-weight: 700;
    background: linear-gradient(135deg, #f7971e, #ffd200);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

#lastUpdate { color: #8b949e; font-size: 0.9rem; margin-top: 8px; }

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 16px;
    margin-bottom: 30px;
}

.stat-card {
    background: #161b22;
    border: 1px solid #30363d;
    border-radius: 12px;
    padding: 20px;
    text-align: center;
}

.stat-number {
    font-size: 2rem;
    font-weight: 700;
    color: #f7971e;
}

.stat-label { font-size: 0.85rem; color: #8b949e; margin-top: 4px; }

.chart-section {
    background: #161b22;
    border: 1px solid #30363d;
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 30px;
}

.chart-section h2 { font-size: 1.1rem; margin-bottom: 16px; }

.chart-container {
    display: flex;
    align-items: flex-end;
    gap: 4px;
    height: 180px;
    overflow-x: auto;
    padding: 4px 0;
}

.bar-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    flex: 0 0 28px;
    min-width: 20px;
}

.bar {
    width: 100%;
    background: linear-gradient(180deg, #f7971e, #ffd200);
    border-radius: 3px 3px 0 0;
    transition: height 0.3s;
    min-height: 2px;
}

.bar-label {
    font-size: 0.5rem;
    color: #8b949e;
    margin-top: 4px;
    text-align: center;
}

.players-section {
    background: #161b22;
    border: 1px solid #30363d;
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 30px;
}

.players-section h2 { font-size: 1.1rem; margin-bottom: 12px; }

.player-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.player-tag {
    background: #238636;
    color: white;
    padding: 4px 14px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 500;
}

.player-tag.empty {
    background: #30363d;
    color: #8b949e;
}

.records-section {
    background: #161b22;
    border: 1px solid #30363d;
    border-radius: 12px;
    padding: 20px;
}

.records-section h2 { font-size: 1.1rem; margin-bottom: 12px; }

.table-wrapper { overflow-x: auto; }

table { width: 100%; border-collapse: collapse; font-size: 0.9rem; }

thead th {
    text-align: left;
    padding: 10px 12px;
    border-bottom: 2px solid #30363d;
    color: #8b949e;
    font-weight: 500;
}

tbody td {
    padding: 8px 12px;
    border-bottom: 1px solid #21262d;
}

tbody tr:hover { background: #1c2128; }

.status-empty { color: #8b949e; font-style: italic; }
.status-error { color: #f85149; }
.loading { color: #8b949e; text-align: center; padding: 20px; }

@media (max-width: 600px) {
    header h1 { font-size: 1.4rem; }
    .stats-grid { grid-template-columns: repeat(2, 1fr); }
    .stat-number { font-size: 1.4rem; }
    .chart-container { height: 120px; }
    .bar-wrapper { flex: 0 0 18px; min-width: 14px; }
}