/* =============================================================================
   ITPulp Testimonials - Optimized Stylesheet
   ============================================================================= */

/* --- Carousel Container --- */
.itpulp-testimonials-carousel {
    /* Using position: relative is crucial for positioning the arrows and dots inside */
    position: relative;
    margin: 20px 0;
    padding: 0 40px; /* Add padding to prevent arrows from overlapping content */
}

/* --- Testimonial Item --- */
.testimonial-item {
    padding: 20px;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    margin: 10px; /* Slick will handle margins, but this is a good fallback */
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    text-align: center; /* Centered text is often better for testimonials */
    /* Using a fixed height is better for consistency in a carousel */
    height: 350px; 
}

.testimonial-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

/* --- Testimonial Content --- */
.testimonial-content {
    flex-grow: 1; /* Allows the content area to fill available space */
    display: flex;
    align-items: center;
    margin-bottom: 20px;
}

.testimonial-content p {
    font-size: 16px;
    font-style: italic;
    line-height: 1.5;
    /* This is a great way to handle long text */
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 5;
    -webkit-box-orient: vertical;
    margin: 0;
}

/* --- Author Section --- */
.testimonial-author {
    margin-top: auto; /* Pushes author section to the bottom */
}

.testimonial-author .name {
    font-weight: bold;
    font-size: 18px;
    margin-bottom: 5px;
}

.testimonial-author .designation {
    font-size: 14px;
    color: #777;
    margin-top: 0;
}


/* =============================================================================
   Slick Carousel Specifics (Navigation & Dots)
   ============================================================================= */

/* --- Navigation Arrows (Combined & Optimized) --- */
.itpulp-testimonials-carousel .slick-prev,
.itpulp-testimonials-carousel .slick-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 10;
    display: block !important; /* Force display, overriding theme defaults */
    width: 45px;
    height: 45px;
    padding: 0;
    cursor: pointer;
    color: transparent; /* Hides the default "Next/Previous" text */
    border: none;
    outline: none;
    background: rgba(255, 255, 255, 0.8);
    border-radius: 50%;
    transition: all 0.2s ease-in-out;
}

.itpulp-testimonials-carousel .slick-prev:hover,
.itpulp-testimonials-carousel .slick-next:hover {
    background: #fff;
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}

/* Position the arrows */
.itpulp-testimonials-carousel .slick-prev {
    left: 0;
}
.itpulp-testimonials-carousel .slick-next {
    right: 0;
}

/* Style the Font Awesome icon inside the button */
.itpulp-testimonials-carousel .slick-prev:before,
.itpulp-testimonials-carousel .slick-next:before {
    font-family: "Font Awesome 5 Free";
    font-weight: 900;
    opacity: 1;
    color: #0073e6; /* Using your theme color */
    font-size: 18px;
    line-height: 1;
}

.itpulp-testimonials-carousel .slick-prev:before {
    content: "\f053"; /* FontAwesome chevron-left */
}
.itpulp-testimonials-carousel .slick-next:before {
    content: "\f054"; /* FontAwesome chevron-right */
}

/* --- Slick Dots --- */
.itpulp-testimonials-carousel .slick-dots {
    position: absolute;
    bottom: -35px; /* Moved down to not overlap with content */
    width: 100%;
    padding: 0;
    margin: 0;
    list-style: none;
    text-align: center;
}

.itpulp-testimonials-carousel .slick-dots li {
    position: relative;
    display: inline-block;
    width: 20px;
    height: 20px;
    margin: 0 5px;
    padding: 0;
    cursor: pointer;
}

.itpulp-testimonials-carousel .slick-dots li button {
    font-size: 0;
    line-height: 0;
    display: block;
    width: 20px;
    height: 20px;
    padding: 5px;
    cursor: pointer;
    color: transparent;
    border: 0;
    outline: none;
    background: transparent;
}

.itpulp-testimonials-carousel .slick-dots li button:before {
    font-family: 'slick';
    font-size: 12px;
    line-height: 20px;
    position: absolute;
    top: 0;
    left: 0;
    width: 20px;
    height: 20px;
    content: '•';
    text-align: center;
    opacity: .5;
    color: #ccc; /* Inactive dot color */
}

.itpulp-testimonials-carousel .slick-dots li.slick-active button:before {
    opacity: 1;
    color: #0073e6; /* Active dot color (using your theme color) */
}


/* =============================================================================
   Conditional Hiding (Based on Shortcode Attributes)
   ============================================================================= */

/* Hide navigation arrows if the setting is off */
.itpulp-testimonials-carousel[data-show-navigation="0"] .slick-prev,
.itpulp-testimonials-carousel[data-show-navigation="0"] .slick-next {
    display: none !important;
}

/* Hide dots if the setting is off */
.itpulp-testimonials-carousel[data-show-dots="0"] .slick-dots {
    display: none !important;
}