/* Fantasy Playoff Tracker - Sleek Compact Dark Design */

:root {
    --bg-primary: #0d0d0f;
    --bg-secondary: #1a1a1c;
    --bg-tertiary: #242426;
    --bg-elevated: #2e2e30;

    --text-primary: #ffffff;
    --text-secondary: #9ca3af;
    --text-tertiary: #6b7280;

    --accent-primary: #3b82f6;
    --accent-secondary: #60a5fa;
    --accent-success: #10b981;
    --accent-warning: #f59e0b;
    --accent-gold: #fbbf24;

    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.3);
    --shadow-md: 0 2px 4px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 4px 8px rgba(0, 0, 0, 0.5);

    --radius-sm: 6px;
    --radius-md: 8px;
    --radius-lg: 10px;

    --transition-fast: 0.1s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-base: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Inter', system-ui, sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.5;
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    font-size: 14px;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 1rem 1rem;
}

/* Header */
.header {
    background: var(--bg-secondary);
    border-bottom: 1px solid var(--bg-tertiary);
    padding: 0.75rem 0;
}

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

.logo {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--accent-primary);
    letter-spacing: -0.3px;
}

.league-name {
    font-size: 1.75rem;
    font-weight: 700;
    margin-bottom: 0.25rem;
    letter-spacing: -0.5px;
}

.league-meta {
    color: var(--text-secondary);
    font-size: 0.85rem;
    margin-bottom: 1rem;
}

/* Card Component */
.card {
    background: var(--bg-secondary);
    border-radius: var(--radius-md);
    padding: 1rem;
    border: 1px solid var(--bg-tertiary);
}

.card-title {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
    color: var(--text-primary);
}

/* Standings Table */
.standings-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9rem;
}

.standings-table thead {
    background: var(--bg-tertiary);
}

.standings-table th {
    padding: 0.5rem 0.75rem;
    text-align: left;
    font-weight: 600;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--text-tertiary);
    border-bottom: 1px solid var(--bg-elevated);
}

.standings-table th:first-child {
    width: 40px;
    text-align: center;
}

.standings-table th:last-child {
    text-align: right;
}

.standings-table tbody tr {
    border-bottom: 1px solid var(--bg-tertiary);
    transition: background var(--transition-fast);
}

.standings-table tbody tr:hover {
    background: var(--bg-tertiary);
}

.standings-table td {
    padding: 0.6rem 0.75rem;
    color: var(--text-primary);
}

.standings-table td:first-child {
    text-align: center;
}

.standings-table td:last-child {
    text-align: right;
}

.rank {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    border-radius: 4px;
    background: var(--bg-elevated);
    font-weight: 700;
    font-size: 0.8rem;
}

.rank.top {
    background: var(--accent-gold);
    color: var(--bg-primary);
}

.rank.top-3 {
    background: var(--accent-primary);
    color: white;
}

.team-name {
    font-weight: 500;
    color: var(--text-primary);
    cursor: pointer;
    transition: color var(--transition-fast);
    text-decoration: none;
}

.team-name:hover {
    color: var(--accent-primary);
}

.points {
    font-weight: 600;
    font-variant-numeric: tabular-nums;
    color: var(--text-secondary);
}

.points.total {
    font-size: 1rem;
    color: var(--accent-success);
    font-weight: 700;
}

/* Roster Grid */
.roster-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 0.75rem;
    margin-top: 0.75rem;
}

.player-card {
    background: var(--bg-tertiary);
    border-radius: var(--radius-sm);
    padding: 0.75rem;
    border: 1px solid var(--bg-elevated);
    transition: all var(--transition-fast);
}

.player-card:hover {
    border-color: var(--accent-primary);
    background: var(--bg-elevated);
}

.player-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
}

.player-name {
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--text-primary);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    max-width: 140px;
}

.player-position {
    display: inline-block;
    padding: 0.15rem 0.4rem;
    background: var(--accent-primary);
    border-radius: 3px;
    font-size: 0.65rem;
    font-weight: 700;
    color: white;
    letter-spacing: 0.3px;
}

.player-team {
    color: var(--text-tertiary);
    font-size: 0.75rem;
    margin-bottom: 0.5rem;
    font-weight: 500;
}

.player-stats {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.5rem;
}

.stat-item {
    display: flex;
    flex-direction: column;
}

.stat-label {
    font-size: 0.65rem;
    color: var(--text-tertiary);
    text-transform: uppercase;
    letter-spacing: 0.3px;
    margin-bottom: 0.15rem;
}

.stat-value {
    font-size: 1rem;
    font-weight: 700;
    color: var(--accent-success);
    font-variant-numeric: tabular-nums;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    padding: 0.5rem 1rem;
    background: var(--accent-primary);
    color: white;
    border: none;
    border-radius: var(--radius-sm);
    font-weight: 600;
    font-size: 0.85rem;
    cursor: pointer;
    transition: all var(--transition-fast);
    text-decoration: none;
}

.btn:hover {
    background: var(--accent-secondary);
}

.btn-sm {
    padding: 0.35rem 0.75rem;
    font-size: 0.75rem;
}

/* Utility Classes */
.text-center {
    text-align: center;
}

.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }

/* Responsive */
@media (max-width: 768px) {
    .container {
        padding: 0.75rem;
    }

    .league-name {
        font-size: 1.5rem;
    }

    .standings-table {
        font-size: 0.8rem;
    }

    .standings-table th,
    .standings-table td {
        padding: 0.4rem 0.5rem;
    }

    .roster-grid {
        grid-template-columns: 1fr;
    }
}
