@import url('/CSS/responsive.css');

@font-face {
    font-family: 'Montserrat';
    src: url('../fonts/Montserrat-Regular.ttf') format('truetype');
    font-weight: 400;
    font-style: normal;
}

@font-face {
    font-family: 'Montserrat';
    src: url('../fonts/Montserrat-Bold.ttf') format('truetype');
    font-weight: 700;
    font-style: normal;
}

@font-face {
    font-family: 'Montserrat';
    src: url('../fonts/Montserrat-Light.ttf') format('truetype');
    font-weight: 300;
    font-style: normal;
}

@font-face {
    font-family: 'Montserrat';
    src: url('../fonts/Montserrat-Medium.ttf') format('truetype');
    font-weight: 500;
    font-style: normal;
}

@font-face {
    font-family: 'Montserrat';
    src: url('../fonts/Montserrat-ExtraLight.ttf') format('truetype');
    font-weight: 200;
    font-style: normal;
}

@font-face {
    font-family: 'Montserrat';
    src: url('../fonts/Montserrat-Black.ttf') format('truetype');
    font-weight: 900;
    font-style: normal;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Montserrat', sans-serif;
    overflow-x: hidden;
}

/* Header Section */
.header-section {
    position: relative;
    width: 100%;
    height: 100vh;
    overflow: hidden;
    z-index: 100;
}

.portada-img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 1;
}

/* Navigation - Con funcionalidad de esconder */
.navbar {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    padding: 5px 100px;
    border-radius: 50px;
    margin: 20px auto;
    width: fit-content;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    position: fixed;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    z-index: 1000;
    transition: all 0.3s ease;
}

.navbar.hidden {
    transform: translateX(-50%) translateY(-100px);
    opacity: 0;
}


.navbar ul {
    display: flex;
    list-style: none;
    align-items: center;
    gap: 70px;
}

.navbar li {
    position: relative;
}

.navbar a {
    text-decoration: none;
    color: #333;
    margin: 15px;
    text-align: center;
    font-weight: 500;
    padding: 10px 20px;
    border-radius: 25px;
    transition: all 0.3s ease;
    text-transform: uppercase;
    font-size: 14px;
    background: transparent;
    white-space: nowrap;
}

.navbar a:hover {
    background: rgba(231, 76, 60, 0.1);
    color: #e74c3c;
}

.navbar a:not(:hover) {
    background: transparent;
    color: #333;
}

.logo img {
    height: 60px;
    width: auto;
    display: block;
}

/* Logo como enlace */
.navbar .logo {
    padding: 0; 
    margin: 0;
    background: none !important;
    border-radius: 0;
    display: flex;
    align-items: center;
}

.navbar .logo img {
    height: 60px;
    width: auto;
    display: block;
}

/* Evita efecto hover de los links en el logo */
.navbar .logo:hover {
    background: none;
    color: inherit;
}
/* Dropdown Principal */
.dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    background: white;
    min-width: 280px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    border-radius: 10px;
    padding: 15px 0;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    z-index: 1001;
    text-align: left;
}

.navbar li.dropdown-open > .dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown a {
    display: block;
    padding: 12px 20px;
    color: #666;
    font-size: 14px;
    text-transform: uppercase;
    border-radius: 0;
    white-space: nowrap;
    margin: 0;
    position: relative;
}

.dropdown a:hover {
    background: rgba(231, 76, 60, 0.1);
    color: #e74c3c;
}

/* Dropdown secundario para BISAGRAS */
.dropdown-item {
    position: relative;
}

.subdropdown {
    position: absolute;
    top: 0;
    left: 100%;
    background: white;
    min-width: 250px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    border-radius: 10px;
    padding: 15px 0;
    opacity: 0;
    visibility: hidden;
    transform: translateX(-10px);
    transition: all 0.3s ease;
    z-index: 1002;
}

.dropdown-item.subdropdown-open > .subdropdown {
    opacity: 1;
    visibility: visible;
    transform: translateX(0);
}

.subdropdown a {
    display: block;
    padding: 10px 20px;
    color: #666;
    font-size: 13px;
    text-transform: uppercase;
    border-radius: 0;
    white-space: nowrap;
}

.subdropdown a:hover {
    background: rgba(231, 76, 60, 0.1);
    color: #e74c3c;
}

/* Main Content */
.main-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    color: white;
    z-index: 10;
    width: 90%;
    max-width: 1200px;
}

.main-text {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.main-text p {
    font-size: 1.2rem;
    margin: 0 auto;
}

.main-text h1 {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 10px;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
    text-transform: uppercase;
    color: white;
    margin: 0 auto 10px auto;
    white-space: normal;
    word-wrap: break-word;
    transition: opacity 0.2s ease;
}

/* Asegurar que elementos traducibles no causen saltos */
[data-i18n] {
    transition: opacity 0.15s ease;
}

.main-content p {
    font-size: 1.4rem;
    max-width: 700px;
    line-height: 1.3;
    color: white;
    font-weight: 400;
}

/* Flecha posicionada correctamente debajo del header */
.scroll-indicator {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
}

.flecha-img {
    width: 200vh;
    height: 80px;
    margin-bottom: -50px;
    animation: bounce 2s infinite;
    cursor: pointer;
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% { 
        transform: translateY(0); 
    }
    40% { 
        transform: translateY(-10px); 
    }
    60% { 
        transform: translateY(-5px); 
    }
}

/* Unified Product Showcase Section - Con efecto persiana funcional */
.unified-product-section {
    position: relative;
    height: 300vh; /* 3 veces la altura para el scroll */
    z-index: 10;
}

.background-images {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    z-index: 1;
}

.product-section {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    display: flex;
    opacity: 1;
    transition: none;
    z-index: 1;
    pointer-events: none;
}

.product-section.active {
    opacity: 1;
    z-index: 2;
    pointer-events: auto;
}

.split-image {
    flex: 1;
    position: relative;
    overflow: hidden;
    will-change: transform, opacity;
}

.split-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    will-change: transform;
}

/* Estado inicial de imágenes para animación */
.product-section:not(.active) .split-image.left-image {
    opacity: 0;
    transform: translateX(-100px) scale(0.9);
    transition: none;
}

.product-section:not(.active) .split-image.right-image {
    opacity: 0;
    transform: translateX(100px) scale(0.9);
    transition: none;
}

/* Imágenes visibles en sección activa */
.product-section.active .split-image.left-image,
.product-section.active .split-image.right-image {
    /* Las animaciones son manejadas por anime.js */
    transition: none;
}

.product-content-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 50%;
    height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    color: white;
    text-align: center;
    padding: 60px 40px;
    
    z-index: 5;
    box-sizing: border-box;
}

/* IMPORTANTE: Hacer visible el contenido según el estado activo */
.product-info {
    opacity: 0;
    transition: opacity 0.8s ease;
    max-width: 450px;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.product-info.active {
    opacity: 1;
}

.product-logo {
    width: 80px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 40px;
    flex-shrink: 0;
}

.product-logo img {
    width: 250px;
    height: 250px;
    object-fit: contain;
}

.product-title {
    font-size: 3rem;
    font-weight: 700;
    margin-top: 20px;
    margin-bottom: 20px;
    color: #fff;
}

.product-description {
    font-size: 1.2rem;
    line-height: 1.4;
    color: rgb(136, 136, 136);
    margin-top: 15px;
    margin-bottom: 30px;
    font-weight: 400;
}

.product-features {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
    justify-content: center;
}

.product-features .feature {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 1rem;
    color: #fff;
    font-weight: 500;
}

.product-progress {
    position: fixed;
    right: 30px;
    top: 50%;
    transform: translateY(-50%);
    z-index: 10;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
}

.progress-bar {
    width: 2px;
    height: 200px;
    background: rgba(255, 255, 255, 0.3);
    position: relative;
}

.progress-bar::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 33.333%;
    background: white;
    transition: transform 0.3s ease;
    transform: translateY(var(--progress-transform, 0%));
}

.progress-dots {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: all 0.3s ease;
}

.dot.active {
    background: white;
    transform: scale(1.2);
}

/* ================================
   SECCIÓN CATÁLOGO - COMPLETAMENTE CORREGIDA
================================ */
.catalog-header-section {
    position: relative;
    background-color: #f5f5f5;
    width: 100%;
    display: flex;
    flex-direction: column;
    z-index: 100;
    padding: 60px 0 40px 0;
    margin: 0;
}

.catalog-header {
    padding: 0;
    width: 100%;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: auto;
}

.catalog-title-section { 
    display: flex; 
    align-items: center; 
    justify-content: flex-start;
    position: relative;
    flex: 0 0 auto;
    height: 100px;
}

.catalog-arrow {
    position: absolute;
    left: -78px;
    top: -70px;
    z-index: 2;
    width: 180px;
    height: 220px;
}

.catalog-arrow img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
}

.catalog-title-link {
    position: relative;
    display: inline-block;
    text-decoration: none;
    margin-left: 100px;
    margin-top: -30px;
}

.catalog-title-link:hover .catalog-title {
    color: #1e3a8a;
}

.catalog-tooltip {
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    background-color: #1e3a8a;
    color: white;
    padding: 8px 16px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s, visibility 0.3s;
    margin-bottom: 10px;
}

.catalog-tooltip::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 8px solid transparent;
    border-top-color: #1e3a8a;
}

.catalog-title-link:hover .catalog-tooltip {
    opacity: 1;
    visibility: visible;
}

.catalog-title {
    font-size: 3rem;
    font-weight: 700;
    text-transform: uppercase;
    color: #333;
    text-shadow: none;
    margin: 0;
    z-index: 1;
    transition: color 0.3s;
}

.catalog-description-section { 
    max-width: 500px; 
    text-align: right;
    padding-right: 40px;
    margin-top: 0;
    align-self: center;
}

.catalog-description {
    font-size: 1rem;
    line-height: 1.3;
    color: #666;
    text-shadow: none;
    margin: 0;
}

.catalog-download-btn { 
    display: inline-flex;
    align-items: center;
    gap: 8px;
    text-decoration: none; 
    color: #fff; 
    background: #003399; 
    padding: 12px 24px; 
    border-radius: 25px; 
    font-weight: 500; 
    transition: all 0.3s ease; 
}

.catalog-download-btn:hover { 
    background: #002080; 
    transform: translateY(-2px);
}

/* CAROUSEL CONTAINER */
.catalog-carousel {
    position: relative;
    width: 100%;
    flex: 1;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    margin-top: 20px;
    min-height: 100vh;
    height: 100vh;
}

/* NAVIGATION ARROWS */
.carousel-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 51, 153, 0.8);
    color: white;
    border: none;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 100;
    font-size: 18px;
}

.carousel-nav:hover {
    background: #003399;
    transform: translateY(-50%) scale(1.1);
}

.prev-btn {
    left: 20px;
}

.next-btn {
    right: 20px;
}

/* CAROUSEL TRACK */
.catalog-track {
    display: flex;
    width: auto;
    height: 100vh;
    min-height: 100vh;
    transition: transform 0.5s ease-in-out;
}

/* CATALOG ITEMS */
.catalog-item {
    position: relative;
    cursor: pointer;
    transition: all 0.3s ease;
    flex: 0 0 auto;
    width: 370px;
    min-width: 370px;
    max-width: 370px;
    height: 100vh;
    min-height: 100vh;
    overflow: hidden;
    background: #f8f9fa;
    text-decoration: none;
    display: block;
    color: inherit;
}

.catalog-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: all 0.3s ease;
}

/* OVERLAY - OCULTO POR DEFECTO */
.catalog-overlay {
    position: absolute;
    bottom: -100%; /* oculto */
    left: 0;
    width: 100%;
    background: rgba(0, 51, 153, 0.9);
    color: #fff;
    text-align: center;
    padding: 15px;
    font-weight: 600;
    font-size: 1rem;
    text-transform: uppercase;
    transition: bottom 0.3s ease;
}

.catalog-overlay-text {
    font-weight: 700;
    text-align: center;
    font-size: 1rem;
    text-transform: uppercase;
    line-height: 1.2;
    padding: 20px;
}

/* EFECTO HOVER */
.catalog-item:hover {
    border: 15px solid #003399;
    transform: scale(1);
    z-index: 30;
}

.catalog-item:hover img {
    transform: translateY(-20px);
    height: 110%;
}

.catalog-item:hover .catalog-overlay {
    bottom: 0;
}

.catalogo-item::after {
  content: "";
  position: absolute;
  inset: 0;
  border: 10px solid #003399;
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none; /* no bloquea el hover */
}

/* INDICATORS */
.carousel-indicators {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
    z-index: 100;
}

.indicator {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: all 0.3s ease;
}

.indicator.active {
    background: #003399;
    transform: scale(1.2);
}

.indicator:hover {
    background: rgba(0, 51, 153, 0.8);
}

/* ========================================
   PRODUCTOS SIMILARES (Carrusel del Index)
   ======================================== */
.productos-similares {
    width: 100%;
    padding: 60px 0 0 0;
    margin: 0;
    background: white;
    display: flex;
    flex-direction: column;
    height: 100vh;
    position: relative;
    z-index: 100;
}

.productos-similares.productos-index {
    padding: 0;
    height: 75vh;
}

.similares-titulo {
    font-size: 36px;
    font-weight: 900;
    color: #1e3a8a;
    text-align: center;
    margin: 0 0 20px 0;
    padding: 0 60px;
    flex-shrink: 0;
}

.productos-similares .catalog-carousel {
    margin-top: 0;
    padding-top: 0;
    flex: 1;
    height: auto;
    min-height: auto;
    overflow: visible;
    position: relative;
    z-index: 101;
}

.productos-similares .catalog-track {
    height: 100%;
    min-height: 100%;
    width: auto;
    display: flex;
}

.productos-similares .catalog-item {
    height: 100%;
    min-height: 100%;
    flex-shrink: 0;
    width: 370px;
    min-width: 370px;
    max-width: 370px;
    overflow: hidden;
    background: #f8f9fa;
}

.productos-similares .catalog-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.productos-similares .carousel-nav {
    z-index: 200;
}

/* Footer */
.footer-red {
    background: #e74c3c;
    color: #fff;
    text-align: center;
    padding: 15px 0;
    font-weight: 500;
    font-size: 0.9rem;
    position: relative;
    z-index: 101;
    margin: 0;
    margin-top: 0 !important;
    flex-shrink: 0;
}

/* Eliminar padding/margin en desktop para secciones antes del footer */
@media (min-width: 1201px) {
    .catalog-section {
        margin-bottom: 0 !important;
        padding-bottom: 0 !important;
    }

    .calidad-section {
        margin-bottom: 0 !important;
        padding-bottom: 40px !important;
    }

    /* Asegurar que no haya espacio después de la última sección */
    body > section:last-of-type {
        margin-bottom: 0 !important;
        padding-bottom: 0 !important;
    }

    /* Footer pegado */
    .footer-red {
        margin-top: 0 !important;
        padding-top: 15px !important;
    }
}

/* Contenedor de hexágonos */
.footer-hexagons {
    position: absolute;
    bottom: 15px;
    left: 40px;
    display: flex;
    gap: 8px; /* separación entre hexágonos */
    z-index: 3;
}

/* Hexágonos más chicos */
.hexagon {
    width: 30px;
    height: 25px;
    position: relative;
    cursor: pointer;
    transition: transform 0.3s ease;
    text-decoration: none;
    display: block;
}

.hexagon img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    clip-path: polygon(
        25% 0%,
        75% 0%,
        100% 50%,
        75% 100%,
        25% 100%,
        0% 50%
    );
}

/* Hover */
.hexagon:hover {
    transform: scale(1.1);
}

/* ====== Responsive ====== */
@media(max-width: 1200px) {
    .catalog-item {
        min-height: 200px;
    }
    
    .catalog-overlay-text {
        font-size: 0.9rem;
        padding: 15px;
    }
}

@media(max-width: 1024px) { 
    .catalog-title {
        font-size: 2.2rem;
    }
    
    .catalog-header {
        padding: 40px 0 30px 0;
    }
    
    .carousel-nav {
        width: 45px;
        height: 45px;
        font-size: 16px;
    }
}

@media(max-width: 768px) {
    .catalog-section {
        min-height: auto;
    }
    
    .catalog-container {
        height: auto;
    }
    
    .catalog-header {
        padding: 40px 15px 30px 15px;
    }
    
    .catalog-title { 
        font-size: 2rem; 
    }
    
    .catalog-description { 
        font-size: 1rem; 
    }
    
    .catalog-slide {
        flex-wrap: wrap;
        align-content: flex-start;
    }
    
    .catalog-item {
        flex: 0 0 50%;
        height: 150px;
    }
    
    .carousel-nav {
        width: 40px;
        height: 40px;
        font-size: 14px;
    }
    
    .prev-btn {
        left: 10px;
    }
    
    .next-btn {
        right: 10px;
    }
}

@media(max-width: 480px) {
    .catalog-item {
        flex: 0 0 100%;
        height: 120px;
    }
    
    .catalog-download-btn { 
        padding: 10px 18px; 
        font-size: 0.9rem; 
    }
    
    .catalog-title { 
        font-size: 1.7rem; 
    }
    
    .catalog-title-section {
        flex-direction: column;
        gap: 10px;
    }
    
    .catalog-overlay-text {
        font-size: 0.8rem;
        padding: 10px;
    }
}

/* ============================================
   CALIDAD SECTION
   ============================================ */

.calidad-section {
    position: relative;
    background: linear-gradient(135deg, #003399 0%, #0044bb 100%);
    width: 100%;
    min-height: 50vh;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 50;
    padding: 60px 40px;
    overflow: hidden;
}

.calidad-container {
    max-width: 1400px;
    width: 100%;
    margin: 0 auto;
    overflow: hidden;
}

.calidad-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 80px;
    width: 100%;
    max-width: 100%;
}

.calidad-text {
    flex: 1;
    max-width: 700px;
    z-index: 2;
}

.calidad-title {
    font-family: 'Montserrat', sans-serif;
    font-size: 4rem;
    font-weight: 700;
    text-transform: uppercase;
    color: #ffffff;
    margin-bottom: 30px;
    letter-spacing: 2px;
}

.calidad-description {
    font-family: 'Montserrat', sans-serif;
    font-size: 1.3rem;
    line-height: 1.5;
    color: rgba(255, 255, 255, 0.9);
    font-weight: 300;
}

.calidad-icon {
    flex: 0 0 auto;
    max-width: 300px;
    opacity: 0.3;
    z-index: 1;
    flex-shrink: 0;
    overflow: hidden;
}

.calidad-icon img {
    width: 100%;
    height: auto;
    max-width: 100%;
    object-fit: contain;
    filter: brightness(0) invert(1);
    display: block;
}

/* Responsive */
@media(max-width: 1200px) {
    .calidad-content {
        gap: 50px;
    }

    .calidad-title {
        font-size: 3rem;
    }

    .calidad-description {
        font-size: 1.1rem;
    }

    .calidad-icon {
        max-width: 350px;
    }
}

@media(max-width: 768px) {
    .calidad-section {
        padding: 60px 20px;
    }

    .calidad-content {
        flex-direction: column;
        gap: 40px;
        text-align: center;
    }

    .calidad-title {
        font-size: 2.5rem;
    }

    .calidad-description {
        font-size: 1rem;
    }

    .calidad-icon {
        max-width: 250px;
        opacity: 0.2;
    }
}