/**
 * TK Testimonial Slider Styles - Glide.js Integration
 * Responsive slider with 3 testimonials on desktop, 1 on mobile
 */

/* Base Slider Container */
.tk-testimonial-slider {
    position: relative;
    max-width: 900px;
    margin: 0 auto;
    padding: 20px 0;
}

/* Glide Track */
.glide__track {
    overflow: hidden;
}

/* Glide Slides Container */
.glide__slides {
    display: flex;
    list-style: none !important;
    padding: 0;
    margin: 0;
    backface-visibility: hidden;
    transform-style: preserve-3d;
    touch-action: pan-Y;
    overflow: hidden;
}

/* Override TK theme list styles for slider */
.the_content .glide__slides ul li:before {
    display: none !important;
}

.the_content .glide__slides li:before {
    display: none !important;
}

/* Override TK theme dot styles for glide slides */
.the_content ul.glide__slides li:before,
.tk-text-section ul.glide__slides li:before {
    display: none !important;
}

/* Individual Slides */
.glide__slide {
    width: 100%;
    height: 100%;
    flex-shrink: 0;
    box-sizing: border-box;
    list-style: none !important;
}

/* Individual Testimonial Item */
.tk-testimonial-item {
    width: 100%;
    background: #ffffff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 25px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    position: relative;
    overflow: hidden;
    min-height: 200px;
    display: flex;
    box-sizing: border-box;
}

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

/* Glide Bullets (Dots) */
.glide__bullets {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: 15px;
    gap: 10px;
}

.glide__bullet {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    border: none;
    background: #cccccc;
    cursor: pointer;
    transition: all 0.3s ease;
    padding: 0;
}

.glide__bullet:hover,
.glide__bullet--active {
    background: #B60059;
    transform: scale(1.2);
}

.glide__bullet:focus {
    outline: 2px solid #B60059;
    outline-offset: 2px;
}

/* Testimonial Content */
.tk-testimonial-content {
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
}

/* Testimonial Text */
blockquote.tk-testimonial-text {
    font-size: 16px !important;
    line-height: 1.6;
    color: #333333;
    margin: 0;
    padding: 0;
    font-style: italic;
    text-align: left !important;
}

.tk-testimonial-text::before {
    display: none;
}

/* Testimonial Footer */
.tk-testimonial-footer {
    margin-top: auto;
    padding-top: 20px;
    border-top: 1px solid #f0f0f0;
}

/* Company Name */
.tk-testimonial-company {
    font-style: normal;
    font-weight: 700;
    color: #3EC6B8;
    text-align: left;
    margin-bottom: 5px;
    word-wrap: break-word;
    overflow-wrap: break-word;
    hyphens: auto;
    max-width: 100%;
    overflow: hidden;
}

/* Author */
.tk-testimonial-author {
    font-style: normal;
    font-weight: 600;
    color: #333;
    font-size: 16px;
    text-decoration: none;
    text-align: left;
    margin-bottom: 10px;
}

.tk-testimonial-author a {
    color: #007cba;
    text-decoration: none;
    transition: color 0.3s ease;
}

.tk-testimonial-author a:hover {
    color: #005a8b;
    text-decoration: underline;
}

/* Navigation Arrows */
.tk-testimonial-slider-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: #007cba;
    color: white;
    border: none;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    cursor: pointer;
    font-size: 18px;
    font-weight: bold;
    transition: all 0.3s ease;
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
}

.tk-testimonial-slider-nav:hover {
    background: #005a8b;
    transform: translateY(-50%) scale(1.1);
}

.tk-testimonial-slider-nav:focus {
    outline: 2px solid #007cba;
    outline-offset: 2px;
}

.tk-testimonial-slider-prev {
    left: -25px;
}

.tk-testimonial-slider-next {
    right: -25px;
}

/* Pagination Dots */
.tk-testimonial-slider-pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: 30px;
    gap: 10px;
}

.tk-testimonial-slider-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    border: none;
    background: #cccccc;
    cursor: pointer;
    transition: all 0.3s ease;
    padding: 0;
}

.tk-testimonial-slider-dot:hover,
.tk-testimonial-slider-dot.active {
    background: #B60059;
    transform: scale(1.2);
}

.tk-testimonial-slider-dot:focus {
    outline: 2px solid #007cba;
    outline-offset: 2px;
}

/* Empty State */
.tk-testimonial-slider-empty {
    text-align: center;
    padding: 40px 20px;
    color: #666666;
    font-style: italic;
}

/* Responsive Design */

/* Tablet (768px and below) */
@media (max-width: 768px) {
    .tk-testimonial-slider {
        padding: 15px 20px;
    }
    
    .tk-testimonial-slide {
        gap: 15px;
        padding: 15px 0;
    }
    
    .tk-testimonial-item {
        margin: 0 5px;
        padding: 25px 20px;
    }
    
    .tk-testimonial-slider-nav {
        width: 45px;
        height: 45px;
        font-size: 16px;
    }
    
    .tk-testimonial-slider-prev {
        left: -22px;
    }
    
    .tk-testimonial-slider-next {
        right: -22px;
    }
}

/* Mobile (480px and below) */
@media (max-width: 480px) {
    .tk-testimonial-slider {
        padding: 10px 15px;
    }
    
    .glide__slide {
        padding: 0;
    }
    
    .tk-testimonial-item {
        margin: 0;
        padding: 20px 15px;
        min-height: 200px;
    }
    
    blockquote.tk-testimonial-text {
        font-size: 15px !important;
        line-height: 1.5;
    }
    
    .glide__bullets {
        margin-top: 25px;
        gap: 8px;
    }
    
    .glide__bullet {
        width: 14px;
        height: 14px;
    }
}

/* Very small screens (320px and below) */
@media (max-width: 320px) {
    .tk-testimonial-item {
        padding: 15px 12px;
    }
    
    .tk-testimonial-text {
        font-size: 14px;
    }
    
    .tk-testimonial-author {
        font-size: 13px;
    }
}

/* Accessibility improvements */
@media (prefers-reduced-motion: reduce) {
    .tk-testimonial-slider-wrapper,
    .tk-testimonial-item,
    .tk-testimonial-slider-nav,
    .tk-testimonial-slider-dot {
        transition: none;
    }
}

/* High contrast mode */
@media (prefers-contrast: high) {
    .tk-testimonial-item {
        border: 2px solid #000000;
    }
    
    .tk-testimonial-slider-nav {
        border: 2px solid #000000;
    }
    
    .tk-testimonial-slider-dot {
        border: 2px solid #000000;
    }
    
    .tk-testimonial-slider-dot.active {
        background: #000000;
    }
}

/* Print styles */
@media print {
    .tk-testimonial-slider-nav,
    .tk-testimonial-slider-pagination {
        display: none;
    }
    
    .tk-testimonial-slide:not(.active) {
        display: flex;
    }
    
    .tk-testimonial-slider-wrapper {
        display: block;
    }
    
    .tk-testimonial-slide {
        page-break-inside: avoid;
        margin-bottom: 20px;
    }
}