/* WOQUE Rooms 0.39.1 – the recording player (assets/js/wql-player.js). Used in the room, on WOQUE Hub's Library
   item and in the room editor, so it is not prefixed with the room's scope: every rule starts with .wql-player. The
   room's colours (plum, magenta, gold) are written out, so it looks the same everywhere. */
.wql-player { --wql-p: 0%; --wql-b: 0%; box-sizing: border-box; display: grid; gap: 10px; width: 100%; padding: 14px 16px 12px; border-radius: 18px; border: 1px solid #E6DAEA; background: #fff; color: #2E0F38; font-family: inherit; box-shadow: 0 6px 18px -12px rgba(46, 15, 56, 0.35); text-align: left; }
.wql-player *, .wql-player *::before, .wql-player *::after { box-sizing: border-box; }
.wql-player__head { display: flex; align-items: center; gap: 8px; min-width: 0; }
.wql-player__icon { flex: none; font-size: 18px; line-height: 1; }
.wql-player__title { flex: 1; min-width: 0; font-size: 15px; font-weight: 800; line-height: 1.3; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.wql-player__open { flex: none; font-size: 12px; font-weight: 700; color: #A3155F; text-decoration: underline; }
.wql-player__track { display: grid; gap: 4px; }
.wql-player__bar { position: relative; height: 22px; cursor: pointer; touch-action: none; outline: none; border-radius: 999px; }
.wql-player__bar::before { content: ""; position: absolute; left: 0; right: 0; top: 9px; height: 4px; border-radius: 999px; background: #EFE6F2; }
.wql-player__buf, .wql-player__done { position: absolute; left: 0; top: 9px; height: 4px; border-radius: 999px; pointer-events: none; }
.wql-player__buf { width: var(--wql-b); background: #D9C4E1; }
.wql-player__done { width: var(--wql-p); background: #A3155F; }
.wql-player__knob { position: absolute; top: 4px; left: var(--wql-p); width: 14px; height: 14px; margin-left: -7px; border-radius: 50%; background: #A3155F; box-shadow: 0 0 0 3px #fff, 0 2px 6px rgba(46, 15, 56, 0.35); pointer-events: none; transition: transform 0.15s ease; }
.wql-player__bar:focus-visible { box-shadow: 0 0 0 3px #F2B632; }
.wql-player.is-dragging .wql-player__knob, .wql-player__bar:hover .wql-player__knob { transform: scale(1.25); }
.wql-player__times { display: flex; justify-content: space-between; font-size: 12px; font-weight: 600; color: #66546D; font-variant-numeric: tabular-nums; }
.wql-player__row { display: flex; align-items: center; gap: 10px; }
.wql-player__play { position: relative; flex: none; width: 52px; height: 52px; border-radius: 50%; border: 0; padding: 0; background: #A3155F; color: #fff; display: inline-flex; align-items: center; justify-content: center; cursor: pointer; transition: transform 0.2s cubic-bezier(.2, 1.6, .4, 1), background 0.15s ease; }
.wql-player__play:hover { background: #7C0F48; }
.wql-player__play:active { transform: scale(0.9); }
.wql-player__play svg { width: 24px; height: 24px; fill: currentColor; }
.wql-player__play .wql-pi-pause { display: none; }
.wql-player.is-playing .wql-player__play .wql-pi-play { display: none; }
.wql-player.is-playing .wql-player__play .wql-pi-pause { display: inline; }
.wql-player__spin { position: absolute; inset: -4px; border-radius: 50%; border: 3px solid transparent; border-top-color: #F2B632; opacity: 0; pointer-events: none; }
.wql-player.is-loading .wql-player__spin { opacity: 1; animation: wql-player-spin 0.8s linear infinite; }
@keyframes wql-player-spin { to { transform: rotate(360deg); } }
.wql-player__skip { flex: none; width: 44px; height: 44px; border-radius: 50%; border: 0; padding: 0; background: #F6F0F8; color: #2E0F38; display: inline-flex; align-items: center; justify-content: center; cursor: pointer; }
.wql-player__skip:hover { background: #EDE2F1; }
.wql-player__skip svg { width: 26px; height: 26px; fill: currentColor; }
.wql-player__skip svg text { font: 800 7px/1 system-ui, -apple-system, "Segoe UI", sans-serif; fill: currentColor; }
.wql-player__speeds { margin-left: auto; display: inline-flex; padding: 3px; border-radius: 999px; background: #F6F0F8; }
.wql-player__rate { min-width: 40px; min-height: 32px; padding: 0 8px; border: 0; border-radius: 999px; background: transparent; color: #66546D; font: inherit; font-size: 13px; font-weight: 800; cursor: pointer; }
.wql-player__rate[aria-pressed="true"] { background: #2E0F38; color: #fff; }
.wql-player button:focus-visible, .wql-player__open:focus-visible { outline: 3px solid #F2B632; outline-offset: 2px; }
.wql-player__err { margin: 0; padding: 8px 12px; border-radius: 12px; background: #FFF3D6; color: #5B3B00; font-size: 13px; font-weight: 600; line-height: 1.4; }
.wql-player__err[hidden] { display: none; }
.wql-player__retry { margin-left: 4px; padding: 0; border: 0; background: none; color: #A3155F; font: inherit; font-weight: 800; text-decoration: underline; cursor: pointer; }
.wql-player audio { display: none; }
/* Before the script runs: the title and the length only. */
.wql-player:not(.is-ready) { min-height: 74px; }

/* Compact (the room editor): one row of controls over the bar. */
.wql-player[data-compact] { gap: 6px; padding: 10px 12px 8px; border-radius: 14px; box-shadow: none; }
.wql-player[data-compact] .wql-player__title { font-size: 13px; }
.wql-player[data-compact] .wql-player__play { width: 38px; height: 38px; }
.wql-player[data-compact] .wql-player__play svg { width: 18px; height: 18px; }
.wql-player[data-compact] .wql-player__skip { width: 32px; height: 32px; }
.wql-player[data-compact] .wql-player__skip svg { width: 20px; height: 20px; }
.wql-player[data-compact] .wql-player__rate { min-width: 34px; min-height: 26px; font-size: 12px; }

/* Under a WOQUE Hub Library row. */
.wql-player--lib { margin: -2px 0 12px; }

@media (max-width: 420px) {
  .wql-player { padding: 12px 12px 10px; }
  .wql-player__row { gap: 6px; }
  .wql-player__rate { min-width: 34px; padding: 0 6px; }
}
@media (prefers-reduced-motion: reduce) {
  .wql-player__play, .wql-player__knob { transition: none; }
  .wql-player.is-loading .wql-player__spin { animation-duration: 2.4s; }
}
