@import url("https://fonts.googleapis.com/css2?family=Montserrat:wght@100;300;400;500;600;700&display=swap");

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Montserrat", sans-serif;
}
body {
  background-color: #f2f9fa;
}
.main_form {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
  min-height: 100vh;
}
.formal {
  position: relative;
  width: 70vw;
  height: 80vh;
  box-shadow: rgba(0, 0, 0, 0.25) 0px 14px 28px,
    rgba(0, 0, 0, 0.22) 0px 10px 10px;
  border-radius: 15px;
  overflow: hidden;
}
.formal {
  margin-top: 80px;
  transform: translateX(0);
}
.formal::before {
  content: "";
  position: absolute;
  top: 0;
  left: -50%;
  width: 100%;
  height: 100%;
  background: linear-gradient(315deg, #1fd1f9 0%, #b621fe 100%);
  z-index: 6;
  transform: translateX(100%);
  transition: 1s ease-in-out;
}
.signin-signup {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-around;
  z-index: 5;
}
#page {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  width: 40%;
  min-width: 238px;
  padding: 0 10px;
}
#page.sign-in-form {
  opacity: 1;
  transition: 0.5s ease-in-out;
  transition-delay: 1s;
}
#page.sign-up-form {
  opacity: 0;
  transition: 0.5s ease-in-out;
  transition-delay: 1s;
}
.title {
  font-size: 35px;
  color: #1fd1f9;
  margin-bottom: 10px;
}
.input-field {
  width: 100%;
  height: 50px;
  background: #f0f0f0;
  margin: 10px 0;
  border: 2px solid #1fd1f9;
  border-radius: 50px;
  display: flex;
  align-items: center;
}
.input-field i {
  flex: 1;
  text-align: center;
  color: #666;
  font-size: 18px;
}
.input-field input {
  flex: 5;
  background: none;
  border: none;
  outline: none;
  width: 100%;
  font-size: 18px;
  font-weight: 600;
  color: #444;
  padding-right: 20px;
}
.btn1 {
  width: 150px;
  height: 50px;
  border: none;
  border-radius: 50px;
  background: #1fd1f9;
  color: #fff;
  font-weight: 600;
  margin: 10px 0;
  text-transform: uppercase;
  cursor: pointer;
}
.btn1:hover {
  color: #fff;
  background: #000;
}
.social-text {
  margin: 10px 0;
  font-size: 16px;
}
.social {
  display: flex;
  justify-content: center;
}
.social-icon1 {
  height: 45px;
  width: 45px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #444;
  border: 1px solid #444;
  border-radius: 50px;
  margin: 0 5px;
}
a {
  text-decoration: none;
}
.social-icon1:hover {
  color: #1fd1f9;
  border-color: #1fd1f9;
}
.panels-container {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-around;
}
.panel {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-around;
  width: 35%;
  min-width: 238px;
  padding: 0 10px;
  text-align: center;
  z-index: 6;
}
.left-panel {
  pointer-events: none;
}
.content {
  color: #fff;
  transition: 1.1s ease-in-out;
  transition-delay: 0.5s;
}
.panel h3 {
  font-size: 30px;
  font-weight: 600;
}
.panel p {
  font-size: 15px;
  padding: 10px 0;
}
.image {
  width: 100%;
  transition: 1.1s ease-in-out;
  transition-delay: 0.4s;
}
.left-panel .image,
.left-panel .content {
  transform: translateX(-200%);
}
.right-panel .image,
.right-panel .content {
  transform: translateX(0);
}
.account-text {
  display: none;
}
#sign-up-btn2,
#sign-in-btn2 {
  color: #1fd1f9;
  font-weight: bold;
}
/*Animation*/


/* add classlist - chữ sẽ di chuyển phần tử ngang theo trục X  */
.formal.sign-up-mode::before {
  transform: translateX(0); 
}
.formal.sign-up-mode .right-panel .image,
.formal.sign-up-mode .right-panel .content {

  /* di chuyển các phần tử ngang theo trục X một khoảng cách bằng 200% chiều rộng của chính nó */
  transform: translateX(200%);
}
.formal.sign-up-mode .left-panel .image,
.formal.sign-up-mode .left-panel .content {
  transform: translateX(0);
}
/* formal và sign-up-mode. opacity: 0 sẽ đặt độ mờ của phần tử là 0, trong suốt kh nhìn thấy được */
.formal.sign-up-mode #page.sign-in-form {
  opacity: 0;
}

/* hoàn toàn không trong suốt nhìn thấy được */
.formal.sign-up-mode #page.sign-up-form {
  opacity: 1;
}

/* Các sự kiện con trỏ: không có : không thể tương tác với phần tử .right-panel bằng chuột hoặc màn hình cảm ứng  */
.formal.sign-up-mode .right-panel {
  pointer-events: none;
}

/* right-panel` sẽ phản ứng với tất cả các sự kiện con trỏ như di chuột, nhấp chuột hoặc chạm */
.formal.sign-up-mode .left-panel {
  pointer-events: all;
}

/*============== Responsive ==========*/
@media (max-width: 1024px) {
  .formal {
    width: 90vw;
    height: 100vh;
  }
  .btn1,
  .btn2 {
    font-size: 0.9rem;
  }
}
@media (max-width: 779px) {
  .formal {
    width: 100vw;
    height: 100vh;
  }
}
@media (max-width: 635px) {
  .formal::before {
    display: none;
  }
  #page {
    width: 80%;
  }
  #page.sign-up-form {
    display: none;
  }
  .formal.sign-up-mode2 #page.sign-up-form {
    display: flex;
    opacity: 1;
  }
  .formal.sign-up-mode2 #page.sign-in-form {
    display: none;
  }
  .panels-container {
    display: none;
  }
  .account-text {
    display: initial;
    margin-top: 30px;
  }
}
@media (max-width: 320px) {
  #page {
    width: 90%;
  }
}
