.player-controls {
  position: absolute; inset: auto 0 0; z-index: 6;
  padding: 36px 20px 14px; border-radius: 0 0 11px 11px;
  background: linear-gradient(transparent,#080b12b3 40%,#080b12ed);
  color: #f1f5f9; opacity: 1; transition: opacity .15s;
}
.video-wrap.controls-idle { cursor: none; }
.video-wrap.controls-idle .player-controls { opacity: 0; pointer-events: none; }
.player-timeline { display: flex; align-items: center; height: 16px; margin-bottom: 7px; }
.player-preview { position: absolute; bottom: calc(100% - 30px); width: 192px; height: 108px; transform: translateX(-50%); border: 1px solid #ffffff26; border-radius: 5px; background: #080b12; box-shadow: 0 6px 22px #0008; pointer-events: none; }
.player-preview::after { content: ""; position: absolute; top: calc(100% + 3px); left: var(--preview-arrow,50%); transform: translateX(-50%); border: 5px solid transparent; border-bottom: 0; border-top-color: var(--pink); }
.player-preview canvas { display: block; width: 100%; height: 100%; border-radius: inherit; }
.player-preview-status { display: grid; place-items: center; height: 100%; color: #94a3b8; font-size: 11px; }
.player-preview-time { position: absolute; bottom: 5px; left: 50%; transform: translateX(-50%); padding: 2px 5px; border-radius: 3px; background: #000b; color: #fff; font: 12px ui-monospace,monospace; font-variant-numeric: tabular-nums; }
.player-volume-feedback { position: absolute; top: 18px; right: 18px; z-index: 6; padding: 7px 10px; border-radius: 6px; color: #fff; background: #080b12c0; font-size: 12px; pointer-events: none; }
#player-progress {
  --played: 0%; --buffered: 0%;
  appearance: none; width: 100%; height: 5px; padding: 0; border: 0; border-radius: 999px; cursor: pointer;
  background: linear-gradient(to right,var(--pink) 0 var(--played),transparent var(--played)),linear-gradient(to right,#ffffff55 0 var(--buffered),#ffffff26 var(--buffered));
}
#player-progress::-webkit-slider-thumb { appearance: none; width: 12px; height: 12px; border-radius: 50%; background: #fff; box-shadow: 0 0 10px #ff658433; }
#player-progress::-moz-range-thumb { width: 12px; height: 12px; border: 0; border-radius: 50%; background: #fff; }
#player-progress:focus-visible { outline: 2px solid var(--cyan); outline-offset: 5px; box-shadow: none; }
.player-controls-row, .player-controls-group { display: flex; align-items: center; gap: 10px; }
.player-controls-row { justify-content: space-between; gap: 16px; }
.player-control { display: grid; place-items: center; flex-shrink: 0; width: 32px; height: 32px; padding: 6px; border-radius: 6px; color: #cbd5e1; background: transparent; font-size: 12px; }
.player-control:hover:not(:disabled) { color: #fff; background: #ffffff14; }
.player-control:disabled { opacity: .4; }
.player-play { color: #fff; }
.player-icon { width: 20px; height: 20px; fill: currentColor; }
.player-time { font-family: ui-monospace,monospace; font-size: 12px; white-space: nowrap; font-variant-numeric: tabular-nums; margin-left: 4px; }
.player-time-divider, #player-time-duration { color: #94a3b8; }
.player-rate { width: auto; height: 32px; padding: 4px 6px; color: #cbd5e1; background: #080b12c0; border-color: #ffffff1a; font-size: 12px; cursor: pointer; }
.player-rate:disabled { opacity: .4; cursor: default; }
.player-rate:focus-visible { outline: 2px solid var(--cyan); outline-offset: 2px; }
.player-danmaku { width: auto; padding: 5px 8px; border: 1px solid #ffffff1a; font-size: 11px; }
.player-danmaku[aria-pressed=true] { color: var(--pink); border-color: #ff658440; }
.player-volume { width: clamp(60px,5vw,100px); height: 4px; padding: 0; border: 0; cursor: pointer; accent-color: var(--pink); }
.player-volume:focus { box-shadow: none; }
.video-wrap:fullscreen .player-controls { border-radius: 0; padding-bottom: 20px; }
.video-wrap:-webkit-full-screen .player-controls { border-radius: 0; padding-bottom: 20px; }
.video-wrap.is-fullscreen .player-controls { border-radius: 0; padding-bottom: 20px; }
@media (prefers-reduced-motion: reduce) {
  .player-controls { transition: none; }
}
