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. 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

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

              
                <header id="top_nav" class="top_nav">
  <div class="primary">
    <div class="grid-container">
      <div class="grid-x align-middle top">
        <div class="cell large-auto large-shrink">
          <div class="grid-x">
            <div class="icon_tray">
              <a href="#!"><i class="fab fa-facebook-f"></i></a>
              <a href="#!"><i class="fab fa-twitter"></i></a>
              <a href="#!"><i class="fab fa-linkedin-in"></i></a>
              <a href="#!"><i class="fab fa-youtube"></i></a>
              <a href="#!"><i class="fab fa-instagram"></i></a>
            </div>
            <div class="link_tray">
              <a href="!#">News</a> |
              <a href="!#">Blog</a> |
              <a href="!#">Register</a> |
              <a href="!#">Login</a> |
              <a href="!#">Search</a>
            </div>
          </div>
        </div>
      </div>
      <div class="grid-x align-middle bot">
        <div class="cell large-auto">
          <div class="mg_logo">
            <img src="https://i.imgur.com/ZlBVYgr.png" alt="Multiplying Good Logo">
          </div>
        </div>
        <div class="cell large-shrink">
          <ul class="dropdown menu" data-dropdown-menu>
            <li class="menuitem">
              <a href="#" class="menu_parent">Why Service?</a>
            </li>
            <li class="menuitem">
              <a href="#" class="menu_parent">What We Do</a>
              <ul class="menu variable_long submenu three-col">
                <li>
                  <div>
                    <span class="menu_cat">Youth Programs</span>
                    <span class="menu_subcat"><a href="">Youth Service Recognition</a></span>
                    <span class="menu_subcat"><a href="">Youth Leadership Training</a></span>
                    <span class="menu_subcat"><a href="">Students in Action</a></span>
                    <span class="menu_subcat"><a href="">Lead 360</a></span>
                  </div>
                </li>
                <li>
                  <div>
                    <span class="menu_cat">Programs For Organizations</span>
                    <span class="menu_subcat"><a href="">Champions Nominations Process</a></span>
                  </div>
                </li>
                <li>
                  <div>
                    <span class="menu_cat">Media Partnerships</span>
                    <span class="menu_subcat"><a href="">Media Nominations Process</a></span>
                  </div>
                </li>
                <li>
                  <div>
                    <span class="menu_cat">Jefferson Awards</span>
                    <span class="menu_subcat"><a href="">Jefferson Awards Nominations</a></span>
                    <span class="menu_subcat"><a href="">Attend Awards Ceremony</a></span>
                    <span class="menu_subcat"><a href="">Become Event Sponsor</a></span>
                    <span class="menu_subcat"><a href="">For Current Nominees</a></span>
                    <span class="menu_subcat"><a href="">For Past Award Winners</a></span>
                  </div> 
                </li>
              </ul>
            </li>
            <li class="menuitem">
              <a href="#" class="menu_parent">How To Get Involved</a>
              <ul class="menu variable_normal">
                <li>
                  <div>
                    <span class="menu_cat">Donate</span>
                    <span class="menu_subcat"><a href="">Give once</a></span>
                    <span class="menu_subcat"><a href="">Give Monthly</a></span>
                  </div>
                </li>
                <li><div><span class="menu_cat">Attend or Sponsor Event</span></div></li>
                <li><div><span class="menu_cat">Become A Sponsor</span></div></li>
                <li><div><span class="menu_cat">Shop</span></div></li>
              </ul>
            </li>
            <li class="menuitem">
              <a href="#" class="menu_parent">Who We Are</a>
              <ul class="menu variable_normal">
                <li>
                  <div>
                    <span class="menu_cat">Team</span>
                    <span class="menu_subcat"><a href="">Staff</a></span>
                    <span class="menu_subcat"><a href="">Board of Governors</a></span>
                    <span class="menu_subcat"><a href="">Board of Selectors</a></span>
                    <span class="menu_subcat"><a href="">Thing Big Team</a></span>
                  </div>
                  <div><span class="menu_cat">Our Communities</a></div>
                  <div><span class="menu_cat">Financials</a></div>
                  <div><span class="menu_cat">Contact</a></div>
                </li>
              </ul>
            </li>
            <a href="about.html" class="button orange_button">Donate</a>
            <a href="about.html" class="button white_button">Nominate</a>
          </ul>
          <div class="mg_logo mobile">
            <img src="https://i.imgur.com/ZlBVYgr.png" alt="Multiplying Good Logo">
          </div>
          <div class="cell small-6 medium-8 large-9 text-right mobile_options_container">
            <div class="menu_toggle">
              <div class="menu button"></div>
            </div>
          </div>
        </div>
        
      </div>
    </div>
  </div>
    <!-- ///// MOBILE NAV ////// -->
  <div class="grid-container mobile_nav" id="mobile_nav">
    <div class="grid-x align-middle shrink">
      <div class="cell small-12">
        <ul class="drilldown menu" id="drilldown" data-drilldown data-parent-link="true">
          <li>
            <a href="#" class="fas fa-angle-right"><span>Why Service?</span></a>
          </li>
          <li>
            <a href="#" class="fas fa-angle-right"><span>What We Do</span></a>
            <ul class="menu">
              <li><a href="/individual_article.html">Youth Programs</a></li>
              <li><a href="/individual_event.html">Programs for Organizations</a></li>
              <li><a href="/investigator_detail.html">Media Partnership</a></li>
              <li>
                <a href="#" class="fas fa-angle-right"><span>Jefferson Awards</span></a>
                <ul class="menu">
                  <li><a href="/individual_article.html" class="menu-child">JA 1</a></li>
                  <li><a href="/individual_event.html" class="menu-child">JA2</a></li>
                  <li><a href="/investigator_detail.html" class="menu-child">JA3</a></li>
                  <li>
                    <a href="#" class="fas fa-angle-right"><span>Next Level</span></a>
                    <ul class="menu">
                      <li><a href="/individual_article.html" class="menu-child">JA 1</a></li>
                      <li><a href="/individual_event.html" class="menu-child">JA2</a></li>
                      <li><a href="/investigator_detail.html" class="menu-child">JA3</a></li>
                  </li>
                </ul>
              </li>
            </ul>
          </li>
          <li>
            <a href="#" class="fas fa-angle-right"><span>How To Get Involved</span></a>
          </li>
          <div class="cell social_media_container">
            <!--        --------------        -->
            <!--     BOTTOM AREA LOCATION     -->
            <!--        --------------        -->
          </div>
        </ul>
      </div>
    </div>
  </div>
<!-- ///// END MOBILE NAV ////// -->
</header> 
              
            
!

CSS

              
                // https://codepen.io/paulkmiller/pen/YVGaVQ?editors=0110
// Small + Medium
@mixin bp($point) {
  @if $point == small {
    @media (min-width: 0em) and (max-width: 63.9375em) {
      @content;
    }
  }
   @else if $point == large {
    @media (min-width: 63.999em) {
      @content;
    }
  } 
}

body {
  background: teal;
}

a.orange_button {
  width: 112px;
  height: 37px;
  background: #fa8e1f;
  font-weight: bold;
  border-radius: 5px;
}

a.white_button {
  width: 112px;
  height: 37px;
  background: #fff;
  font-weight: bold;
  color: #123e7f;
  border: 2px solid #123e7f;
  border-radius: 5px;
}

.top_nav {
  height: 94px;
  background: #fff;
  padding: 5px 0px;
}

.top_nav .mg_logo {
  margin-top: -5px;
}
.top_nav .grid-x.top {
  padding-bottom: 10px;
}

.top_nav .grid-x.bot {
  margin-top: -1px;
}

.top_nav .align-middle.top {
  justify-content: flex-end;
}

.top_nav .cell.large-shrink {
  padding-bottom: 5px;
}

.dropdown.menu .cell.large.auto {
  background: #002541;
  padding: 0.7rem 0;
  position: relative;
}

.top_nav .icon_tray {
  margin-left: 20px;
}

.top_nav .link_tray {
  font-family: ff-tisa-sans-web-pro;
  font-weight: 500;
  color: #123e7f;
  margin-left: 15px;
}

.top_nav .link_tray a {
  font-family: ff-tisa-sans-web-pro;
  color: #123e7f;
  font-size: 0.85rem;
  font-weight: 500;
  margin: 0 4px;
}

.top_nav i.fab {
  font-size: 0.6rem;
  color: #fff;
  background: #123e7f;
  border-radius: 50%;
  padding: 0px;
  margin: 0 6px;
  height: 19px;
  width: 19px;
  text-align: center;
  vertical-align: middle;
  line-height: 1.2rem;
}

.top_nav i.fab.fa-instagram {
  font-weight: bold;
}

.top_nav i.fab.fa-linkedin-in {
  padding-left: 1px;
}

.top_nav .bot ul.dropdown li a.menu_parent {
  font-family: ff-tisa-sans-web-pro;
  padding: 11px 11px;
  font-weight: 500;
  color: #123e7f;
}

.top_nav .bot ul.dropdown li a.menu_parent:hover {
  color: #3ab1d7;
}

.top_nav .bot li.menuitem {
  position: relative;
}

.top_nav .bot li.menuitem::after {
  content: "";
  display: none;
  position: absolute;
  bottom: -13px;
  left: 7.5%;
  height: 6px;
  width: 85%;
  background: #3ab1d7;
}

.top_nav .bot li.menuitem:hover::after {
  display: block;
}

.top_nav .variable_long {
  min-width: 732px;
}

.top_nav .variable_long .cell.large.auto:nth-child(-n + 2)::after {
  content: "";
  display: block;
  position: absolute;
  right: 0;
  top: 10%;
  width: 3px;
  height: 80%;
  background: #00427d;
}

.top_nav .variable_normal {
  min-width: 250px;
}

.top_nav .bot ul.dropdown li span.menu_cat,
.top_nav .bot ul.dropdown li a.menu_subcat {
  color: #fff;
  font-weight: bold;
  display: block;
}

.top_nav .bot ul.dropdown li span.menu_cat {
  display: block;
  line-height: 1.3rem;
  padding: 0.7rem 1rem;
  text-transform: uppercase;
  font-family: ff-tisa-sans-web-pro;
  font-size: 1.3rem;
  letter-spacing: 2px;
  margin-bottom: -10px;
}

.top_nav .bot ul.dropdown li span.menu_subcat {
  font-family: ff-tisa-sans-web-pro;
  color: #fff;
  display: block;
  padding: 8px 27px;
}

.top_nav .bot ul.dropdown li span.menu_subcat a {
  line-height: 1.2rem;
  font-size: 0.9rem;
}

.top_nav .bot ul.dropdown .variable_long li:nth-child(n + 2) {
  margin-top: 20px;
}

.top_nav .bot .dropdown.menu li a::after {
  content: none;
}

.top_nav .bot a.button {
  margin: 0px 0px 0px 20px;
  padding: 0.7rem 1rem;
  line-height: 0.8rem;
}

.top_nav .dropdown.menu > li.opens-right > .is-dropdown-submenu {
  margin-top: 13px;
  left: 50%;
  transform: translateX(-50%);
}

.top_nav .dropdown.menu > li.opens-right > .is-dropdown-submenu {
  background: #022d56;
  border: none;
  columns: 1;
  &.two-col {
    columns: 2;
      &:after {
      content: '';
      display: block;
      width: 2px;
      height: 90%;
      background: #0964AF;
      position: absolute;
      left: 50%;
      top: 5%;
    }
  }
  &.three-col {
    columns: 3;
      &:before {
      content: '';
      display: block;
      width: 2px;
      height: 90%;
      background: #0964AF;
      position: absolute;
      left: 33%;
      top: 5%;
    }
      &:after {
      content: '';
      display: block;
      width: 2px;
      height: 90%;
      background: #0964AF;
      position: absolute;
      left: 66%;
      top: 5%;
    }
  }
  > li {
    break-inside: avoid-column;
    -webkit-column-break-inside: avoid;
  }
}

.top_nav .dropdown .is-dropdown-submenu a {
  padding-bottom: 0;
  padding-top: 0;
  color: #fff;
}

.top_nav {
  @include bp(small) {
    padding: 20px 0;
    height: 65px;
    .primary {
      padding: 0 10px;
    }
  }
  @include bp(large) {
    padding: 5px 0px;
    height: 94px;
  }
}

.mg_logo.mobile {
  @include bp(small) { display: flex; float: left; }
  @include bp(large) { display: none; }
}

.primary .top, 
.primary .bot .large-shrink .dropdown.menu, 
.primary .mg_logo:not(.mobile){
  @include bp(small) { display: none; }
  @include bp(large) { display: flex; }
}

.mobile_options_container {
  @include bp(small) { display: block; }
  @include bp(large) { display: none; }
  .menu_toggle {
    float: right;
    cursor: pointer;
    .menu.button {
      font-family: ff-tisa-sans-web-pro;
      font-weight: 700;
      color: #003d81;
      min-height: 38px;
      min-width: 55px;
      background: #fff;
      padding: 10px 5px;
      margin: -5px 0 0 0;
      border: 3px solid #003d81;
      border-radius: 7px;
      &::before{
        content:'Menu';
      }
      &.on::before {
        content:'Close'
      }
    }
  }
}

.mobile_nav {
  height: calc(100vh - 65px);
  width: 100vw;
  overflow-y: auto;
  position: relative;
  background: #fff;
  visibility: hidden;
  opacity: 0;
  transform: translateY(-100%);
  transition: all 0.5s cubic-bezier(0.8, 0, 0.2, 1) 0s,
    visibility 0s linear 0.3s, z-index 0s cubic-bezier(0.8, 0, 0.2, 1);
  z-index: 0;
  padding: 0px;

  &.open {
    visibility: visible;
    opacity: 1;
    z-index: 1;
    transform: translateY(0%);
    transition-delay: 0s, 0s, 0.3s;
    margin-top: -1px;
  }
  .js-drilldown-back {
    &:before {
      font-family: "FontAwesome";
      content: "\f104";
      color: #123d83;
      float: left;
      font-weight: bold;
      font-size: 2rem;
      margin-top: -7px;
    }
  }
  // overwrite Foundation's built-in inline-width for drilldown
  &#mobile_nav > .grid-x > .cell > .is-drilldown {
    max-width: 100% !important;
  }
  &#mobile_nav { z-index: -1; }
    > .grid-x
    > .cell
    > .is-drilldown
    .drilldown
    .is-drilldown-submenu.is-closing {
    -webkit-transform: translateX(5%);
    -ms-transform: translateX(5%);
    transform: translateX(5%);
  }
  .drilldown.menu li {
    font-family: ff-tisa-sans-web-pro;
    padding: 1rem 2rem;
    border-bottom: 1px solid #e5e5e5;
    width: 100%;
    a {
      background: #fff;
      color: #123d83;
      margin: 0;
      @include bp(xxsmall) {
        padding-right: 0px;
      }
      &.fas::before {
        float: right;
        color: #123d83;
        font-size: 2rem;
        margin-top: -7px;
        @include bp(xxmedium) {
          transform: translateX(-15px);
        }
        @include bp(xxsmall) {
          transform: translateX(0);
        }
      }
      span {
        font-family: ff-tisa-sans-web-pro, "Helvetica Neue", Helvetica, Roboto, Arial, sans-serif;
        color: #123d83;
      }
    }
    ul {
      background: #fff;
      &.submenu {
        height: calc(100vh - 80px);
        background: #fff;
      }
      a {
        color: #123d83;
        background: #fff;
        font-weight: 700;
        &.is-submenu-parent-item {
          background: #fff;
        }
      }
      li {
        background: #fff;
        &.is-submenu-parent-item {
          background: #fff;
          a.fas {
            background: #fff;
            span {
              color: #123d83;
            }
          }
        }
        &.is-submenu-item.is-drilldown-submenu-item:not(.is-submenu-parent-item) {
          background: #fff;
          border-bottom: 1px solid rgba(0, 0, 0, 0.3);
          a {
            background: #fff;
            color: #123d83;
            font-weight: 700;
            &.menu-child{
              font-weight: 500;
              padding-left: 35px;
            }
            span {
              color: #123d83;
            }
          }
          li.js-drilldown-back a {
            background: #fff;
            color: #123d83;
          }
          li.is-submenu-parent-item a {
            // background: #ccc;
          }
        }
      }
    }
    &:not(.is-drilldown-submenu-parent) {
      .fas:before {
        display: none;
      }
    }
    &.is-drilldown-submenu-parent {
      a:after, a:before {
        border: none;
      }
    }
  }
  .social_media_container {
    float: left;
    margin-top: 2rem;
    padding: 1rem 2.5rem;
    .language {
      float: left;
      a {
        padding: 5px;
        background: transparent;
        color: #123d83;
      }
    }
    .social_media {
      display: inline-block;
      margin: 0;
      padding: 0;
      float: right;
      li {
        display: inline-block;
        margin: 0 15px;
        padding: 0;
        width: auto;
        border-bottom: 0px;
        @include bp(xxsmall) {
          margin: 0 5px;
        }
      }
      a {
        display: inline-block;
        background-color: transparent;
        background-repeat: no-repeat;
        background-position: 50% 50%;
        background-size: 15px 15px;
        vertical-align: top;
        @include bp(small) {
          height: 15px;
          width: 25px;
        }
        @include bp(medium) {
          height: 15px;
          width: 25px;
        }
        &.icon-email {
          background-image: url("../img/email.png");
          background-size: contain;
          background-repeat: no-repeat;
          background-position: center center;
        }
        &.icon-facebook {
          background-image: url("../img/facebook.png");
          background-size: contain;
          background-repeat: no-repeat;
          background-position: center center;
        }
        &.icon-twitter {
          background-image: url("../img/twitter.png");
          background-size: contain;
          background-repeat: no-repeat;
          background-position: center center;
        }
        &.icon-youtube {
          background-image: url("../img/youtube.png");
          background-size: contain;
          background-repeat: no-repeat;
          background-position: center center;
        }
        &.icon-email,
        &.icon-facebook,
        &.icon-twitter,
        &.icon-youtube {
          @include bp(small) {
            padding: 0;
            vertical-align: middle;
          }
          @include bp(medium) {
            padding: 0.7rem 1rem;
          }
        }
        > span {
          display: none;
        }
      }
    }
  }
}
              
            
!

JS

              
                $(document).foundation();
 // mobile menu toggle
  $('.menu_toggle').click(function(e){
  $('.menu_toggle .menu.button').toggleClass('on');
  $('.svg_menu_toggle').toggleClass('open');
  $('.mobile_nav').toggleClass('open');
});
              
            
!
999px

Console