/* Main container styling */
.auth-container {
  min-height: 100vh;
  background: #f8f6f3;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
}

/* Central card container */
.auth-card {
  background: transparent;
  border-radius: 0;
  padding: 2rem 1.5rem;
  box-shadow: none;
  backdrop-filter: none;
  border: none;
  width: 100%;
  max-width: 400px;
  position: relative;
  overflow: visible;
}

/* Remove background pattern */
.auth-card::before {
  display: none;
}

/* Header section styling */
.auth-header {
  text-align: center;
  margin-bottom: 2rem;
  position: relative;
  z-index: 1;
}

.auth-emoji {
  font-size: 3.5rem;
  display: block;
  margin-bottom: 1rem;
  filter: none;
}

.auth-title {
  font-size: 1.8rem;
  font-weight: 300;
  color: #2d3748;
  margin-bottom: 0.75rem;
  letter-spacing: 0.3px;
}

.auth-subtitle {
  color: #718096;
  font-size: 0.9rem;
  margin: 0;
  font-weight: 400;
  line-height: 1.4;
  max-width: 320px;
  margin-left: auto;
  margin-right: auto;
}

/* Form styling */
.auth-form {
  position: relative;
  z-index: 1;
  margin-bottom: 1.5rem;
}

/* Input field styling */
.auth-input {
  width: 100%;
  padding: 1.2rem 1.5rem;
  font-size: 1rem;
  border: none;
  border-radius: 8px;
  background: #e6e3dd;
  transition: all 0.2s ease;
  margin-bottom: 1.5rem;
  font-weight: 400;
  color: #333;
  text-align: center;
}

.auth-input::placeholder {
  color: #666;
  font-weight: 400;
  text-align: center;
}

.auth-input:focus {
  outline: none;
  background: #ddd8d1;
  transform: none;
  box-shadow: none;
}

.auth-input:valid {
  background: #e6e3dd;
}

.auth-input.is-invalid {
  background: #f8d7da;
  color: #721c24;
}

.auth-input.is-valid {
  background: #e6e3dd;
}

/* Button styling */
.auth-button {
  width: 100%;
  padding: 1.2rem 1.5rem;
  font-size: 1rem;
  font-weight: 600;
  color: white;
  background: #d2691e;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
  margin: 1rem 0;
  position: relative;
  overflow: hidden;
}

.auth-button:hover {
  background: #b8601a;
  transform: none;
  box-shadow: none;
}

.auth-button:active {
  transform: none;
}

.auth-button:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

/* Loading state for button */
.auth-button.loading {
  color: transparent;
}

.auth-button.loading::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 20px;
  height: 20px;
  margin-top: -10px;
  margin-left: -10px;
  border: 2px solid #ffffff;
  border-radius: 50%;
  border-top-color: transparent;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* Help text styling */
.auth-help-text {
  background: transparent;
  border: none;
  border-radius: 0;
  padding: 0;
  margin: 1rem 0;
  position: relative;
  z-index: 1;
}

.auth-help-text p {
  margin: 0;
  color: #718096;
  font-size: 0.85rem;
  line-height: 1.4;
  text-align: center;
}

/* Bottom section styling */
.auth-bottom {
  text-align: center;
  border-top: none;
  padding-top: 1.5rem;
  position: relative;
  z-index: 1;
}

.auth-navigation-links {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  margin-bottom: 1.5rem;
  flex-wrap: wrap;
}

.auth-secondary-link {
  color: #d2691e;
  text-decoration: none;
  font-weight: 500;
  font-size: 0.9rem;
  transition: color 0.2s ease;
}

.auth-secondary-link:hover {
  color: #b8601a;
  text-decoration: underline;
}

.auth-separator {
  color: #cbd5e0;
  font-weight: 300;
  user-select: none;
}

.auth-back-button {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.8rem 1.5rem;
  background: #e6e3dd;
  color: #666;
  text-decoration: none;
  border-radius: 8px;
  font-size: 0.9rem;
  transition: all 0.2s ease;
}

.auth-back-button:hover {
  background: #ddd8d1;
  color: #333;
  transform: none;
}

.auth-back-button::before {
  content: "←";
  font-weight: bold;
}

/* Alert styling with smooth transitions */
.alert {
  margin-bottom: 1rem;
  border-radius: 6px;
  border: none;
  position: relative;
  z-index: 1;
  transition:
    opacity 0.3s ease,
    transform 0.3s ease;
  padding: 0.8rem 1rem;
}

.alert-success {
  background: rgba(72, 187, 120, 0.1);
  color: #22543d;
  border-left: 3px solid #48bb78;
}

.alert-danger {
  background: rgba(245, 101, 101, 0.1);
  color: #742a2a;
  border-left: 3px solid #f56565;
}

/* Alert dismissal animation */
.alert.fade-out {
  opacity: 0;
  transform: translateY(-10px);
}

/* Success state styling */
.auth-card.success {
  border: none;
}

.auth-card.success .auth-emoji {
  filter: none;
}

/* Email sent confirmation */
.email-sent-confirmation {
  text-align: center;
  padding: 2rem 0;
  position: relative;
  z-index: 1;
}

.email-sent-icon {
  font-size: 3rem;
  margin-bottom: 1rem;
  display: block;
}

.email-sent-title {
  font-size: 1.5rem;
  font-weight: 600;
  color: #2d3748;
  margin-bottom: 0.5rem;
}

.email-sent-message {
  color: #718096;
  font-size: 0.9rem;
  line-height: 1.4;
  margin-bottom: 1.5rem;
}

/* Loading overlay */
.loading-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(248, 246, 243, 0.9);
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 0;
  z-index: 10;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
}

.loading-overlay.active {
  opacity: 1;
  visibility: visible;
}

.loading-spinner {
  width: 2.5rem;
  height: 2.5rem;
  border: 3px solid rgba(210, 105, 30, 0.1);
  border-radius: 50%;
  border-top-color: #d2691e;
  animation: spin 0.8s linear infinite;
}

/* Responsive design */
@media (max-width: 480px) {
  .auth-container {
    padding: 0.5rem;
  }

  .auth-card {
    padding: 1.5rem 1rem;
  }

  .auth-emoji {
    font-size: 3rem;
  }

  .auth-title {
    font-size: 1.5rem;
  }

  .auth-subtitle {
    font-size: 0.8rem;
  }

  .auth-input,
  .auth-button {
    padding: 1rem 1.25rem;
  }

  .auth-navigation-links {
    flex-direction: column;
    gap: 0.5rem;
  }

  .auth-separator {
    display: none;
  }
}

/* Animation for form appearance */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.auth-card {
  animation: fadeInUp 0.4s ease-out;
}

/* Focus states for accessibility */
.auth-input:focus,
.auth-button:focus,
.auth-secondary-link:focus,
.auth-back-button:focus {
  outline: 2px solid #d2691e;
  outline-offset: 2px;
}
