Pen Settings



CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URL's added here will be added as <link>s in order, and before the CSS in the editor. If you link to another Pen, it will include the CSS from that Pen. If the preprocessor matches, it will attempt to combine them before processing.

+ add another resource


Babel is required to process package imports. If you need a different preprocessor remove all packages first.

Add External Scripts/Pens

Any URL's added here will be added as <script>s in order, and run before the JavaScript in the editor. You can use the URL of any other Pen and it will include the JavaScript from that Pen.

+ add another resource


Save Automatically?

If active, Pens will autosave every 30 seconds after being saved once.

Auto-Updating Preview

If enabled, the preview panel updates automatically as you code. If disabled, use the "Run" button to update.

Format on Save

If enabled, your code will be formatted when you actively save your Pen. Note: your code becomes un-folded during formatting.

Editor Settings

Code Indentation

Want to change your Syntax Highlighting theme, Fonts and more?

Visit your global Editor Settings.


  <div class="content">
  <div class="overlay"></div>
<section class="site">
    <a href="">Page</a>
    <a href="">Page</a>
    <a href="">Page</a>
    <a href="">Page</a>
    <a href="">Page</a>
 <img src="" align="left" >“I invented nothing new. I simply assembled the discoveries of other men behind whom were centuries of work. Had I worked fifty or ten or even five years before, I would have failed. So it is with every new thing. Progress happens when all the factors that make for it are ready, and then it is inevitable. To teach that a comparatively few men are responsible for the greatest forward steps of mankind is the worst sort of nonsense.”

― Henry Ford


                @import url(;
html, body {
  padding: 0;
  margin: 0;
  height: 100%;

html {
  font: 1em/1.5 "Lato", sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizelegibility;

body {
  font-size: 1.3em;

header {
  height: 100%;
  position: relative;
  overflow: hidden;
  background: url( center no-repeat;
  /* Image Credit: */
  background-size: cover;
header .content {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 1;
header h1, header h2 {
  margin: 0;
header h2 {
  text-transform: uppercase;
  margin-top: -.5em;
header hgroup {
  -webkit-transform: translate(-50%, -50%);
  -moz-transform: translate(-50%, -50%);
  -ms-transform: translate(-50%, -50%);
  -o-transform: translate(-50%, -50%);
  transform: translate(-50%, -50%);
  display: inline-block;
  text-align: center;
  position: absolute;
  top: 50%;
  left: 50%;
  color: #fff;
  border: 5px solid #fff;
  padding: .5em 3em;
  background-color: rgba(0, 0, 0, 0.2);
  z-index: 2;
header .overlay {
  position: absolute;
  top: 0;
  right: 0;
  left: 0;
  bottom: 0;
  background:#333 center no-repeat;
  background-size: cover;
  z-index: 0;
  opacity: 0;  -webkit-filter: blur(4px);
.site {
  padding: 20em 0;
  text-align: center;
  background-color: #efefef;
  font-size: .8em;
  color: #444;
.site a {
  color: #666;
  text-decoration: none;
.site a:hover {
  color: #222;

.site nav{
.site nav a{
  padding:10px 30px;
.site nav a:hover{


                //Based on the Scroller function from @sallar
var $content = $('header .content')
  , $blur    = $('header .overlay')
  , wHeight  = $(window).height();

$(window).on('resize', function(){
  wHeight = $(window).height();

window.requestAnimFrame = (function()
  return  window.requestAnimationFrame       ||
          window.webkitRequestAnimationFrame ||
          window.mozRequestAnimationFrame    ||
          function( callback ){
            window.setTimeout(callback, 1000 / 60);

function Scroller()
  this.latestKnownScrollY = 0;
  this.ticking            = false;

Scroller.prototype = {
  init: function() {
    window.addEventListener('scroll', this.onScroll.bind(this), false);

  onScroll: function() {
    this.latestKnownScrollY = window.scrollY;

  requestTick: function() {
    if( !this.ticking ) {
    this.ticking = true;

  update: function() {
    var currentScrollY = this.latestKnownScrollY;
    this.ticking       = false;
    var slowScroll = currentScrollY / 2
      , blurScroll = currentScrollY * 2
      , opaScroll = 1.4 - currentScrollY / 400;
   if(currentScrollY > wHeight)
      'transform'         : 'translateY(' + slowScroll + 'px)',
      '-moz-transform'    : 'translateY(' + slowScroll + 'px)',
      '-webkit-transform' : 'translateY(' + slowScroll + 'px)',
      'opacity' : opaScroll
      'opacity' : blurScroll / wHeight

var scroller = new Scroller();