/* Tela de login — layout duas colunas, cores SIGCartório #0b2658 */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

.login-body {
  font-family: 'Plus Jakarta Sans', system-ui, sans-serif;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f5f0e8;
  padding: max(16px, env(safe-area-inset-top)) max(16px, env(safe-area-inset-right)) max(16px, env(safe-area-inset-bottom)) max(16px, env(safe-area-inset-left));
}

.login-root {
  display: flex;
  width: 100%;
  max-width: 820px;
  min-height: 520px;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 8px 48px rgba(0, 0, 0, 0.12);
}

/* Coluna esquerda — marca centralizada */
.login-left {
  flex: 1;
  background: #0b2658;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 2.5rem;
  position: relative;
  overflow: hidden;
}

.login-left::before {
  content: '';
  position: absolute;
  width: 320px;
  height: 320px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255,255,255,0.08) 0%, transparent 70%);
  top: -60px;
  left: -60px;
  pointer-events: none;
}

.login-left::after {
  content: '';
  position: absolute;
  width: 200px;
  height: 200px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255,255,255,0.05) 0%, transparent 70%);
  bottom: 40px;
  right: -40px;
  pointer-events: none;
}

.brand {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  position: relative;
  z-index: 1;
}

.brand-logo {
  max-height: 220px;
  width: auto;
  max-width: 360px;
  object-fit: contain;
  filter: brightness(0) invert(1);
}

.brand-icon {
  width: 120px;
  height: 120px;
  border-radius: 16px;
  background: rgba(255,255,255,0.2);
  display: flex;
  align-items: center;
  justify-content: center;
}

.login-left-wave {
  position: absolute;
  bottom: 0;
  left: 0;
  opacity: 0.12;
  color: #fff;
}

/* Coluna direita — formulário */
.login-right {
  flex: 1.1;
  background: #fff;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 3rem 2.5rem;
}

.login-title {
  font-family: 'Plus Jakarta Sans', system-ui, sans-serif;
  font-size: 26px;
  font-weight: 600;
  color: #1a1a1a;
  margin-bottom: 6px;
  text-align: center;
}

.login-subtitle {
  font-size: 13px;
  color: #888;
  margin-bottom: 2rem;
  font-weight: 300;
  text-align: center;
}

.field-group {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-bottom: 1rem;
}

.field-label {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #888;
}

.field-input {
  width: 100%;
  padding: 10px 14px;
  border: 0.5px solid #ddd;
  border-radius: 8px;
  background: #fafafa;
  color: #1a1a1a;
  font-family: inherit;
  font-size: 14px;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.field-input:focus {
  border-color: #0b2658;
  box-shadow: 0 0 0 3px rgba(11, 38, 88, 0.15);
}

.forgot {
  text-align: right;
  margin-top: -4px;
  margin-bottom: 1.5rem;
}

.forgot a {
  font-size: 12px;
  color: #0b2658;
  text-decoration: none;
}

.forgot a:hover {
  text-decoration: underline;
}

.login-back {
  text-align: center;
  margin-top: 1rem;
}

.login-back a {
  font-size: 13px;
  color: #0b2658;
  text-decoration: none;
}

.login-back a:hover {
  text-decoration: underline;
}

.login-link-box {
  margin: 1rem 0;
  padding: 12px 14px;
  font-size: 12px;
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  word-break: break-all;
}

.login-link-box a {
  color: #0b2658;
  text-decoration: none;
}

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

.btn-login {
  width: 100%;
  padding: 11px;
  background: #0b2658;
  color: #fff;
  border: none;
  border-radius: 8px;
  font-family: inherit;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  letter-spacing: 0.04em;
  transition: background 0.2s, transform 0.1s;
  margin-bottom: 1.2rem;
}

.btn-login:hover {
  background: #0d3073;
}

.btn-login:active {
  transform: scale(0.98);
}

.login-err {
  margin-bottom: 1.25rem;
  padding: 12px 14px;
  font-size: 0.875rem;
  color: #b91c1c;
  background: #fef2f2;
  border-radius: 8px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.login-err::before {
  content: "";
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%23b91c1c'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M12 8v4m0 4h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z'/%3E%3C/svg%3E") center/contain no-repeat;
}

.login-version {
  margin-top: auto;
  padding-top: 1.5rem;
  text-align: center;
  font-size: 0.6875rem;
  color: #aaa;
}

/* Responsivo: em telas pequenas empilha colunas */
@media (max-width: 700px) {
  .login-root {
    flex-direction: column;
    min-height: auto;
    max-width: 420px;
  }

  .login-left {
    padding: 2rem 1.5rem;
    min-height: 200px;
  }

  .left-tagline h2 {
    font-size: 22px;
  }

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

  .brand-logo {
    max-height: 100px;
  }

  .field-input {
    font-size: 16px;
    min-height: 48px;
    padding: 12px 14px;
  }

  .btn-login {
    min-height: 48px;
    font-size: 16px;
    padding: 14px;
  }
}

@media (max-width: 400px) {
  .login-title {
    font-size: 22px;
  }

  .login-root {
    border-radius: 12px;
  }

  .login-left {
    min-height: 160px;
    padding: 1.25rem 1rem;
  }

  .login-right {
    padding: 1.5rem 1.1rem;
  }
}
