@import "../../../scss/variables";

material-navbar {
  display: block;
  background-color: $site-primary-color-200;
  color: $site-text-color-100;
  box-shadow: $box-shadow-3;
  position: relative;
  z-index: 2;
  height: $material-navbar-height;

  .navbar-container {
    display: flex;
    align-items: center;
    padding: 0 15px;
    margin: 0 auto;
    width: 100%;
    height: 100%;
  }

  .logo-container {
    height: 55%;
    width: auto;

    .logo {
      display: block;
      height: 100%;
      width: auto;
    }
  }

  .text-logo {
    font-size: 2.2rem;
    color: $site-text-color-100;
  }

  .toggle-sidebar-button {
    display: block;
    vertical-align: middle;
    margin: 0 30px 0 20px;
  }

  custom-menu {
    display: flex;
    align-items: center;
    flex: 1 1 auto;
    flex-grow: 0;

    @media only screen and (max-width: $tablet) {
      display: none;
    }

    .nav-item {
      white-space: nowrap;
      display: block;
      color: inherit;
      text-decoration: none;
      padding: 5px 15px;
      border-radius: 5px;
      line-height: 22px;

      &:hover {
        text-decoration: underline;
      }

      &.router-link-active, &.active {
        color: $site-text-color-100;
        background-color: $site-primary-color-100;
      }
    }
  }

  .nav-searchbar {
    height: 65%;
    max-height: 48px;

    // separate logo and search bar
    margin-left: 30px;

    // needed to separate search bar and user avatar
    // on small screens, if there's no menu items
    margin-right: 30px;

    input, form {
      height: 100%;
    }

    @media only screen and (max-width: $tablet) {
      display: none;
    }
  }

  logged-in-user-widget {
    margin-left: auto;
  }

  .auth-buttons {
    margin-left: auto;

    a {
      min-width: 110px;
      line-height: 44px;
    }
  }
}