/* 
  Nuevo diseño para el Login basado en Figma 
*/

:root {
  /*--login-left-panel-bg: rgba(5, 1, 25, 0.38); /* slightly more transparent than before */
  --login-left-panel-bg: rgba(0, 0, 0, 0.5);
  --login-input-bg: rgba(37, 29, 73, 0.3);
  --login-input-border: #58B2CD;
  --login-button-bg: #382B6E;
  --login-text-color: #FFFFFF;
  --login-font-family: 'Montserrat', sans-serif;
  --login-solid-bg: #251D49;
}

body {
  font-family: var(--login-font-family);
  height: 100vh;
  margin: 0;
  overflow: hidden; /* Evitar scroll en la página de login */
}

/* Contenedor principal */
.xl-login {
  display: flex;
  width: 100%;
  height: 100vh;
  position: relative;
  /* 1. El fondo ahora es la imagen de la ciudad */
  background-image: url('/images/ciudad.png');
  background-size: cover;
  background-position: center;
}

/* Overlay gradient that tints the city image */
.xl-login::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  /* Más transparencia para dejar ver mejor la foto */
  background:
  radial-gradient(1200px 600px at 38% 88%, rgba(166, 29, 70, 0.20), rgba(166, 29, 70, 0) 62%),
  linear-gradient(47.73deg, rgba(166, 29, 70, 0.0) 0.12%, rgba(69, 29, 72, 0.15) 28.31%, rgba(37, 29, 73, 0.60) 75.31%);
  z-index: 1;
  pointer-events: none; /* no bloquear interacciones */
}

/* Dark tint overlay only for the left panel, without blur */
.xl-login__left::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(37,29,73,0.50) 0%, rgba(69,29,72,0.45) 60%, rgba(166,29,70,0.35) 100%);
  pointer-events: none;
  z-index: -1; /* keep under content */
}

/* Panel Izquierdo */
.xl-login__left {
  background: var(--login-left-panel-bg);
  /* remove blur to keep background sharp */
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  width: 462px;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 27px 37px;
  position: relative;
  z-index: 2;
  box-shadow: 0px 2px 36px rgba(0, 0, 0, 0.25);
}

/* Panel Derecho */
.xl-login__right {
  flex-grow: 1;
  height: 100%;
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 2;
}

/* Clear any conflicting background set elsewhere (e.g., header.css) */
.xl-login__right { 
  background: none !important; 
  box-shadow: none; 
}

/* Visually-hidden utility class */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border-width: 0;
}

/* Positioning for image-based claim */
.xl-login__claim-img {
  position: absolute;
  top: 82px;
  right: 100px;
  width: 480px;
  height: auto;
  object-fit: contain;
  z-index: 2;
}

@media (max-width: 1400px) { .xl-login__claim-img { width: 420px; right: 88px; } }
@media (max-width: 1200px) { .xl-login__claim-img { width: 300px; right: 64px; } }
@media (max-width: 992px)  { .xl-login__claim-img { width: 200px; right: 40px; } }
@media (max-width: 768px)  { .xl-login__claim-img { display: none; } }

/* Logo */
.xl-login__brand {
  margin-bottom: 24px;
}

.xl-login__brand img {
  width: 226px;
  height: auto;
}

/* Formulario */
.xl-login__form {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  max-width: 315px;
}

.xl-login__field {
  width: 100%;
  margin-bottom: 16px;
}

.xl-login__field label {
  display: block;
  font-size: 14px;
  color: var(--login-text-color);
  margin-bottom: 4px;
  padding-left: 10px;
  font-weight: 400;
  line-height: 17px;
}

.xl-input {
  width: 100%;
  height: 40px;
  background: var(--login-input-bg);
  border: 1px solid var(--login-input-border);
  border-radius: 50px;
  padding: 8px 20px;
  color: var(--login-text-color);
  font-size: 16px;
}

.xl-input::placeholder {
  color: rgba(255, 255, 255, 0.7);
}

.xl-inputWrap {
  position: relative;
  display: flex;
  align-items: center;
}

.xl-eye {
  position: absolute;
  right: 15px;
  width: 24px;
  height: 24px;
  background-color: transparent;
  border: none;
  cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2358B2CD' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M1 12s4-8 11-8 11 8 11 8-4 8-11 8-11-8-11-8z'%3E%3C/path%3E%3Ccircle cx='12' cy='12' r='3'%3E%3C/circle%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center;
}


/* Checkbox */
.xl-login__policy {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  margin-bottom: 16px;
}

.xl-login__policy input[type="checkbox"] {
  width: 15px;
  height: 15px;
  accent-color: var(--login-button-bg);
}

.xl-login__policy label {
  font-size: 14px;
  color: var(--login-text-color);
  font-weight: 400;
  line-height: 17px;
}

.xl-login__policy label a {
  color: var(--login-text-color);
  text-decoration: underline;
}

/* Botón de Ingresar */
.xl-login__submit {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 140px;
  height: 40px;
  background: var(--login-button-bg);
  box-shadow: 0px 1px 2px rgba(0, 0, 0, 0.25);
  border-radius: 50px;
  border: none;
  color: var(--login-text-color);
  font-size: 16px;
  font-weight: 500;
  line-height: 20px; /* Añadido para consistencia */
  cursor: pointer;
  margin-bottom: 16px;
  padding: 10px 15px; /* Añadido de Figma */
}

/* Recordar contraseña y mensajes */
.xl-login__link {
  font-size: 14px;
  text-decoration: underline;
  color: var(--login-text-color);
  margin-bottom: 8px;
  font-weight: 400;
  line-height: 17px;
}

.xl-login__msg {
  color: #ffcdd2; /* Un rojo claro para mensajes de error */
  min-height: 20px;
}

/* Botón de ayuda */
.xl-help {
  position: absolute;
  top: 27px;
  right: 27px;
  width: 35px;
  height: 35px;
  background: var(--login-solid-bg);
  border-radius: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
  box-shadow: 0px 3px 25px rgba(0, 0, 0, 0.4);
  outline: none; /* ✅ Evita el borde blanco */
  border: none;   /* ✅ Asegura que no haya borde */
}
.xl-help svg {
  width: 24px;
  height: 24px;
  color: #FFFFFF;
}

.xl-login__claimMobile { display: none; }

/* Responsive para móviles */
@media (max-width: 768px) {
  .xl-login__right {
    display: none;
  }
  .xl-login__left {
    width: 100%;
    background: var(--login-solid-bg);
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
  }
}