/* ========================================
   SYSTÈME DE CATÉGORIES
   ======================================== */

.categories-container {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin: 25px 0;
    padding: 20px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 15px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    animation: slideDown 0.5s ease;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ========================================
   BOUTONS DE CATÉGORIE
   ======================================== */

.category-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 20px;
    background: rgba(255, 255, 255, 0.05);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 25px;
    color: rgba(255, 255, 255, 0.8);
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.category-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, var(--category-color), transparent);
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: 0;
}

.category-btn:hover::before {
    opacity: 0.2;
}

.category-btn:hover {
    transform: translateY(-2px);
    border-color: var(--category-color);
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.3);
}

.category-btn.active {
    background: var(--category-color);
    border-color: var(--category-color);
    color: white;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.4);
    transform: translateY(-2px);
}

.category-btn.active::before {
    opacity: 0;
}

.category-icon {
    font-size: 20px;
    z-index: 1;
    position: relative;
}

.category-name {
    z-index: 1;
    position: relative;
}

.category-count {
    background: rgba(0, 0, 0, 0.3);
    padding: 2px 8px;
    border-radius: 10px;
    font-size: 12px;
    font-weight: bold;
    z-index: 1;
    position: relative;
}

.category-btn.active .category-count {
    background: rgba(255, 255, 255, 0.2);
}

/* ========================================
   ANIMATION DE TRANSITION DES JEUX
   ======================================== */

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: scale(0.95);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* ========================================
   CARTES "BIENTÔT DISPONIBLE"
   ======================================== */

.coming-soon-card {
    position: relative;
    opacity: 0.7;
    cursor: default !important;
}

.coming-soon-card:hover {
    transform: translateY(-5px);
}

.game-soon-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.9), transparent);
    padding: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.game-soon-text {
    background: rgba(255, 152, 0, 0.9);
    padding: 8px 16px;
    border-radius: 20px;
    font-weight: bold;
    font-size: 13px;
    color: white;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.badge-soon {
    background: linear-gradient(135deg, #ff9800, #ff5722);
}

/* ========================================
   AUCUN JEU TROUVÉ
   ======================================== */

.no-games {
    grid-column: 1 / -1;
    text-align: center;
    padding: 80px 20px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 20px;
    border: 2px dashed rgba(255, 255, 255, 0.1);
}

.no-games-icon {
    font-size: 80px;
    margin-bottom: 20px;
    opacity: 0.5;
    animation: float 3s ease-in-out infinite;
}

@keyframes float {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-10px);
    }
}

.no-games h3 {
    font-size: 24px;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 10px;
}

.no-games p {
    font-size: 16px;
    color: rgba(255, 255, 255, 0.5);
}

/* ========================================
   AMÉLIORATION DE LA BARRE DE RECHERCHE
   ======================================== */

#searchBar {
    width: 100%;
    max-width: 500px;
    padding: 12px 20px;
    font-size: 15px;
    border-radius: 25px;
    border: 2px solid rgba(255, 255, 255, 0.1);
    background: rgba(255, 255, 255, 0.05);
    color: white;
    transition: all 0.3s ease;
}

#searchBar::placeholder {
    color: rgba(255, 255, 255, 0.4);
}

#searchBar:focus {
    outline: none;
    border-color: var(--accent);
    background: rgba(255, 255, 255, 0.08);
    box-shadow: 0 0 20px rgba(100, 255, 218, 0.2);
}

/* ========================================
   RESPONSIVE
   ======================================== */

@media (max-width: 1200px) {
    .categories-container {
        gap: 10px;
        padding: 15px;
    }

    .category-btn {
        padding: 10px 16px;
        font-size: 13px;
    }

    .category-icon {
        font-size: 18px;
    }
}

@media (max-width: 768px) {
    .categories-container {
        gap: 8px;
        padding: 12px;
        justify-content: center;
    }

    .category-btn {
        padding: 8px 12px;
        font-size: 12px;
        flex: 0 0 auto;
    }

    .category-icon {
        font-size: 16px;
    }

    .category-name {
        display: none;
    }

    .category-btn:hover .category-name,
    .category-btn.active .category-name {
        display: inline;
    }

    .category-count {
        font-size: 10px;
        padding: 2px 6px;
    }
}

@media (max-width: 480px) {
    .categories-container {
        padding: 10px;
    }

    .category-btn {
        padding: 6px 10px;
    }
}

/* ========================================
   AMÉLIORATION DES BADGES
   ======================================== */

.game-badge {
    position: absolute;
    top: 15px;
    right: 15px;
    background: linear-gradient(135deg, var(--accent), #667eea);
    color: white;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: bold;
    letter-spacing: 1px;
    z-index: 10;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

/* ========================================
   EFFET HOVER SUR LES CARTES
   ======================================== */

.game-card {
    transition: all 0.3s ease;
}

.game-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.5);
}

.game-card::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, var(--accent) 0%, transparent 50%);
    opacity: 0;
    transition: opacity 0.3s ease;
    border-radius: 15px;
    pointer-events: none;
}

.game-card:hover::after {
    opacity: 0.1;
}

/* ========================================
   SCROLL DOUX
   ======================================== */

.games-container {
    scroll-behavior: smooth;
}
