/* ==========================================================================
   HEADER SUPERIOR
   ========================================================================== */
.top-header {
    background: var(--blanco-puro);
    padding: 10px 0;
    border-bottom: 3px solid var(--verde-bosque);
}

.container-header {
    width: 100%;
    max-width: 98%;
    margin: 0 auto;
    padding: 0 15px; 
    display: flex;
    align-items: center;
}

.header-flex {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: nowrap;              
    padding: 10px 0;
}

.logo-container {
    display: flex;
    align-items: center;
    gap: 15px;
}

.main-logo {
    height: 110px !important;
    width: auto;
    display: block;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    cursor: pointer;
}

.main-logo:hover {
    transform: scale(1.1) translateY(-5px);
    filter: drop-shadow(0 5px 15px rgba(218, 165, 32, 0.5));
}

.brand-name {
    display: block;
    font-weight: 800;
    color: var(--dorado-cosecha);
    font-size: 2rem;
    letter-spacing: 1px;
}

.slogan-box p {
    font-size: 1rem;
    color: var(--verde-bosque);
    font-style: italic;
    margin: 0;
    max-width: 350px;
    line-height: 1.2;
}

.contact-top {
    display: flex;
    gap: 20px;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    color: var(--texto-oscuro);
    font-weight: 600;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    padding: 8px 15px;
    border-radius: 50px;
    background: #f0f4f0; 
}

.icon-circle {
    width: 35px;
    height: 35px;
    background: var(--verde-bosque);
    color: var(--dorado-cosecha);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
}

@media (max-width: 768px) {
    .header-flex {
        flex-direction: column;
        gap: 20px;
        text-align: center;
    }
    .logo-container { flex-direction: column; }
    .contact-top { flex-direction: column; gap: 10px; }
}

/* ==========================================================================
   NAVEGACIÓN Y FOOTER
   ========================================================================== */
.main-nav {
    background: var(--verde-primario);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.main-nav ul {
    display: flex;
    list-style: none;
    justify-content: center;
}

.main-nav a {
    color: var(--blanco);
    text-decoration: none;
    padding: 15px 25px;
    display: block;
    font-weight: bold;
}

.main-footer {
    background: var(--verde-primario);
    color: var(--blanco);
    text-align: center;
    padding: 30px 0;
    margin-top: 50px;
}

/* ==========================================================================
   SECCIÓN INICIO
   ========================================================================== */
.hero {
    padding: 40px 0;
}

.hero-banner {
    position: relative;
    width: 100%;
    height: 500px; 
    border-radius: 20px;
    overflow: hidden; 
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
}

.img-inicio {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important; 
    position: absolute;
    top: 0;
    left: 0;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to right, rgba(0,0,0,0.85) 0%, rgba(0,0,0,0.4) 60%, transparent 100%);
    display: flex;
    align-items: center;
    padding: 0 50px;
    z-index: 2;
}

.hero-text-overlay {
    max-width: 600px;
    color: white;
}

.hero-text-overlay h1 {
    font-size: 3.5rem;
    margin-bottom: 20px;
    color: white !important;
    text-shadow: 2px 2px 10px rgba(0,0,0,0.5);
}

.hero-text-overlay p {
    font-size: 1.3rem;
    line-height: 1.4;
    border-left: 4px solid var(--dorado);
    padding-left: 20px;
    text-shadow: 1px 1px 5px rgba(0,0,0,0.5);
}

@keyframes brillo-pulsante {
    0% { box-shadow: 0 0 0 0 rgba(218, 165, 32, 0.7); }
    70% { box-shadow: 0 0 0 15px rgba(218, 165, 32, 0); }
    100% { box-shadow: 0 0 0 0 rgba(218, 165, 32, 0); }
}

.btn-gold {
    background-color: var(--dorado);
    color: var(--verde-primario);
    padding: 15px 35px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: bold;
    font-size: 1.1rem;
    display: inline-block;
    margin-top: 20px;
    animation: brillo-pulsante 2s infinite;
    transition: 0.3s;
}

@media (max-width: 768px) {
    .hero-banner { height: 550px; }
    .hero-overlay {
        background: linear-gradient(to top, rgba(0,0,0,0.9) 40%, rgba(0,0,0,0.2) 100%);
        align-items: flex-end;
        padding: 40px 20px;
        text-align: center;
    }
    .hero-text-overlay h1 { font-size: 2.2rem; }
    .hero-text-overlay p { font-size: 1.1rem; border-left: none; padding-left: 0; }
}


.dropdown:hover .dropdown-content { display: block; }

.dropdown-content {
    display: none;
    position: absolute;
    background-color: #ffffff;
    min-width: 240px;
    box-shadow: 0px 10px 30px rgba(0,0,0,0.15);
    z-index: 3000;
    border-radius: 12px;
}

.active-nav {
    color: #bfa34b !important;
    font-weight: bold;
    border-bottom: 2px solid #bfa34b;
}

/* ==========================================================================
   SISTEMA DE GRID Y PRODUCTOS (CORREGIDO)
   ========================================================================== */

#grid-productos {
    display: grid !important;
    /* Esto define las columnas de las tarjetas */
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)) !important; 
    gap: 30px !important;
    align-items: start !important;
    width: 100%;
}

/* Forzamos que el título rompa el grid y use todo el ancho */
.titulo-categoria-seccion {
    grid-column: 1 / -1 !important; 
    width: 100% !important;
    display: block !important;
    color: #2d572c !important;
    border-left: 5px solid #bfa34b !important;
    padding-left: 15px !important;
    margin: 40px 0 20px 0 !important;
    font-size: 2rem !important;
    text-align: left !important;
    box-sizing: border-box;
}

.card {
    display: flex !important;
    flex-direction: column !important;
    justify-content: space-between !important;
    background: white !important;
    padding: 15px !important;
    border-radius: 12px !important;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1) !important;
    height: 100% !important;
}

.btn-detalles-tecnicos {
    background: transparent;
    border: 2px solid #bfa34b;
    color: #2d572c;
    padding: 8px 15px;
    border-radius: 20px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s;
    margin-top: 15px;
}

.btn-detalles-tecnicos:hover {
    background: #bfa34b;
    color: white;
}

/* ==========================================================================
   WHATSAPP PROFESIONAL CON VENTANA DE SALUDO
   ========================================================================== */
.whatsapp-container {
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 10000;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
}

/* El botón circular */
.whatsapp-launcher {
    width: 60px;
    height: 60px;
    background-color: #25d366;
    color: white;
    border-radius: 50%;
    border: none;
    font-size: 30px;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: 0.3s;
}

/* La tarjeta/ventana de chat */
.whatsapp-card {
    width: 300px;
    background: white;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 10px 25px rgba(0,0,0,0.2);
    margin-bottom: 15px;
    display: none; /* Oculta al inicio */
    animation: slideUp 0.3s ease-out;
}

.card-header {
    background: #25d366;
    color: white;
    padding: 12px 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 13px;
}

.close-card {
    background: none;
    border: none;
    color: white;
    font-size: 20px;
    cursor: pointer;
}

.card-body {
    padding: 20px;
    background: #f0f2f5;
}

.chat-bubble {
    background: white;
    padding: 10px 15px;
    border-radius: 10px;
    font-size: 14px;
    position: relative;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.chat-bubble::before {
    content: '';
    position: absolute;
    left: -8px;
    top: 10px;
    border-top: 8px solid transparent;
    border-bottom: 8px solid transparent;
    border-right: 8px solid white;
}

.card-footer {
    padding: 10px;
    background: white;
    text-align: right;
}

.btn-open-chat {
    background: #25d366;
    color: white;
    text-decoration: none;
    padding: 8px 20px;
    border-radius: 20px;
    display: inline-block;
    font-weight: bold;
    font-size: 14px;
    transition: 0.3s;
}

.btn-open-chat:hover {
    background: #128c7e;
    color: white;
}

@keyframes slideUp {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Esto "enciende" el botón cuando lo seleccionas */
.filter-btn.active {
    background-color: #2d572c !important; /* Verde oscuro */
    color: white !important;
    border: 2px solid #daa520 !important; /* Borde dorado */
    font-weight: bold;
    transform: scale(1.05);
}

/* ==========================================================================
   SECCIÓN CONTACTO: FONDO + FORMULARIO ESTILIZADO
   ========================================================================== */

/* 1. El contenedor del fondo (Imagen + Capa Verde) */
.contacto-seccion {
    padding: 100px 5%;
    position: relative;
    background-image: url('https://images.unsplash.com/photo-1625246333195-78d9c38ad449?ixlib=rb-4.0.3&auto=format&fit=crop&w=1920&q=80');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
}

.contacto-seccion::before {
    content: "";
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(11, 61, 30, 0.75); /* Tu verde bosque con transparencia */
    z-index: 1;
}

/* 2. El contenedor blanco que flota */
.contacto-container {
    position: relative;
    z-index: 2;
    max-width: 1100px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    background: white;
    padding: 50px;
    border-radius: 30px;
    box-shadow: 0 25px 50px rgba(0,0,0,0.3);
}

/* 3. RECUPERANDO LOS ESTILOS DEL FORMULARIO */
.formulario-estilo {
    background: #fdfdfd;
    padding: 20px;
    border-radius: 15px;
}

/* Estilo de los inputs (Lo que se había perdido) */
.formulario-estilo label {
    display: block;
    margin-top: 15px;
    font-weight: 600;
    color: var(--verde-bosque);
}

.formulario-estilo input, 
.formulario-estilo select, 
.formulario-estilo textarea {
    width: 100%;
    padding: 12px 15px;
    margin-top: 8px;
    border: 2px solid #e1e1e1;
    border-radius: 12px; /* Bordes redondeados como antes */
    transition: all 0.3s ease;
    font-size: 15px;
    box-sizing: border-box; /* Evita que se salgan del contenedor */
}

/* Efecto Focus */
.formulario-estilo input:focus, 
.formulario-estilo select:focus, 
.formulario-estilo textarea:focus {
    border-color: #0B3D1E;
    outline: none;
    box-shadow: 0 0 8px rgba(11, 61, 30, 0.2);
    transform: translateY(-2px);
}

/* El botón de enviar (Recuperando el estilo verde) */
.btn-enviar-formulario {
    width: 100%;
    background: #0B3D1E;
    color: white;
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 1px;
    padding: 15px;
    border-radius: 12px;
    border: none;
    cursor: pointer;
    transition: all 0.3s;
    margin-top: 25px;
}

.btn-enviar-formulario:hover {
    background: #155e2f;
    box-shadow: 0 5px 15px rgba(11, 61, 30, 0.3);
    transform: scale(1.02);
}

/* Ajuste móvil */
@media (max-width: 768px) {
    .contacto-container {
        grid-template-columns: 1fr;
        padding: 30px 20px;
    }

/* ==========================================================================
   SECCIÓN CONTACTO: FONDO + FORMULARIO ESTILIZADO
   ========================================================================== */

/* 1. El contenedor del fondo (Imagen + Capa Verde) */
.contacto-seccion {
    padding: 100px 5%;
    position: relative;
    background-image: url('https://images.unsplash.com/photo-1625246333195-78d9c38ad449?ixlib=rb-4.0.3&auto=format&fit=crop&w=1920&q=80');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
}

.contacto-seccion::before {
    content: "";
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(11, 61, 30, 0.75); /* Tu verde bosque con transparencia */
    z-index: 1;
}

/* 2. El contenedor blanco que flota */
.contacto-container {
    position: relative;
    z-index: 2;
    max-width: 1100px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    background: white;
    padding: 50px;
    border-radius: 30px;
    box-shadow: 0 25px 50px rgba(0,0,0,0.3);
}

/* 3. RECUPERANDO LOS ESTILOS DEL FORMULARIO */
.formulario-estilo {
    background: #fdfdfd;
    padding: 20px;
    border-radius: 15px;
}

/* Estilo de los inputs (Lo que se había perdido) */
.formulario-estilo label {
    display: block;
    margin-top: 15px;
    font-weight: 600;
    color: var(--verde-bosque);
}

.formulario-estilo input, 
.formulario-estilo select, 
.formulario-estilo textarea {
    width: 100%;
    padding: 12px 15px;
    margin-top: 8px;
    border: 2px solid #e1e1e1;
    border-radius: 12px; /* Bordes redondeados como antes */
    transition: all 0.3s ease;
    font-size: 15px;
    box-sizing: border-box; /* Evita que se salgan del contenedor */
}

/* Efecto Focus */
.formulario-estilo input:focus, 
.formulario-estilo select:focus, 
.formulario-estilo textarea:focus {
    border-color: #0B3D1E;
    outline: none;
    box-shadow: 0 0 8px rgba(11, 61, 30, 0.2);
    transform: translateY(-2px);
}

/* El botón de enviar (Recuperando el estilo verde) */
.btn-enviar-formulario {
    width: 100%;
    background: #0B3D1E;
    color: white;
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 1px;
    padding: 15px;
    border-radius: 12px;
    border: none;
    cursor: pointer;
    transition: all 0.3s;
    margin-top: 25px;
}

.btn-enviar-formulario:hover {
    background: #155e2f;
    box-shadow: 0 5px 15px rgba(11, 61, 30, 0.3);
    transform: scale(1.02);
}

/* Ajuste móvil */
@media (max-width: 768px) {
    .contacto-container {
        grid-template-columns: 1fr;
        padding: 30px 20px;
    }
}
}