@import 'assets/scss/colors.scss';
@import 'assets/scss/fonts.scss';
@import 'assets/scss/z-index.scss';
@import 'assets/scss/animations.scss';

.topBar {
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  z-index: $navigation;
  height: 72px;
  background-color: var(--color-background-white);
  box-shadow: 0 3px 8px 0 var(--color-shadow-gray);
  position: fixed;
  overflow: visible;
  top: 0;
  width: 100%;
}

.airyLogo {
  margin: 20px 24px;
}

.airyLogoSvg {
  width: 86px;
  height: 32px;
}

.menuArea {
  display: flex;
  flex-direction: row;
  align-items: center;
  margin-right: 32px;
}

.dropDown {
  display: flex;
  flex-direction: row;
  align-items: center;
  margin: 8px 0;
  transition: 0.2s all ease-in-out;
  padding: 8px 16px;
  border-radius: 8px;
  color: var(--color-text-contrast);
  cursor: pointer;
  &:hover {
    background-color: var(--color-background-blue);
  }
}

.dropHint {
  width: 16px;
  svg {
    path {
      fill: var(--color-text-gray);
    }
  }
}

.dropHintOpen {
  transition: 300ms ease;
  margin-bottom: 0;
  transform: rotate(180deg);
}

.dropHintClose {
  transition: 300ms ease;
  margin-bottom: 0;
  transform: rotate(0deg);
}

.accountDetails {
  padding-right: 12px;
}

.accountName {
  font-weight: 900;
  color: var(--color-text-contrast);
}

.accountHint {
  @include font-s;
  color: var(--color-text-gray);
}

.menuItem {
  position: relative;
  height: 100%;
  display: flex;
  align-items: center;
}

.dropdownContainer {
  position: absolute;
  background-color: var(--color-background-white);
  border: 1px solid var(--color-light-gray);
  border-radius: 8px;
  top: 68px;
  overflow: hidden;
  right: 0;
  white-space: nowrap;
}

.dropdownLine {
  display: flex;
  width: 228px;
  align-items: center;
  border-bottom: 1px solid var(--color-background-gray);
  padding: 12px;

  color: var(--color-text-contrast);
  text-decoration: none;
  font-weight: 400;

  &:hover {
    background-color: var(--color-background-blue);
    color: var(--color-airy-blue);
    text-decoration: underline;
    cursor: pointer;

    .dropdownIcon {
      svg {
        path {
          fill: var(--color-airy-blue);
        }
      }
    }
  }
}

.dropdownIcon {
  display: inline-block;
  margin-right: 6px;
  margin-top: 4px;
  width: 24px;

  svg {
    path {
      fill: var(--color-text-gray);
    }
  }
}

.dropdownIconLanguage {
  display: flex;
  align-items: center;
  width: 24px;
  height: 24px;
  border-radius: 24px;
  margin-right: 6px;
  &hover {
    cursor: pointer;
  }
}

.dropdownIconControlCenter {
  display: inline-block;
  margin-right: 6px;
  margin-top: 4px;
  width: 24px;
  height: 24px;

  svg {
    height: 100%;
    width: 100%;
  }
}

.dropdownLastLine {
  @include font-s;
  border-top: 1px solid var(--color-light-gray);
  padding: 16px 32px;
  text-align: center;
  color: var(--color-text-gray);
}

.dropdownLastLink {
  color: var(--color-text-gray);
  font-weight: 400;

  &:not(:last-child) {
    padding-right: 4px;
  }

  &:hover {
    color: var(--color-airy-blue);
    text-decoration: underline;
  }
}

.help {
  @include font-m;
  background: transparent;
  margin-right: 16px;
  border: 1px solid var(--color-text-gray);
  border-radius: 50%;
  width: 24px;
  height: 24px;
  display: flex;
  justify-content: center;
  align-items: center;
  color: var(--color-text-contrast);
  cursor: pointer;

  &:hover {
    color: var(--color-airy-blue);
    background-color: var(--color-background-blue);
    border: 1px solid var(--color-airy-blue);
    box-shadow: 0px 0px 0px 3px var(--color-background-blue);
  }
}

.theme {
  background: transparent;
  border: none;
  margin-left: 8px;
}

#dropDownLink {
  color: var(--color-airy-blue);
  text-decoration: none;
  font-size: 10px;
  line-height: 10px;
  margin: 9px 0 0 0;

  &:hover {
    text-decoration: underline;
  }
}

.dropDownVersionContainer {
  display: flex;
  flex-direction: column;
  margin-left: 42px;

  h1 {
    @include font-base;
    line-height: 16px;
    font-weight: 600;
    color: var(--color-text-contrast);
    margin-top: 4px;
    margin-bottom: 6px;
  }

  a {
    font-family: 'Lato', sans-serif;
    font-size: 10px;
    line-height: 10px;
    font-weight: 600;
    color: var(--color-text-gray);
    cursor: pointer;
    margin-bottom: 8px;
    text-decoration: none;

    &:hover {
      text-decoration: underline;
    }
  }
}

.animateIn {
  animation: topbarDropdownIn 300ms ease;
}

.animateOut {
  animation: topbarDropdownOut 300ms forwards;
}
