/* Clients Testimonials Section */
.clients-section {
    width: 100vw;
    height: 627px;
    margin-left: 50%;
    transform: translateX(-50%);
    display: flex;
    justify-content: center;
    align-items: stretch;
    background: none;
    padding: 0;
    background-color: white;
}
.clients-content {
    display: flex;
    width: 100vw;
}
.clients-left {
    position: relative;
    flex: 1 1 50%;
    min-width: 0;
    /* background: url('../images/Frame-1000001118-1.png') center center/cover no-repeat; */
    background-image: linear-gradient(180deg, rgba(0,0,0,0) 0%, rgba(0,0,0,0.9) 100%), url('../images/regulirovanie-otopitel-nyh-klapanov-v-zilom-zdanii.jpg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    opacity: 0;
    transform: translateX(-100%);
    transition: opacity 1s ease, transform 1.1s ease;
}
.clients-left::before {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.5); /* степень затемнения */
    z-index: 1;
    pointer-events: none;
}
.clients-section.visible .clients-left {
    opacity: 1;
    transform: none;
}
.clients-title {
    position: relative;
    z-index: 2;
    color: #fff;
    font-size: 50px;
    font-family: 'Montserrat', 'Poppins', Arial, sans-serif;
    font-weight: 700;
    text-align: left;
    padding-bottom: 150px;
    padding-left: 7vw;
    padding-right: 7vw;
    text-transform: uppercase;
    line-height: 1.3em;
    letter-spacing: 0.5px;
}
.clients-right {
    flex: 1 1 50%;
    background: #212121;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    position: relative;
    opacity: 0;
    transform: translateX(100%);
    transition: opacity 1s ease, transform 1.1s ease;
}
.clients-section.visible .clients-right {
    opacity: 1;
    transform: none;
}
.quote-mark img {
    max-height: 32px;
}
.testimonials-carousel {
    position: relative;
    width: 100%;
    max-width: 480px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 1;
    padding-bottom: 2.5em;
    overflow: visible;
}
.testimonial-slide {
    display: none;
    flex-direction: column;
    align-items: center;
    text-align: center;
    color: #fff;
    font-family: 'Montserrat', Arial, sans-serif;
    font-size: 1.1rem;
    min-height: 180px;
    opacity: 0;
    transform: translateY(150px);
}
.testimonial-slide.active {
    display: flex;
    opacity: 1;
    transform: translateY(0);
    animation: testimonial-slide-in 1.5s ease;
}
@keyframes testimonial-slide-in {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}
.testimonial-text {
    font-size: 17px;
    line-height: 1.6em;
    margin-top: 50px;
    margin-bottom: 1.2em;
}
.testimonial-author {
    font-size: 16px;
}
.testimonial-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: #fff;
    font-size: 2.2rem;
    padding: 0.1em 0.4em;
    cursor: pointer;
    border-radius: 0;
    transition: opacity 0.3s, transform 0.4s cubic-bezier(.4,1.4,.6,1), background 0.2s, color 0.2s;
    z-index: 2;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
}
.testimonial-btn.prev {
    left: -1.7em;
    transform: translateX(-30px) translateY(-50%);
}
.testimonial-btn.next {
    right: -1.7em;
    transform: translateX(30px) translateY(-50%);
}
.clients-right:hover .testimonial-btn.prev,
.clients-right:focus-within .testimonial-btn.prev {
    opacity: 1;
    pointer-events: auto;
    transform: translateX(0) translateY(-50%);
}
.clients-right:hover .testimonial-btn.next,
.clients-right:focus-within .testimonial-btn.next {
    opacity: 1;
    pointer-events: auto;
    transform: translateX(0) translateY(-50%);
}
.testimonial-btn.prev::before {
    content: '';
    display: inline-block;
    width: 12px;
    height: 12px;
    border-left: 3px solid #fff;
    border-bottom: 3px solid #fff;
    transform: rotate(45deg);
    margin-right: 2px;
}
.testimonial-btn.next::before {
    content: '';
    display: inline-block;
    width: 12px;
    height: 12px;
    border-right: 3px solid #fff;
    border-top: 3px solid #fff;
    transform: rotate(45deg);
    margin-left: 2px;
}
.testimonial-btn:hover {
    background: none;
    cursor: pointer;
}
.testimonial-btn.prev {
    left: -1.7em;
}
.testimonial-btn.next {
    right: -1.7em;
}
.clients-right:hover .testimonial-btn,
.clients-right:focus-within .testimonial-btn {
    opacity: 1;
    pointer-events: auto;
}
.testimonial-dots {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.7em;
    z-index: 3;
}
.testimonial-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: rgba(255,255,255,0.4);
    cursor: pointer;
    transition: background 0.2s;
    display: inline-block;
}
.testimonial-dot.active {
    background: #fff;
}
@media (max-width: 1100px) {
    .clients-section {
        height: auto;
        min-height: 420px;
    }
    .clients-title {
        font-size: 36px;
        padding-top: 60px;
    }
}
@media (max-width: 900px) {
    .clients-content {
        flex-direction: column;
        width: 100vw;
        align-items: stretch;
    }
    .clients-left, .clients-right {
        min-height: 180px;
        flex: none;
        /* width: 100vw; */
    }
    .clients-left {
        min-height: 120px;
        padding-top: 30px;
        padding-bottom: 30px;
    }
    .clients-right {
        min-height: 220px;
        padding: 30px 2vw 30px 2vw;
    }
    .clients-title {
        font-size: 28px;
        padding: 30px 5vw 10px 5vw;
        text-align: center;
    }
}
@media (max-width: 600px) {
    .clients-section {
        height: auto;
        min-height: 320px;
    }
    .clients-title {
        font-size: 20px;
        padding: 0;
    }
    .quote-mark img {
        max-height: 28px;
    }
    .testimonials-carousel {
        max-width: 100vw;
        padding-bottom: 10px;
        min-height: 215px;
    }
    .testimonial-slide {
        max-width: 70vw;
    }
    .testimonial-text {
        font-size: 16px;
        margin-top: 20px;
    }
    .testimonial-author {
        font-size: 14px;
    }
    .testimonial-btn.prev {
        left: 10px;
        transform: none;
        opacity: 1;
    }
    .testimonial-btn.next {
        right: 10px;
        transform: none;
        opacity: 1;
    }
    .clients-right:hover .testimonial-btn.prev,
    .clients-right:focus-within .testimonial-btn.prev {
        transform: none;
    }
    .clients-right:hover .testimonial-btn.next,
    .clients-right:focus-within .testimonial-btn.next {
        transform: none;
    }
}
