/* CSS for Autoscrolling testimonial section */
.acf-layout-autoscrolling-testimonial-section {
  background-color: var(--color-black);
  color: var(--color-white);
  overflow: hidden;
}

.testimonial-swipers-wrapper {
  position: relative;
  height: 800px;
  overflow: hidden;
  margin: 0;
}

/* Top fade gradient */
.testimonial-swipers-wrapper::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 130px;
  background: linear-gradient(180deg, #000000 0%, rgba(0, 0, 0, 0) 100%);
  z-index: 10;
  pointer-events: none;
}

/* Bottom fade gradient */
.testimonial-swipers-wrapper::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 130px;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0) 0%, #000000 100%);
  z-index: 10;
  pointer-events: none;
}

.testimonial-swiper-col {
  height: 100%;
  position: relative;
}

.testimonial-swiper-col .swiper {
  height: 100%;
  width: 100%;
}

.testimonial-swiper-col .swiper-slide {
  height: auto !important; /* Let slides wrap card content height dynamically */
  padding: 10px 0; /* Add spacing between slides */
  display: flex;
  flex-direction: column;
}

/* Direct transform scrolling for continuous ticker without transition glitch */
.testimonial-swiper-vertical-1 .swiper-wrapper,
.testimonial-swiper-vertical-2 .swiper-wrapper,
.testimonial-swiper-vertical-3 .swiper-wrapper {
  transition: none !important;
  will-change: transform;
}

/* Testimonial Card Styling */
.testimonial-card {
  background-color: var(--color-white);
  color: var(--color-1);
  border-radius: 25px;
  padding: 20px;
  min-height: 260px;
  height: 100%;
  display: flex;
  flex-direction: column;
  box-sizing: border-box;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.25);
  margin: 0 10px;
}

.testimonial-card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 40px;
  width: 100%;
}

.testimonial-avatar-wrapper {
  display: flex;
  align-items: center;
  gap: 15px;
}

.testimonial-avatar {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
}

.testimonial-avatar-placeholder {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background-color: var(--color-7);
  flex-shrink: 0;
}

.testimonial-meta {
  display: flex;
  flex-direction: column;
}

.testimonial-name {
  font-family: var(--font-clash-display);
  color: var(--color-1);
  margin: 0 !important;
  font-weight: 400;
  font-size: 20px;
}

.testimonial-designation {
  font-family: var(--font-archivo);
  font-weight: 400;
  font-size: 14px;
  color: var(--color-8);
}

.testimonial-quote {
  flex-shrink: 0;
}

.testimonial-quote svg {
  display: block;
}

.testimonial-card-body {
  flex-grow: 1;
  display: flex;
  align-items: flex-start;
}

.testimonial-text {
  font-family: var(--font-archivo);
  font-weight: 400;
  font-size: 14px;
  color: var(--color-1);
  margin: 0 !important;
}

/* Side graphic image (TRUST) */
.testimonial-side-image-col {
  display: flex;
  justify-content: center;
  align-items: center;
  height: 730px;
}

.testimonial-side-graphic {
  max-height: 100%;
  width: auto;
  object-fit: contain;
  display: block;
}

/* Tablet responsiveness */
@media (max-width: 991px) {
  .testimonial-swipers-wrapper {
    height: 600px;
  }
  .testimonial-side-image-col {
    height: 600px;
  }
  .testimonial-card {
    padding: 20px;
    min-height: 220px;
  }
}

/* Mobile responsiveness */
@media (max-width: 767px) {
  .testimonial-swipers-wrapper-mobile {
    position: relative;
    height: 500px;
    overflow: hidden;
    margin: 0;
  }

  /* Direct transform scrolling for continuous ticker on mobile */
  .testimonial-swiper-vertical-mobile .swiper-wrapper {
    transition: none !important;
    will-change: transform;
  }

  .testimonial-swiper-vertical-mobile {
    height: 100%;
    width: 100%;
  }

  .testimonial-swiper-vertical-mobile .swiper-slide {
    height: auto !important;
    padding: 8px 0;
    display: flex;
    flex-direction: column;
  }

  /* Top & bottom fade gradient for mobile swiper */
  .testimonial-swipers-wrapper-mobile::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 90px;
    background: linear-gradient(180deg, #000000 0%, rgba(0, 0, 0, 0) 100%);
    z-index: 10;
    pointer-events: none;
  }

  .testimonial-swipers-wrapper-mobile::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 90px;
    background: linear-gradient(180deg, rgba(0, 0, 0, 0) 0%, #000000 100%);
    z-index: 10;
    pointer-events: none;
  }

  /* Testimonial Card Styling for mobile */
  .testimonial-card {
    padding: 20px;
    min-height: 220px;
    border-radius: 20px;
  }

  .testimonial-avatar {
    width: 40px;
    height: 40px;
  }

  .testimonial-avatar-placeholder {
    width: 40px;
    height: 40px;
  }

  .testimonial-name {
    font-size: 14px;
  }

  .testimonial-designation {
    font-size: 11px;
  }

  .testimonial-text {
    font-size: 12px;
  }

  .testimonial-quote svg {
    width: 24px;
    height: 24px;
  }

  /* 25% side image layout */
  .mobile-image-col {
    display: flex;
    justify-content: center;
    align-items: center;
    padding-left: 10px;
  }

  .testimonial-side-graphic-mobile {
    height: auto;
    width: auto;
    object-fit: contain;
    display: block;
  }
  .testimonial-card-header {
    margin-bottom: 22px;
  }
}
