  /**
 * noticias.css
 * Estilos para integrar las noticias legacy con el nuevo diseno
 * Proyecto: git-acom-web-upv
 */

/* ==========================================================================
   VARIABLES
   ========================================================================== */
:root {
    --news-max-width: 1200px;
    --news-content-width: 70%;
    --news-sidebar-width: 30%;
    --news-gap: 2rem;
    --news-font-base: 'Inter', sans-serif;
    --news-font-title: 'Poppins', sans-serif;
}

/* ==========================================================================
   LAYOUT PRINCIPAL
   ========================================================================== */

/* Breadcrumbs */
#DIVrutaN3 {
    max-width: var(--news-max-width);
    margin: 0 auto;
    padding: 0.5rem 1.5rem 1.5rem;
    font-family: var(--news-font-base);
    font-size: var(--small-font-size-2, 0.875rem);
    color: inherit;
}

#DIVrutaN3 a {
    color: inherit;
    text-decoration: underline;
}

/* Contenedor principal - 1 columna, panel debajo */
#DIVcontenidoN3 {
    max-width: var(--news-max-width);
    margin: 0 auto;
    padding: 0 1.5rem 2rem;
    display: flex;
    flex-direction: column;
    gap: var(--news-gap);
}

/* Contenido principal */
#DIVpanelIZQN3 {
    width: 100%;
}

/* Panel de noticias destacadas (debajo del contenido) */
#DIVpanelDERN3 {
    width: 100%;
    padding: 1.5rem 0;
    border-top: 1px solid #e0e0e0;
}

/* Grid 2 columnas en desktop */
@media (min-width: 768px) {
    #DIVpanelDERN3 {
        display: grid !important;
        grid-template-columns: repeat(2, 1fr);
        gap: 1.5rem;
    }

    #DIVpanelDERN3 > p.texto_bloqueN3,
    #DIVpanelDERN3 > .texto_bloqueN3 {
        grid-column: 1 / -1;
        margin-bottom: 0;
    }

    #DIVpanelDERN3 > br,
    #DIVpanelDERN3 > .estabilizador {
        display: none !important;
    }

    #DIVpanelDERN3 > .noticiaColumna3 {
        padding: 1rem;
        background: #f8f8f8;
        border-radius: 8px;
        border-bottom: none;
    }
}

/* Ocultar br en noticias columna (todos los tamanos) */
.noticiaColumna3 br {
    display: none;
}

/* ==========================================================================
   CONTENIDO DE LA NOTICIA
   ========================================================================== */

/* Titulo principal - h1 (font-gen-42: 42px desktop / 28px mobile) */
.titularpag {
    font-family: var(--news-font-title);
    font-size: 2.625rem; /* 42px */
    font-weight: 700;
    color: #1a1a1a;
    margin: 0 0 1rem;
    line-height: 1.2;
}

/* Contenedor titulo/fecha */
.NoticiaFotoTit {
    margin-bottom: 1.5rem !important;
    display: flow-root;
}

/* Subtitulo - h2 (font-gen-28: 28px desktop / 22px mobile) */
.titN3.noticiasubtitular,
h2.noticiasubtitular {
    font-family: var(--news-font-base);
    font-size: 1.75rem; /* 28px */
    font-weight: 400;
    color: #333;
    line-height: 1.4;
    margin: 0 0 0.5rem;
}

/* Subtitulos h3 dentro del contenido (font-gen-22: 22px desktop / 18px mobile) */
#DIVpanelIZQN3 h3 {
    font-family: var(--news-font-title);
    font-size: 1.375rem; /* 22px */
    font-weight: 700;
    color: #1a1a1a;
    line-height: 1.3;
    margin: 1.5rem 0 0.75rem;
}

/* Fecha */
.NoticiaFotoTit > span {
    font-size: 0.75em !important;
    color: #666;
    font-weight: 600;
}

/* Imagen principal */
.foto-not {
    float: left;
    max-width: 1200px;
    margin: 0 1.5rem 1rem 0;
}

/* Parrafos - con separacion entre ellos */
.texto_baseGN3 {
    font-family: var(--news-font-base);
    font-size: 1rem;
    line-height: 1.7;
    color: #333;
    margin: 0 0 1.5rem 0;
}

.texto_baseGN3:last-of-type {
    margin-bottom: 0;
}

.texto_baseGN3 b,
.texto_baseGN3 strong {
    font-weight: 700;
    color: #1a1a1a;
}

/* Seccion "Mas informacion" */
#DIVdestacadoN3 {
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid #e0e0e0;
    clear: both;
}

.titulares_seccionesN3 {
    font-family: var(--news-font-title);
    font-size: 1.25rem;
    font-weight: 700;
    color: #1a1a1a;
    margin-bottom: 1rem;
}

.lista_recursos {
    list-style: none;
    padding: 0;
    margin: 0;
}

.lista_recursos li {
    padding: 0.5rem 0;
}

.lista_recursos a {
    text-decoration: underline;
    font-family: var(--news-font-base);
}


/* ==========================================================================
   PANEL DERECHO (Noticias destacadas)
   ========================================================================== */

.panelDERGradN3 {
    background: transparent;
}

#DIVpanelDERN3 .texto_bloqueN3 {
    font-family: var(--news-font-title);
    font-size: 1.125rem;
    margin: 0 0 1rem;
}

#DIVpanelDERN3 .destacado_DER b {
    color: #1a1a1a;
    text-decoration: none;
}

/* Cada noticia en el sidebar */
.noticiaColumna3 {
    padding: 1rem 0;
    border-bottom: 1px solid #e0e0e0;
    display: flow-root;
}

.noticiaColumna3:last-of-type {
    border-bottom: none;
}

.imgColumnaNotis {
    float: left;
    width: 60px;
    height: 60px;
    object-fit: cover;
    margin-right: 1rem;
}

a.titularNOTI {
    font-family: var(--news-font-base);
    font-size: 1rem;
    font-weight: 600;
    text-decoration: underline;
    display: block;
    margin-bottom: 0.25rem;
}

.noticiaColumna3 br + text,
.noticiaColumna3 {
    font-family: var(--news-font-base);
    font-size: 0.8125rem;
    color: #333;
    line-height: 1.4;
}

/* ==========================================================================
   UTILIDADES LEGACY
   ========================================================================== */

.estabilizador {
    clear: both;
    height: 0;
    overflow: hidden;
}

/* ==========================================================================
   VIDEO EMBEBIDO
   ========================================================================== */

#DIVdestacadoN3 div[id^="video"] {
    max-width: 100%;
    margin: 1rem auto;
}

#DIVdestacadoN3 iframe {
    max-width: 100%;
}

#DIVdestacadoN3 div[id^="video_pie"] {
    font-size: 0.75rem !important;
    padding: 0.5rem 0;
}

#DIVdestacadoN3 div[id^="video_pie"] a {
    text-decoration: underline;
}

/* ==========================================================================
   RESPONSIVE
   ========================================================================== */

/* Breakpoint principal: 1030px (consistente con guia de estilos) */
@media (max-width: 1030px) {
    /* h1: font-gen-42 mobile = 28px (1.75rem) */
    .titularpag {
        font-size: 1.75rem;
    }

    /* h2: font-gen-28 mobile = 22px (1.375rem) */
    .titN3.noticiasubtitular,
    h2.noticiasubtitular {
        font-size: 1.375rem;
    }

    /* h3: font-gen-22 mobile = 18px (1.125rem) */
    #DIVpanelIZQN3 h3 {
        font-size: 1.125rem;
    }
}

@media (max-width: 768px) {
    .foto-not {
        float: none;
        max-width: 100%;
        margin: 0 0 1rem;
    }

    #DIVrutaN3 {
        padding: 1rem;
    }

    #DIVcontenidoN3 {
        padding: 0 1rem 2rem;
    }
}

@media (max-width: 480px) {
    .imgColumnaNotis {
        width: 50px;
        height: 50px;
    }
}

/* ==========================================================================
   PAGE NO HERO (main content adjustment)
   ========================================================================== */

.page-no-hero {
    padding-top: 0;
}

.page-no-hero .container {
    max-width: 100%;
    padding: 0;
}

/* ==========================================================================
   ESTILOS DE IMPRESION
   ========================================================================== */

@media print {
    /* Convertir header fixed a static para que fluya con el documento */
    .global-menu {
        position: static !important;
    }

    /* Quitar todo padding/margin que compense el header fixed */
    #smooth-wrapper,
    main,
    .page-no-hero,
    .container,
    #DIVrutaN3 {
        padding-top: 0 !important;
        margin-top: 0 !important;
    }

    /* El header no debe tener margin-bottom extra */
    header,
    .global-menu {
        margin-bottom: 0 !important;
    }

    /* Asegurar que el contenido sea visible */
    body, html {
        height: auto !important;
        overflow: visible !important;
    }

    /* Evitar cortes en medio de elementos */
    .titularpag, h1, h2, h3 {
        page-break-after: avoid;
    }

    img, .foto-not {
        page-break-inside: avoid;
    }
}
