/* Base responsive styles */
.slider-container {
    position: relative;
    width: 100%;
    height: 0;
    padding-bottom: 56.25%; /* 16:9 aspect ratio by default */
    overflow: hidden;
    margin: 20px 0;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.slider-wrapper {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.5s ease;
}

.slide.active {
    opacity: 1;
}

.slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

.slide-content {
    position: absolute;
    bottom: 50px;
    left: 50px;
    color: #fff;
    text-shadow: 2px 2px 5px rgba(0, 0, 0, 0.8);
    max-width: 80%;
    z-index: 2;
}

.slider-navigation {
    position: absolute;
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    top: 50%;
    transform: translateY(-50%);
    padding: 0 20px;
    z-index: 10;
}

.prev-btn, .next-btn {
    width: 50px;
    height: 50px;
    background-color: rgba(255, 255, 255, 0.2);
    border: none;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: white;
    font-size: 1.2rem;
    transition: background-color 0.3s;
}

.prev-btn:hover, .next-btn:hover {
    background-color: rgba(255, 255, 255, 0.5);
}

.slider-indicators {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
}

.indicator {
    width: 12px;
    height: 12px;
    background-color: rgba(255, 255, 255, 0.5);
    border-radius: 50%;
    cursor: pointer;
    transition: background-color 0.3s;
}

.indicator.active,
.indicator:hover {
    background-color: #FFB800;
}

/* Laptop and Desktop (1024px and up) */
@media (min-width: 1024px) {
    .slider-container {
        padding-bottom: 40%; /* Slightly shorter aspect ratio */
        max-height: 600px;
    }
}

/* Tablets and small laptops (768px to 1023px) */
@media (min-width: 768px) and (max-width: 1023px) {
    .slider-container {
        padding-bottom: 45%; /* Middle ground aspect ratio */
        max-height: 500px;
        border-radius: 8px;
    }
    
    .slide-content {
        bottom: 40px;
        left: 40px;
    }
    
    .prev-btn, .next-btn {
        width: 45px;
        height: 45px;
        font-size: 1.1rem;
    }
}

/* Large Mobile (481px to 767px) */
@media (min-width: 481px) and (max-width: 767px) {
    .slider-container {
        padding-bottom: 56.25%; /* Return to 16:9 */
        max-height: 400px;
        border-radius: 8px;
    }
    
    .slide-content {
        bottom: 30px;
        left: 30px;
    }
    
    .prev-btn, .next-btn {
        width: 40px;
        height: 40px;
        font-size: 1rem;
    }
    
    .slider-indicators {
        bottom: 15px;
    }
    
    .indicator {
        width: 10px;
        height: 10px;
        margin: 0 5px;
    }
}

/* Small Mobile (480px and down) */
@media (max-width: 480px) {
    .slider-container {
        padding-bottom: 75%; /* Taller aspect ratio for mobile */
        max-height: 350px;
        margin: 15px 0;
        border-radius: 6px;
    }
    
    .slide-content {
        bottom: 20px;
        left: 20px;
        max-width: 90%;
    }
    
    .prev-btn, .next-btn {
        width: 35px;
        height: 35px;
        font-size: 0.9rem;
    }
    
    .slider-indicators {
        bottom: 10px;
    }
    
    .indicator {
        width: 8px;
        height: 8px;
        margin: 0 4px;
    }
}

/* Extra Small Mobile (320px and down) */
@media (max-width: 320px) {
    .slider-container {
        padding-bottom: 80%; /* Even taller for very small screens */
        max-height: 280px;
        border-radius: 5px;
    }
    
    .slide-content {
        bottom: 15px;
        left: 15px;
    }
    
    .prev-btn, .next-btn {
        width: 30px;
        height: 30px;
        font-size: 0.8rem;
    }
}

/* Support for High Pixel Density Screens */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
    .slide img {
        object-fit: contain;
    }
}

/* Orientation-specific adjustments */
@media (orientation: landscape) and (max-width: 767px) {
    .slider-container {
        padding-bottom: 50%; /* Less tall in landscape orientation */
    }
}