fablabbcn/fablabs

View on GitHub
app/assets/stylesheets/header.css.scss

Summary

Maintainability
Test Coverage
#logo {
   width: 30px;
}
header {
  border-bottom: 1px solid #D9D9D9;

  a.top-link {
    padding-left: 8px;
    padding-right: 8px;
  }
  .has-form {
    padding: 10px;
  }
  position: relative;
  z-index: 40;
  ul {
    background: none !important;
  }

  body.a-home &, body.c-labs.a-map & {
    margin-bottom: 0;
  }
  margin-bottom: 20px;

  .dropdown {
    border: 1px solid #ccc;
    border-top: none;
  }

  .top-bar-section .dropdown li a {
    padding-top: 12px;
    padding-bottom: 12px;
    color: #333;
  }

  .top-bar-section .has-dropdown > a::after {
    color: #333;
    border-color: rgba(0, 0, 0, 0.5) transparent transparent;
  }

  #locale {
    display: none;
  }
  .form-group {
    padding: 0 10px;
  }
  #locale-icon img {
    vertical-align: middle;
  }

  .top-bar {
    margin: 0;
  }

  // // margin-bottom: 40px;
  // .a-home & {
  //   margin-bottom: 0;
  // }

  .nav .open > a, .nav .open > a:hover, .nav .open > a:focus,
  .nav > li > a:hover, .nav > li > a:focus {
    background: none !important;
  }

  .navbar-collapse {
    box-shadow: none !important;
  }

  nav.top-bar.expanded #search-box:focus {
    width: 100%;
  }
  #search-box {
    display: block;
    height: emCalc(42px);
    padding: 0px 10px;
    margin: -5px 0px 0px 0px;
    border: none;
    border-radius: 4px;
    &:focus {
      width: 240px;
      // transition: width 0.2s;
      // max-width: 100%;
    }
  }

  .avatar {
    margin-right: 5px;
    margin-top: -10px;
    margin-bottom: -10px;
  }
  .nav > li > a:hover {
    // background: none;
    color: #333 !important;
  }
  .icon-bar {
    // border-color: #333 !important;
  }

  .navbar {
    border-radius: 0 !important;
    background: #3D3544;
    border: none;
    z-index: 50;

    .caret {
      border-top-color: #333 !important;
      border-bottom-color: #333 !important;
    }
    // background: rgba(#F2F2F2, 0.8);
    .navbar-toggle .icon-bar {
      border: 1px solid #444;
      color: #333
    }
    a {
      color: #333;
    }
    a.navbar-brand {
      padding: 18px 0 0 10px;
      img {
        width: 140px;
      }
      // background: url('http://labs.fabfoundation.org/assets/logo-b87fc9df044d86d6412c0bee21945dfe.png') 7px 22px no-repeat;
      // padding-left: 35px;
      text-transform: uppercase;
      // color: #FFF;
      .fab {
        font-weight: bold;
      }
      .foundation {
        margin-left: -3px;
      }
    }
  }
}

.navbar.navbar-custom {
  width: 100%;
  background-color: white;
  border-bottom: 1px solid #E5E5E5;
  margin-bottom: 0;

  .navbar-toggler {
    margin-top: 23px;

    .icon-bar {
      background-color: #111;
    }
  }


  .navbar-brand {
    height: 80px;
    font-size: 18px;
    font-weight: bold;
    text-align: center;
    line-height: 80px;
    color: black;
    display: flex;
    align-items: center;
  }

  .navbar-form {
    @media (min-width: 768px) {
      margin: 15px 0;
    }

    #search-box {
      border-radius: 4px;
      border: 1px solid #E5E5E5;
      height: 50px;
      font-size: 14px;
      padding-left: 15px;
      box-shadow: 0 6px 10px rgba(0,0,0,0.05);
      outline-color: #e5e5e5;
      background-color: white;

      @media (min-width: 1300px) {
        width: 400px;
      }
    }
  }

  .navbar-nav {
    .active {
      border-bottom: 2px solid #ccc;
      a {
        color: black !important;
      }
    }
    .nav-item {
      > a {
        color: #666666;
        font-size: 15px;
        font-weight: bold;

        &:hover {
          color: #111111;
          background-color: initial;
        }
        padding: 0 10px;
        height: 50px;
        display: flex;
        align-items: center;
      }
    }

    .navbar-btn {
      margin-top: 23px;
      margin-bottom: 23px;

      > a {
        height: initial;
        padding: 6px 12px;
      }

      @media (max-width: 767px) {
        margin: 10px 15px;
      }
    }

    @media (min-width: 768px) {
      .navbar-btn + .navbar-btn {
        margin-left: 8px;
      }
    }

    .dropdown-toggle {
      padding: 30px 8px;
      color: black;

      &:hover {
        background-color: initial;
      }
    }
  }
}

.subnavbar {
  margin-bottom: 40px;

  .title {
    font-weight: bold;
    font-size: 22px;
    color: #111111;
    line-height: 34px;
  }
}