/* ===================== RESET ===================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', sans-serif;
}

body {
    background-color: #fff;
    color: #001f3f;
}

/* ===================== MENU ===================== */
.header {
    width: 100%;
    background-color: #001f3f;
}

.navigation {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    padding: 15px 20px;
    justify-content: space-between;
}

.logo a {
    color: #fff;
    font-size: 1.6rem;
    font-weight: bold;
    text-decoration: none;
    transition: color 0.3s ease;
}

.logo a:hover {
    color: #00bfff;
}

.menu {
    list-style: none;
    display: flex;
    gap: 25px;
}

.menu li {
    position: relative;
}

.menu li a {
    color: #fff;
    text-decoration: none;
    padding: 10px 15px;
    display: block;
    border-radius: 5px;
    transition: all 0.3s ease;
}

.menu li a:hover {
    background: linear-gradient(90deg, #001f3f, #00bfff);
    transform: scale(1.05);
}

/* ===================== SUBMENU ===================== */
.submenu {
    position: absolute;
    top: 100%;
    left: 0;
    background-color: #001f3f;
    min-width: 200px;
    display: none;
    flex-direction: column;
    border-radius: 5px;
    z-index: 999;
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.4s ease;
}

.submenu li a {
    padding: 12px 20px;
    color: #fff;
    transition: background 0.3s, transform 0.3s;
}

.submenu li a:hover {
    background-color: #00bfff;
    transform: translateX(5px);
}

.menu li:hover > .submenu {
    display: flex;
    opacity: 1;
    transform: translateY(0);
}

/* ===================== GALERÍA DE NOTICIAS ===================== */
.noticias-section {
    max-width: 1200px;
    margin: 40px auto;
    padding: 0 20px;
}

.galeria-noticias {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 30px;
}

.noticia-div {
    background: #fff;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 8px 20px rgba(0,0,0,0.15);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.noticia-div:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: 0 12px 25px rgba(0,0,0,0.25);
}

.noticia-div img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.noticia-contenido {
    padding: 15px 20px;
}

.noticia-contenido h2 {
    font-size: 1.3rem;
    margin-bottom: 10px;
    color: #001f3f;
}

.noticia-contenido p {
    font-size: 0.95rem;
    color: #333;
    margin-bottom: 15px;
}

.btn-vermas {
    text-decoration: none;
    background-color: #001f3f;
    color: #fff;
    padding: 8px 15px;
    border-radius: 5px;
    transition: all 0.3s ease;
}

.btn-vermas:hover {
    background-color: #00bfff;
    color: #fff;
    transform: scale(1.05);
}

/* ===================== RESPONSIVE ===================== */
@media (max-width: 992px) {
    .menu {
        flex-direction: column;
        gap: 0;
        background-color: #001f3f;
        width: 100%;
        display: none;
    }

    .menu li {
        width: 100%;
    }

    .menu li a {
        padding: 15px;
    }

    .menu.active {
        display: flex;
    }

    .submenu {
        position: relative;
        top: 0;
        left: 0;
        display: none;
    }

    .submenu li a {
        padding-left: 30px;
    }

    .menu li:hover > .submenu {
        display: flex;
    }
}
/* ===================== VARIABLES GLOBALES ===================== */
:root {
    --primary: #001f3f;
    --accent: #00bfff;
    --radius: 15px;
    --transition-fast: 0.25s ease;
    --transition-medium: 0.4s ease;
}

/* ===================== ANIMACIÓN DE ENTRADA GENERAL ===================== */
@keyframes fadeUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ===================== TITULO CON EFECTO ===================== */
.noticias-section h1 {
    text-align: center;
    margin-bottom: 40px;
    font-size: clamp(1.8rem, 3vw, 2.4rem);
    position: relative;
    animation: fadeUp 0.8s ease forwards;
}

.noticias-section h1::after {
    content: "";
    width: 80px;
    height: 4px;
    background: linear-gradient(90deg, var(--primary), var(--accent));
    display: block;
    margin: 15px auto 0;
    border-radius: 10px;
}

/* ===================== CARDS: ENTRADA ESCALONADA ===================== */
.noticia-div {
    animation: fadeUp 0.8s ease forwards;
    opacity: 0;
}

.noticia-div:nth-child(1) { animation-delay: 0.1s; }
.noticia-div:nth-child(2) { animation-delay: 0.2s; }
.noticia-div:nth-child(3) { animation-delay: 0.3s; }
.noticia-div:nth-child(4) { animation-delay: 0.4s; }
.noticia-div:nth-child(5) { animation-delay: 0.5s; }
.noticia-div:nth-child(6) { animation-delay: 0.6s; }

/* ===================== IMÁGENES: ZOOM SUAVE ===================== */
.noticia-div img {
    transition: transform 0.6s ease;
}

.noticia-div:hover img {
    transform: scale(1.1);
}

/* ===================== OVERLAY SUTIL ===================== */
.noticia-div::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.25), transparent 60%);
    opacity: 0;
    transition: opacity var(--transition-medium);
    pointer-events: none;
}

.noticia-div:hover::after {
    opacity: 1;
}

/* ===================== TEXTO MÁS ELEGANTE ===================== */
.noticia-contenido h2 {
    line-height: 1.3;
    transition: color var(--transition-fast);
}

.noticia-div:hover h2 {
    color: var(--accent);
}

/* ===================== BOTÓN PREMIUM ===================== */
.btn-vermas {
    position: relative;
    overflow: hidden;
}

.btn-vermas::before {
    content: "";
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        120deg,
        transparent,
        rgba(255,255,255,0.4),
        transparent
    );
    transition: left 0.6s ease;
}

.btn-vermas:hover::before {
    left: 100%;
}

/* ===================== HEADER CON SCROLL FEEL ===================== */
.header {
    position: sticky;
    top: 0;
    z-index: 1000;
    animation: fadeUp 0.6s ease;
}

/* ===================== ACCESIBILIDAD ===================== */
@media (prefers-reduced-motion: reduce) {
    * {
        animation: none !important;
        transition: none !important;
    }
}
/* ===================== LEER MÁS ===================== */
.texto-noticia {
    max-height: 90px;
    overflow: hidden;
    position: relative;
    transition: max-height 0.5s ease;
    line-height: 1.5;
}

.texto-noticia.expandido {
    max-height: 600px;
}

.texto-noticia::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 40px;
    background: linear-gradient(to top, #fff, transparent);
    transition: opacity 0.3s ease;
}

.texto-noticia.expandido::after {
    opacity: 0;
}

.leer-mas {
    background: none;
    border: none;
    color: #00bfff;
    font-weight: 600;
    cursor: pointer;
    padding: 5px 0 10px;
}

.leer-mas:hover {
    color: #001f3f;
}
.noticia-contenido {
    display: flex;
    flex-direction: column;
}

.leer-mas {
    align-self: flex-start;
    margin-bottom: 12px;
}
