:root {
    --bg-color: #0f172a;
    --card-bg: rgba(30, 41, 59, 0.7);
    --accent-color: #38bdf8;
    --text-primary: #f8fafc;
    --text-secondary: #94a3b8;
    --rank-1: #fbbf24;
    --rank-2: #e2e8f0;
    --rank-3: #94a3b8;
    --card-border: rgba(255, 255, 255, 0.1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Outfit', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-primary);
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
}

.background-blobs {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
}

.blob {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.4;
    animation: move 20s infinite alternate;
}

.blob-1 {
    width: 400px;
    height: 400px;
    background: #3b82f6;
    top: -100px;
    left: -100px;
}

.blob-2 {
    width: 300px;
    height: 300px;
    background: #a855f7;
    bottom: -50px;
    right: -50px;
    animation-delay: -5s;
}

.blob-3 {
    width: 250px;
    height: 250px;
    background: #06b6d4;
    top: 50%;
    left: 50%;
    animation-delay: -10s;
}

@keyframes move {
    from { transform: translate(0, 0) scale(1); }
    to { transform: translate(100px, 100px) scale(1.2); }
}

.dashboard-container {
    width: 95%;
    max-width: 1000px;
    padding: 2rem;
    z-index: 10;
}

header {
    text-align: center;
    margin-bottom: 3rem;
}

h1 {
    font-size: 3rem;
    font-weight: 700;
    letter-spacing: -1px;
    margin-bottom: 0.5rem;
}

.accent {
    color: var(--accent-color);
}

.subtitle {
    color: var(--text-secondary);
    font-size: 1.1rem;
    font-weight: 300;
}

.leaderboard-card {
    background: var(--card-bg);
    backdrop-filter: blur(16px);
    border: 1px solid var(--card-border);
    border-radius: 24px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    overflow: hidden;
    animation: slideUp 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes slideUp {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}

.table-header {
    display: grid;
    grid-template-columns: 60px 1fr 90px 90px 70px 100px;
    padding: 1.25rem 1.5rem;
    background: rgba(255, 255, 255, 0.05);
    border-bottom: 1px solid var(--card-border);
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.8rem;
    letter-spacing: 1px;
    color: var(--text-secondary);
}

.leaderboard-rows {
    min-height: 200px;
}

.user-row {
    display: grid;
    grid-template-columns: 60px 1fr 90px 90px 70px 100px;
    padding: 1.25rem 1.5rem;
    align-items: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.03);
    transition: background 0.3s ease;
}

.user-row:hover {
    background: rgba(255, 255, 255, 0.03);
}

.user-row:last-child {
    border-bottom: none;
}

.rank-badge {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-weight: 700;
    font-size: 0.9rem;
    background: rgba(255, 255, 255, 0.1);
}

.user-row[data-rank="1"] .rank-badge { background: var(--rank-1); color: #000; }
.user-row[data-rank="2"] .rank-badge { background: var(--rank-2); color: #000; }
.user-row[data-rank="3"] .rank-badge { background: #cd7f32; color: #fff; }

.user-name {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-primary);
}

.val-outbound, .val-inbound {
    font-weight: 400;
    color: var(--text-secondary);
}

.val-total {
    font-weight: 700;
    font-size: 1.3rem;
    color: var(--accent-color);
}

.val-talktime {
    font-weight: 400;
    font-size: 0.95rem;
    color: var(--text-secondary);
    font-family: 'Courier New', monospace;
}

.loading {
    padding: 4rem;
    text-align: center;
    color: var(--text-secondary);
    font-style: italic;
}

footer {
    margin-top: 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.status-indicator {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.dot {
    width: 8px;
    height: 8px;
    background: #10b981;
    border-radius: 50%;
    display: inline-block;
    box-shadow: 0 0 10px #10b981;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% { opacity: 0.5; }
    50% { opacity: 1; }
    100% { opacity: 0.5; }
}

.brand {
    font-weight: 700;
    letter-spacing: 3px;
    opacity: 0.3;
}
