/* ==========================================================================
   Colegio Mayor del Caribe — sistema visual
   Paleta institucional: tinta (azul oscuro del escudo) · verde (del escudo) · sol (amarillo caribe)
   Tipografía: Bricolage Grotesque (display) · Figtree (texto) · IBM Plex Mono (glosa)
   ========================================================================== */

:root {
    --tinta: #081E33;
    --tinta-suave: #0E3A5C;
    --verde: #1B6E4A;
    --verde-oscuro: #123F2C;
    --verde-brillo: #2F9E6E;
    --verde-claro: #E9F3EC;
    --mar: #1B6E4A;              /* alias retrocompatible: reutilizado como acento institucional */
    --mar-claro: #E9F3EC;
    --sol: #F4B942;
    --sol-claro: #FFE3A3;
    --espuma: #F8F5EE;
    --marfil: #FBFAF6;
    --nube: #FFFFFF;
    --grafito: #4B5A5A;
    --linea: rgba(8, 30, 51, 0.11);
    --sombra: 0 18px 40px -24px rgba(8, 30, 51, 0.4);
    --sombra-alta: 0 30px 60px -30px rgba(8, 30, 51, 0.5);
    --sombra-verde: 0 16px 34px -20px rgba(27, 110, 74, 0.5);
    --radio: 22px;
    --radio-s: 12px;
    --ancho: 1440px;
    --display: 'Fraunces', 'Figtree', serif;
    --marca: 'Outfit', 'Figtree', system-ui, sans-serif;
    --texto: "Figtree", system-ui, -apple-system, "Segoe UI", sans-serif;
    --mono: "IBM Plex Mono", ui-monospace, "SFMono-Regular", monospace;
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
    margin: 0;
    font-family: var(--texto);
    font-size: 17px;
    line-height: 1.65;
    letter-spacing: -.005em;
    text-rendering: optimizeLegibility;
    color: var(--tinta);
    background: var(--marfil);
    -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }
a { color: var(--mar); text-decoration: none; }
a:hover { text-decoration: underline; }

:focus-visible {
    outline: 2px solid var(--verde);
    outline-offset: 3px;
    border-radius: 8px;
    box-shadow: 0 0 0 6px rgba(27, 110, 74, .16);
}

h1, h2, h3, h4 {
    font-family: var(--display);
    font-weight: 700;
    line-height: 1.1;
    letter-spacing: -0.02em;
    margin: 0 0 0.5em;
    text-wrap: balance;
}

h1 { font-size: clamp(2.2rem, 4.8vw, 4rem); font-weight: 600; }
h2 { font-size: clamp(1.75rem, 3.4vw, 2.85rem); font-weight: 600; }
h3 { font-size: clamp(1.15rem, 2vw, 1.45rem); }

p { margin: 0 0 1em; }
p:last-child { margin-bottom: 0; }

.contenedor {
    width: 100%;
    max-width: var(--ancho);
    margin-inline: auto;
    padding-inline: clamp(20px, 4vw, 60px);
}
.contenedor--estrecho { max-width: 1120px; }

.saltar {
    position: absolute;
    left: -9999px;
    top: 0;
    background: var(--tinta);
    color: #fff;
    padding: 12px 18px;
    z-index: 999;
}
.saltar:focus { left: 12px; top: 12px; }

/* --- Glosa bilingüe: la firma del sitio ------------------------------- */
.glosa {
    font-family: var(--mono);
    font-size: 0.68rem;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--mar);
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 14px;
}
.glosa::before {
    content: "EN";
    font-size: 0.6rem;
    letter-spacing: 0.08em;
    background: var(--mar);
    color: #fff;
    padding: 2px 5px;
    border-radius: 4px;
    line-height: 1.2;
}
.glosa--claro { color: rgba(255, 255, 255, 0.82); }
.glosa--claro::before { background: var(--sol); color: var(--tinta); }
.glosa--sin-tag::before { content: none; }

.eyebrow {
    font-family: var(--mono);
    font-size: 0.7rem;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--grafito);
    margin: 0 0 10px;
}

/* --- Botones ---------------------------------------------------------- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    font-family: var(--texto);
    font-weight: 600;
    font-size: 0.97rem;
    letter-spacing: -.01em;
    padding: 13px 26px;
    border-radius: 999px;
    border: 1.5px solid transparent;
    background: var(--mar);
    color: #fff;
    cursor: pointer;
    box-shadow: 0 1px 2px rgba(8, 30, 51, .1), 0 8px 20px -12px rgba(27, 110, 74, .45);
    transition: transform .2s cubic-bezier(.2, .8, .2, 1), background .2s ease, color .2s ease, border-color .2s ease, box-shadow .2s ease;
    text-decoration: none;
}
.btn:hover { background: var(--verde-oscuro); text-decoration: none; transform: translateY(-1px); box-shadow: 0 2px 4px rgba(8, 30, 51, .12), 0 14px 28px -12px rgba(27, 110, 74, .5); }
.btn:active { transform: translateY(0) scale(.98); }
.btn--sol { background: var(--sol); color: #3A2600; box-shadow: 0 1px 2px rgba(58, 38, 0, .12), 0 10px 24px -14px rgba(244, 185, 66, .8); }
.btn--sol:hover { background: #FFD264; transform: translateY(-1px); box-shadow: 0 2px 4px rgba(58, 38, 0, .14), 0 14px 28px -12px rgba(244, 185, 66, .85); }
.btn--linea { background: rgba(8, 30, 51, .04); border-color: rgba(8, 30, 51, .14); color: var(--tinta); box-shadow: none; }
.btn--linea:hover { background: var(--tinta); color: #fff; border-color: var(--tinta); }
.btn--claro { background: rgba(255, 255, 255, .12); border-color: rgba(255,255,255,.5); color: #fff; backdrop-filter: blur(6px); }
.btn--claro:hover { background: #fff; color: var(--tinta); border-color: #fff; }
.btn--bloque { width: 100%; }

/* --- Barra superior --------------------------------------------------- */
.cinta {
    background: var(--tinta);
    color: rgba(255, 255, 255, 0.86);
    font-size: 0.83rem;
}
.cinta .contenedor {
    display: flex;
    flex-wrap: wrap;
    gap: 6px 22px;
    align-items: center;
    justify-content: space-between;
    min-height: 36px;
    padding-block: 5px;
}
.cinta-telefonos { display: inline-flex; align-items: center; gap: 8px; white-space: nowrap; }
.cinta-telefonos .sep { opacity: .45; }
.cinta a { color: inherit; }
.cinta-datos { display: flex; flex-wrap: wrap; gap: 6px 20px; }
.cinta-enlaces { display: flex; flex-wrap: wrap; gap: 6px 18px; }
.cinta-enlaces a { font-family: var(--mono); font-size: .72rem; letter-spacing: .12em; text-transform: uppercase; }

/* --- Franja de aviso (inscripciones) ---------------------------------- */
.franja-aviso {
    background: linear-gradient(100deg, var(--sol) 0%, #FFD97A 55%, var(--sol) 100%);
    color: #3A2600;
    position: relative;
    z-index: 40;
}
.franja-aviso .contenedor {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 10px 22px;
    padding-block: 11px;
}
.franja-aviso p {
    margin: 0;
    font-weight: 600;
    font-size: .95rem;
    letter-spacing: -.01em;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    text-align: center;
}
.franja-punto {
    width: 9px; height: 9px;
    border-radius: 50%;
    background: #1B6E4A;
    flex: none;
    box-shadow: 0 0 0 4px rgba(27, 110, 74, .22);
    animation: latido 2.4s ease-in-out infinite;
}
@keyframes latido {
    0%, 100% { box-shadow: 0 0 0 4px rgba(27, 110, 74, .22); }
    50% { box-shadow: 0 0 0 7px rgba(27, 110, 74, .1); }
}
.franja-btn {
    background: #08331F;
    color: #fff;
    font-weight: 600;
    font-size: .88rem;
    letter-spacing: -.01em;
    padding: 8px 18px;
    border-radius: 999px;
    text-decoration: none;
    white-space: nowrap;
    transition: transform .2s cubic-bezier(.2, .8, .2, 1), background .2s ease;
}
.franja-btn:hover { background: var(--verde); color: #fff; text-decoration: none; transform: translateY(-1px); }
.franja-btn:active { transform: scale(.98); }

@media (max-width: 620px) {
    .franja-aviso .contenedor { flex-direction: column; gap: 10px; padding-block: 13px; }
    .franja-aviso p { font-size: .88rem; }
}

/* --- Encabezado ------------------------------------------------------- */
.encabezado {
    position: sticky;
    top: 0;
    z-index: 60;
    background: transparent;
    border-bottom: 1px solid rgba(8, 30, 51, 0.08);
}
/* El vidrio esmerilado va en una capa de fondo.
   Si se aplica al encabezado, éste atrapa al menú móvil (position: fixed). */
.encabezado::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    background: rgba(251, 250, 246, 0.88);
    backdrop-filter: blur(16px) saturate(160%);
    -webkit-backdrop-filter: blur(16px) saturate(160%);
}
.encabezado .contenedor {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    min-height: 92px;
}
.marca { display: flex; align-items: center; gap: 14px; text-decoration: none; color: var(--tinta); }
.marca:hover { text-decoration: none; }
.marca img { height: 76px; width: 76px; object-fit: contain; border-radius: 0; border: 0; box-shadow: none; }
.marca-texto strong {
    display: block;
    font-family: var(--marca);
    font-size: 1.22rem;
    font-weight: 600;
    letter-spacing: -0.018em;
    line-height: 1.12;
    color: var(--tinta);
    white-space: nowrap;
}
.marca-texto span {
    font-family: var(--mono);
    font-size: 0.62rem;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--verde);
}

.menu { display: flex; align-items: center; gap: 2px; }
.menu a:not(.btn) {
    color: var(--tinta);
    font-weight: 600;
    font-size: 0.95rem;
    white-space: nowrap;
    padding: 10px 13px;
    border-radius: 999px;
    position: relative;
}
.menu a:not(.btn)::after {
    content: "";
    position: absolute;
    left: 15px; right: 15px; bottom: 2px;
    height: 2px;
    background: var(--sol);
    border-radius: 2px;
    transform: scaleX(0);
    transform-origin: left;
    transition: transform .22s ease;
}
.menu a:not(.btn):hover { text-decoration: none; color: var(--verde); }
.menu a:not(.btn):hover::after, .menu a.activo:not(.btn)::after { transform: scaleX(1); }
.menu a.activo:not(.btn) { color: var(--verde); }
.menu-acciones { display: flex; align-items: center; gap: 8px; margin-left: 18px; }

.menu .btn-portal, .btn-portal, .encabezado .btn-portal {
    background: var(--verde);
    border: 0;
    color: #fff;
    padding: 10px 20px 10px 10px;
    font-size: .9rem;
    font-weight: 600;
    letter-spacing: -.01em;
    gap: 10px;
    white-space: nowrap;
    color: #fff;
    text-indent: 0;
    overflow: visible;
    box-shadow: 0 1px 2px rgba(8, 30, 51, .1), 0 8px 20px -10px rgba(27, 110, 74, .5);
}
.btn-portal .portal-texto,
.encabezado .btn-portal .portal-texto {
    display: inline-block !important;
    visibility: visible !important;
    opacity: 1 !important;
    color: #fff !important;
    font-size: .9rem;
    font-weight: 600;
    line-height: 1.2;
    text-indent: 0 !important;
    width: auto !important;
    height: auto !important;
    clip: auto !important;
}
.btn-portal .portal-icono {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: rgba(255, 255, 255, .22);
    display: grid;
    place-items: center;
    flex: none;
    transition: background .2s ease;
}
.btn-portal svg { width: 15px; height: 15px; flex: none; }
.btn-portal:hover {
    background: var(--verde-brillo);
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(8, 30, 51, .12), 0 12px 26px -10px rgba(27, 110, 74, .6);
}
.btn-portal:hover .portal-icono { background: rgba(255, 255, 255, .3); }
.btn-portal:active { transform: translateY(0) scale(.98); }

.hamburguesa {
    display: none;
    position: relative;
    z-index: 100;
    background: rgba(8, 30, 51, .05);
    border: 1px solid var(--linea);
    border-radius: 12px;
    width: 48px;
    height: 44px;
    cursor: pointer;
    padding: 0;
    align-items: center;
    justify-content: center;
    transition: background .2s ease, border-color .2s ease;
}
.hamburguesa span { display: block; width: 20px; height: 2px; background: var(--tinta); position: relative; transition: background .25s ease; }
.hamburguesa span::before, .hamburguesa span::after {
    content: ""; position: absolute; left: 0; width: 20px; height: 2px; background: var(--tinta);
    transition: transform .3s cubic-bezier(.5, 0, .2, 1), background .25s ease;
}
.hamburguesa span::before { top: -6px; }
.hamburguesa span::after { top: 6px; }
.hamburguesa[aria-expanded="true"] { background: rgba(255, 255, 255, .12); border-color: rgba(255, 255, 255, .3); }
.hamburguesa[aria-expanded="true"] span { background: transparent; }
.hamburguesa[aria-expanded="true"] span::before { transform: translateY(6px) rotate(45deg); background: #fff; }
.hamburguesa[aria-expanded="true"] span::after { transform: translateY(-6px) rotate(-45deg); background: #fff; }

@media (max-width: 1340px) {
    .menu a:not(.btn) { padding: 9px 9px; font-size: .88rem; }
    .menu-acciones { margin-left: 8px; }
    .btn-portal { padding: 9px 15px 9px 9px; font-size: .82rem; }
    .btn-portal .portal-texto { font-size: .82rem; }
    .marca img { height: 64px; width: 64px; }
    .marca-texto strong { font-size: 1.1rem; }
}

@media (max-width: 1150px) {
    .hamburguesa { display: flex; }
    .encabezado .contenedor { min-height: 82px; }
    .marca img { height: 58px; width: 58px; }
    .marca-texto strong { font-size: 1.02rem; }
    .marca-texto span { font-size: .55rem; }

    .menu {
        position: fixed;
        inset: 0;
        z-index: 95;
        width: 100%;
        height: 100%;
        height: 100dvh;
        background:
            radial-gradient(60% 40% at 80% 8%, rgba(47, 158, 110, .5), transparent 65%),
            radial-gradient(50% 35% at 5% 95%, rgba(244, 185, 66, .22), transparent 62%),
            linear-gradient(170deg, #081E33 0%, #123F2C 100%);
        flex-direction: column;
        align-items: stretch;
        justify-content: flex-start;
        gap: 0;
        padding: 84px 28px 40px;
        -webkit-overflow-scrolling: touch;
        transform: translateY(-100%);
        transition: transform .38s cubic-bezier(.5, 0, .2, 1);
        overflow-y: auto;
        box-shadow: none;
    }
    .menu.abierto { transform: translateY(0); }
    .menu a:not(.btn) {
        padding: 14px 4px;
        border-bottom: 1px solid rgba(255, 255, 255, .13);
        border-radius: 0;
        color: #fff;
        font-family: var(--display);
        font-size: 1.28rem;
        font-weight: 600;
        letter-spacing: -.01em;
        flex: none;
        opacity: 1;
    }
    .menu.abierto a:not(.btn) { animation: entrarEnlace .45s cubic-bezier(.2, .8, .2, 1) forwards; }
    .menu.abierto a:nth-child(1) { animation-delay: .06s; }
    .menu.abierto a:nth-child(2) { animation-delay: .11s; }
    .menu.abierto a:nth-child(3) { animation-delay: .16s; }
    .menu.abierto a:nth-child(4) { animation-delay: .21s; }
    .menu.abierto a:nth-child(5) { animation-delay: .26s; }
    .menu.abierto a:nth-child(6) { animation-delay: .31s; }
    .menu.abierto a:nth-child(7) { animation-delay: .36s; }
    .menu a:not(.btn)::after { display: none; }
    .menu a:not(.btn):hover, .menu a.activo:not(.btn) { color: var(--sol); }
    .menu a.activo:not(.btn)::before { content: "— "; color: var(--sol); }

    .menu-acciones { flex-direction: column; align-items: stretch; margin: 22px 0 10px; gap: 10px; flex: none; }
    .menu-acciones .btn { justify-content: center; border-bottom: none; }
    .btn-portal {
        background: linear-gradient(135deg, var(--sol), #E0A32E);
        color: #3A2600;
        padding: 14px 22px;
        font-size: 1rem;
        box-shadow: 0 16px 32px -14px rgba(244, 185, 66, .7);
    }
    .btn-portal .portal-icono { background: rgba(58, 38, 0, .14); }
    .btn-portal:hover { background: linear-gradient(135deg, var(--sol), #E0A32E); color: #3A2600; }
    .btn-portal:hover .portal-icono { background: rgba(58, 38, 0, .22); }

    .cinta-datos { display: none; }
}

@keyframes entrarEnlace { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: translateY(0); } }

@media (max-width: 560px) {
    .marca-texto strong { font-size: .95rem; max-width: 170px; }
    .marca img { height: 52px; width: 52px; }
    .menu { padding: 80px 22px 34px; }
    .menu a:not(.btn) { font-size: 1.15rem; padding: 13px 4px; }
}

/* Pantallas de poca altura: el menú se ajusta para no cortar nada */
@media (max-width: 1150px) and (max-height: 720px) {
    .menu { padding-top: 76px; }
    .menu a:not(.btn) { font-size: 1.05rem; padding: 11px 4px; }
    .menu-acciones { margin-top: 16px; }
}

/* --- Portada ---------------------------------------------------------- */
.portada { position: relative; background: var(--tinta); color: #fff; overflow: hidden; }
.diapositiva {
    display: none;
    position: relative;
    min-height: 640px;
    height: 640px;
}
@media (max-width: 900px) { .diapositiva { min-height: 580px; height: 580px; } }
@media (max-width: 560px) { .diapositiva { min-height: 540px; height: 540px; } }
.diapositiva.activa { display: flex; align-items: center; animation: aparecer .7s ease both; }
.diapositiva > .contenedor { width: 100%; }
@keyframes aparecer { from { opacity: 0; } to { opacity: 1; } }

.diapositiva-fondo { position: absolute; inset: 0; overflow: hidden; }
.diapositiva-fondo img { width: 100%; height: 100%; object-fit: cover; }

/* --- Modo "completa": la pieza gráfica se ve entera, sin recortes -------
   La imagen se centra con object-fit: contain y los costados se rellenan
   con la misma imagen ampliada y difuminada, en vez de barras vacías. */
.diapositiva-fondo--completa .diapositiva-imagen {
    object-fit: contain;
    position: relative;
    z-index: 2;
}
.diapositiva-relleno {
    position: absolute;
    inset: 0;
    z-index: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: blur(34px) saturate(120%) brightness(.72);
    transform: scale(1.18);
}

/* --- Modo sin difuminado: la imagen se ve nítida, sin velo de color ---- */
.diapositiva-fondo--nitida::after { display: none; }
.diapositiva-fondo--nitida::before { display: none; }

/* Una diapositiva sin textos no necesita reservar espacio para ellos */
.diapositiva--solo-imagen > .contenedor { display: none; }

/* Si la pieza gráfica lleva enlace, toda la imagen es clicable */
.diapositiva-enlace {
    position: absolute;
    inset: 0;
    z-index: 3;
    display: block;
}
.diapositiva-enlace span {
    position: absolute;
    left: -9999px;
}
.diapositiva-fondo::after {
    content: "";
    position: absolute;
    inset: 0;
    background:
        radial-gradient(55% 60% at 10% 10%, rgba(47, 158, 110, .5), transparent 62%),
        radial-gradient(42% 45% at 94% 6%, rgba(244, 185, 66, .3), transparent 60%),
        linear-gradient(115deg, rgba(8, 30, 51, .96) 0%, rgba(8, 30, 51, .88) 40%, rgba(18, 63, 44, .6) 78%, rgba(18, 63, 44, .28) 100%);
}
.diapositiva-fondo::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 1;
    background-image: radial-gradient(rgba(244, 185, 66, .55) 1.5px, transparent 1.5px);
    background-size: 26px 26px;
    opacity: .12;
    mix-blend-mode: overlay;
}
.diapositiva-texto {
    position: relative;
    z-index: 2;
    max-width: 680px;
    padding-block: 40px;
    max-height: 100%;
    overflow: hidden;
}
.diapositiva-texto h1 { color: #fff; margin-bottom: 18px; }
.diapositiva-texto h1 em { font-style: italic; font-weight: 500; color: var(--sol-claro); }
.diapositiva-texto p { color: rgba(255, 255, 255, .84); font-size: 1.08rem; max-width: 54ch; }
.diapositiva-acciones { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 26px; }

.portada-sello {
    position: absolute;
    z-index: 3;
    right: 46px;
    bottom: 88px;
    width: 136px;
    height: 136px;
    border-radius: 50%;
    background: rgba(255, 255, 255, .1);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, .35);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: #fff;
    text-align: center;
}
.portada-sello::before { content: ""; position: absolute; inset: 9px; border-radius: 50%; border: 1px dashed rgba(255, 255, 255, .38); }
.portada-sello strong { font-family: var(--display); font-size: 1.7rem; font-weight: 700; line-height: 1; }
.portada-sello span { font-family: var(--mono); font-size: .58rem; letter-spacing: .12em; text-transform: uppercase; color: var(--sol-claro); margin-top: 5px; max-width: 90px; line-height: 1.3; }
@media (max-width: 860px) { .portada-sello { display: none; } }

.portada-controles {
    position: absolute;
    left: 0; right: 0; bottom: 24px;
    z-index: 3;
}
.portada-controles .contenedor { display: flex; align-items: center; gap: 12px; }
.punto {
    width: 34px; height: 4px; border-radius: 99px; border: 0; padding: 0;
    background: rgba(255, 255, 255, .35); cursor: pointer; transition: background .2s;
}
.punto[aria-current="true"] { background: var(--sol); width: 52px; }

/* --- Franja de cifras ------------------------------------------------- */
.cifras { background: linear-gradient(135deg, var(--sol), #E0A32E); color: #3A2600; }
.cifras .contenedor {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 4px 34px;
    padding-block: 26px;
}
.cifra { display: flex; align-items: baseline; gap: 12px; }
.cifra strong { font-family: var(--display); font-size: 2.15rem; font-weight: 700; line-height: 1; }
.cifra span { font-size: .93rem; line-height: 1.35; }

/* --- Secciones -------------------------------------------------------- */
.seccion { padding-block: clamp(56px, 8vw, 96px); }
.seccion--espuma { background: var(--espuma); }
.seccion--tinta {
    position: relative;
    background:
        radial-gradient(50% 55% at 90% 0%, rgba(47, 158, 110, .35), transparent 62%),
        radial-gradient(40% 40% at 8% 100%, rgba(244, 185, 66, .18), transparent 60%),
        linear-gradient(165deg, #081E33 0%, #123F2C 100%);
    color: #fff;
    overflow: hidden;
}
.seccion--tinta h2, .seccion--tinta h3 { color: #fff; }
.seccion--tinta p { color: rgba(255, 255, 255, .8); }

.cabecera-seccion { max-width: 760px; margin-bottom: 40px; }
.cabecera-seccion p { color: var(--grafito); font-size: 1.05rem; }
.cabecera-seccion h2 { text-wrap: balance; }
.seccion--tinta .cabecera-seccion p { color: rgba(255, 255, 255, .78); }
.cabecera-seccion--centro { margin-inline: auto; text-align: center; }
.cabecera-seccion--centro .glosa { justify-content: center; }

/* En pantallas anchas el encabezado ocupa todo el ancho con un orden claro:
   la glosa y el título a la izquierda, la explicación a la derecha,
   separadas por una línea fina que guía la lectura. */
@media (min-width: 1100px) {
    .cabecera-seccion:not(.cabecera-seccion--centro) {
        max-width: 100%;
        display: grid;
        grid-template-columns: minmax(340px, 1.1fr) minmax(340px, 1fr);
        grid-template-areas:
            "glosa  texto"
            "titulo texto";
        column-gap: clamp(48px, 6vw, 96px);
        row-gap: 0;
        align-items: start;
        margin-bottom: 52px;
    }
    .cabecera-seccion:not(.cabecera-seccion--centro) .glosa {
        grid-area: glosa;
        margin-bottom: 14px;
    }
    .cabecera-seccion:not(.cabecera-seccion--centro) h2 {
        grid-area: titulo;
        margin-bottom: 0;
        align-self: start;
    }
    .cabecera-seccion:not(.cabecera-seccion--centro) p {
        grid-area: texto;
        margin: 0;
        max-width: 56ch;
        padding-left: clamp(24px, 3vw, 40px);
        border-left: 1px solid var(--linea);
        align-self: center;
    }
    .seccion--tinta .cabecera-seccion:not(.cabecera-seccion--centro) p {
        border-left-color: rgba(255, 255, 255, .22);
    }
}

/* Entre 900 y 1100 px vuelve a una sola columna, pero con más aire */
@media (min-width: 900px) and (max-width: 1099px) {
    .cabecera-seccion { max-width: 820px; }
}

/* El texto de las páginas internas también respira mejor */
.cabecera-pagina p { max-width: 70ch; }
.cabecera-pagina h1 { text-wrap: balance; max-width: 20ch; }
@media (min-width: 1100px) {
    .cabecera-pagina h1 { max-width: 26ch; }
}

.rejilla { display: grid; gap: 24px; }
.rejilla--2 { grid-template-columns: repeat(auto-fit, minmax(340px, 1fr)); }
.rejilla--3 { grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); }
.rejilla--4 { grid-template-columns: repeat(auto-fit, minmax(270px, 1fr)); }
@media (min-width: 1200px) { .rejilla { gap: 30px; } }

/* --- Tarjetas de nivel (abren modal) ------------------------------------ */
.nivel {
    position: relative;
    display: flex;
    flex-direction: column;
    background: #fff;
    border: 1px solid var(--linea);
    border-radius: var(--radio);
    overflow: hidden;
    text-align: left;
    width: 100%;
    padding: 0;
    cursor: pointer;
    font-family: inherit;
    color: inherit;
    text-decoration: none;
    box-shadow: 0 1px 2px rgba(8, 30, 51, .05), 0 12px 30px -18px rgba(8, 30, 51, .22);
    transition: transform .34s cubic-bezier(.2, .8, .2, 1), box-shadow .34s ease, border-color .3s ease;
}
.nivel:hover { text-decoration: none; }
.nivel::before {
    content: "";
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--verde), var(--sol));
    transform: scaleX(0);
    transform-origin: left;
    transition: transform .25s ease;
}
.nivel:hover, .nivel:focus-visible {
    transform: translateY(-8px);
    box-shadow: 0 4px 10px -4px rgba(8, 30, 51, .18), 0 30px 60px -28px rgba(27, 110, 74, .55);
    border-color: rgba(27, 110, 74, .3);
}
.nivel:hover::before, .nivel:focus-visible::before { transform: scaleX(1); }
.nivel-foto { aspect-ratio: 16 / 10; background: var(--verde-claro); position: relative; overflow: hidden; }
.nivel-foto img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.nivel:hover .nivel-foto img, .nivel:focus-visible .nivel-foto img { transform: scale(1.06); }
.nivel-foto::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, rgba(8, 30, 51, .5), transparent 55%); }
.nivel-cuerpo { padding: 20px 22px 26px; display: flex; flex-direction: column; flex: 1; }
.nivel-edades {
    font-family: var(--mono);
    font-size: .68rem;
    letter-spacing: .14em;
    text-transform: uppercase;
    color: var(--verde);
    margin-bottom: 8px;
}
.nivel-foto .nivel-edades {
    position: absolute;
    left: 14px;
    bottom: 12px;
    z-index: 2;
    background: rgba(255, 255, 255, .92);
    backdrop-filter: blur(6px);
    color: var(--tinta);
    padding: 5px 12px;
    border-radius: 999px;
    margin: 0;
}
.nivel h3 { margin-bottom: 6px; }
.nivel-etiqueta { font-size: .85rem; color: var(--grafito); margin-bottom: 12px; }
.nivel p { color: var(--grafito); font-size: .96rem; }
.nivel-enlace {
    margin-top: auto;
    padding-top: 16px;
    font-weight: 700;
    font-size: .93rem;
    display: inline-flex;
    align-items: center;
    gap: 7px;
    color: var(--verde);
}
.nivel-enlace::after { content: "→"; transition: transform .18s ease; }
.nivel:hover .nivel-enlace::after { transform: translateX(4px); }

/* --- Modal de nivel ----------------------------------------------------- */
.modal {
    position: fixed;
    inset: 0;
    z-index: 210;
    background: rgba(11, 46, 79, .6);
    backdrop-filter: blur(3px);
    display: none;
    align-items: center;
    justify-content: center;
    padding: 22px;
}
.modal.abierto { display: flex; }
.modal-caja {
    width: min(700px, 100%);
    max-height: min(84vh, 780px);
    background: #fff;
    border-radius: 22px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    box-shadow: var(--sombra-alta);
}
.modal-foto { aspect-ratio: 21 / 8; background: var(--verde-claro); flex: none; position: relative; }
.modal-foto img { width: 100%; height: 100%; object-fit: cover; }
.modal-cerrar {
    position: absolute;
    top: 14px; right: 14px;
    width: 40px; height: 40px;
    border-radius: 50%;
    border: 0;
    background: rgba(11, 46, 79, .55);
    color: #fff;
    font-size: 1.15rem;
    cursor: pointer;
    display: grid;
    place-items: center;
}
.modal-cuerpo { padding: 28px 30px 30px; overflow-y: auto; }
.modal-cuerpo .nivel-edades { margin-bottom: 6px; }
.modal-cuerpo h3 { font-size: clamp(1.3rem, 3vw, 1.7rem); margin-bottom: 4px; }
.modal-etiqueta { font-size: .92rem; color: var(--grafito); margin-bottom: 18px; }
.modal-pie {
    padding-top: 22px;
    margin-top: 22px;
    border-top: 1px solid var(--linea);
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: center;
}
.modal-pie span { font-size: .86rem; color: var(--grafito); }

/* --- Bloque destacado (texto + imagen) -------------------------------- */
.duo {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: clamp(28px, 5vw, 70px);
    align-items: center;
}
@media (min-width: 1200px) {
    .duo { grid-template-columns: 1.05fr 1fr; }
    .duo p, .duo .lista-marcada { max-width: 60ch; }
}
.duo-foto { border-radius: var(--radio); overflow: hidden; box-shadow: var(--sombra); }
.duo-foto img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.lista-marcada { list-style: none; padding: 0; margin: 20px 0 0; display: grid; gap: 13px; }
.lista-marcada li { display: flex; gap: 12px; align-items: flex-start; font-size: 1rem; }
.lista-marcada li::before {
    content: "";
    flex: none;
    width: 10px; height: 10px;
    margin-top: 8px;
    border-radius: 3px;
    background: var(--sol);
    box-shadow: 0 0 0 3px rgba(255, 200, 69, .22);
}

/* --- Dependencias ----------------------------------------------------- */
.dependencia {
    position: relative;
    border-radius: var(--radio);
    overflow: hidden;
    min-height: 300px;
    display: flex;
    align-items: flex-end;
    color: #fff;
    isolation: isolate;
    transition: transform .22s ease, box-shadow .22s ease;
}
.dependencia:hover { transform: translateY(-8px); box-shadow: 0 4px 10px -4px rgba(8, 30, 51, .2), 0 34px 64px -30px rgba(8, 30, 51, .6); }
.dependencia img { transition: transform .6s ease; }
.dependencia:hover img { transform: scale(1.07); }
.dependencia img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; }
.dependencia::after {
    content: ""; position: absolute; inset: 0; z-index: -1;
    background: linear-gradient(to top, rgba(10, 37, 64, .94) 12%, rgba(10, 37, 64, .25) 78%);
}
.dependencia-cuerpo { padding: 26px 24px; }
.dependencia h3 { color: #fff; margin-bottom: 6px; }
.dependencia p { color: rgba(255, 255, 255, .82); font-size: .94rem; margin-bottom: 14px; }

/* --- Blog ------------------------------------------------------------- */
.entrada {
    position: relative;
    display: flex;
    flex-direction: column;
    background: #fff;
    border: 1px solid var(--linea);
    border-radius: var(--radio);
    overflow: hidden;
    box-shadow: 0 1px 2px rgba(8, 30, 51, .05), 0 12px 30px -18px rgba(8, 30, 51, .22);
    transition: transform .34s cubic-bezier(.2, .8, .2, 1), box-shadow .34s ease, border-color .3s ease;
}
.entrada:hover {
    transform: translateY(-8px);
    box-shadow: 0 4px 10px -4px rgba(8, 30, 51, .18), 0 30px 60px -28px rgba(8, 30, 51, .45);
    border-color: rgba(27, 110, 74, .25);
}
.entrada-foto { aspect-ratio: 16 / 9; background: var(--espuma); overflow: hidden; }
.entrada-foto img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.entrada:hover .entrada-foto img { transform: scale(1.06); }
.entrada-cuerpo { padding: 20px 22px 24px; display: flex; flex-direction: column; flex: 1; }
.entrada-meta {
    font-family: var(--mono);
    font-size: .68rem;
    letter-spacing: .12em;
    text-transform: uppercase;
    color: var(--mar);
    margin-bottom: 10px;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}
.entrada-meta em { font-style: normal; color: var(--grafito); }
.entrada h3 { font-size: 1.2rem; margin-bottom: 8px; }
.entrada p { color: var(--grafito); font-size: .95rem; }

.articulo { max-width: 760px; margin-inline: auto; }
.articulo-portada { border-radius: var(--radio); overflow: hidden; margin-bottom: 32px; }
.articulo-portada img { width: 100%; aspect-ratio: 16 / 8; object-fit: cover; }
.articulo-cuerpo { font-size: 1.06rem; }
.articulo-cuerpo h3 { margin-top: 1.6em; }
.articulo-cuerpo ul, .articulo-cuerpo ol { padding-left: 1.2em; display: grid; gap: 8px; margin-bottom: 1.2em; }
.articulo-cuerpo img { border-radius: var(--radio-s); margin-block: 1.4em; }
.articulo-cuerpo blockquote {
    margin: 1.6em 0;
    padding: 4px 0 4px 22px;
    border-left: 4px solid var(--sol);
    font-size: 1.12rem;
}

/* --- Cartelera digital ------------------------------------------------ */
.filtros { display: flex; flex-wrap: wrap; gap: 9px; margin-bottom: 30px; }
.filtro {
    font-family: var(--mono);
    font-size: .72rem;
    letter-spacing: .12em;
    text-transform: uppercase;
    padding: 9px 16px;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, .28);
    background: transparent;
    color: rgba(255, 255, 255, .8);
    cursor: pointer;
    transition: background .18s, color .18s, border-color .18s;
}
.filtro:hover { border-color: var(--sol); color: #fff; }
.filtro[aria-pressed="true"] { background: var(--sol); border-color: var(--sol); color: var(--tinta); }

.muro { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 20px; }
.clip {
    position: relative;
    border: 0;
    padding: 0;
    background: #071c31;
    border-radius: 16px;
    overflow: hidden;
    cursor: pointer;
    text-align: left;
    color: #fff;
    aspect-ratio: 9 / 14;
    display: block;
    width: 100%;
    transition: transform .22s ease, box-shadow .22s ease;
}
.clip:hover, .clip:focus-visible { transform: translateY(-5px); box-shadow: var(--sombra-alta); }
.clip img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: .82; }
.clip::after {
    content: ""; position: absolute; inset: 0;
    background: linear-gradient(to top, rgba(4, 18, 32, .95) 18%, rgba(4, 18, 32, 0) 62%);
}
.clip-play {
    position: absolute;
    top: 12px; right: 12px;
    width: 38px; height: 38px;
    border-radius: 50%;
    background: rgba(255, 200, 69, .95);
    color: var(--tinta);
    display: grid;
    place-items: center;
    font-size: .8rem;
    z-index: 2;
}
.clip-cuerpo { position: absolute; left: 0; right: 0; bottom: 0; padding: 16px 15px; z-index: 2; }
.clip-grupo {
    font-family: var(--mono);
    font-size: .62rem;
    letter-spacing: .14em;
    text-transform: uppercase;
    color: var(--sol);
    display: block;
    margin-bottom: 5px;
}
.clip-cuerpo strong { display: block; font-family: var(--display); font-size: 1rem; line-height: 1.2; }
.clip-cuerpo em { font-style: normal; font-size: .78rem; color: rgba(255, 255, 255, .68); }

.visor {
    position: fixed;
    inset: 0;
    z-index: 200;
    background: rgba(4, 18, 32, .93);
    display: none;
    align-items: center;
    justify-content: center;
    padding: 22px;
}
.visor.abierto { display: flex; }
.visor-caja { width: min(430px, 100%); }
.visor-marco {
    position: relative;
    aspect-ratio: 9 / 16;
    background: #000;
    border-radius: 18px;
    overflow: hidden;
}
.visor-marco iframe, .visor-marco video { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.visor-pie { color: #fff; padding-top: 14px; }
.visor-pie strong { font-family: var(--display); font-size: 1.1rem; display: block; }
.visor-pie span { font-size: .85rem; color: rgba(255, 255, 255, .7); }
.visor-cerrar {
    position: absolute;
    top: 18px; right: 20px;
    width: 44px; height: 44px;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, .3);
    background: transparent;
    color: #fff;
    font-size: 1.3rem;
    cursor: pointer;
}

/* --- Vacíos ----------------------------------------------------------- */
.vacio {
    border: 1px dashed var(--linea);
    border-radius: var(--radio);
    padding: 44px 26px;
    text-align: center;
    color: var(--grafito);
}
.seccion--tinta .vacio { border-color: rgba(255, 255, 255, .25); color: rgba(255, 255, 255, .75); }

/* --- Formularios ------------------------------------------------------ */
.formulario { display: grid; gap: 16px; }
.campo { display: grid; gap: 6px; }
.campo label { font-weight: 700; font-size: .88rem; }
.campo input, .campo textarea, .campo select {
    font-family: var(--texto);
    font-size: 1rem;
    padding: 12px 14px;
    border: 1px solid var(--linea);
    border-radius: var(--radio-s);
    background: #fff;
    color: var(--tinta);
    width: 100%;
}
.campo textarea { min-height: 130px; resize: vertical; }
.campo input:focus, .campo textarea:focus, .campo select:focus { outline: 2px solid var(--mar); outline-offset: 1px; }
.campo-doble { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 16px; }
.ayuda { font-size: .82rem; color: var(--grafito); }

.aviso { padding: 14px 18px; border-radius: var(--radio-s); font-size: .95rem; margin-bottom: 20px; }
.aviso--ok { background: var(--verde-claro); color: #0f4a2e; border: 1px solid #bfe3cd; }
.aviso--error { background: #FDECEC; color: #8E2B2B; border: 1px solid #F3C9C9; }

/* --- Contacto --------------------------------------------------------- */
.tarjeta-datos {
    background: #fff;
    border: 1px solid var(--linea);
    border-radius: var(--radio);
    padding: 26px;
}
.datos-lista { list-style: none; padding: 0; margin: 0; display: grid; gap: 16px; }
.datos-lista li { display: grid; gap: 2px; }
.datos-lista span {
    font-family: var(--mono);
    font-size: .66rem;
    letter-spacing: .14em;
    text-transform: uppercase;
    color: var(--mar);
}

/* --- Cabecera de página interna --------------------------------------- */
.cabecera-pagina {
    background:
        radial-gradient(52% 58% at 88% 0%, rgba(47, 158, 110, .42), transparent 64%),
        radial-gradient(38% 42% at 4% 100%, rgba(244, 185, 66, .18), transparent 62%),
        linear-gradient(160deg, #081E33 0%, #123F2C 100%);
    color: #fff;
    padding-block: clamp(48px, 7vw, 78px);
    position: relative;
    overflow: hidden;
}
.cabecera-pagina--alta { padding-block: clamp(56px, 8vw, 96px); }
.cabecera-pagina h1 { color: #fff; margin-bottom: 12px; }
.cabecera-pagina p { color: rgba(255, 255, 255, .8); max-width: 62ch; }
.migas { font-family: var(--mono); font-size: .7rem; letter-spacing: .12em; text-transform: uppercase; color: rgba(255,255,255,.6); margin-bottom: 16px; }
.migas a { color: rgba(255, 255, 255, .82); }

/* --- Página CLEI ------------------------------------------------------ */
.clei-portada {
    display: grid;
    grid-template-columns: 1.15fr .85fr;
    gap: clamp(28px, 5vw, 60px);
    align-items: center;
}
.clei-portada-foto {
    border-radius: var(--radio);
    overflow: hidden;
    box-shadow: 0 40px 80px -40px rgba(0, 0, 0, .55);
    border: 1px solid rgba(255, 255, 255, .2);
}
.clei-portada-foto img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.clei-lema {
    font-family: var(--display);
    font-style: italic;
    font-size: clamp(1.05rem, 2vw, 1.3rem);
    color: var(--sol-claro) !important;
    margin-bottom: 16px;
}
.clei-cierre {
    font-family: var(--display);
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--sol-claro) !important;
    margin-top: 18px;
}
@media (max-width: 900px) { .clei-portada { grid-template-columns: 1fr; } }

.bloque-clei {
    position: relative;
    background: #fff;
    border: 1px solid var(--linea);
    border-radius: var(--radio);
    padding: 32px 30px 30px;
    box-shadow: 0 1px 2px rgba(8, 30, 51, .05), 0 12px 30px -18px rgba(8, 30, 51, .22);
    transition: transform .34s cubic-bezier(.2, .8, .2, 1), box-shadow .34s ease;
}
.bloque-clei:hover { transform: translateY(-5px); box-shadow: 0 4px 10px -4px rgba(8, 30, 51, .16), 0 28px 56px -30px rgba(27, 110, 74, .5); }
.bloque-clei-num {
    font-family: var(--mono);
    font-size: .72rem;
    letter-spacing: .16em;
    color: var(--verde);
    background: var(--verde-claro);
    padding: 5px 12px;
    border-radius: 999px;
    display: inline-block;
    margin-bottom: 14px;
}
.bloque-clei h2 { font-size: clamp(1.3rem, 2.4vw, 1.7rem); margin-bottom: 14px; }

.tarjeta-datos--oscura {
    background: rgba(255, 255, 255, .07);
    backdrop-filter: blur(14px);
    border: 1px solid rgba(255, 255, 255, .22);
    color: #fff;
}
.tarjeta-datos--oscura h3 { color: #fff; }
.tarjeta-datos--oscura .datos-lista span { color: var(--sol-claro); }
.tarjeta-datos--oscura a { color: #fff; text-decoration: underline; }

/* --- Pie -------------------------------------------------------------- */
.pie { background: var(--tinta); color: rgba(255, 255, 255, .76); padding-block: 56px 0; font-size: .95rem; }
.pie h4 {
    font-family: var(--mono);
    font-size: .7rem;
    letter-spacing: .18em;
    text-transform: uppercase;
    color: var(--sol);
    margin: 0 0 16px;
    font-weight: 500;
}
.pie a { color: rgba(255, 255, 255, .82); }
.pie-rejilla { display: grid; grid-template-columns: 1.5fr 1fr 1fr 1.2fr; gap: 34px; }
.pie-lista { list-style: none; padding: 0; margin: 0; display: grid; gap: 9px; }
.pie-logo { height: 62px; width: auto; margin-bottom: 16px; }
.pie-social { display: flex; gap: 10px; margin-top: 16px; }
.pie-social a {
    width: 40px; height: 40px;
    border: 1px solid rgba(255, 255, 255, .24);
    border-radius: 50%;
    display: grid;
    place-items: center;
}
.pie-social a:hover { background: var(--sol); border-color: var(--sol); color: var(--tinta); text-decoration: none; }
.pie-social svg { width: 17px; height: 17px; fill: currentColor; }
.pie-abajo {
    margin-top: 44px;
    padding-block: 20px;
    border-top: 1px solid rgba(255, 255, 255, .14);
    display: flex;
    flex-wrap: wrap;
    gap: 10px 22px;
    justify-content: space-between;
    font-size: .84rem;
    color: rgba(255, 255, 255, .55);
}

@media (max-width: 860px) {
    .pie-rejilla { grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
}

/* --- WhatsApp flotante ------------------------------------------------ */
.whatsapp {
    position: fixed;
    right: 18px;
    bottom: 18px;
    z-index: 90;
    width: 56px; height: 56px;
    border-radius: 50%;
    background: #25D366;
    color: #fff;
    display: grid;
    place-items: center;
    box-shadow: 0 12px 26px -10px rgba(0, 0, 0, .45);
}
.whatsapp:hover { text-decoration: none; transform: scale(1.06); }
.whatsapp svg { width: 28px; height: 28px; fill: currentColor; }

/* --- Aparición al hacer scroll ---------------------------------------- */
.revela {
    opacity: 0;
    transform: translateY(26px);
    transition: opacity .7s cubic-bezier(.2, .8, .2, 1), transform .7s cubic-bezier(.2, .8, .2, 1);
    will-change: opacity, transform;
}
.revela.visible { opacity: 1; transform: none; }
.revela:nth-child(2) { transition-delay: .08s; }
.revela:nth-child(3) { transition-delay: .16s; }
.revela:nth-child(4) { transition-delay: .24s; }
.revela:nth-child(5) { transition-delay: .32s; }
.revela:nth-child(6) { transition-delay: .4s; }

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after { animation-duration: .001ms !important; transition-duration: .001ms !important; }
    .revela { opacity: 1 !important; transform: none !important; }
}

/* ==========================================================================
   EXPERIENCIA MÓVIL — áreas de toque amplias, jerarquía clara
   ========================================================================== */
@media (max-width: 720px) {
    body { font-size: 16px; }

    /* Cabecera compacta: el logo manda, el texto se reduce */
    .encabezado .contenedor { min-height: 74px; gap: 12px; }
    .marca img { height: 54px; width: 54px; }
    .marca-texto strong { font-size: .95rem; white-space: normal; line-height: 1.12; }
    .marca-texto span { font-size: .5rem; letter-spacing: .1em; }

    /* Barra superior: solo lo esencial */
    .cinta .contenedor { justify-content: center; min-height: 0; padding-block: 7px; }
    .cinta-enlaces { gap: 4px 12px; justify-content: center; }
    .cinta-enlaces a { font-size: .62rem; }

    /* Franja de inscripciones: apilada y con botón ancho */
    .franja-aviso .contenedor { padding-block: 14px; }
    .franja-aviso p { font-size: .86rem; line-height: 1.35; }
    .franja-btn { width: 100%; text-align: center; padding: 13px 18px; font-size: .92rem; }

    /* Portada: texto legible y botones a lo ancho */
    .diapositiva-texto { padding-block: 30px; }
    .diapositiva-texto p { font-size: 1rem; }
    .diapositiva-acciones { gap: 10px; width: 100%; }
    .diapositiva-acciones .btn { width: 100%; justify-content: center; padding: 15px 22px; }
    .portada-controles { bottom: 16px; }

    /* Cifras: una debajo de otra, sin apretujar */
    .cifras .contenedor { gap: 14px; padding-block: 22px; }
    .cifra strong { font-size: 1.8rem; }

    /* Secciones más cortas para no hacer scroll eterno */
    .seccion { padding-block: 48px; }
    .cabecera-seccion { margin-bottom: 28px; }

    /* Tarjetas a una columna y con toque cómodo */
    .rejilla { gap: 18px; }
    .nivel-cuerpo { padding: 18px 18px 22px; }
    .nivel-enlace { padding-top: 14px; }
    .dependencia { min-height: 250px; }
    .dependencia-cuerpo { padding: 22px 20px; }

    /* Botones: altura mínima cómoda para el dedo */
    .btn { min-height: 48px; padding: 14px 24px; }

    /* Modal a pantalla casi completa */
    .modal { padding: 0; align-items: flex-end; }
    .modal-caja { max-height: 92vh; border-radius: 22px 22px 0 0; width: 100%; }
    .modal-foto { aspect-ratio: 16 / 9; }
    .modal-cuerpo { padding: 22px 20px 28px; }
    .modal-pie { flex-direction: column; align-items: stretch; }
    .modal-pie .btn { width: 100%; justify-content: center; }

    /* Cartelera: dos columnas legibles */
    .muro { grid-template-columns: repeat(2, 1fr); gap: 12px; }
    .clip-cuerpo strong { font-size: .88rem; }
    .visor { padding: 12px; }

    /* Formularios cómodos: evita el zoom automático de iOS */
    .campo input, .campo textarea, .campo select { font-size: 16px; padding: 14px; }

    /* Pie: una columna, con aire */
    .pie { padding-block: 42px 0; }
    .pie-rejilla { grid-template-columns: 1fr; gap: 28px; }
    .pie-abajo { margin-top: 30px; flex-direction: column; gap: 8px; }

    /* Artículos y páginas internas */
    .cabecera-pagina { padding-block: 38px; }
    .articulo-cuerpo { font-size: 1rem; }
    .bloque-clei { padding: 24px 20px; }

    /* WhatsApp: que no tape el contenido */
    .whatsapp { width: 52px; height: 52px; right: 14px; bottom: 14px; }
    .whatsapp svg { width: 25px; height: 25px; }
}

@media (max-width: 420px) {
    .muro { grid-template-columns: 1fr; }
    .marca-texto strong { font-size: .85rem; }
    .cinta-enlaces a { font-size: .58rem; }
}

/* Evita el desplazamiento horizontal en cualquier pantalla */
html, body { overflow-x: hidden; max-width: 100%; }

/* Con el menú móvil abierto, el fondo no se mueve */
body.menu-abierto { overflow: hidden; }
img, video, iframe { max-width: 100%; }

/* --- Barra de progreso de lectura (superior) -------------------------- */
.progreso-lectura {
    position: fixed;
    top: 0; left: 0;
    height: 3px;
    width: 0;
    background: linear-gradient(90deg, var(--verde), var(--sol));
    z-index: 100;
    transition: width .1s linear;
}

/* --- Botón volver arriba --------------------------------------------- */
.subir {
    position: fixed;
    right: 18px;
    bottom: 84px;
    z-index: 89;
    width: 46px; height: 46px;
    border-radius: 50%;
    border: 1px solid var(--linea);
    background: rgba(255, 255, 255, .92);
    backdrop-filter: blur(10px);
    color: var(--tinta);
    display: grid;
    place-items: center;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: opacity .25s ease, transform .25s ease, visibility .25s;
    box-shadow: 0 8px 22px -12px rgba(8, 30, 51, .5);
}
.subir.visible { opacity: 1; visibility: visible; transform: translateY(0); }
.subir:hover { background: var(--tinta); color: #fff; border-color: var(--tinta); }
.subir svg { width: 20px; height: 20px; }
@media (max-width: 720px) { .subir { width: 44px; height: 44px; right: 14px; bottom: 76px; } }

/* ==========================================================================
   REFINAMIENTO INSTITUCIONAL — ritmo, jerarquía y detalle
   ========================================================================== */

/* Línea de acento bajo el título de cada sección: marca jerarquía sin ruido */
.cabecera-seccion h2 { position: relative; padding-bottom: 18px; }
.cabecera-seccion h2::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: 0;
    width: 56px;
    height: 3px;
    border-radius: 2px;
    background: linear-gradient(90deg, var(--verde), var(--sol));
}
.cabecera-seccion--centro h2::after { left: 50%; transform: translateX(-50%); }
.seccion--tinta .cabecera-seccion h2::after { background: linear-gradient(90deg, var(--sol), var(--sol-claro)); }

/* La glosa se lee como una etiqueta de archivo institucional */
.glosa { letter-spacing: .2em; font-weight: 500; }

/* Separación fina entre secciones contiguas del mismo tono */
.seccion + .seccion:not(.seccion--espuma):not(.seccion--tinta) {
    border-top: 1px solid var(--linea);
}

/* Enlaces de tarjeta: la flecha se separa al pasar el cursor */
.nivel-enlace { letter-spacing: -.01em; }

/* Listas con viñeta cuadrada dorada, alineadas con precisión */
.lista-marcada li { line-height: 1.6; }
.lista-marcada li::before { margin-top: 9px; }

/* Citas y párrafos destacados dentro de artículos */
.articulo-cuerpo blockquote {
    font-family: var(--display);
    font-style: italic;
    font-weight: 500;
    color: var(--tinta);
}

/* Tarjetas de datos: encabezado con más presencia */
.tarjeta-datos h3 { padding-bottom: 14px; border-bottom: 1px solid var(--linea); margin-bottom: 18px; }
.tarjeta-datos--oscura h3 { border-bottom-color: rgba(255, 255, 255, .18); }
.datos-lista li { padding-bottom: 14px; border-bottom: 1px solid var(--linea); }
.datos-lista li:last-child { padding-bottom: 0; border-bottom: 0; }
.tarjeta-datos--oscura .datos-lista li { border-bottom-color: rgba(255, 255, 255, .14); }

/* Pie: jerarquía más clara entre columnas */
.pie-lista li { padding-bottom: 2px; }
.pie h4 { padding-bottom: 12px; border-bottom: 1px solid rgba(255, 255, 255, .14); }

/* En móvil la línea de acento se mantiene proporcionada */
@media (max-width: 720px) {
    .cabecera-seccion h2 { padding-bottom: 14px; }
    .cabecera-seccion h2::after { width: 44px; height: 3px; }
    .datos-lista li { padding-bottom: 12px; }
}
