/* --- 1. Fuentes --- */
@font-face {
  font-family: 'Roboto';
  font-style: normal;
  font-weight: 400;
  font-stretch: normal;
  src: url(s/roboto/v49/KFOMCnqEu92Fr1ME7kSn66aGLdTylUAMQXC89YmC2DPNWubEbVmUiA8.ttf) format('truetype');
}

/* --- 2. Bloque de ocultar elementos --- */
#olark-wrapper .olark-launch-button { display: none !important; }
img:is([sizes="auto" i], [sizes^="auto," i]) { contain-intrinsic-size: 3000px 1500px; }

/* ... resto de tu código ... */
/* --- 3. TODO el código que consolidamos antes --- */
.floating-buttons { ... }
#pg-409-10 { ... }
/* ... (aquí el resto de tu CSS) ... */

    /* --- BOTONES FLOTANTES (Mantenidos) --- */
    .floating-buttons { position: fixed; z-index: 1000; font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif; }
    .whatsapp-button { position: fixed; bottom: 25px; right: 25px; width: 60px; height: 60px; background: #25D366; border-radius: 50%; display: flex; align-items: center; justify-content: center; box-shadow: 0 4px 20px rgba(37, 211, 102, 0.4); transition: all 0.3s ease; text-decoration: none; z-index: 1001; }
    .whatsapp-button:hover { transform: scale(1.1); box-shadow: 0 6px 25px rgba(37, 211, 102, 0.6); background: #20bd5a; }
    .whatsapp-button i { color: white; font-size: 32px; }
    .call-button { position: fixed; bottom: 25px; left: 25px; width: 60px; height: 60px; background: #8B4513; border-radius: 50%; display: none; align-items: center; justify-content: center; box-shadow: 0 4px 20px rgba(139, 69, 19, 0.4); transition: all 0.3s ease; text-decoration: none; z-index: 1001; }
    .call-button:hover { transform: scale(1.1); box-shadow: 0 6px 25px rgba(139, 69, 19, 0.6); background: #654321; }
    .call-button i { color: white; font-size: 24px; }
    @keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(37, 211, 102, 0.7); } 70% { box-shadow: 0 0 0 15px rgba(37, 211, 102, 0); } 100% { box-shadow: 0 0 0 0 rgba(37, 211, 102, 0); } }
    .whatsapp-button { animation: pulse 2s infinite; }
    .call-button { animation: pulse 2s infinite 1s; }
    @media (max-width: 768px) { .call-button { display: flex; } .whatsapp-button { bottom: 25px; right: 25px; } .call-button { bottom: 25px; left: 25px; } }
    @media (max-width: 480px) { .whatsapp-button, .call-button { width: 55px; height: 55px; bottom: 20px; } .whatsapp-button { right: 20px; } .call-button { left: 20px; } }

    /* --- SERVICIOS (Limpio y Centrado) --- */
    .services-section { padding: 60px 20px; max-width: 1200px; margin: 0 auto; }
    .services-header { text-align: center; margin-bottom: 50px; }
    
    .services-grid {
        display: flex;
        flex-wrap: wrap;
        justify-content: center;
        gap: 30px;
    }

    .service-card {
        background: #fff;
        padding: 25px;
        border-radius: 15px;
        box-shadow: 0 10px 30px rgba(0,0,0,0.08);
        transition: transform 0.4s ease, box-shadow 0.4s ease;
        text-align: center;
        /* Define ancho para que entren 3 por fila */
        flex: 0 0 calc(33.33% - 30px);
        min-width: 300px;
        display: flex;
        flex-direction: column;
    }

    .service-card:hover { transform: translateY(-10px); box-shadow: 0 20px 40px rgba(0,0,0,0.15); }
    .service-card img { width: 100%; height: 220px; object-fit: cover; border-radius: 10px; margin-bottom: 20px; }
    
    .cta-button { display: inline-block; margin-top: auto; padding: 12px 25px; background: #DAA177; color: white; border-radius: 25px; text-decoration: none; font-weight: 600; }
    .cta-button:hover { background: #c58d65; }

    /* Ajuste responsivo para que se vean bien en todo dispositivo */
    @media (max-width: 1024px) { .service-card { flex: 0 0 calc(50% - 30px); } }
    @media (max-width: 768px) { .service-card { flex: 0 0 100%; } }
.rc-anchor-content {
    display: none;
}
/* --- Bloque Reviews Minimalista y Centrado --- */
.testimonial {
    padding: 60px 20px;
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
}
.testimonial h2 { margin-bottom: 15px; }
.testimonial p { font-size: 16px !important; line-height: 1.6 !important; color: #666; margin-bottom: 20px; }

.btn-primary {
    display: inline-block;
    padding: 12px 30px;
    background-color: #DAA177;
    color: #fff;
    text-decoration: none;
    border-radius: 25px;
    font-weight: bold;
    transition: background 0.3s;
}
.btn-primary:hover { background-color: #c58d65; }

/* --- Bloque Gallery y Estructura Profesional --- */
#pg-409-11 {
    background-color: transparent;
    padding: 60px 0;
}

.panel-grid { display: flex; flex-wrap: wrap; gap: 30px; margin-bottom: 40px; }
.panel-grid-cell { flex: 1; min-width: 300px; }
.panel-grid-cell img { width: 100%; height: 250px; object-fit: cover; border-radius: 8px; display: block; margin-bottom: 15px; }
.textwidget h3 { margin-bottom: 10px; font-size: 20px; }
.textwidget p { font-size: 16px !important; line-height: 1.6 !important; color: #666; }

/* Carrusel profesional */
#projectCarousel .carousel-inner .item .row { margin-left: -5px; margin-right: -5px; display: flex; justify-content: center; }
#projectCarousel .carousel-inner .item .col-xs-3 { padding-left: 5px; padding-right: 5px; }
#projectCarousel .carousel-inner .item img { width: 100%; height: 180px; object-fit: cover; display: block; }

.project-item { position: relative; overflow: hidden; padding: 10px; }
.project-item .overlay {
    position: absolute; top: 0; left: 0; right: 0; bottom: 0;
    background-color: rgba(0, 0, 0, 0.5);
    display: flex; align-items: center; justify-content: center;
    opacity: 0; transition: opacity 0.3s ease;
}
.project-item:hover .overlay { opacity: 1; }
.overlay .view-project-btn { background-color: #f7b733; color: #333; padding: 10px 20px; font-weight: bold; text-decoration: none; }

/* Controles carrusel */
.carousel-controls-bottom { text-align: center; background-color: #444444; padding: 8px 0; }
.carousel-controls-bottom a { 
    display: inline-block; background-color: #2f2f2f; color: #999999; 
    font-size: 20px; font-weight: bold; padding: 2px 15px; margin: 0 5px; text-decoration: none; 
}
.carousel-controls-bottom a:hover { background-color: #1a1a1a; color: #fff; }

/* Responsividad mejorada */
@media (max-width: 991px) {
    #projectCarousel .carousel-inner .item { min-height: 0; }
    #projectCarousel .carousel-inner .item img { height: auto; }
}
@media (max-width: 767px) {
    .project-item { margin-bottom: 15px; width: 100%; }
}
.olark-launch-button-wrapper .olark-text-button {
    display: none !important;
    visibility: hidden !important;
}
/* --- Corrección Responsive para Layout y Títulos --- */
@media (max-width: 768px) {
    /* Si estos elementos están dentro de un contenedor padre común, 
       forzamos a que ocupen todo el ancho y se apilen */
    .panel-layout, 
    .widget-title {
        display: block !important;
        width: 100% !important;
        float: none !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
        margin-bottom: 20px !important; /* Espacio entre ellos al apilarse */
    }
}
/* --- CORRECCIÓN DEFINITIVA PARA COLUMNAS EN MÓVIL --- */
@media (max-width: 768px) {
    .panel-grid-cell {
        display: block !important;
        width: 100% !important;
        float: none !important;
        margin-bottom: 20px !important;
    }

    /* Forzamos a que los elementos hijos se apilen */
    .panel-grid-cell .panel-layout, 
    .panel-grid-cell .widget-title {
        display: block !important;
        width: 100% !important;
        margin-bottom: 10px !important;
    }
}
/* --- CORRECCIÓN FORZADA PARA SITEORIGIN EN MÓVILES --- */
@media (max-width: 767px) {
    /* Forzamos a que las celdas dejen de ser columnas y sean bloques */
    .panel-grid .panel-grid-cell {
        display: block !important;
        width: 100% !important;
        float: none !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
        padding-left: 0 !important;
        padding-right: 0 !important;
    }

    /* Si hay filas (panel-grid) que tienen flexbox, las anulamos */
    .panel-grid {
        display: block !important;
    }
}
/* --- CORRECCIÓN FORZADA PARA EL FORMULARIO EN MÓVIL --- */
@media (max-width: 767px) {
    /* Seleccionamos la columna del formulario específicamente */
    .wpcf7-form .row .col-xs-12.w-p1.col-sm-12 {
        display: block !important;
        width: 100% !important;
        flex: 0 0 100% !important;
        max-width: 100% !important;
        float: none !important;
        padding-left: 0 !important;
        padding-right: 0 !important;
    }

    /* Aseguramos que los inputs también se estiren al 100% */
    .wpcf7-form-control-wrap,
    .wpcf7-text,
    .wpcf7-textarea {
        display: block !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }
}
/* --- CORRECCIÓN AGRESIVA PARA EL FORMULARIO EN PGC-409-17-1 --- */
@media (max-width: 767px) {
    /* 1. Forzamos al contenedor padre de la columna del formulario */
    #pgc-409-17-1 {
        display: block !important;
        width: 100% !important;
        max-width: 100% !important;
        flex: 1 1 100% !important;
        padding-left: 0 !important;
        padding-right: 0 !important;
    }

    /* 2. Reseteamos el comportamiento de la fila (el padre de la celda) */
    .panel-row-style-for-409-17 {
        display: block !important;
        width: 100% !important;
    }

    /* 3. Aseguramos que el contenido del formulario ocupe el ancho total */
    #pgc-409-17-1 .wpcf7-form {
        width: 100% !important;
        margin: 0 !important;
    }

    /* 4. Estiramos los inputs dentro de esa celda específica */
    #pgc-409-17-1 .wpcf7-form-control {
        width: 100% !important;
        box-sizing: border-box !important;
    }
}
/* --- Corrección de imagen larga (Panel 409-16) --- */
#panel-409-16-0-0 img {
    width: 100% !important;        /* Ocupa el ancho disponible */
    height: 400px !important;      /* Altura fija para escritorio (ajústalo a tu gusto) */
    object-fit: cover;             /* Recorta la imagen para que rellene el espacio sin deformarse */
    object-position: center;       /* Asegura que lo más importante se vea centrado */
    display: block;
}

/* En móvil, reducimos la altura para que no ocupe tanto espacio */
@media (max-width: 767px) {
    #panel-409-16-0-0 img {
        height: 250px !important;  /* Menos altura en pantallas pequeñas */
    }
}
/* --- Corrección para el Slider (Jumbotron) --- */
.js-jumbotron-slider .item {
    height: 600px; /* Altura fija para escritorio */
    overflow: hidden;
}

.js-jumbotron-slider .item img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover;       /* Recorta la imagen para que rellene el espacio */
    object-position: center; /* Mantiene el centro de la imagen visible */
}

/* Responsividad: Ajuste para móviles */
@media (max-width: 767px) {
    .js-jumbotron-slider .item {
        height: 350px; /* Más corto en móviles para que no estorbe */
    }
}
/* --- Diseño Vistoso para Reviews --- */
.testimonial {
    background: #ffffff;
    padding: 50px 30px;
    border-radius: 20px;
    box-shadow: 0 15px 35px rgba(0,0,0,0.1);
    max-width: 600px;
    margin: 40px auto;
    border: 1px solid #f0f0f0;
    transition: transform 0.3s ease;
}

.testimonial:hover {
    transform: translateY(-5px);
}

.testimonial h2 {
    color: #333;
    font-size: 28px;
    margin-bottom: 10px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Estilo del botón con logo de Google */
.google-reviews-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #4285F4;
    color: #fff !important;
    padding: 15px 30px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: bold;
    font-size: 16px;
    transition: all 0.3s;
}

.google-reviews-btn:hover {
    background: #357ae8;
    box-shadow: 0 5px 15px rgba(66, 133, 244, 0.4);
}

.google-icon {
    background: #fff;
    padding: 5px;
    border-radius: 50%;
    margin-right: 10px;
    width: 20px;
    height: 20px;
}
/* --- Centrado Forzado de Reviews --- */
#panel-409-10-0-1 {
    display: flex !important;
    justify-content: center !important;
    width: 100% !important;
}

.testimonial {
    margin: 40px auto !important; /* El auto asegura centrado horizontal */
    float: none !important;
    width: 90% !important;        /* Ocupa casi todo el ancho pero centrado */
    max-width: 600px !important;  /* No deja que sea infinito */
}
/* --- Eliminación de Espacios Excesivos --- */
.panel-grid, 
.panel-row-style, 
.panel-grid-cell,
.so-panel {
    margin-bottom: 0 !important;
    padding-bottom: 0 !important;
}

/* Ajuste específico para separar un poco los bloques, pero no tanto */
.panel-grid {
    margin-bottom: 30px !important;
}

/* Si tu carrusel tiene una clase propia que añade espacio */
#projectCarousel {
    margin-bottom: 20px !important;
}
/* --- Mejora de carga y visualización de imágenes de servicios --- */
.service-card img {
    /* Evita que se corten "a medias" manteniendo el área de la foto llena */
    object-fit: cover !important; 
    object-position: center !important;
    
    /* Optimización de carga rápida */
    content-visibility: auto;
    aspect-ratio: 4 / 3; /* Reserva el espacio antes de cargar para evitar saltos */
}

/* Forzar que las imágenes de la galería también carguen completas */
.panel-grid-cell img, #projectCarousel .item img {
    object-fit: cover !important;
    object-position: center !important;
}
