/* Hero Slider CSS - Infinite Right to Left Animation */

/* Slider Container */
.hero-slider-container {
    background: rgba(255, 255, 255, 0);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    height: 220px;
    width: 100%;
}

/* Slider Track - Auto Slide Functionality */
.hero-slider-track {
    transition: transform 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* Smooth slide transition */
.hero-slider-track.sliding {
    transition: transform 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* Pause sliding on hover */
.hero-slider-container:hover {
    /* Add visual feedback on hover */
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.2);
}

/* Individual Slider Card */
.hero-slider-card {
    flex: 0 0 100%;
    width: 100%;
    height: 100%;
    min-height: 215px;
    margin: 0;
    border-radius: 16px;
    position: relative;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
}

/* Card Hover Effect */
/* .hero-slider-card:hover {
    transform: translateY(-5px) scale(1.05);
    box-shadow:
        0 20px 40px rgba(0, 0, 0, 0.3),
        0 10px 20px rgba(0, 0, 0, 0.2);
} */

/* Card Overlay Gradient */
.hero-slider-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    /* background: linear-gradient(135deg,
            rgba(0, 0, 0, 0.2) 0%,
            rgba(0, 0, 0, 0.4) 40%,
            rgba(0, 0, 0, 0.7) 100%); */
    border-radius: 16px;
    transition: opacity 0.3s ease;
}

/* Card Content Overlay */
.hero-slider-content {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 20px;
    color: white;
    z-index: 2;
    /* background: linear-gradient(to top,
            rgba(0, 0, 0, 0.8) 0%,
            rgba(0, 0, 0, 0.4) 60%,
            transparent 100%); */
    border-radius: 0 0 16px 16px;
}

/* Card Title */
.hero-slider-title {
    font-weight: 700;
    margin-bottom: 8px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    line-height: 1.4rem;
    line-clamp: 2;
    overflow: hidden;
}

/* Card Description */
.hero-slider-description {
    font-size: 0.9rem;
    line-height: 1.4;
    opacity: 0.9;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    padding-bottom: 40px;
    overflow: hidden;
}

/* Card Meta Info */
.hero-slider-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.75rem;
    opacity: 0;
}

/* View Count Badge */
.hero-slider-views {
    display: flex;
    align-items: center;
    background: rgba(255, 255, 255, 0.2);
    padding: 4px 8px;
    border-radius: 20px;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.hero-slider-views svg {
    width: 12px;
    height: 12px;
    margin-right: 4px;
}

/* Popular Badge */
.hero-slider-popular {
    position: absolute;
    top: 12px;
    right: 12px;
    background: linear-gradient(45deg, #ff6b6b, #ff8e8e);
    color: white;
    font-size: 0.7rem;
    font-weight: 600;
    padding: 2px 8px;
    border-radius: 12px;
    z-index: 3;
    box-shadow: 0 2px 8px rgba(255, 107, 107, 0.3);
}

/* Loading Animation */
.hero-slider-loading {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 215px;
    /* Match container height */
    color: rgba(255, 255, 255, 0.8);
    font-size: 1rem;
}

.hero-slider-loading::after {
    content: '';
    width: 30px;
    height: 30px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-top: 3px solid rgba(255, 255, 255, 0.8);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-left: 10px;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

/* Smooth Performance Optimizations */
.hero-slider-track {
    will-change: transform;
    backface-visibility: hidden;
    perspective: 1000px;
}

.hero-slider-card {
    will-change: transform;
    backface-visibility: hidden;
    transform-style: preserve-3d;
}

/* Alternative Background for Cards without Images */
.hero-slider-card.no-image {
    background: linear-gradient(135deg,
            rgba(59, 130, 246, 0.8) 0%,
            rgba(20, 184, 166, 0.8) 100%);
}

.hero-slider-card.no-image::before {
    background: linear-gradient(135deg,
            rgba(0, 0, 0, 0.1) 0%,
            rgba(0, 0, 0, 0.3) 100%);
}

/* Slide Indicators */
.hero-slider-indicators {
    position: absolute;
    bottom: 7px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 8px;
    z-index: 10;
}

.hero-slider-dot {
    width: 12px;
    height: 4px;
    border-radius: 30px;
    background: whitesmoke;
    cursor: pointer;
    transition: all 0.3s ease;
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(20px);
}

.hero-slider-dot.active {
    background: rgba(59, 130, 246, 0.9);
    border-color: rgba(255, 255, 255, 0.9);
    transform: scale(1.2);
    box-shadow: 0 0 10px rgba(59, 130, 246, 0.5);
}

.hero-slider-dot:hover {
    background: rgba(59, 130, 246, 0.3);
    transform: scale(1.1);
}

/* Auto-slide progress bar */
.hero-slider-progress {
    position: absolute;
    bottom: 0;
    left: 0;
    height: 2px;
    background: whitesmoke;
    transition: width 0.1s linear;
    border-radius: 0 0 0 20px;
    z-index: 5;
}

/* Navigation arrows */
.hero-slider-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.6);
    color: white;
    border: none;
    width: 45px;
    height: 45px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    transition: all 0.3s ease;
    z-index: 10;
    opacity: 0.8;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

.hero-slider-nav:hover {
    background: rgba(0, 0, 0, 0.8);
    opacity: 1;
    transform: translateY(-50%) scale(1.1);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

.hero-slider-nav.prev {
    left: 15px;
}

.hero-slider-nav.next {
    right: 15px;
}

.hero-slider-nav svg {
    width: 18px;
    height: 18px;
}

/* Responsive Design */
@media (min-width: 640px) {
    .hero-slider-loading {
        height: 400px;
        /* Match container height */
    }
}

@media (min-width: 768px) {
    .hero-slider-container {
        margin: 1.5rem 0;
    }

    .hero-slider-card {
        flex: 0 0 100%;
    }

    .hero-slider-track {
        /* Remove mobile-specific animation - let JavaScript handle it */
        animation: none;
    }

    .hero-slider-content {
        padding: 15px;
    }

    /* Hide navigation arrows on mobile - touch/swipe preferred */
    .hero-slider-nav {
        display: none;
    }
}

@media (min-width: 1024px) {

    .hero-slider-loading {
        height: 400px;
        /* Match container height */
    }

    .hero-slider-nav {
        display: flex;
        /* Show navigation arrows on desktop */
    }
    .hero-slider-title {
        font-size: 1.3rem;
        padding: 0 10px;
    }

    .hero-slider-description {
        font-size: 1rem;
        -webkit-line-clamp: 2;
    }
}

@media (max-width: 500px) {
    .hero-slider-popular {
        top: 6px;
        right: 6px;
        font-size: 0.7rem;
        font-weight: 600;
    }

    .hero-slider-card {
        flex: 0 0 100%;
        border-radius: 12px;
    }

    .hero-slider-track {
        /* Remove mobile-specific animation - let JavaScript handle it */
        animation: none;
    }

    .hero-slider-content {
        padding: 12px;
    }

    .hero-slider-indicators {
        bottom: 10px;
    }

    .hero-slider-views {
        background: rgba(255, 255, 255, 0);
        padding: 2px 8px;
        margin-left: -10px;
        margin-bottom: -15px;
    }

    .hero-slider-views svg {
        width: 12px;
        height: 12px;
        margin-right: 4px;
    }
}


/* 📱 Up to 400px (very small phones) */
@media (min-width: 400px) {
    .hero-slider-container {
        height: 250px;
    }
}

@media (min-width: 500px) {
    .hero-slider-container {
        height: 300px;
    }
}

@media (min-width: 600px) {
    .hero-slider-container {
        height: 350px;
    }
}

@media (min-width: 700px) {
    .hero-slider-container {
        height: 380px;
        width: 600px;
        margin: 1.5rem auto;
    }
    .hero-slider-title {
        font-size: 1.5rem;
        padding: 0 10px;
    }

    .hero-slider-description {
        font-size: 1rem;
        -webkit-line-clamp: 2;
        padding: 0px 15px 20px 15px;
    }
}

@media (min-width: 800px) {
    .hero-slider-container {
        height: 380px;
        width: 700px;
    }
}

@media (min-width: 900px) {
    .hero-slider-container {
        height: 400px;
        width: 95%;
    }
}

@media (min-width: 1000px) {
    .hero-slider-container {
        height: 420px;
        width: 80%;
    }
}

@media (min-width: 1100px) {
    .hero-slider-container {
        height: 500px;
        width: 90%;
    }
}