/* The element renders inside the theme's section > .container, like every other
   content element here: width and mobile margin come from that container, so the
   player needs neither a width limit nor a margin of its own (QA finding m2 of
   #70 is covered by the container). */

/* Reserve the 16:9 player space before the iframe loads to prevent layout shift. */
.bunny-video__frame {
    position: relative;
    padding-top: 56.25%;
    height: 0;
}

.bunny-video__frame iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

/* An own preview image is the poster of the player: it fills the same 16:9 box
   and is the surface that starts the video. */
.bunny-video__start {
    position: absolute;
    top: 0;
    left: 0;
    display: block;
    width: 100%;
    height: 100%;
    padding: 0;
    border: 0;
    background: none;
    cursor: pointer;
}

/* The theme switches the focus ring off globally (`:focus { outline: none
   !important; }` in style-vars.css), so this button has to bring its own back -
   it is operable with the keyboard and would otherwise give no feedback at all
   (Codex review, WCAG 2.4.7). */
.bunny-video__start:focus-visible {
    outline: 3px solid #fff !important;
    outline-offset: -6px;
    box-shadow: 0 0 0 3px rgba(0, 0, 0, 0.7);
}

.bunny-video__poster {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.bunny-video__playicon {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 68px;
    height: 68px;
    margin: -34px 0 0 -34px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.6);
}

.bunny-video__playicon::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    margin: -12px 0 0 -7px;
    border-style: solid;
    border-width: 12px 0 12px 20px;
    border-color: transparent transparent transparent #fff;
}
