/* Modern Sports Categories Styling - Enhanced Version */

/* Section header styling */
.category-section-header {
    display: flex;
    flex-direction: column;
    margin-bottom: 8px;
    padding-left: 5px;
}

.category-section-title {
    font-size: 18px;
    font-weight: 700;
    color: #ffffff;
    margin: 0;
    line-height: 1.3;
    letter-spacing: 0.5px;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}

.category-section-subtitle {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.7);
    margin-top: 2px;
    font-weight: 400;
}

@media (max-width: 768px) {
    .category-section-title {
        font-size: 16px;
    }
    .category-section-subtitle {
        font-size: 12px;
    }
}

/* Main wrapper styling with 3D depth effect */
.categories-wrapper {
    background: linear-gradient(135deg, #1e2235 0%, #171a28 100%);
    border-radius: 12px;
    padding: 12px 10px;
    margin: 12px 0;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.25);
    overflow-x: auto;
    scrollbar-width: thin;
    scrollbar-color: rgba(255, 255, 255, 0.2) transparent;
    position: relative;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

/* Glass-like effect overlay */
.categories-wrapper::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 50%;
    background: linear-gradient(to bottom, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0));
    border-radius: 18px 18px 0 0;
    pointer-events: none;
}

/* Custom scrollbar with glow effect */
.categories-wrapper::-webkit-scrollbar {
    height: 6px;
}

.categories-wrapper::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.2);
    border-radius: 10px;
    margin: 0 15px;
}

.categories-wrapper::-webkit-scrollbar-thumb {
    background: linear-gradient(to right, #3498db, #2980b9);
    border-radius: 10px;
    box-shadow: 0 0 5px rgba(52, 152, 219, 0.5);
}

.categories-wrapper::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(to right, #3498db, #2980b9);
    box-shadow: 0 0 8px rgba(52, 152, 219, 0.7);
}

/* Container for categories with enhanced spacing */
.categories-container {
    display: flex;
    flex-wrap: nowrap;
    gap: 15px;
    padding: 5px;
    align-items: center;
}

/* Individual category item styled to match the site theme */
.category-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-width: 110px;
    padding: 12px 8px;
    border-radius: 12px;
    background: rgba(30, 34, 53, 0.5);
    transition: all 0.2s ease;
    border: 1px solid rgba(255, 255, 255, 0.05);
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    cursor: pointer;
}

/* Hover effect matching tournament groups */
.category-item:hover {
    background: rgba(30, 34, 53, 0.7);
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
    border-color: rgba(255, 255, 255, 0.08);
}

/* Active state matching the blue accent used in tournaments */
.category-item.active {
    background: linear-gradient(
        90deg,
        rgba(13, 102, 233, 0.15),
        rgba(13, 102, 233, 0.08)
    );
    border: 1px solid rgba(13, 102, 233, 0.25);
    box-shadow: 0 5px 16px rgba(13, 102, 233, 0.2);
}

/* Icon styling to match tournament header styling */
.category-icon {
    background: rgba(13, 102, 233, 0.08);
    width: 48px;
    height: 48px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 8px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    transition: all 0.2s ease;
    position: relative;
    overflow: hidden;
}

/* Remove shine effect for a cleaner look */
.category-icon::before {
    display: none;
}

/* Simpler hover effect to match site theme */
.category-item:hover .category-icon {
    transform: scale(1.05);
    background: rgba(13, 102, 233, 0.12);
}

/* Active state matching tournament blue accent */
.category-item.active .category-icon {
    background: rgba(13, 102, 233, 0.15);
    box-shadow: 0 4px 12px rgba(13, 102, 233, 0.2);
}

/* Icon styling to match tournament styling */
.category-icon i {
    font-size: 22px !important;
    color: rgba(255, 255, 255, 0.85);
    transition: all 0.2s ease;
    position: relative;
    z-index: 2;
}

.category-item:hover .category-icon i {
    transform: scale(1.1);
    color: #ffffff;
}

.category-item.active .category-icon i {
    color: #3498db;
}

/* Category name styling to match site theme */
.category-name {
    font-size: 13px;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.8);
    text-align: center;
    margin-top: 6px;
    transition: all 0.2s ease;
    position: relative;
    z-index: 2;
}

.category-item:hover .category-name {
    color: #ffffff;
}

.category-item.active .category-name {
    color: #3498db;
}

/* Subtle pulse animation for active category */
.category-item.active::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(13, 102, 233, 0.1);
    border-radius: inherit;
    z-index: -1;
    animation: subtlePulse 2s infinite;
}

@keyframes subtlePulse {
    0% {
        opacity: 0.5;
    }
    50% {
        opacity: 0.2;
    }
    100% {
        opacity: 0.5;
        box-shadow: 0 0 0 0 rgba(52, 152, 219, 0);
    }
}

/* Enhanced ripple effect on click */
.category-item::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 5px;
    height: 5px;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.7) 0%, rgba(255, 255, 255, 0.3) 70%);
    opacity: 0;
    border-radius: 100%;
    transform: scale(1, 1) translate(-50%, -50%);
    transform-origin: 50% 50%;
    z-index: 1;
}

.category-item:active::after {
    animation: enhancedRipple 0.6s ease-out;
}

@keyframes enhancedRipple {
    0% {
        transform: scale(0, 0) translate(-50%, -50%);
        opacity: 0.5;
    }
    20% {
        transform: scale(20, 20) translate(-50%, -50%);
        opacity: 0.3;
    }
    100% {
        opacity: 0;
        transform: scale(50, 50) translate(-50%, -50%);
    }
}

/* Subtle scale effect on click */
.category-item:active {
    transform: scale(0.97);
    transition: transform 0.1s ease;
}

.category-item:active .category-icon {
    transform: scale(0.95);
    transition: transform 0.1s ease;
}

/* Using only the ::after pseudo-element ripple for a cleaner implementation */

/* Enhanced responsive adjustments */
@media (max-width: 768px) {
    .categories-wrapper {
        padding: 12px 10px;
        border-radius: 14px;
        margin: 12px 0;
    }

    .categories-container {
        gap: 12px;
        padding: 3px;
    }

    .category-item {
        min-width: 95px;
        padding: 10px 8px;
        border-radius: 14px;
    }

    .category-icon {
        width: 46px;
        height: 46px;
        border-radius: 14px;
        margin-bottom: 6px;
    }

    .category-icon i {
        font-size: 22px !important;
    }

    .category-name {
        font-size: 12px;
        margin-top: 6px;
    }
}

/* Small mobile optimization */
@media (max-width: 480px) {
    .categories-wrapper {
        padding: 10px 8px;
        border-radius: 12px;
    }

    .categories-container {
        gap: 8px;
    }

    .category-item {
        min-width: 85px;
        padding: 8px 5px;
    }

    .category-icon {
        width: 42px;
        height: 42px;
        border-radius: 12px;
    }

    .category-icon i {
        font-size: 20px !important;
    }

    .category-name {
        font-size: 11px;
        letter-spacing: 0.2px;
    }
}