Created
March 21, 2022 12:07
-
-
Save 3200pro/338a4be4b562844293261b45629a6785 to your computer and use it in GitHub Desktop.
Vimeo Video Styling
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
.embed-container { | |
--video--width: 1296; | |
--video--height: 540; | |
position: relative; | |
padding-bottom: calc(var(--video--height) / var(--video--width) * 100%); /* 41.66666667% */ | |
overflow: hidden; | |
max-width: 100%; | |
background: black; | |
} | |
.embed-container iframe, | |
.embed-container object, | |
.embed-container embed { | |
position: absolute; | |
top: 0; | |
left: 0; | |
width: 100%; | |
height: 100%; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment