@import url('https://fonts.googleapis.com/css2?family=Roboto:wght@400;500;700&display=swap');

:root {
    --bg-base: #121212;
    --bg-elevated: #1a1a1a;
    --bg-surface: #181818;
    --bg-surface-hover: #282828;
    --bg-highlight: #333333;
    --accent: #D4A843;
    --accent-hover: #e0b954;
    --brand-gold: #D9A13E;
    --border-subtle: #333;
    --text-primary: #ffffff;
    --text-secondary: #b3b3b3;
    --text-muted: #6a6a6a;
    --border-color: #333;
    --playbar-h: 90px;
    --sidebar-w: 280px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: var(--bg-base);
    color: var(--text-primary);
    font-family: 'Roboto', sans-serif;
    overflow: hidden;
    height: 100vh;
}

::-webkit-scrollbar { width: 10px; }
::-webkit-scrollbar-thumb { background-color: #444; border-radius: 5px; }
::-webkit-scrollbar-track { background: var(--bg-base); }

/* ===== LAYOUT ===== */
.container {
    display: flex;
    height: calc(100vh - var(--playbar-h));
}

/* ===== LEFT SIDEBAR ===== */
.left {
    width: var(--sidebar-w);
    flex-shrink: 0;
    background: var(--bg-base);
    display: flex;
    flex-direction: column;
    padding: 8px;
    overflow: hidden;
}

.close {
    display: none;
    cursor: pointer;
    padding: 10px;
    text-align: right;
}

.home {
    background: var(--bg-surface);
}

.logo {
    padding: 12px 10px 8px;
}

.logo svg {
    display: block;
}

.home ul {
    list-style: none;
    padding: 4px 10px;
}

.home ul li {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 10px 8px;
    font-weight: 500;
    font-size: 15px;
    color: var(--text-secondary);
    cursor: pointer;
    border-radius: 4px;
    transition: color 0.2s;
}

.home ul li:hover {
    color: var(--text-primary);
}

.home ul li svg {
    flex-shrink: 0;
}

.left > ul {
    list-style: none;
    padding: 4px 10px;
    background: var(--bg-surface);
    border-radius: 6px;
    margin-bottom: 8px;
}

.left > ul li {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 10px 8px;
    font-weight: 500;
    font-size: 15px;
    color: var(--text-secondary);
    cursor: pointer;
    border-radius: 4px;
    transition: color 0.2s, background 0.2s;
}

.left > ul li:hover {
    color: var(--text-primary);
    background: var(--bg-surface-hover);
}

.left > ul li.active {
    color: var(--accent);
}

.left > ul li svg {
    flex-shrink: 0;
}

.library {
    background: var(--bg-surface);
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    margin-top: 8px;
}

.heading {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px 14px 10px;
    font-weight: 700;
    font-size: 14px;
    color: var(--text-secondary);
}

.heading img, .heading svg {
    width: 24px;
    height: 24px;
    flex-shrink: 0;
}

.sidebar-search {
    padding: 0 14px 10px;
}

.sidebar-search input {
    width: 100%;
    background: var(--bg-highlight);
    border: 1px solid transparent;
    border-radius: 20px;
    padding: 8px 16px;
    color: var(--text-primary);
    font-size: 13px;
    outline: none;
    transition: border-color 0.2s;
}

.sidebar-search input:focus {
    border-color: var(--accent);
}

.sidebar-search input::placeholder {
    color: var(--text-muted);
}

.songList {
    flex: 1;
    overflow-y: auto;
    padding-bottom: 60px;
}

.songList ul {
    list-style: none;
    padding: 0 8px;
}

.songList ul li {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 10px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 13px;
    color: var(--text-secondary);
    transition: background 0.2s, color 0.2s;
}

.songList ul li:hover {
    background: var(--bg-surface-hover);
    color: var(--text-primary);
}

.songList ul li.active {
    color: var(--accent);
}

.songList ul li .lib-cover {
    width: 40px;
    height: 40px;
    border-radius: 4px;
    background: var(--bg-highlight);
    overflow: hidden;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.songList ul li .lib-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.songList ul li .lib-cover svg {
    width: 20px;
    height: 20px;
    opacity: 0.5;
}

.songList ul li .lib-info {
    flex: 1;
    min-width: 0;
}

.songList ul li .lib-info .lib-name {
    font-weight: 500;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    color: var(--text-primary);
}

.songList ul li .lib-info .lib-meta {
    font-size: 11px;
    color: var(--text-muted);
    margin-top: 2px;
}

.songList ul li .lib-info .lib-name.active {
    color: var(--accent);
}

.create-playlist {
    padding: 8px 14px;
}

#btnNewPlaylist {
    display: flex;
    align-items: center;
    gap: 10px;
    background: transparent;
    border: none;
    color: var(--text-secondary);
    font-size: 14px;
    cursor: pointer;
    padding: 8px;
    border-radius: 4px;
    width: 100%;
    transition: color 0.2s;
}

#btnNewPlaylist:hover {
    color: var(--text-primary);
}

.footer {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    padding: 12px 14px;
    font-size: 11px;
}

.footer a {
    color: var(--text-muted);
    text-decoration: none;
}

.footer a:hover {
    text-decoration: underline;
}

/* ===== RIGHT MAIN CONTENT ===== */
.right {
    flex: 1;
    background: var(--bg-base);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    border-radius: 0;
}

.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(18,18,18,0.8);
    padding: 12px 16px;
    position: sticky;
    top: 0;
    z-index: 10;
    backdrop-filter: blur(10px);
}

.nav {
    display: flex;
    align-items: center;
}

.hamburgerContainer {
    display: flex;
    align-items: center;
    gap: 8px;
}

.hamburger {
    cursor: pointer;
    padding: 4px;
    display: none;
}

.nav svg {
    cursor: pointer;
    opacity: 0.7;
    transition: opacity 0.2s;
}

.nav svg:hover {
    opacity: 1;
}

.user-area {
    display: flex;
    align-items: center;
    gap: 12px;
}

.user-name {
    font-size: 14px;
    font-weight: 500;
    color: var(--text-secondary);
}

/* ===== SCROLLABLE CONTENT ===== */
.content-area {
    flex: 1;
    overflow-y: auto;
    padding-bottom: 20px;
}

.view-header {
    padding: 24px 32px 16px;
}

.view-header h1 {
    font-size: 28px;
    font-weight: 700;
}

.playlist-header {
    display: flex;
    align-items: flex-end;
    gap: 24px;
    padding: 24px 32px;
    background: linear-gradient(var(--bg-surface) 0%, transparent 100%);
}

.playlist-cover-large {
    width: 192px;
    height: 192px;
    background: var(--bg-highlight);
    border-radius: 4px;
    flex-shrink: 0;
    box-shadow: 0 4px 60px rgba(0,0,0,0.5);
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.playlist-cover-large img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.playlist-info {
    flex: 1;
    min-width: 0;
}

.playlist-type {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    color: var(--text-primary);
}

.playlist-info h1 {
    font-size: 48px;
    font-weight: 900;
    margin: 8px 0;
    word-break: break-word;
}

.playlist-info p {
    color: var(--text-secondary);
    font-size: 14px;
}

.playlist-info #playlistTrackCount {
    color: var(--text-muted);
    font-size: 13px;
}

.playlist-actions-bar {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 16px 32px;
}

.play-all-btn {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: var(--accent);
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.2s, background 0.2s;
}

.play-all-btn:hover {
    transform: scale(1.06);
    background: var(--accent-hover);
}

.shuffle-btn {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: transparent;
    border: 2px solid var(--text-secondary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-secondary);
    transition: border-color 0.2s, color 0.2s;
}

.shuffle-btn:hover {
    border-color: var(--text-primary);
    color: var(--text-primary);
}

/* ===== QUICK CARDS ===== */
.cardContainer {
    padding: 16px 32px;
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
}

.quick-card {
    display: flex;
    align-items: center;
    gap: 0;
    background: var(--bg-surface-hover);
    border-radius: 6px;
    cursor: pointer;
    transition: background 0.3s;
    overflow: hidden;
    flex: 1;
    min-width: 160px;
    max-width: 280px;
}

.quick-card:hover {
    background: var(--bg-highlight);
}

.quick-card .qc-icon {
    width: 64px;
    height: 64px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.qc-gold    { background: linear-gradient(135deg, #D9A13E 0%, #c4952e 100%); }
.qc-fluo {
    background: linear-gradient(90deg, #D9A13E, #ff6b9d, #00f5d4, #00bbf9, #9b5de5, #D9A13E);
    background-size: 400% 100%;
    animation: fluoShift 6s ease infinite;
}
@keyframes fluoShift {
    0%   { background-position: 0% 50%; }
    50%  { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}
@keyframes pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.5; transform: scale(1.3); }
}
.qc-fluo-gold {
    background: linear-gradient(90deg, #D9A13E, #ffbe0b, #fb5607, #ff006e, #8338ec, #D9A13E);
    background-size: 400% 100%;
    animation: fluoShift 7s ease infinite;
}
.qc-fluo-slow {
    background: linear-gradient(90deg, #D9A13E, #ff6b9d, #00f5d4, #00bbf9, #9b5de5, #D9A13E);
    background-size: 400% 100%;
    animation: fluoShift 12s ease infinite;
}
.qc-fluo-blue {
    background: linear-gradient(90deg, #0ea5e9, #06b6d4, #10b981, #3b82f6, #8b5cf6, #0ea5e9);
    background-size: 400% 100%;
    animation: fluoShift 8s ease infinite;
}
.qc-blue svg path, .qc-blue svg circle { stroke: #D9A13E !important; }
.qc-fluo svg path, .qc-fluo svg circle,
.qc-fluo-slow svg path, .qc-fluo-slow svg circle,
.qc-fluo-blue svg path, .qc-fluo-blue svg circle,
.qc-fluo-gold svg path, .qc-fluo-gold svg circle { stroke: #fff !important; filter: drop-shadow(0 0 3px rgba(255,255,255,0.6)); }

.quick-card span {
    padding: 0 16px;
    font-weight: 700;
    font-size: 14px;
}

/* ===== RESULTS ===== */
.spotifyPlaylists {
    padding: 0 32px;
}

.spotifyPlaylists > h1 {
    padding: 16px 0;
    font-size: 20px;
    font-weight: 700;
}

.results-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 20px;
    margin-bottom: 32px;
}

/* Track Card (grid item) */
.track-card {
    background: var(--bg-surface);
    border-radius: 8px;
    padding: 16px;
    cursor: pointer;
    transition: background 0.3s;
    position: relative;
}

.track-card:hover {
    background: var(--bg-surface-hover);
}

.track-card .tc-cover-wrap {
    position: relative;
    width: 100%;
    aspect-ratio: 1;
    border-radius: 6px;
    overflow: hidden;
    background: var(--bg-highlight);
    margin-bottom: 12px;
}

.track-card .tc-cover-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.track-card .tc-play-btn {
    position: absolute;
    bottom: 8px;
    right: 8px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--accent);
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transform: translateY(8px);
    transition: opacity 0.3s, transform 0.3s, background 0.2s;
    box-shadow: 0 8px 16px rgba(0,0,0,0.3);
}

.track-card:hover .tc-play-btn {
    opacity: 1;
    transform: translateY(0);
}

.track-card .tc-play-btn:hover {
    background: var(--accent-hover);
    transform: scale(1.08) translateY(0);
}

.tc-overlay-actions {
    position: absolute;
    top: 8px;
    right: 8px;
    display: flex;
    flex-direction: column;
    gap: 6px;
    opacity: 0;
    transform: translateY(-4px);
    transition: opacity 0.2s, transform 0.2s;
}

.track-card:hover .tc-overlay-actions {
    opacity: 1;
    transform: translateY(0);
}

.tc-btn-action {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: rgba(0,0,0,0.5);
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    transition: background 0.2s, color 0.2s, transform 0.2s;
}

.tc-btn-action:hover {
    background: rgba(0,0,0,0.8);
    transform: scale(1.1);
}

.tc-like.liked {
    color: #e22134;
}

.tc-like.liked svg path {
    fill: #e22134;
}

.tc-add:hover {
    background: var(--accent);
}

.tc-add.added {
    background: rgba(217, 161, 62, 0.2);
}

.tc-add.added:hover {
    background: var(--accent);
}

.track-card .tc-title {
    font-size: 14px;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-bottom: 4px;
}

.track-card .tc-artist {
    font-size: 12px;
    color: var(--text-secondary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.track-card .tc-source {
    font-size: 10px;
    color: var(--text-muted);
    margin-top: 4px;
}

/* ===== TRACK LIST (detailed view) ===== */
.track-list-container {
    margin-top: 8px;
}

.track-list-header {
    display: grid;
    grid-template-columns: 40px 6fr 4fr 120px 80px;
    padding: 8px 16px;
    border-bottom: 1px solid var(--bg-highlight);
    font-size: 12px;
    font-weight: 500;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 8px;
}

.track-list-header .tlh-num { text-align: center; }
.track-list-header .tlh-dur { text-align: right; padding-right: 16px; }

.track-row {
    display: grid;
    grid-template-columns: 40px 6fr 4fr 120px 80px;
    align-items: center;
    padding: 8px 16px;
    border-radius: 4px;
    cursor: pointer;
    transition: background 0.2s;
    position: relative;
}

.track-row:hover {
    background: var(--bg-surface-hover);
}

.track-row.playing {
    background: var(--bg-surface-hover);
}

.track-row .tr-num {
    text-align: center;
    font-size: 14px;
    color: var(--text-secondary);
}

.track-row.playing .tr-num {
    color: var(--accent);
}

.track-row .tr-play-icon {
    display: none;
    color: var(--accent);
}

.track-row.playing .tr-play-icon {
    display: block;
}

.track-row.playing .tr-num-text {
    display: none;
}

.track-row .tr-cover-wrap {
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 0;
}

.track-row .tr-cover {
    width: 40px;
    height: 40px;
    border-radius: 4px;
    background: var(--bg-highlight);
    flex-shrink: 0;
    object-fit: cover;
}

.track-row .tr-title-wrap {
    min-width: 0;
}

.track-row .tr-title {
    font-size: 14px;
    font-weight: 500;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.track-row.playing .tr-title {
    color: var(--accent);
}

.track-row .tr-artist {
    font-size: 12px;
    color: var(--text-secondary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.track-row .tr-album {
    font-size: 13px;
    color: var(--text-secondary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    padding-right: 8px;
}

.track-row .tr-date {
    font-size: 13px;
    color: var(--text-muted);
}

.track-row .tr-dur {
    font-size: 13px;
    color: var(--text-secondary);
    text-align: right;
    padding-right: 16px;
}

.track-row .tr-actions {
    position: absolute;
    right: 16px;
    display: none;
    gap: 8px;
}

.track-row:hover .tr-actions {
    display: flex;
    align-items: center;
}

.track-row .tr-actions button {
    background: transparent;
    border: none;
    cursor: pointer;
    color: var(--text-secondary);
    padding: 4px;
    transition: color 0.2s;
}

.track-row .tr-actions button:hover {
    color: var(--text-primary);
}

.track-row .tr-actions .tr-like.liked {
    color: #e22134;
}

.track-row .tr-actions .tr-like.liked svg path {
    fill: #e22134;
    stroke: #e22134;
}

/* ===== PLAYBAR ===== */
.playbar {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: var(--playbar-h);
    background: var(--bg-surface);
    border-top: 1px solid var(--bg-highlight);
    padding: 12px 16px;
    display: flex;
    flex-direction: column;
    z-index: 100;
}

.seekbar {
    height: 4px;
    width: 100%;
    background: var(--bg-highlight);
    border-radius: 2px;
    cursor: pointer;
    position: relative;
    margin-bottom: 8px;
}

.seekbar:hover {
    height: 6px;
}

.seekbar:hover .circle {
    opacity: 1;
}

.circle {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--accent);
    position: absolute;
    top: 50%;
    left: 0%;
    transform: translateY(-50%);
    opacity: 0;
    transition: opacity 0.2s;
}

.seekbar-fill {
    height: 100%;
    background: var(--accent);
    border-radius: 2px;
    width: 0%;
    pointer-events: none;
}

.abovebar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex: 1;
}

/* Song info (left) */
.songinfo {
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 180px;
    max-width: 260px;
}

.song-cover-mini {
    width: 48px;
    height: 48px;
    border-radius: 4px;
    background: var(--bg-highlight);
    flex-shrink: 0;
    object-fit: cover;
}

.song-cover-mini img {
    width: 100%;
    height: 100%;
    border-radius: 4px;
    object-fit: cover;
}

.song-text-mini {
    min-width: 0;
}

.song-name-mini {
    font-size: 13px;
    font-weight: 500;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.song-artist-mini {
    font-size: 11px;
    color: var(--text-secondary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Controls (center) */
.songbuttons {
    display: flex;
    align-items: center;
    gap: 16px;
}

.ctrl-btn {
    color: var(--text-secondary);
    cursor: pointer;
    transition: color 0.2s, transform 0.2s;
}

.ctrl-btn:hover {
    color: var(--text-primary);
}

.ctrl-btn.active {
    color: var(--accent);
}

.play-btn-wrap {
    display: flex;
    align-items: center;
    justify-content: center;
}

.play-main {
    width: 32px;
    height: 32px;
    color: var(--text-primary);
}

.play-main:hover {
    transform: scale(1.1);
    color: var(--text-primary);
}

/* Time + Volume (right) */
.timevol {
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 180px;
    justify-content: flex-end;
}

.songtime {
    font-size: 12px;
    color: var(--text-secondary);
    white-space: nowrap;
    min-width: 90px;
    text-align: right;
}

.volume {
    display: flex;
    align-items: center;
    gap: 6px;
}

.vol-icon {
    color: var(--text-secondary);
    cursor: pointer;
}

.range input[type="range"] {
    -webkit-appearance: none;
    appearance: none;
    width: 90px;
    height: 4px;
    background: var(--bg-highlight);
    border-radius: 2px;
    outline: none;
    cursor: pointer;
}

.range input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--text-secondary);
    cursor: pointer;
    transition: background 0.2s;
}

/* ===== FULL-SCREEN PLAYER (desktop video) ===== */
#fullscreenPlayer {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 300;
    background: #121212;
}

#fullscreenPlayer.open {
    display: flex;
    align-items: center;
    justify-content: center;
}

.fsp-inner {
    width: 100%;
    max-width: 900px;
    padding: 24px;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.fsp-header {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
}

.fsp-collapse {
    background: rgba(255,255,255,0.1);
    border: none;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.fsp-label {
    font-size: 11px;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.fsp-body {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
}

.fsp-video-wrap {
    width: 100%;
    max-width: 800px;
}

.fsp-video-container {
    width: 100%;
    aspect-ratio: 16/9;
    background: #000;
    border-radius: 8px;
    overflow: hidden;
}

.fsp-video-container iframe {
    width: 100%;
    height: 100%;
    border: none;
}

.fsp-info {
    display: flex;
    align-items: center;
    gap: 14px;
}

.fsp-cover-mini {
    width: 48px;
    height: 48px;
    border-radius: 4px;
    background: var(--bg-highlight);
    object-fit: cover;
    flex-shrink: 0;
}

.fsp-cover-mini img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 4px;
}

.fsp-text { flex: 1; }

.fsp-title {
    font-size: 20px;
    font-weight: 700;
    color: var(--text-primary);
}

.fsp-artist {
    font-size: 14px;
    color: var(--text-secondary);
}

.fsp-controls {
    display: flex;
    align-items: center;
    gap: 16px;
}

.fsp-ctrl {
    width: 40px;
    height: 40px;
    color: var(--text-secondary);
    cursor: pointer;
    transition: color 0.2s;
}

.fsp-ctrl:hover { color: var(--text-primary); }

.fsp-play {
    width: 56px;
    height: 56px;
    background: var(--accent);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: transform 0.15s, background 0.2s;
}

.fsp-play:hover { transform: scale(1.05); }
.fsp-play:active { transform: scale(0.95); }

.range input[type="range"]:hover::-webkit-slider-thumb {
    background: var(--text-primary);
}

/* ===== RESPONSIVE ===== */
@media (max-width: 1200px) {
    .left {
        position: fixed;
        left: -100%;
        top: 0;
        height: 100vh;
        z-index: 200;
        transition: left 0.3s;
        width: 320px;
    }

    .left.open {
        left: 0;
    }

    .close {
        display: block;
    }

    .hamburger {
        display: block;
    }

    .view-header, .cardContainer, .spotifyPlaylists {
        padding-left: 20px;
        padding-right: 20px;
    }

    .cardContainer {
        overflow-x: auto;
        flex-wrap: nowrap;
        -webkit-overflow-scrolling: touch;
    }

    .quick-card {
        min-width: 140px;
    }

    .results-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    }

    .track-list-header,
    .track-row {
        grid-template-columns: 40px 6fr 3fr 60px;
    }

    .track-list-header .tlh-date,
    .track-row .tr-date { display: none; }

    .playbar {
        padding: 8px 12px;
    }

    .abovebar {
        gap: 8px;
    }

    .songinfo {
        min-width: 140px;
        max-width: 180px;
    }

    .timevol {
        min-width: 140px;
    }

    .range input[type="range"] {
        width: 60px;
    }
}

@media (max-width: 600px) {
    .view-header h1 {
        font-size: 22px;
    }

    .playlist-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 16px;
    }

    .playlist-info h1 {
        font-size: 28px;
    }

    .playlist-cover-large {
        width: 140px;
        height: 140px;
    }

    .results-grid {
        grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
        gap: 12px;
    }

    .songbuttons .ctrl-btn:not(.play-main) {
        display: none;
    }

    .songinfo {
        max-width: 140px;
    }

    .song-cover-mini {
        width: 40px;
        height: 40px;
    }

    .timevol {
        min-width: 100px;
    }

    .songtime {
        display: none;
    }

    .track-list-header,
    .track-row {
        grid-template-columns: 40px 1fr 50px;
    }

    .track-list-header .tlh-album,
    .track-row .tr-album { display: none; }
}

/* ===== UTILITY CLASSES ===== */
.flex { display: flex; }
.bg-dark { background: var(--bg-surface); }
.bg-surface { background: var(--bg-elevated); }
.bg-surface-hover { background: var(--bg-surface-hover); }
.rounded { border-radius: 8px; }
.rounded-right { border-radius: 0; }
.m-1 { margin: 5px; }
.p-1 { padding: 10px; }
.invert { filter: invert(1); }

/* ===== LOADING SPINNER ===== */
.loading {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px;
    color: var(--text-secondary);
}

.loading::after {
    content: '';
    width: 24px;
    height: 24px;
    border: 2px solid var(--bg-highlight);
    border-top-color: var(--accent);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    margin-left: 12px;
}

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

/* ===== NOTIFICATION ===== */
#notification {
    position: fixed;
    bottom: 110px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--bg-surface-hover);
    color: var(--text-primary);
    padding: 10px 20px;
    border-radius: 20px;
    font-size: 13px;
    z-index: 999;
    opacity: 0;
    transition: opacity 0.3s;
    pointer-events: none;
}

#notification.show {
    opacity: 1;
}

/* ===== STREAMING RADIO GENRES (Desktop) ===== */
.streaming-genres {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    padding: 16px 0 8px;
}
.genre-btn {
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    color: var(--text-secondary);
    padding: 10px 18px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s, border-color 0.2s, color 0.2s, transform 0.15s;
    font-family: 'Montserrat', sans-serif;
}
.genre-btn:hover {
    background: rgba(217,161,62,0.15);
    border-color: var(--brand-gold);
    color: var(--brand-gold);
}
.genre-btn:active { transform: scale(0.95); }
.genre-divider { width: 100%; height: 1px; background: var(--border-subtle); margin: 4px 0; }
.genre-btn-ballo {
    background: linear-gradient(135deg, #D9A13E 0%, #ff6b9d 50%, #D9A13E 100%);
    background-size: 200% 200%;
    animation: balloShimmer 3s ease infinite;
    border-color: #ff6b9d;
    color: #fff;
    font-weight: 700;
    font-size: 14px;
}
@keyframes balloShimmer {
    0%   { background-position: 0% 50%; }
    50%  { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}
.loading {
    color: var(--text-secondary);
    font-size: 14px;
    padding: 30px 0;
    text-align: center;
}
.no-results {
    color: var(--text-muted);
    font-size: 14px;
    padding: 30px 0;
    text-align: center;
}

