/* css/playlist_manager.css */
#playlist_manager_wrapper {
    position: fixed;
    inset: 0;
    width: 100%;
    height: 100%;
    z-index: 26;
    display: none;
    align-items: center;
    justify-content: center;
    /* background: rgba(0, 0, 0, 0.15); */
    backdrop-filter: blur(2px) grayscale(40%);
    -webkit-backdrop-filter: blur(2px) grayscale(40%);
}

#playlist_manager {
    width: 400px;
    min-width: 400px;
    max-height: 90%;
    background: white;
    border-radius: 18px;
    padding: 16px;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

#playlist_manager_selector_area {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

#playlist_manager_title {
    font-size: 22px;
    font-weight: 800;
    color: #222;
}

#playlist_manager_selector {
    width: 80%;
    padding: 8px;
    border-radius: 8px;
    border: 1px solid #bdbdbd;
    font-size: 15px;
    font-weight: 600;
}

#playlist_manager_table_wrap {
    max-height: 550px;
    overflow-y: auto;
    border: 1px solid #bdbdbd;
    border-radius: 8px;
}

#playlist_manager_table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
}

#playlist_manager_table thead {
    border-bottom: 1px solid #9f9f9f;
}

#playlist_manager_table th,
#playlist_manager_table td {
    padding: 8px;
    text-align: center;
    border-left: 1px solid #d6d6d6;
    font-size: 15px;
    font-weight: 600;
}

#playlist_manager_table th:first-child,
#playlist_manager_table td:first-child {
    border-left: 0;
}

#playlist_manager_table tbody tr:nth-child(odd) {
    background: #f5f5f5;
}

#playlist_manager_table tbody tr:nth-child(even) {
    background: #e9e9e9;
}

#playlist_manager_table .playlist-manager-name {
    text-align: left;
}

.playlist-manager-handle {
    width: 32px;
    cursor: grab;
    user-select: none;
    touch-action: none;
    font-size: 18px;
}

.playlist-manager-handle:active {
    cursor: grabbing;
}

.playlist-manager-order {
    width: 56px;
}

.playlist-manager-dragging {
    opacity: 0.45;
}

.playlist-manager-drop-before td {
    border-top: 4px solid #1f8f46;
}

.playlist-manager-drop-after td {
    border-bottom: 4px solid #1f8f46;
}

.playlist-manager-touch-ghost {
    position: fixed;
    z-index: 9999;
    max-width: 260px;
    padding: 8px 12px;
    border-radius: 8px;
    background: #1f8f46;
    color: white;
    font-size: 14px;
    font-weight: 700;
    pointer-events: none;
    opacity: 0.95;
    box-shadow: 0 8px 22px rgba(0, 0, 0, 0.22);
}

#playlist_manager_buttons {
    margin-top: auto;
    display: flex;
    justify-content: center;
    gap: 10px;
}

#playlist_manager_buttons button {
    padding: 8px 16px;
    border-radius: 8px;
    border: 0;
    color: white;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
}

#playlist_manager_save {
    background: #1f8f46;
}

#playlist_manager_cancel {
    background: #777;
}
