/* ==========================================================================
   Login Propuesta — Premium Glassmorphism Login Styling
   ========================================================================== */

/* ---------- Custom Properties ---------- */
:root {
  --lp-primary:        #0f2640;
  --lp-accent:         #01488d;
  --lp-accent-hover:   #00356b;
  --lp-green:          #6abf4b;
  --lp-text-light:     #ffffff;
  --lp-text-muted:     rgba(255, 255, 255, 0.7);
  --lp-card-bg:        rgba(15, 34, 55, 0.68);
  --lp-card-border:    rgba(255, 255, 255, 0.1);
  --lp-transition:     0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ---------- Reset & Base ---------- */
body.login-propuesta.login-page {
  margin: 0;
  padding: 0;
  min-height: 100vh;
  /* Misma cadena que AdminLTE: no se carga ninguna fuente externa. Si Source Sans Pro
     no esta disponible, cae al stack del sistema operativo. */
  font-family: "Source Sans Pro", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
               "Helvetica Neue", Arial, sans-serif;
  display: flex !important;
  flex-direction: column !important;
  align-items: stretch !important;
  justify-content: space-between !important;
  height: auto !important;
  background: url("/static/img/fondo.webp") no-repeat center center fixed !important;
  background-size: cover !important;
  color: var(--lp-text-light);
  overflow-x: hidden;
  position: relative;
}



/* ---------- Top Bar (Cabecera Transparente Flotante) ---------- */
.lp-topbar {
  position: relative;
  z-index: 1050;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.25rem 2rem;
  background: transparent !important;
  border-bottom: none !important;
}

.lp-brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
}

.lp-brand__icon {
  width: 40px;
  height: 40px;
  background-color: #0f2640 !important; /* Logo sólido en duro */
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.lp-brand__icon img {
  width: 26px;
  height: auto;
  filter: brightness(10);
}

.lp-brand__text {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
}

.lp-brand__name {
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--lp-text-light) !important;
  letter-spacing: 1px;
}

.lp-brand__subtitle {
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--lp-text-muted) !important;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

/* Language toggle styling override — medio transparente con blur (como pie de página) */
.lp-topbar .lang-toggle .btn {
  background: rgba(15, 34, 55, 0.75) !important;
  backdrop-filter: blur(24px) saturate(1.4);
  -webkit-backdrop-filter: blur(24px) saturate(1.4);
  border: 1px solid rgba(255, 255, 255, 0.12) !important;
  color: rgba(255, 255, 255, 0.85) !important;
  font-size: 0.85rem;
  font-weight: 500;
  border-radius: 6px;
  padding: 0.4rem 0.8rem;
  transition: var(--lp-transition);
}

.lp-topbar .lang-toggle .btn:hover,
.lp-topbar .lang-toggle .btn:focus {
  background: rgba(15, 23, 42, 0.95) !important;
  color: #ffffff !important;
  border-color: rgba(255, 255, 255, 0.25) !important;
}

.lp-topbar .lang-toggle .dropdown-menu {
  background: rgba(15, 34, 55, 0.88) !important;
  backdrop-filter: blur(24px) saturate(1.4);
  -webkit-backdrop-filter: blur(24px) saturate(1.4);
  border: 1px solid rgba(255, 255, 255, 0.1) !important;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4) !important;
  border-radius: 6px;
  margin-top: 4px;
}

.lp-topbar .lang-toggle .dropdown-item {
  color: rgba(255, 255, 255, 0.8) !important;
  font-size: 0.85rem;
  padding: 0.5rem 1rem;
  transition: var(--lp-transition);
}

.lp-topbar .lang-toggle .dropdown-item:hover {
  background: rgba(255, 255, 255, 0.08) !important;
  color: #ffffff !important;
}

/* ---------- Main Content (Centrado) ---------- */
.lp-main {
  position: relative;
  z-index: 10;
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2.5rem 1rem;
}

/* ---------- Card Premium Glassmorphism ---------- */
.lp-card {
  width: 100%;
  max-width: 440px;
  background: var(--lp-card-bg) !important;
  backdrop-filter: blur(24px) saturate(1.4);
  -webkit-backdrop-filter: blur(24px) saturate(1.4);
  border: 1px solid var(--lp-card-border) !important;
  border-radius: 16px;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.35);
  padding: 2.5rem 2.25rem 2rem;
  animation: lp-fadeUp 0.6s cubic-bezier(0.16, 1, 0.3, 1) both;
}

@keyframes lp-fadeUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ---------- Card Header ---------- */
.lp-card__header {
  text-align: center;
  margin-bottom: 1.5rem;
}

.lp-card__seal {
  width: 85px;
  height: auto;
  margin: 0 auto 1.25rem;
  filter: brightness(0) invert(1) drop-shadow(0 4px 8px rgba(0, 0, 0, 0.3));
  transition: var(--lp-transition);
}

.lp-card__seal:hover {
  transform: scale(1.04);
}

.lp-card__title {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--lp-text-light);
  line-height: 1.4;
  margin-bottom: 0.5rem;
  letter-spacing: 0.5px;
}

.lp-card__subtitle {
  font-size: 0.85rem;
  color: var(--lp-text-muted);
  font-weight: 400;
}

.lp-card__divider {
  width: 45px;
  height: 3px;
  background: var(--lp-green);
  border: none;
  border-radius: 2px;
  margin: 1.25rem auto 0;
}

/* ---------- Alerts ---------- */
.lp-alert {
  background: rgba(239, 68, 68, 0.15) !important;
  border: 1px solid rgba(239, 68, 68, 0.3) !important;
  border-radius: 8px;
  padding: 0.75rem 1rem;
  margin-bottom: 1.25rem;
  color: #fca5a5 !important;
  font-size: 0.85rem;
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.lp-alert--warning {
  background: rgba(245, 158, 11, 0.12) !important;
  border-color: rgba(245, 158, 11, 0.25) !important;
  color: #fde68a !important;
}

.lp-alert i {
  display: inline-flex;
  align-items: center;
  line-height: 1;
  flex-shrink: 0;
  transform: translateY(1px);
}

.lp-alert__close {
  background: none;
  border: none;
  color: inherit;
  margin-left: auto;
  cursor: pointer;
  font-size: 1.1rem;
  opacity: 0.6;
  transition: opacity var(--lp-transition);
  padding: 0;
  line-height: 1;
}

.lp-alert__close:hover {
  opacity: 1;
}

/* ---------- Form ---------- */
.lp-form {
  margin-top: 1.5rem;
}

/* Input group */
.lp-input-group {
  position: relative;
  margin-bottom: 0;
}

.lp-input-group__icon {
  position: absolute;
  left: 1rem;
  top: 50%;
  transform: translateY(-50%);
  color: rgba(255, 255, 255, 0.5);
  font-size: 0.95rem;
  z-index: 2;
  pointer-events: none;
  transition: color var(--lp-transition);
}

.lp-input-group__field {
  width: 100%;
  padding: 0.85rem 1rem 0.85rem 2.75rem;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 8px;
  color: var(--lp-text-light);
  font-size: 0.95rem;
  font-family: inherit;
  outline: none;
  transition: var(--lp-transition);
  box-sizing: border-box;
}

.lp-input-group__field::placeholder {
  color: rgba(255, 255, 255, 0.4);
}

.lp-input-group__field:focus {
  border-color: var(--lp-accent);
  background: rgba(255, 255, 255, 0.08);
  box-shadow: 0 0 0 3px rgba(1, 72, 141, 0.25);
}

.lp-input-group__field:focus ~ .lp-input-group__icon {
  color: #38bdf8;
}

/* Password toggle */
.lp-input-group__toggle {
  position: absolute;
  right: 1rem;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: rgba(255, 255, 255, 0.5);
  cursor: pointer;
  font-size: 0.95rem;
  z-index: 2;
  padding: 4px;
  transition: color var(--lp-transition);
}

.lp-input-group__toggle:hover {
  color: var(--lp-text-light);
}

/* Submit button (Azul Mockup) ---------- */
.lp-btn-submit {
  display: block;
  width: 100%;
  padding: 0.85rem;
  margin-top: 0.5rem;
  background: var(--lp-accent);
  color: var(--lp-text-light);
  border: none;
  border-radius: 8px;
  font-size: 1rem;
  font-weight: 600;
  font-family: inherit;
  letter-spacing: 0.5px;
  cursor: pointer;
  transition: var(--lp-transition);
  box-shadow: 0 4px 12px rgba(1, 72, 141, 0.3);
}

.lp-btn-submit:hover:not(:disabled) {
  background: var(--lp-accent-hover);
  box-shadow: 0 6px 16px rgba(1, 72, 141, 0.45);
  transform: translateY(-1px);
}

.lp-btn-submit:active:not(:disabled) {
  transform: translateY(0);
  box-shadow: 0 2px 8px rgba(1, 72, 141, 0.3);
}

.lp-btn-submit:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

/* Form Row Layout & Labels */
.lp-form-group {
  margin-bottom: 1.25rem;
}

.lp-form-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.45rem;
}

.lp-form-label {
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: rgba(255, 255, 255, 0.55);
  margin-bottom: 0;
}

.lp-forgot-wrapper {
  text-align: center;
  margin-top: 1.25rem;
}

/* Forgot password link */
.lp-forgot-link {
  font-size: 0.72rem;
  font-weight: 500;
  color: #38bdf8;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  transition: var(--lp-transition);
}

.lp-forgot-link i {
  font-size: 0.7rem;
  transition: transform 0.3s ease;
}

.lp-forgot-link:hover {
  color: #ffffff;
  text-shadow: 0 0 8px rgba(56, 189, 248, 0.5);
}

.lp-forgot-link:hover i {
  transform: rotate(-15deg) scale(1.1);
}

/* ---------- Feature Badges ---------- */
.lp-features {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.lp-feature {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  flex: 1;
}

.lp-feature__icon {
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: rgba(106, 191, 75, 0.12);
  border: 1px solid rgba(106, 191, 75, 0.25);
  color: var(--lp-green);
  font-size: 0.95rem;
  margin-bottom: 0.5rem;
  transition: var(--lp-transition);
}

.lp-feature:hover .lp-feature__icon {
  background: rgba(106, 191, 75, 0.22);
  transform: translateY(-2px);
}

.lp-feature__label {
  font-size: 0.65rem;
  font-weight: 500;
  color: var(--lp-text-muted);
  line-height: 1.2;
}

/* ---------- Footer (Cabecera Oscura Inferior) ---------- */
.lp-footer {
  position: relative;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 2rem;
  background: rgba(15, 34, 55, 0.85) !important;
  backdrop-filter: blur(24px) saturate(1.4);
  -webkit-backdrop-filter: blur(24px) saturate(1.4);
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  color: rgba(255, 255, 255, 0.6);
}

.lp-footer__left {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

.lp-footer__left i {
  color: var(--lp-green);
  font-size: 0.95rem;
  display: inline-flex;
  align-items: center;
  line-height: 1;
}

.lp-footer__right {
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 0.5px;
}

/* ---------- Responsive ---------- */
@media (max-width: 576px) {
  .lp-topbar {
    padding: 0.75rem 1.25rem;
  }

  .lp-brand__name {
    font-size: 1.1rem;
  }

  .lp-card {
    padding: 2rem 1.5rem 1.5rem;
    margin: 0 0.5rem;
  }

  .lp-card__title {
    font-size: 1rem;
  }

  .lp-features {
    gap: 0.5rem;
  }

  .lp-feature__icon {
    width: 32px;
    height: 32px;
    font-size: 0.85rem;
  }

  .lp-feature__label {
    font-size: 0.6rem;
  }

  .lp-footer {
    padding: 0.85rem 1.25rem;
    flex-direction: column;
    gap: 0.5rem;
    text-align: center;
  }
}

.lp-footer-link {
  color: inherit !important;
  text-decoration: none !important;
  cursor: pointer;
}
.lp-footer-link:hover, .lp-footer-link:focus, .lp-footer-link:active {
  color: inherit !important;
  text-decoration: none !important;
}

/* ---------- Vertical Responsiveness (Notebooks and short screens) ---------- */
@media (max-height: 800px) {
  .lp-topbar {
    padding: 0.75rem 1.5rem;
  }

  .lp-main {
    padding: 1rem 1rem;
  }

  .lp-card {
    padding: 1.75rem 1.75rem 1.25rem;
  }

  .lp-card__seal {
    width: 65px;
    margin-bottom: 0.75rem;
  }

  .lp-card__header {
    margin-bottom: 1rem;
  }

  .lp-card__divider {
    margin: 0.75rem auto 0;
  }

  .lp-form-group {
    margin-bottom: 0.85rem;
  }

  .lp-form-label {
    margin-bottom: 0.25rem;
  }

  .lp-features {
    margin-top: 1.25rem;
    padding-top: 1rem;
  }
}


/* ===== Cloudflare Turnstile ===== */
.lp-turnstile {
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* El widget de Cloudflare es un iframe de ancho fijo: se deja escalar hacia
   abajo para que no desborde la tarjeta en pantallas angostas. */
.lp-turnstile .cf-turnstile {
  max-width: 100%;
  overflow: hidden;
}
