* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

/* Navbar */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.5rem 5%; /* Reducimos padding vertical para ajustar altura */
    background: #1a1a1a;
    color: white;
    position: sticky;
    top: 0;
    z-index: 1000;
    height: 100px; /* Definimos una altura fija opcional para la barra */
}

/* Contenedor del enlace del logo */
.logo-container {
    display: flex;
    align-items: center;
    text-decoration: none;
    height: 100%; /* Para que ocupe el alto de la navbar */
}

.logo-img {
    max-height: 90px; /* Limita el alto máximo para que no deforme la barra */
    width: auto; /* Mantiene la proporción */
    display: block;
    object-fit: contain; /* Asegura que la imagen quepa dentro sin cortarse */
}

.nav-links {
    display: flex;
    list-style: none;
    align-items: center; /* Alineación vertical */
}

.nav-links li {
    margin-left: 50px;
}

.nav-links a {
    color: white;
    text-decoration:solid;
    font-weight: 700;
    transition: 0.3s;
}

.nav-links a:hover {
    color: #ff4d4d; /* Color de acento */
}

/* Header */
.hero {
    height: 60vh;
    background: linear-gradient(rgba(0,0,0,0.6), rgba(0,0,0,0.6)), 
                url('./img\ header1.jpg') no-repeat center/cover;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: white;
}

.btn-whatsapp {
    display: inline-block;
    margin-top: 20px;
    padding: 12px 25px;
    background: #25d366;
    color: white;
    text-decoration: none;
    border-radius: 5px;
    font-weight: bold;
    transition: transform 0.3s;
}

.btn-whatsapp:hover {
    transform: scale(1.05);
}

/* Tarjetas con Efecto */
.cards-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    padding: 50px 5%;
    background: #f4f4f4;
}

.card {
    height: 200px;
    perspective: 1000px;
}

.card-inner {
    position: relative;
    width: 100%;
    height: 100%;
    text-align: center;
    transition: transform 0.6s;
    transform-style: preserve-3d;
    cursor: pointer;
}

.card:hover .card-inner {
    transform: rotateY(180deg);
}

.card-front, .card-back {
    position: absolute;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    padding: 20px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

.card-front {
    background: white;
    color: #333;
    border-bottom: 4px solid #ff4d4d;
}

.card-back {
    background: #333;
    color: white;
    transform: rotateY(180deg);
}

/* Hero específico para la página de máquinas */
.hero-maquinas {
    height: 60vh;
    background: linear-gradient(rgba(0,0,0,0.6), rgba(0,0,0,0.6)), 
                url('./img\ header1.jpg') no-repeat center/cover;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: white;
}

/* Hero específico para Sobre Nosotros */
.hero-nosotros {
    height: 60vh;
    background: linear-gradient(rgba(0,0,0,0.6), rgba(0,0,0,0.6)), 
                url('./img\ header1.jpg') no-repeat center/cover;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: white;
}

/* --- Sección Contacto --- */
.contacto-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    padding: 60px 10%;
    background: #fff;
}

.contacto-info h2 {
    color: #1a1a1a;
    margin-bottom: 20px;
}

.info-item {
    margin-bottom: 25px;
}

.link-contacto {
    color: #25d366; /* Verde WhatsApp */
    text-decoration: none;
    font-weight: bold;
}

/* Formulario */
.contacto-form {
    background: #f9f9f9;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
}

.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 600;
}

.form-group input, 
.form-group select, 
.form-group textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 1rem;
}

.btn-enviar {
    background: #ff4d4d;
    color: white;
    border: none;
    padding: 12px 25px;
    border-radius: 5px;
    cursor: pointer;
    font-weight: bold;
    width: 100%;
    transition: 0.3s;
}

.btn-enviar:hover {
    background: #cc0000;
}

/* Redes Sociales */
.iconos-redes {
    display: flex;
    gap: 15px;
    margin-top: 15px;
}

.social-btn {
    text-decoration: none;
    background: #333;
    color: white;
    padding: 8px 15px;
    border-radius: 5px;
    font-size: 0.9rem;
}

/* Adaptabilidad para móviles */
@media (max-width: 768px) {
    .contacto-container {
        grid-template-columns: 1fr;
    }
}

/* --- Estilos Catálogo de Máquinas --- */
.catalogo-seccion {
    padding: 60px 5%;
    background: #fdfdfd;
}

.serie-header {
    text-align: center;
    margin: 40px 0;
    border-bottom: 2px solid #ff4d4d;
    display: inline-block;
    width: 100%;
    padding-bottom: 10px;
}

.productos-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-bottom: 60px;
}

.producto-card {
    background: white;
    border: 1px solid #eee;
    border-radius: 8px;
    overflow: hidden;
    transition: 0.3s;
}

.producto-card:hover {
    box-shadow: 0 10px 20px rgba(0,0,0,0.1);
    transform: translateY(-5px);
}

.producto-card img {
    width: 100%;
    height: 250px;
    object-fit: cover;
}

.producto-info {
    padding: 20px;
}

.producto-info h3 {
    margin-bottom: 15px;
    color: #333;
}

.producto-info ul {
    list-style: none;
    margin-bottom: 20px;
    font-size: 0.9rem;
    color: #666;
}

.producto-info li::before {
    content: "✓";
    color: #ff4d4d;
    margin-right: 8px;
    font-weight: bold;
}

.btn-cotizar {
    display: block;
    text-align: center;
    background: #1a1a1a;
    color: white;
    text-decoration: none;
    padding: 10px;
    border-radius: 4px;
    font-weight: bold;
    transition: 0.3s;
}

.btn-cotizar:hover {
    background: #25d366; /* Cambia a verde al hover para invitar al WhatsApp */
}

/* --- Sección Sobre Nosotros --- */

/* Historia: Diseño en dos columnas */
.nosotros-historia {
    display: flex;
    align-items: center;
    gap: 50px;
    padding: 80px 10%;
    flex-wrap: wrap;
}

.texto-historia {
    flex: 1;
    min-width: 300px;
}

.texto-historia h2 {
    font-size: 2.5rem;
    margin-bottom: 20px;
    color: #1a1a1a;
}

.texto-historia p {
    line-height: 1.8;
    color: #555;
    margin-bottom: 15px;
}

.imagen-taller {
    flex: 1;
    min-width: 300px;
}

.imagen-taller img {
    width: 100%;
    border-radius: 15px;
    box-shadow: 20px 20px 0px #ff4d4d; /* Un detalle visual industrial */
}

/* Valores: Iconos y Pilares */
.valores-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    padding: 60px 10%;
    background: #f4f4f4;
    text-align: center;
}

.valor-item {
    background: white;
    padding: 40px 20px;
    border-radius: 10px;
    transition: 0.3s;
}

.valor-item:hover {
    transform: translateY(-10px);
}

.valor-item .icon {
    font-size: 3rem;
    margin-bottom: 15px;
}

.valor-item h3 {
    margin-bottom: 10px;
    color: #1a1a1a;
}

/* Llamado a la acción final */
.cta-final {
    text-align: center;
    padding: 80px 10%;
    background: #1a1a1a;
    color: white;
}

.cta-final h2 {
    font-size: 2.2rem;
    margin-bottom: 15px;
}

.btn-cta {
    display: inline-block;
    margin-top: 25px;
    padding: 15px 40px;
    background: #ff4d4d;
    color: white;
    text-decoration: none;
    font-weight: bold;
    border-radius: 5px;
    transition: 0.3s;
}

.btn-cta:hover {
    background: white;
    color: #ff4d4d;
}

/* --- Footer Global --- */
.main-footer {
    background: #111; /* Negro profundo para el cierre */
    color: #bbb;
    padding: 60px 0 20px 0;
    font-size: 0.9rem;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 2fr 1fr 1.5fr;
    gap: 40px;
    padding: 0 5%;
}

.footer-section h3 {
    color: white;
    margin-bottom: 20px;
    font-size: 1.2rem;
    border-left: 3px solid #ff4d4d;
    padding-left: 10px;
}

.footer-logo {
    max-height: 50px;
    margin-bottom: 20px;
    filter: brightness(0) invert(1); /* Hace que el logo se vea blanco si es oscuro */
}

/* Estilos de los links en el footer */
.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 10px;
}

.footer-section a {
    color: #bbb;
    text-decoration: none;
    transition: 0.3s;
}

.footer-section a:hover {
    color: #ff4d4d;
    padding-left: 5px;
}

/* Redes Sociales */
.social-icons {
    margin-top: 20px;
    display: flex;
    gap: 15px;
}

.social-link {
    background: #333;
    color: white !important; /* Forzamos el blanco para el icono */
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    font-size: 1.2rem; /* Tamaño del icono */
    transition: 0.3s ease;
    text-decoration: none;
}

.social-link:hover {
    transform: translateY(-5px);
}

.fa-instagram:hover { color: #E1306C; }
.fa-facebook-f:hover { color: #1877F2; }
.fa-youtube:hover { color: #FF0000; }
.fa-whatsapp:hover { color: #25D366; }

/* Barra inferior de derechos */
.footer-bottom {
    text-align: center;
    margin-top: 50px;
    padding-top: 20px;
    border-top: 1px solid #222;
    color: #666;
}

/* Ajuste móvil */
@media (max-width: 768px) {
    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .footer-section h3 {
        border-left: none;
        border-bottom: 2px solid #ff4d4d;
        display: inline-block;
        padding-bottom: 5px;
    }

    .social-icons {
        justify-content: center;
    }
}

/* --- Botón Flotante de WhatsApp --- */
.whatsapp-float {
    position: fixed;
    width: 60px;
    height: 60px;
    bottom: 40px;
    right: 40px;
    background-color: #25d366;
    color: #FFF;
    border-radius: 50px;
    text-align: center;
    font-size: 35px;
    box-shadow: 2px 2px 10px rgba(0,0,0,0.3);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    transition: all 0.3s ease;
    animation: pulse-whatsapp 2s infinite;
}

.whatsapp-float:hover {
    background-color: #128c7e;
    transform: scale(1.1);
    color: white;
}

/* Tooltip (Leyenda que aparece al lado) */
.tooltip-whatsapp {
    position: absolute;
    right: 70px;
    background: #333;
    color: white;
    padding: 8px 15px;
    border-radius: 5px;
    font-size: 14px;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: 0.3s;
}

.whatsapp-float:hover .tooltip-whatsapp {
    opacity: 1;
    visibility: visible;
}

/* Animación de pulso para llamar la atención */
@keyframes pulse-whatsapp {
    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);
    }
}

/* Ajuste para móviles para que no tape contenido importante */
@media (max-width: 768px) {
    .whatsapp-float {
        width: 50px;
        height: 50px;
        bottom: 20px;
        right: 20px;
        font-size: 30px;
    }
    .tooltip-whatsapp {
        display: none; /* Ocultamos el texto en móviles para no saturar la pantalla */
    }
}

.ubicacion-destacada {
    background: #f9f9f9;
    padding: 40px 10%;
    border-left: 5px solid #ff4d4d;
    margin: 20px 0;
    display: flex;
    align-items: center;
    gap: 20px;
}

.ubicacion-destacada i {
    font-size: 2.5rem;
    color: #ff4d4d;
}

.ubicacion-destacada h3 {
    margin-bottom: 5px;
    color: #1a1a1a;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Ocultar el botón hamburguesa en escritorio */
.hamburger {
    display: none;
    background: none;
    border: none;
    color: white;
    font-size: 1.8rem;
    cursor: pointer;
}

/* Media Query para Celulares */
@media (max-width: 768px) {
    .hamburger {
        display: block; /* Aparece en móviles */
    }

    .nav-links {
        position: fixed;
        left: -100%; /* Escondido a la izquierda */
        top: 80px; /* Altura de tu navbar */
        flex-direction: column;
        background: #1a1a1a;
        width: 100%;
        height: calc(100vh - 80px);
        text-align: center;
        transition: 0.3s;
        padding-top: 50px;
        z-index: 999;
    }

    .nav-links li {
        margin: 20px 0;
    }

    /* Clase que activaremos con JS */
    .nav-links.active {
        left: 0;
    }
}