/* ==================================================
   GAME GRID SYSTEM
   Engels811 Network – Dark Crimson Theme
   Zweck:
   - Toolbar & Filters
   - Responsive Game Grid
   - Fokus auf Optik & Ruhe
   - KEINE festen Spaltenzahlen
================================================== */

/* =========================
   GAMES TOOLBAR
========================= */
.games-toolbar {
    display: flex;
    gap: 1rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
    align-items: center;
}

.games-search {
    flex: 1;
    min-width: 260px;
    padding: 0.75rem 1rem;
    background: rgba(20, 20, 20, 0.8);
    border: 1px solid rgba(255, 50, 50, 0.25);
    border-radius: 8px;
    color: #fff;
    font-size: 1rem;
    transition: border-color 0.25s ease, box-shadow 0.25s ease;
}

.games-search:focus {
    outline: none;
    border-color: #ff4444;
    box-shadow: 0 0 0 3px rgba(255, 50, 50, 0.12);
}

.games-search::placeholder {
    color: #666;
}

.games-sort {
    padding: 0.75rem 1rem;
    background: rgba(20, 20, 20, 0.8);
    border: 1px solid rgba(255, 50, 50, 0.25);
    border-radius: 8px;
    color: #fff;
    font-size: 1rem;
    cursor: pointer;
    transition: border-color 0.25s ease, background 0.25s ease;
}

.games-sort:hover,
.games-sort:focus {
    outline: none;
    border-color: #ff4444;
    background: rgba(30, 30, 30, 0.9);
}

/* =========================
   CATEGORY FILTERS
========================= */
.category-filters {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.category-filters button {
    padding: 0.5rem 1rem;
    background: rgba(20, 20, 20, 0.8);
    border: 1px solid rgba(255, 50, 50, 0.25);
    border-radius: 6px;
    color: #e8e8e8;
    font-size: 0.9rem;
    cursor: pointer;
    text-transform: capitalize;
    transition: border-color 0.25s ease, color 0.25s ease, background 0.25s ease;
}

.category-filters button:hover {
    background: rgba(30, 30, 30, 0.9);
    border-color: #ff4444;
    color: #ff6666;
}

.category-filters button.active {
    background: linear-gradient(135deg, #ff3232 0%, #cc0000 100%);
    border-color: #ff3232;
    color: #fff;
    font-weight: 600;
}

/* =========================
   GAMES GRID (FINAL)
========================= */
.games-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 26px;
    align-items: stretch;
}

/* =========================
   GAME CARD NORMALIZATION
========================= */
.game-card {
    display: flex;
    flex-direction: column;
    height: 100%;
}

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

/* Tablets */
@media (max-width: 768px) {
    .games-grid {
        grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
        gap: 18px;
    }

    .games-toolbar {
        flex-direction: column;
        align-items: stretch;
    }

    .games-search {
        width: 100%;
    }

    .category-filters {
        width: 100%;
    }
}

/* Mobile */
@media (max-width: 480px) {
    .games-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }
}
