/* ==========================================================
   VIDEO EMBED
   One player look for Hospital\VideoEmbed::render(): the Page
   Builder "Video" block and the «Video» field on entity pages.
   ========================================================== */

.video-embed {
    margin: 0;
}

.video-embed--9x16 {
    max-width: 22rem;
    margin-inline: auto;
}

.video-embed__frame {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    border-radius: var(--radius-lg, 0.75rem);
    background: #000;
}

.video-embed--9x16 .video-embed__frame {
    aspect-ratio: 9 / 16;
}

.video-embed__media {
    position: absolute;
    inset: 0;
    display: block;
    width: 100%;
    height: 100%;
    border: 0;
    background: #000;
}

video.video-embed__media {
    object-fit: contain;
}

.video-embed__caption {
    margin-top: var(--space-2, 0.5rem);
    color: var(--text-muted, #6c757d);
    font-size: var(--font-size-helper, 0.8125rem);
    line-height: var(--line-height-body, 1.6);
}

.video-embed--9x16 .video-embed__caption {
    text-align: center;
}

/* Editors only: the link could not be turned into a player. */
.video-embed__notice {
    margin: 0;
    padding: 0.75rem 1rem;
    border: 1px dashed #d63939;
    border-radius: var(--radius-lg, 0.75rem);
    color: #b02a2a;
    font-size: 0.875rem;
    word-break: break-all;
}

/* ---------- Page Builder: video_block ---------- */

.video-block__head {
    margin-bottom: 1.5rem;
}

.video-block__title {
    margin: 0;
    font-weight: var(--font-weight-bold, 700);
}

.video-block__text {
    margin: 0.5rem 0 0;
    color: var(--gray-600, #6c757d);
}

.video-block__player {
    max-width: 56rem;
}

/* ---------- Entity pages ---------- */

.equipment-single__section .video-embed + .equipment-gallery {
    margin-top: 1.5rem;
}
