/*
 * OSPI — rediseño 2026 (v2)
 * Paleta tomada de la propuesta en Figma.
 */

@font-face {
    font-family: 'Noto Sans';
    src: url('../../fonts/noto-sans/NotoSans-latin-var.woff2') format('woff2');
    font-weight: 400 800;
    font-style: normal;
    font-display: swap;
}

:root {
    --ospi-azul: #03254a;
    --ospi-azul-fondo: #022649;
    --ospi-azul-pie: #012447;
    --ospi-burdeos: #6e112d;
    --ospi-burdeos-hover: #570d23;
    --ospi-dorado: #d5961c;
    --ospi-beige: #f5e6d4;
    --ospi-borde: #e4e4e4;
    --ospi-radio: 18px;
    --ospi-sombra: 0 4px 6px rgba(0, 0, 0, .18);
    --ospi-alto-header: 120px;

    --bs-body-font-family: 'Noto Sans', system-ui, -apple-system, 'Segoe UI', Roboto, Arial, sans-serif;
    --bs-body-color: var(--ospi-azul);
}

body {
    background: #fff;
    color: var(--ospi-azul);
}

a {
    color: inherit;
}

section[id] {
    scroll-margin-top: calc(var(--ospi-alto-header) + 1rem);
}

.text-burdeos {
    color: var(--ospi-burdeos);
}

/* ---------- Botón principal ---------- */

.ospi-btn {
    display: inline-flex;
    align-items: center;
    gap: .9rem;
    padding: .85rem 1.75rem;
    border-radius: 14px;
    background: var(--ospi-burdeos);
    color: #fff;
    font-size: clamp(1.05rem, 1.4vw, 1.3rem);
    font-weight: 500;
    text-decoration: none;
    transition: background-color .2s;
}

.ospi-btn:hover,
.ospi-btn:focus-visible {
    background: var(--ospi-burdeos-hover);
    color: #fff;
}

/* ---------- Encabezado ---------- */

.ospi-header {
    background: var(--ospi-azul-fondo);
}

.ospi-header .navbar {
    min-height: var(--ospi-alto-header);
    padding: .5rem 0;
}

.ospi-marca {
    display: flex;
    align-items: center;
    gap: .75rem;
    margin-right: 1rem;
    color: #fff;
}

.ospi-marca-insp {
    display: flex;
    align-items: center;
    gap: .5rem;
    color: #fff;
    font-size: clamp(.95rem, 1.4vw, 1.3rem);
    line-height: 1.35;
    text-align: center;
}

.ospi-marca-insp img {
    width: auto;
    height: clamp(46px, 5vw, 70px);
}

@media (max-width: 575.98px) {
    .ospi-header .ospi-marca-insp > span {
        display: none;
    }
}

.ospi-marca-ospi {
    display: flex;
    flex-direction: column;
    padding-left: .6rem;
    border-left: 2px solid var(--ospi-dorado);
    line-height: 1.15;
}

.ospi-marca-ospi strong {
    font-family: Arial, Helvetica, sans-serif;
    font-size: clamp(1.9rem, 2.7vw, 2.5rem);
    font-weight: 700;
    letter-spacing: .02em;
    line-height: 1;
}

.ospi-marca-ospi small {
    margin-top: .3rem;
    font-size: .66rem;
}

.ospi-header .navbar-toggler {
    border: 0;
    color: #fff;
    font-size: 1.6rem;
}

.ospi-header .navbar-nav .nav-link {
    position: relative;
    padding: .5rem 0;
    color: #fff;
    font-size: clamp(1rem, 1.45vw, 1.375rem);
    line-height: 1.4;
    text-align: center;
    white-space: nowrap;
}

.ospi-header .navbar-nav .nav-link:hover,
.ospi-header .navbar-nav .nav-link:focus-visible,
.ospi-header .navbar-nav .nav-link.active {
    color: var(--ospi-dorado);
}

.ospi-header .navbar-nav .nav-link.active::after {
    content: '';
    position: absolute;
    left: 50%;
    bottom: .1rem;
    width: 2.25rem;
    height: 3px;
    border-radius: 2px;
    background: var(--ospi-dorado);
    transform: translateX(-50%);
}

.ospi-buscar {
    padding: .25rem .5rem;
    border: 0;
    background: none;
    color: #fff;
    font-size: 1.7rem;
}

.ospi-buscar:hover {
    color: var(--ospi-dorado);
}

@media (min-width: 1200px) {
    .ospi-header .navbar-nav {
        gap: clamp(1rem, 2vw, 2rem);
    }

    .ospi-buscar {
        margin-left: clamp(1rem, 2vw, 2rem);
    }
}

@media (max-width: 1199.98px) {
    :root {
        --ospi-alto-header: 88px;
    }

    .ospi-header .navbar-collapse {
        padding: .5rem 0 1rem;
    }

    .ospi-header .navbar-nav .nav-link {
        text-align: left;
        border-bottom: 1px solid rgba(255, 255, 255, .12);
    }

    .ospi-header .navbar-nav .nav-link.active::after {
        left: 0;
        transform: none;
    }

    .ospi-buscar {
        margin-top: .5rem;
        padding-left: 0;
    }
}

/* ---------- Títulos de sección ---------- */

.ospi-titulo-seccion {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: clamp(1rem, 3vw, 2.75rem);
    margin: 0;
    font-size: clamp(1.75rem, 2.7vw, 2.4rem);
    font-weight: 700;
    text-align: center;
}

/* Las líneas solo ocupan el espacio que deja el texto */
.ospi-titulo-seccion::before,
.ospi-titulo-seccion::after {
    content: '';
    flex: 1 1 0;
    max-width: 340px;
    height: 3px;
    background: var(--ospi-dorado);
}

.ospi-subtitulo {
    margin: .75rem 0 0;
    font-size: clamp(1rem, 1.4vw, 1.25rem);
    font-weight: 600;
    text-align: center;
}

/* ---------- Hero ---------- */

.ospi-hero {
    position: relative;
    background: #fff;
}

.ospi-hero-texto {
    padding: clamp(2.5rem, 4.5vw, 4rem) 0 2.5rem;
}

.ospi-hero h1 {
    margin-bottom: clamp(1.5rem, 4vw, 3.5rem);
    font-size: clamp(2rem, 3.6vw, 3.25rem);
    font-weight: 700;
    line-height: 1.22;
}

.ospi-hero-bajada {
    max-width: 640px;
    margin: 0 0 clamp(1.5rem, 3.5vw, 3.75rem) .5rem;
    font-size: clamp(1.1rem, 1.65vw, 1.5rem);
    font-weight: 600;
    line-height: 1.5;
}

.ospi-hero .ospi-btn i {
    transform: rotate(-45deg);
}

.ospi-hero-ilustracion {
    display: block;
    width: 100%;
    height: auto;
}

@media (min-width: 992px) {
    .ospi-hero {
        min-height: clamp(470px, 45.8vw, 760px);
        background: #fff url('../img/home/hero.jpg') no-repeat right bottom / cover;
    }

    .ospi-hero-texto {
        max-width: 68%;
    }

    .ospi-hero h1 span {
        display: block;
    }

    .ospi-hero-ilustracion {
        display: none;
    }
}

/* ---------- Explora el OSPI ---------- */

.ospi-explora {
    padding: clamp(2.5rem, 4vw, 3.5rem) 0 clamp(2.5rem, 3vw, 2.5rem);
}

.ospi-tarjeta {
    position: relative;
    display: flex;
    flex-direction: column;
    height: 100%;
    overflow: hidden;
    border: 1px solid var(--ospi-borde);
    border-radius: 8px;
    background: #fff;
    box-shadow: var(--ospi-sombra);
    transition: transform .2s, box-shadow .2s;
}

.ospi-tarjeta:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 18px rgba(0, 0, 0, .16);
}

.ospi-tarjeta img {
    width: 100%;
    aspect-ratio: 242 / 190;
    object-fit: cover;
}

.ospi-tarjeta-cuerpo {
    display: flex;
    flex: 1;
    flex-direction: column;
    padding: .75rem 1.1rem 1rem;
}

.ospi-tarjeta h3 {
    margin-bottom: .9rem;
    font-size: 1.25rem;
    font-weight: 700;
}

.ospi-tarjeta h3 a {
    text-decoration: none;
}

.ospi-tarjeta p {
    margin-bottom: 0;
    font-weight: 500;
    line-height: 1.3;
}

.ospi-flecha {
    color: var(--ospi-dorado);
    font-size: 1.6rem;
}

.ospi-tarjeta .ospi-flecha {
    align-self: flex-end;
    margin-top: auto;
    padding-top: .25rem;
}

/* ---------- ¿Qué es el OSPI? ---------- */

.ospi-que-es {
    margin-bottom: 1.5rem;
    border-radius: var(--ospi-radio);
    background: #03274a;
    color: #fff;
}

.ospi-que-es-texto {
    padding: clamp(2rem, 4vw, 3.25rem) clamp(1.5rem, 3vw, 2.25rem) 2rem;
}

.ospi-que-es h2 {
    display: inline-block;
    margin: 0 0 clamp(1.5rem, 3vw, 2.75rem) clamp(0rem, 1vw, 1rem);
    padding-bottom: 1rem;
    font-size: clamp(2.25rem, 4.4vw, 4rem);
    font-weight: 700;
    line-height: 1.1;
    background: linear-gradient(var(--ospi-dorado), var(--ospi-dorado)) no-repeat left bottom / 150px 4px;
}

.ospi-que-es p {
    margin-bottom: clamp(1.5rem, 3vw, 3rem);
    font-size: clamp(1.1rem, 1.65vw, 1.5rem);
    line-height: 1.55;
}

/* Las raíces se salen de la caja: el PNG es más alto que la caja */
.ospi-que-es-img {
    display: block;
    width: 100%;
    height: auto;
    margin-bottom: -6.8%;
    border-top-right-radius: var(--ospi-radio);
}

@media (max-width: 991.98px) {
    .ospi-que-es-img {
        border-top-right-radius: 0;
    }
}

/* ---------- Contenido destacado ---------- */

.ospi-destacados {
    padding: 1.5rem 0 clamp(2rem, 3vw, 2.25rem);
}

.ospi-destacado {
    position: relative;
    display: grid;
    grid-template-columns: 46% 1fr;
    grid-template-areas:
        "imagen titulo"
        "imagen texto"
        "enlace enlace";
    align-items: center;
    column-gap: 1rem;
    height: 100%;
    min-height: 250px;
    padding: 1.6rem 1.4rem 1.25rem;
    border-radius: var(--ospi-radio);
    box-shadow: var(--ospi-sombra);
}

.ospi-destacado-imagen {
    grid-area: imagen;
    justify-self: center;
    max-width: 100%;
}

.ospi-destacado h3 {
    grid-area: titulo;
    align-self: start;
    margin-bottom: .8rem;
    font-size: 1.3rem;
    font-weight: 700;
}

.ospi-destacado p {
    grid-area: texto;
    align-self: start;
    margin-bottom: 0;
    line-height: 1.65;
}

.ospi-destacado-enlace {
    grid-area: enlace;
    justify-self: end;
    display: inline-flex;
    align-items: center;
    gap: 1.5rem;
    margin-top: .5rem;
    font-size: .9rem;
    font-weight: 600;
    text-decoration: none;
}

.ospi-destacado-enlace::after {
    content: '';
    position: absolute;
    inset: 0;
}

.ospi-destacado.azul {
    grid-template-areas:
        "titulo titulo"
        "imagen texto"
        "enlace enlace";
    background: var(--ospi-azul);
    color: #fff;
}

.ospi-destacado.azul h3 {
    justify-self: end;
}

.ospi-destacado.claro {
    border: 1px solid var(--ospi-borde);
    background: #fdfdfd;
}

.ospi-destacado.claro h3 {
    color: var(--ospi-burdeos);
}

.ospi-destacado.burdeos {
    background: var(--ospi-burdeos);
    color: #fff;
}

.ospi-destacado.burdeos .ospi-flecha {
    color: #fff;
}

.ospi-destacado.burdeos .ospi-destacado-imagen {
    font-size: 7.5rem;
    line-height: 1;
}

/* ---------- Pie ---------- */

.ospi-footer {
    padding: 3rem 0 1rem;
    background: var(--ospi-azul-pie);
    color: #fff;
}

.ospi-footer a {
    color: #fff;
}

.ospi-footer h3 {
    margin-bottom: .2rem;
    color: var(--ospi-dorado);
    font-size: 1.3rem;
    font-weight: 700;
}

.ospi-footer .ospi-marca-insp {
    font-size: 1.3rem;
}

.ospi-footer .ospi-marca-insp img {
    height: 84px;
}

.ospi-redes {
    display: flex;
    gap: 1.25rem;
    margin-top: 2rem;
}

.ospi-redes a {
    display: grid;
    place-items: center;
    width: 66px;
    height: 66px;
    border: 3px solid #fff;
    border-radius: 50%;
    font-size: 1.9rem;
    text-decoration: none;
    transition: background-color .2s, color .2s;
}

.ospi-redes a:hover,
.ospi-redes a:focus-visible {
    background: #fff;
    color: var(--ospi-azul-pie);
}

.ospi-footer-col ul {
    margin: 0;
    padding: 0;
    list-style: none;
}

.ospi-footer-col li,
.ospi-footer-col p {
    margin-bottom: .1rem;
    font-size: .875rem;
    font-weight: 600;
}

.ospi-footer-col a {
    text-decoration: none;
}

.ospi-footer-col a:hover {
    color: var(--ospi-dorado);
}

.ospi-footer-col p i {
    width: 1.5rem;
    font-size: 1.1rem;
}

.ospi-footer-direccion {
    display: flex;
    margin-top: .75rem;
}

.ospi-footer-direccion a {
    text-align: center;
    text-decoration: underline;
}

.ospi-footer-ospi strong {
    display: block;
    font-family: Arial, Helvetica, sans-serif;
    font-size: clamp(3.5rem, 6vw, 5rem);
    font-weight: 700;
    line-height: 1;
}

.ospi-footer-ospi span {
    display: block;
    margin-top: 1.5rem;
    font-size: 1.2rem;
    line-height: 1.35;
}

.ospi-footer-ospi .ospi-redes {
    margin-top: 1.5rem;
    padding-left: 2.75rem;
}

.ospi-footer-legal {
    margin-top: 2rem;
    font-size: .875rem;
    text-align: center;
}

.ospi-footer-legal > a {
    display: inline-block;
    margin-bottom: .4rem;
    margin-right: 10rem;
    font-weight: 600;
    text-decoration: none;
}

.ospi-footer-legal p {
    margin: 0;
}

@media (min-width: 1200px) {
    .ospi-footer-separador {
        padding-left: 1.25rem;
        border-left: 2px solid rgba(255, 255, 255, .9);
    }

    .ospi-footer-col {
        min-height: 220px;
        padding-top: 2.5rem;
    }

    .ospi-footer-direccion a {
        display: block;
        max-width: 200px;
    }
}

@media (max-width: 1199.98px) {
    .ospi-footer-ospi .ospi-redes {
        padding-left: 0;
    }

    .ospi-footer-legal > a {
        margin-right: 0;
    }
}

@media (max-width: 575.98px) {
    .ospi-redes {
        gap: 1rem;
    }

    .ospi-redes a {
        width: 54px;
        height: 54px;
        font-size: 1.5rem;
    }
}
