Background Video.module.css'

CSS
video.fullscreen { 
  position: fixed;
  top: 50%;
  left: 50%;
  min-width: 100%;
  min-height: 100%;
  width: auto;
  height: auto;
  z-index: -100;
  transform: translate(-50%, -50%);
}<video
  src="#defer-loading"
  poster="nice-default.jpg
  autoplay
/>
Source

Also in CSS: