:root {
  --accent: #053d7a;
  --secondary: #053d7a;
}

.sticky-aside {
  position: relative;
  transition: transform 0.1s ease;
}

.mr-accordion-content {
  overflow: hidden;
  transition:
    max-height 0.3s ease-out,
    padding 0.3s ease;
  max-height: 0;
  padding: 0 1rem !important;
}

.mr-accordion-content.open {
  max-height: 500px;
  padding: 0.75rem 1rem !important;
}

@media (max-width: 767px) {
  .mr-accordion-content.open {
    padding: 0.5rem 1rem !important;
  }
}

/* Prevent horizontal scroll on mobile */
section,
.max-w-\[1620px\],
.bg-\[#0056a3\] {
  overflow-x: clip; /* or visible, but clip prevents scroll */
}

/* On small screens, reduce the image overlap */
@media (max-width: 640px) {
  .bg-\[#0056a3\] {
    padding-bottom: 6rem !important; /* extra space for the image */
  }
  .absolute {
    position: absolute;
    bottom: -1.5rem;
    right: 0;
    width: 45%; /* smaller relative to container */
    max-width: 180px;
  }
}

@media (min-width: 641px) and (max-width: 768px) {
  .absolute {
    width: 40%;
    max-width: 240px;
    bottom: -2rem;
  }
}

@media (min-width: 769px) {
}
.primary-gradient2 {
  background: linear-gradient(135deg, #053d7a, #0056a3);
}

@media (max-width: 767px) {
  .absolute {
    position: relative;
    width: 100%;
    height: 250px;
    margin-top: 1rem;
  }
  .relative.z-10 {
    position: relative;
    z-index: 10;
  }
}

/* Sticky styling for pharmacy left column */
#stickyDiv {
  transition: all 0.2s ease;
}

#stickyDiv.is-stuck {
  position: fixed;
  top: 80px;
  z-index: 100;
}

/* Ensure left column maintains its height to avoid jump when sticky activates */
#leftColumn {
  display: flex;
  flex-direction: column;
}
/* ===== FLIP CARDS ===== */
.flip-card {
  perspective: 1000px;
  height: 420px;
}

.flip-card-inner {
  position: relative;
  width: 100%;
  height: 100%;
  transition: transform 0.65s cubic-bezier(0.4, 0.2, 0.2, 1);
  transform-style: preserve-3d;
}

.flip-card.flipped .flip-card-inner {
  transform: rotateY(180deg);
}

.flip-card-front,
.flip-card-back {
  position: absolute;
  width: 100%;
  height: 100%;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  border-radius: 1rem;
  overflow: hidden;
}

.flip-card-back {
  transform: rotateY(180deg);
}

/* ===== STICKY LEFT ===== */
#pharmacySection {
  align-items: start;
}

#leftColumn {
  /* height placeholder so right column scrolls against it */
}

#stickyDiv {
  position: sticky;
  top: 90px; /* navbar height + buffer */
}

/* ===== RESPONSIVE ===== */
@media (max-width: 1023px) {
  #stickyDiv {
    position: static; /* mobile pe sticky nahi */
  }

  .flip-card {
    height: 200px;
    min-height: 200px;
  }
}

.admission-section {
  max-width: 1300px;
  margin-inline: auto;
  width: 100%;
  background: #ffffff;
  border-radius: 3rem;
  padding: 3.5rem 2.5rem;
  box-shadow: 0 12px 30px -10px rgba(5, 61, 122, 0.1);
}

/* ----- HEADER (centered, minimal) ----- */
.main-heading {
  color: #053d7a;
  font-size: 2.4rem;
  font-weight: 650;
  letter-spacing: -0.02em;
  line-height: 1.2;
  text-align: center;
  margin-bottom: 0.75rem;
}

.main-heading span {
  font-size: 0.7em;
  display: block;
  color: #2d4b6e;
  font-weight: 400;
  letter-spacing: 0.3px;
  margin-top: 8px;
}

/* intro – centered, soft width, no backgrounds */
.intro-text {
  text-align: center;
  color: #2d4b6e;
  font-size: 1.2rem;
  max-width: 700px;
  margin: 1rem auto 3rem auto;
  font-weight: 380;
  line-height: 1.5;
  padding: 0 1rem;
}
/* ===== TIMELINE FIX: ZIG-ZAG ===== */

.timeline {
  position: relative;
  padding: 1.5rem 0;
}

/* Central line at true 50% */
.timeline::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 0;
  bottom: 0;
  width: 3px;
  background: linear-gradient(
    180deg,
    #053d7a20,
    #053d7a 15%,
    #053d7a 85%,
    #053d7a20
  );
  transform: translateX(-50%);
  border-radius: 6px;
}

.timeline-row {
  display: flex;
  align-items: flex-start;
  margin-bottom: 2.5rem;
  position: relative;
  width: 100%;
}

.timeline-row .col {
  width: 50%;
  padding: 0 2.5rem;
  box-sizing: border-box;
}

/* Dot on central line */
.timeline-row::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 2rem;
  width: 20px;
  height: 20px;
  background: #ffffff;
  border: 4px solid #053d7a;
  border-radius: 50%;
  transform: translateX(-50%);
  z-index: 2;
  box-shadow: 0 0 0 4px rgba(5, 61, 122, 0.1);
  transition: 0.15s;
}

.timeline-row:hover::after {
  background: #e2efff;
  box-shadow: 0 0 0 6px rgba(5, 61, 122, 0.15);
}

/* LEFT row — card on left, empty on right */
.timeline-row.left {
  flex-direction: row;
}
.timeline-row.left .col:first-child {
  display: block;
}
.timeline-row.left .col:last-child {
  display: block;
  visibility: hidden; /* space rakho, card nahi */
}

/* RIGHT row — empty on left, card on right */
.timeline-row.right {
  flex-direction: row;
}
.timeline-row.right .col:first-child {
  display: block;
  visibility: hidden;
}
.timeline-row.right .col:last-child {
  display: block;
}

/* Card styling */
.timeline-card {
  background: #ffffff;
  border: 1px solid #e0ecf9;
  border-radius: 1.5rem;
  padding: 1.6rem 2rem;
  box-shadow: 0 4px 12px rgba(5, 61, 122, 0.04);
  transition: all 0.2s ease;
}

.timeline-card:hover {
  border-color: #a3c6e9;
  box-shadow: 0 10px 22px -10px rgba(5, 61, 122, 0.18);
}

/* ── Step Number bubble ── */
.step-number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #eaf2fc;
  color: #053d7a;
  font-weight: 700;
  font-size: 1.5rem;
  width: 3.2rem;
  height: 3.2rem;
  border-radius: 50%;
  border: 2px solid rgba(5, 61, 122, 0.15);
  margin-bottom: 1rem;
  transition: 0.15s;
}

.timeline-card:hover .step-number {
  background: #d9e9fc;
  border-color: #053d7a60;
}

/* ── Step Title ── */
.step-title {
  color: #053d7a;
  font-size: 1.5rem;
  font-weight: 630;
  margin-bottom: 0.3rem;
  letter-spacing: -0.01em;
}

/* ── Soft gradient rule ── */
.soft-rule {
  height: 3px;
  width: 80px;
  background: linear-gradient(90deg, #053d7a, #9bbde0, #e1eefa);
  border: none;
  margin: 0.6rem 0 1rem 0;
  border-radius: 4px;
}

/* ── Step Description ── */
.step-desc {
  color: #2b4a6b;
  font-size: 1rem;
  line-height: 1.65;
}

/* ===== MOBILE: single column ===== */
@media (max-width: 750px) {
  .admission-section {
    padding: 2.2rem 1.5rem;
    border-radius: 2rem;
  }

  /* Line on the left */
  .timeline::before {
    left: 20px;
    transform: none;
  }

  /* All rows stack vertically */
  .timeline-row,
  .timeline-row.left,
  .timeline-row.right {
    flex-direction: column;
    margin-left: 48px;
    margin-bottom: 2rem;
  }

  /* Show only the col that has the card, hide empty col */
  .timeline-row.left .col:first-child,
  .timeline-row.right .col:last-child {
    display: block !important;
    visibility: visible !important;
    width: 100%;
    padding: 0;
  }

  .timeline-row.left .col:last-child,
  .timeline-row.right .col:first-child {
    display: none !important;
  }

  /* Dot position on left line */
  .timeline-row::after {
    left: -28px;
    top: 1.8rem;
    transform: none;
    width: 18px;
    height: 18px;
    border-width: 3px;
  }

  .timeline-card {
    width: 100%;
    border-radius: 1.2rem;
  }

  .main-heading {
    font-size: 1.8rem;
  }
  .intro-text {
    font-size: 1rem;
    margin-bottom: 2rem;
  }
}

@media (max-width: 480px) {
  .timeline-row,
  .timeline-row.left,
  .timeline-row.right {
    margin-left: 36px;
  }

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

  .timeline-row::after {
    left: -22px;
    width: 16px;
    height: 16px;
  }

  .step-title {
    font-size: 1.2rem;
  }
  .step-number {
    width: 2.6rem;
    height: 2.6rem;
    font-size: 1.2rem;
  }
}
