Pen Settings

HTML

CSS

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. You can use the CSS from another Pen by using it's URL and the proper URL extention.

+ add another resource

JavaScript

Babel includes JSX processing.

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

Packages

Add Packages

Search for and use JavaScript packages from npm here. By selecting a package, an import statement will be added to the top of the JavaScript editor for this package.

Behavior

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.

HTML

              
                <div class="nav-wrapper">
  <div class="topbar">
    
    <a class="nav-trigger nav-trigger--offcanvas">
      <div class="navicon"></div>
    </a>
 
    <div class="topbar__logo">
      <a class="logo">
        <img src="https://www.leadingedgesafety.co.uk/images/logo.svg" 
             alt="Leading Edge Logo">
      </a>
    </div>
    
    <nav class="topbar__main-nav">
      <ul>
        <li><a href="home"><i class="material-icons">home</i></a></li>
        <li><a class="has-subnav" href="working-at-height">Woking At Height</a></li>
        <li><a class="has-subnav" href="height-rescue">Rescue</a></li>
        <li><a class="has-subnav" href="tool-tethering">Tool Tethering</a></li>
        <li><a class="has-subnav" href="shop">Shop</a></li>
        <li><a class="has-subnav" href="more">More +</a></li>
        <li><a href="contact"><i class="material-icons">message</i> Contact</a></li>
      </ul>
    </nav>
    
    <div class="topbar__icon-menu">
      <ul>      
        <li>
          <a class="logo"><i class="material-icons">today</i></a>
        </li>
        <li>
          <a class="icon"><i class="material-icons">shopping_cart</i></a>
      </li>
      </ul>
    </div>
    
    <div class="topbar__quick-menu">
       <a class="nav-trigger--shop-menu nav-trigger">Shop</a>
       <a class="nav-trigger--courses-menu nav-trigger">Courses</a>
     </div>
  </div>
  
  <div class="subnavs">
    <nav class="subnavs__subnav" data-menu="working-at-height">
      <ul>
        <li>
          <a href="#!">Overview</a>     
        </li>
        <li class="has-dropdown">
          <a href="#!">Training</a>
          <ul>
            <li><a href="">About Training</a></li>
            <li class="subnav-divider"></li>
            <li><a href="">Level 1 Operatives</a></li>
            <li><a href="">Level 2 Managers</a></li>
            <li><a href="">Height Rescue</a></li>
            <li><a href="">PPE Inspection</a></li>
            <li><a href="">Ladder Height Safety</a></li>
            <li class="subnav-divider"></li>
            <li><a href="">Syllabus</a></li>
            <li><a href="">Reviews</a></li>        
          </ul>
        </li>
        <li class="has-dropdown">
          <a href="#!">Products</a>
          <ul>
            <li><a href="">link</a></li>
            <li><a href="">link</a></li>
            <li><a href="">link</a></li>
            <li><a href="">link</a></li>
          </ul>
        </li>
        <li class="has-dropdown">
          <a href="#!">Products</a>
          <ul>
            <li><a href="">link</a></li>
            <li><a href="">link</a></li>
            <li><a href="">link</a></li>
            <li><a href="">link</a></li>
          </ul>
        </li>
        <li><a href="">Training Center</a></li>
        <li><a href="">Open-Enrolment</a></li>
      </ul>
    </nav>
    
    <nav class="subnavs__subnav" data-menu="height-rescue">
      <ul>
        <li><a href="working-at-height">Home</a></li>
        <li><a href="">Woking At Height</a></li>
        <li><a href="">Rescue</a></li>
        <li><a href="">Shop</a></li>
        <li><a href="">More</a></li>
        <li><a href="">Contact</a></li>
      </ul>
    </nav>
    
    <nav class="subnavs__subnav" data-menu="shop">
      <ul>
        <li><a href="working-at-height"><i class="nav-icon nav-icon-restraint"></i><span>Storefront</span></a></li>
        <li><a href=""><i class="nav-icon nav-icon-restraint"></i><span>Harnesses</span></a></li>
        <li><a href=""><i class="nav-icon nav-icon-restraint"></i><span>Lanyards</span></a></li>
        <li><a href=""><i class="nav-icon nav-icon-restraint"></i><span>Restraint</span></a></li>
        <li><a href=""><i class="nav-icon nav-icon-restraint"></i><span>Lifelines</span></a></li>
        <li><a href=""><i class="nav-icon nav-icon-restraint"></i><span>Inertia Reels</span></a></li>
        <li><a href=""><i class="nav-icon nav-icon-restraint"></i><span>Tethers</span></a></li>
        <li><a href=""><i class="nav-icon nav-icon-restraint"></i><span>Confined Space</span></a></li>
        <li><a href=""><i class="nav-icon nav-icon-restraint"></i><span>Anchorage</span></a></li>
        <li><a href=""><i class="nav-icon nav-icon-restraint"></i><span>Rescue</span></span></a></li>
        <li><a href=""><i class="nav-icon nav-icon-restraint"></i><span>Search</span></a></li>
      </ul>
    </nav>
    
    <nav class="subnavs__subnav" data-menu="tool-tethering">
      <ul>
        <li><a href="working-at-height">Home</a></li>
        <li><a href="">Woking At Height</a></li>
        <li><a href="">Rescue</a></li>
        <li><a href="">Shop</a></li>
        <li><a href="">More</a></li>
        <li><a href="">Contact</a></li>
      </ul>
    </nav>
    
    <nav class="subnavs__subnav" data-menu="more">
      <ul>
        <li><a href="working-at-height">Home</a></li>
        <li><a href="">Woking At Height</a></li>
        <li><a href="">Rescue</a></li>
        <li><a href="">Shop</a></li>
        <li><a href="">More</a></li>
        <li><a href="">Contact</a></li>
      </ul>
    </nav>
    
  </div>
</div>

<!--Off Canvas  -->
<div id="menu--offcanvas__main" class="mobile-menu-container">
  <div class="mobile-menu-container__inner">
    <nav class="mobile-menu">
      <ul class="toggle-menu">    
        <li>
          <a class="has-dropdown" href="working-at-height">Working At Height</a>
          <ul>
            <li><a href="">Overview</a></li>
            <li><a href="">Products</a></li>
            <li>
              <a href="#!" class="has-dropdown">Training</a>
              <ul>
                <li><a>About Training</a></li>
                <li><a>Syllabus</a></li>
                <li><a>Aftercare</a></li>
                <li><a>Training Reviews</a></li>   
                <li><a href="#!">Training Center</a></li>  
                <li><a href="#!">Open-Enrolment</a></li>
              </ul>
            </li>
            <li>
              <a href="#!" class="has-dropdown">Courses</a>
              <ul>
                <li><a>Level 1 Operatives</a></li>
                <li><a>Level 1+ Supervisors</a></li>
                <li><a>Level 2 Managers</a></li>
                <li><a>PPE inspection</a></li>
              </ul>
            </li>       
          </ul>
        </li>     
        <li>
          <a class="has-dropdown" href="working-at-height">Tool Tethering</a>
          <ul>
            <li><a href="/tool-tethering/overview">Overview</a></li>
            <li><a href="/tool-tethering/overview">Products</a></li>
            <li><a href="/tool-tethering/overview">Testing</a></li>
            <li><a href="/tool-tethering/overview">Manufacturing</a></li>
            <li>
              <a href="#!" class="has-dropdown">Support</a>
              <ul>
                <li><a>Tether Guide</a></li>
                <li><a>Tool Safety Roadmap</a></li>
                <li><a>Free Consultation</a></li>
              </ul>
            </li>             
          </ul>
        </li>
        <li>
          <a class="has-dropdown" href="">Height Rescue</a>
          <ul>
            <li><a>Overview</a></li>
            <li><a>Why Rescue?</a></li>
            <li><a>Products</a></li>
            <li><a>Training</a></li>
          </ul>
        </li>
        <li><a>About</a></li>
        <li><a>Blog</a></li>
        <li><a>Downloads</a></li>
        <li><a>Contact</a></li>
      </ul>
    </nav>
  </div>
</div>

<div id="menu--offcanvas__shop" class="mobile-menu-container">
  <div class="mobile-menu-container__inner">
    <div class="shop-buttons">
      <div class="shop-button shop-button--left"><a href=""><i class="material-icons">shopping_basket</i>My Bag</a></div>
      <div class="shop-button shop-button--right"><a href=""><i class="material-icons">payment</i>Checkout</a></div>
    </div>
    <nav class="mobile-menu toggle-menu">   
      <ul>    
        <li>   
          <a href="#!" class="has-dropdown active">Height Safety</a>
          <ul class="icon-menu">
            <li><a href=""><i class="nav-icon nav-icon--restraint"></i>Kits</a></li>
            <li><a href=""><i class="nav-icon nav-icon--restraint"></i>Harnesses</a></li>
            <li><a href=""><i class="nav-icon nav-icon--restraint"></i>Lanyards</a></li>
            <li><a href=""><i class="nav-icon nav-icon--restraint"></i>Restraint</a></li>
            <li><a href=""><i class="nav-icon nav-icon--restraint"></i>Lifelines</a></li>
            <li><a href=""><i class="nav-icon nav-icon--restraint"></i>Inertia Reels</a></li>
            <li><a href=""><i class="nav-icon nav-icon--restraint"></i>Anchorage</a></li>
            <li><a href=""><i class="nav-icon nav-icon--restraint"></i>Connectors</a></li>
          </ul>
        </li>
        <li>
          <a href="#!" class="has-dropdown">Height Rescue</a>
          <ul class="icon-menu">
            <li><a><i class="nav-icon nav-icon--restraint"></i>Systems</a></li>
            <li><a><i class="nav-icon nav-icon--restraint"></i>Kits</a></li>
            <li><a><i class="nav-icon nav-icon--restraint"></i>Rescue Blocks</a></li>
            <li><a><i class="nav-icon nav-icon--restraint"></i>Accessories</a></li>
          </ul>
        </li>       
        <li>
         <li>
            <a href="#!" class="has-dropdown">Tool Tethering</a>
            <ul class="icon-menu">
              <li><a><i class="nav-icon nav-icon--restraint"></i>Tethers</a></li>
              <li><a><i class="nav-icon nav-icon--restraint"></i>Lanyards</a></li>
              <li><a><i class="nav-icon nav-icon--restraint"></i>Wristbands</a></li>
              <li><a><i class="nav-icon nav-icon--restraint"></i>Holsters</a></li>
              <li><a><i class="nav-icon nav-icon--restraint"></i>Belts</a></li>
              <!--<li><a><i class="nav-icon nav-icon--restraint"></i>Bags</a></li>-->
              <li class="dummy">poi</li>
              
            </ul>
          </li>
        </li>      
      </ul>
    </nav>
  </div>
</div>

<div id="menu--offcanvas__courses" class="mobile-menu-container">
  <div class="mobile-menu-container__inner">
    <nav class="mobile-menu">
      <ul> 
        <li class="mobile-menu__catagory">Working At Height</li>
        <li><a>Basic Awareness</a></li>
        <li><a>Level 1 Operatives</a></li>
        <li><a>Level 1+ Supervisors</a></li>
        <li><a>Level 2 Managers</a></li>
        <li class="mobile-menu__catagory">Height Rescue</li>
        <li><a>Descent Rescue</a></li>
        <li><a>Winch Rescue</a></li>
        <li><a>Haul Rescue</a></li>    
        <li><a>Multi-Method Rescue</a></li>
        <li class="mobile-menu__catagory">Comptetend Person</li>
        <li><a>Tool Tethering</a></li>
        <li><a>PPE Inspection</a></li>
        <li><a>Ladder Height Safety</a></li>
      </ul>
    </nav>
  </div>
</div>
              
            
!

CSS

              
                * { box-sizing: border-box; }

ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.clearfix::after {
  content: '';
  display: table;
  clear: both;
}

html { -webkit-text-size-adjust: 100%; }

body { 
  font-size: 62.5%;
  font-family: 'proxima nova', helvetica, sans-serif;
  background: gainsboro;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}



@mixin clearfix {
  &:after {
    content: "";
    display: table;
    clear: both;
  }
}


$tablet-width: 768px;
$small-desktop-width: 960px;
$desktop-width: 1024px;
$large-desktop-width: 1200px;
$landscape-tablet-width: 1367px;


@mixin tablet {
  @media (min-width: $tablet-width)  {
    @content;
  }
}

@mixin landscape-tablet {
  @media (min-width: $landscape-tablet-width) {
    @content;
  }
}

@mixin small-desktop {
  @media (min-width: $small-desktop-width) {
    @content;
  }
}

@mixin desktop {
  @media (min-width: $desktop-width) {
    @content;
  }
}

@mixin large-desktop {
  @media (min-width: $large-desktop-width) {
    @content;
  }
}

//////////////////////////////////////////////

$color--primary:                      #ff4500;

$white:                               #fff;
$navColor--topbarBg:                  #1d2831;
$navColor--working-at-height:         #dc3711;
$navColor--tool-tethering:            #275482;
$navColor--height-rescue:             #b52236;
$navColor--shop:                      #152129;
$navColor--more:                      #54606b;

$nav--font-size:                      1.3em;
$nav--height:                         48px;
$nav--icon-size:                      21px;
$nav--icon-gutter:                    15px;

$topbar--font-color:                  #d0d0d0;
$topbar--link-padding-desktop:        0 16px;
$topbar--link-padding-mobile:         0 12px;
$topbar--lateral-container-width:     15%;
$topbar--padding:                     0 1.2em;
$topbar--logo-padding:                8px 0;

$subnav--link-gutter:                 0 5px;
$subnav--shop-height:                 76px;

$mobile-nav-background: #3e454e;
$mobile-nav-border: 1px solid rgba(0, 0, 0, 0.14);


///////////////////////////////////////////////////////////////////////////////////////

%flexbox                              { display: flex; }
%flexbox--align-center                { align-items: center; }
%topbar-outer-container               { flex-basis: $topbar--lateral-container-width; }

///////////////////////////////////////////////////////////////////////////////////////

.nav-wrapper {
  position: fixed;
  width: 100%;
  z-index: 10;
  
  a {
    transition: all .4s ease;
    vertical-align: middle;
    display: block;
    text-decoration: none;
    letter-spacing:1px;
    font-weight: 800;
    text-transform: uppercase;
    font-size: 1.2em;   
   // @include small-desktop { font-size: 0em }
    @include desktop { font-size: 1.3em }
    @include large-desktop { font-size: $nav--font-size; }
     
     
    &:hover { color: $white; }
     
    .material-icons { 
      margin-top: -1px;
      vertical-align: middle;
      font-size: $nav--icon-size;
      display: inline-block;
      line-height: $nav--height 
    }
  }
}

.topbar {
  @extend %flexbox;
  position: relative;
  padding: $topbar--padding;
  align-items: center;
  justify-content: space-between;
  height: $nav--height;
  background: $navColor--topbarBg;
  width: 100%;
  z-index: 10;
  overflow: hidden;
 
  a {
    color: $topbar--font-color;
    
    &.active { color: $white; }
    
    &:not(.icon):not(.logo):not(.nav-trigger) {  
      line-height: $nav--height;        
      padding: $topbar--link-padding-mobile;
      
      @include large-desktop {
        padding: $topbar--link-padding-desktop;
      }
      
      //------------------------------------------------------------------------//
      // Darken or Lighten the Subnav buttons Hover and Active states           //
      //------------------------------------------------------------------------//
      
      @mixin boxShadowEffect($target, $color) {
        &[href="#{$target}"] { 
          box-shadow: inset 0 0 $color; 
          &.active {
            box-shadow: inset 0 ( -$nav--height ) $color; 
          }
        }
      }
      
      @include boxShadowEffect('working-at-height', $navColor--working-at-height);
      @include boxShadowEffect('height-rescue', $navColor--height-rescue);
      @include boxShadowEffect('tool-tethering', $navColor--tool-tethering);
      @include boxShadowEffect('shop', $navColor--shop);
      @include boxShadowEffect('more', $navColor--more);
      
      //------------------------------------------------------------------------//
           
    }
  }
  
  &__logo {
    @include landscape-tablet { flex-basis: $topbar--lateral-container-width; }
    
    img {
      height: $nav--height;
      padding: $topbar--logo-padding;
      max-width: 100%;
    }
  }
  
  &__main-nav {  
    display: none;
    @include small-desktop { display: block; }
    
    ul { 
      flex-wrap: nowrap;
      display: flex; 
    }  
    
    li {
      transition: box-shadow .4s ease;
      box-shadow: inset 0 0 lighten( $navColor--topbarBg, 5%);
      &:hover { box-shadow: inset 0 ( -$nav--height ) lighten( $navColor--topbarBg, 10%); }   
    }
  }
  
  &__icon-menu { 
    @extend %flexbox;
    @include landscape-tablet { flex-basis: $topbar--lateral-container-width; }
    justify-content: flex-end;  
    
    ul { 
      @extend %flexbox;   
      list-style: none;
    }  

    li:first-child > a { padding-right: $nav--icon-gutter; }
    
  }  
  
  &__quick-menu {
    position: relative;
    min-width: 126px;
    padding: 8px 0;
    height: 48px;
    transition: all .3s ease-in-out;
    margin-left: 1.2em;
    transform: translateZ();
    backface-visibility: hidden;
    
    .mobile-menu-is-open & {
      opacity: 0;
      margin-right: -126px
    }
    
    
    a {
      background: #3e454e;
      border-radius: 3px;
      font-size: 1em;
      height: 32px;
      line-height: 32px;
      overflow: hidden;
      padding: 0 8px;
      position: absolute;
      text-align: center;
      white-space: nowrap;
      z-index: 1;
    }
  }
}

.subnavs {
  z-index: 8;
  position: relative;
  height: $nav--height;
  
  nav { 
    @extend %flexbox; 
    justify-content: center;
    position: absolute;
    width: 100%;
    height: $nav--height;
    transform: translate3d( 0 , -100%, 0 );
    transition: transform .4s ease;     
     
    &.active { transform: translate3d( 0 , 0, 0 ); }
    
    // Subnav Menu
    & > ul {  
      @extend %flexbox; 
      @extend %flexbox--align-center; 
      
      & > li { 
        height: 100%; 
        margin: $subnav--link-gutter;
        @extend %flexbox; 
        @extend %flexbox--align-center;
             
        & > a {             
          color: $white;
          height: 12px;
          line-height: 14px;
          padding: 8px 12px;
          border-radius: 3px;
          box-sizing: initial;      
        }
      }
    } //
    
    // Dropdown Menu
    & .has-dropdown {    
      position: relative; 
           
      & > a {
        padding: 8px 8px 8px 12px;
        &::after {
          content: 'keyboard_arrow_down';
          font-family: 'Material Icons';
          margin-left: 3px;
          vertical-align: middle;
          font-size: 15px;
          text-transform: none;           
        }
      }
             
      & > ul { 
        display: none;
        position: absolute;
        min-width: 260px;
        top: 100%;
        padding: 15px 0;
        background: $white;
        left: -11px;
        border-radius: 0 0 3px 3px;
        box-shadow: 0 10px 15px rgba(0, 0, 0, 0.08);
      }
            
      & > ul > li > a {
        color: #888;
        padding: 12px 20px 12px 30px;

        &:hover { 
          color: #444;
          background: darken($white, 5%); 
        }
      }  
      
      .subnav-divider { 
        height: 1px; 
        background: darken($white, 5%);
        margin: 10px 0;
      }
      
    } //
    
    //--------------------------------------------------------------------------//
    // Darken or Lighten the Subnav buttons Hover and Active states             //
    //--------------------------------------------------------------------------//
    
    @mixin subnavLinkBg($target, $color) { 
      &[data-menu="#{$target}"] {
        background: $color;
          a {
            &:hover { 
              background: darken($color, 10%);
            }
            &.active {
              background: lighten($color, 10%);
            }
         }
       }
    }
    
    @include subnavLinkBg("working-at-height", $navColor--working-at-height);
    @include subnavLinkBg("height-rescue", $navColor--height-rescue);
    @include subnavLinkBg("more", $navColor--more);
    @include subnavLinkBg("tool-tethering", $navColor--tool-tethering);
    
    &[data-menu="shop"] { background: $navColor--shop; }
       
    //--------------------------------------------------------------------------//
    // Fade-in subnav links when subnav is active with incremental delay        //
    //--------------------------------------------------------------------------//
    
    & > ul > li { 
      opacity: 0;
      transition: opacity .4s ease;
    }  
    
    &.active > ul > li { 
      opacity: 1; 
      @for $i from 1 to 12 { 
        $timeBase: $i / 16;
        &:nth-child(#{$i}) { transition-delay: $timeBase + .01 + s; }
      }  
    }
    
    //--------------------------------------------------------------------------//
    
    &[data-menu="shop"] {
      height: $subnav--shop-height;
      a {
        display: flex;
        flex-direction: column;
        justify-content: center;
        height: $subnav--shop-height;
        box-sizing: border-box; 
        white-space: nowrap;
        font-size: 0.9em;
        padding: 0 5px;
        @include desktop { 
          font-size: 1em; 
          padding: 0 8px;
        }
        @include large-desktop { 
          padding: 0 12px;
        }
      }
    }  
  } 
}

/////////////////////////////////

.navicon {
  margin-top: 14px;
  position: relative;
  width: 28px;
  max-width:100%;
  height: 3px;
  background: #E7E6DD;
  transition: .2s;
  border-radius: 2.5rem;
  pointer-events: none;

  &:before, &:after {
    display: block;
    content: "";
    height: 3px;
    width: 100%;
    background: #E7E6DD;
    position: absolute;
    z-index: -1;
    transition: .2s;
    //border-radius: 1rem;
  }

  &:before { top: 8px; }
  &:after { top: -8px; }
}


.mobile-menu-is-open { 
  .navicon {
    background: transparent;  
    &:before,
    &:after { top: 0; }
    &:before { transform: rotate(-45deg); }
    &:after  { transform: rotate(45deg);  }
  }
}

/////////////////////////////////

.nav-icon {

  background: gray;
  margin: 2px auto 7px auto;
  display: block;

  .subnavs & {  
    height: 36px;
    width: 36px;
  }
  
  .icon-menu & {height:40px;width:40px;}
  
  
  &.nav-icon-restraint {
    
  }
  
}

////////////////////////////////////
//       Quick-menu Triggers      //
////////////////////////////////////

%quick-menu-trigger-open {
  padding-right: 40px;
  width: 127px;
  z-index: 10;
  background: $color--primary;
  color: $white;
}

%quick-menu-trigger-closed {
  transform: scale(0);
  z-index: 0;
}

@mixin reset {
  transform: translateX(0); 
  opacity: 1;
}

.nav-trigger {
  &:not(.nav-trigger--offcanvas)::after { 
    content: '';
    background-image: url('https://dl.dropboxusercontent.com/u/15563902/icon--close.svg');
    background-size: 12px 12px;
    background-repeat: no-repeat;
    position: absolute;
    top: 0;
    right: 0;
    bottom:0;
    width: 32px;
    background-color: rgba(0,0,0,0.1);
    transform: translateX(100%);
    transition: .3s ease;
    background-position: center center;
    opacity: 0;
  }
  
  &--shop-menu {
    width: 48px;
    left: 0;
    
    .shop-menu-is-open & {
      @extend %quick-menu-trigger-open;
      &::after { @include reset }  
    }
    
    .courses-menu-is-open & { @extend %quick-menu-trigger-closed; }
  }

  &--courses-menu {
    width: 70px;
    text-align: center;
    right: 0;
    
    .shop-menu-is-open & { @extend %quick-menu-trigger-closed; }
    
    .courses-menu-is-open & {
      @extend %quick-menu-trigger-open;
      &::after { @include reset } 
    }
  }

  &--offcanvas {
    display: none;
    max-width: 100%;
    display: inline-block;
    cursor: pointer;
    user-select: none;
    opacity: .8;
    padding: 8px 0;
    position: relative;
    width: 32px;
    overflow: hidden;
    height: 48px;
    margin-right: 8px;

    .shop-menu-is-open &, 
    .courses-menu-is-open & { 
      opacity: 0;
      margin-left: -32px;
    }
  }
  
}


.mobile-menu-container {
  text-align: center;
  top: 0;
  overflow-y: auto;
  transition: all .3s ease;
  position: fixed;
  height: calc(100% - 48px);
  margin-top: 48px;
  width: 100%;
  background: #343b44;
  z-index: 9;
  -webkit-overflow-scrolling: touch;
  
  &__inner {
    max-width: 960px;
    margin: 0 auto;   
    min-height: calc(100% + 1px);   
    padding: 2em;
    .no-touch & { min-height: 100%; } 
  }
}

#menu--offcanvas {
  
  &__main {
    .mobile-menu-is-open & { transform: translate3d(0, 0, 0); }
    transform: translate3d(-100%, 0, 0);
  }

  &__shop {
    .shop-menu-is-open & { transform: translate3d(0, 0, 0); }
    transform: translate3d(0, calc(-100% - 48px), 0);
  }

  &__courses {
    .courses-menu-is-open & { transform: translate3d(0, 0, 0); }
    transform: translate3d(0, calc(-100% - 48px), 0);
  }
  
}



  .shop-buttons  {
    @include clearfix;
    .shop-button {
      width: 50%;
      display: inline-block;
      float: left; 
    
      i {    
        position: absolute;
        left: 0;
        top: 0;
        width: 43px;
        line-height: 43px;
        background: rgba(0,0,0,0.1);
        color: rgba(255,255,255,0.2);
      }
      a { 
        font-weight: 700;
        text-transform: uppercase;
        line-height:43px;
        text-decoration: none;
        color: $white;
        position:relative;
        display: block; 
        box-shadow: 0 2px 0 #30383e;
        font-size: 1em;
        border-radius: 3px;
        padding-left: 53px;
        overflow:hidden;
        white-space: nowrap;
      }
      &--left {   
        a { border-top: 1px solid lighten($mobile-nav-background,4%); background: lighten($mobile-nav-background, 2%); }
        padding: 0 .5em 1em 0;
      }
      
      &--right {
        
        a { border-top: 1px solid lighten($color--primary,4%); background: $color--primary; }
        padding: 0 0 1em .5em;     
      }    
    }  
  } 


.mobile-menu {
  
  background: $mobile-nav-background;
  border-radius: 3px;
  border-top: 1px solid lighten($mobile-nav-background, 6%);
  border-left: 1px solid darken($mobile-nav-background, 6%);
  border-bottom: 1px solid darken($mobile-nav-background, 10%);
  border-right: 1px solid darken($mobile-nav-background, 6%);
  
  a { 
    position: relative;
    &.has-dropdown::after {     
      content: url(https://dl.dropboxusercontent.com/u/15563902/icon-down-arrow-white.svg);
      position: absolute;
      top: 50%;
      right: 2em;
      width: 15px;
      opacity: .2;
      transform: translateY(-50%);
    }
  }
  
  
  &__catagory {  
    
    &:not(:first-child) { border-top: 1px solid lighten($mobile-nav-background, 6%); }
    
    text-transform: uppercase;
    font-weight: 700;
    display: block;
    padding: 1.7em 0;
    color: rgba(255, 255, 255, 0.3);
    font-size: 1em;
    letter-spacing: 2px;
    background: lighten($mobile-nav-background, 3%);
  }
  
  .icon-menu {  
    @include clearfix; 
    
    li {
      float: left; 
      width: 50%;
      @include tablet { 
        width: 25%; 
        float: left; 
      } 
    }
    
    li:nth-child(odd) { border-right: $mobile-nav-border; }
    
    @include tablet {
      //li:nth-child(odd) { border-right: initial; }
      li:not(:nth-child(4n+4)) { border-right: $mobile-nav-border; }
    }
  }
 
  
  & > ul > li:first-child > a { border-top: none; }
  
  ul {  
    a { border-top: $mobile-nav-border; }   
    & > li > ul > li {
      background: darken( $mobile-nav-background, 2% );
      & > ul > li { background: darken( $mobile-nav-background, 4% ); }
    }
  }
    
  a {    
    display: block;
    padding: 1.5em 0;  
    text-decoration: none; 
    color: white;
    font-size: 1.2em;
    font-size: 1.2em;
    font-weight: 700;
    @include tablet { font-size: 1.6em; }  
  }
}

html.no-scroll { overflow-x: hidden; }

              
            
!

JS

              
                var navigation = (function() {
  
  var $body                = $('body');

  var $navWrapper          = $('.nav-wrapper');
  var $topbar              = $('.topbar');
  var $mainNav             = $topbar.find('nav');
  var $mainNavLink         = $topbar.find('a');
  var $iconMenu            = $topbar.find('.topbar__icon-menu');
  var $quickMenu           = $topbar.find('.topbar__quick-menu');
  
  var $subnavs             = $('.subnavs');
  var $subnav              = $subnavs.find('nav');
  var $subnavLi            = $subnav.find('> ul > li');
  var $subnavLink          = $subnav.find('> ul > li > a');
  
  var $dropdown            = $('.has-dropdown ul');
  
  var $offCanvasTrigger    = $('.nav-trigger.nav-trigger--offcanvas');
  var $shopMenuTrigger     = $('.nav-trigger--shop-menu');
  var $coursesMenuTrigger  = $('.nav-trigger--courses-menu');
  
  function addActiveClass(e) {
    var $this = $(e.target);
    $mainNav.find('a').not( $this ).removeClass('active');
    $this.addClass('active');
  }

  function swapSubmenu(e, closeTimeout) { 
    var $this = $(e.target);
    var $subnavTarget = $this.attr('href');
    var $currentMenu = $subnavs.find("[data-menu='" + $subnavTarget + "']");
    
    // if the clicked link is already active
    // dont do anything
    if ( !$currentMenu.hasClass('active') ) {
      
      // append current menu in front of other menus
      $currentMenu.appendTo($subnavs);
      
      // add active class after append is complete
      // ** css transition callback might be better?
      setTimeout(function() {     
        $currentMenu.addClass('active');
      }, 20);  
      
      // remove old menu
      setTimeout(function() {     
        $subnav.not($currentMenu).removeClass('active');
      }, closeTimeout);
        
    } 
  } 
  
  // close all dropdowns in the sub navigtion
  function closeDropdown() {
    $subnav.find('.has-dropdown ul').slideUp(200);
    $subnav.find('a').removeClass('active');
  }
 
  function toggleDropdown(e) {
   
    var $this = $(e.target);
    if ( $dropdown.not( $(e.target).siblings() ).is(":visible") ) {
      closeDropdown(); 
      $this.toggleClass('active');
      $this.next().slideToggle(200);       
    } else {
      $this.toggleClass('active');
      $this.next().slideToggle(200);
    }
    
    e.preventDefault();
    e.stopPropagation();
  } 
  
  function closeMobileDropdowns() {
    $('.has-dropdown').siblings('ul').slideUp(200);
  }
  
  function toggleOpenClass(e) { 
    $(e.target).toggleClass('open');
  }
  
  function toggleBodyClass(bodyClass) {
    $body.toggleClass(bodyClass);
  }
  
  function setUI() {
    // The main nav is only visible on desktop. 
    // If it is visible, hide mobile navigation items.
    // If it is not visible, show mobile navigation items.
    if ( !$mainNav.is(':visible') ){
      $subnavs.hide();  
      $iconMenu.hide();  
      $quickMenu.show();
      $offCanvasTrigger.show();    
    } else {
      $subnavs.show();
      $iconMenu.show();
      $quickMenu.hide();
      $quickMenu.hide();
      $offCanvasTrigger.hide();
      $dropdown.slideUp('fast');
      $subnavLink.removeClass('active');
      closeMobileDropdowns();
      $body.removeClass('mobile-menu-is-open shop-menu-is-open courses-menu-is-open');
    }
  }
  
  function openMobileMenu(menuType) { 
    toggleBodyClass(menuType + '-menu-is-open');  
    $('html').toggleClass('no-scroll');
    closeMobileDropdowns();
  }
  
  // Event Listeners
  $(document).ready(function(){
          
    $mainNav.find('a').click(function(e) {
      if ( $(this).hasClass('has-subnav') ) {
        
        closeDropdown();
        
        // shop submenu has larger height than other submenu's and transitions better without a delay -
        // set 0 transition delay for shop submenu and 400ms for all other submenu's.
        if ( $mainNav.find('a[href="shop"]').hasClass('active') ) {
          addActiveClass(e);
          swapSubmenu(e, 0);
        } else if ( $(e.target).attr('href') !== 'home') {   
          addActiveClass(e);
          swapSubmenu(e, 400);     
        }        
        e.preventDefault();
      }     
    });

    $subnavLink.click( function(e){ 
      toggleDropdown(e);           
    });
    
    // toggle mobile menus when mobile navigation triggers are clicked
    $mainNavLink.click( function(e){
        
      var menu    = 'mobile';
      var shop    = 'shop';
      var courses = 'courses';   
        
      if( e.target === $offCanvasTrigger[0] ) {
        openMobileMenu(menu);
      }
      else if ( e.target === $shopMenuTrigger[0] ) {
        openMobileMenu(shop);
      }   
      else if ( e.target === $coursesMenuTrigger[0] ) {
        openMobileMenu(courses);
      }    
      
      e.stopPropagation();
      
    });
    
    $(window).click( function(e){
      closeDropdown(e); 
    });
    
    // set/reset navigtion items for mobile or 
    // and desktop depending on screen size
    $(window).resize( function(){
      setUI();             
    });
    
    setUI();
    
  });
 
})();

var toggleMenu = (function(e) {
  
  var $toggleMenu = $('.toggle-menu');
  var $toggleMenuLink = $toggleMenu.find('.has-dropdown');
  
  // hide dropdowns on load 
  function hideDropdowns() {
    $toggleMenuLink.siblings().hide();
  }
 
  function toggleMenuItems(e) {
    e.preventDefault();
    $(e.target).next().slideToggle('fast');
  }
  
  function closeSiblingDropdowns(e) {
    $(e.target).parent().siblings().find('a').next().slideUp('fast');
  }
  
  function closeAllDropdowns() {
    $toggleMenuLink.slideUp('fast');
  }
  
  $(document).ready(function(){
    hideDropdowns();
    $toggleMenuLink.click(function(e){
      e.preventDefault;
      $toggleMenuLink.parent().children().find( $('.has-dropdown').next().not( $(e.target).next() )).slideUp('fast');  
      toggleMenuItems(e);
    });
    
    // if top level link is clicked close all other open top level dropdowns
    $toggleMenu.find('> li > a.has-dropdown').click(function(e){
      if( $(e.target).parent().siblings().find('.has-dropdown').next().is(':visible') ) {
        closeSiblingDropdowns(e);
      }   
    });
    
  });
  
})();





              
            
!
999px

Console