.header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: em(50px);
  background: $white;
  border-bottom: em(1px) solid $light_gray;
  text-align: right;
  font-size: 0;
  z-index: 506;
  box-shadow: 0 -1px 0 0 $light_gray, 0 em(-50px) 0 0 $white;
  transition: top 1s $easeInOutQuart;
  will-change: transform, top;
  .search_open & {
    top: 100%;
  }
  &.reveal {
    transform: translateY(-100%);
  }
  .cms-toolbar-expanded & {
    top: 46px;
  }
}

.header__logo {
  position: fixed;
  top: 0;
  display: block;
  text-decoration: none;
  background: $green;
  padding: em(12px) em(15px) em(15px) em(15px);
  z-index: 510;
  transition: z-index 0s 1s;
  img {
    width: em(100px);
    height: em(100px);
    display: block;
  }
  .search_open & {
    z-index: 910;
    transition: z-index 0s;
  }
  &.reveal {
    transform: translateY(-100%);
    opacity: 1;
  }
  .cms-toolbar-expanded & {
    top: 46px;
  }
  @media screen and (max-width: $medium_breakpoint) {
    img {
      width: em(70px);
      height: em(70px);
      display: block;
    }
  }
}

.header__slogan {
  font-size: em(18px);
  line-height: em(48px);
  height: em(50px);
  color: $gray;
  font-weight: 300;
  position: absolute;
  margin-left: em(150px);
  top: 0;
  display: block;
  @media screen and (max-width: $medium_breakpoint) {
    display: none;
  }
}

.header__logo, .header__slogan {
  left: 15%;
  .timetable_body & {
    left: em(100px);
  }
  @media screen and (max-width: $huge_breakpoint) {
    left: em(70px) !important;
  }
  @media screen and (max-width: $large_breakpoint) {
    left: em(30px) !important;
  }
}

.header__button {
  height: em(50px);
  line-height: em(48px);
  display: inline-block;
  border-left: em(1px) solid $light_gray;
  border-bottom: em(1px) solid $light_gray;
  font-size: em(18px);
  font-weight: 800;
  color: $green;
  text-decoration: none;
  padding: 0 em(64px) 0 em(18px);
  position: relative;
  background: $white;
  transition: background 0.3s ease-in-out;
  vertical-align: middle;
  &:hover {
    background: darken($white, 1);
  }
}

.header__button--navigation {
  rect {
    transform: none;
    transform-origin: 100% 50%;
    transition: transform 0.3s $easeOutQuart;
    &.line-middle {
      transform: scaleX(0.8);
    }
  }
  &:hover {
    .line-top {
      transform: scaleX(0.8);
    }
    .line-bottom {
      transform: scaleX(0.6);
    }
    .line-middle {
      transform: scaleX(1);
    }
  }
}

.header__button--close {
  position: absolute;
  top: 0;
  right: 0;
  z-index: 5;
  background: none;
  border: none;
  path {
    transform: none;
    transform-origin: 50% 50%;
    transition: transform 0.3s $easeOutQuart;
  }
  &:hover {
    background: none;
    path {
      transform: rotate(90deg);
    }
  }
  .cms-toolbar-expanded & {
    top: 46px;
  }
}

.header__button--search {
  font-size: 0;
  padding-left: 0;
  .circle {
    transform: none;
    transform-origin: 50% 50%;
    transition: transform 0.3s $easeOutQuart;
  }
  &:hover {
    .circle {
      transform: scale(1.15);
    }
  }
}

.header__button__icon {
  width: em(32px);
  height: em(32px);
  position: absolute;
  top: em(9px);
  right: em(16px);
  svg {
    display: block;
    width: 100%;
    height: 100%;
    fill: $green;
  }
}