@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap');

:root {
    --brand-color: #e50914;
    --bg-main: #141414;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-main);
    color: #e5e5e5;
    overflow-x: hidden;
    margin: 0;
    padding: 0;
}

/* Controle de Visibilidade por Aba */
#hero-section, #moods-row { 
    display: none !important; 
}

body[data-tab="home"] #hero-section { 
    display: block !important; 
}

body[data-tab="home"] #moods-row { 
    display: flex !important; 
}

/* Hero Carousel Professional Styles */
#brands-row {
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    scroll-behavior: smooth;
    -ms-overflow-style: none;
    scrollbar-width: none;
    padding-bottom: 10px;
}
#brands-row::-webkit-scrollbar { display: none; }

/* Canais Hub Style */
#hub-grid {
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    justify-content: flex-start;
    gap: 16px;
    padding: 10px 20px 20px 20px;
    -ms-overflow-style: none;
    scrollbar-width: none;
}
#hub-grid::-webkit-scrollbar { display: none; }

.brand-card {
    min-width: 140px; 
    height: 80px;
    flex-shrink: 0;
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

#moods-row {
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    justify-content: flex-start;
    padding: 0 20px;
    -ms-overflow-style: none;
    scrollbar-width: none;
}
#moods-row::-webkit-scrollbar { display: none; }

.brand-card:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.3);
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

.brand-card span {
    font-size: 0.9rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 1px;
    z-index: 2;
}

/* Glow Effect */
.brand-card::after {
    content: '';
    position: absolute;
    inset: 0;
    opacity: 0;
    transition: opacity 0.3s;
    background: radial-gradient(circle at center, var(--glow-color), transparent 70%);
}

.brand-card:hover::after {
    opacity: 0.2;
}

#brands-hub {
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.3s;
}

#brands-hub.hidden {
    transform: translateY(-20px);
    opacity: 0;
    display: none;
}

#brands-hub.active {
    display: block;
    opacity: 1;
    transform: translateY(0);
}

/* Top 10 Styles */
.top10-number {
    font-size: 150px;
    font-weight: 900;
    line-height: 1;
    position: absolute;
    left: -15px;
    bottom: -15px;
    color: #141414;
    -webkit-text-stroke: 2px rgba(255,255,255,0.4);
    z-index: 5;
    user-select: none;
    transition: all 0.3s ease;
}

.poster-card:hover .top10-number {
    -webkit-text-stroke: 2px var(--brand-color);
    transform: scale(1.1) translateX(-5px);
}

.top10-card {
    padding-left: 40px; /* Espaço para o número não cobrir tudo */
}

.hero-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    transition: opacity 1.2s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    align-items: center;
    visibility: hidden;
    z-index: 1;
}

.hero-slide.active {
    opacity: 1;
    visibility: visible;
    z-index: 5;
}

.hero-bg {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center 20%;
    transform: scale(1.1);
    transition: transform 10s ease-out;
}

.hero-slide.active .hero-bg {
    transform: scale(1);
}

.indicator-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgba(255,255,255,0.2);
    cursor: pointer;
    transition: all 0.4s ease;
}

.indicator-dot.active {
    background: var(--brand-color);
    width: 24px;
    border-radius: 4px;
    box-shadow: 0 0 15px rgba(229, 9, 20, 0.6);
}

.hero-text-shadow {
    text-shadow: 0 2px 15px rgba(0,0,0,0.8);
}

/* Scrollbar */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: var(--bg-main); }
::-webkit-scrollbar-thumb { background: #333; border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: #555; }

.hide-scroll { -ms-overflow-style: none; scrollbar-width: none; scroll-behavior: smooth; }
.hide-scroll::-webkit-scrollbar { display: none; }

.glass-header {
    background: #0a0a0a !important; /* Totalmente sólido para garantir bloqueio */
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    z-index: 2000 !important; /* Camada Soberana */
}

.server-btn { transition: all 0.2s ease; }
.server-btn.active { background-color: var(--brand-color); color: white; border-color: var(--brand-color); font-weight: 600; }

@keyframes spin { to { transform: rotate(360deg); } }
.loader { width: 32px; height: 32px; border: 3px solid rgba(255,255,255,0.1); border-radius: 50%; border-top-color: var(--brand-color); animation: spin 1s ease-in-out infinite; }

@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
.fade-in { animation: fadeIn 0.3s ease-in-out forwards; }

main {
    position: relative;
    z-index: 1 !important; /* Base absoluta */
}

@keyframes slideUp { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: translateY(0); } }
.slide-up { animation: slideUp 0.3s ease-out forwards; }

/* Cards de Poster */
.poster-card {
    position: relative;
    transition: transform 0.3s ease, box-shadow 0.2s ease;
    overflow: hidden;
    flex-shrink: 0;
    border-radius: 8px;
}

@media (hover: hover) {
    .poster-card:hover { 
        transform: scale(1.05); 
        z-index: 20; 
        box-shadow: 0 10px 30px rgba(0,0,0,0.9); 
    }
}

.card-info {
    opacity: 0;
    transition: opacity 0.3s ease;
}

.poster-card:hover .card-info {
    opacity: 1;
}

.ep-active { 
    border-color: var(--brand-color) !important; 
    background-color: rgba(229, 9, 20, 0.1) !important; 
}
.ep-active h4, .ep-active .ep-number { 
    color: var(--brand-color) !important; 
}

/* Loader Custom */
.skeleton {
    background: linear-gradient(90deg, #222 25%, #333 50%, #222 75%);
    background-size: 200% 100%;
    animation: skeletonLoading 1.5s infinite;
}

@keyframes skeletonLoading {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

.nav-scroll button {
    position: relative;
    padding: 8px 4px;
    color: #999;
    transition: all 0.3s ease;
}

.nav-scroll button.active { color: #fff; }

/* Indicador (Barra Vermelha Padrão) */
.nav-scroll button.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: var(--brand-color);
    border-radius: 10px;
    box-shadow: 0 0 10px var(--brand-color);
}

/* Cores Específicas */
#nav-archive.active { color: #3b82f6 !important; }
#nav-archive.active::after { background: #3b82f6 !important; box-shadow: 0 0 10px #3b82f6; }

#nav-favorites.active { color: #eab308 !important; }
#nav-favorites.active::after { background: #eab308 !important; box-shadow: 0 0 10px #eab308; }

.custom-scroll::-webkit-scrollbar {
    width: 4px;
}
.custom-scroll::-webkit-scrollbar-thumb {
    background: #333;
    border-radius: 10px;
}

/* Modo TV - Foco Visual */
.tv-focus {
    outline: none !important;
    border-color: #fff !important;
    box-shadow: 0 0 0 4px rgba(255, 255, 255, 0.4), 0 0 20px rgba(255, 255, 255, 0.6) !important;
    transform: scale(1.08) !important;
    z-index: 50 !important;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1) !important;
    background-color: rgba(255, 255, 255, 0.1) !important;
}

/* Ajuste específico para posters no Modo TV */
.poster-card.tv-focus {
    transform: scale(1.1) !important;
}

/* Esconder o foco padrão do navegador para não duplicar */
*:focus {
    outline: none !important;
}