/* =================================================================
   4. 侧边栏样式
   ================================================================= */
.sidebar {
    width: 240px;
    height: 100%;
    background: rgba(10, 10, 10, 0.3);
    border-right: 1px solid rgba(255, 255, 255, 0.05);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    position: relative;
    z-index: 2;
    transition: background 0.3s ease;
}

.logo {
    flex-shrink: 0;
    padding: 35px 25px;
    font-size: 26px;
    font-weight: 800;
    color: #31c27c;
    display: flex;
    align-items: center;
    gap: 12px;
    letter-spacing: -0.5px;
}

.logo span {
    background: linear-gradient(135deg, #31c27c, #85e4b6);
    -webkit-background-clip: text;
    color: transparent;
    text-shadow: 0 0 30px rgba(49, 194, 124, 0.3);
}

#mobile-user-mount {
    display: none;
}

.nav-group {
    flex-shrink: 0;
    margin-bottom: 25px;
}

#my-playlist-nav {
    flex: 1 !important;
    display: flex !important;
    flex-direction: column !important;
    margin-bottom: 0 !important;
    min-height: 0 !important;
    overflow: hidden !important;
}

.nav-title {
    padding: 10px 25px;
    font-size: 11px;
    color: #555;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    font-weight: 700;
    flex-shrink: 0;
}

.nav-item {
    padding: 12px 20px;
    margin: 4px 15px;
    color: #999;
    cursor: pointer;
    transition: all 0.25s ease;
    display: flex;
    align-items: center;
    gap: 14px;
    border-radius: 12px;
    border-left: none;
    font-weight: 500;
    flex-shrink: 0;
}

.nav-item:hover {
    background: rgba(255, 255, 255, 0.05);
    color: #fff;
    transform: translateX(4px);
}

.nav-item.active {
    background: linear-gradient(135deg, #31c27c, #25a062);
    color: #fff;
    box-shadow: 0 4px 15px rgba(49, 194, 124, 0.3);
    font-weight: 600;
}

.nav-item:active {
    transform: scale(0.95) !important;
}

#playlist-actions {
    flex-shrink: 0;
    margin-top: 12px;
    padding: 0 15px;
    display: none;
    gap: 10px;
    justify-content: center;
}

#playlist-actions.show {
    display: flex;
}

.icon-btn-sidebar {
    background: linear-gradient(145deg, #222, #1a1a1a);
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.05);
    color: #31c27c;
    width: 38px;
    height: 38px;
    border-radius: 10px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
}

.icon-btn-sidebar:hover {
    background: #31c27c;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(49, 194, 124, 0.4);
    border-color: #31c27c;
}

.sidebar-footer {
    display: block;
    padding: 15px 0;
    text-align: center;
    font-size: 12px;
    margin-top: auto;
    color: #666;
}

.sidebar-footer a {
    color: #666;
    text-decoration: none;
    transition: color 0.3s;
}

.sidebar-footer a:hover {
    color: #31c27c;
}

.footer-info {
    display: none;
}

/* =================================================================
   5. 侧边栏歌单容器
   ================================================================= */
.playlist-container {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 0;
    overflow: hidden;
    margin-top: 10px;
    padding-bottom: 5px;
}

#my-playlist-songs {
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
    display: flex;
    flex-direction: column;
    padding: 5px 15px 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    min-height: 0;
    scroll-behavior: smooth;
    scrollbar-width: thin;
    scrollbar-color: transparent transparent;
    transition: scrollbar-color 0.3s;
}

#my-playlist-songs:hover {
    scrollbar-color: #444 transparent;
}

#my-playlist-songs::-webkit-scrollbar {
    width: 4px;
}

#my-playlist-songs::-webkit-scrollbar-thumb {
    background: transparent;
    border-radius: 2px;
}

#my-playlist-songs:hover::-webkit-scrollbar-thumb {
    background: #444;
}

#my-playlist-songs::-webkit-scrollbar-track {
    background: transparent;
}

.playlist-song-item {
    display: flex;
    align-items: center;
    padding: 10px 12px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
    margin-bottom: 4px;
    border: 1px solid transparent;
    flex-shrink: 0;
}

.playlist-song-item:hover {
    background: rgba(255, 255, 255, 0.05);
}

.playlist-song-item.playing {
    background: rgba(49, 194, 124, 0.1);
    border: 1px solid rgba(49, 194, 124, 0.2);
}

.playlist-song-item.playing .song-name {
    color: #31c27c;
}

.song-info {
    flex: 1;
    overflow: hidden;
    margin-left: 8px;
    min-width: 0;
}

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

.song-artist {
    font-size: 12px;
    color: #777;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.playlist-song-remove {
    margin-left: auto;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    border: 1px solid #444;
    background: transparent;
    color: #888;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    cursor: pointer;
    transition: 0.2s;
    flex-shrink: 0;
}

.playlist-song-remove:hover {
    border-color: #ff4d4f;
    color: #ff4d4f;
    background: rgba(255, 77, 79, 0.1);
}