:root {
    --bg: #f2efe8;
    --paper: #fffdf8;
    --ink: #121212;
    --muted: #575757;
    --line: #d9d2c4;
    --accent: #e03515;
    --accent-dark: #911f0d;
    --contrast: #181717;
    --sand: #efe5d7;
    --wrap-max: 1200px;
    --wrap-gutter: clamp(40px, 3.8vw, 84px);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    overflow-x: hidden;
    color: var(--ink);
    background:
        radial-gradient(1100px 420px at 80% -10%, #f5c9a5 0%, rgba(245, 201, 165, 0) 60%),
        radial-gradient(900px 340px at -10% 10%, #fef8db 0%, rgba(254, 248, 219, 0) 62%),
        linear-gradient(180deg, #f6f2ea 0%, #f2efe8 100%);
    font-family: "Segoe UI", Tahoma, sans-serif;
    line-height: 1.5;
}

img,
video,
svg {
    max-width: 100%;
    height: auto;
}

.wrap {
    width: min(var(--wrap-max), calc(100% - (var(--wrap-gutter) * 2)));
    margin: 0 auto;
}

.ad-slot {
    position: relative;
    border: 1px dashed rgba(224, 53, 21, 0.38);
    border-radius: 14px;
    background:
        linear-gradient(135deg, rgba(224, 53, 21, 0.09), rgba(145, 31, 13, 0.04)),
        repeating-linear-gradient(135deg, rgba(224, 53, 21, 0.07) 0 12px, rgba(255, 255, 255, 0.18) 12px 24px);
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 0.28rem;
    padding: 1rem 1.1rem;
    overflow: hidden;
}

.ad-slot::after {
    content: "AD";
    position: absolute;
    top: 0.65rem;
    right: 0.7rem;
    font-size: 2rem;
    font-weight: 900;
    line-height: 1;
    color: rgba(224, 53, 21, 0.09);
    pointer-events: none;
}

.ad-slot-kicker {
    font-size: 0.68rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.9px;
    color: var(--accent);
}

.ad-slot-title {
    font-size: 1rem;
    font-family: "Arial Black", Impact, sans-serif;
    line-height: 1.1;
    color: var(--ink);
}

.ad-slot-format {
    font-size: 0.78rem;
    font-weight: 800;
    color: var(--accent-dark);
    text-transform: uppercase;
    letter-spacing: 0.45px;
}

.ad-slot-copy {
    margin: 0;
    max-width: 38ch;
    font-size: 0.86rem;
    color: var(--muted);
}

.ad-slot-band {
    min-height: 118px;
    margin-top: 0.95rem;
}

.ad-slot-rail {
    min-height: 100%;
    height: 100%;
}

.home-ad {
    position: relative;
    margin-top: 0.95rem;
}

.home-ad-link {
    position: relative;
    display: block;
    border-radius: 14px;
    overflow: hidden;
}

.home-ad-link.is-static {
    cursor: default;
}

.home-ad-image {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
}

.home-ad-badge {
    display: none;
}

.home-ad-band .home-ad-link {
    min-height: 118px;
}

.home-ad-rail {
    margin-top: 0;
}

.home-ad-rail .home-ad-link {
    height: 100%;
    min-height: 340px;
}

.home-ad-html {
    position: relative;
    border-radius: 14px;
    overflow: hidden;
}

.home-ad-html .home-ad-badge {
    position: relative;
    top: auto;
    left: auto;
    display: inline-flex;
    margin-bottom: 0.4rem;
}

.home-ad-image video,
.home-ad-link video {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
}

.home-popup {
    position: fixed;
    inset: 0;
    z-index: 1200;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
}

.home-popup.is-hidden {
    display: none;
}

.home-popup-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(7, 12, 20, 0.72);
    backdrop-filter: blur(4px);
}

.home-popup-card {
    position: relative;
    z-index: 1;
    width: min(560px, calc(100vw - 48px));
    max-height: calc(100vh - 80px);
    overflow: hidden;
    border-radius: 20px;
    background: #0f1722;
    border: 1px solid rgba(255, 255, 255, 0.12);
    box-shadow: 0 24px 80px rgba(0, 0, 0, 0.42);
}

.home-popup-close {
    position: absolute;
    top: 12px;
    right: 12px;
    z-index: 2;
    border: 0;
    border-radius: 999px;
    padding: 10px 14px;
    background: rgba(255, 255, 255, 0.92);
    color: #111827;
    font: inherit;
    cursor: pointer;
}

.home-popup-link,
.home-popup-media {
    display: block;
}

.home-popup-link {
    width: 100%;
    padding: 18px 18px 20px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.home-popup-media {
    width: 100%;
    max-height: min(68vh, 520px);
    border-radius: 14px;
    object-fit: contain;
    object-position: center;
    background: #0b1220;
}

.home-popup-body-html {
    max-height: calc(100vh - 130px);
    overflow: auto;
    padding: 56px 18px 18px;
}

@media (max-width: 640px) {
    .home-popup {
        padding: 14px;
    }

    .home-popup-card {
        width: calc(100vw - 20px);
        max-height: calc(100vh - 24px);
        border-radius: 16px;
    }

    .home-popup-close {
        top: 10px;
        right: 10px;
        padding: 8px 12px;
    }

    .home-popup-link {
        padding: 14px 14px 16px;
    }

    .home-popup-media {
        max-height: 62vh;
        border-radius: 12px;
    }
}

.site-banner {
    display: none;
    background-color: var(--contrast);
    position: relative;
    overflow: hidden;
    min-height: 240px;
}

.site-banner.has-bg {
    display: block;
    background-size: cover;
    background-position: center;
}

.site-banner.has-left-image {
    display: block;
}

.site-banner.has-center-image {
    display: block;
}

.site-banner.has-right1-image {
    display: block;
}

.site-banner.has-right2-image {
    display: block;
}

.banner-inner {
    position: relative;
    height: 100%;
    min-height: 240px;
}

.banner-left-image {
    position: absolute;
    left: clamp(0.35rem, 1.5vw, 1.2rem);
    top: 50%;
    transform: translateY(-50%);
    height: auto;
    width: clamp(188px, 35vw, 760px);
    max-height: 92%;
    max-width: none;
    object-fit: contain;
    filter: drop-shadow(0 3px 10px rgba(0, 0, 0, 0.45));
    pointer-events: none;
}

.banner-center-image {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    height: 88%;
    width: auto;
    max-width: clamp(95px, 18vw, 400px);
    object-fit: contain;
    filter: drop-shadow(0 3px 10px rgba(0, 0, 0, 0.45));
    pointer-events: none;
}

.banner-right1-image {
    position: absolute;
    right: calc(clamp(95px, 18vw, 400px) + clamp(0.7rem, 3vw, 2.4rem));
    top: 50%;
    transform: translateY(-50%);
    height: 88%;
    width: auto;
    max-width: clamp(95px, 18vw, 400px);
    object-fit: contain;
    filter: drop-shadow(0 3px 10px rgba(0, 0, 0, 0.45));
    pointer-events: none;
}

.banner-right1-link {
    position: absolute;
    right: calc(clamp(95px, 18vw, 400px) + clamp(0.7rem, 3vw, 2.4rem));
    top: 50%;
    transform: translateY(-50%);
    height: 88%;
    width: auto;
    max-width: clamp(95px, 18vw, 400px);
    display: block;
    z-index: 3;
    transition: transform 0.18s ease;
}

.banner-right1-link .banner-right1-image {
    position: static;
    transform: none;
    height: 100%;
    width: auto;
    max-width: 100%;
    display: block;
    object-fit: contain;
    filter: drop-shadow(0 3px 10px rgba(0, 0, 0, 0.45));
    pointer-events: none;
}

.banner-right1-link:hover,
.banner-right1-link:focus-visible {
    transform: translateY(-50%) scale(1.03);
}

.banner-right2-image {
    position: absolute;
    right: clamp(0.35rem, 1.5vw, 1.2rem);
    top: 36%;
    transform: translateY(-50%);
    height: 76%;
    width: auto;
    max-width: clamp(70px, 12vw, 240px);
    object-fit: contain;
    filter: drop-shadow(0 3px 10px rgba(0, 0, 0, 0.45));
    pointer-events: none;
}

.nav {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.85rem;
    font-size: 0.95rem;
}

.nav a {
    text-decoration: none;
    color: var(--ink);
    font-weight: 700;
    min-width: 0;
}

.nav a:hover {
    color: var(--accent);
}

.nav .ad-slot-kicker {
    color: var(--accent);
}

/* =====================================================
   MEDIA QUERIES - RESPONSIVE (NOTEBOOKS, PC, TABLETS)
   ===================================================== */

@media (max-width: 1366px) {
    .site-banner, .banner-inner {
        min-height: 200px;
    }
    .banner-center-image {
        max-width: 14vw;
    }
    .banner-right1-image, .banner-right1-link {
        max-width: 14vw;
    }
    .portada-grid {
        height: 440px;
    }
}

@media (max-width: 1024px) {
    .site-banner, .banner-inner {
        min-height: 160px;
    }
    .banner-left-image {
        width: 30vw;
    }
    .banner-right2-image {
        display: none; /* Hide smaller image to save space on small screens */
    }
    .portada-grid {
        grid-template-columns: 1fr;
        height: auto;
        grid-auto-rows: minmax(280px, auto);
    }
    .pg-left {
        grid-template-rows: 280px 280px;
    }
    .pg-right {
        grid-template-rows: 280px 220px;
    }
}

@media (max-width: 768px) {
    .site-banner, .banner-inner {
        min-height: 130px;
    }
    .banner-center-image {
        max-width: 20vw;
    }
    .banner-right1-image, .banner-right1-link {
        display: none; /* Hide if screen is too small and might overlap */
    }
    .pg-left, .pg-right {
        grid-template-rows: auto;
        grid-auto-rows: 240px;
    }
    .pg-small-row {
        grid-template-columns: 1fr;
        grid-auto-rows: 240px;
    }
}

.btn-panel {
    border-radius: 999px;
    padding: 0.4rem 0.85rem;
    background: var(--contrast);
    color: #fff !important;
}

.ticker {
    margin-top: 0.85rem;
    border: 1px solid #262626;
    border-radius: 10px;
    background: #101010;
    color: #fff;
    display: flex;
        align-items: stretch;
    overflow: hidden;
    min-height: 42px;
}

.ticker-tag {
    background: var(--accent);
    color: #fff;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.7px;
    font-size: 0.74rem;
    display: grid;
    place-items: center;
        flex: 0 0 auto;
    padding: 0 0.9rem;
    white-space: nowrap;
}

.ticker-track {
    display: flex;
    align-items: center;
    flex: 0 0 auto;
    gap: 2.2rem;
    min-width: max-content;
    width: max-content;
    padding: 0 1rem;
    white-space: nowrap;
    animation: ticker 20s linear infinite;
}

.ticker-marquee {
    flex: 1 1 auto;
    min-width: 0;
    overflow: hidden;
    display: flex;
    align-items: center;
}

.ticker-track span,
.ticker-track a {
    opacity: 0.95;
    color: #fff;
    text-decoration: none;
    font-weight: 600;
}

.ticker-track a:hover {
    opacity: 1;
    text-decoration: underline;
}

.countdown-wrap {
    margin-top: 0.85rem;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.75rem;
}

.countdown-card {
    border: 1px solid var(--line);
    border-radius: 12px;
    background: var(--paper);
    padding: 0.8rem;
    display: grid;
    grid-template-columns: minmax(0, 1fr) clamp(110px, 15vw, 160px);
    gap: 0.8rem;
    align-items: center;
}

.countdown-body h3 {
    margin: 0;
    font-size: 1rem;
    line-height: 1.25;
    font-family: "Arial Black", Impact, sans-serif;
}

.countdown-body p {
    margin: 0.35rem 0 0;
    color: #343434;
    font-weight: 600;
}

.countdown-date {
    margin-top: 0.35rem;
    font-size: 0.8rem;
    color: var(--muted);
}

.countdown-time {
    margin-top: 0.55rem;
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
}

.countdown-time span {
    min-width: 70px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
    display: grid;
    justify-items: center;
    padding: 0.35rem 0.45rem;
    font-size: 0.72rem;
    text-transform: uppercase;
    color: #454545;
    font-weight: 700;
}

.countdown-time b {
    font-size: 1.02rem;
    line-height: 1;
    color: var(--accent-dark);
}

.countdown-logo {
    width: 100%;
    min-height: 104px;
    border: 1px dashed #b6ad9c;
    border-radius: 10px;
    display: grid;
    place-items: center;
    background: #f9f4ec;
    color: #7d7466;
    font-size: 0.76rem;
    font-weight: 800;
    overflow: hidden;
    padding: 0.45rem;
}

.countdown-logo img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center;
}

@keyframes ticker {
    from {
        transform: translateX(0);
    }

    to {
        transform: translateX(-50%);
    }
}

.programacion-showcase {
    margin-top: 0.78rem;
    border-radius: 16px;
    overflow: hidden;
    position: relative;
    padding: clamp(0.72rem, 1.7vw, 1.08rem);
    background:
        radial-gradient(70% 70% at 50% 0%, rgba(255, 255, 255, 0.18), rgba(255, 255, 255, 0) 72%),
        linear-gradient(135deg, #292f3a 0%, #141925 100%);
    background-size: cover;
    background-position: center;
    border: 1px solid rgba(255, 255, 255, 0.14);
}

.programacion-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom, rgba(9, 13, 22, 0.38), rgba(9, 13, 22, 0.7));
    pointer-events: none;
}

.programacion-content {
    position: relative;
    z-index: 1;
}

.programacion-center-logo-wrap {
    display: grid;
    justify-items: center;
    margin-bottom: 0.6rem;
}

.programacion-center-logo {
    width: min(100%, 460px);
    max-height: 108px;
    object-fit: contain;
    filter: drop-shadow(0 8px 24px rgba(0, 0, 0, 0.35));
}

.programacion-top-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 0.6rem;
}

.programacion-top-card {
    border-radius: 10px;
    padding: 0.62rem 0.62rem;
    color: #fff;
    background: var(--programacion-card-bg, #2f80ed);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
    text-align: center;
}

.programacion-top-card h3 {
    margin: 0;
    font-size: 0.96rem;
    font-family: "Arial Black", Impact, sans-serif;
    line-height: 1.1;
}

.programacion-top-card p {
    margin: 0.28rem 0 0;
    font-size: 0.9rem;
    font-weight: 700;
    line-height: 1.2;
}

.programacion-media-grid {
    margin-top: 0.66rem;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 0.56rem;
}

.programacion-media-card {
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.18);
    background: rgba(255, 255, 255, 0.1);
    padding: 0.5rem;
    backdrop-filter: blur(2px);
}

.programacion-media-image-wrap {
    border-radius: 9px;
    overflow: hidden;
    background: transparent;
}

.programacion-media-image {
    width: 100%;
    height: 92px;
    object-fit: contain;
    display: block;
    background: transparent;
}

.programacion-media-desc {
    margin: 0.42rem 0 0;
    color: #fff;
    text-align: center;
    font-size: 0.82rem;
    font-weight: 800;
    line-height: 1.2;
}

/* =====================================================
   PORTADA GRID — 2 grandes + 1 mediana + 2 pequeñas
   ===================================================== */
.portada-grid {
    margin-top: 1rem;
    display: grid;
    grid-template-columns: 1.62fr 1fr;
    gap: 0.5rem;
    height: 520px;
}

.pg-left {
    display: grid;
    grid-template-rows: 1fr 1fr;
    gap: 0.5rem;
}

.pg-right {
    display: grid;
    grid-template-rows: 1.12fr 0.88fr;
    gap: 0.5rem;
}

.pg-small-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.5rem;
}

.pg-main,
.pg-medium,
.pg-small {
    position: relative;
    border-radius: 10px;
    overflow: hidden;
    background: #181818;
}

.pg-card-link {
    position: absolute;
    inset: 0;
    z-index: 3;
}

.pg-img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.4s ease;
}

.pg-main:hover .pg-img,
.pg-medium:hover .pg-img,
.pg-small:hover .pg-img {
    transform: scale(1.04);
}

.pg-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 1rem 1.1rem;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.85) 0%, rgba(0, 0, 0, 0.4) 55%, rgba(0, 0, 0, 0.05) 100%);
    color: #fff;
}

.pg-badge {
    display: inline-block;
    background: var(--accent);
    color: #fff;
    font-size: 0.64rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    padding: 0.2rem 0.5rem;
    border-radius: 4px;
    margin-bottom: 0.38rem;
    align-self: flex-start;
}

.pg-date {
    font-size: 0.72rem;
    font-weight: 700;
    color: #f5c8b0;
    margin-bottom: 0.28rem;
    display: block;
}

.pg-title-main {
    margin: 0;
    font-size: clamp(1.15rem, 2vw, 1.8rem);
    font-family: "Arial Black", Impact, sans-serif;
    text-transform: uppercase;
    line-height: 1.1;
    letter-spacing: 0.3px;
    max-width: 22ch;
}

.pg-desc {
    margin: 0.5rem 0 0;
    font-size: 0.87rem;
    color: #ececec;
    max-width: 55ch;
    line-height: 1.4;
}

.pg-title-med {
    margin: 0;
    font-size: clamp(0.9rem, 1.4vw, 1.2rem);
    font-family: "Arial Black", Impact, sans-serif;
    text-transform: uppercase;
    line-height: 1.15;
    letter-spacing: 0.2px;
}

.pg-title-sm {
    margin: 0;
    font-size: clamp(0.75rem, 1.1vw, 0.98rem);
    font-family: "Arial Black", Impact, sans-serif;
    text-transform: uppercase;
    line-height: 1.15;
    letter-spacing: 0.1px;
}

/* Overlay padding reducido en tarjetas chicas */
.pg-small .pg-overlay {
    padding: 0.7rem 0.8rem;
}

.pg-medium .pg-overlay {
    padding: 0.85rem 0.95rem;
}

/* ===================================================== */

.hero {
    margin-top: 0.95rem;
    display: grid;
    grid-template-columns: 1.55fr 1fr;
    gap: 1rem;
}

.hero-lead {
    min-height: 420px;
    border-radius: 16px;
    overflow: hidden;
    border: 1px solid #2c2c2c;
    color: #fff;
    background:
        linear-gradient(to top, rgba(0, 0, 0, 0.72), rgba(0, 0, 0, 0.06)),
        radial-gradient(120% 90% at 15% 20%, rgba(255, 141, 83, 0.8), rgba(255, 141, 83, 0.02)),
        linear-gradient(120deg, #4f4f4f, #181818 65%);
    padding: 1.3rem;
    display: flex;
    align-items: flex-end;
    position: relative;
    overflow: hidden;
}

.hero-lead.has-custom-bg {
    background:
        linear-gradient(to top, rgba(0, 0, 0, 0.72), rgba(0, 0, 0, 0.2)),
        var(--hero-bg-image),
        radial-gradient(120% 90% at 15% 20%, rgba(255, 141, 83, 0.8), rgba(255, 141, 83, 0.02)),
        linear-gradient(120deg, #4f4f4f, #181818 65%);
    background-size: cover, cover, auto, auto;
    background-position: center center, center center, center, center;
}

.hero-lead.has-news-image {
    background:
        radial-gradient(120% 90% at 15% 20%, rgba(255, 141, 83, 0.52), rgba(255, 141, 83, 0.02)),
        linear-gradient(120deg, #4f4f4f, #181818 65%);
}

.hero-news-image {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 0;
}

.hero-lead.has-news-image::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.78), rgba(0, 0, 0, 0.2));
    z-index: 1;
}

.hero-lead.has-left-image > div {
    margin-left: clamp(110px, 16vw, 250px);
}

.hero-left-image {
    position: absolute;
    left: 1rem;
    bottom: 1rem;
    width: clamp(95px, 14vw, 220px);
    max-height: calc(100% - 2rem);
    object-fit: contain;
    z-index: 1;
    filter: drop-shadow(0 10px 22px rgba(0, 0, 0, 0.35));
}

.hero-lead > div {
    position: relative;
    z-index: 2;
}

.hero-lead::after {
    content: "";
    position: absolute;
    right: -80px;
    bottom: -80px;
    width: 220px;
    height: 220px;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, 0.3);
    z-index: 2;
}

.lead-kicker {
    display: inline-block;
    padding: 0.28rem 0.55rem;
    border-radius: 5px;
    font-size: 0.7rem;
    background: var(--accent);
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 700;
}

.hero-lead h1 {
    margin: 0.65rem 0 0;
    font-size: clamp(1.65rem, 3vw, 2.7rem);
    line-height: 1.08;
    max-width: 18ch;
    font-family: "Arial Black", Impact, sans-serif;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.hero-lead p {
    margin: 0.7rem 0 0;
    max-width: 60ch;
    color: #f4f4f4;
}

.lead-meta {
    margin-top: 0.7rem;
    color: #f7cdbe;
    font-size: 0.82rem;
    font-weight: 700;
}

.hero-side {
    display: grid;
    gap: 1rem;
}

.box {
    background: var(--paper);
    border: 1px solid var(--line);
    border-radius: 14px;
    padding: 1rem;
}

.box h2 {
    margin: 0 0 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-size: 0.95rem;
    border-left: 4px solid var(--accent);
    padding-left: 0.5rem;
    font-family: "Arial Black", Impact, sans-serif;
}

.events {
    margin: 0;
    padding: 0;
    list-style: none;
    display: grid;
    gap: 0.5rem;
}

.events li {
    border: 1px solid var(--line);
    border-radius: 9px;
    padding: 0.65rem;
    background: #fff;
}

.events b {
    display: block;
    font-size: 0.92rem;
}

.events span {
    color: var(--muted);
    font-size: 0.86rem;
}

.quick-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.55rem;
}

.quick {
    min-height: 72px;
    border-radius: 10px;
    border: 1px solid var(--line);
    background: linear-gradient(140deg, #f2e8d8, #fdfbf7);
    padding: 0.5rem;
    font-size: 0.82rem;
    font-weight: 700;
    color: #3d3d3d;
    display: flex;
    align-items: flex-end;
}

.main-grid {
    margin: 1rem 0 2.2rem;
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
}

.main-menu-wrapper {
    margin-top: 1rem;
    background: var(--paper);
    border: 1px solid var(--line);
    border-radius: 14px;
    overflow: visible;
    position: relative;
    z-index: 10;
}

.main-menu {
    margin: 0;
    padding: 0.4rem;
    list-style: none;
    display: flex;
    flex-wrap: nowrap;
    gap: 0.4rem;
}

.menu-item {
    position: static;
    flex: 1 1 0;
    min-width: 0;
}

.menu-label {
    width: 100%;
    border: 1px solid var(--line);
    border-radius: 9px;
    padding: clamp(0.22rem, calc(0.56rem - (var(--menu-count, 6) * 0.011rem)), 0.5rem) 0.34rem;
    background: linear-gradient(180deg, #fff, #f7f2e8);
    color: var(--ink);
    font-size: clamp(0.5rem, calc(1rem - (var(--menu-count, 6) * 0.028rem)), 0.82rem);
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.2px;
    text-align: center;
    cursor: pointer;
    font-family: inherit;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    line-height: 1.1;
}

.main-menu.menu-density-medium .menu-label {
    letter-spacing: 0.1px;
}

.main-menu.menu-density-compact .menu-label {
    letter-spacing: 0;
}

.main-menu.menu-density-ultra .menu-label {
    font-size: 0.48rem;
    padding: 0.2rem 0.26rem;
    letter-spacing: 0;
}

.menu-label:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 1px;
}

.menu-item:hover .menu-label,
.menu-item:focus-within .menu-label,
.menu-item.is-open .menu-label {
    border-color: var(--accent);
    color: var(--accent);
    background: #fff;
}

.menu-dropdown {
    position: absolute;
    top: calc(100% + 0.4rem);
    left: 0.4rem;
    right: 0.4rem;
    width: auto;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 12px;
    box-shadow: 0 16px 36px rgba(0, 0, 0, 0.13);
    padding: 0.85rem;
    opacity: 0;
    visibility: hidden;
    transform: translateY(8px);
    transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s;
    pointer-events: none;
}

.menu-item:hover .menu-dropdown,
.menu-item:focus-within .menu-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    pointer-events: auto;
}

.menu-dropdown h3 {
    margin: 0 0 0.55rem;
    font-size: 0.88rem;
    font-family: "Arial Black", Impact, sans-serif;
    text-transform: uppercase;
    color: var(--accent-dark);
    letter-spacing: 0.4px;
}

.menu-news-cards {
    margin: 0;
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 0.7rem;
}

.menu-news-card {
    border: 1px solid var(--line);
    border-radius: 10px;
    background: linear-gradient(180deg, #ffffff, #fcfaf6);
    padding: 0.5rem;
    display: grid;
    gap: 0.45rem;
}

.menu-news-card-link {
    color: inherit;
    text-decoration: none;
    display: grid;
    gap: 0.45rem;
}

.menu-news-card-image,
.menu-news-card-no-image {
    width: 100%;
    height: 170px;
    border-radius: 8px;
    border: 1px solid #dcd4c6;
}

.menu-news-card-image {
    object-fit: cover;
    display: block;
}

.menu-news-card-no-image {
    display: grid;
    place-items: center;
    background: #f2ece0;
    color: #6f6658;
    font-size: 0.84rem;
    font-weight: 700;
}

.menu-news-card h4 {
    margin: 0;
    font-size: 0.95rem;
    line-height: 1.2;
    font-family: "Arial Black", Impact, sans-serif;
    color: #1f1f1f;
}

.menu-news-card p {
    margin: 0;
    font-size: 0.82rem;
    color: #4b4b4b;
    line-height: 1.35;
}

.menu-news-card time {
    font-size: 0.76rem;
    color: #6a6258;
    font-weight: 700;
}

.menu-empty {
    margin: 0;
    border: 1px dashed var(--line);
    border-radius: 8px;
    background: var(--sand);
    padding: 0.55rem;
    font-size: 0.8rem;
}

.panel {
    background: var(--paper);
    border: 1px solid var(--line);
    border-radius: 15px;
    padding: 1rem;
}

.news-panel {
    min-width: 0;
}

.panel-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 0.8rem;
    border-bottom: 1px dashed var(--line);
    padding-bottom: 0.55rem;
}

.panel-head h2 {
    margin: 0;
    font-size: 1.05rem;
    text-transform: uppercase;
    font-family: "Arial Black", Impact, sans-serif;
    letter-spacing: 0.5px;
}

.panel-head small {
    color: var(--muted);
    font-weight: 700;
}

.news-grid {
    display: grid;
    gap: 0.75rem;
}

.news-card {
    border: 1px solid var(--line);
    border-radius: 12px;
    background: #fff;
    padding: 0.85rem;
    transform: translateY(6px);
    opacity: 0;
    animation: reveal 0.5s ease forwards;
}

.news-card-link {
    color: inherit;
    text-decoration: none;
    display: block;
}

.news-card:nth-child(2) {
    animation-delay: 0.08s;
}

.news-card:nth-child(3) {
    animation-delay: 0.16s;
}

.news-card:nth-child(4) {
    animation-delay: 0.24s;
}

.news-card:nth-child(5) {
    animation-delay: 0.32s;
}

.news-card:nth-child(6) {
    animation-delay: 0.4s;
}

@keyframes reveal {
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.news-card time {
    color: var(--muted);
    font-size: 0.79rem;
    font-weight: 700;
}

.news-card-image {
    width: 100%;
    height: 180px;
    object-fit: cover;
    border-radius: 8px;
    margin-bottom: 0.55rem;
    border: 1px solid var(--line);
}

.news-card h3 {
    margin: 0.35rem 0;
    font-size: 1.03rem;
    line-height: 1.25;
}

.news-card p {
    margin: 0;
    color: #333;
}

.news-card small {
    display: block;
    margin-top: 0.45rem;
    color: var(--muted);
    font-size: 0.78rem;
    font-weight: 700;
}

/* =============================================================
   CATEGORY SECTIONS — tarjetas contenedoras por categoría
   ============================================================= */

.cat-sections {
    margin: 1.2rem auto 2rem;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    width: 100%;
}

.cat-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 1rem;
    align-items: start;
}

.cat-layout.has-global-rail {
    grid-template-columns: minmax(0, 1fr) clamp(260px, 23vw, 340px);
}

.cat-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    min-width: 0;
}

.cat-block {
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid var(--line);
    background: var(--paper);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.07);
}

/* Cabecera roja */
.cat-header {
    background: var(--accent);
    padding: 0.5rem 1rem;
}

.cat-title {
    margin: 0;
    color: #fff;
    font-size: 0.95rem;
    font-family: "Arial Black", Impact, sans-serif;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.6px;
}

.cat-inner {
    padding: 0.9rem;
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
}

.cat-global-rail {
    min-width: 0;
    width: 100%;
    max-width: clamp(260px, 23vw, 340px);
    justify-self: end;
    align-self: start;
}

@media (min-width: 1400px) {
    .wrap {
        width: calc(100% - 240px);
        max-width: 1360px;
    }

    .cat-layout.has-global-rail {
        grid-template-columns: minmax(0, 1fr) clamp(280px, 22vw, 360px);
        gap: 1.1rem;
    }

    .cat-global-rail {
        max-width: clamp(280px, 22vw, 360px);
    }

    .banner-left-image {
        width: clamp(250px, 38vw, 860px);
        max-height: 94%;
    }
}

.cat-global-rail .home-ad-rail {
    margin-top: 0;
    width: 100%;
    max-width: 100%;
}

.cat-global-rail .home-ad + .home-ad {
    margin-top: 0.75rem;
}

.cat-global-rail .home-ad-rail .home-ad-link {
    width: 100%;
    max-width: 100%;
    height: auto;
    min-height: 0;
    aspect-ratio: auto;
    background: #d9d2c4;
}

.cat-global-rail .home-ad-rail .home-ad-image,
.cat-global-rail .home-ad-rail video {
    width: 100%;
    height: auto;
    object-fit: contain;
}

.cat-global-rail .home-ad-html {
    width: 100%;
    max-width: 100%;
    overflow: hidden;
}

.cat-global-rail .home-ad-html iframe,
.cat-global-rail .home-ad-html embed,
.cat-global-rail .home-ad-html object,
.cat-global-rail .home-ad-html img,
.cat-global-rail .home-ad-html video {
    max-width: 100% !important;
}

.cat-main-column {
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
    min-width: 0;
}

.cat-content {
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
    min-width: 0;
}

/* --- Fila destacada: miniaturas + artículo principal --- */
.cat-feature-grid {
    display: grid;
    grid-template-columns: 210px 1fr;
    gap: 0.8rem;
    align-items: stretch;
}

/* Pila de miniaturas (izquierda) */
.cat-thumb-stack {
    display: grid;
    grid-template-rows: 1fr 1fr;
    gap: 0.4rem;
    height: 270px;
}

.cat-thumb-item {
    position: relative;
    display: block;
    overflow: hidden;
    border-radius: 8px;
    background: #111;
}

.cat-thumb-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.35s ease;
}

.cat-thumb-item:hover img {
    transform: scale(1.06);
}

.cat-thumb-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.72));
    color: #fff;
    font-size: 0.7rem;
    font-weight: 800;
    text-transform: uppercase;
    padding: 0.6rem 0.5rem 0.28rem;
    letter-spacing: 0.5px;
}

.cat-thumb-no-img {
    width: 100%;
    height: 100%;
    display: grid;
    place-items: center;
    background: #2a2a2a;
    color: #888;
    font-size: 0.8rem;
    padding: 0.4rem;
    text-align: center;
}

/* Artículo destacado (derecha) */
.cat-feature-main {
    display: flex;
    flex-direction: column;
    gap: 0;
    background: var(--accent);
    border-radius: 10px;
    overflow: hidden;
    color: #fff;
    height: 270px; /* igual que .cat-thumb-stack */
}

.cat-feature-img-wrap {
    display: block;
    height: 120px;
    overflow: hidden;
    flex-shrink: 0;
}

.cat-feature-img-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.35s ease;
}

.cat-feature-main:hover .cat-feature-img-wrap img {
    transform: scale(1.04);
}

.cat-feature-body {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    padding: 1rem 1.2rem 1.1rem;
    flex: 1;
}

.cat-feature-meta {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    font-size: 0.78rem;
    color: rgba(255, 255, 255, 0.82);
    font-weight: 700;
}

.cat-feature-author::before {
    content: "✍ ";
}

.cat-feature-meta time::before {
    content: "🗓 ";
}

.cat-feature-title {
    margin: 0;
    font-size: clamp(1.05rem, 2.1vw, 1.5rem);
    font-family: "Arial Black", Impact, sans-serif;
    line-height: 1.1;
    text-transform: uppercase;
    letter-spacing: 0.2px;
}

.cat-feature-title a {
    text-decoration: none;
    color: inherit;
}

.cat-feature-title a:hover {
    text-decoration: underline;
}

.cat-feature-desc {
    margin: 0;
    font-size: 0.9rem;
    line-height: 1.5;
    color: rgba(255, 255, 255, 0.9);
    flex: 1;
}

.cat-read-more {
    display: inline-block;
    align-self: flex-start;
    background: #fff;
    color: var(--accent);
    font-weight: 900;
    font-size: 0.86rem;
    padding: 0.38rem 0.85rem;
    border-radius: 5px;
    text-decoration: none;
    letter-spacing: 0.3px;
    margin-top: 0.2rem;
    transition: background 0.18s, color 0.18s;
}

.cat-read-more:hover {
    background: #1a1a1a;
    color: #fff;
}

/* --- Fila inferior: tarjetas compactas --- */
.cat-row-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.6rem;
}

.cat-row-card {
    border: 1px solid var(--line);
    border-radius: 8px;
    overflow: hidden;
    background: var(--paper);
    transition: border-color 0.18s, box-shadow 0.18s;
}

.cat-row-card:hover {
    border-color: var(--accent);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.cat-row-link {
    display: flex;
    flex-direction: column;
    text-decoration: none;
    color: var(--ink);
    height: 100%;
}

.cat-row-img-wrap {
    height: 105px;
    overflow: hidden;
}

.cat-row-img-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.3s ease;
}

.cat-row-card:hover .cat-row-img-wrap img {
    transform: scale(1.05);
}

.cat-row-text {
    padding: 0.5rem 0.6rem;
    display: flex;
    flex-direction: column;
    gap: 0.22rem;
    flex: 1;
}

.cat-row-text time {
    font-size: 0.7rem;
    font-weight: 700;
    color: var(--accent);
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.cat-row-text h4 {
    margin: 0;
    font-size: 0.84rem;
    font-weight: 800;
    line-height: 1.3;
    color: var(--ink);
}

/* =============================================================
   FIN CATEGORY SECTIONS
   ============================================================= */

.empty {
    border: 1px dashed var(--line);
    border-radius: 12px;
    background: var(--sand);
    padding: 1rem;
}

.final-widgets {
    position: relative;
    background:
        radial-gradient(circle at 12% 8%, rgba(255, 210, 64, 0.24), transparent 42%),
        radial-gradient(circle at 88% 84%, rgba(46, 229, 192, 0.2), transparent 46%),
        linear-gradient(135deg, #071826 0%, #0b2436 40%, #111f2d 100%);
    color: #edf5ff;
    border-top: 2px solid #ffd240;
    border-bottom: 2px solid #2ee5c0;
    padding: 2.1rem 0;
    overflow: hidden;
}

.final-widgets::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image: linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px), linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
    background-size: 24px 24px;
    pointer-events: none;
}

.final-grid {
    display: grid;
    grid-template-columns: minmax(0, 2fr) minmax(210px, 1fr) minmax(210px, 1fr);
    gap: 1rem;
}

.final-block {
    min-width: 0;
    position: relative;
    z-index: 1;
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 14px;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.09), rgba(255, 255, 255, 0.04));
    backdrop-filter: blur(2px);
    padding: 0.9rem;
}

.final-title {
    margin: 0 0 0.9rem;
    display: flex;
    align-items: center;
    gap: 0.65rem;
    font-size: 1rem;
    font-family: "Trebuchet MS", "Arial Black", sans-serif;
    letter-spacing: 0.4px;
    text-transform: uppercase;
    color: #f8fbff;
}

.final-title::before {
    content: "";
    width: 36px;
    height: 3px;
    border-radius: 999px;
    background: linear-gradient(90deg, #ffd240, #ff8a00);
    opacity: 1;
}

.final-sponsor-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.65rem;
}

.final-sponsor-card {
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 10px;
    background: rgba(7, 24, 38, 0.55);
    overflow: hidden;
    transition: transform 0.2s ease, border-color 0.2s ease;
}

.final-sponsor-card:hover {
    transform: translateY(-2px);
    border-color: rgba(255, 210, 64, 0.72);
}

.final-sponsor-card a,
.final-sponsor-card img {
    display: block;
    width: 100%;
}

.final-sponsor-card img {
    height: 84px;
    object-fit: cover;
}

.final-sponsor-card p {
    margin: 0;
    padding: 0.45rem 0.55rem;
    font-size: 0.75rem;
    font-weight: 700;
    color: #f8fbff;
    text-transform: uppercase;
    letter-spacing: 0.4px;
}

.final-empty {
    margin: 0;
    color: #d8e4f3;
    font-size: 0.9rem;
}

.final-sections-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.55rem;
}

.final-sections-grid a {
    text-decoration: none;
    color: #f8fbff;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.06);
    font-size: 0.9rem;
    font-weight: 800;
    padding: 0.62rem 0.74rem;
    transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.final-sections-grid a:hover {
    background: linear-gradient(90deg, #ffd240, #ff8a00);
    border-color: #ffd240;
    color: #0e2131;
}

.final-social-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.55rem;
}

.final-social-grid a {
    text-decoration: none;
    color: #f7fbff;
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.06);
    font-size: 0.9rem;
    font-weight: 800;
    padding: 0.62rem 0.74rem;
    transition: transform 0.2s ease, background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.final-social-grid a:hover {
    transform: translateX(3px);
    color: #fff;
}

.final-social-grid a:nth-child(1):hover {
    background: #0f0f0f;
    border-color: #0f0f0f;
}

.final-social-grid a:nth-child(2):hover {
    background: #ff0000;
    border-color: #ff0000;
}

.final-social-grid a:nth-child(3):hover {
    background: linear-gradient(120deg, #8a3ab9, #e95950, #fccc63);
    border-color: #e95950;
}

.final-social-grid a:nth-child(4):hover {
    background: #1877f2;
    border-color: #1877f2;
}

.final-social-grid a:nth-child(5):hover {
    background: #25d366;
    border-color: #25d366;
}

.final-tags span {
    border: 1px solid #555253;
    border-radius: 2px;
    padding: 0.35rem 0.55rem;
    font-size: 0.82rem;
    background: #3f3c3d;
    color: #fff;
}

.final-about {
    margin: 0;
    font-size: 1.03rem;
    line-height: 1.45;
    text-align: center;
    color: #f4f4f4;
}

.contact-mini-form {
    display: grid;
    gap: 0.55rem;
}

.contact-mini-form input,
.contact-mini-form textarea {
    width: 100%;
    border: 1px solid #555253;
    background: #3f3c3d;
    color: #fff;
    padding: 0.62rem 0.7rem;
    border-radius: 2px;
    font: inherit;
}

.contact-mini-form textarea {
    resize: vertical;
    min-height: 70px;
}

.contact-mini-form button {
    border: 0;
    background: #ef1b11;
    color: #fff;
    font-weight: 800;
    padding: 0.6rem;
    border-radius: 2px;
    cursor: pointer;
}

.contact-mini-form button:hover {
    background: #d6170f;
}

@media (max-width: 950px) {
    .programacion-top-cards {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .programacion-media-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .portada-grid {
        height: auto;
        grid-template-columns: 1fr;
    }

    .pg-left {
        grid-template-rows: auto auto;
    }

    .pg-main {
        min-height: 250px;
    }

    .pg-right {
        grid-template-rows: auto auto;
    }

    .pg-medium {
        min-height: 200px;
    }

    .pg-small {
        min-height: 165px;
    }

    .hero,
    .main-grid {
        grid-template-columns: 1fr;
    }

    .cat-feature-grid {
        grid-template-columns: 170px 1fr;
    }

    .cat-thumb-stack {
        height: 220px;
    }

    .cat-feature-main {
        height: 220px;
    }

    .cat-row-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .cat-layout.has-global-rail {
        grid-template-columns: minmax(0, 1fr) 210px;
    }

    .cat-global-rail {
        max-width: 210px;
    }

    .cat-global-rail .home-ad-rail .home-ad-link {
        aspect-ratio: auto;
    }

    .ad-slot-band,
    .home-ad-band .home-ad-link {
        min-height: 104px;
    }

    .site-banner {
        min-height: 165px;
    }

    .banner-left-image,
    .banner-center-image,
    .banner-right1-image,
    .banner-right2-image {
        max-width: clamp(76px, 16vw, 180px);
    }

    .banner-left-image {
        width: clamp(138px, 31vw, 310px);
        max-height: 90%;
    }

    .banner-right2-image {
        top: 38%;
        max-width: clamp(52px, 10vw, 112px);
    }

    .banner-right1-image {
        right: calc(clamp(76px, 16vw, 180px) + clamp(0.55rem, 2.2vw, 1.5rem));
    }

    .banner-right1-link {
        right: calc(clamp(76px, 16vw, 180px) + clamp(0.55rem, 2.2vw, 1.5rem));
        max-width: clamp(76px, 16vw, 180px);
    }

    .nav {
        width: 100%;
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 0.55rem;
    }

    .nav a {
        display: flex;
        align-items: center;
        justify-content: center;
        min-height: 42px;
        padding: 0.55rem 0.7rem;
        text-align: center;
        border: 1px solid var(--line);
        border-radius: 10px;
        background: rgba(255, 255, 255, 0.65);
    }

    .btn-panel {
        grid-column: 1 / -1;
    }

    .final-grid {
        grid-template-columns: 1fr;
    }

    .final-sponsor-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }

    .main-menu-wrapper {
        overflow-x: auto;
        overflow-y: visible;
        -webkit-overflow-scrolling: touch;
        scroll-snap-type: x proximity;
        scrollbar-width: thin;
    }

    .main-menu-wrapper::-webkit-scrollbar {
        height: 7px;
    }

    .main-menu-wrapper::-webkit-scrollbar-thumb {
        background: #c8bcaa;
        border-radius: 999px;
    }

    .main-menu {
        width: max-content;
        min-width: 100%;
        gap: 0.4rem;
        padding: 0.35rem 0.45rem 0.45rem;
        flex-wrap: nowrap;
    }

    .menu-item {
        flex: 0 0 auto;
        min-width: max-content;
        scroll-snap-align: start;
    }

    .menu-label {
        min-width: clamp(120px, 23vw, 210px);
        padding: 0.55rem 0.78rem;
        font-size: 0.76rem;
        overflow: visible;
        text-overflow: clip;
    }

    .hero-lead {
        min-height: 350px;
    }

    .hero-lead.has-left-image > div {
        margin-left: clamp(85px, 22vw, 165px);
    }

    .hero-left-image {
        left: 0.7rem;
        bottom: 0.7rem;
        width: clamp(72px, 18vw, 145px);
    }

    .countdown-wrap {
        grid-template-columns: 1fr;
    }

    .menu-dropdown {
        position: static;
        width: 100%;
        margin-top: 0.35rem;
        box-shadow: none;
        opacity: 1;
        visibility: visible;
        transform: none;
        pointer-events: auto;
        display: none;
    }

    .menu-news-cards {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 0.55rem;
    }

    .menu-news-card-image,
    .menu-news-card-no-image {
        height: 140px;
    }

    .menu-item:hover .menu-dropdown,
    .menu-item:focus-within .menu-dropdown {
        display: none;
    }

    .menu-item.is-open .menu-dropdown {
        display: block;
    }
}

@media (max-width: 640px) {
    .programacion-showcase {
        padding: 0.56rem;
    }

    .programacion-center-logo {
        max-height: 84px;
    }

    .programacion-top-cards {
        grid-template-columns: 1fr;
    }

    .programacion-top-card h3 {
        font-size: 0.9rem;
    }

    .programacion-top-card p {
        font-size: 0.82rem;
    }

    .programacion-media-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 0.55rem;
    }

    .programacion-media-image {
        height: 78px;
    }

    .programacion-media-desc {
        font-size: 0.76rem;
    }

    .pg-main {
        min-height: 220px;
    }

    .pg-medium {
        min-height: 170px;
    }

    .pg-small {
        min-height: 145px;
    }

    .pg-small-row {
        grid-template-columns: 1fr 1fr;
    }

    .pg-title-main {
        font-size: clamp(1rem, 5vw, 1.4rem);
    }

    .pg-desc {
        display: none;
    }

    .wrap {
        width: min(100% - 1rem, var(--wrap-max));
    }

    .ad-slot-band,
    .home-ad-band .home-ad-link {
        min-height: 96px;
    }

    .ad-slot-copy {
        max-width: none;
    }

    .cat-layout.has-global-rail {
        grid-template-columns: 1fr;
    }

    .cat-global-rail {
        max-width: none;
        width: 100%;
    }

    .ad-slot-rail,
    .home-ad-rail .home-ad-link {
        min-height: 125px;
    }

    .cat-feature-grid {
        grid-template-columns: 1fr;
    }

    .cat-thumb-stack {
        height: 180px;
        grid-template-rows: 1fr;
        grid-template-columns: 1fr 1fr;
    }

    .cat-thumb-stack .cat-thumb-item:nth-child(2) {
        display: none;
    }

    .cat-row-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .ticker {
        min-height: 0;
        flex-direction: column;
    }

    .site-banner {
        min-height: 90px;
    }

    .banner-left-image {
        height: auto;
        width: clamp(128px, 56vw, 320px);
        max-height: 90%;
    }

    .banner-center-image {
        height: 82%;
        max-width: clamp(70px, 30vw, 200px);
    }

    .banner-right1-image {
        height: 82%;
        max-width: clamp(70px, 30vw, 200px);
    }

    .banner-right2-image {
        top: 34%;
        height: 74%;
        max-width: clamp(48px, 23vw, 128px);
    }

    .ticker-tag {
        width: 100%;
        flex: none;
        min-height: 36px;
        padding: 0.45rem 0.8rem;
    }

    .ticker-track {
        width: 100%;
        min-width: 100%;
        gap: 1rem;
        padding: 0.65rem 0.8rem;
        animation-duration: 16s;
    }

    .ticker-marquee {
        width: 100%;
        min-width: 0;
    }

    .countdown-card {
        grid-template-columns: 1fr;
        gap: 0.6rem;
    }

    .countdown-logo {
        width: 100%;
        min-height: 84px;
    }

    .countdown-time {
        gap: 0.3rem;
    }

    .countdown-time span {
        min-width: 62px;
    }

    .hero {
        gap: 0.8rem;
    }

    .hero-lead {
        min-height: 300px;
        padding: 1rem;
    }

    .hero-lead::after {
        width: 140px;
        height: 140px;
        right: -50px;
        bottom: -50px;
    }

    .hero-lead h1 {
        max-width: none;
        font-size: clamp(1.35rem, 7vw, 2rem);
    }

    .hero-lead p {
        font-size: 0.95rem;
    }

    .lead-meta {
        font-size: 0.78rem;
    }

    .box {
        padding: 0.85rem;
    }

    .quick-grid {
        grid-template-columns: 1fr;
    }

    .main-menu {
        display: flex;
        flex-wrap: nowrap;
        min-width: max-content;
        padding: 0.38rem 0.5rem 0.5rem;
    }

    .main-menu-wrapper {
        border-radius: 12px;
    }

    .menu-label {
        min-height: 44px;
        min-width: clamp(140px, 56vw, 220px);
        font-size: 0.82rem;
        padding: 0.6rem 0.9rem;
    }

    .menu-dropdown {
        padding: 0.65rem;
    }

    .menu-news-cards {
        grid-template-columns: 1fr;
    }

    .menu-news-card-image,
    .menu-news-card-no-image {
        height: 180px;
    }

    .panel {
        padding: 0.85rem;
    }

    .panel-head {
        align-items: flex-start;
        flex-direction: column;
        gap: 0.25rem;
    }

    .panel-head h2 {
        font-size: 0.98rem;
    }

    .news-card {
        padding: 0.75rem;
    }

    .news-card h3 {
        font-size: 0.96rem;
    }

    .final-widgets {
        padding: 1.4rem 0;
    }

    .final-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    .final-title {
        font-size: 0.98rem;
    }

    .final-sponsor-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 420px) {
    .programacion-media-grid {
        grid-template-columns: 1fr;
    }

    .wrap {
        width: calc(100% - 0.8rem);
    }

    .ticker-track {
        font-size: 0.84rem;
    }

    .hero-lead {
        min-height: 270px;
    }


    .hero-lead.has-left-image > div {
        margin-left: 0;
    }

    .hero-left-image {
        display: none;
    }
    .hero-side {
        gap: 0.75rem;
    }

    .events li,
    .quick,
    .news-card,
    .menu-news-list li {
        padding-left: 0.65rem;
        padding-right: 0.65rem;
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}

/* ============ REPRODUCTOR DE RADIO ============ */
.radio-player-container {
    position: static;
    z-index: 9999;
    font-family: inherit;
    pointer-events: auto;
}

.banner-radio-toggle {
    position: absolute;
    right: clamp(0.35rem, 1.5vw, 1.2rem);
    top: auto;
    bottom: clamp(0.45rem, 1.2vw, 1rem);
    min-height: 38px;
    padding: 0.45rem 0.85rem;
    background: linear-gradient(180deg, var(--accent), var(--accent-dark));
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.35);
    border-radius: 999px;
    cursor: pointer;
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    gap: 0.45rem;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.35);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    user-select: none;
    z-index: 9;
}

.banner-radio-toggle:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.42);
}

.radio-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.radio-label {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.35px;
    text-transform: uppercase;
    writing-mode: horizontal-tb;
    line-height: 1;
}

.radio-player-panel {
    position: fixed;
    right: clamp(0.6rem, 2vw, 1.4rem);
    top: clamp(120px, 15vh, 200px);
    z-index: 2147483646;
    width: 340px;
    max-height: min(76vh, 560px);
    overflow-y: auto;
    background: var(--paper);
    border: 2px solid var(--accent);
    border-radius: 12px;
    box-shadow: 6px 6px 28px rgba(0, 0, 0, 0.32);
    transition: opacity 0.3s ease, visibility 0.3s ease, transform 0.3s ease;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
}

.radio-player-container.active .radio-player-panel {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    z-index: 2147483647;
}

.radio-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
    background: var(--accent);
    color: white;
    border-radius: 0 12px 0 0;
}

.radio-header h3 {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
}

.radio-mode-indicator {
    font-size: 12px;
    font-weight: 600;
    padding: 2px 8px;
    border-radius: 20px;
    letter-spacing: 0.03em;
    white-space: nowrap;
}

.radio-mode-live {
    background: rgba(255, 255, 255, 0.25);
    color: #fff;
    animation: pulse-live 2s ease-in-out infinite;
}

.radio-mode-playlist {
    background: rgba(255, 255, 255, 0.15);
    color: rgba(255, 255, 255, 0.85);
}

.radio-hidden-playlist {
    display: none !important;
}

@keyframes pulse-live {
    0%, 100% { opacity: 1; }
    50%       { opacity: 0.6; }
}

.radio-close {
    cursor: pointer;
    font-size: 24px;
    line-height: 1;
    opacity: 0.8;
    transition: opacity 0.2s;
}

.radio-close:hover {
    opacity: 1;
}

.radio-programacion {
    padding: 20px;
}

.programacion-info h4 {
    margin: 0 0 10px 0;
    color: var(--accent);
    font-size: 16px;
}

.programacion-info p {
    margin: 0 0 20px 0;
    color: var(--muted);
    font-size: 14px;
}

.radio-controls {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.radio-btn {
    display: flex;
    align-items: center;
    gap: 5px;
    padding: 8px 12px;
    background: var(--accent);
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.2s ease;
}

.radio-btn:hover:not(:disabled) {
    background: var(--accent-dark);
    transform: translateY(-1px);
}

.radio-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.radio-btn svg {
    flex-shrink: 0;
}

.radio-progress {
    margin-bottom: 20px;
}

.progress-bar {
    width: 100%;
    height: 6px;
    background: var(--line);
    border-radius: 3px;
    margin-bottom: 8px;
    cursor: pointer;
    position: relative;
}

.progress-fill {
    height: 100%;
    background: var(--accent);
    border-radius: 3px;
    width: 0%;
    transition: width 0.1s ease;
}

.progress-time {
    display: flex;
    justify-content: space-between;
    font-size: 12px;
    color: var(--muted);
}

.radio-playlist h5 {
    margin: 0 0 15px 0;
    color: var(--ink);
    font-size: 16px;
    font-weight: 600;
}

.playlist-items {
    max-height: 300px;
    overflow-y: auto;
}

.playlist-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px;
    border-bottom: 1px solid var(--line);
    cursor: pointer;
    transition: background 0.2s ease;
}

.playlist-item:hover {
    background: var(--sand);
}

.playlist-item.active {
    background: var(--accent);
    color: white;
}

.playlist-item.active:hover {
    background: var(--accent-dark);
}

.item-info {
    flex: 1;
    min-width: 0;
}

.item-title {
    font-weight: 500;
    font-size: 14px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.item-artist {
    font-size: 12px;
    opacity: 0.8;
    margin-top: 2px;
}

.item-duration {
    font-size: 12px;
    opacity: 0.7;
    flex-shrink: 0;
    margin-left: 10px;
}

.radio-no-programacion {
    padding: 40px 20px;
    text-align: center;
    color: var(--muted);
}

.radio-no-programacion p {
    margin: 10px 0;
}

.radio-volume {
    padding: 15px 20px;
    border-top: 1px solid var(--line);
    display: flex;
    align-items: center;
    gap: 10px;
}

.radio-volume label {
    font-size: 14px;
    font-weight: 500;
    color: var(--ink);
    white-space: nowrap;
}

.radio-volume input[type="range"] {
    flex: 1;
    height: 4px;
    background: var(--line);
    border-radius: 2px;
    outline: none;
    appearance: none;
    -webkit-appearance: none;
}

.radio-volume input[type="range"]::-webkit-slider-thumb {
    appearance: none;
    -webkit-appearance: none;
    width: 16px;
    height: 16px;
    background: var(--accent);
    border-radius: 50%;
    cursor: pointer;
}

.radio-volume input[type="range"]::-moz-range-thumb {
    width: 16px;
    height: 16px;
    background: var(--accent);
    border-radius: 50%;
    cursor: pointer;
    border: none;
}

/* Responsive */
@media (max-width: 768px) {
    .banner-radio-toggle {
        right: 0.45rem;
        top: auto;
        bottom: 0.35rem;
        min-height: 34px;
        padding: 0.35rem 0.68rem;
        gap: 0.35rem;
    }

    .banner-radio-toggle .radio-label {
        font-size: 10px;
    }

    .radio-player-panel {
        width: 280px;
        right: 0.5rem;
        top: clamp(100px, 13vh, 170px);
        max-height: 72vh;
    }

    .radio-controls {
        flex-direction: column;
    }

    .radio-btn {
        justify-content: center;
    }
}
