/* 1. ESTRUCTURA BASE */
html, body {
    height: 100%;
}

.main-layout {
    display: flex;
    flex-direction: column;
    margin: 0;
    font-family: "Roboto", sans-serif; 
    color: #C4C4C4;
    /* Tu fondo original con el overlay oscuro */
    background-image: linear-gradient(rgba(0,0,0,0.7), rgba(0,0,0,0.7)), url(fondonosostros.jpeg);
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    background-color: #1a1a1a;
    min-height: 100vh;
}

/* 2. HEADER Y NAVEGACIÓN */
header {
    flex-shrink: 0;
    position: sticky;
    top: 0;
    width: 100%;
    background-color: #111111;
    min-height: 8vh;
    box-shadow: 0 5px 30px rgb(0, 0, 0);
    z-index: 1000;
    display: flex; 
    justify-content: center; 
    align-items: center; 
    padding: 10px 0;
}

#header-inner { 
    display: flex;
    justify-content: space-between; 
    align-items: center;
    width: 90%;
    max-width: 1400px; 
}

#logo {
    max-height: 6vh;
    width: auto;
}

#header-nav {
    display: flex;
    align-items: center;
    gap: 15px;
}

#header-nav a {
    text-decoration: none;
    font-size: 15px;
    color: #C4C4C4 !important;
    padding: 10px 20px;
    border-radius: 5px;
    transition: 0.3s;
    text-transform: uppercase;
}

#nosotros-active {
    background-color: #222222;
    border-bottom: 2px solid #A67C00;
}

#header-nav a:hover {
    background-color: #222222;
    color: #e6b421 !important;
}

/* BOTÓN RAINBOW */
.btn-rainbow {
    background: linear-gradient(45deg, #ff0000, #ff7300, #fffb00, #48ff00, #00ffd5, #002bff, #7a00ff, #ff00c8, #ff0000);
    background-size: 400%;
    color: white !important;
    padding: 8px 15px !important;
    border-radius: 5px;
    font-weight: bold;
    animation: rainbow_animation 10s linear infinite;
}

@keyframes rainbow_animation {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* MENU TOGGLE */
#menu-toggle {
    display: none;
    flex-direction: column;
    gap: 6px;
    cursor: pointer;
}

#menu-toggle span {
    width: 30px; height: 3px; background: #e6b421; border-radius: 3px;
}

/* 3. CONTENIDO CENTRAL */
.main-content {
    flex: 1 0 auto;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 80px 7%;
}

.cards-wrapper {
    display: flex;
    gap: 30px;
    width: 100%;
    max-width: 1200px;
}

.section-block.mission-vision {
    flex: 1;
    background: rgba(17, 17, 17, 0.6);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border: 1px solid #3d3d3d;
    border-radius: 30px;
    padding: 45px;
    transition: 0.4s;
}

.section-block.mission-vision:hover {
    transform: translateY(-10px);
    border-color: #A67C00;
    background: rgba(25, 25, 25, 0.8);
}

.letra-dorada {
    background-image: linear-gradient(to right, #A67C00, #c99f22, #A67C00);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    font-weight: bold;
}

.block-title { 
    font-size: 35px; 
    margin-bottom: 15px; 
}

.texto-descripcion {
    line-height: 1.8;
    font-size: 18px;
}

/* 4. FOOTER */
footer {
    flex-shrink: 0;
    background-color: #0d0d0d;
    padding: 60px 7% 30px;
    border-top: 2px solid #A67C00;
}

#footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
}

.footer-logo-img {
    width: 200px;
    margin-bottom: 20px;
}

.footer-list {
    list-style: none;
    padding: 0;
}

.footer-list li {
    margin-bottom: 10px;
}

.social-links {
    margin-top: 15px;
}

.social-links a {
    color: #C4C4C4;
    text-decoration: none;
    margin-right: 15px;
    font-size: 14px;
}

#copyright {
    text-align: center;
    margin-top: 40px;
    padding-top: 20px;
    border-top: 1px solid #222;
    color: #555;
    font-size: 14px;
}

/* -----------------------------------------------------------
   RESPONSIVE / CELULAR
   ----------------------------------------------------------- */

@media (max-width: 900px) {
    #menu-toggle { display: flex; }

    #header-nav {
        display: none;
        flex-direction: column;
        position: absolute;
        top: 100%; left: 0; width: 100%;
        background: #111;
        padding: 20px;
        border-bottom: 2px solid #A67C00;
        text-align: center;
        gap: 10px;
    }

    #header-nav.active { display: flex; }

    .cards-wrapper { 
        flex-direction: column; 
        gap: 20px;
    }

    .main-content {
        padding: 40px 5%;
    }

    .section-block.mission-vision {
        padding: 30px;
    }

    .block-title {
        font-size: 28px;
    }

    /* REDUCCIÓN DE GRAMAJE FOOTER */
    footer {
        padding: 30px 5% 20px;
    }

    #footer-grid {
        gap: 25px;
    }

    .footer-logo-img {
        width: 150px;
    }

    #footer-grid h4 {
        font-size: 14px;
        margin-bottom: 10px;
    }

    #footer-grid p, .footer-list li, .social-links a {
        font-size: 13px;
        line-height: 1.4;
    }

    #copyright {
        font-size: 11px;
        margin-top: 20px;
    }
}