/* Testimonials Widget CSS */

/* Main container */
.cew-testimonials-box {
  background: transparent;
  -webkit-transition: all 0.3s ease;
  -ms-transition: all 0.3s ease;
  transition: all 0.3s ease;
}

.cew-testimonials-box[data-layout="masonry"] .cew-grid-item-wrap.animated-item {
  -webkit-animation-fill-mode: unset;
  animation-fill-mode: unset;
}

.cew-testimonials-box:not([data-layout="masonry"]) {
  display: -webkit-flex;
  display: -ms-flexbox;
  display: flex;
  -webkit-flex-wrap: wrap;
  -ms-flex-wrap: wrap;
  flex-wrap: wrap;
  width: 100%;
}

/* Content wrapper */
.cew-testimonials-equal-height-yes .cew-testimonials-content-wrapper {
  height: 100%;
}

.cew-testimonials-content-wrapper .cew-testimonials-text-wrapper {
  margin: 0 0 10px;
}

.cew-testimonials-content-wrapper .cew-testimonials-text-wrapper > *:first-child {
  margin-top: 0;
}

.cew-testimonials-content-wrapper .cew-testimonials-text-wrapper > *:last-child {
  margin-bottom: 0;
}

/* Carousel / Swiper */
.cew-testimonials-carousel,
.cew-testimonials-carousel.swiper-container,
.cew-testimonials-carousel.swiper {
  display: block;
  min-width: 100%;
  overflow: hidden;
  position: relative;
}

.cew-testimonials-carousel .swiper-wrapper {
  display: flex;
  position: relative;
  width: 100%;
  height: 100%;
  z-index: 1;
  transition-property: transform;
  box-sizing: content-box;
}

.cew-testimonials-carousel .swiper-slide {
  flex-shrink: 0;
  width: 100%;
  height: 100%;
  position: relative;
  transition-property: transform;
}

.cew-testimonials-carousel.swiper-container-horizontal > .swiper-pagination-bullets,
.cew-testimonials-carousel.swiper-container .swiper-pagination-bullets.swiper-pagination-horizontal,
.cew-testimonials-carousel .swiper-pagination-horizontal {
  height: 8px;
  bottom: 0;
}

/* Swiper Container Wrap */
.swiper-container-wrap,
.cew-swiper-slider {
  -webkit-transition: opacity 0.3s ease;
  -ms-transition: opacity 0.3s ease;
  transition: opacity 0.3s ease;
}

/* DISABLED: Fade-in effect - causes slider to be invisible
.swiper-container-wrap:not(.cew-slider-inited),
.swiper-container-wrap:not(.trx-addons-slider-inited) {
  opacity: 0;
}
*/

.swiper-container-wrap .swiper-slide,
.swiper-container .swiper-slide {
  text-align: center;
  max-width: 100%;
}

/* Pagination */
.swiper-container-wrap .swiper-pagination {
  bottom: 10px;
  left: 0;
  width: 100%;
  line-height: 1;
}

.cew-swiper-slider-pagination-outside .swiper-pagination,
.trx-addons-swiper-slider-pagination-outside .swiper-pagination,
.swiper-container-wrap-dots-outside .swiper-pagination,
.swiper-container-dots-outside .swiper-pagination {
  position: static;
}

.swiper-container-wrap .swiper-pagination-bullet {
  background: #ccc;
  margin: 0 4px;
  opacity: 1;
  height: 8px;
  width: 8px;
  vertical-align: top;
  -webkit-transition: color 0.3s ease, background-color 0.3s ease, border-color 0.3s ease;
  -ms-transition: color 0.3s ease, background-color 0.3s ease, border-color 0.3s ease;
  transition: color 0.3s ease, background-color 0.3s ease, border-color 0.3s ease;
}

.swiper-horizontal > .swiper-pagination.swiper-pagination-bullets .swiper-pagination-bullet,
.swiper-container-horizontal > .swiper-pagination.swiper-pagination-bullets .swiper-pagination-bullet,
.swiper-pagination.swiper-pagination-horizontal.swiper-pagination-bullets .swiper-pagination-bullet {
  margin: 0;
}

.swiper-horizontal > .swiper-pagination.swiper-pagination-bullets .swiper-pagination-bullet + .swiper-pagination-bullet,
.swiper-container-horizontal > .swiper-pagination.swiper-pagination-bullets .swiper-pagination-bullet + .swiper-pagination-bullet,
.swiper-pagination.swiper-pagination-horizontal.swiper-pagination-bullets .swiper-pagination-bullet + .swiper-pagination-bullet {
  margin-left: 8px;
}

.swiper-container-wrap .swiper-pagination-bullet-active {
  background: #000;
}

/* Navigation Arrows */
.swiper-container-wrap .swiper-button-next,
.swiper-container-wrap .swiper-button-prev,
.swiper-container .swiper-button-next,
.swiper-container .swiper-button-prev {
  background-image: none;
  font-size: 20px;
  height: 1.8182em;
  line-height: 1;
  margin: 0;
  text-align: center;
  transform: translateY(-50%);
  width: 1.8182em;
}

.swiper-container-wrap .swiper-button-next .fa,
.swiper-container-wrap .swiper-button-prev .fa,
.swiper-container .swiper-button-next .fa,
.swiper-container .swiper-button-prev .fa {
  vertical-align: top;
}

.cew-swiper-button svg,
.trx-addons-swiper-button svg {
  fill: currentColor;
  width: auto;
  height: 1em;
}

.swiper-button-next:focus,
.swiper-button-prev:focus {
  outline: 0;
}

.cew-slider-arrow,
.trx-addons-slider-arrow {
  align-items: center;
  justify-content: center;
  background-color: #fff;
  border-radius: 50%;
  color: #000;
  cursor: pointer;
  display: inline-flex;
  font-size: 22px;
  line-height: 22px;
  position: absolute;
  top: 50%;
  width: 1.8182em;
  height: 1.8182em;
  transform: translateY(-50%);
  z-index: 1;
  transition: all 0.25s linear 0s;
}

.cew-slider-arrow svg,
.trx-addons-slider-arrow svg {
  fill: currentColor;
  width: auto;
  height: 1em;
}

.cew-arrow-next,
.trx-addons-arrow-next {
  right: 20px;
}

.cew-arrow-prev,
.trx-addons-arrow-prev {
  left: 20px;
}

.cew-slider-arrow,
.cew-slider-arrow:focus,
.trx-addons-slider-arrow,
.trx-addons-slider-arrow:focus,
.swiper-pagination-bullet,
.swiper-pagination-bullet:focus {
  outline: 0;
}

/* Show arrows on hover (desktop only) */
@media screen and (min-width: 1024px) {
  .cew-slider-arrows-show-on-hover-yes .cew-slider-arrow,
  .trx-addons-slider-arrows-show-on-hover-yes .trx-addons-slider-arrow {
    -webkit-transition: -webkit-transform 0.3s ease, opacity 0.3s ease;
    -ms-transition: -ms-transform 0.3s ease, opacity 0.3s ease;
    transition: transform 0.3s ease, opacity 0.3s ease;
    opacity: 0;
  }
  
  .cew-slider-arrows-show-on-hover-yes .cew-arrow-prev,
  .trx-addons-slider-arrows-show-on-hover-yes .trx-addons-arrow-prev {
    -webkit-transform: translate(-100px, -50%);
    -ms-transform: translate(-100px, -50%);
    transform: translate(-100px, -50%);
  }
  
  .cew-slider-arrows-show-on-hover-yes .cew-arrow-next,
  .trx-addons-slider-arrows-show-on-hover-yes .trx-addons-arrow-next {
    -webkit-transform: translate(100px, -50%);
    -ms-transform: translate(100px, -50%);
    transform: translate(100px, -50%);
  }
  
  .cew-slider-arrows-show-on-hover-yes:hover .cew-slider-arrow,
  .trx-addons-slider-arrows-show-on-hover-yes:hover .trx-addons-slider-arrow {
    -webkit-transform: translate(0, -50%);
    -ms-transform: translate(0, -50%);
    transform: translate(0, -50%);
    opacity: 1;
  }
}

/* Hide arrows on tablet */
@media screen and (max-width: 1279px) {
  .cew-slider-arrows-hide-on-tablet .cew-slider-arrow,
  .trx-addons-slider-arrows-hide-on-tablet .trx-addons-slider-arrow {
    display: none;
  }
}

/* Hide arrows on mobile */
@media screen and (max-width: 767px) {
  .cew-slider-arrows-hide-on-mobile .cew-slider-arrow,
  .trx-addons-slider-arrows-hide-on-mobile .trx-addons-slider-arrow {
    display: none;
  }
}

/* Author info */
.cew-testimonials-author-info {
  display: -webkit-flex;
  display: -ms-flexbox;
  display: flex;
  -webkit-flex-direction: column;
  -ms-flex-direction: column;
  flex-direction: column;
  -webkit-align-items: flex-start;
  -ms-flex-align: start;
  align-items: flex-start;
}

.cew-testimonials-box .cew-testimonials-heading {
  margin: 0 0 10px;
}

.cew-testimonials-box .cew-testimonials-person-name {
  margin: 0 0 5px;
  width: 100%;
}

.cew-testimonials-box .cew-testimonials-company {
  margin: 0;
  width: 100%;
}

/* Container */
.cew-testimonials-container {
  position: relative;
  width: 100%;
}

/* Image wrapper */
.cew-testimonials-img-wrapper {
  overflow: hidden;
  border-radius: 50%;
  -webkit-transition: all 0.3s ease;
  -ms-transition: all 0.3s ease;
  transition: all 0.3s ease;
  -webkit-flex-shrink: 0;
  -ms-flex-shrink: 0;
  flex-shrink: 0;
}

.cew-testimonials-img-wrapper img {
  object-fit: cover;
  width: 100%;
  height: 100% !important;
  border-radius: 50%;
}

/* Image + Info wrapper */
.cew-testimonials__img-info {
  display: -webkit-flex;
  display: -ms-flexbox;
  display: flex;
  -webkit-align-items: center;
  -ms-flex-align: center;
  align-items: center;
}

/* Content wrapper */
.cew-testimonials-content-wrapper {
  position: relative;
  display: -webkit-flex;
  display: -ms-flexbox;
  display: flex;
  -webkit-flex-direction: column;
  -ms-flex-direction: column;
  flex-direction: column;
  width: 100%;
  padding: 20px;
}

.cew-testimonials-clear-float {
  clear: both;
}

/* Quote icons */
.cew-testimonials-upper-quote {
  position: absolute;
  z-index: 1;
  top: 3px;
  left: 3px;
}

.cew-testimonials-lower-quote {
  position: absolute;
  z-index: 1;
  bottom: 3px;
  right: 3px;
  -webkit-transform: rotate(180deg);
  -ms-transform: rotate(180deg);
  transform: rotate(180deg);
}

/* Rating */
.cew-testimonials-rating-position-hide .cew-testimonials__rating-wrapper {
  display: none;
}

.cew-fb-rev-stars {
  font-size: 15px;
}

.cew-fb-rev-stars svg {
  width: 1em;
  height: 1em;
}

/* Layout order - Skin 1 */
.cew-testimonials-heading {
  -webkit-order: 2;
  -ms-flex-order: 2;
  order: 2;
}

.cew-testimonials-text-wrapper {
  -webkit-order: 3;
  -ms-flex-order: 3;
  order: 3;
}

.cew-testimonials__rating-wrapper {
  -webkit-order: 4;
  -ms-flex-order: 4;
  order: 4;
}

.cew-testimonials-rating-position-before .cew-testimonials__rating-wrapper {
  -webkit-order: 3;
  -ms-flex-order: 3;
  order: 3;
}

.cew-testimonials-rating-position-before .cew-testimonials-text-wrapper {
  -webkit-order: 4;
  -ms-flex-order: 4;
  order: 4;
}

/* Skin variations */
.cew-testimonials__skin1 .cew-testimonials__img-info {
  -webkit-order: 5;
  -ms-flex-order: 5;
  order: 5;
}

.cew-testimonials__skin2 .cew-testimonials__img-info {
  -webkit-order: 1;
  -ms-flex-order: 1;
  order: 1;
}

.cew-testimonials__skin3 .cew-testimonials-img-wrapper {
  -webkit-order: 1;
  -ms-flex-order: 1;
  order: 1;
}

.cew-testimonials__skin3 .cew-testimonials-author-info {
  -webkit-order: 5;
  -ms-flex-order: 5;
  order: 5;
}


.cew-testimonials-grid.cew-columns-1 {
  grid-template-columns: 1fr;
}

.cew-testimonials-grid.cew-columns-2 {
  grid-template-columns: repeat(2, 1fr);
}

.cew-testimonials-grid.cew-columns-3 {
  grid-template-columns: repeat(3, 1fr);
}

.cew-testimonials-grid.cew-columns-4 {
  grid-template-columns: repeat(4, 1fr);
}

/* Responsive */
@media (max-width: 768px) {
  .cew-testimonials-grid.cew-columns-3,
  .cew-testimonials-grid.cew-columns-4 {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 480px) {
  .cew-testimonials-grid {
    grid-template-columns: 1fr !important;
  }
}

/* ThemeREX compatibility - alias selectors */
.trx-addons-testimonials-box {
  background: transparent;
}

.trx-addons-testimonials-grid {
  display: grid;
  gap: 20px;
}

.trx-addons-testimonials-container {
  position: relative;
  width: 100%;
}

.trx-addons-testimonials-content-wrapper {
  position: relative;
  display: flex;
  flex-direction: column;
  width: 100%;
  padding: 20px;
}

.trx-addons-testimonials-img-wrapper {
  overflow: hidden;
  border-radius: 50%;
}

.trx-addons-testimonials-img-wrapper img {
  object-fit: cover;
  width: 100%;
  height: 100% !important;
  border-radius: 50%;
}
