/* Moved from inline styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}
body {
  font-family: Inter, sans-serif;
  background: linear-gradient(135deg, #0f0c29 0, #302b63 50%, #24243e 100%);
  color: #fff;
  min-height: 100vh;
  padding: 20px;
}
.container {
  max-width: 1400px;
  margin: 0 auto;
}
header {
  text-align: center;
  margin-bottom: 40px;
  padding: 20px;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 20px;
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
}
h1 {
  font-size: 2.5rem;
  margin-bottom: 10px;
  background: linear-gradient(135deg, #667eea 0, #764ba2 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}
.subtitle {
  color: #999;
  font-size: 1.1rem;
}
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 20px;
  margin-bottom: 40px;
}
.stat-card {
  background: rgba(255, 255, 255, 0.05);
  border-radius: 16px;
  padding: 24px;
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  transition:
    transform 0.3s ease,
    box-shadow 0.3s ease;
}
.stat-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 30px rgba(139, 92, 246, 0.3);
}
.stat-label {
  color: #999;
  font-size: 0.9rem;
  margin-bottom: 8px;
  text-transform: uppercase;
  letter-spacing: 1px;
}
.stat-value {
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 8px;
}
.stat-change {
  font-size: 0.9rem;
  display: flex;
  align-items: center;
  gap: 5px;
}
.stat-change.positive {
  color: #22c55e;
}
.stat-change.negative {
  color: #ef4444;
}
.charts-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(500px, 1fr));
  gap: 24px;
  margin-bottom: 40px;
}
.chart-container {
  background: rgba(255, 255, 255, 0.05);
  border-radius: 16px;
  padding: 24px;
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  min-height: 350px;
  position: relative;
}
.chart-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
}
.chart-title {
  font-size: 1.2rem;
  font-weight: 600;
}
.timeframe-selector {
  display: flex;
  gap: 8px;
}
.timeframe-btn {
  padding: 6px 12px;
  background: rgba(255, 255, 255, 0.1);
  border: none;
  border-radius: 8px;
  color: #fff;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 0.85rem;
}
.timeframe-btn:hover {
  background: rgba(139, 92, 246, 0.3);
}
.timeframe-btn.active {
  background: rgba(139, 92, 246, 0.6);
}
.chart-wrapper {
  position: relative;
  height: 300px;
}
canvas {
  max-height: 100%;
}
.loading {
  text-align: center;
  padding: 40px;
  color: #999;
}
.loading::after {
  content: '...';
  animation: dots 1.5s steps(4, end) infinite;
}
@keyframes dots {
  0%,
  20% {
    content: '.';
  }
  40% {
    content: '..';
  }
  100%,
  60% {
    content: '...';
  }
}
.nav-link {
  display: inline-block;
  margin: 20px 0;
  padding: 12px 24px;
  background: rgba(139, 92, 246, 0.2);
  border-radius: 12px;
  color: #fff;
  text-decoration: none;
  transition: all 0.3s ease;
}
.nav-link:hover {
  background: rgba(139, 92, 246, 0.4);
  transform: translateX(-5px);
}
@media (max-width: 768px) {
  h1 {
    font-size: 1.8rem;
  }
  .charts-grid {
    grid-template-columns: 1fr;
  }
  .chart-wrapper {
    height: 250px;
  }
  .stats-grid {
    grid-template-columns: 1fr;
  }
}
.insights-section {
  background: rgba(255, 255, 255, 0.05);
  border-radius: 16px;
  padding: 24px;
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  margin-top: 40px;
}
.insights-title {
  font-size: 1.5rem;
  margin-bottom: 20px;
}
.insight-item {
  padding: 16px;
  margin-bottom: 12px;
  background: rgba(255, 255, 255, 0.03);
  border-radius: 12px;
  border-left: 4px solid #8b5cf6;
}
.insight-item h4 {
  margin-bottom: 8px;
  color: #8b5cf6;
}
.insight-item p {
  color: #ccc;
  line-height: 1.6;
}
body::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image:
    radial-gradient(2px 2px at 20px 30px, #eee, transparent),
    radial-gradient(2px 2px at 40px 70px, #fff, transparent),
    radial-gradient(1px 1px at 90px 40px, #eee, transparent),
    radial-gradient(1px 1px at 130px 80px, #fff, transparent),
    radial-gradient(2px 2px at 160px 30px, #ddd, transparent);
  background-repeat: repeat;
  background-size: 200px 100px;
  animation: twinkle 4s ease-in-out infinite alternate;
  z-index: -1;
}
@keyframes twinkle {
  0% {
    filter: brightness(0.3);
  }
  100% {
    filter: brightness(0.8);
  }
}
