/* ==============================================
   ROADMAP & MILESTONE SECTION
   ============================================== */
.roadmap-section {
  background: linear-gradient(180deg, #f9fafb 0%, #ffffff 100%);
  padding: 0px 1%;
  font-family: "Poppins", sans-serif;
  position: relative;
  overflow-x: hidden;
}

/* ---------- Section Title ---------- */
.section-title {
  font-size: 2.2rem;
  font-weight: 700;
  color: #222;
  text-align: center;
  margin-bottom: 0px;
  letter-spacing: 0.5px;
  position: relative;
}

.section-title::after {
  content: "";
  display: block;
  width: 0px;
  height: 4px;
  background: #16a34a;
  margin: 12px auto 0;
  border-radius: 2px;
}

/* ---------- Timeline Wrapper (Horizontal Scroll on Desktop) ---------- */
.timeline-container {
  display: flex;
  justify-content: flex-start;
  align-items: flex-start;
  gap: 50px;
  overflow-x: auto;
  overflow-y: hidden;
  padding-bottom: 3px;
  scroll-snap-type: x mandatory;
  scrollbar-width: thin;
  scrollbar-color: #16a34a #e0e0e0;
  position: relative;
}

/* Smooth scrolling for modern browsers */
.timeline-container {
  scroll-behavior: smooth;
}

.timeline-container::-webkit-scrollbar {
  height: 8px;
}
.timeline-container::-webkit-scrollbar-thumb {
  background: #16a34a;
  border-radius: 5px;
}
.timeline-container::-webkit-scrollbar-track {
  background: #e0e0e0;
}

/* ---------- Central Line for Desktop ---------- */
.timeline-container::before {
  content: "";
  position: absolute;
  top: 85px;
  left: 0;
  width: 100%;
  height: 4px;
  background: #16a34a;
  border-radius: 3px;
  z-index: 0;
}

/* ---------- Timeline Items ---------- */
.timeline-item {
  flex: 0 0 300px;
  scroll-snap-align: center;
  position: relative;
  text-align: center;
  z-index: 2;
  transition: transform 0.4s ease;
}

.timeline-item:hover {
  transform: translateY(-6px);
}

/* ---------- Dot Connector ---------- */
.timeline-item::before {
  content: "";
  position: absolute;
  top: 72px;
  left: 50%;
  transform: translateX(-50%);
  width: 22px;
  height: 22px;
  background: #16a34a;
  border: 3px solid #fff;
  border-radius: 50%;
  box-shadow: 0 0 0 6px rgba(22, 163, 74, 0.2);
  z-index: 3;
}

/* ---------- Content Box ---------- */
.timeline-content {
  background: #fff;
  padding: 25px 20px;
  border-radius: 12px;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.08);
  transition: all 0.3s ease;
  width: 100%;
  max-width: 320px;
  position: relative;
  margin-top: 120px;
}

.timeline-content:hover {
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.12);
}

.timeline-content h3 {
  color: #16a34a;
  font-size: 1.25rem;
  margin-bottom: 10px;
  font-weight: 600;
}

.timeline-content p {
  color: #555;
  font-size: 0.95rem;
  line-height: 1.6;
  margin: 0;
}

/* ---------- Animation ---------- */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.timeline-item {
  animation: fadeInUp 0.7s ease forwards;
}

/* ==============================================
   RESPONSIVE (VERTICAL VIEW ON MOBILE)
   ============================================== */
@media (max-width: 992px) {
  .timeline-container {
    display: block;
    overflow-x: hidden;
    padding: 20px;
  }

  .timeline-container::before {
    top: 0;
    bottom: 0;
    left: 25px;
    width: 4px;
    height: 100%;
  }

  .timeline-item {
    flex: 1 1 100%;
    text-align: left;
    padding-left: 60px;
    margin-bottom: 60px;
    transform: none;
  }

  .timeline-item::before {
    top: 25px;
    left: 16px;
    transform: none;
  }

  .timeline-content {
    margin-top: 0;
    max-width: 100%;
  }

  .section-title {
    font-size: 1.8rem;
  }
}

/* Extra small mobile view */
@media (max-width: 576px) {
  .timeline-content {
    padding: 18px 16px;
  }
  .timeline-content h3 {
    font-size: 1.1rem;
  }
  .timeline-content p {
    font-size: 0.9rem;
  }
}
