/* =========================================================
   NOTICIERO KING — Design System v4.0 "Periodístico"
   ========================================================= */

/* ── 1. Design Tokens ─────────────────────────────────── */
:root {
  --nk-primary:        #2563eb;
  --nk-primary-dark:   #1d4ed8;
  --nk-primary-light:  #dbeafe;
  --nk-accent:         #dc2626;   /* rojo urgente/ticker */
  --nk-accent-hover:   #b91c1c;

  /* Categorías */
  --nk-local:         #2563eb;
  --nk-provincial:    #7c3aed;
  --nk-nacional:      #059669;
  --nk-internacional: #d97706;

  /* Superficies – Light */
  --nk-bg:            #f1f5f9;
  --nk-surface:       #ffffff;
  --nk-surface-2:     #f8fafc;
  --nk-border:        #e2e8f0;
  --nk-border-subtle: rgba(0,0,0,0.06);

  /* Texto */
  --nk-text:          #0f172a;
  --nk-text-muted:    #64748b;
  --nk-text-inv:      #ffffff;

  /* Header */
  --nk-header-bg:     #ffffff;
  --nk-topbar-bg:     #0f172a;
  --nk-catbar-bg:     #1e3a8a;

  /* Sombras */
  --nk-shadow-sm:     0 1px 3px rgba(0,0,0,.08);
  --nk-shadow-md:     0 4px 12px rgba(0,0,0,.10);
  --nk-shadow-lg:     0 8px 24px rgba(0,0,0,.12);
  --nk-shadow-hover:  0 12px 32px rgba(37,99,235,.15);

  /* Radios */
  --nk-radius:        10px;
  --nk-radius-sm:     6px;
  --nk-radius-pill:   50px;

  /* Layout */
  --nk-header-h:      56px;
  --nk-topbar-h:      32px;
  --nk-catbar-h:      44px;
}

:root.dark {
  --nk-bg:            #020617;
  --nk-surface:       #0f172a;
  --nk-surface-2:     #1e293b;
  --nk-border:        #1e293b;
  --nk-border-subtle: rgba(255,255,255,0.07);
  --nk-text:          #f1f5f9;
  --nk-text-muted:    #94a3b8;
  --nk-header-bg:     #0f172a;
  --nk-topbar-bg:     #020617;
  --nk-catbar-bg:     #1e3a8a;
  --nk-shadow-sm:     0 1px 3px rgba(0,0,0,.4);
  --nk-shadow-md:     0 4px 12px rgba(0,0,0,.4);
  --nk-shadow-lg:     0 8px 24px rgba(0,0,0,.5);
}

/* ── 2. Reset Global ───────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  background: var(--nk-bg);
  color: var(--nk-text);
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  -webkit-font-smoothing: antialiased;
  line-height: 1.55;
  overflow-x: hidden;
}

h1,h2,h3,h4,h5,h6 {
  color: var(--nk-text);
  font-weight: 700;
  letter-spacing: -.02em;
  line-height: 1.2;
}

a { color: var(--nk-primary); text-decoration: none; transition: color .18s; }
a:hover { color: var(--nk-primary-dark); }

img { max-width: 100%; height: auto; display: block; }

:focus-visible { outline: 2px solid var(--nk-primary); outline-offset: 2px; border-radius: 4px; }

/* Bootstrap dark overrides */
:root.dark .text-dark,
:root.dark .text-body   { color: var(--nk-text) !important; }
:root.dark .text-muted  { color: var(--nk-text-muted) !important; }
:root.dark .bg-light    { background: var(--nk-surface-2) !important; }
:root.dark .border      { border-color: var(--nk-border) !important; }

/* ── 3. Header ─────────────────────────────────────────── */

/* Top bar (fecha / clima / dólar) */
.nk-topbar {
  background: var(--nk-topbar-bg);
  color: #94a3b8;
  font-size: .78rem;
  height: var(--nk-topbar-h);
  display: flex;
  align-items: center;
}
.nk-topbar a { color: #94a3b8; }
.nk-topbar a:hover { color: #fff; }
.nk-topbar-widgets { display: flex; align-items: center; gap: 1rem; }
.nk-topbar-widget { display: flex; align-items: center; gap: .35rem; }
.nk-topbar-widget i { color: var(--nk-accent); font-size: .85rem; }

/* Main header bar */
.nk-header {
  background: var(--nk-header-bg);
  border-bottom: 1px solid var(--nk-border);
  box-shadow: var(--nk-shadow-sm);
  position: sticky;
  top: 0;
  z-index: 1000;
}
:root.dark .nk-header { border-bottom-color: var(--nk-border); }

.nk-mainbar {
  height: var(--nk-header-h);
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0 1rem;
}

/* Logo */
.nk-logo {
  font-size: 1.3rem;
  font-weight: 800;
  color: var(--nk-text) !important;
  letter-spacing: -.03em;
  white-space: nowrap;
  line-height: 1;
}
.nk-logo span { color: var(--nk-primary); }

/* Search bar */
.nk-search {
  display: flex;
  align-items: center;
  background: var(--nk-surface-2);
  border: 1.5px solid var(--nk-border);
  border-radius: var(--nk-radius-pill);
  overflow: hidden;
  transition: border-color .2s, box-shadow .2s;
  max-width: 420px;
  width: 100%;
}
.nk-search:focus-within {
  border-color: var(--nk-primary);
  box-shadow: 0 0 0 3px rgba(37,99,235,.12);
}
.nk-search input {
  flex: 1;
  border: none;
  background: transparent;
  padding: .45rem .9rem;
  font-size: .875rem;
  color: var(--nk-text);
  outline: none;
}
.nk-search input::placeholder { color: var(--nk-text-muted); }
.nk-search button {
  background: var(--nk-primary);
  border: none;
  color: #fff;
  padding: .45rem .85rem;
  cursor: pointer;
  transition: background .2s;
  font-size: .9rem;
}
.nk-search button:hover { background: var(--nk-primary-dark); }
:root.dark .nk-search { background: var(--nk-surface-2); }

/* Header icon buttons */
.nk-header-btn {
  background: none;
  border: 1.5px solid var(--nk-border);
  color: var(--nk-text-muted);
  border-radius: var(--nk-radius-sm);
  width: 36px; height: 36px;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
  transition: all .2s;
  font-size: 1rem;
}
.nk-header-btn:hover { background: var(--nk-surface-2); color: var(--nk-text); border-color: var(--nk-primary); }

/* Category navbar */
.nk-catbar {
  background: var(--nk-catbar-bg);
  height: var(--nk-catbar-h);
  display: flex;
  align-items: center;
}
.nk-catbar .nav { gap: 0; flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
.nk-catbar .nav::-webkit-scrollbar { display: none; }
.nk-catbar .nav-link {
  color: rgba(255,255,255,.75);
  font-size: .85rem;
  font-weight: 600;
  padding: .55rem 1rem;
  border-radius: 0;
  white-space: nowrap;
  transition: all .15s;
  border-bottom: 3px solid transparent;
}
.nk-catbar .nav-link:hover { color: #fff; background: rgba(255,255,255,.08); }
.nk-catbar .nav-link.active { color: #fff; border-bottom-color: var(--nk-accent); background: rgba(255,255,255,.1); }

/* ── Header unificado — fondo neutro (hereda nk-header-bg) ─ */
.nk-mainbar .nk-search { max-width: 260px; }

/* Inline nav en el mainbar — colores sobre fondo claro/oscuro */
.nk-inline-nav {
  display: flex;
  align-items: stretch;
  overflow-x: auto;
  scrollbar-width: none;
  gap: 0;
}
.nk-inline-nav::-webkit-scrollbar { display: none; }
.nk-inline-nav .nav-link {
  color: var(--nk-text-muted);
  font-size: .81rem;
  font-weight: 600;
  padding: 0 .72rem;
  white-space: nowrap;
  border-bottom: 2px solid transparent;
  border-radius: 0;
  display: flex;
  align-items: center;
  transition: color .15s, background .15s;
}
.nk-inline-nav .nav-link:hover {
  color: var(--nk-text);
  background: var(--nk-surface-2);
}
.nk-inline-nav .nav-link.active {
  color: var(--nk-accent);
  border-bottom-color: var(--nk-accent);
  font-weight: 700;
}

@media (max-width: 600px) {
  .nk-mainbar .nk-search { max-width: 140px; }
  .nk-inline-nav .nav-link { padding: 0 .5rem; font-size: .76rem; }
}

/* ── 4. Ticker de últimas noticias ─────────────────���───── */
.nk-ticker {
  background: #fff;
  border-bottom: 2px solid var(--nk-primary-light);
  overflow: hidden;
  display: flex;
  align-items: center;
  height: 38px;
}
:root.dark .nk-ticker { background: var(--nk-surface); border-bottom-color: var(--nk-border); }

.nk-ticker-label {
  background: var(--nk-accent);
  color: #fff;
  font-size: .72rem;
  font-weight: 800;
  letter-spacing: .08em;
  padding: 0 .9rem;
  height: 100%;
  display: flex;
  align-items: center;
  white-space: nowrap;
  flex-shrink: 0;
}

.nk-ticker-track {
  flex: 1;
  overflow: hidden;
  height: 100%;
  position: relative;
  mask-image: linear-gradient(to right, transparent 0, black 2%, black 98%, transparent 100%);
}

.nk-ticker-inner {
  display: flex;
  align-items: center;
  height: 100%;
  white-space: nowrap;
  animation: ticker-scroll 40s linear infinite;
  gap: 0;
}
.nk-ticker-inner:hover { animation-play-state: paused; }

@keyframes ticker-scroll {
  0%   { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

.nk-ticker-item {
  display: inline-flex;
  align-items: center;
  padding: 0 1.5rem;
  font-size: .82rem;
  font-weight: 500;
  color: var(--nk-text);
  white-space: nowrap;
  border-right: 1px solid var(--nk-border);
}
.nk-ticker-item:last-child { border-right: none; }
.nk-ticker-item:hover { color: var(--nk-primary); }
.nk-ticker-item i { color: var(--nk-accent); margin-right: .4rem; font-size: .75rem; }

/* ── 5. Slider portada de imágenes (background) ─────────── */
.nk-masthead {
  position: relative;
  height: 440px;
  background: #000;
  overflow: hidden;
  border-radius: 0 0 var(--nk-radius) var(--nk-radius);
}
.nk-masthead .carousel,
.nk-masthead .carousel-inner,
.nk-masthead .carousel-item { height: 100%; }
.nk-masthead img {
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: 50% var(--mast-focal, 62%);
  filter: brightness(.78);
  transform-origin: center center;
}
.nk-masthead .carousel-item.active img {
  animation: mastZoom 9s ease forwards;
}
@keyframes mastZoom {
  from { transform: scale(1); }
  to   { transform: scale(1.07); }
}
.nk-masthead-shade {
  position: absolute; inset: 0;
  background: linear-gradient(
    to bottom,
    rgba(0,0,0,.08) 0%,
    transparent     28%,
    rgba(0,0,0,.45) 60%,
    rgba(0,0,0,.82) 100%
  );
  z-index: 10; pointer-events: none;
}
.nk-masthead-overlay {
  position: absolute; inset: 0;
  z-index: 20;
  display: flex; flex-direction: column;
  justify-content: flex-end;
  padding-bottom: 1.5rem;
}
/* Controles del slider de portada */
.nk-masthead .carousel-control-prev,
.nk-masthead .carousel-control-next {
  width: 52px;
  opacity: 0;
  transition: opacity .25s;
}
.nk-masthead:hover .carousel-control-prev,
.nk-masthead:hover .carousel-control-next { opacity: .9; }
.nk-masthead .carousel-control-prev-icon,
.nk-masthead .carousel-control-next-icon {
  background-color: rgba(0,0,0,.55);
  border-radius: 50%;
  padding: 1.15rem;
  background-size: 42%;
}
/* Indicadores del slider de portada */
.nk-masthead .carousel-indicators {
  bottom: .85rem;
  margin: 0 4rem;
}
.nk-masthead .carousel-indicators [data-bs-target] {
  width: 22px; height: 3px;
  border-radius: 2px;
  background: rgba(255,255,255,.45);
  border: none;
  transition: all .35s;
}
.nk-masthead .carousel-indicators .active {
  background: #fff;
  width: 34px;
}
@media (max-width: 768px) { .nk-masthead { height: 280px; } }

/* ── 5b. Slider de noticias ─────────────────────────────── */
.nk-news-slider {
  position: relative;
  border-radius: var(--nk-radius);
  overflow: hidden;
  box-shadow: 0 12px 40px rgba(0,0,0,.25);
  background: #000;
}
.nk-news-slider .carousel-item {
  height: 490px;
}
@media (max-width: 768px) { .nk-news-slider .carousel-item { height: 320px; } }
.nk-slide-link {
  display: block;
  width: 100%; height: 100%;
  position: relative;
  text-decoration: none;
}
.nk-slide-img {
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: center 40%;
  filter: brightness(.7);
  transition: transform .6s ease, filter .4s ease;
}
.nk-news-slider .carousel-item.active .nk-slide-img {
  animation: nkSlideZoom 6s ease forwards;
}
@keyframes nkSlideZoom {
  from { transform: scale(1); }
  to   { transform: scale(1.04); }
}
.nk-slide-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top,
    rgba(0,0,0,.9)  0%,
    rgba(0,0,0,.5) 45%,
    rgba(0,0,0,.1) 75%,
    transparent    100%);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 2rem;
  color: #fff;
}
.nk-slide-title {
  font-size: clamp(1.15rem, 2.8vw, 1.75rem);
  font-weight: 800;
  line-height: 1.2;
  color: #fff;
  margin: .5rem 0 .4rem;
  text-shadow: 0 2px 8px rgba(0,0,0,.5);
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.nk-slide-sub {
  font-size: .9rem;
  color: rgba(255,255,255,.8);
  line-height: 1.45;
  margin-bottom: .6rem;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.nk-slide-meta {
  display: flex;
  align-items: center;
  gap: .75rem;
  font-size: .78rem;
  color: rgba(255,255,255,.65);
}
/* Controles del slider */
.nk-news-slider .carousel-control-prev,
.nk-news-slider .carousel-control-next {
  width: 48px;
  opacity: 0;
  transition: opacity .25s;
}
.nk-news-slider:hover .carousel-control-prev,
.nk-news-slider:hover .carousel-control-next { opacity: 1; }
.nk-news-slider .carousel-control-prev-icon,
.nk-news-slider .carousel-control-next-icon {
  background-color: rgba(0,0,0,.5);
  border-radius: 50%;
  padding: 1.1rem;
  background-size: 45%;
}
/* Indicadores del slider */
.nk-news-slider .carousel-indicators {
  bottom: .75rem;
  margin: 0 3.5rem;
}
.nk-news-slider .carousel-indicators [data-bs-target] {
  width: 28px; height: 3px;
  border-radius: 2px;
  background: rgba(255,255,255,.5);
  border: none;
  transition: all .3s;
}
.nk-news-slider .carousel-indicators .active {
  background: #fff;
  width: 42px;
}

/* ── 5c. Barra de radio persistente (rediseño) ──────────── */
.nk-radio-bar {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  z-index: 9999;
  background: linear-gradient(90deg, #0a1628 0%, #1a3a6e 35%, #1d4ed8 70%, #1e40af 100%);
  color: #fff;
  padding: 0;
  height: 62px;
  border-top: 1px solid rgba(255,255,255,.12);
  box-shadow: 0 -6px 32px rgba(0,0,0,.45);
  transition: transform .35s cubic-bezier(.4,0,.2,1);
}
.nk-radio-bar--hidden { transform: translateY(100%); }
body.nk-has-radio-bar { padding-bottom: 62px; }

/* Inner layout */
.nk-radio-bar-inner {
  display: flex;
  align-items: center;
  height: 62px;
  gap: .75rem;
}

/* Brand section: waves + info */
.nk-radio-bar-brand {
  display: flex;
  align-items: center;
  gap: .65rem;
  flex-shrink: 0;
  min-width: 0;
}

/* Wave bars inside the bottom bar */
.nk-rb-waves {
  display: flex;
  align-items: flex-end;
  gap: 3px;
  height: 22px;
  flex-shrink: 0;
}
.nk-rb-waves span {
  width: 4px;
  background: rgba(255,255,255,.55);
  border-radius: 2px;
  height: 5px;
  display: block;
  transition: height .1s;
}
.nk-radio-bar.is-playing .nk-rb-waves span:nth-child(1) { animation: rkBar .65s .00s ease-in-out infinite alternate; }
.nk-radio-bar.is-playing .nk-rb-waves span:nth-child(2) { animation: rkBar .65s .13s ease-in-out infinite alternate; }
.nk-radio-bar.is-playing .nk-rb-waves span:nth-child(3) { animation: rkBar .65s .26s ease-in-out infinite alternate; }
.nk-radio-bar.is-playing .nk-rb-waves span:nth-child(4) { animation: rkBar .65s .08s ease-in-out infinite alternate; }
.nk-radio-bar.is-playing .nk-rb-waves span:nth-child(5) { animation: rkBar .65s .20s ease-in-out infinite alternate; }

/* Dot + info text */
.nk-radio-bar-info {
  display: flex;
  flex-direction: column;
  line-height: 1.25;
  min-width: 0;
}
.nk-radio-bar-name {
  font-size: .87rem;
  font-weight: 700;
  white-space: nowrap;
  display: flex;
  align-items: center;
  gap: .4rem;
}
.nk-rb-freq-badge {
  font-size: .65rem;
  font-weight: 700;
  background: rgba(255,255,255,.18);
  border: 1px solid rgba(255,255,255,.25);
  border-radius: 100px;
  padding: 1px 7px;
  letter-spacing: .02em;
  color: rgba(255,255,255,.9);
}
#rk-status {
  font-size: .72rem;
  color: rgba(255,255,255,.62);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  display: block;
}

/* Controls */
.nk-radio-bar-controls {
  display: flex;
  align-items: center;
  gap: .55rem;
  flex-shrink: 0;
  margin-left: auto;
}
.nk-radio-bar-btn {
  width: 42px; height: 42px;
  border-radius: 50%;
  background: rgba(255,255,255,.18);
  border: 2px solid rgba(255,255,255,.3);
  color: #fff;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
  font-size: 1.1rem;
  transition: background .18s, border-color .18s, transform .15s, box-shadow .18s;
  flex-shrink: 0;
}
.nk-radio-bar-btn:hover {
  background: rgba(255,255,255,.3);
  border-color: rgba(255,255,255,.65);
  transform: scale(1.08);
  box-shadow: 0 0 12px rgba(255,255,255,.2);
}
.nk-radio-bar.is-playing .nk-radio-bar-btn {
  background: rgba(255,255,255,.22);
  border-color: rgba(255,255,255,.55);
  box-shadow: 0 0 16px rgba(96,165,250,.35);
}
.nk-radio-bar-vol {
  display: flex;
  align-items: center;
  gap: .35rem;
  flex-shrink: 0;
}
.nk-radio-bar-vol-icon { font-size: .8rem; opacity: .65; }
.nk-radio-range {
  width: 80px; height: 4px;
  accent-color: rgba(255,255,255,.9);
  cursor: pointer;
}
.nk-radio-bar-close {
  background: none;
  border: none;
  color: rgba(255,255,255,.45);
  cursor: pointer;
  padding: .3rem .4rem;
  border-radius: var(--nk-radius-sm);
  transition: all .18s;
  flex-shrink: 0;
  font-size: .85rem;
  margin-left: .25rem;
}
.nk-radio-bar-close:hover { color: #fff; background: rgba(255,255,255,.12); }

/* Live green dot on bar */
.nk-radio-bar .live-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: #4ade80;
  flex-shrink: 0;
  display: none;
  animation: rkPulseDot 1.4s ease-in-out infinite;
}
.nk-radio-bar.is-playing .live-dot { display: block; }
@keyframes rkPulseDot {
  0%,100% { box-shadow: 0 0 0 0 rgba(74,222,128,.6); }
  50%      { box-shadow: 0 0 0 5px rgba(74,222,128,.0); }
}

/* Botón para abrir la radio (en sidebar) */
.nk-radio-open-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: .5rem;
  background: linear-gradient(135deg, #2563eb, #1d4ed8);
  color: #fff;
  border: none;
  border-radius: var(--nk-radius-sm);
  padding: .65rem 1rem;
  width: 100%;
  cursor: pointer;
  font-size: .875rem;
  font-weight: 600;
  transition: opacity .2s, transform .15s;
  margin-bottom: 1.25rem;
}
.nk-radio-open-btn:hover { opacity: .88; transform: translateY(-1px); }
.nk-radio-open-btn .live-dot { flex-shrink: 0; }

@media (max-width: 600px) {
  .nk-radio-bar-vol { display: none; }
  .nk-radio-bar-brand { gap: .4rem; }
  .nk-radio-bar-name { font-size: .8rem; }
}
@media (max-width: 480px) {
  .nk-news-slider .carousel-item { height: 300px; }
  .nk-slide-overlay { padding: 1.25rem; }
}

/* ── 6. Cards de noticias ──────────────────────────────── */
.card {
  background: var(--nk-surface);
  border: 1px solid var(--nk-border-subtle);
  border-radius: var(--nk-radius);
  box-shadow: var(--nk-shadow-sm);
  overflow: hidden;
  transition: transform .22s, box-shadow .22s, border-color .22s;
}
.card:hover {
  transform: translateY(-3px);
  box-shadow: var(--nk-shadow-hover);
  border-color: rgba(37,99,235,.2);
}

/* Thumbnail 16:9 */
.nk-thumb {
  position: relative;
  width: 100%;
  aspect-ratio: 16/9;
  overflow: hidden;
  overflow: hidden;
  background: var(--nk-surface-2);
  flex-shrink: 0;
}
.nk-thumb img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform .5s ease;
}
.card:hover .nk-thumb img,
.nk-card:hover .nk-thumb img { transform: scale(1.06); }

/* Tarjeta grande (featured hero) */
.nk-card-hero {
  position: relative;
  border-radius: var(--nk-radius);
  overflow: hidden;
  aspect-ratio: 21/9;   /* más panorámico = menos alto, más periodístico */
  background: #000;
  box-shadow: var(--nk-shadow-lg);
  display: block;
  text-decoration: none;
}
.nk-card-hero img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform .6s;
  filter: brightness(.75);
}
.nk-card-hero:hover img { transform: scale(1.03); filter: brightness(.65); }
.nk-card-hero-body {
  position: absolute; inset: 0;
  display: flex; flex-direction: column;
  justify-content: flex-end;
  padding: 1.5rem;
  background: linear-gradient(to top, rgba(0,0,0,.85) 0%, transparent 60%);
  color: #fff;
}
.nk-card-hero-body h2 {
  color: #fff;
  font-size: clamp(1.1rem, 2.5vw, 1.5rem);
  line-height: 1.25;
  margin-bottom: .5rem;
  text-shadow: 0 1px 4px rgba(0,0,0,.5);
}
.nk-card-hero-body .sub {
  font-size: .875rem;
  color: rgba(255,255,255,.8);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* Tarjeta horizontal (sidebar hero strip) */
.nk-card-h {
  display: flex;
  gap: .75rem;
  background: var(--nk-surface);
  border: 1px solid var(--nk-border-subtle);
  border-radius: var(--nk-radius-sm);
  box-shadow: var(--nk-shadow-sm);
  overflow: hidden;
  transition: box-shadow .2s, border-color .2s;
  text-decoration: none;
  color: var(--nk-text);
}
.nk-card-h:hover { box-shadow: var(--nk-shadow-md); border-color: rgba(37,99,235,.2); color: var(--nk-text); }
.nk-card-h-thumb {
  width: 110px; flex-shrink: 0;
  aspect-ratio: 4/3;
  overflow: hidden;
  background: var(--nk-surface-2);
}
.nk-card-h-thumb img { width:100%; height:100%; object-fit:cover; transition:transform .4s; }
.nk-card-h:hover .nk-card-h-thumb img { transform:scale(1.05); }
.nk-card-h-body { flex: 1; padding: .6rem .7rem .6rem 0; display: flex; flex-direction: column; justify-content: center; }
.nk-card-h-body h6 { font-size: .875rem; font-weight: 700; line-height: 1.35; margin: 0; color: var(--nk-text);
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.nk-card-h-body .meta { font-size: .73rem; color: var(--nk-text-muted); margin-top: .3rem; }

/* Tarjeta grilla estándar */
.nk-card {
  display: flex; flex-direction: column;
  height: 100%;
  text-decoration: none; color: inherit;
  transition: transform .25s ease, box-shadow .25s ease;
}
.nk-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--nk-shadow-md);
}
.nk-card .card-body { padding: .875rem; display: flex; flex-direction: column; flex: 1; }
.nk-card .card-title {
  font-size: .925rem; font-weight: 700; color: var(--nk-text);
  line-height: 1.35; margin-bottom: .4rem;
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
  transition: color .2s;
}
.nk-card:hover .card-title { color: var(--nk-primary); }
.nk-card .card-sub {
  font-size: .8rem; color: var(--nk-text-muted); line-height: 1.45;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
  margin-bottom: .5rem; flex: 1;
}
.nk-card .card-meta {
  display: flex; align-items: center; gap: .5rem; flex-wrap: wrap;
  font-size: .72rem; color: var(--nk-text-muted); margin-top: auto;
}

/* ── 7. Badges de categoría ────────────────────────────── */
.nk-cat-badge {
  display: inline-block;
  font-size: .68rem; font-weight: 700;
  letter-spacing: .04em; text-transform: uppercase;
  padding: 2px 8px; border-radius: 4px;
  color: #fff; white-space: nowrap;
}
.nk-cat-local        { background: var(--nk-local); }
.nk-cat-provincial   { background: var(--nk-provincial); }
.nk-cat-nacional     { background: var(--nk-nacional); }
.nk-cat-internacional{ background: var(--nk-internacional); }
.nk-cat-default      { background: #64748b; }

/* ── 8. Reading time badge ──────────────────────────────── */
.nk-read-time {
  display: inline-flex; align-items: center; gap: 3px;
  font-size: .72rem; color: var(--nk-text-muted);
}
.nk-read-time i { font-size: .75rem; }

/* ── 9. Sección heading con línea ───────────────────────── */
.nk-section-heading {
  display: flex; align-items: center; gap: .75rem;
  margin-bottom: 1.25rem;
}
.nk-section-heading h1,
.nk-section-heading h2 {
  font-size: 1rem; font-weight: 800;
  text-transform: uppercase; letter-spacing: .06em;
  white-space: nowrap; margin: 0;
}
.nk-section-heading h1 { white-space: normal; }
.nk-section-heading .accent-bar {
  width: 32px; height: 3px;
  background: var(--nk-accent);
  border-radius: 2px; flex-shrink: 0;
}
.nk-section-heading .line {
  flex: 1; height: 1px;
  background: var(--nk-border);
}

/* ── 10. Sidebar ────────────────────────────────────────── */
.nk-sidebar-section {
  background: var(--nk-surface);
  border: 1px solid var(--nk-border);
  border-radius: var(--nk-radius);
  padding: 1rem;
  box-shadow: var(--nk-shadow-sm);
  margin-bottom: 1.25rem;
}

/* Tabs sidebar */
.nk-tabs .nav-link {
  color: var(--nk-text-muted);
  font-size: .8rem; font-weight: 600;
  border-radius: var(--nk-radius-sm);
  padding: .4rem .75rem;
  transition: all .15s;
}
.nk-tabs .nav-link.active {
  background: var(--nk-primary-light);
  color: var(--nk-primary);
}
:root.dark .nk-tabs .nav-link.active {
  background: rgba(37,99,235,.2);
  color: #60a5fa;
}

/* Ítem noticia sidebar */
.nk-sidebar-item {
  display: flex; gap: .65rem; padding: .55rem 0;
  border-bottom: 1px solid var(--nk-border);
  text-decoration: none; color: var(--nk-text);
  transition: padding-left .15s;
}
.nk-sidebar-item:last-child { border-bottom: none; }
.nk-sidebar-item:hover { padding-left: .3rem; }
.nk-sidebar-item img {
  width: 64px; height: 48px; flex-shrink: 0;
  border-radius: 5px; object-fit: cover;
  background: var(--nk-surface-2);
}
.nk-sidebar-item .si-title {
  font-size: .82rem; font-weight: 600; line-height: 1.35; color: var(--nk-text);
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
  transition: color .15s;
}
.nk-sidebar-item:hover .si-title { color: var(--nk-primary); }
.nk-sidebar-item .si-meta { font-size: .7rem; color: var(--nk-text-muted); margin-top: 2px; }
.si-rank {
  width: 36px; flex-shrink: 0;
  font-size: 1.25rem; font-weight: 800;
  color: var(--nk-border);
  text-align: center; line-height: 1;
  font-variant-numeric: tabular-nums;
}

/* ── 11. Radio card ─────────────────────────────────────── */
.nk-radio-card {
  background: linear-gradient(135deg, var(--nk-primary) 0%, #1e40af 100%);
  color: #fff; border-radius: var(--nk-radius);
  padding: 1.1rem; box-shadow: var(--nk-shadow-md);
  margin-bottom: 1.25rem;
}
.nk-radio-card .nk-header-btn { border-color: rgba(255,255,255,.3); color: rgba(255,255,255,.8); }
.nk-radio-card .nk-header-btn:hover { background: rgba(255,255,255,.15); color: #fff; }
.live-dot {
  width: 8px; height: 8px; background: #f87171;
  border-radius: 50%; flex-shrink: 0;
  box-shadow: 0 0 0 0 rgba(248,113,113,.7);
  animation: pulse-dot 2s infinite;
}
@keyframes pulse-dot {
  0%   { box-shadow: 0 0 0 0 rgba(248,113,113,.7); }
  70%  { box-shadow: 0 0 0 6px rgba(248,113,113,0); }
  100% { box-shadow: 0 0 0 0 rgba(248,113,113,0); }
}
.radio-btn-play {
  width: 42px; height: 42px;
  border-radius: 50%; background: rgba(255,255,255,.2);
  border: 2px solid rgba(255,255,255,.4);
  color: #fff; display: flex; align-items: center; justify-content: center;
  cursor: pointer; font-size: 1.1rem;
  transition: all .2s; flex-shrink: 0;
}
.radio-btn-play:hover { background: rgba(255,255,255,.3); border-color: #fff; }
.form-range::-webkit-slider-thumb { background: #fff; }
.form-range::-moz-range-thumb { background: #fff; }

/* ── 12. Anuncios ───────────────────────────────────────── */
.ad-unit { border-radius: var(--nk-radius-sm); overflow: hidden; margin-bottom: 1rem; }
.ad-unit img, .ad-unit video { width:100%; height:auto; display:block; }
.ad-label {
  position: absolute; top: 4px; right: 4px;
  font-size: .65rem; color: #94a3b8;
  background: rgba(255,255,255,.85); padding: 1px 5px; border-radius: 3px;
}
:root.dark .ad-label { background: rgba(0,0,0,.7); }
/* Compat aliases */
.nk-espacio { border-radius: var(--nk-radius-sm); overflow: hidden; margin-bottom: 1rem; }
.nk-espacio img, .nk-espacio video { width:100%; height:auto; display:block; }
.ad-banner-top, .ad-feed { border-radius: var(--nk-radius-sm); overflow: hidden; margin-bottom: 1rem; }
.ad-banner-top img, .ad-banner-top video,
.ad-feed img, .ad-feed video { width:100%; height:auto; display:block; }

/* ── 13. Contenido artículo (ver.php) ───────────────────── */
.nk-article-hero { position: relative; border-radius: var(--nk-radius); overflow: hidden; margin-bottom: 1.5rem; }
.nk-article-img {
  width:100%; max-height:480px; object-fit:cover;
  border-radius: var(--nk-radius); display:block;
  box-shadow: var(--nk-shadow-md);
}

/* La nota es lo primero del contenedor: sin esto hereda un margen superior
   que la despega de la cabecera. Antes esto era un
   "body > .container > *:first-child { margin-top:0 !important }" incrustado
   en ver.php, que pisaba el primer elemento de CUALQUIER pagina. */
.nk-article-header { margin-top: 0; }

/* Reproductor de video nativo. Vivia dentro de ver.php junto con cinco clases
   que ni siquiera existian en el HTML (.btn-whatsapp, .btn-facebook, .btn-x,
   .hero-header, .noticia-bajada) y con una redefinicion de .btn-share que
   pisaba la de mas abajo y agrandaba los botones de compartir. */
.video-wrapper {
  position: relative; width: 100%;
  background: var(--nk-surface-2);
  border: 1px solid var(--nk-border);
  border-radius: var(--nk-radius);
  padding: 8px;
}
.video-wrapper video {
  width: 100%; max-height: 60vh; display: block;
  object-fit: contain; background: #000;
  border-radius: var(--nk-radius-sm);
}

.nk-article-header { padding-bottom: 1rem; border-bottom: 1px solid var(--nk-border); margin-bottom: 1.5rem; }
.nk-article-header h1 { font-size: clamp(1.4rem, 3.5vw, 2rem); line-height: 1.2; }
.nk-article-header .sub { font-size: 1.1rem; font-weight: 300; color: var(--nk-text-muted); line-height: 1.6; margin: .5rem 0 1rem; }
.nk-article-meta { display: flex; flex-wrap: wrap; align-items: center; gap: .65rem; font-size: .8rem; color: var(--nk-text-muted); }
.nk-article-meta i { margin-right: 2px; }

.nk-article-body {
  font-size: 1.05rem; line-height: 1.85;
  color: var(--nk-text);
}
.nk-article-body p { margin-bottom: 1.25rem; }
.nk-article-body img, .nk-article-body video, .nk-article-body iframe {
  max-width: 100%; height: auto;
  border-radius: var(--nk-radius-sm);
  margin: 1.25rem 0;
  box-shadow: var(--nk-shadow-sm);
  display: block;
}

/* Share bar */
.nk-share-bar { padding: 1rem 0; border-top: 1px solid var(--nk-border); border-bottom: 1px solid var(--nk-border); margin: 1.5rem 0; }
.nk-share-bar h6 { font-size: .75rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--nk-text-muted); margin-bottom: .6rem; }
.btn-share {
  border-radius: var(--nk-radius-pill); font-size: .82rem; font-weight: 600;
  padding: .35rem .9rem; display: inline-flex; align-items: center; gap: 5px;
  border: none; cursor: pointer; transition: transform .18s, opacity .18s;
}
.btn-share:hover { transform: translateY(-2px); opacity: .9; }
.btn-wa  { background: #25D366; color:#fff; }
.btn-fb  { background: #1877F2; color:#fff; }
.btn-tw  { background: #000;    color:#fff; border:1px solid #333; }
.btn-tg  { background: #2CA5E0; color:#fff; }
.btn-li  { background: #0077B5; color:#fff; }
.btn-copy{ background: var(--nk-surface-2); color: var(--nk-text); border:1px solid var(--nk-border); }

/* Tags etiquetas */
.nk-tags { display: flex; flex-wrap: wrap; gap: .4rem; margin: 1rem 0; }
.nk-tag {
  display: inline-block; font-size: .78rem; font-weight: 600;
  padding: 3px 10px; border-radius: var(--nk-radius-pill);
  background: var(--nk-surface-2); color: var(--nk-text-muted);
  border: 1px solid var(--nk-border); transition: all .18s;
}
.nk-tag:hover { background: var(--nk-primary); color:#fff; border-color: var(--nk-primary); }

/* Comentarios */
.nk-comment-form { background: var(--nk-surface); border: 1px solid var(--nk-border); border-radius: var(--nk-radius); padding: 1.25rem; }
.nk-comment-form .form-control {
  background: var(--nk-surface-2); border-color: var(--nk-border);
  color: var(--nk-text); border-radius: var(--nk-radius-sm);
}
.nk-comment-form .form-control:focus {
  background: var(--nk-surface); border-color: var(--nk-primary);
  box-shadow: 0 0 0 3px rgba(37,99,235,.12); color: var(--nk-text);
}
:root.dark .nk-comment-form .form-control::placeholder { color: var(--nk-text-muted); }

.nk-comment-item { padding: .85rem 0; border-bottom: 1px solid var(--nk-border); }
.nk-comment-item:last-child { border-bottom: none; }
.nk-comment-author { font-weight: 700; font-size: .875rem; }
.nk-comment-date   { font-size: .73rem; color: var(--nk-text-muted); }
.nk-comment-text   { font-size: .9rem; margin-top: .35rem; line-height: 1.55; }

/* ── 14. Paginación ─────────────────────────────────────── */
.pagination { gap: 4px; }
.page-link {
  border: none !important; border-radius: var(--nk-radius-sm) !important;
  color: var(--nk-text); background: var(--nk-surface);
  font-weight: 600; font-size: .875rem;
  min-width: 38px; text-align: center;
  box-shadow: var(--nk-shadow-sm);
  transition: all .18s;
}
.page-link:hover { background: var(--nk-primary-light); color: var(--nk-primary); transform: translateY(-1px); }
.page-item.active .page-link { background: var(--nk-primary) !important; color: #fff !important; box-shadow: 0 4px 12px rgba(37,99,235,.35); }
.page-item.disabled .page-link { background: transparent; color: var(--nk-text-muted); box-shadow: none; }
:root.dark .page-link { background: var(--nk-surface-2); color: var(--nk-text); }
:root.dark .page-link:hover { background: rgba(37,99,235,.2); }

/* ── 15. Footer ─────────────────────────────────────────── */
/* Contraste: el fondo del pie es #0f172a y los titulos de columna estaban en
   #475569, o sea 2,36 sobre un minimo de 4,5. En 0,75rem y mayusculas se leian
   apenas. Los valores de abajo estan medidos: titulos 6,96 · enlaces 12,02 ·
   descripcion 8,66 · copyright 6,96. Si se cambia alguno, medirlo antes. */
.nk-footer {
  background: #0f172a;
  color: #94a3b8;
  margin-top: 3rem;
  border-top: 3px solid var(--nk-primary);
}
.nk-footer-top { padding: 2.5rem 0 1.5rem; }
.nk-footer-brand { font-size: 1.2rem; font-weight: 800; color: #fff; letter-spacing: -.02em; }
.nk-footer-brand span { color: var(--nk-primary); }
.nk-footer-desc { font-size: .85rem; color: #a8b6c8; margin-top: .4rem; }
.nk-footer-heading { font-size: .75rem; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: #94a3b8; margin-bottom: .75rem; }
.nk-footer-links { list-style: none; padding: 0; margin: 0; }
.nk-footer-links li { margin-bottom: .35rem; }
.nk-footer-links a { color: #cbd5e1; font-size: .875rem; transition: color .15s; }
.nk-footer-links a:hover { color: #fff; }
.nk-footer-bottom {
  border-top: 1px solid #1e293b;
  padding: 1rem 0;
  font-size: .8rem; color: #94a3b8;
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .5rem;
}
.nk-social-link {
  display: inline-flex; width: 36px; height: 36px;
  border-radius: 50%; background: rgba(255,255,255,.06);
  align-items: center; justify-content: center;
  color: #cbd5e1; margin-right: .35rem;
  transition: all .2s;
}
.nk-social-link:hover { background: var(--nk-primary); color: #fff; transform: translateY(-2px); }

/* ── 16. Stream card ─────────────────────────────────────── */
.nk-stream-card { border: 2px solid var(--nk-accent); border-radius: var(--nk-radius); overflow: hidden; box-shadow: var(--nk-shadow-lg); margin-bottom: 1.5rem; }
.nk-stream-header { background: var(--nk-accent); color:#fff; padding: .5rem 1rem; display:flex; align-items:center; justify-content:space-between; font-size:.875rem; font-weight:700; }
.pulse-icon { animation: pulse-anim 1.5s infinite; }
@keyframes pulse-anim { 0%,100%{opacity:1} 50%{opacity:.2} }

/* ── 17. Utilidades ─────────────────────────────────────── */
.line-clamp-2 { display:-webkit-box; -webkit-line-clamp:2; -webkit-box-orient:vertical; overflow:hidden; }
.line-clamp-3 { display:-webkit-box; -webkit-line-clamp:3; -webkit-box-orient:vertical; overflow:hidden; }

/* Divider con texto */
.nk-divider { display:flex; align-items:center; gap:.75rem; margin:1.5rem 0 1rem; }
.nk-divider::before, .nk-divider::after { content:''; flex:1; height:1px; background:var(--nk-border); }
.nk-divider span { font-size:.72rem; font-weight:700; text-transform:uppercase; letter-spacing:.08em; color:var(--nk-text-muted); white-space:nowrap; }

/* ── 18. Búsqueda ─────────────────────────────────────────── */
.nk-search-page { max-width: 680px; margin: 0 auto; }
.nk-search-page .nk-search { max-width: 100%; }
.nk-search-result { padding: 1rem; border-bottom: 1px solid var(--nk-border); }
.nk-search-result:last-child { border-bottom: none; }
.nk-search-result h5 { font-size: .95rem; }
.nk-search-result h5 a { color: var(--nk-text); }
.nk-search-result h5 a:hover { color: var(--nk-primary); }
.nk-search-result mark { background: #fef08a; color: #0f172a; padding: 0 2px; border-radius: 2px; }

/* ── 19. Responsive ─────────────────────────────────────── */
@media (max-width: 1200px) {
  .container { max-width: 100%; padding-left: 1rem; padding-right: 1rem; }
}

@media (max-width: 991px) {
  .nk-masthead { height: 300px; }
  .nk-card-hero { aspect-ratio: 16/7; }
}

@media (max-width: 768px) {
  .nk-topbar { display: none; }
  .nk-masthead { height: 220px; }
  .nk-card-hero { aspect-ratio: 4/3; }
  .nk-search { max-width: 100%; }
  .nk-logo { font-size: 1.05rem; }
  .nk-catbar .nav-link { padding: .45rem .65rem; font-size: .78rem; }
  .nk-article-header h1 { font-size: 1.3rem; }
  .nk-article-body { font-size: .975rem; }
  .nk-card-h-thumb { width: 90px; }
  .nk-ticker-inner { animation-duration: 30s; }
}

@media (max-width: 480px) {
  .nk-mainbar { gap: .4rem; padding: 0 .6rem; }
  .nk-logo { font-size: .95rem; }
  .nk-catbar .nav-link { padding: .4rem .5rem; font-size: .75rem; }
  .nk-ticker { height: 32px; }
  .nk-ticker-label { font-size: .68rem; padding: 0 .65rem; }
  .nk-ticker-item { font-size: .78rem; padding: 0 1rem; }
  .nk-card-hero { aspect-ratio: 3/2; }
  .nk-masthead { height: 190px; }
  /* En móvil el grid va a 1 columna */
  .row .col-sm-6 { flex: 0 0 100%; max-width: 100%; }
}

/* ── 20. Radio Widget (sidebar card) ───────────────────── */
.nk-radio-widget {
  background: linear-gradient(160deg, #0f2044 0%, #1d4ed8 100%);
  border-radius: 14px;
  padding: 1.1rem 1.25rem 1rem;
  color: #fff;
  margin-bottom: 1.5rem;
  position: relative;
  overflow: hidden;
  box-shadow: 0 8px 32px rgba(29,78,216,.35);
}
.nk-radio-widget::after {
  content: '';
  position: absolute;
  top: -40px; right: -25px;
  width: 110px; height: 110px;
  background: rgba(255,255,255,.04);
  border-radius: 50%;
  pointer-events: none;
}
.nk-rw-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: .6rem;
}
.nk-rw-live-badge {
  font-size: .65rem;
  font-weight: 700;
  background: #ef4444;
  color: #fff;
  padding: 2px 8px;
  border-radius: 100px;
  letter-spacing: .04em;
  animation: rkBlink 1.8s ease-in-out infinite;
}
.nk-rw-freq {
  font-size: .88rem;
  font-weight: 800;
  opacity: .9;
  letter-spacing: .02em;
}
.nk-rw-waves {
  display: flex;
  align-items: flex-end;
  gap: 3px;
  height: 20px;
  opacity: 0;
  transition: opacity .3s;
}
.nk-radio-widget.is-playing .nk-rw-waves { opacity: 1; }
.nk-rw-waves span {
  width: 4px;
  background: rgba(255,255,255,.65);
  border-radius: 2px;
  height: 6px;
  display: block;
}
.nk-radio-widget.is-playing .nk-rw-waves span:nth-child(1) { animation: rkBar .7s .00s ease-in-out infinite alternate; }
.nk-radio-widget.is-playing .nk-rw-waves span:nth-child(2) { animation: rkBar .7s .15s ease-in-out infinite alternate; }
.nk-radio-widget.is-playing .nk-rw-waves span:nth-child(3) { animation: rkBar .7s .30s ease-in-out infinite alternate; }
.nk-radio-widget.is-playing .nk-rw-waves span:nth-child(4) { animation: rkBar .7s .10s ease-in-out infinite alternate; }
.nk-radio-widget.is-playing .nk-rw-waves span:nth-child(5) { animation: rkBar .7s .25s ease-in-out infinite alternate; }
@keyframes rkBar  { from { height: 4px; } to { height: 18px; } }
@keyframes rkBlink { 0%,100% { opacity:1; } 50% { opacity:.55; } }
.nk-rw-station {
  font-size: .97rem;
  font-weight: 700;
  margin-bottom: .85rem;
  display: flex;
  align-items: center;
  gap: .45rem;
  color: rgba(255,255,255,.92);
}
.nk-rw-controls {
  display: flex;
  align-items: center;
  gap: .8rem;
}
.nk-rw-play-btn {
  width: 50px; height: 50px;
  border-radius: 50%;
  background: rgba(255,255,255,.18);
  border: 2px solid rgba(255,255,255,.35);
  color: #fff;
  font-size: 1.3rem;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  transition: background .2s, transform .15s, border-color .2s;
}
.nk-rw-play-btn:hover {
  background: rgba(255,255,255,.3);
  border-color: rgba(255,255,255,.65);
  transform: scale(1.06);
}
.nk-radio-widget.is-playing .nk-rw-play-btn {
  background: rgba(255,255,255,.25);
  border-color: rgba(255,255,255,.6);
}
.nk-rw-right { flex: 1; min-width: 0; }
.nk-rw-status {
  font-size: .77rem;
  color: rgba(255,255,255,.65);
  display: block;
  margin-bottom: .35rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.nk-rw-vol {
  display: flex;
  align-items: center;
  gap: .3rem;
  font-size: .75rem;
  opacity: .75;
  color: #fff;
}
.nk-rw-range {
  flex: 1;
  height: 4px;
  accent-color: rgba(255,255,255,.9);
  cursor: pointer;
  min-width: 0;
}

/* ── Footer enhancements ────────────────────────────────── */
.nk-footer-fm-badge {
  font-size: .78rem;
  color: #3b82f6;
  font-weight: 600;
  margin-top: .25rem;
  margin-bottom: .45rem;
}

/* Footer radio CTA card */
.nk-footer-radio-cta {
  background: linear-gradient(135deg, #0e1e3d 0%, #1a3562 55%, #163060 100%);
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 12px;
  padding: .9rem 1rem;
  position: relative;
  overflow: hidden;
}
.nk-footer-radio-cta::after {
  content: '';
  position: absolute;
  top: -20px; right: -20px;
  width: 80px; height: 80px;
  background: rgba(255,255,255,.04);
  border-radius: 50%;
  pointer-events: none;
}

/* Wave bars — always animated (decorative "live" feel) */
.nk-frb-waves {
  display: flex;
  align-items: flex-end;
  gap: 2px;
  height: 18px;
  flex-shrink: 0;
}
.nk-frb-waves span {
  width: 3px;
  background: #60a5fa;
  border-radius: 2px;
  display: block;
}
.nk-frb-waves span:nth-child(1) { animation: rkBar .75s .00s ease-in-out infinite alternate; }
.nk-frb-waves span:nth-child(2) { animation: rkBar .75s .18s ease-in-out infinite alternate; }
.nk-frb-waves span:nth-child(3) { animation: rkBar .75s .36s ease-in-out infinite alternate; }
.nk-frb-waves span:nth-child(4) { animation: rkBar .75s .12s ease-in-out infinite alternate; }
.nk-frb-waves span:nth-child(5) { animation: rkBar .75s .28s ease-in-out infinite alternate; }

/* Station name + freq badge */
.nk-frb-name {
  font-size: .85rem;
  font-weight: 700;
  color: #fff;
  display: flex;
  align-items: center;
  gap: .4rem;
  line-height: 1.2;
}
.nk-frb-freq {
  font-size: .62rem;
  font-weight: 700;
  background: rgba(255,255,255,.14);
  border: 1px solid rgba(255,255,255,.2);
  border-radius: 100px;
  padding: 1px 7px;
  color: rgba(255,255,255,.82);
  letter-spacing: .02em;
}
.nk-frb-loc {
  font-size: .72rem;
  color: rgba(255,255,255,.45);
  margin-top: 2px;
}

/* Full-width CTA play button */
.nk-frb-btn {
  width: 100%;
  margin-top: .7rem;
  background: linear-gradient(90deg, #1e3a8a 0%, #2563eb 45%, #0ea5e9 100%);
  color: #fff;
  border: none;
  border-radius: 10px;
  padding: .62rem 1rem;
  font-size: .82rem;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: .55rem;
  letter-spacing: .025em;
  position: relative;
  overflow: hidden;
  transition: transform .15s, box-shadow .2s;
  box-shadow: 0 4px 18px rgba(14,165,233,.4);
}
.nk-frb-btn::before {
  content: '';
  position: absolute;
  top: 0; left: -80%;
  width: 50%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,.22), transparent);
  animation: nkShimmer 2.8s ease-in-out infinite;
  pointer-events: none;
}
@keyframes nkShimmer {
  0%   { left: -80%; }
  100% { left: 160%; }
}
.nk-frb-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 26px rgba(14,165,233,.6);
}
.nk-frb-btn:active { transform: scale(.97); }
.nk-frb-btn .nk-frb-btn-icon { margin-left: auto; font-size: 1rem; opacity: .85; }

/* Live dot inside button */
.nk-frb-btn-dot {
  width: 8px; height: 8px;
  background: #f87171;
  border-radius: 50%;
  flex-shrink: 0;
  animation: rkBlink 1.4s ease-in-out infinite;
}
.nk-social-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px; height: 34px;
  border-radius: 8px;
  background: rgba(255,255,255,.07);
  color: #94a3b8;
  font-size: 1rem;
  margin-right: .4rem;
  transition: background .18s, color .18s;
  text-decoration: none;
}
.nk-social-link:hover { background: var(--nk-primary); color: #fff; }


/* ── 22. Páginas institucionales ────────────────────────── */
/* nosotros · contacto · términos · privacidad
   Esto vivía incrustado en las cuatro páginas: las tres primeras clases estaban
   copiadas cuatro veces, y cada archivo traía además su propio modo oscuro con
   colores fijos y !important que NO coincidían con los del sitio. Las tarjetas
   quedaban en #1e293b cuando el resto del sitio las pinta con --nk-surface. */

.masthead-mini {
  position: relative;
  background-color: #0f172a;
  min-height: 160px;
  display: flex;
  align-items: center;
  overflow: hidden;
}
.masthead-bg {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
  z-index: 0;
}
.masthead-content { position: relative; z-index: 10; width: 100%; }

/* Quiénes somos */
.stat-pill {
  background: rgba(59,130,246,.12);
  border: 1px solid rgba(59,130,246,.25);
  border-radius: var(--nk-radius-pill);
  padding: .55rem 1.2rem;
  font-size: .9rem; font-weight: 600; color: #60a5fa;
  display: inline-flex; align-items: center; gap: .5rem;
}
.team-card {
  border-radius: var(--nk-radius);
  border: 1px solid var(--nk-border);
  background: var(--nk-surface);
  padding: 1.75rem 1.5rem;
  text-align: center;
  transition: transform .2s, box-shadow .2s;
}
.team-card:hover { transform: translateY(-4px); box-shadow: var(--nk-shadow-lg); }
.team-avatar {
  width: 72px; height: 72px;
  border-radius: 50%;
  background: linear-gradient(135deg, #3b82f6, #6366f1);
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 1.8rem; font-weight: 700; color: #fff;
  margin-bottom: 1rem;
}
.value-icon {
  width: 48px; height: 48px;
  border-radius: var(--nk-radius-sm);
  background: rgba(59,130,246,.12);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.4rem; margin-bottom: .85rem;
}

/* Contacto */
.contact-info-card {
  background: linear-gradient(135deg, #1e3a5f 0%, #0f172a 100%);
  border: 1px solid rgba(255,255,255,.1);
  border-radius: var(--nk-radius);
  color: #e2e8f0;
}
.contact-info-card .info-item {
  display: flex; align-items: flex-start; gap: 14px;
  padding: 14px 0;
  border-bottom: 1px solid rgba(255,255,255,.08);
}
.contact-info-card .info-item:last-child { border-bottom: none; }
.contact-info-card .info-icon {
  width: 40px; height: 40px;
  background: rgba(96,165,250,.15);
  border-radius: var(--nk-radius-sm);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.1rem; color: #60a5fa; flex-shrink: 0;
}
.contact-info-card .info-label { font-size: .75rem; color: #94a3b8; margin-bottom: 2px; }
.contact-info-card .info-value { font-size: .9rem; color: #e2e8f0; font-weight: 500; }

.social-contact-btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 10px 18px; border-radius: var(--nk-radius-pill);
  font-size: .875rem; font-weight: 600; text-decoration: none;
  transition: opacity .2s; border: none;
}
.social-contact-btn:hover { opacity: .85; }
.social-contact-btn.fb { background: #1877f2; color: #fff; }
.social-contact-btn.ig { background: linear-gradient(135deg,#e1306c,#833ab4); color: #fff; }

/* Formularios y alertas en modo oscuro.
   estilos.css solo los cubria dentro de .nk-comment-form, asi que el formulario
   de contacto quedaba con fondo blanco sobre pagina oscura. */
:root.dark .form-control,
:root.dark .form-select {
  background: var(--nk-surface);
  border-color: var(--nk-border);
  color: var(--nk-text);
}
:root.dark .form-control::placeholder { color: var(--nk-text-muted); }
:root.dark .form-control:focus,
:root.dark .form-select:focus {
  background: var(--nk-surface);
  border-color: var(--nk-primary);
  color: var(--nk-text);
  box-shadow: 0 0 0 .2rem rgba(59,130,246,.25);
}
:root.dark .alert-success { background: #14532d; border-color: #166534; color: #bbf7d0; }
:root.dark .alert-danger  { background: #450a0a; border-color: #7f1d1d; color: #fecaca; }
:root.dark hr { border-color: var(--nk-border); }

/* ── 21. Print ──────────────────────────────────────────── */
@media print {
  .nk-header, .nk-topbar, .nk-catbar, .nk-ticker, .nk-radio-card,
  .ad-unit, .nk-espacio, .ad-banner-top, .ad-feed,
  .nk-share-bar, .nk-sidebar-section, .nk-footer,
  #darkToggle, .nk-header-btn { display: none !important; }
  .nk-article-body { font-size: 11pt; color: #000; box-shadow: none; }
  a::after { content: ' (' attr(href) ')'; font-size: 9pt; color: #666; }
}


/* ============================================================
   NK AUDIO — reproductor dentro de la nota + badge en tarjetas
   ============================================================ */
.nk-audio {
  margin: 1.75rem 0;
  padding: .85rem 1rem;
  background: var(--nk-surface-2);
  border: 1px solid var(--nk-border);
  border-left: 4px solid var(--nk-accent);
  border-radius: var(--nk-radius);
  box-shadow: var(--nk-shadow-sm);
}
.nk-audio audio {
  display: block;
  width: 100%;
  height: 40px;
}
.nk-audio figcaption {
  margin-top: .55rem;
  font-size: .85rem;
  line-height: 1.35;
  color: var(--nk-text-muted);
}
.nk-audio figcaption::before {
  content: "♪ ";
  color: var(--nk-accent);
  font-weight: 700;
}
:root.dark .nk-audio { background: rgba(255,255,255,.04); }
:root.dark .nk-audio audio { color-scheme: dark; }

/* Badge de audio sobre la miniatura de las tarjetas */
.nk-badge-audio {
  position: absolute;
  left: 8px;
  bottom: 8px;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: rgba(15, 23, 42, .82);
  color: #fff;
  font-size: .72rem;
  font-weight: 600;
  line-height: 1;
  padding: 5px 10px;
  border-radius: var(--nk-radius-pill);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  pointer-events: none;
}
.nk-badge-audio i { font-size: .85rem; }
@media (max-width: 575.98px) {
  .nk-badge-audio { font-size: .68rem; padding: 4px 8px; }
}

/* ── 23. La radio dentro del diario ─────────────────────── */
/* Franja de arriba (includes/cabecera.php). No es fija: se va con el scroll.
   Los datos los completa js/radio-ahora.js. */
.nk-radio-franja {
  background: linear-gradient(90deg, #0f2044 0%, #1d4ed8 100%);
  color: #fff;
  font-size: .82rem;
}
:root.dark .nk-radio-franja { background: linear-gradient(90deg, #0b1220 0%, #1e3a8a 100%); }
.nk-radio-franja .container {
  display: flex;
  align-items: center;
  gap: .6rem;
  min-height: 34px;
}
.nk-rf-vivo {
  flex: none;
  font-size: .62rem;
  font-weight: 800;
  letter-spacing: .05em;
  background: #ef4444;
  padding: 2px 8px;
  border-radius: 100px;
  animation: rkBlink 1.8s ease-in-out infinite;
}
.nk-radio-franja.fuera .nk-rf-vivo { background: rgba(255,255,255,.2); animation: none; }
.nk-rf-texto {
  flex: 1;
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.nk-rf-texto strong { font-weight: 700; }
.nk-rf-tema { opacity: .82; }
.nk-rf-btn {
  flex: none;
  display: inline-flex;
  align-items: center;
  gap: .25rem;
  padding: 3px 12px 3px 9px;
  border-radius: 100px;
  background: rgba(255,255,255,.16);
  color: #fff;
  font-weight: 700;
  font-size: .78rem;
  text-decoration: none;
  transition: background .2s;
}
.nk-rf-btn:hover, .nk-rf-btn:focus-visible { background: rgba(255,255,255,.3); color: #fff; }
.nk-rf-btn.sonando { background: #fff; color: #1d4ed8; }
.nk-rf-link {
  flex: none;
  color: rgba(255,255,255,.8);
  font-size: .78rem;
  text-decoration: none;
}
.nk-rf-link:hover { color: #fff; text-decoration: underline; }
@media (max-width: 600px) {
  .nk-rf-tema, .nk-rf-link { display: none; }
}

/* "Radio en vivo" en el menu, con su punto rojo */
.nk-inline-nav .nk-nav-radio::before {
  content: '';
  display: inline-block;
  width: 7px; height: 7px;
  margin-right: .35rem;
  border-radius: 50%;
  background: #ef4444;
  vertical-align: 1px;
  animation: rkBlink 1.8s ease-in-out infinite;
}

/* El recuadro lateral: lo que esta al aire (includes/radio_card.php) */
.nk-rw-ahora { margin: -.35rem 0 .9rem; font-size: .82rem; }
.nk-rw-fila { display: flex; align-items: baseline; gap: .45rem; min-width: 0; }
.nk-rw-label {
  flex: none;
  font-size: .6rem;
  font-weight: 800;
  letter-spacing: .06em;
  color: rgba(255,255,255,.6);
}
.nk-rw-prog { font-weight: 700; color: #fff; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.nk-rw-sub { color: rgba(255,255,255,.72); min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.nk-rw-ahora > .nk-rw-sub { margin: .1rem 0 0 2.6rem; }
.nk-rw-tema {
  display: flex;
  align-items: center;
  gap: .55rem;
  margin: .55rem 0;
  padding: .4rem .5rem;
  border-radius: 10px;
  background: rgba(255,255,255,.09);
}
.nk-rw-tema img { flex: none; width: 38px; height: 38px; border-radius: 6px; object-fit: cover; background: rgba(255,255,255,.12); }
.nk-rw-tema span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 600; color: #fff; }
.nk-rw-links { display: flex; flex-wrap: wrap; gap: .4rem 1rem; margin-top: .9rem; font-size: .78rem; }
.nk-rw-links a { color: rgba(255,255,255,.85); text-decoration: none; }
.nk-rw-links a:hover { color: #fff; text-decoration: underline; }
.nk-rw-links i { margin-right: .2rem; }
.nk-rf-fuera { opacity: .82; }
.nk-rw-live-badge.fuera { background: rgba(255,255,255,.2); animation: none; }

/* Agenda del dia (HOY EN LA RADIO): lista compacta, ancho completo del widget.
   .is-ahora se destaca; .paso queda opaco. */
.nk-rw-agenda { margin-top: .9rem; padding-top: .8rem; border-top: 1px solid rgba(255,255,255,.08); }
.nk-rw-agenda .nk-rw-label { margin-bottom: .5rem; display: block; }
.nk-rw-agenda-lista { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 2px; }
.nk-rw-ag-item {
  display: grid;
  grid-template-columns: 44px 1fr auto;
  align-items: baseline;
  gap: .1rem .5rem;
  padding: .35rem .5rem;
  border-radius: 6px;
  font-size: .78rem;
  color: rgba(255,255,255,.82);
  transition: background .15s ease;
}
.nk-rw-ag-item:hover { background: rgba(255,255,255,.04); }
.nk-rw-ag-hora { font-family: var(--nk-mono, ui-monospace, monospace); font-weight: 600; color: rgba(255,255,255,.55); font-size: .74rem; letter-spacing: .04em; }
.nk-rw-ag-nom  { font-weight: 600; color: #fff; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.nk-rw-ag-meta { color: rgba(255,255,255,.55); font-size: .72rem; text-align: right; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; grid-column: 2 / -1; }
.nk-rw-ag-item.is-ahora { background: rgba(59,130,246,.14); }
.nk-rw-ag-item.is-ahora .nk-rw-ag-hora { color: #60a5fa; }
.nk-rw-ag-item.is-ahora .nk-rw-ag-nom::after {
  content: "AL AIRE"; margin-left: .4rem; padding: 1px 6px; border-radius: 999px;
  background: rgba(59,130,246,.25); color: #93c5fd;
  font: 600 9px/1.4 var(--nk-mono, ui-monospace, monospace); letter-spacing: .06em; vertical-align: 1px;
}
.nk-rw-ag-item.paso { opacity: .42; }
.nk-rw-ag-item.paso .nk-rw-ag-nom { text-decoration: line-through; }
