/* AO Page Banner Styles */

.ao-banner-carousel {
    position: relative;
    width: 100%;
    background: #f0f0f0;
    overflow: hidden;
    border-radius: 0;
}

.ao-banner-slides {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 6;
    display: flex;
    align-items: stretch;
}

.ao-banner-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.8s ease-in-out;
    background-color: #f0f0f0; /* Fallback color while loading */
}

/* Loading state spinner */
.ao-banner-slide.bg-loading::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 50px;
    height: 50px;
    margin: -25px 0 0 -25px;
    border: 5px solid rgba(255, 255, 255, 0.3);
    border-top: 5px solid rgba(255, 255, 255, 0.8);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    z-index: 1;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Blurred background layer - only shows after image loads */
.ao-banner-slide.bg-loaded::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    filter: blur(40px); /* Adjust blur intensity (20px to 60px) */
    transform: scale(1.1); /* Slightly scale to hide blur edges */
    z-index: 1;
    animation: none; /* Override loading animation */
}

/* Sharp image layer on top - only shows after image loads */
.ao-banner-slide.bg-loaded::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    z-index: 2;
}

.ao-banner-slide.active {
    opacity: 1;
    z-index: 2;
}

.ao-banner-content {
    position: relative;
    z-index: 5;
    padding: 40px;
    color: white;
    display: flex;
    flex-direction: column;    
    max-width: 1200px;
    width: 90%;
    margin: 0 auto;
}

h2.ao-banner-title {
    margin: 0 0 15px 0;
    font-size: 55px;
    font-weight: 800;
    line-height: 1.2;    
    font-family: 'Roboto', 'Poppins';
    color: #ffffff !important;    
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.8);
    font-style: normal;
    text-decoration: none;
    text-align: inherit;
    letter-spacing: 1px;
    word-spacing: normal;
    text-transform: none;
}

.ao-banner-description {
    margin: 0 0 25px 0;
    font-size: 28px;
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.95);
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.8);
}

.ao-banner-description p {
    margin: 0 0 10px 0;
}

.ao-banner-description p:last-child {
    margin-bottom: 0;
}

.ao-banner-description strong {
    color: white;
}

.ao-banner-button {
    display: inline-block;
    padding: 12px 28px;
    background: #78160e;
    color: var(--ast-global-color-5);
    text-decoration: none !important;
    border-radius: 40px;
    font-weight: 600;
    font-size: 26px;
    transition: all 0.3s ease;
    width: fit-content;
}

.ao-banner-content a {
    text-decoration: none !important;
}

.ao-banner-button:hover {
    background-color: var(--ast-global-color-5);
    color: #78160e;
}

/* Carousel Indicators */
.ao-banner-dots {
    position: absolute;
    bottom: 20px;
    right: 20px;
    display: flex;
    gap: 8px;
    z-index: 10;
}

.ao-banner-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
}

.ao-banner-dot:hover {
    background-color: rgba(255, 255, 255, 0.75);
}

.ao-banner-dot.active {
    background-color: #fff;
    width: 24px;
    border-radius: 5px;
}

.ao-banner-empty {
    padding: 40px;
    text-align: center;
    color: #999;
    font-size: 16px;
    background-color: #f5f5f5;
    border-radius: 8px;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .ao-banner-content {
        width: 85%;
        padding: 35px;
    }

    h2.ao-banner-title {
        font-size: 45px;
    }

    .ao-banner-description {
        font-size: 24px;
    }
    
    .ao-banner-slide.bg-loaded::before {
        filter: blur(30px);
    }
}

@media (max-width: 768px) {
    .ao-banner-slides {
        aspect-ratio: 4 / 3;
    }

    .ao-banner-content {
        width: 90%;
        padding: 30px 20px;
    }

    h2.ao-banner-title {
        font-size: 32px;
        margin-bottom: 12px;
    }

    .ao-banner-description {
        font-size: 18px;
        margin-bottom: 20px;
    }

    .ao-banner-button {
        padding: 10px 24px;
        font-size: 13px;
    }

    .ao-banner-dots {
        bottom: 15px;
        right: 15px;
        gap: 6px;
    }

    .ao-banner-dot {
        width: 8px;
        height: 8px;
    }

    .ao-banner-dot.active {
        width: 20px;
    }
    
    .ao-banner-slide.bg-loaded::before {
        filter: blur(25px);
    }
    
    .ao-banner-slide.bg-loading::before {
        width: 40px;
        height: 40px;
        margin: -20px 0 0 -20px;
        border-width: 4px;
    }
}

@media (max-width: 480px) {
    .ao-banner-slides {
        aspect-ratio: 1 / 1;
    }

    .ao-banner-content {
        width: 90%;
        padding: 20px 15px;
    }

    h2.ao-banner-title {
        font-size: 24px;
        margin-bottom: 10px;
        letter-spacing: 0.5px;
    }

    .ao-banner-description {
        font-size: 14px;
        margin-bottom: 15px;
    }

    .ao-banner-button {
        padding: 10px 20px;
        font-size: 12px;
    }

    .ao-banner-dots {
        bottom: 10px;
        right: 10px;
        gap: 5px;
    }

    .ao-banner-dot {
        width: 7px;
        height: 7px;
    }

    .ao-banner-dot.active {
        width: 18px;
    }
    
    .ao-banner-slide.bg-loaded::before {
        filter: blur(20px);
    }
    
    .ao-banner-slide.bg-loading::before {
        width: 35px;
        height: 35px;
        margin: -17.5px 0 0 -17.5px;
        border-width: 3px;
    }
}

@media (max-width: 360px) {
    h2.ao-banner-title {
        font-size: 20px;
    }

    .ao-banner-description {
        font-size: 12px;
    }

    .ao-banner-button {
        padding: 8px 16px;
        font-size: 11px;
    }
    
    .ao-banner-slide.bg-loading::before {
        width: 30px;
        height: 30px;
        margin: -15px 0 0 -15px;
    }
}