* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    color: #333;
}

.music-app {
    max-width: 1200px;
    margin: 0 auto;
    background: rgba(255, 255, 255, 0.95);
    min-height: 100vh;
    box-shadow: 0 0 30px rgba(0, 0, 0, 0.1);
}

/* 头部样式 */
.app-header {
    padding: 20px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.app-header h1 {
    margin-bottom: 15px;
    font-size: 2rem;
    text-align: center;
}

.header-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.search-box input {
    width: 300px;
    padding: 10px 15px;
    border: none;
    border-radius: 25px;
    font-size: 1rem;
    background: rgba(255, 255, 255, 0.9);
}

.playlist-controls {
    display: flex;
    gap: 10px;
}

.btn {
    padding: 8px 16px;
    border: none;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.9);
    color: #667eea;
    cursor: pointer;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.btn:hover {
    background: white;
    transform: translateY(-1px);
}

.btn-sm {
    padding: 6px 12px;
    font-size: 0.8rem;
}

.btn-danger {
    background: #ff4757;
    color: white;
}

.btn-danger:hover {
    background: #ff3838;
}

/* 主内容区域 */
.main-content {
    display: flex;
    min-height: calc(100vh - 320px);
}

.sidebar {
    width: 250px;
    background: #f8f9fa;
    padding: 20px;
    border-right: 1px solid #eee;
}

.playlist-section h3 {
    margin-bottom: 15px;
    color: #333;
}

.playlist-list {
    list-style: none;
}

.playlist-item {
    padding: 10px;
    margin-bottom: 5px;
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.3s ease;
}

.playlist-item:hover,
.playlist-item.active {
    background: #e9ecef;
}

.content-area {
    flex: 1;
    padding: 20px;
    overflow-y: auto;
}

.current-playlist-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

/* 音乐列表样式 */
.music-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 15px;
}

.music-item {
    background: white;
    border-radius: 10px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    transition: all 0.3s ease;
    cursor: pointer;
}

.music-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
}

.music-item.active {
    border: 2px solid #667eea;
}

.music-item-cover {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.music-item-info {
    padding: 15px;
}

.music-item-info h3 {
    margin-bottom: 5px;
    color: #333;
    font-size: 1.1rem;
}

.music-item-info p {
    color: #666;
    font-size: 0.9rem;
    margin-bottom: 10px;
}

.music-item-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.favorite-btn {
    background: none;
    border: none;
    font-size: 1.2rem;
    cursor: pointer;
    transition: color 0.3s ease;
}

.favorite-btn.favorited {
    color: #ff4757;
}

/* 播放控制样式 */
.player-controls {
    background: white;
    padding: 20px;
    border-top: 1px solid #eee;
    display: flex;
    align-items: center;
    gap: 20px;
}

.album-cover img {
    width: 100px;
    height: 100px;
    border-radius: 8px;
    object-fit: cover;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.player-info-controls {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.current-track-info {
    text-align: center;
}

.current-track-info h3 {
    margin-bottom: 5px;
    color: #333;
}

.current-track-info p {
    color: #666;
    font-size: 0.9rem;
}

.progress-container {
    display: flex;
    align-items: center;
    gap: 10px;
}

.time {
    font-size: 0.8rem;
    color: #666;
    min-width: 40px;
}

#progressBar {
    flex: 1;
    height: 6px;
    border-radius: 3px;
    background: #ddd;
    outline: none;
    -webkit-appearance: none;
}

#progressBar::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #667eea;
    cursor: pointer;
}

.control-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.control-buttons {
    display: flex;
    gap: 20px;
}

.control-btn {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    border: none;
    background: #667eea;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.control-btn:hover {
    background: #5568d3;
    transform: scale(1.1);
}

.play-btn {
    width: 60px;
    height: 60px;
    font-size: 1.8rem;
}

.volume-control {
    display: flex;
    align-items: center;
    gap: 10px;
}

#volumeBar {
    width: 100px;
    height: 6px;
    border-radius: 3px;
    background: #ddd;
    outline: none;
    -webkit-appearance: none;
}

#volumeBar::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: #667eea;
    cursor: pointer;
}

/* 模态框样式 */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.4);
}

.modal-content {
    background-color: #fefefe;
    margin: 15% auto;
    padding: 20px;
    border: 1px solid #888;
    width: 90%;
    max-width: 400px;
    border-radius: 10px;
    position: relative;
}

.close {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
}

.close:hover,
.close:focus {
    color: black;
    text-decoration: none;
    cursor: pointer;
}

.modal-content h2 {
    margin-bottom: 20px;
    color: #333;
}

.modal-content input {
    width: 100%;
    padding: 10px;
    margin-bottom: 20px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 1rem;
}

.modal-actions {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
}


/* 批量操作工具栏样式 */
.batch-toolbar {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 8px;
    flex-wrap: wrap;
}

/* 复选框样式 */
.music-item {
    position: relative;
}

.music-item-checkbox {
    position: absolute;
    top: 10px;
    left: 10px;
    width: 20px;
    height: 20px;
    cursor: pointer;
    z-index: 10;
    background: rgba(255, 255, 255, 0.8);
    border: 2px solid #667eea;
    border-radius: 4px;
}

.music-item-checkbox:checked {
    background: #667eea;
}

.music-item-checkbox:checked::after {
    content: '✓';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-weight: bold;
}

/* 批量添加模态框样式 */
.playlist-select {
    width: 100%;
    padding: 10px;
    margin-bottom: 20px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 1rem;
}


/* 表单样式 */
.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
    color: #333;
}

.form-group input {
    width: 100%;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 1rem;
}


/* 调整头部操作按钮布局 */
.add-song-buttons {
    display: flex;
    gap: 10px;
}

/* 批量添加模态框样式 */
#batchAddLocalSongsModal .form-group {
    margin-bottom: 20px;
}

#batchAddLocalSongsModal input[type="file"] {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 8px;
    background: #f8f9fa;
}

#batchAddLocalSongsModal input[type="checkbox"] {
    margin-right: 10px;
}

/* 响应式调整 */
@media (max-width: 768px) {
    .add-song-buttons {
        flex-direction: column;
        gap: 5px;
    }
    .batch-toolbar {
        justify-content: center;
    }
    
    .music-item-checkbox {
        top: 5px;
        left: 5px;
        width: 16px;
        height: 16px;
    }

     .header-actions {
        flex-direction: column;
        gap: 5px;
    }
    
    .form-group input {
        padding: 6px;
    }
}






/* 响应式设计 */
@media (max-width: 768px) {
    .main-content {
        flex-direction: column;
    }
    
    .sidebar {
        width: 100%;
        border-right: none;
        border-bottom: 1px solid #eee;
    }
    
 
    
    .search-box input {
        width: 100%;
        margin-bottom: 10px;
    }
    
    .playlist-controls {
        justify-content: center;
    }
    
    .player-controls {
        flex-direction: column;
        text-align: center;
    }
    
    .control-row {
        flex-direction: column;
        gap: 15px;
    }
    
    .music-container {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    }
}



