Snippets: CSS

Embed Responsive YouTube Videos

First, the CSS: .youtube-video { aspect-ratio: 16 / 9; width: 100%; } Then add the class to the iframe embed code: <iframe class="youtube-video" src="https://www.youtube.com/embed/xxxxxx" title="YouTube video [...]
CSS, Responsive, Video | Type: CSS

Fixing Fixed Header Problems

html body { position:static !important; } /*fixes many(!) issues caused by fixed header*/ .anchor::before { display: block; content: " "; margin-top: -75px; height: 75px; visibility: hidden; [...]
CSS | Type: CSS

Full-width Responsive Autoplay Video Slider

This is an autoplay video slider. It's a lot like the single full-width video, but with an additional container to hold the video slides and jQuery to make it slide.
ACF, CSS, jQuery, PHP, Video | Type: Javascript

Full-width Responsive Autoplay Video with Text Overlay

This is a single, autoplay video hero that takes the place of an image slider, most often included on a homepage. Text is overlaid on the video, allowing messaging and a link to another page related to the message.
ACF, CSS, PHP, Video | Type: CSS

Gravity Forms Ready Classes

Add classes to GF form fields; these are the most commonly used, but look at the others also.
CSS, Forms | Type: CSS

Proportional scaling of a container

There is more detail at the reference link for complex containers. .parent { height: 0; padding-bottom: 56.25%; /* 16:9 */ position: relative; } .child { position: [...]
CSS | Type: CSS