<div class="parent">

    <div><h1>hello</h1></div>

    <div class="video-container">
        <video autoplay muted loop>
            <source src="https://commondatastorage.googleapis.com/gtv-videos-bucket/sample/BigBuckBunny.mp4"
                    type="video/mp4"/>
        </video>
    </div>

</div>

 


.parent {
    display: flex;
    flex-direction: column;

    width: 100vw;
    height: 100vh;

    padding: 2em;
    box-sizing: border-box;

    background-color: red;
}

.video-container {
    position: relative;

    height: 100%;

    background-color: #333333;
}

.parent video {
    position: absolute;

    max-width: 100%;
    max-height: 100%;

    top: 50%;
    left: 50%;
    transform: translateX(-50%) translateY(-50%);

    box-sizing: border-box;
}