:root {
    --bg-dark: #0b0c10;
    --card-bg: #1f2833;
    --text-main: #c5c6c7;
    --text-bright: #ffffff;
    --neon-cyan: #00d2ff;
    --neon-magenta: #ff004c;
    --font-heading: 'Outfit', sans-serif;
    --font-body: 'Inter', sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; -webkit-tap-highlight-color: transparent; }

body {
    font-family: var(--font-body);
    background-color: var(--bg-dark);
    color: var(--text-main);
    display: flex;
    flex-direction: column;
    height: 100dvh; /* Mobile viewport fix */
    overflow: hidden;
}

/* Header */
.app-header {
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 20px;
    background: rgba(31, 40, 51, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255,255,255,0.05);
    z-index: 10;
}
.logo { font-family: var(--font-heading); font-weight: 800; font-size: 1.2rem; color: var(--text-bright); }
.logo-accent { color: var(--neon-cyan); text-shadow: 0 0 5px rgba(0,210,255,0.5); }
.btn-icon { background: none; border: none; color: var(--text-bright); width: 40px; height: 40px; display: flex; align-items: center; justify-content: center; border-radius: 50%; }
.btn-icon svg { width: 20px; height: 20px; }
.btn-icon.active { color: var(--neon-magenta); }

/* LED Marquee */
.led-marquee {
    background: #050505;
    border: 1px solid rgba(255,145,0,0.15);
    border-radius: 12px;
    padding: 10px 0;
    overflow: hidden;
    position: relative;
    background-image: radial-gradient(rgba(255,145,0,0.12) 1px, transparent 1.4px);
    background-size: 7px 7px;
    box-shadow: inset 0 0 12px rgba(0,0,0,0.8);
}
.led-marquee-track {
    display: flex;
    width: max-content;
    animation: led-scroll 16s linear infinite;
}
.led-marquee-track span {
    font-family: 'Courier New', monospace;
    font-weight: 800;
    font-size: 0.95rem;
    letter-spacing: 3px;
    white-space: nowrap;
    color: #ffb100;
    text-shadow: 0 0 4px #ffb100, 0 0 10px #ff7300, 0 0 18px #ff4d00;
}
@keyframes led-scroll {
    from { transform: translateX(0); }
    to { transform: translateX(-50%); }
}

/* Main Content */
.app-content {
    flex-grow: 1;
    overflow-y: auto;
    padding: 20px;
    padding-bottom: 80px; /* Space for bottom nav */
}

.view-section { display: none; flex-direction: column; gap: 20px; }
.view-section.active { display: flex; animation: slideUp 0.4s cubic-bezier(0.16, 1, 0.3, 1) forwards; }
@keyframes slideUp { 
    from { opacity: 0; transform: translateY(20px); } 
    to { opacity: 1; transform: translateY(0); } 
}

.view-title { font-family: var(--font-heading); font-weight: 800; font-size: 1.8rem; color: var(--text-bright); animation: slideRight 0.5s ease-out forwards; }
@keyframes slideRight {
    from { opacity: 0; transform: translateX(-15px); }
    to { opacity: 1; transform: translateX(0); }
}

/* Neon animated border (used on hero-image sections) */
@property --neon-angle {
    syntax: '<angle>';
    initial-value: 0deg;
    inherits: false;
}
.neon-border-anim { position: relative; z-index: 0; }
.neon-border-anim::before,
.neon-border-anim::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
    padding: 2px;
    background: conic-gradient(from var(--neon-angle), var(--neon-cyan), var(--neon-magenta), var(--neon-cyan));
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    animation: neon-rotate 4s linear infinite;
}
.neon-border-anim::before { z-index: -1; }
.neon-border-anim::after {
    z-index: -2;
    padding: 4px;
    filter: blur(10px);
    opacity: 0.85;
}
@keyframes neon-rotate {
    to { --neon-angle: 360deg; }
}

/* Live Hero */
.live-hero {
    background: linear-gradient(rgba(0,0,0,0.6), rgba(0,0,0,0.8)), url('../assets/hero.png') center/cover;
    border-radius: 16px;
    padding: 24px 20px 0 20px;
    height: 560px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    border: 1px solid rgba(255,255,255,0.05);
}

/* Chat overlaid on the live-hero background image */
.hero-chat-overlay {
    flex-grow: 1;
    width: calc(100% + 40px);
    margin: 15px -20px 0 -20px;
    border: none;
    display: block;
}
.live-badge { background: var(--neon-magenta); color: #fff; padding: 4px 12px; border-radius: 20px; font-size: 0.75rem; font-weight: 700; display: flex; align-items: center; gap: 6px; box-shadow: 0 0 10px rgba(255,0,76,0.4); margin-bottom: 20px; }
.pulse-dot { width: 6px; height: 6px; background: #fff; border-radius: 50%; animation: pulse 1s infinite; }
@keyframes pulse { 0% {opacity:1} 50% {opacity:0.3} 100% {opacity:1} }

.btn-play-huge {
    width: 80px; height: 80px; border-radius: 50%;
    background: var(--neon-cyan); border: none; color: #000;
    display: flex; align-items: center; justify-content: center;
    box-shadow: 0 0 20px rgba(0,210,255,0.4);
    margin-bottom: 15px; cursor: pointer; transition: transform 0.2s;
}
.btn-play-huge:active { transform: scale(0.95); }
.btn-play-huge svg { width: 40px; height: 40px; margin-left: 5px; }
.btn-play-huge .icon-pause { margin-left: 0; }

.live-hero p { font-size: 0.85rem; color: rgba(255,255,255,0.8); }

/* Now Playing strip: nombre de la pista actual del Auto DJ */
.now-playing-strip {
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
    margin-top: 12px;
    padding: 8px 14px;
    border-radius: 20px;
    background: rgba(0, 0, 0, 0.55);
    border: 1px solid rgba(0, 210, 255, 0.25);
    opacity: 0;
    transform: translateY(-4px);
    transition: opacity 0.4s ease, transform 0.4s ease;
    pointer-events: none;
}

.now-playing-strip.active {
    opacity: 1;
    transform: translateY(0);
}

.now-playing-icon {
    color: var(--neon-cyan);
    flex-shrink: 0;
}

.now-playing-marquee {
    flex: 1;
    min-width: 0;
    overflow: hidden;
    position: relative;
}

.now-playing-text {
    display: inline-block;
    font-family: 'Orbitron', var(--font-heading), sans-serif;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #fff;
    text-shadow: 0 0 8px rgba(0, 210, 255, 0.7), 0 2px 6px rgba(0, 0, 0, 0.9);
    white-space: nowrap;
    vertical-align: top;
    padding-left: 100%;
    animation: now-playing-marquee 14s linear infinite;
}

@keyframes now-playing-marquee {
    from { transform: translateX(0); }
    to { transform: translateX(-100%); }
}

/* Audio visualizer bars */
.audio-bars {
    display: flex;
    align-items: flex-end;
    justify-content: center;
    gap: 4px;
    height: 55px;
    align-self: stretch;
    margin: 15px -20px;
    padding: 0 16px;
}
.audio-bars span {
    display: block;
    flex: 1;
    max-width: 14px;
    height: 10px;
    border-radius: 3px;
    background: var(--neon-cyan);
    box-shadow: 0 0 6px rgba(0,210,255,0.6);
    transition: height 0.2s ease;
}
.audio-bars span:nth-child(2n) {
    background: var(--neon-magenta);
    box-shadow: 0 0 6px rgba(255,0,76,0.6);
}
.live-hero.is-playing .audio-bars span { animation: bar-bounce 0.9s ease-in-out infinite; }
.live-hero.is-playing .audio-bars span:nth-child(1) { animation-delay: -0.6s; }
.live-hero.is-playing .audio-bars span:nth-child(2) { animation-delay: -0.3s; }
.live-hero.is-playing .audio-bars span:nth-child(3) { animation-delay: -0.9s; }
.live-hero.is-playing .audio-bars span:nth-child(4) { animation-delay: -0.15s; }
.live-hero.is-playing .audio-bars span:nth-child(5) { animation-delay: -0.45s; }
.live-hero.is-playing .audio-bars span:nth-child(6) { animation-delay: -0.75s; }
.live-hero.is-playing .audio-bars span:nth-child(7) { animation-delay: -0.2s; }
.live-hero.is-playing .audio-bars span:nth-child(8) { animation-delay: -0.5s; }
.live-hero.is-playing .audio-bars span:nth-child(9) { animation-delay: -0.8s; }
.live-hero.is-playing .audio-bars span:nth-child(10) { animation-delay: -0.35s; }
@keyframes bar-bounce {
    0%, 100% { height: 10px; }
    50% { height: 50px; }
}

/* Cards */
.card { background: var(--card-bg); border-radius: 12px; padding: 15px; border: 1px solid rgba(255,255,255,0.05); transition: transform 0.2s ease, box-shadow 0.2s ease; }
.card:active { transform: scale(0.98); box-shadow: 0 0 10px rgba(0,210,255,0.2); }
.card h3 { font-family: var(--font-heading); font-size: 1.1rem; color: var(--text-bright); margin-bottom: 10px; }

/* Countdown */
.countdown { display: flex; justify-content: center; gap: 15px; text-align: center; }
.countdown div { display: flex; flex-direction: column; }
.countdown span { font-size: 1.8rem; font-family: var(--font-heading); font-weight: 800; color: var(--neon-magenta); }
.countdown small { font-size: 0.65rem; color: var(--text-main); }

/* Mixes */
.banner-pendrive { background: linear-gradient(45deg, #1f2833, rgba(0,210,255,0.2)); border-radius: 12px; padding: 15px; display: flex; align-items: center; justify-content: space-between; border: 1px solid var(--neon-cyan); transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275); }
.banner-pendrive:active { transform: scale(0.95); }
.banner-text h3 { font-family: var(--font-heading); color: var(--neon-cyan); margin-bottom: 4px; font-size: 1.1rem; }
.banner-text p { font-size: 0.8rem; text-shadow: 1px 1px 3px rgba(0,0,0,0.8); color: #fff; }
.btn-small { background: var(--neon-cyan); color: #000; padding: 8px 15px; border-radius: 20px; text-decoration: none; font-size: 0.85rem; font-weight: 600; transition: transform 0.2s; display: inline-block; }
.btn-small:active { transform: scale(0.9); }

.mix-list { display: flex; flex-direction: column; gap: 10px; }
.mix-empty { color: var(--text-main); font-size: 0.9rem; text-align: center; padding: 20px 0; }
.mix-item.playing { background: rgba(0,210,255,0.08); }
.mix-item { background: rgba(255,255,255,0.03); border-radius: 8px; padding: 10px; display: flex; align-items: center; gap: 12px; transition: background 0.3s; }
.mix-item:active { background: rgba(255,255,255,0.08); }
.mix-img { width: 50px; height: 50px; background: #333; border-radius: 6px; object-fit: cover; }
.mix-info { flex-grow: 1; }
.mix-info h4 { color: var(--text-bright); font-size: 0.95rem; margin-bottom: 2px; }
.mix-info span { font-size: 0.75rem; color: var(--text-main); }

/* Mundial */
.mundial-list { display: flex; flex-direction: column; gap: 12px; }
.match-item { background: rgba(255,255,255,0.03); border-radius: 8px; padding: 12px; }
.match-item.live { background: rgba(255,0,76,0.08); border: 1px solid rgba(255,0,76,0.3); }
.match-teams { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.match-team { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 6px; text-align: center; }
.match-team img { width: 32px; height: 32px; object-fit: contain; }
.match-team span { font-size: 0.75rem; color: var(--text-bright); }
.match-mid { flex: 0 0 auto; min-width: 60px; text-align: center; font-family: var(--font-heading); }
.match-score { display: block; font-size: 1.1rem; font-weight: 800; color: var(--text-bright); }
.match-status { display: block; font-size: 0.65rem; color: var(--neon-magenta); font-weight: 700; }
.match-meta { margin-top: 8px; font-size: 0.7rem; color: var(--text-main); text-align: center; }

/* Events */
.event-card { display: flex; flex-direction: row; gap: 15px; align-items: center; }
.event-date { background: rgba(255,0,76,0.1); color: var(--neon-magenta); width: 60px; height: 60px; border-radius: 10px; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.event-date span { font-size: 1.4rem; font-weight: 800; font-family: var(--font-heading); line-height: 1; }
.event-date small { font-size: 0.7rem; font-weight: 600; text-transform: uppercase; }
.event-details h4 { color: var(--text-bright); font-size: 1.05rem; }
.event-details p { font-size: 0.8rem; color: var(--text-main); }

.booking-card { text-align: center; }
.btn-primary { display: inline-block; background: var(--neon-cyan); color: #000; padding: 12px 24px; border-radius: 8px; text-decoration: none; font-weight: 600; width: 100%; box-shadow: 0 0 10px rgba(0,210,255,0.3); }

/* Bottom Navigation */
.bottom-nav {
    position: fixed;
    bottom: 0; left: 0; right: 0;
    height: 65px;
    background: rgba(11, 12, 16, 0.95);
    backdrop-filter: blur(10px);
    border-top: 1px solid rgba(255,255,255,0.05);
    display: flex;
    justify-content: space-around;
    align-items: center;
    padding-bottom: env(safe-area-inset-bottom);
    z-index: 100;
}
.nav-item {
    background: none; border: none;
    display: flex; flex-direction: column; align-items: center; gap: 4px;
    color: var(--text-main); cursor: pointer;
    width: 25%;
    transition: color 0.3s ease;
}
.nav-item svg { width: 24px; height: 24px; stroke: currentColor; stroke-width: 2; transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275); }
.nav-item span { font-size: 0.65rem; font-weight: 500; }
.nav-item.active { color: var(--neon-cyan); }
.nav-item.active svg { filter: drop-shadow(0 0 5px rgba(0,210,255,0.5)); transform: translateY(-4px) scale(1.1); }
