Skip to content

Instantly share code, notes, and snippets.

@Renatodeluna
Last active December 13, 2015 17:09
Show Gist options
  • Save Renatodeluna/4945353 to your computer and use it in GitHub Desktop.
Save Renatodeluna/4945353 to your computer and use it in GitHub Desktop.
.video {
position: relative;
padding-bottom: 56.25%; /* 16:9 */
padding-top: 25px;
height: 0;
overflow: hidden;
}
.video > iframe,
.video > object,
.video > 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