/* RESET Y CONFIGURACIÓN BASE COMPLETAMENTE RESPONSIVE */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    background-image: url(img/Fondo_bac.avif);
    color: #333;
    line-height: 1.6;
    overflow-x: hidden;
    font-size: clamp(14px, 2vw, 16px);
}

/* HEADER COMO BANNER CON ESTRUCTURA ORIGINAL */
header {
    position: relative;
    width: 100%;
    height: auto;
    min-height: auto;
}

.header-banner {
    position: relative;
    width: 100%;
}

.banner-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.banner-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* Navegación sobre el banner */
.nav-overlay {
    position: relative;
    z-index: 100;
    background-color: transparent;
    box-shadow: 0 3px 8px #eebe2f;
    padding: 1rem 0;
}

.nav-container {
    width: 95%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    min-height: 80px;
}

.top-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    gap: 1rem;
}

.logo1 {
    width: clamp(120px, 15vw, 190px);
    height: auto;
    display: block;
}

/* Botón menú hamburguesa */
.menu-toggle {
    display: none;
    background: none;
    border: none;
    color: white;
    font-size: 1.8rem;
    cursor: pointer;
    padding: 0.5rem;
    transition: all 0.3s ease;
    z-index: 1001;
}

.menu-toggle:hover {
    color: #eebe2f;
}

.menu-toggle.active i {
    color: #eebe2f;
}

/* NAVEGACIÓN PRINCIPAL - ESCRITORIO */
nav {
    display: flex;
    align-items: center;
    height: 100%;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: clamp(0.5rem, 2vw, 2rem);
    justify-content: center;
    align-items: center;
    margin: 0;
    padding: 0;
    height: 100%;
}

nav li {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
}

nav a {
    color: white;
    text-decoration: none;
    font-weight: 600;
    font-size: clamp(12px, 1.5vw, 15px);
    padding: 0.5rem 0.8rem;
    border-radius: 4px;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    height: 100%;
    min-height: 40px;
}

nav a:hover {
    background-color: rgba(255, 255, 255, 0.2);
    color: #eebe2f;
}

nav a h2 {
    margin: 0;
    padding: 0;
    font-size: clamp(12px, 1.5vw, 20px);
    line-height: 1.2;
    display: flex;
    align-items: center;
}

.selec_ini {
    color: #eebe2f;
    text-decoration: underline;
}

/* Contenedor principal que mantiene la estructura original */
.content-wrapper {
    position: relative;
    z-index: 2;
    background-color: rgba(255, 255, 255, 0);
}

.main-content {
    position: relative;
    z-index: 3;
}

/* TÍTULO EN POSICIÓN ORIGINAL */
.titutloF {
    margin: -2rem 0 2rem;
    color: #004AAD;
    text-align: center;
    padding: 8% 1rem 0;
    font-size: clamp(1.2rem, 3vw, 1.5rem);
    position: relative;
    z-index: 4;
    text-shadow: 1px 1px 3px rgba(255, 255, 255, 0.8);
    animation: entrada 0.8s ease;
}

.titutloF h1 {
    font-size: clamp(1.8rem, 5vw, 2.5rem);
    margin-bottom: 0.5rem;
}

.titutloF h2 {
    font-size: clamp(1.2rem, 3vw, 1.5rem);
    margin-top: -0.5rem;
    color: #333;
    text-shadow: 1px 1px 2px rgba(255, 255, 255, 0.8);
}

.dibujo-icopor {
    text-align: center;
    margin-top: 1rem;
}

.dibujo-icopor img {
    width: min(350px, 80%);
    height: auto;
}

/* PRODUCTOS EN INICIO */
.products {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    margin: 2rem auto 3rem;
    padding: 0 1rem;
    max-width: 1200px;
}

.caseton-icopor1, 
.caseton-guadua1, 
.caseton-lona1 {
    background-size: cover;
    background-position: center;
    border-radius: 10px;
    width: 100%;
    aspect-ratio: 4/3;
    position: relative;
    overflow: hidden;
    transition: transform 0.3s ease;
    box-shadow: 0 5px 20px rgb(0, 0, 0);
    animation: entrada 0.8s ease;
}

.caseton-icopor1 {
    background-image: url('img/ICOPORINICIO.jpeg');
}

.caseton-guadua1 {
    background-image: url('img/GUADUAINICIO.png');
}

.caseton-lona1 {
    background-image: url('img/LONAINICIO.jpeg');
}

.product-title-ci, 
.product-title-cg, 
.product-title-cl {
    position: absolute;
    bottom: 1rem;
    left: 50%;
    transform: translateX(-50%);
    background-color: rgba(0, 74, 173, 0.9);
    color: white;
    padding: 1rem;
    border-radius: 10px;
    font-size: clamp(1rem, 2vw, 1.2rem);
    font-weight: bold;
    text-align: center;
    width: 90%;
    max-width: 200px;
}

.caseton-icopor1:hover, 
.caseton-guadua1:hover, 
.caseton-lona1:hover {
    transform: translateY(-10px);
}

/* BOTÓN MÁS PRODUCTOS */
.mas-productos-container {
    display: flex;
    justify-content: center;
    margin: 2rem 1rem 3rem;
    padding: 1rem;
}

.mas-productos {
    background-color: #004AAD;
    color: white;
    padding: 1rem 2rem;
    text-decoration: none;
    border-radius: 40px;
    text-align: center;
    transition: all 0.3s ease;
    max-width: 400px;
    width: 100%;
    font-weight: bold;
    font-size: clamp(0.9rem, 3vw, 1rem);
    animation: entrada 0.8s ease;
}

.mas-productos:hover {
    background: linear-gradient(#0026ff, #002952);
    color: #eebe2f;
    transform: translateY(-3px);
}

/* SECCIÓN VENTAJAS */
.ventajas-titulo {
    color: #004AAD;
    text-align: center;
    padding: 1rem;
    margin: 2rem 0 1rem;
}

.ventajas-titulo h1 {
    font-size: clamp(1.5rem, 4vw, 2.3rem);
}

.ventajas-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    padding: 0 1rem 3rem;
    max-width: 1200px;
    margin: 0 auto;
}

.ventaja1, .ventaja2, .ventaja3, .ventaja4, .ventaja5 {
    font-size: 18px;
    font-weight: 400;
    background: white;
    color: #004AAD;
    border-radius: 12px;
    padding: 2rem 1.5rem;
    text-align: center;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.26);
    transition: transform 0.3s ease;
    border: 2px solid #004AAD;
}

.ventaja1:hover, .ventaja2:hover, .ventaja3:hover, .ventaja4:hover, .ventaja5:hover {
    transform: translateY(-5px);
    border-color: #eebe2f;
    color: #eebe2f;
}

.ventaja1 h2, .ventaja2 h2, .ventaja3 h2, .ventaja4 h2, .ventaja5 h2 {
    font-size: clamp(1.1rem, 2.5vw, 1.5rem);
    margin-bottom: 1rem;
}

/* SECCIÓN DE PROCESOS */
.proceso-titulo {
    text-align: center;
    color: #004AAD;
    font-size: clamp(1.5rem, 4vw, 2rem);
    margin: 3rem 1rem 2rem;
}

.proceso-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin: 0 auto 4rem;
    padding: 0 1rem;
    max-width: 1200px;
}

.proceso-item {
    background: white;
    color: #004AAD;
    border-radius: 12px;
    padding: 2rem 1.5rem;
    text-align: center;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.26);
    transition: transform 0.3s ease;
    border: 2px solid #004AAD;
}

.proceso-item:hover {
    transform: translateY(-5px);
    border-color: #eebe2f;
    color: #eebe2f;
}

.proceso-icono {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.proceso-item h3 {
    font-size: clamp(1.1rem, 2vw, 1.3rem);
    margin-bottom: 0.8rem;
}

/* FORMULARIO */
form {
    background-color: #eeeeee;
    padding: 2rem 1.5rem;
    border-radius: 1.5rem;
    border: 2px solid #0084ff;
    margin: 3rem auto;
    max-width: 700px;
    width: calc(100% - 2rem);
    transition: transform 0.5s ease;
    animation: entrada 0.8s ease;
}

form h1 {
    text-align: center;
    color: #004AAD;
    margin-bottom: 1.5rem;
    font-size: clamp(1.3rem, 3vw, 1.8rem);
}

.form-group {
    margin-bottom: 1.5rem;
}

form input, form textarea {
    padding: 1rem;
    width: 100%;
    border: 1px solid #ccc;
    border-radius: 8px;
    font-size: clamp(0.9rem, 2vw, 1rem);
    transition: border-color 0.3s ease;
}

form textarea {
    min-height: 120px;
    resize: vertical;
    font-family: inherit;
}

form input:focus, form textarea:focus {
    outline: none;
    border-color: #004AAD;
}

.boton {
    text-align: center;
    margin-top: 1.5rem;
}

button {
    padding: 1rem 2.5rem;
    background-color: #004AAD;
    color: white;
    border-radius: 5px;
    border: none;
    font-size: clamp(0.9rem, 2vw, 1rem);
    cursor: pointer;
    transition: all 0.3s ease;
}

button:hover {
    background: linear-gradient(#0026ff, #002952);
    color: #eebe2f;
    transform: translateY(-3px);
}

/* FOOTER */
footer {
    background-color: #004AAD;
    box-shadow: 0 -3px 8px rgba(0, 195, 255, 0.877);
    color: #eebe2f;
    padding: 3rem 0;
    margin-top: 4rem;
    width: 100%;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    padding: 0 1rem;
}

.footer-section {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.logo2 {
    width: clamp(150px, 20vw, 190px);
    height: auto;
    margin-bottom: 1rem;
}

.footer-section h3 {
    margin-bottom: 1rem;
    font-size: clamp(1.2rem, 2vw, 1.5rem);
    border-bottom: 2px solid #eebe2f;
    padding-bottom: 0.5rem;
    width: 100%;
}

.footer-section h4 {
    margin-bottom: 0.5rem;
    font-weight: normal;
    font-size: clamp(0.9rem, 1.8vw, 1rem);
}

.eslogan-footer h4 {
    color: white;
}

/* BOTÓN WHATSAPP */
.btn-wasa {
    position: fixed;
    bottom: 1.5rem;
    right: 1.5rem;
    width: clamp(50px, 10vw, 60px);
    height: clamp(50px, 10vw, 60px);
    background-color: #25D366;
    border-radius: 50%;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    color: white;
    font-size: clamp(1.5rem, 3vw, 2rem);
    transition: all 0.3s ease;
}

.btn-wasa:hover {
    background-color: #128C7E;
    transform: scale(1.1);
}

/* ANIMACIONES */
@keyframes entrada {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ========== MEDIA QUERIES ========== */

/* Tablets y móviles grandes */
@media (max-width: 768px) {
    .menu-toggle {
        display: block;
    }
    
    nav {
        position: fixed;
        top: 0;
        right: -100%;
        width: 80%;
        max-width: 300px;
        height: 100vh;
        background-color: #004AAD;
        transition: right 0.3s ease-in-out;
        z-index: 1000;
        padding: 80px 1rem 2rem;
        box-shadow: -5px 0 15px rgba(0, 0, 0, 0.3);
        display: flex;
        flex-direction: column;
        justify-content: flex-start;
        align-items: stretch;
    }
    
    nav.active {
        right: 0;
    }
    
    nav.active::before {
        content: '';
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background-color: rgba(0, 0, 0, 0.5);
        z-index: -1;
    }
    
    .nav-menu {
        flex-direction: column;
        gap: 0.5rem;
        width: 100%;
    }
    
    nav li {
        width: 100%;
        margin-bottom: 0.5rem;
    }
    
    nav a {
        width: 100%;
        padding: 1rem 1.5rem;
        text-align: left;
        justify-content: flex-start;
        border-radius: 8px;
        background-color: rgba(255, 255, 255, 0.1);
        min-height: 50px;
    }
    
    nav a h2 {
        font-size: 1.1rem;
    }
    
    .top-bar {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
    }
    
    .logo1 {
        width: clamp(100px, 20vw, 150px);
    }
    
    .titutloF {
        padding-top: 15%;
    }
    
    .btn-wasa {
        width: 70px;
        height: 70px;
        bottom: 2rem;
        right: 2rem;
        font-size: 2.5rem;
    }
}

/* Móviles pequeños */
@media (max-width: 480px) {
    body {
        font-size: 14px;
    }
    
    .products {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .ventajas-grid,
    .proceso-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .ventaja1, .ventaja2, .ventaja3, .ventaja4, .ventaja5,
    .proceso-item {
        padding: 1.5rem 1rem;
    }
    
    .footer-container {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .logo2 {
        width: 160px;
    }
    
    .btn-wasa {
        width: 60px;
        height: 60px;
        bottom: 1.5rem;
        right: 1.5rem;
        font-size: 2rem;
    }
    
    form {
        padding: 1.5rem 1rem;
    }
}

/* Pantallas muy grandes */
@media (min-width: 1200px) {
    .container,
    .nav-container,
    .products,
    .ventajas-grid,
    .proceso-grid,
    .footer-container {
        max-width: 1200px;
        margin-left: auto;
        margin-right: auto;
    }
    
    .products {
        grid-template-columns: repeat(3, 1fr);
    }
}