/* ============================================================
   音频播放器皮肤（YT 风格）— De finale
   结构：.ap-shell（行/列均可）> audio（隐藏）+ .ap-controls
   ============================================================ */

.ap-shell {
  display: block;
  width: 100%;
  background: linear-gradient(135deg, #ffffff, #f2f5f9);
  border: 1px solid var(--border, #dce3ec);
  border-radius: 12px;
  padding: 12px 14px;
  user-select: none;
  -webkit-user-select: none;
  transition: border-color .15s, background .15s;
}
.ap-shell:hover { border-color: var(--accent, #ae1c28); }

.ap-shell audio { display: none; }

/* ---------- 控制条 ---------- */
.ap-controls {
  display: flex;
  flex-direction: column;
  gap: 6px;
  width: 100%;
}

/* 进度条行 */
.ap-seek {
  position: relative;
  height: 16px;
  display: flex;
  align-items: center;
  cursor: pointer;
}
.ap-seek::before {
  content: "";
  position: absolute;
  left: 0; right: 0;
  height: 4px;
  border-radius: 99px;
  background: rgba(255,255,255,.18);
}
.ap-seek .ap-buf {
  position: absolute;
  left: 0;
  height: 4px;
  border-radius: 99px;
  background: rgba(255,255,255,.30);
  width: 0%;
  pointer-events: none;
}
.ap-seek input {
  -webkit-appearance: none;
  appearance: none;
  position: relative;
  width: 100%;
  height: 16px;
  margin: 0;
  background: transparent;
  cursor: pointer;
  z-index: 2;
}
.ap-seek input::-webkit-slider-runnable-track {
  height: 4px;
  border-radius: 99px;
  background: linear-gradient(to right, #ae1c28 0%, #00838f var(--prog, 0%), transparent var(--prog, 0%));
}
.ap-seek input::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 12px; height: 12px;
  border-radius: 50%;
  background: #ae1c28;
  border: none;
  margin-top: -4px;
  box-shadow: 0 1px 4px rgba(0,0,0,.5);
  opacity: 0;
  transition: opacity .15s;
}
.ap-shell:hover .ap-seek input::-webkit-slider-thumb,
.ap-seek:hover input::-webkit-slider-thumb { opacity: 1; }
.ap-seek input::-moz-range-track { height: 4px; border-radius: 99px; background: transparent; }
.ap-seek input::-moz-range-progress { height: 4px; border-radius: 99px; background: linear-gradient(90deg, #ae1c28, #00838f); }
.ap-seek input::-moz-range-thumb { width: 12px; height: 12px; border-radius: 50%; background: #ae1c28; border: none; }

/* 按钮行 */
.ap-bar {
  display: flex;
  align-items: center;
  gap: 6px;
}
.ap-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 34px;
  height: 32px;
  padding: 0 8px;
  border: none;
  border-radius: 8px;
  background: rgba(255,255,255,.08);
  color: #fff;
  font-size: 14px;
  font-family: inherit;
  cursor: pointer;
  transition: background .15s, transform .1s;
}
.ap-btn:hover { background: rgba(255,255,255,.18); }
.ap-btn:active { transform: scale(.94); }
.ap-btn.ap-on { color: #c62f3b; }
.ap-time {
  font-size: 12.5px;
  color: #cfd5e0;
  font-variant-numeric: tabular-nums;
  margin: 0 6px 0 2px;
  white-space: nowrap;
}
.ap-flex { flex: 1; }

/* 倍速 */
.ap-rate { font-size: 12.5px; font-weight: 700; letter-spacing: .3px; }
.ap-rate:hover { color: #c62f3b; }

/* 触屏设备 */
@media (pointer: coarse) {
  .ap-btn { min-width: 38px; height: 34px; font-size: 14px; padding: 0 6px; }
  .ap-time { font-size: 12px; }
  .ap-rate { font-size: 12px; }
}

/* 紧凑列表样式（thema 详情页用） */
.ap-shell.compact {
  padding: 8px 10px;
  background: rgba(255,255,255,.04);
  border-radius: 10px;
}
.ap-shell.compact .ap-bar { gap: 4px; }
.ap-shell.compact .ap-btn { min-width: 30px; height: 28px; font-size: 12.5px; padding: 0 6px; }
.ap-shell.compact .ap-time { font-size: 11.5px; }
