html, body {
    margin: 0;
    padding: 0;
    width: 100%;
    height: 100%;
    overflow-x: hidden; /* Evita el scroll horizontal */
}


body {
    font-family: 'Helvetica Neue', Helvetica, sans-serif;
    text-align: center;
    margin: 0;
  overflow-x: hidden;
}



.mapa-h1 {
    color: #382C14;
    font-size: 35px;
    max-width: 800px;
    text-align: center;
    width: 100%; /* Ocupa todo el ancho disponible */
    /* margin-top: 20px; Añade un poco de espacio arriba */
    margin: 20px auto;
}

/* Centrar el texto del h1 */
/* .centrado {
    text-align: center;
} */

.mapa-h2 {
    color: #382C14;
    font-size: 21px;
    text-align: center;
    margin-bottom: 20px; /* Espacio debajo del h2 */
}

.mapa-p {
    color: #334155;
    font-size: 20px;
    /*text-align: center;*/
      max-width: 60ch;
  width: 100%;
    margin: 20px auto; /* Centra y agrega espacio entre los párrafos */
    line-height: 1.6; /* Espaciado entre líneas */
    padding: 0 2rem;
    box-sizing: border-box;
    text-align: justify;
}

#map {
    width: 100vw;
    height: 80vh; /* Reducir la altura para que se vea el contenido debajo */
    max-width: 100%;
   
}

.gm-style-iw-d {
    overflow: hidden !important; /* Forzar la eliminación del scroll */
    max-height: none !important; 

}

/* Google fija una altura máxima en el contenedor EXTERIOR de la burbuja; al quitarla,
   la burbuja crece hacia arriba según lo que lleve dentro (título largo + texto largo). */
.gm-style .gm-style-iw-c {
    max-height: none !important;
}
.infowindow {
    /* width: 204px;
    padding: 5px; 
    font-family: Helvetica, sans-serif;
    overflow: hidden; 
    box-sizing: border-box;  */
    /* Asegura que el padding no exceda el tamaño del contenedor */

    display: flex;
    flex-direction: column;
    align-items: center; /* Centra horizontalmente */
    text-align: center; /* Centra el texto */
    width: 220px; /* Ancho de la infobox */
    max-width: 100%;
    padding: 8px 10px 10px; /* arriba 8px (antes había un hueco grande por el encabezado de Google) */
    /*max-width: 250px; /* Ajusta el ancho máximo */
    gap: 2px;

}

.infowindow-img {
    width: 100%;
    height: auto;          /* alto fijo: la burbuja no cambia de tamaño según la foto */
    aspect-ratio: 3 / 2;
    object-fit: cover;
    border-radius: 8px;
}

.infowindow-content {
   /* padding: 5px 0; /*
    /* Ajuste del padding interno */
   /* font-family: Helvetica, sans-serif;
    box-sizing: border-box; */
    /* Asegura que el padding no exceda el tamaño del contenedor */

    margin-top: 5px; /* Espacio superior */

}

.infowindow-location {
    font-size: 11px;
    font-weight: bold;
    color: #654321;
    text-transform: uppercase;
}

.infowindow-title {
    font-size: 18px;
    font-weight: bold;
    margin: 5px 0;
}

.infowindow-description {
    font-size: 14px;
    color: #333;
    line-height: 1.2;
    /* Sin altura máxima fija: el texto se muestra completo hasta 6 líneas (160 caracteres caben);
       si alguna vez pasa de 6 líneas, se corta con "…" en vez de a media línea. */
    display: -webkit-box;
    -webkit-line-clamp: 6;
    line-clamp: 6;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Pantallas bajas (celular en horizontal, ventanas pequeñas): burbuja más compacta */
@media (max-height: 600px) {
    .infowindow-img { height: auto; }
    .infowindow-description { -webkit-line-clamp: 4; line-clamp: 4; }
}


.infowindow-link {
    text-decoration: none;
    color: inherit;
    display: block;
}

.infowindow-title:hover {
    text-decoration: underline;
}

.gm-style-iw {
    padding: 0 !important;
    max-width: 100%;
    
}

.gm-ui-hover-effect {
    display: none !important;
}

  
.mapa-p:first-of-type::first-letter {
  /* tamaño algo menor para que no desborde tanto */
  font-size: 4rem;
  /* que flote a la izquierda y el texto lo rodee */
  float: left;
  /* margen: 0 arriba, 0.2em a la derecha, 0 abajo, 0 a la izquierda */
  margin: 0 0.2em 0 0;
  /* que la letra ocupe justo su alto, sin colchoneta extra */
  line-height: 1;
  /* opcional: ajusta font y peso si quieres más contraste */
  font-family: Georgia, serif;
  font-weight: bold;
  /* color a tu gusto */
  color: #334155;
}



/* ============================================================
   INFOBOX PROPIA (reemplaza a google.maps.InfoWindow)
   ============================================================ */
.atlas-popup-ancla {
    position: absolute;
    width: 0;
    height: 0;
}

.atlas-popup {
    position: absolute;
    left: 0;
    transform: translateX(-50%);   /* centrada sobre el pin */
    width: max-content;
    /* misma tipografía que tenía la infobox de Google */
    font-family: Roboto, Arial, sans-serif;
    font-weight: 300;
    font-size: 13px;
    line-height: normal;
    color: #000;
    /* la sombra sigue la forma de la caja Y de la cola */
    filter: drop-shadow(0 2px 5px rgba(0, 0, 0, 0.3));
    cursor: default;
}

.atlas-popup-caja {
    background: #fff;
    border-radius: 8px;
}

.atlas-popup-cola {
    position: absolute;
    left: 50%;
    width: 20px;
    height: 10px;
    margin-left: -10px;
    background: #fff;
}

/* Nace ARRIBA del pin (por defecto): cola hacia abajo */
.atlas-popup.arriba { bottom: 42px; }
.atlas-popup.arriba .atlas-popup-cola {
    top: 100%;
    clip-path: polygon(0 0, 100% 0, 50% 100%);
}

/* Nace ABAJO del pin (solo si arriba no cabe): cola hacia arriba */
.atlas-popup.abajo { top: 12px; }
.atlas-popup.abajo .atlas-popup-cola {
    bottom: 100%;
    clip-path: polygon(50% 0, 0 100%, 100% 100%);
}
