* {
  margin: 0;
  padding: 0;
  font-family: "Work Sans", sans-serif;
} 

a {
  color: #4d4d4d;
  text-decoration: none;
}

small {
  color: #5E8E3F;
}

.cmvfx {
  font-size:1rem;
  margin-top:-10px;
  color:#5E8E3F;
  position:absolute;
  left:52%;
}

h1 {
  position: absolute;
  top: 50%;
  transform: translate(0, -50%);
  color: #ffffff;
  font-weight: 700;
  font-size: 72px;
  z-index: 10;
  width: 100%;
  text-align: center;
  @media only screen and (max-width: 880px){
    font-size: 32px;
  }
}

.container {
  display: flex;
  height: 100vh;
  z-index: 5;
  &__open {
    .menu {
      display: block;
    }
  }
}

.container__open .toggle {
  &__span {
    &:nth-child(1) {
      top: 18px;
      transform: rotate(45deg);
    }
    &:nth-child(2) {
      background-color: transparent;
    }
    &:nth-child(3) {
      top: 18px;
      transform: rotate(-45deg);
    }
  }
}

.container__open .flex-box:nth-child(2) {
  flex: 0 0 0;
}

.flex-box {
  background-color: #5E8E3F;
  flex: 0 1 50%;
  transition: 0.5s all ease-in-out;
  position: relative;
  z-index: 15;
}

.flex-box:nth-child(2) {
  flex: 1 0 100%;
  background-color: #333;
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 56px;
  color: #fff;
  font-weight: 700;
  z-index: 1;
}

.container:hover.flex-box:nth-child(2) {
  flex: 0 0 0;
}

.menu {
  display: none;
  width: 100%;
  position: fixed;
  top: 0;
  left: 0%;
  height: 100vh;
  color: #fff;
  transform: translateY(-100%);
  background-color: transparent;
  animation: 0.4s slideDown 0.25s forwards;
  z-index: 100;
  -webkit-backface-visibility: hidden;

  &__list {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    list-style: none;
    padding: 0;
    @media only screen and (max-width: 880px) {
      flex-direction: column;
    }
  }
  &__item {
    font-weight: 700;
    font-size: 28px;
    padding: 1rem;
    margin: 0 1rem;
    text-align: center;
    background: linear-gradient(
      120deg,
      transparent 0%,
      transparent 50%,
      #fff 50%
    );
    background-size: 280%;
    transition: 0.3s all ease-in-out;
    cursor: pointer;
    position: relative;
    box-sizing: border-box;
    -webkit-backface-visibility: hidden;
    width: 15rem;

    &:hover {
      background-position: 99%;
      color: #5E8E3F;
    }

    @media only screen and(max-width: 1250px) {
      font-size: 36px;
    }

    @media only screen and (max-width: 1000px) {
      font-size: 28px;
    }
  }
}

.hover-box {
  background-color: #fff;
  color: green;
  display: none;
  animation: 0.6s fadeIn ease-in-out;
  position: absolute;
  color: #004d40;
  top: 100%;
  width: 100%;
  left: 0;
  border-top: 4px solid #5E8E3F;
  backface-visibility: none;

  &__list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    width: 100%;
  }
  &__item {
    box-sizing: border-box;
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 16px;
    padding: 6px 12px;
    border-bottom: 2px solid #5E8E3F;
    transition: 0.2s background;
    box-sizing: border-box;
    backface-visibility: none;
    &:hover {
      background-color: #a5d6a7;
    }
  }
  @media only screen and (max-width: 880px) {
    display: block;
    position: relative;
    width: auto;
    border-top: 2px solid #004d40;

    &__list {
      flex-direction: row;
    }
  }
}

.toggle {
  cursor: pointer;
  position: fixed;
  /*top: 2rem;*/
  /*left: 2rem;*/
  /*z-index: 10000;*/
  /*width: 40px;*/
  /*height: 40px;*/

  &__span {
    height: 3px;
    width: 100%;
    background-color: none;
    position: absolute;
    transition: 0.4s;
    &:nth-child(1) {
      top: 10px;
    }
    &:nth-child(2) {
      top: 19px;
    }
    &:nth-child(3) {
      top: 28px;
    }
  }
}

@keyframes slideDown {
  from {
    transform: translateY(-100%);
  }
  to {
    transform: translateY(0);
  }
}
