/* Speed Leaderboard Styles */

.speed-stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1rem;
    margin-bottom: 2rem;
}

.speed-stat-card {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1.25rem 1.5rem;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    backdrop-filter: blur(8px);
}

.speed-stat-icon {
    width: 44px;
    height: 44px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.speed-stat-icon svg {
    width: 22px;
    height: 22px;
}

.speed-stat-icon.fastest {
    background: rgba(139, 92, 246, 0.15);
    color: #a78bfa;
}

.speed-stat-icon.tps {
    background: rgba(59, 130, 246, 0.15);
    color: #60a5fa;
}

.speed-stat-icon.ttft {
    background: rgba(16, 185, 129, 0.15);
    color: #34d399;
}

.speed-stat-icon.models-count {
    background: rgba(245, 158, 11, 0.15);
    color: #fbbf24;
}

.speed-stat-content {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
}

.speed-stat-label {
    font-size: 0.75rem;
    color: var(--text-tertiary);
    text-transform: uppercase;
    letter-spacing: 0.03em;
    font-weight: 600;
}

.speed-stat-value {
    font-size: 1.1rem;
    font-weight: 700;
    font-family: 'Outfit', sans-serif;
    color: var(--text-primary);
}

/* Controls */
.speed-controls {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
}

.speed-sort-group {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.speed-sort-group label {
    font-size: 0.85rem;
    color: var(--text-secondary);
    font-weight: 500;
}

.speed-sort-group select {
    font-size: 0.85rem;
    padding: 0.5rem 2rem 0.5rem 0.75rem;
    border-radius: 8px;
    background-color: var(--card-bg);
    border: 1px solid var(--border-color);
    color: var(--text-primary);
    font-family: inherit;
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%2394a3b8' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.75rem center;
}

/* Speed Table */
.speed-table-section {
    margin-bottom: 3rem;
}

.speed-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9rem;
}

.speed-table thead th {
    text-align: left;
    padding: 0.75rem 1rem;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-tertiary);
    border-bottom: 1px solid var(--border-color);
    font-weight: 600;
    white-space: nowrap;
}

.speed-table tbody tr {
    transition: background 0.15s ease;
    border-bottom: 1px solid var(--border-color);
}

.speed-table tbody tr:hover {
    background: var(--card-bg);
}

.speed-table tbody td {
    padding: 0.85rem 1rem;
    vertical-align: middle;
}

.speed-rank {
    font-weight: 700;
    font-family: 'Outfit', sans-serif;
    color: var(--text-secondary);
    font-size: 0.85rem;
}

.speed-rank.gold { color: #fbbf24; }
.speed-rank.silver { color: #94a3b8; }
.speed-rank.bronze { color: #d97706; }

.speed-model-name {
    font-weight: 600;
    color: var(--text-primary);
}

.speed-value {
    font-weight: 600;
    font-family: 'Outfit', sans-serif;
}

.speed-value.highlight {
    color: #a78bfa;
}

.speed-value.na {
    color: var(--text-tertiary);
    font-weight: 400;
}

/* Throughput Bar */
.throughput-bar-container {
    width: 100%;
    max-width: 200px;
    height: 8px;
    background: var(--border-color);
    border-radius: 4px;
    overflow: hidden;
}

.throughput-bar-fill {
    height: 100%;
    border-radius: 4px;
    background: linear-gradient(90deg, #a78bfa, #6366f1);
    transition: width 0.6s ease;
}

/* Info Section */
.speed-info-section {
    margin-bottom: 3rem;
}

.info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1rem;
    margin-top: 1.25rem;
}

.info-card {
    padding: 1.5rem;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 12px;
}

.info-card h3 {
    font-size: 1rem;
    font-weight: 700;
    font-family: 'Outfit', sans-serif;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.info-card p {
    font-size: 0.85rem;
    color: var(--text-secondary);
    line-height: 1.5;
}

/* Responsive */
@media (max-width: 768px) {
    .speed-stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .speed-table {
        font-size: 0.8rem;
    }
    
    .speed-table thead th,
    .speed-table tbody td {
        padding: 0.6rem 0.5rem;
    }
    
    .throughput-bar-container {
        max-width: 100px;
    }
}
