/* ======================================================= */
        /* IMPORTACIÓN Y CONFIGURACIÓN DE MONTSERRAT */
        /* ======================================================= */
        @import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@300;400;500;600;700;800&display=swap');

        /* ======================================================= */
        /* REINICIO Y ESTILOS BASE MEJORADOS */
        /* ======================================================= */
        :root {
            --color-primary: #540606;
            --color-secondary: #dda97cdd;
            --color-accent: #3498db;
            --color-light: #f5efef;
            --color-dark: #540606;
            --color-texto-claro: #f5efef;
            --color-secundario: #dda97cdd;
            --color-principal: #540606;
            --shadow: 0 4px 6px rgba(0, 0, 0, 0.2);
            --transition: all 0.3s ease;
            --transition-slow: all 0.6s ease;
            --container-padding: clamp(1rem, 5vw, 5%);
        }

        * {
            margin: 0;
            padding: 0;
            box-sizing: border-box;
        }

        html {
            scroll-behavior: smooth;
        }

        body {
            font-family: 'Montserrat', sans-serif;
            line-height: 1.6;
            color: #333;
            overflow-x: hidden;
            background: #ffffff;
            font-weight: 400;
            -webkit-font-smoothing: antialiased;
            -moz-osx-font-smoothing: grayscale;
        }

        /* Mejora de legibilidad para Montserrat */
        h1, h2, h3, h4, h5, h6 {
            font-weight: 700;
            letter-spacing: -0.02em;
            line-height: 1.2;
            color: #333;
        }
        
        h2 {
            color: #540606ea !important;
        }

        p {
            margin-bottom: 1.5rem;
            font-weight: 400;
            line-height: 1.7;
            color: #000000;
        }

        /* Contenedor general para control de anchos */
        .container {
            width: 100%;
            max-width: 1200px;
            margin: 0 auto;
            padding: 0 var(--container-padding);
        }

        /* ======================================================= */
        /* HEADER MEJORADO - MENÚ TOGGLE PROFESIONAL */
        /* ======================================================= */
        .header-principal {
            background-image: linear-gradient(to right, #5a0202, #8a0303);
            box-shadow: none;
            position: sticky;
            top: 0;
            left: 0;
            width: 100%;
            z-index: 1000;
            padding: 0.8rem var(--container-padding);
            display: flex;
            justify-content: space-between;
            align-items: center;
            transition: var(--transition);
            animation: none;
        }

        .header-principal.scrolled {
            padding: 0.5rem var(--container-padding);
            background-image: linear-gradient(to bottom, rgba(84, 6, 6, 0.95), rgba(84, 6, 6, 0.8));
            backdrop-filter: blur(10px);
        }

        .logo {
            display: flex;
            align-items: center;
        }

        .logo img {
            height: 50px;
            width: auto;
            transition: var(--transition);
            animation: pulse 2s infinite;
        }

        .header-principal.scrolled .logo img {
            height: 40px;
            animation: none;
        }

        /* Botón del menú hamburguesa MEJORADO */
        .menu-toggle {
            display: none;
            flex-direction: column;
            justify-content: space-between;
            width: 35px;
            height: 30px;
            background: transparent;
            border: none;
            cursor: pointer;
            padding: 0;
            z-index: 1001;
            position: relative;
        }

        .menu-toggle span {
            width: 100%;
            height: 4px;
            background-color: var(--color-light);
            border-radius: 5px;
            transition: all 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
            position: relative;
            transform-origin: center;
            box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
        }

        .menu-toggle.active span:nth-child(1) {
            transform: rotate(45deg) translate(8px, 8px);
            background-color: var(--color-secondary);
        }

        .menu-toggle.active span:nth-child(2) {
            opacity: 0;
            transform: translateX(-10px);
        }

        .menu-toggle.active span:nth-child(3) {
            transform: rotate(-45deg) translate(8px, -8px);
            background-color: var(--color-secondary);
        }

        /* Mostrar navegación normal en pantallas grandes */
        .barra-navegacion ul {
            display: flex;
            list-style: none;
            align-items: center;
            flex-wrap: wrap;
        }

        .barra-navegacion li {
            position: relative;
            margin: 0 0.8rem;
        }

        .barra-navegacion a {
            text-decoration: none;
            color: var(--color-light);
            font-weight: 500;
            padding: 0.5rem 0;
            position: relative;
            transition: var(--transition);
            font-family: 'Montserrat', sans-serif;
            white-space: nowrap;
        }

        .barra-navegacion a:after {
            content: '';
            position: absolute;
            width: 0;
            height: 2px;
            bottom: 0;
            left: 0;
            background-color: var(--color-secondary);
            transition: var(--transition);
        }

        .barra-navegacion a:hover:after {
            width: 100%;
        }

        .dropdown {
            position: relative;
        }

        .catalogo-dropdown {
            position: absolute;
            top: 100%;
            left: 0;
            background: rgba(84, 6, 6, 0.95);
            min-width: 200px;
            box-shadow: var(--shadow);
            opacity: 0;
            visibility: hidden;
            transform: translateY(10px);
            transition: var(--transition);
            z-index: 100;
            border-radius: 4px;
            padding: 0.5rem 0;
        }

        .catalogo-dropdown a {
            display: block;
            padding: 0.8rem 1.5rem;
            color: var(--color-light);
            transition: var(--transition);
            font-family: 'Montserrat', sans-serif;
            font-weight: 500;
        }

        .catalogo-dropdown a:hover {
            background: var(--color-primary);
            color: var(--color-secondary);
            padding-left: 2rem;
        }

        /* ======================================================= */
        /* WhatsApp flotante con animación */
        /* ======================================================= */
        .whatsapp-flotante {
            position: fixed;
            bottom: 25px;
            right: 25px;
            width: 60px;
            height: 60px;
            background: #25D366;
            border-radius: 50%;
            display: flex;
            justify-content: center;
            align-items: center;
            box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
            z-index: 999;
            transition: var(--transition);
            animation: bounce 2s infinite;
        }

        .whatsapp-flotante:hover {
            transform: scale(1.1);
            animation: none;
        }

        .whatsapp-flotante img {
            width: 35px;
            height: 35px;
        }

        
        /* ======================================================= */
        /* ESTILOS ADICIONALES PARA LA SECCIÓN PRINCIPAL DE MAQUINADO CNC */
        /* ======================================================= */
        .hero-cnc {
            position: relative;
            height: 80vh;
            min-height: 600px;
            display: flex;
            align-items: center;
            justify-content: center;
            overflow: hidden;
            background: #000;
            padding: 2rem;
        }

        .video-background {
            position: absolute;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            object-fit: cover;
            z-index: 1;
        }

        .tools-animation {
            position: absolute;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            z-index: 3;
            pointer-events: none;
        }

        .tool-icon {
            position: absolute;
            font-size: 2rem;
            color: var(--color-primary);
            opacity: 0.3;
            animation: float 6s ease-in-out infinite;
        }

        .tool-icon:nth-child(1) {
            top: 20%;
            left: 10%;
            animation-delay: 0s;
        }

        .tool-icon:nth-child(2) {
            top: 70%;
            left: 80%;
            animation-delay: 2s;
        }

        .tool-icon:nth-child(3) {
            top: 40%;
            left: 85%;
            animation-delay: 4s;
        }

        .tool-icon:nth-child(4) {
            top: 80%;
            left: 15%;
            animation-delay: 1s;
        }

        .cnc-content {
            position: relative;
            z-index: 4;
            text-align: center;
            max-width: 1000px;
            width: 100%;
            text-shadow: 0 2px 10px rgba(0, 0, 0, 0.7);
        }

        .cnc-main-title {
            font-size: clamp(2.5rem, 5vw, 4.5rem);
            font-weight: 800;
            margin-bottom: 2rem;
            color: #fff;
            text-transform: uppercase;
            letter-spacing: 3px;
            animation: fadeInUp 1s ease-out;
            color: var(--color-secondary);
        }

        .cnc-tags-container {
            display: flex;
            flex-wrap: wrap;
            justify-content: center;
            gap: 1.5rem;
            margin-bottom: 3rem;
            animation: fadeInUp 1s ease-out 0.3s both;
        }

        .cnc-tag {
            background: rgba(255, 255, 255, 0.9);
            border: 1px solid rgba(84, 6, 6, 0.5);
            color: #333;
            padding: 0.8rem 1.5rem;
            border-radius: 30px;
            font-weight: 600;
            letter-spacing: 1px;
            text-transform: uppercase;
            font-size: 0.9rem;
            transition: all 0.3s ease;
            cursor: default;
            position: relative;
            overflow: hidden;
            box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
        }

        .cnc-tag:hover {
            background: rgba(255, 255, 255, 1);
            transform: translateY(-3px);
            box-shadow: 0 6px 15px rgba(0, 0, 0, 0.4);
        }

        .cnc-cta {
            display: inline-block;
            background: var(--color-secondary);
            color: var(--color-primary);
            padding: 1rem 2.5rem;
            border-radius: 50px;
            font-weight: 700;
            text-transform: uppercase;
            letter-spacing: 2px;
            text-decoration: none;
            transition: all 0.4s ease;
            box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
            position: relative;
            overflow: hidden;
            animation: fadeInUp 1s ease-out 0.6s both;
        }

        .cnc-cta:hover {
            transform: translateY(-5px);
            box-shadow: 0 10px 25px rgba(0, 0, 0, 0.4);
            background: #e6b17e;
        }

        /* ======================================================= */
        /* SECCIÓN DE PROCESO DE TRABAJO */
        /* ======================================================= */
        .process-section {
            padding: 5rem var(--container-padding);
            background: #ffffff;
        }

        .process-container {
            max-width: 1200px;
            margin: 0 auto;
        }

        .section-title {
            text-align: center;
            margin-bottom: 3rem;
            color: #333;
            font-size: clamp(1.8rem, 4vw, 2.5rem);
            position: relative;
            padding-bottom: 1rem;
        }

        .section-title:after {
            content: '';
            position: absolute;
            bottom: 0;
            left: 50%;
            transform: translateX(-50%);
            width: 80px;
            height: 3px;
            background: var(--color-secondary);
        }

        .process-steps {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
            gap: 2rem;
            margin-top: 3rem;
        }

        .process-step {
            background: #f9f9f9;
            border-radius: 10px;
            padding: 2rem;
            text-align: center;
            transition: var(--transition);
            position: relative;
            overflow: hidden;
            border: 1px solid rgba(84, 6, 6, 0.1);
        }

        .process-step:hover {
            transform: translateY(-10px);
            box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
            border-color: rgba(84, 6, 6, 0.2);
        }

        .step-icon {
            font-size: 3rem;
            color: var(--color-secondary);
            margin-bottom: 1.5rem;
            display: inline-block;
            height: 80px;
            width: 80px;
            line-height: 80px;
            border-radius: 50%;
            background: rgba(84, 6, 6, 0.05);
            transition: var(--transition);
        }

        .process-step:hover .step-icon {
            transform: scale(1.1);
            background: rgba(84, 6, 6, 0.1);
        }

        .step-title {
            font-size: 1.4rem;
            margin-bottom: 1rem;
            color: #333;
        }

        .step-description {
            color: #666;
            line-height: 1.6;
        }

        /* ======================================================= */
/* ESTILOS PARA LA SECCIÓN DE SERVICIOS */
/* ======================================================= */
.servicios-section {
    padding: 5rem var(--container-padding);
    background: #ffffff;
    position: relative;
    overflow: hidden;
}

.servicios-container {
    max-width: 1200px;
    margin: 0 auto;
    position: relative;
    z-index: 2;
}

.servicios-titulo {
    text-align: center;
    margin-bottom: 3rem;
    color: #333;
    font-size: clamp(1.8rem, 4vw, 2.5rem);
    position: relative;
    padding-bottom: 1rem;
}

.servicios-titulo:after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 3px;
    background: var(--color-secondary);
}

.servicios-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

/* Estilo para la primera tarjeta (alargada y centrada) */
.servicios-grid .servicio-card:first-child {
    grid-column: 1 / span 3; /* Ocupa las 3 columnas */
    display: flex;
    justify-content: center;
}

.servicio-card:first-child .servicio-imagen {
    width: 100%;
    max-width: 1200px; /* Controla el ancho máximo del alargado */
    height: 700px; /* Altura aumentada para el efecto alargado */
}

/* Estilos normales para todas las tarjetas */
.servicio-card {
    background: #f9f9f9;
    border-radius: 10px;
    overflow: hidden;
    transition: var(--transition);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    display: flex;
    flex-direction: column;
    height: 100%;
}

.servicio-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.15);
    background: #f0f0f0;
}

.servicio-imagen {
    width: 100%;  
    height: 500px; /* Altura normal para las demás imágenes */
    overflow: hidden;
    position: relative;
}

.servicio-imagen img {
    width: 100%; 
    height: 100%;
    object-fit: cover;
    transition: var(--transition-slow);
}

.servicio-contenido {
    padding: 1.5rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.servicio-nombre {
    font-size: 1.4rem;
    margin-bottom: 1rem;
    color: #333;
    font-weight: 600;
    text-align: center;
}

/* Responsive */
@media (max-width: 768px) {
    .servicios-grid {
        grid-template-columns: 1fr;
    }
    
    .servicios-grid .servicio-card:first-child {
        grid-column: 1;
    }
    
    .servicio-card:first-child .servicio-imagen {
        height: 200px; /* Altura reducida en móviles */
    }
}

        /* ======================================================= */
        /* FOOTER */
        /* ======================================================= */
        .footer-principal {
            background-color: #f8f8f8;
            color: #333;
            padding: 30px 20px;
            font-family: 'Montserrat', sans-serif;
            text-align: center;
        }
        
        footer p {
            font-family: 'Montserrat', sans-serif;
            color: black;
        }

        .footer-container {
            display: flex;
            flex-wrap: wrap;
            justify-content: space-around;
            align-items: flex-start;
            max-width: 1500px;
            margin: 0 auto;
        }

        .footer-columna {
            flex-basis: 30%;
            padding: 20px;
        }

        .footer-info {
            text-align: left;
        }

        .footer-container h3 {
            color: #dda97cdd;
            font-size: 1.2rem;
            margin-bottom: 15px;
            font-weight: bold;
            font-family: 'Montserrat', sans-serif;
        }

        .footer-enlaces ul {
            list-style: none;
            padding: 0;
            margin: 0;
            text-align: left;
        }

        .footer-enlaces li {
            margin-bottom: 10px;
        }

        .footer-enlaces a {
            color: #000000;
            text-decoration: none;
            transition: color 0.3s ease;
            font-family: 'Montserrat', sans-serif;
        }

        .footer-enlaces a:hover {
            color: #dda97cdd;
        }

        .footer-contacto {
            text-align: left;
        }

        .footer-contacto p {
            margin-bottom: 10px;
            font-family: 'Montserrat', sans-serif;
            color: black;
        }

        .footer-contacto i {
            margin-right: 8px;
            color: #dda97cdd;
        }

        .footer-social h3 {
            margin-top: 20px;
            text-align: left;
        }

        .social-icons a {
            color: #555;
            font-size: 1.5rem;
            margin-right: 15px;
            transition: color 0.3s ease;
        }

        .social-icons a:hover {
            color: #dda97cdd;
        }

        .mapa-ubicacion-footer {
            width: 100%;
            margin-top: 1.5rem;
            border-radius: 10px;
            overflow: hidden;
            box-shadow: 0 4px 6px rgba(0, 0, 0, 0.2);
        }

        .mapa-ubicacion-footer iframe {
            width: 100%;
            height: 200px;
            display: block;
        }

        /* ======================================================= */
        /* ANIMACIONES */
        /* ======================================================= */
        @keyframes pulse {
            0%, 100% { transform: scale(1); }
            50% { transform: scale(1.05); }
        }

        @keyframes bounce {
            0%, 20%, 50%, 80%, 100% { transform: translateY(0); }
            40% { transform: translateY(-20px); }
            60% { transform: translateY(-10px); }
        }

        @keyframes fadeInUp {
            from {
                opacity: 0;
                transform: translateY(30px);
            }
            to {
                opacity: 1;
                transform: translateY(0);
            }
        }

        @keyframes float {
            0%, 100% { transform: translateY(0) rotate(0deg); }
            50% { transform: translateY(-20px) rotate(10deg); }
        }

        @keyframes shine {
            0% { transform: translateX(-100%); }
            100% { transform: translateX(100%); }
        }

        /* ======================================================= */
        /* RESPONSIVE DESIGN - MENÚ TOGGLE MEJORADO */
        /* ======================================================= */
        @media (max-width: 768px) {
            /* Botón del menú hamburguesa */
            .menu-toggle {
                display: flex;
            }
            
            /* Navegación para móviles - CENTRADA */
            .barra-navegacion {
                position: fixed;
                top: 0;
                right: -100%;
                width: 100%;
                height: 100vh;
                background: linear-gradient(to bottom, #380101, #5f0000);
                transition: right 0.3s ease;
                z-index: 999;
                overflow-y: auto;
                padding: 80px 20px 20px;
                box-shadow: -5px 0 15px rgba(0, 0, 0, 0.3);
                display: flex;
                justify-content: center;
                align-items: center;
            }
            
            .barra-navegacion.visible {
                right: 0;
            }
            
            .barra-navegacion ul {
                flex-direction: column;
                align-items: center;
                justify-content: center;
                width: 100%;
                text-align: center;
            }
            
            .barra-navegacion li {
                margin: 15px 0;
                width: 100%;
            }
            
            .barra-navegacion a {
                display: block;
                padding: 15px 0;
                font-size: 20px;
                font-weight: 600;
                border-bottom: 1px solid rgba(255, 255, 255, 0.1);
                width: 100%;
                font-family: 'Montserrat', sans-serif;
            }
            
            .barra-navegacion a:after {
                display: none;
            }
            
            /* Dropdown en móviles */
            .catalogo-dropdown {
                position: static;
                opacity: 1;
                visibility: visible;
                transform: none;
                display: none;
                background: rgba(84, 6, 6, 0.7);
                margin-top: 10px;
                padding-left: 0;
                box-shadow: none;
                width: 100%;
                text-align: center;
            }
            
            .catalogo-dropdown.visible {
                display: block;
            }
            
            .catalogo-dropdown a {
                padding: 12px 0;
                font-size: 18px;
                border-bottom: 1px solid rgba(255, 255, 255, 0.1);
                font-family: 'Montserrat', sans-serif;
            }
            
            /* Ajustes para el menú de usuario */
            .barra-navegacion .dropdown .catalogo-dropdown {
                position: static;
                display: none;
                background: rgba(84, 6, 6, 0.7);
                margin-top: 10px;
                padding-left: 0;
                box-shadow: none;
                width: 100%;
                text-align: center;
            }
            
            .barra-navegacion .dropdown .catalogo-dropdown.visible {
                display: block;
            }
            
            /* Header y Navegación */
            .header-principal {
                padding: 0.8rem 3%;
            }
            
            .hero-cnc {
                height: 70vh;
                min-height: 500px;
            }
            
            .cnc-tags-container {
                gap: 1rem;
            }
            
            .cnc-tag {
                padding: 0.6rem 1.2rem;
                font-size: 0.8rem;
            }
            
            .servicios-grid {
                grid-template-columns: 1fr;
                gap: 1.5rem;
            }
            
            .servicio-imagen {
                height: 200px;
            }
            
            .footer-container {
                flex-direction: column;
                align-items: center;
                text-align: center;
            }
            
            .footer-columna {
                margin-bottom: 2rem;
            }
            
            .footer-columna ul {
                display: flex;
                flex-direction: column;
                align-items: center;
            }
            
            .footer-contacto p {
                justify-content: center;
            }
            
            .social-icons {
                display: flex;
                justify-content: center;
            }
            
            .social-icons a {
                animation: none;
            }
        }

        /* Para pantallas más grandes, asegurar que el dropdown funcione con hover */
        @media (min-width: 769px) {
            .catalogo-dropdown {
                position: absolute;
                top: 100%;
                left: 0;
                background: rgba(84, 6, 6, 0.95);
                min-width: 200px;
                box-shadow: var(--shadow);
                opacity: 0;
                visibility: hidden;
                transform: translateY(10px);
                transition: var(--transition);
                z-index: 100;
                border-radius: 4px;
                padding: 0.5rem 0;
                display: block !important;
            }
            
            .dropdown:hover .catalogo-dropdown {
                opacity: 1;
                visibility: visible;
                transform: translateY(0);
            }
            
            /* Asegurar que la navegación sea visible */
            .barra-navegacion {
                display: block !important;
            }
        }

        @media (max-width: 576px) {
            .header-principal {
                padding: 0.8rem 1rem;
            }
            
            .logo img {
                height: 35px;
            }
            
            .whatsapp-flotante {
                width: 50px;
                height: 50px;
                bottom: 20px;
                right: 20px;
            }
            
            .whatsapp-flotante img {
                width: 30px;
                height: 30px;
            }
            
            .back-to-top {
                bottom: 85px;
            }
            
            .footer-columna {
                padding: 0;
            }
            
            .mapa-ubicacion-footer iframe {
                height: 150px;
            }
        }