:root {
    --cobalto-pizarra-oscuro: #090d16;
    --cobalto-hud-card: #121824;
    --cobalto-vivo: #1a66ff; /* Reemplazo definitivo del celeste por cobalto eléctrico */
    --amarillo-oro-alerta: #ffcc00;
    --text-white: #ffffff;
    --text-muted: rgba(255, 255, 255, 0.45);
    --glass-border: rgba(255, 255, 255, 0.05);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

body {
    background-color: var(--cobalto-pizarra-oscuro);
    color: var(--text-white);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    min-height: 100vh;
    padding: 24px 16px;
    overflow-x: hidden;
    overflow-y: auto;
    position: relative;
}

/* CAPA ATMOSFÉRICA DE FONDO */
.ambient-fluid-bg {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    background: radial-gradient(circle at 50% 0%, #0f1624 0%, var(--cobalto-pizarra-oscuro) 100%);
    z-index: 1;
    pointer-events: none;
}

.glow-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(120px);
    mix-blend-mode: screen;
}

.orb-cobalt-dark {
    width: 600px;
    height: 600px;
    background: #0d172a;
    top: -10%;
    left: -10%;
    opacity: 0.85;
}

.orb-cobalt-glow {
    width: 400px;
    height: 400px;
    background: rgba(26, 102, 255, 0.12);
    bottom: 10%;
    right: -5%;
}

/* AJUSTE LOGO EXTERNO: Evita distorsiones y renderiza de forma limpia */
.external-logo-container {
    z-index: 3;
    width: 100%;
    max-width: 390px;
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 24px;
    padding: 0 10px;
}

.external-main-logo {
    max-width: 100%;
    height: auto;
    max-height: 55px;
    object-fit: contain;
    filter: drop-shadow(0 4px 12px rgba(0,0,0,0.5));
}

/* ENTORNO HUD CONTENEDOR */
.player-wrapper {
    width: 100%;
    max-width: 390px;
    background: var(--cobalto-hud-card);
    border-radius: 32px;
    border: 1px solid var(--glass-border);
    padding: 24px 20px 85px;
    display: flex;
    flex-direction: column;
    gap: 20px;
    z-index: 2;
    box-shadow: 0 30px 70px rgba(0, 0, 0, 0.8);
    position: relative;
}

/* NAVEGACIÓN SUPERIOR TABS */
.hud-top-navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.nav-icon-side {
    background: none;
    border: none;
    color: var(--text-white);
    font-size: 18px;
    cursor: pointer;
}

.tab-toggle-container {
    background: #070a10;
    padding: 3px;
    border-radius: 20px;
    display: flex;
    gap: 2px;
}

.tab-toggle-btn {
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 11px;
    font-weight: 700;
    padding: 6px 16px;
    border-radius: 16px;
    cursor: pointer;
    transition: all 0.2s ease;
    letter-spacing: 0.5px;
}

/* Comportamiento cromático cobalto/oro de la referencia */
.tab-toggle-btn#btn-tab-onair.active {
    background: var(--cobalto-vivo);
    color: #fff;
    font-weight: 800;
    box-shadow: 0 2px 8px rgba(26, 102, 255, 0.4);
}

.tab-toggle-btn#btn-tab-revista.active {
    background: var(--amarillo-oro-alerta);
    color: #000;
    font-weight: 800;
    box-shadow: 0 2px 8px rgba(255, 204, 0, 0.4);
}

.hud-view-section {
    display: none;
    flex-direction: column;
    gap: 20px;
}

.hud-view-section.active {
    display: flex;
}

.upper-status-hud {
    text-align: left;
}

.hud-status-tag {
    font-size: 9px;
    font-weight: 700;
    color: var(--text-muted);
    letter-spacing: 1.5px;
}

#hud-top-track-artist {
    font-size: 15px;
    font-weight: 500;
    margin-top: 2px;
}

/* MARCO DE NEÓN GRUESO EN AZUL COBALTO VIVO */
.main-neon-display-card {
    width: 100%;
    aspect-ratio: 1 / 1;
    background: #06090f;
    border-radius: 24px;
    position: relative;
    overflow: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
    border: 3px solid var(--cobalto-vivo); /* Borde grueso cobalto eléctrico */
    box-shadow: 
        0 0 25px rgba(26, 102, 255, 0.45), 
        inset 0 0 20px rgba(26, 102, 255, 0.25);
}

/* Ondas del Visualizador */
.visualizer-overlay {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    width: 100%;
    height: 100%;
    position: absolute;
    padding: 0 24px;
}

.v-bar {
    flex: 1;
    max-width: 6px;
    height: 20px;
    background: linear-gradient(180deg, #ff007f 0%, var(--cobalto-vivo) 100%);
    border-radius: 10px;
}

.v-bar.animate {
    animation: hudWave 0.6s ease-in-out infinite alternate;
}

.v-bar:nth-child(2n) { animation-duration: 0.45s; animation-delay: 0.12s; }
.v-bar:nth-child(3n+1) { animation-duration: 0.7s; animation-delay: 0.25s; }

@keyframes hudWave {
    0% { height: 12px; }
    100% { height: 160px; }
}

/* AdMob Panel */
.admob-intercalated-zone {
    position: absolute;
    width: 95%;
    height: 95%;
    background: #06090f;
    border-radius: 16px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.5s ease;
}

.admob-intercalated-zone.active {
    opacity: 1;
    pointer-events: auto;
}

.ad-tag {
    font-size: 8px;
    font-weight: 700;
    color: var(--text-muted);
    border: 1px solid rgba(255,255,255,0.1);
    padding: 2px 6px;
    border-radius: 4px;
    margin-bottom: 8px;
}

.ad-placeholder {
    color: #fff;
    font-size: 13px;
}

/* 5 BOTONES CIRCULARES AMARILLO ORO */
.gold-circles-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.gold-circle-btn {
    background: none;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: 2px solid var(--amarillo-oro-alerta);
    color: var(--amarillo-oro-alerta);
    font-size: 15px;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: all 0.15s ease;
}

.gold-circle-btn:active {
    transform: scale(0.9);
    background: rgba(255, 204, 0, 0.15);
}

#like-btn.liked {
    background: #ff2d55;
    border-color: #ff2d55;
    color: #fff;
    box-shadow: 0 0 12px rgba(255, 45, 85, 0.5);
}

/* BOTÓN ANCHO COBALTO */
.full-playlist-action-btn {
    width: 100%;
    background: var(--cobalto-vivo);
    color: #fff;
    border: none;
    padding: 13px;
    border-radius: 25px;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 0.8px;
    cursor: pointer;
    box-shadow: 0 5px 15px rgba(26, 102, 255, 0.35);
}

/* VISTA REVISTA EDITORIAL */
.editorial-scroll-container {
    display: flex;
    flex-direction: column;
    gap: 12px;
    max-height: 440px;
    overflow-y: auto;
}

.editorial-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.04);
    border-radius: 14px;
    padding: 14px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
}

.editorial-card-text {
    flex: 1;
    text-align: left;
}

.editorial-card-text h3 {
    font-size: 14px;
    font-weight: 700;
    color: #fff;
}

.editorial-card-text p {
    font-size: 11.5px;
    color: var(--text-muted);
    margin-top: 4px;
    line-height: 1.3;
}

.editorial-card-thumb {
    width: 48px;
    height: 48px;
    border-radius: 8px;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 16px;
    color: #fff;
}

.gradient-monvil { background: linear-gradient(135deg, #ff007f, #7928ca); }
.gradient-movil { background: linear-gradient(135deg, #ff9f1c, #ff5400); }
.gradient-moonshot { background: linear-gradient(135deg, #222, #000); border: 1px solid rgba(255,255,255,0.08); }
.gradient-ai { background: linear-gradient(135deg, #091324, #040812); }

/* BARRA DE AUDIO INFERIOR */
.persistent-base-player {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 75px;
    background: #060a12;
    border-top: 1px solid var(--glass-border);
    border-radius: 0 0 32px 32px;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 10;
}

.base-track-details {
    text-align: left;
    max-width: 45%;
}

.base-meta-tag {
    font-size: 8px;
    font-weight: 700;
    color: var(--cobalto-vivo);
    letter-spacing: 0.5px;
}

#base-track-title {
    font-size: 12.5px;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-top: 1px;
}

.base-player-controls {
    display: flex;
    align-items: center;
    gap: 12px;
}

.hud-precision-volume {
    -webkit-appearance: none;
    width: 70px;
    height: 4px;
    background: rgba(255, 255, 255, 0.15);
    border-radius: 2px;
    outline: none;
}

.hud-precision-volume::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #fff;
    cursor: pointer;
}

.base-play-trigger {
    background: #fff;
    border: none;
    color: #000;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    font-size: 13px;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
}

.base-secondary-trigger {
    background: none;
    border: none;
    color: var(--text-white);
    font-size: 15px;
    cursor: pointer;
}