@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap');

body {
    font-family: 'Inter', sans-serif;
    margin: 0;
    overflow-x: hidden; /* prevent horizontal scroll during slide */
}

[tabindex]:focus {
    outline: 2px solid #ec4899;
    outline-offset: 2px;
    box-shadow: 0 0 10px rgba(236, 72, 153, 0.5);
}

/* ---------- Fullscreen Player ---------- */
.fullscreen-player {
    position: fixed;
    top: 0; 
    left: 0; 
    width: 100vw; 
    height: 100vh;
    background: #000;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    overflow: hidden;
}

.fullscreen-player #playerContainer {
    width: 100%;
    height: 100%;
}

.fullscreen-player #backToResults,
.fullscreen-player #fullscreenBtn {
    position: fixed;
    top: 16px;
    z-index: 1100;
    padding: 8px 16px;
    border-radius: 10px;
    font-weight: 500;
    cursor: pointer;
    user-select: none;
    transition: background 0.2s;
}

.fullscreen-player #backToResults {
    left: 16px;
    background-color: rgba(55, 65, 81, 0.8);
}

.fullscreen-player #fullscreenBtn {
    right: 16px;
    background-color: rgba(139, 92, 246, 0.8);
}

/* ---------- Smooth Slide Animations ---------- */
@keyframes slideInRight {
    0% { transform: translateX(100vw); opacity: 0; }
    100% { transform: translateX(0); opacity: 1; }
}

@keyframes slideOutRight {
    0% { transform: translateX(0); opacity: 1; }
    100% { transform: translateX(100vw); opacity: 0; }
}

.slide-in-right {
    animation: slideInRight 0.5s cubic-bezier(0.4, 0, 0.2, 1) forwards;
    will-change: transform, opacity;
}

.slide-out-right {
    animation: slideOutRight 0.5s cubic-bezier(0.4, 0, 0.2, 1) forwards;
    will-change: transform, opacity;
}

/* ---------- Hide Scrollbar ---------- */
#queueList, .scrollbar-none {
    overflow-x: auto;
    -ms-overflow-style: none;
    scrollbar-width: none;
}
#queueList::-webkit-scrollbar, .scrollbar-none::-webkit-scrollbar {
    display: none;
}

/* ---------- Add to Queue Button ---------- */
.add-to-queue {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 40px;
    height: 40px;
    background: linear-gradient(to bottom right, #a855f7, #ec4899);
    color: white;
    font-size: 24px;
    font-weight: bold;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.4);
    z-index: 10;
    transition: all 0.2s ease;
    user-select: none;
}

.add-to-queue:hover,
.add-to-queue:active {
    transform: scale(1.1);
    box-shadow: 0 6px 14px rgba(0, 0, 0, 0.5);
}

.add-to-queue.already-in-queue {
    background: #6b7280;
    color: #9ca3af;
}

/* ---------- Mobile Touch Fixes ---------- */
button, [tabindex="0"] {
    cursor: pointer;
    touch-action: manipulation;
}

button {
    -webkit-tap-highlight-color: transparent;
}

/* ---------- Search Suggestions Dropdown ---------- */
#suggestions {
    border: 1px solid rgba(139, 92, 246, 0.3);
}

#suggestions ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

#suggestions li {
    padding: 12px 16px;
    cursor: pointer;
    transition: background 0.2s;
    border-bottom: 1px solid rgba(255,255,255,0.05);
    color: white;
    font-size: 1rem;
}

#suggestions li:hover,
#suggestions li.focused {
    background: rgba(168, 85, 247, 0.4);
}

#suggestions li:last-child {
    border-bottom: none;
}

#suggestions .highlight {
    font-weight: bold;
    color: #ec4899;
}
