/* ============================================
   PLAYER DE RÁDIO FIXO
   Sempre visível no rodapé da página
   ============================================ */

.radio-player-fixed {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    width: 100%;
    background: linear-gradient(135deg, var(--radio-primary, #FF8C00) 0%, var(--radio-secondary, #FFA500) 100%);
    box-shadow: 0 -5px 20px rgba(0, 0, 0, 0.3);
    z-index: 9999;
    padding: 15px 0;
    transition: transform 0.3s ease;
}

/* Garantir que está sempre visível */
.radio-player-fixed {
    transform: translateY(0) !important;
}

/* Container do player */
.radio-player-fixed .container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

/* Conteúdo do player */
.player-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    width: 100%;
}

/* ============================================
   CONTROLES
   ============================================ */
.player-controls {
    flex-shrink: 0;
}

.btn-play {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: white;
    color: var(--radio-primary, #FF8C00);
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.btn-play:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.3);
}

.btn-play:active {
    transform: scale(0.95);
}

.btn-play i {
    margin-left: 3px; /* Centralizar ícone play */
}

/* ============================================
   INFORMAÇÕES
   ============================================ */
.player-info {
    flex: 1;
    min-width: 0;
    margin-right: 10px;
}

.player-status {
    margin-bottom: 5px;
}

.status-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    background: rgba(255, 255, 255, 0.2);
    color: white;
    backdrop-filter: blur(10px);
}

.status-badge i {
    font-size: 0.85rem;
    animation: pulse-icon 2s infinite;
}

@keyframes pulse-icon {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.status-loading {
    background: rgba(255, 255, 255, 0.3);
}

.status-live {
    background: rgba(50, 205, 50, 0.3);
}

.status-error {
    background: rgba(239, 68, 68, 0.3);
}

.player-now-playing {
    color: white;
}

.now-playing-title {
    font-size: 1.1rem;
    font-weight: 700;
    margin: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
    display: block;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.2);
}

.now-playing-subtitle {
    font-size: 0.9rem;
    margin: 0;
    opacity: 0.9;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
    display: block;
}

/* ============================================
   VOLUME
   ============================================ */
.player-volume {
    position: relative;
    display: flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
}

.btn-volume {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    color: white;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    cursor: pointer;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.btn-volume:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: scale(1.1);
}

.btn-volume:active {
    transform: scale(0.95);
}

/* ============================================
   RESPONSIVIDADE
   ============================================ */

/* Tablet (768px - 992px) */
@media (max-width: 992px) {
    .player-content {
        gap: 15px;
    }
    
    .btn-play {
        width: 55px;
        height: 55px;
        font-size: 1.8rem;
    }
    
    .btn-volume {
        width: 42px;
        height: 42px;
        font-size: 1.2rem;
    }
    
    .now-playing-title {
        font-size: 1rem;
    }
    
    .now-playing-subtitle {
        font-size: 0.85rem;
    }
}

/* Mobile (< 768px) */
@media (max-width: 768px) {
    .radio-player-fixed {
        padding: 12px 0;
    }
    
    .player-content {
        gap: 10px;
        flex-wrap: nowrap;
    }
    
    .btn-play {
        width: 50px;
        height: 50px;
        font-size: 1.6rem;
    }
    
    .btn-volume {
        width: 40px;
        height: 40px;
        font-size: 1.1rem;
    }
    
    .player-info {
        margin-right: 5px;
        flex: 1;
        min-width: 0;
    }
    
    .now-playing-title {
        font-size: 0.95rem;
    }
    
    .now-playing-subtitle {
        font-size: 0.8rem;
    }
    
    .status-badge {
        font-size: 0.7rem;
        padding: 3px 10px;
    }
}

/* Mobile pequeno (< 576px) */
@media (max-width: 576px) {
    .radio-player-fixed {
        padding: 10px 0;
    }
    
    .player-content {
        gap: 8px;
    }
    
    .btn-play {
        width: 45px;
        height: 45px;
        font-size: 1.4rem;
    }
    
    .btn-volume {
        width: 38px;
        height: 38px;
        font-size: 1rem;
    }
    
    .now-playing-title {
        font-size: 0.9rem;
    }
    
    .now-playing-subtitle {
        font-size: 0.75rem;
    }
    
    .status-badge {
        font-size: 0.65rem;
        padding: 2px 8px;
    }
}

/* Mobile muito pequeno (< 360px) */
@media (max-width: 360px) {
    .btn-play {
        width: 42px;
        height: 42px;
        font-size: 1.3rem;
    }
    
    .btn-volume {
        width: 36px;
        height: 36px;
        font-size: 0.95rem;
    }
    
    .now-playing-title {
        font-size: 0.85rem;
    }
    
    .now-playing-subtitle {
        font-size: 0.7rem;
    }
}

/* ============================================
   ANIMAÇÕES
   ============================================ */
@keyframes slideUp {
    from {
        transform: translateY(100%);
    }
    to {
        transform: translateY(0);
    }
}

.radio-player-fixed {
    animation: slideUp 0.3s ease-out;
}

/* Pulse para ícone ao vivo */
@keyframes pulse-live {
    0%, 100% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.1);
        opacity: 0.8;
    }
}

.status-live i {
    animation: pulse-live 1.5s infinite;
}

/* ============================================
   CORREÇÃO: Aviso de Deprecação do Plyr
   Remove 'appearance: slider-vertical' deprecado
   ============================================ */

/* Sobrescrever CSS do Plyr para remover slider-vertical */
.plyr input[type="range"] {
    -webkit-appearance: none !important;
    -moz-appearance: none !important;
    appearance: none !important;
}

/* Estilo customizado para slider horizontal (volume) */
.plyr__volume input[type="range"] {
    -webkit-appearance: none !important;
    -moz-appearance: none !important;
    appearance: none !important;
    background: transparent;
    cursor: pointer;
}

/* Track do slider (fundo) */
.plyr__volume input[type="range"]::-webkit-slider-runnable-track {
    width: 100%;
    height: 4px;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 2px;
}

.plyr__volume input[type="range"]::-moz-range-track {
    width: 100%;
    height: 4px;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 2px;
}

/* Thumb do slider (bolinha) */
.plyr__volume input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 12px;
    height: 12px;
    background: white;
    border-radius: 50%;
    cursor: pointer;
    margin-top: -4px;
}

.plyr__volume input[type="range"]::-moz-range-thumb {
    width: 12px;
    height: 12px;
    background: white;
    border-radius: 50%;
    cursor: pointer;
    border: none;
}

/* Hover states */
.plyr__volume input[type="range"]:hover::-webkit-slider-thumb {
    transform: scale(1.2);
}

.plyr__volume input[type="range"]:hover::-moz-range-thumb {
    transform: scale(1.2);
}

/* Focus states */
.plyr__volume input[type="range"]:focus {
    outline: none;
}

.plyr__volume input[type="range"]:focus::-webkit-slider-thumb {
    box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.3);
}

.plyr__volume input[type="range"]:focus::-moz-range-thumb {
    box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.3);
}

/* Remover qualquer orientação vertical (deprecada) */
input[type="range"][orient="vertical"] {
    -webkit-appearance: none !important;
    -moz-appearance: none !important;
    appearance: none !important;
    writing-mode: vertical-lr;
    direction: rtl;
}

/* Garantir que todos os sliders do Plyr usem o novo estilo */
.plyr__controls input[type="range"] {
    -webkit-appearance: none !important;
    -moz-appearance: none !important;
    appearance: none !important;
}

/* Progress bar (barra de progresso) */
.plyr__progress input[type="range"] {
    -webkit-appearance: none !important;
    -moz-appearance: none !important;
    appearance: none !important;
}

.plyr__progress input[type="range"]::-webkit-slider-runnable-track {
    height: 4px;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 2px;
}

.plyr__progress input[type="range"]::-moz-range-track {
    height: 4px;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 2px;
}

.plyr__progress input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 12px;
    height: 12px;
    background: white;
    border-radius: 50%;
    margin-top: -4px;
}

.plyr__progress input[type="range"]::-moz-range-thumb {
    width: 12px;
    height: 12px;
    background: white;
    border-radius: 50%;
    border: none;
}
