:root {
    --navy-deep: #101d45;          /* Azul noche - botones, footer, acentos fuertes */
    --primary-color: #23408c;      /* Azul institucional (antes #3a5fae) */
    --secondary-color: #3f68c9;    /* Azul medio, ya no "celeste" pastel (antes #789bfb) */
    --tertiary-color: #cfe3f7;     /* Azul claro - fondos suaves */
    --accent-gold: #e9a53c;        /* Ámbar cálido - detalles y acentos */
    --accent-gold-dark: #c1801f;
    --white: #ffffff;
    --dark-text: #1f2937;
    --light-text: #6b7280;
    --shadow-light: rgba(16, 29, 69, 0.10);
    --shadow-medium: rgba(16, 29, 69, 0.20);
    --shadow-dark: rgba(16, 29, 69, 0.32);
    --font-display: 'Big Shoulders Display', 'Segoe UI', Tahoma, sans-serif;
    --font-body: 'Public Sans', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

/* Reset y estilos base */
* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-body);
    line-height: 1.6;
    color: var(--dark-text);
    background-color: #f7f9fd;
    background-image:
        radial-gradient(circle at 1px 1px, rgba(16, 29, 69, 0.05) 1px, transparent 0);
    background-size: 26px 26px;
}

/* Barra de acento superior, marca de identidad institucional */
body::before {
    content: '';
    display: block;
    height: 4px;
    width: 100%;
    background: linear-gradient(90deg, var(--navy-deep) 0%, var(--primary-color) 35%, var(--secondary-color) 65%, var(--accent-gold) 100%);
    position: relative;
    z-index: 1100;
}

::selection {
    background: var(--accent-gold);
    color: var(--navy-deep);
}

/* Scrollbar personalizada (navegadores webkit) */
::-webkit-scrollbar {
    width: 12px;
}
::-webkit-scrollbar-track {
    background: var(--tertiary-color);
}
::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, var(--secondary-color), var(--primary-color));
    border-radius: 10px;
    border: 3px solid var(--tertiary-color);
}
::-webkit-scrollbar-thumb:hover {
    background: var(--navy-deep);
}

/* Estilos para la barra de navegación */
.navbar {
    background: linear-gradient(135deg, var(--white) 0%, var(--tertiary-color) 100%) !important;
    border-bottom: 3px solid var(--primary-color);
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    transition: padding 0.35s ease, box-shadow 0.35s ease;
}

.navbar.is-scrolled {
    padding: 0.5rem 0;
    box-shadow: 0 10px 30px var(--shadow-medium);
}

.navbar-brand {
    font-weight: bold;
    color: var(--primary-color) !important;
    font-size: 1.5rem;
    display: flex;
    align-items: center;
    flex-wrap: nowrap;
    white-space: nowrap;
    overflow: hidden;
}

.navbar-brand span {
    display: inline-block;
    line-height: 1.2;
    font-family: var(--font-display);
    font-weight: 700;
    letter-spacing: 0.02em;
    text-transform: uppercase;
}

.navbar-nav .nav-link {
    color: var(--primary-color) !important;
    font-weight: 600;
    margin: 0 0.5rem;
    transition: all 0.3s ease;
    position: relative;
}

.navbar-nav .nav-link:hover {
    color: var(--secondary-color) !important;
    transform: translateY(-2px);
}

.navbar-nav .nav-link::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: -5px;
    left: 50%;
    background: linear-gradient(90deg, var(--secondary-color), var(--primary-color));
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

.navbar-nav .nav-link:hover::after {
    width: 100%;
}

/* Estilos para el logo - CORREGIDO PARA QUE SE VEA COMPLETO */
.logo {
    width: 70px;
    height: 70px;
    background-image: url('../imagenes/cabeza.png');
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 15px var(--shadow-medium);
    transition: all 0.3s ease;
    position: relative;
    z-index: 1001;
    flex-shrink: 0;
    background-color: var(--white);
    padding: 5px;
}

.logo:hover {
    transform: rotate(-4deg) scale(1.05);
    box-shadow: 0 6px 20px var(--shadow-dark);
}


/* Estilos para el carrusel */
.carousel {
    box-shadow: 0 8px 32px var(--shadow-medium);
    position: relative;
    z-index: 1;
}

.carousel-item img {
    height: 500px;
    object-fit: cover;
    filter: brightness(0.9);
}

.carousel-caption {
    background: linear-gradient(135deg, var(--navy-deep) 0%, var(--primary-color) 100%);
    border-radius: 15px;
    padding: 1.5rem;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-left: 4px solid var(--accent-gold);
    /* Forzar que siempre sea visible */
    display: block !important;
    position: absolute;
    bottom: 1rem;
    left: 50%;
    transform: translateX(-50%);
    width: 90%;
    max-width: 600px;
    z-index: 10;
}

.carousel-caption h5 {
    color: var(--white);
    font-family: var(--font-display);
    font-weight: 700;
    letter-spacing: 0.01em;
    font-size: 1.9rem;
    margin-bottom: 0.5rem;
}

.carousel-caption p {
    color: var(--tertiary-color);
    font-size: 1.1rem;
    margin-bottom: 0;
}

.carousel-indicators {
    z-index: 15;
    /* Posición ajustada en desktop - un poco más abajo */
    bottom: 10px;
}

.carousel-indicators button {
    background-color: var(--secondary-color);
    border-radius: 50%;
    width: 12px;
    height: 12px;
    margin: 0 5px;
    transition: transform 0.25s ease, background-color 0.25s ease;
}

.carousel-indicators button.active {
    background-color: var(--white);
    transform: scale(1.25);
}

/* CONTROLES DEL CARRUSEL - Z-INDEX ALTO PARA QUE FUNCIONEN */
.carousel-control-prev,
.carousel-control-next {
    z-index: 20 !important;
}

.carousel-control-prev-icon,
.carousel-control-next-icon {
    background-color: var(--navy-deep);
    border-radius: 50%;
    padding: 20px;
    z-index: 21;
}

/* =====================================================================
   Carrusel de Noticias (home)
   Formato "tarjeta": imagen a la izquierda + panel oscuro a la derecha,
   contenido dentro de .container (no ocupa el ancho completo de la página).
   ===================================================================== */
.noticias-carousel {
    border-radius: 0;
    overflow: hidden;
    box-shadow: 0 14px 40px var(--shadow-medium);
    position: relative;
}

.noticia-slide {
    position: relative;
    min-height: 560px;
    background: var(--navy-deep);
    overflow: hidden;
}

.noticia-imagen {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
}

.noticia-panel {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    width: 30%;
    background: linear-gradient(100deg, rgba(0, 0, 0, 0) 0%, rgba(0, 0, 0, 0.65) 24%, rgba(0, 0, 0, 0.88) 55%, rgba(0, 0, 0, 0.92) 100%);
    color: var(--white);
    padding: 2.25rem 1.75rem 2.75rem 2.5rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
    z-index: 1;
}

.noticia-fecha {
    display: inline-flex;
    align-items: center;
    align-self: flex-end;
    background: var(--accent-gold);
    color: var(--navy-deep);
    font-weight: 700;
    padding: 0.3rem 0.85rem;
    border-radius: 999px;
    font-size: 0.8rem;
    letter-spacing: 0.03em;
    margin-bottom: 1.1rem;
}

.noticia-titulo {
    font-family: var(--font-display);
    font-weight: 800;
    font-size: 1.7rem;
    text-transform: uppercase;
    letter-spacing: 0.01em;
    line-height: 1.15;
    margin-bottom: 0.85rem;
}

.noticia-subtitulo {
    font-size: 0.98rem;
    color: var(--tertiary-color);
    margin-bottom: 1.4rem;
}

.noticia-leermas {
    display: inline-flex;
    align-items: center;
    color: var(--tertiary-color);
    font-weight: 700;
    text-decoration: none;
    letter-spacing: 0.01em;
    transition: gap 0.25s ease, color 0.25s ease;
    gap: 0.2rem;
}

.noticia-leermas:hover,
.noticia-leermas:focus-visible {
    color: var(--white);
    gap: 0.5rem;
}

/* Controles e indicadores propios del carrusel de noticias: discretos y
   ubicados sobre la imagen para no tapar el texto del panel. */
.noticias-carousel .carousel-control-prev,
.noticias-carousel .carousel-control-next {
    top: 1rem;
    bottom: auto;
    width: 42px;
    height: 42px;
    opacity: 0.85;
}

.noticias-carousel .carousel-control-prev {
    left: 1rem;
}

.noticias-carousel .carousel-control-next {
    left: auto;
    right: 1rem;
}

.noticias-carousel .carousel-control-prev-icon,
.noticias-carousel .carousel-control-next-icon {
    padding: 15px;
}

.noticias-carousel .carousel-indicators {
    position: absolute;
    bottom: 1.25rem;
    right: 2rem;
    left: auto;
    margin: 0;
    width: auto;
    justify-content: flex-end;
}

.noticias-carousel .carousel-indicators button {
    width: 9px;
    height: 9px;
}

@media (max-width: 768px) {
    .noticia-slide {
        min-height: 480px;
    }
    .noticia-panel {
        width: 100%;
        background: linear-gradient(180deg, rgba(0, 0, 0, 0) 0%, rgba(0, 0, 0, 0.55) 32%, rgba(0, 0, 0, 0.88) 58%, rgba(0, 0, 0, 0.92) 100%);
        padding: 1.75rem 1.5rem 2.25rem;
        justify-content: flex-end;
    }
    .noticia-titulo {
        font-size: 1.35rem;
    }
    .noticia-subtitulo {
        font-size: 0.92rem;
    }
    .noticias-carousel .carousel-control-next {
        right: 1rem;
    }
    .noticias-carousel .carousel-indicators {
        right: 1rem;
        bottom: 0.75rem;
    }
}

/* Modales "Leer más" de noticias */
.modal-content {
    border-radius: 18px;
    overflow: hidden;
    border: none;
    box-shadow: 0 20px 60px var(--shadow-dark);
}

.modal-header {
    background: linear-gradient(135deg, var(--navy-deep) 0%, var(--primary-color) 100%);
    color: var(--white);
    border-bottom: none;
    padding: 1.25rem 1.5rem;
}

.modal-header .modal-title {
    font-family: var(--font-display);
    text-transform: uppercase;
    letter-spacing: 0.02em;
    font-weight: 700;
    font-size: 1.3rem;
}

.modal-header .btn-close {
    filter: invert(1) grayscale(100%) brightness(200%);
}

.modal-body {
    padding: 1.75rem;
    color: var(--dark-text);
    line-height: 1.75;
}

/* Carrusel de fotos verticales (Talleres UOCRA Juventud) - evita recortar personas */
/* Estilos para las secciones */
.bg-light {
    background: linear-gradient(135deg, var(--tertiary-color) 0%, var(--white) 100%) !important;
    position: relative;
    z-index: 1;
}

/* Ajuste para la sección de tarjetas */
.py-5:not(.bg-light) {
    position: relative;
    z-index: 1;
}

/* Franja de credenciales / confianza institucional */
.trust-strip {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.85rem;
    margin-top: 1.75rem;
    margin-bottom: 3rem;
}

@media (min-width: 768px) {
    .trust-strip {
        grid-template-columns: repeat(4, 1fr);
    }
}

.trust-strip .badge-uocra {
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    gap: 0.5rem;
    min-height: 4.5rem;
    background: var(--white);
    color: var(--navy-deep);
    border: 1px solid var(--tertiary-color);
    border-radius: 16px;
    padding: 0.65rem 1rem;
    font-weight: 600;
    font-size: 0.92rem;
    line-height: 1.25;
    box-shadow: 0 4px 14px var(--shadow-light);
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.trust-strip .badge-uocra i {
    flex-shrink: 0;
    color: var(--accent-gold-dark);
    font-size: 1.1rem;
}

.trust-strip .badge-uocra:hover {
    transform: translateY(-4px);
    border-color: var(--secondary-color);
    box-shadow: 0 10px 24px var(--shadow-medium);
}

/* Estilos para los botones personalizados */
.btn-uocra {
    background: linear-gradient(135deg, var(--navy-deep) 0%, var(--primary-color) 100%);
    border: none;
    color: white;
    margin: 0.5rem;
    padding: 0.75rem 1.6rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    transition: all 0.3s ease;
    border-radius: 25px;
    box-shadow: 0 6px 18px var(--shadow-medium);
    position: relative;
    overflow: hidden;
    z-index: 10;
    text-decoration: none !important;
    isolation: isolate;
}

.btn-uocra::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(120deg, transparent 20%, rgba(255,255,255,0.35) 50%, transparent 80%);
    transform: translateX(-120%);
    transition: transform 0.6s ease;
    z-index: -1;
}

.btn-uocra:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 26px var(--shadow-dark);
    color: white;
}

.btn-uocra:hover::before {
    transform: translateX(120%);
}

.btn-uocra:active {
    transform: translateY(-1px);
}

.btn-uocra:focus-visible {
    outline: 3px solid var(--secondary-color);
    outline-offset: 2px;
}

/* Estilos para las tarjetas */
.card {
    transition: all 0.4s ease;
    border: none;
    box-shadow: 0 5px 20px var(--shadow-light);
    border-radius: 20px;
    overflow: hidden;
    background: var(--white);
    position: relative;
    z-index: 10;
}

.card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--navy-deep) 0%, var(--primary-color) 45%, var(--secondary-color) 100%);
    background-size: 200% 100%;
    background-position: 0% 0%;
    transition: background-position 0.6s ease;
    z-index: 3;
}

.card:hover::before {
    background-position: 100% 0%;
}

.card:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: 0 18px 40px var(--shadow-medium);
}

.card-img-top {
    height: 280px;
    object-fit: cover;
    transition: all 0.4s ease;
}

.card-img-top.card-img-contain {
    object-fit: contain;
    background: #ffffff;
    padding-top: 10px;
}

.card:hover .card-img-top.card-img-contain {
    transform: none;
    filter: none;
}

.card:hover .card-img-top {
    transform: scale(1.1);
    filter: brightness(1.1);
}

.card-body {
    padding: 1.5rem;
    background: linear-gradient(135deg, var(--white) 0%, var(--tertiary-color) 100%);
}

.card-title {
    color: var(--primary-color);
    font-weight: 700;
    font-size: 1.3rem;
    margin-bottom: 1rem;
}

.card-text {
    color: var(--light-text);
    line-height: 1.7;
    font-size: 0.95rem;
}

/* Estilos para los títulos de sección */
.section-title {
    color: var(--navy-deep);
    font-family: var(--font-display);
    text-transform: uppercase;
    letter-spacing: 0.03em;
    font-weight: 800;
    margin-bottom: 3rem;
    text-align: center;
    font-size: 2.9rem;
    position: relative;
    z-index: 10;
}

.section-title::before {
    content: '';
    position: absolute;
    top: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, var(--tertiary-color) 0%, var(--secondary-color) 100%);
    border-radius: 50%;
    z-index: -1;
    opacity: 0.3;
}

.section-title::after {
    content: '';
    display: block;
    width: 100px;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-color) 0%, var(--accent-gold) 100%);
    margin: 1rem auto;
    border-radius: 2px;
    box-shadow: 0 2px 10px var(--shadow-light);
}

/* Estilos para el footer */
.footer {
    background: linear-gradient(135deg, var(--navy-deep) 0%, var(--primary-color) 100%);
    color: white;
    padding: 4rem 0 1.5rem;
    position: relative;
    overflow: hidden;
    z-index: 1;
    margin-top: 3rem;
}

.footer h5 {
    color: var(--white);
    font-family: var(--font-display);
    text-transform: uppercase;
    letter-spacing: 0.02em;
    font-weight: 700;
    margin-bottom: 1rem;
    font-size: 1.6rem;
}

.footer h6 {
    color: var(--tertiary-color);
    font-weight: 600;
    margin-bottom: 1rem;
    font-size: 1.2rem;
}

.footer p {
    color: var(--tertiary-color);
    line-height: 1.8;
}

.footer hr {
    border-color: var(--tertiary-color);
    opacity: 0.3;
}

/* Estilos para los enlaces de redes sociales */
.social-links {
    display: flex;
    flex-wrap: wrap;
    gap: 0.9rem;
    justify-content: flex-end;
}

.social-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    color: var(--white);
}

.social-item i {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 3rem;
    height: 3rem;
    font-size: 1.6rem;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
}

.social-item:hover i {
    color: var(--navy-deep);
    background: var(--white);
    transform: translateY(-5px) scale(1.1);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
}

.social-label {
    font-size: 0.68rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.75);
    margin-top: 0.4rem;
    letter-spacing: 0.02em;
    text-align: center;
}

/* Menú desplegable del navbar */
.navbar-collapse {
    z-index: 1050;
}

.navbar-toggler {
    z-index: 1051;
}

/* Botón de pausa/reanudar, se agrega por JS a todo carrusel automático.
   Abajo a la izquierda, en la misma línea que los puntitos indicadores
   (que quedan a la derecha) pero del lado opuesto para no pisarlos. */
.carousel-pause-toggle {
    position: absolute;
    bottom: 1rem;
    left: 1rem;
    top: auto;
    z-index: 25;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    border: none;
    background: rgba(16, 29, 69, 0.6);
    color: var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    line-height: 1;
    cursor: pointer;
    backdrop-filter: blur(4px);
    transition: background 0.25s ease, transform 0.25s ease;
}

.carousel-pause-toggle:hover,
.carousel-pause-toggle:focus-visible {
    background: var(--secondary-color);
    color: var(--white);
    transform: scale(1.08);
}

/* En el carrusel de noticias: mismo lado que los puntitos (derecha, donde
   no tapa el link "Leer más" que queda a la izquierda del panel), pero
   corrido para no superponerse con los puntitos. */
.noticias-carousel .carousel-pause-toggle {
    bottom: 1.25rem;
    left: auto;
    right: 5.75rem;
}

@media (max-width: 768px) {
    .noticias-carousel .carousel-pause-toggle {
        bottom: 0.75rem;
        right: 4.5rem;
    }
}

.carousel-pause-toggle:focus-visible {
    outline: 2px solid var(--white);
    outline-offset: 2px;
}

/* Botón flotante "volver arriba" */
.back-to-top {
    position: fixed;
    right: 1.5rem;
    bottom: 1.5rem;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--navy-deep) 0%, var(--primary-color) 100%);
    color: var(--white);
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    box-shadow: 0 8px 24px var(--shadow-dark);
    opacity: 0;
    visibility: hidden;
    transform: translateY(12px);
    transition: opacity 0.3s ease, transform 0.3s ease, visibility 0.3s ease, background 0.3s ease;
    z-index: 1200;
    cursor: pointer;
}

.back-to-top.is-visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.back-to-top:hover {
    background: linear-gradient(135deg, var(--secondary-color) 0%, var(--primary-color) 100%);
    transform: translateY(-4px);
}

/* Animación de aparición al hacer scroll */
.reveal {
    opacity: 0;
    transform: translateY(28px);
    transition: opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1), transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}

.reveal.is-visible {
    opacity: 1;
    transform: translateY(0);
}

/* Estilos responsivos */
@media (max-width: 768px) {
    .section-title {
        font-size: 2.3rem;
    }

    .btn-uocra {
        margin: 0.3rem;
        padding: 0.75rem 1.5rem;
        font-size: 0.98rem;
    }

    .carousel-item img {
        height: 280px;
    }

    .logo {
        width: 70px;
        height: 70px;
        margin-right: 0.8rem;
        padding: 4px;
    }

    .navbar-brand {
        font-size: 1.35rem;
        flex-direction: row;
        align-items: center;
    }

    .navbar-brand span {
        font-size: 1.45rem !important;
        line-height: 1.15;
        margin-left: 0.5rem;
    }

    .carousel-caption {
        padding: 1rem;
        bottom: 3rem; /* Más espacio para los indicadores */
        width: 95%;
        border-radius: 10px;
    }

    .carousel-caption h5 {
        font-size: 1.3rem;
        margin-bottom: 0.3rem;
    }

    .carousel-caption p {
        font-size: 0.9rem;
        line-height: 1.3;
    }

    /* INDICADORES EN MÓVIL - DEBAJO DEL CAPTION */
    .carousel-indicators {
        bottom: 0.5rem; /* Más abajo que el caption */
        z-index: 5; /* Menor z-index que el caption */
    }

    .card-body {
        padding: 1.2rem;
    }

    .back-to-top {
        right: 1rem;
        bottom: 1rem;
        width: 42px;
        height: 42px;
        font-size: 1.1rem;
    }
}

@media (max-width: 576px) {
    .section-title {
        font-size: 2.1rem;
    }

    .carousel-item img {
        height: 220px;
    }

    .logo {
        width: 60px;
        height: 60px;
        margin-right: 0.6rem;
        padding: 4px;
    }

    .navbar-brand {
        font-size: 1.15rem;
        max-width: 100%;
    }

    .navbar-brand span {
        font-size: 1.25rem !important;
        line-height: 1.15;
        word-break: break-word;
        hyphens: auto;
    }

    .navbar .container {
        padding-left: 0.75rem;
        padding-right: 0.75rem;
    }

    .carousel-caption {
        padding: 0.8rem;
        bottom: 2.5rem; /* Más espacio para los indicadores */
        width: 98%;
        border-radius: 8px;
    }

    .carousel-caption h5 {
        font-size: 1.1rem;
        margin-bottom: 0.2rem;
    }

    .carousel-caption p {
        font-size: 0.8rem;
        line-height: 1.2;
    }

    /* INDICADORES EN MÓVIL PEQUEÑO - DEBAJO DEL CAPTION */
    .carousel-indicators {
        bottom: 0.3rem; /* Más abajo que el caption */
        z-index: 5; /* Menor z-index que el caption */
    }

    .social-links {
        justify-content: center;
        margin-top: 1.5rem;
        gap: 0.7rem;
    }

    .social-item i {
        width: 2.6rem;
        height: 2.6rem;
        font-size: 1.4rem;
    }

    .social-label {
        font-size: 0.62rem;
    }

    .btn-uocra {
        display: block;
        width: 95%;
        margin: 0.5rem auto;
    }
}

@media (max-width: 400px) {
    .logo {
        width: 50px;
        height: 50px;
        margin-right: 0.5rem;
        padding: 3px;
    }

    .navbar-brand {
        font-size: 1.05rem;
    }

    .navbar-brand span {
        font-size: 1.1rem !important;
        line-height: 1.05;
    }

    .navbar .container {
        padding-left: 0.5rem;
        padding-right: 0.5rem;
    }

    .carousel-caption {
        bottom: 2rem; /* Más espacio para los indicadores */
    }

    .carousel-indicators {
        bottom: 0.2rem; /* Más abajo que el caption */
    }
}

/* Animaciones adicionales */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(40px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes floatSlow {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-8px); }
}

/* Efectos de scroll */
@keyframes pulse {
    0% {
        box-shadow: 0 0 0 0 var(--shadow-medium);
    }
    70% {
        box-shadow: 0 0 0 10px rgba(16, 29, 69, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(16, 29, 69, 0);
    }
}


.social-links a:focus,
.nav-link:focus {
    outline: 3px solid var(--secondary-color);
    outline-offset: 2px;
}

/* Efectos de glassmorphism */
.navbar {
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

/* Estilos adicionales para elementos interactivos */
.carousel-control-prev:hover,
.carousel-control-next:hover {
    opacity: 0.9;
}

.carousel-control-prev-icon:hover,
.carousel-control-next-icon:hover {
    background-color: var(--secondary-color);
    transform: scale(1.1);
}

.card-logo {
width: 90px;
height: 90px;
object-fit: contain;
border-radius: 50%;
box-shadow: 0 2px 8px var(--shadow-light);
background: var(--tertiary-color);
display: block;
}
@media (max-width: 767px) {
.card-logo {
    width: 62px;
    height: 62px;
    margin-bottom: 0.5rem;
}
}
@media (max-width: 400px) {
.card-logo {
    width: 44px;
    height: 44px;
}
}

/* =====================================================================
   PÁGINA INDIVIDUAL DE NOTICIA (noticia1.html, noticia2.html, ...)
   ===================================================================== */
.noticia-volver {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    color: var(--primary-color);
    font-weight: 700;
    text-decoration: none;
    letter-spacing: 0.01em;
    transition: gap 0.25s ease, color 0.25s ease;
}

.noticia-volver:hover,
.noticia-volver:focus-visible {
    color: var(--secondary-color);
    gap: 0.7rem;
}

.noticia-hero {
    position: relative;
    min-height: 420px;
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: flex-end;
    overflow: hidden;
}

.noticia-hero::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.88) 0%, rgba(0, 0, 0, 0.45) 55%, rgba(0, 0, 0, 0.15) 100%);
}

.noticia-hero-contenido {
    position: relative;
    z-index: 1;
    width: 100%;
    padding: 3rem 0 2.5rem;
}

.noticia-hero .noticia-fecha {
    align-self: flex-start;
}

.noticia-hero-titulo {
    font-family: var(--font-display);
    font-weight: 800;
    font-size: 2.4rem;
    text-transform: uppercase;
    letter-spacing: 0.01em;
    line-height: 1.15;
    color: var(--white);
    margin: 1rem 0 0;
    max-width: 900px;
}

.noticia-articulo {
    max-width: 780px;
    margin: 0 auto;
}

.noticia-articulo .noticia-bajada {
    font-size: 1.15rem;
    font-weight: 600;
    color: var(--primary-color);
    margin-bottom: 1.75rem;
}

.noticia-articulo p {
    font-size: 1.05rem;
    line-height: 1.75;
    color: #3a3f4b;
    margin-bottom: 1.25rem;
}

@media (max-width: 768px) {
    .noticia-hero {
        min-height: 320px;
    }
    .noticia-hero-titulo {
        font-size: 1.7rem;
    }
}
