/* =============================================
   AGRO-PEC CHECA - Custom Styles
   ============================================= */

/* CSS Variables */
:root {
    --primary-color: #2E7D32;        /* Verde principal */
    --secondary-color: #4CAF50;      /* Verde secundario */
    --accent-color: #66BB6A;         /* Verde claro */
    --success-color: #388E3C;        /* Verde éxito */
    --warning-color: #F57C00;        /* Naranja */
    --dark-color: #1B5E20;           /* Verde oscuro */
    --light-color: #E8F5E8;          /* Verde muy claro */
    --text-dark: #2C2C2C;            /* Texto oscuro */
    --text-muted: #666666;           /* Texto gris */
    --white: #FFFFFF;
    --border-radius: 12px;
    --box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Reset & Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Contenedor principal para todas las secciones */
.container {
    max-width: 1200px;
    width: 100%;
    margin: 0 auto;
    padding: 0 20px;
}

/* Prevenir scroll horizontal y asegurar responsive perfecto */
html, body {
    max-width: 100%;
    overflow-x: hidden;
    width: 100%;
}

* {
    box-sizing: border-box;
    max-width: 100%;
}

div, section, .container, .row, [class*="col-"] {
    max-width: 100%;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

/* Asegurar que las imágenes sean responsivas */
img {
    max-width: 100%;
    height: auto;
    display: block;
}

body {
    font-family: 'Roboto', sans-serif;
    line-height: 1.6;
    color: var(--text-dark);
    overflow-x: hidden;
    width: 100%;
    max-width: 100vw;
    position: relative;
    margin: 0;
    padding: 0;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Poppins', sans-serif;
    font-weight: 600;
    line-height: 1.3;
}

.section-padding {
    padding: 80px 0;
    width: 100%;
    max-width: 100%;
}

.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 1rem;
    position: relative;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    border-radius: 2px;
}

/* Bootstrap Overrides */
.btn-primary {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    border: none;
    border-radius: var(--border-radius);
    padding: 12px 30px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: var(--transition);
    box-shadow: 0 4px 15px rgba(46, 125, 50, 0.3);
}

.btn-primary:hover {
    background: linear-gradient(135deg, var(--dark-color), var(--primary-color));
    transform: translateY(-2px);
    box-shadow: 0 6px 25px rgba(46, 125, 50, 0.4);
}

.btn-outline-primary {
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
    border-radius: var(--border-radius);
    padding: 12px 30px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: var(--transition);
}

.btn-outline-primary:hover {
    background: var(--primary-color);
    border-color: var(--primary-color);
    transform: translateY(-2px);
}

/* =============================================
   NAVBAR
   ============================================= */
.custom-navbar {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.1);
    padding: 1rem 0;
    transition: var(--transition);
    width: 100%;
    max-width: 100%;
    overflow-x: hidden;
}

.navbar-brand {
    display: flex;
    align-items: center;
    font-weight: 700;
    font-size: 1.5rem;
    color: var(--primary-color) !important;
    text-decoration: none;
    margin-right: auto;
    padding-left: 0;
}

.logo {
    height: 50px;
    width: auto;
    margin-right: 12px;
    border-radius: 8px;
}

.brand-text {
    font-family: 'Poppins', sans-serif;
    display: flex;
    flex-direction: column;
    line-height: 1.2;
}

.brand-line-1 {
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--primary-color);
    opacity: 0.9;
}

.brand-line-2 {
    font-size: 1rem;
    font-weight: 700;
    color: var(--primary-color);
    margin-top: -2px;
}

.navbar-nav .nav-link {
    color: var(--text-dark) !important;
    font-weight: 500;
    margin: 0 8px;
    padding: 8px 16px !important;
    border-radius: 8px;
    transition: var(--transition);
    position: relative;
}

/* CORRECCIÓN CRÍTICA: Estilos para el botón de hamburguesa - SOLO MÓVIL */
.navbar-toggler {
    border: 2px solid var(--primary-color) !important;
    padding: 0.5rem 0.7rem !important;
    transition: all 0.3s ease !important;
    outline: none !important;
    box-shadow: none !important;
    background-color: rgba(46, 125, 50, 0.1) !important;
    border-radius: 8px !important;
    position: relative !important;
    z-index: 1050 !important;
    min-width: 44px !important;
    min-height: 44px !important;
    /* OCULTO EN DESKTOP - Bootstrap se encarga de mostrarlo en móvil */
    display: none !important;
}

/* Mostrar el botón hamburguesa SOLO en dispositivos móviles */
@media (max-width: 991.98px) {
    .navbar-toggler {
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
    }
}

.navbar-toggler:hover {
    background-color: var(--primary-color) !important;
    border-color: var(--primary-color) !important;
    transform: scale(1.05) !important;
}

.navbar-toggler:focus {
    box-shadow: 0 0 0 0.3rem rgba(46, 125, 50, 0.4) !important;
    border-color: var(--primary-color) !important;
    background-color: var(--primary-color) !important;
}

.navbar-toggler:active {
    background-color: var(--primary-color) !important;
    border-color: var(--primary-color) !important;
    transform: scale(0.95) !important;
}

.navbar-toggler-icon {
    width: 1.8em !important;
    height: 1.8em !important;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%2846, 125, 50, 1%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e") !important;
    transition: all 0.3s ease !important;
}

.navbar-toggler:hover .navbar-toggler-icon,
.navbar-toggler:focus .navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%28255, 255, 255, 1%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e") !important;
}

.navbar-nav .nav-link:hover {
    color: var(--primary-color) !important;
    background: var(--light-color);
}

.navbar-nav .nav-link.active {
    color: var(--primary-color) !important;
    background: var(--light-color);
}

/* =============================================
   HERO CAROUSEL
   ============================================= */
.hero-section {
    padding-top: 82px; /* Fixed navbar height compensation */
    max-width: 100%;
    overflow-x: hidden;
    position: relative;
    width: 100%;
}

#heroCarousel {
    position: relative;
    max-width: 100%;
    overflow: hidden;
    margin: 0 auto;
    width: 100%;
}

.carousel-item {
    height: 70vh;
    min-height: 600px;
    max-width: 100%;
    overflow: hidden;
}

.carousel-item img {
    object-fit: cover;
    height: 100%;
    width: 100%;
    filter: brightness(0.7);
    max-width: 100%;
}

.carousel-caption {
    background: linear-gradient(135deg, rgba(46, 125, 50, 0.5), rgba(76, 175, 80, 0.4));
    border-radius: var(--border-radius);
    padding: 2rem;
    max-width: 600px;
    backdrop-filter: blur(5px);
    display: flex !important;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: absolute !important;
    bottom: 80px !important; /* Posición fija sobre los indicadores */
    left: 50% !important;
    right: auto !important;
    transform: translateX(-50%) !important;
    width: 90% !important;
    max-width: 600px !important;
    margin: 0 !important;
    text-align: center;
}

.carousel-caption h1,
.carousel-caption h2 {
    color: var(--white);
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
    margin-bottom: 1rem;
}

.carousel-caption p {
    color: var(--white);
    font-size: 1.2rem;
    margin-bottom: 2rem;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.3);
}

.carousel-control-prev,
.carousel-control-next {
    width: 5%;
}

.carousel-control-prev-icon,
.carousel-control-next-icon {
    background-color: var(--primary-color);
    border-radius: 50%;
    padding: 20px;
}

.carousel-indicators button {
    background-color: var(--primary-color);
    border-radius: 50%;
    width: 12px;
    height: 12px;
    margin: 0 5px;
}

/* =============================================
   NOSOTROS SECTION
   ============================================= */
#nosotros {
    background: linear-gradient(135deg, #f8f9fa 0%, var(--light-color) 100%);
    position: relative;
    overflow: hidden;
    max-width: 100%;
    width: 100%;
}

/* Contenedor de imagen mejorado para mejor simetría */
.about-image-container {
    height: 450px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    max-width: 95%;
    margin: 0 auto;
    border-radius: 20px;
}

.about-main-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 20px !important;
    box-shadow: 
        0 20px 60px rgba(0, 0, 0, 0.15),
        0 10px 30px rgba(0, 0, 0, 0.08),
        0 4px 12px rgba(0, 0, 0, 0.05);
    transition: var(--transition);
}

.about-main-image:hover {
    transform: scale(1.02);
    box-shadow: 
        0 25px 80px rgba(0, 0, 0, 0.2),
        0 15px 40px rgba(0, 0, 0, 0.1),
        0 6px 16px rgba(0, 0, 0, 0.08);
}

/* Ajustes para el texto de la izquierda */
.about-image-container + .col-lg-6 .pe-lg-4 {
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

/* Responsive adjustments */
@media (max-width: 991px) {
    .about-image-container {
        height: 350px;
        margin-top: 2rem;
    }
}

@media (max-width: 767px) {
    .about-image-container {
        height: 300px;
        max-width: 100%;
        margin: 0;
        border-radius: 15px;
    }
    
    .about-main-image {
        border-radius: 15px !important;
        width: 100%;
        height: 100%;
        object-fit: cover;
    }
}

/* =============================================
   STATS CARD - Diseño Profesional Mejorado
   ============================================= */
.stats-card {
    position: absolute;
    bottom: 20px;
    right: 20px;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.98) 0%, rgba(248, 249, 250, 0.95) 100%);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.5);
    border-radius: 20px;
    padding: 1.8rem 2rem;
    box-shadow: 
        0 12px 48px rgba(0, 0, 0, 0.18),
        0 6px 16px rgba(0, 0, 0, 0.12),
        inset 0 1px 0 rgba(255, 255, 255, 0.9),
        0 0 0 1px rgba(255, 255, 255, 0.3);
    width: 320px;
    max-width: calc(100% - 40px); /* Asegura que no se salga del contenedor en móviles */
    z-index: 10;
    animation: statsCardSlideIn 0.8s cubic-bezier(0.4, 0, 0.2, 1) 0.5s both;
    overflow: hidden; /* Evita que el contenido se salga */
    transform-origin: bottom right;
}

.stats-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color), var(--warning-color));
    border-radius: 20px 20px 0 0;
    opacity: 0.9;
}

.stats-card::after {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at center, rgba(255, 255, 255, 0.2) 0%, transparent 70%);
    border-radius: 20px;
    pointer-events: none;
    z-index: -1;
}

.stats-card-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    margin: 0;
}

.stats-item {
    text-align: center;
    position: relative;
    padding: 0.5rem 0;
}

.stats-item:not(:last-child)::after {
    content: '';
    position: absolute;
    right: -0.75rem;
    top: 50%;
    transform: translateY(-50%);
    width: 2px;
    height: 35px;
    background: linear-gradient(
        to bottom,
        transparent 0%,
        rgba(46, 125, 50, 0.3) 20%,
        rgba(46, 125, 50, 0.6) 50%,
        rgba(46, 125, 50, 0.3) 80%,
        transparent 100%
    );
    border-radius: 1px;
}

.stats-number {
    position: relative;
    font-size: 1.75rem;
    font-weight: 900;
    line-height: 1;
    margin-bottom: 0.3rem;
    font-family: 'Poppins', sans-serif;
    letter-spacing: -0.5px;
    display: block;
    text-shadow: 
        0 2px 8px rgba(0, 0, 0, 0.15),
        0 1px 3px rgba(0, 0, 0, 0.1);
    background: linear-gradient(135deg, #333 0%, #000 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.stats-label {
    position: relative;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    color: #4a4a4a;
    line-height: 1;
    margin: 0;
    text-shadow: 0 1px 2px rgba(255, 255, 255, 0.8);
    opacity: 0.85;
}

/* Colores específicos para cada estadística */
.stats-item:nth-child(1) .stats-number {
    background: linear-gradient(135deg, var(--primary-color) 0%, #1b5e20 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: none;
}

.stats-item:nth-child(2) .stats-number {
    background: linear-gradient(135deg, var(--success-color) 0%, #2e7d32 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: none;
}

.stats-item:nth-child(3) .stats-number {
    background: linear-gradient(135deg, var(--warning-color) 0%, #e65100 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: none;
}

/* Animaciones */
@keyframes statsCardSlideIn {
    from {
        opacity: 0;
        transform: translateY(20px) scale(0.95);
        box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
        box-shadow: 0 12px 48px rgba(0, 0, 0, 0.18), 0 6px 16px rgba(0, 0, 0, 0.12);
    }
}

.stats-item {
    animation: statsItemFadeIn 0.5s ease-out both;
}

.stats-item:nth-child(1) { animation-delay: 0.6s; }
.stats-item:nth-child(2) { animation-delay: 0.7s; }
.stats-item:nth-child(3) { animation-delay: 0.8s; }

@keyframes statsItemFadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
        filter: blur(2px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
        filter: blur(0);
    }
}

/* Efectos hover */
.stats-card:hover {
    transform: translateY(-5px);
    box-shadow: 
        0 18px 60px rgba(0, 0, 0, 0.22),
        0 10px 24px rgba(0, 0, 0, 0.15),
        inset 0 1px 0 rgba(255, 255, 255, 1),
        0 0 0 1px rgba(255, 255, 255, 0.5);
}

.stats-item:hover .stats-number {
    transform: scale(1.1);
}

.stats-number {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.stats-card {
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Responsive Design */
@media (max-width: 1199.98px) {
    .stats-card {
        width: 280px;
        padding: 1.3rem 1.5rem;
    }
    
    .stats-card-grid {
        gap: 1.2rem;
    }
    
    .stats-number {
        font-size: 1.6rem;
    }
}

/* =============================================
   MENÚ LATERAL (SIDE-DRAWER) RESPONSIVO
   ============================================= */

/* Botón hamburguesa personalizado */
.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    width: 44px;
    height: 44px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 8px;
    border-radius: 8px;
    transition: all 0.3s ease;
    position: relative;
    z-index: 1060;
}

.mobile-menu-toggle:hover {
    background: rgba(46, 125, 50, 0.1);
    transform: scale(1.05);
}

.mobile-menu-toggle:focus {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

.hamburger-line {
    width: 24px;
    height: 3px;
    background: var(--primary-color);
    border-radius: 2px;
    transition: all 0.3s ease;
    margin: 2px 0;
}

/* Animación del botón hamburguesa cuando está activo */
.mobile-menu-toggle.active .hamburger-line:nth-child(1) {
    transform: rotate(45deg) translate(6px, 6px);
}

.mobile-menu-toggle.active .hamburger-line:nth-child(2) {
    opacity: 0;
}

.mobile-menu-toggle.active .hamburger-line:nth-child(3) {
    transform: rotate(-45deg) translate(6px, -6px);
}

/* Overlay semitransparente */
.side-drawer-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1040;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease-in-out;
    backdrop-filter: blur(2px);
}

.side-drawer-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* Menú lateral principal */
.side-drawer {
    position: fixed;
    top: 0;
    left: 0;
    width: 80%;
    max-width: 320px;
    height: 100%;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.98) 0%, rgba(248, 250, 252, 0.98) 100%);
    backdrop-filter: blur(20px);
    border-right: 1px solid rgba(46, 125, 50, 0.1);
    box-shadow: 4px 0 30px rgba(0, 0, 0, 0.15);
    z-index: 1050;
    transform: translateX(-100%);
    transition: transform 0.3s ease-in-out;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.side-drawer.active {
    transform: translateX(0);
}

/* Header del menú lateral */
.side-drawer-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 16px;
    border-bottom: 1px solid rgba(46, 125, 50, 0.1);
    background: rgba(46, 125, 50, 0.03);
    min-height: 80px;
}

.side-drawer-brand {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 1;
}

.side-drawer-logo {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    object-fit: cover;
    border: 2px solid rgba(46, 125, 50, 0.1);
}

.side-drawer-title {
    display: flex;
    flex-direction: column;
    line-height: 1.2;
}

.title-line-1 {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--primary-color);
    margin-bottom: 2px;
}

.title-line-2 {
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--dark-color);
    opacity: 0.8;
}

/* Botón de cierre */
.side-drawer-close {
    width: 36px;
    height: 36px;
    background: transparent;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    color: var(--dark-color);
}

.side-drawer-close:hover {
    background: rgba(46, 125, 50, 0.1);
    transform: scale(1.1);
}

.side-drawer-close:focus {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

.close-icon {
    font-size: 24px;
    font-weight: 300;
    line-height: 1;
}

/* Contenido del menú lateral */
.side-drawer-content {
    flex: 1;
    overflow-y: auto;
    padding: 16px 0;
}

.side-drawer-nav {
    list-style: none;
    margin: 0;
    padding: 0;
}

.side-drawer-item {
    margin: 0;
}

.side-drawer-link {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px 20px;
    color: var(--dark-color);
    text-decoration: none;
    font-weight: 500;
    font-size: 1rem;
    transition: all 0.3s ease;
    border-left: 4px solid transparent;
    min-height: 44px;
    position: relative;
}

.side-drawer-link:hover {
    background: rgba(46, 125, 50, 0.08);
    border-left-color: var(--primary-color);
    color: var(--primary-color);
    transform: translateX(4px);
}

.side-drawer-link:focus {
    outline: 2px solid var(--primary-color);
    outline-offset: -2px;
    background: rgba(46, 125, 50, 0.1);
}

.side-drawer-link.active {
    background: rgba(46, 125, 50, 0.1);
    border-left-color: var(--primary-color);
    color: var(--primary-color);
    font-weight: 600;
}

.link-icon {
    font-size: 1.2rem;
    width: 24px;
    text-align: center;
    opacity: 0.8;
}

.link-text {
    flex: 1;
    font-size: 1rem;
}

/* Responsive: Mostrar menú lateral solo en móvil */
@media (max-width: 991.98px) {
    /* Ocultar menú desktop */
    .desktop-nav {
        display: none;
    }
    
    /* Mostrar botón hamburguesa */
    .mobile-menu-toggle {
        display: flex;
    }
    
    /* Ajustes del navbar para móvil */
    .navbar {
        background: rgba(255, 255, 255, 0.98) !important;
        backdrop-filter: blur(12px) !important;
        border-bottom: 1px solid rgba(46, 125, 50, 0.08) !important;
        padding: 8px 0 !important;
        min-height: 64px !important;
    }
    
    /* Mejora del contenedor del navbar */
    .navbar .container {
        padding-left: 15px !important;
        padding-right: 15px !important;
        display: flex !important;
        align-items: center !important;
        justify-content: space-between !important;
    }
    
    /* Mejora de alineación del logo en móvil */
    .navbar-brand {
        margin-right: 0 !important;
        flex: 1 !important;
        justify-content: flex-start !important;
        padding-left: 0 !important;
        max-width: calc(100% - 60px) !important;
    }
    
    .logo {
        height: 45px !important;
        margin-right: 10px !important;
        flex-shrink: 0 !important;
    }
    
    .brand-text {
        flex-shrink: 1 !important;
        min-width: 0 !important;
    }
    
    .brand-line-1 {
        font-size: 0.8rem !important;
        white-space: nowrap !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
    }
    
    .brand-line-2 {
        font-size: 0.9rem !important;
        white-space: nowrap !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
    }
    
    /* Asegurar que el botón hamburguesa tenga espacio */
    .mobile-menu-toggle {
        margin-left: 10px !important;
        flex-shrink: 0 !important;
    }
}

/* Responsive: Pantallas muy pequeñas */
@media (max-width: 480px) {
    .side-drawer {
        width: 85%;
        max-width: 280px;
    }
    
    .side-drawer-header {
        padding: 16px 12px;
        min-height: 70px;
    }
    
    .side-drawer-logo {
        width: 36px;
        height: 36px;
    }
    
    .title-line-1 {
        font-size: 0.8rem;
    }
    
    .title-line-2 {
        font-size: 0.7rem;
    }
    
    .side-drawer-link {
        padding: 14px 16px;
        font-size: 0.95rem;
    }
    
    .link-icon {
        font-size: 1.1rem;
        width: 20px;
    }
}

/* Mantener estilos desktop intactos */
@media (min-width: 992px) {
    .mobile-menu-toggle,
    .side-drawer,
    .side-drawer-overlay {
        display: none;
    }
    
    .desktop-nav {
        display: block;
    }
    
    .desktop-nav {
        width: auto !important;
        max-height: none !important;
    }
    
    .custom-navbar .navbar-nav {
        display: flex !important;
        flex-direction: row !important;
        padding: 0 !important;
        background: none !important;
    }
    
    .custom-navbar .navbar-nav .nav-link {
        padding: 0.5rem 1rem !important;
        margin: 0 0.25rem !important;
        border: none !important;
        background: none !important;
        color: var(--dark-color) !important;
        font-weight: 500 !important;
        border-radius: 6px !important;
        transition: all 0.3s ease !important;
    }
    
    .custom-navbar .navbar-nav .nav-link:hover {
        background-color: var(--light-color) !important;
        color: var(--primary-color) !important;
        transform: none !important;
    }
    
    .custom-navbar .navbar-nav .nav-link.active {
        background-color: var(--primary-color) !important;
        color: white !important;
    }
}

/* Fin de estilos del menú lateral */

/* =============================================
   ABOUT SECTION
   ============================================= */

@media (max-width: 767.98px) {
    /* Optimización de contenedores para aprovechar el ancho completo */
    .container {
        max-width: 100% !important;
        width: 100% !important;
        padding-left: 20px !important;
        padding-right: 20px !important;
        margin: 0 auto !important;
    }
    
    .section-padding {
        padding: 60px 0;
    }
    
    /* Asegurar centrado perfecto en todas las secciones */
    .row {
        margin-left: 0 !important;
        margin-right: 0 !important;
        width: 100% !important;
    }
    
    [class*="col-"] {
        padding-left: 10px !important;
        padding-right: 10px !important;
        width: 100% !important;
        text-align: center !important;
    }
    
    /* Centrado específico para contenido de texto */
    .text-center, .section-title, h1, h2, h3, h4, h5, h6 {
        text-align: center !important;
    }
    
    /* Mejoras para el footer en dispositivos móviles */
    footer .row {
        text-align: center;
    }
    
    .footer-brand, .footer-links, .contact-info, .social-links {
        margin-bottom: 2rem;
    }
    
    .footer-logo {
        margin: 0 auto 1rem;
        display: block;
    }
    
    .social-links {
        justify-content: center;
    }
    
    .newsletter-form {
        max-width: 300px;
        margin: 0 auto;
    }
    
    /* Ocultar la tarjeta de estadísticas en dispositivos móviles */
    .stats-card {
        display: none;
    }
    
    /* Ajustar el contenedor de imagen para que se vea mejor sin la tarjeta */
    .about-image-container {
        margin-bottom: 1.5rem;
        min-height: 320px;
        max-width: 100%;
        padding: 0 5px;
    }
    
    .about-main-image {
        object-fit: cover;
        height: 100%;
        width: 100%;
        border-radius: 15px !important;
    }
    
    /* Optimizar la certificación en móviles */
    .certification-highlight {
        padding: 18px;
        margin-bottom: 1.5rem;
    }
    
    .certification-badge {
        font-size: 1rem;
    }
    
    .certification-text {
        font-size: 0.9rem;
        line-height: 1.5;
    }
    
    .certification-details {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.3rem;
    }
    
    .certification-license,
    .certification-date {
        font-size: 0.85rem;
    }
    
    /* Mejorar el espaciado del texto */
    .section-title {
        font-size: 2.2rem;
        margin-bottom: 1.2rem;
    }
    
    .lead {
        font-size: 1.1rem;
        line-height: 1.6;
        margin-bottom: 1.5rem;
    }
    
    /* Optimizar imágenes para aprovechar mejor el espacio */
    .blog-card-img {
        height: 250px;
    }
    
    .about-main-image {
        width: 100%;
        height: auto;
        min-height: 300px;
        object-fit: cover;
    }
    
    /* Mejorar el espaciado de las tarjetas */
    .blog-card {
        margin-bottom: 1.5rem;
    }
    
    .testimonial-card {
        padding: 2rem 1rem;
        margin: 0;
    }
    
    /* CORRECCIÓN CRÍTICA: Optimizar sección Mensaje de Productores - CENTRADO y 90% ancho */
    #mensaje .container {
        max-width: 90% !important;
        padding-left: 5% !important;
        padding-right: 5% !important;
    }
    
    #mensaje .col-lg-8 {
        max-width: 100% !important;
        flex: 0 0 100% !important;
        margin: 0 auto !important;
    }
    
    #mensaje .testimonial-card {
        padding: 2rem 1rem;
        margin: 0 auto;
        width: 100%;
        text-align: center;
        max-width: none !important;
    }
    
    #mensaje .testimonial-quote {
        font-size: 1.1rem;
        line-height: 1.7;
        margin-bottom: 1.5rem;
        padding: 0;
        text-align: center;
        width: 100%;
    }
    
    /* CORRECCIÓN CRÍTICA: Sección Sobre Nosotros perfectamente centrada y optimizada */
    #nosotros {
        text-align: center !important;
    }
    
    #nosotros .container {
        max-width: 100% !important;
        padding-left: 20px !important;
        padding-right: 20px !important;
    }
    
    #nosotros .row {
        justify-content: center !important;
        align-items: center !important;
    }
    
    #nosotros .col-lg-6 {
        width: 100% !important;
        max-width: 100% !important;
        text-align: center !important;
        margin-bottom: 2rem !important;
    }
    
    #nosotros .section-title {
        font-size: 2.2rem !important;
        line-height: 1.3 !important;
        margin-bottom: 2rem !important;
        padding: 0 !important;
        text-align: center !important;
        word-wrap: break-word !important;
        overflow-wrap: break-word !important;
        white-space: normal !important;
    }
    
    #nosotros .lead {
        font-size: 1.15rem !important;
        line-height: 1.7 !important;
        margin-bottom: 2rem !important;
        padding: 0 !important;
        text-align: center !important;
        word-wrap: break-word !important;
        overflow-wrap: break-word !important;
        max-width: 100% !important;
    }
    
    #nosotros .certification-text {
        font-size: 1rem !important;
        line-height: 1.6 !important;
        padding: 0 !important;
        text-align: center !important;
        word-wrap: break-word !important;
        overflow-wrap: break-word !important;
    }
    
    #nosotros p {
        font-size: 1.05rem !important;
        line-height: 1.7 !important;
        margin-bottom: 1.5rem !important;
        padding: 0 !important;
        text-align: center !important;
        word-wrap: break-word !important;
        overflow-wrap: break-word !important;
        max-width: 100% !important;
    }
    
    #nosotros .pe-lg-4 {
        padding: 0 !important;
        text-align: center !important;
    }
    
    /* Optimizar el contenido de texto y secciones */
    .pe-lg-4 {
        padding-right: 0 !important;
        text-align: center !important;
    }
    
    /* Centrado perfecto para todas las secciones */
    #blog, #mensaje, #productos, #contacto {
        text-align: center !important;
    }
    
    #blog .container, #mensaje .container, #productos .container, #contacto .container {
        max-width: 100% !important;
        padding-left: 20px !important;
        padding-right: 20px !important;
    }
    
    #blog .row, #mensaje .row, #productos .row, #contacto .row {
        justify-content: center !important;
        align-items: center !important;
    }
    
    #blog .col-lg-4, #mensaje .col-lg-8, #productos .col-lg-6, #contacto .col-lg-4, #contacto .col-lg-2, #contacto .col-lg-3 {
        width: 100% !important;
        max-width: 100% !important;
        text-align: center !important;
        margin-bottom: 2rem !important;
    }
    
    /* Mejorar tarjetas de blog */
    .blog-card {
        max-width: 100% !important;
        margin: 0 auto 2rem auto !important;
    }
    
    /* Mejorar sección de productos */
    .product-info {
        text-align: center !important;
        padding: 0 !important;
    }
    
    .product-features ul, .product-specs .row {
        text-align: center !important;
    }
    
    /* Mejorar footer */
    .footer-brand, .footer-links, .contact-info, .social-links {
        text-align: center !important;
        margin-bottom: 2rem !important;
    }
    
    /* Mejoras para el carrusel en dispositivos móviles - CENTRADO PERFECTO */
    .hero-section {
        width: 100% !important;
        max-width: 100% !important;
        overflow-x: hidden !important;
    }
    
    #heroCarousel {
        width: 100% !important;
        max-width: 100% !important;
    }
    
    .carousel-item {
        width: 100% !important;
        max-width: 100% !important;
    }
    
    .carousel-caption {
        padding: 1.5rem 1rem !important;
        display: flex !important;
        flex-direction: column;
        align-items: center !important;
        justify-content: center !important;
        position: absolute !important;
        bottom: 80px !important;
        left: 50% !important;
        right: auto !important;
        transform: translateX(-50%) !important;
        width: 90% !important;
        max-width: 500px !important;
        margin: 0 auto !important;
        text-align: center !important;
        background: linear-gradient(135deg, rgba(46, 125, 50, 0.8), rgba(76, 175, 80, 0.7)) !important;
        border-radius: 15px !important;
        backdrop-filter: blur(10px) !important;
    }
    
    .carousel-caption h1,
    .carousel-caption .display-4 {
        font-size: 1.9rem !important;
        margin-bottom: 0.8rem !important;
        text-align: center !important;
        line-height: 1.3 !important;
    }
    
    .carousel-caption h2,
    .carousel-caption .display-5 {
        font-size: 1.6rem !important;
        margin-bottom: 0.8rem !important;
        text-align: center !important;
        line-height: 1.3 !important;
    }
    
    .carousel-caption p.lead {
        font-size: 1.1rem !important;
        margin-bottom: 1.2rem !important;
        text-align: center !important;
        line-height: 1.5 !important;
    }
    
    .carousel-caption .btn-lg {
        padding: 0.7rem 1.5rem !important;
        font-size: 1rem !important;
        margin: 0 auto !important;
        display: block !important;
        width: auto !important;
        max-width: 250px !important;
    }
    
    .hero-section {
        margin-top: 0;
        padding-top: 0;
    }
    
    .carousel-item {
        height: 50vh;
        min-height: 400px;
    }
    
    .carousel-caption h1 {
        font-size: 1.8rem;
    }
    
    .carousel-caption .display-4 {
        font-size: 2rem;
    }
    
    .brand-line-1 {
        font-size: 0.85rem;
    }
    
    .brand-line-2 {
        font-size: 0.95rem;
    }
    
    /* Partners section adjustments for mobile */
    .partners-grid-simple {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
    }
    
    .partner-logo-clean {
        width: 140px;
        height: 75px;
        padding: 15px;
        /* Ensure all partner logos have consistent size in mobile view */
        min-width: 140px;
        max-width: 140px;
        min-height: 75px;
        max-height: 75px;
    }
    
    /* Mantener oculta la tarjeta de estadísticas en dispositivos móviles */
    .stats-card {
        display: none;
    }
    
    .testimonial-card {
        padding: 2rem 1rem;
    }
    
    .blog-card-img {
        height: 200px;
    }
    
    .testimonial-quote {
        font-size: 1rem;
    }
    
    .product-title {
        font-size: 1.5rem;
    }
    
    .social-links {
        justify-content: center;
    }
}

/* =============================================
   BLOG SECTION
   ============================================= */
.blog-card {
    background: var(--white);
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--box-shadow);
    transition: var(--transition);
    cursor: pointer;
    max-width: 95%;
    margin: 0 auto;
}

.blog-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

.blog-card-img {
    position: relative;
    overflow: hidden;
    height: 250px;
}

.blog-card-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.blog-card:hover .blog-card-img img {
    transform: scale(1.1);
}

.blog-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(46, 125, 50, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: var(--transition);
}

.blog-card:hover .blog-overlay {
    opacity: 1;
}

.blog-overlay i {
    color: var(--white);
    font-size: 2rem;
}

.blog-card-body {
    padding: 1.5rem;
}

.blog-title {
    color: var(--primary-color);
    margin-bottom: 1rem;
    font-weight: 600;
}

.blog-excerpt {
    color: var(--text-muted);
    margin-bottom: 1rem;
    line-height: 1.6;
}

.read-more {
    color: var(--primary-color);
    font-weight: 500;
    text-decoration: none;
}

/* =============================================
   MENSAJE SECTION
   ============================================= */
#mensaje {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    position: relative;
}

#mensaje::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1000 100" fill="rgba(255,255,255,0.1)"><polygon points="0,0 1000,20 1000,100 0,80"/></svg>');
    background-size: cover;
}

.testimonial-card {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: var(--border-radius);
    padding: 3rem;
    text-align: center;
    position: relative;
    z-index: 1;
    max-width: 85%;
    margin: 0 auto;
}

.testimonial-img {
    margin-bottom: 2rem;
    text-align: center;
    display: flex;
    justify-content: center;
}

.testimonial-img img {
    width: 120px;
    height: 120px;
    object-fit: cover;
    border: 4px solid var(--white);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    margin: 0 auto;
}

.testimonial-quote {
    font-size: 1.1rem;
    font-style: italic;
    line-height: 1.8;
    margin-bottom: 2rem;
    color: var(--white);
    position: relative;
}

/* Eliminamos las comillas dobles que no deberían estar */
.testimonial-quote::before {
    display: none;
}

.testimonial-author {
    color: var(--white);
}

/* =============================================
   PRODUCTOS SECTION
   ============================================= */
.product-gallery {
    position: relative;
    max-width: 95%;
    margin: 0 auto;
}

.main-product-img {
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
}

.product-info {
    padding-left: 2rem;
    max-width: 95%;
}

.product-title {
    color: var(--primary-color);
    font-size: 2rem;
    margin-bottom: 1rem;
}

.product-description {
    font-size: 1.1rem;
    color: var(--text-muted);
    margin-bottom: 2rem;
    line-height: 1.7;
}

.product-features h5,
.product-specs h5 {
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.product-features ul,
.product-specs .row {
    margin-bottom: 2rem;
}

.product-features li {
    margin-bottom: 0.5rem;
    color: var(--text-dark);
}

.product-specs .row > div {
    margin-bottom: 0.3rem;
    color: var(--text-dark);
    line-height: 1.4;
}

/* Mejora de alineación y espaciado de botones */
.product-info .mt-4 {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    align-items: center;
    justify-content: flex-start;
}

.product-info .mt-4 .btn {
    margin: 0;
    min-width: 200px;
    text-align: center;
}

@media (max-width: 576px) {
    .product-info .mt-4 {
        flex-direction: column;
        align-items: stretch;
    }
    
    .product-info .mt-4 .btn {
        width: 100%;
        min-width: auto;
    }
}

/* =============================================
   PARTNERS SECTION (Con el respaldo de)
   ============================================= */
.partners-section {
    position: relative;
    padding: 100px 0;
    overflow: hidden;
}

.partners-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        linear-gradient(rgba(64, 64, 64, 0.75), rgba(96, 96, 96, 0.65)),
        url('../images/partners-background.jpg') center/cover no-repeat;
    filter: grayscale(100%);
    z-index: 1;
}

.partners-section::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(circle at 30% 70%, rgba(255, 255, 255, 0.08) 0%, transparent 40%),
        radial-gradient(circle at 70% 30%, rgba(46, 125, 50, 0.1) 0%, transparent 40%);
    z-index: 2;
}

.partners-section::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--primary-color), transparent);
    z-index: 2;
}

.partners-container {
    position: relative;
    z-index: 3;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    width: 85%;
}

.partners-header {
    text-align: center;
    margin-bottom: 50px;
}

.partners-badge {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: transparent;
    color: rgba(255, 255, 255, 0.9);
    padding: 0;
    border-radius: 0;
    font-size: 1rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 2px;
    border: none;
    box-shadow: none;
    margin-bottom: 20px;
    transition: all 0.3s ease;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.partners-badge:hover {
    color: rgba(255, 255, 255, 1);
    transform: none;
    box-shadow: none;
    border-color: transparent;
    text-shadow: 0 2px 15px rgba(76, 175, 80, 0.4);
}

.partners-badge::before {
    content: '\F62E';
    font-family: 'bootstrap-icons';
    font-size: 1.2rem;
}

.partners-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--white);
    margin-bottom: 20px;
    font-family: 'Poppins', sans-serif;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.partners-subtitle {
    font-size: 1.1rem;
    color: rgba(255, 255, 255, 0.9);
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.6;
    text-shadow: 0 1px 5px rgba(0, 0, 0, 0.3);
}

/* Partners Grid Simple */
.partners-grid-simple {
    display: grid;
    grid-template-columns: repeat(4, 1fr); /* Forzar 4 columnas en desktop */
    gap: 40px;
    margin-top: 60px;
    align-items: center;
    justify-items: center;
    max-width: 1000px;
    margin-left: auto;
    margin-right: auto;
    overflow-x: hidden;
    position: relative;
    z-index: 2;
}

.partner-logo-simple {
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    opacity: 1;
    transform: translateY(0);
}

.partner-logo-simple.animate-entrance {
    opacity: 0;
    transform: translateY(30px);
    animation: slideUpFade 0.8s ease-out forwards;
}

.partner-logo-simple.animate-entrance:nth-child(1) {
    animation-delay: 0.1s;
}

.partner-logo-simple.animate-entrance:nth-child(2) {
    animation-delay: 0.2s;
}

.partner-logo-simple.animate-entrance:nth-child(3) {
    animation-delay: 0.3s;
}

.partner-logo-simple.animate-entrance:nth-child(4) {
    animation-delay: 0.4s;
}

.partner-logo-simple {
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    opacity: 1;
    transform: translateY(0);
    position: relative;
}

.partner-logo-clean {
    width: 200px;
    height: 100px;
    object-fit: contain;
    filter: 
        brightness(1.1) 
        contrast(1.1) 
        drop-shadow(0 4px 20px rgba(0, 0, 0, 0.3))
        grayscale(0%);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    z-index: 2;
    padding: 20px;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 20px;
    border: 2px solid rgba(128, 128, 128, 0.4);
    box-shadow: 
        0 8px 30px rgba(0, 0, 0, 0.15),
        0 4px 15px rgba(0, 0, 0, 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
    backdrop-filter: blur(10px);
    /* Ensure all partner logos have consistent size */
    min-width: 200px;
    max-width: 200px;
    min-height: 100px;
    max-height: 100px;
}

.partner-logo-simple:hover .partner-logo-clean {
    filter: 
        brightness(1.2) 
        contrast(1.2) 
        drop-shadow(0 6px 30px rgba(0, 0, 0, 0.4))
        grayscale(0%);
    transform: scale(1.05);
    background: rgba(255, 255, 255, 0.95);
    border-color: rgba(76, 175, 80, 0.4);
    box-shadow: 
        0 12px 40px rgba(0, 0, 0, 0.2),
        0 6px 20px rgba(76, 175, 80, 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.9);
    /* Maintain size constraints even on hover */
    min-width: inherit;
    max-width: inherit;
    min-height: inherit;
    max-height: inherit;
}

/* Estilos unificados para todos los logos */
.partner-logo-simple .partner-logo-clean {
    transform: scale(1);
}

.partner-logo-simple:hover .partner-logo-clean {
    transform: scale(1.05);
}

@keyframes slideUpFade {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}



/* Responsive Design */
@media (max-width: 991.98px) {
    .partners-section {
        padding: 80px 0;
    }
    
    .partners-title {
        font-size: 2rem;
    }
    
    .partners-grid-simple {
        grid-template-columns: repeat(2, 1fr); /* 2 columnas en tablets */
        gap: 30px;
        margin-top: 40px;
    }
    
    .partner-logo-clean {
        width: 160px;
        height: 85px;
        padding: 18px;
        border-radius: 16px;
        background: rgba(255, 255, 255, 0.75);
        border: 2px solid rgba(128, 128, 128, 0.4);
        /* Ensure all partner logos have consistent size in responsive view */
        min-width: 160px;
        max-width: 160px;
        min-height: 85px;
        max-height: 85px;
    }
}



/* =============================================
   FOOTER
   ============================================= */
footer {
    background: linear-gradient(135deg, #1a1a1a 0%, #2d2d2d 100%) !important;
    max-width: 100%;
    overflow-x: hidden;
}

.footer-logo {
    height: 60px;
    width: auto;
    border-radius: 8px;
}

.footer-title {
    color: var(--secondary-color);
    font-weight: 600;
    margin-bottom: 1rem;
    font-size: 1.1rem;
}

.footer-links {
    list-style: none;
    padding: 0;
}

.footer-links li {
    margin-bottom: 0.5rem;
}

.footer-links a {
    color: #ccc;
    text-decoration: none;
    transition: var(--transition);
}

.footer-links a:hover {
    color: var(--secondary-color);
}

.contact-info p {
    color: #ccc;
    margin-bottom: 0.75rem;
}

.contact-info i {
    color: var(--secondary-color);
    width: 20px;
}

.social-links {
    display: flex;
    gap: 1rem;
    margin-bottom: 1rem;
}

.social-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.1);
    color: var(--white);
    border-radius: 50%;
    text-decoration: none;
    transition: var(--transition);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

/* Colores específicos para cada red social */
.social-link:nth-child(1) {
    background: #1877F2; /* Facebook azul */
}

.social-link:nth-child(2) {
    background: #E4405F; /* Instagram rosa sólido */
}

.social-link:nth-child(3) {
    background: #25D366; /* WhatsApp verde */
}

.social-link:nth-child(4) {
    background: #FF0000; /* YouTube rojo */
}

.social-link:hover {
    transform: translateY(-2px) scale(1.1);
    color: var(--white);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
}

.newsletter-form .form-control {
    border: none;
    border-radius: 8px 0 0 8px;
    background: rgba(255, 255, 255, 0.1);
    color: var(--white);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.newsletter-form .form-control::placeholder {
    color: rgba(255, 255, 255, 0.7);
}

.newsletter-form .btn {
    border-radius: 0 8px 8px 0;
    border: 1px solid var(--primary-color);
}

/* =============================================
   MODALS
   ============================================= */
.modal-content {
    border-radius: var(--border-radius);
    border: none;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    max-width: 100%;
    overflow-x: hidden;
}

.modal-header {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: var(--white);
    border-radius: var(--border-radius) var(--border-radius) 0 0;
}

.modal-title {
    font-weight: 600;
}

.modal-body {
    padding: 2rem;
    line-height: 1.7;
}

.modal-body h6 {
    color: var(--primary-color);
    font-weight: 600;
    margin-top: 1.5rem;
    margin-bottom: 1rem;
}

.modal-body ul {
    margin-bottom: 1.5rem;
}

.modal-body li {
    margin-bottom: 0.5rem;
}

/* =============================================
   RESPONSIVE DESIGN
   ============================================= */
@media (max-width: 991.98px) {
    .section-padding {
        padding: 60px 0;
    }
    
    .section-title {
        font-size: 2rem;
    }
    
    .product-info {
        padding-left: 0;
        padding-top: 2rem;
    }
    
    /* Mantener oculta la tarjeta de estadísticas en dispositivos medianos */
    .stats-card {
        display: none;
    }
    
    .testimonial-card {
        padding: 2rem 1rem;
    }
}



@media (max-width: 575.98px) {
    /* Optimización de contenedores para dispositivos pequeños */
    .container {
        max-width: 100% !important;
        padding-left: 12px !important;
        padding-right: 12px !important;
    }
    
    .section-padding {
        padding: 40px 0;
    }
    
    /* Optimizar columnas para mejor uso del espacio */
    .col-lg-6, .col-lg-4, .col-lg-8 {
        padding-left: 8px;
        padding-right: 8px;
    }
    
    /* Mejorar imágenes en dispositivos pequeños */
    .blog-card-img {
        height: 230px;
    }
    
    .about-main-image {
        min-height: 290px;
    }
    
    /* CORRECCIÓN CRÍTICA: Optimizar sección Mensaje de Productores en dispositivos pequeños */
    #mensaje .container {
        max-width: 90% !important;
        padding-left: 5% !important;
        padding-right: 5% !important;
    }
    
    #mensaje .col-lg-8 {
        max-width: 100% !important;
        flex: 0 0 100% !important;
        margin: 0 auto !important;
    }
    
    #mensaje .testimonial-card {
        padding: 1.8rem 0.8rem;
        margin: 0 auto;
        text-align: center;
        max-width: none !important;
    }
    
    #mensaje .testimonial-quote {
        font-size: 1rem;
        line-height: 1.6;
        padding: 0;
        text-align: center;
        width: 100%;
    }
    
    /* CORRECCIÓN CRÍTICA: Texto de 'Sobre Nosotros' en dispositivos pequeños */
    #nosotros .section-title {
        font-size: 1.8rem !important;
        line-height: 1.2 !important;
        padding: 0 0.8rem !important;
    }
    
    #nosotros .lead {
        font-size: 1.05rem !important;
        line-height: 1.7 !important;
        padding: 0 0.8rem !important;
        text-align: justify;
    }
    
    #nosotros .certification-text {
        font-size: 0.95rem !important;
        line-height: 1.5 !important;
        padding: 0.8rem !important;
    }
    
    #nosotros p {
        font-size: 1rem !important;
        line-height: 1.6 !important;
        padding: 0 0.8rem !important;
        text-align: justify;
    }
    
    .logo {
        height: 40px;
    }
    
    .brand-line-1 {
        font-size: 0.8rem;
    }
    
    .brand-line-2 {
        font-size: 0.9rem;
    }
    
    .brand-text {
        font-size: 1.2rem;
    }
    
    .carousel-caption h1,
    .carousel-caption .display-4 {
        font-size: 1.5rem;
    }
    
    .carousel-caption p {
        font-size: 1rem;
    }
    
    .btn-lg {
        padding: 10px 20px;
        font-size: 1rem;
    }
    
    /* Mejoras para la sección Sobre Nosotros en móviles */
    .about-image-container {
        min-height: 300px;
        margin-bottom: 1.5rem;
        max-width: 100%;
        padding: 0 10px;
    }
    
    /* Mantener oculta la tarjeta de estadísticas en dispositivos pequeños */
    .stats-card {
        display: none;
    }
    
    .certification-highlight {
        padding: 15px;
    }
    
    .certification-badge {
        font-size: 0.9rem;
    }
    
    .certification-text {
        font-size: 0.85rem;
    }
    
    .certification-details {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .certification-license,
    .certification-date {
        font-size: 0.8rem;
        margin-bottom: 5px;
    }
    
    /* Partners Section - Mobile Small */
    .partners-section {
        padding: 60px 0;
    }
    
    .partners-container {
        padding: 0 15px;
    }
    
    .partners-header {
        margin-bottom: 40px;
    }
    
    .partners-badge {
        font-size: 0.9rem;
        letter-spacing: 1px;
        margin-bottom: 15px;
    }
    
    .partners-title {
        font-size: 1.8rem;
        margin-bottom: 15px;
        line-height: 1.2;
    }
    
    .partners-subtitle {
        font-size: 1rem;
        line-height: 1.5;
        padding: 0 10px;
    }
    
    .partners-grid-simple {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
        margin-top: 30px;
        padding: 0 10px;
    }
    
    .partner-logo-clean {
        width: 130px;
        height: 70px;
        padding: 12px;
        border-radius: 10px;
        background: rgba(255, 255, 255, 0.85);
        border: 1px solid rgba(128, 128, 128, 0.3);
        box-shadow: 
            0 4px 15px rgba(0, 0, 0, 0.1),
            0 2px 8px rgba(0, 0, 0, 0.05);
        /* Ensure all partner logos have consistent size in very small devices */
        min-width: 130px;
        max-width: 130px;
        min-height: 70px;
        max-height: 70px;
    }
    
    .partner-logo-simple:hover .partner-logo-clean {
        transform: scale(1.02);
        background: rgba(255, 255, 255, 0.9);
        /* Maintain size constraints even on hover in small devices */
        min-width: inherit;
        max-width: inherit;
        min-height: inherit;
        max-height: inherit;
    }
    
    /* Ajuste unificado para todos los logos en móvil */
    .partner-logo-simple .partner-logo-clean {
        transform: scale(1);
    }
    
    .partner-logo-simple:hover .partner-logo-clean {
        transform: scale(1.02);
    }
}

/* Media query adicional para dispositivos muy pequeños - RESPONSIVE PERFECTO */
@media (max-width: 480px) {
    /* Optimización de contenedores para dispositivos muy pequeños */
    .container {
        max-width: 100% !important;
        width: 100% !important;
        padding-left: 15px !important;
        padding-right: 15px !important;
        margin: 0 auto !important;
    }
    
    .section-padding {
        padding: 50px 0;
    }
    
    /* Optimizar columnas para mejor uso del espacio y centrado perfecto */
    .row {
        margin-left: 0 !important;
        margin-right: 0 !important;
        width: 100% !important;
        justify-content: center !important;
    }
    
    [class*="col-"] {
        padding-left: 8px !important;
        padding-right: 8px !important;
        width: 100% !important;
        text-align: center !important;
        margin-bottom: 1.5rem !important;
    }
    
    /* Centrado global para todos los elementos de texto */
    h1, h2, h3, h4, h5, h6, p, .lead, .section-title {
        text-align: center !important;
        margin-left: auto !important;
        margin-right: auto !important;
        max-width: 100% !important;
    }
    
    /* Mejorar imágenes en dispositivos pequeños */
    .blog-card-img {
        height: 220px;
    }
    
    .about-main-image {
        min-height: 280px;
    }
    
    /* CORRECCIÓN CRÍTICA: Optimizar sección Mensaje de Productores en dispositivos muy pequeños */
    #mensaje .container {
        max-width: 90% !important;
        padding-left: 5% !important;
        padding-right: 5% !important;
    }
    
    #mensaje .col-lg-8 {
        max-width: 100% !important;
        flex: 0 0 100% !important;
        margin: 0 auto !important;
    }
    
    #mensaje .testimonial-card {
        padding: 1.5rem 0.6rem;
        margin: 0 auto;
        text-align: center;
        max-width: none !important;
    }
    
    #mensaje .testimonial-quote {
        font-size: 0.95rem;
        line-height: 1.5;
        padding: 0;
        text-align: center;
        width: 100%;
    }
    
    /* CORRECCIÓN CRÍTICA: Sección 'Sobre Nosotros' perfectamente centrada en 480px */
    #nosotros {
        text-align: center !important;
    }
    
    #nosotros .container {
        max-width: 100% !important;
        padding-left: 15px !important;
        padding-right: 15px !important;
    }
    
    #nosotros .row {
        justify-content: center !important;
        align-items: center !important;
    }
    
    #nosotros .col-lg-6 {
        width: 100% !important;
        max-width: 100% !important;
        text-align: center !important;
        margin-bottom: 2rem !important;
    }
    
    #nosotros .section-title {
        font-size: 1.8rem !important;
        line-height: 1.3 !important;
        padding: 0 !important;
        text-align: center !important;
        margin-bottom: 1.5rem !important;
    }
    
    #nosotros .lead {
        font-size: 1.05rem !important;
        line-height: 1.6 !important;
        padding: 0 !important;
        text-align: center !important;
        margin-bottom: 1.5rem !important;
    }
    
    #nosotros .certification-text {
        font-size: 0.95rem !important;
        line-height: 1.5 !important;
        padding: 0 !important;
        text-align: center !important;
    }
    
    #nosotros p {
        font-size: 1rem !important;
        line-height: 1.6 !important;
        padding: 0 !important;
        text-align: center !important;
        margin-bottom: 1.2rem !important;
    }
    
    #nosotros .pe-lg-4 {
        padding: 0 !important;
        text-align: center !important;
    }
    
    /* Mejoras para el carrusel en dispositivos muy pequeños */
    .carousel-caption {
        padding: 0.8rem;
        display: flex !important;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        position: absolute !important;
        bottom: 50px !important;
        left: 50% !important;
        right: auto !important;
        transform: translateX(-50%) !important;
        width: 95% !important;
        max-width: 400px !important;
        margin: 0 !important;
    }
    
    .carousel-caption h1,
    .carousel-caption .display-4 {
        font-size: 1.5rem;
        margin-bottom: 0.3rem;
    }
    
    .carousel-caption h2,
    .carousel-caption .display-5 {
        font-size: 1.3rem;
        margin-bottom: 0.3rem;
    }
    
    .carousel-caption p.lead {
        font-size: 0.9rem;
        margin-bottom: 0.8rem;
    }
    
    .carousel-caption .btn-lg {
        padding: 0.4rem 0.8rem;
        font-size: 0.8rem;
    }
    
    /* Mejoras para la sección Sobre Nosotros en dispositivos muy pequeños */
    .about-image-container {
        min-height: 250px;
        max-width: 100%;
        padding: 0 5px;
        margin: 0 auto;
    }
    
    .about-main-image {
        object-fit: cover;
        height: 100%;
        width: 100%;
        border-radius: 12px !important;
    }
    
    /* Mantener oculta la tarjeta de estadísticas en dispositivos pequeños */
    .stats-card {
        display: none;
    }
    
    .certification-highlight {
        padding: 12px;
    }
    
    /* Mejoras para el menú de hamburguesa */
    .custom-navbar .container {
        display: flex;
        justify-content: space-between;
        align-items: center;
        flex-wrap: nowrap;
    }
    
    .navbar-brand {
        order: 1;
        flex: 0 0 auto;
    }
    
    .navbar-toggler {
        padding: 0.3rem 0.5rem;
        font-size: 1rem;
        position: relative;
        z-index: 1051;
        order: 2;
        margin-left: auto;
        flex: 0 0 auto;
    }
    
    /* Estilos duplicados removidos - ahora manejados en el media query principal */
    
    /* Mejoras para la sección de partners en dispositivos móviles */
     .partners-section {
         padding: 50px 0;
         max-width: 100%;
         overflow-x: hidden;
     }
     
     .partners-container {
         padding: 0 10px;
         max-width: 100%;
     }
     
     .partners-title {
         font-size: 1.6rem;
         line-height: 1.1;
     }
     
     .partners-subtitle {
         font-size: 0.95rem;
         padding: 0 5px;
     }
     
     .partners-grid-simple {
         gap: 15px;
         padding: 0 5px;
         grid-template-columns: repeat(2, 1fr);
     }
     
     .partner-logo-clean {
         width: 120px;
         height: 65px;
         padding: 10px;
         border-radius: 8px;
     }
}

/* Media query para dispositivos extra pequeños - RESPONSIVE PERFECTO */
@media (max-width: 375px) {
    /* Optimización máxima de contenedores para dispositivos extra pequeños */
    .container {
        max-width: 100% !important;
        width: 100% !important;
        padding-left: 12px !important;
        padding-right: 12px !important;
        margin: 0 auto !important;
    }
    
    .section-padding {
        padding: 45px 0;
    }
    
    /* Optimizar columnas para máximo aprovechamiento del espacio y centrado perfecto */
    .row {
        margin-left: 0 !important;
        margin-right: 0 !important;
        width: 100% !important;
        justify-content: center !important;
    }
    
    [class*="col-"] {
        padding-left: 6px !important;
        padding-right: 6px !important;
        width: 100% !important;
        text-align: center !important;
        margin-bottom: 1.5rem !important;
    }
    
    /* Centrado global para todos los elementos de texto */
    h1, h2, h3, h4, h5, h6, p, .lead, .section-title {
        text-align: center !important;
        margin-left: auto !important;
        margin-right: auto !important;
        max-width: 100% !important;
    }
    
    /* Mejorar imágenes en dispositivos extra pequeños */
    .blog-card-img {
        height: 200px;
    }
    
    .about-main-image {
        min-height: 260px;
    }
    
    /* Optimizar texto y espaciado */
    .testimonial-card {
        padding: 1.5rem 0.8rem;
    }
    
    .blog-card {
        margin-bottom: 1rem;
    }
    
    /* Mejoras para la sección Sobre Nosotros en dispositivos extremadamente pequeños */
    .about-image-container {
        min-height: 240px;
        max-width: 100%;
        padding: 0;
        margin: 0 auto 1rem;
    }
    
    .about-main-image {
        object-fit: cover;
        height: 100%;
        width: 100%;
        border-radius: 10px !important;
    }
    
    /* Mantener oculta la tarjeta de estadísticas en dispositivos extremadamente pequeños */
    .stats-card {
        display: none;
    }
    
    .certification-highlight {
        padding: 10px;
        margin-bottom: 1rem;
    }
    
    .certification-badge {
        font-size: 0.8rem;
    }
    
    .certification-text {
        font-size: 0.8rem;
        line-height: 1.4;
    }
    
    .certification-details {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.2rem;
    }
    
    .certification-license,
    .certification-date {
        font-size: 0.75rem;
    }
    
    /* Optimizar el contenido de texto */
    .pe-lg-4 {
        padding-right: 0 !important;
        margin-bottom: 1.5rem;
    }
    
    .section-title {
        font-size: 1.8rem;
        margin-bottom: 1rem;
    }
    
    .lead {
        font-size: 1rem;
        line-height: 1.5;
    }
    
    /* CORRECCIÓN CRÍTICA: Optimizar sección Mensaje de Productores en dispositivos extremadamente pequeños */
    #mensaje .container {
        max-width: 90% !important;
        padding-left: 5% !important;
        padding-right: 5% !important;
    }
    
    #mensaje .col-lg-8 {
        max-width: 100% !important;
        flex: 0 0 100% !important;
        margin: 0 auto !important;
        padding-left: 5px !important;
        padding-right: 5px !important;
    }
    
    #mensaje .testimonial-card {
        padding: 1.2rem 0.4rem;
        margin: 0 auto;
        text-align: center;
        max-width: none !important;
    }
    
    #mensaje .testimonial-quote {
        font-size: 0.9rem;
        line-height: 1.4;
        padding: 0;
        margin-bottom: 1rem;
        text-align: center;
        width: 100%;
    }
    
    #mensaje .testimonial-img {
        margin-bottom: 1rem;
    }
    
    #mensaje .testimonial-img img {
        width: 80px;
        height: 80px;
    }
    
    /* CORRECCIÓN CRÍTICA: Sección 'Sobre Nosotros' perfectamente centrada en 375px */
    #nosotros {
        text-align: center !important;
    }
    
    #nosotros .container {
        max-width: 100% !important;
        padding-left: 12px !important;
        padding-right: 12px !important;
    }
    
    #nosotros .row {
        justify-content: center !important;
        align-items: center !important;
    }
    
    #nosotros .col-lg-6 {
        width: 100% !important;
        max-width: 100% !important;
        text-align: center !important;
        margin-bottom: 1.5rem !important;
    }
    
    #nosotros .section-title {
        font-size: 1.7rem !important;
        line-height: 1.2 !important;
        padding: 0 !important;
        text-align: center !important;
        margin-bottom: 1.5rem !important;
    }
    
    #nosotros .lead {
        font-size: 1rem !important;
        line-height: 1.5 !important;
        padding: 0 !important;
        text-align: center !important;
        margin-bottom: 1.3rem !important;
    }
    
    #nosotros .certification-text {
        font-size: 0.9rem !important;
        line-height: 1.4 !important;
        padding: 0 !important;
        text-align: center !important;
    }
    
    #nosotros p {
        font-size: 0.95rem !important;
        line-height: 1.5 !important;
        padding: 0 !important;
        text-align: center !important;
        margin-bottom: 1.2rem !important;
    }
    
    #nosotros .certification-badge {
        font-size: 0.8rem !important;
        text-align: center !important;
    }
    
    #nosotros .pe-lg-4 {
        padding: 0 !important;
        text-align: center !important;
    }
    
    /* Mejoras para el carrusel en dispositivos extremadamente pequeños */
    .carousel-caption {
        padding: 0.6rem;
        display: flex !important;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        position: absolute !important;
        bottom: 40px !important;
        left: 50% !important;
        right: auto !important;
        transform: translateX(-50%) !important;
        width: 95% !important;
        max-width: 350px !important;
        margin: 0 !important;
    }
    
    .carousel-caption h1,
    .carousel-caption .display-4 {
        font-size: 1.3rem;
        margin-bottom: 0.2rem;
    }
    
    .carousel-caption h2,
    .carousel-caption .display-5 {
        font-size: 1.1rem;
        margin-bottom: 0.2rem;
    }
    
    .carousel-caption p.lead {
        font-size: 0.8rem;
        margin-bottom: 0.6rem;
    }
    
    .carousel-caption .btn-lg {
        padding: 0.3rem 0.6rem;
        font-size: 0.75rem;
    }
    
    /* Mejoras para la sección Sobre Nosotros en dispositivos extra pequeños */
    .about-image-container {
        min-height: 220px;
        max-width: 100%;
        padding: 0;
        margin: 0 auto;
    }
    
    .about-main-image {
        border-radius: 10px !important;
    }
    
    /* Mantener oculta la tarjeta de estadísticas en dispositivos extra pequeños */
    .stats-card {
        display: none;
    }
    
    .stats-number {
        font-size: 1.2rem;
        margin-bottom: 0.2rem;
    }
    
    .stats-label {
        font-size: 0.6rem;
        letter-spacing: 0.5px;
    }
    
    .stats-item:not(:last-child)::after {
        height: 25px;
        right: -0.5rem;
    }
    
    /* Mejoras para el menú de hamburguesa en pantallas muy pequeñas - estilos heredados del general */
    
    .navbar-nav .nav-link {
        font-size: 0.9rem;
        padding: 0.4rem 0.8rem;
    }
    
    /* Ajustes para partners */
    .partners-section {
        padding: 40px 0;
        max-width: 100%;
        overflow-x: hidden;
    }
    
    .partners-grid-simple {
        grid-template-columns: 1fr 1fr;
        gap: 10px;
        max-width: 300px;
        margin: 25px auto 0;
    }
    
    .partners-title {
        font-size: 1.4rem;
    }
    
    .partners-subtitle {
        font-size: 0.9rem;
    }
    
    .partners-grid-simple {
        grid-template-columns: 1fr 1fr;
        gap: 12px;
        max-width: 300px;
        margin: 25px auto 0;
    }
    
    .partner-logo-clean {
        width: 110px;
        height: 60px;
        padding: 8px;
        border-radius: 8px;
        /* Ensure all partner logos have consistent size in extremely small devices */
        min-width: 110px;
        max-width: 110px;
        min-height: 60px;
        max-height: 60px;
    }
    
    /* Mantener todos los logos con el mismo tamaño en dispositivos muy pequeños */
    .partner-logo-simple .partner-logo-clean {
        transform: scale(1.0);
        /* Ensure consistent size is maintained */
        min-width: 110px;
        max-width: 110px;
        min-height: 60px;
        max-height: 60px;
    }
    
    .partner-logo-simple:hover .partner-logo-clean {
        transform: scale(1.02);
    }
}

/* =============================================
   CERTIFICACION DESTACADA STYLES
   ============================================= */

.certification-highlight {
    background: linear-gradient(135deg, rgba(46, 125, 50, 0.05), rgba(76, 175, 80, 0.05));
    border: 2px solid rgba(46, 125, 50, 0.2);
    border-radius: var(--border-radius);
    padding: 16px 20px;
    position: relative;
    overflow: hidden;
    margin-bottom: 0;
    max-width: 95%;
    margin-left: auto;
    margin-right: auto;
}

.certification-highlight::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color), var(--warning-color));
    border-radius: var(--border-radius) var(--border-radius) 0 0;
}

.certification-badge {
    display: flex;
    align-items: center;
    margin-bottom: 8px;
    font-size: 1rem;
    color: var(--primary-color);
}

.certification-badge i {
    font-size: 1.2rem;
    color: var(--warning-color);
}

.certification-text {
    margin-bottom: 12px;
    font-size: 0.9rem;
    line-height: 1.5;
    color: var(--text-dark);
}

.certification-details {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    font-size: 0.8rem;
    color: var(--text-muted);
}

.certification-license {
    background: rgba(46, 125, 50, 0.1);
    padding: 3px 10px;
    border-radius: 15px;
    font-weight: 500;
}

.certification-date {
    background: rgba(245, 124, 0, 0.1);
    padding: 3px 10px;
    border-radius: 15px;
    font-weight: 500;
}

/* =============================================
   ENHANCED CERTIFICATION STYLES
   ============================================= */
.certification-content {
    display: flex;
    align-items: center;
    gap: 20px;
}

.certification-logo {
    flex-shrink: 0;
}

.fami-agri-logo {
    width: 115px;
    height: auto;
    max-height: 86px;
    object-fit: contain;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: var(--transition);
}

.fami-agri-logo:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.certification-info {
    flex: 1;
}

/* Responsive para certificación */
@media (max-width: 768px) {
    .certification-highlight {
        padding: 12px 16px;
    }
    
    .certification-badge {
        font-size: 0.95rem;
    }
    
    .certification-text {
        font-size: 0.85rem;
    }
    
    .certification-details {
        flex-direction: column;
        gap: 8px;
    }
    
    /* Certification content responsive adjustments */
    .certification-content {
        flex-direction: column;
        text-align: center;
        gap: 15px;
    }
    
    .fami-agri-logo {
        width: 100px;
        max-height: 72px;
    }
}

@media (max-width: 480px) {
    .certification-content {
        gap: 12px;
    }
    
    .fami-agri-logo {
        width: 86px;
        max-height: 65px;
    }
    
    .certification-badge {
        font-size: 0.9rem;
    }
    
    .certification-text {
        font-size: 0.8rem;
    }
}

@media (max-width: 375px) {
    .fami-agri-logo {
        width: 79px;
        max-height: 58px;
    }
    
    .certification-badge {
        font-size: 0.85rem;
    }
    
    .certification-text {
        font-size: 0.75rem;
        line-height: 1.4;
    }
}

/* =============================================
   ANIMATIONS
   ============================================= */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.fade-in-up {
    animation: fadeInUp 0.8s ease-out;
}

.fade-in {
    animation: fadeIn 0.6s ease-out;
}

/* Scroll Behavior */
html {
    scroll-behavior: smooth;
}

/* Loading States */
.loading {
    opacity: 0.7;
    pointer-events: none;
}

/* Focus States */
.btn:focus,
.form-control:focus {
    box-shadow: 0 0 0 0.2rem rgba(46, 125, 50, 0.25);
}

/* =============================================
   UTILITY CLASSES
   ============================================= */
.text-primary-custom {
    color: var(--primary-color) !important;
}

.bg-primary-custom {
    background-color: var(--primary-color) !important;
}

.border-primary-custom {
    border-color: var(--primary-color) !important;
}

.shadow-custom {
    box-shadow: var(--box-shadow) !important;
}

.rounded-custom {
    border-radius: var(--border-radius) !important;
}

/* Asegurar que el contenedor padre tenga el contexto correcto */
.col-lg-6 .position-relative {
    position: relative;
    z-index: 1;
}

/* Mejoras adicionales para la imagen */
.img-fluid.rounded-3.shadow {
    position: relative;
    z-index: 1;
}

/* Contenedor de la sección para mejor contexto */
#nosotros .container {
    position: relative;
    z-index: 2;
    max-width: 100%;
    overflow-x: hidden;
    padding-left: 15px;
    padding-right: 15px;
}

/* Mejora del contraste para mejor legibilidad */
.stats-card {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.98) 0%, rgba(248, 249, 250, 0.95) 100%);
    border: 1px solid rgba(255, 255, 255, 0.4);
}

/* Sombra más definida para destacar sobre la imagen */
.stats-card {
    box-shadow: 
        0 12px 48px rgba(0, 0, 0, 0.18),
        0 6px 16px rgba(0, 0, 0, 0.12),
        inset 0 1px 0 rgba(255, 255, 255, 0.9),
        0 0 0 1px rgba(255, 255, 255, 0.3);
}

/* Efecto hover mejorado */
.stats-card:hover {
    box-shadow: 
        0 18px 60px rgba(0, 0, 0, 0.22),
        0 10px 24px rgba(0, 0, 0, 0.15),
        inset 0 1px 0 rgba(255, 255, 255, 1),
        0 0 0 1px rgba(255, 255, 255, 0.5);
}

/* Mejoras para máxima legibilidad y contraste */
.stats-number {
    position: relative;
    font-weight: 900;
    text-shadow: 
        0 2px 8px rgba(0, 0, 0, 0.15),
        0 1px 3px rgba(0, 0, 0, 0.1);
}

.stats-label {
    position: relative;
    font-weight: 700;
    color: #4a4a4a;
    text-shadow: 0 1px 2px rgba(255, 255, 255, 0.8);
}

/* Animación de pulso sutil para llamar la atención */
@keyframes subtlePulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.02); }
}

.stats-card {
    animation: 
        statsCardSlideIn 0.8s cubic-bezier(0.4, 0, 0.2, 1) 0.5s both,
        subtlePulse 4s ease-in-out 2s infinite;
}

/* Media query específica para asegurar visibilidad en pantallas pequeñas */
@media (max-width: 991.98px) {
    .stats-card {
        background: rgba(255, 255, 255, 0.98);
        border: 2px solid rgba(46, 125, 50, 0.1);
        box-shadow: 
            0 15px 50px rgba(0, 0, 0, 0.2),
            0 8px 20px rgba(0, 0, 0, 0.1);
    }
}
