@font-face {
  font-family: "AgencyFb";
  src: url("../fonts/agencyfb_reg.ttf");
}

:root {
  --primary-bg: #121316;
  --secondary-bg: #191a1e;
  --primary-font-color: #fff;
  --secondary-font-color: #ffffff66;
  --burger-Btn-color: #fff;
  --accent-Color: #6c63ff;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  background-color: #121316;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  height: 100vh;
}

.container {
  background-color: var(--secondary-bg);
  border-radius: 30px;
  box-shadow: rgba(0, 0, 0, 0.25) 0px 54px 55px,
    rgba(0, 0, 0, 0.12) 0px -12px 30px, rgba(0, 0, 0, 0.12) 0px 4px 6px,
    rgba(0, 0, 0, 0.17) 0px 12px 13px, rgba(0, 0, 0, 0.09) 0px -3px 5px;
  position: relative;
  overflow: hidden;
  width: 768px;
  max-width: 100%;
  min-height: 480px;
  color: var(--primary-font-color);
  font-family: "AgencyFb";
}

.container h1 {
  padding-bottom: 20px;
  letter-spacing: 1px;
}

.container p {
  font-size: 1.2rem;
  line-height: 20px;
  letter-spacing: 0.3px;
  margin: 20px 0;
}

.container a {
  color: var(--secondary-font-color);
  font-size: 13px;
  text-decoration: none;
  margin: 15px 0 10px;
}

.container button {
  background-color: #6c63ff;
  color: var(--primary-font-color);
  font-size: 0.9rem;
  padding: 10px 45px;
  border: 1px solid transparent;
  border-radius: 8px;
  font-weight: 600;
  letter-spacing: 0.5;
  text-transform: uppercase;
  margin-top: 10px;
  cursor: pointer;
}

.container button.hidden {
  background-color: transparent;
  border-color: var(--primary-font-color);
  color: var(--primary-font-color);
}

.container form {
  background-color: var(--secondary-bg);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  padding: 0 40px;
  height: 100%;
}

.container input {
  background-color: transparent;
  border: 2px solid var(--accent-Color);
  margin: 8px 0;
  padding: 10px 15px;
  font-size: 13px;
  border-radius: 8px;
  width: 100%;
  outline: none;
  color: var(--primary-font-color);
}

.form-container {
  position: absolute;
  top: 0;
  height: 100%;
  transition: all 0.6s ease-in-out;
}

.sign-in {
  left: 0;
  width: 50%;
  z-index: 2;
}

.container.active .sign-in {
  transform: translateX(100%);
}

.sign-up {
  left: 0;
  width: 50%;
  opacity: 0;
  z-index: 1;
}

.container.active .sign-up {
  transform: translateX(100%);
  opacity: 1;
  z-index: 5;
  animation: move 0.6s;
}

@keyframes move {
  0%,
  49.99% {
    opacity: 0;
    z-index: 1;
  }
  50%,
  100% {
    opacity: 1;
    z-index: 5;
  }
}

.toggle-container {
  position: absolute;
  top: 0;
  left: 50%;
  width: 50%;
  height: 100%;
  overflow: hidden;
  transition: all 0.6s ease-in-out;
  border-radius: 150px 0 0 100px;
  z-index: 1000;
}

.container.active .toggle-container {
  transform: translateX(-100%);
  border-radius: 0 150px 100px 0;
}

.toggle {
  background-color: var(--accent-Color);
  height: 100%;
  position: relative;
  left: -100%;
  height: 100%;
  width: 200%;
  transform: translateX(0);
  transition: all 0.6s ease-in-out;
}

.container.active .toggle {
  transform: translateX(50%);
}

.toggle-panel {
  position: absolute;
  width: 50%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  padding: 0 30px;
  text-align: center;
  top: 0;
  transform: translateX(0);
  transition: all 0.6s ease-in-out;
}

.toggle-left {
  transform: translateX(-200%);
}

.container.active .toggle-left {
  transform: translateX(0);
}

.toggle-right {
  right: 0;
  transform: translateX(0);
}

.container.active .toggle-right {
  transform: translateX(200%);
}

@media (max-width: 768px) {
  .container {
    width: 90vw;
    height: 90%;
  }

  .toggle-container {
    left: unset;
    width: 100%;
    bottom: 0;
    height: 35%;
    top: unset;
    border-radius: 120px 0 0 0;
  }

  .toggle {
    width: 100%;
    left: unset;
  }

  .toggle-panel {
    width: 100%;
  }

  .container form {
    height: 65%;
    width: 100%;
  }

  .sign-in {
    width: 100%;
  }

  .container.active .sign-up {
    transform: unset;
    width: 100%;
  }

  .container.active .toggle {
    transform: unset;
  }

  .container .toggle-container {
    transform: translateX(0%);
  }

  .container.active .toggle-container {
    transform: translateX(0);
    border-radius: 0 120px 0 0;
  }

  .container.active .sign-up {
    transform: translateX(0%);
  }

  .container .sign-up {
    transform: translateX(-100%);
  }
}
