/* ═══════════════════════════════════════════════════════
   Testimonials Section Styling (מה הלקוחות מספרים)
   ═══════════════════════════════════════════════════════ */

.testimonials-section {
    background-color: #ffffff;
    color: #1e2735;
    padding: 144px 0 89px 0; /* Align padding with the blog section styling */
    font-family: 'Heebo', 'Polin', sans-serif;
    position: relative;
    z-index: 2; /* Sit in page content stacking context */
    overflow: hidden;
}

.testimonials-container {
    max-width: 1727px;
    margin: 0 auto;
    padding: 0 20px;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 45px;
}

.testimonials-title {
    font-family: 'Polin', 'Heebo', sans-serif;
    font-weight: 600;
    font-size: clamp(28px, 2.5vw + 18.8px, 62px);
    line-height: 1.2;
    color: #1e2735;
    margin: 0;
    text-align: center;
    width: 100%;
}

.testimonials-slider {
    width: 100%;
    position: relative;
}

.testimonials-track {
    display: flex;
    gap: 90px;
    align-items: flex-start;
    overflow-x: auto;
    scroll-behavior: smooth;
    scrollbar-width: none; /* Firefox */
    padding: 20px 0;
    box-sizing: border-box;
}

.testimonials-track::-webkit-scrollbar {
    display: none; /* Chrome/Safari/Webkit */
}

.testimonial-card {
    flex: 0 0 282px;
    width: 282px;
    display: flex;
    flex-direction: column;
    gap: 0;
    box-sizing: border-box;
    text-align: right;
}

/* Alternating wave margin-top logic (odd shifted down, even aligned top) */
.testimonial-card:nth-child(odd) {
    margin-top: 38px;
}

.testimonial-card:nth-child(even) {
    margin-top: 0;
}

.testimonial-image {
    width: 100%;
    border-radius: 15px;
    background: linear-gradient(135deg, #f1f5f9 0%, #cbd5e1 100%);
    box-sizing: border-box;
}

/* Type 1: Image only (Full Height) */
.testimonial-card.card-image-only .testimonial-image {
    height: 544px;
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 50%, #334155 100%);
}

/* Type 2: Title, Text, Image */
.testimonial-card.card-title-text-image .testimonial-author {
    margin-bottom: 11px; /* gap between box title and text 11px */
}

.testimonial-card.card-title-text-image .testimonial-quote {
    margin-bottom: 33px; /* gap between text and image 33px */
}

.testimonial-card.card-title-text-image .testimonial-image {
    height: 282px;
    background: linear-gradient(135deg, #f8fafc 0%, #cbd5e1 100%);
}

/* Type 3: Image, Title, Text */
.testimonial-card.card-image-title-text .testimonial-image {
    height: 282px;
    background: linear-gradient(135deg, #f1f5f9 0%, #94a3b8 100%);
    margin-bottom: 33px; /* gap between image and title 33px */
}

.testimonial-card.card-image-title-text .testimonial-author {
    margin-bottom: 11px; /* gap between box title and text 11px */
}

.testimonial-quote {
    font-family: 'Polin', 'Heebo', sans-serif;
    font-weight: 400;
    font-size: 17px;
    line-height: 24px;
    color: #000000;
    margin: 0;
    text-align: right;
}

.testimonial-author {
    font-family: 'Polin', 'Heebo', sans-serif;
    font-weight: 600;
    font-size: 22px;
    line-height: 31px;
    color: #000000;
    margin: 0;
    text-align: right;
}

/* Slider Controls */
.testimonials-controls {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    margin-top: 20px;
    box-sizing: border-box;
}

.testimonials-progress-container {
    flex: 1;
    max-width: 325px;
    height: 4px;
    background-color: #d9d9d9;
    border-radius: 50px;
    position: relative;
}

.testimonials-progress-bar {
    position: absolute;
    top: 0;
    right: 0; /* RTL alignment */
    height: 100%;
    width: 30%; /* Initial width covers first slide */
    background-color: #1e2735;
    border-radius: 50px;
    transition: width 0.2s ease;
}

.testimonials-nav {
    display: flex;
    gap: 16px;
}

.testimonials-btn {
    width: 50px;
    height: 50px;
    background-color: #f0f0f0;
    border: none;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.testimonials-btn:hover {
    background-color: #e2e8f0;
}

.testimonials-btn svg {
    width: 10px;
    height: 10px;
    fill: none;
    stroke: #1e2735;
    stroke-width: 2px;
    stroke-linecap: round;
    stroke-linejoin: round;
}

/* Entrance Fade-In Animation */
.testimonials-title,
.testimonials-slider {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s cubic-bezier(0.25, 1, 0.5, 1), transform 0.8s cubic-bezier(0.25, 1, 0.5, 1);
    will-change: opacity, transform;
}

.testimonials-section.animate-in .testimonials-title,
.testimonials-section.animate-in .testimonials-slider {
    opacity: 1;
    transform: translateY(0);
    transition-delay: 0.3s; /* uniform starting delay */
}

/* RESPONSIVENESS */
@media (max-width: 768px) {
    .testimonials-section {
        padding: 80px 0 60px 0;
    }
    
    .testimonials-track {
        gap: 40px;
    }
    
    .testimonial-card {
        flex: 0 0 250px;
        width: 250px;
        gap: 0;
    }
    
    .testimonial-card:nth-child(odd) {
        margin-top: 20px;
    }
    
    .testimonial-card:nth-child(even) {
        margin-top: 0;
    }
    
    .testimonial-card.card-image-only .testimonial-image {
        height: 380px;
    }
    
    .testimonial-card.card-title-text-image .testimonial-author {
        margin-bottom: 6px;
    }
    
    .testimonial-card.card-title-text-image .testimonial-quote {
        margin-bottom: 15px;
    }
    
    .testimonial-card.card-title-text-image .testimonial-image,
    .testimonial-card.card-image-title-text .testimonial-image {
        height: 200px;
    }
    
    .testimonial-card.card-image-title-text .testimonial-image {
        margin-bottom: 15px;
    }
    
    .testimonial-card.card-image-title-text .testimonial-author {
        margin-bottom: 6px;
    }
}
