:root {
    --primary: #d35400; 
    --primary-dark: #b33e00;
    --secondary: #2c3e50; 
    --secondary-light: #34495e;
    --text-dark: #212f3d;
    --text-light: #f4f6f7;
    --white: #ffffff;
    --bg-light: #fdfdfd;
    --grid-gap: 30px;
    --transition: all 0.5s cubic-bezier(0.25, 0.8, 0.25, 1);
}

* { margin: 0; padding: 0; box-sizing: border-box; font-family: 'Montserrat', sans-serif; }
html { scroll-behavior: smooth; overflow-x: hidden; }
body { background-color: var(--bg-light); color: var(--text-dark); line-height: 1.8; position: relative; }

/* Estructura Base */
.section { padding: 100px 5%; position: relative; }
.section-container { max-width: 1200px; margin: 0 auto; position: relative; z-index: 2; overflow: hidden; padding: 20px 0; }
.title-main { text-align: center; font-size: 3rem; color: var(--secondary); text-transform: uppercase; font-weight: 900; margin-bottom: 20px; text-shadow: 0 2px 4px rgba(0,0,0,0.05); }
.text-white { color: var(--white) !important; }
.text-light { color: rgba(255,255,255,0.85) !important; }
.subtitle { text-align: center; max-width: 800px; margin: 0 auto 40px auto; font-size: 1.2rem; color: var(--secondary-light); }
.divider { height: 6px; width: 100px; background: var(--primary); margin: 0 auto 60px auto; border-radius: 10px; }

/* Fondos Texturizados */
.wood-bg-light { background-color: #f9f9f9; background-image: radial-gradient(rgba(44, 62, 80, 0.03) 2px, transparent 2px); background-size: 30px 30px; }
.wood-bg-dark { background-image: linear-gradient(rgba(44, 62, 80, 0.92), rgba(44, 62, 80, 0.96)), url('Images/Tablones-de-fondo.jpg'); background-size: cover; color: var(--text-light); }
.parallax { background-attachment: fixed; background-position: center; }

/* Elementos Decorativos del Negocio */
.decor-forklift {
    position: absolute;
    bottom: -80px;
    right: -120px;
    height: 400px;
    opacity: 0.15;
    z-index: 1;
    pointer-events: none;
    filter: grayscale(100%);
    transition: all 0.6s ease;
}
.section:hover .decor-forklift { opacity: 0.4; filter: grayscale(0%); transform: translateX(-30px); }

/* Botones */
.btn { display: inline-block; padding: 15px 40px; background-color: var(--primary); color: var(--white); text-decoration: none; font-weight: 800; text-transform: uppercase; border-radius: 50px; transition: var(--transition); cursor: pointer; border: 2px solid var(--primary); box-shadow: 0 4px 15px rgba(211, 84, 0, 0.3); letter-spacing: 1px; }
.btn:hover { background-color: transparent; color: var(--primary); transform: translateY(-5px); box-shadow: 0 10px 25px rgba(211, 84, 0, 0.2); }
.btn-large { font-size: 1.2rem; padding: 20px 60px; }
.btn-lowercase { text-transform: lowercase !important; }

/* Botón Flotante WhatsApp - ACTUALIZADO CON ANIMACIÓN CONTINUA */
.whatsapp-float {
    position: fixed;
    width: 65px;
    height: 65px;
    bottom: 30px;
    right: 30px;
    background-color: #25d366;
    color: #FFF;
    border-radius: 50%;
    text-align: center;
    box-shadow: 0px 4px 15px rgba(0, 0, 0, 0.3);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275), background-color 0.3s ease;
    animation: pulse-whatsapp 2s infinite;
}
.whatsapp-float:hover {
    transform: scale(1.15) rotate(-5deg);
    background-color: #20b858;
}
.whatsapp-icon {
    width: 35px;
    height: 35px;
    fill: #FFF;
}

@keyframes pulse-whatsapp {
    0% { box-shadow: 0 0 0 0 rgba(37, 211, 102, 0.6); }
    70% { box-shadow: 0 0 0 20px rgba(37, 211, 102, 0); }
    100% { box-shadow: 0 0 0 0 rgba(37, 211, 102, 0); }
}

/* Sistema de Animaciones */
.animate-slide-up { opacity: 0; transform: translateY(60px); transition: opacity 0.8s ease, transform 0.8s cubic-bezier(0.175, 0.885, 0.32, 1.275); transition-delay: var(--delay, 0s); }
.animate-slide-left { opacity: 0; transform: translateX(-60px); transition: opacity 0.8s ease, transform 0.8s ease; transition-delay: var(--delay, 0s); }
.animate-slide-right { opacity: 0; transform: translateX(60px); transition: opacity 0.8s ease, transform 0.8s ease; transition-delay: var(--delay, 0s); }
.animate-scale-up { opacity: 0; transform: scale(0.8); transition: opacity 0.8s ease, transform 0.8s cubic-bezier(0.175, 0.885, 0.32, 1.275); transition-delay: var(--delay, 0s); }
.animate-fade-in { opacity: 0; transition: opacity 1s ease; }
.animate-pop-in { opacity: 0; transform: scale(0.9) translateY(20px); transition: all 0.8s cubic-bezier(0.175, 0.885, 0.32, 1.275); }
.is-visible { opacity: 1; transform: translateY(0) translateX(0) scale(1); }

@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(211, 84, 0, 0.7); } 70% { box-shadow: 0 0 0 15px rgba(211, 84, 0, 0); } 100% { box-shadow: 0 0 0 0 rgba(211, 84, 0, 0); } }
.pulse-anim { animation: pulse 2s infinite; }

.hover-float { transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), box-shadow 0.4s ease; }
.hover-float:hover { transform: translateY(-15px) scale(1.02) !important; box-shadow: 0 25px 50px rgba(0,0,0,0.15) !important; z-index: 10; position: relative; }

/* Animación Tablones Laterales Flotantes */
.floating-planks {
    position: fixed;
    top: 50%;
    left: -400px;
    transform: translateY(-50%);
    height: 450px;
    z-index: 800;
    pointer-events: none;
    transition: left 0.8s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    filter: drop-shadow(5px 5px 15px rgba(0,0,0,0.3));
    opacity: 0.85;
}
.floating-planks.active { left: -50px; }

/* Header Centrado */
header { position: fixed; top: 0; width: 100%; background: linear-gradient(to bottom, rgba(44, 62, 80, 0.95), transparent); padding: 25px 5%; display: flex; justify-content: center; align-items: center; z-index: 1000; transition: var(--transition); height: auto; }
header.scrolled { background: rgba(44, 62, 80, 0.98); padding: 15px 5%; box-shadow: 0 4px 30px rgba(0,0,0,0.4); backdrop-filter: blur(10px); }

nav ul { list-style: none; display: flex; gap: 25px; flex-wrap: wrap; justify-content: center; }
nav a { color: var(--white); text-decoration: none; font-weight: 700; text-transform: uppercase; font-size: 0.85rem; letter-spacing: 1px; transition: var(--transition); position: relative; text-shadow: 0 2px 4px rgba(0,0,0,0.5); }
nav a::after { content: ''; position: absolute; width: 0; height: 3px; bottom: -5px; left: 0; background-color: var(--primary); transition: width 0.3s ease; border-radius: 5px; }
nav a:hover::after, nav a.active::after { width: 100%; }

/* Hero */
.hero { position: relative; height: 100vh; display: flex; align-items: center; justify-content: center; text-align: center; background-color: var(--secondary); overflow: hidden; }
.hero video { position: absolute; top: 50%; left: 50%; min-width: 100%; min-height: 100%; transform: translate(-50%, -50%); z-index: 0; object-fit: cover; }
.hero-overlay { position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: linear-gradient(45deg, rgba(44,62,80,0.8), rgba(0,0,0,0.6)); z-index: 1; }
.hero-content { position: relative; color: var(--white); max-width: 1100px; padding: 0 20px; z-index: 2; }

.hero-content h1 { font-size: 3.2rem; font-weight: 900; text-transform: uppercase; letter-spacing: 2px; margin-bottom: 20px; text-shadow: 0 4px 15px rgba(0,0,0,0.8); }
.hero-content .btn { margin-top: 30px; }

.hero-logo-wrapper { display: inline-block; margin-bottom: 20px; transition: var(--transition); }
.hero-logo-wrapper img { height: 200px; width: auto; display: block; margin: 0; filter: drop-shadow(0 4px 15px rgba(0,0,0,0.4)); }

/* Tarjetas Flexibles con Look Industrial */
.esencia-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: var(--grid-gap); position: relative; z-index: 2; }
.esencia-card { background-color: var(--white); border-radius: 4px; overflow: hidden; display: flex; flex-direction: column; transition: var(--transition); border: 2px solid var(--secondary); border-bottom: 10px solid var(--secondary); box-shadow: 0 5px 0 rgba(0,0,0,0.1); }
.esencia-card:hover { transform: translateY(-15px) scale(1.02); box-shadow: 0 20px 40px rgba(0,0,0,0.2); border-color: var(--primary); border-bottom-color: var(--primary-dark); }

.card-image { width: 100%; padding-top: 60%; position: relative; overflow: hidden; background: #e1e8ed; border-bottom: 2px solid var(--secondary); }
.esencia-card:hover .card-image { border-bottom-color: var(--primary); }
.card-image img { position: absolute; top: 0; left: 0; width: 100%; height: 100%; object-fit: cover; transition: transform 0.6s ease; }
.esencia-card:hover .card-image img { transform: scale(1.1); }

/* Ajuste de justificación para centrar contenido verticalmente cuando no hay imagen */
.card-content { padding: 40px 30px; flex-grow: 1; display: flex; flex-direction: column; justify-content: center; }

.card-content h3 { text-align: center; font-size: 1.5rem; color: var(--secondary); font-weight: 800; text-transform: uppercase; letter-spacing: 1px; margin-bottom: 15px; transition: var(--transition); }
.esencia-card:hover .card-content h3 { color: var(--primary); }
.card-content p { text-align: center; font-size: 1rem; color: var(--text-dark); margin: 0; }

/* Compromiso Grid */
.compromiso-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 20px; }
.compromiso-item { background: rgba(255,255,255,0.1); border: 1px solid rgba(255,255,255,0.2); border-radius: 12px; padding: 30px 20px; text-align: center; backdrop-filter: blur(5px); color: var(--white); transition: var(--transition); }
.compromiso-item:hover { background: var(--primary); border-color: var(--primary); transform: translateY(-5px); }
.icon-check { font-size: 2rem; color: var(--white); margin-bottom: 15px; display: inline-block; background: rgba(255,255,255,0.2); width: 60px; height: 60px; line-height: 60px; border-radius: 50%; }

/* Malla Flex / Grid Adaptativo */
.malla-imagenes { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); grid-auto-rows: 250px; gap: 15px; }
.malla-item { position: relative; overflow: hidden; border-radius: 12px; background: #2c3e50; }
.malla-item img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.8s ease; opacity: 0.9; }
.hover-zoom:hover img { transform: scale(1.15); opacity: 1; }
.malla-overlay { position: absolute; bottom: 0; left: 0; width: 100%; background: linear-gradient(transparent, rgba(44,62,80,0.95)); color: var(--white); padding: 40px 20px 20px; text-align: center; opacity: 0; transform: translateY(20px); transition: var(--transition); }
.hover-zoom:hover .malla-overlay { opacity: 1; transform: translateY(0); }
.malla-overlay p { font-weight: 800; text-transform: uppercase; font-size: 1.1rem; }
.malla-item-lg { grid-column: span 2; grid-row: span 2; }
.malla-item-h { grid-column: span 2; }

/* Métricas */
.metrica-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 20px; max-width: 950px; margin: 0 auto; }
.metrica-card { background: var(--secondary); padding: 30px 15px; border-radius: 15px; text-align: center; color: var(--white); box-shadow: 0 10px 20px rgba(0,0,0,0.1); border-bottom: 5px solid var(--primary); }
.metrica-card h3 { font-size: 2.8rem; margin-bottom: 5px; text-shadow: 0 4px 10px rgba(0,0,0,0.3); }
.metrica-card p { font-size: 0.95rem; }

/* Respaldo */
.respaldo-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: var(--grid-gap); }
.respaldo-card { background: rgba(255,255,255,0.05); padding: 40px 30px; border-radius: 15px; display: flex; align-items: flex-start; gap: 20px; border: 1px solid rgba(255,255,255,0.1); backdrop-filter: blur(10px); }
.respaldo-card .icon { font-size: 2.5rem; color: var(--white); font-weight: bold; background: var(--primary); width: 60px; height: 60px; display: flex; align-items: center; justify-content: center; border-radius: 50%; flex-shrink: 0; box-shadow: 0 5px 15px rgba(211, 84, 0, 0.4); }
.respaldo-card h4 { color: var(--white); font-size: 1.3rem; margin-bottom: 10px; font-weight: 800; }

/* Clientes */
.clientes-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 15px; text-align: center; }
.cliente-card { background: var(--white); padding: 25px 20px; border-radius: 12px; border: 1px solid #e1e8ed; color: var(--secondary); font-weight: 700; font-size: 1.1rem; transition: var(--transition); display: flex; align-items: center; justify-content: center; min-height: 90px; box-shadow: 0 5px 15px rgba(0,0,0,0.05); }
.cliente-card:hover { background: var(--primary); color: var(--white); transform: translateY(-8px) scale(1.05); box-shadow: 0 15px 30px rgba(211, 84, 0, 0.2); border-color: var(--primary); }

/* Contacto / Footer */
.contacto-box { background: var(--white); padding: 60px; border-radius: 20px; text-align: center; box-shadow: 0 20px 50px rgba(0,0,0,0.2); max-width: 800px; margin: 0 auto; border: 4px solid var(--primary); }
.contacto-box p { color: var(--secondary); }
.contacto-buttons { display: flex; gap: 20px; justify-content: center; flex-wrap: wrap; margin-top: 20px; }

footer { background: #1a252f; color: var(--text-light); padding: 80px 5% 30px 5%; }
.footer-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 50px; margin-bottom: 50px; }
.footer-logo img { height: 75px; background: transparent; padding: 0; border-radius: 0; margin-bottom: 20px; filter: drop-shadow(0 2px 5px rgba(255,255,255,0.2)); }
.footer-section h4 { color: var(--primary); text-transform: uppercase; margin-bottom: 25px; font-weight: 800; }
.footer-section ul { list-style: none; }
.footer-section li { margin-bottom: 12px; }
.footer-section a { color: var(--text-light); text-decoration: none; transition: var(--transition); font-weight: 600; }
.footer-section a:hover { color: var(--primary); padding-left: 5px; }
.footer-bottom { text-align: center; border-top: 1px solid #2c3e50; padding-top: 30px; color: #7f8c8d; font-size: 0.95rem; }

/* Responsive */
@media (max-width: 1024px) {
    .malla-imagenes { grid-template-columns: repeat(2, 1fr); }
    .malla-item-lg, .malla-item-h { grid-column: span 2; }
}
@media (max-width: 768px) {
    .hero-content h1 { font-size: 2.5rem; }
    header { padding: 15px; }
    nav ul { justify-content: center; gap: 15px; }
    .malla-imagenes { grid-template-columns: 1fr; }
    .malla-item-lg, .malla-item-h { grid-column: span 1; }
    .contacto-box { padding: 40px 20px; }
    .contacto-box h2 { font-size: 1.8rem !important; }
    .floating-planks, .decor-forklift { display: none; }
    .whatsapp-float { width: 55px; height: 55px; bottom: 20px; right: 20px; }
    .whatsapp-icon { width: 30px; height: 30px; }
}