.embedded-player {
    position: relative; /* 跟随文章流动 */
    width: 100%;        /* 宽度自适应 */
    max-width: 450px;   /* 限制最大宽度，防止太宽 */
    margin: 25px auto;  /* 上下留白25px，左右居中 */
    background: #f9f9f9; /* 浅灰背景，与正文区分 */
    border-radius: 8px;
    border: 1px solid #eee;
    padding: 15px;
    box-sizing: border-box;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

/* 顶部歌曲信息 */
.player-header {
    display: flex;
    align-items: center;
    margin-bottom: 12px;
    overflow: hidden; /* 防止文字溢出 */
}

.music-icon {
    font-size: 20px;
    margin-right: 10px;
    color: #555;
}

/* 滚动文字遮罩 */
.song-info-mask {
    flex: 1;
    overflow: hidden;
    white-space: nowrap;
    position: relative;
    /* 两侧淡出效果 */
    mask-image: linear-gradient(to right, transparent, black 5%, black 95%, transparent);
    -webkit-mask-image: linear-gradient(to right, transparent, black 5%, black 95%, transparent);
}

.song-title {
    display: inline-block;
    font-size: 15px;
    color: #333;
    font-weight: 600;
    padding-left: 100%;
    animation: scroll-text 12s linear infinite;
}

@keyframes scroll-text {
    0% { transform: translateX(0); }
    100% { transform: translateX(-100%); }
}

/* 控制区 */
.player-controls {
    display: flex;
    align-items: center;
    gap: 10px;
}

#play-btn {
    background: #333;
    color: #fff;
    border: none;
    border-radius: 50%;
    width: 36px;
    height: 36px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    transition: background 0.2s;
    flex-shrink: 0;
}

#play-btn:hover {
    background: #000;
}

#seek-bar {
    flex: 1;
    cursor: pointer;
    height: 5px;
    accent-color: #333;
    width: 0; /* 修复 flex 布局下的 input 宽度问题 */
}

#time-display {
    font-size: 12px;
    color: #666;
    min-width: 70px;
    text-align: right;
    font-variant-numeric: tabular-nums; /* 防止数字跳动 */
}

/* 循环按钮 */
#loop-btn {
    background: transparent;
    border: none;
    font-size: 18px;
    cursor: pointer;
    color: #999 !important; /* 默认灰色：未开启 */
    padding: 0 5px;
    line-height: 1;
    transition: all 0.2s;
}

#loop-btn:hover {
    color: #666;
}

/* 激活状态（开启循环时变色） */
#loop-btn.active-loop {
    color: #007bff; /* 蓝色高亮，或者你可以改成 #333 黑色 */
    text-shadow: 0 0 5px rgba(0, 123, 255, 0.7);
}

/* 稍微调整一下原有控制栏，确保放得下 */
.player-controls {
    display: flex;
    align-items: center;
    gap: 8px; /* 间距稍微调小一点，防止挤 */
}

/* --------------- 歌词区域样式 ------------------- */
.lyrics-wrapper {
    margin-top: 15px;
    height: 120px; /* 歌词显示区域的高度 */
    overflow: hidden; /* 隐藏超出的部分 */
    position: relative;
    text-align: center;
    /* 蒙版：上下边缘渐隐效果 */
    mask-image: linear-gradient(to bottom, transparent 0%, black 15%, black 85%, transparent 100%);
    -webkit-mask-image: linear-gradient(to bottom, transparent 0%, black 15%, black 85%, transparent 100%);
}

#lyrics-list {
    list-style: none;
    padding: 0;
    margin: 0;
    transition: transform 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94); /* 平滑滚动动画 */
}

#lyrics-list li {
    line-height: 24px; /* 每一行的高度，JS计算滚动时会用到 */
    font-size: 13px;
    color: #999; /* 普通歌词颜色 */
    transition: all 0.3s;
    padding: 2px 0;
}

/* 高亮当前行 */
#lyrics-list li.active {
    color: #333; /* 高亮颜色 */
    font-weight: bold;
    font-size: 15px; /* 高亮字体放大 */
    transform: scale(1.05);
}