/* 
   PREMIUM DASHBOARD THEME - 2026 DESIGN SYSTEM
   Redesigned for MusiEQ
*/

@import url('https://fonts.googleapis.com/css2?family=Sora:wght@300;400;500;600;700;800&family=Inter:wght@300;400;500;600;700&display=swap');

:root {
    /* --- COLOR PALETTE --- */
    --primary: #8b5cf6;
    /* Violet */
    --primary-hover: #7c3aed;
    /* Violet-600 */
    --primary-light: #a78bfa;
    /* Violet-400 */
    --primary-dark: #6d28d9;
    /* Violet-700 */

    --accent: #f472b6;
    /* Pink-400 */
    --accent-glow: #ec4899;
    /* Pink-500 */

    --success: #10b981;
    /* Emerald-500 */
    --warning: #f59e0b;
    /* Amber-500 */
    --danger: #ef4444;
    /* Red-500 */
    --info: #3b82f6;
    /* Blue-500 */

    /* --- BACKGROUNDS --- */
    --bg-main: #1e1a25;
    /* Deepest dark */
    --bg-glass: rgba(20, 20, 35, 0.4);
    --bg-glass-strong: rgba(15, 15, 30, 0.75);
    --bg-glass-hover: rgba(139, 92, 246, 0.08);
    /* Slight violet tint */
    --bg-card: rgba(30, 30, 45, 0.4);
    --bg-elevated: rgba(255, 255, 255, 0.03);

    /* --- TEXT ELEMENTS --- */
    --text-primary: #ffffff;
    --text-secondary: #94a3b8;
    /* Slate-400 */
    --text-muted: #64748b;
    /* Slate-500 */
    --text-inverse: #0f172a;

    /* --- BORDERS & EFFECTS --- */
    --border-glass: rgba(255, 255, 255, 0.06);
    --border-hover: rgba(139, 92, 246, 0.3);
    --border-active: rgba(139, 92, 246, 0.6);

    --shadow-sm: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-md: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --shadow-lg: 0 20px 25px -5px rgba(0, 0, 0, 0.2), 0 10px 10px -5px rgba(0, 0, 0, 0.1);
    --shadow-glow: 0 0 20px rgba(139, 92, 246, 0.15);
    --shadow-glow-accent: 0 0 20px rgba(244, 114, 182, 0.15);

    /* --- LAYOUT TOKEN --- */
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 24px;
    --radius-full: 9999px;

    --header-height: 80px;
    --player-height: 100px;
    --sidebar-width: 260px;

    --transition-fast: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-spring: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    --transition-smooth: all 0.3s ease;
}

/* --- RESET & GLOBAL STYLES --- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-main);
    color: var(--text-primary);
    overflow-x: hidden !important;
    overflow-y: auto;
    width: 100%;
    max-width: 100vw;
    position: relative;
    line-height: 1.5;
}

/* Dynamic Background Mesh */
body::before {
    content: '';
    position: fixed;
    inset: 0;
    z-index: -2;
    background:
        radial-gradient(circle at 15% 50%, rgba(76, 29, 149, 0.08), transparent 25%),
        radial-gradient(circle at 85% 30%, rgba(219, 39, 119, 0.05), transparent 25%);
    filter: blur(60px);
    animation: pulseBg 10s ease-in-out infinite alternate;
}

/* Noise Texture Overlay */
body::after {
    content: '';
    position: fixed;
    inset: 0;
    z-index: -1;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.65' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)' opacity='0.03'/%3E%3C/svg%3E");
    opacity: 0.4;
    pointer-events: none;
}

/* Scrollbar Customization */
/* Firefox Support */
* {
    scrollbar-width: thin;
    scrollbar-color: rgba(255, 255, 255, 0.1) transparent;
}

/* Chrome/Edge/Safari */
::-webkit-scrollbar {
    width: 5px;
    /* Thinner */
    height: 5px;
}

::-webkit-scrollbar-track {
    background: transparent;
    /* Completely invisible track */
}

::-webkit-scrollbar-thumb {
    background: transparent;
    /* Invisible by default */
    border-radius: var(--radius-full);
    transition: background 0.3s ease;
}

/* Show scrollbar when hovering over the scrollable element */
*:hover::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.15);
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.3) !important;
    /* Brighter on grab */
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: 'Sora', sans-serif;
    font-weight: 700;
    color: var(--text-primary);
}

button,
input,
select {
    font-family: inherit;
    outline: none;
}

a {
    text-decoration: none;
    color: inherit;
}

/* Utility Classes */
.hidden {
    display: none !important;
    opacity: 0;
    pointer-events: none;
}

.fade-in {
    animation: fadeIn 0.4s ease forwards;
}

/* --- ANIMATIONS --- */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes pulseBg {
    0% {
        opacity: 0.5;
        transform: scale(1);
    }

    100% {
        opacity: 0.8;
        transform: scale(1.1);
    }
}

@keyframes float {
    0% {
        transform: translateY(0px);
    }

    50% {
        transform: translateY(-10px);
    }

    100% {
        transform: translateY(0px);
    }
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

@keyframes pulse-glow {

    0%,
    100% {
        filter: drop-shadow(0 0 12px rgba(139, 92, 246, 0.6));
        transform: scale(1);
    }

    50% {
        filter: drop-shadow(0 0 24px rgba(139, 92, 246, 1));
        transform: scale(1.05);
    }
}

@keyframes shimmer {
    0% {
        background-position: -200% center;
    }

    100% {
        background-position: 200% center;
    }
}

@keyframes equalizer {

    0%,
    100% {
        height: 10px;
    }

    50% {
        height: 40px;
    }
}

/* --- LOADING SCREEN (New Design) --- */
.loading-screen {
    position: fixed;
    inset: 0;
    z-index: 99999;
    background: var(--bg-main);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.5s ease, visibility 0.5s ease;
}

.loading-screen.hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

/* Bar Loader Animation - From Uiverse.io by elijahgummer */
.bar-loader {
    display: flex;
    align-items: flex-end;
    justify-content: center;
    gap: 6px;
    height: 80px;
}

.bar-loader .bar {
    width: 8px;
    height: 60px;
    display: inline-block;
    transform-origin: bottom center;
    border-top-right-radius: 20px;
    border-top-left-radius: 20px;
    box-shadow: 5px 10px 20px inset rgba(139, 92, 246, 0.8);
    animation: barLoader 1.2s linear infinite;
}

.bar-loader .bar1 {
    animation-delay: 0.1s;
}

.bar-loader .bar2 {
    animation-delay: 0.2s;
}

.bar-loader .bar3 {
    animation-delay: 0.3s;
}

.bar-loader .bar4 {
    animation-delay: 0.4s;
}

.bar-loader .bar5 {
    animation-delay: 0.5s;
}

.bar-loader .bar6 {
    animation-delay: 0.6s;
}

.bar-loader .bar7 {
    animation-delay: 0.7s;
}

.bar-loader .bar8 {
    animation-delay: 0.8s;
}

@keyframes barLoader {
    0% {
        transform: scaleY(0.1);
        background: transparent;
    }

    50% {
        transform: scaleY(1);
        background: linear-gradient(to top, var(--primary), var(--accent));
    }

    100% {
        transform: scaleY(0.1);
        background: transparent;
    }
}

/* Small bar loader for inline loading */
.bar-loader-small {
    display: flex;
    align-items: flex-end;
    justify-content: center;
    gap: 3px;
    height: 24px;
}

.bar-loader-small .bar {
    width: 4px;
    height: 20px;
    display: inline-block;
    transform-origin: bottom center;
    border-top-right-radius: 10px;
    border-top-left-radius: 10px;
    box-shadow: 2px 4px 8px inset rgba(139, 92, 246, 0.8);
    animation: barLoader 1.2s linear infinite;
}

.bar-loader-small .bar1 {
    animation-delay: 0.1s;
}

.bar-loader-small .bar2 {
    animation-delay: 0.2s;
}

.bar-loader-small .bar3 {
    animation-delay: 0.3s;
}

.bar-loader-small .bar4 {
    animation-delay: 0.4s;
}

.bar-loader-small .bar5 {
    animation-delay: 0.5s;
}

.bar-loader-small .bar6 {
    animation-delay: 0.6s;
}

.bar-loader-small .bar7 {
    animation-delay: 0.7s;
}

.bar-loader-small .bar8 {
    animation-delay: 0.8s;
}


/* --- LOGIN SCREEN (New 3D Glass Design) --- */
.login-screen {
    position: fixed;
    inset: 0;
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    background: radial-gradient(circle at center, #1e1e2e 0%, #0a0a0f 100%);
    overflow: hidden;
}

/* Background decoration */
.login-bg-decoration {
    position: absolute;
    width: 600px;
    height: 600px;
    background: conic-gradient(from 180deg at 50% 50%, var(--primary), var(--accent), var(--primary));
    filter: blur(100px);
    opacity: 0.15;
    border-radius: 50%;
    animation: spin 20s linear infinite;
    z-index: 0;
}

.login-glass {
    position: relative;
    z-index: 1;
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5), inset 0 0 0 1px rgba(255, 255, 255, 0.05);
    padding: 60px 40px;
    border-radius: 32px;
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 90%;
    max-width: 420px;
    transform: translateY(0);
    transition: transform 0.3s ease;
}

.login-glass:hover {
    transform: translateY(-5px);
    box-shadow: 0 30px 60px -12px rgba(0, 0, 0, 0.6), inset 0 0 0 1px rgba(255, 255, 255, 0.1);
}

.login-icon {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    border-radius: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 36px;
    color: white;
    margin-bottom: 24px;
    box-shadow: 0 10px 30px rgba(124, 58, 237, 0.4);
    animation: float 4s ease-in-out infinite;
}

.login-title {
    font-size: 32px;
    margin-bottom: 8px;
    letter-spacing: -0.5px;
    text-align: center;
    background: linear-gradient(to right, #fff, #cbd5e1);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.login-subtitle {
    color: var(--text-secondary);
    margin-bottom: 40px;
    font-size: 15px;
    text-align: center;
    font-weight: 400;
}

.login-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    width: 100%;
    padding: 16px;
    background: #5865F2;
    /* Discord brand color */
    color: white;
    border: none;
    border-radius: 16px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition-spring);
    box-shadow: 0 8px 20px rgba(88, 101, 242, 0.3);
}

.login-btn:hover {
    background: #4752c4;
    transform: scale(1.02);
    box-shadow: 0 12px 25px rgba(88, 101, 242, 0.4);
}

.login-btn i {
    font-size: 20px;
}

/* ============================================
   MAIN LAYOUT & HEADERS
   ============================================ */

.dashboard {
    height: 100vh;
    display: grid;
    grid-template-rows: auto auto auto 1fr auto;
    grid-template-areas:
        "header"
        "nav"
        "status"
        "main"
        "player";
    background: radial-gradient(circle at 50% 0%, rgba(50, 50, 80, 0.2), transparent 70%);
    position: relative;
    overflow: hidden;
    padding-top: 100px;
    /* Adjusted for floating navbar height */
}

/* --- NAVBAR (Glassmorphic) --- */
.navbar {
    grid-area: header;
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    width: min(1200px, calc(100% - 40px));
    height: 64px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 24px;
    background: rgba(10, 10, 10, 0.4);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-full);
    z-index: 2000;
    transition: var(--transition-smooth);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
}

/* Header Responsiveness */
@media (max-width: 1100px) {
    .header-center {
        gap: 0 !important;
    }

    .header-center a {
        padding: 8px 14px !important;
        font-size: 0.8rem !important;
    }

    .header-right {
        gap: 12px !important;
    }
}

@media (max-width: 950px) {
    .header-center a:not(.active) {
        display: none !important;
        /* Hide secondary links to prevent overlap */
    }

    .header-brand {
        display: none !important;
        /* Hide brand text to save space */
    }
}

/* Ultra-compact navbar for 360px and below */
@media (max-width: 360px) {
    .navbar {
        width: calc(100% - 16px) !important;
        padding: 0 12px !important;
        top: 10px !important;
        left: 8px !important;
        transform: none !important;
    }

    .header-left {
        gap: 8px !important;
    }

    .header-logo {
        width: 36px !important;
        height: 36px !important;
    }

    .header-right {
        gap: 8px !important;
    }

    .user-menu {
        padding: 3px 8px !important;
        gap: 6px !important;
    }

    .user-info {
        gap: 0 !important;
    }

    .user-avatar {
        width: 28px !important;
        height: 28px !important;
    }

    .user-name,
    .user-info .plan-badge {
        display: none !important;
    }

    .signout-btn {
        width: 32px !important;
        height: 32px !important;
        font-size: 14px !important;
    }
}

.header-left {
    display: flex;
    align-items: center;
    gap: 16px;
}

.bot-brand {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
}

.header-logo {
    height: 44px;
    width: 44px;
    object-fit: contain;
    border-radius: 50%;
    border: 2px solid rgba(139, 92, 246, 0.5);
    background: rgba(139, 92, 246, 0.08);
    padding: 5px;
    box-shadow: 0 0 12px rgba(139, 92, 246, 0.35), 0 0 30px rgba(139, 92, 246, 0.12);
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), box-shadow 0.3s ease, border-color 0.3s ease;
}

.header-logo:hover {
    transform: scale(1.08) rotate(5deg);
    border-color: rgba(139, 92, 246, 0.8);
    box-shadow: 0 0 18px rgba(139, 92, 246, 0.5), 0 0 40px rgba(139, 92, 246, 0.2);
}

.header-brand {
    height: 32px;
    width: auto;
    opacity: 0.92;
    display: block;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 24px;
}

/* Navigation Links */
.header-center {
    display: flex;
    align-items: center;
    gap: 8px;
    background: transparent;
    padding: 0;
    border-radius: 0;
    border: none;
    backdrop-filter: none;
    box-shadow: none;
}

.header-center a {
    color: rgba(255, 255, 255, 0.6);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.85rem;
    letter-spacing: 0.03em;
    transition: color 0.3s ease, background 0.3s ease, box-shadow 0.3s ease, transform 0.2s ease;
    padding: 8px 18px;
    border-radius: var(--radius-full);
    position: relative;
    overflow: hidden;
}

.header-center a::after {
    content: '';
    position: absolute;
    bottom: 4px;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, #8b5cf6, #a78bfa, #c084fc);
    border-radius: 2px;
    transition: width 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.header-center a:hover {
    color: #ffffff;
    transform: translateY(-1px);
}

.header-center a:hover::after {
    width: 60%;
}

.header-center a.active {
    color: #ffffff;
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.2), rgba(168, 139, 250, 0.1));
    box-shadow: inset 0 0 0 1px rgba(139, 92, 246, 0.3), 0 2px 8px rgba(139, 92, 246, 0.15);
    font-weight: 600;
}

.header-center a.active::after {
    width: 50%;
    opacity: 1;
}

/* User Menu */
.user-menu {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 4px 12px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-full);
    transition: var(--transition-fast);
}

.user-menu:hover {
    background: var(--bg-glass-hover);
    border-color: var(--border-hover);
    box-shadow: var(--shadow-glow);
}

.user-info {
    display: flex;
    align-items: center;
    gap: 12px;
}

.user-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 2px solid var(--primary);
    box-shadow: 0 0 10px rgba(139, 92, 246, 0.3);
}

.user-name {
    font-weight: 600;
    font-size: 14px;
    letter-spacing: 0.3px;
}

/* ============================================================================
   SUBSCRIPTION BADGES - PREMIUM REDESIGN
   ============================================================================ */

.plan-badge {
    padding: 3px 10px;
    border-radius: 6px;
    font-size: 10px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    user-select: none;
    height: 18px;
    line-height: 1;
}

.plan-badge.hidden {
    display: none;
}

/* User Plans */
.plan-badge.user-free {
    background: rgba(148, 163, 184, 0.15);
    color: #94a3b8;
    border: 1px solid rgba(148, 163, 184, 0.25);
    backdrop-filter: blur(4px);
}

.plan-badge.user-vip {
    background: linear-gradient(135deg, #FFD700 0%, #B8860B 50%, #FFD700 100%);
    background-size: 200% auto;
    color: #ffffffff;
    box-shadow:
        0 4px 12px rgba(255, 215, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.4);
    border: none;
    animation: metallicShine 4s linear infinite;
    text-shadow: 0 0 1px rgba(255, 255, 255, 0.5);
}

/* Server Plans */
.plan-badge.server-free {
    background: rgba(148, 163, 184, 0.15);
    color: #94a3b8;
    border: 1px solid rgba(148, 163, 184, 0.25);
    backdrop-filter: blur(4px);
}

.plan-badge.server-pro {
    background: linear-gradient(135deg, #ef4444 0%, #b91c1c 50%, #ef4444 100%);
    color: #ffffff;
    box-shadow:
        0 4px 12px rgba(239, 68, 68, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.plan-badge.server-premium {
    background: linear-gradient(135deg, #60a5fa 0%, #2563eb 50%, #60a5fa 100%);
    background-size: 200% auto;
    color: #ffffff;
    box-shadow:
        0 4px 12px rgba(37, 99, 235, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.4);
    border: none;
    animation: metallicShine 4s linear infinite;
}

@keyframes metallicShine {
    0% {
        background-position: 0% 50%;
    }

    100% {
        background-position: 200% 50%;
    }
}

.signout-btn {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: none;
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-secondary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition-fast);
}

.signout-btn:hover {
    background: var(--danger);
    color: white;
    transform: rotate(90deg);
}

/* --- BOTTOM HEADER â€” PREMIUM COMPACT PILL --- */
.bottom-header {
    grid-area: nav;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 0 20px;
    height: 56px;
    background: rgba(10, 10, 10, 0.4);
    backdrop-filter: blur(28px);
    -webkit-backdrop-filter: blur(28px);
    z-index: 100;
    width: min(1200px, calc(100% - 40px));
    margin: 0 auto 16px;
    border-radius: var(--radius-full);
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.35);
    transition: var(--transition-smooth);
}

.bottom-header-left {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-shrink: 0;
}

.back-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-full);
    color: rgba(255, 255, 255, 0.6);
    font-weight: 600;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    white-space: nowrap;
}

.back-btn:hover {
    background: rgba(139, 92, 246, 0.1);
    border-color: rgba(139, 92, 246, 0.25);
    color: #c4b5fd;
    transform: translateX(-2px);
}

.back-btn:active {
    transform: translateX(0) scale(0.97);
}

.back-btn i {
    font-size: 13px;
    transition: transform 0.2s ease;
}

.back-btn:hover i {
    transform: translateX(-2px);
}

/* Search Bar - Centered & Responsive */
.bottom-header-center {
    flex: 1;
    display: flex;
    justify-content: center;
    max-width: 600px;
}

.bottom-search {
    width: 100%;
}

.bottom-search .search-input {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    padding: 10px 16px 10px 42px;
    border-radius: var(--radius-full);
    font-size: 0.9rem;
    height: 44px;
    float: none;
}

.bottom-search .search-icon {
    left: 14px;
    color: rgba(139, 92, 246, 0.6);
}

.bottom-search .search-input:focus {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(139, 92, 246, 0.4);
    box-shadow: 0 0 20px rgba(139, 92, 246, 0.15);
}

.search-container {
    position: relative;
    width: 100%;
    max-width: 400px;
}

.search-input {
    width: 100%;
    padding: 12px 16px 12px 44px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-full);
    color: var(--text-primary);
    font-size: 14px;
    transition: all 0.2s ease;
    float: right;
}

.search-input:focus {
    background: rgba(30, 30, 45, 0.9);
    border-color: rgba(139, 92, 246, 0.4);
    box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.1);
    outline: none;
}

.search-icon {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    font-size: 14px;
    pointer-events: none;
}

.close-search-btn {
    display: none;
}

.bottom-header-right {
    display: flex;
    align-items: center;
    justify-content: flex-end;
}

/* In-header Server Display - Premium Glassmorphic Design */
.server-display {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 6px 14px 6px 6px;
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.12), rgba(168, 139, 250, 0.05));
    border-radius: 14px;
    border: 1px solid rgba(139, 92, 246, 0.25);
    backdrop-filter: blur(10px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    transition: all 0.3s ease;
}

.server-display:hover {
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.18), rgba(168, 139, 250, 0.08));
    border-color: rgba(139, 92, 246, 0.4);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(139, 92, 246, 0.2);
}

.server-icon-header {
    width: 38px;
    height: 38px;
    border-radius: 10px;
    object-fit: cover;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.server-display:hover .server-icon-header {
    transform: scale(1.05);
}

.server-info-header {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 2px;
}

.server-name-row {
    display: flex;
    align-items: center;
    gap: 8px;
}

.server-name-header {
    font-size: 14px;
    font-weight: 700;
    color: #ffffff;
    letter-spacing: 0.2px;
    white-space: nowrap;
    max-width: 150px;
    overflow: hidden;
    text-overflow: ellipsis;
}

.server-label {
    font-size: 10px;
    color: var(--text-muted);
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 5px;
    margin-top: 1px;
}

.server-label::before {
    content: '';
    width: 6px;
    height: 6px;
    background: #4b5563;
    /* Default gray/muted */
    border-radius: 50%;
}

.server-display.connected .server-label::before {
    background: #10b981;
    box-shadow: 0 0 8px rgba(16, 185, 129, 0.6);
    animation: pulseDot 2s infinite;
}

@keyframes pulseDot {
    0% {
        transform: scale(0.9);
        opacity: 0.7;
    }

    50% {
        transform: scale(1.1);
        opacity: 1;
    }

    100% {
        transform: scale(0.9);
        opacity: 0.7;
    }
}

/* Plan Badge Styling */
.server-info-header .plan-badge {
    font-size: 9px;
    font-weight: 800;
    padding: 3px 8px;
    border-radius: 6px;
    letter-spacing: 0.8px;
    width: fit-content;
    text-transform: uppercase;
}

.server-info-header .plan-badge.server-premium {
    background: linear-gradient(135deg, #fbbf24 0%, #f59e0b 100%);
    color: #000;
    box-shadow: 0 2px 10px rgba(251, 191, 36, 0.4);
    border: 1px solid rgba(251, 191, 36, 0.5);
}

.server-info-header .plan-badge.server-free {
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.3) 0%, rgba(59, 130, 246, 0.3) 100%);
    color: rgba(255, 255, 255, 0.9);
    border: 1px solid rgba(139, 92, 246, 0.3);
}

/* Active animation state */
.server-display.server-display-active {
    animation: serverDisplayPop 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes serverDisplayPop {
    0% {
        transform: scale(0.9);
        opacity: 0.7;
    }

    50% {
        transform: scale(1.05);
    }

    100% {
        transform: scale(1);
        opacity: 1;
    }
}

/* Connected state styling */
.server-display.connected {
    border-color: rgba(16, 185, 129, 0.4);
    background: linear-gradient(135deg,
            rgba(16, 185, 129, 0.12) 0%,
            rgba(139, 92, 246, 0.08) 50%,
            rgba(16, 185, 129, 0.05) 100%);
}

.server-display.connected .server-label {
    color: #10b981;
}

.server-display.connected .server-label::before {
    background: #10b981;
    box-shadow: 0 0 10px #10b981;
    animation: pulseDotConnected 1.5s ease-in-out infinite;
}

@keyframes pulseDotConnected {

    0%,
    100% {
        opacity: 1;
        transform: scale(1);
        box-shadow: 0 0 10px #10b981;
    }

    50% {
        opacity: 0.8;
        transform: scale(1.1);
        box-shadow: 0 0 20px #10b981, 0 0 30px #10b981;
    }
}


/* --- MAIN CONTENT AREA --- */
.main-area {
    grid-area: main;
    position: relative;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 0;

    /* Scrollbar styling */
    scrollbar-width: thin;
    scrollbar-color: rgba(255, 255, 255, 0.2) transparent;
}

/* Player view container */
#playing-view {
    display: none;
    width: 100%;
    box-sizing: border-box;
}

#playing-view.active {
    display: flex !important;
    flex-direction: column;
    width: 100%;
}

/* Player layout */
#playing-view.active .player-layout-container {
    display: flex;
    flex-direction: column;
    max-width: 1200px;
    margin: 0 auto;
    width: 100%;
}

@media (max-width: 480px) {
    #playing-view.active .player-layout-container {
        padding: 0 8px !important;
    }
}

#playing-view.active .player-nav-tabs {
    display: flex;
    margin-bottom: 16px;
}

.content-container {
    padding: 32px 48px;
    max-width: 1600px;
    margin: 0 auto;
    min-height: 100%;
}

@media (max-width: 768px) {
    .content-container {
        padding: 16px !important;
    }
}

/* Hide content-container when in player mode (playing-view active) */
body.player-mode .content-container {
    display: none;
}

/* Hide primary navbar when in server music player mode */
body.player-mode .navbar {
    display: none !important;
}

/* Adjust dashboard padding when in player mode (no navbar) */
body.player-mode .dashboard {
    padding-top: 0 !important;
    overflow: hidden !important;
    height: 100vh !important;
    display: flex !important;
    flex-direction: column !important;
}

/* Full width player layout when navbar is hidden */
body.player-mode #playing-view.active {
    flex: 1 !important;
    height: 0 !important;
    /* with flex:1, height:0 is the correct base */
    min-height: 0 !important;
    overflow: hidden !important;
    display: flex !important;
    flex-direction: column !important;
}

body.player-mode .main-area {
    flex: 1 !important;
    overflow: hidden !important;
    min-height: 0 !important;
    display: flex !important;
    flex-direction: column !important;
}

body.player-mode #playing-view.active .player-layout-container {
    padding-top: 0;
}

/* View Containers */
.view-container {
    display: flex;
    flex-direction: column;
    animation: fadeUp 0.5s cubic-bezier(0.2, 0.8, 0.2, 1);
    width: 100%;
}

.view-header {
    text-align: center;
    margin-bottom: 24px;
    position: relative;
}

.view-title {
    font-size: 36px;
    margin-bottom: 8px;
    background: linear-gradient(135deg, #fff 0%, #a78bfa 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    filter: drop-shadow(0 0 20px rgba(167, 139, 250, 0.3));
}

.view-description {
    font-size: 16px;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto;
}

/* View Selector Menu */
.view-selector {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-bottom: 10px;
    margin-top: 10px;
    padding: 6px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: var(--radius-full);
    width: fit-content;
    margin-left: auto;
    margin-right: auto;
}

.selector-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    background: transparent;
    border: none;
    border-radius: var(--radius-full);
    color: var(--text-secondary);
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition-fast);
}

.selector-btn:hover {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.05);
}

.selector-btn.active {
    background: var(--primary);
    color: white;
    box-shadow: 0 4px 12px rgba(139, 92, 246, 0.4);
}

.selector-btn i {
    font-size: 14px;
}

/* Responsive View Selector */
@media (max-width: 768px) {
    .view-selector {
        gap: 4px;
        padding: 4px;
        width: 100%;
        margin-bottom: 16px;
    }

    .selector-btn {
        padding: 8px 12px;
        font-size: 12px;
        flex: 1;
        justify-content: center;
    }

    .selector-btn i {
        font-size: 12px;
    }
}

@media (max-width: 480px) {
    .view-selector {
        gap: 2px;
        padding: 4px;
    }

    .selector-btn {
        padding: 6px 8px;
        font-size: 11px;
    }

    .selector-btn span:not(.fa) {
        display: none;
    }
}

@keyframes fadeUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}



/* ============================================
   SERVER SELECTION VIEW (Bento Grid)
   ============================================ */

.servers-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
    padding: 20px 0;
}

.servers-section-title {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-primary);
    margin-top: 24px;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 10px;
    grid-column: 1 / -1;
}

.servers-section-title:first-child {
    margin-top: 0;
}

.servers-section-desc {
    color: var(--text-secondary);
    font-size: 14px;
    margin-bottom: 16px;
    grid-column: 1 / -1;
}

.server-card-add-bot:hover {
    border-color: rgba(251, 191, 36, 0.3) !important;
}

.server-card-add-bot:hover .server-icon {
    box-shadow: 0 0 25px rgba(251, 191, 36, 0.4);
}

.server-card-add-bot::before {
    background: linear-gradient(135deg, rgba(251, 191, 36, 0.1), transparent) !important;
}

.server-card {
    background: rgba(139, 92, 246, 0.05);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(139, 92, 246, 0.2);
    border-radius: 24px;
    overflow: hidden;
    position: relative;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.3);
}

.server-card::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(139, 92, 246, 0.15) 0%, transparent 70%);
    opacity: 0;
    transition: opacity 0.4s ease;
    pointer-events: none;
}

.server-card::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, transparent 0%, rgba(255, 255, 255, 0.05) 50%, transparent 100%);
    transform: translateX(-100%);
    transition: transform 0.6s ease;
    pointer-events: none;
}

.server-card:hover {
    transform: translateY(-10px) scale(1.03);
    border-color: rgba(139, 92, 246, 0.6);
    box-shadow: 0 15px 45px rgba(139, 92, 246, 0.3);
}

.server-card:hover::before {
    opacity: 1;
}

.server-card:hover::after {
    transform: translateX(100%);
}

.server-card-content {
    padding: 24px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
    position: relative;
    z-index: 2;
    text-align: center;
}

/* Server Icon with Ring */
.server-icon {
    width: 90px;
    height: 90px;
    border-radius: 28px;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-elevated);
    padding: 4px;
    border: 2px solid rgba(139, 92, 246, 0.3);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.4);
    transition: all 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.server-icon img {
    width: 100%;
    height: 100%;
    border-radius: 22px;
    object-fit: cover;
}

.server-card:hover .server-icon {
    transform: rotate(8deg) scale(1.1);
    border-color: var(--primary);
    box-shadow: 0 0 30px rgba(139, 92, 246, 0.5);
}

.server-info {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.server-name {
    font-size: 1.1rem;
    font-weight: 800;
    color: #ffffff;
    margin-bottom: 4px;
    letter-spacing: 0.3px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.server-members {
    font-size: 0.85rem;
    color: var(--text-secondary);
    font-weight: 500;
    opacity: 0.8;
}

.server-members i {
    font-size: 11px;
    color: var(--info);
}

/* Play Overlay on Card */
.play-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: var(--transition-fast);
}

.server-card:hover .play-overlay {
    opacity: 1;
}

.play-icon-large {
    font-size: 48px;
    color: white;
    filter: drop-shadow(0 0 10px var(--accent-glow));
    transform: scale(0.5);
    transition: var(--transition-spring);
}

.server-card:hover .play-icon-large {
    transform: scale(1);
}


/* ============================================
   ANALYTICS DASHBOARD
   ============================================ */

.analytics-dashboard-v2 {
    margin-top: 60px;
    display: flex;
    flex-direction: column;
    gap: 32px;
    animation: fadeUp 0.8s ease;
}

.analytics-container-v2 {
    background: var(--bg-card);
    border-radius: var(--radius-xl);
    border: 1px solid var(--border-glass);
    padding: 32px;
    position: relative;
    overflow: visible;
}

/* Shining top border effect */
.analytics-container-v2::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(139, 92, 246, 0.6), transparent);
}

/* --- STATS ROW (Floating Cards) --- */
.stats-row-v2 {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
    margin-bottom: 40px;
}

.stat-box-v2 {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-lg);
    padding: 24px;
    display: flex;
    align-items: center;
    gap: 20px;
    transition: var(--transition-spring);
    position: relative;
    overflow: hidden;
}

.stat-box-v2::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 100% 0%, rgba(255, 255, 255, 0.05), transparent 50%);
    opacity: 0;
    transition: opacity 0.3s;
}

.stat-box-v2:hover {
    transform: translateY(-5px);
    border-color: rgba(255, 255, 255, 0.2);
    box-shadow: var(--shadow-lg);
}

.stat-box-v2:hover::before {
    opacity: 1;
}

.stat-icon-wrap-v2 {
    width: 56px;
    height: 56px;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    color: white;
    box-shadow: var(--shadow-md);
}

/* Individual Stat Colors */
.track-activity .stat-icon-wrap-v2 {
    background: linear-gradient(135deg, #3b82f6, #2563eb);
    box-shadow: 0 4px 15px rgba(59, 130, 246, 0.4);
}

.most-active-server .stat-icon-wrap-v2 {
    background: linear-gradient(135deg, #10b981, #059669);
    box-shadow: 0 4px 15px rgba(16, 185, 129, 0.4);
}

.genre-mood .stat-icon-wrap-v2 {
    background: linear-gradient(135deg, #ec4899, #db2777);
    box-shadow: 0 4px 15px rgba(236, 72, 153, 0.4);
}

.listening-time .stat-icon-wrap-v2 {
    background: linear-gradient(135deg, #f59e0b, #d97706);
    box-shadow: 0 4px 15px rgba(245, 158, 11, 0.4);
}

.stat-data-v2 {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.stat-number-v2 {
    font-size: 28px;
    font-weight: 800;
    color: var(--text-primary);
    letter-spacing: -0.5px;
    line-height: 1;
}

.stat-label-v2 {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}


/* --- CHARTS & TABLES --- */
.weekly-chart-container {
    background: rgba(20, 20, 30, 0.4);
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-glass);
    padding: 24px;
    margin-bottom: 32px;
}

.weekly-chart-title {
    font-size: 18px;
    margin-bottom: 24px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.weekly-chart-title i {
    color: var(--primary);
}

.weekly-chart-bars {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    height: 160px;
    padding: 0 10px;
}

.chart-bar {
    flex: 1;
    margin: 0 6px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px 8px 0 0;
    position: relative;
    height: 100%;
}

.bar-fill {
    position: absolute;
    bottom: 0;
    width: 100%;
    background: linear-gradient(top, var(--primary-light), var(--primary));
    background: -webkit-linear-gradient(top, var(--primary-light), var(--primary));
    border-radius: 8px 8px 0 0;
    transition: height 1s cubic-bezier(0.2, 0.8, 0.2, 1);
    box-shadow: 0 0 10px rgba(139, 92, 246, 0.2);
}

.chart-bar:hover .bar-fill {
    background: linear-gradient(top, var(--accent), var(--accent-glow));
    box-shadow: 0 0 15px rgba(236, 72, 153, 0.4);
}

.bar-label {
    position: absolute;
    bottom: -25px;
    width: 100%;
    text-align: center;
    font-size: 12px;
    color: var(--text-secondary);
    font-weight: 500;
}

.bar-value {
    position: absolute;
    top: -30px;
    width: 100%;
    text-align: center;
    font-size: 12px;
    font-weight: 700;
    color: var(--text-primary);
    opacity: 0;
    transform: translateY(10px);
    transition: all 0.3s ease;
    background: var(--bg-elevated);
    padding: 4px;
    border-radius: 4px;
}

.chart-bar:hover .bar-value {
    opacity: 1;
    transform: translateY(0);
}


/* --- MOST PLAYED TABLE --- */
.most-played-table-container {
    background: rgba(20, 20, 30, 0.4);
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-glass);
    padding: 24px;
    backdrop-filter: blur(8px);
}

.table-header-v2 {
    display: flex;
    justify-content: space-between;
    margin-bottom: 24px;
    align-items: center;
}

.table-title-v2 {
    font-size: 20px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.view-all-table-btn {
    padding: 8px 16px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-full);
    color: var(--primary-light);
    font-weight: 600;
    font-size: 13px;
    cursor: pointer;
    transition: var(--transition-fast);
}

.view-all-table-btn:hover {
    background: var(--border-hover);
    color: white;
    transform: translateX(4px);
}

.tracks-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
}

.tracks-table th {
    text-align: left;
    padding: 16px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--text-secondary);
    border-bottom: 1px solid var(--border-glass);
}

.tracks-table td {
    padding: 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.03);
    transition: background 0.2s;
}

.track-row:hover td {
    background: rgba(255, 255, 255, 0.03);
}

.track-row td:first-child {
    border-top-left-radius: 12px;
    border-bottom-left-radius: 12px;
}

.track-row td:last-child {
    border-top-right-radius: 12px;
    border-bottom-right-radius: 12px;
}

/* Rank Badges */
.rank-badge {
    width: 28px;
    height: 28px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 13px;
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.05);
}

.rank-badge.rank-1 {
    background: linear-gradient(135deg, #fbbf24, #d97706);
    color: black;
    box-shadow: 0 2px 10px rgba(251, 191, 36, 0.3);
}

.rank-badge.rank-2 {
    background: linear-gradient(135deg, #94a3b8, #64748b);
    color: white;
}

.rank-badge.rank-3 {
    background: linear-gradient(135deg, #b45309, #78350f);
    color: white;
}

.track-thumbnail {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    object-fit: cover;
    box-shadow: var(--shadow-sm);
    display: contents;
}

.track-details-cell {
    display: flex;
    align-items: center;
    gap: 16px;
}

.track-info-cell {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.track-title-cell {
    font-weight: 600;
    font-size: 14px;
    color: white;
}

.track-artist-cell {
    font-size: 13px;
    color: var(--text-secondary);
}



/* ============================================
   PLAYER VIEW LAYOUT
   ============================================ */

#playing-view {
    display: block;
    width: 100%;
}

.player-layout-container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 20px 110px;
    width: 100%;
}

/* --- TABS --- */
.player-nav-tabs {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 6px 12px;
    background: rgba(15, 15, 15, 0.4);
    border: 1px solid rgba(139, 92, 246, 0.15);
    width: 100%;
    max-width: 100%;
    margin: 0 auto 24px auto;
    border-radius: var(--radius-full);
    position: sticky;
    top: 10px;
    z-index: 101;
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4), inset 0 1px 1px rgba(255, 255, 255, 0.05);
    flex-wrap: nowrap;
    overflow-x: hidden;
}

.tabs-left,
.tabs-right {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
}

.tabs-center {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    flex-wrap: nowrap;
    min-width: 0;
}

/* Wide Tab Search Container */
.tab-search-container {
    width: 100%;
    display: flex;
    justify-content: center;
    margin-bottom: 16px;
}

.tab-search-container .search-container {
    width: 100%;
    max-width: 650px;
    position: relative;
}

.tab-search-container .search-input {
    width: 100%;
    height: 52px;
    padding: 0 24px 0 54px;
    background: rgba(10, 10, 10, 0.45);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-full);
    color: white;
    font-size: 16px;
    /* MOBILE ZOOM FIX: Must be at least 16px to prevent iOS auto-zoom */
    transition: var(--transition-smooth);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

@media (max-width: 480px) {
    .tab-search-container {
        padding: 0 4px !important;
        margin-bottom: 8px !important;
    }

    .tab-search-container .search-input {
        padding: 0 16px 0 40px !important;
        height: 44px !important;
        font-size: 14px !important;
    }
}

.tab-search-container .search-input:focus {
    background: rgba(20, 20, 30, 0.8);
    border-color: var(--primary);
    box-shadow: 0 0 30px rgba(139, 92, 246, 0.2);
}

.tab-search-container .search-icon {
    position: absolute;
    left: 20px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--primary);
    font-size: 1.2rem;
    pointer-events: none;
}

.tab-search-container .close-search-btn {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.8);
    display: none;
    /* Hidden by default on desktop */
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
    padding: 0;
    z-index: 5;
}

.tab-search-container .close-search-btn:hover {
    background: rgba(255, 255, 255, 0.15);
    color: white;
    transform: translateY(-50%) scale(1.05);
}

/* Show close button when search is active on mobile/tablet */
@media (max-width: 1024px) {
    .mobile-search-active .close-search-btn {
        display: flex !important;
    }

    .mobile-search-active #search-input {
        padding-right: 50px !important;
        /* Make room for the button */
    }
}

.player-nav-tabs::-webkit-scrollbar {
    display: none;
}

.nav-tab {
    flex: 0 0 auto;
    padding: 8px 16px;
    background: transparent;
    border: none;
    border-radius: var(--radius-full);
    color: rgba(255, 255, 255, 0.6);
    font-weight: 600;
    font-size: 0.85rem;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    position: relative;
    white-space: nowrap;
    min-width: 0;
}

@media (max-width: 480px) {
    .nav-tab {
        flex: 1 1 auto !important;
        padding: 8px 4px !important;
        min-width: 0 !important;
        max-width: 80px !important;
        gap: 4px !important;
    }
}

.nav-tab i {
    font-size: 1rem;
    opacity: 0.7;
    transition: transform 0.3s ease;
}

.nav-tab:hover {
    color: #ffffff;
    background: rgba(139, 92, 246, 0.1);
}

.nav-tab:hover i {
    opacity: 1;
    transform: translateY(-2px);
}

.nav-tab.active {
    color: #ffffff;
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.2), rgba(168, 139, 250, 0.1));
    box-shadow: inset 0 0 0 1px rgba(139, 92, 246, 0.3), 0 4px 15px rgba(139, 92, 246, 0.2);
}

.nav-tab.active i {
    opacity: 1;
    color: #a78bfa;
    filter: drop-shadow(0 0 8px rgba(139, 92, 246, 0.5));
}

/* Tab Count Badge */
.tab-count,
.tab-badge {
    background: rgba(139, 92, 246, 0.3);
    padding: 2px 8px;
    border-radius: 10px;
    font-size: 11px;
    font-weight: 700;
    min-width: 20px;
    text-align: center;
    transition: var(--transition-fast);
}

.nav-tab.active .tab-count,
.nav-tab.active .tab-badge {
    background: rgba(255, 255, 255, 0.2);
    box-shadow: 0 0 10px rgba(255, 255, 255, 0.2);
}

.nav-tab.active .tab-count {
    background: rgba(0, 0, 0, 0.3);
    border-color: rgba(255, 255, 255, 0.12);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.1),
        0 0 15px rgba(139, 92, 246, 0.3);
}

/* Tab Content Transitions */
.tab-content {
    display: none;
    animation: fadeIn 0.3s ease;
}

.tab-content.active {
    display: block;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Responsive Section Tabs - Tablet */
@media (max-width: 768px) {
    .section-tabs {
        width: calc(100% - 32px);
        max-width: 600px;
        padding: 6px;
        justify-content: flex-start;
        gap: 3px;
        top: 6px;
        border-radius: 16px;
    }

    .tab-indicator {
        border-radius: 12px;
    }

    .tab-btn {
        padding: 10px 18px;
        font-size: 13px;
        gap: 8px;
    }

    .tab-btn i {
        font-size: 15px;
    }
}

/* Responsive Section Tabs - Mobile */
@media (max-width: 540px) {
    .section-tabs {
        width: calc(100% - 24px);
        padding: 6px;
        gap: 2px;
        justify-content: flex-start;
        border-radius: 14px;
    }

    .tab-btn {
        padding: 10px 14px;
        font-size: 12px;
        gap: 6px;
    }

    .tab-btn i {
        font-size: 15px;
    }

    .tab-count {
        padding: 2px 6px;
        font-size: 10px;
    }
}

/* Responsive Section Tabs - Small Mobile */
@media (max-width: 400px) {
    .section-tabs {
        width: calc(100% - 20px);
        padding: 5px;
        border-radius: 12px;
    }

    .tab-btn {
        padding: 8px 12px;
        font-size: 11px;
        flex-shrink: 0;
    }

    .tab-btn span:not(.tab-count) {
        display: none;
    }

    .tab-btn i {
        font-size: 16px;
    }

    .tab-btn span.tab-count {
        position: absolute;
        top: 2px;
        right: 4px;
        padding: 1px 4px;
        font-size: 8px;
        min-width: 16px;
    }
}

/* Bottom Search - Very Small Mobile */
@media (max-width: 386px) {
    .bottom-search .search-input {
        width: 82% !important;
    }
}

@media (max-width: 329px) {
    .bottom-search .search-input {
        width: 76% !important;
    }
}

/* Responsive Tab Content */
@media (max-width: 768px) {
    .tab-content {
        padding: 0 12px;
    }

    .player-playlists-grid {
        gap: 8px;
        max-height: 350px;
    }

    .player-playlists-empty {
        padding: 36px 16px;
    }

    .player-playlists-empty i {
        font-size: 36px;
    }

    .playlist-cover-large {
        width: 60px;
        height: 60px;
        border-radius: 14px;
    }

    .playlist-cover-large i {
        font-size: 24px;
    }

    .playlist-name-large {
        font-size: 18px;
    }

    .playlists-grid {
        grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
        gap: 16px;
        padding: 8px;
    }

    .filter-grid {
        grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
        gap: 10px;
    }
}

@media (max-width: 481px) {
    .tab-content {
        padding: 0 8px;
    }

    .player-playlists-grid {
        gap: 6px;
        max-height: 300px;
        padding: 4px 2px;
    }

    .player-playlists-empty {
        padding: 28px 12px;
    }

    .player-playlists-empty i {
        font-size: 32px;
    }

    .player-playlist-card {
        padding: 12px 14px;
        gap: 12px;
    }

    .player-playlist-card-icon {
        width: 40px;
        height: 40px;
        border-radius: 11px;
    }

    .player-playlist-card-icon i {
        font-size: 16px;
    }

    .playlist-info-section {
        gap: 14px;
        padding: 16px 6px 12px;
    }

    .playlist-cover-large {
        width: 54px;
        height: 54px;
        border-radius: 12px;
    }

    .playlist-cover-large i {
        font-size: 22px;
    }

    .playlist-name-large {
        font-size: 16px;
    }

    .playlist-actions-bar .play-all-btn {
        padding: 8px 18px;
        font-size: 12px;
    }

    .playlists-grid {
        grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
        gap: 12px;
        padding: 8px;
    }

    .filter-grid {
        grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
        gap: 8px;
    }
}

.tab-content {
    display: none;
    animation: fadeUp 0.4s ease;
    padding: 0 16px;
}

.tab-content.active {
    display: block;
}

.player-panel {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

@media (max-width: 480px) {
    .player-panel {
        gap: 12px !important;
    }
}

/* --- PLAYER PLAYLISTS TAB --- */

/* Responsive Player Nav Tabs */
/* ===== TABLET MEDIUM (1066px - 1024px) ===== */
@media (max-width: 1066px) {
    .player-nav-tabs {
        max-width: 95%;
        padding: 6px 10px;
        gap: 10px;
        margin: 0 auto 20px auto;
    }

    .nav-tab {
        padding: 7px 14px;
        font-size: 13px;
        gap: 6px;
    }

    .nav-tab i {
        font-size: 0.95rem;
    }

    .tabs-center {
        gap: 6px;
    }
}

/* ===== TABLET SMALL (1024px - 900px) ===== */
@media (max-width: 1024px) {
    .player-nav-tabs {
        max-width: 95%;
        padding: 5px 8px;
        gap: 8px;
        margin: 0 auto 18px auto;
        flex-wrap: wrap;
        justify-content: center;
    }

    .tabs-left,
    .tabs-right {
        order: 2;
        flex: 0 1 auto;
    }

    .tabs-center {
        order: 1;
        flex: 0 1 100%;
        gap: 6px;
        margin-bottom: 6px;
    }

    .nav-tab {
        padding: 6px 12px;
        font-size: 12px;
        border-radius: 10px;
        gap: 5px;
    }

    .nav-tab i {
        font-size: 0.9rem;
    }

    .nav-tab span {
        display: none !important;
    }

    .nav-tab span.tab-badge {
        display: inline-block !important;
    }
}

/* ===== TABLET (768px - 900px) ===== */
@media (max-width: 900px) {
    .player-nav-tabs {
        gap: 3px;
        padding: 5px;
        border-radius: 16px;
        flex-wrap: nowrap;
        overflow-x: auto;
        overflow-y: hidden;
        scroll-behavior: smooth;
    }

    .tabs-left,
    .tabs-right {
        order: 0;
        flex: 0 0 auto;
    }

    .tabs-center {
        order: 0;
        flex: 0 1 auto;
        gap: 3px;
    }

    .nav-tab {
        padding: 6px 10px;
        font-size: 11px;
        border-radius: 12px;
        flex-shrink: 0;
        gap: 4px;
    }

    .nav-tab span {
        display: none;
    }

    .nav-tab i {
        font-size: 13px;
    }

    .nav-tab .tab-badge {
        display: inline-block;
        padding: 1px 4px;
        font-size: 9px;
        position: static;
    }
}

/* ===== MOBILE LANDSCAPE (768px - 600px) ===== */
@media (max-width: 768px) {
    .player-nav-tabs {
        gap: 2px;
        padding: 4px;
        border-radius: 14px;
        overflow-x: auto;
        overflow-y: hidden;
        scroll-behavior: smooth;
        -webkit-overflow-scrolling: touch;
    }

    .player-nav-tabs::-webkit-scrollbar {
        height: 3px;
    }

    .player-nav-tabs::-webkit-scrollbar-track {
        background: rgba(255, 255, 255, 0.05);
        border-radius: 2px;
    }

    .player-nav-tabs::-webkit-scrollbar-thumb {
        background: rgba(139, 92, 246, 0.4);
        border-radius: 2px;
    }

    .tabs-left,
    .tabs-right,
    .tabs-center {
        flex: 0 0 auto;
    }

    .nav-tab {
        padding: 5px 8px;
        font-size: 10px;
        border-radius: 10px;
        flex-shrink: 0;
        gap: 3px;
    }

    .nav-tab span {
        display: none;
    }

    .nav-tab i {
        font-size: 12px;
    }

    .nav-tab .tab-badge {
        display: inline-block;
        padding: 1px 3px;
        font-size: 8px;
        position: static;
    }
}

/* ===== MOBILE SMALL (<600px) ===== */
@media (max-width: 600px) {
    .player-nav-tabs {
        gap: 1px;
        padding: 3px;
        border-radius: 12px;
    }

    .nav-tab {
        padding: 4px 6px;
        font-size: 9px;
        border-radius: 8px;
        gap: 2px;
    }

    .nav-tab i {
        font-size: 11px;
    }

    .nav-tab .tab-badge {
        padding: 0px 2px;
        font-size: 7px;
    }
}

@media (max-width: 480px) {
    .player-nav-tabs {
        gap: 2px;
        padding: 4px;
    }

    .nav-tab {
        padding: 8px 6px;
        font-size: 11px;
        gap: 4px;
    }

    .nav-tab span:not(.tab-badge):not(i) {
        display: none;
    }

    .nav-tab i {
        font-size: 14px;
    }

    .nav-tab .tab-badge {
        position: absolute;
        top: 2px;
        right: 2px;
        padding: 1px 4px;
        font-size: 9px;
    }
}

/* Legacy server-connection-bar styles hidden - migrated to integrated player-bar */
.server-connection-bar {
    display: none !important;
}

/* ============================================================================
   PLAYER PLAYLISTS TAB â€” Premium Redesign
   ============================================================================ */

.player-playlists-grid {
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-height: 420px;
    overflow-y: auto;
    padding: 8px 4px;
    scrollbar-width: thin;
    scrollbar-color: rgba(139, 92, 246, 0.25) transparent;
}

.player-playlists-grid::-webkit-scrollbar {
    width: 4px;
}

.player-playlists-grid::-webkit-scrollbar-thumb {
    background: rgba(139, 92, 246, 0.3);
    border-radius: 4px;
}

/* Empty / Loading State */
.player-playlists-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 56px 24px;
    color: var(--text-secondary);
    gap: 14px;
    text-align: center;
}

.player-playlists-empty i {
    font-size: 44px;
    opacity: 0.35;
    background: linear-gradient(135deg, var(--primary), #a855f7);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    filter: drop-shadow(0 0 18px rgba(139, 92, 246, 0.2));
    animation: emptyDiscSpin 8s linear infinite;
}

@keyframes emptyDiscSpin {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

.player-playlists-empty p {
    font-size: 14px;
    opacity: 0.7;
    line-height: 1.5;
}

.player-playlists-empty p:first-of-type {
    font-weight: 600;
    font-size: 15px;
    opacity: 0.85;
    color: var(--text-primary);
}

/* â”€â”€ Playlist Card â”€â”€ */

.player-playlist-card {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 16px;
    background: rgba(255, 255, 255, 0.025);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 14px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(.4, 0, .2, 1);
    position: relative;
    overflow: hidden;
    animation: playlistCardIn 0.35s ease both;
}

/* Staggered entrance for cards */
.player-playlist-card:nth-child(1) {
    animation-delay: 0s;
}

.player-playlist-card:nth-child(2) {
    animation-delay: 0.05s;
}

.player-playlist-card:nth-child(3) {
    animation-delay: 0.1s;
}

.player-playlist-card:nth-child(4) {
    animation-delay: 0.15s;
}

.player-playlist-card:nth-child(5) {
    animation-delay: 0.2s;
}

.player-playlist-card:nth-child(6) {
    animation-delay: 0.25s;
}

.player-playlist-card:nth-child(7) {
    animation-delay: 0.3s;
}

.player-playlist-card:nth-child(8) {
    animation-delay: 0.35s;
}

@keyframes playlistCardIn {
    from {
        opacity: 0;
        transform: translateY(12px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Shimmer sweep on hover */
.player-playlist-card::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(105deg,
            transparent 20%,
            rgba(139, 92, 246, 0.06) 40%,
            rgba(168, 85, 247, 0.08) 50%,
            rgba(139, 92, 246, 0.06) 60%,
            transparent 80%);
    transform: translateX(-100%);
    transition: transform 0.6s ease;
    pointer-events: none;
    border-radius: inherit;
}

.player-playlist-card:hover::before {
    transform: translateX(100%);
}

.player-playlist-card:hover {
    background: rgba(139, 92, 246, 0.08);
    border-color: rgba(139, 92, 246, 0.35);
    transform: translateX(4px);
    box-shadow:
        0 4px 24px rgba(139, 92, 246, 0.12),
        0 0 0 1px rgba(139, 92, 246, 0.08);
}

/* Locked Card */
.player-playlist-card.locked {
    opacity: 0.45;
    cursor: not-allowed;
    filter: grayscale(0.6) brightness(0.85);
}

.player-playlist-card.locked:hover {
    background: rgba(255, 255, 255, 0.025);
    border-color: rgba(255, 255, 255, 0.06);
    transform: none;
    box-shadow: none;
}

.player-playlist-card.locked:hover::before {
    transform: translateX(-100%);
}

.player-playlist-card .lock-overlay {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(0, 0, 0, 0.85);
    border-radius: 50%;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(255, 255, 255, 0.5);
    font-size: 11px;
    z-index: 2;
}

/* Card Icon */
.player-playlist-card-icon {
    width: 46px;
    height: 46px;
    border-radius: 13px;
    background: linear-gradient(135deg, #7c3aed 0%, #a855f7 60%, #c084fc 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    position: relative;
    box-shadow: 0 4px 14px rgba(124, 58, 237, 0.3);
    transition: all 0.3s ease;
}

.player-playlist-card:hover .player-playlist-card-icon {
    box-shadow: 0 6px 20px rgba(124, 58, 237, 0.45);
    transform: scale(1.05);
}

.player-playlist-card-icon i {
    color: white;
    font-size: 18px;
    transition: transform 0.4s ease;
}

.player-playlist-card:hover .player-playlist-card-icon i {
    transform: rotate(90deg);
}

/* Card Info */
.player-playlist-card-info {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.player-playlist-card-name {
    font-weight: 600;
    font-size: 14px;
    color: var(--text-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    letter-spacing: 0.01em;
    transition: color 0.2s ease;
}

.player-playlist-card:hover .player-playlist-card-name {
    color: #c4b5fd;
}

.player-playlist-card-count {
    font-size: 12px;
    color: var(--text-secondary);
    opacity: 0.6;
    display: flex;
    align-items: center;
    gap: 5px;
}

.player-playlist-card-count::before {
    content: 'â™«';
    font-size: 10px;
    opacity: 0.6;
}

/* Arrow */
.player-playlist-card-arrow {
    color: var(--text-secondary);
    opacity: 0.3;
    font-size: 12px;
    transition: all 0.3s cubic-bezier(.4, 0, .2, 1);
}

.player-playlist-card:hover .player-playlist-card-arrow {
    opacity: 1;
    color: #a78bfa;
    transform: translateX(4px);
}

/* ============================================================================
   PLAYLIST DETAIL VIEW (inside player tab)
   ============================================================================ */

.playlist-detail {
    display: flex;
    flex-direction: column;
    gap: 0;
    animation: detailViewSlideIn 0.35s ease both;
}

@keyframes detailViewSlideIn {
    from {
        opacity: 0;
        transform: translateX(20px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Detail Header */
.playlist-detail-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 4px 14px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.playlist-detail-header .back-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 14px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 10px;
    color: var(--text-secondary);
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.playlist-detail-header .back-btn:hover {
    background: rgba(255, 255, 255, 0.08);
    color: white;
    border-color: rgba(255, 255, 255, 0.15);
    transform: translateX(-2px);
}

.playlist-detail-header .back-btn i {
    font-size: 12px;
    transition: transform 0.2s ease;
}

.playlist-detail-header .back-btn:hover i {
    transform: translateX(-3px);
}

.playlist-detail-header .shuffle-btn {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 14px;
    transition: all 0.2s ease;
}

.playlist-detail-header .shuffle-btn:hover {
    background: rgba(139, 92, 246, 0.15);
    color: #a78bfa;
    border-color: rgba(139, 92, 246, 0.3);
}

/* Playlist Info Section (cover + meta) */
.playlist-info-section {
    display: flex;
    align-items: center;
    gap: 18px;
    padding: 20px 8px 16px;
}

.playlist-cover-large {
    width: 72px;
    height: 72px;
    border-radius: 16px;
    background: linear-gradient(135deg, #7c3aed 0%, #a855f7 50%, #c084fc 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    box-shadow:
        0 8px 28px rgba(124, 58, 237, 0.3),
        0 0 0 1px rgba(139, 92, 246, 0.2);
    position: relative;
    overflow: hidden;
}

.playlist-cover-large::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, transparent 40%, rgba(255, 255, 255, 0.12) 50%, transparent 60%);
    pointer-events: none;
}

.playlist-cover-large i {
    font-size: 28px;
    color: white;
    filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.3));
    z-index: 1;
}

.playlist-meta-large {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.playlist-name-large {
    font-size: 20px;
    font-weight: 800;
    color: var(--text-primary);
    margin: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    letter-spacing: -0.01em;
    line-height: 1.2;
}

.playlist-info-text {
    font-size: 13px;
    color: var(--text-secondary);
    opacity: 0.65;
    margin: 0;
}

/* Actions Bar */
.playlist-actions-bar {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 0 8px 16px;
}

.playlist-actions-bar .play-all-btn {
    display: flex;
    align-items: center;
    gap: 9px;
    padding: 10px 22px;
    background: linear-gradient(135deg, #7c3aed 0%, #a855f7 100%);
    border: none;
    border-radius: 24px;
    color: white;
    font-weight: 700;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.25s cubic-bezier(.4, 0, .2, 1);
    box-shadow: 0 4px 18px rgba(124, 58, 237, 0.35);
    letter-spacing: 0.02em;
    position: relative;
    overflow: hidden;
}

.playlist-actions-bar .play-all-btn::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.15) 0%, transparent 50%);
    pointer-events: none;
}

.playlist-actions-bar .play-all-btn:hover {
    transform: translateY(-2px) scale(1.03);
    box-shadow: 0 8px 30px rgba(124, 58, 237, 0.5);
}

.playlist-actions-bar .play-all-btn:active {
    transform: translateY(0) scale(0.97);
    box-shadow: 0 2px 10px rgba(124, 58, 237, 0.3);
}

.playlist-actions-bar .play-all-btn i {
    font-size: 12px;
}

/* Playlist Tracks List */
.player-playlist-tracks {
    display: flex;
    flex-direction: column;
    gap: 2px;
    flex: 1;
    padding: 0 4px;
}

.player-playlist-tracks::-webkit-scrollbar {
    width: 4px;
}

.player-playlist-tracks::-webkit-scrollbar-thumb {
    background: rgba(139, 92, 246, 0.25);
    border-radius: 4px;
}

.player-playlist-track-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 12px;
    border-radius: 12px;
    transition: all 0.2s ease;
    position: relative;
}

.player-playlist-track-item:hover {
    background: rgba(255, 255, 255, 0.04);
}

/* Track number â†’ play icon on hover */
.player-playlist-track-num {
    font-size: 13px;
    color: var(--text-secondary);
    opacity: 0.45;
    width: 26px;
    text-align: center;
    flex-shrink: 0;
    font-weight: 700;
    font-variant-numeric: tabular-nums;
    transition: all 0.2s ease;
}

.player-playlist-track-item:hover .player-playlist-track-num {
    opacity: 0.8;
    color: #a78bfa;
}

.player-playlist-track-info {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.player-playlist-track-title {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    transition: color 0.2s ease;
}

.player-playlist-track-item:hover .player-playlist-track-title {
    color: #e0d4fc;
}

.player-playlist-track-artist {
    font-size: 11px;
    color: var(--text-secondary);
    opacity: 0.6;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.player-playlist-track-play {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.25s cubic-bezier(.4, 0, .2, 1);
    flex-shrink: 0;
    opacity: 0;
    transform: scale(0.85);
}

.player-playlist-track-item:hover .player-playlist-track-play {
    opacity: 1;
    transform: scale(1);
}

.player-playlist-track-play:hover {
    background: linear-gradient(135deg, #7c3aed, #a855f7);
    border-color: transparent;
    color: white;
    box-shadow: 0 0 18px rgba(139, 92, 246, 0.45);
    transform: scale(1.15) !important;
}

.player-playlist-track-play i {
    font-size: 11px;
    margin-left: 1px;
}

/* Old player-playlist-detail class (kept for backward compat) */
.player-playlist-detail {
    display: flex;
    flex-direction: column;
    gap: 0;
    max-height: 420px;
    animation: detailViewSlideIn 0.35s ease both;
}

/* --- NOW PLAYING AREA (Hero Style) â€” PREMIUM REDESIGN --- */
.now-playing-area {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 28px;
    max-width: 860px;
    margin: 0 auto;
    position: relative;
    padding: 16px 0 0;
}

/* Empty State */
.empty-state {
    padding: 80px 40px;
    text-align: center;
}

.empty-icon {
    width: 130px;
    height: 130px;
    margin: 0 auto 36px auto;
    background: linear-gradient(145deg, rgba(139, 92, 246, 0.12), rgba(168, 139, 250, 0.04));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 52px;
    color: #a78bfa;
    border: 1.5px solid rgba(139, 92, 246, 0.2);
    box-shadow:
        0 12px 40px rgba(0, 0, 0, 0.45),
        0 0 30px rgba(139, 92, 246, 0.15),
        inset 0 1px 0 rgba(255, 255, 255, 0.05);
    animation: floatingIcon 4s ease-in-out infinite;
}

@keyframes floatingIcon {

    0%,
    100% {
        transform: translateY(0) scale(1);
    }

    50% {
        transform: translateY(-12px) scale(1.02);
    }
}

.empty-title {
    font-size: 1.8rem;
    font-weight: 800;
    color: #ffffff;
    margin-bottom: 12px;
    letter-spacing: -0.02em;
}

.empty-subtitle {
    font-size: 1rem;
    color: rgba(255, 255, 255, 0.45);
    max-width: 400px;
    margin: 0 auto;
    line-height: 1.6;
}

/* Now Playing Hero Section â€” CINEMATIC PREMIUM */
.track-display {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 36px;
    width: 100%;
    padding: 24px 0;
    animation: trackFadeIn 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes trackFadeIn {
    from {
        opacity: 0;
        transform: translateY(20px) scale(0.97);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.track-visual {
    position: relative;
    width: 100%;
    max-width: 380px;
    aspect-ratio: 1;
    margin: 0 auto;
    perspective: 1200px;
}

.track-artwork {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 28px;
    box-shadow:
        0 24px 64px rgba(0, 0, 0, 0.65),
        0 0 0 1px rgba(255, 255, 255, 0.06),
        0 0 80px rgba(139, 92, 246, 0.08);
    transition: all 0.6s cubic-bezier(0.16, 1, 0.3, 1);
    position: relative;
    z-index: 2;
}

.track-visual:hover .track-artwork {
    transform: translateY(-8px) scale(1.02);
    box-shadow:
        0 36px 80px rgba(0, 0, 0, 0.75),
        0 0 40px rgba(139, 92, 246, 0.15),
        0 0 0 1px rgba(255, 255, 255, 0.08);
}

.artwork-glow {
    position: absolute;
    inset: -50px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(139, 92, 246, 0.25) 0%, rgba(217, 70, 239, 0.1) 40%, transparent 70%);
    filter: blur(90px);
    opacity: 0.5;
    z-index: 1;
    animation: pulseGlow 6s ease-in-out infinite alternate;
}

@keyframes pulseGlow {
    0% {
        opacity: 0.35;
        transform: scale(0.92);
    }

    100% {
        opacity: 0.65;
        transform: scale(1.08);
    }
}

.track-details {
    text-align: center;
    max-width: 700px;
    z-index: 2;
    padding: 0 16px;
}

.track-title {
    font-size: clamp(26px, 4.5vw, 40px);
    font-weight: 900;
    line-height: 1.15;
    margin-bottom: 10px;
    letter-spacing: -0.03em;
    background: linear-gradient(180deg, #ffffff 0%, #e2e8f0 50%, #94a3b8 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    filter: drop-shadow(0 4px 12px rgba(0, 0, 0, 0.4));
}

.track-artist {
    font-size: clamp(14px, 1.8vw, 18px);
    font-weight: 600;
    color: rgba(255, 255, 255, 0.5);
    letter-spacing: 0.08em;
    text-transform: uppercase;
}


/* --- QUEUE LIST --- */
.queue-list-container {
    margin: 0 auto;
    padding-bottom: 120px;
    overflow-y: auto;
    scrollbar-width: thin;
    padding: 8px 4px;
}

.queue-list-container::-webkit-scrollbar {
    width: 4px;
}

.queue-list-container::-webkit-scrollbar-thumb {
    background: rgba(124, 58, 237, 0.3);
    border-radius: 2px;
}

.queue-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.queue-item-sidebar {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px 24px;
    background: var(--bg-card);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-lg);
    transition: var(--transition-fast);
    position: relative;
    overflow: hidden;
}

.queue-item-info {
    flex: 1;
    min-width: 0;
}

.queue-item-title {
    font-weight: 600;
    color: var(--text-primary);
    font-size: 15px;
    margin-bottom: 4px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.queue-item-artist {
    font-size: 13px;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    gap: 6px;
}

.queue-item-artist i {
    font-size: 11px;
}

/* Drag Handle (Visual) */
.queue-drag-handle {
    color: var(--text-muted);
    cursor: grab;
    padding: 4px;
    opacity: 0;
    transition: opacity 0.2s;
}

.queue-item-sidebar:hover .queue-drag-handle {
    opacity: 1;
}


/* --- RECOMMENDATIONS --- */
.recommended-list {
    max-width: 1000px;
    margin: 0 auto;
    padding-bottom: 120px;
    scrollbar-width: thin;
    padding: 8px 4px;
}

.recommended-list::-webkit-scrollbar {
    width: 4px;
}

.recommended-list::-webkit-scrollbar-thumb {
    background: rgba(124, 58, 237, 0.3);
    border-radius: 2px;
}

.recommended-tracks-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 20px;
    padding: 24px 0;
}

.recommended-track-item {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 12px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.04);
    border-radius: 18px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    position: relative;
    overflow: hidden;
    width: 100%;
}

.recommended-track-item:hover {
    background: rgba(139, 92, 246, 0.06);
    border-color: rgba(139, 92, 246, 0.2);
    transform: translateY(-4px);
    box-shadow:
        0 15px 30px rgba(0, 0, 0, 0.4),
        0 0 15px rgba(139, 92, 246, 0.1);
}

.recommended-track-artwork-container {
    width: 64px;
    height: 64px;
    border-radius: 14px;
    position: relative;
    overflow: hidden;
    flex-shrink: 0;
    background: #0a0a0f;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.recommended-track-artwork-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.recommended-track-item:hover .recommended-track-artwork-img {
    transform: scale(1.15);
}

.recommended-track-artwork-fallback {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.1), rgba(168, 139, 250, 0.05));
    color: #a78bfa;
    font-size: 1.4rem;
}

.recommended-track-artwork-overlay {
    position: absolute;
    inset: 0;
    background: rgba(139, 92, 246, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
    backdrop-filter: blur(2px);
}

.recommended-track-item:hover .recommended-track-artwork-overlay {
    opacity: 1;
}

.recommended-track-artwork-overlay i {
    color: white;
    font-size: 1.2rem;
    filter: drop-shadow(0 0 10px rgba(255, 255, 255, 0.8));
    transform: scale(0.8);
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.recommended-track-item:hover .recommended-track-artwork-overlay i {
    transform: scale(1);
}

.recommended-track-info {
    flex: 1;
    min-width: 0;
}

.recommended-track-title {
    font-weight: 700;
    font-size: 1rem;
    color: #ffffff;
    margin-bottom: 4px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.recommended-track-artist {
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.5);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    letter-spacing: 0.01em;
}

.add-btn {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: none;
    background: rgba(255, 255, 255, 0.08);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition-spring);
}


/* ============================================
   PLAYER BAR â€” PREMIUM FLOATING PILL REDESIGN
   ============================================ */

.player-bar {
    position: fixed;
    bottom: 47px;
    left: 12px;
    width: calc(100% - 24px);
    z-index: 1000;
    transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.3s ease;
    background: rgb(12 10 20 / 52%);
    pointer-events: none;
    border-radius: 0px 0px 20px 20px;
    transform: none;
}

.player-content {
    pointer-events: auto;
    height: 80px;
    background: rgba(12, 10, 20, 0.6);
    backdrop-filter: blur(48px) saturate(1.8);
    -webkit-backdrop-filter: blur(48px) saturate(1.8);
    border-top: 1px solid rgba(255, 255, 255, 0.07);
    border-radius: 20px 20px 0 0;
    padding: 0 28px;
    display: grid;
    grid-template-columns: 220px 1fr 300px;
    align-items: center;
    gap: 0;
    position: relative;
    overflow: visible;
    box-shadow: inset 0 1px 0 rgba(139, 92, 246, 0.12);
    transition: border-top-color 0.3s ease;
}

/* Glowing top accent line */
.player-content::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg,
            transparent 0%,
            rgba(139, 92, 246, 0.5) 20%,
            rgba(168, 139, 250, 0.9) 50%,
            rgba(139, 92, 246, 0.5) 80%,
            transparent 100%);
    opacity: 0;
    transition: opacity 0.4s ease;
    z-index: 2;
}

.player-bar.is-playing .player-content::before {
    opacity: 1;
    animation: barTopGlow 4s ease-in-out infinite alternate;
}

@keyframes barTopGlow {
    from {
        opacity: 0.55;
    }

    to {
        opacity: 1;
    }
}

.pv-bar-track {
    position: relative;
    padding-right: 28px;
}

.pv-bar-controls {
    position: relative;
    padding: 0 20px;
}

/* Vertical section dividers */
.pv-bar-track::after,
.pv-bar-controls::after {
    content: '';
    position: absolute;
    right: 0;
    top: 18%;
    bottom: 18%;
    width: 1px;
    background: rgba(255, 255, 255, 0.055);
}

.player-right-wrapper {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 16px;
    width: 100%;
    padding-left: 28px;
}

/* Ambient glow above bar */
.player-ambient-glow {
    position: absolute;
    top: -28px;
    left: 50%;
    transform: translateX(-50%);
    width: 55%;
    height: 28px;
    background: radial-gradient(ellipse, rgba(139, 92, 246, 0.2) 0%, transparent 70%);
    pointer-events: none;
    z-index: -1;
    opacity: 0;
    filter: blur(6px);
    transition: opacity 0.4s ease;
}

.player-bar.is-playing .player-ambient-glow {
    opacity: 1;
    animation: ambientPulse 3s ease-in-out infinite alternate;
}

@keyframes ambientPulse {
    from {
        opacity: 0.5;
        width: 45%;
    }

    to {
        opacity: 1;
        width: 65%;
    }
}

.player-bar.player-hidden {
    transform: translateY(100%);
    opacity: 0;
    pointer-events: none;
}

/* â”€â”€ LEFT: Track Info â”€â”€ */
.player-track {
    display: flex;
    align-items: center;
    gap: 14px;
    min-width: 0;
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
}

.player-artwork-wrap {
    width: 52px;
    height: 52px;
    border-radius: 12px;
    overflow: hidden;
    flex-shrink: 0;
    box-shadow:
        0 4px 16px rgba(0, 0, 0, 0.5),
        0 0 0 1px rgba(255, 255, 255, 0.06);
    transition: all 0.3s ease;
    position: relative;
}

.player-artwork-wrap::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 12px;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.08) 0%, transparent 50%);
    pointer-events: none;
}

.player-bar.is-playing .player-artwork-wrap {
    box-shadow:
        0 4px 20px rgba(139, 92, 246, 0.2),
        0 0 0 1px rgba(139, 92, 246, 0.15);
}

.player-thumb {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.player-artwork-wrap:hover .player-thumb {
    transform: scale(1.08);
}

/* Hide these decorative elements â€” not needed in new design */
.player-artwork-ring,
.player-artwork-spin {
    display: none;
}

.player-info {
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-width: 0;
    gap: 2px;
}

.player-track-title {
    font-size: 14px;
    font-weight: 700;
    color: #fff;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    letter-spacing: -0.01em;
    line-height: 1.3;
}

.player-track-artist {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.45);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-weight: 500;
}

.volume-control {
    display: flex;
    align-items: center;
    gap: 10px;
    background: rgba(255, 255, 255, 0.035);
    padding: 6px 12px;
    border-radius: var(--radius-full);
    border: 1px solid rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(10px);
}

/* â”€â”€ SERVER: Integrated Connection Card â”€â”€ */
.player-server {
    display: flex;
    justify-content: flex-end;
}

.player-server-card {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 18px;
    background: rgba(255, 255, 255, 0.035);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 20px;
    width: 250px;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    cursor: default;
    position: relative;
    overflow: hidden;
}

.player-server-card:hover {
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(255, 255, 255, 0.15);
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3), 0 0 20px rgba(139, 92, 246, 0.05);
}

.player-server-icon {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    object-fit: cover;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.player-server-details {
    display: flex;
    flex-direction: column;
    min-width: 0;
    flex: 1;
    gap: 2px;
}

.player-server-name-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.player-server-name {
    font-size: 13px;
    font-weight: 700;
    color: #fff;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    letter-spacing: -0.01em;
}

.player-server-status {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 10px;
    color: rgba(255, 255, 255, 0.4);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.status-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #4b5563;
    box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.05);
    transition: all 0.4s ease;
}

.player-server-status.connected .status-dot {
    background: #10b981;
    box-shadow: 0 0 10px #10b981, 0 0 0 2px rgba(16, 185, 129, 0.1);
    animation: statusPulse 2s infinite;
}

@keyframes statusPulse {

    0%,
    100% {
        transform: scale(1);
        opacity: 1;
    }

    50% {
        transform: scale(1.2);
        opacity: 0.8;
    }
}

.server-plan-badge {
    padding: 2px 6px;
    border-radius: 5px;
    font-size: 9px;
    font-weight: 900;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

.server-plan-badge.premium {
    background: linear-gradient(135deg, #a855f7, #6366f1);
    color: white;
    box-shadow: 0 2px 8px rgba(139, 92, 246, 0.4);
}

.server-plan-badge.free {
    background: rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.05);
}

/* Responsive Integrated Server Info (Desktop Mid) */
@media (max-width: 1200px) {
    .player-content {
        grid-template-columns: minmax(180px, 240px) 1.2fr auto;
        gap: 16px;
        padding: 0 20px;
    }

    .player-server-card {
        width: 100%;
        padding: 8px 12px;
    }
}

/* Tablet optimization - Keep server info visible but compact */
@media (max-width: 1100px) {
    .player-content {
        grid-template-columns: minmax(160px, 200px) 1.5fr auto;
        gap: 12px;
        padding: 0 16px;
    }

    .player-server-card {
        width: 180px;
        padding: 6px 10px;
    }

    .player-server-icon {
        width: 32px;
        height: 32px;
    }

    .player-server-name {
        font-size: 11px;
    }

    .player-server-status {
        font-size: 9px;
    }
}

.control-buttons {
    display: flex;
    align-items: center;
    gap: 8px;
}

.control-btn {
    width: 34px;
    height: 34px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(255, 255, 255, 0.5);
    background: transparent;
    border: none;
    cursor: pointer;
    font-size: 13px;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
}

.control-btn:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.08);
    transform: scale(1.12);
}

.control-btn:active {
    transform: scale(0.95);
}

.control-btn.active {
    color: #a78bfa;
    text-shadow: 0 0 12px rgba(139, 92, 246, 0.6);
    background: rgba(139, 92, 246, 0.1);
}

.control-btn-nav {
    width: 36px;
    height: 36px;
    font-size: 15px;
    color: rgba(255, 255, 255, 0.65);
}

.control-btn-nav:hover {
    color: #fff;
    transform: scale(1.18);
}

/* Stop button subtle danger hint on hover */
.control-btn-stop:hover {
    color: #f87171;
    background: rgba(239, 68, 68, 0.08);
}

.control-btn-play {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: #ffffff;
    color: #0a0a12;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    border: none;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    box-shadow:
        0 4px 16px rgba(255, 255, 255, 0.15),
        0 0 0 0 rgba(255, 255, 255, 0);
    margin: 0 6px;
    position: relative;
}

.control-btn-play:hover {
    transform: scale(1.12);
    box-shadow:
        0 6px 24px rgba(255, 255, 255, 0.25),
        0 0 30px rgba(255, 255, 255, 0.1);
}

.control-btn-play:active {
    transform: scale(0.95);
    box-shadow: 0 2px 8px rgba(255, 255, 255, 0.1);
}

.play-btn-inner {
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Progress Section */
.progress-section {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    max-width: 480px;
}

.time {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.35);
    font-variant-numeric: tabular-nums;
    width: 36px;
    text-align: center;
    font-weight: 500;
    letter-spacing: 0.02em;
}

.progress-bar {
    flex: 1;
    height: 4px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 4px;
    position: relative;
    cursor: pointer;
    transition: height 0.2s ease;
}

.progress-bar:hover {
    height: 6px;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #8b5cf6 0%, #c084fc 50%, #d946ef 100%);
    border-radius: 4px;
    position: relative;
    width: 0%;
    transition: background 0.3s ease;
}

.progress-glow {
    position: absolute;
    right: 0;
    top: -3px;
    width: 10px;
    height: 10px;
    background: #d946ef;
    border-radius: 50%;
    filter: blur(6px);
    opacity: 0;
    transition: opacity 0.2s ease;
}

.progress-bar:hover .progress-glow {
    opacity: 0.6;
}

.progress-fill::after {
    content: '';
    position: absolute;
    right: -5px;
    top: 50%;
    transform: translateY(-50%);
    width: 12px;
    height: 12px;
    background: #fff;
    border-radius: 50%;
    box-shadow:
        0 0 8px rgba(139, 92, 246, 0.6),
        0 0 20px rgba(139, 92, 246, 0.3);
    opacity: 0;
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.progress-bar:hover .progress-fill::after {
    opacity: 1;
    transform: translateY(-50%) scale(1);
}

.progress-track {
    display: none;
}

.progress-thumb-dot {
    display: none;
}

.progress-slider {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
    z-index: 2;
    margin: 0;
}

/* â”€â”€ RIGHT: Volume & Utilities â”€â”€ */
.player-right {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 8px;
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
}

.player-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    padding-right: 0;
    border-right: none;
}

.icon-btn {
    width: 34px;
    height: 34px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.04);
    color: rgba(255, 255, 255, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.06);
    cursor: pointer;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    font-size: 13px;
}

.icon-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    transform: translateY(-1px);
    border-color: rgba(255, 255, 255, 0.15);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.icon-btn:active {
    transform: translateY(0) scale(0.95);
}

#fx-btn.active {
    background: rgba(139, 92, 246, 0.12);
    color: #a78bfa;
    border-color: rgba(139, 92, 246, 0.3);
    box-shadow: 0 0 16px rgba(139, 92, 246, 0.15);
}

.volume-control {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 140px;
}

.volume-track-wrap {
    flex: 1;
    height: 20px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 4px;
    position: relative;
    cursor: pointer;
    transition: height 0.2s ease;
    display: flex;
    align-items: center;
}

.volume-track-wrap:hover {
    height: 5px;
}

.volume-fill-bg {
    display: none;
}

.volume-fill-bar {
    height: 100%;
    background: linear-gradient(90deg, rgba(255, 255, 255, 0.7), #fff);
    border-radius: 4px;
    width: 100%;
    transition: background 0.2s ease;
}

.volume-slider {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    opacity: 1;
    cursor: pointer;
    z-index: 2;
    margin: 0;
    appearance: none;
    -webkit-appearance: none;
    background: transparent;
    border: none;
    padding: 0;
}

/* Webkit slider styles for volume */
.volume-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 12px;
    height: 12px;
    background: #fff;
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 0 8px rgba(139, 92, 246, 0.6);
    transition: all 0.2s ease;
}

.volume-slider::-webkit-slider-thumb:hover {
    width: 14px;
    height: 14px;
    box-shadow: 0 0 12px rgba(139, 92, 246, 0.9);
}

/* Firefox slider styles for volume */
.volume-slider::-moz-range-thumb {
    width: 12px;
    height: 12px;
    background: #fff;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 0 8px rgba(139, 92, 246, 0.6);
    transition: all 0.2s ease;
}

.volume-slider::-moz-range-thumb:hover {
    width: 14px;
    height: 14px;
    box-shadow: 0 0 12px rgba(139, 92, 246, 0.9);
}

.volume-pct {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.35);
    width: 26px;
    font-variant-numeric: tabular-nums;
    font-weight: 500;
    text-align: right;
}

.volume-icon {
    background: transparent;
    border: none;
    width: auto;
    height: auto;
    font-size: 14px;
}

.volume-icon:hover {
    background: transparent;
    border: none;
    box-shadow: none;
    transform: scale(1.1);
}


/* Minimized State */
.player-bar.player-minimized {
    transform: translateY(calc(100% - 48px));
}

@media (max-width: 1024px) {
    .player-bar.player-minimized {
        transform: translateY(calc(100% - 48px));
    }
}

/* ============================================
PLAYER BAR â€" RESPONSIVE BREAKPOINTS
============================================ */

/* --- DESKTOP LARGE (1440px+) --- */
@media (min-width: 1441px) {
    .player-content {
        height: 80px;
        padding: 0 40px;
        gap: 0;
    }
}

/* --- DESKTOP MEDIUM (1200px - 1440px) --- */
@media (max-width: 1440px) {
    .player-content {
        height: 80px;
        padding: 0 28px;
        gap: 0;
    }
}

/* --- DESKTOP SMALL (1024px - 1199px) --- */
@media (max-width: 1199px) {
    .player-content {
        height: 76px;
        padding: 0 24px;
        gap: 24px;
        grid-template-columns: 180px 1fr auto;
    }

    .player-artwork-wrap {
        width: 48px;
        height: 48px;
        border-radius: 10px;
    }

    .player-info {
        gap: 3px;
    }

    .player-track-title {
        font-size: 14px;
    }

    .player-track-artist {
        font-size: 12px;
    }

    .control-btn {
        width: 32px;
        height: 32px;
        font-size: 13px;
    }

    .control-btn-nav {
        width: 34px;
        height: 34px;
        font-size: 15px;
    }

    .control-btn-play {
        width: 44px;
        height: 44px;
        font-size: 16px;
    }

    .control-buttons {
        gap: 8px;
    }

    .volume-control {
        width: 130px;
    }

    .time {
        font-size: 11px;
        width: 34px;
    }

    .player-server-card {
        width: 220px;
        padding: 9px 16px;
        gap: 10px;
    }
}

/* --- TABLET LANDSCAPE (1024px - 769px) --- */
@media (max-width: 1024px) {
    .player-bar {
        bottom: 47px;
        transform: none;
    }

    .player-content {
        height: 72px;
        padding: 0 20px;
        gap: 16px;
        grid-template-columns: 140px 1fr 120px;
    }

    .player-artwork-wrap {
        width: 44px;
        height: 44px;
        border-radius: 9px;
    }

    .player-info {
        gap: 2px;
    }

    .player-track-title {
        font-size: 13px;
    }

    .player-track-artist {
        font-size: 11px;
    }

    .control-btn {
        width: 28px;
        height: 28px;
        font-size: 11px;
    }

    .control-btn-nav {
        width: 30px;
        height: 30px;
        font-size: 13px;
    }

    .control-btn-play {
        width: 38px;
        height: 38px;
        font-size: 14px;
    }

    .control-buttons {
        gap: 5px;
    }

    .volume-control {
        width: 110px;
        padding: 5px 10px;
    }

    .time {
        font-size: 10px;
        width: 30px;
    }

    .player-server-card {
        width: 200px;
        padding: 8px 14px;
        gap: 8px;
        font-size: 12px;
    }

    .player-right-wrapper {
        gap: 16px;
    }
}

/* --- TABLET PORTRAIT (768px - 769px) --- */
@media (max-width: 768px) {
    .player-bar {
        bottom: 0;
        transform: none;
        max-width: 100%;
        z-index: 1001;
        transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    }

    /* NEW RESPONSIVE PLAYER LAYOUT FOR TABLETS */
    .player-content {
        height: 68px;
        border-radius: 0;
        padding: 0 16px;
        display: grid;
        flex-direction: row;
        align-items: center;
        gap: 12px;
        grid-template-columns: 140px 1fr 100px;
        background: rgba(8, 8, 16, 0.98);
        border: none;
        border-top: 1px solid rgba(139, 92, 246, 0.18);
        box-shadow: 0 -8px 30px rgba(0, 0, 0, 0.7);
    }

    .player-content:hover {
        box-shadow: 0 -8px 30px rgba(0, 0, 0, 0.6);
    }

    .player-ambient-glow {
        display: none;
    }

    .player-hidden {
        transform: translateY(100%);
        opacity: 0;
        pointer-events: none;
    }

    /* Drag pill + toggle removed */

    /* Track info row */
    .player-track {
        display: flex;
        flex-direction: row;
        align-items: center;
        gap: 12px;
        width: 100%;
        margin-bottom: 16px;
        flex: none;
    }

    .player-artwork-wrap {
        width: 50px;
        height: 50px;
        border-radius: 12px;
        flex-shrink: 0;
    }

    .player-artwork-wrap::after {
        border-radius: 12px;
    }

    .player-info {
        flex: 1;
        min-width: 0;
        gap: 3px;
    }

    .player-track-title {
        font-size: 15px;
        font-weight: 700;
    }

    .player-track-artist {
        font-size: 12px;
    }

    /* CONTROLS ROW - Flexible Grid */
    .player-controls {
        display: grid;
        grid-template-columns: repeat(7, 1fr);
        gap: 8px;
        width: 100%;
        margin: 16px 0;
        align-items: center;
        justify-items: center;
    }

    .control-buttons {
        grid-column: 1 / -1;
        display: flex;
        justify-content: center;
        gap: 10px;
        width: 100%;
    }

    .control-btn {
        width: 36px;
        height: 36px;
        font-size: 13px;
    }

    .control-btn-nav {
        width: 36px;
        height: 36px;
        font-size: 15px;
    }

    .control-btn-play {
        width: 48px;
        height: 48px;
        font-size: 18px;
    }

    /* PROGRESS BAR */
    .progress-wrapper {
        width: 100%;
        margin: 14px 0;
    }

    /* VOLUME & RIGHT SECTION */
    .player-right-wrapper {
        display: flex;
        flex-direction: column;
        gap: 12px;
        width: 100%;
        align-items: stretch;
    }

    .player-right {
        display: flex;
        flex-direction: row;
        justify-content: space-between;
        gap: 10px;
        width: 100%;
    }

    .player-actions {
        display: flex;
        gap: 8px;
        flex: 1;
    }

    .volume-control {
        display: flex;
        align-items: center;
        gap: 8px;
        width: 100%;
        background: rgba(255, 255, 255, 0.035);
        padding: 8px 12px;
        border-radius: var(--radius-full);
        border: 1px solid rgba(255, 255, 255, 0.08);
    }

    .player-server {
        display: flex;
        justify-content: center;
    }

    .player-server-card {
        width: auto;
        min-width: 200px;
        padding: 10px 16px;
        font-size: 12px;
    }
}

/* ===== MOBILE PHONE (<600px) - ADDITIONAL REFINEMENTS ===== */
@media (max-width: 600px) {

    .progress-section {
        display: flex;
        flex-direction: row;
        align-items: center;
        gap: 10px;
        width: 100%;
        margin-bottom: 14px;
    }

    .time {
        font-size: 11px;
        width: 36px;
    }

    .player-right {
        display: flex;
        flex-direction: row;
        align-items: center;
        gap: 10px;
        width: 100%;
        margin-top: 10px;
        padding-top: 10px;
        border-top: 1px solid rgba(255, 255, 255, 0.05);
    }

    .player-server {
        order: -1;
        margin-bottom: 12px;
        display: block !important;
    }

    .player-server-card {
        width: 100%;
        background: rgba(255, 255, 255, 0.04);
        border-color: rgba(255, 255, 255, 0.08);
        padding: 8px 12px;
        border-radius: 14px;
    }

    .player-server-icon {
        width: 32px;
        height: 32px;
        border-radius: 8px;
    }

    .player-server-name {
        font-size: 12px;
    }

    .player-server-status {
        font-size: 9px;
    }
}

/* â”€â”€ ROW 1: Track info â”€â”€ */
.player-track {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 12px;
    width: 100%;
    margin-bottom: 14px;
    flex: none;
}

.player-artwork-wrap {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    flex-shrink: 0;
}

.player-artwork-wrap::after {
    border-radius: 12px;
}

.player-info {
    flex: 1;
    min-width: 0;
}

.player-track-title {
    font-size: 14px;
    font-weight: 700;
}

.player-track-artist {
    font-size: 12px;
}

/* â”€â”€ ROW 2: Transport buttons â”€â”€ */
.player-controls {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
    width: 100%;
    max-width: 100%;
    margin-bottom: 0;
}

.control-buttons {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    width: auto;
    gap: 10px;
    margin: 0 auto;
}

.control-btn {
    width: 38px;
    height: 38px;
    font-size: 15px;
    border-radius: 10px;
    flex-shrink: 0;
}

.control-btn-nav {
    width: 40px;
    height: 40px;
    font-size: 17px;
}

.control-btn-play {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    font-size: 20px;
    margin: 0 4px;
    flex-shrink: 0;
}

/* â”€â”€ ROW 3: Progress â”€â”€ */
.progress-section {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 10px;
    width: 100%;
    max-width: 100%;
    margin-bottom: 14px;
}

.time {
    font-size: 11px;
    width: 36px;
}

/* â”€â”€ ROW 4: Actions + Volume â”€â”€ */
.player-right {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 10px;
    width: 100%;
    margin-top: 10px;
    padding-top: 10px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

/* Mobile Server Info integration */
.player-server {
    order: -1;
    margin-bottom: 12px;
    display: block !important;
}

.player-server-card {
    width: 100%;
    background: rgba(255, 255, 255, 0.04);
    border-color: rgba(255, 255, 255, 0.08);
    padding: 8px 12px;
    border-radius: 14px;
}

.player-server-icon {
    width: 32px;
    height: 32px;
    border-radius: 8px;
}

.player-server-name {
    font-size: 12px;
}

.player-server-status {
    font-size: 9px;
}

.player-actions {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 6px;
    border-right: none;
    padding-right: 0;
    margin-right: 0;
    flex-shrink: 0;
}

#fx-btn {
    width: 38px;
    height: 38px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
    margin-left: 0;
}

#leave-btn {
    width: 38px;
    height: 38px;
    background: rgba(239, 68, 68, 0.12);
    border: 1px solid rgba(239, 68, 68, 0.2);
    border-radius: 10px;
    color: var(--danger);
}

#leave-btn:hover {
    background: rgba(239, 68, 68, 0.25);
    color: #fff;
}

.volume-control {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 10px;
    flex: 1;
    width: auto;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 12px;
    padding: 9px 14px;
}

.volume-icon {
    flex-shrink: 0;
    width: 20px;
    height: 20px;
    font-size: 13px;
    background: transparent;
}

.volume-track-wrap {
    flex: 1;
    width: auto;
}

.volume-pct {
    font-size: 10.5px;
    width: 28px;
    text-align: right;
}

/* Minimised - leave only the toggle pill visible */
.player-bar.player-minimized {
    transform: translateY(calc(100% - 38px));
}

/* --- Small phones (<480px) --- */
@media (max-width: 480px) {
    .player-content {
        padding: 10px 14px 14px;
    }

    .player-artwork-wrap {
        width: 42px;
        height: 42px;
        border-radius: 10px;
    }

    .player-track-title {
        font-size: 13px;
    }

    .player-track-artist {
        font-size: 11px;
    }

    .control-btn {
        width: 34px;
        height: 34px;
        font-size: 14px;
    }

    .control-btn-nav {
        width: 36px;
        height: 36px;
        font-size: 16px;
    }

    .control-btn-play {
        width: 48px;
        height: 48px;
        font-size: 18px;
    }

    .control-buttons {
        gap: 8px;
    }

    .volume-control {
        padding: 8px 12px;
    }
}

/* --- Extra small (<360px) --- */
@media (max-width: 360px) {
    .player-content {
        padding: 8px 12px 12px;
    }

    #stop-btn,
    #autoplay-btn {
        display: none;
    }

    .player-artwork-wrap {
        width: 38px;
        height: 38px;
    }

    .control-btn-play {
        width: 44px;
        height: 44px;
    }

    .control-buttons {
        gap: 6px;
    }
}

/* --- Landscape mobile --- */
@media (max-height: 500px) and (orientation: landscape) {
    .player-bar {
        bottom: 0;
    }

    .player-content {
        height: 56px;
        min-height: auto;
        border-radius: 0;
        padding: 0 16px;
        display: grid;
        grid-template-columns: 160px 1fr 100px;
        flex-direction: row;
        gap: 12px;
    }

    .player-track {
        order: 1;
        max-width: 180px;
        margin: 0;
    }

    .player-controls {
        order: 2;
        width: auto;
        flex: 1 1 auto;
        border: none;
        padding: 0;
    }

    .control-buttons {
        gap: 6px;
    }

    .control-btn {
        width: 26px;
        height: 26px;
        font-size: 12px;
    }

    .control-btn-play {
        width: 34px;
        height: 34px;
        font-size: 14px;
    }

    .progress-section {
        display: flex;
        flex: 1;
        max-width: 280px;
        order: 2;
    }

    .time {
        display: block;
        font-size: 10px;
        width: 30px;
    }

    .player-right {
        order: 4;
        margin: 0;
        max-width: 120px;
    }

    .volume-control {
        width: auto;
    }

    .volume-track-wrap {
        width: 50px;
    }
}



/* ============================================
   MODALS & OVERLAYS
   ============================================ */

/* --- GENERAL MODAL --- */
.modal,
.analytics-modal {
    position: fixed;
    inset: 0;
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    visibility: hidden;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.modal:not(.hidden) {
    visibility: visible;
    opacity: 1;
    pointer-events: auto;
}

.modal-table-content {
    max-width: 900px;
    width: 95%;
    max-height: 85vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.modal-table-body {
    overflow-y: auto;
    flex: 1;
    max-height: 60vh;
}

.modal-table-wrapper {
    overflow-x: auto;
}

.modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(8px);
    transition: all 0.3s ease;
}

.modal-content {
    position: relative;
    z-index: 10;
    background: rgba(20, 20, 35, 0.85);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-xl);
    padding: 32px;
    width: 90%;
    max-width: 440px;
    box-shadow: var(--shadow-2xl), 0 0 50px rgba(139, 92, 246, 0.15);
    transform: scale(0.95) translateY(10px);
    transition: var(--transition-spring);
}

.modal:not(.hidden) .modal-content {
    transform: scale(1) translateY(0);
}

.modal-title {
    font-size: 24px;
    margin-bottom: 12px;
}

.modal-text {
    color: var(--text-secondary);
    margin-bottom: 32px;
    line-height: 1.6;
    font-size: 15px;
}

.modal-actions {
    display: flex;
    justify-content: flex-end;
    gap: 16px;
}

/* ========== ADD SONG MODAL - ULTRA MODERN DESIGN ========== */

.add-song-modal-content {
    max-width: 700px;
    width: 92%;
    padding: 0;
    border-radius: 28px;
    background: linear-gradient(145deg, #12122a 0%, #0a0a1a 100%);
    border: 1px solid rgba(139, 92, 246, 0.15);
    box-shadow:
        0 30px 70px rgba(0, 0, 0, 0.7),
        0 0 60px rgba(139, 92, 246, 0.08),
        inset 0 1px 0 rgba(255, 255, 255, 0.05);
    overflow: hidden;
    animation: modalPopIn 0.5s cubic-bezier(0.34, 1.8, 0.64, 1) forwards;
}

@keyframes modalPopIn {
    0% {
        opacity: 0;
        transform: scale(0.8) translateY(50px);
    }

    100% {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

/* Header Section */
.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 28px 32px;
    background: linear-gradient(180deg, rgba(139, 92, 246, 0.03) 0%, transparent 100%);
    border-bottom: 1px solid rgba(139, 92, 246, 0.08);
    position: relative;
}

.modal-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 32px;
    right: 32px;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(139, 92, 246, 0.3), transparent);
}

.modal-header .modal-title {
    margin: 0;
    font-size: 22px;
    font-weight: 800;
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 14px;
    letter-spacing: -0.5px;
    text-shadow: 0 0 30px rgba(139, 92, 246, 0.3);
}

.modal-header .modal-title i {
    color: #8b5cf6;
    font-size: 28px;
    animation: iconBounce 2s ease-in-out infinite;
    display: flex;
    align-items: center;
    justify-content: center;
}

@keyframes iconBounce {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-3px);
    }
}

.modal-close {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: #6b7280;
    font-size: 20px;
    cursor: pointer;
    padding: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    width: 44px;
    height: 44px;
    border-radius: 12px;
    position: relative;
    overflow: hidden;
}

.modal-close::before {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at center, rgba(139, 92, 246, 0.2), transparent 70%);
    transform: scale(0);
    transition: transform 0.4s ease;
}

.modal-close:hover::before {
    transform: scale(1.5);
}

.modal-close:hover {
    background: rgba(139, 92, 246, 0.1);
    border-color: rgba(139, 92, 246, 0.3);
    color: #8b5cf6;
    transform: rotate(90deg) scale(1.05);
    box-shadow: 0 0 25px rgba(139, 92, 246, 0.2);
}

.modal-close:active {
    transform: rotate(90deg) scale(0.95);
}

/* Body Section */
.modal-body {
    padding: 32px;
}

/* Search Section */
.search-input-wrapper {
    position: relative;
    margin-bottom: 24px;
}

.search-icon {
    position: absolute;
    left: 20px;
    top: 50%;
    transform: translateY(-50%);
    color: #8b5cf6;
    font-size: 20px;
    pointer-events: none;
    transition: all 0.3s ease;
    opacity: 0.7;
    display: flex;
    align-items: center;
    justify-content: center;
}

.search-input {
    width: 100%;
    padding: 18px 56px 18px 56px;
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.04) 0%, rgba(139, 92, 246, 0.02) 100%);
    border: 1.5px solid rgba(139, 92, 246, 0.15);
    border-radius: 16px;
    color: #ffffff;
    font-size: 16px;
    font-weight: 500;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    outline: none;
    letter-spacing: 0.3px;
}

.search-input::placeholder {
    color: #6b7280;
    font-weight: 400;
}

.search-input:hover {
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.06) 0%, rgba(139, 92, 246, 0.04) 100%);
    border-color: rgba(139, 92, 246, 0.25);
}

.search-input:focus {
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.08) 0%, rgba(139, 92, 246, 0.05) 100%);
    border-color: #8b5cf6;
    box-shadow:
        0 0 0 4px rgba(139, 92, 246, 0.12),
        0 15px 40px rgba(139, 92, 246, 0.1),
        0 0 30px rgba(139, 92, 246, 0.05);
}

.search-input:focus~.search-icon {
    color: #8b5cf6;
    opacity: 1;
    transform: translateY(-50%) scale(1.15);
    filter: drop-shadow(0 0 8px rgba(139, 92, 246, 0.5));
}

.search-loading {
    position: absolute;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
}

/* Suggestions List */
.search-suggestions {
    max-height: 520px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 14px;
    padding: 8px 0;
}

.search-suggestions::-webkit-scrollbar {
    width: 8px;
}

.search-suggestions::-webkit-scrollbar-track {
    background: rgba(139, 92, 246, 0.02);
    border-radius: 4px;
}

.search-suggestions::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, rgba(139, 92, 246, 0.3), rgba(139, 92, 246, 0.2));
    border-radius: 4px;
    border: 2px solid transparent;
    background-clip: padding-box;
}

.search-suggestions::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(180deg, rgba(139, 92, 246, 0.5), rgba(139, 92, 246, 0.4));
    background-clip: padding-box;
}

/* Suggestion Item */
.search-suggestion-item {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px 18px;
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.03) 0%, rgba(139, 92, 246, 0.015) 100%);
    border: 1px solid rgba(139, 92, 246, 0.08);
    border-radius: 16px;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    box-sizing: border-box;
}

.search-suggestion-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(139, 92, 246, 0.08), transparent);
    transition: left 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    pointer-events: none;
}

.search-suggestion-item:hover::before {
    left: 100%;
}

.search-suggestion-item:hover {
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.08) 0%, rgba(139, 92, 246, 0.04) 100%);
    border-color: rgba(139, 92, 246, 0.25);
    transform: translateX(10px);
    box-shadow:
        0 15px 40px rgba(139, 92, 246, 0.12),
        0 0 20px rgba(139, 92, 246, 0.05);
}

.search-suggestion-item:active {
    transform: translateX(5px);
    transition: transform 0.1s ease;
}

.suggestion-thumbnail {
    width: 56px;
    height: 56px;
    min-width: 56px;
    flex-shrink: 0;
    border-radius: 14px;
    object-fit: cover;
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.1), rgba(139, 92, 246, 0.05));
    border: 1.5px solid rgba(139, 92, 246, 0.15);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
}

.search-suggestion-item:hover .suggestion-thumbnail {
    transform: scale(1.1) rotate(-2deg);
    border-color: rgba(139, 92, 246, 0.4);
    box-shadow:
        0 15px 30px rgba(139, 92, 246, 0.2),
        0 0 15px rgba(139, 92, 246, 0.1);
}

.suggestion-info {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.suggestion-title {
    font-weight: 700;
    color: #ffffff;
    font-size: 15px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    transition: all 0.3s ease;
    letter-spacing: 0.2px;
}

.suggestion-artist {
    color: #9ca3af;
    font-size: 13px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-weight: 400;
    transition: color 0.3s ease;
}

.suggestion-duration {
    color: #9ca3af;
    font-size: 12px;
    font-weight: 700;
    padding: 6px 12px;
    background: rgba(139, 92, 246, 0.08);
    border-radius: 8px;
    white-space: nowrap;
    border: 1px solid rgba(139, 92, 246, 0.1);
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    flex-shrink: 0;
}

.search-suggestion-item:hover .suggestion-title {
    color: #8b5cf6;
    text-shadow: 0 0 20px rgba(139, 92, 246, 0.4);
}

.search-suggestion-item:hover .suggestion-artist {
    color: #d1d5db;
}

.search-suggestion-item:hover .suggestion-duration {
    background: rgba(139, 92, 246, 0.15);
    color: #8b5cf6;
    border-color: rgba(139, 92, 246, 0.3);
    box-shadow: 0 0 15px rgba(139, 92, 246, 0.15);
}

/* Error State */
.search-suggestion-item.error {
    background: rgba(248, 113, 113, 0.03);
    border-color: rgba(248, 113, 113, 0.1);
    cursor: not-allowed;
}

.search-suggestion-item.error:hover {
    background: rgba(248, 113, 113, 0.05);
    border-color: rgba(248, 113, 113, 0.2);
    transform: none;
    box-shadow: none;
}

/* Responsive Modal */
@media (max-width: 900px) {
    .add-song-modal-content {
        max-width: calc(100% - 40px);
        border-radius: 24px;
    }

    .modal-header {
        padding: 24px 26px;
    }

    .modal-header .modal-title {
        font-size: 20px;
    }

    .modal-body {
        padding: 28px;
    }

    .search-input-wrapper {
        margin-bottom: 20px;
    }

    .search-input {
        padding: 16px 50px;
    }
}

@media (max-width: 680px) {
    .add-song-modal-content {
        max-width: calc(100% - 30px);
        border-radius: 20px;
    }

    .modal-header {
        padding: 20px 22px;
    }

    .modal-header .modal-title {
        font-size: 18px;
        gap: 10px;
    }

    .modal-header .modal-title i {
        font-size: 24px;
    }

    .modal-close {
        width: 40px;
        height: 40px;
    }

    .modal-body {
        padding: 22px;
    }

    .search-suggestions {
        gap: 10px;
    }

    .search-suggestion-item {
        padding: 14px 16px;
        gap: 14px;
    }

    .suggestion-thumbnail {
        width: 50px;
        height: 50px;
        min-width: 50px;
    }
}

@media (max-width: 480px) {
    .add-song-modal-content {
        max-width: calc(100% - 24px);
        border-radius: 18px;
    }

    .modal-header {
        padding: 18px 20px;
    }

    .modal-header .modal-title {
        font-size: 16px;
        gap: 8px;
    }

    .modal-header .modal-title i {
        font-size: 20px;
    }

    .modal-close {
        font-size: 18px;
        width: 36px;
        height: 36px;
    }

    .modal-body {
        padding: 18px;
    }

    .search-input-wrapper {
        margin-bottom: 14px;
    }

    .search-input {
        padding: 12px 38px 12px 42px;
        font-size: 13px;
        border-radius: 12px;
    }

    .search-suggestions {
        gap: 8px;
        max-height: 350px;
    }

    .search-suggestion-item {
        padding: 10px 12px;
        gap: 10px;
    }

    .suggestion-thumbnail {
        width: 44px;
        height: 44px;
        min-width: 44px;
        border-radius: 10px;
    }

    .suggestion-title {
        font-size: 13px;
    }

    .suggestion-artist {
        font-size: 11px;
    }

    .suggestion-duration {
        font-size: 10px;
        padding: 4px 8px;
    }
}

/* Modal UI Cleanup */
.modal-close {
    font-size: 18px;
    padding: 8px;
    width: 38px;
    height: 38px;
}

.modal-body {
    padding: 18px 20px;
}

.search-input-wrapper {
    margin-bottom: 18px;
}

.search-icon {
    left: 16px;
    font-size: 17px;
}

.search-input {
    padding: 12px 40px 12px 44px;
    font-size: 13px;
    border-radius: 11px;
}

.search-loading {
    right: 20px;
    top: 20px;
}

.search-suggestions {
    max-height: 320px;
    gap: 8px;
    padding: 4px 0;
}

.search-suggestion-item {
    padding: 11px 12px;
    gap: 12px;
    border-radius: 12px;
}

.suggestion-thumbnail {
    width: 45px;
    height: 45px;
    min-width: 45px;
    border-radius: 9px;
}

.suggestion-info {
    gap: 3px;
}

.suggestion-title {
    font-size: 12px;
    font-weight: 600;
}

.suggestion-artist {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.5);
}

.suggestion-duration {
    font-size: 10px;
    padding: 3px 8px;
}

.search-suggestion-item:hover {
    transform: translateX(4px);
}

.suggestions-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
    gap: 16px;
    color: var(--text-secondary);
}

.suggestions-loading span {
    font-size: 14px;
}

.analytics-loading-v2 {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px 20px;
    gap: 20px;
    color: var(--text-secondary);
}

.analytics-loading-v2 span {
    font-size: 15px;
}

.table-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px;
    gap: 16px;
    color: var(--text-secondary);
}

.table-loading span {
    font-size: 14px;
}

.tracks-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px;
    gap: 16px;
    color: var(--text-secondary);
}

.tracks-loading span {
    font-size: 14px;
}

/* --- AUDIO FX MODAL --- */
.fx-modal-content {
    max-width: 800px !important;
    padding: 0 !important;
    overflow: hidden !important;
    display: flex;
    flex-direction: column;
    height: auto;
    max-height: 90vh;
}

.fx-tabs {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 28px;
    background: rgba(255, 255, 255, 0.02);
    border-bottom: 1px solid var(--border-glass);
    gap: 24px;
}

.fx-tabs-left {
    display: flex;
    gap: 24px;
}

.fx-tabs-right {
    display: flex;
    gap: 12px;
}

.fx-tabs-center {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
}

.active-filters-display {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 12px;
    background: rgba(139, 92, 246, 0.1);
    border: 1px solid rgba(139, 92, 246, 0.3);
    border-radius: 20px;
    font-size: 12px;
}

.active-filters-label {
    color: var(--primary);
    font-weight: 600;
}

#active-filters-list {
    color: var(--text-secondary);
    max-width: 200px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.btn-reset-filters {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-glass);
    color: var(--text-secondary);
    padding: 8px 16px;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    border-radius: 6px;
    transition: var(--transition-fast);
    display: flex;
    align-items: center;
    gap: 6px;
}

.btn-reset-filters:hover {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-primary);
    border-color: var(--primary);
}

.btn-reset-filters i {
    font-size: 12px;
}

.fx-tab {
    background: transparent;
    border: none;
    color: var(--text-secondary);
    padding: 16px 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    position: relative;
    transition: var(--transition-fast);
}

.fx-tab:hover {
    color: var(--text-primary);
}

.fx-tab.active {
    color: var(--primary);
}

.fx-tab.active::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--primary);
    box-shadow: 0 -2px 10px var(--primary);
}

.fx-panel {
    display: none;
    padding: 28px;
    overflow-y: auto;
    position: relative;
    min-height: 400px;
}

.fx-panel.active {
    display: block;
    animation: fadeIn 0.3s ease;
}

/* --- ACTIVE FILTERS PANEL --- */
.active-filters-panel {
    max-width: 600px;
    margin: 0 auto;
}

.active-filters-header {
    text-align: center;
    margin-bottom: 32px;
}

.active-filters-header h3 {
    font-size: 24px;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.active-filters-subtitle {
    color: var(--text-secondary);
    font-size: 14px;
}

.active-filters-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
    min-height: 200px;
}

.active-filter-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-glass);
    border-radius: 12px;
    transition: var(--transition-fast);
}

.active-filter-item:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: var(--primary);
}

.active-filter-item .filter-icon {
    font-size: 20px;
    margin-right: 12px;
}

.active-filter-item .filter-name {
    flex: 1;
    font-weight: 500;
    color: var(--text-primary);
}

.active-filter-item .remove-filter-btn {
    background: transparent;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 8px;
    border-radius: 6px;
    transition: var(--transition-fast);
}

.active-filter-item .remove-filter-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    color: var(--error);
}

.no-filters-message {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px 20px;
    color: var(--text-secondary);
}

.no-filters-message i {
    font-size: 48px;
    margin-bottom: 16px;
    opacity: 0.5;
}

.active-filters-actions {
    margin-top: 32px;
    text-align: center;
}

/* --- FILTERS PANEL --- */
.filter-categories {
    display: flex;
    flex-direction: column;
    gap: 32px;
}

.filter-category h4 {
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--text-muted);
    margin-bottom: 16px;
    padding-left: 12px;
    border-left: 2px solid var(--primary);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.filter-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
    gap: 12px;
}

.filter-btn {
    background: var(--bg-elevated);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-md);
    padding: 12px;
    color: var(--text-primary);
    cursor: pointer;
    transition: var(--transition-smooth);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    text-align: center;
}

.filter-btn i {
    font-size: 18px;
    color: var(--text-secondary);
    transition: var(--transition-fast);
}

.filter-btn span {
    font-size: 12px;
    font-weight: 500;
}

.filter-btn:hover {
    background: var(--bg-glass-hover);
    border-color: var(--primary-light);
    transform: translateY(-2px);
    box-shadow: var(--shadow-glow);
}

.filter-btn:hover i {
    color: var(--primary-light);
    transform: scale(1.1);
}

.filter-btn.active {
    background: rgba(139, 92, 246, 0.15);
    border-color: var(--primary);
    box-shadow: 0 0 20px rgba(139, 92, 246, 0.2);
}

.filter-btn.active i {
    color: var(--primary);
}

.filter-btn.locked {
    opacity: 0.6;
    cursor: not-allowed !important;
    position: relative;
    overflow: hidden;
}

.filter-btn.locked::after {
    content: '\f023';
    font-family: 'Font Awesome 5 Free';
    font-weight: 900;
    position: absolute;
    top: 5px;
    right: 8px;
    font-size: 10px;
    color: var(--warning);
}

.filter-reset-btn {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-glass);
    color: var(--text-secondary);
    padding: 3px 10px;
    font-size: 11px;
    font-weight: 500;
    cursor: pointer;
    border-radius: 5px;
    transition: var(--transition-fast);
    display: inline-flex;
    align-items: center;
    gap: 5px;
    text-transform: none;
    letter-spacing: 0;
    margin-left: auto;
    flex-shrink: 0;
}

.filter-reset-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: var(--primary);
    color: var(--primary);
}

/* --- EQ PANEL --- */

/* EQ Presets Section */
.eq-presets-section {
    background: rgba(0, 0, 0, 0.2);
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-glass);
    padding: 16px;
    margin-bottom: 16px;
}

.eq-presets-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.eq-presets-header h4 {
    color: var(--text-primary);
    font-size: 14px;
    font-weight: 600;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 8px;
}

.btn-eq-action {
    background: rgba(139, 92, 246, 0.2);
    border: 1px solid var(--primary);
    color: var(--primary-light);
    padding: 6px 12px;
    border-radius: var(--radius-md);
    font-size: 12px;
    cursor: pointer;
    transition: var(--transition-fast);
    display: flex;
    align-items: center;
    gap: 6px;
}

.btn-eq-action:hover {
    background: var(--primary);
    color: white;
}

.eq-presets-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    max-height: 120px;
    overflow-y: auto;
}

.eq-preset-item {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-md);
    padding: 8px 12px;
    cursor: pointer;
    transition: var(--transition-fast);
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    color: var(--text-secondary);
}

.eq-preset-item:hover {
    background: rgba(139, 92, 246, 0.2);
    border-color: var(--primary);
    color: var(--text-primary);
}

.eq-preset-item .delete-preset {
    opacity: 0;
    color: var(--error);
    font-size: 10px;
    transition: opacity 0.2s;
}

.eq-preset-item:hover .delete-preset {
    opacity: 1;
}

.eq-presets-empty {
    color: var(--text-muted);
    font-size: 12px;
    font-style: italic;
    padding: 8px;
}

.eq-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 32px;
}

.eq-container-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.eq-container-header h4 {
    color: var(--text-primary);
    font-size: 14px;
    font-weight: 600;
    margin: 0;
}

.eq-sliders {
    display: flex;
    justify-content: space-between;
    width: 100%;
    height: 250px;
    padding: 20px 0;
    background: rgba(0, 0, 0, 0.2);
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-glass);
}

.eq-slider-col {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-between;
    flex: 1;
    position: relative;
}

.eq-slider-input {
    -webkit-appearance: none;
    appearance: none;
    width: 160px;
    height: 4px;
    background: rgba(255, 255, 255, 0.1);
    transform: rotate(-90deg);
    position: absolute;
    top: 50%;
    cursor: pointer;
    border-radius: 2px;
}

.eq-slider-input::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 14px;
    height: 14px;
    background: var(--primary);
    border-radius: 50%;
    box-shadow: 0 0 10px var(--primary);
    cursor: pointer;
    transition: transform 0.1s;
}

.eq-slider-input::-webkit-slider-thumb:hover {
    transform: scale(1.3);
}

.eq-label {
    font-size: 10px;
    color: var(--text-muted);
    font-weight: 600;
}

.eq-value {
    font-size: 10px;
    color: var(--primary-light);
    margin-top: auto;
}

.eq-controls {
    display: flex;
    gap: 16px;
}

/* --- EQ BAND GROUPS (Grouped 15-band) --- */
.eq-band-groups {
    display: flex;
    justify-content: space-between;
    width: 100%;
    padding: 0 10px;
    margin-bottom: 8px;
}

.eq-group-label {
    display: flex;
    flex-direction: column;
    align-items: center;
    flex: 1;
    padding: 8px 4px;
    border-radius: var(--radius-sm);
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid var(--border-glass);
}

.eq-group-label span {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 1px;
}

.eq-group-label small {
    font-size: 9px;
    color: var(--text-muted);
    margin-top: 2px;
}

.eq-group-label.deep {
    border-color: rgba(139, 92, 246, 0.4);
}

.eq-group-label.deep span {
    color: #a78bfa;
}

.eq-group-label.bass {
    border-color: rgba(236, 72, 153, 0.4);
}

.eq-group-label.bass span {
    color: #f472b6;
}

.eq-group-label.mids {
    border-color: rgba(59, 130, 246, 0.4);
}

.eq-group-label.mids span {
    color: #60a5fa;
}

.eq-group-label.high {
    border-color: rgba(139, 92, 246, 0.4);
}

.eq-group-label.high span {
    color: #8b5cf6;
}

.eq-group-label.treble {
    border-color: rgba(52, 211, 153, 0.4);
}

.eq-group-label.treble span {
    color: #34d399;
}

/* --- ADVANCED EQ KNOBS --- */
.advanced-eq-container {
    margin-top: 24px;
    padding-top: 24px;
    border-top: 1px solid var(--border-glass);
}

.parametric-eq {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    width: 100%;
    padding: 20px;
    background: rgba(0, 0, 0, 0.25);
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-glass);
}

.knob-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    flex: 1;
    min-width: 70px;
}

.knob-label {
    font-size: 10px;
    font-weight: 600;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.knob-wrapper {
    position: relative;
    width: 60px;
    height: 60px;
}

.knob {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: linear-gradient(145deg, #2a2a3a, #1a1a28);
    border: 2px solid var(--border-glass);
    cursor: pointer;
    position: relative;
    box-shadow:
        0 4px 8px rgba(0, 0, 0, 0.3),
        inset 0 2px 4px rgba(255, 255, 255, 0.05);
    transition: all 0.2s ease;
    --rotation: 0deg;
}

.knob:hover {
    border-color: var(--primary);
    box-shadow:
        0 4px 12px rgba(0, 0, 0, 0.4),
        0 0 15px rgba(139, 92, 246, 0.3);
}

.knob.active {
    border-color: var(--primary);
    box-shadow:
        0 0 20px rgba(139, 92, 246, 0.4),
        inset 0 2px 4px rgba(255, 255, 255, 0.1);
}

.knob-indicator {
    position: absolute;
    top: 8px;
    left: 50%;
    width: 4px;
    height: 12px;
    background: var(--primary-light);
    border-radius: 2px;
    box-shadow: 0 0 8px var(--primary);
    transition: transform 0.1s ease;
    transform: translateX(-50%) rotate(var(--rotation));
    transform-origin: center 26px;
}

.knob-value {
    font-size: 12px;
    font-weight: 600;
    color: var(--primary-light);
    min-width: 40px;
    text-align: center;
}

.knob-slider {
    -webkit-appearance: none;
    appearance: none;
    width: 60px;
    height: 4px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 2px;
    cursor: pointer;
}

.knob-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 12px;
    height: 12px;
    background: var(--primary);
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 0 8px var(--primary);
}

/* Knob specific colors */
.knob-container[data-type="gain"] .knob {
    --knob-color: #f59e0b;
}

.knob-container[data-type="sub"] .knob {
    --knob-color: #8b5cf6;
}

.knob-container[data-type="low"] .knob {
    --knob-color: #ec4899;
}

.knob-container[data-type="mid"] .knob {
    --knob-color: #3b82f6;
}

.knob-container[data-type="clarity"] .knob {
    --knob-color: #8b5cf6;
}

.knob-container[data-type="air"] .knob {
    --knob-color: #34d399;
}

.knob-container[data-type] .knob-indicator {
    background: var(--knob-color);
    box-shadow: 0 0 8px var(--knob-color);
}

.knob-container[data-type] .knob.active {
    border-color: var(--knob-color);
    box-shadow: 0 0 20px color-mix(in srgb, var(--knob-color) 40%, transparent);
}

/* --- EQ INFO SECTION --- */

/* --- LOCK OVERLAY --- */
.panel-lock-overlay {
    position: absolute;
    inset: 0;
    background: rgba(15, 15, 25, 0.85);
    backdrop-filter: blur(10px);
    z-index: 100;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    border-radius: var(--radius-xl);
    padding: 40px;
}

.lock-content {
    max-width: 300px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
}

.lock-content i {
    font-size: 48px;
    color: var(--warning);
    margin-bottom: 8px;
    filter: drop-shadow(0 0 15px rgba(245, 158, 11, 0.4));
}

.lock-content h3 {
    font-size: 20px;
    margin: 0;
}

.lock-content p {
    color: var(--text-secondary);
    font-size: 14px;
    line-height: 1.5;
}

.btn-premium {
    background: linear-gradient(135deg, var(--warning), #d97706);
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: var(--radius-full);
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 8px 16px rgba(245, 158, 11, 0.2);
    transition: var(--transition-spring);
}

.btn-premium:hover {
    transform: scale(1.05);
    box-shadow: 0 12px 20px rgba(245, 158, 11, 0.3);
}

.search-suggestions {
    max-height: 480px;
    min-height: 0;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding: 12px 0;
    background: linear-gradient(180deg, rgba(139, 92, 246, 0.04), transparent);
}

.search-suggestions::-webkit-scrollbar {
    width: 10px;
}

.search-suggestions::-webkit-scrollbar-track {
    background: transparent;
    margin: 8px 0;
}

.search-suggestions::-webkit-scrollbar-thumb {
    background: rgba(139, 92, 246, 0.3);
    border-radius: 6px;
    border: 3px solid transparent;
    background-clip: padding-box;
    transition: background 0.3s ease;
}

.search-suggestions::-webkit-scrollbar-thumb:hover {
    background: rgba(139, 92, 246, 0.5);
    background-clip: padding-box;
}

.fa-solid,
.fas {
    top: 20px;
}

.search-suggestion-item {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 40px 18px;
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.08), rgba(59, 130, 246, 0.04));
    border: 1.5px solid rgba(139, 92, 246, 0.2);
    border-radius: 16px;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.search-suggestion-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(139, 92, 246, 0.12), transparent);
    transition: left 0.8s cubic-bezier(0.4, 0, 0.2, 1);
    pointer-events: none;
}

.search-suggestion-item:hover::before {
    left: 100%;
}

.search-suggestion-item:hover {
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.15), rgba(59, 130, 246, 0.1));
    border-color: rgba(139, 92, 246, 0.35);
    transform: translateX(8px);
    box-shadow: 0 12px 36px rgba(139, 92, 246, 0.15);
}

.search-suggestion-item:active {
    transform: translateX(4px);
}

.suggestion-thumbnail {
    width: 56px;
    height: 56px;
    min-width: 56px;
    border-radius: 14px;
    object-fit: cover;
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.2), rgba(59, 130, 246, 0.15));
    border: 1.5px solid rgba(139, 92, 246, 0.25);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.search-suggestion-item:hover .suggestion-thumbnail {
    transform: scale(1.12) rotate(2deg);
    border-color: rgba(139, 92, 246, 0.5);
    box-shadow: 0 12px 28px rgba(139, 92, 246, 0.25);
}

.suggestion-info {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.suggestion-title {
    font-weight: 700;
    color: var(--text-primary);
    font-size: 14px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    transition: color 0.3s ease;
    letter-spacing: 0.2px;
}

.suggestion-artist {
    color: rgba(255, 255, 255, 0.5);
    font-size: 12px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    transition: color 0.3s ease;
    font-weight: 400;
}

.suggestion-duration {
    color: rgba(255, 255, 255, 0.5);
    font-size: 12px;
    font-weight: 700;
    padding: 6px 14px;
    background: rgba(139, 92, 246, 0.12);
    border-radius: 10px;
    white-space: nowrap;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid rgba(139, 92, 246, 0.15);
}

.search-suggestion-item:hover .suggestion-title {
    color: #ffffff;
    text-shadow: 0 0 12px rgba(139, 92, 246, 0.4);
}

.search-suggestion-item:hover .suggestion-artist {
    color: rgba(255, 255, 255, 0.8);
}

.search-suggestion-item:hover .suggestion-duration {
    background: rgba(139, 92, 246, 0.25);
    color: var(--primary);
    border-color: rgba(139, 92, 246, 0.4);
    box-shadow: 0 0 12px rgba(139, 92, 246, 0.2);
}

.search-suggestion-item.error {
    background: rgba(244, 63, 94, 0.06);
    border-color: rgba(244, 63, 94, 0.15);
    cursor: not-allowed;
    opacity: 0.7;
}

.search-suggestion-item.error:hover {
    background: rgba(244, 63, 94, 0.06);
    border-color: rgba(244, 63, 94, 0.15);
    transform: none;
    box-shadow: none;
}

/* Responsive Design */
@media (max-width: 768px) {
    .search-suggestions {
        max-height: 350px;
        gap: 6px;
    }

    .search-suggestion-item {
        padding: 12px 14px;
        gap: 12px;
    }

    .suggestion-thumbnail {
        width: 45px;
        height: 45px;
        min-width: 45px;
        border-radius: 8px;
    }

    .suggestion-title {
        font-size: 13px;
    }

    .suggestion-artist {
        font-size: 12px;
    }

    .suggestion-duration {
        font-size: 11px;
        padding: 3px 8px;
    }

    .search-suggestion-item:hover {
        transform: translateX(4px);
    }
}

@media (max-width: 480px) {
    .search-suggestions {
        max-height: 300px;
        gap: 6px;
        padding: 6px 0;
    }

    .search-suggestion-item {
        padding: 10px 12px;
        gap: 10px;
        border-radius: 10px;
    }

    .suggestion-thumbnail {
        width: 42px;
        height: 42px;
        min-width: 42px;
        border-radius: 8px;
    }

    .suggestion-title {
        font-size: 12px;
        font-weight: 600;
    }

    .suggestion-artist {
        font-size: 11px;
    }

    .suggestion-duration {
        font-size: 10px;
        padding: 2px 6px;
    }

    .search-suggestion-item:hover {
        transform: translateX(2px);
    }
}

.search-hint {
    font-size: 12px;
    color: var(--text-secondary);
    margin-top: 8px;
    margin-bottom: 0;
    display: flex;
    align-items: center;
    gap: 6px;
}

.search-hint i {
    font-size: 14px;
}

.search-empty-state {
    text-align: center;
    padding: 40px 20px;
    color: var(--text-secondary);
}

.search-empty-state i {
    font-size: 48px;
    margin-bottom: 16px;
    opacity: 0.5;
}

.btn-secondary {
    padding: 12px 24px;
    background: transparent;
    border: 1px solid var(--border-glass);
    border-radius: 12px;
    color: var(--text-primary);
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s;
}

/* --- FORM GROUPS --- */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 8px;
}

.form-group input {
    width: 100%;
    padding: 12px 16px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-glass);
    border-radius: 12px;
    color: var(--text-primary);
    font-size: 14px;
    transition: all 0.2s;
}

.form-group input:focus {
    border-color: var(--primary);
    background: rgba(255, 255, 255, 0.1);
    box-shadow: 0 0 0 4px rgba(139, 92, 246, 0.1);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: var(--text-secondary);
}

.btn-danger {
    padding: 12px 24px;
    background: var(--danger);
    border: none;
    border-radius: 12px;
    color: white;
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s;
    box-shadow: 0 4px 12px rgba(239, 68, 68, 0.3);
}

.btn-danger:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(239, 68, 68, 0.4);
}

/* --- NOTIFICATIONS (Toast Style) --- */
.notification-container {
    position: fixed;
    top: 32px;
    right: 32px;
    z-index: 99999;
    display: flex;
    flex-direction: column;
    gap: 16px;
    pointer-events: none;
}

.notification {
    pointer-events: auto;
    background: rgba(20, 20, 35, 0.9);
    backdrop-filter: blur(16px);
    border: 1px solid var(--border-glass);
    border-left: 4px solid;
    border-radius: var(--radius-lg);
    padding: 16px 24px;
    min-width: 320px;
    max-width: 400px;
    display: flex;
    align-items: center;
    gap: 16px;
    box-shadow: var(--shadow-lg);
    animation: slideInRight 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    transition: all 0.3s ease;
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(100%);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.notification.success {
    border-left-color: var(--success);
}

.notification.error {
    border-left-color: var(--danger);
}

.notification.warning {
    border-left-color: var(--warning);
}

.notification.info {
    border-left-color: var(--info);
}

.notification i {
    font-size: 20px;
}

.notification.success i {
    color: var(--success);
}

.notification.error i {
    color: var(--danger);
}

.notification.warning i {
    color: var(--warning);
}

.notification.info i {
    color: var(--info);
}

.notification-message {
    font-size: 14px;
    font-weight: 500;
    color: var(--text-primary);
    line-height: 1.4;
}


/* --- SEARCH SUGGESTIONS & RECENT SEARCHES --- */
.suggestions-dropdown {
    position: fixed;
    z-index: 99990;
    background: rgba(15, 15, 25, 0.95);
    backdrop-filter: blur(24px);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-lg);
    width: 100%;
    max-width: 500px;
    box-shadow: var(--shadow-2xl);
    overflow-y: auto;
    max-height: 400px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: var(--transition-fast);
}

.recent-searches-dropdown {
    position: fixed;
    z-index: 99990;
    background: rgb(29 22 39 / 68%);
    backdrop-filter: blur(24px);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-lg);
    width: auto !important;
    min-width: 500px;
    max-width: 90vw;
    box-shadow: var(--shadow-2xl);
    overflow: visible;
    max-height: 400px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: var(--transition-fast);
}

.suggestions-dropdown:not(.hidden) {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.recent-searches-dropdown:not(.hidden) {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

@media (max-width: 480px) {
    .recent-searches-dropdown {
        min-width: 0 !important;
        width: 90vw !important;
        left: 5vw !important;
    }
}

.suggestion-item {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 12px 20px;
    cursor: pointer;
    border-bottom: 1px solid rgba(255, 255, 255, 0.03);
    transition: all 0.2s ease;
    background: transparent;
}

.recent-search-item {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 14px 20px;
    cursor: pointer;
    border-bottom: 1px solid rgba(255, 255, 255, 0.03);
    transition: background 0.2s;
    white-space: nowrap;
}

.recent-search-item span {
    white-space: nowrap !important;
    overflow: visible !important;
    text-overflow: clip !important;
}

.suggestion-item:last-child {
    border-bottom: none;
}

.suggestion-item:hover,
.recent-search-item:hover {
    background: linear-gradient(90deg, rgba(139, 92, 246, 0.15), rgba(59, 130, 246, 0.1));
}

.suggestion-item:hover .suggestion-artwork {
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.suggestion-artwork {
    width: 48px;
    height: 48px;
    border-radius: 10px;
    object-fit: cover;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.suggestion-info {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.suggestion-title {
    font-weight: 600;
    font-size: 15px;
    color: var(--text-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.suggestion-artist {
    font-size: 13px;
    color: var(--text-secondary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.suggestion-duration {
    font-size: 12px;
    color: var(--text-muted);
    font-weight: 500;
    padding: 4px 8px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 6px;
    flex-shrink: 0;
}

.recent-searches-header {
    padding: 16px 20px;
    background: rgba(255, 255, 255, 0.03);
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 12px;
    font-weight: 700;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.recent-searches-list {
    max-height: 300px;
    overflow-y: auto;
    overflow-x: visible;
}

.queue-empty {
    align-items: center;
    justify-content: center;
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 20px;
    color: var(--text-secondary);
    font-size: 14px;
    font-weight: 600;
}

/* --- PLAYLISTS VIEW --- */
.playlists-container {
    padding: 20px 0;
}

.playlists-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
}

.playlists-header-right {
    display: flex;
    align-items: center;
    gap: 12px;
}

.section-title {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 6px;
    background: linear-gradient(135deg, #fff 0%, rgba(255, 255, 255, 0.7) 100%);
    background-clip: text;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.section-subtitle {
    color: var(--text-secondary);
    font-size: 14px;
}

.create-btn {
    background: var(--primary);
    border: none;
    border-radius: 10px;
    padding: 10px 20px;
    color: white;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(88, 101, 242, 0.3);
}

.create-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(88, 101, 242, 0.4);
}

.refresh-btn,
.action-btn#refresh-playlist-btn {
    background: var(--bg-glass);
    backdrop-filter: blur(8px);
    border: 1px solid var(--border-glass);
    border-radius: 12px;
    padding: 10px 18px;
    color: var(--text-secondary);
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative;
    overflow: hidden;
    min-width: 40px;
    height: 40px;
}

.refresh-btn::after,
.action-btn#refresh-playlist-btn::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(59, 130, 246, 0.1);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: width 0.6s ease, height 0.6s ease;
    z-index: 0;
}

.refresh-btn:hover,
.action-btn#refresh-playlist-btn:hover {
    background: rgba(59, 130, 246, 0.08);
    color: #4dabf7;
    border-color: rgba(59, 130, 246, 0.4);
    transform: translateY(-3px) scale(1.05);
    box-shadow: 0 8px 25px rgba(59, 130, 246, 0.25);
}

.refresh-btn:hover::after,
.action-btn#refresh-playlist-btn:hover::after {
    width: 200%;
    height: 200%;
}

.refresh-btn:active,
.action-btn#refresh-playlist-btn:active {
    transform: translateY(-1px) scale(0.96);
    box-shadow: 0 4px 10px rgba(59, 130, 246, 0.15);
}

.refresh-btn i,
.action-btn#refresh-playlist-btn i {
    z-index: 1;
    transition: transform 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.refresh-btn:hover i,
.action-btn#refresh-playlist-btn:hover i {
    transform: rotate(180deg);
}

.refresh-btn.loading,
.action-btn#refresh-playlist-btn.loading {
    pointer-events: none;
    background: rgba(59, 130, 246, 0.15);
    border-color: rgba(59, 130, 246, 0.6);
    animation: refresh-pulse 2s infinite ease-in-out;
}

.refresh-btn.loading i,
.action-btn#refresh-playlist-btn.loading i {
    animation: elegant-rotate 1.2s infinite cubic-bezier(0.5, 0.1, 0.5, 0.9);
}

@keyframes elegant-rotate {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

@keyframes refresh-pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(59, 130, 246, 0.5);
    }

    70% {
        box-shadow: 0 0 0 12px rgba(59, 130, 246, 0);
    }

    100% {
        box-shadow: 0 0 0 0 rgba(59, 130, 246, 0);
    }
}

.playlists-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 20px;
    padding: 10px;
}

.playlist-card {
    background: var(--bg-elevated);
    border: 1px solid var(--border-glass);
    border-radius: 16px;
    padding: 20px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
    gap: 12px;
    position: relative;
}

.playlist-card.locked {
    opacity: 0.5;
    cursor: not-allowed;
    filter: grayscale(0.5);
}

.playlist-card .lock-overlay {
    position: absolute;
    top: 8px;
    right: 8px;
    background: rgba(0, 0, 0, 0.7);
    border-radius: 50%;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-secondary);
    font-size: 12px;
}

.playlist-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--primary-gradient);
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: 0;
}

.playlist-card:hover {
    transform: translateY(-5px);
    border-color: rgba(88, 101, 242, 0.5);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.playlist-card:hover::before {
    opacity: 0.05;
}

.playlist-icon {
    width: 48px;
    height: 48px;
    background: rgba(88, 101, 242, 0.1);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    color: var(--primary-light);
    margin-bottom: 8px;
    z-index: 1;
}

.playlist-body {
    z-index: 1;
}

.playlist-name {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 4px;
    color: white;
}

.playlist-tracks-count {
    color: var(--text-secondary);
    font-size: 13px;
}

/* --- PLAYLIST DETAIL --- */
.playlist-detail {
    animation: fadeIn 0.4s ease;
}

.detail-header {
    margin-bottom: 30px;
}

.back-link {
    background: none;
    border: none;
    color: var(--text-secondary);
    font-size: 14px;
    cursor: pointer;
    padding: 0;
    margin-bottom: 20px;
    transition: color 0.2s;
}

.back-link:hover {
    color: white;
}

.detail-info {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.detail-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.detail-name {
    font-size: 32px;
    font-weight: 800;
    letter-spacing: -0.5px;
}

.detail-actions {
    display: flex;
    gap: 10px;
}

.action-btn {
    background: var(--bg-glass);
    border: 1px solid var(--border-glass);
    width: 40px;
    height: 40px;
    border-radius: 10px;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s;
}

.action-btn:hover {
    background: var(--bg-glass-hover);
    color: white;
    border-color: var(--border-hover);
}

.action-btn.delete:hover {
    background: rgba(244, 63, 94, 0.1);
    color: #f43f5e;
    border-color: #f43f5e;
}

.action-btn.add:hover {
    background: rgba(16, 185, 129, 0.1);
    color: #10b981;
    border-color: #10b981;
}

.action-btn.disabled {
    opacity: 0.45;
    cursor: not-allowed;
    pointer-events: none;
    filter: grayscale(0.5);
}

/* Styles are handled by unified .refresh-btn, .action-btn#refresh-playlist-btn rules */
@keyframes spin {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

.detail-stats {
    color: var(--text-secondary);
    font-size: 14px;
}

.playlist-tracks-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.playlist-track-item {
    display: flex;
    align-items: center;
    padding: 12px 16px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    transition: all 0.2s;
}

.playlist-track-item:hover {
    background: rgba(255, 255, 255, 0.05);
    transform: translateX(5px);
}

.track-index {
    width: 30px;
    color: var(--text-secondary);
    font-size: 13px;
    font-family: 'Sora', sans-serif;
}

.track-info {
    flex: 1;
}

.track-name {
    font-weight: 600;
    font-size: 14px;
    color: white;
    margin-bottom: 2px;
}

.track-author {
    font-size: 12px;
    color: var(--text-secondary);
}

.track-remove {
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.2);
    cursor: pointer;
    padding: 8px;
    transition: color 0.2s;
}

.track-remove:hover {
    color: #f43f5e;
}

/* --- UTILITY ANIMATIONS --- */
@keyframes scaleIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

.scale-in {
    animation: scaleIn 0.3s ease forwards;
}



/* ============================================
   RESPONSIVE LAYOUT (Mobile First Approach)
   ============================================ */

/* --- LARGE DESKTOP (1400px+) --- */
@media (min-width: 1401px) {
    .content-container {
        max-width: 1600px;
        padding: 40px 60px;
    }

    .server-card {
        height: 100%;
    }

    .view-title {
        font-size: 42px;
    }
}

/* --- LAPTOP / MEDIUM (1025px - 1400px) --- */
@media (max-width: 1400px) {
    .stats-row-v2 {
        gap: 16px;
    }

    .stat-number-v2 {
        font-size: 24px;
    }

    .stat-box-v2 {
        padding: 20px;
    }

    .track-visual {
        max-width: 350px;
    }
}

/* --- TABLET / PORTRAIT (769px - 1024px) --- */
@media (max-width: 1024px) {
    .stats-row-v2 {
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
        margin-bottom: 24px;
    }

    .servers-grid {
        grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
        gap: 16px;
    }


    .recommended-tracks-list {
        grid-template-columns: 1fr;
    }
}

/* --- MOBILE LARGE (481px - 768px) --- */
@media (max-width: 768px) {
    :root {
        --header-height: 70px;
        --player-height: 140px;
        /* Taller for stacked layout if needed, though using overlay bar */
    }

    .dashboard {
        grid-template-rows: var(--header-height) auto 1fr;
        grid-template-areas: "header" "nav" "main";
    }

    /* Headers */
    .top-header {
        padding: 0 20px;
    }

    .search-input {
        padding: 7px 3px 17px 49px;
    }

    .header-brand {
        display: none;
    }

    /* Hide brand text */
    .user-name {
        display: none;
    }

    /* Bottom Header - Tablet */
    .bottom-header {
        padding: 10px 16px;
        gap: 12px;
    }

    .back-btn {
        padding: 8px 14px;
        font-size: 12px;
    }

    .back-btn span {
        display: none;
    }

    .search-input {
        padding: 10px 14px 10px 40px;
        font-size: 13px;
    }

    .search-icon {
        left: 14px;
    }

    .content-container {
        padding: 12px !important;
    }

    /* Analytics */
    .stats-row-v2 {
        grid-template-columns: 1fr 1fr;
        gap: 12px;
    }

    .weekly-chart-bars {
        height: 120px;
    }

    /* Table Responsive */
    .tracks-table th,
    .tracks-table td {
        padding: 12px;
    }

    .col-rank,
    .rank-badge {
        width: 24px;
        height: 24px;
        font-size: 11px;
    }

    .col-server,
    .col-play-duration,
    .col-repeats {
        display: none;
    }

    /* Hide less important columns */


}

/* --- MOBILE SMALL (320px - 480px) --- */
@media (max-width: 480px) {
    .view-title {
        font-size: 28px;
    }

    .view-description {
        font-size: 14px;
    }

    /* Bottom Header - Mobile */
    .bottom-header {
        padding: 10px 12px;
        gap: 10px;
    }

    .back-btn {
        padding: 8px 12px;
        font-size: 12px;
    }

    .back-btn span {
        display: none;
    }

    .bottom-header-center {
        max-width: none;
    }

    .search-input {
        padding: 10px 12px 10px 36px;
        font-size: 13px;
        border-radius: var(--radius-full);
    }

    .search-icon {
        left: 12px;
        font-size: 13px;
    }

    /* Icon only back button */

    /* Servers Grid 1 Column */
    .servers-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    /* Analytics Stack */
    .stats-row-v2 {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    /* Single column stats */
    .stat-box-v2 {
        padding: 16px;
    }

    .stat-number-v2 {
        font-size: 22px;
    }

    /* Player View */
    .now-playing-area {
        gap: 24px;
    }

    .track-visual {
        max-width: 280px;
    }

    .track-title {
        font-size: 28px;
    }

    .track-artist {
        font-size: 16px;
    }



    /* Modal Full Width */
    .modal-content {
        width: 95%;
        padding: 24px;
    }

    /* Notifications */
    .notification-container {
        top: 16px;
        right: 16px;
        left: 16px;
        align-items: center;
    }

    .notification {
        min-width: auto;
        width: 100%;
        max-width: 100%;
        padding: 12px 16px;
        font-size: 13px;
    }
}

/* --- EXTRA SMALL (Below 320px) --- */
@media (max-width: 320px) {
    .view-title {
        font-size: 24px;
    }

    .header-logo {
        height: 32px;
    }

    .track-visual {
        max-width: 200px;
    }

    .track-title {
        font-size: 22px;
    }
}

/* --- LANDSCAPE MOBILE FIX --- */
/* For phones rotated sideways to prevent vertical scrolling issues with 100vh */
@media (max-height: 500px) and (orientation: landscape) {
    .dashboard {
        height: auto;
        min-height: 100vh;
        overflow-y: auto;
    }



    .track-visual {
        max-width: 180px;
    }

    .now-playing-area {
        flex-direction: row;
        align-items: center;
        justify-content: center;
        gap: 32px;
    }

    .track-details {
        text-align: left;
    }
}

/* --- PRINT --- */
@media print {
    body {
        background: white;
        color: black;
    }

    .player-bar,
    .top-header,
    .bottom-header {
        display: none;
    }

    .content-container {
        padding: 0;
    }
}



/* ============================================
   REGRESSION FIXES & POLISH (PATCH)
   ============================================ */

/* 1. FORCE HIDE HEADERS IN SERVER VIEW */
/* Uses the .no-player class added by app.js when showing server selection */
.dashboard.no-player .bottom-header,
.dashboard.no-player .player-bar {
    display: none !important;
}

/* 2. SERVER ICON WRAPPER FIX */
/* Restores layout for the specific HTML structure generated by JS */
.server-icon-wrapper {
    position: relative;
    width: 100px;
    height: 100px;
    margin: 0 auto 20px auto;
    display: flex;
    align-items: center;
    justify-content: center;
}

.server-icon {
    width: 80px;
    height: 80px;
    border-radius: 24px;
    position: relative;
    z-index: 2;
    overflow: hidden;
    box-shadow: var(--shadow-md);
    transition: var(--transition-spring);
}

.server-icon img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.server-card:hover .server-icon {
    transform: scale(1.1) rotate(3deg);
    box-shadow: 0 0 25px rgba(139, 92, 246, 0.4);
}

.server-card.server-card-add-bot:hover .server-icon {
    transform: scale(1.1) rotate(3deg);
    box-shadow: 0 0 25px rgba(251, 191, 36, 0.4);
}

/* Status Indicator (Online Dot - Green Glowing Animation) */
.server-status-indicator {
    position: absolute;
    bottom: 5px;
    right: 5px;
    width: 18px;
    height: 18px;
    background: #10b981;
    border: 3px solid var(--bg-card);
    border-radius: 50%;
    z-index: 5;
    box-shadow:
        0 0 8px #10b981,
        0 0 15px #10b981,
        0 0 25px #10b981,
        0 0 40px #10b981;
    animation: statusGlow 2s ease-in-out infinite alternate;
}

/* Yellow Status Indicator for Add Bot Cards */
.server-card-add-bot .server-status-indicator {
    background: #fbbf24;
    box-shadow:
        0 0 8px #fbbf24,
        0 0 15px #fbbf24,
        0 0 25px #fbbf24,
        0 0 40px #fbbf24;
    animation: statusGlowYellow 2s ease-in-out infinite alternate;
}

@keyframes statusGlow {
    0% {
        box-shadow:
            0 0 8px #10b981,
            0 0 15px #10b981,
            0 0 25px #10b981;
    }

    100% {
        box-shadow:
            0 0 10px #10b981,
            0 0 20px #10b981,
            0 0 35px #10b981,
            0 0 50px #10b981;
    }
}

@keyframes statusGlowYellow {
    0% {
        box-shadow:
            0 0 8px #fbbf24,
            0 0 15px #fbbf24,
            0 0 25px #fbbf24;
    }

    100% {
        box-shadow:
            0 0 10px #fbbf24,
            0 0 20px #fbbf24,
            0 0 35px #fbbf24,
            0 0 50px #fbbf24;
    }
}

/* 3. RESTORE BACKGROUND ANIMATIONS */
/* Re-implements .sound-wave and .floating-notes */
.background-elements {
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    overflow: hidden;
}

.sound-wave {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    background-repeat: no-repeat;
    background-position: bottom center;
    background-size: cover;
}

.wave-1 {
    height: 300px;
    opacity: 0.1;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 1440 320' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath fill='%237c3aed' d='M0,192L48,197.3C96,203,192,213,288,229.3C384,245,480,267,576,250.7C672,235,768,181,864,181.3C960,181,1056,235,1152,234.7C1248,235,1344,181,1392,154.7L1440,128L1440,320L1392,320C1344,320,1248,320,1152,320C1056,320,960,320,864,320C768,320,672,320,576,320C480,320,384,320,288,320C192,320,96,320,48,320L0,320Z'%3E%3C/path%3E%3C/svg%3E");
    animation: waveFloat 10s ease-in-out infinite alternate;
}

.wave-2 {
    height: 350px;
    opacity: 0.08;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 1440 320' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath fill='%23ec4899' d='M0,128L48,144C96,160,192,192,288,186.7C384,181,480,139,576,149.3C672,160,768,224,864,229.3C960,235,1056,181,1152,165.3C1248,149,1344,171,1392,181.3L1440,192L1440,320L1392,320C1344,320,1248,320,1152,320C1056,320,960,320,864,320C768,320,672,320,576,320C480,320,384,320,288,320C192,320,96,320,48,320L0,320Z'%3E%3C/path%3E%3C/svg%3E");
    animation: waveFloat 15s ease-in-out infinite alternate-reverse;
}

.wave-3 {
    height: 280px;
    opacity: 0.05;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 1440 320' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath fill='%233b82f6' d='M0,224L48,213.3C96,203,192,181,288,181.3C384,181,480,203,576,224C672,245,768,267,864,250.7C960,235,1056,181,1152,160C1248,139,1344,149,1392,154.7L1440,160L1440,320L1392,320C1344,320,1248,320,1152,320C1056,320,960,320,864,320C768,320,672,320,576,320C480,320,384,320,288,320C192,320,96,320,48,320L0,320Z'%3E%3C/path%3E%3C/svg%3E");
    animation: waveFloat 12s ease-in-out infinite alternate;
}

@keyframes waveFloat {
    0% {
        transform: translateY(0);
    }

    100% {
        transform: translateY(15px);
    }
}

.floating-notes {
    position: absolute;
    inset: 0;
    overflow: hidden;
}

.note {
    position: absolute;
    font-size: 24px;
    color: rgba(255, 255, 255, 0.1);
    animation: noteFloatUp 8s linear infinite;
    pointer-events: none;
}

.note-1 {
    left: 10%;
    animation-delay: 0s;
    font-size: 32px;
}

.note-2 {
    left: 20%;
    animation-delay: 4s;
    font-size: 24px;
}

.note-3 {
    left: 70%;
    animation-delay: 2s;
    font-size: 40px;
}

.note-4 {
    left: 80%;
    animation-delay: 6s;
    font-size: 28px;
}

.note-5 {
    left: 50%;
    animation-delay: 3s;
    font-size: 36px;
}

@keyframes noteFloatUp {
    0% {
        transform: translateY(100vh) rotate(0deg);
        opacity: 0;
    }

    20% {
        opacity: 0.4;
    }

    80% {
        opacity: 0.4;
    }

    100% {
        transform: translateY(-100px) rotate(360deg);
        opacity: 0;
    }
}

/* 4. WEEKLY CHART FIX */
.weekly-chart-bars {
    align-items: flex-end;
    gap: 8px;
    /* Consistent gap instead of margin */
    padding-bottom: 24px;
}

.chart-bar {
    margin: 0;
    flex: 1;
    background: rgba(255, 255, 255, 0.02);
    border-radius: 8px 8px 0 0;
}

.bar-fill {
    min-height: 4px;
    /* Ensure visible even if 0 */
}

/* 5. TOP HEADER FIX */
.top-header {
    height: 80px;
    /* Force height */
    justify-content: space-between;
    padding: 0 40px;
    background: rgb(0 0 0 / 14%);
    /* Slightly darker for better contrast */
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.header-left,
.header-right {
    flex: 1;
}

.header-right {
    justify-content: flex-end;
}

/* Center the brand if needed, or keep it left */
.header-brand {
    font-size: 20px;
    font-weight: 800;
    letter-spacing: -0.5px;
    background: linear-gradient(to right, #fff, #a78bfa);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* 6. BOTTOM HEADER POLISH â€” PREMIUM COMPACT PILL */
.bottom-header {
    height: 56px;
    background: rgba(10, 10, 10, 0.4);
    backdrop-filter: blur(28px);
    -webkit-backdrop-filter: blur(28px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    padding: 0 20px;
    margin: 0 auto 16px;
    border-radius: var(--radius-full);
    width: min(1200px, calc(100% - 40px));
}

.search-container {
    max-width: 600px;
}

.search-input {
    background: rgba(0, 0, 0, 0.2);
    border-color: rgba(255, 255, 255, 0.05);
}

.search-input:focus {
    background: rgba(0, 0, 0, 0.4);
    border-color: var(--primary);
}



/* ============================================
   FINAL LAYOUT FIXES (User Feedback)
   ============================================ */

/* 1. CRITICAL VISIBILITY FIX (Stronger Selectors) */
#dashboard.no-player #bottom-header,
#dashboard.no-player .player-bar,
#dashboard.no-player .player-bar-container {
    display: none !important;
    visibility: hidden !important;
    opacity: 0 !important;
    pointer-events: none !important;
    height: 0 !important;
    overflow: hidden !important;
}

/* 2. TOP HEADER LAYOUT (Grid for perfect centering) */
.top-header {
    display: grid !important;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    height: 80px;
    padding: 0 32px;
    background: rgb(0 0 0 / 14%);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.header-left {
    justify-self: start;
    display: flex;
    align-items: center;
    gap: 16px;
}

.header-center {
    justify-self: center;
    /* Ensure it doesn't overlap if screen is small */
    max-width: 40vw;
}

.header-right {
    justify-self: end;
    display: flex;
    align-items: center;
    gap: 24px;
}

/* 3. BOTTOM HEADER POLISH â€” COMPACT PILL */
/* [DEPRECATED OVERRIDE - MOVED TO ENFORCEMENT BLOCK]
.bottom-header {
    display: flex !important;
    align-items: center;
    justify-content: space-between;
    height: 56px;
    padding: 0 20px;
    background: rgba(10, 10, 10, 0.4);
    backdrop-filter: blur(28px);
    -webkit-backdrop-filter: blur(28px);
    z-index: 100;
    width: min(1200px, calc(100% - 40px));
    margin: 0 auto 16px;
    border-radius: var(--radius-full);
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.35);
}
*/

/* Fix search bar overflow on narrow screens */
@media (max-width: 420px) {
    .bottom-header {
        display: flex !important;
        flex-direction: row;
        justify-content: flex-start;
        gap: 12px;
        padding: 0 16px;
        height: 64px;
    }

    .bottom-header-right {
        display: none;
    }

    .bottom-header-left {
        flex: 0 0 auto;
    }

    .back-btn {
        padding: 10px;
        width: 40px;
        height: 40px;
        justify-content: center;
        border-radius: var(--radius-full);
    }

    .back-btn span {
        display: none;
    }

    .bottom-header-center {
        flex: 1;
        min-width: 0;
        justify-content: flex-start;
    }

    .search-container {
        width: 100%;
        max-width: none;
    }

    .search-input {
        padding: 10px 12px 10px 40px;
        font-size: 14px;
        border-radius: var(--radius-full);
        width: 100%;
        float: none;
        background: rgba(255, 255, 255, 0.03);
        border: 1px solid rgba(255, 255, 255, 0.08);
    }

    .search-icon {
        left: 14px;
        font-size: 14px;
        color: var(--text-secondary);
    }
}

.bottom-header-left {
    justify-self: start;
}

.bottom-header-center {
    justify-self: center;
    width: 100%;
    display: flex;
    justify-content: center;
}

.bottom-header-right {
    justify-self: end;
}

/* Refined Search Input */
.search-container {
    width: 100%;
    max-width: 100%;
}

.search-input {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.search-input:focus {
    background: rgba(0, 0, 0, 0.3);
    border-color: var(--primary);
    box-shadow: 0 0 0 2px rgba(139, 92, 246, 0.2);
}

/* 4. WEEKLY CHART VISUAL OVERHAUL */
.weekly-chart-bars {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    height: 180px;
    /* Taller */
    padding: 20px 10px 0 10px;
    gap: 12px;
    background: linear-gradient(to bottom, transparent, rgba(255, 255, 255, 0.01));
    border-radius: 12px;
}

.chart-bar {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    height: 100%;
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.02);
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

.bar-fill {
    width: 100%;
    background: linear-gradient(to top, var(--primary-dark), var(--primary));
    border-radius: 6px 6px 0 0;
    position: relative;
    min-height: 4px;
    transition: height 1s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.chart-bar:hover .bar-fill {
    background: linear-gradient(to top, var(--accent), var(--accent-glow));
    filter: drop-shadow(0 0 8px var(--accent));
}

.bar-label {
    margin-top: 12px;
    font-size: 11px;
    font-weight: 600;
    color: var(--text-secondary);
    text-align: center;
}



/* ============================================
   STRUCTURAL LAYOUT FIX (Critical)
   ============================================ */

/* 1. Reset Dashboard to match HTML nesting */
/* The HTML has headers INSIDE .main-area, not direct children of .dashboard */
.dashboard {
    display: flex !important;
    flex-direction: column !important;
    /* Override the broken grid templates */
    grid-template-columns: none !important;
    grid-template-rows: none !important;
    grid-template-areas: none !important;
    height: 100vh;
    overflow: hidden;
    /* padding-top preserved from original rule (100px for floating navbar) */
}

/* 2. Main Area becomes the layout controller */
.main-area {
    flex: 1;
    display: flex !important;
    flex-direction: column !important;
    height: 100%;
    overflow: hidden !important;
    grid-area: auto !important;
}

/* 3. Headers as Flex Items */
.top-header {
    flex: 0 0 80px;
    /* Fixed height */
    width: 100%;
    z-index: 50;
    /* Internal layout is Grid (from final_fix) which works fine here */
}

/* [DEPRECATED OVERRIDE - MOVED TO ENFORCEMENT BLOCK]
.bottom-header {
    flex: 0 0 auto;
    width: 100%;
    z-index: 40;
}
*/

/* 4. Content Container handles scrolling */
.content-container {
    flex: 1;
    overflow-y: auto !important;
    overflow-x: hidden;
    padding-bottom: 80px !important;
    /* Exactly the player bar height — no gap */
    min-height: 0;
    /* Allow flex shrinking for proper scroll */
}

/* 5. VISIBILITY LOGIC (Refined for Flex) */
/* When no-player is active (Server View): */
.dashboard.no-player .bottom-header {
    display: none !important;
    /* Remove from flex flow */
}

.dashboard.no-player .content-container {
    padding-bottom: 0 !important;
    /* Reclaim space */
}

.dashboard.no-player .player-bar {
    display: none !important;
}

/* Mobile: Force hide player-bar in no-player state */
@media (max-width: 768px) {

    .dashboard.no-player .player-bar,
    #dashboard.no-player .player-bar {
        display: none !important;
        visibility: hidden !important;
        opacity: 0 !important;
        pointer-events: none !important;
        height: 0 !important;
        overflow: hidden !important;
    }
}

/* ============================================
   SCROLLBAR POSITION FIX
   ============================================ */

/* 1. Make Content Container Full Width (so scrollbar hits edge) */
.content-container {
    max-width: 100% !important;
    width: 100% !important;
    margin: 0 !important;
    padding-top: 0 !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
    padding-bottom: 80px !important;
    /* Exactly matches player-bar height — no gap, no scroll */
}

/* 2. Center the INNER views instead */
.view-container {
    width: 100%;
    max-width: 1400px;
    margin: auto auto !important;
    /* Restore vertical spacing */
    padding: 0 32px;
    /* Restore horizontal spacing */
}

/* Full width when server music player is active */
body.player-mode .view-container,
#playing-view.active .view-container,
#playing-view .view-container {
    max-width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
}

/* Analytics already has max-width, ensure it centers */
.analytics-dashboard-v2 {
    width: 100%;
    max-width: 1400px;
    margin: 50px auto 0 auto !important;
    padding: 0 24px;
}

/* Fix analytics inside user-analytics-section - remove extra margin */
#user-analytics-section .analytics-dashboard-v2 {
    margin-top: 0 !important;
    padding: 0;
    max-width: 100%;
}

/* Mobile responsive fix for full width */
@media (max-width: 768px) {
    .view-container {
        padding: 0 20px;
        margin: 20px auto !important;
    }

    .analytics-dashboard-v2 {
        padding: 0 16px;
        margin-top: 30px !important;
    }
}



/* Volume tooltip styling */
div.volume-control .volume-tooltip {
    display: block;
    position: absolute;
    top: -35px;
    right: 0;
    transform: translateX(0);
    background: rgba(20, 20, 35, 0.9);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: white;
    padding: 4px 8px;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 600;
    opacity: 0;
    visibility: hidden;
    transition: all 0.2s ease;
    pointer-events: none;
    white-space: nowrap;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
    z-index: 1000;
}

div.volume-control .volume-tooltip::after {
    content: '';
    position: absolute;
    bottom: -4px;
    right: 15px;
    width: 8px;
    height: 8px;
    background: rgba(20, 20, 35, 0.9);
    border-right: 1px solid rgba(255, 255, 255, 0.1);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    transform: rotate(45deg);
}

div.volume-control:hover .volume-tooltip {
    opacity: 1;
    visibility: visible;
    transform: translateY(-5px);
}

.fa-trophy,
.fa-music {
    color: var(--primary);
}

/* Mobile volume tooltip centering */
@media (max-width: 768px) {
    div.volume-control .volume-tooltip {
        top: -40px;
        left: 50%;
        right: auto;
        transform: translateX(-50%);
    }

    div.volume-control:hover .volume-tooltip {
        transform: translateX(-50%) translateY(-5px);
    }
}


/* ============================================
   FINAL VISUAL POLISH (Red Buttons & Progress)
   ============================================ */

/* 1. FORCE RED ACTION BUTTONS (Signout & Leave) */
#btn-signout,
#leave-btn {
    color: var(--danger) !important;
    background: rgba(239, 68, 68, 0.1) !important;
    border: 1px solid rgba(239, 68, 68, 0.2) !important;
    transition: all 0.3s ease !important;
}

#btn-signout:hover,
#leave-btn:hover {
    background: rgba(239, 68, 68, 0.25) !important;
    box-shadow: 0 0 12px rgba(239, 68, 68, 0.4) !important;
    transform: scale(1.05);
}

/* 2. PROGRESS BAR THUMB (The "Ball") */
.progress-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 12px;
    height: 12px;
    background: white;
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 0 10px rgba(255, 255, 255, 0.5);
    transform: scale(0);
    /* Hidden by default */
    transition: transform 0.15s cubic-bezier(0.4, 0, 0.2, 1);
}

.progress-slider::-moz-range-thumb {
    width: 12px;
    height: 12px;
    background: white;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    transform: scale(0);
    transition: transform 0.15s;
}

/* Show ball on hover (Desktop) */
.progress-section:hover .progress-slider::-webkit-slider-thumb {
    transform: scale(1) !important;
}

.progress-section:hover .progress-slider::-moz-range-thumb {
    transform: scale(1) !important;
}

/* 3. MOBILE INTERACTION FIXES ("Hover" works differently on touch) */
@media (max-width: 768px) {

    /* Always show progress ball on mobile for better touch targeting */
    .progress-slider::-webkit-slider-thumb {
        transform: scale(1) !important;
        width: 14px;
        /* Slightly larger target */
        height: 14px;
    }

    .progress-slider::-moz-range-thumb {
        transform: scale(1) !important;
        width: 14px;
        height: 14px;
    }

    /* Always show thumb dot on touch */
    .progress-thumb-dot {
        transform: translate(-50%, -50%) scale(1) !important;
    }
}


/* ============================================
   WEEKLY CHART IMPROVEMENTS
   ============================================ */

/* 1. Bar Container */
.weekly-chart-bars {
    /* Ensure bars have room for tooltips */
    padding-top: 30px !important;
    align-items: flex-end !important;
}

/* 2. Bar Item */
.chart-bar {
    position: relative !important;
    cursor: pointer;
    overflow: visible !important;
    /* Allow tooltip to pop out */
}

/* 3. Bar Fill Styling (Gradient & Glow) */
.bar-fill {
    background: linear-gradient(to bottom, #a78bfa, #7c3aed) !important;
    border-radius: 6px 6px 2px 2px !important;
    box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.05) inset !important;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1) !important;
    opacity: 0.8;
}

.chart-bar:hover .bar-fill {
    transform: scaleY(1.05);
    /* Slight grow */
    transform-origin: bottom;
    background: linear-gradient(to bottom, #fff, #a78bfa) !important;
    box-shadow: 0 0 20px rgba(167, 139, 250, 0.4) !important;
    opacity: 1;
}

/* 4. Value Tooltip (Hidden by default, shown on hover) */
.bar-value {
    position: absolute;
    top: -35px;
    /* Float above bar */
    left: 50%;
    transform: translateX(-50%) translateY(5px);

    background: rgba(255, 255, 255, 0.95);
    color: #0f172a;
    font-weight: 700;
    font-size: 11px;
    padding: 3px 8px;
    border-radius: 6px;

    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    z-index: 20;
    white-space: nowrap;
}

/* Tooltip Arrow */
.bar-value::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 50%;
    transform: translateX(-50%) rotate(45deg);
    width: 8px;
    height: 8px;
    background: rgba(255, 255, 255, 0.95);
}

/* Show Tooltip on Hover */
.chart-bar:hover .bar-value {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}



/* ============================================
   CLEAN CHART DESIGN (Ref: User Example)
   ============================================ */

/* 1. Bar Fill - Solid & Clean */
.bar-fill {
    background: #8b5cf6 !important;
    /* Solid Violet/Purple */
    border-radius: 4px 4px 0 0 !important;
    /* Rounded top only */
    box-shadow: none !important;
    /* No glows */
    opacity: 1 !important;
    min-height: 6px !important;
    /* Slightly distinct for 0 values */
    transition: height 0.5s cubic-bezier(0.4, 0, 0.2, 1), background 0.3s !important;
}

/* 2. Hover Effect */
.chart-bar:hover .bar-fill {
    background: #a78bfa !important;
    /* Lighter Purple on hover */
    filter: none !important;
    transform: none !important;
    /* No scaling */
}

/* 3. Container Spacing */
.weekly-chart-bars {
    padding-top: 40px !important;
    /* Room for tooltip */
    padding-bottom: 10px !important;
    align-items: flex-end !important;
    gap: 12px !important;
}

/* 4. Labels */
.bar-label {
    margin-top: 12px !important;
    font-size: 11px !important;
    font-weight: 600 !important;
    color: #94a3b8 !important;
    /* Muted Slate */
    text-transform: uppercase !important;
    letter-spacing: 0.5px !important;
}

/* 5. Tooltip (Retain previous logic but clean up) */
.bar-value {
    background: #1e293b !important;
    /* Dark tooltip */
    color: white !important;
    font-size: 12px !important;
    padding: 4px 10px !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.3) !important;
    top: -40px !important;
}

.bar-value::after {
    background: #1e293b !important;
    border-right: 1px solid rgba(255, 255, 255, 0.1) !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1) !important;
    bottom: -5px !important;
    /* Fix arrow position */
}


/* ============================================
   MOBILE VOLUME TOOLTIP FIX (Show on Slide)
   ============================================ */

/* Ensure tooltip shows when SLIDING (Active state), not just hovering */
.volume-slider:active~.volume-tooltip,
.volume-slider:focus~.volume-tooltip,
.volume-control:active .volume-tooltip {
    opacity: 1 !important;
    visibility: visible !important;
    display: block !important;
    transform: translateX(-50%) translateY(-5px) !important;
}

/* Ensure it's above everything on mobile */
@media (max-width: 768px) {
    div.volume-control .volume-tooltip {
        z-index: 2000 !important;
        background: rgba(20, 20, 35, 0.95) !important;
        border: 1px solid rgba(255, 255, 255, 0.2) !important;
        /* Ensure it doesn't get cut off by screen edge */
        left: 50% !important;
        right: auto !important;
        width: auto !important;
        white-space: nowrap !important;
    }
}


/* ============================================
   FIX TINY MOBILE BUTTON VISIBILITY (<480px)
   ============================================ */

@media (max-width: 480px) {

    /* Override legacy hiding rule */
    .control-btn {
        display: flex !important;
        visibility: visible !important;
        opacity: 1 !important;
    }

    /* Ensure Previous button specifically is shown */
    #previous-btn {
        display: flex !important;
    }

    /* Ensure sizing is consistent */
    .control-btn {
        width: 32px !important;
        height: 32px !important;
        font-size: 16px !important;
    }

    .control-btn-play {
        width: 42px !important;
        height: 42px !important;
        font-size: 18px !important;
    }
}

/* Connection Status Indicator â€” GLASS DESIGN */
#connection-status {
    position: fixed;
    top: 2px;
    right: 2px;
    background: rgba(10, 10, 15, 0.6);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    color: rgba(255, 255, 255, 0.9);
    padding: 2px 4px;
    border-radius: 12px;
    font-weight: 600;
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    z-index: 9999;
    display: flex;
    align-items: center;
    gap: 8px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow:
        0 8px 32px rgba(0, 0, 0, 0.5),
        inset 0 1px 1px rgba(255, 255, 255, 0.05);
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

#connection-status span {
    font-family: inherit;
}

@media (max-width: 768px) {
    /* (Connection status override removed as per user request to be same everywhere) */
}

/* ============================================
   PHASE 7: MOBILE POPUP SEARCH
   ============================================ */

/* Disable background scrolling when search popup is active */
body.mobile-search-active {
    overflow: hidden !important;
}

/* Hide connection bar when mobile search is active */
body.mobile-search-active .connection-content {
    display: none !important;
}

.close-search-btn {
    display: none;
    background: none;
    border: none;
    color: var(--text-primary);
    font-size: 24px;
    padding: 10px;
    cursor: pointer;
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    opacity: 0.8;
    transition: all 0.2s;
    z-index: 200002;
}

.close-search-btn:hover {
    opacity: 1;
    color: var(--primary);
}

/* Force popup search on Tablet and Mobile (< 1025px) */
@media (max-width: 1024px) {
    .search-container.mobile-active {
        position: fixed !important;
        inset: 0 !important;
        width: 100vw !important;
        height: 100vh !important;
        max-width: 100vw !important;
        max-height: 100vh !important;
        background: rgba(0, 0, 0, 0.45) !important;
        backdrop-filter: blur(32px) !important;
        z-index: 200000 !important;
        display: flex !important;
        flex-direction: column !important;
        align-items: center !important;
        padding: 50px 20px 20px 20px !important;
        margin: 0 !important;
        border: none !important;
        animation: searchOverlayFadeIn 0.3s ease-out;
    }

    /* Reset input sizing and focus effects */
    .search-container.mobile-active .search-input {
        display: block !important;
        width: 100% !important;
        max-width: 600px !important;
        height: 56px !important;
        font-size: 16px !important;
        padding: 12px 60px 12px 50px !important;
        border-radius: var(--radius-lg) !important;
        background: rgba(255, 255, 255, 0.08) !important;
        border: 2px solid rgba(255, 255, 255, 0.2) !important;
        color: white !important;
        margin: 0 !important;
        transform: none !important;
        box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5) !important;
    }

    .search-container.mobile-active .search-input:focus {
        border-color: var(--primary) !important;
        box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.2) !important;
        transform: none !important;
        width: 100% !important;
        margin: 0 !important;
    }

    .search-container.mobile-active .search-icon {
        position: fixed !important;
        left: 50% !important;
        margin-left: -280px !important;
        top: 78px !important;
        transform: translateY(-50%) !important;
        display: block !important;
        z-index: 200001 !important;
        color: var(--primary) !important;
    }

    @media (max-width: 640px) {
        .search-container.mobile-active .search-icon {
            left: 35px !important;
            margin-left: 0 !important;
        }
    }

    .search-container.mobile-active .close-search-btn {
        display: block !important;
        position: fixed !important;
        right: 50% !important;
        margin-right: -280px !important;
        top: 78px !important;
        transform: translateY(-50%) !important;
        z-index: 200001 !important;
    }

    @media (max-width: 640px) {
        .search-container.mobile-active .close-search-btn {
            right: 35px !important;
            margin-right: 0 !important;
        }
    }

    /* Standardize dropdown logic for mobile-active state */
    body.mobile-search-active .suggestions-dropdown:not(.hidden),
    body.mobile-search-active .recent-searches-dropdown:not(.hidden) {
        position: fixed !important;
        z-index: 200005 !important;
        top: 190px !important;
        left: 50% !important;
        transform: translateX(-50%) !important;
        width: calc(100% - 40px) !important;
        max-width: 600px !important;
        max-height: calc(100vh - 220px) !important;
        background: rgba(20, 20, 35, 0.9) !important;
        backdrop-filter: blur(20px) !important;
        border: 1px solid rgba(255, 255, 255, 0.1) !important;
        box-shadow: 0 20px 50px rgba(0, 0, 0, 0.6) !important;
        border-radius: var(--radius-xl) !important;
        overflow-y: auto !important;
        display: block !important;
        opacity: 1 !important;
        visibility: visible !important;
    }

    /* Force hide when hidden class is present, providing highest priority */
    body .suggestions-dropdown.hidden,
    body .recent-searches-dropdown.hidden {
        display: none !important;
        opacity: 0 !important;
        visibility: hidden !important;
    }
}

@keyframes searchOverlayFadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

/* ============================================
   PLAYER FILTERS UI
   ============================================ */

.player-filters-container {
    padding: 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.player-filters-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 28px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--border-glass);
    flex-wrap: wrap;
    gap: 16px;
}

.player-filters-header h3 {
    font-size: 22px;
    font-weight: 700;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 12px;
}

.player-filters-header h3::before {
    content: '';
    width: 5px;
    height: 28px;
    background: var(--gradient-primary);
    border-radius: 3px;
}

.player-filters-actions {
    display: flex;
    gap: 12px;
}

.player-filter-reset-btn,
.player-filter-view-btn {
    padding: 10px 18px;
    border-radius: var(--radius-full);
    border: 1px solid var(--border-glass);
    background: var(--bg-glass);
    color: var(--text-secondary);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.25s ease;
    display: flex;
    align-items: center;
    gap: 8px;
}

.player-filter-reset-btn:hover,
.player-filter-view-btn:hover {
    background: var(--bg-glass-hover);
    border-color: var(--primary);
    color: var(--text-primary);
    transform: translateY(-1px);
}

.player-filters-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-bottom: 24px;
}

@media (max-width: 1200px) {
    .player-filters-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .player-filters-grid {
        grid-template-columns: 1fr;
    }
}

.player-filter-category {
    background: var(--bg-glass);
    border: 1px solid var(--border-glass);
    border-radius: 20px;
    padding: 20px;
    transition: all 0.3s ease;
    min-height: 180px;
}

.player-filter-category:hover {
    border-color: var(--primary);
    box-shadow: 0 4px 20px rgba(124, 58, 237, 0.1);
}

.player-filter-category.locked {
    opacity: 0.6;
    background: var(--bg-elevated);
}

.player-filter-category.locked:hover {
    border-color: var(--border-glass);
    box-shadow: none;
}

.player-filter-category-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
    padding-bottom: 14px;
    border-bottom: 1px solid var(--border-glass);
}

.player-filter-category-header i {
    font-size: 20px;
    color: var(--primary);
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(124, 58, 237, 0.15);
    border-radius: 10px;
}

.player-filter-category-header span {
    font-weight: 600;
    font-size: 16px;
    color: var(--text-primary);
    flex: 1;
}

.premium-badge {
    font-size: 10px;
    font-weight: 700;
    padding: 5px 10px;
    background: var(--gradient-primary);
    color: white;
    border-radius: 6px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.player-filter-options {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.player-filter-btn {
    padding: 10px 18px;
    border-radius: var(--radius-full);
    border: 1px solid var(--border-glass);
    background: var(--bg-elevated);
    color: var(--text-secondary);
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.25s ease;
    display: flex;
    align-items: center;
    gap: 6px;
    min-width: 80px;
    justify-content: center;
}

.player-filter-btn:hover {
    background: var(--primary);
    border-color: var(--primary);
    color: white;
    transform: translateY(-2px);
}

.player-filter-btn.active {
    background: var(--gradient-primary);
    border-color: transparent;
    color: white;
    box-shadow: 0 4px 15px rgba(124, 58, 237, 0.4);
}

.player-filter-btn.locked {
    opacity: 0.5;
    cursor: not-allowed;
    background: var(--bg-elevated);
}

.player-filter-btn.locked:hover {
    background: var(--bg-elevated);
    border-color: var(--border-glass);
    color: var(--text-secondary);
    transform: none;
}

.player-filter-btn i {
    font-size: 10px;
}

.player-filters-status {
    background: var(--bg-glass);
    border: 1px solid var(--border-glass);
    border-radius: 16px;
    padding: 18px 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 8px;
}

.player-active-filters {
    display: flex;
    align-items: center;
    gap: 12px;
}

.player-active-label {
    font-weight: 700;
    color: var(--text-primary);
    font-size: 15px;
}

.player-active-list {
    color: var(--text-secondary);
    font-size: 14px;
    font-weight: 500;
}

.player-filter-category {
    position: relative;
}

/* Responsive Filters */
@media (max-width: 768px) {
    .player-filters-grid {
        grid-template-columns: 1fr;
    }

    .player-filters-header {
        flex-direction: column;
        gap: 12px;
        align-items: flex-start;
    }
}

/* ============================================
   CUSTOM EQUALIZER (VIP FEATURE)
   ============================================ */

.player-custom-eq-section {
    background: var(--bg-glass);
    border: 1px solid var(--border-glass);
    border-radius: 20px;
    padding: 24px;
    margin-top: 24px;
    position: relative;
}

.player-custom-eq-section.locked {
    opacity: 0.6;
    background: var(--bg-elevated);
}

.player-custom-eq-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
    padding-bottom: 18px;
    border-bottom: 1px solid var(--border-glass);
    flex-wrap: wrap;
    gap: 12px;
}

.player-custom-eq-title {
    display: flex;
    align-items: center;
    gap: 12px;
    font-weight: 600;
    font-size: 18px;
    color: var(--text-primary);
}

.player-custom-eq-title i {
    font-size: 20px;
    color: var(--primary);
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(124, 58, 237, 0.15);
    border-radius: 10px;
}

.vip-badge {
    font-size: 11px;
    font-weight: 700;
    padding: 5px 12px;
    background: linear-gradient(135deg, #FFD700, #FFA500);
    color: #000;
    border-radius: 6px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.player-custom-eq-actions {
    display: flex;
    gap: 10px;
}

.player-eq-btn {
    padding: 8px 16px;
    border-radius: var(--radius-full);
    border: 1px solid var(--border-glass);
    background: var(--bg-elevated);
    color: var(--text-secondary);
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.25s ease;
    display: flex;
    align-items: center;
    gap: 6px;
}

.player-eq-btn:hover:not(:disabled) {
    background: var(--primary);
    border-color: var(--primary);
    color: white;
}

.player-eq-btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.player-eq-sliders {
    display: flex;
    justify-content: center;
    gap: 12px;
    margin-bottom: 24px;
    padding: 24px;
    background: var(--bg-elevated);
    border-radius: 16px;
    overflow-x: auto;
    min-height: 200px;
}

.eq-band {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    min-width: 44px;
}

.eq-slider {
    appearance: none;
    -webkit-appearance: none;
    writing-mode: vertical-lr;
    direction: rtl;
    width: 32px;
    height: 180px;
    background: transparent;
    cursor: pointer;
}

.eq-slider::-webkit-slider-runnable-track {
    width: 6px;
    background: var(--border-glass);
    border-radius: 3px;
}

.eq-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 20px;
    height: 20px;
    background: var(--gradient-primary);
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 2px 10px rgba(124, 58, 237, 0.5);
    border: 2px solid white;
}

.eq-slider:disabled {
    cursor: not-allowed;
    opacity: 0.5;
}

.eq-slider:disabled::-webkit-slider-thumb {
    background: var(--text-muted);
    border-color: transparent;
}

.eq-label {
    font-size: 11px;
    color: var(--text-muted);
    font-weight: 600;
    text-align: center;
    white-space: nowrap;
}

.player-eq-presets {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.eq-presets-label {
    font-size: 13px;
    color: var(--text-secondary);
    font-weight: 500;
}

.eq-preset-btn {
    padding: 6px 14px;
    border-radius: var(--radius-full);
    border: 1px solid var(--border-glass);
    background: var(--bg-elevated);
    color: var(--text-secondary);
    font-size: 12px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.25s ease;
}

.eq-preset-btn:hover:not(:disabled) {
    background: var(--primary);
    border-color: var(--primary);
    color: white;
}

.eq-preset-btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

/* Responsive Custom EQ */
@media (max-width: 768px) {
    .player-eq-sliders {
        padding: 12px;
        gap: 4px;
    }

    .eq-band {
        min-width: 28px;
    }

    .eq-slider {
        height: 120px;
    }

    .player-custom-eq-header {
        flex-direction: column;
        gap: 12px;
        align-items: flex-start;
    }
}

/* Final Fix: Eliminate top gap in player view by overriding global centering */
#playing-view.active {
    margin: 0 auto !important;
    padding-top: 12px !important;
}

.guild-info-content {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 150px;
}

.guild-plan-badge {
    position: absolute;
    bottom: -4px;
    right: -4px;
    padding: 2px 8px;
    border-radius: 6px;
    font-size: 9px;
    font-weight: 800;
    text-transform: uppercase;
    color: white;
    z-index: 10;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.15);
}

.guild-plan-badge.pro {
    background: linear-gradient(135deg, #3b82f6, #1d4ed8);
}

.guild-plan-badge.premium {
    background: linear-gradient(135deg, #a855f7, #7c3aed);
    animation: metallicShine 3s linear infinite;
    background-size: 200% 100%;
}

/* ============================================================================
   DESIGN SYSTEM ENFORCEMENT BLOCK (NUKE OVERRIDES)
   ============================================================================ */

/* Enforce Integrated Tab Navigation Components */
#dashboard .player-nav-tabs .back-btn {
    border-radius: var(--radius-full) !important;
    background: rgba(255, 255, 255, 0.05) !important;
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
    padding: 8px 18px !important;
    height: 40px !important;
    font-size: 13px !important;
    color: var(--text-secondary) !important;
    transition: var(--transition-smooth) !important;
}

#dashboard .player-nav-tabs .back-btn:hover {
    background: rgba(139, 92, 246, 0.1) !important;
    border-color: rgba(139, 92, 246, 0.3) !important;
    color: var(--text-primary) !important;
}

#dashboard .player-nav-tabs .server-display {
    display: flex !important;
    align-items: center !important;
    gap: 14px !important;
    padding: 6px 20px 6px 8px !important;
    /* Premium symmetric padding */
    background: rgba(255, 255, 255, 0.04) !important;
    border-radius: var(--radius-full) !important;
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
    height: 44px !important;
}

#dashboard .player-nav-tabs .server-icon-header {
    width: 36px !important;
    height: 36px !important;
    border-radius: 50% !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    object-fit: cover !important;
}

#dashboard .player-nav-tabs .server-name-header {
    font-size: 13.5px !important;
    font-weight: 700 !important;
    color: var(--text-primary) !important;
    line-height: 1.2 !important;
    max-width: none !important;
}

#dashboard .player-nav-tabs .server-label {
    font-size: 10px !important;
    color: var(--text-muted) !important;
}

#dashboard .player-nav-tabs .server-display .plan-badge {
    display: inline-flex !important;
}

#dashboard .player-nav-tabs .server-name-row .plan-badge {
    display: inline-flex !important;
    flex-shrink: 0 !important;
    opacity: 1 !important;
    visibility: visible !important;
    min-width: fit-content !important;
}

#dashboard .player-nav-tabs .server-display .plan-badge.hidden,
#dashboard .player-nav-tabs .server-name-row .plan-badge.hidden {
    display: inline-flex !important;
}

#dashboard .player-nav-tabs .server-name-row {
    overflow: visible !important;
    white-space: nowrap !important;
    display: flex !important;
    align-items: center !important;
    gap: 8px !important;
}

#dashboard .player-nav-tabs .server-info-header {
    overflow: visible !important;
    min-width: auto !important;
    flex: 1 1 auto !important;
    max-width: none !important;
}

/* Tablet/Compact Row Mode */
@media (max-width: 1150px) {
    .player-nav-tabs {
        gap: 8px !important;
        padding: 5px 12px !important;
        min-width: unset !important;
        width: 100% !important;
        max-width: 95% !important;
    }
}

/* Optimized Stacking Breakpoint (Tablet vs Mobile) - ONE ROW MODE */
@media (max-width: 880px) {
    #dashboard .player-nav-tabs {
        flex-direction: row !important;
        border-radius: var(--radius-full) !important;
        padding: 6px 10px !important;
        gap: 6px !important;
        height: 54px !important;
        width: calc(100% - 16px) !important;
        min-width: 0 !important;
        justify-content: space-between !important;
        align-items: center !important;
        margin: 0 auto 12px auto !important;
        overflow: visible !important;
    }

    /* Hide tab labels early */
    #dashboard .player-nav-tabs .nav-tab span:not(.tab-badge) {
        display: none !important;
    }

    #dashboard .player-nav-tabs .nav-tab {
        padding: 6px 12px !important;
        min-width: 44px !important;
    }

    #dashboard .player-nav-tabs .server-info-header {
        max-width: 120px !important;
        overflow: hidden !important;
    }

    #dashboard .player-nav-tabs .server-name-header {
        font-size: 11px !important;
        white-space: nowrap !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
    }
}

/* Severe Mobile Tweak (e.g. iPhone SE, 320px) */
@media (max-width: 480px) {
    #dashboard .player-nav-tabs {
        padding: 4px 6px !important;
        gap: 4px !important;
        height: 48px !important;
        width: calc(100% - 10px) !important;
        margin-bottom: 8px !important;
    }

    /* Hide EVERYTHING except icons and back button/server icon if space is tight */
    #dashboard .player-nav-tabs .server-info-header,
    #dashboard .player-nav-tabs .server-display .server-name-header,
    #dashboard .player-nav-tabs .server-display .server-label,
    #dashboard .player-nav-tabs .server-info,
    #dashboard .player-nav-tabs .server-status {
        display: none !important;
    }

    #dashboard .player-nav-tabs .back-btn span {
        display: none !important;
    }

    #dashboard .player-nav-tabs .back-btn {
        width: 36px !important;
        height: 36px !important;
        padding: 0 !important;
    }

    #dashboard .player-nav-tabs .server-display {
        width: 36px !important;
        height: 36px !important;
        padding: 0 !important;
        justify-content: center !important;
        gap: 0 !important;
    }

    #dashboard .player-nav-tabs .server-icon-header {
        width: 28px !important;
        height: 28px !important;
    }

    #dashboard .player-nav-tabs .tabs-center {
        gap: 4px !important;
        padding: 0 !important;
    }

    #dashboard .player-nav-tabs .nav-tab {
        padding: 4px !important;
        height: 36px !important;
        width: 36px !important;
        min-width: 36px !important;
        flex: 0 0 36px !important;
    }

    #dashboard .player-nav-tabs .nav-tab i {
        font-size: 18px !important;
    }
}

/* Ultra-compact 600px and below (Mobile View) */
@media (max-width: 600px) {
    #dashboard .player-nav-tabs {
        padding: 4px 6px !important;
        gap: 2px !important;
    }

    #dashboard .player-nav-tabs .nav-tab {
        padding: 4px 6px !important;
        min-width: 40px !important;
    }

    /* Force icon-only for the absolute smallest screens */
    #dashboard .player-nav-tabs .nav-tab span:not(.tab-badge) {
        display: none !important;
    }

    #dashboard .player-nav-tabs .back-btn {
        width: 36px !important;
        height: 36px !important;
    }
}

/* ============================================================================
   FINAL ATOMIC MOBILE OVERRIDE - NO MERCY FOR OVERFLOW
   ============================================================================ */
@media (max-width: 600px) {

    html,
    body {
        overflow-x: hidden !important;
        width: 100% !important;
        position: relative !important;
    }

    #dashboard,
    .dashboard,
    .main-area,
    .view-container,
    .player-layout-container {
        width: 100% !important;
        max-width: 100vw !important;
        overflow-x: hidden !important;
        margin: 0 !important;
        padding-left: 0 !important;
        padding-right: 0 !important;
    }

    .content-container {
        padding: 10px !important;
        width: 100% !important;
    }

    .navbar {
        width: calc(100% - 16px) !important;
        left: 8px !important;
        right: 8px !important;
        transform: none !important;
        margin: 0 !important;
        position: fixed !important;
        top: 10px !important;
    }

    /* Aggressive Hiding of Server Info on Mobile Nav */
    #dashboard .player-nav-tabs .server-info-header,
    #dashboard .player-nav-tabs .server-display .server-name-header,
    #dashboard .player-nav-tabs .server-display .server-label,
    #dashboard .player-nav-tabs .server-info,
    #dashboard .player-nav-tabs .server-status,
    #dashboard .player-nav-tabs .server-name-row .plan-badge,
    #dashboard .player-nav-tabs .plan-badge {
        display: none !important;
        width: 0 !important;
        height: 0 !important;
        overflow: hidden !important;
    }

    #dashboard .player-nav-tabs .server-display {
        width: 40px !important;
        height: 40px !important;
        padding: 0 !important;
        justify-content: center !important;
        gap: 0 !important;
        border-radius: 12px !important;
    }

    #dashboard .player-nav-tabs .server-icon-header {
        width: 30px !important;
        height: 30px !important;
        margin: 0 !important;
        border-radius: 8px !important;
    }
}

/* Responsive adjustments for player mode when navbar is hidden */
@media (max-width: 768px) {
    body.player-mode .dashboard {
        padding-top: 10px;
    }

    body.player-mode #playing-view.active {
        height: calc(100vh - 120px);
    }

    body.player-mode #playing-view.active .player-layout-container {
        padding: 8px !important;
    }
}

@media (max-width: 480px) {
    body.player-mode .dashboard {
        padding-top: 5px;
    }

    body.player-mode #playing-view.active {
        height: calc(100vh - 100px);
    }

    body.player-mode #playing-view.active .player-layout-container {
        padding: 4px !important;
    }

    body.player-mode .player-nav-tabs {
        margin-bottom: 8px !important;
    }
}

/* ════════════════════════════════════════════════════════════════════════════
   PV-* — Server Music Player (complete re-skin, ref-image accurate)
   Only #playing-view, .pv-*, .pvl-*, .pvc-*, .pvr-*, .pv-bar-* touched.
   All original CSS variables / animations kept intact.
   ════════════════════════════════════════════════════════════════════════════ */

/* ── hide main navbar in player mode ─────────────────────────────────────── */
body.player-mode .navbar {
    display: none !important;
}

body.player-mode .dashboard {
    padding-top: 0 !important;
    overflow: hidden !important;
    height: 100vh !important;
    display: flex !important;
    flex-direction: column !important;
}

body.player-mode .content-container {
    display: none !important;
}

body.player-mode .main-area {
    flex: 1 !important;
    overflow: hidden !important;
    min-height: 0 !important;
    display: flex !important;
    flex-direction: column !important;
    padding-bottom: 80px !important;
}

/* ── playing-view base ────────────────────────────────────────────────────── */
#playing-view {
    display: none;
}

#playing-view.active {
    display: flex !important;
    flex-direction: column !important;
    flex: 1 !important;
    min-height: 0 !important;
    height: calc(100% - 80px) !important;
    /* leave exact room for fixed player-bar */
    opacity: 1 !important;
    pointer-events: auto !important;
    overflow: hidden !important;
}

/* Shell: stacks topbar + body vertically, fills all space except fixed player-bar */
.pv-shell {
    display: grid;
    grid-template-columns: 220px 1fr 300px;
    grid-template-rows: auto auto 1fr;
    flex: 1;
    height: 0;
    min-height: 0;
    gap: 8px;
    padding: 10px 12px 0;
    box-sizing: border-box;
    overflow: hidden;
}

/* topbar spans only the center column */
.pv-topbar {
    grid-column: 2;
    grid-row: 1;
}

/* ════════════════════════════════════════════════════════════════════════════
   BREADCRUMB  (between topbar and pv-center)
   ════════════════════════════════════════════════════════════════════════════ */
.pv-breadcrumb {
    grid-column: 2;
    grid-row: 2;
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 0 4px 6px;
    flex-shrink: 0;
    align-self: start;
}

.pv-bc-item {
    font-size: 11px;
    font-weight: 500;
    color: rgba(255, 255, 255, .28);
    white-space: nowrap;
    letter-spacing: .02em;
}

.pv-bc-sep {
    font-size: 9px;
    color: rgba(255, 255, 255, .15);
}

.pv-bc-active {
    color: #c4b5fd;
    font-weight: 600;
    max-width: 160px;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* ════════════════════════════════════════════════════════════════════════════
   TOP BAR  (ref: ← | logo | search full-width | avatar·plan)
   ════════════════════════════════════════════════════════════════════════════ */
.pv-topbar {
    display: flex;
    align-items: center;
    gap: 10px;
    height: 48px;
    flex-shrink: 0;
    padding: 0 2px;
}

/* back chevron */
.pv-back-btn {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 50%;
    color: rgba(255, 255, 255, 0.6);
    font-size: 14px;
    cursor: pointer;
    flex-shrink: 0;
    transition: all .2s ease;
}

.pv-back-btn:hover {
    background: rgba(139, 92, 246, .12);
    border-color: rgba(139, 92, 246, .3);
    color: #c4b5fd;
}

/* top-brand wrapper inside pv-left */
.pvl-top-brand {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 4px 14px;
    flex-shrink: 0;
    border-bottom: 1px solid rgba(255, 255, 255, .05);
    margin-bottom: 14px;
}

/* breadcrumb in topbar */
.pv-breadcrumb {
    font-size: 12px;
    font-weight: 600;
    color: rgba(255, 255, 255, .38);
    white-space: nowrap;
    flex-shrink: 0;
    letter-spacing: .01em;
}

.pv-breadcrumb #pv-breadcrumb-server {
    color: rgba(168, 139, 250, .85);
}

/* logo */
.pv-brand {
    display: flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    flex-shrink: 0;
}

.pv-brand-logo {
    height: 34px;
    width: 34px;
    border-radius: 50%;
    border: 2px solid rgba(139, 92, 246, .45);
    box-shadow: 0 0 14px rgba(139, 92, 246, .3);
    object-fit: contain;
    padding: 3px;
}

.pv-brand-wordmark {
    height: 24px;
    width: auto;
    opacity: .9;
}

/* search — takes all remaining space */
.pv-search-wrap {
    flex: 1;
    position: relative;
    min-width: 0;
}

.pv-search-ico {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: rgba(255, 255, 255, .35);
    font-size: 13px;
    pointer-events: none;
}

.pv-search-input {
    width: 100%;
    height: 40px;
    padding: 0 40px 0 38px;
    background: rgba(255, 255, 255, .04);
    border: 1px solid rgba(255, 255, 255, .08);
    border-radius: 999px;
    color: #fff;
    font-size: 13px;
    font-family: inherit;
    outline: none;
    transition: all .2s ease;
}

.pv-search-input::placeholder {
    color: rgba(255, 255, 255, .3);
}

.pv-search-input:focus {
    background: rgba(139, 92, 246, .07);
    border-color: rgba(139, 92, 246, .45);
    box-shadow: 0 0 0 3px rgba(139, 92, 246, .09);
}

.pv-search-x {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: rgba(255, 255, 255, .08);
    border: none;
    color: rgba(255, 255, 255, .5);
    font-size: 10px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all .2s;
}

.pv-search-x:hover {
    background: rgba(255, 255, 255, .15);
    color: #fff;
}

/* ════════════════════════════════════════════════════════════════════════════
   3-COLUMN BODY
   ════════════════════════════════════════════════════════════════════════════ */
.pv-body {
    display: contents;
    /* let children participate directly in shell grid */
}

/* shared panel shell */
.pv-left,
.pv-center,
.pv-right {
    background: rgba(12, 10, 20, .6);
    backdrop-filter: blur(22px) saturate(1.5);
    -webkit-backdrop-filter: blur(22px) saturate(1.5);
    border: 1px solid rgba(255, 255, 255, .06);
    border-radius: 18px 18px 0 0;
    /* top corners only — bottom flush with player bar */
    overflow: hidden;
    box-shadow: 0 6px 28px rgba(0, 0, 0, .4), inset 0 1px 0 rgba(255, 255, 255, .035);
}

/* left spans all rows → goes all the way to top */
.pv-left {
    grid-column: 1;
    grid-row: 1 / 4;
    border-top-left-radius: 20px;
    border-top-right-radius: 18px;
}

/* center only in row 3 (below topbar + breadcrumb) */
.pv-center {
    grid-column: 2;
    grid-row: 3;
}

/* right spans all rows → goes all the way to top */
.pv-right {
    grid-column: 3;
    grid-row: 1 / 4;
    border-top-left-radius: 18px;
    border-top-right-radius: 20px;
}

/* ════════════════════════════════════════════════════════════════════════════
   LEFT SIDEBAR
   ════════════════════════════════════════════════════════════════════════════ */
.pv-left {
    display: flex;
    flex-direction: column;
    padding: 14px 12px;
    gap: 0;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: rgba(139, 92, 246, .2) transparent;
}

/* server card */
.pvl-server-card {
    display: flex;
    align-items: center;
    gap: 9px;
    padding: 9px 10px;
    background: linear-gradient(135deg, rgba(139, 92, 246, .10), rgba(168, 139, 250, .04));
    border: 1px solid rgba(139, 92, 246, .2);
    border-radius: 13px;
    margin-top: 20px;
    margin-bottom: 16px;
    cursor: default;
    transition: all .25s ease;
    position: relative;
}

.pvl-server-card::before {
    content: '';
    position: absolute;
    top: -11px;
    left: 0;
    right: 0;
    border-top: 1px solid rgba(255, 255, 255, .05);
}


.pvl-srv-icon {
    width: 36px;
    height: 36px;
    border-radius: 9px;
    object-fit: cover;
    flex-shrink: 0;
    box-shadow: 0 2px 8px rgba(0, 0, 0, .35);
}

.pvl-srv-meta {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.pvl-srv-name-row {
    display: flex;
    align-items: center;
    gap: 6px;
}

.pvl-srv-name {
    font-size: 12px;
    font-weight: 700;
    color: #fff;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100px;
}

.pvl-srv-status {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 10px;
    color: var(--text-muted);
    font-weight: 500;
}

.pvl-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #4b5563;
    flex-shrink: 0;
}

.pvl-server-card.connected .pvl-dot {
    background: #10b981;
    box-shadow: 0 0 7px rgba(16, 185, 129, .7);
    animation: pulseDot 1.8s ease-in-out infinite;
}

.pvl-server-card.connected .pvl-srv-status {
    color: #10b981;
}

/* quick-access nav */
.pvl-quicknav {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.pvl-nav-label {
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .1em;
    color: rgba(255, 255, 255, .28);
    padding: 0 8px 8px;
}

.pvl-nav-link {
    display: flex;
    align-items: center;
    gap: 9px;
    padding: 9px 10px;
    border-radius: 11px;
    color: rgba(255, 255, 255, .5);
    font-size: 13px;
    font-weight: 500;
    text-decoration: none;
    transition: all .18s ease;
}

.pvl-nav-link i {
    width: 16px;
    text-align: center;
    font-size: 13px;
    opacity: .7;
}

.pvl-nav-link:hover {
    color: #fff;
    background: rgba(255, 255, 255, .05);
}

.pvl-nav-active {
    color: #fff !important;
    background: rgba(139, 92, 246, .12) !important;
}

.pvl-nav-active i {
    opacity: 1;
    color: #a78bfa;
}

/* user bottom strip */
.pvl-user-bottom {
    display: flex;
    align-items: center;
    gap: 9px;
    padding: 10px 8px 2px;
    border-top: 1px solid rgba(255, 255, 255, .05);
    margin-top: 8px;
}

.pvl-user-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid rgba(139, 92, 246, .35);
    flex-shrink: 0;
}

.pvl-user-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
    flex: 1;
}

.pvl-user-name {
    font-size: 12px;
    font-weight: 600;
    color: #fff;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 110px;
}

/* ════════════════════════════════════════════════════════════════════════════
   CENTER — hero art + track name
   ════════════════════════════════════════════════════════════════════════════ */
.pv-center {
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

/* aurora bg */
.pv-center::before {
    content: '';
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 0;
    background:
        radial-gradient(ellipse 70% 50% at 50% 30%, rgba(139, 92, 246, .10) 0%, transparent 70%),
        radial-gradient(ellipse 50% 40% at 30% 75%, rgba(244, 114, 182, .07) 0%, transparent 60%);
}

.pv-center>* {
    position: relative;
    z-index: 1;
}

/* hero (track playing) */
.pvc-hero {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 22px;
    padding: 28px 20px;
    width: 100%;
    animation: spHeroReveal .55s cubic-bezier(.16, 1, .3, 1);
}

.pvc-hero.hidden {
    display: none !important;
}

@keyframes spHeroReveal {
    from {
        opacity: 0;
        transform: translateY(14px) scale(.97);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.pvc-art-wrap {
    position: relative;
    flex-shrink: 0;
}

.pvc-art {
    width: clamp(200px, 26vw, 340px);
    height: clamp(200px, 26vw, 340px);
    border-radius: 18px;
    object-fit: cover;
    display: block;
    box-shadow: 0 24px 72px rgba(0, 0, 0, .65), 0 0 0 1px rgba(255, 255, 255, .08), 0 0 56px rgba(139, 92, 246, .17);
    transition: transform .4s cubic-bezier(.16, 1, .3, 1), box-shadow .4s ease;
}

.pvc-art:hover {
    transform: scale(1.04) translateY(-4px);
    box-shadow: 0 32px 96px rgba(0, 0, 0, .7), 0 0 0 1px rgba(255, 255, 255, .12), 0 0 72px rgba(139, 92, 246, .26);
}

.pvc-art-glow {
    position: absolute;
    inset: 0;
    border-radius: 18px;
    filter: blur(44px) saturate(1.6);
    opacity: .28;
    z-index: -1;
    transform: scale(1.12) translateY(12px);
    pointer-events: none;
    background: inherit;
}

.pvc-track-info {
    text-align: center;
    max-width: 90%;
}

.pvc-title {
    font-size: clamp(16px, 2vw, 24px);
    font-weight: 800;
    color: #fff;
    line-height: 1.2;
    letter-spacing: -.02em;
    margin-bottom: 5px;
    background: linear-gradient(135deg, #fff, #ddd6fe);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.pvc-artist {
    font-size: 13px;
    color: rgba(255, 255, 255, .45);
    font-weight: 500;
    letter-spacing: .05em;
    text-transform: uppercase;
}

/* empty state */
.pvc-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    padding: 28px;
    text-align: center;
}

.pvc-empty-ico {
    width: 90px;
    height: 90px;
    border-radius: 50%;
    background: linear-gradient(145deg, rgba(139, 92, 246, .12), rgba(168, 139, 250, .04));
    border: 1.5px solid rgba(139, 92, 246, .18);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 34px;
    color: rgba(139, 92, 246, .55);
    box-shadow: 0 0 32px rgba(139, 92, 246, .09), inset 0 1px 0 rgba(255, 255, 255, .04);
    margin-bottom: 4px;
    animation: float 5s ease-in-out infinite;
}

.pvc-empty-title {
    font-size: 1.45rem;
    font-weight: 800;
    color: #fff;
    letter-spacing: -.02em;
}

.pvc-empty-sub {
    font-size: 13px;
    color: rgba(255, 255, 255, .35);
}

/* ════════════════════════════════════════════════════════════════════════════
   RIGHT PANEL  (exact ref layout)
   ════════════════════════════════════════════════════════════════════════════ */
.pv-right {
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

/* tab strip */
.pvr-tabs {
    display: flex;
    align-items: center;
    gap: 1px;
    padding: 8px 8px 0;
    flex-shrink: 0;
    border-bottom: 1px solid rgba(255, 255, 255, .05);
    padding-bottom: 7px;
}

.pvr-tab {
    display: flex;
    align-items: center;
    gap: 5px;
    padding: 6px 9px;
    background: transparent;
    border: none;
    border-radius: 9px;
    color: rgba(255, 255, 255, .38);
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: all .18s ease;
    font-family: inherit;
    white-space: nowrap;
}

.pvr-tab i {
    font-size: 11px;
}

.pvr-tab:hover {
    color: rgba(255, 255, 255, .7);
    background: rgba(255, 255, 255, .04);
}

.pvr-tab.active {
    color: #fff;
    background: linear-gradient(135deg, rgba(139, 92, 246, .18), rgba(168, 139, 250, .08));
    box-shadow: inset 0 0 0 1px rgba(139, 92, 246, .25);
}

.pvr-badge {
    background: rgba(139, 92, 246, .35);
    color: #c4b5fd;
    font-size: 10px;
    font-weight: 700;
    padding: 1px 6px;
    border-radius: 8px;
    min-width: 18px;
    text-align: center;
}

/* scrollable content */
.pvr-content {
    flex: 1;
    overflow: hidden;
    position: relative;
    min-height: 0;
}

.pvr-panel {
    display: none;
    flex-direction: column;
    gap: 4px;
    height: 100%;
    overflow-y: auto;
    padding: 10px 10px 12px;
    scrollbar-width: thin;
    scrollbar-color: rgba(139, 92, 246, .2) transparent;
    animation: fadeUp .28s ease;
}

.pvr-panel::-webkit-scrollbar {
    width: 3px;
}

.pvr-panel::-webkit-scrollbar-thumb {
    background: rgba(139, 92, 246, .28);
    border-radius: 3px;
}

.pvr-panel.active {
    display: flex;
}

/* queue list */
.pvr-queue-list {
    display: flex;
    flex-direction: column;
    gap: 2px;
    flex: 1;
}

.pvr-queue-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 30px 12px;
    color: rgba(255, 255, 255, .25);
    font-size: 12px;
    font-weight: 500;
    text-align: center;
}

.pvr-queue-empty i {
    font-size: 22px;
    opacity: .35;
}

/* ════════════════════════════════════════════════════════════════════════════
   PLAYER BAR  — redesigned to match ref image
   compact pill: art+info | transport+progress | eq·leave·volume
   ════════════════════════════════════════════════════════════════════════════ */
.pv-bar-content {
    /* Layout only — background/border/shadow come from .player-content */
    height: 80px !important;
    display: grid !important;
    grid-template-columns: 220px 1fr 300px !important;
    align-items: center !important;
    gap: 0 !important;
    padding: 0 28px !important;
    background: transparent !important;
    backdrop-filter: none !important;
    border: none !important;
    border-radius: 0 !important;
    box-shadow: none !important;
}

/* track left */
.pv-bar-track {
    display: flex;
    align-items: center;
    gap: 11px;
    min-width: 0;
    overflow: hidden;
    padding-right: 28px;
    position: relative;
}

.pv-bar-art-wrap {
    width: 50px;
    height: 50px;
    border-radius: 12px;
    overflow: hidden;
    flex-shrink: 0;
    box-shadow: 0 4px 16px rgba(0, 0, 0, .55), 0 0 0 1px rgba(255, 255, 255, .06);
    transition: box-shadow .3s ease;
}

.pv-bar-art-wrap:hover {
    box-shadow: 0 4px 20px rgba(139, 92, 246, .25), 0 0 0 1px rgba(139, 92, 246, .2);
}

.pv-bar-art {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .35s ease;
}

.pv-bar-art-wrap:hover .pv-bar-art {
    transform: scale(1.06);
}

.pv-bar-info {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.pv-bar-title {
    font-size: 14px;
    font-weight: 700;
    color: #fff;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    letter-spacing: -.015em;
    line-height: 1.2;
}

.pv-bar-artist {
    font-size: 11px;
    color: rgba(255, 255, 255, .38);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-weight: 500;
    letter-spacing: .02em;
}

/* controls centre */
.pv-bar-controls {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    min-width: 0;
    overflow: hidden;
    padding: 0 20px;
    position: relative;
    /* override old .player-controls mobile stacking */
    flex-direction: column !important;
    margin-bottom: 0 !important;
}

.pv-bar-btns {
    display: flex;
    align-items: center;
    gap: 6px;
    /* override old control-buttons */
    width: auto !important;
}

.pv-bar-progress {
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
    max-width: 100%;
    /* override old .progress-section */
    flex-direction: row !important;
    margin-bottom: 0 !important;
}

.pv-time {
    font-size: 10px;
    color: rgba(255, 255, 255, .32);
    width: 32px;
    text-align: center;
    font-variant-numeric: tabular-nums;
}

/* right section */
.pv-bar-right {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 10px;
    /* override old player-right-wrapper */
    flex-direction: row !important;
    width: auto !important;
}

.pv-bar-actions {
    display: flex;
    align-items: center;
    gap: 6px;
}

/* ── Volume Control — redesigned ── */
.pv-bar-vol {
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, .04);
    border: 1px solid rgba(255, 255, 255, .07);
    border-radius: 999px;
    padding: 5px 12px 5px 8px;
    transition: all .2s ease;
}

.pv-bar-vol:hover {
    background: rgba(139, 92, 246, .07);
    border-color: rgba(139, 92, 246, .22);
}

/* mute icon button inside the pill */
.pv-bar-vol .pv-icon-btn {
    width: 26px;
    height: 26px;
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
    color: rgba(255, 255, 255, .45);
    font-size: 13px;
    flex-shrink: 0;
    padding: 0;
    border-radius: 50%;
    transition: color .2s ease, transform .15s ease;
}

.pv-bar-vol .pv-icon-btn:hover {
    color: #fff;
    background: transparent !important;
    transform: scale(1.1);
}

/* slider track wrapper */
.pv-vol-track {
    width: 88px !important;
    height: 4px;
    background: rgba(255, 255, 255, .10);
    border-radius: 999px;
    position: relative;
    cursor: pointer;
    flex-shrink: 0;
    overflow: visible;
    transition: transform .15s ease;
}

.pv-bar-vol:hover .pv-vol-track {
    transform: scaleY(1.4);
}

/* filled portion */
.volume-fill-bg {
    display: none;
}

.volume-fill-bar {
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    border-radius: 999px;
    background: linear-gradient(90deg, rgba(139, 92, 246, .7) 0%, #a78bfa 60%, #c4b5fd 100%);
    transition: width .05s linear, background .2s ease;
    pointer-events: none;
    overflow: visible;
}

/* range input overlay */
.volume-slider {
    position: absolute;
    inset: -8px 0;
    width: 100%;
    height: calc(100% + 16px);
    opacity: 0;
    cursor: pointer;
    z-index: 2;
    margin: 0;
    appearance: none;
    -webkit-appearance: none;
    background: transparent;
    border: none;
    padding: 0;
}

/* webkit thumb (hidden but needed for cursor) */
.volume-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 14px;
    height: 14px;
    background: #fff;
    border-radius: 50%;
    cursor: pointer;
}

.volume-slider::-moz-range-thumb {
    width: 14px;
    height: 14px;
    background: #fff;
    border: none;
    border-radius: 50%;
    cursor: pointer;
}

/* show a glowing thumb dot at end of fill bar */
.volume-fill-bar::after {
    content: '';
    position: absolute;
    right: -1px;
    top: 50%;
    transform: translateY(-50%);
    width: 12px;
    height: 12px;
    background: #fff;
    border-radius: 50%;
    box-shadow: 0 0 8px rgba(139, 92, 246, .9), 0 0 16px rgba(139, 92, 246, .4);
    opacity: 0;
    transition: opacity .2s ease;
    pointer-events: none;
}

.pv-bar-vol:hover .volume-fill-bar::after {
    opacity: 1;
}

/* percentage label */
.pv-vol-pct {
    font-size: 11px;
    font-weight: 600;
    color: rgba(255, 255, 255, .35);
    width: 28px;
    text-align: right;
    font-variant-numeric: tabular-nums;
    letter-spacing: -.01em;
    transition: color .2s ease;
}

.pv-bar-vol:hover .pv-vol-pct {
    color: rgba(255, 255, 255, .65);
}

.pv-icon-btn {
    width: 32px;
    height: 32px;
    border-radius: 9px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, .04);
    color: rgba(255, 255, 255, .45);
    border: 1px solid rgba(255, 255, 255, .07);
    cursor: pointer;
    font-size: 12px;
    transition: all .2s ease;
}

.pv-icon-btn:hover {
    background: rgba(255, 255, 255, .09);
    color: #fff;
    border-color: rgba(255, 255, 255, .12);
    transform: translateY(-1px);
}

/* Transport controls — uniform rounded squares */
.pv-ctrl {
    width: 34px !important;
    height: 34px !important;
    font-size: 12px !important;
    border-radius: 10px !important;
    background: rgba(255, 255, 255, .05) !important;
    border: 1px solid rgba(255, 255, 255, .07) !important;
    color: rgba(255, 255, 255, .55) !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    cursor: pointer;
    transition: all .18s ease !important;
}

.pv-ctrl:hover {
    background: rgba(255, 255, 255, .10) !important;
    color: #fff !important;
    border-color: rgba(255, 255, 255, .15) !important;
    transform: translateY(-1px);
}

.pv-ctrl.active {
    color: #a78bfa !important;
    background: rgba(139, 92, 246, .12) !important;
    border-color: rgba(139, 92, 246, .25) !important;
}

/* Play/Pause — prominent circle with gradient */
.pv-ctrl-play {
    width: 44px !important;
    height: 44px !important;
    border-radius: 50% !important;
    font-size: 16px !important;
    margin: 0 6px !important;
    background: linear-gradient(135deg, #7c3aed, #a855f7) !important;
    border: none !important;
    color: #fff !important;
    box-shadow: 0 0 20px rgba(139, 92, 246, .45), 0 4px 12px rgba(0, 0, 0, .4) !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    cursor: pointer;
    transition: all .2s ease !important;
}

.pv-ctrl-play:hover {
    background: linear-gradient(135deg, #8b45f5, #b56df8) !important;
    box-shadow: 0 0 28px rgba(139, 92, 246, .65), 0 6px 16px rgba(0, 0, 0, .5) !important;
    transform: scale(1.07) !important;
}

.pv-ctrl-play:active {
    transform: scale(0.97) !important;
}

/* ════════════════════════════════════════════════════════════════════════════
   RESPONSIVE — Server Music Player
   ════════════════════════════════════════════════════════════════════════════ */

/* ── 1200px: shrink sidebar & right panel slightly ── */
/* ── 1200px: shrink sidebar & right panel slightly ── */
@media (max-width:1200px) {
    .pv-shell {
        grid-template-columns: 190px 1fr 270px;
    }
}

/* ── 1024px: tighter, hide wordmark ── */
@media (max-width:1024px) {
    .pv-shell {
        grid-template-columns: 160px 1fr 240px;
        gap: 6px;
    }

    .pv-brand-wordmark {
        display: none;
    }

    .pv-bar-content {
        grid-template-columns: 160px 1fr 200px;
        padding: 0 20px !important;
    }

    .pv-vol-track {
        width: 70px !important;
    }
}

/* ── 900px and below: MOBILE DRAWER SYSTEM ── */
@media (max-width:900px) {
    .pv-shell {
        grid-template-columns: 1fr !important;
        grid-template-rows: auto auto 1fr !important;
        padding: 0 !important;
        gap: 8px;
        height: 100dvh !important;
        position: fixed !important;
        top: 0 !important;
        left: 0 !important;
        right: 0 !important;
        bottom: 0 !important;
        z-index: 99990 !important;
        background: var(--bg-main) !important;
        overflow-y: auto !important;
        padding-bottom: 72px !important;
    }

    .pv-topbar {
        grid-column: 1 !important;
        grid-row: 1 !important;
        width: 100% !important;
    }

    .pv-breadcrumb {
        grid-column: 1 !important;
        grid-row: 2 !important;
        width: 100% !important;
        padding: 0 4px 8px;
    }

    .pv-center {
        grid-column: 1 !important;
        grid-row: 3 !important;
        width: 100% !important;
        min-height: 0;
    }

    /* Convert Sidebars to Drawers */
    .pv-left,
    .pv-right {
        position: fixed !important;
        top: 0 !important;
        bottom: 0 !important;
        width: 280px !important;
        max-width: 85vw !important;
        height: 100vh !important;
        z-index: 5000 !important;
        transition: transform 0.4s cubic-bezier(0.165, 0.84, 0.44, 1) !important;
        border-radius: 0 !important;
        background: rgba(12, 10, 20, 0.98) !important;
        backdrop-filter: blur(25px) saturate(1.8) !important;
        -webkit-backdrop-filter: blur(25px) saturate(1.8) !important;
        border: none !important;
        box-shadow: 0 0 50px rgba(0, 0, 0, 0.6) !important;
    }

    .pv-left {
        left: 0 !important;
        transform: translateX(-105%) !important;
        border-right: 1px solid rgba(139, 92, 246, 0.2) !important;
    }

    .pv-right {
        right: 0 !important;
        transform: translateX(105%) !important;
        border-left: 1px solid rgba(139, 92, 246, 0.2) !important;
    }

    /* Active Drawer States (Controlled by JS classes on body) */
    body.pv-left-open .pv-left {
        transform: translateX(0) !important;
    }

    body.pv-right-open .pv-right {
        transform: translateX(0) !important;
    }

    /* Custom Backdrop for Player View Drawers */
    .pv-overlay {
        position: fixed;
        inset: 0;
        background: rgba(0, 0, 0, 0.65);
        backdrop-filter: blur(4px);
        -webkit-backdrop-filter: blur(4px);
        z-index: 4900;
        opacity: 0;
        pointer-events: none;
        transition: opacity 0.3s ease;
    }

    body.pv-left-open .pv-overlay,
    body.pv-right-open .pv-overlay {
        opacity: 1;
        pointer-events: auto;
    }

    /* Center Section Adjustments */
    .pvc-hero {
        padding: 20px 10px;
        gap: 15px;
    }

    .pvc-art {
        width: clamp(140px, 35vw, 220px) !important;
        height: clamp(140px, 35vw, 220px) !important;
    }

    /* ── PLAYER BAR MOBILE LAYOUT ── */
    .player-bar {
        height: 72px !important;
        bottom: 0 !important;
    }

    .player-bar.player-minimized {
        transform: translateY(calc(100% - 48px)) !important;
    }

    .pv-bar-content {
        grid-template-columns: 100px 1fr auto !important;
        height: 72px !important;
        padding: 0 12px !important;
        gap: 8px !important;
    }

    .pv-bar-track {
        min-width: 0 !important;
        padding-right: 0 !important;
    }

    .pv-bar-art-wrap {
        width: 50px !important;
        height: 50px !important;
        flex-shrink: 0 !important;
    }

    .pv-bar-info {
        display: flex !important;
        flex-direction: column !important;
        gap: 2px !important;
        overflow: hidden !important;
    }

    .pv-bar-title {
        font-size: 12px !important;
        white-space: nowrap !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
    }

    .pv-bar-artist {
        font-size: 10px !important;
        opacity: 0.7 !important;
        white-space: nowrap !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
    }

    .pv-bar-controls {
        width: 100% !important;
        padding: 0 !important;
        display: flex !important;
        flex-direction: column !important;
        align-items: center !important;
        justify-content: center !important;
        gap: 2px !important;
    }

    .pv-bar-btns {
        justify-content: center !important;
        gap: 8px !important;
        width: 100% !important;
    }

    .pv-bar-progress {
        display: flex !important;
        align-items: center !important;
        gap: 6px !important;
        width: 100% !important;
    }

    .pv-bar-progress .time {
        font-size: 9px !important;
        min-width: 28px !important;
    }

    /* Show volume on mobile, but scale it elegantly to fit the row */
    .pv-bar-right {
        display: flex !important;
        flex-direction: row !important;
        align-items: center !important;
        justify-content: center !important;
        gap: 16px !important;
        width: 100% !important;
    }

    .pv-bar-actions {
        display: flex !important;
        flex-direction: row !important;
        gap: 16px !important;
        align-items: center !important;
    }

    .pv-bar-vol {
        display: flex !important;
        align-items: center !important;
        background: rgba(255, 255, 255, 0.05) !important;
        padding: 6px 10px !important;
        border-radius: 99px !important;
        gap: 8px !important;
        border: 1px solid rgba(255, 255, 255, 0.08) !important;
    }

    .volume-slider,
    .volume-icon {
        display: flex !important;
    }

    .pv-vol-pct {
        display: none !important;
        /* Hide the percentage text to save space on mobile */
    }

    .pv-vol-track {
        width: 70px !important;
        /* Smaller width for mobile */
    }

    .volume-icon {
        width: 24px !important;
        height: 24px !important;
        font-size: 11px !important;
        background: transparent !important;
        box-shadow: none !important;
    }

    /* Control buttons */
    .pv-ctrl {
        width: 32px !important;
        height: 32px !important;
        font-size: 11px !important;
    }

    .pv-ctrl-play {
        width: 42px !important;
        height: 42px !important;
    }

    #fx-btn,
    #leave-btn,
    #shuffle-btn,
    #loop-btn,
    #stop-btn,
    #autoplay-btn {
        display: flex !important;
        width: 32px !important;
        height: 32px !important;
    }

    /* ── Swipe Indicators: Premium Glassmorphism ── */
    .pv-swipe-indicator {
        position: fixed !important;
        top: 45% !important;
        width: 34px !important;
        height: 64px !important;
        background: rgba(255, 255, 255, 0.03) !important;
        backdrop-filter: blur(12px) !important;
        -webkit-backdrop-filter: blur(12px) !important;
        border: 1px solid rgba(255, 255, 255, 0.08) !important;
        color: rgba(255, 255, 255, 0.3) !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        z-index: 4500 !important;
        cursor: pointer !important;
        transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
        box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2) !important;
    }

    .pv-swipe-indicator.left {
        left: 0 !important;
        border-radius: 0 16px 16px 0 !important;
        padding-right: 4px !important;
    }

    .pv-swipe-indicator.right {
        right: 0 !important;
        border-radius: 16px 0 0 16px !important;
        padding-left: 4px !important;
    }

    .pv-swipe-indicator:hover,
    .pv-swipe-indicator:active {
        background: rgba(139, 92, 246, 0.1) !important;
        border-color: rgba(139, 92, 246, 0.3) !important;
        color: #fff !important;
        width: 40px !important;
    }

    .pv-swipe-indicator i {
        font-size: 16px !important;
    }

    .pv-swipe-indicator.left i {
        animation: hintBounceLeft 2.5s infinite ease-in-out;
    }

    .pv-swipe-indicator.right i {
        animation: hintBounceRight 2.5s infinite ease-in-out;
    }

    @keyframes hintBounceLeft {

        0%,
        100% {
            transform: translateX(0);
            opacity: 0.3;
        }

        50% {
            transform: translateX(4px);
            opacity: 0.8;
        }
    }

    @keyframes hintBounceRight {

        0%,
        100% {
            transform: translateX(0);
            opacity: 0.3;
        }

        50% {
            transform: translateX(-4px);
            opacity: 0.8;
        }
    }

    body.pv-left-open #pv-indicator-left,
    body.pv-right-open #pv-indicator-right {
        opacity: 0 !important;
        pointer-events: none !important;
        transform: translateY(-50%) translateX(-100%) !important;
    }

    body.pv-right-open #pv-indicator-right {
        transform: translateY(-50%) translateX(100%) !important;
    }
}

/* ── 900px and below (Full Premium Mobile Redesign extending up to Tablet) ── */
@media (max-width:900px) {

    /* Main content: make room for the fixed player bar — ONLY when a track is playing and bar is NOT minimized */
    body.player-active:not(.player-minimized) .dashboard-main,
    body.player-active:not(.player-minimized) main,
    body.player-active:not(.player-minimized) .pv-shell,
    body.player-active:not(.player-minimized) .player-view {
        padding-bottom: 260px !important;
    }

    /* Add smooth transition so the gap doesn't vanish instantly, creating a jerk */
    .dashboard-main,
    main,
    .pv-shell,
    .player-view {
        transition: padding-bottom 0.4s cubic-bezier(0.4, 0, 0.2, 1) !important;
    }

    /* Arrow collapse/expand button (Sibling decoupled from player bar) */
    /* Only display the button when the body has .player-active (a server is selected) */
    body.player-active .player-bar-collapse-btn {
        display: flex !important;
    }

    .player-bar-collapse-btn {
        position: fixed !important;
        /* Base open position: perfectly aligns with top-right of the 260px tall player bar */
        bottom: 245px !important;
        right: 15px !important;
        width: 32px !important;
        height: 32px !important;
        border-radius: 50% !important;
        background: rgba(40, 40, 60, 0.9) !important;
        border: 1px solid rgba(255, 255, 255, 0.15) !important;
        color: rgba(255, 255, 255, 0.9) !important;
        font-size: 13px !important;
        align-items: center !important;
        justify-content: center !important;
        cursor: pointer !important;
        z-index: 2147483647 !important;
        pointer-events: auto !important;
        transition: background 0.2s, transform 0.4s cubic-bezier(0.4, 0, 0.2, 1) !important;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5) !important;
    }

    .player-bar-collapse-btn:hover {
        background: rgba(60, 60, 90, 0.9) !important;
    }

    /* When minimized, slide down 230px so it sits at bottom: 15px */
    .player-bar-collapse-btn.player-minimized {
        transform: translateY(230px) !important;
    }

    /* Rotation logic for chevron */
    .player-bar-collapse-btn i {
        /* Default HTML is fa-chevron-down (expand = 0deg) */
        transform: rotate(0deg) !important;
        transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1) !important;
    }

    .player-bar-collapse-btn.player-minimized i {
        /* When minimized, rotate to point UP and add a subtle bounce */
        transform: rotate(180deg) !important;
        animation: hintBounceUpArrow 2.5s infinite ease-in-out !important;
    }

    @keyframes hintBounceUpArrow {

        0%,
        100% {
            transform: rotate(180deg) translateY(0);
            opacity: 0.5;
        }

        50% {
            /* Since it's rotated 180deg, positive translateY pushes it visually UP on the screen */
            transform: rotate(180deg) translateY(4px);
            opacity: 1;
        }
    }

    .player-bar {
        position: fixed !important;
        bottom: 0 !important;
        left: 0 !important;
        right: 0 !important;
        width: 100% !important;
        height: 235px !important;
        transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1) !important;
        overflow: visible !important;
        background: rgba(8, 8, 16, 0.98) !important;
        backdrop-filter: blur(30px) !important;
        border-top: 1px solid rgba(255, 255, 255, 0.08) !important;
        box-shadow: 0 -10px 40px rgba(0, 0, 0, 0.5) !important;
        pointer-events: none !important;
        z-index: 99999 !important;
    }

    .player-bar.player-minimized {
        transform: translateY(100%) !important;
    }

    /* Peeking Toggle Button - NUCLEAR INTERACTIVITY */
    .player-toggle-btn {
        display: flex !important;
        position: fixed !important;
        bottom: 0 !important;
        left: 50% !important;
        transform: translateX(-50%) !important;
        width: 120px !important;
        height: 48px !important;
        z-index: 2147483647 !important;
        align-items: center !important;
        justify-content: center !important;
        background: rgba(8, 8, 16, 0.98) !important;
        border: 1px solid rgba(255, 255, 255, 0.15) !important;
        border-bottom: none !important;
        border-radius: 16px 16px 0 0 !important;
        cursor: pointer !important;
        box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.6) !important;
        pointer-events: auto !important;
        transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1) !important;
    }

    /* When bar is NOT minimized, slide toggle up with it */
    .player-bar:not(.player-minimized)~.player-toggle-btn {
        transform: translateX(-50%) translateY(-235px) !important;
    }

    .player-toggle-pill {
        width: 50px !important;
        height: 4px !important;
        border-radius: 99px !important;
        background: rgba(255, 255, 255, 0.4) !important;
        pointer-events: none !important;
    }

    /* Layout Base: Premium Stack */
    .pv-bar-content,
    .player-content {
        display: flex !important;
        flex-direction: column !important;
        /* FORCE COLUMN STACK < 769px */
        height: 235px !important;
        padding: 40px 15px 15px 15px !important;
        gap: 12px !important;
        align-items: center !important;
        position: relative !important;
        z-index: 100 !important;
        width: 100% !important;
        max-width: 100vw !important;
        overflow-x: hidden !important;
        pointer-events: auto !important;
    }

    /* SECTION 1: TRACK INFO */
    .pv-bar-track,
    .player-track-info {
        display: flex !important;
        flex-direction: row !important;
        align-items: center !important;
        justify-content: center !important;
        gap: 12px !important;
        width: 100% !important;
        margin: 0 !important;
    }

    .pv-bar-art-wrap {
        width: 50px !important;
        height: 50px !important;
        flex-shrink: 0 !important;
        border-radius: 10px !important;
        border: 1px solid rgba(255, 255, 255, 0.1) !important;
    }

    .pv-bar-info {
        display: flex !important;
        flex-direction: column !important;
        align-items: flex-start !important;
    }

    .pv-bar-title {
        font-size: 13px !important;
        font-weight: 700 !important;
    }

    .pv-bar-artist {
        font-size: 11px !important;
        color: rgba(255, 255, 255, 0.5) !important;
    }

    /* SECTION 2: CONTROLS */
    .pv-bar-controls,
    .player-controls {
        display: flex !important;
        flex-direction: column !important;
        align-items: center !important;
        gap: 12px !important;
        width: 100% !important;
    }

    .pv-bar-btns,
    .control-buttons {
        display: flex !important;
        justify-content: center !important;
        gap: 12px !important;
    }

    .pv-ctrl {
        width: 34px !important;
        height: 34px !important;
        font-size: 14px !important;
    }

    .pv-ctrl-play {
        width: 48px !important;
        height: 48px !important;
        font-size: 18px !important;
    }

    .pv-bar-progress,
    .progress-section {
        display: flex !important;
        align-items: center !important;
        gap: 10px !important;
        width: 100% !important;
        max-width: 400px !important;
    }

    /* SECTION 3: ACTIONS (NUCLEAR CENTERING) */
    .pv-bar-right,
    .player-right-wrapper,
    .player-right {
        display: flex !important;
        flex-direction: column !important;
        align-items: center !important;
        justify-content: center !important;
        width: 100% !important;
        margin: 0 !important;
        padding: 0 !important;
        position: static !important;
    }

    .player-actions {
        display: flex !important;
        flex-direction: row !important;
        justify-content: center !important;
        align-items: center !important;
        gap: 30px !important;
        width: 100% !important;
        margin-top: 10px !important;
        border-top: 1px solid rgba(255, 255, 255, 0.05) !important;
        padding-top: 15px !important;
    }

    #fx-btn,
    #leave-btn {
        display: flex !important;
        width: 44px !important;
        height: 44px !important;
        border-radius: 12px !important;
        background: rgba(255, 255, 255, 0.06) !important;
        align-items: center !important;
        justify-content: center !important;
        margin: 0 !important;
        position: relative !important;
        left: auto !important;
        right: auto !important;
        top: auto !important;
    }

    #fx-btn {
        color: #3498db !important;
    }

    #leave-btn {
        color: #e74c3c !important;
    }

    .pv-bar-vol,
    .volume-control {
        display: none !important;
    }

    /* ── ULTRA COMPACT (< 400px) ── */
    @media (max-width: 400px) {

        .pv-bar-content,
        .player-content {
            padding: 35px 10px 10px 10px !important;
            gap: 8px !important;
        }

        .pv-bar-art-wrap {
            width: 42px !important;
            height: 42px !important;
        }

        .pv-ctrl {
            width: 30px !important;
            height: 30px !important;
        }

        .pv-ctrl-play {
            width: 40px !important;
            height: 40px !important;
        }

        .player-actions {
            gap: 20px !important;
        }

        #fx-btn,
        #leave-btn {
            width: 38px !important;
            height: 38px !important;
        }
    }
}

/* ── ATOMIC OVERFLOW GATE ── */
body.player-mode,
body.player-mode #dashboard,
body.player-mode .pv-shell {
    overflow-x: hidden !important;
    width: 100% !important;
    max-width: 100vw !important;
    position: relative;
}

/* Hide swipe indicators on screens > 900px */
@media (min-width: 901px) {

    .pv-swipe-indicator.left,
    .pv-swipe-indicator.right {
        display: none !important;
    }
}