@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&family=Plus+Jakarta+Sans:wght@600;700;800&display=swap');

:root {
    --red: #c91824;
    --red2: #a90f19;
    --ink: #172033;
    --muted: #667085;
    --line: #e5e9ef;
    --soft: #f7f8fa;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    color: var(--ink);
    font-family: Inter, system-ui, sans-serif;
    background: #fff;
}

a {
    color: inherit;
}

.wrap {
    width: min(1120px, calc(100% - 30px));
    margin: auto;
}


/* =========================
   NAVEGACIÓN
   ========================= */

.nav {
    height: 60px;
    border-bottom: 1px solid var(--line);
    background: #fff;
    position: sticky;
    top: 0;
    z-index: 20;
}

.navin {
    height: 100%;
    display: flex;
    align-items: center;
}

.logo {
    height: 36px;
    width: auto;
}

.links {
    margin-left: auto;
    display: flex;
    align-items: center;
    gap: 20px;
}

    .links a {
        font-size: .75rem;
        font-weight: 800;
        text-decoration: none;
        color: #475467;
    }

        .links a:hover,
        .links .active {
            color: var(--red);
        }

.adminbtn,
.btn.red {
    background: var(--red);
    color: #fff !important;
    border-radius: 8px;
    padding: 8px 12px;
}


/* =========================
   HERO
   ========================= */

.hero {
    padding: 16px 0 28px;
}

.heroCard {
    min-height: 340px;
    border-radius: 17px;
    overflow: hidden;
    background: #2c3747 center/cover no-repeat;
    position: relative;
}

    .heroCard:after {
        content: "";
        position: absolute;
        inset: 0;
        background: linear-gradient( 90deg, rgba(15, 23, 36, .86), rgba(15, 23, 36, .25) );
    }

.heroCopy {
    position: relative;
    z-index: 1;
    max-width: 650px;
    padding: 55px;
}

.eyebrow,
.kicker {
    font-size: .63rem;
    letter-spacing: .1em;
    text-transform: uppercase;
    font-weight: 800;
    color: var(--red);
}

.hero .eyebrow {
    color: #ffd0d3;
}

.hero h1 {
    font: 800 clamp(2rem, 4vw, 3rem) / 1.05 'Plus Jakarta Sans';
    color: #fff;
    margin: 10px 0;
}

.hero p {
    font-size: .82rem;
    line-height: 1.7;
    color: #eef1f4;
}


/* =========================
   BOTONES
   ========================= */

.btn {
    display: inline-flex;
    text-decoration: none;
    font-size: .71rem;
    font-weight: 800;
    padding: 8px 11px;
    border-radius: 8px;
}

.actions {
    display: flex;
    gap: 8px;
    margin-top: 16px;
}

.btn.white {
    background: #fff;
    color: var(--ink);
}


/* =========================
   SECCIONES
   ========================= */

.section {
    padding: 28px 0;
}

.head {
    display: flex;
    justify-content: space-between;
    align-items: end;
    margin-bottom: 13px;
}

    .head h2 {
        font: 800 1.35rem 'Plus Jakarta Sans';
        margin: 0;
    }

    .head p {
        font-size: .75rem;
        color: var(--muted);
        margin: 4px 0 0;
    }


/* =========================
   ESTADÍSTICAS
   ========================= */

.stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    background: var(--red);
    border-radius: 12px;
    overflow: hidden;
}

.stat {
    padding: 15px;
    text-align: center;
    color: #fff;
    border-right: 1px solid #ffffff2b;
}

    .stat:last-child {
        border: 0;
    }

    .stat b {
        font: 800 1.35rem 'Plus Jakarta Sans';
        display: block;
    }

    .stat span {
        font-size: .61rem;
        font-weight: 800;
        letter-spacing: .06em;
    }

    .stat small {
        display: block;
        font-size: .6rem;
        opacity: .82;
        margin-top: 3px;
    }


/* =========================
   TARJETAS DE ACTUALIDAD
   ========================= */

.cards {
    width: min(900px, 100%);
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
    align-items: start;
}

.card {
    border: 1px solid var(--line);
    border-radius: 10px;
    overflow: hidden;
    background: #fff;
}


/*
   Imagen pequeña de la publicación.
   Se mantiene el tamaño de la tarjeta,
   pero la imagen completa se adapta sin recortarse.
*/

.cover {
    height: 78px;
    background: #eef1f4;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
}

    .cover img {
        width: 100%;
        height: 100%;
        object-fit: contain;
        background: #eef1f4;
    }

.cardbody {
    padding: 10px;
}

.meta {
    font-size: .56rem;
    color: var(--red);
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: .06em;
    line-height: 1.35;
}

.card h3 {
    font-size: .78rem;
    line-height: 1.25;
    margin: 4px 0;
}

.card p {
    font-size: .65rem;
    line-height: 1.4;
    color: var(--muted);
    margin: 0 0 8px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.card .btn {
    font-size: .62rem;
    padding: 6px 8px;
    border-radius: 7px;
}


/* =========================
   CENTRO DE DOCUMENTOS
   ========================= */

.documentCenter {
    margin: 0 auto 34px;
    width: min(1200px, 100%);
}

.documentPreview {
    border: 1px solid var(--line);
    border-radius: 12px;
    background: #fff;
    overflow: hidden;
    box-shadow: 0 4px 16px rgba(16, 24, 40, .06);
}

.documentPreviewTop {
    min-height: 70px;
    padding: 12px 15px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    border-bottom: 1px solid var(--line);
}

    .documentPreviewTop h2 {
        font: 800 .95rem 'Plus Jakarta Sans';
        margin: 2px 0;
    }

    .documentPreviewTop p {
        font-size: .62rem;
        color: var(--muted);
        margin: 3px 0 0;
    }

.documentFrame {
    height: 700px;
    background: #202124;
    position: relative;
}

    .documentFrame iframe {
        display: block;
        width: 100%;
        height: 100%;
        border: 0;
        background: #fff;
    }

        .documentFrame iframe.imagePreview {
            object-fit: contain;
        }

    .documentFrame img {
        display: block;
        width: 100%;
        height: 100%;
        object-fit: contain;
        background: #202124;
    }

.documentsIntro {
    margin: 26px 0 13px;
}

.documentPreviewEmpty {
    height: 100%;
    display: grid;
    place-items: center;
    padding: 20px;
    text-align: center;
    color: #cbd0d8;
    font-size: .72rem;
}

.documentPreviewHtml {
    height: 100%;
    overflow: auto;
    background: #fff;
    padding: 22px 26px;
    font-size: .75rem;
    line-height: 1.7;
    color: #344054;
}

    .documentPreviewHtml table {
        border-collapse: collapse;
        font-size: .68rem;
        width: auto;
    }

        .documentPreviewHtml table td,
        .documentPreviewHtml table th {
            border: 1px solid var(--line);
            padding: 4px 7px;
        }

    .documentPreviewHtml img {
        max-width: 100%;
    }


/* =========================
   BOTONES DE DOCUMENTOS
   ========================= */

.documentButtons {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 10px;
    margin-top: 12px;
}

.documentButton {
    min-width: 0;
    border: 1px solid var(--line);
    background: var(--red);
    color: #fff;
    min-height: 52px;
    padding: 8px 10px;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    cursor: pointer;
    font: 800 .62rem Inter;
    transition: .15s ease;
}

    .documentButton:hover,
    .documentButton.selected {
        transform: translateY(-1px);
        background: var(--red2);
        box-shadow: 0 4px 10px rgba(16, 24, 40, .12);
    }

.documentIcon {
    font-size: .48rem;
    border-radius: 3px;
    background: #fff;
    color: var(--red);
    padding: 5px 4px;
    flex: none;
}

.documentButtonText {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}


/* =========================
   BLOG
   ========================= */

.blogPosts {
    padding-bottom: 45px;
}

.sectionIntro {
    text-align: center;
    margin: 0 0 13px;
}

    .sectionIntro h2 {
        font: 800 1.35rem 'Plus Jakarta Sans';
        margin: 0 0 4px;
    }

    .sectionIntro p {
        font-size: .75rem;
        color: var(--muted);
        margin: 0;
    }


/* =========================
   EMPRESA
   ========================= */

.company {
    background: var(--soft);
    border-block: 1px solid var(--line);
}

.twocol {
    display: grid;
    grid-template-columns: .9fr 1.1fr;
    gap: 24px;
    align-items: center;
}

.featureimg {
    height: 220px;
    border-radius: 14px;
    overflow: hidden;
    background: #e9edf1;
}

    .featureimg img {
        width: 100%;
        height: 100%;
        object-fit: cover;
    }

.feature h2 {
    font: 800 1.45rem 'Plus Jakarta Sans';
    margin: 5px 0 8px;
}

.rich {
    font-size: .78rem;
    line-height: 1.75;
    color: var(--muted);
}


/* =========================
   FOOTER
   ========================= */

.footer {
    background: #171b24;
    color: #d7dde5;
    padding: 22px 0;
}

.footerin {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.footer img {
    height: 32px;
}

.footer a {
    font-size: .69rem;
    text-decoration: none;
    margin-left: 12px;
}


/* =========================
   TÍTULO DE PÁGINA
   ========================= */

.pageTitle {
    padding: 28px 0 22px;
    text-align: center;
}

    .pageTitle h1 {
        font: 800 1.9rem 'Plus Jakarta Sans';
        margin: 0 0 5px;
    }

    .pageTitle p {
        font-size: .78rem;
        color: var(--muted);
        margin: 0;
    }


/* =========================
   DETALLE DE LA PUBLICACIÓN
   ========================= */

.detail {
    max-width: 780px;
    margin: 0 auto;
    padding: 8px 0 50px;
}

.detailHead {
    text-align: center;
    margin: 10px 0 17px;
}

.detail h1 {
    font: 800 1.75rem 'Plus Jakarta Sans';
    margin: 5px 0;
}

.detail .summary {
    font-size: .78rem;
    color: var(--muted);
    line-height: 1.6;
}


/*
   IMAGEN PRINCIPAL DE LA PUBLICACIÓN

   El contenedor ya NO tiene una altura fija.
   La imagen determina la altura automáticamente
   según sus proporciones.
*/

.detailCover {
    width: 100%;
    border-radius: 13px;
    overflow: hidden;
    background: #eef1f4;
    display: flex;
    justify-content: center;
    align-items: center;
}

    .detailCover img {
        display: block;
        width: 100%;
        height: auto;
        max-width: 100%;
        object-fit: contain;
    }


/* =========================
   CONTENIDO DE PUBLICACIÓN
   ========================= */

.content {
    font-size: .8rem;
    line-height: 1.8;
    color: #475467;
    white-space: pre-wrap;
    margin-top: 18px;
}


/* =========================
   DOCUMENTOS DE LA PUBLICACIÓN
   ========================= */

.docs {
    border-top: 1px solid var(--line);
    margin-top: 20px;
    padding-top: 14px;
}

    .docs h3 {
        font-size: .9rem;
    }

.doc {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border: 1px solid var(--line);
    padding: 9px 10px;
    border-radius: 8px;
    margin: 7px 0;
    background: #fafbfc;
}

    .doc strong {
        font-size: .69rem;
    }

    .doc a {
        font-size: .66rem;
        font-weight: 800;
        color: var(--red);
        text-decoration: none;
    }

.back {
    color: var(--red);
    font-size: .7rem;
    font-weight: 800;
    text-decoration: none;
}


/* =========================
   HERO DE EMPRESA
   ========================= */

.companyHero {
    padding: 16px 0 25px;
}

.companyCard {
    height: 275px;
    border-radius: 17px;
    overflow: hidden;
    background: #2c3747 center/cover no-repeat;
    position: relative;
}

    .companyCard:after {
        content: "";
        position: absolute;
        inset: 0;
        background: linear-gradient( 90deg, rgba(15, 23, 36, .86), rgba(15, 23, 36, .25) );
    }

.companyCopy {
    position: relative;
    z-index: 1;
    padding: 45px;
    max-width: 650px;
    color: #fff;
}

    .companyCopy h1 {
        font: 800 2rem 'Plus Jakarta Sans';
        margin: 8px 0;
    }


/* =========================
   INTRODUCCIÓN
   ========================= */

.centerIntro {
    text-align: center;
    padding: 28px 0;
}

    .centerIntro h2,
    .sectionTitle {
        font: 800 1.45rem 'Plus Jakarta Sans';
        margin: 5px 0 8px;
    }


/* =========================
   BLOQUES
   ========================= */

.block {
    padding: 28px 0;
    background: var(--soft);
    border-block: 1px solid var(--line);
}

.reverse .featureimg {
    order: 2;
}


/* =========================
   MISIÓN / VISIÓN / VALORES
   ========================= */

.mvv {
    padding: 28px 0;
    background: #fafbfc;
}

.mvvgrid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 11px;
}

.mvvcard {
    border: 1px solid var(--line);
    border-radius: 12px;
    padding: 15px;
    background: #fff;
}

    .mvvcard h3 {
        font-size: .9rem;
        margin: 0 0 6px;
    }

.pill {
    display: inline-block;
    padding: 6px 9px;
    border: 1px solid var(--line);
    border-radius: 999px;
    font-size: .64rem;
    font-weight: 800;
    margin: 4px 4px 0 0;
}


/* =========================
   LÍNEA DE TIEMPO
   ========================= */

.timeline {
    border-left: 2px solid #f1c9cc;
    padding-left: 15px;
}

    .timeline p {
        font-size: .72rem;
        color: var(--muted);
    }


/* =========================
   RESPONSIVE
   ========================= */

@media (max-width: 980px) {

    .cards {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .documentButtons {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}


@media (max-width: 760px) {

    .documentFrame {
        height: 300px;
    }

    .documentButtons {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .links a:not(.adminbtn) {
        display: none;
    }

    .heroCopy,
    .companyCopy {
        padding: 38px 27px;
    }

    .stats {
        grid-template-columns: 1fr 1fr;
    }

    .stat {
        border-bottom: 1px solid #ffffff2b;
    }

    .cards,
    .twocol,
    .mvvgrid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .reverse .featureimg {
        order: 0;
    }

    .footerin {
        flex-direction: column;
        gap: 10px;
    }
}


@media (max-width: 520px) {

    .cards {
        grid-template-columns: 1fr;
    }
}
