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

/* COFFEE COLOR VARIABLES */
:root {
  --coffee-dark: #3e2723;
  --coffee-medium: #5d4037;
  --coffee-light: #8d6e63;
  --coffee-cream: #efebe9;
  --coffee-bg: linear-gradient(135deg, #4e342e, #a1887f);
  --shadow-color: rgba(0, 0, 0, 0.3);
  --white-color: #fff;
  --transition-3s: 0.3s;
}

/* GLOBAL */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Poppins", sans-serif;
}

body {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  height: 100vh;
  background: var(--coffee-bg);
}

/* HOME ICON */
.icon-log img {
  width: 55px;
  filter: drop-shadow(0 4px 6px rgba(0, 0, 0, 0.4));
}

/* WRAPPER */
.wrapper {
  position: relative;
  width: 430px;
  height: 500px;
  background: var(--coffee-cream);
  border-radius: 20px;
  padding: 120px 32px 64px;
  box-shadow: 0 20px 40px var(--shadow-color);
  transition: var(--transition-3s);
  overflow: hidden;
}

/* HEADER TAB */
.form-header {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 160px;
  height: 75px;
  background: var(--coffee-dark);
  border-radius: 0 0 25px 25px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.form-header::before,
.form-header::after {
  content: "";
  position: absolute;
  top: 0;
  width: 35px;
  height: 35px;
}

.form-header::before {
  left: -35px;
  border-top-right-radius: 50%;
  box-shadow: 18px 0 0 var(--coffee-dark);
}

.form-header::after {
  right: -35px;
  border-top-left-radius: 50%;
  box-shadow: -18px 0 0 var(--coffee-dark);
}

/* TITLES */
.title-login,
.title-register {
  position: absolute;
  color: var(--white-color);
  font-size: 1rem;
  font-weight: 500;
  transition: var(--transition-3s);
}

.title-login {
  top: 40%;
  left: 25%;
}

.title-register {
  top: -160%;
  left: 25%;
}

/* FORMS */
.login-form,
.register-form {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  width: 85%;
  transition: var(--transition-3s);
}

.register-form {
  left: 150%;
}

/* INPUT */
.input-box {
  position: relative;
  margin: 22px 0;
}

.input-field {
  width: 100%;
  height: 55px;
  padding: 0 20px;
  border-radius: 30px;
  border: 1px solid #d7ccc8;
  background: #fff;
  outline: none;
  transition: var(--transition-3s);
}

.input-field:focus {
  border: 1px solid var(--coffee-medium);
  box-shadow: 0 0 0 3px rgba(141, 110, 99, 0.2);
}

.label {
  position: absolute;
  top: 50%;
  left: 20px;
  transform: translateY(-50%);
  color: var(--coffee-light);
  transition: 0.2s;
  pointer-events: none;
}

.input-field:focus ~ .label,
.input-field:valid ~ .label {
  top: 0;
  font-size: 13px;
  background: var(--coffee-cream);
  padding: 0 8px;
  color: var(--coffee-dark);
}

/* ICON */
.icon {
  position: absolute;
  top: 50%;
  right: 20px;
  transform: translateY(-50%);
  font-size: 18px;
  color: var(--coffee-medium);
}

/* BUTTON */
.btn-submit {
  width: 100%;
  height: 50px;
  border-radius: 30px;
  border: none;
  background: var(--coffee-dark);
  color: white;
  font-weight: 500;
  cursor: pointer;
  transition: 0.3s;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
}

.btn-submit:hover {
  background: var(--coffee-medium);
  transform: translateY(-2px);
}

/* SWITCH */
.switch-form {
  text-align: center;
  margin-top: 10px;
}

.switch-form a {
  color: var(--coffee-dark);
  font-weight: 500;
}

.switch-form a:hover {
  text-decoration: underline;
}

/* FORM COLS */
.form-cols {
  display: flex;
  justify-content: space-between;
  font-size: 14px;
  color: var(--coffee-medium);
}

/* RESPONSIVE */
@media (max-width: 564px) {
  .wrapper {
    margin: 20px;
  }
}
