.testimonials {
  display: flex;
  position: relative;
  top: 147vh;
  justify-content: center;
  gap: 40px;
  flex-wrap: wrap;
  padding: 20px;
}

.testimonials-heading {
    position: relative;
    top: 137vh;
    transform: scale(0.8);
    left: -1.5vw;
}

.testimonial-card {
  position: relative; /* Essential for positioning the background image and content */
  width: 350px; /* Adjust based on your card image dimensions */
  height: 500px; /* Adjust based on your card image dimensions */
  display: flex;
  flex-direction: column;
  justify-content: center; /* Center content vertically */
  align-items: center;
  text-align: center;
  margin-bottom: 20px;
}

.card-background-image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: contain; /* Ensures the image fits without cropping, maintaining aspect ratio */
  z-index: 1; /* Puts the image behind the content */
}

.card-content {
   
  position: relative; /* Allows content to be layered above the background image */
  z-index: 2; /* Puts content above the image */
  padding: 50px 30px 30px 30px; /* Adjust padding to fit within your card image */
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between; /* Distributes space between elements */
  height: 100%; /* Occupy full height of the card */
  box-sizing: border-box; /* Include padding in height calculation */
}

.quote-text {
  font-family: 'Poppins', sans-serif;
  font-size: 13px;
  color: #555;
  margin-top: 50px;
  margin-bottom: 20px;
  line-height: 1.6;
}

.client-name {
  font-family: 'Poppins', sans-serif;
  font-weight: bold;
  font-size: 18px;
  color: #44674B;
  margin-top: -2vh; /* Pushes the name and logo to the bottom */
}

.client-logo {
    max-width: 81px;
    position: relative;
    top: -5vh;
}

.feedback-03 {
    margin-top: -3vh;
}

.feedback-03-logo {
    top: -6vh;
    max-width: 109px;
}

/* Media query for small screens */
@media (min-width: 1920px) {

  .testimonials-heading {
      top: 102vh;
  }

  .testimonials {
      top: 108vh;
  }
}

@media (max-width: 840px) {

  .testimonials-heading {
      top: 73vh;
      transform: scale(0.8);
  }

  .testimonials {
      top: 75vh;
  }

  .client-logo {
    top: -3vh;
  }

  .feedback-03-logo {
    top: -4vh;

  }

}

@media (max-width: 820px) {
    .testimonials-heading {
        top: 82vh;
        transform: scale(0.8);
    }
    .testimonials {
        top: 85vh;
    }
}

@media (max-width: 768px) {
  .testimonials-heading {
        top: 88vh;
        transform: scale(0.6);
    }
  .testimonials {
    flex-direction: column;
    align-items: center;
    top: 88vh;
  }

  .card-background-image {
      top: 18px;
      left: -29px;
      width: 118%;
  }

  .client-name {
      margin-top: -1vh;
  }

  .client-logo {
      top: 0vh;
  }

  

  .testimonials-heading {
     top: 88vh;
    transform: scale(0.6);
  }

  .testimonial-card {
    width: 100%; /* Adjust width for better mobile viewing */
    height: auto; /* Let height adjust based on content */
    max-width: 300px; /* Maintain a max width for consistency */
  }

  .card-content {
      padding: 40px 20px 20px 20px; /* Adjust padding for smaller screens */
  }
}

@media (max-width: 440px) {

    .testimonials-heading {
        top: 76vh;
        transform: scale(0.45);
    }
    .testimonials {
        top: 71vh;
    }
}

@media (max-width: 415px) {
    .testimonials-heading {
        top: 39vh;
        transform: scale(0.4);
    }

    .testimonials {
        top: 34vh;
    }
}

@media (max-width: 376px) {

  .testimonials-heading {
        top: 41vh;
    }
    
  .testimonials {
        top: 35vh;
  }
}