:root {
    --primary: #00f2ff; /* Cyan Vivid */
    --secondary: #7000ff; /* Purple Vivid */
    --dark-bg: #0f172a;
    --glass: rgba(255, 255, 255, 0.05);
    --glass-border: rgba(255, 255, 255, 0.1);
    --text-main: #ffffff;
    --text-muted: #94a3b8;
}

* { box-sizing: border-box; margin: 0; padding: 0; font-family: 'Montserrat', sans-serif; }

body {
    background-color: var(--dark-bg);
    color: var(--text-main);
    min-height: 100vh;
    display: flex;
    justify-content: center;
    overflow-x: hidden;
}

/* VIVID BACKGROUND */
.bg-gradient {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background: radial-gradient(circle at 10% 20%, #1e1b4b 0%, #0f172a 90%);
    z-index: -2;
}
.bg-orb {
    position: fixed;
    border-radius: 50%;
    filter: blur(80px);
    z-index: -1;
    animation: float 10s infinite ease-in-out;
}
.orb-1 { width: 300px; height: 300px; background: var(--secondary); top: -50px; left: -50px; opacity: 0.4; }
.orb-2 { width: 400px; height: 400px; background: #0077ff; bottom: -100px; right: -100px; opacity: 0.3; animation-delay: -5s; }

@keyframes float {
    0%, 100% { transform: translate(0, 0); }
    50% { transform: translate(30px, 50px); }
}

/* APP CONTAINER */
.app-container {
    width: 100%;
    max-width: 500px; /* Compact Mobile-First Width */
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

/* HEADER */
.compact-header { text-align: center; margin-top: 20px; }
.artist-badge {
    display: inline-block;
    font-size: 0.7rem;
    letter-spacing: 3px;
    color: var(--primary);
    border: 1px solid var(--primary);
    padding: 5px 10px;
    border-radius: 20px;
    margin-bottom: 10px;
    text-transform: uppercase;
}
.album-title { font-size: 2rem; font-weight: 700; text-shadow: 0 0 20px rgba(0, 242, 255, 0.3); }
.album-subtitle { font-size: 0.9rem; color: var(--text-muted); font-style: italic; }

/* PLAYER CARD */
.player-card {
    background: var(--glass);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    padding: 25px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.4);
    text-align: center;
}

/* VISUALIZER & COVER */
.visualizer-container {
    position: relative;
    height: 180px;
    width: 100%;
    margin-bottom: 20px;
    display: flex;
    justify-content: center;
    align-items: center;
}
#visualizer {
    position: absolute;
    width: 100%;
    height: 100%;
    z-index: 1;
    opacity: 0.6;
}
.cover-art-wrapper {
    position: relative;
    z-index: 2;
    width: 140px;
    height: 140px;
    border-radius: 50%;
    box-shadow: 0 0 30px rgba(0, 242, 255, 0.2);
    border: 4px solid rgba(255,255,255,0.1);
    overflow: hidden;
}
.cover-art { width: 100%; height: 100%; object-fit: cover; animation: spin 15s linear infinite; animation-play-state: paused; }
.play-overlay {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0,0,0,0.3);
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 2rem;
    opacity: 0;
    transition: 0.3s;
}
.cover-art-wrapper:hover .play-overlay { opacity: 1; }

@keyframes spin { 100% { transform: rotate(360deg); } }

/* INFO & PROGRESS */
.track-info-box h2 { font-size: 1.2rem; margin-bottom: 5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.meta-data { font-size: 0.8rem; color: var(--text-muted); }
.dot-sep { margin: 0 5px; }

.progress-area {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.75rem;
    color: var(--text-muted);
    margin: 15px 0;
}
.progress-bar-bg {
    flex-grow: 1;
    height: 6px;
    background: rgba(255,255,255,0.1);
    border-radius: 3px;
    cursor: pointer;
    position: relative;
}
.progress-bar-fill {
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, var(--secondary), var(--primary));
    border-radius: 3px;
    transition: width 0.1s linear;
}

/* CONTROLS */
.controls-wrapper {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    margin-bottom: 20px;
}
.ctrl-btn {
    background: none;
    border: none;
    color: var(--text-main);
    font-size: 1.2rem;
    cursor: pointer;
    transition: 0.2s;
    opacity: 0.8;
}
.ctrl-btn:hover { opacity: 1; color: var(--primary); transform: scale(1.1); }
.main-play {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--secondary), var(--primary));
    color: white;
    font-size: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 10px 20px rgba(0, 242, 255, 0.3);
}
.main-play:hover { transform: scale(1.05); opacity: 1; }

/* BOTTOM ACTIONS */
.bottom-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid var(--glass-border);
    padding-top: 15px;
}
.volume-slider { display: flex; align-items: center; gap: 10px; font-size: 0.9rem; }
#volume-bar { width: 80px; accent-color: var(--primary); }
.action-buttons { display: flex; gap: 15px; }
.icon-btn { background: none; border: none; color: var(--text-muted); cursor: pointer; font-size: 1.1rem; transition: 0.2s; }
.icon-btn:hover { color: var(--primary); }

/* PLAYLIST */
.playlist-section {
    background: var(--glass);
    border-radius: 20px;
    padding: 20px;
    border: 1px solid var(--glass-border);
}
.section-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 15px; }
.section-header h3 { font-size: 1.1rem; }
.badge { background: var(--secondary); font-size: 0.7rem; padding: 3px 8px; border-radius: 10px; }
.tracklist-scroll {
    max-height: 250px;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: var(--primary) transparent;
}
.tracklist-scroll li {
    display: flex;
    justify-content: space-between;
    padding: 12px;
    border-bottom: 1px solid rgba(255,255,255,0.05);
    cursor: pointer;
    transition: 0.2s;
    font-size: 0.9rem;
}
.tracklist-scroll li:hover { background: rgba(255,255,255,0.05); padding-left: 15px; }
.tracklist-scroll li.playing { color: var(--primary); border-left: 3px solid var(--primary); background: rgba(0, 242, 255, 0.05); }

/* GUESTBOOK */
.guestbook-section { margin-top: 10px; }
.guestbook-section h3 { font-size: 1rem; margin-bottom: 10px; color: var(--text-muted); }
#guestbook-form input, #guestbook-form textarea {
    width: 100%;
    background: rgba(0,0,0,0.3);
    border: 1px solid var(--glass-border);
    padding: 12px;
    margin-bottom: 10px;
    border-radius: 10px;
    color: white;
    font-family: inherit;
}
#guestbook-form button {
    width: 100%;
    padding: 12px;
    background: var(--primary);
    color: #000;
    font-weight: bold;
    border: none;
    border-radius: 10px;
    cursor: pointer;
}
.guest-entry { background: rgba(255,255,255,0.03); padding: 10px; border-radius: 8px; margin-bottom: 8px; font-size: 0.85rem; }
.guest-entry strong { color: var(--primary); }

/* MODAL */
.modal { display: none; position: fixed; z-index: 100; left: 0; top: 0; width: 100%; height: 100%; background: rgba(0,0,0,0.8); backdrop-filter: blur(5px); }
.modal-content {
    background: #1e293b;
    margin: 15% auto;
    padding: 25px;
    border: 1px solid var(--primary);
    width: 90%;
    max-width: 400px;
    border-radius: 15px;
    position: relative;
    box-shadow: 0 0 30px rgba(0, 242, 255, 0.2);
}
.close-modal { position: absolute; right: 20px; top: 15px; font-size: 24px; cursor: pointer; color: var(--text-muted); }
.lyrics-body { white-space: pre-wrap; line-height: 1.6; color: #cbd5e1; max-height: 60vh; overflow-y: auto; margin-top: 15px; }

/* RESPONSIVE */
@media (max-width: 400px) {
    .album-title { font-size: 1.5rem; }
    .cover-art-wrapper { width: 120px; height: 120px; }
    .ctrl-btn { font-size: 1rem; }
    .main-play { width: 50px; height: 50px; }
}