/* Layout visual da tela de entrada. Escopo restrito ao painel inicial. */
@supports selector(main:has(#loginPanel:not(.hidden))) {
  main:has(#loginPanel:not(.hidden)) .hero {
    display: none;
  }
}

@supports selector(body:has(#loginPanel:not(.hidden))) {
  body:has(#loginPanel:not(.hidden)) {
    background:
      radial-gradient(circle at 8% 13%, rgba(11, 95, 255, 0.08), transparent 28%),
      radial-gradient(circle at 91% 24%, rgba(11, 95, 255, 0.06), transparent 30%),
      linear-gradient(180deg, #ffffff 0%, #edf5ff 100%);
  }

  body:has(#loginPanel:not(.hidden)) main {
    width: min(1710px, calc(100% - 208px)) !important;
    max-width: 1710px !important;
  }

  body:has(#loginPanel:not(.hidden)) .topbar {
    min-height: 112px !important;
    padding: 18px clamp(84px, 5.6vw, 112px) !important;
    background: rgba(255, 255, 255, 0.94);
  }

  body:has(#loginPanel:not(.hidden)) .brand-logo-img {
    width: 250px;
    max-width: 250px;
  }

  body:has(#loginPanel:not(.hidden)) .top-actions a,
  body:has(#loginPanel:not(.hidden)) .top-actions .link-button,
  body:has(#loginPanel:not(.hidden)) .top-actions button.link-button {
    color: #0a2540;
    font-size: 14px;
    font-weight: 800;
  }

  body:has(#loginPanel:not(.hidden)) .legal-footer {
    width: min(1560px, calc(100% - 208px)) !important;
    max-width: 1560px !important;
    margin-top: 62px !important;
  }
}

.login-enterprise-panel:not(.hidden) {
  margin-top: 42px !important;
  padding: 0 !important;
  overflow: hidden;
  border: 1px solid rgba(10, 37, 64, 0.10) !important;
  border-radius: 30px !important;
  background: #ffffff !important;
  box-shadow: 0 24px 70px rgba(10, 37, 64, 0.10) !important;
}

.login-enterprise-grid {
  display: grid;
  grid-template-columns: minmax(600px, 0.45fr) minmax(700px, 0.55fr);
  min-height: 760px;
}

.login-enterprise-copy {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 58px 54px 42px;
  background: #ffffff;
}

.login-enterprise-panel .panel-head {
  max-width: 650px;
}

.login-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  margin: 0 0 28px !important;
  color: #0b5fff !important;
  font-size: 14px;
  font-weight: 900;
  line-height: 1;
  letter-spacing: 0.17em;
}

.login-eyebrow::before {
  content: "";
  width: 22px;
  height: 22px;
  flex: 0 0 22px;
  border-radius: 999px;
  box-shadow: inset 0 0 0 2px #0b5fff;
}

.login-enterprise-panel .panel-head h2,
.login-enterprise-panel:not(.hidden) .panel-head h2,
.login-enterprise-panel .panel-head h2::after,
.login-enterprise-panel:not(.hidden) .panel-head h2::after {
  display: none !important;
  content: none !important;
}

.login-enterprise-panel .panel-head p:not(.eyebrow)::after {
  content: none !important;
  display: none !important;
}

.login-enterprise-panel .panel-head p:not(.eyebrow) {
  max-width: 520px;
  margin: 0;
  color: #50698c;
  font-size: 18px !important;
  line-height: 1.55;
}

.login-enterprise-form {
  max-width: 640px;
  margin-top: 28px;
}

.login-enterprise-panel .login-form-row {
  display: grid;
  grid-template-columns: 1fr;
  gap: 15px;
  align-items: center;
}

.login-enterprise-form label {
  display: block;
  margin: 0 0 7px;
  color: #0a2540;
  font-size: 14px;
  font-weight: 900;
}

.login-enterprise-panel input {
  width: 100%;
  min-height: 56px;
  border: 1px solid rgba(80, 105, 140, 0.28);
  border-radius: 14px;
  background-color: #ffffff;
  color: #0a2540;
  padding: 0 18px;
  font-size: 16px;
  box-shadow: none;
}

.login-enterprise-panel input::placeholder {
  color: #5f7898;
}

.login-enterprise-panel input:focus {
  border-color: rgba(11, 95, 255, 0.5);
  box-shadow: 0 0 0 4px rgba(11, 95, 255, 0.08);
}

.login-enterprise-panel button[type="submit"] {
  width: 100%;
  min-height: 58px;
  margin-top: 2px;
  border-radius: 13px;
  background: #0b5fff;
  box-shadow: 0 10px 22px rgba(11, 95, 255, 0.24);
  font-size: 18px;
  font-weight: 900;
}

.login-enterprise-panel button[type="submit"]:hover {
  background: #0753e4;
}

.login-enterprise-form small {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 28px;
  margin-top: 16px;
  color: transparent;
  font-size: 0;
  line-height: 1.2;
  text-align: center;
  background: linear-gradient(90deg, transparent calc(50% - 1px), rgba(10, 37, 64, 0.14) calc(50% - 1px), rgba(10, 37, 64, 0.14) calc(50% + 1px), transparent calc(50% + 1px));
}

.login-enterprise-form small::before,
.login-enterprise-form small::after {
  color: #0b5fff;
  font-size: 15px;
  font-weight: 900;
  white-space: nowrap;
}

.login-enterprise-form small::before {
  content: "Criar acesso com esta senha";
}

.login-enterprise-form small::after {
  content: "Definir ou recuperar senha";
}

.login-trust-card {
  max-width: 640px;
  margin-top: 18px;
  padding-top: 22px;
  border-top: 1px solid rgba(10, 37, 64, 0.10);
  display: grid;
  grid-template-columns: 70px minmax(0, 1fr);
  gap: 20px;
  align-items: start;
}

.login-trust-icon {
  width: 70px;
  height: 70px;
  border-radius: 16px;
  display: grid;
  place-items: center;
  background: #eaf3ff;
}

.login-trust-icon svg {
  width: 32px;
  height: 32px;
  stroke: #0b5fff;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
  fill: none;
}

.login-trust-card strong {
  display: block;
  color: #0a2540;
  font-size: 17px;
  line-height: 1.3;
  letter-spacing: -0.02em;
}

.login-trust-card span {
  display: block;
  max-width: 420px;
  margin-top: 5px;
  color: #50698c;
  font-size: 15px;
  line-height: 1.55;
}

.login-visual-panel {
  position: relative;
  min-height: 760px;
  display: grid;
  place-items: center;
  padding: 42px 42px;
  background:
    radial-gradient(circle at 56% 30%, rgba(11, 95, 255, 0.11), transparent 32%),
    radial-gradient(circle at 35% 78%, rgba(11, 95, 255, 0.06), transparent 28%),
    linear-gradient(135deg, #f7fbff 0%, #edf6ff 100%);
  border-left: 1px solid rgba(10, 37, 64, 0.08);
}

.login-hero-image {
  width: min(116%, 920px);
  max-width: 920px;
  max-height: 680px;
  height: auto;
  object-fit: contain;
  display: block;
  border-radius: 0;
  transform: scale(1.12);
}

.login-visual-svg {
  display: none !important;
}

.legal-footer-inner {
  gap: 72px !important;
}

.legal-footer-brand {
  max-width: 760px !important;
}

.legal-footer-brand span {
  white-space: normal !important;
}

.legal-footer-links {
  margin-left: auto !important;
  flex: 0 0 auto;
}

@media (max-width: 1500px) {
  @supports selector(body:has(#loginPanel:not(.hidden))) {
    body:has(#loginPanel:not(.hidden)) main {
      width: calc(100% - 96px) !important;
    }

    body:has(#loginPanel:not(.hidden)) .legal-footer {
      width: calc(100% - 96px) !important;
    }
  }

  .login-enterprise-grid {
    grid-template-columns: minmax(580px, 0.46fr) minmax(620px, 0.54fr);
  }
}

@media (max-width: 1180px) {
  .login-enterprise-grid {
    grid-template-columns: 1fr;
  }

  .login-visual-panel {
    min-height: 360px;
    border-left: 0;
    border-top: 1px solid rgba(10, 37, 64, 0.08);
  }

  .login-hero-image {
    max-height: 340px;
    transform: none;
  }
}

@media (max-width: 850px) {
  @supports selector(body:has(#loginPanel:not(.hidden))) {
    body:has(#loginPanel:not(.hidden)) main {
      width: calc(100% - 32px) !important;
    }
  }

  .login-enterprise-copy {
    padding: 36px 24px 30px;
  }

  .login-enterprise-form small {
    flex-direction: column;
    gap: 8px;
    background: none;
  }

  .login-trust-card {
    grid-template-columns: 1fr;
  }

  .legal-footer-inner {
    gap: 18px !important;
  }
}
/* Ajuste final seguro: imagem, duplicação dos links e ícone da área de assinantes. */
.login-eyebrow::before {
  content: "" !important;
  width: 22px !important;
  height: 22px !important;
  flex: 0 0 22px !important;
  border-radius: 0 !important;
  box-shadow: none !important;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='22' height='22' viewBox='0 0 24 24' fill='none' stroke='%230b5fff' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2'/%3E%3Ccircle cx='9' cy='7' r='4'/%3E%3Cpath d='M22 21v-2a4 4 0 0 0-3-3.87'/%3E%3Cpath d='M16 3.13a4 4 0 0 1 0 7.75'/%3E%3C/svg%3E") !important;
  background-repeat: no-repeat !important;
  background-position: center !important;
  background-size: 22px 22px !important;
}

.login-enterprise-form small,
.login-enterprise-form small::before,
.login-enterprise-form small::after {
  display: none !important;
  content: none !important;
}

#passwordAuthActions {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 0 !important;
  margin-top: 16px !important;
  text-align: center !important;
}

.login-enterprise-panel #passwordAuthActions .link-button {
  color: #0b5fff !important;
  font-size: 15px !important;
  font-weight: 900 !important;
  white-space: nowrap !important;
}

.login-enterprise-panel #passwordAuthActions .link-button + .link-button::before {
  content: "" !important;
  display: inline-block !important;
  width: 1px !important;
  height: 18px !important;
  margin: 0 22px !important;
  vertical-align: middle !important;
  background: rgba(10, 37, 64, 0.14) !important;
}

.login-visual-panel {
  overflow: hidden !important;
  padding: 36px 36px !important;
}

.login-hero-image {
  width: min(100%, 760px) !important;
  max-width: 760px !important;
  max-height: 610px !important;
  transform: none !important;
}

/* Ajuste final 2: esmaecimento da imagem, links menores e remoção da frase do rodapé. */
.login-hero-image {
  opacity: 0.90 !important;
  filter: saturate(0.92) contrast(0.96) !important;
  -webkit-mask-image: radial-gradient(ellipse at center, #000 58%, rgba(0,0,0,0.72) 78%, transparent 100%) !important;
  mask-image: radial-gradient(ellipse at center, #000 58%, rgba(0,0,0,0.72) 78%, transparent 100%) !important;
}

.login-enterprise-panel #passwordAuthActions {
  flex-wrap: nowrap !important;
}

.login-enterprise-panel #passwordAuthActions .link-button {
  font-size: 13px !important;
  line-height: 1.2 !important;
  font-weight: 900 !important;
}

.login-enterprise-panel #passwordAuthActions .link-button + .link-button::before {
  height: 15px !important;
  margin: 0 14px !important;
}

.legal-footer-brand span {
  display: none !important;
}

/* Ajuste final 3: fade mais forte na imagem, fundo lateral e altura do topo igual ao app logado. */

/* Topo com a mesma altura visual da página logada */
@supports selector(body:has(#loginPanel:not(.hidden))) {
  body:has(#loginPanel:not(.hidden)) .topbar {
    min-height: 76px !important;
    padding-top: 14px !important;
    padding-bottom: 14px !important;
  }
}

/* Remove faixa branca residual no lado direito do card */
.login-enterprise-panel:not(.hidden) {
  background: #edf6ff !important;
}

.login-enterprise-copy {
  background: #ffffff !important;
}

.login-visual-panel {
  overflow: hidden !important;
  background:
    radial-gradient(circle at 52% 34%, rgba(11, 95, 255, 0.08), transparent 28%),
    radial-gradient(circle at 48% 72%, rgba(0, 144, 157, 0.035), transparent 34%),
    linear-gradient(135deg, #f7fbff 0%, #edf6ff 100%) !important;
}

/* Esmaecimento mais forte das extremidades da imagem */
.login-hero-image {
  opacity: 0.82 !important;
  filter: saturate(0.88) contrast(0.92) brightness(1.03) !important;
  -webkit-mask-image:
    radial-gradient(
      ellipse at center,
      #000 42%,
      rgba(0, 0, 0, 0.68) 60%,
      rgba(0, 0, 0, 0.28) 76%,
      transparent 96%
    ) !important;
  mask-image:
    radial-gradient(
      ellipse at center,
      #000 42%,
      rgba(0, 0, 0, 0.68) 60%,
      rgba(0, 0, 0, 0.28) 76%,
      transparent 96%
    ) !important;
}
