/* ================= TIMELINE VARIABLES ================= */
:root {
  --accent: #f74670;
  --gradient: linear-gradient(90deg, #e10c5d 0%, #f9681c 100%);
}

/* ================= TIMELINE SECTION ================= */
section#timeline-section {
  position: relative;
  background-color: #ffeff1;
  padding: 100px 20px;
  border-top-left-radius: 120px;
  border-top-right-radius: 120px;
  border-bottom-left-radius: 100px;
  border-bottom-right-radius: 100px;
  overflow: hidden;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.08);
  z-index: 1;
}

/* Soft blend edges */
section#timeline-section::before,
section#timeline-section::after {
  content: "";
  position: absolute;
  left: 0;
  width: 100%;
  height: 80px;
  z-index: 2;
}

section#timeline-section::before { top: 0; }
section#timeline-section::after { bottom: 0; }

/* ================= TITLE ================= */
section#timeline-section h2 {
  text-align: center;
  font-size: 3rem;
  margin-bottom: 80px;
  background: var(--gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* ================= TIMELINE CONTAINER ================= */
.timeline {
  position: relative;
  max-width: 1100px;
  margin: auto;
}

/* Center vertical line (desktop) */
.timeline::before {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 4px;
  background: var(--accent);
  border-radius: 2px;
}

/* ================= TIMELINE ITEMS ================= */
.timeline-item {
  position: relative;
  width: 50%;
  padding: 20px 40px;
  box-sizing: border-box;

  /* animation prep */
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.timeline-item.show {
  opacity: 1;
  transform: translateY(0);
}

.timeline-item:nth-child(odd) {
  left: 0;
  text-align: right;
}

.timeline-item:nth-child(even) {
  left: 50%;
}

/* ================= CONTENT BOX ================= */
.content {
  background: #fff;
  border-radius: 20px;
  padding: 25px 30px;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.08);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  position: relative;
  z-index: 1;
}

/* Arrows */
.timeline-item:nth-child(odd) .content::after {
  content: "";
  position: absolute;
  top: 25px;
  right: -15px;
  border-width: 10px;
  border-style: solid;
  border-color: transparent transparent transparent #000;
}

.timeline-item:nth-child(even) .content::after {
  content: "";
  position: absolute;
  top: 25px;
  left: -15px;
  border-width: 10px;
  border-style: solid;
  border-color: transparent #000 transparent transparent;
}

/* Hover */
.content:hover {
  transform: scale(1.03);
  box-shadow: 0 10px 30px rgba(247, 70, 112, 0.25);
}

.content h3 {
  margin-bottom: 10px;
  background: var(--gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  font-weight: 600;
  font-size: 20px;
}

.content p {
  font-size: 15px;
  line-height: 1.6;
  color: #333;
  margin-bottom: 10px;
}

.date {
  display: inline-block;
  margin-top: 10px;
  font-size: 14px;
  color: #666;
  font-weight: 600;
}

/* ================= VIEW LINK ================= */
.view-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 12px;
  font-weight: 600;
  color: var(--accent);
  font-size: 0.95rem;
  text-decoration: none;
  position: relative;
}

.view-btn::after {
  content: "";
  position: absolute;
  bottom: -3px;
  left: 0;
  width: 0%;
  height: 2px;
  background: var(--accent);
  transition: width 0.3s ease;
}

.view-btn:hover::after {
  width: 100%;
}

.view-btn span {
  transition: transform 0.3s ease;
}

.view-btn:hover span {
  transform: translateX(5px);
}

/* ================= RESPONSIVE ================= */

/* Tablets */
@media (max-width: 1024px) {

  .timeline::before {
    left: 40px;
    transform: none;
  }

  .timeline-item {
    width: 100%;
    left: 0 !important;
    text-align: left;
    padding-left: 90px;
    margin-bottom: 60px;
  }

  /* All arrows point left */
  .timeline-item .content::after {
    left: -15px !important;
    right: auto !important;
    border-color: transparent #000 transparent transparent !important;
  }
}

/* Mobile */
@media (max-width: 768px) {

  section#timeline-section {
    padding: 80px 20px;
    border-top-left-radius: 80px;
    border-top-right-radius: 80px;
    border-bottom-left-radius: 60px;
    border-bottom-right-radius: 60px;
  }

  section#timeline-section h2 {
    font-size: 2.4rem;
    margin-bottom: 60px;
  }

  .timeline::before {
    left: 28px;
  }

  .timeline-item {
    padding-left: 80px;
  }

  .content {
    padding: 20px;
  }
}

/* Small phones */
@media (max-width: 480px) {

  section#timeline-section {
    padding: 60px 16px;
  }

  section#timeline-section h2 {
    font-size: 2rem;
    margin-bottom: 40px;
  }

  .timeline::before {
    left: 18px;
  }

  .timeline-item {
    padding-left: 65px;
  }

  .content {
    padding: 16px;
  }

  .content h3 {
    font-size: 16px;
  }

  .content p {
    font-size: 13px;
  }

  .date {
    font-size: 12px;
  }
}
