.related-product {
  display: inline-block;
  overflow: hidden;
  height: 370px;
}

.related-product-2 {
  display: inline-block;
  overflow: hidden;
  width: 100%;
  height: 100%;
}

@media (min-width: 768px) and (max-width: 1023px) {
  .related-product {
    display: inline-block;
    overflow: hidden;
    height: 300px;
  }
}

@media (min-width: 1024px) and (max-width: 1179px) {
  .related-product {
    display: inline-block;
    overflow: hidden;
    height: 280px;
  }
}

@media (min-width: 1180px) and (max-width: 1399px) {
  .related-product {
    display: inline-block;
    overflow: hidden;
    height: 350px;
  }
}

@media (min-width: 1400px) and (max-width: 1899px) {
  .related-product {
    display: inline-block;
    overflow: hidden;
    height: 400px;
  }
}

@media (min-width: 1900px) {
  .related-product {
    display: inline-block;
    overflow: hidden;
    height: 400px;
  }
}

@media (min-width: 1900px) {
  .only-two-slides .related-product {
    height: 500px;
  }
}

.related-productlink img {
  display: block;
  -moz-transition: all 0.3s;
  -webkit-transition: all 0.3s;
  transition: all 1.5s;
  object-fit: cover;
  object-position: center;
  height: 100%;
  width: 100%;
}

.related-productlink:hover img {
  -moz-transform: scale(1.1) !important;
  -webkit-transform: scale(1.1) !important;
  transform: scale(1.1) !important;
}

.hover-underline-animation {
  display: inline-block;
  position: relative;
}

.hover-underline-animation:after {
  content: '';
  position: absolute;
  width: 100%;
  transform: scaleX(0);
  height: 1px;
  bottom: 0;
  left: 0;
  background-color: var(--bs-primary);
  transform-origin: bottom center;
  transition: transform 0.5s ease-out;
}

.related-productlink:hover .hover-underline-animation:after {
  transform: scaleX(1);
  transform-origin: bottom center;
  transition: transform 1s ease-out;
}

/* Button Text Animation */

.related-productlink:hover .button-text .arrow-forward {
  transform: translateX(30px);
  animation: arrowslideleft 0.5s forwards;
}

