/* ==========================================
   Testimonials Slider
   ========================================== */

.testimonials-slider {
    position: relative;
    max-width: 980px;
    margin: 0 auto;
    padding: 2rem 3.5rem 4.5rem;
}

.testimonials-track {
    position: relative;
    min-height: 320px;
}

.testimonials-viewport {
    overflow: hidden;
}

.testimonials-rail {
    display: flex;
    align-items: stretch;
    transition: transform 0.5s ease;
    will-change: transform;
}

.testimonial-slide {
    flex: 0 0 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    padding: 0 2rem 2.5rem;
    box-sizing: border-box;
}

.testimonial-quote {
    margin: 0;
    width: 100%;
    max-width: 860px;
    padding: 3rem 4rem 4.5rem;
    text-align: center;
    background: #fff;
    box-shadow: 0 18px 40px rgba(18, 29, 41, 0.14);
    position: relative;
    border: 0;
}

.testimonial-text {
    font-size: 1.25rem;
    line-height: 1.7;
    color: #1F2A33;
    font-style: normal;
    position: relative;
    z-index: 1;
}

.testimonial-text p {
    font-size: inherit;
    line-height: inherit;
}

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

.testimonial-author {
    position: absolute;
    left: 50%;
    bottom: -2rem;
    transform: translateX(-50%);
    display: inline-block;
    width: max-content;
    max-width: calc(100% - 3rem);
    padding: 1rem 1.75rem;
    font-weight: 700;
    font-size: 1.1rem;
    text-transform: uppercase;
    letter-spacing: 0.02em;
    color: #fff;
    background: #B32143;
    box-shadow: 0 12px 24px rgba(179, 33, 67, 0.28);
}

.testimonials-nav {
    display: flex;
    justify-content: space-between;
    position: absolute;
    top: 50%;
    left: calc(50% - 50vw + 1.5rem);
    right: calc(50% - 50vw + 1.5rem);
    transform: translateY(-50%);
    pointer-events: none;
}

.testimonials-prev,
.testimonials-next {
    width: 2.35rem;
    height: 2.6rem;
    border: 0;
    background: transparent;
    box-shadow: none;
    font-size: 0;
    color: transparent;
    cursor: pointer;
    pointer-events: all;
    padding: 0;
    transition: transform 0.2s, opacity 0.2s;
    line-height: 0;
    position: relative;
    opacity: 0.9;
}

.testimonials-prev::before,
.testimonials-next::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='47.642' height='52' viewBox='0 0 47.642 52'%3E%3Cg transform='translate(1576.205 106.714) rotate(180)'%3E%3Cpath d='M1532.69,106.714l26-26-26-26-4.128,4.128,21.873,21.872-21.873,21.872Z' transform='translate(0 0)' fill='%23b32143'/%3E%3Cpath d='M1546.978,102.587l4.128,4.128,26-26-26-26-4.128,4.128,21.872,21.872Z' transform='translate(-0.901 0)' fill='%23b32143'/%3E%3C/g%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: center;
    background-size: contain;
}

.testimonials-next::before {
    transform: rotate(180deg);
}

.testimonials-prev:hover,
.testimonials-next:hover {
    transform: scale(1.04);
    opacity: 1;
}

.testimonials-dots {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    margin-top: 1.75rem;
}

.testimonial-dot {
    width: 0.6rem;
    height: 0.6rem;
    border-radius: 50%;
    border: 2px solid #fff;
    background: #fff;
    box-shadow: 0 2px 8px rgba(18, 29, 41, 0.12);
    cursor: pointer;
    padding: 0;
    transition: background-color 0.2s, transform 0.2s;
}

.testimonial-dot.active {
    background: #B32143;
    border-color: #B32143;
    transform: scale(1.1);
}

@media (max-width: 768px) {
    .testimonials-slider {
        padding: 1.5rem 1rem 3.5rem;
    }

    .testimonials-track {
        min-height: 0;
    }

    .testimonials-nav {
        position: static;
        transform: none;
        justify-content: center;
        gap: 1rem;
        margin-top: 1rem;
    }

    .testimonial-text {
        font-size: 1.1rem;
        line-height: 1.7;
    }

    .testimonial-quote {
        padding: 2rem 1.5rem 4.5rem;
    }

    .testimonial-slide {
        padding: 0 0 2.75rem;
    }

    .testimonial-author {
        width: calc(100% - 2rem);
        max-width: calc(100% - 2rem);
        padding: 0.85rem 1rem;
        font-size: 0.95rem;
    }

    .testimonials-prev,
    .testimonials-next {
        width: 2rem;
        height: 2.2rem;
    }
}
