html, body {
    background-color: rgb(0, 0, 0);
    overflow: hidden;
    width: 100%;
    height: 100%;
    margin: 0;
    padding: 0;
}

canvas {
    width: 100%;
    height: 100%;
}

video {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    height: 100%;
    width: 100%;
    display: block;
    pointer-events: none;
}

.fadeIn {
    -webkit-animation: fade-in 1s forwards ease-out;
    animation: fade-in 1s forwards ease-out;
}

.fadeOut {
    -webkit-animation: fade-out 1s forwards ease-out;
    animation: fade-out 1s forwards ease-out;
}

@keyframes fade-in {
    0% {
        visibility: hidden;
        opacity: 0;
    }
    1% {
        visibility: visible;
        opacity: 0;
    }
    100% {
        visibility: visible;
        opacity: 1;
    }
}

@keyframes fade-out {
    0% {
        visibility: visible;
        opacity: 1;
    }
    99% {
        visibility: visible;
        opacity: 0;
    }
    100% {
        visibility: hidden;
        opacity: 0;
    }
}

video::-webkit-media-controls {
    display: none !important;
}

/* This used to work for the parent element of button divs */

/* But it does not work with newer browsers, the below doesn't hide the play button parent div */

video::-webkit-media-controls-panel {
    display: none!important;
    -webkit-appearance: none;
}

/* Old shadow dom for play button */

video::-webkit-media-controls-play-button {
    display: none!important;
    -webkit-appearance: none;
}

/* New shadow dom for play button */

/* This one works! */

video::-webkit-media-controls-start-playback-button {
    display: none!important;
    -webkit-appearance: none;
}

#content {
    position: relative;
    width: 100%;
    height: 100%;
}

#captions {
    opacity: 0;
    transition: opacity 0.5s ease-in-out;
    -moz-transition: opacity 0.5s ease-in-out;
    -webkit-transition: opacity 0.5s ease-in-out;
    position: absolute;
    color: #fff;
    z-index: 1;
    width: 100%;
    text-align: center;
    background: rgba(0, 0, 0, 0.5);
    padding: 8px 0;
    font-family: Arial, Helvetica, sans-serif;
    font-size: 1.1em;
    line-height: 1.1em;
    pointer-events: none;
}

#captions.fadeIn {
    opacity: 1;
}
