* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: "Microsoft Yahei", sans-serif;
}
body {
    min-height: 100vh;
    padding: 15px;
    color: #cc3300;
    position: relative;
    padding-bottom: 125px; /* 预留播放器高度 + 5px间距 */
}
.bg-cover {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;
    opacity: 0.65;
    z-index: -1;
    filter: blur(0px);
}
.container {
    max-width: 1200px; /* 与播放器宽度一致 */
    margin: 0 auto;
    background: rgba(255, 255, 250, 0.5);
    backdrop-filter: blur(0.1px);
    border-radius: 20px;
    padding: 25px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.1);
    position: relative;
    z-index: 1;
    margin-bottom: 5px; /* container底部与播放控件顶部间距5px */
}
.header {
    text-align: center;
    margin-bottom: 2px;
    padding-bottom: 1px;
    border-bottom: 1px solid rgba(255,255,255,0.15);
}
.header h1 {
    font-size: 30px;
    margin-bottom: 8px;
    background: linear-gradient(90deg, #cc0066 0%, #fad0c4 99%, #00ff33 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}
.header p {
    font-size: 25px;
    color: #6633ff;
}
.main-content {
    display: flex;
    gap: 15px;
    height: calc(100vh - 230px); /* 适配头部+底部间距+播放器高度 */
}
.search-section {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 3px;
}
.search-box {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
    width: 100%;
}
.search-box input {
    flex: 1;
    min-width: 150px;
    padding: 12px 15px;
    border-radius: 15px;
    border: 1px solid rgba(0, 0, 255, 0.2);
    outline: none;
    background: rgba(255, 255, 255, 0.1);
    color: #ff0000;
}
.search-box input::placeholder {
    color: #ccc;
}
.search-box button {
    flex: 0 0 80px;
    padding: 12px;
    border-radius: 10px;
    border: none;
    outline: none;
    background: linear-gradient(90deg, #ff6b6b, #feca57);
    color: #fff;
    cursor: pointer;
    transition: all 0.3s;
}
.search-box button:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(255, 107, 107, 0.4);
}
/* 新增：Tab按钮容器样式（保留原有tab-nav样式） */
.tab-nav-container {
    width: 100%;
    margin-bottom: 2px; /* 按钮栏和内容区的间距，可调整 */
}

/* 新增：Tab内容容器样式 */
.tab-content-container {
    flex: 1;
    display: flex;
    flex-direction: column;
    height: calc(100% - 150px); /* 搜索框+按钮栏+头部栏 总高度 */
    overflow: hidden;
}
.tab-nav {
    display: flex;
    gap: 5px;
    border-radius: 10px;
    overflow: hidden;
    width: 100%;
}

.tab-btn {
    flex: 1;
    padding: 12px 0;
    text-align: center;
    background: rgba(255, 255, 255, 0.08);
    border: none;
    color: #66ffcc;
    cursor: pointer;
    transition: all 0.3s;
    font-size: 15px;
}
.tab-btn.active {
    background: linear-gradient(90deg, rgba(255, 154, 158, 0.3), rgba(250, 208, 196, 0.3));
    color: #6666cc;
    font-weight: 500;
}
.tab-content {
    display: none;
    height: 100%;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: rgba(255,255,255,0.2) transparent;
}


.tab-content::-webkit-scrollbar {
    width: 4px;
}
.tab-content::-webkit-scrollbar-thumb {
    background: rgba(255,255,255,0.2);
    border-radius: 2px;
}
.tab-content.active {
    display: block;
}
/* 播放记录栏 */
.history-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 1px;
    border-bottom: 1px solid rgba(255,0,0,0.1);
}
.history-title {
    font-size: 25px;
    font-weight: 500;
}
.history-opt {}
.playlist-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 1px;
    border-bottom: 1px solid rgba(255,0,0,0.1);
}

.playlist-title {
    font-size: 25px;
    font-weight: 500;
}
.playlist-opt {
    display: flex;
    gap: 25px;
}
.playlist-btn {
    padding: 1px 3px;
    border-radius: 16px;
    border: none;
    background: rgba(102, 126, 234, 0.3);
    color: #cc6600;
    cursor: pointer;
    font-size: 10px;
}
.playlist-btn.play-all {
    background: rgba(255, 107, 107, 0.3);
}
.song-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 1px 1px;
    margin-bottom: 2px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s;
    border: 1px solid transparent;
}
.song-item:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.15);
    transform: translateX(2px);
}
.song-cover {
    width: 50px;
    height: 50px;
    border-radius: 8px;
    object-fit: cover;
    background: rgba(255, 255, 255, 0.1);
}
.song-info {
    flex: 1;
    overflow: hidden;
}
.song-title {
    font-size: 20px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-bottom: 4px;
}
.song-author {
    font-size: 16px;
    color: #99ff00;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.song-time {
    font-size: 12px;
    color: #666;
    margin-top: 2px;
}
.song-opt {
    display: flex;
    gap: 10px;
}
.opt-btn {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    border: none;
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
}
.opt-btn.play {
    background: linear-gradient(90deg, #ff6b6b, #feca57);
}
.opt-btn.play:hover {
    box-shadow: 0 2px 8px rgba(255, 107, 107, 0.4);
}
.opt-btn.collect {
    background: rgba(231, 76, 60, 0.2);
}
.opt-btn.collect:hover, .opt-btn.collect.active {
    background: rgba(231, 76, 60, 0.4);
    color: #ff6b6b;
}
.opt-btn.delete {
    background: rgba(150, 150, 150, 0.2);
}
.opt-btn.delete:hover {
    background: rgba(150, 150, 150, 0.4);
}
.lyric-section {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 20px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 15px;
    padding: 20px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}
.player-info {
    text-align: center;
    margin-bottom: 10px;
}
.player-title {
    font-size: 25px;
    margin-bottom: 1px;
}
.player-author {
    font-size: 15px;
    color: #99ff00;
}
.lyric-container {
    flex: 1;
    overflow: hidden;
    text-align: center;
    padding: 0 10px;
    position: relative;
}
.lyric-wrapper {
    position: absolute;
    width: 100%;
    transition: transform 0.3s ease-out;
}
.lyric-line {
    font-size: 22px;
    line-height: 40px;
    color: #0033ff;
    transition: all 0.2s;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
}
/* 修改为蓝色渐变高亮 */
.lyric-line.active {
    background: linear-gradient(45deg, #0066ff, #66ccff);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    font-weight: 500;
    font-size: 28px;
}
/* 底部控件栏 */
.player-controls {
    position: fixed;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: calc(100% - 30px);
    max-width: 1200px;
    padding: 5px 25px;
    background: rgba(255, 255, 250, 0.8);
    backdrop-filter: blur(8px);
    box-shadow: 0 -2px 15px rgba(0, 0, 0, 0.2);
    border-top: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 10px 10px 0 0;
    z-index: 9999;
}
.controls-wrapper {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 5px;
    gap: 15px;
}
.audio-controls {
    display: flex;
    align-items: center;
    gap: 20px;
}
.control-actions {
    display: flex;
    align-items: center;
    gap: 1px;
}
.audio-btn {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: none;
    background: linear-gradient(90deg, #6b6b, #feca57);
    color: #fff;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
}
.audio-btn:hover {
    background: rgba(255, 255, 255, 0.15);
}
.audio-btn.play-pause {
    width: 44px;
    height: 44px;
    background: linear-gradient(90deg, #ff6b6b, #feca57);
}
.audio-btn.play-pause:hover {
    box-shadow: 0 4px 15px rgba(255, 107, 107, 0.5);
    transform: scale(1.05);
}
/* 清除记录按钮 */
.clear-history-btn {
    padding: 1px 3px;
    border-radius: 16px;
    border: none;
    background: rgba(231, 76, 60, 0.3);
    color: #ff6b6b;
    cursor: pointer;
    font-size: 10px;
    transition: all 0.3s;
}
.clear-history-btn:hover {
    background: rgba(231, 76, 60, 0.5);
    box-shadow: 0 2px 8px rgba(231, 76, 60, 0.3);
}
/* 音量调节 */
.volume-control {
    display: flex;
    align-items: center;
    gap: 8px;
    flex: 0 1 150px;
}
.volume-icon {
    color: #666;
    font-size: 16px;
}
.volume-slider {
    width: 100%;
    height: 4px;
    -webkit-appearance: none;
    background: rgba(185, 155, 105, 0.3);
    border-radius: 2px;
    outline: none;
}
.volume-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: linear-gradient(90deg, #ff6b6b, #feca57);
    cursor: pointer;
    transition: all 0.2s;
}
.volume-slider::-webkit-slider-thumb:hover {
    transform: scale(1.2);
    box-shadow: 0 0 8px rgba(255, 107, 107, 0.5);
}
.progress-container {
    width: 100%;
    height: 10px;
    background: rgba(155, 195, 190, 0.2);
    border-radius: 3px;
    cursor: pointer;
}
.progress-bar {
    width: 0%;
    height: 100%;
    background: linear-gradient(90deg, #ff9a9e, #00ff33);
    border-radius: 3px;
}
.time-display {
    display: flex;
    justify-content: space-between;
    font-size: 13px;
    color: #330000;
    margin-top: 8px;
}
.check-tip {
    font-size: 13px;
    margin: 1px 0;
    padding: 1px;
    border-radius: 8px;
    display: none;
}
.check-tip.success {
    display: block;
    background: rgba(46, 204, 113, 0.2);
    color: #2ecc71;
}
.check-tip.error {
    display: block;
    background: rgba(231, 76, 60, 0.2);
    color: #e74c3c;
}
.empty-tip {
    text-align: center;
    padding: 30px 0;
    color: #ccc;
    font-size: 15px;
}
.cache-tip {
    font-size: 12px;
    color: #ccc;
    text-align: right;
    margin-top: 5px;
}
.error-tip {
    font-size: 12px;
    color: #ff6b6b;
    text-align: center;
    margin-top: 10px;
}
/* 二次确认弹窗 */
.confirm-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 99999;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}
.confirm-modal.active {
    opacity: 1;
    visibility: visible;
}
.confirm-content {
    background: rgba(255, 255, 250, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 16px;
    width: 420px;
    padding: 30px 24px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.8);
    text-align: center;
    transform: translateY(20px);
    transition: transform 0.3s ease;
}
.confirm-modal.active .confirm-content {
    transform: translateY(0);
}
.confirm-icon {
    font-size: 48px;
    color: #ff6b6b;
    margin-bottom: 16px;
    animation: breath 2s ease-in-out infinite;
}
@keyframes breath {
    0%, 100% { transform: scale(1); opacity: 0.9; }
    50% { transform: scale(1.1); opacity: 1; }
}
.confirm-title {
    font-size: 18px;
    color: #2d3748;
    font-weight: 600;
    margin-bottom: 8px;
}
.confirm-desc {
    font-size: 14px;
    color: #718096;
    margin-bottom: 24px;
}
.confirm-btns {
    display: flex;
    justify-content: center;
    gap: 20px;
}
.confirm-btn {
    width: 130px;
    height: 42px;
    border-radius: 22px;
    border: none;
    font-size: 15px;
    cursor: pointer;
    transition: all 0.3s ease;
}
.btn-cancel {
    background: #f8f9fa;
    color: #4a5568;
    border: 1px solid #dee2e6;
}
.btn-cancel:hover {
    background: #e9ecef;
    transform: translateY(-2px);
}
.btn-confirm {
    background: linear-gradient(135deg, #ff6b6b 0%, #f78989 100%);
    color: #fff;
}
.btn-confirm:hover {
    background: linear-gradient(135deg, #f78989 0%, #f9a0a0 100%);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(245, 107, 107, 0.3);
}
/* 新增：Tab头部栏容器（存放playlist-bar/history-bar） */
.tab-header-bar {
    width: 100%;
    margin-bottom: 1px;
}
/* 响应式适配 */
@media (max-width: 768px) {
    .main-content {
        flex-direction: column;
        height: auto;
    }
    .lyric-section {
        height: 300px;
        margin-bottom: 5px;
    }
    .player-controls {
        padding: 12px 15px;
    }
    .controls-wrapper {
        flex-direction: column;
        gap: 10px;
    }
    .control-actions {
        margin-top: 5px;
        width: 100%;
        justify-content: space-between;
    }
    .volume-control {
        width: 100%;
        flex: none;
    }
    .tab-nav {
        flex-wrap: wrap;
    }
    .tab-btn {
        flex: 1 1 30%;
    }
    .confirm-content {
        width: 90%;
        padding: 24px 16px;
    }
}
/* 响应式适配：小屏幕下调整容器布局 */
/* @media (max-width: 768px) {
    .tab-content-container {
        height: calc(100% - 100px);
    }
}
@media (max-width: 768px) {
    .tab-content-container {
        height: calc(100% - 130px);
    }
}*/
