:root {
  --primary-blue: #1e3a8a;
  --secondary-blue: #3b82f6;
  --accent-blue: #60a5fa;
  --light-blue: #dbeafe;
  --dark-blue: #1e40af;
  --success-green: #10b981;
  --warning-orange: #f59e0b;
  --danger-red: #ef4444;
  --text-dark: #1f2937;
  --text-light: #6b7280;
  --bg-light: #f8fafc;
}

body {
  background: linear-gradient(
    135deg,
    var(--primary-blue) 0%,
    var(--dark-blue) 100%
  );
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
}

.login-container {
  background: white;
  border-radius: 20px;
  box-shadow: 0 25px 50px rgba(0, 0, 0, 0.15);
  padding: 50px;
  max-width: 450px;
  width: 100%;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.login-header {
  text-align: center;
  margin-bottom: 40px;
}

.login-header .logo {
  font-size: 2.5rem;
  color: var(--primary-blue);
  margin-bottom: 15px;
}

.login-header h1 {
  color: var(--text-dark);
  font-weight: 700;
  margin-bottom: 10px;
  font-size: 2rem;
}

.login-header p {
  color: var(--text-light);
  font-size: 16px;
  margin-bottom: 0;
}

.form-group {
  margin-bottom: 25px;
}

.form-control {
  border-radius: 12px;
  border: 2px solid #e5e7eb;
  padding: 15px 20px;
  font-size: 16px;
  transition: all 0.3s ease;
  background: var(--bg-light);
}

.form-control:focus {
  border-color: var(--secondary-blue);
  box-shadow: 0 0 0 0.3rem rgba(59, 130, 246, 0.15);
  background: white;
}

.btn-login {
  background: linear-gradient(
    135deg,
    var(--secondary-blue) 0%,
    var(--primary-blue) 100%
  );
  border: none;
  border-radius: 12px;
  padding: 15px;
  font-weight: 600;
  font-size: 16px;
  width: 100%;
  transition: all 0.3s ease;
  color: white;
}

.btn-login:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(59, 130, 246, 0.3);
  background: linear-gradient(
    135deg,
    var(--primary-blue) 0%,
    var(--dark-blue) 100%
  );
}

.btn-login:disabled {
  opacity: 0.7;
  transform: none;
}

.alert {
  border-radius: 12px;
  border: none;
  font-weight: 500;
}

.input-group-text {
  background: var(--bg-light);
  border: 2px solid #e5e7eb;
  border-right: none;
  border-radius: 12px 0 0 12px;
  color: var(--text-light);
}

.input-group .form-control {
  border-left: none;
  border-radius: 0 12px 12px 0;
}

.loading {
  display: none;
}

.spinner-border-sm {
  width: 1rem;
  height: 1rem;
}

.footer-text {
  text-align: center;
  margin-top: 30px;
  padding-top: 20px;
  border-top: 1px solid #e5e7eb;
}

.footer-text small {
  color: var(--text-light);
  font-size: 14px;
}

/* Responsive adjustments */
@media (max-width: 576px) {
  .login-container {
    margin: 20px;
    padding: 30px;
  }

  .login-header h1 {
    font-size: 1.75rem;
  }
}

/* Logo image sizing moved from inline style to CSS to comply with CSP */
.login-header .logo img,
.logo-img {
  height: 64px;
  width: auto;
}

/* Password change modal z-index moved from inline style to CSS to comply with CSP */
#changePasswordModal {
    z-index: 9999 !important;
}

#changePasswordModal .modal-dialog {
    z-index: 10000 !important;
}

/* Fix the backdrop */
.modal-backdrop {
    z-index: 9998 !important;
}

/* Ensure modal shows above everything */
#changePasswordModal.show {
    z-index: 9999 !important;
}