/* Video.js, Simul's theme: the site's green (#32de84), Quicksand, soft glass controls.
   Used by the room player for video and audio files (player.js: rawPlayer). Everything is under
   .vjs-simul so other Video.js players (and future plugins) start from the defaults. */

.video-js.vjs-simul {
    --vjs-accent: #32de84;
    --vjs-accent-deep: #1f9d5c;
    --vjs-text: #ffffff;
    --vjs-track: rgba(255, 255, 255, 0.22);
    --vjs-buffer: rgba(255, 255, 255, 0.38);
    --vjs-menu: rgba(20, 22, 26, 0.94);
    font-family: "Quicksand", sans-serif;
    font-weight: 700;
    font-size: 12px;
    color: var(--vjs-text);
    background-color: #000;
}

/* --- the big play button: a round green button, centred ------------------------------------ */
.vjs-simul .vjs-big-play-button {
    top: 50%;
    left: 50%;
    width: 72px;
    height: 72px;
    margin: 0;
    transform: translate(-50%, -50%);
    border: 0;
    border-radius: 50%;
    background-color: var(--vjs-accent);
    color: #0f1a14;
    line-height: 72px;
    font-size: 44px;
    box-shadow: 0 8px 28px rgba(0, 0, 0, 0.45), 0 0 0 6px rgba(50, 222, 132, 0.18);
    transition: transform 0.18s ease, box-shadow 0.18s ease, background-color 0.18s ease;
}

.vjs-simul:hover .vjs-big-play-button,
.vjs-simul .vjs-big-play-button:focus {
    background-color: var(--vjs-accent);
    transform: translate(-50%, -50%) scale(1.08);
    box-shadow: 0 10px 32px rgba(0, 0, 0, 0.5), 0 0 0 10px rgba(50, 222, 132, 0.22);
}

.vjs-simul .vjs-big-play-button .vjs-icon-placeholder:before {
    line-height: 72px;
}

/* --- the control bar: a fade from the bottom, not a solid strip ---------------------------- */
.vjs-simul .vjs-control-bar {
    height: 3.6em;
    padding: 0 0.6em;
    align-items: center;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.82), rgba(0, 0, 0, 0.45) 60%, rgba(0, 0, 0, 0));
}

.vjs-simul .vjs-control {
    width: 3.2em;
    color: var(--vjs-text);
    transition: color 0.15s ease;
}

.vjs-simul .vjs-control:hover,
.vjs-simul .vjs-control:focus-visible {
    color: var(--vjs-accent);
    text-shadow: 0 0 10px rgba(50, 222, 132, 0.55);
}

.vjs-simul .vjs-button > .vjs-icon-placeholder:before {
    font-size: 1.9em;
    line-height: 1.85;
}

/* --- the progress bar: thin, thicker on hover, with a round handle ------------------------- */
.vjs-simul .vjs-progress-control {
    position: absolute;
    left: 0.9em;
    right: 0.9em;
    top: -0.6em;
    width: auto;
    height: 1.2em;
    min-width: 0;
}

.vjs-simul .vjs-progress-control .vjs-progress-holder {
    margin: 0;
    height: 4px;
    border-radius: 999px;
    background-color: var(--vjs-track);
    transition: height 0.15s ease;
}

.vjs-simul .vjs-progress-control:hover .vjs-progress-holder {
    height: 7px;
    font-size: inherit;
}

.vjs-simul .vjs-load-progress,
.vjs-simul .vjs-load-progress div {
    border-radius: 999px;
    background: var(--vjs-buffer);
}

.vjs-simul .vjs-play-progress {
    border-radius: 999px;
    background-color: var(--vjs-accent);
    box-shadow: 0 0 10px rgba(50, 222, 132, 0.6);
}

.vjs-simul .vjs-play-progress:before {
    content: "";
    position: absolute;
    top: 50%;
    right: -7px;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: #fff;
    border: 3px solid var(--vjs-accent);
    box-sizing: border-box;
    transform: translateY(-50%) scale(0);
    transition: transform 0.15s ease;
}

.vjs-simul .vjs-progress-control:hover .vjs-play-progress:before {
    transform: translateY(-50%) scale(1);
}

/* the time tooltips over the progress bar (and the volume's): 10px, the site's font */
.vjs-simul .vjs-time-tooltip,
.vjs-simul .vjs-progress-control:hover .vjs-time-tooltip,
.vjs-simul .vjs-mouse-display .vjs-time-tooltip,
.vjs-simul .vjs-volume-tooltip {
    padding: 3px 7px;
    border-radius: 6px;
    background-color: var(--vjs-menu);
    color: var(--vjs-text);
    font-family: "Quicksand", sans-serif;
    font-size: 10px;
    font-weight: 700;
    line-height: 1.3;
    white-space: nowrap;
}

.vjs-simul .vjs-time-tooltip { top: -2.8em; }

.vjs-simul .vjs-mouse-display {
    background-color: var(--vjs-text);
}

/* --- time: "1:23 / 4:56", like the old player ---------------------------------------------- */
.vjs-simul .vjs-time-control {
    display: block;
    min-width: 0;
    width: auto;
    padding: 0 0.15em;
    font-variant-numeric: tabular-nums;
    line-height: 3.6em;
}

.vjs-simul .vjs-current-time,
.vjs-simul .vjs-time-divider,
.vjs-simul .vjs-duration {
    display: block;
}

.vjs-simul .vjs-time-divider {
    min-width: 0.8em;
    padding: 0 0.1em;
    opacity: 0.7;
}

.vjs-simul .vjs-duration { opacity: 0.8; }
.vjs-simul .vjs-remaining-time { display: none; }

/* the live badge (streams played as files) */
.vjs-simul .vjs-live-control,
.vjs-simul .vjs-seek-to-live-control {
    line-height: 3.6em;
}

/* --- volume: the slider always showing (Video.js's hover-to-open one kept closing as you
   reached for it), with the same round handle as the progress bar --------------------------- */
.vjs-simul .vjs-volume-panel.vjs-volume-panel-horizontal,
.vjs-simul .vjs-volume-panel.vjs-volume-panel-horizontal.vjs-hover,
.vjs-simul .vjs-volume-panel.vjs-volume-panel-horizontal:active {
    width: auto !important;
    transition: none !important;
}

.vjs-simul .vjs-volume-panel .vjs-volume-control.vjs-volume-horizontal,
.vjs-simul .vjs-volume-panel.vjs-hover .vjs-volume-control.vjs-volume-horizontal,
.vjs-simul .vjs-volume-panel .vjs-volume-control.vjs-slider-active.vjs-volume-horizontal {
    /* !important: Video.js resizes it in several hover/active states, which moved the bar
       under the pointer on the first click */
    position: relative !important;
    width: 5.5em !important;
    height: 100% !important;
    margin: 0 0.6em 0 0 !important;
    align-items: center;
    visibility: visible !important;
    opacity: 1 !important;
    transition: none !important;
}

.vjs-simul .vjs-volume-bar.vjs-slider-horizontal {
    width: 100%;
    height: 4px;
    margin: 0 0.4em;
    border-radius: 999px;
    background-color: var(--vjs-track);
}

.vjs-simul .vjs-slider-horizontal .vjs-volume-level {
    height: 100%;
    border-radius: 999px;
    background-color: var(--vjs-accent);
}

.vjs-simul .vjs-volume-level:before {
    content: "";
    top: 50%;
    right: -6px;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #fff;
    border: 2px solid var(--vjs-accent);
    box-sizing: border-box;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.4);
    transform: translateY(-50%);
    line-height: normal;
    font-size: 0;
}

.vjs-simul .vjs-volume-control:hover .vjs-volume-level:before,
.vjs-simul .vjs-volume-control.vjs-slider-active .vjs-volume-level:before {
    transform: translateY(-50%) scale(1.2);
}

.vjs-simul .vjs-volume-control .vjs-mouse-display { display: none; }

.vjs-simul .vjs-slider:focus {
    box-shadow: 0 0 0 2px rgba(50, 222, 132, 0.6);
    text-shadow: none;
}

/* --- fullscreen and picture-in-picture: the bottom right corner (the spacer takes the gap) --- */
.vjs-simul .vjs-custom-control-spacer {
    display: flex;
    flex: auto;
}

/* --- menus (speed, captions, quality plugins later) ----------------------------------------- */
.vjs-simul .vjs-menu-button-popup .vjs-menu .vjs-menu-content {
    bottom: 1em;
    padding: 0.35em;
    border-radius: 10px;
    background-color: var(--vjs-menu);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.45);
}

.vjs-simul .vjs-menu li {
    padding: 0.4em 0.6em;
    border-radius: 6px;
    font-size: 1.1em;
    text-transform: none;
}

.vjs-simul .vjs-menu li.vjs-menu-item:hover,
.vjs-simul .vjs-menu li.vjs-menu-item:focus {
    background-color: rgba(50, 222, 132, 0.16);
    color: var(--vjs-accent);
}

.vjs-simul .vjs-menu li.vjs-selected,
.vjs-simul .vjs-menu li.vjs-selected:hover,
.vjs-simul .vjs-menu li.vjs-selected:focus {
    background-color: var(--vjs-accent);
    color: #0f1a14;
}

/* --- loading, errors and the text track display --------------------------------------------- */
.vjs-simul .vjs-loading-spinner {
    border-color: rgba(50, 222, 132, 0.25);
}

.vjs-simul .vjs-loading-spinner:before,
.vjs-simul .vjs-loading-spinner:after {
    border-top-color: var(--vjs-accent);
}

.vjs-simul .vjs-error-display {
    background: radial-gradient(circle at center, rgba(20, 22, 26, 0.9), rgba(0, 0, 0, 0.95));
}

.vjs-simul .vjs-error-display .vjs-modal-dialog-content {
    font-family: inherit;
    font-size: 1.3em;
    line-height: 1.5;
}

.vjs-simul .vjs-error-display:before {
    color: #e5484d;
    text-shadow: none;
}

.vjs-simul .vjs-text-track-display .vjs-text-track-cue > div {
    border-radius: 4px;
    padding: 0 0.3em;
}

/* --- audio files: a music backdrop, and the controls always showing ----------------------- */
.vjs-simul.vjs-simul-audio {
    background:
        radial-gradient(circle at 50% 42%, rgba(50, 222, 132, 0.22), transparent 55%),
        linear-gradient(160deg, #14161a, #0b0d10);
}

.vjs-simul.vjs-simul-audio .vjs-tech {
    opacity: 0; /* nothing to see: the backdrop shows through */
}

.vjs-simul.vjs-simul-audio:before {
    content: "music_note";
    font-family: "Material Symbols Outlined";
    position: absolute;
    top: 42%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 96px;
    line-height: 1;
    color: rgba(50, 222, 132, 0.85);
    text-shadow: 0 0 30px rgba(50, 222, 132, 0.45);
    pointer-events: none;
}

.vjs-simul.vjs-simul-audio.vjs-playing:before {
    animation: vjs-simul-pulse 2.4s ease-in-out infinite;
}

@keyframes vjs-simul-pulse {
    50% { transform: translate(-50%, -50%) scale(1.08); }
}

.vjs-simul.vjs-simul-audio .vjs-big-play-button {
    top: 72%;
}

.vjs-simul.vjs-simul-audio .vjs-control-bar,
.vjs-simul.vjs-simul-audio.vjs-user-inactive.vjs-playing .vjs-control-bar {
    opacity: 1;
    visibility: visible;
}

@media (prefers-reduced-motion: reduce) {
    .vjs-simul.vjs-simul-audio.vjs-playing:before { animation: none; }
    .vjs-simul .vjs-big-play-button,
    .vjs-simul .vjs-progress-holder,
    .vjs-simul .vjs-play-progress:before { transition: none; }
}
