/* homePopUp.css (reemplaza/añade estas reglas) */

.home-popup-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.85);
    z-index: 9999;
    overflow: auto;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    box-sizing: border-box;
    backdrop-filter: blur(3px); /* Añade efecto blur al fondo */
    -webkit-backdrop-filter: blur(3px); /* Compatibilidad Safari */
}

.home-popup-wrapper {
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;             /* fuerza el centrado horizontal del wrapper */
  border-radius: 10px;
  overflow: hidden;
  position: relative;
  box-shadow: 0 8px 30px rgba(0,0,0,0.4);
  background: transparent;
  box-sizing: border-box;
}

/* Close button — visible en cualquier fondo */
.home-popup-close {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 42px;
  height: 42px;
  display:flex;
  align-items:center;
  justify-content:center;
  background: rgba(0,0,0,0.55);
  border: none;
  border-radius: 50%;
  color: #fff;
  font-size: 22px;
  z-index: 11000;
  cursor: pointer;
  box-shadow: 0 2px 6px rgba(0,0,0,0.3);
}

/* Container and row: centro y control de ancho */
.home-popup-container {
  width: 100%;
  margin: 0 auto;

  box-sizing: border-box;
}

.home-popup-row {
  display: flex;
  flex-direction: row;
  align-items: stretch;
  justify-content: center;   /* si sobra espacio, centra la row en el wrapper */
  width: 100%;
  max-width: 1100px;         /* evita que la fila ocupe todo el ancho del wrapper */
  margin: 0 auto;
  box-sizing: border-box;
}

/* Image module (left) */
.home-popup-image {
  flex: 0 0 50%;             /* fija la mitad izquierda */
  width: 50%;
  min-height: 380px;
  background-size: cover;
  background-position: center;
  display: block;
  text-decoration: none;
  box-sizing: border-box;
}
@media (max-width: 769px) {
  .home-popup-image {
    width: 100%;
    flex: 0 0 100%;
    max-height: 300px;
    min-height: 300px;
  }
}

/* Content area (derecha) */
.home-popup-description {
  flex: 0 0 50%;             /* fija la mitad derecha */
  width: 50%;
  display: flex;
  align-items: center;       /* centrar verticalmente el contenido dentro de su columna */
  justify-content: center;   /* centrar horizontalmente el contenido-inner dentro de la columna */
  padding: 30px 36px;
  box-sizing: border-box;
}
@media (max-width: 769px) {
  .home-popup-description {
    width: 100%;
    flex: 0 0 100%;
    padding: 20px;
  }
}

/* Inner content centrado dentro de la columna */
.content-inner {
  width: 100%;
  max-width: 420px;
  margin: 0 auto;            /* centra el bloque en la mitad derecha */
  color: #fff;
  box-sizing: border-box;
  text-align: left;          /* mantener texto alineado a la izquierda dentro del bloque */
}

/* Tipografías y tamaños */
.home-popup-title {
  font-family: "Open Sans", sans-serif;
  font-size: 18px;
  line-height: 23px;
  font-weight: bold;
  text-transform: uppercase;
  margin-bottom: 20px;
}

@media (max-width: 769px) {
  .home-popup-title { font-size: 18pt; line-height: 23pt; }
}

/* Texto descriptivo y CTA */
.description-text {
  font-family: "Open Sans", sans-serif;
    font-size: 18px;
  line-height: 23px;
  margin-bottom: 16px;
  color: inherit;
}
@media (max-width: 769px) {
  .description-text { font-size: 16px; }
}

.home-popup-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.5rem 2rem;
  min-width: 140px;
  border-radius: 5px;
  font-weight: bold;
  font-size: 17px;
  text-decoration: none;
  background-color: #DA291C; /* fallback */
  color: white;             /* fallback */
}


/* Si por alguna razón existen reglas de "col-*" o floats del framework, forzamos comportamiento flex */
.home-popup-row .home-popup-image,
.home-popup-row .home-popup-description {
  float: none !important;
}

/* --- Responsive forced rules for mobile --- */
/* Usa un selector con mayor especificidad y !important para sobreescribir frameworks */
@media (max-width: 768px) {
  /* fuerza que la fila sea columna */
  .home-popup-wrapper .home-popup-container .home-popup-row,
  .home-popup-wrapper .home-popup-row,
  .home-popup-overlay .home-popup-row {
    flex-direction: column !important;
    display: flex !important;
    width: 100% !important;
  }

  /* imagen y descripción ocupan 100% */
  .home-popup-wrapper .home-popup-row .home-popup-image,
  .home-popup-row .home-popup-image {
    flex: 0 0 100% !important;
    width: 100% !important;
    max-height: 300px !important;
    min-height: 300px !important;
  }

  .home-popup-wrapper .home-popup-row .home-popup-description,
  .home-popup-row .home-popup-description {
    flex: 0 0 100% !important;
    width: 100% !important;
    padding: 16px !important;
    align-items: stretch !important; /* para que el contenido no quede pegado */
    justify-content: flex-start !important;
  }

  /* centro interno */
  .home-popup-wrapper .home-popup-row .content-inner,
  .home-popup-row .content-inner {
    margin: 0 auto !important;
    text-align: left !important;
    max-width: 100% !important;
  }

  /* botón full width en mobile */
  .home-popup-wrapper {
    width: 100% !important;
    display: block !important;
    box-sizing: border-box !important;
  }
}

