/* 基础变量定义 */
zezeplayer {
  --bg: #202020;
  --color: white;
  --controls:#000;
  --btn: #444;
  --btn-hover: #666;
  --progress-bar: #7b7b7b;
  --progress: #487cbb;
}

zezeplayer.sky {
  --bg: #5981b1;
  --color: white;
  --controls:#5981b1;
  --btn: #365475;
  --btn-hover: #15273c;
  --progress-bar: #365475;
  --progress: #9ac1f0;
}

zezeplayer.pink {
  --bg: #ae4c9d;
  --color: white;
  --controls:#ae4c9d;
  --btn: #dcaed1;
  --btn-hover: #cc92c1;
  --progress-bar: #e2b6d5;
  --progress: #f5e7ef;
}

/* 播放器基础样式 */
zezeplayer {
  font-family: 'Segoe UI', 'Microsoft Yahei', 'PingFang SC', Helvetica, STHeiti, 'LiHei Pro', Serif, Arial;
  display: block;
  width: 100%;
  min-height: 55px;
  margin: 10px auto;
  border-radius: 4px;
  color: var(--color);
  overflow: hidden;
  text-indent: 0;
  background: var(--bg);
  box-shadow: 0 0 15px gray;
  position: relative;
  font-size: 14px;
}

/* 加载状态 */
zezeplayer loading:after {
  content: " Loading ";
  position: absolute;
  z-index: 1;
  inset: 0;
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 12px;
}

/* 隐藏原生元素 */
zezeplayer audio,
zezeplayer lrc,
zezeplayer tlrc {
  display: none;
}

/* 可视化画布 */
zezeplayer canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  max-height: 100%;
  z-index: 9;
}

/* 动漫人物装饰 */
zezeplayer.manbo::before,
zezeplayer.manbo::after {
  position: absolute;
  bottom: 55px;
  content: ' ';
  background-repeat: no-repeat;
  background-image: url(./manbo.webp) !important;
  width: 100px;
  height: 125px;
  z-index: 999;
}

zezeplayer.manbo::after {
  right: 0;
  transform: scaleX(-1);
}

/* 控制栏样式 */
zezeplayer .player-controls {
  position: relative;
  display: flex;
  align-items: center;
  padding: 10px;
  z-index: 10;
  background: var(--controls);
}

/* 按钮通用样式 */
zezeplayer button {
  width: 35px;
  height: 35px;
  border-radius: 50%;
  border: none;
  color: white;
  font-size: 20px;
  cursor: pointer;
  display: flex;
  justify-content: center;
  align-items: center;
  transition-timing-function: linear;
  transition-duration: 200ms;
  background-color: var(--btn);
}

zezeplayer button:hover {
  background-color: var(--btn-hover);
}

zezeplayer button svg {
  width: 28px;
}

/* 歌词按钮样式 */
zezeplayer .lyricoff,zezeplayer .info-button {
  margin-left: 10px;
}

/* 新增：歌曲信息按钮样式 */
zezeplayer .info-button {
  margin-left: 5px;
}

/* 按钮激活状态 */
zezeplayer .lyricoff.active,
zezeplayer .info-button.active {
  background-color: var(--btn-hover);
  box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.3);
}

/* 进度条容器 */
zezeplayer .progress-container {
  flex-grow: 1;
  margin: 0 10px;
  position: relative;
}

/* 进度条样式 */
zezeplayer .progress-bar {
  width: 100%;
  height: 10px;
  background-color: var(--progress-bar);
  cursor: pointer;
}

zezeplayer .progress {
  height: 100%;
  background-color: var(--progress);
  width: 0%;
  position: relative;
}

zezeplayer .progress::after {
  content: ' ';
  position: absolute;
  overflow: hidden;
  background: #fff;
  width: 2px;
  height: 100%;
  right: -1px;
}

zezeplayer .progress-bar:hover .progress::after {
  height: 16px;
  width: 8px;
  top: -3px;
  right: -4px;
  border-radius: 4px;
}

/* 时间显示 */
zezeplayer .time-display {
  text-align: right;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, 'Liberation Mono', 'Courier New', monospace;
  min-width: 45px;
}

/* 歌词容器需要相对定位，让歌曲信息绝对定位生效 */
zezeplayer .lyrics-container {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease;
  padding: 0 10px;
  box-sizing: border-box;
  position: relative; /* 关键：添加相对定位 */
  z-index: 11;
}

zezeplayer .lyrics-container.active {
  max-height: 150px; /* 增加高度以容纳歌曲信息 */
  padding-bottom: 10px;
}


/* 歌词滚动区域 */
zezeplayer .lyrics {
  padding: 50px 0;
  text-align: center;
  transition-duration: 1s;
  min-height: 150px;
  display: block;
  
}

/* 歌词容器渐变遮罩 */
zezeplayer .lyrics-container::after,
zezeplayer .lyrics-container::before {
  position: absolute;
  z-index: 1;
  right: 0;
  left: 0;
  display: block;
  overflow: hidden;
  width: 100%;
  height: 20%;
  content: '.';
  text-indent: 9999px;
  pointer-events: none;
}

zezeplayer .lyrics-container::before {
  top: 0;
  background: linear-gradient(to bottom, var(--bg), transparent);
}

zezeplayer .lyrics-container::after {
  bottom: 0;
  background: linear-gradient(to top, var(--bg), transparent);
}
/* 隐藏歌词容器的渐变遮罩伪元素 */
zezeplayer .lyrics-container.hide-mask::before,
zezeplayer .lyrics-container.hide-mask::after {
  display: none !important;
}
/* 歌词行样式 */
zezeplayer .lyric-line {
  transition: color 1.5s, opacity 1.5s;
  opacity: .2;
  color: #fff;
  text-shadow: 0 0 0;
  min-height: 20px;
  margin: 10px 0;
}

zezeplayer .lyric-line.active {
  opacity: 1;
  text-shadow: #fff 0 0 .5px;
}

/* 歌曲信息样式 - 改为叠加显示 */
zezeplayer .zeplayer_info {
  display: none;
  position: absolute;
  inset: 0;
  background-repeat: no-repeat;
  background-size: 100%;
  background-position: center;
}
.zezeplayer_infobg{
  position: absolute;
  inset: 0;
  backdrop-filter: blur(12px);
  display: flex;
  gap: 10px;
  justify-content: center;
  align-items: center;
  background: rgba(0, 0, 0, .68);
    
}
zezeplayer img.zeplayer_pic {
  width: 90px;
  height: 90px;
  border-radius: 4px;
  object-fit: cover;
  background-image: url('./img/none.webp');
  background-repeat:no-repeat;
  background-size: 100%;
}

zezeplayer .zeplayer_title {
  font-size: 16px;
  font-weight: 600;
}

zezeplayer .zeplayer_author {
  font-size: 12px;
  color: #ccc;
}

/* 适配不同主题的文字颜色 */
zezeplayer.pink .zeplayer_author {
  color: #f0e0eb;
}

zezeplayer.sky .zeplayer_author {
  color: #e0e9f2;
}

@media (min-width:768px){
zezeplayer .lyrics-container.active {
  max-height: 250px; 
}
}