I've successfully gotten a video to properly fit inside a div and fill it completely all the time thanks to this SO answer.
I've modified the code just a bit but I'm stumped as to why this code works.
video
position: absolute
opacity: 0.1
z-index: 0
top: 0px
left: 50%
min-width: 100%
min-height: 100%
right: 0px
margin: auto
width: auto
height: auto
overflow-x: hidden
transform: translateX(-50%)
I don't get what the transform does and how to get it to fix to something other than the top-left corner. I think there's something about the min-
properties that makes this work but I'm not sure.