/* ========== ANIMECOMETA — TEMA CÓSMICO AZULADO ========== */
:root {
    --cosmic-bg: #0b0c15;
    --cosmic-bg-elevated: #151621;
    --cosmic-bg-card: #1c1d2e;
    --cosmic-border: rgba(99, 102, 241, 0.15);
    --cosmic-accent: #6366f1;
    --cosmic-accent-bright: #818cf8;
    --cosmic-cta: #4f46e5;
    --cosmic-cta-hover: #6366f1;
    --cosmic-text: #f1f5f9;
    --cosmic-text-muted: #94a3b8;
    --cosmic-glow: rgba(99, 102, 241, 0.25);
    --cosmic-blue-glow: rgba(79, 70, 229, 0.25);
    --font-main: 'Inter', system-ui, -apple-system, sans-serif;
    --font-heading: 'Outfit', 'Inter', system-ui, sans-serif;
}

/* Tema claro (override de variáveis) */
body.light-theme {
    --cosmic-bg: #f8fafc;
    --cosmic-bg-elevated: #ffffff;
    --cosmic-bg-card: #ffffff;
    --cosmic-border: rgba(226, 232, 240, 0.8);
    --cosmic-accent: #4f46e5;
    --cosmic-accent-bright: #6366f1;
    --cosmic-cta: #4f46e5;
    --cosmic-cta-hover: #4338ca;
    --cosmic-text: #0f172a;
    --cosmic-text-muted: #64748b;
    --cosmic-glow: rgba(99, 102, 241, 0.15);
}

body.light-theme {
    background-image:
        radial-gradient(ellipse 120% 80% at 50% -20%, rgba(129, 140, 248, 0.18), transparent),
        radial-gradient(ellipse 80% 50% at 80% 50%, rgba(59, 130, 246, 0.12), transparent);
}

body.light-theme .top-navbar {
    background: rgba(255, 255, 255, 0.92);
    border-bottom-color: rgba(148, 163, 184, 0.7);
    box-shadow: 0 1px 12px rgba(15, 23, 42, 0.12);
}

body.light-theme .left-sidebar {
    background: #ffffff;
    border-right-color: rgba(148, 163, 184, 0.7);
}

body.light-theme .nav-link,
body.light-theme .sidebar-footer a {
    color: var(--cosmic-text-muted);
}

body.light-theme .nav-link:hover {
    color: var(--cosmic-cta);
}

body.light-theme .result-card,
body.light-theme .anime-card,
body.light-theme .trending-item {
    box-shadow: 0 6px 18px rgba(15, 23, 42, 0.08);
    border-color: rgba(148, 163, 184, 0.7);
}

body.light-theme .cookie-banner {
    background: rgba(248, 250, 252, 0.98);
    border-color: rgba(148, 163, 184, 0.7);
    color: #0f172a;
}

body.light-theme .spotlight-section {
    background: linear-gradient(135deg, #ffffff 0%, #eef2ff 40%, #e0f2fe 100%);
}

body.light-theme .result-title,
body.light-theme .anime-card-title,
body.light-theme .section-title,
body.light-theme .spotlight-title {
    color: #020617;
}

body.light-theme .spotlight-description,
body.light-theme .result-meta,
body.light-theme .duration,
body.light-theme .release-date {
    color: #475569;
}

body.light-theme .badge,
body.light-theme .badge-type,
body.light-theme .badge-rating,
body.light-theme .type-badge,
body.light-theme .quality-badge {
    box-shadow: 0 0 0 1px rgba(148, 163, 184, 0.4);
}

body.light-theme .cookie-btn.primary {
    box-shadow: 0 10px 26px rgba(99, 102, 241, 0.35);
}

body.light-theme .top-navbar {
    background: rgba(255, 255, 255, 0.92);
    border-bottom-color: rgba(148, 163, 184, 0.7);
    box-shadow: 0 1px 12px rgba(15, 23, 42, 0.12);
}

body.light-theme .left-sidebar {
    background: #ffffff;
    border-right-color: rgba(148, 163, 184, 0.7);
}

body.light-theme .nav-link,
body.light-theme .sidebar-footer a {
    color: var(--cosmic-text-muted);
}

body.light-theme .nav-link:hover {
    color: var(--cosmic-cta);
}

body.light-theme .result-card,
body.light-theme .anime-card,
body.light-theme .trending-item {
    box-shadow: 0 4px 16px rgba(15, 23, 42, 0.08);
}

body.light-theme .cookie-banner {
    background: rgba(248, 250, 252, 0.98);
    border-color: rgba(148, 163, 184, 0.7);
    color: #0f172a;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* ANIMAÇÕES CÓSMICAS */
@keyframes twinkle {
    0%, 100% { opacity: 0.3; }
    50% { opacity: 1; }
}

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

@keyframes glow {
    0%, 100% { text-shadow: 0 0 5px rgba(99, 102, 241, 0.3); }
    50% { text-shadow: 0 0 10px rgba(99, 102, 241, 0.5); }
}

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

@keyframes pulse {
    0%, 100% { box-shadow: 0 0 10px rgba(99, 102, 241, 0.2); }
    50% { box-shadow: 0 0 20px rgba(99, 102, 241, 0.3); }
}

@keyframes slideInLeft {
    from { opacity: 0; transform: translateX(-50px); }
    to { opacity: 1; transform: translateX(0); }
}

@keyframes slideInRight {
    from { opacity: 0; transform: translateX(50px); }
    to { opacity: 1; transform: translateX(0); }
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

@keyframes dots {
    0%, 20% { content: ''; }
    40% { content: '.'; }
    60% { content: '..'; }
    80%, 100% { content: '...'; }
}

@keyframes shimmer {
    0% { background-position: -1000px 0; }
    100% { background-position: 1000px 0; }
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: radial-gradient(ellipse at 50% 0%, #001a33 0%, #000d1a 50%, #000511 100%);
    min-height: 100vh;
    padding: 0;
    position: relative;
    overflow-x: hidden;
    color: #f0f0f0;
}

body {
    font-family: var(--font-main);
    background: var(--cosmic-bg);
    background-image: 
        radial-gradient(circle at 15% 50%, rgba(99, 102, 241, 0.08), transparent 25%),
        radial-gradient(circle at 85% 30%, rgba(139, 92, 246, 0.08), transparent 25%);
    color: var(--cosmic-text);
    margin: 0;
    padding: 0;
    line-height: 1.6;
    min-height: 100vh;
    position: relative;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, h4, h5, h6, .logo-text, .section-title, .navbar-brand {
    font-family: var(--font-heading);
    letter-spacing: -0.02em;
}

/* PARTÍCULAS ANIMADAS NO BACKGROUND */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    pointer-events: none;
    background-image: 
        radial-gradient(2px 2px at 20% 30%, rgba(99, 102, 241, 0.4), transparent),
        radial-gradient(2px 2px at 60% 70%, rgba(129, 140, 248, 0.3), transparent),
        radial-gradient(1px 1px at 50% 50%, rgba(139, 92, 246, 0.5), transparent),
        radial-gradient(1px 1px at 80% 10%, rgba(99, 102, 241, 0.3), transparent),
        radial-gradient(2px 2px at 30% 80%, rgba(129, 140, 248, 0.4), transparent),
        radial-gradient(1px 1px at 90% 40%, rgba(99, 102, 241, 0.3), transparent),
        radial-gradient(2px 2px at 10% 60%, rgba(139, 92, 246, 0.4), transparent);
    background-size: 200% 200%;
    background-position: 0% 0%;
    animation: particleMove 20s linear infinite;
    opacity: 0.6;
}

/* Acessibilidade + performance */
@media (max-width: 768px) {
    /* Reduzir animações em mobile */
    * {
        transition-duration: 0.2s !important;
    }
}

/* Otimizar para modo de economia de energia */
@media (prefers-reduced-motion: reduce) {
    * {
        animation: none !important;
        transition: none !important;
    }
    
    html {
        scroll-behavior: auto !important;
    }
}

/* Otimizar scrolling - passive listeners sugeridos no DevTools */
.trending-carousel,
.carousel-track,
.left-sidebar,
.episodes-list {
    scroll-behavior: smooth;
    scrollbar-gutter: stable;
}

@media (max-width: 768px) {
    .trending-carousel,
    .carousel-track,
    .episodes-list {
        scroll-behavior: auto;
    }
}

/* Poupar GPU/CPU no mobile: menos blur */
@media (max-width: 1024px) {
    .top-navbar {
        backdrop-filter: none !important;
    }
    .sidebar-overlay {
        backdrop-filter: none !important;
    }
    .sidebar-header {
        backdrop-filter: none !important;
    }
    .spotlight-arrow,
    .spotlight-dots {
        backdrop-filter: none !important;
    }
}

/* Mobile: performance otimizado */
@media (max-width: 768px) {
    body::before {
        animation: none !important;
        opacity: 0.2 !important;
    }
    
    /* Reduzir box shadows em mobile */
    * {
        box-shadow: none !important;
    }
    
    /* Apenas element essenciais com box-shadow simplificado */
    .anime-card,
    .trending-item,
    .result-card {
        box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2) !important;
    }
    
    .trending-item,
    .anime-card,
    .result-card {
        transition: transform 0.2s ease, box-shadow 0.2s ease;
    }
    
    .spotlight-arrow {
        backdrop-filter: none !important;
        box-shadow: none;
    }
    
    .spotlight-dots {
        backdrop-filter: none !important;
        box-shadow: none;
    }
}

@keyframes particleMove {
    0% { background-position: 0% 0%, 100% 100%, 50% 50%, 0% 100%, 100% 0%, 50% 0%, 0% 50%; }
    100% { background-position: 100% 100%, 0% 0%, 50% 50%, 100% 0%, 0% 100%, 50% 100%, 100% 50%; }
}

/* Desabilitar animações em mobile para melhor performance */
@media (max-width: 768px) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    @keyframes glow {
        0%, 100% { text-shadow: none; }
        50% { text-shadow: none; }
    }
    
    @keyframes float {
        0%, 100% { transform: translateY(0px); }
        50% { transform: translateY(0px); }
    }
    
    /* Reduzir elementos pesados em mobile */
    #particles-container {
        display: none !important;
    }
    
    /* Will-change apenas para elementos críticos */
    .trending-item,
    .anime-card,
    .result-card {
        will-change: transform;
    }
    
    /* Melhorar performance de scroll */
    .trending-carousel,
    .anime-grid,
    .results-grid {
        -webkit-overflow-scrolling: touch;
    }
}

/* Container para partículas adicionais */
#particles-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    pointer-events: none;
    overflow: hidden;
}

.particle {
    position: absolute;
    width: 3px;
    height: 3px;
    background: rgba(99, 102, 241, 0.6);
    border-radius: 50%;
    animation: floatParticle 15s infinite ease-in-out;
}

.particle:nth-child(2n) {
    width: 2px;
    height: 2px;
    background: rgba(129, 140, 248, 0.5);
    animation-duration: 20s;
}

.particle:nth-child(3n) {
    width: 4px;
    height: 4px;
    background: rgba(139, 92, 246, 0.4);
    animation-duration: 25s;
}

@keyframes floatParticle {
    0%, 100% {
        transform: translate(0, 0) scale(1);
        opacity: 0.3;
    }
    25% {
        transform: translate(100px, -100px) scale(1.2);
        opacity: 0.6;
    }
    50% {
        transform: translate(-50px, -200px) scale(0.8);
        opacity: 0.4;
    }
    75% {
        transform: translate(-100px, -50px) scale(1.1);
        opacity: 0.5;
    }
}

/* Smooth scroll */
html {
    scroll-behavior: smooth;
}

/* Settings Menu Styles */
.settings-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    background: var(--cosmic-bg-card);
    border: 1px solid var(--cosmic-border);
    border-radius: 8px;
    padding: 10px;
    min-width: 200px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    z-index: 1000;
}

.settings-menu.active {
    display: block;
}

.settings-header {
    font-weight: bold;
    margin-bottom: 8px;
    color: var(--cosmic-text);
    font-size: 0.9em;
}

.settings-option {
    padding: 8px 12px;
    margin: 4px 0;
    background: var(--cosmic-bg-elevated);
    border: 1px solid var(--cosmic-border);
    border-radius: 4px;
    color: var(--cosmic-text);
    cursor: pointer;
    transition: all 0.2s ease;
}

.settings-option:hover {
    background: var(--cosmic-accent);
    color: white;
}

.settings-option.active {
    background: var(--cosmic-accent);
    color: white;
}

/* MOBILE MENU BUTTON */
.mobile-menu-btn {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 8px;
    z-index: 1001;
}

.mobile-menu-btn span {
    width: 25px;
    height: 3px;
    background: #fff;
    border-radius: 3px;
    transition: all 0.3s;
}

.mobile-menu-btn:hover span {
    background: var(--cosmic-accent);
}

@media (max-width: 1024px) {
    .mobile-menu-btn {
        display: flex;
    }
}

.top-navbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: rgba(11, 12, 21, 0.7);
    border-bottom: 1px solid var(--cosmic-border);
    padding: 1rem 1.5rem;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    transition: all 0.3s ease;
}

.left-sidebar {
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    width: 260px;
    background: rgba(11, 12, 21, 0.95);
    border-right: 1px solid var(--cosmic-border);
    z-index: 1002;
    transform: translateX(-100%);
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    overflow-y: auto;
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    backdrop-filter: blur(20px);
}

@media (min-width: 1025px) {
    .left-sidebar {
        transform: translateX(0);
        background: transparent;
        border-right: 1px solid var(--cosmic-border);
    }
    .top-navbar {
        left: 260px;
        width: calc(100% - 260px);
        background: rgba(11, 12, 21, 0.6);
    }
}

.navbar-brand {
    text-decoration: none;
    font-size: 1.6rem;
    font-weight: 800;
    letter-spacing: -0.5px;
    display: flex;
    align-items: center;
}

@media (max-width: 768px) {
    .navbar-brand {
        font-size: 1.35rem;
    }
}

@media (max-width: 480px) {
    .navbar-brand {
        font-size: 1.15rem;
    }
}
.navbar-brand .logo-text {
    color: #fff;
}
.navbar-brand .logo-accent {
    color: var(--cosmic-accent-bright);
}
.navbar-brand:hover .logo-accent {
    color: var(--cosmic-cta);
    text-decoration: none;
}

/* Logo em modo claro: "Anime" preto para melhor contraste */
body.light-theme .navbar-brand .logo-text {
    color: #020617;
}

.navbar-center {
    flex: 1;
    display: flex;
    justify-content: center;
    max-width: 700px;
    margin: 0 30px;
}

.navbar-right {
    margin-left: auto;
}

.theme-toggle-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 1px solid var(--cosmic-border);
    background: rgba(15, 14, 26, 0.4);
    color: var(--cosmic-text-muted);
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    padding: 0;
    backdrop-filter: blur(4px);
    position: relative;
    overflow: hidden;
}

.theme-toggle-btn:hover {
    background: rgba(99, 102, 241, 0.15);
    border-color: var(--cosmic-accent);
    color: var(--cosmic-accent-bright);
    box-shadow: 0 0 16px var(--cosmic-glow);
    transform: rotate(15deg) scale(1.05);
}

.theme-toggle-btn span {
    font-size: 1rem;
    line-height: 1;
}

/* HOME SECTION */
.home-section {
    display: block;
}
.home-hero {
    text-align: center;
    padding: 12px 0 24px;
}
.hero-tagline {
    color: var(--cosmic-text-muted);
    font-size: 1.05rem;
    margin: 0;
    font-weight: 500;
}

@media (max-width: 768px) {
    .hero-tagline {
        font-size: 0.95rem;
    }
}

@media (max-width: 480px) {
    .hero-tagline {
        font-size: 0.85rem;
    }
}
.spotlight-placeholder {
    min-height: 320px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--cosmic-bg-card);
    border-radius: 12px;
    color: var(--cosmic-text-muted);
    border: 1px solid var(--cosmic-border);
}
.trending-skeleton,
.grid-skeleton {
    padding: 40px 20px;
    text-align: center;
    color: var(--cosmic-text-muted);
}
.sidebar-footer .footer-note {
    font-size: 0.75rem;
    color: var(--cosmic-text-muted);
    margin-bottom: 8px;
    opacity: 0.8;
}

.sidebar-footer .legal-links {
    display: flex;
    align-items: center;
    gap: 0.3rem;
    font-size: 0.75rem;
    margin-top: 4px;
}

.content-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 1rem;
}
.content-header .section-title {
    margin-bottom: 0;
}
.filter-controls {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    align-items: center;
}

.filter-group {
    display: flex;
    gap: 8px;
    align-items: center;
}

.filter-group label {
    color: var(--cosmic-text-muted);
    font-weight: 600;
    font-size: 0.9em;
    white-space: nowrap;
}

.filter-select {
    padding: 10px 14px;
    background: var(--cosmic-bg-card);
    border: 1px solid var(--cosmic-border);
    border-radius: 8px;
    color: var(--cosmic-text);
    font-size: 0.9em;
    cursor: pointer;
    transition: all 0.3s;
    min-width: 120px;
}

.filter-select:hover, .filter-select:focus {
    border-color: var(--cosmic-accent);
    outline: none;
    box-shadow: 0 0 10px var(--cosmic-glow);
}

.reset-filters-btn {
    padding: 10px 16px;
    background: transparent;
    border: 1px solid var(--cosmic-border);
    border-radius: 8px;
    color: var(--cosmic-text);
    cursor: pointer;
    transition: all 0.3s;
    font-weight: 600;
    font-size: 0.9em;
    white-space: nowrap;
}

.reset-filters-btn:hover {
    background: rgba(99, 102, 241, 0.2);
    border-color: var(--cosmic-accent);
    color: var(--cosmic-accent-bright);
}

@media (max-width: 768px) {
    .filter-controls {
        gap: 8px;
    }
    
    .filter-select {
        min-width: 100px;
        font-size: 0.85em;
        padding: 8px 12px;
    }
    
    .filter-group label {
        display: none;
    }
    
    .reset-filters-btn {
        padding: 8px 12px;
        font-size: 0.85em;
    }
}

/* TRENDING SECTION */
.trending-section {
    margin-bottom: 30px;
}

/* Renderização mais rápida em listas longas */
.trending-section,
.new-hianime-section,
.results-grid {
    content-visibility: auto;
    contain-intrinsic-size: 480px;
}

.anime-card,
.trending-item,
.result-card {
    contain: layout style paint;
}

@media (max-width: 768px) {
    /* Desabilitar contain no mobile para melhor performance */
    .anime-card,
    .trending-item,
    .result-card {
        contain: unset;
    }
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.section-title {
    font-size: 1.75rem;
    font-weight: 800;
    color: var(--cosmic-text);
    letter-spacing: -0.5px;
}

@media (max-width: 768px) {
    .section-title {
        font-size: 1.45rem;
    }
}

@media (max-width: 480px) {
    .section-title {
        font-size: 1.25rem;
    }
}

.view-all-link, .view-all-link a {
    color: var(--cosmic-accent-bright);
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s;
    font-size: 0.95em;
}

.view-all-link a:hover {
    color: var(--cosmic-cta);
    transform: translateX(4px);
}

/* CARROSSEL HORIZONTAL — Em exibição */
.carousel-wrap {
    position: relative;
    margin: 0 -12px;
}
.carousel-track {
    display: flex;
    gap: 20px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    padding: 12px 0 24px;
    scrollbar-width: thin;
    scrollbar-color: var(--cosmic-border) transparent;
}
.carousel-track::-webkit-scrollbar {
    height: 6px;
}
.carousel-track::-webkit-scrollbar-thumb {
    background: var(--cosmic-border);
    border-radius: 3px;
}
.carousel-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: rgba(28, 29, 46, 0.95);
    border: 1px solid var(--cosmic-border);
    color: var(--cosmic-text);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    z-index: 2;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 16px rgba(0,0,0,0.4);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

/* Posicionamento Desktop (1024px+) */
.carousel-arrow.prev { left: 10px; }
.carousel-arrow.next { right: 10px; }

/* Tablet (768px - 1023px) */
@media (max-width: 1023px) {
    .carousel-arrow {
        width: 56px;
        height: 56px;
        font-size: 1.5rem;
        background: rgba(28, 29, 46, 0.98);
        backdrop-filter: none;
    }
    .carousel-arrow.prev { left: 5px; }
    .carousel-arrow.next { right: 5px; }
}

/* Mobile (até 767px) */
@media (max-width: 767px) {
    .carousel-arrow {
        width: 48px;
        height: 48px;
        font-size: 1.3rem;
    }
    .carousel-arrow.prev { left: 0px; }
    .carousel-arrow.next { right: 0px; }
}

.carousel-arrow:hover {
    background: var(--cosmic-accent);
    border-color: var(--cosmic-accent-bright);
    color: #fff;
    transform: translateY(-50%) scale(1.1);
    box-shadow: 0 0 20px var(--cosmic-glow);
}

.trending-carousel {
    display: flex;
    gap: 24px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    padding: 20px 4px 40px;
    scrollbar-width: none;
    mask-image: linear-gradient(to right, transparent, black 2%, black 98%, transparent);
    -webkit-mask-image: linear-gradient(to right, transparent, black 2%, black 98%, transparent);
}
.trending-carousel::-webkit-scrollbar {
    display: none;
}

.trending-item {
    flex: 0 0 220px;
    scroll-snap-align: start;
    background: var(--cosmic-bg-card);
    border: 1px solid var(--cosmic-border);
    border-radius: 16px;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    cursor: pointer;
    position: relative;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
}

@media (max-width: 768px) {
    .trending-item {
        flex: 0 0 140px;
    }
}

@media (max-width: 480px) {
    .trending-item {
        flex: 0 0 130px;
    }
    
    /* Desabilitar scale em mobile para melhor performance */
    .trending-item:hover {
        transform: translateY(-4px);
        box-shadow: 0 8px 20px var(--cosmic-glow);
    }
}

.trending-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(180deg, transparent 40%, rgba(15, 14, 26, 0.9) 100%);
    opacity: 0;
    transition: opacity 0.3s;
    z-index: 1;
}

.trending-item:hover {
    transform: translateY(-6px) scale(1.02);
    box-shadow: 0 12px 32px var(--cosmic-glow);
    border-color: var(--cosmic-accent);
}

.trending-item:hover::before {
    opacity: 1;
}

.trending-img {
    width: 100%;
    height: 280px;
    object-fit: cover;
    transition: transform 0.3s;
    position: relative;
    z-index: 0;
}

@media (max-width: 768px) {
    .trending-img {
        height: 200px;
    }
}

@media (max-width: 480px) {
    .trending-img {
        height: 180px;
    }
}

.trending-item:hover .trending-img {
    transform: scale(1.05);
}

.trending-info {
    padding: 12px;
    position: relative;
    z-index: 2;
    background: var(--cosmic-bg-card);
}

.trending-info h3 {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--cosmic-text);
    margin-bottom: 8px;
    line-height: 1.35;
    transition: color 0.3s;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.trending-item:hover .trending-info h3 {
    color: var(--cosmic-accent-bright);
}

.trending-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.episode-info {
    color: var(--cosmic-text-muted);
    font-size: 0.8rem;
    font-weight: 500;
}

.rating {
    color: #fbbf24;
    font-size: 0.8rem;
    font-weight: 600;
}

/* NEW ON HIANIME SECTION — carrossel horizontal */
.new-hianime-section {
    margin-bottom: 40px;
}
.new-hianime-section .anime-grid {
    display: flex;
    gap: 20px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    padding: 12px 0 24px;
    scrollbar-width: thin;
    scrollbar-color: var(--cosmic-border) transparent;
}
.new-hianime-section .anime-grid::-webkit-scrollbar {
    height: 6px;
}
.new-hianime-section .anime-card,
.new-hianime-section .result-card {
    flex: 0 0 160px;
    scroll-snap-align: start;
}
.new-hianime-section .anime-card img,
.new-hianime-section .result-card .result-image {
    height: 220px;
}

.anime-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 20px;
}

@media (max-width: 768px) {
    .anime-grid {
        grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
        gap: 12px;
    }
}

@media (max-width: 480px) {
    .anime-grid {
        grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
        gap: 10px;
    }
}

.anime-card {
    background: var(--cosmic-bg-card);
    border: 1px solid var(--cosmic-border);
    border-radius: 16px;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    cursor: pointer;
    position: relative;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.anime-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(180deg, transparent 40%, rgba(15, 14, 26, 0.9) 100%);
    opacity: 0;
    transition: opacity 0.3s;
    z-index: 1;
}

.anime-card:hover {
    transform: translateY(-6px) scale(1.02);
    box-shadow: 0 12px 32px var(--cosmic-glow);
    border-color: var(--cosmic-accent);
}

.anime-card:hover::before {
    opacity: 1;
}

.anime-card img {
    width: 100%;
    height: 260px;
    object-fit: cover;
    transition: transform 0.3s;
    position: relative;
    z-index: 0;
}

@media (max-width: 768px) {
    .anime-card img {
        height: 200px;
    }
}

@media (max-width: 480px) {
    .anime-card img {
        height: 180px;
    }
    
    /* Desabilitar scale em mobile para melhor performance */
    .anime-card:hover img {
        transform: none;
    }
    
    .anime-card:hover {
        transform: translateY(-4px);
        box-shadow: 0 8px 20px var(--cosmic-glow);
    }
}

.anime-card:hover img {
    transform: scale(1.05);
}

.anime-card-info {
    padding: 16px;
    position: relative;
    z-index: 2;
    background: var(--cosmic-bg-card);
}

.anime-card-title {
    font-size: 1rem;
    font-weight: 700;
    color: #fff;
    margin-bottom: 10px;
    line-height: 1.4;
    transition: color 0.3s;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
}

.anime-card:hover .anime-card-title {
    color: var(--cosmic-accent-bright);
}

.anime-card-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: #999;
    font-size: 0.85rem;
    font-weight: 500;
}

/* RESPONSIVE DESIGN */
@media (max-width: 1024px) {
    .top-navbar {
        left: 0;
    }
    
    .left-sidebar {
        transform: translateX(-100%);
        box-shadow: 2px 0 20px rgba(0, 0, 0, 0.5);
    }
    
    .left-sidebar.active {
        transform: translateX(0);
    }
    
    .main-wrapper {
        padding-left: 30px;
        padding-right: 30px;
        padding-left: 30px !important;
    }
    
    .sidebar-header {
        width: 280px;
    }
    
    .spotlight-content {
        grid-template-columns: 1fr;
        gap: 30px;
    }
    
    .spotlight-image {
        order: -1;
    }
    
    .spotlight-title {
        font-size: 2rem;
    }
    
    .top-navbar {
        padding: 12px 20px;
    }
}

@media (max-width: 768px) {
    .carousel-arrow {
        width: 36px;
        height: 36px;
        font-size: 1rem;
    }
    .carousel-arrow.prev { left: 4px; }
    .carousel-arrow.next { right: 4px; }
    .trending-item {
        flex: 0 0 140px;
    }
    .trending-img {
        height: 200px;
    }
    .anime-grid {
        grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
        gap: 15px;
    }
    .anime-card img,
    .result-image {
        height: 200px;
    }
    .new-hianime-section .anime-card,
    .new-hianime-section .result-card {
        flex: 0 0 140px;
    }
    .new-hianime-section .anime-card img,
    .new-hianime-section .result-card .result-image {
        height: 200px;
    }
    .top-navbar {
        padding: 12px 15px;
        flex-wrap: wrap;
    }
    
    .navbar-brand h1 {
        font-size: 1.5rem;
    }
    
    .navbar-center {
        order: 3;
        width: 100%;
        flex-basis: 100%;
        margin: 10px 0 0 0;
        max-width: 100%;
    }
    
    .navbar-search {
        width: 100%;
        max-width: 100%;
    }
    
    .navbar-right {
        gap: 8px;
        flex-basis: auto;
        margin-left: auto;
        order: 2;
    }
    
    .nav-link {
        display: none;
    }
    
    .social-icons {
        display: none;
    }
    
    .join-now-btn, .login-btn {
        padding: 8px 16px;
        font-size: 0.85em;
        white-space: nowrap;
    }
    
    .trending-item {
        flex: 0 0 160px;
    }
    .trending-img {
        height: 240px;
    }
    
    .anime-grid {
        grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
        gap: 18px;
    }
    .anime-card img,
    .result-image {
        height: 230px;
    }
    
    .spotlight-section {
        padding: 25px;
    }
    
    .spotlight-title {
        font-size: 1.75rem;
    }
    
    .main-wrapper {
        padding: 20px 15px;
    }
    
    .results-grid {
        grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
        gap: 15px;
    }
}

.navbar-right {
    display: flex;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
}

.join-now-btn {
    background: linear-gradient(135deg, var(--cosmic-accent) 0%, #4f46e5 100%);
    color: white;
    border: none;
    padding: 10px 24px;
    border-radius: 999px;
    cursor: pointer;
    font-weight: 600;
    font-size: 0.95em;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 12px var(--cosmic-glow);
    position: relative;
    overflow: hidden;
}

.join-now-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(to bottom, rgba(255, 255, 255, 0.1), transparent);
    opacity: 0;
    transition: opacity 0.3s;
}

.join-now-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px var(--cosmic-glow);
}

.join-now-btn:hover::before {
    opacity: 1;
}

.social-icons {
    display: flex;
    gap: 10px;
}

.social-icon {
    color: #666;
    text-decoration: none;
    font-size: 1.2rem;
    transition: all 0.3s;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
}

.social-icon:hover {
    color: var(--cosmic-accent-bright);
    background: rgba(59, 130, 246, 0.1);
}

.nav-link {
    color: var(--cosmic-text-muted);
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 500;
    transition: all 0.3s ease;
    white-space: nowrap;
    position: relative;
    padding: 6px 0;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--cosmic-accent), var(--cosmic-accent-bright));
    transition: width 0.3s ease;
    border-radius: 2px;
}

.nav-link:hover {
    color: var(--cosmic-text);
}

.nav-link:hover::after {
    width: 100%;
}

.login-btn {
    background: rgba(79, 70, 229, 0.15);
    color: var(--cosmic-accent-bright);
    border: 1px solid rgba(99, 102, 241, 0.3);
    padding: 10px 24px;
    border-radius: 999px;
    cursor: pointer;
    font-weight: 600;
    font-size: 0.95em;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: none;
    backdrop-filter: blur(4px);
}

.login-btn:hover {
    background: var(--cosmic-cta);
    color: white;
    border-color: var(--cosmic-cta);
    transform: translateY(-2px);
    box-shadow: 0 4px 20px var(--cosmic-blue-glow);
}

/* SIDEBAR OVERLAY */
.sidebar-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    z-index: 998;
    backdrop-filter: blur(2px);
}

.sidebar-overlay.active {
    display: block;
}

@media (max-width: 1024px) {
    .sidebar-overlay.active {
        display: block;
    }
}

/* LEFT SIDEBAR HI!ANIME STYLE */
.left-sidebar {
    width: 280px;
    background: var(--cosmic-bg-elevated);
    border-right: 1px solid rgba(59, 130, 246, 0.1);
    height: 100vh;
    overflow-y: auto;
    position: fixed;
    left: 0;
    top: 0;
    z-index: 1100;
    transition: transform 0.3s ease;
    padding-top: 0;
    transform: translateX(-100%);
}

/* Desktop - Sidebar sempre visível quando não tem overlay */
@media (min-width: 1025px) {
    .left-sidebar {
        transform: translateX(0) !important;
        position: static;
        height: calc(100vh - 70px);
        border-left: 1px solid var(--cosmic-border);
    }
}

.left-sidebar::-webkit-scrollbar {
    width: 6px;
}

.left-sidebar::-webkit-scrollbar-track {
    background: var(--cosmic-bg-elevated);
}

.left-sidebar::-webkit-scrollbar-thumb {
    background: #333;
    border-radius: 3px;
}

.left-sidebar::-webkit-scrollbar-thumb:hover {
    background: #444;
}

.sidebar-header {
    padding: 15px 20px;
    border-bottom: 1px solid var(--cosmic-border);
    position: fixed;
    top: 0;
    left: 0;
    width: 280px;
    background: var(--cosmic-bg-elevated);
    z-index: 1001;
    border-right: 1px solid var(--cosmic-border);
    backdrop-filter: blur(10px);
}

/* Em desktop, header do sidebar é relativo */
@media (min-width: 1025px) {
    .sidebar-header {
        position: relative;
        top: auto;
        left: auto;
        width: 100%;
        border-right: none;
        border-bottom: 1px solid var(--cosmic-border);
    }
}

.close-menu {
    background: rgba(15, 14, 26, 0.4);
    border: 1px solid var(--cosmic-border);
    color: var(--cosmic-text-muted);
    padding: 12px 16px;
    border-radius: 12px;
    cursor: pointer;
    font-size: 0.95rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    width: 100%;
    text-align: left;
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 500;
    z-index: 1001;
    position: relative;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

/* Permitir fechar menu em desktop */
@media (min-width: 1025px) {
    /* Estado fechado do desktop */
    body.sidebar-closed .left-sidebar {
        width: 0 !important;
        padding: 0 !important;
        overflow: hidden;
        border: none !important;
        transform: translateX(-100%);
    }

    body.sidebar-closed .main-wrapper {
        padding-left: 30px !important;
        max-width: 100% !important;
    }

    body.sidebar-closed .top-navbar {
        left: 0 !important;
        width: 100% !important;
    }
    
    /* Mostrar botão de menu quando sidebar fechada */
    body.sidebar-closed .mobile-menu-btn {
        display: flex !important;
        margin-right: 15px;
    }
    
    /* Mostrar botão de fechar dentro do sidebar em desktop */
    .close-menu {
        display: flex;
    }
}

.close-menu:hover {
    background: rgba(99, 102, 241, 0.15);
    border-color: var(--cosmic-accent);
    color: var(--cosmic-accent-bright);
    transform: translateX(2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.sidebar-content {
    padding: 20px;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    padding-top: 90px;
}

.discussion-stats {
    display: flex;
    gap: 16px;
    margin-top: 16px;
    padding-top: 12px;
    border-top: 1px solid rgba(139, 92, 246, 0.2);
}

.stat-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    border: none;
    background: rgba(139, 92, 246, 0.1);
    border-radius: 20px;
    color: var(--text-secondary);
    font-size: 13px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.stat-btn:hover {
    background: rgba(139, 92, 246, 0.2);
    color: var(--text-primary);
}

.stat-btn.liked {
    background: rgba(236, 72, 153, 0.2);
    color: #ec4899;
}

.stat-btn.liked svg {
    fill: #ec4899;
}

.like-btn svg {
    transition: transform 0.2s ease;
}

.like-btn:hover svg {
    transform: scale(1.1);
}

/* Discussion Detail Modal */
.discussion-detail-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.discussion-detail-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(4px);
}

.discussion-detail-card {
    position: relative;
    background: var(--cosmic-card-bg);
    border: 1px solid rgba(139, 92, 246, 0.3);
    border-radius: 16px;
    width: 100%;
    max-width: 600px;
    max-height: 80vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
}

.discussion-detail-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 24px;
    border-bottom: 1px solid rgba(139, 92, 246, 0.2);
}

.discussion-detail-header h3 {
    margin: 0;
    font-size: 18px;
    color: var(--text-primary);
    padding-right: 20px;
}

.detail-close {
    background: none;
    border: none;
    font-size: 28px;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    transition: all 0.2s ease;
}

.detail-close:hover {
    background: rgba(239, 68, 68, 0.2);
    color: #ef4444;
}

.discussion-detail-body {
    flex: 1;
    overflow-y: auto;
    padding: 20px 24px;
}

.original-post {
    padding: 16px;
    background: rgba(139, 92, 246, 0.1);
    border-radius: 12px;
    margin-bottom: 20px;
}

.post-meta {
    display: flex;
    gap: 12px;
    margin-bottom: 8px;
    font-size: 13px;
}

.post-author {
    color: var(--accent-primary);
    font-weight: 500;
}

.post-time {
    color: var(--text-tertiary);
}

.post-text {
    margin: 0;
    color: var(--text-primary);
    line-height: 1.5;
}

.replies-section {
    margin-bottom: 20px;
}

.replies-section h4 {
    margin: 0 0 12px 0;
    font-size: 14px;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.discussion-reply {
    display: flex;
    gap: 12px;
    padding: 12px;
    margin-bottom: 8px;
    background: rgba(139, 92, 246, 0.05);
    border-radius: 10px;
}

.reply-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    overflow: hidden;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
    color: white;
    font-weight: 600;
    font-size: 14px;
}

.reply-avatar-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.reply-content {
    flex: 1;
}

.reply-header {
    display: flex;
    gap: 8px;
    margin-bottom: 4px;
    align-items: center;
}

.reply-author {
    font-size: 13px;
    font-weight: 600;
    color: var(--accent-primary);
}

.reply-time {
    font-size: 12px;
    color: var(--text-tertiary);
}

.reply-text {
    margin: 0;
    font-size: 14px;
    color: var(--text-primary);
    line-height: 1.4;
}

.no-replies {
    color: var(--text-secondary);
    font-style: italic;
    text-align: center;
    padding: 20px;
}

.reply-input-section {
    padding-top: 16px;
    border-top: 1px solid rgba(139, 92, 246, 0.2);
}

.reply-textarea {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid rgba(139, 92, 246, 0.3);
    border-radius: 10px;
    background: rgba(139, 92, 246, 0.05);
    color: var(--text-primary);
    font-size: 14px;
    resize: vertical;
    min-height: 80px;
    font-family: inherit;
    margin-bottom: 12px;
}

.reply-textarea:focus {
    outline: none;
    border-color: var(--accent-primary);
    background: rgba(139, 92, 246, 0.1);
}

.reply-textarea::placeholder {
    color: var(--text-tertiary);
}

.reply-submit-btn {
    padding: 10px 24px;
    background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
    border: none;
    border-radius: 8px;
    color: white;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    float: right;
}

.reply-submit-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(139, 92, 246, 0.4);
}

/* Mobile responsive for discussion modal */
@media (max-width: 768px) {
    .discussion-detail-card {
        max-width: 100%;
        max-height: 90vh;
        border-radius: 12px;
    }
    
    .discussion-detail-header {
        padding: 16px 20px;
    }
    
    .discussion-detail-body {
        padding: 16px 20px;
    }
}

/* ===================== CHAT PANEL (Full Width Tab) ===================== */

.chat-panel-container {
    display: flex;
    flex-direction: column;
    height: calc(100vh - 300px);
    min-height: 500px;
    background: var(--cosmic-card-bg);
    border: 1px solid rgba(139, 92, 246, 0.2);
    border-radius: 16px;
    overflow: hidden;
}

.chat-panel-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 24px;
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.15), rgba(236, 72, 153, 0.1));
    border-bottom: 1px solid rgba(139, 92, 246, 0.2);
}

.chat-panel-title {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 18px;
    font-weight: 600;
    color: var(--text-primary);
}

.chat-panel-title .icon {
    width: 24px;
    height: 24px;
    color: var(--accent-primary);
}

.chat-online-indicator {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 14px;
    background: rgba(34, 197, 94, 0.15);
    border-radius: 20px;
    font-size: 13px;
    color: #22c55e;
}

.online-dot {
    width: 8px;
    height: 8px;
    background: #22c55e;
    border-radius: 50%;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.chat-messages-panel {
    flex: 1;
    overflow-y: auto;
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.chat-welcome-panel {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    text-align: center;
    color: var(--text-secondary);
}

.chat-welcome-panel .large-icon {
    width: 64px;
    height: 64px;
    margin-bottom: 16px;
    opacity: 0.5;
}

.chat-welcome-panel h3 {
    margin: 0 0 8px 0;
    color: var(--text-primary);
}

.chat-welcome-panel p {
    margin: 0;
    font-size: 14px;
}

.chat-welcome-panel .chat-info {
    margin-top: 12px;
    font-size: 12px;
    color: var(--text-tertiary);
    font-style: italic;
}

.chat-welcome-panel .chat-info.offline {
    color: #f87171;
    font-weight: 600;
}

.chat-message {
    display: flex;
    gap: 12px;
    max-width: 80%;
    animation: fadeIn 0.3s ease;
}

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

.chat-message-me {
    margin-left: auto;
    flex-direction: row-reverse;
}

.chat-message-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    overflow: hidden;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
    color: white;
    font-weight: 600;
    font-size: 16px;
}

.chat-avatar-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.chat-message-content {
    flex: 1;
    min-width: 0;
}

.chat-message-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 4px;
}

.chat-message-me .chat-message-header {
    flex-direction: row-reverse;
}

.chat-author {
    font-size: 13px;
    font-weight: 600;
    color: var(--accent-primary);
}

.chat-time {
    font-size: 11px;
    color: var(--text-tertiary);
}

.chat-message-text {
    padding: 10px 14px;
    background: rgba(139, 92, 246, 0.1);
    border-radius: 16px;
    border-top-left-radius: 4px;
    font-size: 14px;
    line-height: 1.4;
    color: var(--text-primary);
    word-wrap: break-word;
}

.chat-message-me .chat-message-text {
    background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
    color: white;
    border-top-left-radius: 16px;
    border-top-right-radius: 4px;
}

.chat-input-panel {
    display: flex;
    gap: 12px;
    padding: 16px 20px;
    background: rgba(0, 0, 0, 0.2);
    border-top: 1px solid rgba(139, 92, 246, 0.2);
}

.chat-input-panel-field {
    flex: 1;
    padding: 12px 18px;
    border: 1px solid rgba(139, 92, 246, 0.3);
    border-radius: 25px;
    background: rgba(139, 92, 246, 0.05);
    color: var(--text-primary);
    font-size: 14px;
    transition: all 0.2s ease;
}

.chat-input-panel-field:focus {
    outline: none;
    border-color: var(--accent-primary);
    background: rgba(139, 92, 246, 0.1);
}

.chat-input-panel-field::placeholder {
    color: var(--text-tertiary);
}

.chat-send-panel-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 20px;
    background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
    border: none;
    border-radius: 25px;
    color: white;
    font-weight: 500;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.chat-send-panel-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(139, 92, 246, 0.4);
}

.chat-send-panel-btn .icon {
    width: 18px;
    height: 18px;
}

/* Mobile responsive for chat panel */
@media (max-width: 768px) {
    .chat-panel-container {
        height: calc(100vh - 250px);
        min-height: 400px;
        border-radius: 12px;
    }
    
    .chat-panel-header {
        padding: 12px 16px;
    }
    
    .chat-messages-panel {
        padding: 16px;
    }
    
    .chat-message {
        max-width: 90%;
    }
    
    .chat-input-panel {
        padding: 12px 16px;
    }
    
    .chat-send-panel-btn span {
        display: none;
    }
    
    .chat-send-panel-btn {
        padding: 12px 16px;
    }
}

@media (max-width: 480px) {
    .sidebar-content {
        padding: 16px;
    }
}

@media (max-width: 480px) {
    .sidebar-content {
        padding: 14px;
        padding-top: 80px;
    }
}

/* Em desktop, ajustar padding e altura */
@media (min-width: 1025px) {
    .sidebar-content {
        padding-top: 20px;
        min-height: auto;
    }
}

.community-btn {
    width: 100%;
    background: linear-gradient(135deg, var(--cosmic-accent) 0%, #4f46e5 100%);
    color: white;
    border: none;
    padding: 14px;
    border-radius: 10px;
    cursor: pointer;
    font-weight: 600;
    margin-bottom: 25px;
    display: flex;
    align-items: center;
    gap: 10px;
    transition: all 0.3s;
    box-shadow: 0 4px 12px var(--cosmic-glow);
}

.community-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px var(--cosmic-glow);
}

.btn-icon {
    font-size: 1.1rem;
}

.nav-section {
    margin-bottom: 25px;
}

.nav-link-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    color: var(--cosmic-text-muted);
    text-decoration: none;
    border-radius: 12px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    margin-bottom: 6px;
    font-size: 0.95em;
    font-weight: 500;
    border: 1px solid transparent;
}

.nav-link-item:hover {
    background: rgba(99, 102, 241, 0.08);
    color: var(--cosmic-text);
    transform: translateX(4px);
    border-color: rgba(99, 102, 241, 0.1);
}

.nav-link-item.active {
    background: rgba(99, 102, 241, 0.15);
    color: var(--cosmic-accent-bright);
    border: 1px solid rgba(99, 102, 241, 0.2);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.nav-icon {
    font-size: 1rem;
    width: 26px;
    height: 26px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: radial-gradient(circle at 30% 20%, rgba(129, 140, 248, 0.9), rgba(37, 99, 235, 0.4));
    color: #e5edff;
    box-shadow: 0 0 0 1px rgba(15, 23, 42, 0.6), 0 4px 10px rgba(15, 23, 42, 0.8);
}

.app-section {
    margin-bottom: 25px;
}

.app-section h3 {
    color: #666;
    font-size: 0.85rem;
    margin-bottom: 15px;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 700;
}

.app-buttons {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.app-btn {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    background: rgba(15, 14, 26, 0.4);
    border: 1px solid var(--cosmic-border);
    border-radius: 12px;
    color: var(--cosmic-text-muted);
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    text-decoration: none;
    font-size: 0.9em;
    backdrop-filter: blur(4px);
}

.app-btn:hover {
    background: rgba(99, 102, 241, 0.1);
    color: var(--cosmic-text);
    border-color: var(--cosmic-accent);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.app-icon {
    font-size: 1.2rem;
}

.genre-section {
    margin-bottom: 25px;
}

.genre-section h3 {
    color: var(--cosmic-text-muted);
    font-size: 0.8rem;
    margin-bottom: 15px;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    font-weight: 700;
    opacity: 0.8;
}

.genre-list {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
}

.genre-btn {
    padding: 10px 14px;
    background: rgba(15, 14, 26, 0.4);
    border: 1px solid var(--cosmic-border);
    border-radius: 10px;
    color: var(--cosmic-text-muted);
    cursor: pointer;
    font-size: 0.85rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    text-align: left;
    font-weight: 500;
    backdrop-filter: blur(4px);
}

.genre-btn:hover {
    background: rgba(99, 102, 241, 0.15);
    color: var(--cosmic-text);
    border-color: var(--cosmic-accent);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px var(--cosmic-glow);
}

.show-more {
    grid-column: 1 / -1;
    background: linear-gradient(135deg, var(--cosmic-accent) 0%, #4f46e5 100%) !important;
    color: white !important;
    border-color: rgba(99, 102, 241, 0.5) !important;
    text-align: center;
    font-weight: 600;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(79, 70, 229, 0.3);
}

.show-more:hover {
    box-shadow: 0 6px 16px rgba(79, 70, 229, 0.5);
    transform: translateY(-2px);
}

.sidebar-footer {
    padding: 24px 20px;
    border-top: 1px solid var(--cosmic-border);
    text-align: center;
    margin-top: auto;
    background: linear-gradient(to top, rgba(15, 14, 26, 0.4), transparent);
}

.sidebar-footer a {
    color: var(--cosmic-text-muted);
    text-decoration: none;
    font-size: 0.85rem;
    transition: all 0.3s ease;
    font-weight: 500;
    opacity: 0.8;
}

.sidebar-footer a:hover {
    color: var(--cosmic-accent-bright);
    opacity: 1;
}

/* MAIN CONTENT ADJUSTMENT - já definido acima */

/* SPOTLIGHT SECTION — visual cósmico */
.spotlight-section {
    background: radial-gradient(circle at 0% 0%, rgba(99, 102, 241, 0.15), transparent 50%),
                linear-gradient(135deg, rgba(28, 29, 46, 0.8) 0%, rgba(11, 12, 21, 0.9) 100%);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: 32px;
    padding: 48px;
    margin-bottom: 48px;
    border: 1px solid var(--cosmic-border);
    box-shadow: 0 20px 50px -10px rgba(0, 0, 0, 0.5), inset 0 0 0 1px rgba(255, 255, 255, 0.05);
    position: relative;
    overflow: hidden;
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.spotlight-section:hover {
    box-shadow: 0 30px 60px -15px rgba(0, 0, 0, 0.6), inset 0 0 0 1px rgba(99, 102, 241, 0.2);
    border-color: var(--cosmic-accent);
    transform: translateY(-2px);
}

@media (max-width: 768px) {
    .spotlight-section {
        padding: 24px;
        margin-bottom: 30px;
        border-radius: 12px;
    }
}

@media (max-width: 480px) {
    .spotlight-section {
        padding: 18px;
        margin-bottom: 24px;
        border-radius: 10px;
    }
}

.spotlight-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--cosmic-accent) 0%, var(--cosmic-accent-bright) 100%);
}
.spotlight-section::after {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 50%;
    height: 100%;
    background: linear-gradient(90deg, transparent 0%, rgba(99, 102, 241, 0.06) 100%);
    pointer-events: none;
}

/* UI do carrossel do destaque (setas + dots) */
.spotlight-carousel-ui {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin-top: 18px;
    position: relative;
    z-index: 2;
}

.spotlight-arrow {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    border: 1px solid var(--cosmic-border);
    background: rgba(15, 14, 26, 0.4);
    color: var(--cosmic-text);
    font-size: 1.2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.spotlight-arrow:hover {
    transform: scale(1.1);
    background: var(--cosmic-cta);
    border-color: var(--cosmic-cta);
    color: #fff;
    box-shadow: 0 0 15px var(--cosmic-glow);
}

.spotlight-dots {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 8px 16px;
    border: 1px solid var(--cosmic-border);
    background: rgba(15, 14, 26, 0.4);
    border-radius: 999px;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.spotlight-dot {
    width: 9px;
    height: 9px;
    border-radius: 999px;
    border: 1px solid rgba(129, 140, 248, 0.35);
    background: rgba(129, 140, 248, 0.12);
    cursor: pointer;
    transition: transform 0.2s ease, background 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.spotlight-dot:hover {
    transform: scale(1.15);
    border-color: rgba(129, 140, 248, 0.6);
}

.spotlight-dot.active {
    background: rgba(129, 140, 248, 0.9);
    border-color: rgba(129, 140, 248, 0.95);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.18);
}

.spotlight-content {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 30px;
    align-items: center;
}

@media (max-width: 768px) {
    .spotlight-content {
        grid-template-columns: 1fr;
        gap: 20px;
    }
}

@media (max-width: 480px) {
    .spotlight-content {
        grid-template-columns: 1fr;
        gap: 16px;
    }
}

.spotlight-title {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--cosmic-text);
    margin-bottom: 20px;
    line-height: 1.2;
    letter-spacing: -0.5px;
    position: relative;
    z-index: 1;
}

@media (max-width: 768px) {
    .spotlight-title {
        font-size: 1.8rem;
        margin-bottom: 14px;
    }
}

@media (max-width: 480px) {
    .spotlight-title {
        font-size: 1.4rem;
        margin-bottom: 12px;
    }
}

.spotlight-meta {
    display: flex;
    gap: 15px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

@media (max-width: 768px) {
    .spotlight-meta {
        gap: 10px;
        margin-bottom: 14px;
    }
}

@media (max-width: 480px) {
    .spotlight-meta {
        gap: 8px;
        margin-bottom: 12px;
    }
}

.type-badge {
    background: linear-gradient(135deg, var(--cosmic-accent) 0%, #4f46e5 100%);
    color: white;
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 0.8rem;
    font-weight: 600;
    box-shadow: 0 2px 8px var(--cosmic-glow);
}

@media (max-width: 768px) {
    .type-badge {
        font-size: 0.75rem;
        padding: 5px 10px;
        border-radius: 5px;
    }
}

@media (max-width: 480px) {
    .type-badge {
        font-size: 0.7rem;
        padding: 4px 8px;
    }
}

.duration, .release-date {
    color: var(--cosmic-text-muted);
    font-size: 0.9rem;
    font-weight: 500;
}

.quality-badge {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 0.8rem;
    font-weight: 600;
    box-shadow: 0 2px 8px rgba(16, 185, 129, 0.3);
}

.spotlight-description {
    color: var(--cosmic-text-muted);
    line-height: 1.7;
    margin-bottom: 30px;
    font-size: 1.05rem;
    max-width: 800px;
    position: relative;
    z-index: 1;
}

@media (max-width: 768px) {
    .spotlight-description {
        font-size: 0.95rem;
        margin-bottom: 16px;
        display: -webkit-box;
        -webkit-line-clamp: 3;
        line-clamp: 3;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }
}

@media (max-width: 480px) {
    .spotlight-description {
        font-size: 0.9rem;
        margin-bottom: 14px;
        -webkit-line-clamp: 2;
        line-clamp: 2;
    }
}

.spotlight-actions {
    display: flex;
    gap: 15px;
    flex-direction: row;
}

@media (max-width: 480px) {
    .spotlight-actions {
        flex-direction: column;
        gap: 12px;
    }
}

.watch-now-btn {
    background: linear-gradient(135deg, var(--cosmic-cta) 0%, var(--cosmic-accent-bright) 100%);
    color: white;
    border: none;
    padding: 14px 28px;
    border-radius: 10px;
    cursor: pointer;
    font-weight: 700;
    font-size: 1rem;
    transition: all 0.3s;
    box-shadow: 0 4px 16px var(--cosmic-blue-glow);
    position: relative;
    z-index: 1;
}

@media (max-width: 768px) {
    .watch-now-btn {
        padding: 12px 18px;
        font-size: 0.95rem;
        width: 100%;
    }
}

@media (max-width: 480px) {
    .watch-now-btn {
        padding: 10px 16px;
        font-size: 0.9rem;
    }
}

.watch-now-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 24px var(--cosmic-blue-glow);
    background: linear-gradient(135deg, var(--cosmic-cta-hover) 0%, var(--cosmic-accent) 100%);
}

.details-btn {
    background: transparent;
    color: var(--cosmic-text-muted);
    border: 1px solid var(--cosmic-border);
    padding: 14px 28px;
    border-radius: 10px;
    cursor: pointer;
    font-weight: 600;
    font-size: 1rem;
    transition: all 0.3s;
    position: relative;
    z-index: 1;
}

@media (max-width: 768px) {
    .details-btn {
        padding: 12px 18px;
        font-size: 0.95rem;
        width: 100%;
    }
}

@media (max-width: 480px) {
    .details-btn {
        padding: 10px 16px;
        font-size: 0.9rem;
    }
}

.details-btn:hover {
    background: var(--cosmic-bg-card);
    color: var(--cosmic-accent-bright);
    border-color: var(--cosmic-accent);
    transform: translateY(-2px);
}

.spotlight-img {
    width: 100%;
    height: 450px;
    object-fit: cover;
    border-radius: 12px;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.5);
    transition: transform 0.3s;
}

@media (max-width: 768px) {
    .spotlight-img {
        height: 320px;
    }
}

@media (max-width: 480px) {
    .spotlight-img {
        height: 240px;
        border-radius: 8px;
        width: 100%;
    }
    
    /* Desabilitar scale em mobile para melhor performance */
    .spotlight-img:hover {
        transform: none;
    }
}

.spotlight-img:hover {
    transform: scale(1.02);
}

.navbar-search {
    flex: 1;
    max-width: 600px;
    position: relative;
    display: flex;
    gap: 10px;
    align-items: center;
}
.navbar-search .search-suggestions {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    margin-top: 4px;
    background: var(--cosmic-bg-card);
    border: 1px solid #333;
    border-radius: 8px;
    max-height: 320px;
    overflow-y: auto;
    z-index: 1001;
    box-shadow: 0 8px 32px rgba(0,0,0,0.5);
    display: none;
}
.navbar-search .search-suggestions.active {
    display: block;
}
.navbar-search .search-suggestion-item {
    padding: 12px 16px;
    cursor: pointer;
    border-bottom: 1px solid var(--cosmic-border);
    transition: background 0.2s;
    color: #e0e0e0;
}
.navbar-search .search-suggestion-item:last-child {
    border-bottom: none;
}
.navbar-search .search-suggestion-item:hover {
    background: rgba(99, 102, 241, 0.2);
}
.navbar-search .search-suggestion-item strong {
    display: block;
    margin-bottom: 2px;
}
.navbar-search .search-suggestion-item small {
    color: #888;
    font-size: 0.85em;
}

.search-input {
    flex: 1;
    padding: 12px 20px;
    background: rgba(15, 14, 26, 0.4);
    border: 1px solid var(--cosmic-border);
    border-radius: 999px;
    color: var(--cosmic-text);
    font-size: 0.95em;
    transition: all 0.3s ease;
    backdrop-filter: blur(4px);
}

@media (max-width: 768px) {
    .search-input {
        padding: 10px 16px;
        font-size: 0.9em;
    }
}

@media (max-width: 480px) {
    .search-input {
        padding: 9px 14px;
        font-size: 0.85em;
        width: 100%;
    }
}

.search-input:focus {
    outline: none;
    background: rgba(15, 14, 26, 0.8);
    border-color: var(--cosmic-accent);
    box-shadow: 0 0 0 4px var(--cosmic-glow);
    transform: translateY(-1px);
}

.search-input::placeholder {
    color: var(--cosmic-text-muted);
    opacity: 0.7;
}

.search-btn-icon {
    padding: 12px;
    width: 42px;
    height: 42px;
    background: var(--cosmic-accent);
    border: 1px solid var(--cosmic-accent-bright);
    border-radius: 50%;
    color: white;
    font-size: 1.1em;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    white-space: nowrap;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px var(--cosmic-glow);
}

.search-btn-icon:hover {
    background: var(--cosmic-accent-bright);
    transform: scale(1.05);
    box-shadow: 0 6px 16px var(--cosmic-glow);
}

.search-btn-icon:active {
    transform: scale(0.98);
}

@media (max-width: 768px) {
    .search-btn-icon {
        padding: 10px 14px;
        font-size: 1em;
    }
}

@media (max-width: 480px) {
    .search-btn-icon {
        padding: 9px 12px;
        font-size: 0.95em;
    }
}

.filter-btn {
    padding: 12px 20px;
    background: var(--cosmic-bg-card);
    border: 1px solid #333;
    border-radius: 8px;
    color: #fff;
    cursor: pointer;
    font-size: 0.9em;
    font-weight: 500;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.filter-btn:hover {
    background: #1f1f1f;
    border-color: var(--cosmic-accent-bright);
    color: var(--cosmic-accent-bright);
}

.search-suggestions {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: linear-gradient(135deg, rgba(0, 30, 60, 0.95) 0%, rgba(0, 20, 40, 0.95) 100%);
    border: 1px solid rgba(77, 166, 255, 0.3);
    border-top: none;
    border-radius: 0 0 8px 8px;
    max-height: 300px;
    overflow-y: auto;
    display: none;
    z-index: 1000;
}

.search-suggestions.active {
    display: block;
}

.search-suggestion-item {
    padding: 12px 15px;
    border-bottom: 1px solid rgba(77, 166, 255, 0.1);
    cursor: pointer;
    transition: all 0.2s ease;
}

.search-suggestion-item:hover {
    background: rgba(77, 166, 255, 0.1);
}

.search-suggestion-item strong {
    color: #4da6ff;
}



/* COSMIC STARS - SIMPLIFIED */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(1px 1px at 20% 30%, #4da6ff, transparent),
        radial-gradient(1px 1px at 60% 70%, #66b3ff, transparent),
        radial-gradient(1px 1px at 50% 50%, #99ccff, transparent),
        radial-gradient(1px 1px at 80% 10%, #b3d9ff, transparent),
        radial-gradient(1px 1px at 30% 80%, #e6f2ff, transparent);
    background-size: 150% 150%;
    background-position: 0% 0%;
    background-repeat: repeat;
    z-index: 0;
    pointer-events: none;
    animation: cosmicStars 200s linear infinite;
}

@keyframes cosmicStars {
    0% { background-position: 0% 0%; }
    100% { background-position: 150% 150%; }
}

/* REMOVED MOVING PARTICLES FOR PERFORMANCE */

/* WRAPPER E SIDEBAR */
.wrapper {
    min-height: 100vh;
    position: relative;
    z-index: 1;
}

/* Em desktop, wrapper usa flexbox para sidebar + main */
@media (min-width: 1025px) {
    .wrapper {
        display: flex;
        flex-direction: row;
    }
}

.main-wrapper {
    padding: 30px;
    padding-top: calc(62px + 30px);
    max-width: 1600px;
    margin-left: auto;
    margin-right: auto;
    padding-left: calc(280px + 30px);
    padding-right: 30px;
    overflow-y: auto;
    min-height: calc(100vh - 62px);
    position: relative;
    z-index: 1;
}

@media (max-width: 768px) {
    .main-wrapper {
        padding: 16px 15px;
        padding-top: calc(62px + 16px);
        padding-left: 15px !important;
    }
}

@media (max-width: 480px) {
    .main-wrapper {
        padding: 16px 14px;
        padding-top: calc(62px + 16px);
        padding-left: 14px !important;
    }
}

/* Em desktop, remover padding-left pois sidebar é static */
@media (min-width: 1025px) {
    .main-wrapper {
        padding-left: 30px;
        flex: 1;
        overflow-y: auto;
        max-width: 100%;
    }
}

.sidebar {
    width: 250px;
    background: linear-gradient(135deg, rgba(0, 20, 40, 0.95) 0%, rgba(0, 10, 30, 0.95) 100%);
    border-right: 1px solid rgba(77, 166, 255, 0.2);
    padding: 20px 0;
    box-shadow: 1px 0 10px rgba(77, 166, 255, 0.1);
    display: flex;
    flex-direction: column;
    animation: slideInLeft 0.6s ease-out;
}

.sidebar-header {
    padding: 20px;
    border-bottom: 1px solid rgba(77, 166, 255, 0.2);
    text-align: center;
}

.sidebar-header h2 {
    font-size: 1.5em;
    background: linear-gradient(135deg, #0066cc 0%, #004d99 50%, #003366 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin: 0;
    font-weight: 900;
}

.sidebar-nav {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 20px 10px;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px 20px;
    background: rgba(77, 166, 255, 0.1);
    border: 2px solid rgba(77, 166, 255, 0.2);
    border-radius: 12px;
    cursor: pointer;
    color: #b3d9ff;
    font-weight: 600;
    font-size: 0.95em;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    text-align: left;
    white-space: nowrap;
}

.nav-item:hover {
    background: rgba(77, 166, 255, 0.2);
    border-color: rgba(77, 166, 255, 0.4);
    color: #0066cc;
    transform: translateX(3px);
    box-shadow: 0 0 10px rgba(77, 166, 255, 0.2);
}

.nav-item.active {
    background: linear-gradient(135deg, #0066cc 0%, #004d99 100%);
    border-color: #0066cc;
    color: white;
    box-shadow: 0 0 15px rgba(0, 102, 204, 0.3);
}

.nav-item .icon {
    font-size: 1.3em;
    flex-shrink: 0;
}

/* Menu Expansível */
.nav-category {
    margin: 8px 0;
}

.nav-category-btn {
    width: 100%;
    padding: 12px 15px;
    background: transparent;
    border: none;
    color: rgba(240, 240, 240, 0.8);
    cursor: pointer;
    font-size: 0.95em;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 12px;
    transition: all 0.3s ease;
    border-left: 3px solid transparent;
}

.nav-category-btn:hover {
    background: rgba(77, 166, 255, 0.1);
    color: #4da6ff;
    border-left-color: #4da6ff;
}

.nav-category-btn .arrow {
    margin-left: auto;
    font-size: 0.8em;
    transition: transform 0.3s ease;
}

.nav-category-btn.expanded .arrow {
    transform: rotate(180deg);
}

.submenu {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

.submenu.active {
    max-height: 600px;
}

.nav-subitem {
    width: 100%;
    padding: 10px 15px 10px 40px;
    background: rgba(77, 166, 255, 0.05);
    border: none;
    color: rgba(240, 240, 240, 0.7);
    cursor: pointer;
    font-size: 0.9em;
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 4px 0;
    border-radius: 6px;
    transition: all 0.2s ease;
    margin-left: 10px;
    margin-right: 10px;
}

.nav-subitem:hover {
    background: rgba(77, 166, 255, 0.2);
    color: #4da6ff;
    transform: translateX(5px);
}

.about-container {
    padding: 40px;
    background: radial-gradient(circle at 0% 0%, rgba(99, 102, 241, 0.1), transparent 40%),
                linear-gradient(135deg, var(--cosmic-bg-card) 0%, var(--cosmic-bg-elevated) 100%);
    border-radius: 24px;
    border: 1px solid var(--cosmic-border);
    color: var(--cosmic-text);
    box-shadow: 0 20px 40px -10px rgba(0, 0, 0, 0.5);
}

.about-container h2 {
    font-size: 2.5em;
    background: linear-gradient(135deg, var(--cosmic-text) 0%, var(--cosmic-accent-bright) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 30px;
    font-weight: 800;
    letter-spacing: -0.03em;
}

.about-container h3 {
    font-size: 1.5em;
    color: var(--cosmic-accent-bright);
    margin-top: 32px;
    margin-bottom: 16px;
    font-weight: 700;
}

.about-content {
    line-height: 1.8;
    color: var(--cosmic-text-muted);
}

.about-content p {
    margin-bottom: 20px;
    font-size: 1.05em;
}

.about-content ul {
    list-style: none;
    padding-left: 0;
    margin-bottom: 24px;
}

.about-content ul li {
    padding: 12px 0;
    padding-left: 32px;
    position: relative;
    font-size: 1em;
    border-bottom: 1px solid rgba(99, 102, 241, 0.1);
}

.about-content ul li:last-child {
    border-bottom: none;
}

.about-content ul li::before {
    content: '✦';
    position: absolute;
    left: 0;
    color: var(--cosmic-accent);
    font-size: 1.2em;
}

/* HEADER (Cosmic Theme) */
header {
    background: radial-gradient(circle at 50% 0%, var(--cosmic-bg-elevated) 0%, var(--cosmic-bg) 100%);
    color: var(--cosmic-text);
    padding: 60px 20px;
    text-align: center;
    position: relative;
    overflow: hidden;
    border-bottom: 1px solid var(--cosmic-border);
}

header::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle at 20% 50%, var(--cosmic-glow) 0%, transparent 60%);
    animation: float 30s ease-in-out infinite;
    pointer-events: none;
}

header::after {
    content: '';
    position: absolute;
    bottom: -50%;
    right: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle at 80% 50%, rgba(139, 92, 246, 0.1) 0%, transparent 60%);
    animation: float 35s ease-in-out infinite reverse;
    pointer-events: none;
}

header h1 {
    font-size: 3.5em;
    margin-bottom: 10px;
    font-weight: 900;
    letter-spacing: -2px;
    position: relative;
    z-index: 1;
    animation: glow 3s ease-in-out infinite, slideInLeft 0.8s ease-out;
    background: linear-gradient(135deg, #fff 0%, var(--cosmic-accent-bright) 50%, var(--cosmic-accent) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

header p {
    font-size: 1.2em;
    opacity: 0.85;
    position: relative;
    z-index: 1;
    font-weight: 500;
    letter-spacing: 1px;
    animation: slideInRight 0.8s ease-out 0.2s both;
    color: var(--cosmic-text-muted);
}

/* MAIN CONTENT */
.main-content {
    padding: 40px 30px;
    animation: fadeIn 0.8s ease-out 0.3s both;
}

/* SEARCH SECTION */
.search-container {
    display: flex;
    gap: 12px;
    margin-bottom: 40px;
    flex-wrap: wrap;
    align-items: flex-start;
}

.search-box {
    flex: 1;
    min-width: 250px;
    position: relative;
}

.search-input {
    width: 100%;
    padding: 14px 20px;
    border: 1px solid var(--cosmic-border);
    border-radius: 999px;
    font-size: 1em;
    transition: all 0.3s ease;
    background: rgba(15, 14, 26, 0.6);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
    color: var(--cosmic-text);
}

.search-input:focus {
    outline: none;
    border-color: var(--cosmic-accent);
    box-shadow: 0 0 20px var(--cosmic-glow);
    background: rgba(15, 14, 26, 0.8);
}

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

.search-suggestions {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: rgba(0, 15, 35, 0.95);
    border: 1px solid rgba(77, 166, 255, 0.2);
    border-top: none;
    border-radius: 0 0 12px 12px;
    max-height: 350px;
    overflow-y: auto;
    display: none;
    z-index: 100;
    box-shadow: 0 5px 20px rgba(77, 166, 255, 0.15);
    backdrop-filter: blur(5px);
}

.search-suggestions.active {
    display: block;
}

.search-suggestion-item {
    padding: 14px 18px;
    cursor: pointer;
    transition: all 0.2s;
    border-bottom: 1px solid rgba(139, 92, 246, 0.15);
    font-size: 0.95em;
    color: #f0f0f0;
}

.search-suggestion-item:hover {
    background: rgba(77, 166, 255, 0.15);
    color: #0066cc;
    font-weight: 600;
    padding-left: 20px;
    border-left: 2px solid #0066cc;
}

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

.provider-select {
    padding: 14px 18px;
    border: 1px solid rgba(77, 166, 255, 0.2);
    border-radius: 12px;
    background: rgba(0, 20, 40, 0.6);
    cursor: pointer;
    font-size: 1em;
    transition: all 0.3s ease;
    font-weight: 600;
    color: #f0f0f0;
    box-shadow: 0 0 10px rgba(102, 179, 255, 0.05);
}

.provider-select:hover {
    border-color: rgba(77, 166, 255, 0.4);
    box-shadow: 0 0 15px rgba(77, 166, 255, 0.15);
}

.provider-select:focus {
    outline: none;
    border-color: rgba(77, 166, 255, 0.5);
    box-shadow: 0 0 15px rgba(77, 166, 255, 0.2);
}

.search-btn {
    padding: 14px 32px;
    background: linear-gradient(135deg, #0066cc 0%, #004d99 100%);
    color: white;
    border: none;
    border-radius: 12px;
    cursor: pointer;
    font-size: 1em;
    font-weight: 700;
    transition: all 0.3s ease;
    white-space: nowrap;
    box-shadow: 0 0 15px rgba(0, 102, 204, 0.2);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.search-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 0 25px rgba(0, 102, 204, 0.3);
}

.search-btn:active {
    transform: translateY(-1px);
}

.reset-btn {
    background: linear-gradient(135deg, #004080 0%, #004d99 100%);
    box-shadow: 0 0 15px rgba(0, 64, 128, 0.2);
}

.reset-btn:hover {
    box-shadow: 0 0 25px rgba(0, 64, 128, 0.3);
}

/* LETTER FILTER */
.letter-filter {
    margin-bottom: 35px;
    padding: 20px;
    background: linear-gradient(135deg, rgba(77, 166, 255, 0.05) 0%, rgba(102, 179, 255, 0.02) 100%);
    border-radius: 15px;
    border: 1px solid rgba(77, 166, 255, 0.1);
    box-shadow: 0 0 10px rgba(77, 166, 255, 0.05);
}

.filter-label {
    display: block;
    font-size: 0.95em;
    font-weight: 700;
    color: #b3d9ff;
    margin-bottom: 15px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.letter-buttons-container {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.letter-btn {
    padding: 8px 12px;
    background: rgba(77, 166, 255, 0.1);
    border: 1px solid rgba(77, 166, 255, 0.2);
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.85em;
    font-weight: 700;
    color: #b3d9ff;
    transition: all 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.letter-btn:hover {
    border-color: rgba(77, 166, 255, 0.4);
    color: #0066cc;
    background: rgba(77, 166, 255, 0.15);
    box-shadow: 0 0 8px rgba(77, 166, 255, 0.2);
    transform: translateY(-1px);
}

.letter-btn.active {
    background: linear-gradient(135deg, #0066cc 0%, #004d99 100%);
    color: white;
    border-color: #0066cc;
    box-shadow: 0 0 12px rgba(0, 102, 204, 0.3);
}

/* WORD FILTER */
.word-filter {
    margin-bottom: 30px;
    display: flex;
    gap: 12px;
    align-items: center;
}

.word-filter-input {
    flex: 1;
    padding: 12px 16px;
    border: 1px solid rgba(77, 166, 255, 0.2);
    border-radius: 12px;
    font-size: 0.95em;
    transition: all 0.2s ease;
    background: rgba(0, 20, 40, 0.6);
    color: #f0f0f0;
    min-width: 250px;
    box-shadow: 0 0 10px rgba(102, 179, 255, 0.05);
}

.word-filter-input:focus {
    outline: none;
    border-color: rgba(77, 166, 255, 0.5);
    box-shadow: 0 0 15px rgba(77, 166, 255, 0.2);
}

.word-filter-input::placeholder {
    color: rgba(255, 255, 255, 0.4);
}

.filter-hint {
    font-size: 0.85em;
    color: #b3d9ff;
    font-weight: 600;
    min-width: 150px;
}

/* SECTION TITLE */
.section-title {
    margin-bottom: 30px;
    padding-bottom: 15px;
    border-bottom: 1px solid rgba(77, 166, 255, 0.2);
    animation: slideInLeft 0.6s ease-out;
}

.section-title h2 {
    font-size: 2.2em;
    background: linear-gradient(135deg, #0066cc 0%, #004d99 50%, #003366 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin: 0;
    font-weight: 900;
    letter-spacing: -0.5px;
}

/* RESULTS GRID */
.results-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 25px;
}

@media (max-width: 768px) {
    .results-grid {
        grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
        gap: 12px;
    }
}

@media (max-width: 480px) {
    .results-grid {
        grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
        gap: 8px;
    }
}

.result-card {
    background: var(--cosmic-bg-card);
    border-radius: 16px;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    border: 1px solid var(--cosmic-border);
    position: relative;
    animation: fadeIn 0.6s ease-out;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.result-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(180deg, transparent 40%, rgba(15, 14, 26, 0.9) 100%);
    opacity: 0;
    z-index: 1;
    transition: opacity 0.3s;
}

.result-card:hover {
    transform: translateY(-6px) scale(1.02);
    box-shadow: 0 12px 32px var(--cosmic-glow);
    border-color: var(--cosmic-accent);
}

.result-card:hover::before {
    opacity: 1;
}

/* Image container com badges */
.result-card-image {
    position: relative;
    overflow: hidden;
    flex-shrink: 0;
}

.result-image {
    width: 100%;
    height: 260px;
    object-fit: cover;
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.2) 0%, rgba(37, 99, 235, 0.1) 100%);
    position: relative;
    transition: transform 0.3s;
    z-index: 0;
    display: block;
}

@media (max-width: 768px) {
    .result-image {
        height: 200px;
    }
}

@media (max-width: 480px) {
    .result-image {
        height: 150px;
    }
}

.result-card:hover .result-image {
    transform: scale(1.05);
}

/* Overlay com badges */
.result-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.4);
    display: flex;
    align-items: flex-start;
    justify-content: flex-end;
    padding: 8px;
    opacity: 0;
    transition: opacity 0.3s;
    z-index: 2;
}

.result-card:hover .result-overlay {
    opacity: 1;
}

/* Badges */
.result-badges {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.badge {
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 600;
    background: rgba(99, 102, 241, 0.8);
    color: #fff;
    backdrop-filter: blur(4px);
    border: 1px solid rgba(99, 102, 241, 0.5);
    white-space: nowrap;
}

.badge-type {
    background: rgba(59, 130, 246, 0.8);
}

.badge-rating {
    background: rgba(34, 197, 94, 0.8);
}

/* Info section */
.result-info {
    padding: 16px;
    background: var(--cosmic-bg-card);
    border-top: 1px solid rgba(59, 130, 246, 0.1);
    position: relative;
    z-index: 2;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.result-title {
    font-weight: 700;
    margin: 0;
    color: #fff;
    word-break: break-word;
    font-size: 0.95em;
    line-height: 1.4;
    transition: color 0.3s;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
}

.result-card:hover .result-title {
    color: var(--cosmic-accent-bright);
}

.result-meta {
    font-size: 0.8rem;
    color: var(--cosmic-text-muted);
    display: flex;
    gap: 4px;
    flex-wrap: wrap;
}

.meta-item {
    white-space: nowrap;
}

.result-genres {
    font-size: 0.75rem;
    color: var(--cosmic-accent-bright);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.result-status {
    font-size: 0.8rem;
    padding: 4px 8px;
    background: rgba(99, 102, 241, 0.2);
    border-radius: 4px;
    color: var(--cosmic-accent-bright);
    text-align: center;
    font-weight: 600;
}



.result-meta {
    font-size: 0.85em;
    color: #999;
    margin-bottom: 5px;
    font-weight: 500;
}

/* LOADING */
.loading {
    display: none;
    text-align: center;
    padding: 60px 40px;
    font-size: 1.3em;
    color: var(--cosmic-accent-bright);
    animation: glow 2s ease-in-out infinite;
}

.loading.active {
    display: block;
}

/* MODAL LOADING STATE */
.modal-details.loading-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 400px;
    gap: 30px;
}

/* SKELETON LOADERS */
.modal-skeleton-header {
    display: flex;
    gap: 20px;
    width: 100%;
    margin-bottom: 20px;
}

.modal-skeleton-image {
    width: 200px;
    height: 280px;
    background: linear-gradient(90deg, rgba(99, 102, 241, 0.1) 0%, rgba(99, 102, 241, 0.2) 50%, rgba(99, 102, 241, 0.1) 100%);
    background-size: 200% 100%;
    border-radius: 12px;
    animation: shimmer 2s infinite;
    flex-shrink: 0;
}

.modal-skeleton-text {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.modal-skeleton-line {
    height: 12px;
    background: linear-gradient(90deg, rgba(99, 102, 241, 0.1) 0%, rgba(99, 102, 241, 0.2) 50%, rgba(99, 102, 241, 0.1) 100%);
    background-size: 200% 100%;
    border-radius: 6px;
    animation: shimmer 2s infinite;
}

.modal-skeleton-line.title {
    height: 24px;
    width: 80%;
}

.modal-skeleton-line:not(.title) {
    width: 100%;
}

.modal-skeleton-line.short {
    width: 60%;
}

.modal-skeleton-body {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

/* LOADING SPINNER */
.loading-spinner {
    width: 50px;
    height: 50px;
    border: 4px solid rgba(99, 102, 241, 0.2);
    border-top-color: var(--cosmic-accent-bright);
    border-radius: 50%;
    animation: spin 1.5s linear infinite;
}

.loading-text {
    font-size: 1.2em;
    color: var(--cosmic-accent-bright);
    font-weight: 600;
    letter-spacing: 1px;
}

/* PAGINATION */
.pagination-container {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    margin-top: 40px;
    padding-bottom: 40px;
}

.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.page-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 44px;
    height: 44px;
    padding: 0 14px;
    background: var(--cosmic-bg-card);
    border: 1px solid var(--cosmic-border);
    border-radius: 50%;
    color: var(--cosmic-text);
    font-weight: 600;
    cursor: pointer;
    transition: all 0.25s ease;
    font-size: 0.95em;
}

.page-btn:hover {
    background: var(--cosmic-bg-elevated);
    border-color: var(--cosmic-accent);
    color: var(--cosmic-accent-bright);
    box-shadow: 0 0 16px var(--cosmic-glow);
    transform: scale(1.08);
}

.page-btn.active {
    background: var(--cosmic-cta);
    border-color: var(--cosmic-cta);
    color: #fff;
    box-shadow: 0 0 20px var(--cosmic-blue-glow);
    transform: scale(1.1);
}

.page-dots {
    color: var(--cosmic-text-muted);
    font-size: 1.2em;
    margin: 0 4px;
}

/* GENRES GRID */
.genres-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 15px;
    margin-top: 20px;
}

.genre-card {
    background: linear-gradient(135deg, rgba(77, 166, 255, 0.15) 0%, rgba(0, 51, 102, 0.1) 100%);
    border: 2px solid rgba(77, 166, 255, 0.3);
    border-radius: 10px;
    padding: 20px 15px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 600;
    color: #4da6ff;
}

.genre-card:hover {
    background: linear-gradient(135deg, rgba(77, 166, 255, 0.3) 0%, rgba(0, 51, 102, 0.2) 100%);
    border-color: rgba(77, 166, 255, 0.6);
    transform: translateY(-5px);
    box-shadow: 0 5px 20px rgba(77, 166, 255, 0.2);
}

/* SCHEDULE GRID */
.schedule-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.schedule-day {
    background: linear-gradient(135deg, rgba(0, 30, 60, 0.5) 0%, rgba(0, 20, 40, 0.5) 100%);
    border: 1px solid rgba(77, 166, 255, 0.2);
    border-radius: 10px;
    padding: 15px;
    overflow: hidden;
}

.schedule-day-title {
    font-size: 1.1em;
    font-weight: 700;
    color: #4da6ff;
    margin-bottom: 12px;
    padding-bottom: 10px;
    border-bottom: 2px solid rgba(77, 166, 255, 0.2);
}

.schedule-anime-item {
    padding: 10px 0;
    border-bottom: 1px solid rgba(77, 166, 255, 0.1);
    cursor: pointer;
    transition: all 0.2s ease;
    color: rgba(240, 240, 240, 0.8);
}

.schedule-anime-item:hover {
    color: #4da6ff;
    padding-left: 5px;
}

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

/* MODAL */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(5px);
    animation: fadeIn 0.3s;
}

.modal.active {
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-content {
    background: linear-gradient(135deg, rgba(0, 15, 35, 0.95) 0%, rgba(0, 25, 50, 0.95) 100%);
    padding: 40px;
    border-radius: 20px;
    max-width: 650px;
    max-height: 85vh;
    overflow-y: auto;
    position: relative;
    box-shadow: 0 0 60px rgba(77, 166, 255, 0.5), 0 0 30px rgba(0, 102, 204, 0.3);
    border: 2px solid rgba(77, 166, 255, 0.3);
}

.close {
    position: absolute;
    right: 24px;
    top: 24px;
    font-size: 32px;
    font-weight: bold;
    color: #0066cc;
    cursor: pointer;
    transition: all 0.3s;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}

.close:hover {
    color: #fff;
    background: rgba(0, 102, 204, 0.2);
    transform: rotate(90deg);
    box-shadow: 0 0 20px rgba(0, 102, 204, 0.4);
}

/* MODAL DETAILS - IMPROVED LAYOUT */
.modal-details {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

/* Modal Header - Horizontal Layout */
.modal-header {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 24px;
    align-items: start;
}

.modal-image {
    width: 200px;
    height: 300px;
    object-fit: cover;
    border-radius: 15px;
    box-shadow: 0 0 40px rgba(77, 166, 255, 0.4), 0 0 20px rgba(0, 102, 204, 0.2);
    border: 2px solid rgba(77, 166, 255, 0.3);
}

.modal-header-info {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.modal-title {
    font-size: 2em;
    font-weight: 900;
    margin: 0;
    background: linear-gradient(135deg, #0066cc 0%, #004d99 50%, #003366 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: -0.5px;
    line-height: 1.2;
}

.modal-alt-title {
    font-size: 0.9em;
    color: var(--cosmic-text-muted);
    margin: 0;
    font-style: italic;
}

/* Meta informações */
.modal-meta {
    background: linear-gradient(135deg, rgba(77, 166, 255, 0.15) 0%, rgba(102, 179, 255, 0.1) 100%);
    padding: 16px;
    border-radius: 12px;
    border: 1px solid rgba(77, 166, 255, 0.2);
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.meta-row {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    font-size: 0.9em;
}

.meta-label {
    font-weight: 600;
    color: var(--cosmic-accent-bright);
    min-width: 100px;
}

.meta-value {
    color: #b3d9ff;
}

/* Modal Actions */
.modal-actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.watch-now-btn,
.details-btn,
.favorite-btn {
    padding: 10px 20px;
    border-radius: 8px;
    border: none;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s;
    font-size: 0.95em;
}

.watch-now-btn {
    background: linear-gradient(135deg, #0066cc 0%, #004d99 100%);
    color: white;
    box-shadow: 0 0 20px rgba(0, 102, 204, 0.3);
}

.watch-now-btn:hover {
    background: linear-gradient(135deg, #0080ff 0%, #0066cc 100%);
    box-shadow: 0 0 30px rgba(0, 102, 204, 0.5);
}

.details-btn {
    background: rgba(77, 166, 255, 0.2);
    color: #0066cc;
    border: 1px solid #0066cc;
}

.details-btn:hover {
    background: rgba(77, 166, 255, 0.3);
}

.favorite-btn {
    padding: 10px 20px;
    border-radius: 8px;
    border: 1px solid rgba(99, 102, 241, 0.5);
    background: transparent;
    color: var(--cosmic-text);
    cursor: pointer;
    transition: all 0.3s;
    font-weight: 600;
}

.favorite-btn.add {
    color: #888;
}

.favorite-btn.add:hover {
    background: rgba(139, 92, 246, 0.2);
    color: var(--cosmic-accent-bright);
    border-color: var(--cosmic-accent);
}

.favorite-btn.remove {
    color: #f87171;
    border-color: #f87171;
    background: rgba(248, 113, 113, 0.1);
}

.favorite-btn.remove:hover {
    background: rgba(248, 113, 113, 0.2);
}

/* Modal Sections */
.modal-section {
    background: rgba(77, 166, 255, 0.1);
    padding: 20px;
    border-radius: 12px;
    border: 1px solid rgba(77, 166, 255, 0.2);
}

.modal-section h3 {
    margin-top: 0;
    margin-bottom: 12px;
    color: var(--cosmic-accent-bright);
    font-size: 1.1em;
}

.modal-description {
    color: #b3d9ff;
    line-height: 1.8;
    margin: 0;
    text-align: left;
    font-size: 0.95em;
}

/* Info Grid */
.info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
}

.info-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.info-item strong {
    color: var(--cosmic-accent-bright);
    font-size: 0.9em;
}

.info-item span {
    color: #b3d9ff;
    font-size: 0.85em;
    word-break: break-word;
}

/* Episodes Section - IMPROVED */
.episodes-section {
    margin-top: 20px;
}

.episodes-title {
    font-size: 1.4em;
    font-weight: 700;
    margin-bottom: 16px;
    color: #0066cc;
    border-bottom: 2px solid rgba(77, 166, 255, 0.4);
    padding-bottom: 10px;
}

.episode-tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 16px;
    flex-wrap: wrap;
}

.episode-tab {
    padding: 8px 16px;
    border-radius: 6px;
    background: rgba(77, 166, 255, 0.1);
    color: var(--cosmic-text);
    border: 1px solid rgba(77, 166, 255, 0.3);
    cursor: pointer;
    transition: all 0.3s;
    font-weight: 600;
    font-size: 0.85em;
}

.episode-tab.active {
    background: #0066cc;
    color: white;
    border-color: #0066cc;
}

.episode-tab:hover {
    background: rgba(77, 166, 255, 0.2);
}

.episodes-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
    gap: 12px;
}

.episode-btn {
    padding: 10px 8px;
    background: linear-gradient(135deg, rgba(77, 166, 255, 0.2), rgba(102, 179, 255, 0.1));
    border: 1px solid rgba(77, 166, 255, 0.4);
    border-radius: 8px;
    color: #b3d9ff;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.2s;
    font-size: 0.85em;
}

.episode-btn:hover {
    background: linear-gradient(135deg, #0066cc, #004d99);
    color: white;
    border-color: #0066cc;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 102, 204, 0.3);
}

.no-episodes {
    text-align: center;
    padding: 20px;
    color: var(--cosmic-text-muted);
}

/* Video Player Container */
.video-container {
    position: relative;
    width: 100%;
    padding-bottom: 56.25%;
    height: 0;
    overflow: hidden;
    border-radius: 12px;
    margin: 20px 0;
}

.video-iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
    border-radius: 12px;
}

/* Modal Mobile Responsiveness */
@media (max-width: 768px) {
    .modal-header {
        grid-template-columns: 1fr;
    }
    
    .modal-image {
        width: 100%;
        height: auto;
        max-height: 300px;
    }
    
    .modal-title {
        font-size: 1.5em;
    }
    
    .meta-row {
        flex-direction: column;
        gap: 4px;
    }
    
    .info-grid {
        grid-template-columns: 1fr;
    }
    
    .episodes-list {
        grid-template-columns: repeat(auto-fill, minmax(60px, 1fr));
    }
    
    .modal-actions {
        flex-direction: column;
    }
    
    .watch-now-btn,
    .details-btn,
    .favorite-btn {
        width: 100%;
    }
}

/* RESPONSIVE */
@media (max-width: 768px) {
    header h1 {
        font-size: 2em;
    }

    header p {
        font-size: 1em;
    }

    .search-container {
        flex-direction: column;
    }

    .search-box,
    .provider-select,
    .search-btn {
        width: 100%;
    }

    .results-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
        gap: 15px;
    }

    .modal-content {
        width: 90%;
        padding: 20px;
    }

    .episodes-list {
        grid-template-columns: repeat(auto-fill, minmax(70px, 1fr));
    }
}

/* EMPTY STATE */
.empty {
    text-align: center;
    padding: 80px 20px;
    color: #b3d9ff;
}

.empty-icon {
    font-size: 4em;
    margin-bottom: 20px;
    animation: float 3s ease-in-out infinite;
}

.empty-text {
    font-size: 1.2em;
    color: #b3d9ff;
}

/* EPISODES SECTION */
.episodes-section {
    margin-top: 30px;
    text-align: left;
}

.episodes-section h3 {
    font-size: 1.4em;
    font-weight: 700;
    margin-bottom: 20px;
    color: #0066cc;
    border-bottom: 2px solid rgba(77, 166, 255, 0.4);
    padding-bottom: 10px;
}

.episodes-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
    gap: 12px;
    margin-bottom: 15px;
}

.episode-btn {
    padding: 12px 14px;
    background: rgba(77, 166, 255, 0.15);
    border: 2px solid rgba(77, 166, 255, 0.3);
    border-radius: 10px;
    cursor: pointer;
    font-size: 0.85em;
    font-weight: 700;
    color: #b3d9ff;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.episode-btn:hover {
    background: linear-gradient(135deg, #0066cc 0%, #004d99 100%);
    color: white;
    border-color: #0066cc;
    transform: translateY(-3px);
    box-shadow: 0 0 20px rgba(0, 102, 204, 0.4);
}

.more-episodes {
    grid-column: 1 / -1;
    text-align: center;
    color: #666;
    font-size: 0.9em;
}

.download-link {
    display: inline-block;
    padding: 12px 20px;
    background: linear-gradient(135deg, #0066cc 0%, #004d99 100%);
    color: white;
    text-decoration: none;
    border-radius: 10px;
    transition: all 0.3s;
    box-shadow: 0 0 20px rgba(0, 102, 204, 0.3);
}

.download-link:hover {
    box-shadow: 0 0 30px rgba(0, 102, 204, 0.6);
    transform: translateY(-2px);
}

/* VIDEO PLAYER */
.video-container {
    position: relative;
    width: 100%;
    max-height: 700px;
    overflow-y: auto;
    border-radius: 12px;
    margin-bottom: 15px;
    background: #000;
    box-shadow: 0 0 30px rgba(77, 166, 255, 0.3);
    border: 1px solid rgba(77, 166, 255, 0.2);
}

.video-iframe {
    width: 100%;
    height: 600px;
    border: none;
    border-radius: 12px;
    display: block;
}

/* Ajustes para mobile */
@media (max-width: 768px) {
    .video-container {
        max-height: 450px;
    }

    .video-iframe {
        height: 350px;
    }
}

/* Ajustes para tablets */
@media (max-width: 1024px) and (min-width: 769px) {
    .video-container {
        max-height: 550px;
    }

    .video-iframe {
        height: 450px;
    }
}

/* PLAYER CONTROLS */
.player-controls {
    display: flex;
    gap: 20px;
    margin-bottom: 25px;
    flex-wrap: wrap;
    padding: 20px;
    background: linear-gradient(135deg, rgba(77, 166, 255, 0.1) 0%, rgba(102, 179, 255, 0.05) 100%);
    border-radius: 12px;
    border: 1px solid rgba(77, 166, 255, 0.2);
}

.control-group {
    display: flex;
    gap: 10px;
    align-items: center;
}

.control-group label {
    font-weight: 700;
    color: #b3d9ff;
    font-size: 0.9em;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.control-btn {
    padding: 10px 16px;
    border: 2px solid rgba(77, 166, 255, 0.3);
    background: rgba(77, 166, 255, 0.15);
    border-radius: 10px;
    cursor: pointer;
    font-size: 0.85em;
    font-weight: 700;
    color: #b3d9ff;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.control-btn:hover {
    border-color: rgba(77, 166, 255, 0.8);
    background: rgba(77, 166, 255, 0.25);
    box-shadow: 0 0 15px rgba(77, 166, 255, 0.3);
}

.control-btn.active {
    background: linear-gradient(135deg, #0066cc 0%, #004d99 100%);
    color: white;
    border-color: #0066cc;
    box-shadow: 0 0 20px rgba(0, 102, 204, 0.4);
}

.control-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.select-control {
    padding: 10px 14px;
    border: 2px solid rgba(77, 166, 255, 0.3);
    background: rgba(0, 20, 40, 0.6);
    border-radius: 10px;
    font-size: 0.85em;
    cursor: pointer;
}

/* ========== HISTORY STYLES ========== */
.history-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.history-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    background: rgba(99, 102, 241, 0.1);
    border: 1px solid rgba(99, 102, 241, 0.2);
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s;
}

.history-item:hover {
    background: rgba(99, 102, 241, 0.2);
    border-color: var(--cosmic-accent);
    transform: translateX(4px);
}

.history-index {
    font-weight: 700;
    color: var(--cosmic-accent-bright);
    min-width: 30px;
    text-align: center;
}

.history-title {
    flex: 1;
    color: var(--cosmic-text);
    font-weight: 500;
}

.history-date {
    color: var(--cosmic-text-muted);
    font-size: 0.85em;
}

/* ========== ERROR MESSAGE ========== */
.error-message {
    color: #f87171;
    background: rgba(248, 113, 113, 0.1);
    border: 1px solid rgba(248, 113, 113, 0.3);
    padding: 16px;
    border-radius: 8px;
    text-align: center;
    font-weight: 600;
}

.select-control:hover {
    border-color: rgba(77, 166, 255, 0.8);
    box-shadow: 0 0 15px rgba(77, 166, 255, 0.3);
}

.select-control:focus {
    outline: none;
    border-color: rgba(77, 166, 255, 0.8);
    box-shadow: 0 0 20px rgba(77, 166, 255, 0.4);
}

/* Spotlight carousel UI — mobile tweaks */
@media (max-width: 768px) {
    .spotlight-carousel-ui {
        margin-top: 14px;
        gap: 10px;
    }
    .spotlight-arrow {
        width: 34px;
        height: 34px;
        border-radius: 10px;
        font-size: 1.15rem;
    }
    .spotlight-dots {
        gap: 7px;
        padding: 5px 9px;
    }
    .spotlight-dot {
        width: 8px;
        height: 8px;
    }
}

/* ===== Melhorias mobile (telefone) ===== */
@media (max-width: 768px) {
    .home-hero {
        padding: 8px 0 16px;
    }
    .hero-tagline {
        font-size: 0.95rem;
    }

    .spotlight-section {
        padding: 18px;
        margin-bottom: 26px;
    }
    .spotlight-content {
        gap: 18px;
    }
    .spotlight-title {
        font-size: 1.55rem;
        margin-bottom: 12px;
    }
    .spotlight-meta {
        gap: 10px;
        margin-bottom: 14px;
    }
    .type-badge,
    .quality-badge {
        font-size: 0.75rem;
        padding: 5px 10px;
    }
    .duration,
    .release-date {
        font-size: 0.82rem;
    }
    .spotlight-description {
        font-size: 0.95rem;
        margin-bottom: 16px;
        display: -webkit-box;
        -webkit-line-clamp: 5;
        line-clamp: 5;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }
    .spotlight-actions {
        flex-direction: column;
        gap: 10px;
    }
    .watch-now-btn,
    .details-btn {
        width: 100%;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        padding: 12px 18px;
    }
    .spotlight-img {
        height: 220px;
    }
    .spotlight-placeholder {
        min-height: 220px;
    }
}

@media (max-width: 480px) {
    .top-navbar {
        padding: 10px 12px;
    }
    .navbar-brand {
        font-size: 1.35rem;
    }
    .navbar-center {
        margin-top: 8px;
    }
    .search-input {
        height: 40px;
        padding: 10px 12px;
        font-size: 0.95rem;
    }

    .main-wrapper {
        padding: 16px 12px;
    }

    .spotlight-section {
        padding: 16px;
        border-radius: 14px;
    }
    .spotlight-title {
        font-size: 1.4rem;
    }
    .spotlight-img {
        height: 200px;
    }
    .spotlight-placeholder {
        min-height: 200px;
    }

    .left-sidebar {
        width: min(320px, 86vw);
    }
    .sidebar-header {
        width: min(320px, 86vw);
    }
    .sidebar-content {
        padding: 16px;
        padding-top: 90px;
    }
}

/* ========== EPISODES ========== */
.episodes-section {
    margin: 20px 0;
}

.episodes-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
    gap: 8px;
    margin-bottom: 20px;
    max-height: 400px;
    overflow-y: auto;
    padding: 10px;
    background: rgba(15, 14, 26, 0.5);
    border-radius: 8px;
    border: 1px solid var(--cosmic-border);
}

.episodes-list::-webkit-scrollbar {
    width: 6px;
}

.episodes-list::-webkit-scrollbar-track {
    background: var(--cosmic-bg-elevated);
    border-radius: 3px;
}

.episodes-list::-webkit-scrollbar-thumb {
    background: var(--cosmic-accent);
    border-radius: 3px;
}

.episodes-list::-webkit-scrollbar-thumb:hover {
    background: var(--cosmic-accent-bright);
}

.episode-btn {
    background: var(--cosmic-bg-card);
    border: 1px solid var(--cosmic-border);
    color: var(--cosmic-text);
    padding: 8px 4px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.8rem;
    font-weight: 500;
    text-align: center;
    transition: all 0.3s ease;
    min-height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.episode-btn:hover {
    background: var(--cosmic-accent);
    border-color: var(--cosmic-accent);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
}

.episode-block {
    margin-bottom: 30px;
}

.episode-block h4 {
    color: var(--cosmic-accent-bright);
    margin-bottom: 15px;
    font-size: 1.1rem;
    font-weight: 600;
}

/* Responsive para episódios */
@media (max-width: 768px) {
    .episodes-list {
        grid-template-columns: repeat(auto-fill, minmax(60px, 1fr));
        gap: 6px;
        padding: 8px;
        max-height: 300px;
    }
    
    .episode-btn {
        font-size: 0.75rem;
        padding: 6px 3px;
        min-height: 35px;
    }
}

@media (max-width: 480px) {
    .episodes-list {
        grid-template-columns: repeat(auto-fill, minmax(50px, 1fr));
        gap: 4px;
    }
    
    .episode-btn {
        font-size: 0.7rem;
        padding: 5px 2px;
        min-height: 32px;
    }
}

/* ===== Banner de cookies ===== */
.cookie-banner {
    position: fixed;
    left: 1.5rem;
    right: 1.5rem;
    bottom: 1.5rem;
    z-index: 9999;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem 1rem;
    padding: 0.9rem 1.1rem;
    border-radius: 0.75rem;
    background: rgba(15, 23, 42, 0.96);
    border: 1px solid rgba(148, 163, 184, 0.4);
    box-shadow: 0 18px 45px rgba(15, 23, 42, 0.85);
    color: #e5e7eb;
    font-size: 0.85rem;
    transform: translateY(24px);
    opacity: 0;
    pointer-events: none;
    backdrop-filter: blur(14px);
    transition: opacity 0.25s ease, transform 0.25s ease;
}

.cookie-banner.active {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}

.cookie-text {
    flex: 1 1 220px;
    line-height: 1.5;
}

.cookie-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem;
}

.cookie-btn {
    border-radius: 999px;
    padding: 0.4rem 1.2rem;
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
    border: 1px solid transparent;
    background: transparent;
    color: #e5e7eb;
    transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease, transform 0.15s ease;
}

.cookie-btn.primary {
    background: linear-gradient(135deg, #6366f1, #a855f7);
    color: white;
    border-color: rgba(191, 219, 254, 0.6);
}

.cookie-btn.primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 8px 24px rgba(99, 102, 241, 0.45);
}

.cookie-btn:focus-visible {
    outline: 2px solid #e5e7eb;
    outline-offset: 2px;
}

.link-like {
    border: none;
    padding: 0;
    margin: 0 0.15rem;
    background: none;
    color: #a5b4fc;
    text-decoration: underline;
    cursor: pointer;
    font: inherit;
}

.link-like:hover {
    color: #c4b5fd;
}

@media (max-width: 640px) {
    .cookie-banner {
        left: 0.75rem;
        right: 0.75rem;
        bottom: 0.75rem;
        font-size: 0.8rem;
    }
}

/* Anime Details Page */
#animeDetails {
    padding-top: 20px;
    min-height: 80vh;
}

.details-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Mobile: increase container size */
@media (max-width: 768px) {
    .details-container {
        max-width: 100%;
        padding: 0;
        width: 100%;
    }
    
    #animeDetails {
        padding-top: 0;
        min-height: 100vh;
        width: 100%;
    }
    
    #animeDetails .main-content {
        padding: 0;
        width: 100%;
    }
}

/* Small mobile: full width */
@media (max-width: 480px) {
    .details-container {
        padding: 0;
        width: 100%;
    }
    
    #animeDetails {
        padding: 0;
    }
}

.back-btn {
    background: transparent;
    border: 1px solid var(--cosmic-border);
    color: var(--cosmic-text);
    padding: 10px 20px;
    border-radius: 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 20px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.back-btn:hover {
    background: var(--cosmic-accent);
    color: #fff;
    border-color: var(--cosmic-accent-bright);
}

.page-details {
    background: var(--cosmic-bg-card);
    border-radius: 16px;
    padding: 30px;
    border: 1px solid var(--cosmic-border);
}

.details-header-layout {
    display: flex;
    gap: 30px;
    margin-bottom: 30px;
}

.page-details .modal-image {
    width: 300px;
    height: auto;
    border-radius: 12px;
    object-fit: cover;
    box-shadow: 0 8px 24px rgba(0,0,0,0.3);
}

.details-info-content {
    flex: 1;
}

.page-details .modal-title {
    font-size: 2.5rem;
    margin-bottom: 15px;
    line-height: 1.2;
}

.page-details .modal-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin-bottom: 20px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--cosmic-border);
}

.page-details .modal-description {
    font-size: 1.1rem;
    line-height: 1.6;
    color: var(--cosmic-text-muted);
}

/* Responsive for Details */
@media (max-width: 768px) {
    .details-header-layout {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }
    
    .page-details .modal-image {
        width: 200px;
        margin-bottom: 20px;
    }

    .page-details .modal-meta {
        justify-content: center;
    }
}

#detailsFavoriteBtn {
    margin-top: 20px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 1rem;
    padding: 12px 24px;
}

/* Seasons Section */
.seasons-section {
    margin-top: 2rem;
    padding: 0 1rem;
}

.seasons-section h3 {
    font-size: 1.2rem;
    color: var(--cosmic-text);
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--cosmic-border);
}

.seasons-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 1rem;
}

.season-btn {
    background: var(--cosmic-bg-card);
    border: 1px solid var(--cosmic-border);
    border-radius: 8px;
    padding: 0;
    cursor: pointer;
    transition: all 0.3s ease;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    text-align: left;
    height: 100%;
}

.season-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.2);
    border-color: var(--cosmic-accent);
}

.season-btn.active {
    border-color: var(--cosmic-accent);
    box-shadow: 0 0 0 2px var(--cosmic-accent-bright);
}

.season-poster {
    width: 100%;
    height: 200px;
    background-size: cover;
    background-position: center;
    background-color: var(--cosmic-bg-elevated);
}

.season-info {
    padding: 0.8rem;
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
    background: rgba(0, 0, 0, 0.2);
    flex-grow: 1;
}

/* ========== COMMUNITY SECTION ========== */
.community-header {
    margin-bottom: 2rem;
}

.community-subtitle {
    color: var(--cosmic-text-muted);
    font-size: 1.1rem;
    margin-top: 0.5rem;
}

.community-tabs {
    display: flex;
    gap: 1rem;
    margin-bottom: 2rem;
    border-bottom: 2px solid var(--cosmic-border);
    padding-bottom: 0.5rem;
    flex-wrap: wrap;
}

.community-tab {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    background: transparent;
    border: 2px solid transparent;
    border-radius: 8px;
    color: var(--cosmic-text-muted);
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.community-tab:hover {
    color: var(--cosmic-text);
    background: rgba(99, 102, 241, 0.1);
}

.community-tab.active {
    color: var(--cosmic-accent-bright);
    border-color: var(--cosmic-accent);
    background: rgba(99, 102, 241, 0.15);
}

.community-content {
    min-height: 400px;
}

.community-panel {
    display: none;
    animation: fadeIn 0.3s ease;
}

.community-panel.active {
    display: block;
}

.community-actions {
    margin-bottom: 1.5rem;
    display: flex;
    justify-content: flex-end;
}

.community-btn-primary {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    background: linear-gradient(135deg, var(--cosmic-accent) 0%, var(--cosmic-cta) 100%);
    border: none;
    border-radius: 8px;
    color: white;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(99, 102, 241, 0.3);
}

.community-btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(99, 102, 241, 0.4);
}

/* Discussion Cards */
.discussions-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.discussion-card {
    background: var(--cosmic-bg-card);
    border: 1px solid var(--cosmic-border);
    border-radius: 12px;
    padding: 1.5rem;
    transition: all 0.3s ease;
    cursor: pointer;
}

.discussion-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(99, 102, 241, 0.15);
    border-color: var(--cosmic-accent);
}

.discussion-card.featured {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.1) 0%, var(--cosmic-bg-card) 100%);
    border-color: var(--cosmic-accent);
}

.discussion-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

.user-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--cosmic-accent) 0%, var(--cosmic-cta) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    color: white;
    font-size: 0.9rem;
}

.discussion-meta {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
    flex-grow: 1;
}

.username {
    font-weight: 600;
    color: var(--cosmic-text);
}

.time {
    font-size: 0.85rem;
    color: var(--cosmic-text-muted);
}

.discussion-tag {
    padding: 0.3rem 0.8rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
}

.discussion-tag.announcement {
    background: rgba(99, 102, 241, 0.2);
    color: var(--cosmic-accent-bright);
}

.discussion-title {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--cosmic-text);
    margin-bottom: 0.5rem;
}

.discussion-preview {
    color: var(--cosmic-text-muted);
    line-height: 1.6;
    margin-bottom: 1rem;
}

.discussion-stats {
    display: flex;
    gap: 1.5rem;
    color: var(--cosmic-text-muted);
    font-size: 0.9rem;
}

.discussion-stats span {
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

/* Recommendation Cards */
.recommendations-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.recommendation-card {
    background: var(--cosmic-bg-card);
    border: 1px solid var(--cosmic-border);
    border-radius: 12px;
    padding: 1.5rem;
    transition: all 0.3s ease;
}

.recommendation-card:hover {
    border-color: var(--cosmic-accent);
    box-shadow: 0 4px 15px rgba(99, 102, 241, 0.1);
}

.rec-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.rec-type {
    padding: 0.3rem 0.8rem;
    background: rgba(99, 102, 241, 0.2);
    color: var(--cosmic-accent-bright);
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
}

.rec-time {
    font-size: 0.85rem;
    color: var(--cosmic-text-muted);
}

.recommendation-card h3 {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--cosmic-text);
    margin-bottom: 0.5rem;
}

.recommendation-card > p {
    color: var(--cosmic-text-muted);
    margin-bottom: 1rem;
}

.rec-animes {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.rec-anime-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.75rem 1rem;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.rec-anime-item:hover {
    background: rgba(99, 102, 241, 0.15);
    transform: translateX(5px);
}

.rec-rank {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: var(--cosmic-accent);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    color: white;
    font-size: 0.9rem;
}

.rec-name {
    flex-grow: 1;
    font-weight: 600;
    color: var(--cosmic-text);
}

.rec-votes {
    font-size: 0.85rem;
    color: var(--cosmic-text-muted);
}

/* Review Cards */
.reviews-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.review-card {
    background: var(--cosmic-bg-card);
    border: 1px solid var(--cosmic-border);
    border-radius: 12px;
    padding: 1.5rem;
    transition: all 0.3s ease;
}

.review-card:hover {
    border-color: var(--cosmic-accent);
}

.review-anime {
    display: flex;
    gap: 1rem;
    margin-bottom: 1rem;
}

.review-poster {
    width: 80px;
    height: 120px;
    object-fit: cover;
    border-radius: 8px;
}

.review-info h4 {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--cosmic-text);
    margin-bottom: 0.5rem;
}

.review-rating {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.stars {
    color: #ffd700;
    font-size: 1rem;
}

.rating-value {
    font-weight: 600;
    color: var(--cosmic-accent-bright);
}

.review-text {
    color: var(--cosmic-text);
    line-height: 1.6;
    font-style: italic;
    margin-bottom: 1rem;
    padding-left: 1rem;
    border-left: 3px solid var(--cosmic-accent);
}

.review-author {
    display: flex;
    justify-content: space-between;
    font-size: 0.85rem;
    color: var(--cosmic-text-muted);
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 4rem 2rem;
    color: var(--cosmic-text-muted);
}

.empty-state h3 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--cosmic-text);
    margin: 1rem 0;
}

.empty-icon {
    font-size: 4rem;
    opacity: 0.5;
}

.explore-btn {
    margin-top: 1rem;
    padding: 0.75rem 1.5rem;
    background: var(--cosmic-accent);
    border: none;
    border-radius: 8px;
    color: white;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.explore-btn:hover {
    background: var(--cosmic-cta-hover);
    transform: translateY(-2px);
}

/* Mobile Responsive for Community */
@media (max-width: 768px) {
    .community-tabs {
        gap: 0.5rem;
    }
    
    .community-tab {
        padding: 0.5rem 1rem;
        font-size: 0.9rem;
    }
    
    .discussion-card,
    .recommendation-card,
    .review-card {
        padding: 1rem;
    }
    
    .discussion-title {
        font-size: 1.1rem;
    }
    
    .review-poster {
        width: 60px;
        height: 90px;
    }
    
    .rec-anime-item {
        padding: 0.5rem 0.75rem;
    }
}

.season-title {
    font-size: 0.9rem;
    color: var(--cosmic-text);
    font-weight: 500;
    line-height: 1.3;
}

.season-eps {
    font-size: 0.75rem;
    color: var(--cosmic-text-muted);
}

/* ========== PROFESSIONAL COMMUNITY - PROFILE & CHAT ========== */

/* Profile Bar in Community Header */
.community-profile-bar {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-top: 1rem;
    flex-wrap: wrap;
}

.community-user-badge {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    background: var(--cosmic-surface);
    border: 2px dashed var(--cosmic-border);
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.community-user-badge:hover {
    border-color: var(--cosmic-accent);
    background: var(--cosmic-card);
}

.community-user-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--cosmic-accent);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 600;
    font-size: 0.9rem;
    overflow: hidden;
}

.community-user-avatar.has-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.community-user-name {
    color: var(--cosmic-text);
    font-weight: 500;
    font-size: 0.9rem;
}

.community-chat-btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    background: linear-gradient(135deg, var(--cosmic-accent) 0%, var(--cosmic-purple) 100%);
    border: none;
    border-radius: 50px;
    color: white;
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.community-chat-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(99, 102, 241, 0.4);
}

.community-chat-btn .icon {
    width: 18px;
    height: 18px;
}

/* Profile Modal */
.profile-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.profile-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(4px);
}

.profile-card {
    position: relative;
    width: 90%;
    max-width: 400px;
    background: var(--cosmic-card);
    border: 1px solid var(--cosmic-border);
    border-radius: 16px;
    padding: 0;
    z-index: 2001;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.5);
    overflow: hidden;
}

.profile-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid var(--cosmic-border);
    background: var(--cosmic-surface);
}

.profile-header h3 {
    margin: 0;
    color: var(--cosmic-text);
    font-size: 1.25rem;
}

.profile-close {
    background: none;
    border: none;
    color: var(--cosmic-text-muted);
    font-size: 1.5rem;
    cursor: pointer;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.3s ease;
}

.profile-close:hover {
    background: var(--cosmic-border);
    color: var(--cosmic-text);
}

.profile-body {
    padding: 1.5rem;
}

.profile-avatar-section {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.profile-avatar-display {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    overflow: hidden;
    background: var(--cosmic-surface);
    border: 3px solid var(--cosmic-accent);
    display: flex;
    align-items: center;
    justify-content: center;
}

.profile-preview-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.profile-avatar-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--cosmic-accent);
}

.profile-photo-btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    background: var(--cosmic-surface);
    border: 1px solid var(--cosmic-border);
    border-radius: 8px;
    color: var(--cosmic-text);
    font-size: 0.85rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.profile-photo-btn:hover {
    background: var(--cosmic-card);
    border-color: var(--cosmic-accent);
}

.profile-photo-btn input {
    display: none;
}

.profile-form {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.profile-label {
    color: var(--cosmic-text);
    font-weight: 500;
    font-size: 0.9rem;
}

.profile-input {
    padding: 0.75rem 1rem;
    background: var(--cosmic-surface);
    border: 1px solid var(--cosmic-border);
    border-radius: 8px;
    color: var(--cosmic-text);
    font-size: 1rem;
    transition: all 0.3s ease;
}

.profile-input:focus {
    outline: none;
    border-color: var(--cosmic-accent);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.2);
}

.profile-hint {
    color: var(--cosmic-text-muted);
    font-size: 0.8rem;
    margin: 0;
}

.profile-save-btn {
    margin-top: 0.5rem;
    padding: 0.75rem 1.5rem;
    background: linear-gradient(135deg, var(--cosmic-accent) 0%, var(--cosmic-purple) 100%);
    border: none;
    border-radius: 8px;
    color: white;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.profile-save-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(99, 102, 241, 0.4);
}

/* Chat Modal */
.chat-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 2000;
    display: flex;
    align-items: flex-end;
    justify-content: flex-end;
    padding: 1rem;
}

.chat-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
}

.chat-container {
    position: relative;
    width: 100%;
    max-width: 400px;
    height: 500px;
    background: var(--cosmic-card);
    border: 1px solid var(--cosmic-border);
    border-radius: 16px;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.5);
    z-index: 2001;
}

.chat-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 1.25rem;
    background: linear-gradient(135deg, var(--cosmic-accent) 0%, var(--cosmic-purple) 100%);
    color: white;
}

.chat-title {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 600;
    font-size: 1rem;
}

.chat-title .icon {
    width: 20px;
    height: 20px;
}

.chat-close {
    background: none;
    border: none;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.3s ease;
}

.chat-close:hover {
    background: rgba(255, 255, 255, 0.2);
}

.chat-messages {
    flex: 1;
    overflow-y: auto;
    padding: 1rem;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.chat-welcome {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    color: var(--cosmic-text-muted);
    text-align: center;
}

.chat-welcome .icon {
    width: 48px;
    height: 48px;
    margin-bottom: 1rem;
    opacity: 0.5;
}

.chat-welcome p {
    margin: 0;
    font-size: 1rem;
}

.chat-welcome-sub {
    font-size: 0.85rem;
    opacity: 0.7;
}

.chat-message {
    display: flex;
    gap: 0.75rem;
    align-items: flex-start;
}

.chat-message-me {
    flex-direction: row-reverse;
}

.chat-message-me .chat-message-content {
    background: var(--cosmic-accent);
    color: white;
}

.chat-message-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--cosmic-surface);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    overflow: hidden;
    border: 2px solid var(--cosmic-border);
}

.chat-avatar-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.chat-avatar-text {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--cosmic-text);
}

.chat-message-content {
    background: var(--cosmic-surface);
    border-radius: 12px;
    padding: 0.75rem 1rem;
    max-width: 75%;
}

.chat-message-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.25rem;
}

.chat-author {
    font-weight: 600;
    font-size: 0.85rem;
}

.chat-time {
    font-size: 0.75rem;
    opacity: 0.7;
}

.chat-message-text {
    font-size: 0.95rem;
    line-height: 1.4;
    word-break: break-word;
}

.chat-input-area {
    display: flex;
    gap: 0.5rem;
    padding: 1rem;
    border-top: 1px solid var(--cosmic-border);
    background: var(--cosmic-surface);
}

.chat-input {
    flex: 1;
    padding: 0.75rem 1rem;
    background: var(--cosmic-card);
    border: 1px solid var(--cosmic-border);
    border-radius: 25px;
    color: var(--cosmic-text);
    font-size: 0.95rem;
    transition: all 0.3s ease;
}

.chat-input:focus {
    outline: none;
    border-color: var(--cosmic-accent);
}

.chat-send-btn {
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--cosmic-accent);
    border: none;
    border-radius: 50%;
    color: white;
    cursor: pointer;
    transition: all 0.3s ease;
}

.chat-send-btn:hover {
    background: var(--cosmic-cta-hover);
    transform: scale(1.05);
}

.chat-send-btn .icon {
    width: 20px;
    height: 20px;
}

/* Updated Community Cards */
.empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 3rem 2rem;
    color: var(--cosmic-text-muted);
    text-align: center;
}

.empty-state .icon {
    width: 64px;
    height: 64px;
    margin-bottom: 1rem;
    opacity: 0.3;
}

.empty-state h3 {
    margin: 0 0 0.5rem 0;
    color: var(--cosmic-text);
    font-size: 1.25rem;
}

.empty-state p {
    margin: 0;
    font-size: 0.95rem;
}

/* User Avatars in Cards */
.user-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--cosmic-surface);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    border: 2px solid var(--cosmic-border);
    flex-shrink: 0;
}

.user-avatar.small {
    width: 32px;
    height: 32px;
}

.user-avatar-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.user-avatar-text {
    font-size: 1rem;
    font-weight: 600;
    color: var(--cosmic-text);
}

/* Review Professional */
.review-card.professional {
    background: var(--cosmic-card);
    border: 1px solid var(--cosmic-border);
    border-radius: 12px;
    padding: 1.25rem;
}

.review-card.professional .review-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.review-card.professional .review-meta {
    display: flex;
    flex-direction: column;
}

.review-author-name {
    font-weight: 600;
    color: var(--cosmic-text);
}

.review-anime-title {
    font-size: 1.1rem;
    color: var(--cosmic-accent);
    margin: 0 0 0.5rem 0;
}

/* Recommendations Updated */
.rec-author {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.rec-genre {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    background: var(--cosmic-surface);
    border-radius: 20px;
    font-size: 0.8rem;
    color: var(--cosmic-text-muted);
}

.rec-responses {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--cosmic-border);
}

.rec-response {
    padding: 0.5rem 0;
    font-size: 0.9rem;
}

.rec-response-author {
    font-weight: 600;
    color: var(--cosmic-text);
}

.rec-response-text {
    color: var(--cosmic-text-muted);
}

.no-responses {
    color: var(--cosmic-text-muted);
    font-style: italic;
    font-size: 0.9rem;
    margin: 0;
}

.rec-reply-btn {
    margin-top: 1rem;
    padding: 0.5rem 1rem;
    background: var(--cosmic-surface);
    border: 1px solid var(--cosmic-border);
    border-radius: 8px;
    color: var(--cosmic-text);
    font-size: 0.85rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.rec-reply-btn:hover {
    background: var(--cosmic-accent);
    border-color: var(--cosmic-accent);
    color: white;
}

/* Mobile Responsive for New Elements */
@media (max-width: 768px) {
    .community-profile-bar {
        flex-direction: column;
        align-items: stretch;
        gap: 0.75rem;
    }
    
    .community-user-badge,
    .community-chat-btn {
        justify-content: center;
    }
    
    .chat-container {
        max-width: 100%;
        height: 70vh;
        border-radius: 16px 16px 0 0;
    }
    
    .chat-modal {
        padding: 0;
        align-items: flex-end;
    }
    
    .profile-card {
        width: 95%;
    }
}
