/* 文件: style.css */
/* 音乐网站基础样式 */

:root {
    --bg-color: #f8f9fa;
    --text-color: #212529;
    --card-bg: #ffffff;
    --header-bg: #ffffff;
    --border-color: #dee2e6;
    --primary-color: #2c3e50;
    --primary-hover: #1a252f;
    --secondary-color: #6c757d;
    --music-color: #ff6b6b;
    --success-color: #28a745;
    --warning-color: #ffc107;
    --danger-color: #dc3545;
    --info-color: #17a2b8;
    --shadow: 0 2px 15px rgba(0, 0, 0, 0.08);
    --shadow-hover: 0 5px 20px rgba(0, 0, 0, 0.12);
    --input-bg: #ffffff;
    --transition-speed: 0.3s;
}

.dark-mode {
    --bg-color: #1a1a1a;
    --text-color: #e0e0e0;
    --card-bg: #2d2d2d;
    --header-bg: #2d2d2d;
    --border-color: #404040;
    --primary-color: #3498db;
    --primary-hover: #2980b9;
    --secondary-color: #95a5a6;
    --music-color: #ff6b6b;
    --shadow: 0 2px 15px rgba(0, 0, 0, 0.3);
    --shadow-hover: 0 5px 20px rgba(0, 0, 0, 0.4);
    --input-bg: #3a3a3a;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Microsoft YaHei', 'Segoe UI', sans-serif;
}

body {
    background-color: var(--bg-color);
    color: var(--text-color);
    line-height: 1.6;
    padding-top: 70px;
    transition: all var(--transition-speed) ease;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* 播放器样式 */
.music-player {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background: var(--card-bg);
    border-top: 3px solid var(--music-color);
    padding: 15px 30px;
    box-shadow: 0 -5px 20px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    transition: all var(--transition-speed) ease;
}

.player-content {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    gap: 30px;
}

.player-info {
    display: flex;
    align-items: center;
    gap: 15px;
    flex: 1;
    min-width: 0;
}

.player-cover {
    width: 50px;
    height: 50px;
    border-radius: 8px;
    overflow: hidden;
    flex-shrink: 0;
}

.player-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.player-details {
    flex: 1;
    min-width: 0;
}

.player-title {
    font-weight: 600;
    margin-bottom: 4px;
    color: var(--primary-color);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.player-artist {
    font-size: 0.9rem;
    color: var(--secondary-color);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.player-controls {
    display: flex;
    align-items: center;
    gap: 15px;
    flex-shrink: 0;
}

.control-btn {
    background: var(--music-color);
    color: white;
    border: none;
    width: 45px;
    height: 45px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    transition: all 0.3s ease;
}

.control-btn:hover {
    background: #ff5252;
    transform: scale(1.05);
}

.control-btn.play-btn {
    width: 55px;
    height: 55px;
    font-size: 1.4rem;
}

.player-progress {
    flex: 2;
    min-width: 300px;
}

.progress-bar {
    width: 100%;
    height: 6px;
    background: var(--border-color);
    border-radius: 3px;
    cursor: pointer;
    position: relative;
    margin-bottom: 8px;
}

.progress-fill {
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    background: var(--music-color);
    border-radius: 3px;
    width: 0%;
    transition: width 0.1s linear;
}

.time-display {
    display: flex;
    justify-content: space-between;
    font-size: 0.85rem;
    color: var(--secondary-color);
}

.player-volume {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
    min-width: 120px;
}

.volume-icon {
    color: var(--secondary-color);
    font-size: 1.2rem;
}

.volume-slider {
    flex: 1;
    height: 6px;
    background: var(--border-color);
    border-radius: 3px;
    outline: none;
    -webkit-appearance: none;
}

.volume-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 16px;
    height: 16px;
    background: var(--music-color);
    border-radius: 50%;
    cursor: pointer;
}

.volume-slider::-moz-range-thumb {
    width: 16px;
    height: 16px;
    background: var(--music-color);
    border-radius: 50%;
    cursor: pointer;
    border: none;
}

/* 响应式播放器 */
@media (max-width: 992px) {
    .player-content {
        gap: 20px;
    }
    
    .player-progress {
        min-width: 200px;
    }
}

@media (max-width: 768px) {
    .music-player {
        padding: 15px 20px;
    }
    
    .player-content {
        flex-wrap: wrap;
        gap: 15px;
    }
    
    .player-progress {
        min-width: 100%;
        order: 3;
    }
    
    .player-volume {
        min-width: 100px;
    }
}

@media (max-width: 480px) {
    .music-player {
        padding: 12px 15px;
    }
    
    .player-controls {
        gap: 10px;
    }
    
    .control-btn {
        width: 40px;
        height: 40px;
        font-size: 1.1rem;
    }
    
    .control-btn.play-btn {
        width: 45px;
        height: 45px;
        font-size: 1.2rem;
    }
}