
header{z-index: 2000;display:block;position: relative;}
header nav {
  background-color: rgba(0, 0, 0, 0.8);
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  visibility: hidden;
  -webkit-transition: all 0.3s ease-in-out;
  transition: all 0.3s ease-in-out;
}
header nav ul {
  list-style-type: none;
  padding: 0;
  margin: 0;
  position: absolute;
  left: 50%;
  top: 170px;
  -webkit-transition: all 0.3s ease-in-out;
  transition: all 0.3s ease-in-out;
  -webkit-transform: translateX(-50%);
          transform: translateX(-50%);
}
header nav ul li {
  -webkit-transform: translateY(50px);
          transform: translateY(50px);
  opacity: 0;
}
header nav ul li a {
  display: block;
  font-size: 2em;
  text-decoration: none;
  padding: 10px 0;
  text-align: center;
  color: #fff;
  font-weight: bold;
  -webkit-transition: all 0.2s ease-in-out;
  transition: all 0.2s ease-in-out;
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.5);
}
header nav ul li a:hover {
  color: #E84A5F;
}

.toggle-btn {
  display: block;
  position: fixed;
  z-index: 10;
  left: 20px;
  top: 20px;
  cursor: pointer;
}
.toggle-btn .bar {
  width: 30px;
  height: 2px;
  margin: 7px auto;
  background-color: #B20A2F;
  -webkit-transition: all 0.3s ease-in-out;
  transition: all 0.3s ease-in-out;
  /*box-shadow: 0 0 3px 1px rgba(0, 0, 0, 0.3);*/
}
.toggle-btn .bar:nth-child(2) {
  width: 20px;
}

#toggle:checked ~ nav {
  opacity: 1;
  visibility: visible;
}
#toggle:checked ~ nav ul {
  top: 70px;
}
#toggle:checked ~ nav ul li {
  -webkit-transform: translateY(0px);
          transform: translateY(0px);
  opacity: 1;
}
#toggle:checked ~ nav ul li:nth-child(1) {
  -webkit-transition: all 0.3s cubic-bezier(0.6, 0, 0.8, 1.5) 0.1s;
  transition: all 0.3s cubic-bezier(0.6, 0, 0.8, 1.5) 0.1s;
}
#toggle:checked ~ nav ul li:nth-child(2) {
  -webkit-transition: all 0.3s cubic-bezier(0.6, 0, 0.8, 1.5) 0.2s;
  transition: all 0.3s cubic-bezier(0.6, 0, 0.8, 1.5) 0.2s;
}
#toggle:checked ~ nav ul li:nth-child(3) {
  -webkit-transition: all 0.3s cubic-bezier(0.6, 0, 0.8, 1.5) 0.3s;
  transition: all 0.3s cubic-bezier(0.6, 0, 0.8, 1.5) 0.3s;
}
#toggle:checked ~ nav ul li:nth-child(4) {
  -webkit-transition: all 0.3s cubic-bezier(0.6, 0, 0.8, 1.5) 0.4s;
  transition: all 0.3s cubic-bezier(0.6, 0, 0.8, 1.5) 0.4s;
}
#toggle:checked + label.toggle-btn .bar {
  background-color: red;
}
#toggle:checked + label.toggle-btn .bar:nth-child(2) {
  -webkit-transform: translateX(50px);
          transform: translateX(50px);
  opacity: 0;
}
#toggle:checked + label.toggle-btn .bar:nth-child(1) {
  -webkit-transform: translateY(10px) rotate(45deg);
          transform: translateY(10px) rotate(45deg);
}
#toggle:checked + label.toggle-btn .bar:nth-child(3) {
  -webkit-transform: translateY(-8px) rotate(-45deg);
          transform: translateY(-8px) rotate(-45deg);
}
