/* ============================================
   Categories Slider - Modern & Clean Design
   ============================================ */

/* Main Container */
.categories-slider-container {
    background: linear-gradient(135deg, #007bff 0%, #0056b3 100%);
    padding: 16px 0;
    position: relative;
    z-index: 1020;
    border-top: 1px solid rgba(255, 255, 255, 0.15);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    margin: 0;
}

/* Wrapper */
.categories-slider-wrapper {
    position: relative;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 60px;
}

/* Content Area */
.categories-slider-content {
    overflow: hidden;
    position: relative;
    border-radius: 8px;
}

/* Track */
.categories-slider-track {
    display: flex;
    align-items: center;
    transition: transform 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    gap: 14px;
    padding: 4px 8px;
    will-change: transform;
}

/* Category Items */
.category-item {
    flex-shrink: 0;
    padding: 10px 24px;
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(10px);
    color: #ffffff;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    white-space: nowrap;
    font-size: 14px;
    font-weight: 500;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    min-height: 40px;
    line-height: 1.4;
    letter-spacing: 0.3px;
}

.category-item:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: translateY(-3px);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.2);
    text-decoration: none;
    color: #ffffff;
    border-color: rgba(255, 255, 255, 0.4);
}

.category-item:active {
    transform: translateY(-1px);
    box-shadow: 0 3px 6px rgba(0, 0, 0, 0.15);
}

.category-item:focus {
    outline: 2px solid rgba(255, 255, 255, 0.5);
    outline-offset: 2px;
}

/* Navigation Arrows */
.categories-slider-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 10;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    color: #ffffff;
    font-size: 16px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
}

.categories-slider-nav:hover {
    background: rgba(255, 255, 255, 0.25);
    border-color: rgba(255, 255, 255, 0.5);
    transform: translateY(-50%) scale(1.15);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

.categories-slider-nav:active {
    transform: translateY(-50%) scale(1.05);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
}

.categories-slider-prev {
    right: 8px;
}

.categories-slider-next {
    left: 8px;
}

.categories-slider-nav:disabled {
    opacity: 0.25;
    cursor: not-allowed;
    pointer-events: none;
    background: rgba(255, 255, 255, 0.08);
}

.categories-slider-nav:disabled:hover {
    transform: translateY(-50%) scale(1);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
}

/* Loading State */
.categories-loading {
    text-align: center;
    padding: 24px 20px;
    color: rgba(255, 255, 255, 0.9);
    font-size: 14px;
    font-weight: 500;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 40px;
}

.categories-loading span {
    display: inline-block;
    animation: pulse 1.5s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.6;
    }
}

/* Responsive Design - Tablet */
@media (max-width: 992px) {
    .categories-slider-wrapper {
        padding: 0 50px;
    }

    .categories-slider-nav {
        width: 36px;
        height: 36px;
        font-size: 14px;
    }

    .categories-slider-prev {
        right: 6px;
    }

    .categories-slider-next {
        left: 6px;
    }

    .category-item {
        padding: 9px 20px;
        font-size: 13.5px;
        min-height: 38px;
    }
}

/* Responsive Design - Mobile */
@media (max-width: 768px) {
    .categories-slider-container {
        padding: 14px 0;
    }

    .categories-slider-wrapper {
        padding: 0 45px;
    }

    .categories-slider-nav {
        width: 34px;
        height: 34px;
        font-size: 13px;
    }

    .categories-slider-prev {
        right: 4px;
    }

    .categories-slider-next {
        left: 4px;
    }

    .category-item {
        padding: 8px 18px;
        font-size: 13px;
        min-height: 36px;
        gap: 10px;
    }

    .categories-slider-track {
        gap: 10px;
        padding: 4px 6px;
    }
}

/* Responsive Design - Small Mobile */
@media (max-width: 576px) {
    .categories-slider-container {
        padding: 12px 0;
    }

    .categories-slider-wrapper {
        padding: 0 38px;
    }

    .categories-slider-nav {
        width: 32px;
        height: 32px;
        font-size: 12px;
    }

    .categories-slider-prev {
        right: 3px;
    }

    .categories-slider-next {
        left: 3px;
    }

    .category-item {
        padding: 7px 16px;
        font-size: 12px;
        min-height: 34px;
        border-radius: 6px;
    }

    .categories-slider-track {
        gap: 8px;
        padding: 3px 4px;
    }

    .categories-loading {
        padding: 20px 15px;
        font-size: 13px;
    }
}

/* Extra Small Devices */
@media (max-width: 400px) {
    .categories-slider-wrapper {
        padding: 0 32px;
    }

    .categories-slider-nav {
        width: 28px;
        height: 28px;
        font-size: 11px;
    }

    .category-item {
        padding: 6px 14px;
        font-size: 11.5px;
        min-height: 32px;
    }
}

/* Smooth Scrolling Enhancement */
.categories-slider-content {
    -webkit-overflow-scrolling: touch;
    scroll-behavior: smooth;
}

/* Accessibility Improvements */
.categories-slider-nav:focus {
    outline: 2px solid rgba(255, 255, 255, 0.6);
    outline-offset: 2px;
}

.category-item:focus-visible {
    outline: 2px solid rgba(255, 255, 255, 0.6);
    outline-offset: 2px;
}

/* Performance Optimization */
.categories-slider-track {
    backface-visibility: hidden;
    perspective: 1000px;
}

.category-item {
    will-change: transform;
}

/* Ensure proper alignment */
.categories-slider-container {
    display: block;
    width: 100%;
}

.categories-slider-wrapper {
    display: block;
    width: 100%;
}
