/* 
 * Toscano Radio Pro - Main CSS Refactor
 * Resolviendo problemas de diseño, menú y ticker
 */

:root {
    --primary: #6366f1;
    --primary-glow: rgba(99, 102, 241, 0.4);
    --bg-dark: #050507;
    --bg-card: #0c0c0e;
    --text-main: #ffffff;
    --text-dim: #94a3b8;
    --border: rgba(255, 255, 255, 0.08);
    --header-h: 80px;
}

/* Base Layout Fixes */
body {
    background: var(--bg-dark);
    color: var(--text-main);
    overflow-x: hidden;
}

.content-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
}

.flex-between {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* Top Bar & Ticker */
.top-bar {
    background: #000;
    height: 36px;
    border-bottom: 1px solid var(--border);
    font-size: 13px;
    overflow: hidden;
}

.news-ticker {
    display: flex;
    align-items: center;
    width: 100%;
    height: 100%;
}

.ticker-label {
    background: var(--primary);
    padding: 0 15px;
    height: 100%;
    display: flex;
    align-items: center;
    font-weight: 800;
    text-transform: uppercase;
    font-size: 11px;
    white-space: nowrap;
    position: relative;
    z-index: 10;
}

.ticker-wrapper {
    flex: 1;
    overflow: hidden;
    position: relative;
}

.ticker-scroll {
    display: flex;
    white-space: nowrap;
    animation: tickerLoop 40s linear infinite;
    gap: 40px;
    padding-left: 20px;
}

@keyframes tickerLoop {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(-50%);
    }
}

.ticker-item {
    color: var(--text-dim);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: color 0.3s;
}

.ticker-item:hover {
    color: var(--primary);
}

.ticker-dot {
    width: 5px;
    height: 5px;
    background: var(--primary);
    border-radius: 50%;
}

/* Header & Menu */
.site-header {
    height: var(--header-h);
    background: rgba(5, 5, 7, 0.95);
    backdrop-filter: blur(15px);
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-inner {
    display: flex;
    align-items: center;
    height: 100%;
    justify-content: space-between;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 30px;
}

.nav-menu a {
    color: var(--text-dim);
    text-decoration: none;
    font-weight: 600;
    font-size: 15px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: all 0.3s;
}

.nav-menu a:hover,
.nav-menu .current-menu-item a {
    color: var(--primary);
}

/* Navigation Mobile */
.mobile-toggle-btn {
    display: none;
    flex-direction: column;
    gap: 6px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 10px;
}

.mobile-toggle-btn span {
    width: 25px;
    height: 2px;
    background: white;
    transition: 0.3s;
}

@media (max-width: 1024px) {
    .mobile-toggle-btn {
        display: flex;
    }

    .main-navigation {
        position: fixed;
        top: 0;
        right: -101%;
        width: 300px;
        height: 100vh;
        background: var(--bg-card);
        z-index: 2000;
        transition: 0.4s cubic-bezier(0.4, 0, 0.2, 1);
        padding: 40px 20px;
        box-shadow: -10px 0 30px rgba(0, 0, 0, 0.5);
    }

    .main-navigation.active {
        right: 0;
    }

    .nav-menu {
        flex-direction: column;
        gap: 20px;
    }

    .nav-menu a {
        font-size: 18px;
    }

    .mobile-nav-header {
        display: flex;
        justify-content: space-between;
        align-items: center;
        margin-bottom: 40px;
        border-bottom: 1px solid var(--border);
        padding-bottom: 20px;
    }

    .close-menu-btn {
        background: none;
        border: none;
        color: white;
        font-size: 24px;
        cursor: pointer;
    }
}

/* Home Section Fix */
.home-hero {
    height: 60vh;
    min-height: 450px;
    position: relative;
    display: flex;
    align-items: center;
    overflow: hidden;
}

.news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 25px;
    margin-bottom: 50px;
}

/* Ocultar listados interminables (Categorías y Tags) */
.infinite-list-block {
    display: none;
    /* Esto se activará en áreas específicas si se desea */
}

/* Player Refactor */
.audio-player {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 90px;
    background: rgba(12, 12, 14, 0.98);
    backdrop-filter: blur(20px);
    border-top: 1px solid var(--border);
    z-index: 9999;
}

.player-inner {
    display: grid;
    grid-template-columns: 300px 1fr 300px;
    height: 100%;
    align-items: center;
}

.track-info {
    display: flex;
    align-items: center;
    gap: 15px;
}

.track-artwork {
    width: 55px;
    height: 55px;
    border-radius: 8px;
    overflow: hidden;
    background: var(--primary);
}

.track-artwork img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.track-name {
    font-weight: 700;
    font-size: 14px;
    display: block;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.track-artist {
    font-size: 12px;
    color: var(--text-dim);
}

.player-controls {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

.play-btn {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: white;
    color: black;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    cursor: pointer;
    transition: 0.3s;
}

.play-btn:hover {
    transform: scale(1.1);
    background: var(--primary);
    color: white;
}

.progress-container {
    width: 100%;
    max-width: 600px;
    height: 4px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 2px;
}

.progress-bar {
    height: 100%;
    background: var(--primary);
    width: 0%;
    border-radius: 2px;
}

@media (max-width: 768px) {
    .player-inner {
        grid-template-columns: 1fr 80px;
    }

    .player-actions,
    .track-artist {
        display: none;
    }

    .audio-player {
        height: 70px;
    }
}