:root {
  --paper: #f5f9fc;
  --white: #ffffff;
  --ink: #102033;
  --muted: #5a6b7b;
  --faint: #7d8e9f;
  --rule: #dce6ef;
  --blue: #075ff7;
  --blue-dark: #0349c8;
  --cyan: #00c9ee;
  --navy: #061d3b;
  --danger: #a4262c;
  --danger-pale: #fdf3f4;
}

* { box-sizing: border-box; }

html, body { height: 100%; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: 'Segoe UI', system-ui, -apple-system, 'Helvetica Neue', Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}

.login-shell {
  position: relative;
  min-height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 28px;
  padding: 32px 16px;
  overflow: hidden;
}

/* Motivo de fundo desenhado em CSS: o logo e um JPEG sem canal alfa e nao
   funciona como marca d'agua esmaecida. */
.login-glow {
  position: absolute;
  border-radius: 50%;
  filter: blur(8px);
  pointer-events: none;
}

.login-glow-start {
  width: 520px;
  height: 520px;
  top: -220px;
  left: -180px;
  background: radial-gradient(circle at center, rgba(7, 95, 247, .13), rgba(7, 95, 247, 0) 68%);
}

.login-glow-end {
  width: 640px;
  height: 640px;
  right: -260px;
  bottom: -280px;
  background: radial-gradient(circle at center, rgba(0, 201, 238, .16), rgba(0, 201, 238, 0) 68%);
}

.login-card {
  position: relative;
  width: 100%;
  max-width: 420px;
  background: var(--white);
  border: 1px solid var(--rule);
  border-radius: 14px;
  box-shadow: 0 14px 38px rgba(7, 64, 113, .12);
  padding: 40px 44px 36px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.login-card::before {
  content: '';
  position: absolute;
  inset: 0 0 auto;
  height: 4px;
  border-radius: 14px 14px 0 0;
  background: linear-gradient(90deg, var(--blue), var(--cyan));
}

.login-logo {
  width: 168px;
  max-width: 70%;
  height: auto;
  margin-bottom: 26px;
}

.login-title {
  margin: 0;
  font-size: 1.5rem;
  line-height: 1.25;
  font-weight: 700;
  color: var(--navy);
  letter-spacing: -.01em;
}

.login-subtitle {
  margin: 10px 0 0;
  font-size: .9375rem;
  line-height: 1.55;
  color: var(--muted);
}

.login-message {
  width: 100%;
  margin: 22px 0 0;
  padding: 12px 14px;
  border: 1px solid #f0d4d6;
  border-radius: 8px;
  background: var(--danger-pale);
  color: var(--danger);
  font-size: .8125rem;
  line-height: 1.5;
  text-align: left;
}

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

.login-button {
  width: 100%;
  margin-top: 26px;
  min-height: 46px;
  padding: 0 18px;
  border: none;
  border-radius: 10px;
  background: var(--blue);
  color: var(--white);
  font-size: .9375rem;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: background .15s ease;
}

.login-button:hover:not(:disabled) { background: var(--blue-dark); }

.login-button:focus-visible {
  outline: 3px solid rgba(7, 95, 247, .35);
  outline-offset: 2px;
}

.login-button:disabled {
  background: #e3ebf3;
  color: var(--faint);
  cursor: not-allowed;
}

.login-note {
  margin: 20px 0 0;
  padding-top: 18px;
  border-top: 1px solid var(--rule);
  width: 100%;
  font-size: .8125rem;
  color: var(--faint);
}

.login-footer {
  position: relative;
  margin: 0;
  font-size: .8125rem;
  color: var(--faint);
}

@media (max-width: 480px) {
  .login-card { padding: 32px 24px 28px; }
  .login-glow { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  .login-button { transition: none; }
}
