/* Font Face */
@font-face {
    font-family: 'Croogs';
    src: url('fonts/Croogs.otf') format('opentype'),
        url('fonts/Croogs.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
}

/* Variables */
:root {
    --primary-orange: #F58220;
    --primary-green: #1B4D26;
    /* Dark green from footer/buttons */
    --secondary-green: #2E7D32;
    /* Lighter green for some elements if needed */
    --text-dark: #333;
    --text-light: #fff;
    --bg-light: #f9f9f9;
    --font-heading: 'Croogs', sans-serif;
    --font-body: 'Outfit', sans-serif;
}

/* Reset & Base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-body);
    color: var(--text-dark);
    line-height: 1.6;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
}

a {
    text-decoration: none;
    color: inherit;
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

/* Typography */
h1,
h2,
h3 {
    font-family: var(--font-heading);
    text-transform: uppercase;
    letter-spacing: 0.02em;
}

.section-title-large {
    font-size: 3rem;
    color: var(--primary-orange);
    line-height: 1;
    margin-bottom: 20px;
}

.section-title-white {
    font-size: 2.5rem;
    color: var(--text-light);
    margin-bottom: 30px;
}

.section-title-orange {
    font-size: 2.5rem;
    color: var(--primary-orange);
    margin-bottom: 30px;
}

.section-title-green {
    font-size: 2.5rem;
    color: var(--primary-green);
    margin-bottom: 30px;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 12px 30px;
    border-radius: 50px;
    font-weight: 600;
    transition: all 0.3s ease;
    cursor: pointer;
    border: none;
    font-family: var(--font-body);
}

.btn-primary {
    background-color: var(--primary-green);
    color: var(--text-light);
    font-size: 1.2rem;
}

.btn-primary:hover {
    background-color: #143a1c;
    transform: translateY(-2px);
}

.btn-dark {
    background-color: var(--primary-green);
    color: var(--text-light);
    padding: 10px 40px;
    font-size: 1rem;
}

.btn-dark:hover {
    background-color: #143a1c;
}

/* Header */
.header {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 100;
    padding: 20px 0;
    background: linear-gradient(to bottom, rgba(0, 0, 0, 0.5), transparent);
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo img {
    height: 60px;
}

.nav-menu ul {
    display: flex;
    gap: 35px;
    align-items: center;
}

.nav-menu a {
    color: var(--text-light);
    font-weight: 600;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
    transition: all 0.3s ease;
}

.nav-menu a:hover {
    color: var(--primary-orange);
}

.lang-toggle {
    border: 2px solid var(--text-light);
    padding: 5px 12px;
    border-radius: 20px;
    font-weight: 600;
}

.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
}

.mobile-menu-btn span {
    display: block;
    width: 25px;
    height: 3px;
    background-color: var(--text-light);
    margin: 5px 0;
    transition: all 0.3s ease;
}

/* Hero Section */
.hero {
    position: relative;
    height: 100vh;
    min-height: 600px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
}

.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
}

.hero-bg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hero-content h1 {
    color: var(--text-light);
    font-size: 4rem;
    margin-bottom: 35px;
    font-family: var(--font-body);
    font-weight: 800;
    line-height: 1.1;
    letter-spacing: -0.02em;
    filter: drop-shadow(0 4px 15px rgba(0, 0, 0, 0.4));
}

/* About Section */
.about {
    padding: 100px 0;
    background-color: #fff;
}

.about-header {
    display: flex;
    align-items: center;
    gap: 60px;
    margin-bottom: 80px;
}

.about-text {
    font-size: 1.05rem;
    color: #555;
    max-width: 600px;
    line-height: 1.8;
    text-align: justify;
}

.mission-vision {
    display: flex;
    justify-content: center;
    gap: 100px;
    text-align: center;
}

.mv-item {
    flex: 1;
    max-width: 400px;
}

.mv-image {
    width: 220px;
    height: 220px;
    border-radius: 50%;
    overflow: hidden;
    margin: 0 auto 25px;
    border: 6px solid var(--primary-orange);
}

.mv-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.mv-item h3 {
    color: var(--primary-orange);
    font-size: 2.2rem;
    margin-bottom: 20px;
}

.mv-item p {
    color: #555;
    line-height: 1.7;
    text-align: justify;
}

/* Values Section */
.values {
    background-color: var(--primary-orange);
    padding: 70px 0;
    text-align: center;
}

.values-grid {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 60px;
    max-width: 1200px;
    margin: 0 auto;
}

.value-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    color: var(--text-light);
    width: 200px;
}

.value-icon-wrapper {
    width: 150px;
    height: 150px;
    background-color: #fff;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 25px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease;
}

.value-icon-wrapper i {
    font-size: 40px;
    color: var(--primary-orange);
}

.value-icon-wrapper img {
    width: 90%;
    height: 90%;
    object-fit: contain;
}

.value-item:hover .value-icon-wrapper {
    transform: scale(1.1);
}

.value-item span {
    font-family: var(--font-body);
    font-size: 1.3rem;
    font-weight: 700;
    text-align: center;
    letter-spacing: 0.5px;
    line-height: 1.2;
}

/* Farmers Section */
.farmers {
    background-color: var(--primary-green);
    color: var(--text-light);
    position: relative;
    overflow: hidden;
}

.farmers-container {
    display: flex;
    align-items: center;
}

.farmers-image {
    flex: 1;
    height: 550px;
}

.farmers-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    /* Mask effect to blend image */
    mask-image: linear-gradient(to right, black 75%, transparent 100%);
    -webkit-mask-image: linear-gradient(to right, black 75%, transparent 100%);
}

.farmers-content {
    flex: 1;
    padding: 80px 60px;
}

.farmers-content h2 {
    font-size: 3rem;
    margin-bottom: 30px;
    line-height: 1.2;
}

.farmers-content p {
    font-size: 1.05rem;
    line-height: 1.9;
    opacity: 0.95;
    text-align: justify;
}

/* Data Section */
.data {
    padding: 100px 0;
    text-align: center;
    background-color: #f9f9f9;
}

.data-content {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 60px;
    margin-top: 60px;
    max-width: 1400px;
    margin-left: auto;
    margin-right: auto;
}

.data-left,
.data-right {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 100px;
}

.data-center {
    flex: 0 0 450px;
}

.data-center img {
    width: 100%;
    height: auto;
}

.data-item {
    position: relative;
    max-width: 450px;
}

.data-left .data-item {
    margin-left: auto;
    text-align: right;
}

.data-right .data-item {
    margin-right: auto;
    text-align: left;
}

.data-item p {
    font-size: 1.2rem;
    color: #6b8e7f;
    line-height: 1.8;
}

.data-item strong {
    color: var(--primary-green);
    font-size: 2.5rem;
    font-weight: 700;
    display: inline-block;
}

.arrow-icon {
    width: 150px;
    height: 60px;
    display: block;
}

.data-left .arrow-icon {
    margin-left: auto;
}

.data-right .arrow-icon {
    margin-right: auto;
}

/* Carousel Section */
.image-carousel {
    padding: 0;
    background-color: #fff;
    overflow: hidden;
}

.carousel-container {
    position: relative;
    max-width: 1400px;
    height: 600px;
    margin: 40px auto;
    border-radius: 40px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
}

.carousel-track {
    display: flex;
    height: 100%;
    transition: transform 0.6s cubic-bezier(0.165, 0.84, 0.44, 1);
}

.carousel-slide {
    min-width: 100%;
    height: 100%;
}

.carousel-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.carousel-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.95);
    border: none;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    cursor: pointer;
    z-index: 10;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    color: var(--text-dark);
}

.carousel-btn:hover {
    background: var(--primary-orange);
    color: #fff;
}

.carousel-btn.prev {
    left: 40px;
}

.carousel-btn.next {
    right: 40px;
}

.carousel-indicators {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 15px;
    z-index: 11;
}

.carousel-indicators span {
    width: 12px;
    height: 12px;
    background: rgba(255, 255, 255, 0.6);
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s ease;
}

.carousel-indicators span.active {
    background: var(--primary-green);
    transform: scale(1.3);
}

@media (max-width: 900px) {
    .carousel-container {
        height: 400px;
        margin: 20px 15px;
        border-radius: 25px;
    }

    .carousel-btn {
        width: 45px;
        height: 45px;
        font-size: 1rem;
    }

    .carousel-btn.prev {
        left: 15px;
    }

    .carousel-btn.next {
        right: 15px;
    }
}

@media (max-width: 480px) {
    .carousel-container {
        height: 300px;
    }
}

/* Products Section */
.products {
    padding: 100px 0;
    background-color: #ececec;
    text-align: center;
}

.products-grid {
    display: flex;
    justify-content: center;
    gap: 60px;
    flex-wrap: wrap;
    margin-top: 20px;
}

.product-card {
    position: relative;
    width: 450px;
    height: 600px;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.15);
    transition: transform 0.4s ease, box-shadow 0.4s ease;
}

.product-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.2);
}

.product-card>img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.product-info {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgb(245, 130, 32) 0%, rgb(245, 130, 32) 60%, rgba(245, 130, 32, 0.85) 80%, rgba(245, 130, 32, 0) 100%);
    padding: 100px 40px 60px;
    text-align: center;
    height: 60%;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
}

.product-info h3 {
    font-family: var(--font-body);
    font-weight: 800;
    color: var(--text-light);
    font-size: 2.5rem;
    margin-bottom: 25px;
    text-transform: none;
    line-height: 1.05;
    letter-spacing: -0.02em;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
}

.btn-link {
    color: var(--text-light);
    text-decoration: underline;
    font-weight: 500;
    font-size: 1.1rem;
}

/* Certifications */
.certifications {
    padding: 80px 0;
    background-color: #fff;
    text-align: center;
}

.cert-logos {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 60px;
    flex-wrap: wrap;
    margin-top: 20px;
}

.cert-logos img {
    height: 100px;
    object-fit: contain;
}

/* Contact Section */
.contact {
    padding: 100px 0;
    background-color: #f5f5f5;
}

.contact-card {
    background-color: var(--primary-orange);
    border-radius: 40px;
    padding: 60px 50px;
    max-width: 500px;
    margin: 0 auto;
    text-align: center;
    color: var(--text-light);
    box-shadow: 0 10px 40px rgba(245, 130, 32, 0.3);
}

.contact-card h2 {
    font-size: 2.5rem;
    margin-bottom: 40px;
}

.contact-form {
    text-align: left;
}

.form-group {
    margin-bottom: 25px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    font-size: 1rem;
}

.form-group input {
    width: 100%;
    padding: 14px 20px;
    border-radius: 30px;
    border: none;
    outline: none;
    font-family: var(--font-body);
    font-size: 1rem;
}

.contact-form .btn {
    width: auto;
    display: block;
    margin: 35px auto 0;
    min-width: 150px;
    font-size: 1.1rem;
}

/* Footer */
.footer {
    background-color: var(--primary-green);
    color: var(--text-light);
    padding: 60px 0 40px;
    font-size: 0.95rem;
    position: relative;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
}

.footer-left p {
    margin-bottom: 20px;
    line-height: 1.8;
}

.footer-right {
    text-align: right;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
}

.social-icons {
    display: flex;
    gap: 20px;
    margin: 15px 0 30px;
}

.social-icons a {
    display: inline-block;
    transition: transform 0.3s ease;
}

.social-icons a:hover {
    transform: scale(1.2);
}

.social-icons img {
    width: 30px;
    height: 30px;
}

.footer-logo img {
    height: 120px;
    opacity: 0.25;
}

/* Responsive Design */
@media (max-width: 992px) {
    .section-title-large {
        font-size: 2.5rem;
    }

    .about-header {
        flex-direction: column;
        text-align: center;
        gap: 20px;
    }

    .mission-vision {
        flex-direction: column;
        align-items: center;
        gap: 40px;
    }

    .farmers-container {
        flex-direction: column;
    }

    .farmers-image {
        width: 100%;
        height: 300px;
    }

    .farmers-image img {
        mask-image: none;
        -webkit-mask-image: none;
    }

    .farmers-content {
        padding: 40px 20px;
        text-align: center;
    }

    .data-content {
        flex-direction: column;
    }

    .data-left,
    .data-right {
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: center;
    }

    .footer-content {
        flex-direction: column;
        gap: 40px;
        text-align: center;
    }

    .footer-right {
        align-items: center;
        text-align: center;
        width: 100%;
    }
}

@media (max-width: 768px) {
    .header-container {
        padding: 0 20px;
    }

    .mobile-menu-btn {
        display: block;
        z-index: 101;
    }

    .nav-menu {
        position: fixed;
        top: 0;
        right: -100%;
        width: 70%;
        height: 100vh;
        background-color: rgba(27, 77, 38, 0.95);
        padding: 80px 20px;
        transition: 0.3s ease;
        backdrop-filter: blur(10px);
    }

    .nav-menu.active {
        right: 0;
    }

    .nav-menu ul {
        flex-direction: column;
        gap: 30px;
    }

    .hero-content h1 {
        font-size: 2.8rem;
        padding: 0 10px;
        line-height: 1.1;
    }

    .hero-content {
        padding-top: 60px;
    }

    .values-grid {
        gap: 30px;
    }

    .value-item {
        width: 45%;
    }

    .contact-card {
        padding: 30px 20px;
    }

    /* Data Section Mobile Improvements */
    .data-content {
        gap: 40px;
    }

    .data-left,
    .data-right {
        flex-direction: column;
        gap: 40px;
        width: 100%;
    }

    .data-item {
        max-width: 100%;
        text-align: center !important;
        margin: 0 !important;
        padding: 0 20px;
    }

    .data-item strong {
        font-size: 1.8rem;
        display: inline;
    }

    .arrow-icon {
        display: none;
    }

    .data-center {
        flex: 0 0 auto;
        width: 80%;
        max-width: 300px;
        margin: 0 auto;
    }
}

/* Product Modal */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1000;
    display: flex;
    align-items: flex-start;
    /* Cambiado de center a flex-start */
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    overflow-y: auto;
    /* Permitir scroll si el modal es muy largo */
    padding: 20px 0;
    /* Espacio arriba y abajo */
}

.modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.modal.active {
    opacity: 1;
    visibility: visible;
}

.modal-container {
    position: relative;
    background: #fff;
    width: 90%;
    max-width: 1000px;
    max-height: none;
    /* Quitamos max-height para permitir que crezca si es necesario */
    margin: 40px auto;
    /* Margen arriba/abajo para evitar que se pegue al borde */
    border-radius: 30px;
    overflow: hidden;
    z-index: 1001;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    transform: translateY(20px) scale(0.98);
    transition: all 0.5s cubic-bezier(0.165, 0.84, 0.44, 1);
    display: flex;
    flex-direction: column;
}

.modal.active .modal-container {
    transform: translateY(0) scale(1);
}

.modal-close {
    position: absolute;
    top: 20px;
    right: 20px;
    background: #fff;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    font-size: 20px;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-dark);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
    z-index: 10;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.modal-close:hover {
    background: var(--primary-orange);
    color: #fff;
    transform: rotate(90deg);
}

.modal-content {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    height: 100%;
    overflow-y: auto;
}

.modal-left {
    background: #f0f0f0;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
}

.modal-left img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.modal-right {
    padding: 60px 50px;
    display: flex;
    flex-direction: column;
    background: #fff;
}

.modal-title {
    font-family: var(--font-body);
    /* Cambiado de Croogs a Outfit para mayor limpieza */
    color: var(--primary-green);
    font-size: 2.2rem;
    margin-bottom: 15px;
    line-height: 1.1;
    letter-spacing: -0.02em;
    font-weight: 800;
    text-transform: none;
    /* Quitamos uppercase para un look más moderno */
}

.modal-description {
    font-size: 1.1rem;
    color: #444;
    margin-bottom: 35px;
    line-height: 1.6;
    text-align: left;
    font-weight: 400;
    letter-spacing: -0.01em;
}

.modal-details {
    display: grid;
    gap: 20px;
    margin-bottom: 40px;
}

.detail-item {
    display: flex;
    flex-direction: column;
    gap: 5px;
    padding-bottom: 15px;
    border-bottom: 1px solid #eee;
}

.detail-label {
    font-weight: 700;
    color: var(--primary-orange);
    text-transform: uppercase;
    font-size: 0.85rem;
    letter-spacing: 1.5px;
    margin-bottom: 2px;
}

.detail-value {
    color: var(--text-dark);
    font-size: 1.1rem;
    line-height: 1.5;
    font-weight: 400;
}

.modal-btn {
    align-self: flex-start;
    padding: 15px 45px;
    font-size: 1.1rem;
    margin-top: auto;
}

@media (max-width: 900px) {
    .modal {
        align-items: flex-start;
        padding: 40px 0;
    }

    .modal-container {
        margin: 0 auto;
    }

    .modal-content {
        grid-template-columns: 1fr;
    }

    .modal-left {
        height: 250px;
    }

    .modal-right {
        padding: 40px 25px;
    }

    .modal-title {
        font-size: 2.22rem;
        margin-bottom: 20px;
    }

    .modal-description {
        font-size: 1.05rem;
        margin-bottom: 30px;
    }

    .modal-container {
        width: 92%;
        max-height: none;
        border-radius: 25px;
    }
}

@media (max-width: 480px) {
    .modal-left {
        height: 280px;
    }

    .modal-right {
        padding: 30px 20px 40px;
    }

    .modal-title {
        font-size: 1.8rem;
        font-weight: 800;
        line-height: 1.1;
    }

    .modal-close {
        top: 15px;
        right: 15px;
        width: 38px;
        height: 38px;
        font-size: 18px;
        background: #fff;
    }

    .modal-description {
        font-size: 1.05rem;
        margin-bottom: 25px;
    }

    .detail-value {
        font-size: 1rem;
    }
}