css Audio - Active file-generic CSS - Active Generic - Active HTML - Active JS - Active SVG - Active Text - Active file-generic Video - Active header Love html icon-new-collection icon-person icon-team numbered-list123 pop-out spinner split-screen star tv

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

You're using npm packages, so we've auto-selected Babel for you here, which we require to process imports and make it all work. If you need to use a different JavaScript preprocessor, remove the packages in the npm tab.

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

Use npm Packages

We can make npm packages available for you to use in your JavaScript. We use webpack to prepare them and make them available to import. We'll also process your JavaScript with Babel.

⚠️ This feature can only be used by logged in users.

Code Indentation

     

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.

HTML Settings

Here you can Sed posuere consectetur est at lobortis. Donec ullamcorper nulla non metus auctor fringilla. Maecenas sed diam eget risus varius blandit sit amet non magna. Donec id elit non mi porta gravida at eget metus. Praesent commodo cursus magna, vel scelerisque nisl consectetur et.

            
              <!-- Start of navigation toggle -->
<input id="navigation-checkbox" class="navigation-checkbox" type="checkbox" />
<label class="navigation-toggle" for="navigation-checkbox">
  <span class="navigation-toggle-icon"></span>
  <span class="navigation-toggle-label">Menu</span>
</label>
<!-- End of navigation toggle -->
<ul class="nav">
  <li><a href="#">Home</a></li>
  <li><a href="#">About</a></li>
  <li><a href="#">Work</a></li>
  <li><a href="#">Contact</a></li>
</ul>

<div class="content">
  <h1>Hello World</h1>
  <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Pellentesque vitae facilisis ligula, eu cursus urna. Morbi maximus tellus nulla, sed tempor sem porttitor ac. Donec odio nisl, finibus non ullamcorper ac, rhoncus eget nisl. Sed vestibulum lacus in risus commodo ullamcorper. Pellentesque aliquam scelerisque lectus vel mollis. Donec blandit in augue non imperdiet. Mauris tincidunt, augue quis viverra auctor, nunc libero porttitor nisi, nec ornare magna dolor sit amet elit. Donec sit amet congue quam. Nam enim diam, consectetur vitae sodales et, condimentum vel ligula.</p>

<p>Quisque elit justo, viverra nec posuere ultrices, tempus et neque. Quisque porttitor pellentesque est, ac rhoncus felis interdum sit amet. Vivamus ullamcorper turpis a scelerisque bibendum. Donec rutrum nibh et mi tempus convallis. Donec nec nisl tristique, facilisis ex eget, gravida felis. Duis et convallis libero. Sed non mi a nulla placerat tristique non ac mi. Class aptent taciti sociosqu ad litora torquent per conubia nostra, per inceptos himenaeos. Sed quam orci, commodo non scelerisque quis, condimentum eget sem. Nulla condimentum dapibus ex, sodales ornare neque lobortis in. Morbi tristique, velit et consequat molestie, elit eros venenatis tortor, ut viverra risus sapien quis magna.</p>
</div>

<div class="footer">
  <p><a href="https://danielhart.co">Daniel Hart</a> &copy; 2018</p>
</div>
            
          
!
            
              // Default colors
$primary-color: #FFFFFF;
$secondary-color: #00B5FF;
$secondary-color-alt: #0C6EE8;

body {
  margin: 0px;
  padding: 0px;
  position: relative;
  background: linear-gradient($secondary-color-alt, $secondary-color);
  font-family: 'Hevetica Neue', Helvetica, Arial, sans-serif;
}

.content {
  color: $primary-color;
  text-align: left;
  padding: 80px;
  
}

.nav {
  position: absolute;
  background: transparent;
  width: 100%;
  list-style: none;
  margin: 0px auto;
  padding: 0px;
  visibility: hidden;
  opacity: 0;
  transition: all 0.4s ease;

  li {
    width: 100%;
    
    a {
      background: #00B5FF;
      color: $primary-color;
      text-decoration: none;
      text-transform: uppercase;
      text-align: center;
      font-weight: 700;
      transition: all 0.7s ease;
      display: block;
      padding: 25px 40px;
      margin-bottom: 2px;

      &:hover {
        background: #ededed;
        color: $secondary-color;
        transition: all 0.7s ease;
      }
    }
  }

  li ul {
    display: none;
  }
}

// Hides Checkbox that will be checked when hamburger is clicked
.navigation-checkbox {
  display: none;
  opacity: 0;
  transition: all 0.7s ease;
}

.navigation-toggle {
  position: relative;
  width: 40px;
  height: 40px;
  margin: 2px auto 23px auto;
  display: block;
  cursor: pointer;
}

.navigation-toggle-label {
  font-weight: bold;
  font-size: 14px;
  color: #ffffff;
  text-align: center;
  display: block;
  text-transform: uppercase;
  position: relative;
  bottom: -20px;
}

.navigation-toggle-icon {
  border-bottom: 6px solid $primary-color;
  padding-top: 17px;
  display: block;
  transition-delay: 0.125s;
  
  &:before, &:after {
    border-top: 6px solid $primary-color;
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    transition-delay: 0s;
    transform-origin: center;
  }
  
  &:before {
    top: 4px;
  }
  
  &:after {
    bottom: 4px;
  }
}

// Menu Toggle Animation X
.navigation-toggle-icon,
.navigation-toggle-icon:before,
.navigation-toggle-icon:after {
  transition-property: transform, border-color;
  transition-duration: 0.25s;
  transition-timing-function: cubic-bezier(0.5, -0.5, 0.5, 1.5);
}

.navigation-checkbox:checked + .navigation-toggle {
  .navigation-toggle-icon {
    transition-delay: 0s;
  }

  .navigation-toggle-icon:before,
  .navigation-toggle-icon:after {
    transition-delay: 0.125s;
  }

  .navigation-toggle-icon:before {
    transform: translateY(13px) rotate(135deg);
  }

  .navigation-toggle-icon {
    border-color: transparent;
  }

  .navigation-toggle-icon:after {
    transform: translateY(-13px) rotate(-135deg);
  }
}

input[type="checkbox"]:checked ~ .nav {
  visibility: visible !important;
  opacity: 1;
  transition: all 0.7s ease;

  li:nth-child(1) {
    animation: staircaseReveal 120ms 0s both;
  }
  li:nth-child(2) {
    animation: staircaseReveal 120ms 120ms both;
  }
  li:nth-child(3) {
    animation: staircaseReveal 120ms 240ms both;
  }
  li:nth-child(4) {
    animation: staircaseReveal 120ms 360ms both;
  }
}
// Reveal Animation for li
@keyframes staircaseReveal {
  0% {
    opacity:0;
    transform:translateX(30px) translateY(-40px)
  }
  100% {
    opacity:1;
    transform:translateX(0) translateY(0)
  }
}

.footer {
  text-align: center;
  background: #E2E2E2;
  padding: 50px;
  
  a {
    color: $secondary-color;
    text-decoration: none;
  }
}
            
          
!
999px
🕑 One or more of the npm packages you are using needs to be built. You're the first person to ever need it! We're building it right now and your preview will start updating again when it's ready.
Loading ..................

Console