/* === USER SECTION (Sidebar) === */
.user-section {
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

/* === USER PROFILE & MENU === */
.user-profile-summary {
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
    padding: 0.6rem;
    background: rgba(255, 255, 255, 0.02);
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.05);
    margin-bottom: 0.5rem;
}

.user-identity {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    padding-bottom: 0.6rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.user-avatar {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    object-fit: cover;
    border: 1.5px solid var(--primary-glow);
    padding: 1px;
    background: #0f172a;
    box-shadow: 0 0 15px rgba(14, 165, 233, 0.3);
}

.user-text {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.user-greeting {
    font-size: 0.7rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1.5px;
    font-weight: 600;
}

.user-name-wrapper {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
}

.menu-chevron {
    font-size: 0.8rem;
    color: var(--text-muted);
    transition: transform 0.3s ease;
}

.user-email {
    font-size: 0.75rem;
    color: var(--text-muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 180px;
}

.user-name {
    font-weight: 700;
    font-size: 1.05rem;
    color: white;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.user-menu {
    display: grid;
    grid-template-rows: 0fr;
    transition: grid-template-rows 0.3s ease, opacity 0.3s ease, margin 0.3s ease;
    opacity: 0;
    overflow: hidden;
    gap: 0;
    margin-top: 0;
}

.user-profile-summary.open .user-menu {
    grid-template-rows: 1fr;
    opacity: 1;
    margin-top: 0.6rem;
    gap: 0.5rem;
}

.user-profile-summary.open .menu-chevron {
    transform: rotate(180deg);
}

.user-menu>div {
    min-height: 0;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.user-menu-btn {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.05);
    padding: 0.6rem 0.8rem;
    border-radius: 10px;
    color: var(--text-muted);
    font-size: 0.85rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    text-align: left;
    width: 100%;
}

.user-menu-btn .btn-icon {
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
    color: var(--text-muted);
    background: rgba(255, 255, 255, 0.02);
    border-radius: 8px;
    transition: all 0.2s;
}

.user-menu-btn:hover {
    background: rgba(14, 165, 233, 0.1);
    color: white;
    transform: translateY(-2px);
    border-color: rgba(14, 165, 233, 0.3);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.user-menu-btn:hover .btn-icon {
    color: var(--primary-glow);
    background: rgba(14, 165, 233, 0.1);
    transform: scale(1.1);
}

/* Logout Specific */
.user-menu-btn.danger {
    margin-top: 0.5rem;
    border-color: rgba(239, 68, 68, 0.15);
}

.user-menu-btn.danger:hover {
    background: rgba(239, 68, 68, 0.08);
    color: #f87171;
    border-color: rgba(239, 68, 68, 0.4);
}

.user-menu-btn.danger:hover .btn-icon {
    color: #ef4444;
    background: rgba(239, 68, 68, 0.1);
}

/* === MODAL SYSTEM === */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(10px);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.3s ease;
}

.modal-content {
    width: 90%;
    max-width: 500px;
    background: #0f172a;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-lg);
    padding: 2rem;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
    max-height: 80vh;
    display: flex;
    flex-direction: column;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

/* === SEARCH MODAL (SPECIAL DESIGN) === */
.search-modal-content {
    width: 95%;
    max-width: 900px;
    height: auto;
    min-height: 500px;
    max-height: 85vh;
    background: #0f172a;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 24px;
    padding: 2.5rem;
    display: flex;
    flex-direction: column;
    gap: 2rem;
    box-shadow: 0 50px 100px rgba(0, 0, 0, 0.8);
    position: relative;
    animation: modalScaleIn 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes modalScaleIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

.search-modal-header {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.search-input-wrapper {
    flex: 1;
    position: relative;
    display: flex;
    align-items: center;
}

.search-input-wrapper i {
    position: absolute;
    left: 1.5rem;
    font-size: 1.4rem;
    color: var(--primary-glow);
}

.search-input-wrapper input {
    width: 100%;
    background: rgba(255, 255, 255, 0.03);
    border: 2px solid rgba(14, 165, 233, 0.3);
    border-radius: 100px;
    padding: 1.25rem 2rem 1.25rem 4rem;
    color: white;
    font-size: 1.4rem;
    font-weight: 500;
    transition: all 0.3s ease;
    box-shadow: 0 0 20px rgba(14, 165, 233, 0.1);
}

.search-input-wrapper input:focus {
    background: rgba(255, 255, 255, 0.06);
    border-color: var(--primary-glow);
    box-shadow: 0 0 30px rgba(14, 165, 233, 0.2);
    outline: none;
}

.search-results-container {
    flex: 1;
    overflow-y: auto;
    padding-right: 0.5rem;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.search-results-container .discovery-card {
    display: flex;
    flex-direction: row;
    align-items: center;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 12px;
    padding: 0.6rem 1.2rem;
    gap: 1.5rem;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid rgba(255, 255, 255, 0.05);
    width: 100%;
}

.search-results-container .discovery-card:hover {
    transform: translateX(10px);
    background: rgba(255, 255, 255, 0.06);
    border-color: var(--primary-glow);
}

.search-results-container .card-thumb-wrapper {
    width: 120px;
    min-width: 120px;
    height: 120px;
    border-radius: 8px;
    overflow: hidden;
    position: relative;
}

.search-results-container .card-thumb {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.search-results-container .card-content {
    flex: 1;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0;
    gap: 1rem;
    min-width: 0;
}

.search-results-container .card-title {
    font-size: 1.1rem;
    margin: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    color: white;
}

.search-results-container .card-artist {
    font-size: 0.9rem;
    margin: 0;
    opacity: 0.6;
}

.search-results-container .card-footer {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    margin-top: 0;
    padding-top: 0;
    border-top: none;
    flex-shrink: 0;
}

.search-results-container .card-tag {
    display: block;
    background: rgba(255, 255, 255, 0.05);
    padding: 3px 10px;
    border-radius: 6px;
    font-size: 0.65rem;
    white-space: nowrap;
    text-transform: uppercase;
}

.search-empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 4rem 2rem;
    color: var(--text-muted);
    gap: 1.5rem;
    opacity: 0.4;
}

.search-empty-state i {
    font-size: 4rem;
}

.search-empty-state p {
    font-size: 1rem;
    font-weight: 500;
}

.btn-close-search {
    background: rgba(255, 255, 255, 0.05);
    border: none;
    color: white;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    font-size: 1.2rem;
    cursor: pointer;
    transition: all 0.2s;
    flex-shrink: 0;
}

.btn-close-search:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: rotate(90deg);
}

/* === COMMUNITY PLAYLISTS (TOP 25) === */
.community-container {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    padding: 0.5rem 0;
}

.community-card {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.75rem;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s;
}

.community-card:hover {
    background: rgba(255, 255, 255, 0.06);
    border-color: var(--primary-glow);
    transform: translateX(5px);
}

.rank-number {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--accent-glow);
    min-width: 40px;
    text-align: center;
}

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

.com-name {
    font-weight: 600;
    font-size: 0.95rem;
    color: white;
    margin-bottom: 0.25rem;
}

.com-meta {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.com-actions {
    display: flex;
    gap: 0.5rem;
}

.btn-vote {
    background: rgba(251, 191, 36, 0.1);
    border: 1px solid rgba(251, 191, 36, 0.3);
    color: #facc15;
    padding: 0.4rem 0.8rem;
    border-radius: 8px;
    font-size: 0.85rem;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-vote:hover {
    background: rgba(251, 191, 36, 0.2);
    transform: scale(1.05);
}

.btn-icon-small {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--text-muted);
    padding: 0.4rem 0.6rem;
    border-radius: 8px;
    font-size: 0.85rem;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-icon-small:hover {
    background: rgba(255, 255, 255, 0.1);
    color: white;
}


/* === TAB SYSTEM (SIMPLIFIED) === */
.app-view {
    display: none;
    width: 100%;
    height: 100%;
    overflow-y: auto;
    padding: 2rem;
}

.app-view.active {
    display: flex;
    flex-direction: column;
}

/* Top Hits Section */
.explore-header {
    text-align: center;
    margin-bottom: 3rem;
}

.explore-header h1 {
    font-size: 3rem;
    font-weight: 900;
    letter-spacing: -2px;
    background: linear-gradient(135deg, #fff 0%, var(--primary-glow) 100%);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 0.5rem;
}

.explore-subtitle {
    color: var(--text-muted);
    font-size: 1.2rem;
}

/* Shared Grid Styles */
.discovery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 2rem;
}

.discovery-card {
    background: rgba(255, 255, 255, 0.03);
    border-radius: 20px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.05);
    cursor: pointer;
    transition: all 0.3s ease;
}

.discovery-card:hover {
    transform: translateY(-10px);
    border-color: var(--primary-glow);
    background: rgba(255, 255, 255, 0.08);
}

.card-thumb-wrapper {
    aspect-ratio: 16/9;
    position: relative;
}

.card-thumb {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.card-play-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.4);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: 0.3s;
}

.discovery-card:hover .card-play-overlay {
    opacity: 1;
}

.card-content {
    padding: 1.2rem;
}

.card-title {
    font-weight: 700;
    font-size: 1rem;
    margin-bottom: 0.4rem;
    color: white;
}

.card-artist {
    color: var(--text-muted);
    font-size: 0.9rem;
}

.sidebar-tabs {
    display: flex;
    background: rgba(0, 0, 0, 0.3);
    margin: 0 1rem 1rem 1rem;
    border-radius: 12px;
    padding: 5px;
    gap: 5px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.tab-btn {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    background: transparent;
    border: none;
    color: var(--text-muted);
    padding: 8px 2px;
    border-radius: 8px;
    font-size: 0.75rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s;
    line-height: 1.2;
}

.tab-btn.active {
    color: white;
}

/* === TAB SYSTEM FIX === */
.tab-pane {
    display: none;
}

.tab-pane.active {
    display: block;
}

/* === COMMUNITY SECTION (Top 25) === */
.community-box-full {
    padding: 0.5rem;
}

.community-list {
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
}

.community-card {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.8rem;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.community-card:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: var(--primary-glow);
    transform: translateX(4px);
}

.rank-number {
    font-size: 1.2rem;
    font-weight: 900;
    color: var(--primary-glow);
    width: 24px;
    text-align: center;
    opacity: 0.5;
}

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

.com-name {
    font-weight: 700;
    font-size: 0.95rem;
    color: white;
    margin-bottom: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.com-meta {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.com-actions {
    display: flex;
    gap: 0.5rem;
}

.btn-vote {
    background: rgba(255, 107, 107, 0.1);
    border: 1px solid rgba(255, 107, 107, 0.2);
    color: #ff6b6b;
    padding: 4px 8px;
    border-radius: 8px;
    font-size: 0.8rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    gap: 4px;
}

.btn-vote:hover {
    background: rgba(255, 107, 107, 0.2);
    transform: scale(1.05);
}

.btn-icon-small {
    background: rgba(255, 255, 255, 0.05);
    border: none;
    color: var(--text-muted);
    width: 28px;
    height: 28px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-icon-small:hover {
    background: rgba(255, 255, 255, 0.1);
    color: white;
}

/* === DISCOVERY CARDS ENHANCEMENTS === */
.card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 0.8rem;
    padding-top: 0.8rem;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.card-tag {
    font-size: 0.7rem;
    text-transform: uppercase;
    font-weight: 700;
    color: var(--primary-glow);
    background: rgba(14, 165, 233, 0.1);
    padding: 2px 8px;
    border-radius: 4px;
    letter-spacing: 0.5px;
}

.card-actions {
    display: flex;
    gap: 0.5rem;
}

.card-btn-mini {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: white;
    width: 28px;
    height: 28px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s;
    font-size: 0.8rem;
}

.card-btn-mini:hover {
    background: var(--primary-glow);
    border-color: var(--primary-glow);
    transform: scale(1.1);
    box-shadow: 0 0 10px rgba(14, 165, 233, 0.4);
}

/* === PLAYLIST MODAL STYLES === */
.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.modal-header h3 {
    font-size: 1.25rem;
    font-weight: 700;
    color: white;
    margin: 0;
}

.modal-body {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.playlist-controls {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.input-dark {
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    padding: 0.75rem 1rem;
    color: white;
    font-size: 0.9rem;
    flex: 1;
    min-width: 150px;
    transition: all 0.2s ease;
}

.input-dark:focus {
    outline: none;
    border-color: var(--primary-glow);
    box-shadow: 0 0 0 3px rgba(14, 165, 233, 0.15);
}

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

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-muted);
    font-size: 0.85rem;
    cursor: pointer;
    white-space: nowrap;
}

.checkbox-label input[type="checkbox"] {
    width: 16px;
    height: 16px;
    accent-color: var(--primary-glow);
    cursor: pointer;
}

.btn-primary-sm {
    background: linear-gradient(135deg, var(--primary-glow), #0ea5e9);
    border: none;
    color: white;
    padding: 0.75rem 1.25rem;
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.85rem;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.btn-primary-sm:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(14, 165, 233, 0.4);
}

.btn-primary-sm:active {
    transform: translateY(0);
}

.playlists-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    max-height: 300px;
    overflow-y: auto;
    padding-right: 0.5rem;
}

.playlists-list::-webkit-scrollbar {
    width: 6px;
}

.playlists-list::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 3px;
}

.playlists-list::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.15);
    border-radius: 3px;
}

.playlists-list::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.25);
}

.playlist-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.playlist-item:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: var(--primary-glow);
    transform: translateX(4px);
}

.playlist-info {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    flex: 1;
    min-width: 0;
}

.playlist-name {
    font-weight: 600;
    color: white;
    font-size: 0.95rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.playlist-meta {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.8rem;
    color: var(--text-muted);
}

.playlist-visibility {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.playlist-visibility::before {
    content: '';
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #10b981;
}

.playlist-visibility.private::before {
    background: #f59e0b;
}

.playlist-actions {
    display: flex;
    gap: 0.5rem;
}

.btn-delete-playlist {
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.2);
    color: #f87171;
    width: 32px;
    height: 32px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s;
    font-size: 0.9rem;
}

.btn-delete-playlist:hover {
    background: rgba(239, 68, 68, 0.2);
    border-color: #ef4444;
    transform: scale(1.05);
}

.text-muted {
    color: var(--text-muted);
    font-size: 0.9rem;
    text-align: center;
    padding: 1rem 0;
}

/* === PLAYLIST CREATION FORM === */
.playlist-create-form {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.playlist-create-form .input-dark {
    background: rgba(0, 0, 0, 0.4);
    border: 1.5px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    padding: 0.85rem 1.15rem;
    color: white;
    font-size: 0.95rem;
    font-weight: 500;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.playlist-create-form .input-dark:focus {
    outline: none;
    border-color: var(--primary-glow);
    background: rgba(0, 0, 0, 0.5);
    box-shadow: 0 0 0 4px rgba(14, 165, 233, 0.1),
        0 4px 12px rgba(0, 0, 0, 0.3);
    transform: translateY(-1px);
}

.playlist-create-form .input-dark::placeholder {
    color: rgba(255, 255, 255, 0.3);
    font-weight: 400;
}

.playlist-create-form .checkbox-wrapper {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.5rem 0;
}

.playlist-create-form .checkbox-wrapper input[type="checkbox"] {
    width: 20px;
    height: 20px;
    accent-color: var(--primary-glow);
    cursor: pointer;
    border-radius: 4px;
}

.playlist-create-form .checkbox-wrapper label {
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    user-select: none;
    transition: color 0.2s;
}

.playlist-create-form .checkbox-wrapper:hover label {
    color: white;
}

.playlist-create-form .btn-primary-sm {
    background: linear-gradient(135deg, #0ea5e9 0%, #06b6d4 100%);
    border: none;
    color: white;
    padding: 0.9rem 1.5rem;
    border-radius: 10px;
    font-weight: 700;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 12px rgba(14, 165, 233, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.playlist-create-form .btn-primary-sm:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(14, 165, 233, 0.4);
    background: linear-gradient(135deg, #0284c7 0%, #0891b2 100%);
}

.playlist-create-form .btn-primary-sm:active {
    transform: translateY(0);
    box-shadow: 0 2px 8px rgba(14, 165, 233, 0.3);
}

.playlist-create-form .btn-primary-sm i {
    font-size: 1rem;
}

/* === PLAYLISTS LIST SECTION === */
.playlists-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    max-height: 350px;
    overflow-y: auto;
    padding: 0.25rem;
}

.playlists-list .text-muted {
    padding: 2rem 1rem;
    opacity: 0.5;
}

/* === PLAYLIST ROW (for JS rendering) === */
.playlist-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 1.25rem;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 10px;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: default;
}

.playlist-row.selectable {
    cursor: pointer;
}

.playlist-row:hover {
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(14, 165, 233, 0.3);
    transform: translateX(4px);
}

.playlist-row.selectable:hover {
    border-color: var(--primary-glow);
    box-shadow: 0 2px 8px rgba(14, 165, 233, 0.15);
}

.playlist-row .p-name {
    font-weight: 600;
    font-size: 1rem;
    color: white;
    margin-bottom: 0.25rem;
    display: block;
}

.playlist-row .btn-delete {
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.2);
    color: #f87171;
    width: 34px;
    height: 34px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s;
    font-size: 1rem;
}

.playlist-row .btn-delete:hover {
    background: rgba(239, 68, 68, 0.2);
    border-color: #ef4444;
    transform: scale(1.1);
    box-shadow: 0 2px 8px rgba(239, 68, 68, 0.3);
}


/* Responsive Breakpoints for Search Modal */
@media (max-width: 992px) {
    .search-modal-content {
        padding: 2rem;
        max-width: 900px;
    }

    .search-input-wrapper input {
        font-size: 1.5rem;
    }
}

@media (max-width: 768px) {
    .modal-overlay {
        padding: 0;
    }

    .search-modal-content {
        padding: 1.25rem;
        border-radius: 0;
        width: 100%;
        height: 100vh;
        max-width: none;
        gap: 1.5rem;
        background: #0f172a;
    }

    .search-modal-header {
        gap: 0.75rem;
    }

    .search-input-wrapper i {
        left: 1.25rem;
        font-size: 1.25rem;
    }

    .search-input-wrapper input {
        font-size: 1rem;
        padding: 0.8rem 1rem 0.8rem 3.25rem;
        border-radius: 12px;
    }

    .btn-close-search {
        width: 42px;
        height: 42px;
        min-width: 42px;
        font-size: 1rem;
    }

    .search-modal-body {
        padding-right: 0.25rem;
    }

    #search-results-grid .discovery-card {
        padding: 0.5rem;
        gap: 0.75rem;
        flex-direction: row;
        /* Keep row on mobile for thumb + text */
        align-items: flex-start;
    }

    #search-results-grid .card-thumb-wrapper {
        width: 100px;
        min-width: 100px;
        height: 56px;
    }

    #search-results-grid .card-content {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.25rem;
    }

    #search-results-grid .card-title {
        font-size: 0.9rem;
        max-width: 100%;
    }

    #search-results-grid .card-artist {
        font-size: 0.8rem;
    }

    #search-results-grid .card-footer {
        width: 100%;
        justify-content: space-between;
        margin-top: 0.25rem;
    }

    #search-results-grid .card-tag {
        font-size: 0.6rem;
    }
}

@media (max-width: 480px) {
    #search-results-grid .card-thumb-wrapper {
        width: 80px;
        min-width: 80px;
        height: 45px;
    }

    #search-results-grid .card-title {
        font-size: 0.85rem;
    }
}