/* HGest — Login cliente (premium) */

@keyframes lx-rise {
  from { opacity: 0; transform: translateY(32px) scale(0.97); }
  to   { opacity: 1; transform: none; }
}

@keyframes lx-float-a {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50%      { transform: translate(24px, -18px) scale(1.06); }
}

@keyframes lx-float-b {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50%      { transform: translate(-20px, 14px) scale(1.04); }
}

@keyframes lx-shimmer {
  to { background-position: 250% center; }
}

@keyframes lx-glow {
  0%, 100% { opacity: 0.45; }
  50%      { opacity: 0.85; }
}

@keyframes lx-spin {
  to { transform: rotate(360deg); }
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

body.login-cliente {
  font-family: 'Outfit', system-ui, sans-serif;
  font-size: 15px;
  min-height: 100dvh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: clamp(0.75rem, 3vw, 1.75rem);
  background: #030305;
  color: #fafafa;
  -webkit-font-smoothing: antialiased;
}

/* ── Cena ambiental ── */
.login-scene {
  width: 100%;
  max-width: 1060px;
  position: relative;
  animation: lx-rise 0.85s cubic-bezier(0.16, 1, 0.3, 1) both;
  --mx: 50%;
  --my: 50%;
}

.login-scene::after {
  content: '';
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background: radial-gradient(
    600px circle at var(--mx) var(--my),
    rgba(255, 255, 255, 0.04) 0%,
    transparent 55%
  );
  transition: opacity 0.4s;
}

.login-ambient {
  position: absolute;
  inset: -30% -15%;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
  transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1);
  will-change: transform;
}

.login-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(90px);
}

.login-orb-a {
  width: min(60vw, 480px);
  height: min(60vw, 480px);
  top: 0;
  left: 0;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.09) 0%, transparent 68%);
  animation: lx-float-a 16s ease-in-out infinite;
}

.login-orb-b {
  width: min(50vw, 400px);
  height: min(50vw, 400px);
  bottom: 5%;
  right: 0;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.05) 0%, transparent 70%);
  animation: lx-float-b 20s ease-in-out infinite;
}

.login-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.025) 1px, transparent 1px);
  background-size: 52px 52px;
  mask-image: radial-gradient(ellipse 75% 65% at 50% 45%, #000 20%, transparent 75%);
}

.login-shell {
  position: relative;
  z-index: 1;
}

.login-card {
  display: flex;
  min-height: min(600px, calc(100dvh - 2rem));
  border-radius: 26px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.09);
  box-shadow:
    0 48px 120px rgba(0, 0, 0, 0.72),
    0 0 0 1px rgba(255, 255, 255, 0.04) inset;
  background: rgba(255, 255, 255, 0.015);
  backdrop-filter: blur(12px);
}

/* ── Painel marca ── */
.login-brand {
  flex: 1 1 52%;
  position: relative;
  background: linear-gradient(145deg, #16161c 0%, #0e0e12 55%, #0a0a0e 100%);
  padding: clamp(1.75rem, 4vw, 2.75rem);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 1.5rem;
  border-right: 1px solid rgba(255, 255, 255, 0.06);
  overflow: hidden;
}

.login-brand::before {
  content: '';
  position: absolute;
  top: -40%;
  right: -30%;
  width: 80%;
  height: 80%;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.04) 0%, transparent 60%);
  pointer-events: none;
}

.login-brand-top {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.login-brand-logo {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.login-brand-logo img {
  width: 100%;
  max-width: 260px;
  height: auto;
  object-fit: contain;
  filter: drop-shadow(0 0 28px rgba(255, 255, 255, 0.12));
}

.login-client-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  align-self: flex-start;
  padding: 7px 14px;
  border-radius: 100px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  font-size: 13px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(8px);
}

.login-client-badge .dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #22c55e;
  box-shadow: 0 0 10px rgba(34, 197, 94, 0.7);
  animation: lx-glow 2.5s ease-in-out infinite;
  flex-shrink: 0;
}

.login-brand-headline {
  font-size: clamp(1.75rem, 4vw, 2.35rem);
  font-weight: 800;
  letter-spacing: -0.045em;
  line-height: 1.08;
  color: #fff;
  max-width: 14ch;
}

.login-brand-headline em {
  font-style: normal;
  color: rgba(255, 255, 255, 0.42);
  font-weight: 300;
}

.login-brand-desc {
  font-size: 15px;
  font-weight: 400;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.52);
  max-width: 36ch;
}

.login-brand-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  margin-top: 0.25rem;
}

.login-brand-list li {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 14px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.82);
}

.login-brand-list .feat-num {
  width: 26px;
  height: 26px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.65);
  flex-shrink: 0;
}

.login-brand-footer {
  position: relative;
  z-index: 1;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.38);
  line-height: 1.5;
}

.login-brand-footer strong {
  display: block;
  font-size: 14px;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.75);
  letter-spacing: -0.01em;
  margin-bottom: 2px;
}

/* ── Painel formulário ── */
.login-form-panel {
  flex: 1 1 48%;
  background: #060608;
  padding: clamp(1.5rem, 4vw, 2.5rem);
  display: flex;
  align-items: center;
  justify-content: center;
}

.login-glass {
  width: 100%;
  max-width: 400px;
  padding: clamp(1.5rem, 4vw, 2rem);
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow:
    0 24px 60px rgba(0, 0, 0, 0.45),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(24px);
}

.login-form-eyebrow {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.38);
  margin-bottom: 0.5rem;
}

.login-form-head h1 {
  font-size: clamp(1.75rem, 4vw, 2rem);
  font-weight: 800;
  letter-spacing: -0.04em;
  line-height: 1.1;
  color: #fff;
  margin-bottom: 0.35rem;
}

.login-form-head p {
  font-size: 15px;
  font-weight: 400;
  color: rgba(255, 255, 255, 0.48);
  line-height: 1.5;
  margin-bottom: 1.75rem;
}

.login-cliente .alert {
  display: none;
  background: rgba(239, 68, 68, 0.1);
  border: 1px solid rgba(248, 113, 113, 0.35);
  border-radius: 12px;
  padding: 10px 12px;
  margin-bottom: 1rem;
  align-items: center;
  gap: 8px;
}

.login-cliente .alert.visible { display: flex; }
.login-cliente .alert-icon { color: #f87171; flex-shrink: 0; }
.login-cliente .alert-msg { font-size: 14px; color: #fecaca; font-weight: 500; }

.login-cliente .field { margin-bottom: 1rem; }
.login-cliente .field-last { margin-bottom: 1.35rem; }

.login-cliente .field-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
}

.login-cliente label {
  font-size: 13px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.75);
  letter-spacing: 0.01em;
}

.login-cliente .forgot {
  font-size: 13px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.4);
  text-decoration: none;
  transition: color 0.15s;
}

.login-cliente .forgot:hover { color: #fff; }

.login-cliente input[type="email"],
.login-cliente input[type="password"],
.login-cliente input[type="text"] {
  width: 100%;
  height: 52px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 14px;
  padding: 0 16px;
  font-size: 16px;
  font-family: inherit;
  font-weight: 400;
  color: #fff;
  background: rgba(0, 0, 0, 0.35);
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
}

.login-cliente input::placeholder {
  color: rgba(255, 255, 255, 0.28);
}

.login-cliente input:focus {
  border-color: rgba(255, 255, 255, 0.28);
  background: rgba(0, 0, 0, 0.5);
  box-shadow: 0 0 0 4px rgba(255, 255, 255, 0.06);
}

.login-cliente input.input-err {
  border-color: rgba(248, 113, 113, 0.55);
}

.login-cliente .pw-wrap { position: relative; }
.login-cliente .pw-wrap input { padding-right: 56px; }

.login-cliente .pw-toggle {
  position: absolute;
  right: 0;
  top: 0;
  height: 52px;
  min-width: 52px;
  padding: 0 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: rgba(255, 255, 255, 0.4);
  background: none;
  border: none;
  font-size: 13px;
  font-weight: 600;
  font-family: inherit;
  transition: color 0.15s;
}

.login-cliente .pw-toggle:hover { color: #fff; }

.login-cliente .btn-login {
  position: relative;
  width: 100%;
  min-height: 54px;
  border: none;
  border-radius: 14px;
  cursor: pointer;
  font-family: inherit;
  font-size: 16px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: #050505;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  background: linear-gradient(105deg, #fff 0%, #e4e4e7 45%, #fff 55%, #d4d4d8 100%);
  background-size: 200% auto;
  box-shadow: 0 4px 24px rgba(255, 255, 255, 0.12), 0 8px 32px rgba(0, 0, 0, 0.35);
  transition: transform 0.2s, box-shadow 0.2s;
}

.login-cliente .btn-login:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow: 0 8px 32px rgba(255, 255, 255, 0.18), 0 12px 40px rgba(0, 0, 0, 0.4);
  animation: lx-shimmer 2.5s linear infinite;
}

.login-cliente .btn-login:active:not(:disabled) { transform: translateY(0); }
.login-cliente .btn-login:disabled { opacity: 0.45; cursor: not-allowed; transform: none; }

.login-cliente .btn-login svg {
  width: 18px;
  height: 18px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.login-form-meta {
  margin-top: 1.5rem;
  text-align: center;
  font-size: 12px;
  font-weight: 400;
  color: rgba(255, 255, 255, 0.32);
  line-height: 1.65;
}

.login-form-meta .secure {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 12px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.5);
  margin-bottom: 6px;
}

.login-form-meta .secure svg {
  width: 13px;
  height: 13px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2;
}

/* ── Mobile: dois cards, scroll ok ── */
@media (max-width: 820px) {
  body.login-cliente {
    align-items: flex-start;
    padding: 1rem 0.85rem 2.5rem;
  }

  .login-scene { max-width: 100%; }

  .login-ambient { inset: -20% -10%; }

  .login-card {
    flex-direction: column;
    gap: 14px;
    min-height: 0;
    background: transparent;
    border: none;
    box-shadow: none;
    backdrop-filter: none;
    border-radius: 0;
    overflow: visible;
  }

  .login-brand {
    flex: none;
    border: 1px solid rgba(255, 255, 255, 0.09);
    border-radius: 22px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    padding: 1.5rem 1.25rem 1.35rem;
  }

  .login-brand-logo img { max-width: 240px; }

  .login-brand-headline { font-size: 1.65rem; max-width: none; }

  .login-brand-desc { max-width: none; font-size: 14px; }

  .login-form-panel {
    flex: none;
    background: transparent;
    padding: 0;
  }

  .login-glass {
    max-width: none;
    border-radius: 22px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
  }
}

@media (max-width: 380px) {
  body.login-cliente { padding: 0.75rem 0.65rem 2rem; }

  .login-brand-logo img { max-width: 220px; }

  .login-brand,
  .login-glass { padding: 1.2rem 1rem; }
}
