/* radio-handler-v10.css */

/* BLOCO 0: Layout Base e Grid */
.radio-page-layout {
    display: grid;
    grid-template-columns: 1fr 280px;
    gap: 24px;
    align-items: start;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.radio-main-col {
    min-width: 0;
}

.radio-sidebar {
    position: sticky;
    top: 80px;
    align-self: start;
}

/* BLOCO 1: Header da Rádio */
.player-header {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 10px 30px rgba(15, 23, 42, 0.04);
    margin-bottom: 24px;
    position: relative;
}

.radio-info-main {
    display: flex;
    gap: 30px;
    align-items: flex-start;
}

.logo-container {
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
}

.radio-logo-large {
    width: 138px;
    height: 138px;
    border-radius: 20px;
    object-fit: cover;
    box-shadow: 0 8px 20px rgba(0,0,0,0.08);
}

.radio-details {
    flex: 1;
    min-width: 0;
}

.radio-header-content {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    position: relative;
    margin-bottom: 20px;
    min-height: 100px;
}

.player-header .radio-details h1 {
    font-size: clamp(24px, 4vw, 36px);
    font-weight: 900;
    color: #0f172a;
    margin: 0 0 8px;
    line-height: 1.1;
}

.radio-slogan {
    font-size: 15px;
    color: #64748b;
    margin: 0 0 12px;
    font-weight: 500;
    line-height: 1.4;
}

/* Redes Sociais e Estrelas */
.radio-header-side-wrap {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    padding-left: 16px;
    border-left: 1px solid #f1f5f9;
    margin-left: 16px;
    min-height: 120px;
}

.radio-social-sidebar {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.social-btn {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    text-decoration: none;
    transition: all 0.2s;
    font-size: 14px;
    border: none;
    cursor: pointer;
}
.social-btn:hover { transform: translateY(-2px); opacity: 0.9; }
.social-btn.facebook { background: #1877f2; }
.social-btn.instagram { background: linear-gradient(45deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%); }
.social-btn.twitter { background: #000; }
.social-btn.whatsapp { background: #25d366; }
.social-btn.youtube { background: #ff0000; }

/* Avaliação Vertical */
.rating-sidebar-box {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
}

.star-rating {
    display: flex;
    flex-direction: column; /* Estrelas uma sob a outra */
    gap: 0px;
    align-items: center;
}

.star-rating input { display: none; }
.star-rating label {
    color: #cbd5e1;
    cursor: pointer;
    transition: 0.2s;
    font-size: 16px;
    line-height: 1;
    padding: 0;
    margin: 0;
}
.star-rating label:hover,
.star-rating label:hover ~ label,
.star-rating input:checked ~ label {
    color: #fbbf24;
}

#avg-rating-sidebar {
    display: block;
    font-size: 16px;
    font-weight: 900;
    color: #1e293b;
    margin-top: 2px;
    line-height: 1;
}

/* Info Grid */
.radio-info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 12px;
    margin-top: 20px;
}

.info-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    background: #f8fafc;
    border-radius: 12px;
    border: 1px solid #f1f5f9;
}

.info-item i {
    color: #6366f1;
    font-size: 16px;
}

.info-label {
    display: block;
    font-size: 10px;
    font-weight: 800;
    color: #94a3b8;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.info-value {
    display: block;
    font-size: 13px;
    font-weight: 700;
    color: #334155;
}

/* BLOCO 2: Player Box */
.player-box {
    background: #1e293b;
    border-radius: 18px;
    padding: 20px 24px;
    color: #fff;
    box-shadow: 0 12px 40px rgba(0,0,0,0.15);
    margin-bottom: 24px;
    border: 1px solid rgba(255,255,255,0.05);
}

.player-controls {
    display: flex;
    align-items: center;
    gap: 20px;
}

.player-controls > .btn-control,
.player-controls > .volume-control,
.player-controls > [style*="volume-control"],
.player-controls > [style*="theme-selector"] {
    flex-shrink: 0;
}

.btn-control {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: #fff;
    border: none;
    color: #1e293b;
    font-size: 22px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: 0.2s;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}
.btn-control:hover { transform: scale(1.05); background: #f8fafc; }

.now-playing-meta-box {
    display: flex;
    align-items: center;
    gap: 15px;
    flex: 1;
    min-width: 0;
    max-width: 100%;
    overflow: hidden;
}

.now-playing-meta-img {
    width: 50px;
    height: 50px;
    min-width: 50px;
    flex: 0 0 50px;
    border-radius: 10px;
    object-fit: cover;
    background: #334155;
}

.now-playing-meta-text {
    display: flex;
    flex-direction: column;
    min-width: 0;
    flex: 1 1 auto;
    max-width: 100%;
    overflow: hidden;
}

.now-playing-meta-artist {
    display: block;
    font-size: 14px;
    font-weight: 800;
    color: #fff;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
}

.now-playing-meta-track {
    display: block;
    font-size: 12px;
    color: #94a3b8;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
}

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

.volume-control i { color: #94a3b8; font-size: 14px; cursor: pointer; }
.volume-control input[type="range"] {
    width: 60px;
    accent-color: #6366f1;
    cursor: pointer;
}

/* BLOCO 3: Outros Componentes */
.compact-broadcast-box {
    display: flex;
    align-items: center;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 14px;
    padding: 8px 14px;
    margin-top: 10px;
    transition: all 0.2s ease;
    cursor: pointer;
    text-decoration: none !important;
    width: 100%;
}

.radio-rich-section {
    margin-top: 24px;
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 18px;
    padding: 24px;
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.04);
}

.genre-tag {
    background: #f1f5f9 !important;
    color: #475569 !important;
    font-weight: 700 !important;
    font-size: 12px !important;
    padding: 4px 12px !important;
    border-radius: 999px !important;
    text-decoration: none !important;
    display: inline-block;
    margin-right: 6px;
    margin-bottom: 6px;
    transition: 0.2s;
}
.genre-tag:hover { background: #e2e8f0 !important; color: #1e293b !important; }

/* ── MODO ESCURO ── */
body.dark-mode { background-color: #0f172a !important; }

body.dark-mode .player-header,
body.dark-mode .radio-rich-section,
body.dark-mode .radio-sidebar-card,
body.dark-mode #playlist-history-container,
body.dark-mode .comment-card,
body.dark-mode .comment-form {
    border-color: #e2e8f0 !important;
}
body.dark-mode .radio-card-small h4 {
    color: #1e293b !important;
}
body.dark-mode .radio-card-small p {
    color: #64748b !important;
}

/* ── Contextos editoriais no dark mode ── */
body.dark-mode .listen-moment-tab {
    background: #1e293b !important;
    border-color: #334155 !important;
    color: #cbd5e1 !important;
}
body.dark-mode .listen-moment-tab.active {
    color: #fff !important;
}
body.dark-mode .listen-moment-card {
    background: #ffffff !important;
    border-color: #e2e8f0 !important;
}
body.dark-mode .listen-moment-radios {
    background: linear-gradient(180deg, #f8fafc, #ffffff) !important;
}
body.dark-mode .listen-moment-radio {
    background: #ffffff !important;
    border-color: #e2e8f0 !important;
}
body.dark-mode .listen-moment-radio strong {
    color: #0f172a !important;
}
body.dark-mode .listen-moment-radio span {
    color: #64748b !important;
}

/* ── Popup de endereço ── */
body.dark-mode .radio-address-pop {
    background: #ffffff;
    border-color: #e2e8f0;
    color: #334155;
    box-shadow: 0 18px 42px rgba(0, 0, 0, 0.15);
}
body.dark-mode .radio-address-pop strong {
    color: #0f172a;
}

/* ── Modal de programação ── */
body.dark-mode .radio-program-modal-subtitle,
body.dark-mode .radio-program-day p,
body.dark-mode .radio-program-host {
    color: #cbd5e1;
}
body.dark-mode .radio-program-modal-dialog,
body.dark-mode .radio-program-day,
body.dark-mode .radio-program-panel {
    background: #0f172a;
    border-color: rgba(51, 65, 85, 0.86);
}
body.dark-mode .radio-program-modal-header {
    border-bottom-color: rgba(51, 65, 85, 0.86);
    background: linear-gradient(180deg, rgba(15, 23, 42, 0.98) 0%, rgba(15, 23, 42, 0.92) 100%);
}
body.dark-mode .radio-program-modal-title,
body.dark-mode .radio-program-day strong,
body.dark-mode .radio-program-name {
    color: #f8fafc;
}
body.dark-mode .radio-program-item {
    border-top-color: rgba(51, 65, 85, 0.7);
}
body.dark-mode .radio-program-tab {
    background: rgba(30, 41, 59, 0.94);
    border-color: rgba(51, 65, 85, 0.86);
    color: #cbd5e1;
}
body.dark-mode .radio-program-tab.is-active,
body.dark-mode .radio-program-tab[aria-selected="true"] {
    background: #2563eb;
    border-color: #2563eb;
    color: #ffffff;
}
body.dark-mode .radio-program-modal-close {
    background: rgba(51, 65, 85, 0.95);
    color: #f8fafc;
}

/* Dark mode sidebar specifically */
body.dark-mode .radio-sidebar-card {
    background: #ffffff !important;
    border-color: #e2e8f0 !important;
}
body.dark-mode .radio-sidebar-title {
    color: #0f172a !important;
}
body.dark-mode .radio-sidebar-item {
    background: #fafbfc !important;
    border-color: #f1f5f9 !important;
}
body.dark-mode .radio-sidebar-item:hover {
    background: #eff6ff !important;
}
body.dark-mode .radio-sidebar-item-name {
    color: #0f172a !important;
}
body.dark-mode .radio-sidebar-item-city {
    color: #64748b !important;
}

/* NOTIFICAÇÃO FLUTUANTE DE FEEDBACK */
.floating-cta { position: fixed; bottom: 85px; right: 20px; z-index: 9999; transition: 0.5s; pointer-events: auto; }
.floating-cta.hide { opacity: 0; transform: translateY(100px); pointer-events: none; }
.cta-card { background: #1e293b; border: 2px solid #6366f1; border-radius: 15px; padding: 15px 20px; display: flex; align-items: center; gap: 15px; box-shadow: 0 10px 25px rgba(0,0,0,0.5); animation: popUp 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275); }
.cta-icon { background: #6366f1; width: 35px; height: 35px; border-radius: 50%; display: flex; align-items: center; justify-content: center; color: #fff; font-size: 16px; animation: glow 2s infinite; }
.cta-text { color: #fff; font-size: 13px; max-width: 180px; line-height: 1.3; }
.cta-close-btn { background: none; border: none; color: #94a3b8; font-size: 24px; cursor: pointer; margin-left: 10px; line-height: 1; }
@keyframes popUp { from { transform: scale(0.5) translateY(100px); opacity: 0; } to { transform: scale(1) translateY(0); opacity: 1; } }
@keyframes glow { 0% { box-shadow: 0 0 0 0 rgba(99, 102, 241, 0.7); } 70% { box-shadow: 0 0 0 10px rgba(99, 102, 241, 0); } 100% { box-shadow: 0 0 0 0 rgba(99, 102, 241, 0); } }

/* CORREÇÕES DE VISIBILIDADE E COMPARTILHAMENTO */
.radio-details h1 { color: #0f172a !important; text-shadow: none !important; }
.radio-slogan { color: #475569 !important; }
