/* Advanced Testimonials for Elementor - Styles */

.ate-testimonials-wrapper {
    position: relative;
}

.ate-testimonials-carousel {
    position: relative;
    overflow: hidden;
    padding-left: 15px;
    padding-right: 15px;
    padding-bottom: 5px;
    padding-top: 5px;
}

/* Equal Height Slides */
.ate-equal-height .swiper-wrapper {
    align-items: stretch;
}

.ate-equal-height .swiper-slide {
    height: auto;
    display: flex;
}

.ate-equal-height .ate-testimonial-item {
    height: 100%;
    width: 100%;
}

/* Testimonial Item */
.ate-testimonial-item {
    display: flex;
    flex-direction: column;
    text-decoration: none;
    transition: all 0.3s ease;
}

.ate-testimonial-item:hover {
    transform: translateY(-5px);
}

/* Image Position Layouts */
.ate-image-position-top .ate-testimonial-item {
    flex-direction: column;
}

.ate-image-position-left .ate-testimonial-item {
    flex-direction: row;
    align-items: flex-start;
}

.ate-image-position-right .ate-testimonial-item {
    flex-direction: row-reverse;
    align-items: flex-start;
}

.ate-image-position-left .ate-testimonial-image,
.ate-image-position-right .ate-testimonial-image {
    flex-shrink: 0;
}

.ate-image-position-left .ate-testimonial-content-wrapper {
    margin-left: 20px;
}

.ate-image-position-right .ate-testimonial-content-wrapper {
    margin-right: 20px;
}

/* Image */
.ate-testimonial-image {
    text-align: center;
}

.ate-testimonial-image img {
    display: inline-block;
    object-fit: cover;
    max-width: 100%;
}

.ate-image-position-left .ate-testimonial-image img,
.ate-image-position-right .ate-testimonial-image img {
    margin: 0;
}

/* Content Wrapper */
.ate-testimonial-content-wrapper {
    display: flex;
    flex-direction: column;
    flex: 1;
}

/* Rating */
.ate-testimonial-rating {
    display: flex;
    gap: 4px;
}

.ate-testimonial-rating i {
    display: inline-block;
}

/* Name */
.ate-testimonial-name {
    font-weight: 600;
    line-height: 1.4;
}

/* Title */
.ate-testimonial-title {
    font-size: 14px;
    line-height: 1.4;
}

/* Content */
.ate-testimonial-content {
    line-height: 1.6;
    position: relative;
}

.ate-testimonial-content p {
    margin: 0 0 10px;
}

.ate-testimonial-content p:last-child {
    margin-bottom: 0;
}

/* Read More / Read Less Functionality */
.ate-testimonial-content.ate-truncated {
    overflow: hidden;
}

.ate-testimonial-content .ate-truncated-text {
    display: inline;
}

.ate-testimonial-content .ate-full-text {
    display: none;
}

.ate-testimonial-content.ate-expanded .ate-truncated-text {
    display: none;
}

.ate-testimonial-content.ate-expanded .ate-full-text {
    display: block;
}

.ate-read-more-wrapper {
    display: block;
    margin-top: 8px;
}

.ate-read-more-btn {
    display: inline-block;
    cursor: pointer;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
    user-select: none;
    background: none;
    border: none;
    padding: 0;
    font-family: inherit;
    font-size: inherit;
    line-height: inherit;
    outline: none;
}

.ate-read-more-btn:hover {
    text-decoration: underline;
}

.ate-read-more-btn:focus {
    outline: none;
}

/* Navigation Arrows - Default (Sides) Position */
.ate-swiper-button-prev,
.ate-swiper-button-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 10;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    user-select: none;
    line-height: 1;
}

.ate-swiper-button-prev i,
.ate-swiper-button-next i,
.ate-swiper-button-prev svg,
.ate-swiper-button-next svg {
    line-height: 1;
}

/* SVG Icon sizing and coloring for custom icons */
.ate-swiper-button-prev svg,
.ate-swiper-button-next svg {
    width: 1em;
    height: 1em;
    fill: currentColor;
}

.ate-swiper-button-prev img,
.ate-swiper-button-next img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* Arrow Position - Sides (default) */
.ate-arrows-sides .ate-swiper-button-prev {
    left: 2px;
}

.ate-arrows-sides .ate-swiper-button-next {
    right: 2px;
}

/* Arrow Position - Bottom */
.ate-arrows-bottom .ate-swiper-button-prev,
.ate-arrows-bottom .ate-swiper-button-next {
    position: relative;
    top: auto;
    transform: none;
}

.ate-arrows-bottom .ate-navigation-bottom {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    flex-wrap: wrap;
    margin-top: 20px;
}

.ate-arrows-bottom .ate-arrows-container {
    display: flex;
    align-items: center;
    gap: 15px;
}

.ate-arrows-bottom .swiper-pagination {
    position: relative;
    margin-top: 0;
}

/* Arrow Hover States */
.ate-swiper-button-prev:hover,
.ate-swiper-button-next:hover {
    opacity: 0.7;
}

.ate-swiper-button-prev.swiper-button-disabled,
.ate-swiper-button-next.swiper-button-disabled {
    opacity: 0.35;
    cursor: default;
}

/* Fallback if icons don't load */
.ate-swiper-button-prev:not(:has(i)):not(:has(img)):not(:has(svg)):before {
    content: '‹';
    font-size: 1.5em;
    font-weight: bold;
}

.ate-swiper-button-next:not(:has(i)):not(:has(img)):not(:has(svg)):before {
    content: '›';
    font-size: 1.5em;
    font-weight: bold;
}

/* Pagination */
.swiper-pagination {
    position: relative;
    margin-top: 30px;
    text-align: center;
}

/* Dots Position - Outside (default) */
.ate-dots-outside .swiper-pagination {
    position: relative;
    margin-top: 30px;
}

/* Dots Position - Inside */
.ate-dots-inside .swiper-pagination {
    position: absolute;
    bottom: 20px;
    left: 0;
    right: 0;
    margin-top: 0;
    z-index: 10;
}

.swiper-pagination-bullet {
    border-radius: 50%;
    opacity: 1;
    cursor: pointer;
    transition: all 0.3s ease;
    margin: 0 5px;
}

.swiper-pagination-bullet:hover {
    opacity: 0.7;
}

/* Responsive */
@media (max-width: 767px) {
    .ate-image-position-left .ate-testimonial-item,
    .ate-image-position-right .ate-testimonial-item {
        flex-direction: column;
    }

    .ate-image-position-left .ate-testimonial-content-wrapper,
    .ate-image-position-right .ate-testimonial-content-wrapper {
        margin-left: 0;
        margin-right: 0;
    }
    
    .ate-arrows-sides .ate-swiper-button-prev {
        left: 2px;
    }
    
    .ate-arrows-sides .ate-swiper-button-next {
        right: 2px;
    }

    .ate-arrows-bottom .ate-navigation-bottom {
        flex-direction: column;
        gap: 20px;
    }
}