
/* 1. VARIABLES Y RESET BÁSICO */
:root {
    --navy-900: #0c2151;
    --navy-700: #1c3f7c;
    --navy-500: #2f63b6;
    --navy-300: #5a86d6;
    --neutral-900: #1f2333;
    --neutral-700: #3c435c;
    --neutral-200: #e5e8f2;
    --neutral-100: #f5f7fc;
    --accent-gold: #f5b041;
    --shadow-soft: 0 24px 54px rgba(12, 33, 81, 0.16);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

body {
    font-family: 'Montserrat', Arial, sans-serif;
    background-color: #f5f7fc;
    color: var(--neutral-900);
}

/* 2. HEADER / TOP BAR */
.top-bar {
    position: sticky;
    top: 0;
    z-index: 50;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 32px;
    padding: 18px 48px;
    background-color: rgba(255,255,255,0.96);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(12, 33, 81, 0.08);
}

.brand {
    display: flex;
    align-items: center;
    gap: 16px;
}

.brand-logo {
    width: 52px;
    aspect-ratio: 1 / 1;
    object-fit: contain;
}

.brand-text {
    font-weight: 700;
    font-size: 0.95rem;
    color: var(--navy-900);
    text-transform: uppercase;
    letter-spacing: 0.12em;
}

/* 3. MENÚ HAMBURGUESA */
.menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 6px;
    width: 46px;
    height: 46px;
    border-radius: 12px;
    border: none;
    background: var(--navy-900);
    cursor: pointer;
    transition: transform 0.3s ease, background 0.3s ease;
}

.menu-toggle span {
    display: block;
    height: 3px;
    width: 24px;
    margin: 0 auto;
    background: #ffffff;
    border-radius: 999px;
}

.menu-toggle:hover {
    transform: translateY(-2px);
    background: var(--navy-700);
}

/* 4. NAVEGACIÓN PRINCIPAL */
.main-nav ul {
    display: flex;
    align-items: center;
    gap: 28px;
    list-style: none;
    font-weight: 600;
}

.main-nav a {
    color: var(--navy-900);
    text-decoration: none;
    font-size: 0.95rem;
    letter-spacing: 0.04em;
    position: relative;
    padding-bottom: 6px;
    transition: color 0.3s ease;
}

.main-nav a::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: 0;
    width: 100%;
    height: 2px;
    background: var(--navy-500);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.3s ease;
}

.main-nav a:hover,
.main-nav a.active {
    color: var(--navy-500);
}

.main-nav a:hover::after,
.main-nav a.active::after {
    transform: scaleX(1);
}

/* 5. DROPDOWN DEL MENÚ */
.has-dropdown {
    position: relative;
}

.dropdown {
    position: absolute;
    top: 110%;
    left: 0;
    background: #ffffff;
    box-shadow: 0 16px 40px rgba(12, 33, 81, 0.16);
    border-radius: 12px;
    padding: 14px 18px;
    display: none;
    flex-direction: column;
    gap: 10px;
    min-width: 160px;
}

.has-dropdown:hover .dropdown,
.has-dropdown:focus-within .dropdown {
    display: flex;
}

.dropdown a {
    color: var(--navy-900);
    font-weight: 500;
    font-size: 0.9rem;
}

.dropdown a:hover {
    color: var(--navy-500);
}

.has-dropdown.open .dropdown {
    display: flex;
}

/* 6. SELECTOR DE IDIOMA */
.language-switcher {
    position: relative;
}

.language-select {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 600;
    color: var(--navy-900);
    background: rgba(255, 255, 255, 0.92);
    border: 1px solid rgba(12, 33, 81, 0.12);
    border-radius: 999px;
    padding: 6px 16px;
    cursor: pointer;
    transition: box-shadow 0.3s ease, transform 0.3s ease;
    border: none;
    outline: none;
}

.language-select:hover {
    box-shadow: 0 8px 20px rgba(12, 33, 81, 0.2);
    transform: translateY(-1px);
}

.language-flag {
    width: 24px;
    aspect-ratio: 3 / 2;
    object-fit: cover;
    border-radius: 4px;
    box-shadow: 0 0 0 1px rgba(12, 33, 81, 0.12);
}

.language-caret {
    font-size: 0.75rem;
    color: var(--navy-700);
}

.language-menu {
    position: absolute;
    right: 0;
    margin-top: 8px;
    background: #ffffff;
    border-radius: 14px;
    box-shadow: 0 18px 40px rgba(12, 33, 81, 0.25);
    padding: 10px;
    list-style: none;
    display: none;
    min-width: 200px;
    z-index: 50;
}

.language-switcher.open .language-menu {
    display: block;
}

.language-option {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 10px;
    background: transparent;
    border: none;
    padding: 8px 10px;
    border-radius: 10px;
    cursor: pointer;
    font-weight: 600;
    color: var(--navy-900);
    transition: background 0.2s ease, color 0.2s ease;
}

.language-option img {
    width: 22px;
    height: 16px;
    border-radius: 4px;
    box-shadow: 0 0 0 1px rgba(12, 33, 81, 0.12);
}

.language-option:hover,
.language-option.active {
    background: rgba(47, 99, 182, 0.12);
    color: var(--navy-700);
}

.language-select:focus-visible,
.language-option:focus-visible {
    outline: 2px solid var(--navy-500);
    outline-offset: 2px;
}

/* 7. CONTENIDO PRINCIPAL (PÁGINA) */
.page-content {
    padding: 80px 48px;
    text-align: center;
    background: #ffffff;
}

.page-content h1 {
    font-size: clamp(2.4rem, 5vw, 3.2rem);
    font-weight: 800;
    letter-spacing: 0.12em;
    color: var(--navy-900);
    margin-bottom: 24px;
}

/* 8. ANIMACIÓN DE CONSTRUCCIÓN */
.construction-animation {
    text-align: center;
    margin: 32px auto 16px;
}

.construction-cars {
    display: flex;
    justify-content: center;
    gap: 26px;
    margin-bottom: 12px;
}

.truck {
    font-size: 2.6rem;
    display: inline-flex;
    animation: drive 4s linear infinite;
}

.truck-one {
    animation-delay: 0s;
}

.truck-two {
    animation-delay: 0.3s;
}

.truck-three {
    animation-delay: 0.6s;
}

.construction-text {
    font-weight: 700;
    letter-spacing: 0.3em;
    text-transform: uppercase;
    color: var(--navy-900);
}

@keyframes drive {
    0% {
        transform: translateY(0) translateX(-4px);
    }
    50% {
        transform: translateY(-3px) translateX(4px);
    }
    100% {
        transform: translateY(0) translateX(-4px);
    }
}

/* 9. FOOTER */
.site-footer {
    background: var(--navy-900);
    padding: 42px 80px 32px;
    color: #ffffff;
}

.footer-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 24px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
    padding-bottom: 28px;
}

.footer-contact {
    display: flex;
    align-items: center;
    gap: 18px;
    font-weight: 500;
}

.footer-contact img {
    width: 64px;
    aspect-ratio: 1 / 1;
    object-fit: contain;
}

.footer-email {
    height: 1rem;
    color: transparent;
    user-select: none;
}

.footer-contact h3,
.footer-social h3 {
    font-weight: 800;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    margin-bottom: 8px;
    color: #ffffff;
}

.footer-social {
    text-align: right;
}

.social-icons {
    display: flex;
    justify-content: flex-end;
    gap: 14px;
}

.social-icons a {
    width: 46px;
    height: 46px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.15);
    color: #ffffff;
    display: grid;
    place-items: center;
    text-decoration: none;
    transition: transform 0.3s ease, background 0.3s ease;
}

.social-icons svg {
    width: 24px;
    height: 24px;
}

.social-icons a:hover {
    transform: translateY(-4px);
    background: rgba(255, 255, 255, 0.3);
}

.footer-bottom {
    text-align: center;
    margin-top: 28px;
    font-size: 0.9rem;
    letter-spacing: 0.12em;
}

/* 10. RESPONSIVE DESIGN */

/* Tablet y pantallas medianas */
@media (max-width: 1200px) {
    .top-bar {
        padding: 16px 28px;
    }

    .footer-top {
        flex-direction: column;
        text-align: center;
    }

    .footer-social {
        text-align: center;
    }

    .social-icons {
        justify-content: center;
    }
}

/* Móvil grande */
@media (max-width: 900px) {
    .menu-toggle {
        display: flex;
    }
    
    .top-bar {
        display: grid;
        grid-template-columns: auto 1fr auto;
        align-items: center;
        gap: 12px;
    }

    .menu-toggle {
        order: 3;
        justify-self: end;
    }

    .brand {
        order: 1;
        justify-self: start;
    }

    .language-switcher {
        order: 2;
        justify-self: center;
    }

    .language-select {
        padding: 6px 14px;
    }

    .main-nav {
        position: absolute;
        top: 100%;
        right: 48px;
        background: #ffffff;
        box-shadow: 0 24px 48px rgba(12, 33, 81, 0.18);
        padding: 24px;
        border-radius: 18px;
        display: none;
        width: clamp(260px, 70vw, 320px);
        max-width: 90vw;
    }

    .main-nav.open {
        display: block;
    }

    .main-nav ul {
        flex-direction: column;
        align-items: flex-start;
        gap: 18px;
    }

    .has-dropdown {
        position: relative;
        width: 100%;
    }

    .has-dropdown .dropdown {
        position: absolute;
        top: calc(100% + 6px);
        left: 0;
        background: #ffffff;
        border-radius: 18px;
        padding: 16px 18px;
        box-shadow: 0 20px 40px rgba(12, 33, 81, 0.18);
        display: none;
        flex-direction: column;
        gap: 12px;
        width: 100%;
        z-index: 12;
    }

    .has-dropdown.open .dropdown {
        display: flex;
    }

    .has-dropdown .dropdown a {
        font-size: 1rem;
        padding: 8px 0;
    }

    .page-content {
        padding: 60px 28px;
    }
}

/* Móvil mediano */
@media (max-width: 700px) {
    .top-bar {
        padding: 14px 22px;
        gap: 16px;
    }

    .brand-text {
        font-size: 0.75rem;
        letter-spacing: 0.08em;
    }

    .language-switcher {
        justify-self: center;
    }

    .language-switcher .language-menu {
        left: 50%;
        right: auto;
        transform: translateX(-50%);
    }

    .language-select {
        font-size: 0.85rem;
    }

    .page-content {
        padding: 48px 20px;
    }

    .site-footer {
        padding: 32px 24px;
    }
}

/* Móvil pequeño */
@media (max-width: 480px) {
    .main-nav {
        right: 20px;
        left: 20px;
    }

    .language-switcher .language-menu {
        width: min(240px, 90vw);
    }

    .page-content {
        padding: 40px 16px;
    }
}


.seccion-azul {
    position: relative;
}

.seccion-azul img {
    width: 100%;
    height: 320px;
    object-fit: cover;
     position: relative;
    z-index: 1;
    overflow: hidden;
}
/* -------- Recuadro con foto -------- */
.contenedor-foto {
    background: rgba(12, 29, 44, 1);
    border-radius: 25px;
    padding: 14px;
    width: 78%;
    max-width: 800px;
    margin: -160px auto 32px auto;
    text-align: center;
    min-height: 240px;  /* <-- GARANTIZA VISIBILIDAD */
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: relative;
    z-index: 10;
}

.contenedor-foto img {
width: 100%;
max-width: 800px;
border-radius: 10px;
display: block;
}
/* -------- Texto sobre la foto -------- */
.texto-superior {
font-family: 'Montserrat', Arial, sans-serif;
color: rgba(243, 243, 243, 1);
font-size: 1rem;
font-weight: 500;
line-height: 1.7;
margin-bottom: 12px;
}
/* -------- Texto principal en fondo blanco -------- */
.contenido {
max-width: 1200px;
margin: auto;
padding: 40px 36px;
text-align: center;
color: rgba(21, 48, 72, 1);
}


.contenido h1 {
font-family: 'Montserrat', Arial, sans-serif;
font-size: 2.4rem;
margin-bottom: 14px;
color: rgba(21, 48, 72, 1);
font-weight: 800;
letter-spacing: 0.06em;
}


.contenido p{
font-family: 'Montserrat', Arial, sans-serif;
font-size: 1rem;
line-height: 1.7;
text-align: justify;
color: var(--neutral-700);
}

/* ===== Contenedor principal ===== */
.seccion-azul2 {
    position: relative; /* Permite posicionar el texto encima */
    width: 100%;
    height: 140px; /* Igual que la imagen */
    overflow: hidden; /* Evita desbordes */
}

/* ===== Imagen de fondo ===== */
.seccion-azul2 img {
    width: 100%;
    height: 100%;
    object-fit: cover; /* Ajuste correcto sin deformar */
    
    position: absolute; /* Se coloca detrás del texto */
    top: 0;
    left: 0;

    z-index: 1; /* Capa de fondo */
}

/* ===== Texto sobre la imagen ===== */
.texto-superior2 {
    position: absolute; /* Permite ubicarlo encima de la imagen */
    z-index: 2; /* Más arriba que la imagen */

    top: 50%; /* Centrado vertical */
    left: 50%; /* Centrado horizontal */
    transform: translate(-50%, -50%); /* Ajuste del centrado real */

    font-family: 'Montserrat', Arial, sans-serif;
    color: rgb(243, 243, 243); /* Blanco */
    font-size: clamp(2.4rem, 5vw, 3.2rem);
    font-weight: 800;
    letter-spacing: 0.08em;
    text-align: center;
    white-space: nowrap; /* <-- Evita que el texto salte a otra línea */
}

/*
    Contenedor principal con ancho máximo.
    Esto centra todo y evita que el contenido ocupe pantallas demasiado grandes.
*/
.contenido-2 {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    position: relative; /* Necesario para que los elementos absolute se posicionen respecto a este bloque */
    padding: 32px 28px;
    color: rgba(21, 48, 72, 1);
    display: grid;
    grid-template-columns: 50% 25% 25%;
    grid-template-areas:
        "texto1 img1 img2"
        "img3   texto2 texto2";
    gap: 22px 28px;
    align-items: start;
}

/* 
    Texto del bloque izquierdo superior.
    Tamaño de fuente y color igual al diseño observado.
*/
.bloque-texto-izquierdo  {
    width: 100%; /* Ocupar la misma proporción que en el diseño */
    max-width: 540px;
    font-family: 'Montserrat', Arial, sans-serif;
    font-size: 1rem;
    line-height: 1.7;
    text-align: justify;
    display: flex;
    flex-direction: column;
    justify-content: center;  /* CENTRA verticalmente */
    color: var(--neutral-700);
    grid-area: texto1;
}

/* 
    ESTILO GLOBAL PARA TODAS LAS IMÁGENES
    Antes eran .box como divs; ahora son <img> pero mantenemos la clase.
*/
.caja {
    object-fit: cover; /* Hace que la imagen llene el recuadro sin deformarse */
    border-radius: 4px; /* Igual que los recuadros grises originales */
    background: #ccc;   /* Si hay error de carga de imagen, queda gris */
    transition: transform 0.4s ease, box-shadow 0.4s ease;
    cursor: pointer;
      box-shadow: 0 8px 18px rgba(0, 0, 0, 0.25);
}

/* Aumenta a 1.5 veces */
.caja:hover {
    transform: none;
    box-shadow: 0 12px 30px rgba(0,0,0,0.22);
    
}

/* Desactivar cualquier animación/zoom en la sección de missão */
.seccion-azul3 .caja,
.seccion-azul3 .caja:hover {
    transform: none;
    transition: none;
    cursor: default;
    opacity: 1;
}

/* 
    Imagen superior izquierda (box1)
    Se posiciona exactamente donde estaba en el diseño original.
*/
.box1 {
    position: relative;
    right: auto;
    top: auto;
    width: 100%;
    max-width: 320px;
    height: 240px;
    object-fit: cover;
    grid-area: img1;
    align-self: start;
    justify-self: start;
    border-radius: 12px;
    box-shadow: 0 10px 26px rgba(0,0,0,0.22);
    cursor: default;
}

/*
    Imagen superior derecha (box2)
    Leve superposición calculada según la imagen proporcionada.
*/
.box2 {
    position: relative;
    right: auto;
    top: auto;
    width: 100%;
    max-width: 320px;
    height: 240px;
    object-fit: cover;
    grid-area: img2;
    margin-top: 0;
    justify-self: start;
    align-self: start;
    border-radius: 12px;
    box-shadow: 0 10px 26px rgba(0,0,0,0.22);
    cursor: default;
}

/* 
    Imagen inferior izquierda (box3)
    Esta no está en posición absolute para mantener el flujo natural después del texto.
*/
.box3 {
    width: 100%;
    max-width: 760px;
    height: 260px;
    object-fit: cover;
    margin: 0;
    grid-area: img3;
    border-radius: 12px;
    box-shadow: 0 10px 26px rgba(0,0,0,0.22);
}

/*
    Texto del bloque inferior derecho.
    Posicionamiento absoluto para fijarlo en el lugar mostrado en el diseño.
*/
.bloque-texto-derecho {
    width: 100%;
    max-width: 520px;
    font-family: 'Montserrat', Arial, sans-serif;
    font-size: 1rem;
    line-height: 1.7;
    text-align: justify;
    position: relative;
    right: auto;
    bottom: auto;
    display: flex;
    flex-direction: column;
    justify-content: center;  /* CENTRA verticalmente */
    color: var(--neutral-700);
    grid-area: texto2;
}


/* ============================================================
   CONTENEDOR PRINCIPAL
   ============================================================ */
.seccion-azul3 {
    position: relative;
    width: 100%;
    min-height: 620px;
    overflow: hidden;
    display: grid;
    grid-template-columns: 52% 24% 24%;
    grid-template-rows: auto auto;
    grid-template-areas:
        "texto grande grande"
        "texto mini1  mini2";
    gap: 18px 16px;
    padding: 36px 32px 40px;
}

/* ============================================================
   IMAGEN DE FONDO
   ============================================================ */

/* CORRECCIÓN: el selector debe llevar punto "." */
.seccion-azul3 .img-fondo {
    position: absolute;
    top: 0;
    left: 0;

    width: 100%;
    height: 100%;

    object-fit: cover;
    z-index: 1;                     /* Fondo detrás */
}

/* ============================================================
   TEXTO
   ============================================================ */

.bloque-texto-izquierdo2 {
    position: relative;
    z-index: 3;                      /* Encima del fondo */
    width: 100%;
    max-width: none;
    padding: 10px 4% 10px 2%;
    color: rgb(243, 243, 243); /* Blanco */
    text-align: left;
    grid-area: texto;
}

.bloque-texto-izquierdo2 h1 {
    font-size: 2.3rem;
    font-family: 'Montserrat', Arial, sans-serif;
    font-weight: 800;
    letter-spacing: 0.06em;
    margin-bottom: 14px;
    white-space: normal; /* <-- Evita que el texto salte a otra línea */
    text-align: left;
}

.bloque-texto-izquierdo2 p {
   
    font-family: 'Montserrat', Arial, sans-serif;
    width: 100%; /* Ocupar la misma proporción que en el diseño */
    font-size: 1rem;
    line-height: 1.65;
    text-align: justify;
    display: flex;
    flex-direction: column;
    justify-content: center;  /* CENTRA verticalmente */
    margin-bottom: 8px;
}

/* ============================================================
   IMÁGENES (box4, box5, box6)
   ============================================================ */

.box4, .box5, .box6 {
    position: relative;
    z-index: 4;                       /* Encima del texto */
    border-radius: 14px;
    object-fit: cover;
    object-position: center center;    /* Centra por defecto */
    box-shadow: 0 10px 28px rgba(0,0,0,0.32);
    width: 100%;
    max-width: 96%;
    justify-self: start;
    transition: none;
    cursor: default;
}

.box4 {
    grid-area: grande;
    height: 330px;
    object-position: center 18%;       /* Levanta el encuadre para no cortar rostros */
}

.box5 {
    grid-area: mini1;
    height: 190px;
}

.box6 {
    grid-area: mini2;
    height: 190px;
}


.contenido-3 {
    position: relative;
    width: 100%;
    min-height: 620px;              /* Mejor que height fija para adaptarse */
    overflow: hidden;
    display: grid;
    grid-template-columns: 52% 48%; /* Izquierda imágenes | derecha texto */
    gap: 18px 16px;
    align-items: start;
    padding: 36px 32px;
}

/* ============================================
   COLUMNA DERECHA (TEXTO)
   ============================================ */
.bloque-texto-derecho2 {
    margin-left: auto;  /* Empuja todo hacia la derecha */
    width: 100%;
    max-width: none;
    color: rgb(21, 48, 72);
    position: relative;
    z-index: 3;                      /* Encima del fondo */
    padding: 10px 3% 10px 0;
    text-align: left;
}

.bloque-texto-derecho2 h1 {
    width: 100%;
    font-size: 2.35rem;
    font-family: 'Montserrat', Arial, sans-serif;
    font-weight: 800;
    letter-spacing: 0.06em;
    margin-bottom: 12px;
    white-space: normal; /* <-- Evita que el texto salte a otra línea */
    text-align: left;
}

.bloque-texto-derecho2 p {
    font-family: 'Montserrat', Arial, sans-serif;
    width: 100%; /* Ocupar la misma proporción que en el diseño */
    font-size: 1rem;
    line-height: 1.65;
    text-align: justify;
    display: flex;
    flex-direction: column;
    justify-content: center;  /* CENTRA verticalmente */
    color: var(--neutral-700);
}

/* ============================================
   COLUMNA IZQUIERDA (IMÁGENES EN BLOQUE)
   ============================================ */

.contenido-3 .columna-imagenes {
    display: flex;
    flex-direction: column; /* UNA IMAGEN DEBAJO DE OTRA */
    gap: 12px;
    justify-content: flex-start;
    align-items: flex-start;
    padding-left: 4%;
}

.box7, .box8, .box9 {
    width: 100%;
    max-width: 94%;
    height: clamp(180px, 28vw, 260px); /* altura fluida para distintos anchos */
    object-fit: cover;
    object-position: center 32%; /* valor base */
    border-radius: 15px;
    box-shadow: 0 8px 30px rgba(0,0,0,0.3);
    margin: 0 auto;
    transition: none;
    cursor: default;
}

/* Ajustes finos por imagen para mostrar mejor los rostros */
.box7 { object-position: center 38%; }
.box8 { object-position: center 46%; }
.box9 { object-position: center 40%; }

/* Desactivar animación/zoom en Visión */
.contenido-3 .caja,
.contenido-3 .caja:hover {
    transform: none;
    transition: none;
    cursor: default;
}


/* Fondo azul como imagen */
.background {
    position: relative;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

.bg-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    position: absolute;
    z-index: -1;
}

/* Contenedor principal */
.container-artigos {
    display: grid;
    grid-template-columns: 1fr 1fr;
    padding: 36px 48px;
    gap: 32px;
}

/* Columna izquierda */
.col-left {
    width: 100%; /* Ocupar la misma proporción que en el diseño */
    font-family: 'Montserrat', Arial, sans-serif;
    font-size: 1rem;
    line-height: 1.7;
    text-align: justify;
    color: rgb(243, 243, 243); /* Blanco */
    display: flex;
    flex-direction: column;
    justify-content: center;  /* CENTRA verticalmente */
    position: sticky;
    top: 40px;
    justify-content: flex-start;
}

/* Columna derecha */
.col-right {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

/* Título ARTIGOS DE FÉ */
.artigos-title {
    font-family: 'Montserrat', Arial, sans-serif;
    font-weight: 600;
    background: #0C1D2C;
    padding: 20px;
    border-radius: 10px;
    text-align: center;
    color: white;
    box-shadow: 0px 5px 10px rgba(0, 0, 0, .4);
}

.artigos-title h2 {
    font-family: 'Montserrat', Arial, sans-serif;
    font-weight: 800;
    font-size: 2.6rem;
    letter-spacing: 0.08em;
    margin: 0;
}

        /* Estilos del box principal */
        .artigo-box {
             font-family: 'Montserrat', Arial, sans-serif;
             font-weight: 400;
            background: #153048;
            margin-bottom: 0;
            color: white;
            border-radius: 25px;
            padding: 18px 15px;
            display: flex;
            justify-content: space-between;
            align-items: center;
            box-shadow: 0px 5px 10px rgba(0, 0, 0, .4);
            cursor: pointer;
            transition: border-radius 0.3s ease;
        }

        .artigo-box.active {
            border-radius: 25px 25px 0 0;
             margin-bottom: 0;
        }

        
        .artigo-text {
            font-family: 'Montserrat', Arial, sans-serif;
            font-weight: 500;
            width: 80%;
            font-size: 0.95rem;
        }

        /* Botón del menú */
        .artigo-btn {
            width: 40px;
            height: 40px;
            background: #0C1D2C;
            border: none;
            cursor: pointer;
            display: flex;
            justify-content: center;
            align-items: center;
            padding: 6px;
            transform: scale(2);
            border-radius: 0px 10px 10px 0px;
            overflow: visible;
            transition: transform 0.3s ease;
            position: relative;
            border-radius: 0px 10px 10px 0px;
        }


        /* Imágenes del botón menú */
        .artigo-btn img {
            width: 100%;
            height: 100%;
            object-fit: contain;
            transition: opacity 0.3s ease;
            position: absolute;
        }

        .menu-icon {
            opacity: 1;
        }

        .menu-icon-close {
            opacity: 0;
        }

        .artigo-btn.active .menu-icon {
            opacity: 0;
        }

        .artigo-btn.active .menu-icon-close {
            opacity: 1;
        }

        /* Contenedor del dropdown */
        .dropdown-content {
            background:white;
            overflow: hidden;
            max-height: 0;
            transition: max-height 0.4s ease;
            border-radius: 0 0 25px 25px;
            box-shadow: 0px 5px 10px rgba(0, 0, 0, .4);
        }

        .dropdown-content.active {
            max-height: 800px;
        }

        /* Items del dropdown */
        .dropdown-item {
            background: linear-gradient(135deg, #74A5D1 0%, #B0E0E6 100%);
            padding: 15px 20px;
            margin: 0 15px 10px 15px;
            border-radius: 15px;
            display: flex;
            justify-content: space-between;
            align-items: center;
            cursor: pointer;
            transition: all 0.3s ease;
        }

        .dropdown-item:first-child {
            margin-top: 10px;
        }

        .dropdown-item:last-child {
            margin-bottom: 15px;
        }

        .dropdown-item:hover {
            background: linear-gradient(135deg, #B0E0E6 0%, #87CEEB 100%);
            transform: translateX(5px);
        }

        .dropdown-item-text {
            font-family: 'Montserrat', Arial, sans-serif;
            color: #1e3a5f;
            font-size: 0.95rem;
            font-weight: 500;
            line-height: 1.8;
            flex: 1;
        }

        /* Icono de Google Drive */
        .drive-icon {
            width: 35px;
            height: 35px;
            background: white;
            border-radius: 6px;
            padding: 5px;
            box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
            display: flex;
            align-items: center;
            justify-content: center;
        }

        .drive-icon img {
            width: 100%;
            height: 100%;
            object-fit: contain;
        }
p {
    margin-bottom: 20px;
}


/* ============================================================
   RESPONSIVE DESIGN - MEDIA QUERIES
   ============================================================ */

/* ============================================================
   TABLETS (768px - 1024px)
   ============================================================ */
@media screen and (max-width: 1024px) {
    
    /* SECCIÓN 1: Banner superior */
    .seccion-azul img {
        height: 300px;
    }
    
    /* SECCIÓN 2: Recuadro con foto */
    .contenedor-foto {
        width: 80%;
        margin: -150px auto 30px auto;
        padding: 15px;
    }
    
    /* SECCIÓN 3: Texto sobre foto */
    .texto-superior {
        font-size: 1.25rem;
    }
    
    /* SECCIÓN 4: Contenido principal */
    .contenido {
        padding: 40px 30px;
    }
    
    .contenido h1 {
        font-size: 2.6rem;
    }
    
    .contenido p {
        font-size: 1.05rem;
    }
    
    /* SECCIÓN 5: Banner azul con texto */
    .texto-superior2 {
        font-size: clamp(2.4rem, 5vw, 3.2rem);
    }
    
    /* SECCIÓN 6: Contenido con layout mixto */
    .contenido-2 {
        padding: 30px 15px;
    }
    
    .bloque-texto-izquierdo {
        width: 60%;
        font-size: 1.05rem;
    }
    
    /* Ajustar imágenes */
    .box1 {
        right: 150px;
        width: 280px;
        height: 185px;
    }
    
    .box2 {
        right: 30px;
        width: 240px;
        height: 160px;
    }
    
    .box3 {
        width: 60%;
        height: 200px;
        margin-top: 120px;
    }
    
    .bloque-texto-derecho {
        width: 45%;
        font-size: 1.05rem;
        right: 30px;
        bottom: 30px;
    }
    
    /* SECCIÓN 7: Contenido azul */
    .seccion-azul3 {
        min-height: 550px;
    }
    
    .bloque-texto-izquierdo2 {
        width: 60%;
        padding: 40px 3%;
    }
    
    .bloque-texto-izquierdo2 h1 {
        font-size: 2.6rem;
    }
    
    .bloque-texto-izquierdo2 p {
        font-size: 1.05rem;
    }
    
    .box4 {
        width: 40%;
        height: 35%;
    }
    
    .box5, .box6 {
        width: 19%;
        height: 35%;
    }
    
    /* SECCIÓN 8: Contenido con grid */
    .contenido-3 {
        min-height: 550px;
        grid-template-columns: 1.5fr 3.5fr;
    }
    
    .bloque-texto-derecho2 {
        padding: 40px 3%;
    }
    
    .bloque-texto-derecho2 h1 {
        font-size: 2.6rem;
        width: 90%;
    }
    
    .bloque-texto-derecho2 p {
        font-size: 1.05rem;
        width: 95%;
    }
    
    .box7, .box8, .box9 {
        height: clamp(170px, 32vw, 230px);
        max-width: 96%;
    }
    
    /* SECCIÓN 9: Artigos de Fé */
    .container-artigos {
        padding: 30px 40px;
        gap: 30px;
    }
    
    .col-left {
        font-size: 1.05rem;
    }
    
    .artigo-text {
        font-size: 0.9rem;
    }
    
    .dropdown-item-text {
        font-size: 0.9rem;
    }
}

/* ============================================================
   TABLETS PEQUEÑOS Y MÓVILES GRANDES (481px - 768px)
   ============================================================ */
@media screen and (max-width: 768px) {
    
    /* SECCIÓN 1: Banner superior */
    .seccion-azul img {
        height: 250px;
    }
    
    /* SECCIÓN 2: Recuadro con foto */
    .contenedor-foto {
        width: 90%;
        margin: -100px auto 20px auto;
        min-height: 200px;
    }
    
    /* SECCIÓN 3: Texto sobre foto */
    .texto-superior {
        font-size: 1.15rem;
    }
    
    /* SECCIÓN 4: Contenido principal */
    .contenido {
        padding: 30px 20px;
    }
    
    .contenido h1 {
        font-size: 2.2rem;
    }
    
    .contenido p {
        font-size: 1.05rem;
    }
    
    /* SECCIÓN 5: Banner azul con texto */
    .seccion-azul2 {
        height: 120px;
    }
    
    .texto-superior2 {
        font-size: clamp(2rem, 5vw, 2.6rem);
        white-space: normal; /* Permite salto de línea */
    }
    
    /* SECCIÓN 6: Contenido con layout mixto - CAMBIO A COLUMNA */
    .contenido-2 {
        padding: 20px 15px;
    }
    
    .bloque-texto-izquierdo {
        width: 100%;
        font-size: 1.05rem;
        margin-bottom: 20px;
    }
    
    /* Cambiar posicionamiento de imágenes a relativo */
    .box1, .box2 {
        position: relative;
        right: auto;
        top: auto;
        width: 100%;
        height: 200px;
        margin-bottom: 15px;
    }
    
    .box3 {
        width: 100%;
        height: 200px;
        margin-top: 20px;
    }
    
    .bloque-texto-derecho {
        position: relative;
        width: 100%;
        font-size: 1.05rem;
        right: auto;
        bottom: auto;
        margin-top: 20px;
    }
    
    /* SECCIÓN 7: Contenido azul - CAMBIO A COLUMNA */
    .seccion-azul3 {
        min-height: auto;
        padding-bottom: 30px;
    }
    
    .bloque-texto-izquierdo2 {
        width: 100%;
        padding: 30px 5%;
    }
    
    .bloque-texto-izquierdo2 h1 {
        font-size: 2.2rem;
        text-align: center;
        white-space: normal;
    }
    
    .bloque-texto-izquierdo2 p {
        font-size: 1.05rem;
    }
    
    /* Imágenes debajo del texto */
    .box4, .box5, .box6 {
        position: relative;
        width: 90%;
        height: 200px;
        margin: 15px auto;
        top: auto;
        right: auto;
    }
    
    /* SECCIÓN 8: Contenido con grid - CAMBIO A COLUMNA */
    .contenido-3 {
        grid-template-columns: 1fr;
        min-height: auto;
        gap: 20px;
    }
    
    .contenido-3 .columna-imagenes {
        order: 2; /* Las imágenes van después del texto */
    }
    
    .bloque-texto-derecho2 {
        order: 1; /* El texto va primero */
        padding: 30px 5%;
    }
    
    .bloque-texto-derecho2 h1 {
        font-size: 2.2rem;
        width: 100%;
        text-align: center;
        white-space: normal;
    }
    
    .bloque-texto-derecho2 p {
        font-size: 1.05rem;
        width: 100%;
    }
    
    .box7, .box8, .box9 {
        width: 94%;
        height: clamp(170px, 45vw, 230px);
        margin: 15px auto;
    }
    
    /* SECCIÓN 9: Artigos de Fé - CAMBIO A COLUMNA */
    .container-artigos {
        grid-template-columns: 1fr;
        padding: 20px;
        gap: 20px;
    }
    
    .col-left {
        position: static; /* Quitar sticky */
        font-size: 1.05rem;
        margin-bottom: 20px;
    }
    
    .col-right {
        gap: 15px;
    }
    
    .artigo-text {
        font-size: 0.85rem;
        width: 75%;
    }
    
    .artigo-btn {
        transform: scale(1.5);
    }
    
    .artigo-btn:hover {
        transform: scale(1.6);
    }
    
    .dropdown-item {
        padding: 12px 15px;
        margin: 0 10px 8px 10px;
    }
    
    .dropdown-item-text {
        font-size: 0.85rem;
    }
    
    .drive-icon {
        width: 30px;
        height: 30px;
    }
}

/* ============================================================
   MÓVILES (320px - 480px)
   ============================================================ */
@media screen and (max-width: 480px) {
    
    /* SECCIÓN 1: Banner superior */
    .seccion-azul img {
        height: 200px;
    }
    
    /* SECCIÓN 2: Recuadro con foto */
    .contenedor-foto {
        width: 95%;
        margin: -80px auto 20px auto;
        min-height: 180px;
        padding: 10px;
    }
    
    /* SECCIÓN 3: Texto sobre foto */
    .texto-superior {
        font-size: 1rem;
    }
    
    /* SECCIÓN 4: Contenido principal */
    .contenido {
        padding: 20px 15px;
    }
    
    .contenido h1 {
        font-size: 2rem;
    }
    
    .contenido p {
        font-size: 1.05rem;
    }
    
    /* SECCIÓN 5: Banner azul con texto */
    .seccion-azul2 {
        height: 100px;
    }
    
    .texto-superior2 {
        font-size: clamp(1.8rem, 5vw, 2.2rem);
        padding: 0 10px;
    }
    
    /* SECCIÓN 6: Contenido con layout mixto */
    .contenido-2 {
        padding: 15px 10px;
    }
    
    .bloque-texto-izquierdo {
        font-size: 1.05rem;
    }
    
    .box1, .box2, .box3 {
        height: 180px;
        margin-bottom: 10px;
    }
    
    .bloque-texto-derecho {
        font-size: 1.05rem;
        margin-top: 15px;
    }
    
    /* SECCIÓN 7: Contenido azul */
    .bloque-texto-izquierdo2 {
        padding: 20px 5%;
    }
    
    .bloque-texto-izquierdo2 h1 {
        font-size: 2rem;
    }
    
    .bloque-texto-izquierdo2 p {
        font-size: 1.05rem;
    }
    
    .box4, .box5, .box6 {
        height: 180px;
        margin: 10px auto;
    }
    
    /* SECCIÓN 8: Contenido con grid */
    .bloque-texto-derecho2 {
        padding: 20px 5%;
    }
    
    .bloque-texto-derecho2 h1 {
        font-size: 2rem;
    }
    
    .bloque-texto-derecho2 p {
        font-size: 1.05rem;
    }
    
    .box7, .box8, .box9 {
        height: clamp(150px, 52vw, 210px);
        margin: 10px auto;
    }
    
    /* SECCIÓN 9: Artigos de Fé */
    .container-artigos {
        padding: 15px;
    }
    
    .col-left {
        font-size: 1.05rem;
    }
    
    .col-left p {
        margin-bottom: 15px;
    }
    
    .artigos-title {
        padding: 15px;
        font-size: 18px;
    }
    
    .artigo-box {
        padding: 12px 10px;
    }
    
    .artigo-text {
        font-size: 0.8rem;
        width: 70%;
    }
    
    .artigo-btn {
        width: 35px;
        height: 35px;
        transform: scale(1.3);
    }
    
    .artigo-btn:hover {
        transform: scale(1.4);
    }
    
    .dropdown-item {
        padding: 10px 12px;
        margin: 0 8px 6px 8px;
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    
    .dropdown-item-text {
        font-size: 0.8rem;
        width: 100%;
    }
    
    .drive-icon {
        width: 28px;
        height: 28px;
        align-self: flex-end;
    }
    
    .dropdown-content.active {
        max-height: 1000px;
    }
    
    /* Desactivar efecto hover en móviles */
    .caja:hover {
        transform: scale(1);
    }
}

/* ============================================================
   MÓVILES EXTRA PEQUEÑOS (max-width: 375px)
   ============================================================ */
@media screen and (max-width: 375px) {
    
    .contenido h1 {
        font-size: 1.8rem;
    }
    
    .contenido p {
        font-size: 1.05rem;
    }
    
    .texto-superior2 {
        font-size: clamp(1.6rem, 5vw, 2rem);
    }
    
    .bloque-texto-izquierdo,
    .bloque-texto-derecho,
    .bloque-texto-izquierdo2 p,
    .bloque-texto-derecho2 p {
        font-size: 1.05rem;
    }
    
    .bloque-texto-izquierdo2 h1,
    .bloque-texto-derecho2 h1 {
        font-size: 1.8rem;
    }
    
    .col-left {
        font-size: 1.05rem;
    }
    
    .artigo-text {
        font-size: 0.75rem;
    }
    
    .dropdown-item-text {
        font-size: 0.75rem;
    }
}

/* ============================================================
   Ajuste general: imágenes estables en pantallas táctiles
   ============================================================ */
@media screen and (max-width: 900px) {
    /* Nueva disposición móvil para la sección "¿O que somos na doutrina?" */
    .contenido-2 {
        grid-template-columns: 1fr;
        grid-template-areas:
            "texto1"
            "img1"
            "img2"
            "img3"
            "texto2";
        gap: 16px;
        padding: 24px 18px;
    }

    .bloque-texto-izquierdo {
        max-width: 100%;
    }

    .box1,
    .box2 {
        max-width: 100%;
        height: auto;
        justify-self: center;
    }

    .box3 {
        max-width: 100%;
        height: auto;
        justify-self: center;
    }

    /* Reacomodo misión en móvil */
    .seccion-azul3 {
        grid-template-columns: 1fr;
        grid-template-areas:
            "texto"
            "grande"
            "mini1"
            "mini2";
        padding: 24px 18px;
        gap: 12px;
    }

    .bloque-texto-izquierdo2 {
        padding: 14px 0;
        line-height: 1.65;
    }

    .box4 {
        height: auto;
        max-width: 100%;
    }

    .box5,
    .box6 {
        height: auto;
        max-width: 100%;
    }

    /* Ajuste Visión en móvil */
    .contenido-3 {
        grid-template-columns: 1fr;
        padding: 24px 18px;
        gap: 14px;
    }

    .contenido-3 .columna-imagenes {
        padding-left: 0;
        align-items: center;
    }

    .box7, .box8, .box9 {
        width: 100%;
        height: auto;
    }

    /* Evita saltos de layout por escalado en hover */
    .caja,
    .caja:hover {
        transform: none;
    }
    /* Mantiene las imágenes dentro de su contenedor */
    .caja {
        width: 100%;
        max-width: 100%;
        height: auto;
    }
}

