// main: style.scss

/*--------------------------------------------------------------
# Navigation Menu
--------------------------------------------------------------*/

/* Desktop Navigation */

.main-nav {

  &, * {
    margin: 0;
    padding: 0;
    list-style: none;
  }

  > ul > li {
    position: relative;
    white-space: nowrap;
    float: left;
  }

  a {
    display: block;
    position: relative;
    color: darken($primary-dark, 15%);
    padding: 10px 15px;
    transition: 0.3s;
    font-size: 14px;
    font-family: $primary-font;
    font-weight: 500;
  }

  a:hover, .active > a, li:hover > a {
    color: $primary;
    text-decoration: none;
  }

  /* Drop Down */

  .drop-down ul {
    display: block;
    position: absolute;
    left: 0;
    top: calc(100% + 30px);
    z-index: 99;
    opacity: 0;
    visibility: hidden;
    padding: 10px 0;
    background: #fff;
    box-shadow: 0px 0px 30px rgba(127, 137, 161, 0.25);
    transition: ease all 0.3s;
  }
  
  .drop-down:hover > ul {
    opacity: 1;
    top: 100%;
    visibility: visible;
  }

  .drop-down li {
    min-width: 180px;
    position: relative;
  }

  .drop-down ul a {
    padding: 10px 20px;
    font-size: 13px;
    color: darken($primary-dark, 15%);
  }

  .drop-down ul a:hover, .drop-down ul .active > a, .drop-down ul li:hover > a {
    color: $primary;
  }
  
  .drop-down > a:after {
    content: "\f107";
    font-family: FontAwesome;
    padding-left: 10px; 
  }

  /* Deep Drop Down */

  .drop-down .drop-down ul {
    top: 0;
    left: calc(100% - 30px);
  }

  .drop-down .drop-down:hover > ul {
    opacity: 1;
    top: 0;
    left: 100%;
  }
  
  .drop-down .drop-down > a {
    padding-right: 35px;
  }
  
  .drop-down .drop-down > a:after {
    content: "\f105";
    position: absolute;
    right: 15px;
  }
  
}

/* Mobile Navigation */

.mobile-nav {
  position: fixed;
  top: 0;
  bottom: 0;
  z-index: 9999;
  overflow-y: auto;
  left: -260px;
  width: 260px;
  padding-top: 18px;
  background: rgba($secondary-dark, 0.8);
  transition: 0.4s;

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

  a {
    display: block;
    position: relative;
    color: #fff;
    padding: 10px 20px;
    font-weight: 500;
  }

  a:hover, .active > a, li:hover > a {
    color: $primary-light;
    text-decoration: none;
  }

  .drop-down > a:after {
    content: "\f078";
    font-family: FontAwesome;
    padding-left: 10px; 
    position: absolute;
    right: 15px;
  }

  .active.drop-down > a:after {
    content: "\f077";
  }
  
  .drop-down > a {
    padding-right: 35px;
  }
  
  .drop-down ul {
    display: none;
    overflow: hidden;
  }

  .drop-down li {
    padding-left: 20px;
  }
}

.mobile-nav-toggle {
  position: fixed;
  right: 0;
  top: 0;
  z-index: 9998;
  border: 0;
  background: none;
  font-size: 24px;
  transition: all 0.4s;
  outline: none !important;
  line-height: 1;
  cursor: pointer;
  text-align: right;
  i {
    margin: 18px 18px 0 0;
    color: darken($primary-dark, 15%);
  }

}

.mobile-nav-overly {
  width:100%;
  height:100%;
  z-index:9997;
  top:0;
  left:0;
  position:fixed;
  background: rgba($secondary-dark, 0.8);
  overflow: hidden;
  display: none;
}

.mobile-nav-active {
  overflow: hidden;

  .mobile-nav {
    left: 0;
  }

  .mobile-nav-toggle i {
    color: #fff;
  }
}
