/* Testimonial Cards Carousel */

#testimonials-card {
    position: relative;
    width: 100%;
    padding: 5rem 0;
    background-color: #f8f9fa;
    overflow: hidden;
}

.testimonials-card__carousel {
    position: relative;
    width: 100%;
    height: 250px; /* Reduced height for single row */
    overflow: hidden;
}

.testimonials-card__carousel-row {
    display: flex;
    position: absolute;
    width: max-content;
    animation-duration: 30s;
    animation-timing-function: linear;
    animation-iteration-count: infinite;
}

.testimonials-card__carousel-row {
    animation-name: scroll-right;
    top: 0;
}

@keyframes scroll-right {
    0% {
        transform: translateX(0);
    }
    100% {
        transform: translateX(-50%);
    }
}

.testimonials-card__carousel-item {
    flex: 0 0 auto;
    width: 350px;
    height: 220px;
    margin: 0 15px;
    background-color: #2c3e50; /* Dark background */
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.15);
    overflow: hidden;
    position: relative;
    transition: all 0.3s ease;
}

.testimonials-card__carousel-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
}

.testimonials-card__preview {
    padding: 20px;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.testimonials-card__preview p {
    font-size: 0.9rem;
    line-height: 1.5;
    color: #ffffff; /* White text for dark background */
    margin: 0 0 15px 0; /* Added bottom margin for author info */
    display: -webkit-box;
    -webkit-line-clamp: 4; /* Reduced to make room for author info */
    line-clamp: 4;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
}

.testimonials-card__preview a {
    text-decoration: none;
    color: inherit;
}

/* Author and company styles */
.testimonials-card__author {
    margin-top: auto;
    font-size: 0.85rem;
    color: #E2706D; /* Brand color for author name */
    font-weight: 600;
}

.testimonials-card__company {
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.7); /* Slightly transparent white */
    font-style: italic;
}

.testimonials-card__content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-top: 3rem;
}

.testimonials-card__content--left {
    flex: 0 0 40%;
}

.testimonials-card__content--right {
    flex: 0 0 50%;
}

.testimonials-card__tagline {
    color: #E2706D;
    font-size: 1rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 1rem;
}

.testimonials-card__heading--h2 {
    font-size: 2.5rem;
    font-weight: 700;
    color: #333;
    margin-bottom: 1.5rem;
}

.testimonials-card__text {
    font-size: 1.1rem;
    line-height: 1.6;
    color: #666;
    margin-bottom: 2rem;
}

.testimonials-card__buttons {
    display: flex;
    gap: 15px;
    margin-top: 2.25rem;
}

.testimonials-btn {
    background-color: #E2706D;
    color: white;
    border: none;
    padding: 0.875rem 1.5rem;
    border-radius: 50px;
    font-weight: 600;
    font-size: 1rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
    cursor: pointer;
    text-decoration: none;
    display: inline-block;
}

.testimonials-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(226, 112, 109, 0.3);
    background-color: #d45a57;
}

/* Pause animation on hover */
.testimonials-card__carousel:hover .testimonials-card__carousel-row {
    animation-play-state: paused;
}

/* Responsive styles */
@media (max-width: 992px) {
    .testimonials-card__content {
        flex-direction: column;
    }
    
    .testimonials-card__content--left,
    .testimonials-card__content--right {
        flex: 0 0 100%;
        width: 100%;
    }
    
    .testimonials-card__content--right {
        margin-top: 2rem;
    }
    
    .testimonials-card__buttons {
        flex-direction: column;
        gap: 10px;
    }
    
    .testimonials-card__carousel {
        height: 450px;
    }
}

@media (max-width: 768px) {
    .testimonials-card__carousel {
        height: 500px;
    }
    
    .testimonials-card__carousel-item {
        width: 300px;
        height: 200px;
    }
    
    .testimonials-card__heading--h2 {
        font-size: 2rem;
    }
}

@media (max-width: 576px) {
    .testimonials-card__carousel {
        height: 450px;
    }
    
    .testimonials-card__carousel-item {
        width: 280px;
        height: 180px;
    }
    
    .testimonials-card__preview p {
        font-size: 0.8rem;
        -webkit-line-clamp: 4;
        line-clamp: 4;
    }
    
    .testimonials-card__heading--h2 {
        font-size: 1.8rem;
    }
    
    .testimonials-card__text {
        font-size: 1rem;
    }
}
