/* Login static page styles. Independent of Vite/SPA build. */
* { box-sizing: border-box; }

body {
  margin: 0;
  background:
    radial-gradient(circle at 20% 18%, rgba(46, 134, 230, 0.12), transparent 32%),
    radial-gradient(circle at 82% 26%, rgba(46, 134, 230, 0.08), transparent 30%),
    #F4F9FF;
  color: #0E1E33;
  font-family: system-ui, -apple-system, 'Segoe UI', Roboto, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; }
input { font-family: inherit; }

.login-page {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

/* Logo */
.login-logo {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  text-decoration: none;
  margin-bottom: 28px;
}

.login-logo__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-template-rows: 1fr 1fr;
  gap: 2px;
  width: 26px;
  height: 26px;
}

.login-logo__grid > span {
  border-radius: 2px;
  display: block;
}

.login-logo__text {
  font-weight: 700;
  font-size: 22px;
  letter-spacing: 0.02em;
  color: #0E1E33;
}

/* Card */
.login-card {
  width: 100%;
  max-width: 420px;
  background: #ffffff;
  border-radius: 18px;
  padding: 36px 32px 32px;
  box-shadow: 0 24px 60px -28px rgba(15, 79, 168, 0.28);
}

.login-title {
  margin: 0 0 6px;
  font-size: 22px;
  font-weight: 700;
  text-align: center;
}

.login-subtitle {
  margin: 0 0 24px;
  text-align: center;
  font-size: 14.5px;
  color: #43546B;
}

/* Fields */
.login-field {
  margin-bottom: 16px;
}

.login-label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: #43546B;
  margin-bottom: 6px;
}

.login-input {
  width: 100%;
  height: 46px;
  padding: 0 14px;
  font-size: 15px;
  color: #0E1E33;
  background: #fff;
  border: 1.5px solid #D6E2F2;
  border-radius: 11px;
  outline: none;
  transition: border-color 0.15s, box-shadow 0.15s;
}

.login-input:focus {
  border-color: #2E86E6;
  box-shadow: 0 0 0 3px rgba(46, 134, 230, 0.15);
}

.login-input.is-invalid {
  border-color: #E5484D;
}

.login-error {
  display: none;
  margin-top: 5px;
  font-size: 12.5px;
  color: #E5484D;
}

/* Row: remember + forgot */
.login-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 6px 0 18px;
}

.login-checkbox {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 14px;
  color: #43546B;
  cursor: pointer;
  user-select: none;
}

.login-checkbox input {
  width: 16px;
  height: 16px;
  accent-color: #1668D6;
  cursor: pointer;
}

.login-link {
  font-size: 14px;
  font-weight: 600;
  color: #1668D6;
  text-decoration: none;
}

.login-link:hover { text-decoration: underline; }

/* Alert */
.login-alert {
  margin: 0 0 16px;
  padding: 11px 14px;
  background: #FDECEC;
  border: 1px solid #F4C9C9;
  color: #B53034;
  border-radius: 10px;
  font-size: 13.5px;
  line-height: 1.4;
}

/* Submit button */
.login-btn {
  width: 100%;
  height: 50px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  background: #1668D6;
  color: #fff;
  border: none;
  border-radius: 13px;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 8px 22px rgba(22, 104, 214, 0.28);
  transition: background 0.15s, box-shadow 0.15s;
}

.login-btn:hover:not(:disabled) {
  background: #0F4FA8;
  box-shadow: 0 10px 26px rgba(22, 104, 214, 0.38);
}

.login-btn:disabled {
  background: #9BBDE6;
  cursor: not-allowed;
  box-shadow: none;
}

.login-btn__spinner {
  width: 18px;
  height: 18px;
  border: 2.5px solid rgba(255, 255, 255, 0.45);
  border-top-color: #fff;
  border-radius: 50%;
  display: inline-block;
  animation: login-spin 0.7s linear infinite;
}

.login-btn__spinner[hidden] { display: none; }

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

@media (max-width: 480px) {
  .login-card { padding: 28px 20px; border-radius: 14px; }
  .login-title { font-size: 20px; }
  .login-row { flex-direction: column; align-items: flex-start; gap: 10px; }
}
