/* Comparator Specific Styles */

.comparator-grid {
    display: grid;
    gap: 1rem;
}

.comparator-grid.grid-cols-2 {
    grid-template-columns: minmax(200px, 250px) minmax(200px, 1fr);
}
.comparator-grid.grid-cols-3 {
    grid-template-columns: minmax(200px, 250px) repeat(2, minmax(200px, 1fr));
}
.comparator-grid.grid-cols-4 {
    grid-template-columns: minmax(200px, 250px) repeat(3, minmax(200px, 1fr));
}
.comparator-grid.grid-cols-5 {
    grid-template-columns: minmax(200px, 250px) repeat(4, minmax(200px, 1fr));
}

/* Simulation cards */
.simulation-card {
    background: white;
    border-radius: 8px;
    border: 1px solid #e5e7eb;
    padding: 1rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    transition: all 0.2s ease;
}

.simulation-card:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* Régime selector */
.regime-selector {
    font-size: 0.875rem;
}

.regime-selector:disabled {
    background-color: #f3f4f6;
    cursor: not-allowed;
}

/* Metric values */
.metric-value {
    font-size: 1.125rem;
    font-weight: 600;
    transition: color 0.2s ease;
}

.metric-value.is-best {
    color: #059669;
    position: relative;
}

.metric-value.is-best::after {
    content: "👑";
    position: absolute;
    right: -20px;
    top: 0;
    font-size: 0.875rem;
    opacity: 0.7;
}

/* Metric labels */
.metric-label {
    font-weight: 600;
    color: #374151;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* Loading states */
.loading-shimmer {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
}

@keyframes shimmer {
    0% {
        background-position: -200% 0;
    }
    100% {
        background-position: 200% 0;
    }
}

/* Position indicators */
.position-indicator {
    background: #3b82f6;
    color: white;
    width: 1.5rem;
    height: 1.5rem;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: 600;
}

/* Controls bar */
.controls-bar {
    background: white;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    padding: 1rem;
    margin-bottom: 1.5rem;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .comparator-grid {
        grid-template-columns: 1fr;
        gap: 0.75rem;
    }

    .simulation-card {
        padding: 0.75rem;
    }

    .metric-value {
        font-size: 1rem;
    }
}

/* Dark mode support */
.dark .simulation-card {
    background: #374151;
    border-color: #4b5563;
    color: white;
}

.dark .controls-bar {
    background: #374151;
    border-color: #4b5563;
}

.dark .metric-label {
    color: #d1d5db;
}

.dark .loading-shimmer {
    background: linear-gradient(90deg, #4b5563 25%, #6b7280 50%, #4b5563 75%);
    background-size: 200% 100%;
}

/* Error states */
.error-value {
    color: #dc2626;
    font-style: italic;
}

/* Success highlighting */
.text-success {
    color: #059669 !important;
    font-weight: 700 !important;
}

/* Modal improvements */
.metrics-modal {
    backdrop-filter: blur(4px);
}

/* Button improvements */
.btn-comparator {
    background: #3b82f6;
    color: white;
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 6px;
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.btn-comparator:hover {
    background: #2563eb;
}

.btn-comparator:disabled {
    background: #9ca3af;
    cursor: not-allowed;
}

/* Scrollbar styling for horizontal scroll */
.overflow-x-auto::-webkit-scrollbar {
    height: 8px;
}

.overflow-x-auto::-webkit-scrollbar-track {
    background: #f1f5f9;
    border-radius: 4px;
}

.overflow-x-auto::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 4px;
}

.overflow-x-auto::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}
