/* Custom styles for AI Benchmarks */

/* Smooth scrolling */
html {
  scroll-behavior: smooth;
}

/* Dark mode scrollbar */
.dark ::-webkit-scrollbar-track {
  background: #1e293b;
}

.dark ::-webkit-scrollbar-thumb {
  background: #475569;
}

.dark ::-webkit-scrollbar-thumb:hover {
  background: #64748b;
}

/* Custom scrollbar */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

::-webkit-scrollbar-track {
  background: #f1f5f9;
  border-radius: 4px;
}

::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: #94a3b8;
}

/* Boxed Header */
.boxed-header {
  position: sticky;
  top: 0;
  z-index: 50;
  max-width: 56rem;
  margin: 0 auto;
  padding: 0.75rem 1rem 0.5rem;
}

.boxed-header nav {
  padding: 0.5rem 0.75rem;
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid #e5e7eb;
  border-radius: 0.75rem;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  box-shadow: 0 10px 30px -15px rgba(0, 0, 0, 0.25);
}

.dark .boxed-header nav {
  background: rgba(30, 41, 59, 0.6);
  border-color: #334155;
}

/* Theme Toggle */
.theme-toggle {
  width: 2.25rem;
  height: 2.25rem;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 0.5rem;
  transition: background-color 0.2s;
  cursor: pointer;
}

.theme-toggle:hover {
  background-color: #f3f4f6;
}

.dark .theme-toggle:hover {
  background-color: #374151;
}

.theme-toggle svg {
  width: 1.25rem;
  height: 1.25rem;
}

.theme-toggle .icon-moon {
  display: none;
}

.dark .theme-toggle .icon-sun {
  display: none;
}

.dark .theme-toggle .icon-moon {
  display: block;
}

/* Table hover effect */
.table-row-hover:hover {
  background-color: rgba(99, 102, 241, 0.05);
}

.dark .table-row-hover:hover {
  background-color: rgba(99, 102, 241, 0.1);
}

/* Card hover effect */
.card-hover {
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.card-hover:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 40px -10px rgba(0, 0, 0, 0.15);
}

.dark .card-hover:hover {
  box-shadow: 0 10px 40px -10px rgba(0, 0, 0, 0.4);
}

/* Tab styles */
.tab-btn {
  position: relative;
  padding: 0.75rem 1.5rem;
  font-weight: 500;
  color: #64748b;
  transition: color 0.2s ease;
}

.dark .tab-btn {
  color: #94a3b8;
}

.tab-btn:hover {
  color: #6366f1;
}

.dark .tab-btn:hover {
  color: #818cf8;
}

.tab-btn.active {
  color: #6366f1;
}

.dark .tab-btn.active {
  color: #818cf8;
}

.tab-btn.active::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: #6366f1;
  border-radius: 2px 2px 0 0;
}

/* Pulse animation for live indicator */
@keyframes pulse-dot {
  0%, 100% {
    opacity: 1;
  }
  50% {
    opacity: 0.5;
  }
}

.pulse-dot {
  animation: pulse-dot 2s ease-in-out infinite;
}

/* Fade in animation */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.fade-in {
  animation: fadeIn 0.4s ease-out forwards;
}

/* Staggered animation delays */
.stagger-1 { animation-delay: 0.05s; }
.stagger-2 { animation-delay: 0.1s; }
.stagger-3 { animation-delay: 0.15s; }
.stagger-4 { animation-delay: 0.2s; }
.stagger-5 { animation-delay: 0.25s; }
.stagger-6 { animation-delay: 0.3s; }
.stagger-7 { animation-delay: 0.35s; }
.stagger-8 { animation-delay: 0.4s; }
.stagger-9 { animation-delay: 0.45s; }
.stagger-10 { animation-delay: 0.5s; }

/* Number highlight */
.num-highlight {
  font-variant-numeric: tabular-nums;
  font-feature-settings: "tnum";
}

/* Chart container */
.chart-container {
  position: relative;
  height: 400px;
  width: 100%;
}

/* Selection highlight */
.selection-ring {
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.3);
}
