/* ----- 音樂播放器相關樣式 ----- */
.btn-music { background: var(--bg-card); color: var(--glow-primary); border: 1px solid var(--glow-primary); }
.btn-music:hover { background: var(--glow-primary); color: var(--bg-dark); }
.btn-music.active { background: var(--glow-primary); color: var(--bg-dark); animation: pulse-music 1s infinite; }
@keyframes pulse-music { 0%, 100% { box-shadow: 0 0 0 0 rgba(0, 212, 255, 0.4); } 50% { box-shadow: 0 0 0 10px rgba(0, 212, 255, 0); } }
.music-player { position: fixed; bottom: 6rem; right: 2rem; width: 280px; background: var(--bg-card); border: 1px solid var(--glow-primary); border-radius: 1rem; overflow: hidden; z-index: 1000; box-shadow: var(--shadow-glow); opacity: 0; visibility: hidden; transform: translateY(20px); transition: var(--transition-normal); }
.music-player.visible { opacity: 1; visibility: visible; transform: translateY(0); }
.player-header { background: var(--gradient-primary); padding: 0.75rem 1rem; display: flex; justify-content: space-between; align-items: center; color: var(--bg-dark); font-weight: bold; }
.btn-close-player { background: none; border: none; color: var(--bg-dark); cursor: pointer; font-size: 1rem; opacity: 0.7; transition: var(--transition-fast); }
.btn-close-player:hover { opacity: 1; }
.player-content { padding: 1rem; }
.track-list { max-height: 120px; overflow-y: auto; margin-bottom: 1rem; }
.track-item { padding: 0.5rem; border-radius: 0.5rem; cursor: pointer; color: var(--text-secondary); transition: var(--transition-fast); font-size: 0.9rem; }
.track-item:hover { background: var(--bg-card-hover); color: var(--text-primary); }
.track-item.active { background: var(--bg-card-hover); color: var(--glow-primary); }
.playlist-empty-msg { color: var(--text-muted); text-align: center; padding: 20px; }
.player-controls { display: flex; justify-content: center; gap: 1rem; margin-bottom: 1rem; }
.btn-control { width: 40px; height: 40px; border-radius: 50%; border: 1px solid var(--border-color); background: transparent; color: var(--text-primary); cursor: pointer; transition: var(--transition-fast); display: flex; align-items: center; justify-content: center; }
.btn-control:hover { border-color: var(--glow-primary); color: var(--glow-primary); }
.btn-play { width: 50px; height: 50px; background: var(--gradient-primary); border: none; color: var(--bg-dark); }
.btn-play:hover { transform: scale(1.1); }
.progress-bar { height: 4px; background: var(--border-color); border-radius: 2px; overflow: hidden; margin-bottom: 0.5rem; cursor: pointer; }
.progress-fill { height: 100%; background: var(--gradient-primary); width: 0%; transition: width 0.1s linear; }
.track-time { display: flex; justify-content: space-between; font-size: 0.75rem; color: var(--text-muted); }
.volume-control { padding-top: 5px; color: var(--text-secondary); }
.volume-slider { height: 4px; background: var(--border-color); border-radius: 2px; accent-color: var(--glow-primary); }
.volume-slider::-webkit-slider-thumb { width: 12px; height: 12px; background: var(--glow-primary); }
#btnPanelPlaylistToggle, #btnPanelWaveformToggle, #btnFooterPlayerToggle { color: var(--text-secondary) !important; background: transparent !important; border-color: var(--border-color) !important; transition: all 0.3s ease; }
#btnPanelPlaylistToggle.active, #btnPanelWaveformToggle.active, #btnFooterPlayerToggle.active { background-color: var(--glow-primary) !important; color: #fff !important; border-color: var(--glow-primary) !important; box-shadow: 0 0 10px rgba(0, 212, 255, 0.5); }
#btnPanelPlaylistToggle:hover, #btnPanelWaveformToggle:hover, #btnFooterPlayerToggle:hover { opacity: 0.8; }
.navbar-music-controls .btn { border-width: 1px; }
.top-music-panel { position: fixed; top: 0; left: 0; right: 0; background: var(--bg-card); z-index: 1020; border-bottom: 1px solid var(--glow-primary); box-shadow: 0 5px 20px rgba(0,0,0,0.5); transform: translateY(-100%); transition: transform 0.3s ease; padding-top: 70px; }
.top-music-panel.show { transform: translateY(0); }
#waveform-container { width: 100%; height: 300px; background: rgba(0,0,0,0.2); border-radius: 1rem; margin-bottom: 20px; overflow: hidden; border: 1px solid var(--border-color); }
.story-playlist { height: 100%; max-height: 600px; overflow-y: auto; }
.story-playlist .list-group-item { background: var(--bg-card); border-color: var(--border-color); color: var(--text-secondary); cursor: pointer; transition: all 0.2s; }
.story-playlist .list-group-item:hover { background: var(--bg-card-hover); color: var(--text-primary); }
.story-playlist .list-group-item.active { background: var(--gradient-primary); color: var(--bg-dark); border-color: transparent; }
.wave-btn.active { background: var(--glow-primary); color: var(--bg-dark); }
.mode-btn.active { background: var(--glow-secondary); color: var(--bg-dark); }
.music-nav-btn { color: var(--glow-primary); border-color: var(--glow-primary); box-shadow: 0 0 10px rgba(0, 212, 255, 0.2); }
.music-nav-btn:hover { background: var(--glow-primary); color: var(--bg-dark); box-shadow: 0 0 20px var(--glow-primary); }
.control-btn-circle { width: 32px; height: 32px; display: flex; align-items: center; justify-content: center; padding: 0; }
.waveform-wrapper { position: relative; margin-bottom: 20px; }
.waveform-controls-overlay { position: absolute; top: 10px; right: 10px; z-index: 10; display: flex; gap: 5px; background: rgba(0,0,0,0.5); padding: 5px; border-radius: 8px; backdrop-filter: blur(4px); border: 1px solid rgba(255,255,255,0.1); }
.waveform-controls-overlay .btn-sm { font-size: 0.75rem; padding: 2px 8px; }
.story-playlist { border: 1px solid var(--glow-primary); box-shadow: 0 0 15px rgba(0, 212, 255, 0.1); }
.story-playlist .card-header { background: linear-gradient(90deg, rgba(0,212,255,0.2), transparent); color: var(--glow-primary) !important; font-weight: bold; border-bottom: 1px solid var(--glow-primary); }
.story-playlist .list-group-item.active { background: linear-gradient(90deg, var(--glow-primary), var(--glow-secondary)); border: none; box-shadow: 0 0 10px rgba(0, 212, 255, 0.4); }
#playlistCol { position: fixed; top: 0; left: 0; height: 100vh; width: 260px; z-index: 1060; background-color: rgba(18, 18, 42, 0.95); backdrop-filter: blur(10px); border-right: 1px solid var(--glow-primary); box-shadow: 5px 0 25px rgba(0, 0, 0, 0.5); transform: translateX(-100%); transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1); padding: 0; overflow-y: auto; }
#playlistCol.show { transform: translateX(0); }
#playlistCol .card { background: transparent; border: none; height: 100%; }
#playlistCol .card-header { padding-top: 20px; background: transparent; border-bottom: 1px solid rgba(255,255,255,0.1); }
.waveform-player-bar { position: absolute; bottom: 0; left: 0; right: 0; padding: 10px 20px; background: linear-gradient(to top, rgba(10,10,26,0.9) 0%, rgba(10,10,26,0.6) 60%, transparent 100%); z-index: 20; display: flex; align-items: center; gap: 15px; }
.time-display { font-family: 'Consolas', monospace; font-size: 0.85rem; color: var(--glow-primary); text-shadow: 0 0 5px var(--glow-primary); min-width: 45px; text-align: center; }
.progress-slider { height: 4px; border-radius: 2px; -webkit-appearance: none; background: rgba(255,255,255,0.1); width: 100%; cursor: pointer; }
.progress-slider::-webkit-slider-thumb { -webkit-appearance: none; width: 12px; height: 12px; border-radius: 50%; background: var(--glow-secondary); box-shadow: 0 0 10px var(--glow-secondary); cursor: pointer; margin-top: -4px; transition: transform 0.1s; }
.progress-slider::-webkit-slider-thumb:hover { transform: scale(1.5); }
.progress-slider::-webkit-slider-runnable-track { width: 100%; height: 4px; cursor: pointer; background: rgba(255,255,255,0.1); border-radius: 2px; }
.volume-slider-sm { width: 80px; height: 4px; -webkit-appearance: none; background: rgba(255,255,255,0.1); border-radius: 2px; }
.volume-slider-sm::-webkit-slider-thumb { -webkit-appearance: none; width: 10px; height: 10px; border-radius: 50%; background: var(--text-secondary); cursor: pointer; }
.volume-slider-sm::-webkit-slider-thumb:hover { background: var(--text-primary); }
#volIcon { width: 20px; text-align: center; }
.volume-slider-custom { -webkit-appearance: none; width: 100px; height: 6px; background: rgba(255,255,255,0.1); border-radius: 3px; background-image: linear-gradient(var(--glow-primary), var(--glow-primary)); background-size: 80% 100%; background-repeat: no-repeat; cursor: pointer; }
.volume-slider-custom::-webkit-slider-thumb { -webkit-appearance: none; height: 14px; width: 14px; border-radius: 50%; background: #fff; cursor: pointer; box-shadow: 0 0 5px rgba(0,0,0,0.5); transition: transform 0.1s; }
.volume-slider-custom::-webkit-slider-thumb:hover { transform: scale(1.2); }
.volume-slider-custom::-webkit-slider-runnable-track { -webkit-appearance: none; box-shadow: none; border: none; background: transparent; }
.volume-text { font-family: 'Consolas', monospace; font-size: 0.9rem; color: var(--glow-primary); min-width: 35px; text-align: right; user-select: none; }
.bottom-player-bar { position: fixed; bottom: 0; left: 0; right: 0; background: rgba(10, 10, 26, 0.98); backdrop-filter: blur(10px); border-top: 1px solid var(--glow-primary); padding: 12px 20px; z-index: 9999; display: flex; align-items: center; gap: 20px; box-shadow: 0 -5px 25px rgba(0,0,0,0.6); transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1); min-height: 40px; }
.bottom-player-bar {transform: translateY(100%); /* 預設隱藏 */}
.bottom-player-bar.show { transform: translateY(0); }
.bottom-player-bar .time-display { font-family: 'Consolas', monospace; font-size: 0.9rem; color: var(--glow-primary); min-width: 50px; text-align: center; }
.bottom-player-bar .progress-container { flex: 1; display: flex; align-items: center; gap: 10px; }
.bottom-player-bar .volume-container { display: flex; align-items: center; gap: 10px; width: 200px; }
@media (max-width: 767px) { .music-player { right: 1rem; width: calc(100% - 2rem); max-width: 300px; } }
.padding_bottom30 { padding-bottom: 40px; }