body {
    font-family: Arial, sans-serif;
    margin: 0;
    padding: 0;
    color: #333;
    background-color: white;
}


header {
    background: url('nave.jpg') no-repeat center center;
    background-size: contain; background-repeat: no-repeat; background-position: center top;
    color: black;
    text-align: center;
    padding: 20px;
    position: relative;
    height: 300px;
}

.main-title {
    font-size: 2.5em;
    font-weight: bold;
    color: black;
    position: absolute;
    top: 10px;
    width: 100%;
    text-align: center;
    margin: 0;
}

.sub-title {
    font-size: 1.8em;
    color: black;
    position: absolute;
    top: 60px;
    width: 100%;
    text-align: center;
    margin: 0;
}

nav {
    position: absolute;
    bottom: 10px;
    width: 100%;
    text-align: center;
}

nav ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

nav ul li {
    display: inline;
    margin: 0 15px;
}

nav ul li a {
    color: black;
    text-decoration: none;
    font-weight: bold;
}

    background: url('nave.jpg') no-repeat center center;
    background-size: contain; background-repeat: no-repeat; background-position: center top;
    color: black;
    text-align: center;
    padding: 80px 20px;
    position: relative;
}

.main-title {
    font-size: 2.5em;
    font-weight: bold;
    margin: 10px 0;
    color: black;
    text-align: center;
}

.sub-title {
    font-size: 1.8em;
    margin-bottom: 20px;
    color: black;
    text-align: center;
}

    background: none;
    text-align: left;
    color: black;
    padding: 20px;
    position: relative;
}

.main-title {
    font-size: 2.5em;
    font-weight: bold;
    margin: 10px 0;
    color: black;
}

.sub-title {
    font-size: 1.8em;
    margin-bottom: 20px;
    color: black;
}

    background: url('nave.jpg') no-repeat center center;
    background-size: contain; background-repeat: no-repeat; background-position: center top;
    color: white;
    text-align: center;
    padding: 50px 0;
}

    background-color: #9bcf00;
    color: white;
    text-align: center;
    padding: 15px 0;
}

.main-title {
    font-size: 2.5em;
    font-weight: bold;
    text-align: center;
    margin: 10px 0;
}

.sub-title {
    font-size: 1.8em;
    text-align: center;
    margin-bottom: 20px;
}

nav ul {
    list-style: none;
    padding: 0;
}

nav ul li {
    display: inline;
    margin: 0 15px;
}

nav ul li a {
    color: white;
    text-decoration: none;
}

#hero {
    background: #9bcf00;
    text-align: center;
    color: white;
    padding: 60px 20px;
}

#hero h2 {
    font-size: 2em;
}

section {
    padding: 40px 20px;
    text-align: center;
}

.productos-container {
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
}

.producto {
    border: 1px solid #ddd;
    padding: 20px;
    width: 250px;
    text-align: center;
}

.producto img {
    width: 100%;
    height: auto;
}

.contact-container {
    display: flex;
    justify-content: space-around;
    flex-wrap: wrap;
    gap: 20px;
    padding: 20px;
}

.contact-section {
    border: 1px solid #ddd;
    padding: 15px;
    width: 45%;
    background-color: #f9f9f9;
}

.comercializadora-section {
    border: 1px solid #ddd;
    padding: 15px;
    width: 45%;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.comercializadora-text {
    width: 50%;
    padding: 15px;
    text-align: left;
}

.comercializadora-text h3, 
.comercializadora-text p, 
.comercializadora-text a {
    color: black;
    text-align: left;
}

.comercializadora-image {
    width: 50%;
    text-align: right;
}

.comercializadora-image img {
    width: 100%;
    height: auto;
}

form {
    display: flex;
    flex-direction: column;
    width: 60%;
    margin: auto;
}

form label, form input, form textarea, form button {
    margin-bottom: 15px;
}

form input, form textarea {
    padding: 10px;
    border: 1px solid #ddd;
    width: 100%;
}

form button {
    padding: 10px;
    background-color: #9bcf00;
    color: white;
    border: none;
    cursor: pointer;
}

.centered-image {
    display: block;
    margin: 20px auto;
    max-width: 80%;
}

footer {
    text-align: center;
    background-color: #ffffff;
    color: #333;
    padding: 15px;
}


.nave-image {
    display: block;
    max-width: 100%;
    height: auto;
    margin: 20px auto;
    border-radius: 8px;
}


.producto.pistachos {
    background: url('pistacho.jpg') no-repeat center center;
    background-size: contain; background-repeat: no-repeat; background-position: center top;
    color: white;
    padding: 20px;
    border-radius: 8px;
}


.producto.almendras {
    background: url('almendra.jpg') no-repeat center center;
    background-size: contain; background-repeat: no-repeat; background-position: center top;
    color: white;
    padding: 20px;
    border-radius: 8px;
}

.producto.pistachos h3, .producto.almendras h3 {
    display: none;
}

header {
    background: url('nave.jpg') no-repeat center center;
    background-size: contain; background-repeat: no-repeat; background-position: center top;
    background-attachment: fixed;
    color: black;
    text-align: center;
    padding: 20px;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
}

body {
    margin-top: 320px; /* Ajusta según la altura del encabezado */
}

nav ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

nav ul li {
    display: inline;
    margin: 0 15px;
}

nav ul li a {
    color: black;
    text-decoration: none;
    font-weight: bold;
}

@media only screen and (max-width: 768px) {
    body {
        margin-top: 220px;
    }
    header {
        padding: 15px;
        background-size: cover;
        background-position: center;
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        z-index: 1000;
    }
    .main-title {
        font-size: 1.6em;
    }
    .sub-title {
        font-size: 1.0em;
    }
    nav ul {
        display: flex;
        flex-direction: column;
        padding: 0;
        margin: 0;
    }
    nav ul li {
        display: block;
        margin: 5px 0;
    }
    .productos-container, .contact-container {
        flex-direction: column;
        align-items: center;
    }
    .producto, .contact-section, .comercializadora-section {
        width: 90%;
        margin-bottom: 20px;
    }
    form {
        width: 100%;
        padding: 0 15px;
    }
    .main-title {
        font-size: 2em;
        margin-top: 5px;
    }
    .sub-title {
        font-size: 1.2em;
    }
}

#hero {
    background: #9bcf00;
    text-align: center;
    color: white;
    padding: 20px 10px;
    position: fixed;
    top: 220px; /* Altura del encabezado fijo */
    left: 0;
    width: 100%;
    z-index: 999;
}

#hero nav ul {
    padding: 0;
    margin: 15px 0;
}

#hero nav ul li {
    display: inline-block;
    margin: 0 10px;
}

#hero {
    background: #9bcf00;
    color: white;
    padding: 80px 20px 40px; /* Mayor padding para evitar superposición */
    position: fixed;
    top: 220px;
    left: 0;
    width: 100%;
    z-index: 999;
}

.producto h3 {
    display: none !important; /* Oculta nombres de las imágenes (pistacho y almendra) */
}

body {
    margin-top: 450px; /* Ajuste mayor para compensar el nuevo tamaño del hero y header */
}

.producto.pistachos, .producto.almendras {
    background-size: cover;
    background-position: center;
    height: 250px;
    border-radius: 8px;
}

.productos-container {
    display: flex;
    justify-content: center;
    gap: 20px;
}

.producto {
    padding: 0;
    overflow: hidden;
}

.producto.pistachos {
    background-image: url('pistacho.jpg');
}

.producto.almendras {
    background-image: url('almendra.jpg');
}

section {
    scroll-margin-top: 450px; /* Ajusta a altura real de header + hero para alineación correcta */
}

@media only screen and (max-width: 768px) {
    body {
        margin-top: 220px;
        overflow-x: hidden;
    }
    header, #hero {
        width: 100%;
        padding: 10px;
        box-sizing: border-box;
    }
    .main-title, .sub-title {
        font-size: 1.3em;
        text-align: center;
    }
    nav ul {
        flex-direction: column;
        align-items: center;
        gap: 10px;
        padding: 0;
        margin: 0;
    }
    nav ul li {
        display: block;
        margin: 5px 0;
    }
    #hero {
        padding: 20px;
    }
    .productos-container, .contact-container {
        flex-direction: column;
        align-items: center;
        gap: 15px;
    }
    .producto, .contact-section, .comercializadora-section {
        width: 90%;
        height: auto;
        margin: 15px auto;
    }
    form {
        width: 100%;
        padding: 10px;
    }
    img {
        max-width: 100%;
        height: auto;
    }
    section {
        scroll-margin-top: 250px;
    }
}