/* Advertisement Banner Slider Styles */

.section-advertisements {
    position: relative;
    overflow: hidden;
    padding: 40px 0 !important;
    background: #f8f9fa !important;
}

.advertisement-slider-wrapper {
    max-width: 1200px;
    margin: 0 auto;
    position: relative;
    padding: 0 15px;
}

#advertisementCarousel {
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
    border-radius: 15px;
    overflow: hidden;
}

/* Carousel customization */
.carousel-item {
    height: 400px;
}

.carousel-item img {
    height: 400px;
    width: 100%;
    object-fit: cover;
    display: block;
}

/* Responsive heights */
@media (max-width: 768px) {
    .carousel-item {
        height: 300px;
    }
    
    .carousel-item img {
        height: 300px;
    }
}

@media (max-width: 576px) {
    .carousel-item {
        height: 200px;
    }
    
    .carousel-item img {
        height: 200px;
    }
}

.carousel-caption {
    background: rgba(0, 0, 0, 0.7) !important;
    backdrop-filter: blur(10px);
    border-radius: 10px !important;
    padding: 25px !important;
    bottom: 30px;
    left: 50px;
    right: 50px;
}

.carousel-caption h3 {
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 10px;
    text-shadow: 2px 2px 6px rgba(0, 0, 0, 0.9);
}

.carousel-caption p {
    font-size: 18px;
    margin-bottom: 0;
    text-shadow: 1px 1px 4px rgba(0, 0, 0, 0.9);
}

/* RTL support for captions */
html[dir="rtl"] .carousel-caption {
    text-align: right;
}

/* Controls styling */
.carousel-control-prev,
.carousel-control-next {
    width: 60px;
    height: 60px;
    background: rgba(0, 0, 0, 0.5);
    border-radius: 50%;
    top: 50%;
    transform: translateY(-50%);
    opacity: 0;
    transition: all 0.3s ease;
}

.advertisement-slider-wrapper:hover .carousel-control-prev,
.advertisement-slider-wrapper:hover .carousel-control-next {
    opacity: 1;
}

.carousel-control-prev {
    left: 20px;
}

.carousel-control-next {
    right: 20px;
}

.carousel-control-prev-icon,
.carousel-control-next-icon {
    width: 30px;
    height: 30px;
}

/* Indicators styling */
.carousel-indicators {
    bottom: 15px;
}

.carousel-indicators li {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.5);
    border: 2px solid white;
    margin: 0 5px;
    transition: all 0.3s ease;
}

.carousel-indicators li.active {
    background-color: white;
    width: 35px;
    border-radius: 10px;
}

/* Clickable ad styling */
.ad-link {
    display: block;
    position: relative;
    cursor: pointer;
    transition: transform 0.3s ease;
}

.ad-link:hover {
    transform: scale(1.02);
}

.ad-link::after {
    content: '🔗';
    position: absolute;
    top: 20px;
    right: 20px;
    background: rgba(255, 255, 255, 0.9);
    padding: 10px 15px;
    border-radius: 25px;
    font-size: 16px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.ad-link:hover::after {
    opacity: 1;
}

/* Mobile responsive */
@media (max-width: 768px) {
    .carousel-caption {
        left: 20px;
        right: 20px;
        bottom: 15px;
        padding: 15px !important;
    }
    
    .carousel-caption h3 {
        font-size: 20px;
    }
    
    .carousel-caption p {
        font-size: 14px;
    }
    
    .carousel-control-prev,
    .carousel-control-next {
        width: 40px;
        height: 40px;
    }
    
    .carousel-control-prev {
        left: 10px;
    }
    
    .carousel-control-next {
        right: 10px;
    }
    
    .carousel-indicators li {
        width: 8px;
        height: 8px;
    }
    
    .carousel-indicators li.active {
        width: 25px;
    }
}

/* Fade animation for slides */
.carousel-item {
    transition: transform 0.6s ease-in-out, opacity 0.6s ease-in-out;
}

.carousel-item-next,
.carousel-item-prev,
.carousel-item.active {
    display: block;
}

/* Loading placeholder */
.ad-loading {
    height: 400px;
    background: linear-gradient(90deg, #f0f0f0 0%, #e0e0e0 50%, #f0f0f0 100%);
    background-size: 200% 100%;
    animation: loading 1.5s ease-in-out infinite;
    border-radius: 15px;
}

@keyframes loading {
    0% {
        background-position: 200% 0;
    }
    100% {
        background-position: -200% 0;
    }
}

