/* Header & Navbar */
/* Header & Navbar (Sombreado oscuro eliminado) */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 8%;
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 100;
    background: transparent;
    transition: var(--transition-smooth);
}

.navbar .logo {
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

/* Control del tamaño del logo */
.logo img {
    max-height: 80px; /* Limita el tamaño del logo */
    width: auto;
    border-radius: 50%; /* Opcional: redondea el fondo blanco cuadrado de la imagen */
    transition: var(--transition-smooth);
}

.logo img:hover {
    transform: scale(1.05);
}

/* Navbar al hacer scroll (se mantiene igual para el fondo blanco) */
.navbar.scrolled {
    background-color: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(10px);
    box-shadow: 0 4px 20px rgba(0,0,0,0.08);
    padding: 10px 8%;
}

.navbar.scrolled .logo img {
    max-height: 60px; /* Se reduce un poco más al hacer scroll para mayor elegancia */
}

.navbar.scrolled .logo {
    opacity: 1;
    visibility: visible;
}

.navbar.scrolled .logo-fallback {
    color: var(--dark-color);
}

.navbar.scrolled .nav-links a {
    color: var(--dark-color);
    text-shadow: none;
}

.nav-links {
    list-style: none;
    display: flex;
    gap: 35px;
}

.nav-links a {
    color: #ffffff;
    font-weight: 600; 
    text-shadow: 0 2px 5px rgba(0, 0, 0, 0.7);
    position: relative;
}

.nav-links a::after {
    content: '';
    position: absolute;
    width: 0%;
    height: 2px;
    bottom: -6px;
    left: 0;
    background-color: var(--primary-color);
    transition: var(--transition-smooth);
}

.nav-links a:hover::after, 
.nav-links a.active::after {
    width: 100%;
}

/* =========================================
   Ajuste del Hero para que la imagen suba
========================================= */
.nosotros-hero {
    margin-top: 0 !important; /* Quitamos el margen para que la imagen tope arriba */
}

/* Utilidades contenedoras */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 5%;
}

.text-center {
    text-align: center;
}

.section-subtitle {
    color: var(--primary-color);
    font-weight: 600;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    display: block;
    margin-bottom: 10px;
}

/* 1. Nosotros Hero */
.nosotros-hero {
    position: relative;
    height: 100vh !important;
    min-height: auto;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 0 5%;
    /* Reemplazar con una imagen de fondo elegante del local o equipo */
    background: url('../assets/img/fondo/image5.png') center/cover no-repeat;
    color: #ffffff;
    margin-top: 0 !important;
}

.nosotros-hero::before {
    content: '';
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0, 0, 0, 0.6); /* Overlay oscuro para legibilidad */
    z-index: 1;
}

.nosotros-hero .hero-content {
    position: relative;
    z-index: 2;
    max-width: 800px;
}

.nosotros-hero h1 {
    font-size: 3.5rem;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 15px;
    text-shadow: 0 2px 10px rgba(0,0,0,0.3);
}

.nosotros-hero p {
    font-size: 1.2rem;
    opacity: 0.9;
    font-weight: 300;
}

/* 2. Nuestra Historia */
.nuestra-historia {
    padding: 100px 0;
    background-color: var(--bg-color);
}

.historia-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
    align-items: center;
}

.historia-text h2 {
    font-size: 2.8rem;
    color: var(--dark-color);
    margin-bottom: 25px;
    line-height: 1.2;
}

.historia-text p {
    color: var(--text-muted);
    margin-bottom: 20px;
    font-size: 1.05rem;
}

.historia-image img {
    width: 100%;
    height: auto;
    border-radius: 20px;
    box-shadow: var(--shadow-soft);
    object-fit: cover;
}

/* 3. Misión y Visión */
.mision-vision {
    padding: 100px 0;
    background-color: var(--light-bg); /* Fondo crema suave */
}

.mv-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
}

.mv-card {
    background-color: #ffffff;
    padding: 50px;
    border-radius: 16px;
    box-shadow: var(--shadow-soft);
    border: 1px solid var(--border-color);
    transition: var(--transition-smooth);
    text-align: center;
}

.mv-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
}

.mv-icon {
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 25px;
    display: inline-block;
    padding: 20px;
    background-color: rgba(251, 110, 30, 0.1);
    border-radius: 50%;
}

.mv-card h3 {
    font-size: 1.8rem;
    color: var(--dark-color);
    margin-bottom: 20px;
}

.mv-card p {
    color: var(--text-muted);
    font-size: 1rem;
    line-height: 1.7;
}

/* 4. Nuestros Valores */
.nuestros-valores {
    padding: 100px 0;
    background-color: var(--bg-color);
}

.valores-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    margin-top: 60px;
}

.valor-item {
    text-align: center;
    padding: 30px;
    background-color: #ffffff;
    border-radius: 12px;
    border: 1px solid var(--border-color);
    transition: var(--transition-smooth);
}

.valor-item:hover {
    background-color: var(--light-bg);
    border-color: rgba(251, 110, 30, 0.2);
}

.valor-item i {
    font-size: 2rem;
    color: var(--primary-color);
    margin-bottom: 20px;
}

.valor-item h4 {
    font-size: 1.3rem;
    color: var(--dark-color);
    margin-bottom: 10px;
}

.valor-item p {
    color: var(--text-muted);
    font-size: 0.95rem;
}

/* Responsividad */
@media (max-width: 992px) {
    .historia-grid {
        grid-template-columns: 1fr;
        gap: 50px;
    }
    .historia-text {
        order: 2;
    }
    .historia-image {
        order: 1;
    }
    .historia-text h2 {
        font-size: 2.2rem;
    }
}

@media (max-width: 768px) {
    .nosotros-hero h1 {
        font-size: 2.5rem;
    }
    .mv-grid {
        grid-template-columns: 1fr;
    }
    .mv-card {
        padding: 30px;
    }
}

/* =========================================
   FONDO VERTICAL (9:16) SOLO PARA CELULARES
========================================= */
@media (max-width: 768px) {
    .nosotros-hero {
        /* Carga la imagen vertical optimizada solo en móviles */
        background-image: url('../assets/img/fondo/image5-1.png') !important;
        background-position: center !important;
        background-size: cover !important;
    }
}

/* =========================================
   CONTROL DE DESENFOQUE EN CELULARES
========================================= */
@media (max-width: 768px) {
    .hero-overlay {
        /* Cambia el "2px" por "0px" si quieres quitarlo por completo */
        backdrop-filter: blur(1px) !important;
        -webkit-backdrop-filter: blur(2px) !important;
        
        /* Opcional: Si también quieres que la capa negra sea más transparente */
        background: rgba(0, 0, 0, 0.4) !important; 
    }
}