/* Animations */
@-webkit-keyframes spin {
    0% { -webkit-transform: rotate(0deg); transform: rotate(0deg); }
    100% { -webkit-transform: rotate(360deg); transform: rotate(360deg); }
}
@keyframes spin {
    0% { -webkit-transform: rotate(0deg); transform: rotate(0deg); }
    100% { -webkit-transform: rotate(360deg); transform: rotate(360deg); }
}

/* Global Styles */
* {
  margin: 0;
  padding: 0;
  -webkit-box-sizing: border-box;
  box-sizing: border-box;
  font-family: Arial, sans-serif;
}

body {
  display: -webkit-box;
  display: -ms-flexbox;
  display: flex;
  -webkit-box-pack: center;
  -ms-flex-pack: center;
  justify-content: center;
  -webkit-box-align: center;
  -ms-flex-align: center;
  -webkit-box-orient: vertical;
  -webkit-box-direction: normal;
      -ms-flex-direction: column;
          flex-direction: column;
  align-items: center;
  height: 100vh;
  background: #fff;
}

/* Login Container */
.login-container {
  background: rgba(255, 255, 255, 0.1);
  padding: 2rem;
  border-radius: 10px;
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  -webkit-box-shadow: 0 0 10px rgba(255, 255, 255, 0.2);
  box-shadow: 0 0 10px rgba(255, 255, 255, 0.2);
  text-align: center;
  width: 300px;
}

.login-container h2 {
  color: #121212;
  margin-bottom: 1.5rem;
}

.login-container h2 a {
  color: #121212;
  text-decoration: none;
}

.login-container h2 a:hover {
  color: #ff6600;
}

/* Input Groups */
.input-group {
  position: relative;
  margin-bottom: 1rem;
}

.input-group input {
  width: 100%;
  padding: 10px;
  padding-left: 35px;
  border: 1px solid #121212;
  outline: none;
  border-radius: 5px;
  background: rgba(255, 255, 255, 0.2);
  color: #121212;
  font-size: 1rem;
}

.input-group input:focus {
  outline: 2px solid #ff6600;
  outline-offset: 2px;
  border-color: #ff6600;
}

.input-group input:invalid {
  border-color: #dc3545;
}

.input-group input:valid {
  border-color: #28a745;
}

.input-group i {
  position: absolute;
  left: 10px;
  top: 50%;
  -webkit-transform: translateY(-50%);
  -ms-transform: translateY(-50%);
  transform: translateY(-50%);
  color: #ccc;
}

/* Button Styles */
.login-btn {
  width: 100%;
  padding: 10px;
  border: none;
  border-radius: 5px;
  background: #ff6600;
  color: #fff;
  font-size: 1rem;
  cursor: pointer;
  -webkit-transition: background 0.3s ease-in-out;
  -o-transition: background 0.3s ease-in-out;
  transition: background 0.3s ease-in-out;
}

.login-btn:hover:not(:disabled) {
  background: #cc5200;
}

.login-btn:disabled {
  background-color: #6c757d;
  cursor: not-allowed;
  opacity: 0.6;
}

/* Form Links */
.form-links {
  text-align: center;
  margin-top: 20px;
}

.forgot-password {
  display: block;
  margin-top: 1rem;
  color: #bbb;
  font-size: 0.9rem;
  text-decoration: none;
}

.forgot-password:hover {
  color: #ff6600;
}

/* Messages */
.error-message {
  background-color: rgba(248, 215, 218, 0.9);
  color: #721c24;
  padding: 12px;
  border-radius: 5px;
  border: 1px solid #f5c6cb;
  margin-bottom: 20px;
  font-size: 0.9rem;
}

.success-message {
  background-color: rgba(212, 237, 218, 0.9);
  color: #155724;
  padding: 12px;
  border-radius: 5px;
  border: 1px solid #c3e6cb;
  margin-bottom: 20px;
  font-size: 0.9rem;
}

/* Password Requirements (for registration page) */
.password-requirements {
  margin: 10px 0;
  padding: 10px;
  background-color: rgba(248, 249, 250, 0.9);
  border-radius: 5px;
  font-size: 0.9em;
  text-align: left;
}

.password-requirements ul {
  margin: 5px 0 0 20px;
  padding: 0;
}

.password-requirements li {
  margin: 2px 0;
  color: #666;
}

/* Spinner */
.spinner {
  display: inline-block;
  width: 18px;
  height: 18px;
  border: 3px solid white;
  border-top: 3px solid rgba(255, 255, 255, 0.5);
  border-radius: 50%;
  -webkit-animation: spin 1s linear infinite;
  animation: spin 1s linear infinite;
  margin-left: 8px;
}

/* Responsive Design */
@media (max-width: 480px) {
  .login-container {
    width: 90%;
    padding: 1.5rem;
  }
}