/* ======================================================
   ESTILOS GENERALES DE MODALES Y OVERLAYS
   ====================================================== */

/* ---- ESTRUCTURAS BASE (Overlays y Contenedores) ---- */

.auth-overlay,
.ei-overlay {
  position: fixed;
  inset: 0;
  background: rgba(28, 43, 90, 0.60);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 200;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.38s cubic-bezier(0.16, 1, 0.3, 1), visibility 0.38s ease;
  padding: 20px;
}

.auth-overlay.active,
.ei-overlay.open {
  opacity: 1;
  visibility: visible;
}

/* Modal Base Auth */
.auth-modal {
  background: var(--blanco);
  border-radius: var(--radius-lg);
  width: min(96vw, 980px);
  max-width: 980px;
  box-shadow:
    0 0 0 1px rgba(28, 43, 90, 0.08),
    0 32px 80px -12px rgba(28, 43, 90, 0.35);
  overflow: hidden;
  animation: authFadeUp 0.42s cubic-bezier(0.16, 1, 0.3, 1) forwards;
  position: relative;
}

.auth-modal.registro-activo {
  max-width: 860px !important;
}

@keyframes authFadeUp {
  from {
    opacity: 0;
    transform: translateY(24px) scale(0.97);
  }

  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes authSlideUp {
  from {
    opacity: 0;
    transform: translateY(100%);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Modales de Carga y Logout */
.login-loading-overlay,
.logout-overlay,
.forgot-overlay {
  position: fixed;
  inset: 0;
  background: rgba(28, 43, 90, 0.50);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 300;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.login-loading-overlay.active,
.logout-overlay.active,
.forgot-overlay.active {
  opacity: 1;
  visibility: visible;
}

/* ======================================================
   SECCIÓN: MODALES DE CARGA Y LOGOUT
   ====================================================== */

.login-loading-box,
.logout-box {
  background: var(--blanco);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 44px 56px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  box-shadow: 0 32px 80px rgba(28, 43, 90, 0.22);
  animation: authFadeUp 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
  overflow: hidden;
}

.login-loading-spinner,
.logout-spinner {
  width: 44px;
  height: 44px;
  border: 3px solid var(--border-light);
  border-top-color: var(--magenta-oscuro);
  border-radius: 50%;
  animation: spinLoader 0.75s linear infinite;
}

@keyframes spinLoader {
  to {
    transform: rotate(360deg);
  }
}

.login-loading-texto,
.logout-texto {
  font-family: "Nunito", sans-serif;
  font-size: 16px;
  font-weight: 700;
  color: var(--text-body);
  letter-spacing: 0.02em;
}

/* ======================================================
   SECCIÓN: MODAL RECUPERACIÓN DE CONTRASEÑA
   ====================================================== */

.forgot-modal {
  background: var(--blanco);
  border-radius: var(--radius-md);
  width: 90%;
  max-width: 420px;
  overflow: hidden;
  box-shadow:
    0 0 0 1px rgba(28, 43, 90, 0.06),
    0 32px 80px rgba(28, 43, 90, 0.28);
  animation: authFadeUp 0.38s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
}

.forgot-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 22px 28px;
  background: var(--azul-oscuro);
  border-bottom: 1px solid var(--border-light);
  padding-top: 26px;
}

.forgot-header-titulo {
  font-family: "Nunito", sans-serif;
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--blanco);
}

.forgot-titulo span {
  font-style: italic;
  color: var(--amarillo);
  font-weight: 400;
}

.forgot-close {
  width: 36px;
  height: 36px;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid var(--border-light);
  border-radius: 50%;
  color: var(--blanco);
  font-size: 17px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.forgot-close:hover {
  background: var(--magenta-oscuro);
  color: var(--blanco);
  transform: rotate(90deg);
}

.forgot-body {
  padding: 36px 32px 32px;
}

.forgot-titulo {
  font-family: "Philosopher", serif;
  font-size: 24px;
  font-weight: 700;
  color: var(--azul-oscuro);
  margin: 0 0 10px 0;
  line-height: 1.25;
}

.forgot-descripcion {
  font-family: "Nunito", sans-serif;
  font-size: 16px;
  color: var(--text-soft);
  line-height: 1.65;
  margin: 0 0 28px 0;
}

.forgot-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.forgot-msg {
  font-family: "Nunito", sans-serif;
  font-size: 15px;
  font-weight: 600;
  color: var(--magenta-oscuro);
  margin: 14px 0 0 0;
  min-height: 22px;
  text-align: center;
}

/* ======================================================
   SECCIÓN: MODAL DE AUTENTICACIÓN (Login/Registro)
   ====================================================== */

/* ---- TABS ---- */
.auth-tabs {
  display: flex;
  align-items: stretch;
  background: var(--azul-oscuro);
  color: var(--blanco);
  border-bottom: 1px solid var(--border-light);
}

.auth-tab {
  flex: 1;
  padding: 16px 20px;
  background: transparent;
  border: none;
  color: var(--blanco-oscuro);
  font-family: "Nunito", sans-serif;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  cursor: pointer;
  position: relative;
  transition: color 0.25s ease, background 0.25s ease;
}

.auth-tab:hover {
  color: var(--blanco);
  background: rgba(28, 43, 90, 0.05);
}

.auth-tab.active {
  color: var(--blanco);
  background: rgb(67, 4, 162);
}


.auth-close {
  width: 52px;
  flex-shrink: 0;
  background: rgba(255, 255, 255, 0.12);
  border: none;
  border-left: 1px solid var(--border-light);
  color: var(--blanco-oscuro);
  font-size: 18px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color 0.2s ease, background 0.2s ease;
  padding-top: 4px;
}

.auth-close:hover {
  color: var(--blanco);
  background: var(--magenta-oscuro);
}

/* ---- CONTENIDO INTERNO ---- */
.auth-content {
  padding: 40px 36px 36px;
}

.auth-tab-content {
  display: none;
  animation: authTabIn 0.28s ease forwards;
}

.auth-tab-content.active {
  display: block;
}

@keyframes authTabIn {
  from {
    opacity: 0;
    transform: translateY(8px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.auth-titulo {
  font-family: "Philosopher", serif;
  font-size: 28px;
  font-weight: 700;
  color: var(--azul-oscuro);
  margin: 0 0 8px 0;
  line-height: 1.2;
}

.auth-titulo em {
  color: var(--amarillo);
  font-style: italic;
}

.auth-titulo span {
  font-style: italic;
  color: var(--amarillo);
  font-weight: 400;
}

.auth-subtitle {
  font-family: "Nunito", sans-serif;
  font-size: 16px;
  color: var(--text-soft);
  margin: 0 0 30px 0;
}

/* ---- FORMULARIOS AUTH ---- */
.auth-form {
  display: grid;
  flex-direction: column;
  gap: 20px;
}

.auth-modal.registro-activo #registerForm {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}

/* Responsividad Grid Registro */
@media (min-width: 769px) {

  /* Fila 1: Nombre y Apellido */
  #registro-tab .auth-form .form-group:nth-child(1),
  #registro-tab .auth-form .form-group:nth-child(2) {
    grid-column: span 1;
  }

  /* Fila 2: Email y País */
  #registro-tab .auth-form .form-group:nth-child(3),
  #registro-tab .auth-form .form-group:nth-child(4) {
    grid-column: span 1;
  }

  /* Fila 3: Nivel y WhatsApp */
  #registro-tab .auth-form .form-group:nth-child(5),
  #registro-tab .auth-form .form-group:nth-child(6) {
    grid-column: span 1;
  }

  /* Fila 4: Contraseña y Confirmar */
  #registro-tab .auth-form .form-group:nth-child(7),
  #registro-tab .auth-form .form-group:nth-child(8) {
    grid-column: span 1;
  }

  /* Footer: Términos y Botón (Reglas generales de centrado) */
  #registro-tab .auth-form .form-checkbox {
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    margin: 0;
  }

  #registro-tab .auth-form .auth-captcha-wrapper {
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 0;
  }

  /* Distribución de columnas solo en PC */
  @media (min-width: 769px) {
    #registro-tab .auth-form .form-checkbox {
      grid-column: 1 / 2;
      height: 74px;
    }

    #registro-tab .auth-form .auth-captcha-wrapper {
      grid-column: 2 / 3;
      height: 74px;
      padding: 8px;
      box-sizing: border-box;
    }

    #registro-tab .auth-form .auth-btn-primary {
      grid-column: span 2;
      margin-top: 10px;
    }
  }
}

/* El botón siempre ocupa todo el ancho en móvil, se hereda span 2 si no se redefine */
#registro-tab .auth-form .auth-btn-primary {
  grid-column: 1 / -1;
}

/* ---- FORM GROUPS (inputs, labels, helpers) ---- */

.form-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.register-phone-row {
  display: grid;
  grid-template-columns: 85px 1fr;
  gap: 10px;
}

.register-country-code {
  font-family: "Nunito", sans-serif;
  font-size: 14px;
  font-weight: 500;
  padding: 13px 16px;
  color: var(--text-heading);
  background: var(--bg-accent-3);
  border: 1.5px solid var(--border-medium);
  border-radius: var(--radius-sm);
  outline: none;
  transition: border-color 0.22s ease, background 0.22s ease, box-shadow 0.22s ease;
  appearance: none;
  -webkit-appearance: none;
}

.form-label {
  font-family: "Nunito", sans-serif;
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--text-body);
}

.form-input {
  width: 100%;
  padding: 13px 16px;
  font-family: "Nunito", sans-serif;
  font-size: 16px;
  font-weight: 500;
  color: var(--text-heading);
  background: var(--bg-accent-3);
  border: 1.5px solid var(--border-medium);
  border-radius: var(--radius-sm);
  outline: none;
  transition: border-color 0.22s ease, background 0.22s ease, box-shadow 0.22s ease;
  appearance: none;
  -webkit-appearance: none;
  box-sizing: border-box;
}

.form-input::placeholder {
  color: var(--text-muted);
  font-weight: 400;
}

.form-input:hover {
  border-color: var(--border-dark);
  background: var(--blanco);
}

.form-input:focus {
  border-color: var(--azul-oscuro);
  background: var(--blanco);
  box-shadow: 0 0 0 3px rgba(28, 43, 90, 0.10);
}

.form-helper-text {
  font-family: "Nunito", sans-serif;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-muted);
  margin: 0;
  min-height: 20px;
  transition: color 0.2s ease;
}

.form-helper-text.error {
  color: #c0392b;
}

.form-helper-text.success {
  color: #27ae60;
}

/* ---- PASSWORD TOGGLE ---- */
.password-input-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}

.password-input-wrapper .form-input {
  padding-right: 48px;
}

.password-toggle {
  position: absolute;
  right: 14px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color 0.2s ease;
}

.password-toggle:hover {
  color: var(--azul-oscuro);
}

.eye-icon {
  width: 20px;
  height: 20px;
  display: block;
}

/* ---- CHECKBOX ---- */
.form-checkbox {
  display: flex;
  align-items: center;
  justify-content: center; /* Centrado horizontal por defecto */
  gap: 10px;
  width: 100%;             /* Asegura que ocupe todo el ancho para poder centrar */
}

.form-checkbox label {
  font-family: "Nunito", sans-serif;
  font-size: 15px;
  font-weight: 600;
  color: var(--text-body);
  cursor: pointer;
  line-height: 1.4;
  text-align: center;      /* Centra el texto si se rompe en varias líneas */
}

/* ---- BOTONES Y LINKS ---- */
.auth-btn-primary {
  width: 100%;
  padding: 14px 24px;
  background: var(--magenta-oscuro);
  color: var(--blanco);
  border: none;
  border-radius: var(--radius-sm);
  font-family: "Nunito", sans-serif;
  font-size: 14px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  cursor: pointer;
  transition: background 0.25s ease, transform 0.2s ease, box-shadow 0.25s ease;
  position: relative;
  overflow: hidden;
}

.auth-btn-primary::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(255, 255, 255, 0);
  transition: background 0.2s ease;
}

.auth-btn-primary:hover:not(:disabled) {
  background: var(--magenta-hover);
  transform: translateY(-2px);
  box-shadow: 0 10px 28px rgba(159, 39, 101, 0.35);
}

.auth-btn-primary:active:not(:disabled) {
  transform: translateY(0);
}

.auth-btn-primary:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.auth-btn-google {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  padding: 13px 20px;
  background: var(--blanco);
  border: 1.5px solid var(--border-medium);
  border-radius: var(--radius-sm);
  font-family: "Nunito", sans-serif;
  font-size: 15px;
  font-weight: 700;
  color: var(--text-body);
  cursor: pointer;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.auth-btn-google:hover {
  border-color: var(--border-dark);
  background: var(--bg-accent-3);
  box-shadow: 0 4px 12px rgba(28, 43, 90, 0.08);
}

.auth-link {
  font-family: "Nunito", sans-serif;
  font-size: 15px;
  color: var(--text-soft);
  text-align: center;
  margin: 14px 0 0 0;
}

.auth-text-link {
  color: var(--azul-oscuro);
  text-decoration: none;
  font-weight: 800;
  border-bottom: 1.5px solid rgba(28, 43, 90, 0.22);
  transition: color 0.2s ease, border-color 0.2s ease;
}

.auth-text-link:hover {
  color: var(--magenta-oscuro);
  border-color: var(--magenta-oscuro);
}

/* ======================================================
   SECCIÓN: MODAL DE INSCRIPCIÓN (EI)
   ====================================================== */

.ei-modal {
  width: 620px;
  max-width: 95%;
  background: var(--blanco);
  border-radius: 20px;
  overflow: hidden;
  box-shadow:
    0 0 0 1px rgba(28, 43, 90, 0.07),
    0 32px 80px -12px rgba(28, 43, 90, 0.38);
  animation: eiFadeUp 0.42s cubic-bezier(0.16, 1, 0.3, 1) forwards;
  position: relative;
}

@keyframes eiFadeUp {
  from {
    opacity: 0;
    transform: translateY(32px) scale(0.97);
  }

  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.ei-header {
  background: var(--azul-oscuro);
  padding: 32px 28px;
  position: relative;
  text-align: center;
}

.ei-titulo {
  color: var(--blanco);
  font-family: "Philosopher", serif;
  font-size: 24px;
  font-weight: 700;
  margin: 0;
  line-height: 1.25;
}

.ei-texto {
  color: #000000;
  font-size: 15px;
}

.ei-cerrar {
  position: absolute;
  top: 50%;
  right: 20px;
  transform: translateY(-50%);

  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.25);
  color: var(--blanco);
  cursor: pointer;
  font-size: 20px;
  width: 38px;
  height: 38px;
  border-radius: 50%;

  display: flex;
  align-items: center;
  justify-content: center;

  transition: background 0.22s ease, transform 0.22s ease;
}

.ei-cerrar:hover {
  background: var(--magenta-oscuro);
  transform: translateY(-50%) rotate(90deg);
}

.ei-body {
  padding: 0;
}

.ei-form {
  padding: 32px;
}

.ei-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 24px;
  margin-bottom: 28px;
}

/* ---- Card Datos de Usuario ---- */
.ei-card-datos {
  background: #fdfaf5;
  padding: 24px;
  border-radius: 14px;
  margin-bottom: 20px;
  border: 1px solid rgba(193, 155, 118, 0.18);
  position: relative;
  overflow: hidden;
}

.ei-card-datos::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 4px;
  height: 100%;
  background: var(--amarillo);
}

.ei-tag {
  display: block;
  color: var(--text-heading);
  margin-bottom: 12px;
  font-family: "Nunito", sans-serif;
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 1.8px;
}

.ei-user-name {
  margin: 10px 0 4px 0;
  color: var(--azul-oscuro);
  font-size: 20px;
  font-family: "Philosopher", serif;
  font-weight: 700;
  line-height: 1.2;
}

.ei-user-email {
  font-family: "Nunito", sans-serif;
  font-size: 16px;
  color: #303030;
  margin: 0 0 8px 0;
  word-break: break-all;
}

.ei-user-country {
  font-family: "Nunito", sans-serif;
  font-size: 16px;
  color: #303030;
  margin: 6px 0 20px 0;
}

.ei-validar-footer {
  font-size: 14px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.ei-validar-item {
  display: flex;
  gap: 8px;
  align-items: flex-start;
}

.ei-validar-item svg {
  margin-top: 3px;
  flex-shrink: 0;
}

.ei-phone-box {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 10px;
  font-family: "Nunito", sans-serif;
  font-size: 16px;
  font-weight: 800;
  color: var(--magenta-oscuro);
}

/* ---- Inputs de Pago ---- */
.ei-inputs-pago {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.ei-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.ei-label {
  font-family: "Nunito", sans-serif;
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--text-body);
}

.ei-select {
  width: 100%;
  padding: 13px 40px 13px 16px;
  font-family: "Nunito", sans-serif;
  font-size: 16px;
  font-weight: 600;
  color: var(--text-heading);
  border-radius: 10px;
  border: 1.5px solid var(--border-medium);
  background: var(--bg-accent-3);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%2374686e' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  appearance: none;
  -webkit-appearance: none;
  outline: none;
  cursor: pointer;
  transition: border-color 0.22s ease, background 0.22s ease, box-shadow 0.22s ease;
  box-sizing: border-box;
}

.ei-select:hover {
  border-color: var(--border-dark);
  background-color: var(--blanco);
}

.ei-select:focus {
  border-color: var(--magenta-oscuro);
  background-color: var(--blanco);
  box-shadow: 0 0 0 3px rgba(159, 39, 101, 0.10);
}

/* ---- Panel Instrucciones de Pago ---- */
#info-pago-panel {
  background: linear-gradient(135deg, rgba(28, 43, 90, 0.04), rgba(159, 39, 101, 0.04));
  border: 1.5px solid var(--border-light);
  border-radius: 14px;
  padding: 22px 24px;
  animation: authTabIn 0.25s ease;
}

.ei-pago-titulo {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: "Nunito", sans-serif;
  font-size: 14px;
  font-weight: 800;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  color: var(--azul-oscuro);
  margin: 0 0 14px 0;
}

.ei-pago-titulo svg {
  flex-shrink: 0;
  color: var(--magenta-oscuro);
}

.ei-pago-detalle {
  font-family: "Nunito", sans-serif;
  font-size: 16px;
  color: var(--text-body);
  line-height: 1.7;
}

/* ---- Botón Submit EI ---- */
.ei-btn-submit {
  width: 100%;
  padding: 18px;
  background: var(--magenta-oscuro);
  color: var(--blanco);
  border: none;
  border-radius: 14px;
  font-family: "Nunito", sans-serif;
  font-size: 15px;
  font-weight: 800;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  transition: background 0.25s ease, transform 0.2s ease, box-shadow 0.25s ease;
  box-shadow: 0 8px 24px rgba(159, 39, 101, 0.30);
  cursor: pointer;
}

.ei-btn-submit:hover {
  background: var(--magenta-hover);
  transform: translateY(-2px);
  box-shadow: 0 14px 32px rgba(159, 39, 101, 0.38);
}

.ei-btn-submit:active {
  transform: translateY(0);
}

.ei-footer-msg {
  font-family: "Nunito", sans-serif;
  font-size: 15px;
  color: #303030;
  text-align: center;
  margin: 14px 0 0 0;
  line-height: 1.5;
}

/* ---- Vista de Éxito ---- */
.ei-exito {
  display: none;
  text-align: center;
  padding: 50px 36px;
  animation: authFadeUp 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.ei-exito-icon {
  width: 88px;
  height: 88px;
  background: #e8f5e9;
  color: #2e7d32;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 24px;
  font-size: 44px;
  box-shadow: 0 8px 24px rgba(46, 125, 50, 0.18);
}

.ei-exito-titulo {
  font-family: "Philosopher", serif;
  font-size: 26px;
  font-weight: 700;
  color: var(--azul-oscuro);
  margin: 0 0 12px 0;
}

.ei-exito-desc {
  font-family: "Nunito", sans-serif;
  font-size: 16px;
  color: var(--text-soft);
  line-height: 1.7;
  margin: 0 0 28px 0;
}

.ei-btn-wa {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  background: #25D366;
  color: var(--blanco);
  padding: 18px 32px;
  border-radius: 14px;
  text-decoration: none;
  font-family: "Nunito", sans-serif;
  font-size: 16px;
  font-weight: 800;
  width: 100%;
  box-sizing: border-box;
  box-shadow: 0 8px 24px rgba(37, 211, 102, 0.28);
  transition: background 0.25s ease, transform 0.2s ease, box-shadow 0.25s ease;
}

.ei-btn-wa:hover {
  background: #128c7e;
  transform: translateY(-2px);
  box-shadow: 0 14px 32px rgba(37, 211, 102, 0.36);
}

/* Card de resumen específica para Paso 3 */
.ei-resumen-pago {
  background: #F4F7FA !important;
  /* Un tono sutilmente distinto para diferenciar */
  border-color: #D1D9E6 !important;
  margin-bottom: 24px;
}

/* Caja de showToasta/info sobre el comprobante */
.ei-showToasta-info {
  background: rgba(82, 167, 122, 0.1);
  border-left: 4px solid #52A77A;
  padding: 12px;
  margin-top: 15px;
  border-radius: 4px;
}

.ei-showToasta-texto {
  font-family: 'Nunito', sans-serif;
  font-size: 13px;
  color: #2E7D32;
  margin: 0;
  font-weight: 700;
}

/* Botones y Layout del Paso 3 */
.ei-btn-back {
  padding: 16px;
  font-size: 18px;
  width: 35%;
  border-radius: 14px;
  border: 1.5px solid #5a5a5a;
  background: rgb(235, 235, 235);
  font-family: 'Nunito', sans-serif;
  font-weight: 800;
  color: #373737;
  cursor: pointer;

  transition:
    background 0.25s ease,
    transform 0.2s ease,
    box-shadow 0.25s ease,
    border-color 0.25s ease;
}

.ei-btn-back:hover {
  background: #ffffff;
  border-color: var(--magenta-oscuro);
  color: var(--magenta-oscuro);

  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(159, 39, 101, 0.15);
}

.ei-btn-back:active {
  transform: translateY(0);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
}

.ei-flex-buttons {
  display: flex;
  gap: 12px;
  margin-top: 10px;
}

.ei-btn-submit-largo {
  width: 65% !important;
}

.ei-btn-full {
  width: 100% !important;
  margin-bottom: 12px;
  box-sizing: border-box;
}

/* ---- Nuevos Estilos para el Flujo por Pasos (Responsive) ---- */

.ei-stepper {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: #f5f6f8;
  border-radius: 30px;
  margin: 24px 32px 16px;
  font-family: "Nunito", sans-serif;
  font-size: 14px;
  color: #4a5568;
  padding: 4px;
  overflow: hidden;
}

.ei-step-item {
  padding: 8px 12px;
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
  transition: all 0.3s ease;
  border-radius: 20px;
  color: #4a5568;
}

.ei-step-item.active {
  background: #4a74b5;
  color: white;
  padding: 8px 16px;
}

.ei-step-icon {
  background: #2d3a5d;
  color: white;
  border-radius: 50%;
  width: 22px;
  height: 22px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: bold;
  transition: all 0.3s ease;
  flex-shrink: 0;
}

.ei-step-item.active .ei-step-icon {
  background: white;
  color: #4a74b5;
}

.ei-step-item.completed .ei-step-icon {
  background: #52a77a;
  color: white;
}

.ei-step-divider {
  flex-shrink: 0;
  margin: 0 4px;
}

/* ======================================================
   SECCIÓN: MODAL DE INFORMACIÓN (FAQ, Términos, Privacidad)
   ====================================================== */

.info-overlay {
  position: fixed;
  inset: 0;
  background: rgba(58, 46, 51, 0.50);
  z-index: 400;
  display: none;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  padding: 20px;
}

.info-overlay.open {
  display: flex;
}

.info-modal {
  background: var(--blanco);
  border-radius: var(--radius-lg);
  box-shadow:
    0 0 0 1px rgba(28, 43, 90, 0.07),
    0 32px 80px rgba(58, 46, 51, 0.20);
  width: 620px;
  max-width: 100%;
  max-height: 82vh;
  display: flex;
  flex-direction: column;
  position: relative;
  overflow: hidden;
  animation: authFadeUp 0.38s cubic-bezier(0.16, 1, 0.3, 1);
}

.info-header {
  padding: 26px 32px;
  background: var(--azul-oscuro);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-shrink: 0;
}

.info-header span {
  color: #fff;
}

.info-titulo {
  font-family: "Philosopher", serif;
  font-size: 23px;
  font-weight: 700;
  color: var(--blanco);
}

.info-titulo span {
  font-style: italic;
  color: var(--amarillo);
  font-weight: 400;
}

.cart-close {
  width: 38px;
  height: 38px;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.20);
  border-radius: 50%;
  color: var(--blanco);
  font-size: 18px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.22s ease, transform 0.22s ease;
  flex-shrink: 0;
}

.cart-close:hover {
  background: var(--magenta-oscuro);
  color: var(--blanco);
  transform: rotate(90deg);
}

.info-body {
  padding: 32px;
  overflow-y: auto;
  font-family: "Nunito", sans-serif;
  font-size: 16px;
  color: var(--text-body);
  line-height: 1.75;
}

.info-body h2,
.info-body h3 {
  font-family: "Philosopher", serif;
  color: var(--azul-oscuro);
  margin: 24px 0 10px;
}

.info-body h2 {
  font-size: 22px;
}

.info-body h3 {
  font-size: 18px;
}

.info-body p {
  margin: 0 0 14px 0;
  font-size: 17px;
}

.info-body a {
  color: var(--magenta-oscuro);
  font-weight: 700;
  text-decoration: none;
  border-bottom: 1.5px solid rgba(159, 39, 101, 0.25);
  transition: border-color 0.2s ease;
}

.info-body a:hover {
  border-color: var(--magenta-oscuro);
}

/* ======================================================
   MODAL DE INFORMACIÓN: CLASES PARA REEMPLAZAR INLINE STYLES
   ====================================================== */

/* Bloques generales */
.info-body .info-section {
  margin-bottom: 24px;
}

.info-body .info-title-line {
  color: #2c3e50;
  border-bottom: 2px solid #3498db;
  padding-bottom: 8px;
  margin: 0 0 12px 0;
  display: flex;
  align-items: center;
}

.info-body .info-title-icon {
  color: #3498db;
  margin-right: 12px;
  flex-shrink: 0;
}

.info-body .info-text-indented {
  line-height: 1.6;
  color: #444;
  margin-left: 28px;
  margin-bottom: 0;
}

.info-body .info-text {
  line-height: 1.6;
  color: #444;
  margin-bottom: 0;
}

.info-body .info-text.mb-20 {
  margin-bottom: 20px;
}

/* Callouts / avisos */
.info-body .info-callout-blue {
  background: #e8f4fd;
  border-left: 4px solid #3498db;
  padding: 16px;
  margin-bottom: 24px;
  border-radius: 4px;
}

.info-body .info-callout-blue p {
  margin: 0;
  color: #2980b9;
  font-size: 0.95rem;
  line-height: 1.5;
}

.info-body .info-callout-green {
  background: #e8f5e9;
  border-left: 4px solid #2e7d32;
  padding: 16px;
  margin-bottom: 24px;
  border-radius: 4px;
}

.info-body .info-callout-green p {
  margin: 0;
  color: #1b5e20;
  font-size: 0.95rem;
  line-height: 1.5;
}

.info-body .info-callout-warning {
  background: #fdf6e3;
  border-left: 4px solid #b58900;
  padding: 16px;
  margin-bottom: 24px;
  border-radius: 4px;
}

.info-body .info-callout-warning p {
  margin: 0;
  color: #856404;
  font-size: 0.95rem;
  line-height: 1.5;
}

.info-body .info-callout-lime {
  background: #fff9e6;
  border-left: 4px solid #f1c40f;
  padding: 16px;
  margin-bottom: 24px;
  border-radius: 4px;
}

.info-body .info-callout-lime p {
  margin: 0;
  color: #856404;
  font-size: 0.95rem;
  line-height: 1.5;
}

.info-body .info-callout-soft-red {
  background: #fdf2f2;
  border: 1px solid #f5c6cb;
  padding: 15px;
  border-radius: 8px;
  margin-bottom: 24px;
}

.info-body .info-callout-soft-red h5 {
  margin: 0 0 10px 0;
  color: #721c24;
}

.info-body .info-callout-soft-red p {
  margin: 0;
  color: #721c24;
  font-size: 0.9rem;
  line-height: 1.5;
}

.info-body .info-callout-soft-red small {
  display: block;
  margin-top: 4px;
}

/* Iconos dentro de callouts */
.info-body .info-callout-icon {
  vertical-align: middle;
  margin-right: 8px;
}

.info-body .info-svg-icon {
  margin-right: 10px;
  flex-shrink: 0;
}

/* Tarjetas de contenido */
.info-body .info-card {
  background: #ffffff;
  border: 1px solid #eee;
  padding: 20px;
  border-radius: 8px;
  margin-bottom: 24px;
}

.info-body .info-card-soft {
  background: #f8f9fa;
  padding: 20px;
  border-radius: 8px;
  margin-bottom: 24px;
  border: 1px solid #eee;
}

/* Títulos simples */
.info-body .info-title-simple {
  color: #2c3e50;
  border-bottom: 2px solid #eee;
  padding-bottom: 8px;
  margin: 0 0 16px 0;
}

.info-body .info-subtitle {
  color: #2c3e50;
  margin-top: 0;
  margin-bottom: 12px;
  font-size: 1.1rem;
}

/* Secciones con íconos */
.info-body .info-step-title {
  color: #2c3e50;
  border-bottom: 2px solid #eee;
  padding-bottom: 8px;
  margin: 0 0 16px 0;
  display: flex;
  align-items: center;
}

.info-body .info-step-badge {
  background: #e67e22;
  color: #fff;
  width: 24px;
  height: 24px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  margin-right: 12px;
  font-size: 14px;
  flex-shrink: 0;
}

/* Listas con checks */
.info-body .info-check-list {
  list-style: none;
  padding: 0;
  margin: 0 0 24px 0;
}

.info-body .info-check-item {
  margin-bottom: 12px;
  display: flex;
  align-items: flex-start;
}

.info-body .info-check-mark {
  color: #27ae60;
  margin-right: 12px;
  margin-top: 4px;
  flex-shrink: 0;
}

/* Bloques de datos */
.info-body .info-data-card {
  background: #f8f9fa;
  padding: 20px;
  border-radius: 8px;
  margin-bottom: 24px;
  border: 1px solid #eee;
}

.info-body .info-data-item {
  margin-bottom: 12px;
  border-bottom: 1px solid #eee;
  padding-bottom: 10px;
}

.info-body .info-data-item:last-child {
  margin-bottom: 0;
  border-bottom: none;
  padding-bottom: 0;
}

.info-body .info-data-label {
  color: #7f8c8d;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  display: block;
}

.info-body .info-data-label--small {
  font-size: 0.8rem;
}

.info-body .info-data-value {
  color: #2c3e50;
  font-size: 1.1rem;
  display: block;
  margin-top: 4px;
}

.info-body .info-data-value--large {
  font-size: 1.2rem;
  letter-spacing: 1px;
}

.info-body .info-data-value--bold {
  font-weight: 700;
}

/* Párrafos y detalles de cierre */
.info-body .info-confirmation {
  line-height: 1.6;
  color: #444;
}

.info-body .info-confirmation strong {
  font-weight: 700;
}

/* ======================================================
   RESPONSIVIDAD GENERAL MODALES
   ====================================================== */

@media (max-width: 768px) {
  .auth-overlay {
    padding: 0;
    /* Eliminamos el padding para que pegue a los lados */
    align-items: flex-end;
    /* Aseguramos que pegue abajo */
    height: 100dvh;
  }

  .auth-modal {
    width: 100%;
    max-width: 100% !important;
    max-height: 92dvh;
    border-radius: 24px 24px 0 0;
    /* Redondo solo arriba */
    align-self: flex-end;
    margin: 0;
    animation: authSlideUp 0.42s cubic-bezier(0.16, 1, 0.3, 1) forwards;
    overflow-y: auto;
  }

  .auth-modal.registro-activo #registerForm {
    display: grid;
    grid-template-columns: repeat(1, 1fr);
    gap: 20px;
  }

  .ei-modal,
  .info-modal {
    width: 95%;
    max-height: 92dvh;
    border-radius: 20px;
    align-self: center;
    overflow-y: auto;
  }

  .ei-header {
    padding: 20px 20px;
    /* Reducimos padding del header */
  }

  .ei-stepper {
    margin: 12px 12px 8px;
    font-size: 11px;
    justify-content: space-around;
    /* Mejor distribución en móvil */
    gap: 2px;
  }

  .ei-step-item {
    padding: 6px 4px;
    gap: 4px;
    flex: 0 1 auto;
    /* Permite que se encojan */
  }

  .ei-step-item.active {
    padding: 6px 10px;
  }

  /* Ocultamos el texto en móviles para que solo queden los círculos */
  .ei-step-item span:not(.ei-step-icon) {
    display: none;
  }

  /* El texto del paso ACTIVO solo se muestra si hay espacio suficiente (ej. > 400px) */
  @media (min-width: 400px) {
    .ei-step-item.active span:not(.ei-step-icon) {
      display: inline;
    }
  }

  .ei-step-divider {
    margin: 0 2px;
    width: 10px;
  }

  .ei-form {
    padding: 16px 20px;
    /* Reducimos padding interno del formulario */
  }

  .ei-card-datos {
    padding: 16px;
    /* Reducimos padding de la tarjeta de datos */
    margin-bottom: 16px !important;
  }

  .ei-inputs-pago {
    gap: 12px;
    /* Reducimos espacio entre inputs */
  }

  .ei-flex-buttons {
    margin-top: 8px;
  }

  .ei-btn-wa {
    padding: 14px 16px;
  }
}

@media (max-width: 480px) {
  .ei-modal {
    width: 98%;
  }

  .ei-header {
    padding: 16px 15px;
  }

  .ei-titulo {
    font-size: 17px;
    text-align: start;
    width: 80%;
  }

  .ei-cerrar {
    position: absolute;
    top: 50%;
    right: 20px;
    transform: translateY(-50%);

    width: 30px;
    height: 30px;
  }

  .ei-user-name {
    font-size: 16px;
    margin-top: 6px !important;
  }

  .ei-user-email,
  .ei-user-country,
  .ei-phone-box {
    font-size: 13px;
  }

  .ei-stepper {
    margin: 8px 8px;
  }

  .ei-flex-buttons {
    gap: 8px;
    margin-top: 12px;
  }

  .ei-btn-back,
  .ei-btn-submit-largo {
    padding: 12px;
    font-size: 14px;
  }
}

/* ======================================================
   ESTILOS CAPTCHA TURNSTILE
   ====================================================== */
.auth-captcha-wrapper {
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
}

.cf-turnstile {
    max-width: 100%;
}