/* ======================================================
   NAVBAR (IDÉNTICA A TU INCIDENCIAS)
====================================================== */

#mainNav .nav-link {
    position: relative;
    color: #fff !important;
    opacity: 0.55;
    transition: all 0.25s ease;
    transform: translateY(0);
}

/* ACTIVO (FIJO, SIN EFECTOS DE HOVER) */
#mainNav .nav-link.active {
    opacity: 1;
    transform: none;
}

/* HOVER SOLO EN NO ACTIVOS */
#mainNav .nav-link:not(.active):hover {
    opacity: 1;
    transform: translateY(-2px);
}

/* SUBRAYADO BASE */
#mainNav .nav-link::after {
    content: "";
    position: absolute;
    left: 50%;
    bottom: 4px;
    width: 0%;
    height: 2px;
    background: #1cc88a;
    transition: all 0.3s ease;
    transform: translateX(-50%);
    border-radius: 2px;
}

/* SUBRAYADO ACTIVO FIJO */
#mainNav .nav-link.active::after {
    width: 60%;
    opacity: 1;
}

/* SUBRAYADO HOVER (SOLO NO ACTIVOS) */
#mainNav .nav-link:not(.active):hover::after {
    width: 40%;
    opacity: 0.6;
}

.brand-wrapper {
    display: flex;
    flex-direction: column;
    line-height: 1.1;
}

.brand-subtitle {
    font-size: 0.72rem;
    font-weight: 400;
    letter-spacing: 0.5px;
    color: rgba(255, 255, 255, 0.78);
    text-transform: none;
    margin-top: 2px;
}

@media (min-width: 992px) {

    #mainNav .navbar-nav > li.nav-item > a.nav-link.active {
        background: transparent !important;
    }

    #mainNav .navbar-brand {
        font-size: 1.75em;
        transition: font-size 0.3s;
    }
}

/* =========================
   NAV GENERAL
========================= */

#mainNav {
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 999;
    backdrop-filter: blur(12px);
    background: rgba(44, 62, 80, 0.65) !important;
    transition: all 0.3s ease;
    padding: 18px 0;
}

#mainNav.shrink {
    padding: 8px 0;
    background: rgba(44, 62, 80, 0.9) !important;
}

/* =========================
   DESKTOP EXTRAS
========================= */

@media (min-width: 992px) {

    #mainNav .navbar-brand {
        font-size: 1.75em;
        transition: font-size 0.3s;
    }
}

/* =========================
   MOBILE
========================= */

@media (max-width: 991.98px) {

    #mainNav .navbar-collapse {
        background: transparent;
        backdrop-filter: blur(10px);
        border-top: 1px solid rgba(255, 255, 255, 0.08);
        margin-top: 15px;
        margin-left: 10px;
        margin-right: 10px;
        border-radius: 5px;
    }

    #mainNav .nav-link {
        padding: 12px 16px;
        margin: 4px 10px;
        border-radius: 10px;
        opacity: 0.55;
        transform: none !important;
    }

    #mainNav .nav-link:hover {
        opacity: 1;
        background: rgba(255, 255, 255, 0.06);
        transform: none !important;
    }

    #mainNav .nav-link.active {
        opacity: 1;
        font-weight: 600;
        background: rgba(28, 200, 138, 0.18);
        border-left: 4px solid #1cc88a;
        border-right: 4px solid #1cc88a;
        color: #fff !important;
    }

    #mainNav .nav-link::after {
        display: none;
    }
}

/* ======================================================
   BACKGROUND
====================================================== */

html {
    background: #0f172a;
    overflow-x: hidden;
}

/* AURORA ANIMADA SUAVE */
body::before {
    content: "";
    position: fixed;
    inset: -20%;
    z-index: 0;
    pointer-events: none;

    background:
        radial-gradient(
            circle at 20% 20%,
            rgba(59, 130, 246, 0.35),
            transparent 45%
        ),

        radial-gradient(
            circle at 80% 30%,
            rgba(168, 85, 247, 0.30),
            transparent 50%
        ),

        radial-gradient(
            circle at 40% 80%,
            rgba(20, 184, 166, 0.25),
            transparent 55%
        ),

        radial-gradient(
            circle at 70% 70%,
            rgba(34, 211, 238, 0.20),
            transparent 60%
        );

    filter: blur(70px);
    animation: auroraMove 20s ease-in-out infinite alternate;
}

/* CAPA DE SUAVIZADO EXTRA */
body::after {
    content: "";
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    background: rgba(0, 0, 0, 0.10);
}

/* ANIMACIÓN LENTA Y ORGÁNICA */
@keyframes auroraMove {

    0% {
        transform: translate(-2%, -2%) scale(1);
    }

    50% {
        transform: translate(2%, 1%) scale(1.05);
    }

    100% {
        transform: translate(-1%, 2%) scale(1.02);
    }
}

body {
    margin: 0;
    min-height: 100vh;
}

/* ======================================================
   LAYOUT
====================================================== */

.page-wrapper {
    padding-top: 120px;
    padding-bottom: 60px;
    position: relative;
    z-index: 1;
}

.container {
    max-width: 900px;
    position: relative;
    z-index: 1;
}

/* ======================================================
   TÍTULO
====================================================== */

.titulo {
    text-align: center;
    color: #fff;
    font-weight: 600;
    margin-bottom: 25px;
}

/* =========================================
   LINK TÍTULO NOTICIA
========================================= */

.titulo-noticia-link {
    color: inherit;
    text-decoration: none;
    transition: all 0.25s ease;
    text-align: center;
}

.titulo-noticia-link:hover {
    color: #1cc88a;
}

.titulo-noticia-link:active {
    opacity: 0.8;
}

/* ======================================================
   CARD NOTICIA (VISIBLE Y LEGIBLE)
====================================================== */

.titulo {
    text-align: center;
    color: #fff;
    font-weight: 800;
    margin-bottom: 30px;
    letter-spacing: 0.5px;
    text-shadow: 0 6px 20px rgba(0, 0, 0, 0.25);
}

/* CARD MODERNA */
.noticia {
    background: rgba(255, 255, 255, 0.92);
    border-radius: 20px;
    padding: 22px;
    margin-bottom: 22px;

    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.18);

    border: 1px solid rgba(255, 255, 255, 0.4);

    opacity: 0;
    transform: translateY(25px) scale(0.98);
    transition: all 0.6s ease;

    position: relative;
    text-align: justify !important;
    z-index: 1;
}

.noticia.show {
    opacity: 1;
    transform: translateY(0) scale(1);
}

.noticia:hover {
    transform: translateY(-4px) scale(1.01);

    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.25);
}

.noticia h4 {
    margin: 0;
    color: #1f2d3d;
    font-weight: 700;
    text-align: justify;
}

.noticia small {
    color: #6c757d;
    display: block;
    margin-top: 4px;
}

.noticia p {
    color: #2b2b2b;
    margin-top: 10px;
    white-space: pre-line;
    line-height: 1.5;
}

/* =========================================
   VOLVER
========================================= */

.volver-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;

    color: rgba(255,255,255,0.9);
    text-decoration: none;
    font-weight: 600;

    transition: all 0.25s ease;
}

.volver-link:hover {
    color: #1cc88a;
    transform: translateX(-2px);
}

/* =========================
   IMÁGENES
========================= */

.galeria {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 14px;
    margin-top: 14px;
}

.galeria img {
    width: 100%;
    height: auto;
    object-fit: cover;
    border-radius: 14px;
    border: none;

    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.15);

    transition:
        transform 0.25s ease,
        filter 0.25s ease;
}

.galeria img:hover {
    transform: scale(1.04);
    filter: brightness(1.05);
}

/* =========================
   DOCUMENTOS
========================= */

.doc {
    display: inline-flex;
    align-items: center;
    gap: 8px;

    margin-top: 12px;
    margin-right: 10px;

    padding: 10px 14px;

    background: linear-gradient(
        135deg,
        #1cc88a,
        #17a673
    );

    color: white;

    border-radius: 12px;
    text-decoration: none;
    font-size: 13px;
    font-weight: 600;

    box-shadow: 0 8px 18px rgba(28, 200, 138, 0.25);

    transition: all 0.2s ease;
}

.doc:hover {
    transform: translateY(-2px);

    box-shadow: 0 12px 25px rgba(28, 200, 138, 0.35);
}

/* ICONO OPCIONAL SI LO USAS */
.doc i {
    font-size: 14px;
}

/* ======================================================
   LOADER
====================================================== */

#loader {
    text-align: center;
    color: #fff;
    padding: 20px;
}