/* ============================================================
   Noticias v4 — portada editorial tipo portal (Infolenca)
   Layout: cabecera + temas + hero con carril + cinta de últimas
   + grilla con carga progresiva + rail de exploración.
   Se carga SOLO en /noticias (después de public.css y front-v2.css).
   ============================================================ */

.nv-page {
    --nv-red: #c8102e;
    --nv-red-ink: #8f0a20;
    --nv-ink: var(--fx-text);
    --nv-muted: var(--fx-muted);
    --nv-line: var(--fx-border);
    --nv-surface: var(--fx-surface);
    --nv-soft: var(--fx-surface-2);
    --nv-radius: 8px;
    background: var(--nv-surface);
    color: var(--nv-ink);
    padding: 0 0 64px;
    font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    -webkit-font-smoothing: antialiased;
}

[data-theme="dark"] .nv-page {
    --nv-red: #ff5a6e;
    --nv-red-ink: #ff8796;
}

@media (prefers-color-scheme: dark) {
    :root:not([data-theme="light"]) .nv-page {
        --nv-red: #ff5a6e;
        --nv-red-ink: #ff8796;
    }
}

.nv-page *,
.nv-page *::before,
.nv-page *::after {
    box-sizing: border-box;
}

.nv-page .fx-container {
    max-width: 1240px;
    padding-inline: clamp(16px, 4vw, 32px);
}

/* ---------- Cabecera de sección ---------- */

.nv-head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 32px;
    padding: 32px 0 20px;
    border-bottom: 3px solid var(--nv-ink);
}

.nv-head__main {
    min-width: 0;
}

.nv-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin: 0 0 10px;
    color: var(--nv-red);
    font-size: .7rem;
    font-weight: 850;
    letter-spacing: .16em;
    text-transform: uppercase;
}

.nv-eyebrow__dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--nv-red);
    animation: nv-pulse 2s ease-out infinite;
}

@keyframes nv-pulse {
    0% { box-shadow: 0 0 0 0 rgba(200, 16, 46, .45); }
    70% { box-shadow: 0 0 0 8px rgba(200, 16, 46, 0); }
    100% { box-shadow: 0 0 0 0 rgba(200, 16, 46, 0); }
}

.nv-head__title {
    margin: 0;
    font-size: clamp(2.7rem, 6vw, 4.3rem);
    font-weight: 900;
    line-height: .9;
    letter-spacing: -.045em;
    color: var(--nv-ink);
}

.nv-head__dek {
    max-width: 62ch;
    margin: 14px 0 0;
    color: var(--nv-muted);
    font-size: 1rem;
    line-height: 1.6;
}

.nv-head__meta {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 3px;
    flex: 0 0 auto;
    color: var(--nv-muted);
    font-size: .76rem;
}

.nv-head__date {
    color: var(--nv-ink);
    font-size: .72rem;
    font-weight: 850;
    letter-spacing: .06em;
    text-transform: uppercase;
}

.nv-head__updated {
    font-weight: 650;
}

.nv-head__rss {
    margin-top: 6px;
    color: var(--nv-red);
    font-size: .68rem;
    font-weight: 850;
    letter-spacing: .12em;
    text-transform: uppercase;
    text-decoration: none;
    border-bottom: 2px solid transparent;
}

.nv-head__rss:hover {
    border-bottom-color: var(--nv-red);
}

/* ---------- Temas ---------- */

.nv-topics {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 13px 0;
    border-bottom: 1px solid var(--nv-line);
}

.nv-topics__label {
    flex: 0 0 auto;
    color: var(--nv-muted);
    font-size: .66rem;
    font-weight: 850;
    letter-spacing: .14em;
    text-transform: uppercase;
}

.nv-topics__scroll {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    overflow: visible;
    padding: 2px 0;
}

.nv-topics__scroll::-webkit-scrollbar {
    display: none;
}

.nv-chip {
    flex: 0 0 auto;
    padding: 6px 12px;
    border: 1px solid var(--nv-line);
    border-radius: 999px;
    color: var(--nv-ink);
    font-size: .75rem;
    font-weight: 750;
    text-decoration: none;
    white-space: nowrap;
    transition: border-color .18s ease, color .18s ease, background .18s ease;
}

.nv-chip:hover {
    border-color: var(--nv-red);
    color: var(--nv-red);
    background: color-mix(in srgb, var(--nv-red) 6%, transparent);
}

/* ---------- Bloque superior ---------- */

.nv-top {
    display: grid;
    grid-template-columns: minmax(0, 2.05fr) minmax(0, 1fr);
    gap: clamp(24px, 3vw, 42px);
    padding: 26px 0 30px;
    border-bottom: 1px solid var(--nv-line);
}

.nv-hero {
    min-width: 0;
}

.nv-hero__media {
    position: relative;
    display: block;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    border-radius: var(--nv-radius);
    background: var(--nv-soft);
}

.nv-hero__media img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .6s cubic-bezier(.22, 1, .36, 1);
}

.nv-hero:hover .nv-hero__media img {
    transform: scale(1.03);
}

.nv-hero__tag {
    position: absolute;
    top: 12px;
    left: 12px;
    padding: 5px 10px;
    border-radius: 2px;
    background: var(--nv-red);
    color: #fff;
    font-size: .63rem;
    font-weight: 850;
    letter-spacing: .1em;
    text-transform: uppercase;
}

.nv-hero__body {
    padding-top: 18px;
}

.nv-kicker {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0;
    font-size: .68rem;
    font-weight: 850;
    letter-spacing: .1em;
    text-transform: uppercase;
}

.nv-kicker a {
    color: var(--nv-red);
    text-decoration: none;
}

.nv-kicker a:hover {
    text-decoration: underline;
    text-underline-offset: 3px;
}

.nv-kicker__sep {
    color: var(--nv-line);
}

.nv-kicker__time {
    color: var(--nv-muted);
    font-weight: 700;
    letter-spacing: .04em;
    text-transform: none;
}

.nv-hero__title {
    margin: 10px 0 0;
    font-size: clamp(1.85rem, 3.6vw, 2.9rem);
    font-weight: 900;
    line-height: 1.02;
    letter-spacing: -.035em;
    text-wrap: balance;
    color: var(--nv-ink);
}

.nv-hero__title a {
    color: inherit;
    text-decoration: none;
}

.nv-hero__title a:hover {
    text-decoration: underline;
    text-decoration-thickness: 3px;
    text-underline-offset: 5px;
}

.nv-hero__dek {
    max-width: 64ch;
    margin: 14px 0 0;
    color: var(--nv-muted);
    font-size: 1.02rem;
    line-height: 1.6;
}

.nv-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 16px;
    margin-top: 16px;
    color: var(--nv-muted);
    font-size: .74rem;
}

.nv-meta span {
    color: var(--nv-ink);
    font-weight: 700;
}

/* Carril de titulares */

.nv-side {
    min-width: 0;
    border-top: 3px solid var(--nv-ink);
    padding-top: 10px;
}

.nv-side__title {
    margin: 0 0 4px;
    color: var(--nv-muted);
    font-size: .68rem;
    font-weight: 850;
    letter-spacing: .14em;
    text-transform: uppercase;
}

.nv-side__list {
    margin: 0;
    padding: 0;
    list-style: none;
}

.nv-side__item {
    border-bottom: 1px solid var(--nv-line);
}

.nv-side__link {
    display: grid;
    grid-template-columns: 106px minmax(0, 1fr);
    gap: 14px;
    align-items: start;
    padding: 14px 0;
    color: inherit;
    text-decoration: none;
}

.nv-side__thumb {
    display: block;
    aspect-ratio: 4 / 3;
    overflow: hidden;
    border-radius: 4px;
    background: var(--nv-soft);
}

.nv-side__thumb img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .45s ease;
}

.nv-side__link:hover .nv-side__thumb img {
    transform: scale(1.06);
}

.nv-side__thumb.is-empty {
    display: grid;
    place-items: center;
    color: var(--nv-red);
    font-size: 1.3rem;
    font-weight: 900;
}

.nv-side__copy {
    display: grid;
    gap: 4px;
    min-width: 0;
}

.nv-side__label {
    color: var(--nv-red);
    font-size: .61rem;
    font-weight: 850;
    letter-spacing: .1em;
    text-transform: uppercase;
}

.nv-side__headline {
    font-size: 1rem;
    font-weight: 800;
    line-height: 1.25;
    letter-spacing: -.015em;
    color: var(--nv-ink);
}

.nv-side__link:hover .nv-side__headline {
    text-decoration: underline;
    text-underline-offset: 3px;
}

.nv-side__time {
    color: var(--nv-muted);
    font-size: .7rem;
}

/* ---------- Cinta de últimas noticias ---------- */

.nv-latest {
    padding: 22px 0 26px;
    border-bottom: 1px solid var(--nv-line);
}

.nv-band {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 16px;
}

.nv-band__title {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0;
    color: var(--nv-ink);
    font-size: 1.42rem;
    font-weight: 900;
    letter-spacing: -.03em;
}

.nv-band__title::before {
    content: "";
    display: block;
    flex: 0 0 auto;
    width: 6px;
    height: 22px;
    background: var(--nv-red);
}

.nv-band__hint {
    color: var(--nv-muted);
    font-size: .66rem;
    font-weight: 800;
    letter-spacing: .12em;
    text-transform: uppercase;
}

.nv-latest__list {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    margin: 0;
    padding: 0;
    list-style: none;
}

.nv-latest__item {
    padding: 0 18px;
    border-left: 1px solid var(--nv-line);
}

.nv-latest__item:first-child {
    padding-left: 0;
    border-left: 0;
}

.nv-latest__item:last-child {
    padding-right: 0;
}

.nv-latest__link {
    display: grid;
    gap: 8px;
    color: inherit;
    text-decoration: none;
}

.nv-latest__top {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px 8px;
    min-width: 0;
}

.nv-latest__time {
    color: var(--nv-red);
    font-size: .72rem;
    font-weight: 850;
    letter-spacing: .04em;
}

.nv-latest__label {
    overflow: hidden;
    color: var(--nv-muted);
    font-size: .61rem;
    font-weight: 800;
    letter-spacing: .1em;
    text-transform: uppercase;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.nv-latest__headline {
    font-size: .97rem;
    font-weight: 750;
    line-height: 1.28;
    letter-spacing: -.01em;
    color: var(--nv-ink);
}

.nv-latest__link:hover .nv-latest__headline {
    text-decoration: underline;
    text-underline-offset: 3px;
}

/* ---------- Cuerpo: grilla + rail ---------- */

.nv-body {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 320px;
    gap: clamp(28px, 4vw, 48px);
    padding-top: 30px;
}

.nv-feed {
    min-width: 0;
}

.nv-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 30px 24px;
}

/* Tarjeta de la grilla (mixed-card) adaptada al nuevo estilo */

.nv-page .mixed-story-card,
.nv-page .mixed-story-card.card {
    height: auto;
    overflow: visible;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
}

.nv-page .mixed-story-media {
    position: relative;
    display: block;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    border-radius: var(--nv-radius);
    background: var(--nv-soft);
}

.nv-page .mixed-story-media img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .5s cubic-bezier(.22, 1, .36, 1);
}

.nv-page .mixed-story-card:hover .mixed-story-media img {
    transform: scale(1.04);
}

.nv-page .mixed-story-content {
    display: block;
    padding: 13px 0 0;
}

.nv-page .mixed-story-topline {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin: 0 0 8px;
}

.nv-page .story-chip-group {
    min-width: 0;
}

.nv-page .mixed-story-badge {
    display: inline-block;
    padding: 0;
    background: none;
    color: var(--nv-red);
    font-size: .63rem;
    font-weight: 850;
    letter-spacing: .1em;
    text-transform: uppercase;
    text-decoration: none;
}

.nv-page .story-format-chip {
    display: none;
}

.nv-page .mixed-story-topline time {
    flex: 0 0 auto;
    color: var(--nv-muted);
    font-size: .68rem;
    font-weight: 700;
    white-space: nowrap;
}

.nv-page .mixed-story-card h2,
.nv-page .mixed-story-card h3 {
    margin: 0 0 8px;
    color: var(--nv-ink);
    font-size: 1.12rem;
    font-weight: 800;
    line-height: 1.22;
    letter-spacing: -.025em;
}

.nv-page .mixed-story-card h2 a,
.nv-page .mixed-story-card h3 a {
    color: inherit;
    text-decoration: none;
}

.nv-page .mixed-story-card h2 a:hover,
.nv-page .mixed-story-card h3 a:hover {
    text-decoration: underline;
    text-underline-offset: 3px;
}

.nv-page .mixed-story-card p {
    display: -webkit-box;
    margin: 0;
    overflow: hidden;
    color: var(--nv-muted);
    font-size: .85rem;
    line-height: 1.5;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.nv-page .mixed-story-meta {
    display: none;
}

.nv-page .mixed-play-badge {
    left: 10px;
    bottom: 10px;
    width: 40px;
    height: 40px;
}

.nv-page .mixed-play-badge svg {
    width: 24px;
    height: 24px;
}

/* Cargar más */

.nv-more {
    display: flex;
    justify-content: center;
    margin-top: 36px;
}

.nv-page .nv-loadmore {
    min-width: 260px;
    padding: 14px 26px;
    border: 2px solid var(--nv-ink);
    border-radius: 3px;
    background: transparent;
    color: var(--nv-ink);
    font: inherit;
    font-size: .73rem;
    font-weight: 850;
    letter-spacing: .1em;
    text-transform: uppercase;
    cursor: pointer;
    transition: background .2s ease, color .2s ease, opacity .2s ease;
}

.nv-page .nv-loadmore:hover:not(:disabled) {
    background: var(--nv-ink);
    color: var(--nv-surface);
}

.nv-page .nv-loadmore:disabled {
    opacity: .45;
    cursor: wait;
}

/* ---------- Rail ---------- */

.nv-rail {
    display: grid;
    gap: 18px;
    align-content: start;
}

.nv-box {
    padding: 20px;
    border-radius: 10px;
    background: var(--nv-soft);
}

.nv-box__title {
    margin: 0 0 12px;
    color: var(--nv-ink);
    font-size: .7rem;
    font-weight: 850;
    letter-spacing: .13em;
    text-transform: uppercase;
}

.nv-box__kicker {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0 0 8px;
    color: var(--nv-red);
    font-size: .64rem;
    font-weight: 850;
    letter-spacing: .12em;
    text-transform: uppercase;
}

.nv-box__dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--nv-red);
    animation: nv-pulse 1.8s ease-out infinite;
}

.nv-box--live {
    background: var(--nv-ink);
    color: var(--fx-bg);
}

.nv-box--live .nv-box__lead {
    margin: 0 0 14px;
    color: var(--fx-bg);
    font-size: .95rem;
    font-weight: 650;
    line-height: 1.5;
    opacity: .92;
}

.nv-box__cta {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding-bottom: 3px;
    border-bottom: 2px solid var(--nv-red);
    color: var(--fx-bg);
    font-size: .78rem;
    font-weight: 850;
    text-decoration: none;
}

.nv-box__cta:hover {
    color: var(--nv-red);
}

.nv-box__text {
    margin: 0;
    color: var(--nv-muted);
    font-size: .86rem;
    line-height: 1.55;
}

.nv-box__link {
    display: inline-block;
    margin-top: 10px;
    color: var(--nv-red);
    font-size: .8rem;
    font-weight: 850;
    text-decoration: none;
}

.nv-box__link:hover {
    text-decoration: underline;
    text-underline-offset: 3px;
}

.nv-links {
    display: grid;
    margin: 0;
    padding: 0;
    list-style: none;
}

.nv-links li + li {
    border-top: 1px solid var(--nv-line);
}

.nv-links a {
    display: block;
    padding: 9px 0;
    color: var(--nv-ink);
    font-size: .88rem;
    font-weight: 700;
    text-decoration: none;
}

.nv-links a:hover {
    color: var(--nv-red);
}

/* ---------- Estados ---------- */

.nv-empty {
    padding: 70px 0;
    color: var(--nv-muted);
    font-size: 1.02rem;
    text-align: center;
}

.nv-empty--inline {
    padding: 30px 0;
}

/* ---------- Responsive ---------- */

@media (max-width: 1080px) {
    .nv-body {
        grid-template-columns: minmax(0, 1fr);
    }

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

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

@media (max-width: 900px) {
    .nv-top {
        grid-template-columns: minmax(0, 1fr);
    }

    .nv-side {
        padding-top: 16px;
        border-top: 1px solid var(--nv-line);
    }

    .nv-side__list {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        column-gap: 24px;
    }

    .nv-latest__list {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        row-gap: 18px;
    }

    .nv-latest__item {
        padding: 0 16px;
    }

    .nv-latest__item:nth-child(odd) {
        padding-left: 0;
        border-left: 0;
    }

    .nv-latest__item:nth-child(even) {
        padding-right: 0;
    }
}

@media (max-width: 900px) {
    .nv-topics__scroll {
        flex-wrap: nowrap;
        overflow-x: auto;
        scrollbar-width: none;
        -webkit-overflow-scrolling: touch;
        mask-image: linear-gradient(90deg, #000 calc(100% - 24px), transparent);
    }

    .nv-topics__scroll::-webkit-scrollbar {
        display: none;
    }
}

@media (max-width: 640px) {
    .nv-head {
        flex-direction: column;
        align-items: flex-start;
        gap: 14px;
        padding-top: 24px;
    }

    .nv-head__meta {
        flex-direction: row;
        flex-wrap: wrap;
        align-items: center;
        gap: 12px;
    }

    .nv-head__rss {
        margin-top: 0;
    }

    .nv-topics {
        gap: 10px;
    }

    .nv-topics__label {
        display: none;
    }

    .nv-side__list {
        grid-template-columns: minmax(0, 1fr);
        column-gap: 0;
    }

    .nv-side__link {
        grid-template-columns: 92px minmax(0, 1fr);
    }

    .nv-latest__list {
        grid-template-columns: minmax(0, 1fr);
        row-gap: 0;
    }

    .nv-latest__item {
        padding: 12px 0;
        border-top: 1px solid var(--nv-line);
        border-left: 0;
    }

    .nv-latest__item:first-child {
        padding-top: 0;
        border-top: 0;
    }

    .nv-grid {
        grid-template-columns: minmax(0, 1fr);
        gap: 26px;
    }

    .nv-rail {
        grid-template-columns: minmax(0, 1fr);
    }

    .nv-band {
        align-items: baseline;
    }

    .nv-page .nv-loadmore {
        width: 100%;
        min-width: 0;
    }
}

@media (prefers-reduced-motion: reduce) {
    .nv-page *,
    .nv-page *::before,
    .nv-page *::after {
        animation: none !important;
        transition: none !important;
    }
}

/* Más aire entre tarjetas e imágenes de /noticias */
.nv-grid {
    gap: 38px 28px;
}
.nv-page .mixed-story-content {
    padding-top: 15px;
}
.nv-google-follow {
    margin: 0 0 28px;
}
@media (max-width: 700px) {
    .nv-grid {
        gap: 32px 20px;
    }
}
