/* Estilos Generales */
body {
    font-family: 'Montserrat', sans-serif;
    background-color: #F2F2F2;
    color: #020202;
    margin: 0;
    padding: 0;
    scroll-behavior: smooth;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 50px 20px;
}

/* Nueva clase para que cada sección ocupe el tamaño completo */
.full-section {
    min-height: 100vh; /* Mantenemos la altura mínima del 100% del viewport */
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 50px 20px;
    box-sizing: border-box;
    text-align: center;
    background-color: #FFFFFF; /* Fondo blanco para estas secciones, como habíamos definido */
}

/* Ajuste específico para la sección de servicios, que no debería tener min-height 100vh */
/* La mantenemos dentro de .full-section para el centrado, pero modificamos su altura */
.full-section:not(.hero-section) #servicios {
    min-height: auto; /* Quitamos el min-height 100vh de la sección de servicios */
    padding: 50px 0; /* Ajustamos el padding para que no interfiera con el del .full-section */
}
/* Aseguramos que el .container dentro de .full-section esté bien gestionado */
.full-section .container {
    padding: 50px 20px; /* Asegura el padding correcto dentro de la sección */
}


/* Sección Hero */
.hero-section {
    background-color: #F2F2F2; /* Fondo gris claro */
    height: 100vh; /* Ocupa el 100% de la altura de la ventana visible */
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 20px;
    text-align: center;
}

h1, h2, h3 {
    color: #020202;
    text-align: center;
    margin-bottom: 30px;
}

h2 {
    font-size: 2.8em;
    color: #020202;
}

h3 {
    font-size: 2em;
    color: #59161C;
    margin-bottom: 15px;
}

a {
    color: #9e9e9e;
    text-decoration: none;
    transition: color 0.3s ease;
}

a:hover {
    color: #59161C;
}

/* Logo */
.logo {
    font-weight: bold;
    margin-bottom: 20px;
    display: block;
    font-size: 4.5em;
}

.logo .part1 {
    background: linear-gradient(to right, #e2e2e2, #C1C1C1);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    display: inline-block;
}

.logo .part2 {
    color: #59161C;
font-family: "Montserrat", sans-serif;
  font-optical-sizing: auto;
  font-style: normal;
font-weight: 400; 
    display: inline-block;
}

/* Subtítulo */
.subtitle {
    font-size: 1.6em;
    color: #424242;
    margin-top: 0;
    margin-bottom: 0;
}

/* Sección de Servicios - Diseño lado a lado */
.services-container {
    display: flex;
    justify-content: space-between;
    gap: 30px;
    flex-wrap: wrap;
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
}

.services-section {
    flex: 1;
    min-width: 280px;
    background-color: #FFFFFF;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.services-section.visible {
    opacity: 1;
    transform: translateY(0);
}

.services-section ul {
    list-style: none;
    padding: 0;
}

.services-section li {
    margin-bottom: 10px;
    font-size: 1.1em;
    padding-left: 20px;
    position: relative;
}

.services-section li::before {
    content: '\2022';
    color: #59161C;
    font-weight: bold;
    display: inline-block;
    width: 1em;
    margin-left: -1em;
    position: absolute;
    left: 0;
}

/* ... (estilos anteriores) ... */

/* Sección de Galería */
/* ... (estilos anteriores) ... */

/* Sección de Galería */
.gallery-section {
    text-align: center;
    background-color: #FFFFFF;
    padding: 50px 0;
}

.gallery-section .container {
    padding: 0 20px; /* Asegura padding lateral dentro del container */
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 25px;
    margin-top: 30px;
    width: 100%;
    max-width: 1200px;
    margin: 30px auto 0 auto;
    padding: 0 20px; /* Importante para que los items no toquen los bordes de la pantalla */
}

.gallery-item {
    background-color: #FFFFFF;
    border-radius: 8px;
    overflow: hidden; /* Clave para que el contenido no se salga */
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    cursor: pointer;
    display: flex;
    flex-direction: column; /* Apila imagen y texto verticalmente */
    justify-content: flex-start; /* Alinea al inicio verticalmente */
    align-items: center;
    text-align: center;
    position: relative;
}

.gallery-item img {
    width: 100%;
    height: 250px; /* Altura fija, pero object-fit: cover ayuda */
    object-fit: cover;
    display: block;
    filter: brightness(100%);
    transition: filter 0.3s ease;
}

.gallery-item:hover img {
    filter: brightness(95%);
}

.gallery-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2);
}

/* Estilos para el texto del proyecto dentro de la galería */
.gallery-item-text {
    padding: 15px; /* Espaciado interno */
    font-size: 1.1em;
    color: #020202;
    width: 100%; /* Asegura que ocupe el ancho completo del div */
    box-sizing: border-box; /* Incluye el padding en el ancho */
    word-wrap: break-word; /* Permite que las palabras largas se rompan */
    overflow-wrap: break-word; /* Otra propiedad para asegurar el quiebre de palabras */
    text-overflow: ellipsis; /* Opcional: si quieres truncar texto muy largo */
    /* white-space: nowrap; // Descomenta esto si quieres truncar el texto y usar ellipsis */
    /* overflow: hidden; */
}

/* Media Queries para responsividad de la galería */
@media (max-width: 768px) {
    .gallery-grid {
        grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
        gap: 15px;
        padding: 0 15px;
    }
    .gallery-item img {
        height: 200px;
    }
    .gallery-item-text {
        font-size: 1em;
        padding: 10px;
    }
}

@media (max-width: 480px) {
    .gallery-grid {
        grid-template-columns: 1fr;
        gap: 10px;
    }
    .gallery-item img {
        height: 180px;
    }
    .gallery-item-text {
        font-size: 0.95em; /* Un poco más pequeño si es necesario */
        padding: 10px;
    }
}
/* Sección de Contacto */
.contact-section {
    text-align: center;
}

.contact-info {
    margin-top: 30px;
    font-size: 1.2em;
}

.contact-info p {
    margin-bottom: 15px;
}

.contact-info a {
    font-weight: bold;
}

/* Sección de Ubicación */
.location-section {
    text-align: center;
    background-color: #FFFFFF;
    padding: 50px 20px;
}

.location-address {
    margin-top: 30px;
    font-size: 1.2em;
    line-height: 1.6;
    color: #424242;
    margin-bottom: 30px;
}

.map-container {
    margin-top: 0;
    display: flex;
    justify-content: center;
    width: 100%;
    max-width: 900px;
    margin: 0 auto;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.map-container iframe {
    width: 100%;
    height: 450px;
    border: none;
    border-radius: 8px;
}

/* Animación de scroll */
.fade-in-on-scroll {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.fade-in-on-scroll.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Media Queries para Responsive Design */
@media (max-width: 1024px) {
    .logo {
        font-size: 4em;
    }
    .subtitle {
        font-size: 1.3em;
    }
    h2 {
        font-size: 2.4em;
    }
    h3 {
        font-size: 1.8em;
    }
}

@media (max-width: 768px) {
    .hero-section {
        height: 70vh;
    }
    .logo {
        font-size: 3.5em;
    }
    .logo .part1, .logo .part2 {
        font-size: 1em;
    }
    .subtitle {
        font-size: 1.1em;
    }
    h2 {
        font-size: 2em;
    }
    .services-container {
        flex-direction: column;
        gap: 0;
    }
    .services-section {
        margin-bottom: 30px;
        min-width: 100%;
    }
    .gallery-grid {
        grid-template-columns: 1fr;
    }
    .location-address {
        font-size: 1em;
    }
    .map-container {
        max-width: 100%;
    }
    .map-container iframe {
        height: 350px;
    }
}

@media (max-width: 480px) {
    .logo {
        font-size: 2.8em;
    }
    .subtitle {
        font-size: 1em;
    }
    h2 {
        font-size: 2em;
    }
    .services-section li {
        font-size: 1em;
    }
}