/* =========================================================
   PORTAL DE CLIENTES — AZ CONTABLE
   ESTILO APPLE PREMIUM
========================================================= */


/* =========================================================
   BODY
========================================================= */

.portal-body {
  margin: 0;

  min-height: 100vh;
  min-height: 100svh;

  background: #f5f7fa;

  color: #101b2d;

  -webkit-font-smoothing: antialiased;
}


/* =========================================================
   ESTRUCTURA PRINCIPAL
========================================================= */

.portal-split {
  display: grid;

  grid-template-columns:
    minmax(0, 460px)
    minmax(0, 1fr);

  min-height: 100vh;
  min-height: 100svh;
}


/* =========================================================
   PANEL IZQUIERDO — MARCA
========================================================= */

.portal-brand {
  position: relative;

  overflow: hidden;

  display: flex;
  flex-direction: column;
  justify-content: space-between;

  padding: 52px 48px;

  background: #101b2d;

  color: #fff;
}


/* ---------- textura ---------- */

.portal-brand::before {
  content: "";

  position: absolute;
  inset: 0;

  background-image:
    radial-gradient(
      rgba(255, 255, 255, 0.075) 1px,
      transparent 1px
    );

  background-size: 22px 22px;

  opacity: 0.5;

  pointer-events: none;
}


/* ---------- header marca ---------- */

.portal-brand__top {
  position: relative;
  z-index: 1;

  display: flex;
  align-items: center;

  gap: 11px;
}

.portal-brand__top .navbar__mark {
  width: 34px;
  height: 34px;

  display: flex;
  align-items: center;
  justify-content: center;

  background: #fff;
  color: #0a2a5e;

  border-radius: 9px;

  font-size: 13px;
  font-weight: 700;
}

.portal-brand__top span:last-child {
  font-size: 14px;
  font-weight: 500;

  letter-spacing: 0.01em;

  color: rgba(255, 255, 255, 0.88);
}


/* =========================================================
   CONTENIDO MARCA
========================================================= */

.portal-brand__body {
  position: relative;
  z-index: 1;

  width: 100%;
  max-width: 340px;
}

.portal-brand__eyebrow {
  display: block;

  margin-bottom: 20px;

  font-size: 10px;
  font-weight: 600;

  letter-spacing: 0.18em;

  text-transform: uppercase;

  color: rgba(255, 255, 255, 0.42);
}

.portal-brand__body h2 {
  margin: 0 0 18px;

  font-size: clamp(27px, 3vw, 34px);

  line-height: 1.2;

  font-weight: 600;

  letter-spacing: -0.025em;

  color: rgba(255, 255, 255, 0.94);
}

.portal-brand__body p {
  margin: 0;

  font-size: 14px;

  line-height: 1.8;

  color: rgba(255, 255, 255, 0.62);
}


/* =========================================================
   LISTA DE CONFIANZA
========================================================= */

.portal-trust {
  position: relative;
  z-index: 1;

  list-style: none;

  margin: 38px 0 0;
  padding: 0;

  display: flex;
  flex-direction: column;

  gap: 18px;
}

.portal-trust li {
  display: flex;
  align-items: flex-start;

  gap: 12px;

  font-size: 13px;

  line-height: 1.6;

  color: rgba(255, 255, 255, 0.72);
}

.portal-trust__mark {
  flex-shrink: 0;

  width: 21px;
  height: 21px;

  margin-top: 1px;

  display: flex;
  align-items: center;
  justify-content: center;

  border: 1px solid rgba(126, 217, 168, 0.3);

  border-radius: 50%;

  font-size: 10px;

  color: #7ed9a8;
}


/* =========================================================
   FOOTER PANEL IZQUIERDO
========================================================= */

.portal-brand__footer {
  position: relative;
  z-index: 1;

  font-size: 9px;

  font-weight: 500;

  letter-spacing: 0.13em;

  color: rgba(255, 255, 255, 0.25);
}


/* =========================================================
   PANEL DERECHO
========================================================= */

.portal-form-side {
  position: relative;

  display: flex;
  align-items: center;
  justify-content: center;

  padding: 60px 40px;

  background:
    radial-gradient(
      circle at 50% 45%,
      rgba(255, 255, 255, 0.95),
      rgba(245, 247, 250, 1) 65%
    );
}


/* =========================================================
   CARD DE LOGIN
========================================================= */

.portal-card {
  width: 100%;
  max-width: 430px;

  padding: 44px 42px 38px;

  box-sizing: border-box;

  background: rgba(255, 255, 255, 0.92);

  border: 1px solid rgba(10, 42, 94, 0.08);

  border-radius: 20px;

  box-shadow:
    0 24px 70px rgba(10, 42, 94, 0.08),
    0 4px 16px rgba(10, 42, 94, 0.035);

  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
}


/* =========================================================
   HEADER CARD
========================================================= */

.portal-card__eyebrow {
  display: block;

  margin-bottom: 12px;

  font-size: 10px;

  font-weight: 600;

  letter-spacing: 0.17em;

  text-transform: uppercase;

  color: #9aa3b5;
}

.portal-card h1 {
  margin: 0 0 10px;

  font-size: 29px;

  line-height: 1.2;

  font-weight: 600;

  letter-spacing: -0.025em;

  color: #0a2a5e;
}

.portal-card__sub {
  margin: 0 0 32px;

  font-size: 14px;

  line-height: 1.65;

  color: #737b89;
}


/* =========================================================
   FORMULARIO
========================================================= */

.portal-card .form__row {
  margin-bottom: 18px;
}

.portal-card label {
  display: block;

  margin-bottom: 8px;

  font-size: 12px;

  font-weight: 600;

  letter-spacing: 0.01em;

  color: #101b2d;
}


/* =========================================================
   INPUT
========================================================= */

.portal-card input[type="email"] {
  display: block;

  width: 100%;
  height: 50px;

  padding: 0 15px;

  box-sizing: border-box;

  border: 1px solid #dce3ef;

  border-radius: 10px;

  background: #fff;

  color: #101b2d;

  font-family: inherit;

  font-size: 14px;

  outline: none;

  appearance: none;

  transition:
    border-color 0.2s ease,
    box-shadow 0.2s ease,
    background 0.2s ease;
}

.portal-card input[type="email"]::placeholder {
  color: #b1b8c5;
}

.portal-card input[type="email"]:hover {
  border-color: #cbd4e2;
}

.portal-card input[type="email"]:focus {
  border-color: #0a2a5e;

  background: #fff;

  box-shadow:
    0 0 0 3px rgba(10, 42, 94, 0.07);
}


/* =========================================================
   BOTÓN
========================================================= */

.portal-card__submit {
  width: 100%;
  height: 50px;

  margin-top: 7px;

  border: 0;

  border-radius: 10px;

  font-size: 13px;

  font-weight: 600;

  letter-spacing: 0.01em;

  cursor: pointer;

  transition:
    transform 0.2s ease,
    box-shadow 0.2s ease,
    opacity 0.2s ease;
}

.portal-card__submit:hover {
  transform: translateY(-1px);

  box-shadow:
    0 8px 20px rgba(10, 42, 94, 0.14);
}

.portal-card__submit:active {
  transform: translateY(0);
}


/* =========================================================
   ESTADO
========================================================= */

.form__status {
  min-height: 20px;

  margin: 14px 0 0;

  font-size: 12.5px;

  line-height: 1.5;
}

.form__status[data-state="ok"] {
  color: #3b9b68;
}

.form__status[data-state="error"] {
  color: #b3455b;
}


/* =========================================================
   AVISO DE SEGURIDAD
========================================================= */

.portal-card__hint {
  display: flex;
  align-items: flex-start;

  gap: 10px;

  margin: 28px 0 0;
  padding-top: 22px;

  border-top: 1px solid #edf0f4;

  font-size: 11.5px;

  line-height: 1.65;

  color: #9aa3b5;
}

.portal-card__hint .ti {
  flex-shrink: 0;

  margin-top: 1px;

  font-size: 13px;
}


/* =========================================================
   VERIFICACIÓN
========================================================= */

.verificar-body {
  margin: 0;

  min-height: 100vh;
  min-height: 100svh;

  display: flex;
  align-items: center;
  justify-content: center;

  padding: 24px;

  box-sizing: border-box;

  background: #f5f7fa;
}


/* =========================================================
   CARD VERIFICACIÓN
========================================================= */

.verificar-card {
  width: 100%;
  max-width: 380px;

  padding: 46px 38px;

  box-sizing: border-box;

  background: rgba(255, 255, 255, 0.95);

  border: 1px solid rgba(10, 42, 94, 0.08);

  border-radius: 18px;

  text-align: center;

  box-shadow:
    0 24px 60px rgba(10, 42, 94, 0.08),
    0 4px 16px rgba(10, 42, 94, 0.035);
}


/* =========================================================
   SELLO
========================================================= */

.sello {
  position: relative;

  width: 84px;
  height: 84px;

  margin: 0 auto 28px;

  border: 2px solid #0a2a5e;

  border-radius: 50%;

  display: flex;
  align-items: center;
  justify-content: center;
}

.sello::before {
  content: "";

  position: absolute;
  inset: 6px;

  border: 1px dashed rgba(10, 42, 94, 0.3);

  border-radius: 50%;
}

.sello__check {
  font-size: 30px;

  color: #0a2a5e;

  opacity: 0;

  transform: scale(0.6);

  transition:
    opacity 0.35s ease,
    transform 0.35s ease;
}

.sello.verificando {
  animation: selloPulso 1.4s ease-in-out infinite;
}

.sello.ok .sello__check {
  opacity: 1;

  transform: scale(1);
}

.sello.ok {
  border-color: #3b9b68;
}

.sello.ok::before {
  border-color: rgba(59, 155, 104, 0.35);
}

.sello.ok .sello__check {
  color: #3b9b68;
}

.sello.error {
  border-color: #b3455b;
}

.sello.error::before {
  border-color: rgba(179, 69, 91, 0.35);
}

.sello.error .sello__check {
  color: #b3455b;

  opacity: 1;

  transform: scale(1);
}


@keyframes selloPulso {

  0%,
  100% {
    transform: scale(1);
    opacity: 1;
  }

  50% {
    transform: scale(1.06);
    opacity: 0.7;
  }

}


/* =========================================================
   VERIFICACIÓN — TEXTOS
========================================================= */

.verificar-card h1 {
  margin: 0 0 9px;

  font-size: 22px;

  line-height: 1.25;

  font-weight: 600;

  letter-spacing: -0.015em;

  color: #0a2a5e;
}

.verificar-card__sub {
  margin: 0;

  font-size: 14px;

  line-height: 1.65;

  color: #6b7280;
}

.verificar-card .form__status {
  margin-top: 16px;
}

.verificar-card .btn {
  width: 100%;
  height: 46px;

  margin-top: 22px;

  border-radius: 9px;
}


/* =========================================================
   TABLET
========================================================= */

@media (max-width: 1000px) {

  .portal-split {
    grid-template-columns:
      minmax(0, 390px)
      minmax(0, 1fr);
  }

  .portal-brand {
    padding: 44px 38px;
  }

  .portal-form-side {
    padding: 50px 28px;
  }

  .portal-card {
    padding: 40px 34px 34px;
  }

}


/* =========================================================
   MOBILE
========================================================= */

@media (max-width: 860px) {

  .portal-split {
    grid-template-columns: 1fr;

    min-height: 100svh;
  }


  /* ---------- PANEL IZQUIERDO ---------- */

  .portal-brand {
    min-height: auto;

    padding: 58px 28px 62px;

    align-items: center;

    text-align: center;
  }

  .portal-brand__top {
    justify-content: center;

    margin-bottom: 32px;
  }

  .portal-brand__body {
    width: 100%;

    max-width: 520px;

    margin: 0 auto;
  }

  .portal-brand__eyebrow {
    margin-bottom: 22px;
  }

  .portal-brand__body h2 {
    margin-bottom: 20px;

    font-size: 29px;
  }

  .portal-brand__body p {
    max-width: 440px;

    margin: 0 auto;

    font-size: 14px;

    line-height: 1.8;
  }


  /* ---------- BENEFICIOS ---------- */

  .portal-trust {
    width: 100%;

    max-width: 370px;

    margin: 42px auto 0;

    gap: 21px;

    text-align: left;
  }

  .portal-trust li {
    gap: 13px;

    font-size: 13px;

    line-height: 1.6;
  }


  /* ---------- FOOTER ---------- */

  .portal-brand__footer {
    width: 100%;

    margin-top: 58px;

    text-align: center;
  }


  /* ---------- PANEL LOGIN ---------- */

  .portal-form-side {
    width: 100%;

    padding: 48px 20px 64px;

    box-sizing: border-box;

    display: flex;

    align-items: center;
    justify-content: center;

    text-align: center;
  }


  /* ---------- CARD ---------- */

  .portal-card {
    width: 100%;

    max-width: 430px;

    margin: 0 auto;

    padding: 38px 26px 32px;

    border-radius: 18px;
  }

  .portal-card__eyebrow {
    text-align: center;
  }

  .portal-card h1 {
    font-size: 27px;

    text-align: center;
  }

  .portal-card__sub {
    max-width: 320px;

    margin-left: auto;
    margin-right: auto;

    text-align: center;
  }


  /* ---------- FORM ---------- */

  .portal-card .form__row {
    text-align: left;
  }

  .portal-card__hint {
    text-align: left;
  }

}


/* =========================================================
   MOBILE PEQUEÑO
========================================================= */

@media (max-width: 480px) {

  .portal-brand {
    padding: 48px 22px 54px;
  }

  .portal-brand__top {
    margin-bottom: 28px;
  }

  .portal-brand__body h2 {
    font-size: 27px;
  }

  .portal-brand__body p {
    font-size: 13.5px;
  }

  .portal-trust {
    margin-top: 38px;

    max-width: 340px;

    gap: 19px;
  }

  .portal-brand__footer {
    margin-top: 48px;

    font-size: 8px;
  }


  .portal-form-side {
    padding: 40px 16px 54px;
  }

  .portal-card {
    padding: 34px 22px 30px;

    border-radius: 17px;
  }

  .portal-card h1 {
    font-size: 25px;
  }

  .portal-card__sub {
    margin-bottom: 28px;

    font-size: 13.5px;
  }

  .portal-card input[type="email"],
  .portal-card__submit {
    height: 49px;
  }

  .portal-card__hint {
    margin-top: 24px;
    padding-top: 20px;

    font-size: 11px;
  }


  .verificar-body {
    padding: 18px;
  }

  .verificar-card {
    padding: 38px 22px;

    border-radius: 16px;
  }

}


/* =========================================================
   REDUCIR ANIMACIONES
========================================================= */

@media (prefers-reduced-motion: reduce) {

  .sello.verificando {
    animation: none;
  }

  .portal-card__submit,
  .portal-card input[type="email"] {
    transition: none;
  }

}

/* =========================================================
   MOBILE — SOLO LOGIN
========================================================= */

@media (max-width: 860px) {

  /* Ocultar completamente el panel izquierdo */
  .portal-brand {
    display: none;
  }

  /* El login ocupa toda la pantalla */
  .portal-split {
    display: block;
    min-height: 100svh;
  }

  .portal-form-side {
    width: 100%;
    min-height: 100svh;

    padding: 24px 18px;

    display: flex;
    align-items: center;
    justify-content: center;

    box-sizing: border-box;
  }

  /* Card centrada */
  .portal-card {
    width: 100%;
    max-width: 430px;

    margin: 0 auto;

    padding: 40px 28px 34px;

    border-radius: 20px;
  }

}

.portal-card__back {
  width: 100%;
  height: 50px;

  margin-top: 10px;

  display: flex;
  align-items: center;
  justify-content: center;

  box-sizing: border-box;

  border: 1px solid #dce3ef;
  border-radius: 10px;

  background: #fff;
  color: #0a2a5e;

  font-family: inherit;
  font-size: 13px;
  font-weight: 600;

  text-decoration: none;

  cursor: pointer;

  transition:
    background 0.2s ease,
    border-color 0.2s ease,
    transform 0.2s ease;
}

.portal-card__back:hover {
  background: #f7f9fc;
  border-color: #cbd4e2;

  transform: translateY(-1px);
}

.portal-card__back:active {
  transform: translateY(0);
}