* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen', 'Ubuntu', 'Cantarell', sans-serif;
  background-color: #f8f9fa;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 40px 20px;
}

.header-title {
  font-size: 48px;
  font-weight: 700;
  color: #4a90e2;
  margin-bottom: 60px;
  text-align: center;
  letter-spacing: -0.5px;
}

.auth-container {
  background: white;
  padding: 50px;
  border-radius: 20px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  width: 100%;
  max-width: 700px;
  position: relative;
}

.auth-title {
  font-size: 42px;
  font-weight: 700;
  color: #000;
  text-align: center;
  margin-bottom: 50px;
}

.form-container {
  position: relative;
}

.auth-form {
  display: none;
}

.auth-form.active {
  display: block;
  animation: fadeIn 0.3s ease-in;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.form-group {
  margin-bottom: 30px;
}

.form-label {
  display: block;
  font-size: 16px;
  color: #999;
  margin-bottom: 10px;
  font-weight: 400;
}

.form-input {
  width: 100%;
  padding: 20px 25px;
  font-size: 16px;
  border: 2px solid #ddd;
  border-radius: 50px;
  outline: none;
  transition: border-color 0.3s ease;
  background-color: #fff;
}

.form-input:focus {
  border-color: #4a90e2;
}

.form-input.error {
  border-color: #ff6b6b;
}

.error-message {
  color: #ff6b6b;
  font-size: 13px;
  margin-top: 5px;
  margin-left: 15px;
  display: none;
}

.error-message.show {
  display: block;
}

.forgot-password {
  display: block;
  text-align: right;
  font-size: 14px;
  color: #999;
  text-decoration: none;
  margin-top: 8px;
  transition: color 0.3s ease;
}

.forgot-password:hover {
  color: #4a90e2;
}

.remember-me-container {
  margin-top: 20px;
  margin-bottom: 10px;
}

.remember-me-label {
  display: flex;
  align-items: center;
  cursor: pointer;
  user-select: none;
}

.remember-checkbox {
  width: 18px;
  height: 18px;
  margin-right: 10px;
  cursor: pointer;
  accent-color: #4a90e2;
}

.remember-text {
  font-size: 15px;
  color: #333;
}

.submit-button {
  width: 100%;
  padding: 20px;
  font-size: 20px;
  font-weight: 600;
  color: white;
  background: linear-gradient(135deg, #4a90e2 0%, #5ba3f5 100%);
  border: none;
  border-radius: 50px;
  cursor: pointer;
  margin-top: 30px;
  transition: all 0.3s ease;
  box-shadow: 0 4px 15px rgba(74, 144, 226, 0.3);
}

.submit-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(74, 144, 226, 0.4);
}

.submit-button:active {
  transform: translateY(0);
}

.toggle-text {
  text-align: center;
  margin-top: 25px;
  font-size: 16px;
  color: #333;
}

.toggle-link {
  color: #4a90e2;
  text-decoration: none;
  font-weight: 600;
  cursor: pointer;
  transition: color 0.3s ease;
}

.toggle-link:hover {
  color: #357abd;
  text-decoration: underline;
}

@media (max-width: 768px) {
  .header-title {
    font-size: 32px;
    margin-bottom: 40px;
  }

  .auth-container {
    padding: 30px 25px;
  }

  .auth-title {
    font-size: 32px;
    margin-bottom: 35px;
  }

  .form-input {
    padding: 16px 20px;
  }

  .submit-button {
    padding: 16px;
    font-size: 18px;
  }
}

@media (max-width: 480px) {
  body {
    padding: 20px 15px;
  }

  .header-title {
    font-size: 24px;
  }

  .auth-container {
    padding: 25px 20px;
  }

  .auth-title {
    font-size: 28px;
  }
}
.back-home-btn {
  display: inline-block;
  margin: 15px 0 20px 20px;
  padding: 8px 16px;
  background-color: #4a90e2;
  color: white;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-size: 14px;
  transition: background 0.3s ease;
}

.back-home-btn:hover {
  background-color: #357ab7;
}

/* Admin login button — visually same as back-home but spaced nicely */
.admin-login-btn {
  margin-left: 12px;
}

/* On small screens stack the buttons vertically */
@media (max-width: 480px) {
  .back-home-btn,
  .admin-login-btn {
    display: block;
    width: auto;
    margin-left: 0;
    margin-bottom: 10px;
  }
}

/* Back to homepage button styling */
.back-home-container {
  text-align: left;
  max-width: 800px;
  margin: 10px auto 20px;
  padding: 0 20px;
}

.back-home-btn {
  display: inline-block;
  background-color: #4a90e2;
  color: white;
  padding: 8px 16px;
  border-radius: 6px;
  text-decoration: none;
  font-weight: 600;
  transition: background 0.3s ease;
}

.back-home-btn:hover {
  background-color: #357ab7;
}
.submit-button {
  position: relative;
  transition: transform 0.5s ease;
}

.auth-container {
  position: relative;
  overflow: hidden; /* keeps the button inside */
}
/* Make the button movable */
.submit-button {
  position: relative;
  transition: transform 0.5s ease;
}

/* Prevent it from leaving the box */
.auth-container {
  position: relative;
  overflow: hidden;
}

/* 🌀 Shake animation */
@keyframes shake {
  0%, 100% { transform: translateX(0); }
  20%, 60% { transform: translateX(-10px); }
  40%, 80% { transform: translateX(10px); }
}

.shake {
  animation: shake 0.5s ease;
}
/* Make the button movable */
.submit-button {
  position: relative;
  transition: transform 0.5s ease;
}

/* Keep it inside the form */
.auth-container {
  position: relative;
  overflow: hidden;
}

/* 🌀 Shake animation */
@keyframes shake {
  0%, 100% { transform: translateX(0); }
  20%, 60% { transform: translateX(-10px); }
  40%, 80% { transform: translateX(10px); }
}

.shake {
  animation: shake 0.5s ease;
}

/* 🪩 Smooth bounce-back easing handled by JS */
.submit-button {
  position: relative;
  transition: transform 0.5s ease;
}

.auth-container {
  position: relative;
  overflow: hidden;
}

@keyframes shake {
  0%, 100% { transform: translateX(0); }
  20%, 60% { transform: translateX(-10px); }
  40%, 80% { transform: translateX(10px); }
}

.shake {
  animation: shake 0.5s ease;
}
.submit-button {
  position: relative;
  transition: transform 0.5s ease;
}

/* Toast notification for login errors */
.site-toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(0, 0, 0, 0.85);
  color: #fff;
  padding: 12px 18px;
  border-radius: 8px;
  z-index: 9999;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.2);
  font-size: 14px;
}

.auth-container {
  position: relative;
  overflow: hidden;
}

@keyframes shake {
  0%, 100% { transform: translateX(0); }
  20%, 60% { transform: translateX(-10px); }
  40%, 80% { transform: translateX(10px); }
}

.shake {
  animation: shake 0.5s ease;
}
