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

body {
    background: linear-gradient(135deg, #2c3e50, #1a1a2e);
    color: #fff;
    height: 100vh;
    justify-content: center;
    align-items: center;
    overflow: hidden;
}

.music-player {
    width: 100%;
    height: calc(100% - 30px);
    display: grid;
    grid-template-rows: 1fr 80px;
    grid-template-columns: 1fr 0;
    background-color: rgba(20, 20, 30, 0.8);
    backdrop-filter: blur(10px);
}

/* 左侧歌曲列表样式 */
.song-list-container {
    grid-row: 1;
    grid-column: 1;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.list-search {
    padding:0 15px 15px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    gap: 10px;
}

.search-box {
    flex: 1;
    display: flex;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    overflow: hidden;
}

.search-box input {
    flex: 1;
    background: transparent;
    border: none;
    padding: 8px 15px;
    color: #fff;
    outline: none;
}

.search-box button {
    background: transparent;
    border: none;
    color: #ccc;
    padding: 0 15px;
    cursor: pointer;
}

.song-list {
    flex: 1;
    overflow-y: auto;
    padding: 0 15px;
    
    /* 自定义滚动条样式 */
    scrollbar-width: thin;
    scrollbar-color: rgba(29, 185, 84, 0.5) rgba(0, 0, 0, 0.1);
}

/* Webkit浏览器的滚动条样式 */
.song-list::-webkit-scrollbar {
    width: 6px;
}

.song-list::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.1);
    border-radius: 3px;
}

.song-list::-webkit-scrollbar-thumb {
    background-color: rgba(29, 185, 84, 0.5);
    border-radius: 3px;
    transition: background-color 0.3s;
}

.song-list::-webkit-scrollbar-thumb:hover {
    background-color: rgba(29, 185, 84, 0.8);
}

.song-list table {
    width: 100%;
    border-collapse: collapse;
}

.song-list th {
    text-align: left;
    padding: 10px 5px;
    font-weight: normal;
    color: #aaa;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.song-list td {
    padding: 12px 5px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.song-list tr td:first-child {
    text-align: center;
}

.song-list tr:hover {
    background: rgba(255, 255, 255, 0.05);
}

.song-list tr.active {
    background: rgba(29, 185, 84, 0.2);
}

/* 下载和收藏按钮样式 */
.download-btn, .favorite-btn {
    background: transparent;
    border: none;
    color: #888;
    font-size: 14px;
    cursor: pointer;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.3s;
}

.download-btn:hover {
    color: #1db954;
    background: transparent;
    transform: scale(1.1);
}

.favorite-btn:hover {
    color: #ff4757;
    background: rgba(255, 71, 87, 0.1);
}

.favorite-btn .fas.fa-heart {
    color: #ff4757;
}

/* 右侧歌曲详情样式 */
.song-detail-container {
    width: 100%;
    height: calc(100% - 80px);
    display: flex;
    flex-direction: column;
    padding: 20px;
    background: rgba(23, 25, 37);
    overflow: hidden;
    position: fixed;
    left:0; 
    top:100vh;
    z-index: 9999;
    transition: all 0.6s;
}

.lyrics-off{ width: 22px; height: 22px; position:absolute; top: 0; right: 30px; cursor: pointer;}

.song-info {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    margin-bottom: 30px;
}

.album-cover {
    width: 200px;
    height: 200px;
    border-radius: 50%;
    margin-bottom: 20px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    object-fit: cover;
    display: block;
}

.song-text h2 {
    font-size: 24px;
    margin-bottom: 10px;
    color: #fff;
}

.song-text p {
    color: #aaa;
    margin: 5px 0;
    font-size: 16px;
}

.song-lyrics {
    flex: 1;
    overflow-y: hidden;
    text-align: center;
    padding: 20px 0;
    scroll-behavior: smooth;
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    
    /* 自定义滚动条样式 */
    scrollbar-width: thin;
    scrollbar-color: rgba(29, 185, 84, 0.5) rgba(0, 0, 0, 0.1);
}

/* Webkit浏览器的滚动条样式 */
.song-lyrics::-webkit-scrollbar {
    width: 6px;
}

.song-lyrics::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.1);
    border-radius: 3px;
}

.song-lyrics::-webkit-scrollbar-thumb {
    background-color: rgba(29, 185, 84, 0.5);
    border-radius: 3px;
    transition: background-color 0.3s;
}

.song-lyrics::-webkit-scrollbar-thumb:hover {
    background-color: rgba(29, 185, 84, 0.8);
}

.lyrics-line {
    margin: 8px 0;
    color: rgba(255, 255, 255, 0.5);
    transition: all 0.3s ease;
    font-size: 16px;
    line-height: 1.4;
    padding: 3px 10px;
    border-radius: 4px;
    width: 90%;
    text-align: center;
    position: relative;
    transform: scale(0.95);
    opacity: 0.7;
}

.lyrics-line.highlight {
    color: #1db954;
    font-size: 18px;
    font-weight: bold;
    /*background-color: rgba(29, 185, 84, 0.2);*/
    /*box-shadow: 0 0 10px rgba(29, 185, 84, 0.3);*/
    transform: scale(1);
    opacity: 1;
    /*text-shadow: 0 0 5px rgba(255, 255, 255, 0.3);*/
    letter-spacing: 0.5px;
}

/* 添加前后行的渐变效果 */
.song-lyrics::before,
.song-lyrics::after {
    content: '';
    position: sticky;
    left: 0;
    right: 0;
    height: 50px;
    pointer-events: none;
    z-index: 1;
}

.song-lyrics::before {
    top: 0;
    background: linear-gradient(to bottom, rgba(20, 20, 30, 0.9), transparent);
}

.song-lyrics::after {
    bottom: 0;
    background: linear-gradient(to top, rgba(20, 20, 30, 0.9), transparent);
}

.song-info-line {
    color: #1db954;
    font-weight: bold;
    margin-bottom: 15px;
    border-bottom: 1px solid rgba(29, 185, 84, 0.3);
    padding-bottom: 8px;
    transform: scale(1);
    opacity: 1;
    letter-spacing: 1px;
}

.no-lyrics {
    color: rgba(255, 255, 255, 0.5);
    font-style: italic;
    margin-top: 50px;
}

/* 底部播放控制栏样式 */
.player-controls {
    grid-row: 2;
    grid-column: 1 / span 2;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 4px 20px 0;
    background: rgba(20, 20, 30, 0.9);
    position: relative;
    z-index: 99999;
    /* border-top: 5px solid rgba(22, 23, 35); */
}

.control-song-info {
    width: 300px;
    display: flex;
    align-items: center;
    gap: 10px;
    margin-right: 30px;
}

.control-song-info .album-cover{ width: 50px; height: 50px; background: #000; border: none; border-radius: 10px; margin-bottom: 0;}
.control-song-info .song-text{ flex: 1;}
.control-song-info .song-text .current-song-title{ font-size: 15px; line-height: 1; margin-bottom: 6px;}
.control-song-info .song-text .current-song-artist{ font-size: 13px; line-height: 1;}

.control-middle{ display: flex;}
.control-right{ display: flex; align-items: center;}

.control-buttons {
    display: flex;
    align-items: center;
    gap: 15px;
}

.control-buttons button {
    background: transparent;
    border: none;
    color: #fff;
    font-size: 16px;
    cursor: pointer;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.3s;
}

.control-buttons button:hover {
    background: rgba(255, 255, 255, 0.1);
}

.control-buttons #play-btn {
    background: rgba(255, 255, 255, 0.1);
    width: 40px;
    height: 40px;
    font-size: 18px;
}

.progress-container {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 0 20px;
}

.progress-bar {
    width: 100%;
    flex: 1;
    height: 4px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 2px;
    cursor: pointer;
    position: absolute;
    left: 0;
    top: 0;
}
.progress-bar:hover{ background: rgba(255, 255, 255, 0.2);}

.progress {
    height: 100%;
    background: #1db954;
    border-radius: 2px;
    position: relative;
}

.progress::after {
    content: '';
    position: absolute;
    right: -5px;
    top: -3px;
    width: 10px;
    height: 10px;
    background: #fff;
    border-radius: 50%;
    opacity: 0;
    transition: opacity 0.3s;
}

.progress-bar:hover .progress::after {
    opacity: 1;
}

.volume-container {
    display: flex;
    align-items: center;
    gap: 10px;
    position: relative;
}

.volume-slider {
    width: 100px;
    height: 4px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 2px;
    cursor: pointer;
}

.volume-progress {
    height: 100%;
    background: #1db954;
    border-radius: 2px;
    position: relative;
}

.playOrder{ margin-left: 10px;}
.playOrder button{
    background: transparent;
    border: none;
    color: #fff;
    font-size: 16px;
    cursor: pointer;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.3s;
}

.lyrics-button{ margin-left: 10px;}
.lyrics-button button{
    background: transparent;
    border: none;
    cursor: pointer;
    width: 32px;
    height: 32px;
    border-radius: 5px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
}

.lyrics-button button:hover{
    background: rgba(255, 255, 255, 0.05);
}

/* 下载模态框样式 */
.download-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    backdrop-filter: blur(5px);
    animation: modalFadeIn 0.3s ease;
}

@keyframes modalFadeIn {
    from {
        opacity: 0;
        transform: scale(0.95);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

.download-modal-content {
    background-color: white;
    padding: 25px;
    border-radius: 15px;
    min-width: 320px;
    max-width: 500px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
    transform: translateY(0);
    animation: modalContentSlideIn 0.3s ease;
}

@keyframes modalContentSlideIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.download-modal h3 {
    margin: 0 0 20px 0;
    text-align: center;
    color: #333;
    font-size: 18px;
    font-weight: 600;
}

.download-options {
    max-height: 300px;
    overflow-y: auto;
    margin: 0 -25px;
    padding: 0 25px;
    /* 自定义滚动条样式 */
    scrollbar-width: thin;
    scrollbar-color: rgba(29, 185, 84, 0.5) rgba(0, 0, 0, 0.1);
}

.download-options::-webkit-scrollbar {
    width: 6px;
}

.download-options::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.1);
    border-radius: 3px;
}

.download-options::-webkit-scrollbar-thumb {
    background-color: rgba(29, 185, 84, 0.5);
    border-radius: 3px;
}

.close-modal {
    display: block;
    width: 100%;
    padding: 12px;
    margin-top: 25px;
    background-color: #f5f5f5;
    border: none;
    border-radius: 25px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    color: #666;
    transition: all 0.3s ease;
}

.close-modal:hover {
    background-color: #ebebeb;
    color: #333;
    transform: translateY(-1px);
}

.filter-button {
    background: transparent;
    border: none;
    color: #ccc;
    padding: 0 15px;
    cursor: pointer;
}

.control-button {
    background: transparent;
    border: none;
    color: #fff;
    font-size: 16px;
    cursor: pointer;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.3s;
}

.control-button:hover {
    background: rgba(255, 255, 255, 0.1);
}

.play-button {
    background: rgba(255, 255, 255, 0.1);
    width: 40px;
    height: 40px;
    font-size: 18px;
}

.action-buttons {
    text-align: center;
}

.btn-download {
    background: transparent;
    border: none;
    color: #aaa;
    cursor: pointer;
    padding: 5px;
    transition: color 0.3s;
}

.btn-download:hover {
    color: #1db954;
}

/* 切换列表按钮样式 */
.switch-list-btn {
    background: rgba(29, 185, 84, 0.2);
    color: #fff;
    border: none;
    border-radius: 20px;
    padding: 8px 15px;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    gap: 5px;
    white-space: nowrap;
    margin-left: 10px;
}

.switch-list-btn:hover {
    background: rgba(29, 185, 84, 0.4);
}

.switch-list-btn i {
    font-size: 14px;
}



/* 响应式布局 */
@media screen and (max-width: 1320px) {
    .song-list td { padding: 6px 5px; font-size: 15px;}
}

@media screen and (max-width: 1200px) {
    .music-player {
        grid-template-columns: 1fr 0;
    }
    
    .album-cover {
        width: 180px;
        height: 180px;
    }
    
    .song-text h2 {
        font-size: 20px;
    }
}

@media screen and (max-width: 992px) {
    .music-player {
        grid-template-columns: 1fr 0;
    }
    
    .album-cover {
        width: 150px;
        height: 150px;
    }
    
    .song-text h2 {
        font-size: 18px;
    }
    
    .lyrics-line {
        font-size: 13px;
    }
}

@media screen and (max-width: 768px) {
    
    .song-detail-container {
        grid-row: 2;
        grid-column: 1;
        border-top: 1px solid rgba(255, 255, 255, 0.1);
    }
    
    .song-list-container {
        grid-row: 1;
        grid-column: 1;
        border-right: none;
    }
    
    .player-controls {
        grid-row: 3;
        grid-column: 1;
        padding: 0 15px;
    }

    .player-controls .control-song-info{ display: none;}
    
    .album-cover {
        width: 120px;
        height: 120px;
    }
    
    .song-info {
        margin-bottom: 15px;
    }
    
    .song-lyrics {
        padding: 10px 0;
    }
}

@media screen and (max-width: 576px) {
    body {
        font-size: 13px;
    }

    .music-player {
        display: block;
        height:100vh;
    }

    .song-list-container{ height: calc(100% - 70px); display: block;}
    .song-detail-container{ height: calc(100% - 70px); padding:50px 15px 0;}
    .player-controls{ width: 100%; height: 70px; position: sticky; left: 0; bottom: 0; }
    .player-controls .lyrics-button button{ width: 18px; height: 18px;}
    .player-controls .volume-container{ display: none;}

    .lyrics-off{ width: 18px; height: 18px; right: 15px; top: 13px; opacity: 0.8; display: none;}
    .lyrics-off svg{ width: 18px; height: 18px;}

    .song-info {
        margin-bottom: 25px;
        overflow: hidden;
    }
    
    .list-search {
        height: 50px;
        padding: 10px;
    }
    
    .search-box input {
        padding: 6px 10px;
    }
    
    .song-list  { height: calc(100% - 50px);}
    
    .song-list td {
        padding: 8px 5px;
        font-size: 13px;
    }
    
    .album-cover {
        width: 100px;
        height: 100px;
    }
    
    .song-text h2 {
        font-size: 22px;
    }
    
    .song-text p {
        font-size: 14px;
    }
    
    .control-buttons {
        gap: 5px;
    }
    
    .control-buttons button {
        width: 30px;
        height: 30px;
    }
    
    .control-buttons #play-btn {
        width: 45px;
        height: 45px;
    }
    
    .progress-container {
        padding: 0 10px;
    }
    
    .volume-container {
        padding: 0 10px;
    }
    
    /* 隐藏音量滑块，只保留静音按钮 */
    .volume-slider {
        display: none;
    }
}

@media screen and (max-width: 460px) {

    .album-cover {
        width: 120px;
        height: 120px;
    }
    
    .lyrics-line {
        font-size: 16px;
        padding: 2px 5px;
    }
    
    .control-buttons #play-btn {
        width: 40px;
        height: 40px;
    }
    
    /* 调整音量按钮间距 */
    .volume-container {
        padding: 0 5px;
    }
}

/* 横屏模式优化 */
@media screen and (max-height: 600px) and (orientation: landscape) {
    .album-cover {
        width: 100px;
        height: 100px;
        margin-bottom: 10px;
    }
    
    .song-info {
        margin-bottom: 10px;
    }
    
    .song-text h2 {
        font-size: 16px;
        margin-bottom: 5px;
    }
    
    .song-text p {
        margin: 2px 0;
    }
    
    .lyrics-line {
        margin: 4px 0;
    }
    
    .player-controls {
        height: 60px;
    }
}

.download-option {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px;
    border-bottom: 1px solid #eee;
    transition: all 0.3s ease;
}

.download-option:hover {
    background-color: rgba(29, 185, 84, 0.05);
}

.download-option:last-child {
    border-bottom: none;
}

.download-option span {
    color: #333;
    font-size: 14px;
    font-weight: 500;
    flex: 1;
    margin-right: 15px;
}

.download-option .download-btn {
    background: linear-gradient(135deg, #1db954, #1ed760);
    color: white;
    padding: 8px 20px;
    border-radius: 20px;
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    letter-spacing: 0.5px;
    box-shadow: 0 2px 8px rgba(29, 185, 84, 0.2);
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 6px;
    min-width: 100px;
    justify-content: center;
    border: none;
}

.download-option .download-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(29, 185, 84, 0.3);
    background: linear-gradient(135deg, #1ed760, #1db954);
}

.download-option .download-btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 4px rgba(29, 185, 84, 0.2);
}

.download-option .download-btn::before {
    content: '\f019';  /* 下载图标的 Unicode */
    font-family: 'Font Awesome 5 Free';
    font-weight: 900;
    font-size: 14px;
}

/* 添加不同格式的颜色标识 */
.download-option[data-format="WAV"] .download-btn,
.download-option[data-format="FLAC"] .download-btn {
    background: linear-gradient(135deg, #9b59b6, #8e44ad);
    box-shadow: 0 2px 8px rgba(155, 89, 182, 0.2);
}

.download-option[data-format="WAV"] .download-btn:hover,
.download-option[data-format="FLAC"] .download-btn:hover {
    box-shadow: 0 4px 12px rgba(155, 89, 182, 0.3);
    background: linear-gradient(135deg, #8e44ad, #9b59b6);
}

.download-option[data-format="MP3"] .download-btn {
    background: linear-gradient(135deg, #3498db, #2980b9);
    box-shadow: 0 2px 8px rgba(52, 152, 219, 0.2);
}

.download-option[data-format="MP3"] .download-btn:hover {
    box-shadow: 0 4px 12px rgba(52, 152, 219, 0.3);
    background: linear-gradient(135deg, #2980b9, #3498db);
}

#volume-btn {
    background: transparent;
    border: none;
    color: #fff;
    cursor: pointer;
    padding: 0;
    transition: all 0.3s ease;
}

#volume-btn:hover {
    transform: scale(1.1);
}

/* 列表切换按钮组样式 */
.list-buttons {
    display: flex;
    gap: 10px;
    margin-left: 10px;
}

.list-btn {
    background: rgba(29, 185, 84, 0.2);
    color: #fff;
    border: none;
    border-radius: 20px;
    padding: 8px 15px;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    gap: 5px;
    white-space: nowrap;
}

.list-btn:hover {
    background: rgba(29, 185, 84, 0.4);
    transform: translateY(-1px);
}

.list-btn i {
    font-size: 14px;
}

.list-btn.active {
    background: rgba(29, 185, 84, 0.6);
}

.list-btn a{ color:#fff; text-decoration: none;}

/* 响应式布局调整 */
@media screen and (max-width: 768px) {
    .list-buttons {
        flex-wrap: wrap;
        gap: 5px;
        margin-left: 5px;
    }
    
    .list-btn {
        padding: 6px 12px;
        font-size: 13px;
    }
    
    .list-btn.pc{ display:none;}
}