body.plantilla-tn,
body.plantilla-tn *,
body.plantilla-tn_foto,
body.plantilla-tn_foto *,
body.plantilla-tn_vertical,
body.plantilla-tn_vertical * {
    overflow-anchor: none;
}

body.plantilla-tn,
body.plantilla-tn_foto {
    background: #fff;
    color: #161616;
}

body.plantilla-tn .tn-wrap {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
}

.tn-header {
    position: sticky;
    top: 0;
    z-index: 40;
    background: #862b4a;
    color: #fff;
    overflow-anchor: none;
}

/* Franja YouTube en vivo (bajo el header TN) */
.vivo-barra {
    position: relative;
    width: 100%;
    max-width: 100%;
    background: #111018;
    color: #fff;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
.vivo-barra[hidden] {
    display: none !important;
}
.vivo-cerrar {
    position: absolute;
    top: 0.55rem;
    right: 0.55rem;
    z-index: 5;
    width: 2.1rem;
    height: 2.1rem;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.14);
    color: #fff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    line-height: 1;
}
.vivo-cerrar:hover,
.vivo-cerrar:focus-visible {
    background: rgba(255, 255, 255, 0.28);
    outline: none;
}
.vivo-inner {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 1rem 1.25rem;
    padding: 0.85rem 3.25rem 0.85rem 1rem;
    max-width: 1180px;
    margin: 0 auto;
}
.vivo-video {
    flex: 0 1 420px;
    width: min(100%, 420px);
    max-width: 100%;
}
.vivo-ratio {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    background: #000;
    border-radius: 8px;
    overflow: hidden;
}
.vivo-ratio iframe {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: 0;
    max-width: none !important;
}
.vivo-meta {
    flex: 1 1 220px;
    min-width: 0;
    padding-right: 0.5rem;
}
.vivo-badge {
    display: inline-block;
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.06em;
    background: #e11d48;
    color: #fff;
    padding: 0.2rem 0.55rem;
    border-radius: 4px;
    margin-bottom: 0.45rem;
}
.vivo-titulo {
    margin: 0;
    font-size: clamp(1rem, 2.2vw, 1.35rem);
    font-weight: 700;
    line-height: 1.25;
    color: #fff;
}
@media (max-width: 575.98px) {
    .vivo-inner {
        padding: 0.75rem 2.75rem 0.85rem 0.75rem;
    }
    .vivo-video {
        flex-basis: 100%;
        width: 100%;
    }
}

.tn-barra {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: 16px;
    min-height: 148px;
    padding: 12px 22px;
}

.tn-barra-lado,
.tn-barra-derecha {
    display: flex;
    align-items: center;
    gap: 18px;
}

.tn-barra-derecha {
    justify-content: flex-end;
}

.tn-redes-fila {
    display: flex;
    align-items: center;
    gap: 18px;
}

.tn-secciones-btn,
.tn-buscar-btn,
.tn-ultimas,
.tn-redes a,
.tn-temas a,
.tn-panel a {
    color: #fff;
    text-decoration: none;
}

.tn-secciones-btn,
.tn-buscar-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    border: 0;
    background: transparent;
    font: inherit;
    font-weight: 700;
    cursor: pointer;
}

.tn-ultimas {
    font-weight: 700;
}

.tn-logo img {
    display: block;
    width: auto;
    max-width: 420px;
    max-height: 132px;
    object-fit: contain;
    background: #fff;
    border-radius: 4px;
    padding: 6px 10px;
}

.tn-redes {
    display: flex;
    gap: 12px;
}

.tn-header-redes {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 6px;
}

.tn-buscar-btn {
    line-height: 1;
}

.tn-redes a {
    font-size: 16px;
    line-height: 1;
}

.tn-cortina {
    position: fixed;
    inset: 0;
    z-index: 80;
    background: rgba(0, 0, 0, 0.45);
}

.tn-cortina[hidden],
.tn-panel[hidden],
.tn-buscar[hidden] {
    display: none !important;
}

.tn-panel {
    position: fixed;
    top: 0;
    bottom: 0;
    left: 0;
    z-index: 90;
    width: min(300px, 86vw);
    display: flex;
    flex-direction: column;
    margin: 0;
    padding: 0;
    overflow: auto;
    background: #fff;
    color: #161616;
    box-shadow: 8px 0 24px rgba(0, 0, 0, 0.18);
}

.tn-panel-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 18px;
    background: #862b4a;
    color: #fff;
}

.tn-panel-cerrar {
    border: 0;
    background: transparent;
    color: #fff;
    font-size: 30px;
    line-height: 1;
    cursor: pointer;
}

.tn-panel a {
    display: block;
    padding: 14px 18px;
    border-bottom: 1px solid #eee;
    color: #161616;
    font-weight: 700;
    text-decoration: none;
}

.tn-panel a:hover {
    background: #f7eef1;
    color: #862b4a;
}

.tn-buscar {
    display: flex;
    gap: 8px;
    padding: 12px 22px 16px;
    background: #fff;
    color: #161616;
}

.tn-buscar input {
    flex: 1;
    border: 1px solid #d7d7d7;
    border-radius: 4px;
    padding: 10px 12px;
    font: inherit;
}

.tn-buscar button {
    border: 0;
    background: #862b4a;
    color: #fff;
    font-weight: 700;
    padding: 0 16px;
    cursor: pointer;
}

.tn-fecha {
    color: #fff;
    font-size: 12px;
    font-weight: 700;
    line-height: 1.2;
    text-align: right;
    white-space: nowrap;
}

.tn-mercado .cotizacion-barra {
    margin: 0;
    border: 0;
    border-radius: 0;
    background: #081226;
    color: #fff;
    box-shadow: none;
}

.tn-mercado .cotizacion-nombre,
.tn-mercado .cotizacion-venta,
.tn-mercado .cotizacion-cambio-igual {
    color: #fff;
}

.tn-portada,
.tn-nota,
.tn-listado {
    padding: 22px 0 48px;
}

.tn-portada {
    padding-top: 6px;
}

.tn-portada-grid,
.tn-nota-grid {
    display: block;
}

.tn-con-lateral {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 300px;
    gap: 28px;
    align-items: start;
}

.tn-bloque {
    margin-bottom: 28px;
    padding: 0 0 8px;
}

.tn-bloque.tn-bloque-color {
    padding: 16px 16px 20px;
    border-radius: 14px;
    overflow: hidden;
}

.tn-bloque.tn-bloque-color .tn-bloque-titulo {
    border-bottom-color: rgba(0, 0, 0, 0.12);
}

.tn-bloque.tn-bloque-color .tn-hero time,
.tn-bloque.tn-bloque-color .tn-card time,
.tn-bloque.tn-bloque-color .tn-nota-meta time {
    color: #111;
}

.tn-bloque-titulo {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 0 0 14px;
    padding-bottom: 8px;
    border-bottom: 1px solid #e6e6e6;
}

.tn-bloque-titulo h1,
.tn-bloque-titulo h2,
.tn-nota h1 {
    margin: 0;
    color: #111;
    font-weight: 800;
    letter-spacing: -0.02em;
}

.tn-bloque-titulo h1,
.tn-bloque-titulo h2 {
    font-size: 1.35rem;
    text-transform: uppercase;
}

.tn-bloque-titulo a {
    color: inherit;
    text-decoration: none;
}

.tn-bloque-titulo img {
    height: 32px;
    width: auto;
}

.tn-ver-mas {
    margin-left: auto;
    color: #862b4a;
    font-size: 13px;
    font-weight: 800;
    text-decoration: none;
    text-transform: uppercase;
}

.tn-hero-foto,
.tn-card-foto {
    position: relative;
    display: block;
    background: #ececec;
    overflow: hidden;
}

.tn-apertura {
    display: grid;
    grid-template-columns: minmax(0, 1.7fr) minmax(240px, 0.85fr);
    grid-template-rows: minmax(0, 1fr) minmax(0, 1fr);
    gap: 16px 18px;
    align-items: stretch;
}

.tn-hero {
    grid-row: 1 / span 2;
    display: flex;
    flex-direction: column;
    min-height: 0;
}

.tn-lado {
    display: flex;
    flex-direction: column;
    min-height: 0;
    overflow: hidden;
}

.tn-apertura .tn-hero-foto {
    flex: 1 1 auto;
    aspect-ratio: 4 / 3;
    height: auto;
    max-height: none;
}

.tn-lado .tn-card-foto {
    flex: 1 1 auto;
    height: auto;
    min-height: 0;
    aspect-ratio: auto;
    max-height: none;
}

.tn-lado .tn-card-texto {
    flex: 0 0 auto;
}

.tn-lado h2 {
    font-size: 1.05rem;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.tn-apertura .tn-hero-foto img,
.tn-lado .tn-card-foto img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
}

.tn-card-foto {
    aspect-ratio: 16 / 10;
}

.tn-hero-foto,
.tn-card-foto,
.tn-nota-foto img {
    border-radius: 6px;
}

.tn-hero-foto img,
.tn-card-foto img,
.tn-nota-foto img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.tn-nota-foto img {
    height: auto;
}

.tn-hero-texto,
.tn-card-texto {
    padding-top: 10px;
}

.tn-kicker {
    display: inline-block;
    margin-bottom: 6px;
    color: #862b4a;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    text-decoration: none;
}

.tn-hero h2,
.tn-card h2 {
    margin: 0;
    font-weight: 800;
    line-height: 1.2;
}

.tn-hero h2 {
    font-size: clamp(1.35rem, 2.1vw, 1.9rem);
}

.tn-card h2 {
    font-size: 1.05rem;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    word-break: break-word;
}

.tn-hero h2 a,
.tn-card h2 a {
    color: #111;
    text-decoration: none;
}

.tn-hero h2 a:hover,
.tn-card h2 a:hover {
    color: #862b4a;
}

.tn-bajada {
    margin: 8px 0 0;
    color: #444;
    font-size: 1rem;
    line-height: 1.4;
}

.tn-hero time,
.tn-card time,
.tn-nota-meta time {
    display: block;
    margin-top: 8px;
    color: #333;
    font-size: 13px;
}

.tn-grilla {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 22px 18px;
    margin-top: 18px;
    align-items: stretch;
}

.tn-grilla-2 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.tn-grilla-1 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.tn-grilla .tn-card {
    display: flex;
    flex-direction: column;
    height: 100%;
}

.tn-grilla .tn-card-texto {
    flex: 1 1 auto;
}

.tn-grilla-1 .tn-card-foto {
    aspect-ratio: 16 / 10;
    max-height: none;
}

.tn-aviso {
    margin: 18px 0;
}

.tn-aviso-etiqueta {
    display: block;
    margin-bottom: 6px;
    color: #888;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.tn-aviso img {
    display: block;
    width: 100%;
    height: auto;
}

.tn-lateral {
    position: sticky;
    top: 92px;
}

.tn-nota h1 {
    font-size: clamp(2rem, 4vw, 2.8rem);
    line-height: 1.12;
}

.tn-nota .noticia-comentarios {
    margin-top: 2.5rem;
    margin-bottom: 2rem;
}

.tn-nota .noticia-comentarios .comentario {
    margin-bottom: 1rem;
    padding: 0.85rem 1rem;
    border: 1px solid #e5e5e5;
    border-left: 4px solid #862b4a;
    border-radius: 8px;
    background: #fff;
}

.tn-nota .btn-outline-principal {
    color: #862b4a !important;
    border-color: #862b4a !important;
    background-color: #fff !important;
}

.tn-nota .btn-outline-principal:hover,
.tn-nota .btn-outline-principal:focus,
.tn-nota .btn-outline-principal:active {
    color: #fff !important;
    background-color: #862b4a !important;
    border-color: #862b4a !important;
}

.tn-volanta {
    margin: 0 0 8px;
    color: #862b4a;
    font-size: 14px;
    font-weight: 800;
    text-transform: uppercase;
}

.tn-nota-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    margin: 16px 0;
    padding: 12px 0;
    border-top: 1px solid #ececec;
    border-bottom: 1px solid #ececec;
}

.tn-nota-meta strong {
    display: block;
}

.tn-compartir {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
}

.tn-compartir a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    padding: 0;
    border: 0;
    border-radius: 50%;
    color: #fff !important;
    text-decoration: none !important;
    font-size: 1rem;
    line-height: 1;
    overflow: hidden;
}

.tn-compartir a:hover {
    color: #fff !important;
    opacity: 0.9;
    transform: scale(1.06);
}

.tn-compartir a i {
    margin: 0;
    line-height: 1;
}

.tn-compartir .compartir-facebook  { background-color: #1877F2; }
.tn-compartir .compartir-twitter   { background-color: #000000; }
.tn-compartir .compartir-instagram { background: linear-gradient(45deg, #f09433, #e6683c, #dc2743, #cc2366, #bc1888); }
.tn-compartir .compartir-whatsapp  { background-color: #25D366; }
.tn-compartir .compartir-telegram  { background-color: #0088CC; }

.tn-nota-foto {
    margin: 0 0 18px;
}

.tn-nota-foto figcaption,
.tn-nota .noticia-epigrafe {
    background: #f3f3f3;
    color: #555;
    font-size: 0.92rem;
    font-style: italic;
    padding: 8px 12px;
}

.tn-nota-texto video,
.tn-documento iframe {
    width: 100%;
    border: 0;
}

.tn-nota-texto video {
    display: block;
    margin: 16px 0;
}

.tn-nota-texto .noticia-embed {
    width: 100%;
    max-width: 100%;
    margin: 16px 0;
}

.tn-nota-texto .noticia-embed-media:not(.noticia-embed-mapa) {
    position: relative;
    aspect-ratio: 16 / 9;
    background: #000;
}

.tn-nota-texto .noticia-embed-media:not(.noticia-embed-mapa) iframe {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

.tn-nota-texto .noticia-embed-red,
.tn-nota-texto .noticia-embed-mapa {
    display: flex;
    justify-content: center;
}

.tn-nota-texto .noticia-embed-red iframe,
.tn-nota-texto .noticia-embed-red .instagram-media,
.tn-nota-texto .noticia-embed-red .tiktok-embed,
.tn-nota-texto .noticia-embed-red .fb-post,
.tn-nota-texto .noticia-embed-red .fb-video,
.tn-nota-texto .noticia-embed-mapa iframe {
    max-width: 100%;
    margin-left: auto !important;
    margin-right: auto !important;
}

.tn-documento {
    margin: 24px 0;
    overflow: hidden;
    border: 1px solid #e5e5e5;
    background: #fff;
}

.tn-documento-barra {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    padding: 10px 14px;
    background: #f7f7f7;
    font-weight: 700;
}

.tn-documento-barra a {
    color: #862b4a;
}

.tn-documento iframe {
    height: 600px;
}

.tn-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 18px 0;
}

.tn-tags a {
    background: #862b4a;
    color: #fff;
    font-size: 12px;
    font-weight: 800;
    text-decoration: none;
    text-transform: uppercase;
    padding: 6px 10px;
}

.tn-ultimas {
    margin-top: 28px;
}

.tn-vacio {
    color: #555;
}

.tn-footer {
    background: #862b4a;
    color: #fff;
    margin-top: 20px;
}

.tn-footer-grid {
    display: grid;
    grid-template-columns: 1.2fr 2fr 1fr;
    gap: 24px;
    padding: 28px 0;
}

.tn-footer a {
    color: #fff;
    text-decoration: none;
}

.tn-header .tn-redes a:hover,
.tn-footer .tn-redes a:hover,
.tn-footer-secciones a:hover {
    color: #4a1528;
}

.tn-footer-logo img {
    width: auto;
    max-width: 380px;
    max-height: 120px;
    background: #fff;
    border-radius: 4px;
    padding: 6px 10px;
}

.tn-footer .tn-redes {
    justify-content: flex-end;
}

.tn-footer-secciones {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 16px;
    align-content: flex-start;
}

.tn-footer p {
    margin: 6px 0;
    color: #d5d8e0;
}

.tn-footer-copy {
    padding: 14px 22px 18px;
    border-top: 1px solid rgba(255, 255, 255, 0.12);
    color: #c5c8d0;
    font-size: 13px;
    text-align: center;
}

body.plantilla-tn .sidebar-item,
body.plantilla-tn_foto .sidebar-item {
    background: transparent;
}

body.plantilla-tn .sidebar-item-texto,
body.plantilla-tn_foto .sidebar-item-texto {
    background: transparent !important;
    justify-content: flex-start !important;
    padding-top: 4px !important;
    padding-bottom: 4px !important;
}

body.plantilla-tn .sidebar-item-seccion,
body.plantilla-tn_foto .sidebar-item-seccion {
    margin-bottom: 2px !important;
}

body.plantilla-tn .sidebar-item-titulo,
body.plantilla-tn_foto .sidebar-item-titulo {
    color: #862b4a !important;
    display: -webkit-box !important;
    -webkit-box-orient: vertical !important;
    -webkit-line-clamp: 3 !important;
    line-clamp: 3 !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: normal !important;
    word-break: break-word;
    line-height: 1.2 !important;
    max-height: calc(1.2em * 3);
    margin-top: 0 !important;
}

body.plantilla-tn .sidebar-item-titulo:hover,
body.plantilla-tn_foto .sidebar-item-titulo:hover {
    color: #4a1528 !important;
}

body.plantilla-tn .sidebar-item-seccion a,
body.plantilla-tn_foto .sidebar-item-seccion a {
    background: #862b4a;
    color: #fff;
}

@media (max-width: 900px) {
    .tn-con-lateral,
    .tn-grilla,
    .tn-grilla-2,
    .tn-apertura,
    .tn-footer-grid,
    .tn-barra {
        grid-template-columns: 1fr;
    }

    .tn-apertura {
        grid-template-rows: none;
    }

    .tn-hero,
    .tn-lado {
        display: flex;
        flex-direction: column;
        grid-row: auto;
    }

    .tn-apertura .tn-hero-foto,
    .tn-lado .tn-card-foto,
    .tn-grilla-1 .tn-card-foto {
        aspect-ratio: 16 / 10;
        height: auto;
        max-height: none;
        flex: none;
    }

    .tn-apertura .tn-hero-foto img,
    .tn-lado .tn-card-foto img {
        position: static;
    }

    .tn-ultimas {
        margin-top: 18px;
    }

    .tn-logo {
        justify-self: center;
    }

    .tn-lateral {
        position: static;
    }

    .tn-nota-meta {
        align-items: flex-start;
        flex-direction: column;
    }
}

.tn-header-compacto .tn-barra {
    grid-template-columns: 1fr auto;
    min-height: 0;
    padding: 8px 22px;
}

.tn-header-compacto .tn-logo {
    justify-self: end;
}

.tn-header-compacto .tn-logo img {
    max-width: 150px;
    max-height: 46px;
    padding: 3px 8px;
}

.tn-header-compacto .tn-barra-derecha,
.tn-header-compacto .tn-mercado,
.tn-header-compacto .tn-buscar {
    display: none;
}
