/* Auth Modal Styles */
.auth-modal {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 1000;
  background-color: rgba(0, 0, 0, 0.6);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.3s ease;
}

.auth-modal.hidden {
  display: none;
  pointer-events: none;
}

.auth-modal.hidden .modal-overlay {
  opacity: 0;
}

.auth-modal.hidden .modal-content {
  opacity: 0;
  transform: scale(0.95);
}

.modal-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0, 0, 0, 0.6);
  opacity: 1;
  transition: opacity 0.3s ease;
  display: none; /* Remove modal-overlay */
}

.auth-modal-content {
  position: relative;
  background: white;
  border-radius: 12px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  width: 90%;
  max-width: 500px;
  max-height: 90vh;
  overflow-y: auto;
  padding: 40px;
  opacity: 1;
  transform: scale(1);
  transition: opacity 0.3s ease, transform 0.3s ease;
}

.auth-modal-content h2 {
  margin: 0 0 30px 0;
  font-size: 28px;
  font-weight: 700;
  color: #1a1a1a;
}

.close-modal {
  position: absolute;
  top: 20px;
  right: 20px;
  background: none;
  border: none;
  font-size: 28px;
  cursor: pointer;
  color: #666;
  padding: 0;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: all 0.3s ease;
}

.close-modal:hover {
  background-color: #f0f0f0;
  color: #000;
}

.modal-header {
  display: none; /* Remove modal-header */
  justify-content: space-between;
  align-items: center;
  margin-bottom: 30px;
}

.modal-header h2 {
  margin: 0;
  font-size: 28px;
  font-weight: 700;
  color: #1a1a1a;
}

.modal-close {
  display: none; /* Remove modal-close */
  background: none;
  border: none;
  font-size: 28px;
  cursor: pointer;
  color: #666;
  padding: 0;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: all 0.3s ease;
}

.modal-close:hover {
  background-color: #f0f0f0;
  color: #000;
}

#login-form,
#signup-form,
#verification-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.auth-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.form-group label {
  font-weight: 600;
  color: #333;
  font-size: 14px;
}

.form-group input,
.form-group select {
  padding: 12px 16px;
  border: 1px solid #ddd;
  border-radius: 8px;
  font-size: 14px;
  font-family: inherit;
  transition: all 0.3s ease;
}

.form-group input:focus,
.form-group select:focus {
  outline: none;
  border-color: #000;
  box-shadow: 0 0 0 3px rgba(0, 0, 0, 0.1);
}

.form-group input::placeholder {
  color: #999;
}

.error-message {
  color: #dc3545;
  font-size: 12px;
  display: none;
}

.form-group.error input,
.form-group.error select {
  border-color: #dc3545;
  background-color: #fff5f5;
}

.form-group.error .error-message {
  display: block;
}

.btn-submit {
  padding: 14px 20px;
  background-color: #000;
  color: white;
  border: none;
  border-radius: 8px;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  margin-top: 10px;
  transition: all 0.3s ease;
}

.btn-submit:hover {
  background-color: #333;
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
}

.btn-submit:active {
  transform: translateY(0);
}

.auth-toggle {
  text-align: center;
  margin-top: 20px;
  padding-top: 20px;
  border-top: 1px solid #eee;
  font-size: 14px;
  color: #666;
}

.auth-toggle a {
  color: #000;
  text-decoration: none;
  font-weight: 600;
  cursor: pointer;
  transition: color 0.3s ease;
}

.auth-toggle a:hover {
  color: #666;
}

/* Added verification modal specific styles */
.verification-message {
  font-size: 16px;
  color: #333;
  margin-bottom: 20px;
  text-align: center;
  line-height: 1.5;
}

.resend-code {
  text-align: center;
  margin-top: 20px;
  font-size: 14px;
  color: #666;
}

.resend-link {
  color: #000;
  text-decoration: none;
  font-weight: 600;
  cursor: pointer;
  transition: color 0.3s ease;
}

.resend-link:hover {
  color: #666;
}

.modal-footer {
  display: none; /* Remove modal-footer */
  text-align: center;
  margin-top: 20px;
  padding-top: 20px;
  border-top: 1px solid #eee;
  font-size: 14px;
  color: #666;
}

.modal-footer a {
  color: #000;
  text-decoration: none;
  font-weight: 600;
  cursor: pointer;
  transition: color 0.3s ease;
}

.modal-footer a:hover {
  color: #666;
}

/* Responsive Design */
@media (max-width: 768px) {
  .auth-modal-content {
    width: 95%;
    padding: 30px 20px;
    max-height: 95vh;
  }

  .auth-modal-content h2 {
    font-size: 24px;
  }

  .form-group input,
  .form-group select {
    padding: 12px 14px;
    font-size: 16px; /* Prevents zoom on iOS */
  }
}

@media (max-width: 480px) {
  .auth-modal-content {
    padding: 20px 15px;
  }

  .auth-modal-content h2 {
    font-size: 20px;
  }

  .close-modal {
    width: 36px;
    height: 36px;
    font-size: 24px;
  }

  #login-form,
  #signup-form {
    gap: 16px;
  }

  .form-group input,
  .form-group select {
    padding: 12px 12px;
  }
}
