* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

:root {
    --primary: #183451;
    --secondary: #e52e19;
    --accent: #3498db;
    --light: #ecf0f1;
    --dark: #2c3e50;
    --gray: #95a5a6;
    --text: #333333;
}

body {
    background-color: #f8f9fa;
    color: var(--text);
    line-height: 1.6;
    scroll-behavior: smooth;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

/* Header con color azul #183451 */
header {
    background-color: #183451;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
    padding: 15px 0;
}

.header-main .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: flex;
    align-items: center;
    gap: 15px;
}

.logo-img {
    height: 60px;
    width: auto;
}

.logo-text h1 {
    font-size: 1.8rem;
    color: white;
    line-height: 1.2;
}

.logo-text p {
    font-size: 0.9rem;
    color: #ecf0f1;
}

/* Navegación - Texto blanco para fondo azul */
nav ul {
    display: flex;
    list-style: none;
    gap: 25px;
}

nav a {
    text-decoration: none;
    color: white;
    font-weight: 600;
    font-size: 1rem;
    transition: color 0.3s;
    position: relative;
}

nav a:hover {
    color: var(--secondary);
}

nav a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--secondary);
    transition: width 0.3s;
}

nav a:hover::after {
    width: 100%;
}

/* Hero Section */
.hero {
    background: linear-gradient(rgba(0,0,0,0.7), rgba(0,0,0,0.7)), url('imagenes/PORTADA/portada.jpg');
    background-size: cover;
    background-position: center;
    color: white;
    padding: 100px 0;
    text-align: center;
}

.hero h2 {
    font-size: 2.5rem;
    margin-bottom: 20px;
}

.hero p {
    font-size: 1.2rem;
    max-width: 700px;
    margin: 0 auto 30px;
}

.btn {
    display: inline-block;
    background-color: var(--secondary);
    color: white;
    padding: 12px 30px;
    border-radius: 4px;
    text-decoration: none;
    font-weight: 600;
    transition: background-color 0.3s;
}

.btn:hover {
    background-color: #c0392b;
}

/* Products Section */
.products {
    padding: 80px 0;
    background-color: white;
}

.section-title {
    text-align: center;
    margin-bottom: 50px;
}

.section-title h2 {
    font-size: 2rem;
    color: var(--primary);
    margin-bottom: 15px;
    position: relative;
    display: inline-block;
}

.section-title h2::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 3px;
    background-color: var(--secondary);
}

.section-title p {
    color: var(--gray);
    max-width: 600px;
    margin: 0 auto;
}

.products-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.product-card {
    background-color: white;
    border-radius: 5px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    transition: transform 0.3s, box-shadow 0.3s;
}

.product-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0,0,0,0.15);
}

/* Mejoras específicas para imágenes de productos */
.product-img {
    height: 200px;
    background-color: var(--light);
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.product-img img {
    width: 100%;
    height: 100%;
    object-fit: cover; /* Esto es clave para que las imágenes se ajusten */
    object-position: center; /* Enfoca el centro de la imagen */
    transition: transform 0.3s ease;
}

.product-card:hover .product-img img {
    transform: scale(1.05); /* Efecto zoom más sutil */
}

/* Si las imágenes son verticales, usa esto: */
.product-img.vertical img {
    object-fit: contain; /* Muestra toda la imagen sin recortar */
    background-color: white; /* Fondo blanco para imágenes con transparencia */
}

/* Si las imágenes son horizontales: */
.product-img.horizontal img {
    object-fit: cover;
    object-position: center 30%; /* Ajusta el enfoque si es necesario */
}

/* Contenedor de imagen con relación de aspecto */
.product-img.aspect-ratio {
    height: 0;
    padding-bottom: 75%; /* Relación 4:3 (ajusta según necesites) */
    position: relative;
}

.product-img.aspect-ratio img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.product-content {
    padding: 20px;
}

.product-content h3 {
    font-size: 1.3rem;
    margin-bottom: 10px;
    color: var(--primary);
}

.product-content p {
    color: var(--gray);
    margin-bottom: 15px;
    font-size: 0.95rem;
}

.product-price {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 15px;
}

.price {
    font-weight: 700;
    color: var(--secondary);
    font-size: 1.2rem;
}

/* Services Section */
.services {
    padding: 80px 0;
    background-color: var(--light);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 25px;
}

.service-card {
    background-color: white;
    padding: 30px 20px;
    border-radius: 5px;
    text-align: center;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    transition: transform 0.3s;
}

.service-card:hover {
    transform: translateY(-5px);
}

.service-icon {
    width: 70px;
    height: 70px;
    background-color: var(--primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    color: white;
    font-size: 1.8rem;
}

.service-card h3 {
    font-size: 1.2rem;
    margin-bottom: 15px;
    color: var(--primary);
}

.service-card p {
    color: var(--gray);
    font-size: 0.9rem;
}

/* Gallery Section - MEJORADO CON TRANSICIONES */
.gallery {
    padding: 80px 0;
    background-color: white;
}

.gallery-filters {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-bottom: 40px;
    flex-wrap: wrap;
}

.filter-btn {
    padding: 10px 20px;
    background-color: white;
    border: 1px solid var(--gray);
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s;
    font-weight: 600;
}

.filter-btn.active, .filter-btn:hover {
    background-color: var(--primary);
    color: white;
    border-color: var(--primary);
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

.gallery-item {
    height: 250px;
    background-color: var(--light);
    border-radius: 5px;
    overflow: hidden;
    position: relative;
    transition: all 0.3s ease-in-out;
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s;
}

.gallery-item:hover img {
    transform: scale(1.1);
}

.gallery-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(0,0,0,0.7));
    color: white;
    padding: 20px;
    transform: translateY(100%);
    transition: transform 0.3s;
}

.gallery-item:hover .gallery-overlay {
    transform: translateY(0);
}

/* About Section con Mapa */
.about {
    padding: 80px 0;
    background-color: var(--primary);
    color: white;
}

.about .container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    align-items: start;
}

.about-content h2 {
    font-size: 2rem;
    margin-bottom: 20px;
}

.about-content p {
    margin-bottom: 20px;
    font-size: 1.05rem;
    line-height: 1.7;
}

.about-features {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-top: 30px;
}

.feature {
    display: flex;
    align-items: center;
    gap: 15px;
}

.feature-icon {
    width: 50px;
    height: 50px;
    background-color: var(--secondary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

/* Estilos para el mapa */
.about-map {
    background: rgba(255, 255, 255, 0.1);
    padding: 25px;
    border-radius: 10px;
    backdrop-filter: blur(10px);
}

.about-map h3 {
    font-size: 1.5rem;
    margin-bottom: 20px;
    color: white;
    text-align: center;
}

.map-container {
    position: relative;
    width: 100%;
    padding-bottom: 56.25%; /* Relación 16:9 */
    height: 0;
    overflow: hidden;
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.3);
    margin-bottom: 20px;
}

.map-container iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

.map-info {
    background: rgba(255, 255, 255, 0.1);
    padding: 15px;
    border-radius: 8px;
}

.map-info p {
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.map-info i {
    color: var(--secondary);
    width: 20px;
}

/* Footer */
footer {
    background-color: var(--dark);
    color: white;
    padding: 60px 0 20px;
}

.footer-content {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 40px;
    margin-bottom: 40px;
}

.footer-logo h3 {
    font-size: 1.5rem;
    margin-bottom: 15px;
    color: white;
}

.footer-logo p {
    color: #bbb;
    margin-bottom: 20px;
}

.social-links {
    display: flex;
    gap: 15px;
}

.social-links a {
    width: 40px;
    height: 40px;
    background-color: rgba(255,255,255,0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    transition: background-color 0.3s;
}

.social-links a:hover {
    background-color: var(--secondary);
}

.footer-column h4 {
    font-size: 1.2rem;
    margin-bottom: 20px;
    color: white;
}

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: 10px;
}

.footer-links a {
    color: #bbb;
    text-decoration: none;
    transition: color 0.3s;
}

.footer-links a:hover {
    color: white;
}

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid rgba(255,255,255,0.1);
    color: #bbb;
    font-size: 0.9rem;
}

/* Responsive */
@media (max-width: 992px) {
    .products-grid, .services-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .gallery-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    
    .footer-content {
        grid-template-columns: 1fr 1fr;
    }
    
    .about .container {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    
    .about-map {
        order: -1;
    }
    
    .about-features {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .header-main .container {
        flex-direction: column;
        gap: 15px;
    }
    
    nav ul {
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .products-grid, .services-grid, .gallery-grid {
        grid-template-columns: 1fr;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
    }
    
    .hero h2 {
        font-size: 2rem;
    }
    
    .services-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .about {
        padding: 60px 0;
    }
    
    .about-map {
        padding: 20px;
    }
    
    .map-container {
        padding-bottom: 75%; /* Más alto y cómodo en móvil */
    }
}

@media (max-width: 480px) {
    .services-grid {
        grid-template-columns: 1fr;
    }
    
    .hero {
        padding: 60px 0;
    }
    
    .hero h2 {
        font-size: 1.8rem;
    }
    
    .hero p {
        font-size: 1rem;
    }
    
    .logo-text h1 {
        font-size: 1.5rem;
    }
    
    nav ul {
        gap: 15px;
    }
    
    nav a {
        font-size: 0.9rem;
    }
    
    .gallery-grid {
        grid-template-columns: 1fr;
    }
}
/* WhatsApp Flotante con Menú */
/* .whatsapp-float {
    position: fixed;
    bottom: 25px;
    right: 25px;
    background-color: #25D366;
    color: white;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    box-shadow: 0 4px 20px rgba(37, 211, 102, 0.4);
    z-index: 1000;
    transition: all 0.3s;
    animation: pulse 2s infinite;
}

.whatsapp-float:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 25px rgba(37, 211, 102, 0.6);
}

/* WhatsApp Flotante con Menú - CORREGIDO */
/* .whatsapp-float {
    position: fixed;
    bottom: 25px;
    right: 25px;
    background-color: #25D366;
    color: white;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    box-shadow: 0 4px 20px rgba(37, 211, 102, 0.4);
    z-index: 1000;
    transition: all 0.3s;
    animation: pulse 2s infinite;
    cursor: pointer;
}

.whatsapp-float:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 25px rgba(37, 211, 102, 0.6);
} */ 

/* Menú desplegable de WhatsApp
.whatsapp-menu {
    position: absolute;
    bottom: 70px;
    right: 0;
    background: white;
    border-radius: 12px;
    box-shadow: 0 8px 30px rgba(0,0,0,0.2);
    padding: 15px;
    min-width: 200px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.3s ease;
    z-index: 1001;
}

.whatsapp-menu.active {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.whatsapp-menu::before {
    content: '';
    position: absolute;
    bottom: -8px;
    right: 20px;
    width: 0;
    height: 0;
    border-left: 8px solid transparent;
    border-right: 8px solid transparent;
    border-top: 8px solid white;
}

.whatsapp-option {
    display: flex;
    align-items: center;
    padding: 12px 15px;
    color: var(--dark);
    text-decoration: none;
    border-radius: 8px;
    transition: all 0.3s;
    margin: 5px 0;
    border: 1px solid transparent;
    cursor: pointer;
}

.whatsapp-option:hover {
    background-color: #f8f9fa;
    border-color: #25D366;
    transform: translateX(-5px);
    text-decoration: none;
}

.whatsapp-option i {
    background-color: #25D366;
    color: white;
    width: 35px;
    height: 35px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 12px;
    font-size: 1.1rem;
}

.whatsapp-info {
    display: flex;
    flex-direction: column;
}

.whatsapp-number {
    font-weight: 600;
    color: var(--dark);
    font-size: 0.95rem;
}

.whatsapp-label {
    font-size: 0.8rem;
    color: var(--gray);
    margin-top: 2px;
}

.whatsapp-close {
    position: absolute;
    top: 8px;
    right: 10px;
    background: none;
    border: none;
    color: var(--gray);
    cursor: pointer;
    font-size: 1.2rem;
    padding: 5px;
    z-index: 1002;
}

.whatsapp-close:hover {
    color: var(--dark);
}

@keyframes pulse {
    0% {
        box-shadow: 0 4px 20px rgba(37, 211, 102, 0.4);
    }
    50% {
        box-shadow: 0 4px 25px rgba(37, 211, 102, 0.8);
    }
    100% {
        box-shadow: 0 4px 20px rgba(37, 211, 102, 0.4);
    }
}

/* Responsive para WhatsApp */
/* @media (max-width: 768px) {
    .whatsapp-float {
        bottom: 20px;
        right: 20px;
        width: 55px;
        height: 55px;
        font-size: 1.6rem;
    }
    
    .whatsapp-menu {
        min-width: 180px;
        right: -10px;
    }
    
    .whatsapp-menu::before {
        right: 25px;
    }
}

@media (max-width: 480px) {
    .whatsapp-float {
        bottom: 15px;
        right: 15px;
        width: 50px;
        height: 50px;
        font-size: 1.5rem;
    }
}  */