/* Overlay Box */

.sign-in {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.5); 
  align-items: center;
  justify-content: center;
  display: none;
  flex-direction: column;
  gap: 12px;
  z-index: 9999;
}

.sign-in h1 {
  font-family: 'Playfair Display', serif;
  color: white;
  text-decoration: underline;
}

.sign-in-box {
  background: #fffdfa;
  padding: 2rem;
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
  width: 400px;
  max-width: 90%;
  text-align: center;
  position: relative;
}

.sign-in.active {
  display: flex;
  animation: slideIn 1.5s;
  background: rgba(0,0,0,0.5); 
}

.sign-in.remove {
  animation: slideOut 1.5s;
}

#close2 {
  position: absolute;
  top: 6px;
  right: 12px;
  font-size: 16px;
  cursor: pointer;
  color: #333;
}

.sign-in-box h2 {
  font-size: 1.2rem;
  color: #333;
  margin-bottom: 1.5rem;
  line-height: 1.4;
}

.input-fields input {
  display: block;
  width: 100%;
  padding: 0.8rem;
  margin-bottom: 1rem;
  border: 1px solid #ddd;
  border-radius: 8px;
  font-size: 0.95rem;
  transition: border 0.3s;
}

.input-fields input:focus {
  border-color: #b87333;
  outline: none;
}

.input-fields button {
  width: 100%;
  background: #111;
  color: #fff;
  border: none;
  padding: 0.9rem;
  border-radius: 8px;
  cursor: pointer;
  font-size: 1rem;
  transition: background 0.3s;
}

.input-fields button:hover {
  background: #333;
}

.create-acc-link {
  cursor: pointer;
  text-decoration: underline;
  color: #9e5905;
}

/* CREATE ACCOUNT */

/* Overlay background */
.create-account {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.5);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 9999;
}

.create-account-box {
  position: relative;
  background: #fffdfa;
  padding: 2rem;
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
  width: 600px;
  text-align: center;
  position: relative;
}

.create-account.active {
  display: flex;
  animation: slideIn 1.5s;
  background: rgba(0,0,0,0.5);
}

.create-account.remove {
  animation: slideOut 1.5s;
}

@keyframes slideIn {
  0% {
    transform: translate(1000px, -50%); 
    opacity: 0;
  }
  100% {
    transform: translate(-50%, -50%); 
    opacity: 1;
  }
}

@keyframes slideOut {
  0% {
    transform: translate(-50%, -50%); 
    opacity: 1;
  }
  100% {
    transform: translate(1000px, -50%); 
    opacity: 0;
  }
}

.create-account i {
  position: absolute;   
  top: 6px;
  right: 10px;
  font-size: 18px;
  color: #555;
  cursor: pointer;
  transition: transform 0.3s ease, color 0.3s ease;
}

.create-account i:hover {
  transform: scale(1.05);
}

.create-account-box {
  margin: 4rem;
}

.create-account h2 {
  font-family: "DM Serif Text", serif;
  text-align: center;
  font-size: 1.4rem;
  font-weight: bold;
  color: #333;
  margin-bottom: 1.5rem;
  line-height: 1.4;
  padding: 0 10px;
}

.input-fields {
  display: flex;
  flex-direction: column;
}

.input-fields input {
  padding: 12px 20px;
  font-size: 1rem;
  border: 2px solid #d9b68c; 
  border-radius: 8px;
  outline: none;
  transition: all 0.3s ease;
  background-color: #fffdf9;
  color: #262626;
}

.input-fields input:focus {
  border-color: #262626;
  box-shadow: 0 4px 10px rgba(38,38,38,0.2);
}

.create-account button {
  margin-top: 20px;
  padding: 12px;
  width: 100%;
  color: #fff;
  background-color: #262626;
  font-size: 1rem;
  font-weight: bold;
  border: none;
  border-radius: 2px;
  cursor: pointer;
  transition: background 0.3s ease, transform 0.2s ease;
}

.create-account button:hover {
  background: #333333;
  transform: translateY(-2px);
}

input[type=number]::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.create-account a {
  cursor: pointer;
  color: #9e5905;
  text-decoration: underline;
}

/* ERROR STATE FOR INPUT */
input#firstName.error,
input#lastName.error,
input#email.error,
input#phone.error,
input#password.error,
input#confirm-password.error {
  border-color: #e74c3c;
  box-shadow: 0 0 5px rgba(231, 76, 60, 0.4);
}

input#firstName.error,
input#lastName.error,
input#email.error,
input#phone.error,
input#password.error,
input#confirm-password.error:focus {
  border-color: #e74c3c;
  box-shadow: 0 0 5px rgba(231, 76, 60, 0.4);
}

input#firstName.success,
input#lastName.success,
input#email.success,
input#phone.success,
input#confirm-password.success,
input#password.success {
  border-color: #1eee4b;
  box-shadow: 0 0 5px rgba(30, 238, 75, 0.4);
}

input#firstName.success,
input#lastName.success,
input#email.success,
input#phone.success,
input#confirm-password.success,
input#password.success {
  border-color: #1eee4b;
  box-shadow: 0 0 5px rgba(30, 238, 75, 0.4);
}

/* Error message text */
#pw-error-message,
#error-message {
  color: #e74c3c;
  font-size: 0.85rem;
  margin-bottom: 0.8rem;
  display: none; 
}