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

:root {
    --bg-dark: #050505;
    --card-bg: rgba(255, 255, 255, 0.03);
    --neon-blue: #00f2ff;
    --top-chart-blue: #0ea5e9;
    --blue-gradient: linear-gradient(135deg, #7dd3fc 0%, #0ea5e9 100%);
    --premium-shadow: 0 10px 40px rgba(0, 0, 0, 0.6);
}

body {
    background: var(--bg-dark);
    background-image:
        radial-gradient(circle at 50% -10%, rgba(0, 242, 255, 0.08) 0%, transparent 40%),
        radial-gradient(circle at 0% 100%, rgba(0, 242, 255, 0.05) 0%, transparent 30%);
    min-height: 100vh;
    color: white;
    font-family: 'Plus Jakarta Sans', sans-serif;
    overflow-x: hidden;
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
}

/* Glassmorphism Premium */
.glass-effect {
    background: var(--card-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.06);
    transition: all 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.channel-card {
    position: relative;
    width: 100%;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    perspective: 1000px;
}

.channel-card:hover {
    transform: translateY(-12px) rotateX(5deg) rotateY(2deg);
    border-color: var(--neon-blue);
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.5), 0 0 25px rgba(0, 242, 255, 0.15);
    background: rgba(255, 255, 255, 0.08);
}

.channel-card img {
    filter: drop-shadow(0 0 10px rgba(255, 255, 255, 0.1));
    transition: all 0.5s ease;
}

.channel-card:hover img {
    transform: scale(1.15) translateZ(20px);
    filter: drop-shadow(0 0 20px rgba(0, 242, 255, 0.3));
}

.active-channel {
    background: rgba(0, 242, 255, 0.08) !important;
    border-color: var(--neon-blue) !important;
    box-shadow: 0 0 30px rgba(0, 242, 255, 0.25);
}

/* Listener Badge Refined */
.listener-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(12px);
    padding: 6px 12px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    gap: 6px;
    border: 1px solid rgba(0, 242, 255, 0.2);
    z-index: 10;
    box-shadow: var(--premium-shadow);
}

.listener-icon {
    font-size: 8px;
    color: var(--neon-blue);
}

.listener-count-text {
    font-size: 10px;
    font-weight: 800;
    color: white;
}

/* Player Styling */
.player-glass {
    background: rgba(8, 8, 8, 0.9);
    backdrop-filter: blur(40px);
    -webkit-backdrop-filter: blur(40px);
    border: 1px solid rgba(0, 242, 255, 0.3);
    box-shadow: 0 -20px 50px rgba(0, 0, 0, 0.6);
    transition: all 0.4s ease;
}

.player-glass:hover {
    border-color: var(--neon-blue);
    box-shadow: 0 -10px 40px rgba(0, 242, 255, 0.2);
}

/* Performance and Animations */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: all 1s cubic-bezier(0.22, 1, 0.36, 1);
}

.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

.category-pill {
    background: rgba(255, 255, 255, 0.03);
    color: #71717a;
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: all 0.4s ease;
}

.category-pill.active {
    background: var(--blue-gradient);
    color: #ffffff;
    font-weight: 700;
    border-color: transparent;
    box-shadow: 0 5px 15px rgba(14, 165, 233, 0.3);
}

#visualizer-canvas {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    opacity: 0.4;
    pointer-events: none;
}

.hide-scrollbar::-webkit-scrollbar {
    display: none;
}

.hide-scrollbar {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

.volume-range {
    appearance: none;
    -webkit-appearance: none;
    width: 100%;
    height: 4px;
    background: rgba(0, 242, 255, 0.1);
    border-radius: 4px;
    outline: none;
}

.volume-range::-webkit-slider-thumb {
    appearance: none;
    -webkit-appearance: none;
    width: 14px;
    height: 14px;
    background: var(--neon-blue);
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 0 15px var(--neon-blue);
    transition: all 0.2s ease;
}

.volume-range::-webkit-slider-thumb:hover {
    transform: scale(1.3);
}

.blue-gradient-text {
    background: var(--blue-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    padding-right: 2px;
}

.chart-number {
    background: var(--blue-gradient);
    color: white;
    position: absolute;
    top: 5px;
    left: 5px;
    width: 32px;
    height: 32px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 900;
    font-size: 14px;
    z-index: 20;
    border: 2px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.5);
}

.top-card-glow {
    transition: all 0.5s cubic-bezier(0.23, 1, 0.32, 1);
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.top-card-glow:hover {
    border-color: rgba(0, 242, 255, 0.3);
    box-shadow: 0 0 30px rgba(0, 242, 255, 0.15), inset 0 0 20px rgba(0, 242, 255, 0.05);
    transform: translateY(-5px);
}

/* Histórico / Playlist Styles */
@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(20px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.history-item {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.03) 0%, rgba(255, 255, 255, 0.01) 100%);
    border: 1px solid rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(10px);
    transition: all 0.4s cubic-bezier(0.25, 1, 0.5, 1);
    animation: slideInRight 0.5s ease forwards;
    opacity: 0;
}

.history-item:hover {
    background: rgba(255, 255, 255, 0.07);
    border-color: rgba(0, 242, 255, 0.2);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    transform: scale(1.02) translateX(8px);
}

.history-time-badge {
    background: rgba(0, 242, 255, 0.1);
    color: var(--neon-blue);
    padding: 3px 10px;
    border-radius: 8px;
    font-size: 10px;
    font-weight: 900;
    text-shadow: 0 0 10px rgba(0, 242, 255, 0.5);
    border: 1px solid rgba(0, 242, 255, 0.2);
    box-shadow: inset 0 0 10px rgba(0, 242, 255, 0.05);
}

.history-img-container {
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.hero-title {
    font-size: clamp(2.5rem, 8vw, 6rem);
    line-height: 0.9;
    background: linear-gradient(to bottom, #fff 40%, rgba(255, 255, 255, 0.4));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

@keyframes pulse-neon {
    0% {
        box-shadow: 0 0 10px rgba(0, 242, 255, 0.2);
    }

    50% {
        box-shadow: 0 0 25px rgba(0, 242, 255, 0.5);
    }

    100% {
        box-shadow: 0 0 10px rgba(0, 242, 255, 0.2);
    }
}

.animate-neon {
    animation: pulse-neon 2s infinite;
}

@media (max-width: 640px) {
    .player-glass {
        border-radius: 2.5rem 2.5rem 0 0;
    }
}

/* PWA Install Banner - REFINADO E DISCRETO */
.install-banner {
    position: fixed !important;
    bottom: 30px !important;
    right: 30px !important;
    width: 320px !important;
    background: rgba(10, 10, 10, 0.95);
    backdrop-filter: blur(25px);
    -webkit-backdrop-filter: blur(25px);
    border: 1px solid rgba(0, 242, 255, 0.2);
    border-radius: 20px;
    padding: 15px;
    z-index: 9999;
    display: none;
    align-items: center;
    gap: 12px;
    box-shadow: 0 15px 40px rgba(0,0,0,0.8);
    transform: translateX(120%);
    transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.install-banner.show {
    display: flex !important;
    transform: translateX(0);
}

.install-logo {
    width: 40px !important;
    height: 40px !important;
    border-radius: 10px;
    object-fit: cover !important;
    border: 1px solid rgba(255,255,255,0.1);
}

.install-btn {
    background: var(--blue-gradient);
    color: white;
    font-weight: 800;
    padding: 8px 16px;
    border-radius: 10px;
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 0 5px 15px rgba(14, 165, 233, 0.3);
}

@media (max-width: 768px) {
    .install-banner {
        left: 15px !important;
        right: 15px !important;
        bottom: 110px !important;
        width: auto !important;
    }

/* Oculta o banner se já estiver instalado (Standalone) */
@media (display-mode: standalone) {
    .install-banner {
        display: none !important;
        visibility: hidden !important;
        opacity: 0 !important;
        pointer-events: none !important;
    }
}
}