/* Chart wrapper for Chart.js */
.chart-wrapper {
  position: relative;
  width: 100%;
  height: 300px;
  max-width: 2000px;
  margin: 0 auto;
  padding: 1rem 0;
}

.chart-title {
  max-width: 2000px;
  margin: auto;
}

/* Timeline Styles */
.timeline-container {
  max-width: 1000px;
  margin: 0 auto;
  padding: 2rem 0;
  position: relative;
}

.timeline-container::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 0;
  bottom: 0;
  width: 3px;
  background: var(--gold);
  transform: translateX(-50%);
}

.timeline-item {
  display: flex;
  align-items: center;
  margin-bottom: 3rem;
  position: relative;
}

.timeline-item:nth-child(odd) {
  flex-direction: row;
}

.timeline-item:nth-child(even) {
  flex-direction: row-reverse;
}

.timeline-year {
  flex: 0 0 120px;
  text-align: center;
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--gold);
  background: white;
  border: 3px solid var(--gold);
  border-radius: 50%;
  width: 120px;
  height: 120px;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2;
  position: relative;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.timeline-content {
  flex: 1;
  padding: 1.5rem 2rem;
  background: white;
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  margin: 0 2rem;
  border-left: 4px solid var(--primary);
}

.timeline-item:nth-child(even) .timeline-content {
  border-left: none;
  border-right: 4px solid var(--primary);
}

.timeline-content h4 {
  color: var(--primary);
  margin-bottom: 0.5rem;
  font-size: 1.2rem;
}

.timeline-content p {
  color: var(--silver);
  line-height: 1.6;
  margin: 0;
}

/* Projection Chart Styles */
.projection-chart {
  display: flex;
  align-items: flex-end;
  justify-content: space-around;
  height: 300px;
  padding: 2rem 1rem;
  background: white;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.projection-bar {
  flex: 1;
  max-width: 120px;
  background: var(--gold);
  border-radius: 8px 8px 0 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  padding-top: 1rem;
  margin: 0 0.5rem;
  position: relative;
  transition: transform var(--animation-duration) var(--transition-easing);
}

.projection-bar:hover {
  transform: translateY(-5px);
}

.projection-label {
  color: white;
  font-weight: 700;
  font-size: 1.1rem;
  margin-bottom: 0.5rem;
}

.projection-year {
  position: absolute;
  bottom: -2rem;
  color: var(--silver);
  font-weight: 600;
}

/* Responsive Design */
@media (max-width: 800px) {
  .timeline-container::before {
    left: 60px;
  }

  .timeline-item,
  .timeline-item:nth-child(even) {
    flex-direction: row;
  }

  .timeline-year {
    flex: 0 0 80px;
    width: 80px;
    height: 80px;
    font-size: 1.2rem;
  }

  .timeline-content {
    margin: 0 1rem 0 2rem;
    border-left: 4px solid var(--primary);
    border-right: none;
  }

  .timeline-item:nth-child(even) .timeline-content {
    border-left: 4px solid var(--primary);
    border-right: none;
  }

  .projection-chart {
    height: 250px;
    padding: 1.5rem 0.5rem;
  }

  .projection-bar {
    max-width: 80px;
  }

  .projection-label {
    font-size: 0.9rem;
  }
}

/* ======================================== DARK MODE ======================================== */

.body-dark .timeline-year {
  background: var(--dark-bg);
  border-color: var(--gold);
}

.body-dark .timeline-content {
  background: var(--dark-bg);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
}

.body-dark .timeline-content h4 {
  color: var(--tertiary);
}

.body-dark .projection-chart {
  background: var(--dark-bg);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.body-dark .projection-year {
  color: var(--white);
}