/* ============================================================
   CTV Peru — Brand CSS (Bootstrap 5 supplement)
   Solo lo que Bootstrap no cubre nativamente
   ============================================================ */

/* ── Google Font ──────────────────────────────────────────── */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800;900&display=swap');

/* ── Variables ────────────────────────────────────────────── */
:root {
  --rojo: #CC0000;
  --rojo-oscuro: #aa0000;
  --negro: #111111;
}

/* ── Base ─────────────────────────────────────────────────── */
body { font-family: 'Inter', system-ui, sans-serif; }
a { text-decoration: none; }
a:hover { text-decoration: none; }
img { max-width: 100%; }

/* ── Bootstrap overrides ──────────────────────────────────── */
.bg-negro  { background-color: var(--negro) !important; }
.bg-ctv    { background-color: var(--rojo)  !important; }
.text-ctv  { color: var(--rojo) !important; }
.btn-ctv   { background: var(--rojo); color: #fff; border: none; }
.btn-ctv:hover, .btn-ctv:focus { background: var(--rojo-oscuro); color: #fff; }
.border-ctv { border-color: var(--rojo) !important; }
.form-control:focus, .form-select:focus {
  border-color: var(--rojo);
  box-shadow: 0 0 0 .2rem rgba(204,0,0,.15);
}

/* ── Navbar ───────────────────────────────────────────────── */
.navbar { border-bottom: 2px solid var(--rojo); }
.navbar-nav .nav-link {
  font-size: 12px; text-transform: uppercase;
  letter-spacing: .5px; font-weight: 600;
  padding: 8px 12px !important;
}
.btn-live {
  background: var(--rojo); color: #fff;
  font-size: 11px; font-weight: 700;
  text-transform: uppercase; letter-spacing: 1px;
  padding: 8px 18px; border-radius: 6px;
  display: inline-flex; align-items: center; gap: 6px;
  border: none; white-space: nowrap;
}
.btn-live:hover { background: var(--rojo-oscuro); color: #fff; }

/* ── Live dot ─────────────────────────────────────────────── */
.live-dot {
  display: inline-block; width: 8px; height: 8px;
  background: currentColor; border-radius: 50%;
  animation: pulse-dot 1.2s ease-in-out infinite; flex-shrink: 0;
}
.btn-live .live-dot { background: #fff; }
@keyframes pulse-dot {
  0%,100% { opacity:1; transform:scale(1) }
  50%      { opacity:.35; transform:scale(.55) }
}

/* ── Ticker (breaking news) ───────────────────────────────── */
.ticker {
  height: 40px; overflow: hidden;
  background: var(--negro);
}
.ticker-inner { display: flex; align-items: center; height: 100%; }
.ticker-label {
  background: var(--rojo); color: #fff;
  font-size: 10px; font-weight: 700;
  text-transform: uppercase; letter-spacing: 2px;
  padding: 0 18px; height: 100%;
  display: flex; align-items: center; white-space: nowrap; gap: 8px; flex-shrink: 0;
}
.ticker-wrap { flex: 1; overflow: hidden; position: relative; }
.ticker-items {
  display: flex; animation: ticker-move 40s linear infinite;
  white-space: nowrap;
}
.ticker-items:hover { animation-play-state: paused; }
.ticker-item {
  padding: 0 30px; font-size: 13px;
  color: rgba(255,255,255,.8); white-space: nowrap;
  display: flex; align-items: center; gap: 8px;
}
.ticker-sep { color: var(--rojo); }
@keyframes ticker-move { from{transform:translateX(0)} to{transform:translateX(-50%)} }

/* ── Cat badge ────────────────────────────────────────────── */
.cat-badge {
  display: inline-block; background: var(--rojo); color: #fff;
  font-size: 10px; font-weight: 700;
  text-transform: uppercase; letter-spacing: .8px;
  padding: 3px 8px; border-radius: 3px;
}

/* ── Banner slider ────────────────────────────────────────── */
.banner-slide { display: none; }
.banner-slide.active { display: block; }
.banner-dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: rgba(255,255,255,.4); cursor: pointer;
  border: none; padding: 0; transition: background .2s;
}
.banner-dot.active { background: #fff; }

/* ── News card thumbnail ──────────────────────────────────── */
.news-thumb { position: relative; overflow: hidden; }
.news-thumb img {
  width: 100%; aspect-ratio: 16/9;
  object-fit: cover; display: block;
  transition: transform .35s;
}
.card:hover .news-thumb img { transform: scale(1.04); }
.news-thumb .cat-badge { position: absolute; top: 10px; left: 10px; }

/* ── Hero ─────────────────────────────────────────────────── */
.hero-section { padding: 28px 0 0; }
.hero-main-wrap { position: relative; overflow: hidden; border-radius: 8px 0 0 8px; height: 100%; }
@media (max-width: 991.98px) { .hero-main-wrap { border-radius: 8px 8px 0 0; height: auto; } }
.hero-main-wrap > a { display: block; height: 100%; }
.hero-main-wrap img {
  width: 100%; height: 100%; min-height: 320px;
  aspect-ratio: 16/10; object-fit: cover; display: block;
}
.hero-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,.92) 0%, rgba(0,0,0,.35) 50%, transparent 100%);
}
.hero-overlay-body {
  position: absolute; bottom: 0; left: 0; right: 0;
  padding: 50px 22px 22px;
}
.hero-overlay-body h1 {
  color: #fff; font-size: clamp(17px, 2.1vw, 26px);
  font-weight: 800; line-height: 1.22; margin: 8px 0 8px;
}
.hero-overlay-body p  { color: rgba(255,255,255,.8); font-size: 13px; line-height: 1.5; margin: 0 0 8px; }
.hero-time { color: rgba(255,255,255,.6); font-size: 12px; }
.hero-meta { color: rgba(255,255,255,.5); font-size: 12px; display: flex; gap: 10px; }

/* ── Hero sidebar panel ───────────────────────────────────── */
.hero-sidebar-panel {
  border: 1px solid #e8e8e8;
  border-left: none;
  border-radius: 0 8px 8px 0;
  overflow: hidden;
  height: 100%;
  display: flex; flex-direction: column;
}
@media (max-width: 991.98px) {
  .hero-sidebar-panel { border-left: 1px solid #e8e8e8; border-radius: 0 0 8px 8px; }
}
.hero-sidebar-head {
  background: #fafafa; border-bottom: 2px solid var(--rojo);
  padding: 10px 14px; display: flex; align-items: center; justify-content: space-between;
  flex-shrink: 0;
}
.section-label { font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: 1.5px; color: #111; margin: 0; }
.section-more { font-size: 11px; color: var(--rojo); font-weight: 600; }
.section-more:hover { text-decoration: underline !important; }
.hero-sidebar-list { flex: 1; overflow: hidden; }
.brief-row {
  display: flex; gap: 12px; padding: 11px 14px;
  border-bottom: 1px solid #f2f2f2;
  color: inherit; transition: background .15s;
}
.brief-row:last-child { border-bottom: none; }
.brief-row:hover { background: #fef5f5; }
.brief-thumb { width: 70px; height: 52px; border-radius: 4px; overflow: hidden; flex-shrink: 0; }
.brief-thumb img { width: 100%; height: 100%; object-fit: cover; }
.brief-kicker { font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: .7px; display: block; margin-bottom: 3px; }
.brief-title { font-size: 12px; font-weight: 700; line-height: 1.35; color: #111; margin: 0 0 4px; }
.brief-meta  { font-size: 11px; color: #999; }

/* ── Hero 2x2 grid cuadrados ─────────────────────────────── */
.hero-grid4 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-template-rows: 1fr 1fr;
  gap: 3px;
  border-radius: 0 8px 8px 0;
  overflow: hidden;
}
@media (max-width: 991.98px) {
  .hero-grid4 { border-radius: 0 0 8px 8px; }
}
.hero-sq {
  position: relative;
  overflow: hidden;
  display: block;
  background: #111;
}
.hero-sq img {
  width: 100%; height: 100%;
  object-fit: cover; display: block;
  transition: transform .5s ease;
}
.hero-sq:hover img { transform: scale(1.08); }

.hero-sq-noimg { width: 100%; height: 100%; background: #222; }

.hero-sq-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,.85) 0%, rgba(0,0,0,.1) 60%, transparent 100%);
  display: flex; flex-direction: column; justify-content: flex-end;
  padding: 10px;
  transform: translateY(30%);
  transition: transform .35s cubic-bezier(.4,0,.2,1);
}
.hero-sq:hover .hero-sq-overlay { transform: translateY(0); }

.hero-sq-cat {
  font-size: 9px; font-weight: 700;
  text-transform: uppercase; letter-spacing: .8px;
  margin-bottom: 3px; display: block;
}
.hero-sq-title {
  color: #fff; font-size: 11px; font-weight: 700;
  line-height: 1.3;
}

/* ── Now playing bar ──────────────────────────────────────── */
.now-playing-bar { background: var(--negro); color: #fff; }

/* ── Program card ─────────────────────────────────────────── */
.prog-img { position: relative; overflow: hidden; }
.prog-img img { width: 100%; aspect-ratio: 3/4; object-fit: cover; display: block; transition: transform .35s; }
.card:hover .prog-img img { transform: scale(1.04); }
.on-air-badge {
  position: absolute; top: 8px; left: 8px;
  background: var(--rojo); color: #fff;
  font-size: 10px; font-weight: 700; text-transform: uppercase;
  padding: 3px 8px; border-radius: 3px;
  display: flex; align-items: center; gap: 4px;
}
.prog-dia-tag {
  display: inline-block; background: #f0f0f0;
  font-size: 10px; font-weight: 600; padding: 2px 7px;
  border-radius: 3px; color: #444; margin: 1px;
}

/* ── Article page ─────────────────────────────────────────── */
.article-content img { max-width: 100%; height: auto; border-radius: 6px; margin: 12px 0; }
.article-content p { line-height: 1.85; margin-bottom: 1.3rem; }
.article-content h2, .article-content h3 { font-weight: 800; margin: 1.6rem 0 .8rem; }
.article-summary {
  font-size: 17px; font-weight: 500; color: #444;
  border-left: 3px solid var(--rojo);
  padding-left: 16px; margin-bottom: 24px; line-height: 1.65;
}
.share-btn { padding: 6px 14px; border-radius: 4px; font-size: 12px; font-weight: 700; color: #fff; display: inline-block; }
.share-btn.fb { background: #1877f2; }
.share-btn.tw { background: #1da1f2; }
.share-btn.wa { background: #25d366; }
.tag-item { display: inline-block; background: #f5f5f5; color: #444; font-size: 12px; padding: 4px 10px; border-radius: 20px; margin: 2px; }

/* ── Sidebar widget ───────────────────────────────────────── */
.widget-title {
  font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 1.5px;
  background: var(--negro); color: #fff;
  padding: 10px 14px; border-left: 3px solid var(--rojo); margin-bottom: 0;
}
.widget-cat-item {
  display: flex; align-items: center; justify-content: space-between;
  padding: 9px 14px; border-bottom: 1px solid #f5f5f5;
  color: #333; font-size: 13px; font-weight: 500;
}
.widget-cat-item:last-child { border-bottom: none; }
.widget-cat-item:hover { background: #fef5f5; color: var(--rojo); }
.widget-news-item { display: flex; gap: 10px; padding: 10px 14px; border-bottom: 1px solid #f5f5f5; }
.widget-news-item:last-child { border-bottom: none; }
.widget-news-item:hover { background: #fef5f5; }
.widget-news-thumb { width: 60px; height: 45px; border-radius: 4px; overflow: hidden; flex-shrink: 0; }
.widget-news-thumb img { width: 100%; height: 100%; object-fit: cover; }
.widget-news-title { font-size: 12px; font-weight: 700; line-height: 1.35; color: #111; }

/* ── Live page ────────────────────────────────────────────── */
.live-hero-section { background: #111; }
.live-player iframe { width: 100%; aspect-ratio: 16/9; border: none; display: block; }

/* ── Breadcrumb ───────────────────────────────────────────── */
.ctv-breadcrumb { font-size: 12px; color: #888; padding: 10px 0; }
.ctv-breadcrumb a { color: #666; }
.ctv-breadcrumb a:hover { color: var(--rojo); }
.ctv-breadcrumb span { color: #aaa; margin: 0 4px; }

/* ── Offcanvas fullscreen mobile menu ─────────────────────── */
@media (max-width: 991.98px) {
  .offcanvas.offcanvas-start { width: 100% !important; }
}
.offcanvas-nav-link {
  display: flex; justify-content: space-between; align-items: center;
  padding: 14px 20px; color: rgba(255,255,255,.85);
  font-size: 15px; font-weight: 600;
  border-bottom: 1px solid rgba(255,255,255,.06);
}
.offcanvas-nav-link:hover, .offcanvas-nav-link.active {
  background: rgba(255,255,255,.06); color: #fff;
}
.mobile-cat-btn {
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.12);
  border-left: 3px solid var(--cat-color, var(--rojo));
  color: #fff; border-radius: 6px;
  padding: 10px 12px; font-size: 12px; font-weight: 600;
  display: block; text-align: left;
}
.mobile-cat-btn:hover { background: rgba(255,255,255,.12); color: #fff; }

/* ── Search overlay ───────────────────────────────────────── */
.search-modal .modal-content { border-radius: 0; border: none; border-bottom: 2px solid var(--rojo); }
.search-modal .modal-body { padding: 20px 24px 16px; }
.search-form-inner {
  display: flex; align-items: center; gap: 12px;
  background: #f7f7f7; border-radius: 8px;
  padding: 12px 16px; border: 1px solid #e0e0e0;
}
.search-form-inner:focus-within { border-color: var(--rojo); background: #fff; }
.search-form-inner input {
  flex: 1; border: none; background: none; outline: none;
  font-size: 17px; color: #111;
}
.search-form-inner svg { flex-shrink: 0; }
.search-hint { font-size: 12px; color: #aaa; margin-top: 8px; padding-left: 4px; }

/* ── Footer ───────────────────────────────────────────────── */
.footer-logo { height: 38px; width: auto; }
.footer-link { color: rgba(255,255,255,.6); font-size: 13px; display: block; padding: 3px 0; }
.footer-link:hover { color: #fff; }
.footer-h { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 1.5px; color: rgba(255,255,255,.4); margin-bottom: 14px; }

/* ── sr-only ──────────────────────────────────────────────── */
.sr-only { position: absolute; width:1px; height:1px; padding:0; margin:-1px; overflow:hidden; clip:rect(0,0,0,0); white-space:nowrap; border:0; }
