@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap');

:root {
  --bg-dark: #0b1120;
  --bg-panel: #0f172a;
  --surface-glass: rgba(255, 255, 255, 0.06);
  --surface-glass-strong: rgba(255, 255, 255, 0.1);
  --border-glass: rgba(255, 255, 255, 0.12);
  --border-subtle: rgba(148, 163, 184, 0.2);
  --accent: #3b82f6;
  --accent-hover: #2563eb;
  --accent-glow: rgba(59, 130, 246, 0.25);
  --text-primary: #f1f5f9;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;
  --white: #ffffff;
  --radius: 12px;
  --radius-lg: 20px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
  height: 100%;
}

body {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  color: var(--text-primary);
  background: var(--bg-dark);
  -webkit-font-smoothing: antialiased;
}

.login-page {
  display: flex;
  min-height: 100vh;
}

/* ── Hero ── */
.login-hero {
  position: relative;
  flex: 0 0 58%;
  background: url("/static/imagens/login_fundo/login_fundo.png") no-repeat center center;
  background-size: cover;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  overflow: hidden;
}

.login-hero__overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(135deg, rgba(11, 17, 32, 0.55) 0%, rgba(15, 23, 42, 0.25) 50%, rgba(11, 17, 32, 0.7) 100%),
    linear-gradient(to top, rgba(11, 17, 32, 0.85) 0%, transparent 60%);
  pointer-events: none;
}

.login-hero__brand {
  position: absolute;
  top: 2rem;
  left: 2.5rem;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.login-hero__brand-dot {
  width: 8px;
  height: 8px;
  background: var(--accent);
  border-radius: 50%;
  box-shadow: 0 0 12px var(--accent-glow);
}

.login-hero__brand-text {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.7);
}

.login-hero__highlights {
  position: relative;
  z-index: 2;
  margin: 0 2rem 2.5rem;
  padding: 1.5rem 1.75rem;
  background: var(--surface-glass);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-lg);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}

.highlights-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.25rem;
}

.highlight-item {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.highlight-item__icon {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
  font-size: 1.1rem;
}

.highlight-item__title {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--white);
  margin: 0;
  line-height: 1.3;
  letter-spacing: -0.01em;
}

.highlight-item__desc {
  font-size: 0.72rem;
  color: var(--text-secondary);
  margin: 0;
  line-height: 1.5;
}

/* ── Painel de login ── */
.login-panel {
  flex: 0 0 42%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2.5rem 2rem;
  background:
    radial-gradient(ellipse at 20% 50%, rgba(59, 130, 246, 0.08) 0%, transparent 50%),
    radial-gradient(ellipse at 80% 80%, rgba(59, 130, 246, 0.05) 0%, transparent 40%),
    var(--bg-panel);
  position: relative;
}

.login-panel::before {
  content: '';
  position: absolute;
  inset: 0;
  background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23334155' fill-opacity='0.15'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
  opacity: 0.4;
  pointer-events: none;
}

.login-card {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 380px;
  padding: 2.5rem 2rem;
  background: var(--surface-glass);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-lg);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.04) inset,
    0 24px 48px rgba(0, 0, 0, 0.3);
}

.login-card__logo {
  width: 160px;
  max-width: 70%;
  margin-bottom: 1.75rem;
  filter: brightness(1.1);
}

.login-card__welcome {
  font-size: 0.8125rem;
  color: var(--text-secondary);
  font-weight: 400;
  margin: 0 0 0.35rem;
  line-height: 1.5;
  letter-spacing: 0.01em;
}

.login-card__title {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--white);
  margin: 0 0 1.75rem;
  letter-spacing: -0.03em;
}

.login-card .messages {
  margin-bottom: 1rem;
}

.alert-message {
  background: rgba(251, 191, 36, 0.12);
  color: #fcd34d;
  padding: 0.75rem 1rem;
  margin-bottom: 0.5rem;
  border: 1px solid rgba(251, 191, 36, 0.25);
  border-radius: var(--radius);
  font-size: 0.8125rem;
  text-align: center;
}

.input-group {
  position: relative;
  margin-top: 0.75rem;
}

.input-group label {
  display: block;
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--text-secondary);
  margin-bottom: 0.35rem;
  letter-spacing: 0.02em;
}

.input-group input {
  width: 100%;
  padding: 0.7rem 0.85rem;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius);
  font-size: 0.9375rem;
  font-family: inherit;
  color: var(--text-primary);
  background: rgba(15, 23, 42, 0.6);
  transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
}

.input-group input::placeholder {
  color: var(--text-muted);
}

.input-group input:focus {
  outline: none;
  border-color: var(--accent);
  background: rgba(15, 23, 42, 0.8);
  box-shadow: 0 0 0 3px var(--accent-glow);
}

.btn-entrar {
  width: 100%;
  padding: 0.8rem;
  margin-top: 1.5rem;
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-hover) 100%);
  color: var(--white);
  border: none;
  border-radius: var(--radius);
  font-size: 0.9375rem;
  font-weight: 600;
  font-family: inherit;
  letter-spacing: 0.01em;
  cursor: pointer;
  transition: transform 0.15s, box-shadow 0.2s, opacity 0.2s;
  box-shadow: 0 4px 16px var(--accent-glow);
}

.btn-entrar:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 24px var(--accent-glow);
}

.btn-entrar:active {
  transform: translateY(0);
}

.login-card__links {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.65rem;
  margin-top: 1.25rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--border-glass);
}

.link-reset {
  font-size: 0.8125rem;
  color: var(--text-secondary);
  text-decoration: none;
  transition: color 0.2s;
}

.link-reset:hover {
  color: var(--accent);
}

.link-secondary {
  font-size: 0.8125rem;
  color: var(--text-muted);
  text-decoration: none;
  transition: color 0.2s;
}

.link-secondary:hover {
  color: var(--text-secondary);
}

.btn-assinar {
  display: block;
  width: 100%;
  margin-top: 1rem;
  padding: 0.7rem 1rem;
  background: transparent;
  color: var(--text-secondary);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius);
  font-size: 0.8125rem;
  font-weight: 500;
  font-family: inherit;
  text-align: center;
  text-decoration: none;
  transition: border-color 0.2s, color 0.2s, background 0.2s;
}

.btn-assinar:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: rgba(59, 130, 246, 0.06);
}

.login-card__social {
  display: flex;
  justify-content: center;
  gap: 1.25rem;
  margin-top: 1.5rem;
}

.login-card__social a {
  color: var(--text-muted);
  font-size: 1.1rem;
  text-decoration: none;
  transition: color 0.2s, transform 0.2s;
}

.login-card__social a:hover {
  color: var(--text-secondary);
  transform: translateY(-2px);
}

.login-card__footer {
  margin-top: 1.75rem;
  text-align: center;
  font-size: 0.6875rem;
  color: var(--text-muted);
  letter-spacing: 0.04em;
}

/* ── Mobile ── */
@media (max-width: 991px) {
  .login-page {
    flex-direction: column;
  }

  .login-hero {
    flex: none;
    min-height: 240px;
  }

  .login-hero__brand {
    top: 1.25rem;
    left: 1.25rem;
  }

  .login-hero__highlights {
    margin: 0 1rem 1rem;
    padding: 1.15rem;
  }

  .highlights-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
  }

  .login-panel {
    flex: 1;
    padding: 1.5rem 1rem 2rem;
  }

  .login-card {
    padding: 2rem 1.5rem;
  }
}

@media (max-width: 480px) {
  .login-hero {
    min-height: 200px;
  }

  .highlights-grid {
    grid-template-columns: 1fr 1fr;
    gap: 0.85rem;
  }

  .highlight-item__desc {
    display: none;
  }

  .login-card__title {
    font-size: 1.35rem;
  }
}
