/* ==========================================================================
   Why Aurigene Pharmaceutical Services? — Statistics Section
   Scoped entirely under .why-aurigene-section so it is safe to drop into a
   Drupal theme alongside other components without leaking styles.
   ========================================================================== */
@import url('https://fonts.googleapis.com/css2?family=Montserrat:ital,wght@0,100..900;1,100..900&display=swap');

.why-aurigene-section {
  position: relative;
  overflow: hidden;
  isolation: isolate;
  /* keeps stacking context self-contained */
  padding-block: 4.5rem 5rem;
  color: #ffffff;
  background-color: #0b1f69;
  /* fallback shown before/without video */

}

/* --- Video background ------------------------------------------------- */

.why-aurigene-section .why-aurigene__media {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
}

.why-aurigene-section .why-aurigene__video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  pointer-events: none;
  /* video never intercepts interaction */
}

/* Blue / gradient overlay above the video, below the content */
.why-aurigene-section .why-aurigene__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg,
      rgba(14, 45, 145, 0.90) 0%,
      rgba(12, 75, 175, 0.86) 48%,
      rgba(0, 142, 196, 0.84) 100%);
}

/* --- Content layer ------------------------------------------------------ */

.why-aurigene-section .why-aurigene__container {
  position: relative;
  z-index: 1;
}

.why-aurigene-section .why-aurigene__heading {
  margin: 0 0 3.5rem;
  text-align: center;
  color: #ffffff;
  font-weight: 700;
  font-size: clamp(22px, 1.2rem + 1.5vw, 36px);
  line-height: 1.25;
  letter-spacing: -0.01em;
}

.why-aurigene-section .why-aurigene__grid {
  --why-aurigene-divider: rgba(255, 255, 255, 0.22);
  row-gap: 2.75rem;
}

.why-aurigene-section .why-aurigene__stat-col {
  position: relative;
  padding: 0 1.25rem;
}

.why-aurigene-section .why-aurigene__stat {
  text-align: center;
}

.why-aurigene-section .why-aurigene__stat-number {
  margin: 0 0 0.65rem;
  font-weight: 700;
  font-size: clamp(2.5rem, 1.8rem + 2.8vw, 3.6rem);
  line-height: 1.1;
  letter-spacing: -0.01em;
  font-variant-numeric: tabular-nums;
  font-family: "Montserrat", sans-serif !important;
}

span.stat-number {
  font-family: "Montserrat", sans-serif !important;
  font-weight: 600 !important;
}

.why-aurigene-section .why-aurigene__stat-label {
  margin: 0 auto;
  max-width: 24ch;
  color: rgba(255, 255, 255, 0.92);
  font-size: clamp(1rem, 0.82rem + 0.3vw, 1.5rem);
  line-height: 1.45;
  font-weight: 600;
}

/* Vertical divider between columns - continuous grid lines */
.why-aurigene-section .why-aurigene__stat-col::before {
  content: "";
  position: absolute;
  left: 0;
  width: 1px;
  background: var(--why-aurigene-divider);
  display: none;
}

/* Horizontal divider between rows */
.why-aurigene-section .why-aurigene__stat-col::after {
  content: "";
  position: absolute;
  top: -1.375rem;
  left: 10%;
  right: 10%;
  height: 1px;
  background: var(--why-aurigene-divider);
  display: none;
}

/* --- Responsive column counts + divider placement ------------------------
   Desktop (>=992px):  4 columns x 2 rows
   Tablet  (576-991px): 2 columns x 4 rows
   Mobile  (<576px):    1 column
   -------------------------------------------------------------------- */

/* Desktop: 4 per row -> vertical divider on cols 2,3,4 & 6,7,8;
   forming continuous vertical lines across row 1 & row 2 */
@media (min-width: 992px) {

  /* Row 1 vertical lines extend downwards */
  .why-aurigene-section .why-aurigene__stat-col:nth-child(2)::before,
  .why-aurigene-section .why-aurigene__stat-col:nth-child(3)::before,
  .why-aurigene-section .why-aurigene__stat-col:nth-child(4)::before {
    display: block;
    top: 5%;
    bottom: 0.5rem;
  }

  /* Row 2 vertical lines extend upwards to connect */
  .why-aurigene-section .why-aurigene__stat-col:nth-child(6)::before,
  .why-aurigene-section .why-aurigene__stat-col:nth-child(7)::before,
  .why-aurigene-section .why-aurigene__stat-col:nth-child(8)::before {
    display: block;
    top: 0.5rem;
    bottom: 5%;
  }

  /* Horizontal divider between row 1 and row 2 */
  .why-aurigene-section .why-aurigene__stat-col:nth-child(n+5)::after {
    display: block;
  }
}

/* Tablet: 2 per row -> vertical divider on the 2nd column of each pair;
   horizontal divider starts at row 2 (item 3 onward) */
@media (min-width: 576px) and (max-width: 991.98px) {
  .why-aurigene-section .why-aurigene__stat-col:nth-child(2n)::before {
    display: block;
    top: 5%;
    bottom: 5%;
  }

  .why-aurigene-section .why-aurigene__stat-col:nth-child(n+3)::after {
    display: block;
  }
}

/* Mobile: single column -> no vertical dividers, horizontal divider
   between every stat except the first */
@media (max-width: 575.98px) {
  .why-aurigene-section .why-aurigene__stat-col:nth-child(n+2)::after {
    display: block;
    left: 15%;
    right: 15%;
  }

  .why-aurigene-section .why-aurigene__grid {
    row-gap: 2.25rem;
  }
}

/* --- Accessibility -------------------------------------------------------- */

@media (prefers-reduced-motion: reduce) {
  .why-aurigene-section .why-aurigene__video {
    display: none;
    /* avoid non-essential motion; overlay + bg color remain */
  }

  .why-aurigene-section .why-aurigene__overlay {
    background: #0b1f69;
  }
}

/* --- Fine-tuning for very large / very small viewports -------------------- */

@media (min-width: 1600px) {
  .why-aurigene-section {
    padding-block: 6rem;
  }
}

@media (max-width: 320px) {
  .why-aurigene-section .why-aurigene__stat-col {
    padding: 0 0.75rem;
  }
}