/**
 * Tela de login — sempre em tema claro (o painel branco do formulário não
 * segue [data-theme="escuro"], é intencional: login.php não carrega
 * theme.js, então as variáveis de :root já resolvem pro claro sozinhas).
 */

.auth-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  background: #12132b;
}

@media (max-width: 860px) {
  .auth-shell {
    grid-template-columns: 1fr;
  }
  .auth-intro {
    display: none;
  }
}

/* ---------- Painel de marca (esquerda) ---------- */

.auth-intro {
  position: relative;
  overflow: hidden;
  background: linear-gradient(158deg, #1d1e3d 0%, #12132b 55%, #0d0e20 100%);
  padding: 52px 56px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 36px;
  color: #f4f4fa;
}

.auth-intro::before {
  content: "";
  position: absolute;
  top: -160px;
  right: -130px;
  width: 440px;
  height: 440px;
  border-radius: 50%;
  background: radial-gradient(circle at 30% 30%, rgba(99, 102, 241, 0.36), rgba(99, 102, 241, 0) 70%);
}

.auth-intro::after {
  content: "";
  position: absolute;
  inset: 0;
  opacity: 0.5;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.045) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: linear-gradient(to bottom, #000, transparent 88%);
}

.auth-intro > * {
  position: relative;
}

.auth-wordmark {
  display: flex;
  align-items: center;
  gap: 12px;
}

.auth-wordmark .brand-mark {
  width: 40px;
  height: 40px;
  flex: none;
  position: relative;
}

.brand-mark span {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 29px;
  height: 29px;
  transform: translate(-50%, -50%) rotate(45deg);
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-template-rows: 1fr 1fr;
  gap: 2.5px;
}

.brand-mark span i {
  border-radius: 1.5px;
}

.brand-mark span i:nth-child(1) { background: #4b4a72; }
.brand-mark span i:nth-child(2) { background: #7a72ff; }
.brand-mark span i:nth-child(3) { background: #7a72ff; }
.brand-mark span i:nth-child(4) { background: #f4f4fa; }

.auth-wordmark strong {
  font-size: 16.5px;
  font-weight: 750;
  letter-spacing: -0.015em;
}

.auth-wordmark strong em {
  font-style: normal;
  color: #8b84ff;
}

.auth-pitch {
  max-width: 460px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.auth-pitch h1 {
  margin: 0;
  color: #f7f7fc;
  font-size: 42px;
  line-height: 1.1;
  font-weight: 800;
  letter-spacing: -0.03em;
  text-wrap: balance;
}

.auth-pitch p.lead {
  margin: 0;
  color: #9b9ab8;
  font-size: 15.5px;
  line-height: 1.6;
}

.auth-features {
  list-style: none;
  margin: 4px 0 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 11px;
}

.auth-features li {
  display: flex;
  align-items: center;
  gap: 11px;
  color: #c6c5da;
  font-size: 14.5px;
}

.auth-features li::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #7a72ff;
  flex: none;
}

.auth-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  color: #5d5c78;
  font-size: 12.5px;
}

/* ---------- Painel do formulário (direita) ---------- */

.auth-panel {
  background: #f4f4f8;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 48px 32px;
}

.auth-card {
  width: 100%;
  max-width: 400px;
  background: #fff;
  border: 1px solid #e6e6ef;
  border-radius: var(--radius-lg);
  box-shadow: 0 24px 60px -32px rgba(18, 19, 43, 0.28);
  padding: 34px 34px 28px;
}

.auth-card-head {
  margin-bottom: 22px;
}

.auth-card-head h2 {
  margin: 0 0 6px;
  font-size: 22px;
  font-weight: 750;
  letter-spacing: -0.02em;
  color: #14152e;
}

.auth-card-head p {
  margin: 0;
  font-size: 14px;
  color: #6f6e88;
}

.auth-panel .form-error {
  display: flex;
  gap: 9px;
  align-items: flex-start;
  background: #fdf2f2;
  border: 1px solid #f6d5d5;
  color: #a3312f;
  border-radius: 11px;
  padding: 11px 13px;
  font-size: 13.5px;
  line-height: 1.45;
  margin: 0 0 18px;
}

.auth-panel .field label {
  color: #3d3c58;
}

.auth-panel input[type="email"],
.auth-panel input[type="password"] {
  height: 44px;
  background: #fbfbfd;
  border-color: #dcdce8;
  color: #14152e;
}

.auth-panel input[type="email"]:focus,
.auth-panel input[type="password"]:focus {
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px var(--color-primary-soft);
  background: #fff;
}

.auth-field-label-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
}

.auth-field-label-row a {
  font-size: 12.5px;
  font-weight: 500;
  color: var(--color-primary);
}

.auth-checkbox {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 13.5px;
  color: #4a4964;
  cursor: pointer;
  margin: -3px 0 15px;
}

.auth-checkbox input {
  width: 16px;
  height: 16px;
  accent-color: var(--color-primary);
  margin: 0;
  cursor: pointer;
}

.auth-password-wrap {
  position: relative;
}

.auth-password-toggle {
  position: absolute;
  right: 6px;
  top: 6px;
  height: 32px;
  padding: 0 10px;
  border: none;
  background: transparent;
  font-family: inherit;
  font-size: 12.5px;
  font-weight: 600;
  color: #6f6e88;
  border-radius: 7px;
  cursor: pointer;
}

.auth-password-toggle:hover {
  background: #f1f1f7;
  color: #14152e;
}

.auth-panel .btn-primary {
  width: 100%;
  height: 46px;
  margin-top: 6px;
  font-size: 15px;
  box-shadow: 0 10px 22px -12px rgba(79, 70, 229, 0.85);
}

.auth-hint {
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid #eeeef4;
  text-align: center;
  font-size: 12.5px;
  color: #9a99b0;
}
