Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
This CSS can be used to style lazy loaded Youtube videos without WordPress. See instructions:
a.lazy-load-youtube {
vertical-align: top;
background: #555;
width: 100%;
max-width: 480px;
height: 270px;
background-size: cover;
text-decoration: none;
color: #ddd;
display: inline-block;
a.lazy-load-youtube:hover {
color: #fff;
.lazy-load-youtube-info {
color: #2c2c29;
padding: 20px 0;
font-size: 21px;
.lazy-load-youtube-div {
border: 3px solid #2c2c29;
background: url(images/play-youtube.png) center center no-repeat;
position: absolute;
opacity: 0.8;
.lazy-load-youtube-div:hover {
opacity: 1;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment