/* NOSOTROS SECTION */
.nosotros-section {
    padding: 100px 0;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    position: relative;
}

/* Prevenir cambios de tamaño con zoom */
.nosotros-section * {
    -webkit-text-size-adjust: 100%;
    -moz-text-size-adjust: 100%;
    -ms-text-size-adjust: 100%;
    text-size-adjust: 100%;
}

/* Contenido principal */
.nosotros-content {
    padding-right: 2rem;
}

.nosotros-section .section-title {
    font-size: 3rem;
    font-weight: 800;
    color: #2c3e50;
    margin-bottom: 2rem;
    position: relative;
}

.nosotros-section .section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 0;
    width: 80px;
    height: 4px;
    background: #e74c3c;
    border-radius: 2px;
}

.nosotros-description {
    font-size: 1.2rem;
    line-height: 1.8;
    color: #5a6c7d;
    margin-bottom: 3rem;
}

.text-accent {
    color: #e74c3c;
    font-weight: 700;
}

/* Misión y Visión */
.mision-vision {
    margin-bottom: 3rem;
}

.mv-item {
    display: flex;
    align-items: flex-start;
    margin-bottom: 2rem;
    padding: 2rem;
    background: white;
    border-radius: 15px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    border-left: 4px solid #e74c3c;
}

.mv-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.15);
}

.mv-mision {
    border-left-color: #e74c3c;
}

.mv-vision {
    border-left-color: #3498db;
}

.mv-icon {
    width: 70px;
    height: 70px;
    background: linear-gradient(135deg, #e74c3c, #c0392b);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.8rem;
    margin-right: 1.5rem;
    flex-shrink: 0;
}

.mv-vision .mv-icon {
    background: linear-gradient(135deg, #3498db, #2980b9);
}

.mv-content h4 {
    font-size: 1.5rem;
    font-weight: 700;
    color: #2c3e50;
    margin-bottom: 1rem;
}

.mv-content p {
    color: #5a6c7d;
    line-height: 1.7;
    font-style: italic;
    margin: 0;
    font-size: 1.1rem;
}

/* Características en horizontal */
.nosotros-features {
    margin: 3rem 0;
}

.feature-card {
    text-align: center;
    padding: 2rem 1.5rem;
    background: white;
    border-radius: 15px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.08);
    transition: all 0.4s ease;
    height: 100%;
    border: 2px solid transparent;
    position: relative;
    overflow: hidden;
    /* Nuevas propiedades añadidas */
    min-height: 200px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.feature-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(231, 76, 60, 0.05), transparent);
    transition: left 0.6s ease;
}

.feature-card:hover::before {
    left: 100%;
}

.feature-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.15);
    border-color: #e74c3c;
}

.feature-card .feature-icon {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, #e74c3c, #c0392b);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    color: white;
    font-size: 2rem;
    transition: all 0.4s ease;
}

.feature-card:hover .feature-icon {
    transform: scale(1.1) rotate(5deg);
    box-shadow: 0 10px 25px rgba(231, 76, 60, 0.3);
}

.feature-card h4 {
    font-size: 1.3rem;
    font-weight: 700;
    color: #2c3e50;
    margin-bottom: 1rem;
}

.feature-card p {
    color: #7f8c8d;
    line-height: 1.6;
    margin: 0;
    font-size: 0.95rem;
}

/* Estadísticas */
.nosotros-stats {
    display: flex;
    justify-content: space-around;
    text-align: center;
    padding: 2.5rem 1rem;
    background: white;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    flex-wrap: wrap;
    gap: 1rem;
    /* Nueva propiedad añadida */
    width: 100%;
    box-sizing: border-box;
}

.nosotros-stats .stat-item {
    flex: 1;
    min-width: 150px;
    /* Nuevas propiedades añadidas */
    flex-shrink: 0;
    flex-grow: 0;
    flex-basis: auto;
}

.nosotros-stats .stat-item h3 {
    font-size: 2.5rem;
    font-weight: 800;
    color: #e74c3c;
    margin-bottom: 0.5rem;
}

.nosotros-stats .stat-item p {
    color: #5a6c7d;
    font-weight: 500;
    margin: 0;
}

/* Imagen */
.nosotros-image {
    position: relative;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
    /* Añade estas propiedades */
    max-height: 500px; /* Altura máxima */
    display: flex;
    align-items: center;
    justify-content: center;
}

.nosotros-image img {
    width: 100%;
    height: auto;
    transition: transform 0.5s ease;
    /* Añade esta propiedad */
    max-height: 500px;
    object-fit: cover;
}

.nosotros-image:hover img {
    transform: scale(1.05);
}

.nosotros-image .image-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(231, 76, 60, 0.9), rgba(192, 57, 43, 0.8));
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: all 0.3s ease;
}

.nosotros-image:hover .image-overlay {
    opacity: 1;
}

.nosotros-image .overlay-content {
    text-align: center;
    color: white;
}

.nosotros-image .overlay-content i {
    font-size: 3rem;
    margin-bottom: 1rem;
    display: block;
}

.nosotros-image .overlay-content p {
    font-size: 1.2rem;
    font-weight: 600;
    margin: 0;
}

/* Valores */
.valores-section {
    margin-top: 100px;
}

.valores-section .valores-title {
    font-size: 2.5rem;
    font-weight: 800;
    color: #2c3e50;
    margin-bottom: 3rem;
    position: relative;
}

.nosotros-section .section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;  /* Cambia de 0 a 50% */
    transform: translateX(-50%);  /* Añade esto */
    width: 80px;
    height: 4px;
    background: #e74c3c;
    border-radius: 2px;
}

.valores-section .valor-card {
    text-align: center;
    padding: 2rem 1rem;
    background: white;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    height: 100%;
}

.valores-section .valor-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

.valores-section .valor-icon {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, #3498db, #2980b9);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    color: white;
    font-size: 2rem;
    transition: all 0.3s ease;
}

.valores-section .valor-card:hover .valor-icon {
    transform: scale(1.1) rotate(5deg);
}

.valores-section .valor-card:nth-child(1) .valor-icon {
    background: linear-gradient(135deg, #3498db, #2980b9);
}

.valores-section .valor-card:nth-child(2) .valor-icon {
    background: linear-gradient(135deg, #e74c3c, #c0392b);
}

.valores-section .valor-card:nth-child(3) .valor-icon {
    background: linear-gradient(135deg, #f39c12, #e67e22);
}

.valores-section .valor-card:nth-child(4) .valor-icon {
    background: linear-gradient(135deg, #9b59b6, #8e44ad);
}

.valores-section .valor-card h4 {
    font-size: 1.4rem;
    font-weight: 700;
    color: #2c3e50;
    margin-bottom: 1rem;
}

.valores-section .valor-card p {
    color: #7f8c8d;
    line-height: 1.6;
    margin: 0;
}

/* Responsive */
@media (max-width: 991.98px) {
    .nosotros-content {
        padding-right: 0;
        margin-bottom: 3rem;
    }
    
    .nosotros-section .section-title {
        font-size: 2.5rem;
    }
    
    .nosotros-stats {
        flex-direction: row; /* Mantener en fila en tablet */
        gap: 1rem;
        justify-content: center;
        flex-wrap: wrap;
    }
    
    .mv-item {
        flex-direction: column;
        text-align: center;
    }
    
    .mv-icon {
        margin-right: 0;
        margin-bottom: 1rem;
    }
    
    /* Nuevo: ajustes para tablet */
    .feature-card {
        min-height: 180px;
        padding: 1.5rem 1rem;
    }
}

@media (max-width: 768px) {
    .nosotros-section {
        padding: 60px 0;
    }
    
    .nosotros-section .section-title {
        font-size: 2rem;
    }
    
    .nosotros-description {
        font-size: 1.1rem;
    }
    
    .nosotros-features .feature-item {
        flex-direction: column;
        text-align: center;
    }
    
    .nosotros-features .feature-icon {
        margin-right: 0;
        margin-bottom: 1rem;
    }
    
    .valores-section .valores-title {
        font-size: 2rem;
    }
    
    .valores-section .valor-card {
        margin-bottom: 2rem;
    }
    
    /* MÓVIL: Fijar dimensiones para evitar cambios con zoom */
    .feature-card {
        min-height: 160px; /* Altura fija en móvil */
        padding: 20px 15px; /* Padding fijo en px */
        width: 100%; /* Ancho completo */
        max-width: 100%;
        box-sizing: border-box;
    }
    
    .feature-icon {
        width: 60px !important; /* Tamaño fijo en px */
        height: 60px !important; /* Tamaño fijo en px */
        font-size: 1.5rem !important;
        margin: 0 auto 15px !important; /* Margen fijo en px */
    }
    
    .feature-card h4 {
        font-size: 1.1rem; /* Tamaño de fuente fijo */
        margin-bottom: 10px; /* Margen fijo en px */
    }
    
    .feature-card p {
        font-size: 0.9rem; /* Tamaño de fuente fijo */
        line-height: 1.4;
    }
    
    /* Estadísticas en móvil */
    .nosotros-stats {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
        padding: 20px 15px;
    }
    
    .nosotros-stats .stat-item {
        min-width: unset;
        width: 100%;
    }
    
    .nosotros-stats .stat-item h3 {
        font-size: 1.8rem; /* Tamaño fijo */
        margin-bottom: 5px;
    }
    
    .nosotros-stats .stat-item p {
        font-size: 0.9rem; /* Tamaño fijo */
    }
    
    /* Contenedor de características en móvil */
    .nosotros-features .row {
        margin: 0;
    }
    
    .nosotros-features .col-md-6 {
        padding: 8px !important; /* Padding fijo */
    }
}

@media (max-width: 576px) {
    .nosotros-section .section-title {
        font-size: 1.8rem;
    }
    
    .mv-item {
        padding: 1.5rem;
    }
    
    .nosotros-features .feature-item {
        padding: 1rem;
    }
    
    /* Ajustes adicionales para móviles pequeños */
    .feature-card {
        min-height: 150px;
        padding: 15px 10px;
    }
    
    .feature-icon {
        width: 50px !important;
        height: 50px !important;
        font-size: 1.3rem !important;
        margin-bottom: 10px !important;
    }
    
    .feature-card h4 {
        font-size: 1rem;
    }
    
    .feature-card p {
        font-size: 0.85rem;
    }
    
    .nosotros-stats .stat-item h3 {
        font-size: 1.5rem;
    }
    
    .valores-section .valores-title {
        font-size: 1.8rem;
    }
    
    /* Para pantallas muy pequeñas, estadísticas en una columna */
    @media (max-width: 380px) {
        .nosotros-stats {
            grid-template-columns: 1fr;
        }
    }
}

/* Soporte para iOS */
@supports (-webkit-touch-callout: none) {
    .nosotros-section * {
        -webkit-touch-callout: none;
    }
    
    .feature-card,
    .nosotros-stats .stat-item,
    .nosotros-image {
        transform: translateZ(0);
        -webkit-transform: translateZ(0);
    }
}

/* Opcional: Prevenir zoom específico en la sección nosotros en móvil */
@media (max-width: 768px) {
    .nosotros-section {
        touch-action: pan-y;
    }
    
    .feature-card,
    .nosotros-stats {
        pointer-events: auto;
    }
}
/* Ajustes responsivos */
@media (max-width: 1400px) {
    .nosotros-image,
    .nosotros-image img {
        max-height: 450px;
    }
}

@media (max-width: 1200px) {
    .nosotros-image,
    .nosotros-image img {
        max-height: 400px;
    }
}

@media (max-width: 992px) {
    .nosotros-image,
    .nosotros-image img {
        max-height: 350px;
    }
}

@media (max-width: 768px) {
    .nosotros-image,
    .nosotros-image img {
        max-height: 300px;
    }
}

/* Historia Heroica */
.historia-destacada {
    font-size: 1.4rem;
    line-height: 1.8;
    color: #2c3e50;
    position: relative;
    padding: 0 1.5rem;
}

.historia-timeline {
    position: relative;
    padding-left: 2rem;
}

.historia-timeline::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 3px;
    background: linear-gradient(to bottom, #e74c3c, #3498db);
    border-radius: 3px;
}

.timeline-item {
    position: relative;
}

.timeline-item::before {
    content: '';
    position: absolute;
    left: -2.4rem;
    top: 0.5rem;
    width: 12px;
    height: 12px;
    background: #e74c3c;
    border-radius: 50%;
    border: 3px solid white;
    box-shadow: 0 0 0 3px #e74c3c;
}

.timeline-year {
    font-size: 0.9rem;
    padding: 0.4rem 1rem;
    font-weight: 600;
}

.historia-legado {
    border-left: 4px solid #e74c3c;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
}

.cta-historia {
    padding: 1.5rem;
    background: linear-gradient(135deg, rgba(231, 76, 60, 0.1), rgba(52, 152, 219, 0.1));
    border-radius: 10px;
    border: 2px solid transparent;
    background-clip: padding-box;
    position: relative;
}

.cta-historia::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: linear-gradient(135deg, #e74c3c, #3498db);
    border-radius: 12px;
    z-index: -1;
}