Last active
May 6, 2018 12:47
-
-
Save Xavka/aa17950686787a8ab03b to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
.fullscreen-bg { | |
position: fixed; | |
top: 0; | |
right: 0; | |
bottom: 0; | |
left: 0; | |
overflow: hidden; | |
z-index: -100; | |
} | |
.fullscreen-bg__video { | |
position: absolute; | |
top: 50%; | |
left: 50%; | |
width: auto; | |
height: auto; | |
min-width: 100%; | |
min-height: 100%; | |
-webkit-transform: translate(-50%, -50%); | |
-moz-transform: translate(-50%, -50%); | |
-ms-transform: translate(-50%, -50%); | |
transform: translate(-50%, -50%); | |
} | |
@media (max-width: 767px) { | |
.fullscreen-bg { | |
background: url('http://dev2.slicejack.com/fullscreen-video-demo/img/videoframe.jpg') center center / cover no-repeat; | |
} | |
.fullscreen-bg__video { | |
display: none; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Nice example, i want to overlap with an image, i've tried this, but the image its not coming up