/**
 * ==============================================
 * GAME FILTERS STYLES - ESTILOS PRINCIPAIS DOS FILTROS
 * ==============================================
 * 
 * RESPONSABILIDADE ESPECÍFICA:
 * - Estilos visuais principais da seção de filtros (.games-filters-section)
 * - Efeitos visuais de background (partículas, gradientes, brilhos)
 * - Animações e transições dos componentes de filtro
 * - Responsividade geral da seção
 * 
 * TRABALHA COM:
 * - game-filters-layout.css (complementa com layout específico)
 * - game-filters-main.php (estrutura HTML que estiliza)
 * 
 * NÃO CONTÉM:
 * - Layout específico dos componentes (isso fica no game-filters-layout.css)
 * - Lógica JavaScript (isso fica nos arquivos .js)
 * 
 * @package Nuntius Theme
 * @version 2.0.1
 * @author Nuntius Team
 * @file-responsibility Estilos visuais e animações da seção de filtros
 */

/* ===== FILTERS SECTION PRINCIPAL - COMPACTO ===== */
.games-filters-section {
    position: relative;
    width: 100vw;
    margin-left: calc(50% - 50vw);
    padding: 30px 0;
    background: 
        radial-gradient(circle at 30% 30%, rgba(88, 101, 242, 0.08) 0%, transparent 60%),
        radial-gradient(circle at 70% 70%, rgba(114, 137, 218, 0.06) 0%, transparent 60%),
        linear-gradient(180deg, #0a0a0f 0%, #16213e 50%, #0a0a0f 100%);
    overflow: hidden;
    color: #ffffff;
}

/* ===== BACKGROUND EFFECTS ===== */
.filters-bg-effects {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
}

.filters-particle-layer {
    position: absolute;
    width: 100%;
    height: 100%;
    background-image: 
        radial-gradient(circle at 20% 20%, rgba(88, 101, 242, 0.1) 0%, transparent 30%),
        radial-gradient(circle at 80% 80%, rgba(114, 137, 218, 0.08) 0%, transparent 30%);
    animation: filtersParticleFloat 20s ease-in-out infinite;
}

.filters-glow-layer {
    position: absolute;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at 50% 50%, rgba(67, 181, 129, 0.03) 0%, transparent 70%);
    animation: filtersGlowPulse 15s ease-in-out infinite;
}

/* ===== CONTAINER PRINCIPAL - FULL WIDTH ===== */
.games-filters-container {
    width: 100%;
    max-width: none;
    margin: 0;
    padding: 0 2rem;
    position: relative;
    z-index: 10;
}

/* ===== HEADER DOS FILTROS ===== */
.filters-header {
    text-align: center;
    margin-bottom: 3rem;
    opacity: 0;
    animation: fadeInUp 1s ease-out 0.2s forwards;
}

.filters-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    text-shadow: 0 0 20px rgba(88, 101, 242, 0.5);
}

.filters-title i {
    color: #5865f2;
    text-shadow: 0 0 15px rgba(88, 101, 242, 0.8);
}

.filters-subtitle {
    font-size: 1.2rem;
    color: rgba(255, 255, 255, 0.8);
    max-width: 600px;
    margin: 0 auto;
}

/* ===== CONTAINER PRINCIPAL - LAYOUT HORIZONTAL COMPACTO ===== */
.filters-main-container {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 15px;
    padding: 1.5rem;
    box-shadow: 
        0 10px 30px rgba(0, 0, 0, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

/* ===== BUSCA ÉPICA ===== */
.search-container {
    margin-bottom: 3rem;
    position: relative;
}

.search-input-wrapper {
    position: relative;
    max-width: 600px;
    margin: 0 auto;
}

.search-input {
    width: 100%;
    padding: 1.2rem 3.5rem 1.2rem 3.5rem;
    font-size: 1.1rem;
    background: rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(15px);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 50px;
    color: #ffffff;
    outline: none;
    transition: all 0.3s ease;
    box-shadow: inset 0 2px 10px rgba(0, 0, 0, 0.2);
}

.search-input::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.search-input:focus {
    border-color: #5865f2;
    box-shadow: 
        0 0 0 3px rgba(88, 101, 242, 0.2),
        inset 0 2px 10px rgba(0, 0, 0, 0.2);
    background: rgba(88, 101, 242, 0.1);
}

.search-icon {
    position: absolute;
    left: 1.5rem;
    top: 50%;
    transform: translateY(-50%);
    color: rgba(255, 255, 255, 0.6);
    font-size: 1.2rem;
    transition: color 0.3s ease;
}

.search-input:focus + .search-icon {
    color: #5865f2;
}

.search-clear {
    position: absolute;
    right: 1.5rem;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.6);
    font-size: 1rem;
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 50%;
    transition: all 0.3s ease;
}

.search-clear:hover {
    color: #ff6b6b;
    background: rgba(255, 107, 107, 0.1);
}

/* ===== SUGESTÕES DE BUSCA ===== */
.search-suggestions {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 15px;
    margin-top: 0.5rem;
    max-height: 300px;
    overflow-y: auto;
    z-index: 1000;
    display: none;
}

.suggestion-item {
    padding: 1rem 1.5rem;
    cursor: pointer;
    transition: all 0.3s ease;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    display: flex;
    align-items: center;
    gap: 1rem;
}

.suggestion-item:hover {
    background: rgba(88, 101, 242, 0.2);
}

.suggestion-item:last-child {
    border-bottom: none;
}

/* ===== CATEGORIAS DE FILTROS ===== */
.filters-categories {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.filter-group {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.filter-label {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    font-size: 1.1rem;
    font-weight: 600;
    color: #ffffff;
    text-shadow: 0 0 10px rgba(88, 101, 242, 0.3);
}

.filter-label i {
    color: #5865f2;
    font-size: 1.2rem;
}

/* ===== SELECT CUSTOMIZADO ===== */
.filter-select {
    width: 100%;
    padding: 1rem 1.5rem;
    font-size: 1rem;
    background: rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(15px);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 15px;
    color: #ffffff;
    outline: none;
    transition: all 0.3s ease;
    cursor: pointer;
}

.filter-select:focus {
    border-color: #5865f2;
    box-shadow: 0 0 0 3px rgba(88, 101, 242, 0.2);
    background: rgba(88, 101, 242, 0.1);
}

.filter-select option {
    background: #1a1a2e;
    color: #ffffff;
    padding: 0.5rem;
}

/* ===== TAGS DE FILTROS SELECIONADOS ===== */
.filter-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 0.5rem;
}

.filter-tag {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(88, 101, 242, 0.2);
    border: 1px solid rgba(88, 101, 242, 0.4);
    border-radius: 20px;
    padding: 0.3rem 1rem;
    font-size: 0.9rem;
    color: #ffffff;
    animation: tagSlideIn 0.3s ease-out;
}

.filter-tag .remove-tag {
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.8);
    cursor: pointer;
    padding: 0.2rem;
    border-radius: 50%;
    transition: all 0.2s ease;
}

.filter-tag .remove-tag:hover {
    color: #ff6b6b;
    background: rgba(255, 107, 107, 0.2);
}

/* ===== SLIDER DE RATING ===== */
.rating-slider-container {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.rating-slider {
    flex: 1;
    height: 8px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    outline: none;
    cursor: pointer;
    -webkit-appearance: none;
}

.rating-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 20px;
    height: 20px;
    background: linear-gradient(45deg, #5865f2, #7289da);
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 0 10px rgba(88, 101, 242, 0.5);
    transition: all 0.3s ease;
}

.rating-slider::-webkit-slider-thumb:hover {
    transform: scale(1.2);
    box-shadow: 0 0 15px rgba(88, 101, 242, 0.8);
}

.rating-display {
    display: flex;
    align-items: center;
    gap: 0.3rem;
    padding: 0.5rem 1rem;
    background: rgba(67, 181, 129, 0.2);
    border: 1px solid rgba(67, 181, 129, 0.4);
    border-radius: 15px;
    font-weight: 600;
    color: #43b581;
    min-width: 80px;
    justify-content: center;
}

/* ===== CONTROLES DE VISUALIZAÇÃO ===== */
.view-controls {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 2rem;
    padding: 2rem 0;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    margin-bottom: 2rem;
}

.sort-container,
.view-toggle,
.items-per-page {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.sort-label,
.view-label,
.items-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1rem;
    color: rgba(255, 255, 255, 0.8);
    white-space: nowrap;
}

.sort-select,
.items-select {
    padding: 0.8rem 1.2rem;
    background: rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    color: #ffffff;
    outline: none;
    transition: all 0.3s ease;
    cursor: pointer;
}

.sort-select:focus,
.items-select:focus {
    border-color: #5865f2;
    background: rgba(88, 101, 242, 0.1);
}

/* ===== BOTÕES DE VISUALIZAÇÃO ===== */
.view-buttons {
    display: flex;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 10px;
    padding: 0.2rem;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.view-btn {
    padding: 0.8rem 1.2rem;
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.6);
    cursor: pointer;
    border-radius: 8px;
    transition: all 0.3s ease;
    font-size: 1.1rem;
}

.view-btn.active {
    background: rgba(88, 101, 242, 0.3);
    color: #ffffff;
    box-shadow: 0 2px 10px rgba(88, 101, 242, 0.3);
}

.view-btn:hover:not(.active) {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.1);
}

/* ===== FILTROS ATIVOS ===== */
.active-filters-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 2rem;
}

.active-filters {
    display: flex;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.active-filters-label {
    color: rgba(255, 255, 255, 0.8);
    font-weight: 600;
    white-space: nowrap;
}

.active-filters-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.active-filter-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(114, 137, 218, 0.2);
    border: 1px solid rgba(114, 137, 218, 0.4);
    border-radius: 20px;
    padding: 0.3rem 1rem;
    font-size: 0.9rem;
    color: #7289da;
    animation: activeFilterSlide 0.3s ease-out;
}

.active-filter-remove {
    background: none;
    border: none;
    color: inherit;
    cursor: pointer;
    padding: 0.2rem;
    border-radius: 50%;
    transition: all 0.2s ease;
}

.active-filter-remove:hover {
    color: #ff6b6b;
    background: rgba(255, 107, 107, 0.2);
}

/* ===== BOTÃO RESET ===== */
.reset-filters-btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.8rem 1.5rem;
    background: rgba(255, 107, 107, 0.2);
    border: 1px solid rgba(255, 107, 107, 0.4);
    border-radius: 25px;
    color: #ff6b6b;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.reset-filters-btn:hover {
    background: rgba(255, 107, 107, 0.3);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(255, 107, 107, 0.3);
}

.reset-filters-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

/* ===== INFORMAÇÕES DE RESULTADOS ===== */
.results-info {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 1rem;
}

.results-count {
    color: rgba(255, 255, 255, 0.9);
    font-size: 1.1rem;
}

.results-count strong {
    color: #43b581;
    font-weight: 700;
}

/* ===== LOADING INDICATOR ===== */
.loading-indicator {
    display: flex;
    align-items: center;
    gap: 1rem;
    color: rgba(255, 255, 255, 0.8);
}

.loading-spinner {
    width: 20px;
    height: 20px;
    border: 2px solid rgba(88, 101, 242, 0.3);
    border-top: 2px solid #5865f2;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

/* ===== ANIMAÇÕES ===== */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes filtersParticleFloat {
    0%, 100% { 
        transform: translateX(0) translateY(0) rotate(0deg); 
    }
    33% { 
        transform: translateX(20px) translateY(-15px) rotate(120deg); 
    }
    66% { 
        transform: translateX(-15px) translateY(10px) rotate(240deg); 
    }
}

@keyframes filtersGlowPulse {
    0%, 100% { 
        opacity: 0.3; 
        transform: scale(1); 
    }
    50% { 
        opacity: 0.6; 
        transform: scale(1.1); 
    }
}

@keyframes tagSlideIn {
    from {
        opacity: 0;
        transform: translateX(-20px) scale(0.8);
    }
    to {
        opacity: 1;
        transform: translateX(0) scale(1);
    }
}

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

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* ===== RESPONSIVIDADE ===== */
@media (max-width: 1200px) {
    .filters-categories {
        grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    }
}

@media (max-width: 768px) {
    .games-filters-container {
        padding: 0 20px;
    }
    
    .filters-main-container {
        padding: 2rem;
    }
    
    .filters-title {
        font-size: 2rem;
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .filters-categories {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .view-controls {
        flex-direction: column;
        align-items: stretch;
        gap: 1.5rem;
    }
    
    .sort-container,
    .view-toggle,
    .items-per-page {
        justify-content: space-between;
    }
    
    .active-filters-container {
        flex-direction: column;
        align-items: stretch;
    }
    
    .active-filters {
        justify-content: center;
    }
    
    .reset-filters-btn {
        align-self: center;
    }
}

@media (max-width: 480px) {
    .filters-main-container {
        padding: 1.5rem;
    }
    
    .search-input {
        padding: 1rem 3rem 1rem 3rem;
        font-size: 1rem;
    }
    
    .filters-title {
        font-size: 1.8rem;
    }
    
    .rating-slider-container {
        flex-direction: column;
        align-items: stretch;
        gap: 0.5rem;
    }
    
    .view-buttons {
        justify-content: center;
    }
}