.wrap {
  position: relative;
  z-index: 1;
}

.aside {
  position: sticky;
  top: 0;
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
  width: 72px;
  height: 100vh;
  padding: 24px 16px;
  overflow: hidden;
  overflow-y: auto;
  background-color: var(--theme-card-color);
  border-right: 1px solid var(--theme-border-color);
  transition: all 0.2s linear;

  &.expanded {
    width: 216px;

    .logoLabel,
    .btnContent {
      visibility: visible;
    }
  }

  @media (max-width: 768px) {
    position: fixed;
    left: -100%;
    z-index: 10;
    width: 275px !important;

    &.open {
      left: 0;

      .logoLabel,
      .btnContent {
        visibility: visible;
      }
    }
  }
}

.logoContainer {
  flex-shrink: 0;
  display: flex;
  margin-bottom: 48px;
  overflow: hidden;
  padding: 0 8px;
  transition: width 0.3s linear;
}

.logo {
  flex-shrink: 0;
  display: flex;
}

.logoLabel {
  flex-shrink: 0;
  margin-left: 12px;
  overflow: hidden;
  visibility: hidden;
}

.button {
  position: relative;
  display: flex;
  align-items: center;
  width: 100%;
  background-color: transparent;
  border: 0;
  border-radius: 4px;
  text-align: left;
  color: var(--theme-secondary-color);

  &:hover,
  &.active {
    color: var(--theme-primary-color);

    svg {
      --icon-display__light: none;
      --icon-display__dark: none;
      --icon-display__hover: block;
      color: inherit;
    }

    .btnText {
      color: var(--theme-primary-color);
    }
  }

  .btnContent {
    margin-left: 16px;
    visibility: hidden;

    > div {
      white-space: nowrap;
      overflow: hidden;
    }
  }

  &:not(.active):not(:hover) {
    .btnLabel {
      color: var(--theme-grey-color);
    }
  }

  .btnText {
    color: var(--theme-secondary-color);
  }
}

.themeButton {
  &:hover,
  &.active {
    svg {
      --icon-display__light: none;
      --icon-display__dark: none;
      --icon-display__hover: block;
    }

    .btnText {
      color: var(--theme-primary-color);
    }
  }

  svg {
    flex-shrink: 0;
  }
}

.top {
  .button {
    margin-bottom: 24px;
  }
}

.bottom {
  margin-top: auto;

  @media (max-width: 768px) {
    border-top: 1px solid var(--theme-border-color);
  }

  .button {
    margin-top: 24px;
  }
}

.mask {
  background: var(--theme-mask-color);
  bottom: 0;
  height: 100%;
  left: 0;
  position: fixed;
  right: 0;
  top: 0;
  visibility: hidden;
  width: 0;
  z-index: 9;

  &.open {
    visibility: visible;
    width: 100%;
  }
}

.closeButton {
  background-color: transparent;
  border: 0;
  display: none;
  height: 24px;
  margin-right: 12px;
  padding: 0;
  width: 24px;

  @media (max-width: 768px) {
    display: block;
  }
}
