/* --- ESTILOS GENERALES Y RESET --- */
:root {
    --color-primario: #0d47a1; /* Azul oscuro profesional */
    --color-secundario: #ffc107; /* Amarillo para acentos */
    --color-fondo: #f4f7f6;
    --color-texto: #000000;
    --color-blanco: #ffffff;
    --fuente-titulos: 'Teko', sans-serif;
    --fuente-texto: 'Roboto', sans-serif;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    scroll-behavior: smooth;
}

body {
    font-family: var(--fuente-texto);
    color: var(--color-texto);
    background-color: var(--color-blanco);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

section {
    padding: 80px 0;
}

h1, h2, h3 {
    font-family: var(--fuente-titulos);
    font-weight: 500;
    letter-spacing: 1px;
}

h2 {
    font-size: 3rem;
    text-align: center;
    margin-bottom: 60px;
    color: var(--color-primario);
}

/* --- BARRA DE CONTACTO SUPERIOR --- */
.top-bar {
    background-color: #333;
    color: var(--color-blanco);
    padding: 8px 0;
    font-size: 0.9rem;
}
.top-bar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.top-bar a {
    color: var(--color-blanco);
    text-decoration: none;
    margin-left: 20px;
}
.top-bar a:hover {
    color: var(--color-secundario);
}

/* --- HEADER Y NAVEGACIÓN --- */
header {
    background-color: #ffffff; /* --- var(--color-blanco);--- */ 
    padding: 15px 0;
    border-bottom: 1px solid #eee;
    position: sticky;
    top: 0;
    z-index: 1000;
    transition: box-shadow 0.3s ease;
}
header.scrolled {
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}
header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.logo {
    width: 95px;
    height: auto;
}
.main-nav ul {
    list-style: none;
    display: flex;
}
.main-nav ul li {
    margin-left: 30px;
}
.main-nav ul li a {
    text-decoration: none;
    color: var(--color-texto);
    font-weight: 700;
    padding-bottom: 5px;
    border-bottom: 2px solid transparent;
    transition: all 0.3s ease;
}
.main-nav ul li a:hover {
    color: var(--color-primario);
    border-bottom: 2px solid var(--color-primario);
}
.cta-button {
    background-color: #233849;
    color: #ffffff !important;
    padding: 10px 20px;
    border-radius: 5px;
    font-weight: 700;
    border-bottom: none !important;
}
.cta-button:hover {
    background-color: #346886;
    color: #33333348 !important;
}

/* --- MENÚ MÓVIL (HAMBURGUESA) --- */
.hamburger-menu {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    flex-direction: column;
    gap: 5px;
}
.hamburger-menu span {
    display: block;
    width: 25px;
    height: 3px;
    background-color: var(--color-primario);
    transition: all 0.3s ease;
}

/* --- SECCIÓN HERO (CON CARRUSEL) --- */
.hero {
    position: relative; /* Esencial para posicionar el carrusel y el texto */
    overflow: hidden; /* Oculta partes de las imágenes que se salen */
    height: 600px; /* Ajusta la altura deseada del carrusel */
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: var(--color-blanco);
}

.hero-carousel {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    transition: transform 0.8s ease-in-out; /* Transición suave entre slides */
}

.carousel-slide {
    min-width: 100%; /* Cada slide ocupa el 100% del ancho */
    height: 100%;
    position: relative;
}

.carousel-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover; /* Asegura que la imagen cubra todo el espacio sin distorsionarse */
    filter: brightness(0.7); /* Oscurece un poco la imagen para mejor legibilidad */
}

.overlay { /* Capa oscura adicional para legibilidad del texto */
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.450); /* Negro semi-transparente */
    z-index: 1; /* Asegura que esté por encima del carrusel pero debajo del texto */
}

.hero-content { /* Contenedor del texto y botones */
    position: relative; /* Importante para que esté encima del carrusel */
    z-index: 2; /* Asegura que el contenido esté por encima del overlay y el carrusel */
    padding: 120px 0; /* Padding para separar del tope y base */
    max-width: 700px; /* Limita el ancho del texto */
}
.hero-content h1 {
    font-size: 5rem;
    margin-bottom: 20px;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.5);
}
.hero-content p {
    font-size: 1.2rem;
    margin: 0 auto 40px;
}
.value-props {
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
}
.prop {
    background-color: rgba(255, 255, 255, 0.1);
    padding: 15px 25px;
    border-radius: 8px;
    border: 1px solid var(--color-secundario);
}
.prop h3 {
    font-family: var(--fuente-texto);
    font-size: 1.1rem;
    margin: 0;
}

/* --- MEJORA VISUAL: SERVICIOS CON FONDO PARALLAX --- */
#featured-services-carousel {
    /* Reemplaza 'URL_DE_TU_IMAGEN' con una imagen real, ej: image/fondo_tecnico.jpg */
    background-image: linear-gradient(rgba(255, 255, 255, 0.9), rgba(200, 211, 228, 0.938)), url('image/fondo_secc.jpg');
    /* El linear-gradient de arriba sirve como "velo" blanco para que la imagen sea muy sutil */
    
    background-attachment: fixed; /* ESTO CREA EL EFECTO PARALLAX */
    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
}


/* --- BARRA DE CONFIANZA --- */
.trust-bar {
    background-color: var(--color-fondo);
    padding: 25px 0;
    border-bottom: 1px solid #ddd;
}
.trust-bar .container {
    display: flex;
    justify-content: space-around;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
    text-align: center;
}
.trust-element {
    font-weight: 700;
    color: var(--color-primario);
    font-size: 1rem;
}
.trust-element span {
    font-size: 2rem;
    font-family: var(--fuente-titulos);
    color: var(--color-primario);
    display: block;
}

/* --- OTRAS SECCIONES (SERVICIOS, TESTIMONIOS, CONTACTO, FOOTER) --- */

#contacto {
    position: relative;
    color: var(--color-blanco);
    padding: 100px 0;
    /* Fondo Parallax Azul */
    background-image: 
        linear-gradient(rgba(255, 255, 255, 0.9), rgba(200, 211, 228, 0.938)),
        url('image/fondo_secc.jpg'); /* Asegúrate que esta imagen existe */
    background-attachment: fixed;
    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
}

/* --- CORRECCIÓN DE COLOR PARA TEXTOS DE CONTACTO --- */

#contacto .contact-info h3{
    color: #0d47a1 !important; /* Tu azul corporativo brillante */
    font-weight: 700;
}
/* Esto afecta solo a los párrafos dentro de la información de contacto */
#contacto .contact-info p {
    color: #0a2e5c !important; /* Azul marino oscuro para buen contraste */
    font-weight: 500; /* Un poco más grueso para que se lea mejor */
}

/* Si quieres que las etiquetas "Teléfono:", "Email:", etc. resalten más */
#contacto .contact-info strong {
    color: #0d47a1 !important; /* Tu azul corporativo brillante */
    font-weight: 700;
}

/* --- ESTILOS PARA LA SECCIÓN DE SERVICIOS DESTACADOS (Carrusel) --- */
#featured-services-carousel {
    background-color: #f8f9fa;
    padding: 80px 0;
    text-align: center;
}

.section-title {
    font-size: 2.8rem;
    color: var(--color-primario);
    margin-bottom: 10px;
    font-weight: 700;
}

.section-subtitle {
    font-size: 1.3rem;
    color: #555;
    margin-bottom: 50px;
}

.dynamic-carousel-wrapper {
    position: relative;
    max-width: 1200px;
    margin: 0 auto;
    overflow: hidden;
    padding: 20px 0;
}

.dynamic-service-carousel {
    display: flex;
    transition: transform 0.5s ease-in-out;
}

.service-card-link {
    text-decoration: none;
    color: inherit;
    display: block;
    /* 3 cards por vista, con 20px de espacio */
    min-width: calc(100% / 3 - 20px); 
    margin: 0 10px;
    flex-shrink: 0;
}

.service-card-dynamic {
    background-color: var(--color-blanco);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.service-card-dynamic:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
}

.service-card-image {
    width: 100%;
    height: 180px;
    background-size: cover;
    background-position: center;
}

.service-card-content {
    padding: 25px;
    text-align: left;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.service-card-content h3 {
    font-size: 1.5rem;
    color: var(--color-primario);
    margin-bottom: 10px;
    font-weight: 600;
}

.service-card-content p {
    font-size: 1rem;
    color: #666;
    line-height: 1.6;
    margin-bottom: 15px;
    flex-grow: 1;
}

.read-more {
    color: var(--color-secundario);
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-top: auto;
}

.read-more i {
    transition: transform 0.3s ease;
}

.service-card-dynamic:hover .read-more i {
    transform: translateX(5px);
}

/* Botones de navegación del carrusel */
.carousel-control-prev,
.carousel-control-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: rgba(0, 0, 0, 0.5);
    color: var(--color-blanco);
    border: none;
    border-radius: 50%;
    width: 45px;
    height: 45px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 1.5rem;
    z-index: 10;
    transition: background-color 0.3s ease;
}

.carousel-control-prev:hover,
.carousel-control-next:hover {
    background-color: var(--color-primario);
}

.carousel-control-prev { left: 10px; }
.carousel-control-next { right: 10px; }

/* Botón "Ver Todos" */
.btn-primary-lg {
    display: inline-block;
    background-color: var(--color-primario);
    color: var(--color-blanco);
    padding: 15px 30px;
    border-radius: 8px;
    text-decoration: none;
    font-size: 1.1rem;
    font-weight: 600;
    transition: background-color 0.3s ease;
    margin-top: 30px;
}
.btn-primary-lg:hover {
    background-color: var(--color-secundario);
}

/* --- Media Queries para esta sección --- */
@media (max-width: 992px) {
    .dynamic-service-carousel .service-card-link {
        min-width: calc(100% / 2 - 20px); /* 2 cards */
    }
}
@media (max-width: 768px) {
    .dynamic-service-carousel .service-card-link {
        min-width: calc(100% - 20px); /* 1 card */
    }
    .carousel-control-prev,
    .carousel-control-next {
        width: 35px;
        height: 35px;
        font-size: 1.2rem;
    }
}

/* --- ESTILOS PARA TESTIMONIALS (Opción 2: Muro Dinámico) --- */
#testimonios {
    background-color: var(--color-fondo);
}

.testimonial-wall {
    /* La magia del Masonry con CSS puro */
    column-count: 3; /* 3 columnas en escritorio */
    column-gap: 25px;
}

.testimonial-card {
    background-color: var(--color-blanco);
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    margin-bottom: 25px; /* Espacio entre tarjetas en la misma columna */
    /* Evita que una tarjeta se parta entre dos columnas */
    display: inline-block;
    width: 100%;
}

.testimonial-card p {
    font-style: italic;
}
.testimonial-author {
    margin-top: 20px;
    display: flex;
    align-items: center;
    gap: 15px;
}
.testimonial-author i {
    font-size: 2.5rem;
    color: #ccc;
}
.stars {
    color: var(--color-secundario);
    margin-bottom: 10px;
    font-size: 1.2rem;
}
.author-name {
    font-weight: 700;
}

/* Adaptación a tablets */
@media (max-width: 992px) {
    .testimonial-wall {
        column-count: 2; /* 2 columnas */
    }
}

/* Adaptación a móviles */
@media (max-width: 768px) {
    .testimonial-wall {
        column-count: 1; /* 1 columna */
    }
}

.contact-wrapper { display: grid; grid-template-columns: 1fr 1fr; gap: 50px; align-items: flex-start; }
.contact-form form { display: flex; flex-direction: column; gap: 20px; }
.contact-form input, .contact-form textarea { width: 100%; padding: 15px; border: 1px solid #ccc; border-radius: 5px; font-family: var(--fuente-texto); font-size: 1rem; }
.contact-form button { background-color: var(--color-primario); color: var(--color-blanco); padding: 15px; border: none; border-radius: 5px; font-size: 1.1rem; font-weight: 700; cursor: pointer; transition: background-color 0.3s ease; }
.contact-form button:hover { background-color: #0b3a82; }
.contact-info h3 { font-size: 2rem; margin-bottom: 20px; }
.contact-info p { margin-bottom: 15px; line-height: 1.6; }
.map-placeholder iframe { border-radius: 8px; }

/* ==============================================
   4. ESTILOS DEL NUEVO FOOTER PROFESIONAL
   ============================================== */

.site-footer {
    background-color: #1a2a3a; /* Un azul muy oscuro, más profesional que el negro puro */
    color: #adb5bd; /* Un gris claro para el texto */
    padding-top: 60px; /* Espacio superior antes de los widgets */
}

.footer-widgets {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); /* Columnas flexibles */
    gap: 40px; /* Espacio entre columnas */
    padding-bottom: 50px; /* Espacio antes de la barra de copyright */
    border-bottom: 1px solid #34495e; /* Línea separadora sutil */
}

.footer-widget {
    font-size: 0.95rem;
}

.footer-logo-img img {
    max-width: 120px; /* Ajusta el tamaño de tu logo */
    height: auto;
    margin-bottom: 20px;
}

.footer-description {
    line-height: 1.7;
}

.widget-title {
    font-family: var(--fuente-titulos);
    font-size: 1.5rem;
    color: var(--color-blanco);
    margin-bottom: 25px;
    position: relative;
    padding-bottom: 10px;
}
/* Línea decorativa debajo de los títulos */
.widget-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 40px;
    height: 3px;
    background-color: var(--color-secundario); /* Amarillo */
}

.footer-links,
.footer-contact {
    list-style: none;
    padding: 0;
}

.footer-links li,
.footer-contact li {
    margin-bottom: 12px;
}

.footer-links a {
    color: #adb5bd;
    text-decoration: none;
    transition: color 0.3s ease, padding-left 0.3s ease;
}
.footer-links a:hover {
    color: var(--color-blanco);
    padding-left: 5px; /* Pequeño desplazamiento al hacer hover */
}

.footer-contact i {
    color: var(--color-secundario); /* Iconos en amarillo */
    margin-right: 12px;
    width: 20px; /* Asegura alineación */
    text-align: center;
}

.social-links-footer a {
    display: inline-flex; /* Para centrar el icono */
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background-color: #34495e; /* Fondo grisáceo oscuro */
    color: var(--color-blanco);
    border-radius: 50%;
    margin-right: 10px;
    text-decoration: none;
    font-size: 1.1rem;
    transition: background-color 0.3s ease, transform 0.3s ease;
}
.social-links-footer a:hover {
    background-color: var(--color-secundario); /* Amarillo al pasar el ratón */
    color: #1a2a3a; /* Color de fondo del footer para el icono */
    transform: translateY(-3px); /* Efecto de levitar */
}

/* Barra de Copyright */
.footer-bottom {
    padding: 20px 0;
    background-color: #111e2b; /* Un poco más oscuro que el fondo principal */
}
.footer-bottom .container {
    text-align: center;
}
.copyright {
    font-size: 0.9rem;
    color: #869ab8; /* Un gris azulado claro */
    margin: 0;
}

/* Responsive del Footer */
@media (max-width: 768px) {
    .footer-widgets {
        grid-template-columns: 1fr; /* Una columna en móvil */
        text-align: center; /* Centrar contenido en móvil */
    }
    .widget-title::after {
        left: 50%; /* Centrar la línea decorativa */
        transform: translateX(-50%);
    }
    .footer-contact li {
        display: flex; /* Mejor alineación en móvil */
        align-items: center;
        justify-content: center;
        text-align: left; /* Alinea el texto a la izquierda del icono */
    }
    .footer-contact i {
        margin-right: 10px;
    }
}


/* --- RESPONSIVE DESIGN --- */
@media (max-width: 850px) {
    h2 { font-size: 2.5rem; }
    .hero h1 { font-size: 3rem; }
    .contact-wrapper { grid-template-columns: 1fr; }
    
    .hamburger-menu { display: flex; }
    .main-nav {
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background-color: var(--color-blanco);
        flex-direction: column;
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.5s ease-out;
    }
    .main-nav.active {
        max-height: 300px; /* Suficiente para 4-5 items */
        border-bottom: 1px solid #eee;
    }
    .main-nav ul {
        flex-direction: column;
        padding: 20px;
        align-items: center;
    }
    .main-nav ul li {
        margin: 10px 0;
    }
    .top-bar .contact-details span { display: none; }
    
}

/* --- ESTILOS ADICIONALES PARA PÁGINA "QUIÉNES SOMOS" --- */

/* Título principal de la página */
.page-title {
    margin-top: 40px;
    font-size: 4rem;
    text-align: center;
}
.page-section {
    padding-top: 60px;
}

/* --- SECCIÓN 1: NOSOTROS --- */
#nosotros {
    background-color: var(--color-blanco);
}
.nosotros-wrapper {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    align-items: center;
}
.nosotros-texto h3 {
    font-size: 2rem;
    color: var(--color-primario);
    margin-bottom: 20px;
}
.nosotros-texto p {
    line-height: 1.7;
    margin-bottom: 20px;
}
.nosotros-imagen-cert img {
    width: 100%;
    border-radius: 8px;
    margin-bottom: 20px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.1);
}
.certificaciones {
    text-align: center;
}
.certificaciones h4 {
    margin-bottom: 15px;
    color: var(--color-texto);
}
.certificaciones img {
    width: auto;
    height: 55px;
    margin: 0 10px;
    filter: grayscale(100%);
    opacity: 0.7;
    transition: all 0.3s ease;
}
.certificaciones img:hover {
    filter: grayscale(0%);
    opacity: 1;
}

/* --- SECCIÓN 2: FILOSOFÍA --- */
#filosofia {
    background-color: var(--color-fondo);
}
.filosofia-wrapper {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    align-items: flex-start;
}
.filosofia-pilares {
    display: flex;
    flex-direction: column;
    gap: 30px;
}
.card {
    background-color: var(--color-blanco);
    padding: 40px;
    border-radius: 12px;
    box-shadow: 0 5px 25px rgba(0,0,0,0.07);
}
.filosofia-pilares .card {
    text-align: center;
}
.card i {
    font-size: 2.5rem;
    color: var(--color-primario);
    margin-bottom: 20px;
}
.card h3 {
    font-size: 2.2rem;
    margin-bottom: 15px;
    color: var(--color-primario);
}
.filosofia-valores ul {
    list-style: none;
}
.filosofia-valores li {
    display: flex;
    align-items: flex-start;
    gap: 20px;
    margin-bottom: 25px;
}
.filosofia-valores li i {
    margin-bottom: 0;
    font-size: 1.5rem;
    margin-top: 5px;
}
.filosofia-valores h4 {
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 5px;
}

/* --- SECCIÓN 3: ¿POR QUÉ ELEGIRNOS? --- */
#porque-elegirnos {
    background-color: #1a2a3a;
    background-image: linear-gradient(rgba(26, 42, 58, 0.9), rgba(26, 42, 58, 0.9)), url('https://via.placeholder.com/1920x1080.png?text=Fondo+Tenue');
    background-size: cover;
    background-position: center;
    background-attachment: fixed; /* Efecto Parallax */
}
#porque-elegirnos h2 {
    color: var(--color-blanco);
}
.porque-elegirnos-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}
.feature-card {
    background-color: rgba(255, 255, 255, 0.95);
    padding: 30px;
    border-radius: 12px;
    text-align: center;
    transition: all 0.3s ease;
}
.feature-card:hover {
    transform: translateY(-10px);
    background-color: var(--color-blanco);
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
}
.feature-card i {
    font-size: 2rem;
    color: var(--color-primario);
    margin-bottom: 20px;
}
.feature-card h4 {
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 10px;
}

/* --- RESPONSIVE PARA LAS NUEVAS SECCIONES --- */
@media (max-width: 992px) {
    .porque-elegirnos-grid {
        grid-template-columns: repeat(2, 1fr); /* 2 columnas en tablets */
    }
}
@media (max-width: 768px) {
    .page-title { font-size: 3rem; }
    .nosotros-wrapper, .filosofia-wrapper {
        grid-template-columns: 1fr; /* 1 columna en móviles */
    }
    .porque-elegirnos-grid {
        grid-template-columns: 1fr; /* 1 columna en móviles */
    }
}

/* --- ANIMACIÓN DE SCROLL --- */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}
.animate-on-scroll.visible {
    opacity: 1;
    transform: translateY(0);
}

/* --- ESTILOS PARA PÁGINA DE SERVICIOS --- */

.page-header {
    background-color: var(--color-primario);
    color: var(--color-blanco);
    padding: 40px 0 60px 0;
    text-align: center;
    position: relative;
}
.page-header::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 0;
    border-left: 50vw solid transparent;
    border-right: 50vw solid transparent;
    border-bottom: 50px solid var(--color-blanco);
}
.page-header h1 {
    font-size: 4rem;
    font-family: var(--fuente-titulos);
}

#nuestros-servicios {
    padding-top: 60px;
}
.servicios-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 25px;
}
.servicio-card {
    position: relative;
    height: 250px;
    border-radius: 12px;
    overflow: hidden;
    cursor: pointer;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
}
.servicio-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 25px rgba(0,0,0,0.2);
}
.servicio-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}
.servicio-card:hover img {
    transform: scale(1.1);
}
.servicio-card::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to top, rgba(0,0,0,0.8), transparent 50%);
}
.servicio-card h3 {
    position: absolute;
    bottom: 20px;
    left: 20px;
    right: 20px;
    z-index: 2;
    color: var(--color-blanco);
    font-size: 1.5rem;
    font-family: var(--fuente-titulos);
}

/* --- ESTILOS PARA LA VENTANA EMERGENTE (MODAL) --- */
.hidden {
    display: none !important;
}
#modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    z-index: 2000;
    display: flex;
    justify-content: center;
    align-items: center;
    animation: fadeIn 0.3s ease;
}
#modal-container {
    background-color: var(--color-blanco);
    padding: 30px;
    border-radius: 12px;
    width: 90%;
    max-width: 700px;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    animation: slideUp 0.4s ease;
}
#modal-close-btn {
    position: absolute;
    top: 15px;
    right: 15px;
    background: none;
    border: none;
    font-size: 2rem;
    color: #888;
    cursor: pointer;
    line-height: 1;
}
#modal-image {
    width: 100%;
    height: 300px;
    object-fit: cover;
    border-radius: 8px;
    margin-bottom: 20px;
}
#modal-title {
    font-size: 2.5rem;
    color: var(--color-primario);
    margin-bottom: 15px;
}
#modal-description {
    line-height: 1.7;
    color: #555;
}

/* Animaciones para el Modal */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}
@keyframes slideUp {
    from { transform: translateY(50px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

/* --- ESTILOS PARA EL CARRUSEL DENTRO DEL MODAL --- */

.modal-carousel-wrapper {
    position: relative;
    width: 100%;
    height: 300px; /* Altura fija para las imágenes del carrusel */
    overflow: hidden; /* Oculta las imágenes que no están en vista */
    border-radius: 8px;
    margin-bottom: 20px;
}

.carousel-content {
    display: flex; /* Para que las imágenes se alineen horizontalmente */
    width: 100%;
    height: 100%;
    transition: transform 0.5s ease-in-out; /* Suaviza la transición entre imágenes */
}

.carousel-content img {
    min-width: 100%; /* Cada imagen ocupa el 100% del ancho del contenedor */
    height: 100%;
    object-fit: cover; /* Asegura que las imágenes cubran el espacio sin distorsionarse */
    border-radius: 8px;
}

.carousel-nav {
    position: absolute;
    bottom: 10px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    align-items: center;
    gap: 10px;
    background-color: rgba(0, 0, 0, 0.5);
    padding: 8px 15px;
    border-radius: 20px;
    z-index: 10;
}

.carousel-nav button {
    background-color: transparent;
    border: none;
    color: var(--color-blanco);
    font-size: 1.5rem;
    cursor: pointer;
    padding: 5px 10px;
    border-radius: 50%;
    transition: background-color 0.3s ease;
}
.carousel-nav button:hover {
    background-color: rgba(255, 255, 255, 0.2);
}

.dots-container {
    display: flex;
    gap: 8px;
}

.dot {
    width: 10px;
    height: 10px;
    background-color: rgba(255, 255, 255, 0.5);
    border-radius: 50%;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.2s ease;
}
.dot.active {
    background-color: var(--color-secundario); /* Color de tu marca para el punto activo */
    transform: scale(1.2);
}

/* Ajustes para el modal en móvil */
@media (max-width: 768px) {
    #modal-container {
        padding: 20px;
    }
    .modal-carousel-wrapper {
        height: 200px; /* Menor altura en móviles */
    }
    .carousel-nav {
        bottom: 5px;
        padding: 5px 10px;
    }
    .carousel-nav button {
        font-size: 1.2rem;
    }
    .dot {
        width: 8px;
        height: 8px;
    }
}

/* --- PÁGINA DE SERVICIOS (Con fondo Parallax) --- */
#nuestros-servicios {
    padding-top: 60px;
    padding-bottom: 80px; /* Añadimos padding inferior */

    /* --- INICIO DE LA MEJORA --- */

    /* 1. La imagen de fondo */
    /* REEMPLAZA 'image/canal_1.jpg' por la imagen que elijas */
    background-image: 
        /* Capa 1: Un "velo" de color blanco semi-transparente para que la imagen sea sutil y el texto se lea bien */
        linear-gradient(rgba(255, 255, 255, 0.9), rgba(200, 211, 228, 0.938)),
        
        /* Capa 2: Tu imagen de fondo */
        url('image/fondo_secc.jpg'); 

    /* 2. El efecto Parallax */
    background-attachment: fixed;
    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;
    
    /* --- FIN DE LA MEJORA --- */
}

/* --- PÁGINA DE NOSOTROS (Con fondo Parallax) --- */
#nosotros {
    padding-top: 60px;
    padding-bottom: 80px; /* Añadimos padding inferior */

    /* --- INICIO DE LA MEJORA --- */

    /* 1. La imagen de fondo */
    /* REEMPLAZA 'image/canal_1.jpg' por la imagen que elijas */
    background-image: 
        /* Capa 1: Un "velo" de color blanco semi-transparente para que la imagen sea sutil y el texto se lea bien */
        linear-gradient(rgba(255, 255, 255, 0.9), rgba(200, 211, 228, 0.938)),
        
        /* Capa 2: Tu imagen de fondo */
        url('image/fondo_secc.jpg'); 

    /* 2. El efecto Parallax */
    background-attachment: fixed;
    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;
    
    /* --- FIN DE LA MEJORA --- */
}

