/* ==========================================================================
           RM SOFT — Arquitetura Visual Inspirada em Plataformas de Streaming
           Zero Gradientes de IA • Superfícies Sólidas (#000000 / #121212 / #181818)
           ========================================================================== */
html {
    scroll-behavior: smooth;
    background-color: #000000;
    color: #FFFFFF;
}

body {
    background-color: #000000;
    overflow-x: hidden;
}

/* Scrollbar minimalista estilo Desktop App */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: #000000;
}

::-webkit-scrollbar-thumb {
    background: #282828;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #535353;
}

/* Microinteração do botão Play nos Cards (Assinatura visual de catálogo) */
.catalog-card {
    background-color: #181818;
    transition: background-color 0.25s ease, transform 0.25s ease, border-color 0.25s ease;
}

.catalog-card:hover {
    background-color: #282828;
    transform: translateY(-4px);
}

.catalog-card.is-selected {
    background-color: #242424;
    border-color: #FFFFFF;
}

.play-action-btn {
    opacity: 0;
    transform: translateY(8px);
    transition: opacity 0.22s ease, transform 0.22s ease, background-color 0.15s ease;
}

.catalog-card:hover .play-action-btn,
.catalog-card.is-selected .play-action-btn {
    opacity: 1;
    transform: translateY(0);
}

/* Linha de Tracklist interativa */
.track-row {
    transition: background-color 0.15s ease;
}

.track-row:hover {
    background-color: #242424;
}

/* Padrão arquitetônico técnico discreto (sem blur ou gradiente) */
.tech-grid-pattern {
    background-image: radial-gradient(#262626 1px, transparent 1px);
    background-size: 20px 20px;
}

/* Safe Area iOS para barra inferior fixa */
aside[aria-label="Inspeção rápida de sistema"] {
    padding-bottom: calc(0.75rem + env(safe-area-inset-bottom, 0px));
}

/* ==========================================================================
   CARROSSEL INFINITO MOBILE (Auto-scroll suave + Arrastar com dedo/mouse)
   Ativo abaixo de 1024px (mobile/tablet); no desktop mantém o grid padrão.
   ========================================================================== */
@media (max-width: 1023px) {
    .infinite-carousel-mobile {
        display: flex !important;
        flex-wrap: nowrap !important;
        overflow-x: auto !important;
        gap: 1rem !important;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        -ms-overflow-style: none;
        cursor: grab;
        user-select: none;
        padding-bottom: 4px;
    }

    .infinite-carousel-mobile::-webkit-scrollbar {
        display: none;
    }

    .infinite-carousel-mobile.is-dragging {
        cursor: grabbing;
    }

    .infinite-carousel-mobile>* {
        flex: 0 0 82vw;
        max-width: 310px;
    }

    /* Quando filtrado para poucos itens, volta ao layout normal sem rolagem infinita */
    .infinite-carousel-mobile.is-filtered {
        display: grid !important;
        grid-template-columns: 1fr;
        overflow-x: visible !important;
        cursor: default;
        user-select: auto;
    }

    .infinite-carousel-mobile.is-filtered>* {
        flex: none;
        max-width: none;
    }
}