:root {
    --bg-color: #0d0d0d;
    --card-bg: rgba(15, 10, 10, 0.95); /* Even darker with a red tint */
    --primary-color: #ff2400; /* Blood Orange / Intense Fire Red */
    --secondary-color: #e62b1e; /* Deeper Fire Red */
    --accent-silver: #eceff1;
    --text-primary: #ffffff;
    --text-secondary: rgba(255, 255, 255, 0.7);
    --accent-glow: radial-gradient(circle, rgba(230, 43, 30, 0.3) 0%, rgba(255, 36, 0, 0.1) 70%, transparent 100%);
    --gradient-linear: linear-gradient(135deg, var(--primary-color), #ff6a00); /* Fire gradient */
}

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

body {
    font-family: 'Outfit', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-primary);
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    overflow: hidden;
}

.background-glow {
    position: fixed;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: var(--accent-glow);
    z-index: -1;
    filter: blur(80px);
}

.container {
    width: 100%;
    max-width: 420px;
    height: 95vh;
    max-height: 850px;
    background: var(--card-bg);
    border-radius: 40px;
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.5);
    display: flex;
    flex-direction: column;
    padding: 15px 25px 25px 25px; /* Reduced top padding */
    position: relative;
    overflow: hidden;
}

header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 5px; /* Significantly reduced margin */
    padding: 5px 0;
}

.header-center {
    display: flex;
    justify-content: center;
    align-items: center;
}

.brand-logo {
    height: 40px;
    width: auto;
    filter: drop-shadow(0 0 5px rgba(230, 43, 30, 0.5));

}

.header-right {
    display: flex;
    gap: 10px;
}

.icon-btn {
    background: none;
    border: none;
    color: white;
    font-size: 18px;
    cursor: pointer;
    transition: transform 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.icon-btn:hover {
    transform: scale(1.1);
}

.icon-btn.small {
    font-size: 16px;
    color: var(--text-secondary);
}

.player-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-around;
}

.album-art-container {
    position: relative;
    width: 280px; /* Reduced from 320 to save vertical space */
    height: 280px;
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 10px 0; /* Reduced margin */
}

.progress-ring {
    position: absolute;
    width: 100%;
    height: 100%;
    transform: rotate(-90deg);
}

.album-art {
    width: 220px; /* Slightly smaller logo to lift design */
    height: 220px;
    z-index: 2;
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: transform 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.album-art.logo-focus {
    border-radius: 0; /* Remove container circle to allow logo shape */
    border: none;
    box-shadow: none;
}

.album-art img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    filter: drop-shadow(0 15px 40px rgba(230, 43, 30, 0.6));

}

.album-art:hover {
    transform: scale(1.05);
}

.volume-side-controls {
    position: absolute;
    width: 120%;
    height: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    pointer-events: none; /* Keep container non-blocking but buttons interactive below */
}

.volume-btn {
    background: none;
    border: none;
    color: var(--text-secondary);
    font-size: 18px;
    cursor: pointer;
    transition: 0.3s ease;
    pointer-events: auto; /* Allow clicks on buttons only */
}

.volume-btn:hover {
    color: var(--secondary-color);
    transform: scale(1.2);
}

.volume-btn:active {
    transform: scale(0.9);
}

.track-info {
    text-align: center;
    width: 100%;
}

.plays-count {
    font-size: 11px; /* Smaller font to save space */
    color: var(--text-secondary);
    margin-bottom: 4px; /* Reduced gap */
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
}

.track-info h1 {
    font-size: 20px; /* Smaller title to lift layout */
    font-weight: 700;
    margin-bottom: 2px;
    letter-spacing: -0.5px;
}

.track-info p {
    font-size: 15px;
    color: var(--text-secondary);
    margin-bottom: 10px; /* Reduced margin */
}

.track-actions {
    display: flex;
    justify-content: center;
    gap: 30px;
    margin-bottom: 5px; /* Added margin control */
}

.visualizer-container {
    width: 100%;
    height: 40px;
    display: flex;
    justify-content: center;
    align-items: center;
}

#visualizer {
    width: 100%;
    height: 100%;
}

.time-info {
    font-size: 14px;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    gap: 5px;
}

.divider {
    opacity: 0.3;
}

.controls {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 30px; /* Reduced gap */
    margin-top: 10px; /* Control gap */
}

.control-btn {
    background: none;
    border: none;
    color: white;
    font-size: 24px;
    cursor: pointer;
    transition: 0.2s ease;
}

.control-btn:hover {
    color: var(--secondary-color);
}

.play-btn {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: var(--gradient-linear);
    border: none;
    color: #1a1c1e; /* Darker icon for contrast on gold/orange */
    font-size: 28px;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    box-shadow: 0 10px 25px rgba(255, 77, 0, 0.4);
    transition: transform 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275), box-shadow 0.2s ease;
}

.play-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 15px 35px rgba(255, 77, 0, 0.6);
}

.play-btn:active {
    transform: scale(0.95);
}

.player-footer {
    display: flex;
    justify-content: space-between;
    width: 100%;
    padding-top: 10px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.footer-btn {
    font-size: 16px;
    color: var(--text-secondary);
}

.footer-btn:hover {
    color: white;
}

/* Animations */
@keyframes pulse {
    0% { transform: scale(1); opacity: 0.8; }
    50% { transform: scale(1.1); opacity: 1; }
    100% { transform: scale(1); opacity: 0.8; }
}

#play-icon.playing {
    display: block;
}

/* Mobile Responsiveness */
@media (max-width: 480px) {
    .container {
        height: 100vh;
        max-height: 100vh;
        border-radius: 0;
        border: none;
    }
}
