* { margin: 0; padding: 0; box-sizing: border-box; }

:root {
  --blue:  #1F4E78;
  --blue2: #2c5aa0;
  --gold:  #C9A84C;
  --white: #ffffff;
  --light: #f0f4f8;
  --red:   #dc3545;
}

body {
  font-family: 'Segoe UI', sans-serif;
  background: linear-gradient(135deg, #0f2744 0%, #1F4E78 50%, #2c5aa0 100%);
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

.login-page {
  width: 100%;
  padding: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.login-card {
  background: var(--white);
  border-radius: 16px;
  padding: 40px 36px 32px;
  width: 100%;
  max-width: 420px;
  box-shadow: 0 20px 60px rgba(0,0,0,0.35);
}

/* Logo */
.logo-wrap {
  text-align: center;
  margin-bottom: 24px;
}
.login-logo {
  width: 180px;
  height: auto;
  object-fit: contain;
}

/* Headings */
.login-title {
  text-align: center;
  color: var(--blue);
  font-size: 22px;
  font-weight: 700;
  margin-bottom: 6px;
}
.login-sub {
  text-align: center;
  color: #666;
  font-size: 14px;
  margin-bottom: 28px;
}

/* Error box */
.error-box {
  background: #fff5f5;
  border: 1px solid #f5c6cb;
  color: var(--red);
  border-radius: 8px;
  padding: 12px 16px;
  font-size: 14px;
  margin-bottom: 20px;
}

/* Form fields */
.field {
  margin-bottom: 18px;
}
.field label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: #444;
  margin-bottom: 7px;
}
.field input {
  width: 100%;
  padding: 12px 14px;
  border: 1.5px solid #dee2e6;
  border-radius: 8px;
  font-size: 15px;
  transition: border-color 0.2s, box-shadow 0.2s;
  color: #212529;
}
.field input:focus {
  outline: none;
  border-color: var(--blue);
  box-shadow: 0 0 0 3px rgba(31,78,120,0.12);
}

/* Button */
.btn-login {
  width: 100%;
  padding: 13px;
  background: linear-gradient(135deg, var(--blue), var(--blue2));
  color: white;
  border: none;
  border-radius: 8px;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  margin-top: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  transition: transform 0.15s, box-shadow 0.15s;
}
.btn-login:hover:not(:disabled) {
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(31,78,120,0.35);
}
.btn-login:disabled { opacity: 0.7; cursor: not-allowed; }

/* Spinner */
.spinner {
  width: 18px;
  height: 18px;
  border: 2px solid rgba(255,255,255,0.4);
  border-top-color: white;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* Footer */
.login-footer {
  text-align: center;
  font-size: 12px;
  color: #aaa;
  margin-top: 24px;
}

@media (max-width: 480px) {
  .login-card { padding: 30px 22px 24px; }
  .login-logo { width: 150px; }
}
