#timeline {
  padding: 1rem 2rem 2rem;
  /* background-image: url("./../img/display/fondoTimeline.jpg");
  background-size: auto;
  background-position: center;
  background-repeat: repeat;
  overflow: hidden; */
}

#timeline h2 {
  text-align: center;
  font-size: 2rem;
  margin-bottom: 1rem;
}

#timeline p {
  text-align: center;
  margin: auto;
  max-width: 70%;
  font-size: 1rem;
  margin-bottom: 1rem;
}

.timeline-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-evenly;
  gap: 1rem;
  padding: 2rem;
}

.timeline-card {
  flex: 1 1 calc(30% - 3rem);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  min-width: 180px;
  max-width: calc(20% - 3rem);
  /* background-color: #111827; */
  background-image: url("./../img/games/FondoCardGames.jpg");
  background-size: 120% auto;
  background-position: center;
  background-repeat: no-repeat;
  overflow: hidden;
  padding: 0.75em;
  border-radius: 1.25rem;
  box-shadow: 0 2px 5px rgb(0, 0, 0);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  text-align: center;
  color: #5b3118;
  position: relative;
  overflow: hidden;
}

.timeline-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  height: 4px;
  width: 60px;
  background: #007bff;
  border-radius: 2px;
  margin-bottom: 1rem;
}

.timeline-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 12px 30px rgb(0, 0, 0);
}

.timeline-card .years {
  font-size: clamp(15px, 0.9vw, 24px);
  font-weight: bold;
  margin-bottom: 0.75rem;
}

.timeline-card h3 {
  font-size: clamp(20px, 1.5vw, 24px);
  margin: 0.5rem 0;
}

.timeline-card p {
  font-size: clamp(17px, 1vw, 24px);
  line-height: 1.5;
}

.timeline-card .gameIcon {
  width: 100%;
}

@media (max-width: 768px) {
  .timeline-card {
    min-width: 150px;
    /* padding: 0.8rem; */
    /* font-size: 0.85rem; */
  }

  .timeline-bar {
    height: 220px;
  }
}
