/* WTC Carousel Styles */

.wtc-carousel-wrapper {
    position: relative;
    margin: 0 auto;
}

.wtc-carousel-wrapper.slick-initialized {
    visibility: visible;
}

.wtc-carousel-wrapper:not(.slick-initialized) {
    display: flex;
    overflow-x: auto;
    gap: 20px;
    padding: 20px 0;
}

/* Items */
.wtc-carousel-item {
    outline: none !important;
    transition: transform 0.3s ease;
}

.wtc-carousel-item:hover {
    transform: translateY(-5px);
}

.wtc-carousel-link {
    display: block;
    text-decoration: none;
    color: inherit;
    transition: all 0.3s ease;
}

/* Images */
.wtc-carousel-image-wrapper {
    position: relative;
    padding-bottom: 100%;
    height: 0;
    overflow: hidden;
    background: #f5f5f5;
    border-radius: 8px;
    margin-bottom: 15px;
}

.wtc-carousel-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.wtc-carousel-link:hover .wtc-carousel-image {
    transform: scale(1.05);
}

/* Content */
.wtc-carousel-content {
    padding: 10px 5px;
}

.wtc-carousel-title {
    margin: 0 0 8px 0;
    font-size: 18px;
    font-weight: 600;
    line-height: 1.4;
    color: #333;
    transition: color 0.3s ease;
}

.wtc-carousel-link:hover .wtc-carousel-title {
    color: #0073aa;
}

.wtc-carousel-count {
    display: block;
    font-size: 14px;
    color: #666;
    font-weight: normal;
}

/* Slick Overrides */
.wtc-carousel-wrapper .slick-list {
    overflow: hidden;
}

.wtc-carousel-wrapper .slick-track {
    display: flex;
    align-items: stretch;
}

.wtc-carousel-wrapper .slick-slide {
    height: auto;
}

.wtc-carousel-wrapper .slick-slide > div {
    height: 100%;
}

.wtc-carousel-wrapper .wtc-carousel-item {
    height: 100%;
    display: flex;
    flex-direction: column;
}

.wtc-carousel-wrapper .wtc-carousel-link {
    height: 100%;
    display: flex;
    flex-direction: column;
}

/* Navigation Arrows */
.wtc-carousel-wrapper .slick-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 999;
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.95);
    border: 2px solid #ddd;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0;
}

.wtc-carousel-wrapper .slick-arrow:hover {
    background: #fff;
    border-color: #333;
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}

.wtc-carousel-wrapper .slick-arrow:before {
    font-family: 'ETmodules', sans-serif;
    font-size: 20px;
    line-height: 1;
    color: #333;
    opacity: 1;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.wtc-carousel-wrapper .slick-prev {
    left: -50px;
}

.wtc-carousel-wrapper .slick-prev:before {
    content: '\34';
}

.wtc-carousel-wrapper .slick-next {
    right: -50px;
}

.wtc-carousel-wrapper .slick-next:before {
    content: '\35';
}

/* Dots */
.wtc-carousel-wrapper .slick-dots {
    position: relative;
    bottom: 0;
    margin-top: 30px;
    padding: 0;
    list-style: none;
    text-align: center;
}

.wtc-carousel-wrapper .slick-dots li {
    display: inline-block;
    margin: 0 5px;
    padding: 0;
}

.wtc-carousel-wrapper .slick-dots li button {
    display: block;
    width: 12px;
    height: 12px;
    padding: 0;
    border: 2px solid #ccc;
    border-radius: 50%;
    background: transparent;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0;
    line-height: 0;
}

.wtc-carousel-wrapper .slick-dots li button:hover {
    border-color: #666;
}

.wtc-carousel-wrapper .slick-dots li.slick-active button {
    background: #333;
    border-color: #333;
}

/* Loading State */
.wtc-carousel-wrapper.loading {
    opacity: 0.5;
    pointer-events: none;
}

/* Error Messages */
.wtc-error,
.wtc-no-terms {
    padding: 40px;
    text-align: center;
    background: #f5f5f5;
    border: 1px solid #ddd;
    border-radius: 8px;
    color: #666;
    font-size: 16px;
}

/* Equal Height Cards */
.wtc-carousel-wrapper.equal-height .slick-track {
    display: flex;
    align-items: stretch;
}

.wtc-carousel-wrapper.equal-height .slick-slide {
    display: flex;
    height: auto;
    align-items: stretch;
}

.wtc-carousel-wrapper.equal-height .wtc-carousel-item {
    display: flex;
    height: 100%;
}

/* Responsive */
@media (max-width: 1024px) {
    .wtc-carousel-wrapper .slick-prev {
        left: -35px;
    }
    
    .wtc-carousel-wrapper .slick-next {
        right: -35px;
    }
}

@media (max-width: 768px) {
    .wtc-carousel-wrapper .slick-arrow {
        width: 35px;
        height: 35px;
    }
    
    .wtc-carousel-wrapper .slick-arrow:before {
        font-size: 16px;
    }
    
    .wtc-carousel-wrapper .slick-prev {
        left: -25px;
    }
    
    .wtc-carousel-wrapper .slick-next {
        right: -25px;
    }
    
    .wtc-carousel-title {
        font-size: 16px;
    }
}

@media (max-width: 480px) {
    .wtc-carousel-wrapper {
        margin: 0 -20px;
        padding: 0 20px;
    }
    
    .wtc-carousel-wrapper .slick-prev {
        left: 5px;
    }
    
    .wtc-carousel-wrapper .slick-next {
        right: 5px;
    }
    
    .wtc-carousel-wrapper .slick-arrow {
        background: rgba(255, 255, 255, 0.8);
    }
    
    .wtc-carousel-title {
        font-size: 14px;
    }
    
    .wtc-carousel-count {
        font-size: 12px;
    }
}

/* Visual Builder Specific */
.et-fb-root-ancestor .wtc-carousel-wrapper {
    min-height: 250px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Dark Section Support */
.et_pb_section.et_section_regular_dark .wtc-carousel-title,
.et_pb_section.et_section_specialty_dark .wtc-carousel-title {
    color: #fff;
}

.et_pb_section.et_section_regular_dark .wtc-carousel-count,
.et_pb_section.et_section_specialty_dark .wtc-carousel-count {
    color: rgba(255, 255, 255, 0.7);
}

.et_pb_section.et_section_regular_dark .wtc-carousel-link:hover .wtc-carousel-title,
.et_pb_section.et_section_specialty_dark .wtc-carousel-link:hover .wtc-carousel-title {
    color: #2ea3f2;
}

/* RTL Support */
.rtl .wtc-carousel-wrapper .slick-prev {
    left: auto;
    right: -50px;
}

.rtl .wtc-carousel-wrapper .slick-prev:before {
    content: '\35';
}

.rtl .wtc-carousel-wrapper .slick-next {
    right: auto;
    left: -50px;
}

.rtl .wtc-carousel-wrapper .slick-next:before {
    content: '\34';
}