/* assets/css/auth.css
   Estilo das telas de autenticação (login / logout).
   Estrutura herdada do padrão visual do app rh_whatsapp (MeuRH),
   recolorida para a identidade do JANOS: fundo grafite neutro e o
   azul da marca (--auth-accent) como único ponto de cor (foco/links). */

:root {
  --auth-accent: #1565d8; /* azul da logo JANOS */
  --auth-accent-rgb: 21, 101, 216;
}

.auth-card {
  width: 100%;
  max-width: 420px;
  background: var(--card-bg);
  border-radius: 16px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  overflow: hidden;
  animation: authSlideUp 0.5s ease-out;
}

@keyframes authSlideUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.auth-header {
  text-align: center;
  padding: 2.5rem 2rem 1.5rem;
}

.auth-logo {
  width: 100px;
  height: 100px;
  margin: 0 auto 1.25rem;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(4px);
  border: 1px solid rgba(255, 255, 255, 0.15);
  padding: 12px;
}

.auth-logo img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.auth-header h2 {
  margin: 0;
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text-color);
}

.auth-header p {
  margin: 0.35rem 0 0;
  color: var(--muted-color);
  font-size: 0.9rem;
}

.auth-body {
  padding: 0 2rem 2rem;
}

.auth-body .form-label {
  font-weight: 500;
  color: var(--text-color);
  margin-bottom: 0.4rem;
  font-size: 0.875rem;
}

.auth-body .form-control {
  border: 1.5px solid var(--divider);
  border-radius: 10px;
  padding: 0.7rem 1rem;
  font-size: 0.95rem;
  background: var(--card-bg);
  color: var(--text-color);
  transition:
    border-color 0.2s,
    box-shadow 0.2s;
}

.auth-body .form-control:focus {
  border-color: var(--auth-accent);
  box-shadow: 0 0 0 0.2rem rgba(var(--auth-accent-rgb), 0.18);
}

.auth-body .input-group .form-control {
  border-right: none;
}

.auth-body .input-group .btn-toggle-pw {
  border: 1.5px solid var(--divider);
  border-left: none;
  background: var(--card-bg);
  color: var(--muted-color);
  border-radius: 0 10px 10px 0;
  transition: color 0.15s;
}

.auth-body .input-group .btn-toggle-pw:hover {
  color: var(--text-color);
}

.auth-body .form-check-input:checked {
  background-color: var(--auth-accent);
  border-color: var(--auth-accent);
}

.btn-auth {
  background: linear-gradient(135deg, #1f2937 0%, #111827 100%);
  border: none;
  color: #fff;
  font-weight: 600;
  padding: 0.8rem 1.5rem;
  border-radius: 10px;
  font-size: 1rem;
  transition:
    transform 0.2s,
    box-shadow 0.2s,
    opacity 0.2s;
}

.btn-auth:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(17, 24, 39, 0.4);
  color: #fff;
}

.btn-auth:disabled {
  opacity: 0.7;
  cursor: not-allowed;
}

.btn-auth-outline {
  background: transparent;
  border: 1.5px solid var(--divider);
  color: var(--text-color);
  font-weight: 600;
  padding: 0.8rem 1.5rem;
  border-radius: 10px;
  font-size: 1rem;
  transition: all 0.2s;
}

.btn-auth-outline:hover {
  background: var(--divider);
  color: var(--text-color);
}

.auth-footer {
  text-align: center;
  padding: 1.25rem 2rem;
  border-top: 1px solid var(--divider);
}

.auth-footer a {
  color: var(--auth-accent);
  text-decoration: none;
  font-weight: 500;
}

.auth-footer a:hover {
  text-decoration: underline;
}

.auth-link-forgot a {
  font-size: 0.85rem;
  color: var(--muted-color);
  text-decoration: none;
}

.auth-link-forgot a:hover {
  color: var(--auth-accent);
}

.auth-overlay {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.35);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 1050;
  padding: 1rem;
}

.auth-overlay .auth-card,
.auth-overlay-login .auth-card {
  animation: authModalPop 0.35s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@keyframes authModalPop {
  from {
    opacity: 0;
    transform: scale(0.9) translateY(20px);
  }
  to {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

.auth-overlay-login {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1050;
  padding: 1rem;
  /* Gradiente grafite neutro com dot-pattern sobreposto para textura */
  background-color: #111827;
  background-image:
    radial-gradient(rgba(255, 255, 255, 0.06) 1px, transparent 1px),
    linear-gradient(135deg, #0b1120 0%, #1f2937 55%, #111827 100%);
  background-size: 22px 22px, 100% 100%;
}

@media (max-width: 576px) {
  .auth-card {
    border-radius: 12px;
  }
  .auth-header {
    padding: 2rem 1.5rem 1rem;
  }
  .auth-body {
    padding: 0 1.5rem 1.5rem;
  }
  .auth-footer {
    padding: 1rem 1.5rem;
  }
}
