/* ==========================================================
   "Live 24 National" website theme — red & black TV-channel look.
   Loaded only when this theme is active (body.tpl-live24).
   ========================================================== */
body.tpl-live24 { --l24: var(--red, #D7141A); --l24d: color-mix(in srgb, var(--l24) 72%, #000); --radius: 6px; --wrap: 1320px; }
body.tpl-live24 .sh h2::before { width: 4px; border-radius: 0; }

/* ---------- Top bar ---------- */
.l24-top { background: #0B0B0B; color: #D1D5DB; font-size: 12.5px; }
.l24-top .wrap { display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 34px; flex-wrap: wrap; }
.l24-top .l, .l24-top .r { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.l24-top .sep { opacity: .3; }
.l24-top b { color: #fff; font-weight: 600; }
.l24-top .r > a { color: #E5E7EB; font-weight: 600; display: inline-flex; align-items: center; gap: 6px; }
.l24-top .r > a:hover { color: #fff; }
.l24-top .r > a:first-child { color: #fff; } .l24-top .r > a:first-child i { color: #FF4D4D; }
.l24-top .soc { display: flex; gap: 6px; margin-left: 4px; }
.l24-top .soc-i { width: 22px; height: 22px; font-size: 11px; }

/* ---------- Logo · banner · LIVE TV ---------- */
.l24-head { background: #fff; border-bottom: 1px solid #E5E7EB; }
.l24-head .wrap { display: flex; align-items: center; gap: 22px; min-height: 104px; padding-top: 10px; padding-bottom: 10px; }
.l24-logo { display: inline-flex; flex-direction: column; align-items: center; flex-shrink: 0; line-height: 1; }
.l24-logo .mk { display: inline-flex; align-items: stretch; border-radius: 6px; overflow: hidden; box-shadow: 0 6px 16px rgba(215,20,26,.25); }
.l24-logo .mk b { background: var(--l24); color: #fff; font: 900 38px/1 'Poppins', var(--font), sans-serif; padding: 8px 12px 6px; letter-spacing: -1px; }
.l24-logo .mk i { font-style: normal; background: #fff; color: var(--l24); border: 3px solid var(--l24); border-left: 0; border-radius: 0 6px 6px 0; font: 900 26px/1 'Poppins', var(--font), sans-serif; padding: 0 9px; display: flex; align-items: center; }
.l24-logo .img { height: 92px; width: auto; max-width: 320px; object-fit: contain; display: block; }
.l24-logo .tg { font-size: 13.5px; font-weight: 700; color: #111; margin-top: 6px; letter-spacing: .2px; max-width: 220px; text-align: center; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.l24-banner { flex: 1; min-width: 0; display: flex; justify-content: center; }
.l24-banner .ad { display: block; max-width: 728px; width: 100%; }
.l24-banner .ad img { width: 100%; max-height: 90px; object-fit: cover; border-radius: 4px; }
.l24-banner .promo { width: 100%; max-width: 728px; height: 84px; border-radius: 6px; display: flex; align-items: center; gap: 16px; padding: 0 20px; color: #fff;
    background: radial-gradient(circle at 85% 50%, rgba(255,255,255,.18), transparent 35%), linear-gradient(100deg, #0B0B0B 0%, #3B0507 45%, var(--l24) 100%); position: relative; overflow: hidden; }
.l24-banner .promo::after { content: ''; position: absolute; inset: 0; background: repeating-linear-gradient(115deg, transparent 0 22px, rgba(255,255,255,.04) 22px 44px); }
.l24-banner .promo .pl { width: 48px; height: 48px; border-radius: 50%; background: var(--l24); display: grid; place-items: center; font-size: 20px; flex-shrink: 0; box-shadow: 0 0 0 6px rgba(215,20,26,.25); position: relative; z-index: 1; }
.l24-banner .promo .pt { flex: 1; min-width: 0; position: relative; z-index: 1; }
.l24-banner .promo .pt b { display: block; font-size: 24px; font-weight: 800; color: #FFD43B; }
.l24-banner .promo .pt small { font-size: 13px; color: #E5E7EB; }
.l24-banner .promo .pb { background: #fff; color: var(--l24); font-weight: 700; font-size: 13.5px; padding: 8px 14px; border-radius: 30px; white-space: nowrap; position: relative; z-index: 1; }
.l24-livebtn { flex-shrink: 0; display: inline-flex; align-items: center; gap: 10px; background: var(--l24); color: #fff !important; border-radius: 8px; padding: 10px 16px 10px 12px; position: relative; box-shadow: 0 10px 22px rgba(215,20,26,.3); }
.l24-livebtn:hover { background: var(--l24d); }
.l24-livebtn .pi { width: 42px; height: 30px; border-radius: 8px; background: #fff; color: var(--l24); display: grid; place-items: center; font-size: 15px; }
.l24-livebtn b { display: block; font: 800 21px/1 'Poppins', sans-serif; letter-spacing: .5px; }
.l24-livebtn small { display: block; font: 600 11px 'Poppins', var(--font), sans-serif; letter-spacing: 1px; opacity: .9; margin-top: 3px; }
.l24-livebtn em { position: absolute; top: -5px; right: -5px; width: 14px; height: 14px; border-radius: 50%; background: #22C55E; border: 2px solid #fff; animation: grPulse 1.4s infinite; }

/* ---------- Red menu ---------- */
.l24-nav { background: var(--l24); position: sticky; top: 0; z-index: 120; box-shadow: 0 4px 14px rgba(0,0,0,.15); }
.l24-nav > .wrap { display: flex; align-items: stretch; min-height: 46px; position: relative; }
.l24-nav .links { display: flex; align-items: stretch; flex: 1; min-width: 0; overflow-x: auto; scrollbar-width: none; }
.l24-nav .links::-webkit-scrollbar { display: none; }
.l24-nav .n { color: #fff; font-size: 15.5px; font-weight: 700; padding: 0 13px; display: inline-flex; align-items: center; gap: 7px; white-space: nowrap; background: none; border: 0; cursor: pointer; font-family: inherit; position: relative; }
.l24-nav .n:hover, .l24-nav .n.on { background: var(--l24d); }
.l24-nav .n.on::after { content: ''; position: absolute; left: 10px; right: 10px; bottom: 0; height: 3px; background: #FFD43B; }
.l24-nav .n.home { background: #0B0B0B; padding: 0 16px; }
.l24-nav .n.home.on::after { display: none; }
.l24-nav .n.ic { font-size: 16px; padding: 0 14px; }
.l24-nav .menu-btn { display: none; }
.l24-nav .dd { position: relative; display: flex; }
.l24-nav .dd-menu { display: none; position: absolute; top: 100%; right: 0; background: #fff; border-radius: 0 0 8px 8px; box-shadow: 0 18px 40px rgba(0,0,0,.2); padding: 8px 0; min-width: 190px; max-height: 60vh; overflow: auto; z-index: 130; }
.l24-nav .dd:hover .dd-menu, .l24-nav .dd:focus-within .dd-menu { display: block; }
.l24-nav .dd-menu a { display: block; padding: 7px 16px; font-size: 14.5px; color: #111; }
.l24-nav .dd-menu a:hover { background: #FEF2F2; color: var(--l24); }
.l24-search { display: none; position: absolute; right: 16px; top: 100%; background: #fff; padding: 10px; border-radius: 0 0 10px 10px; box-shadow: 0 18px 40px rgba(0,0,0,.2); gap: 8px; z-index: 131; width: min(440px, calc(100% - 32px)); }
.l24-search.show { display: flex; }
.l24-search input { flex: 1; min-width: 0; border: 1px solid #E5E7EB; border-radius: 6px; padding: 9px 12px; font: 15px var(--font), sans-serif; }
.l24-search button { background: var(--l24); color: #fff; border: 0; border-radius: 6px; padding: 0 14px; font-weight: 700; cursor: pointer; font-family: inherit; }

/* ---------- Breaking ---------- */
.l24-brk { background: #fff; border-bottom: 1px solid #E5E7EB; }
.l24-brk .wrap { display: flex; align-items: center; gap: 12px; min-height: 44px; }
.l24-brk .lbl { background: var(--l24); color: #fff; font: 700 13px 'Poppins', sans-serif; padding: 7px 14px; border-radius: 4px; white-space: nowrap; display: inline-flex; align-items: center; gap: 7px; }
.l24-brk .lbl i { color: #FFD43B; }
.l24-brk .track { flex: 1; overflow: hidden; mask-image: linear-gradient(90deg, transparent, #000 2%, #000 98%, transparent); }
.l24-brk .run { display: inline-flex; white-space: nowrap; animation: tick 50s linear infinite; }
.l24-brk:hover .run { animation-play-state: paused; }
.l24-brk .run a { font-size: 14.5px; font-weight: 600; color: #111; padding: 0 16px; border-right: 2px solid #D1D5DB; }
.l24-brk .run a:hover { color: var(--l24); }
.l24-brk .x { width: 28px; height: 28px; border-radius: 50%; border: 0; background: #F3F4F6; color: #111; cursor: pointer; flex-shrink: 0; }

/* ---------- Row 1 ---------- */
.l24-row1 { display: grid; grid-template-columns: minmax(0, 1.7fr) minmax(0, 1.05fr) minmax(0, .95fr); gap: 14px; margin-top: 16px; }
.l24-slider { position: relative; border-radius: var(--radius); overflow: hidden; background: #111; min-height: 440px; }
.l24-slider .sl { position: absolute; inset: 0; opacity: 0; transition: opacity .6s; }
.l24-slider .sl.on { opacity: 1; z-index: 1; }
.l24-slider .sl img, .l24-slider .sl .ph { width: 100%; height: 100%; object-fit: cover; }
.l24-slider .shade { position: absolute; inset: 0; background: linear-gradient(180deg, transparent 35%, rgba(0,0,0,.88)); }
.l24-slider .cap { position: absolute; left: 0; right: 0; bottom: 0; padding: 22px 24px 36px; color: #fff; }
.l24-slider .cap b { display: -webkit-box; font-size: 30px; line-height: 1.3; font-weight: 800; margin: 10px 0 8px; text-shadow: 0 2px 10px rgba(0,0,0,.4); }
.l24-slider .cap small { font-size: 13px; color: #E5E7EB; display: inline-flex; gap: 6px; align-items: center; }
.l24-tag { display: inline-block; background: var(--l24, #D7141A); color: #fff; font-size: 12.5px; font-weight: 700; padding: 3px 9px; border-radius: 3px; }
.l24-slider .arr { position: absolute; top: 50%; transform: translateY(-50%); z-index: 2; width: 38px; height: 38px; border-radius: 50%; border: 0; background: rgba(0,0,0,.5); color: #fff; cursor: pointer; }
.l24-slider .arr:hover { background: var(--l24); }
.l24-slider .arr.p { left: 12px; } .l24-slider .arr.n { right: 12px; }
.l24-slider .dots { position: absolute; z-index: 2; left: 24px; bottom: 14px; display: flex; gap: 6px; }
.l24-slider .dots button { width: 9px; height: 9px; border-radius: 50%; border: 0; background: rgba(255,255,255,.55); cursor: pointer; padding: 0; }
.l24-slider .dots button.on { background: var(--l24); width: 24px; border-radius: 6px; }
.l24-side { display: grid; grid-template-rows: repeat(3, 1fr); gap: 10px; }
.l24-side .sc { display: grid; grid-template-columns: 44% minmax(0, 1fr); background: #141414; color: #fff; border-radius: var(--radius); overflow: hidden; min-height: 0; }
.l24-side .im img, .l24-side .im .ph { width: 100%; height: 100%; object-fit: cover; }
.l24-side .tx { padding: 10px 12px; display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.l24-side .tx .l24-tag { align-self: flex-start; font-size: 11.5px; padding: 2px 7px; }
.l24-side .tx b { font-size: 15px; line-height: 1.45; font-weight: 700; }
.l24-side .tx small { color: #9CA3AF; font-size: 12px; margin-top: auto; }
.l24-side .sc:hover b { color: #FFD43B; }
.l24-right { display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.l24-tv { background: #0B0B0B; border-radius: var(--radius); overflow: hidden; }
.l24-tv .hd { display: flex; align-items: center; justify-content: space-between; padding: 8px 12px; color: #fff; font: 800 14px 'Poppins', sans-serif; }
.l24-tv .hd span { background: var(--l24); padding: 3px 9px; border-radius: 3px; display: inline-flex; gap: 6px; align-items: center; }
.l24-tv .hd em { font-style: normal; font-size: 11.5px; color: #fff; display: inline-flex; align-items: center; gap: 5px; }
.l24-tv .hd em i { width: 8px; height: 8px; border-radius: 50%; background: #FF3B3B; animation: grPulse 1.4s infinite; }
.l24-tv .pv { display: block; position: relative; aspect-ratio: 16 / 9; background: #111; }
.l24-tv .pv img { width: 100%; height: 100%; object-fit: cover; opacity: .9; }
.l24-tv .pl, .l24-col .pl { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); width: 52px; height: 52px; border-radius: 50%; background: rgba(215,20,26,.92); color: #fff; display: grid; place-items: center; font-size: 18px; box-shadow: 0 0 0 6px rgba(255,255,255,.2); }
.l24-tv .pv:hover .pl { transform: translate(-50%, -50%) scale(1.08); }
.l24-tv .nm { position: absolute; left: 0; right: 0; bottom: 0; padding: 18px 10px 8px; background: linear-gradient(transparent, rgba(0,0,0,.85)); color: #fff; font-size: 13px; font-weight: 600; }
.l24-top5 { background: #fff; border: 1px solid #E5E7EB; border-radius: var(--radius); flex: 1; padding: 4px 12px 8px; }
.l24-top5 .hd { font-size: 17px; font-weight: 800; color: #111; padding: 8px 0; border-bottom: 2px solid var(--l24); margin-bottom: 4px; display: flex; gap: 8px; align-items: center; }
.l24-top5 .hd i { color: var(--l24); }
.l24-top5 a { display: flex; gap: 10px; align-items: flex-start; padding: 7px 0; border-bottom: 1px dashed #E5E7EB; font-size: 14px; font-weight: 600; color: #1F2937; line-height: 1.45; }
.l24-top5 a:last-child { border-bottom: 0; }
.l24-top5 a:hover { color: var(--l24); }
.l24-top5 .no { font: 800 16px 'Poppins', sans-serif; color: var(--l24); min-width: 24px; }

/* ---------- Category tiles ---------- */
.l24-tiles { display: grid; grid-template-columns: repeat(13, minmax(0, 1fr)); gap: 8px; margin-top: 16px; }
.l24-tiles .tl { display: block; border-radius: var(--radius); overflow: hidden; background: #111; }
.l24-tiles .im { display: block; position: relative; aspect-ratio: 1 / .78; }
.l24-tiles .im img, .l24-tiles .im .ph { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .3s; }
.l24-tiles .tl:hover img { transform: scale(1.08); }
.l24-tiles .ic { position: absolute; right: 5px; top: 5px; width: 24px; height: 24px; border-radius: 50%; background: rgba(0,0,0,.55); color: #fff; display: grid; place-items: center; font-size: 11px; }
.l24-tiles .lb { display: block; text-align: center; color: #fff; font-size: 13.5px; font-weight: 700; padding: 6px 4px; background: linear-gradient(180deg, var(--l24), var(--l24d)); }

/* ---------- Four columns ---------- */
.l24-cols { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; margin-top: 22px; }
.l24-col { background: #fff; border: 1px solid #E5E7EB; border-radius: var(--radius); padding: 12px; min-width: 0; }
.l24-col .hd, .l24-sh { display: flex; align-items: center; justify-content: space-between; border-bottom: 2px solid #E5E7EB; margin-bottom: 12px; padding-bottom: 6px; position: relative; }
.l24-col .hd::after, .l24-sh::after { content: ''; position: absolute; left: 0; bottom: -2px; width: 70px; height: 2px; background: var(--l24); }
.l24-col .hd h2, .l24-sh h2 { margin: 0; font-size: 19px; font-weight: 800; color: #111; display: flex; align-items: center; gap: 8px; }
.l24-col .hd h2::before, .l24-sh h2::before { content: ''; width: 4px; height: 20px; background: var(--l24); }
.l24-col .hd a, .l24-sh a { font-size: 12.5px; color: var(--l24); font-weight: 700; white-space: nowrap; }
.l24-col .big { display: block; margin-bottom: 10px; }
.l24-col .big .im { display: block; position: relative; aspect-ratio: 16 / 10; border-radius: 4px; overflow: hidden; }
.l24-col .im img, .l24-col .im .ph { width: 100%; height: 100%; object-fit: cover; }
.l24-col .big b { display: -webkit-box; font-size: 16px; line-height: 1.45; font-weight: 800; color: #111; margin: 9px 0 4px; }
.l24-col small { font-size: 12px; color: #6B7280; }
.l24-col .sm { display: grid; grid-template-columns: 96px minmax(0, 1fr); gap: 10px; padding: 9px 0; border-top: 1px solid #F1F5F9; }
.l24-col .sm .im { display: block; position: relative; aspect-ratio: 16 / 11; border-radius: 4px; overflow: hidden; }
.l24-col .sm b { display: -webkit-box; font-size: 13.5px; line-height: 1.45; font-weight: 700; color: #1F2937; margin-bottom: 3px; }
.l24-col a:hover b { color: var(--l24); }
.l24-col.vid { background: #0B0B0B; border-color: #0B0B0B; }
.l24-col.vid .hd { border-bottom-color: #262626; } .l24-col.vid .hd h2 { color: #fff; }
.l24-col.vid b { color: #fff !important; } .l24-col.vid a:hover b { color: #FFD43B !important; }
.l24-col.vid .sm { border-top-color: #262626; }
.l24-col.vid small { color: #9CA3AF; }
.l24-col.vid .sm .pl { width: 28px; height: 28px; font-size: 10px; box-shadow: none; }

/* ---------- Latest strip ---------- */
.l24-latest { margin-top: 24px; }
.l24-latest .grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.l24-latest .it { display: block; background: #fff; border: 1px solid #E5E7EB; border-radius: var(--radius); overflow: hidden; padding-bottom: 10px; }
.l24-latest .im { display: block; position: relative; aspect-ratio: 16 / 9.5; }
.l24-latest .im img, .l24-latest .im .ph { width: 100%; height: 100%; object-fit: cover; }
.l24-latest .im .l24-tag { position: absolute; left: 8px; top: 8px; font-size: 11.5px; }
.l24-latest b { display: -webkit-box; margin: 9px 12px 5px; font-size: 15px; line-height: 1.45; font-weight: 700; color: #111; }
.l24-latest small { margin: 0 12px; font-size: 12px; color: #6B7280; }
.l24-latest .it:hover b { color: var(--l24); }
.l24-more > .sec:first-child { margin-top: 24px; }

/* Shared sections + inner pages in this theme */
body.tpl-live24 .side-item, body.tpl-live24 .dist, body.tpl-live24 .box, body.tpl-live24 .ccol, body.tpl-live24 .ncard, body.tpl-live24 .article, body.tpl-live24 .side-box { border-radius: 6px; box-shadow: none; border-color: #E5E7EB; }
body.tpl-live24 .sh h2 { font-size: 21px; }
body.tpl-live24 .site-foot { background: #0B0B0B; }
body.tpl-live24 .site-foot::before { background: var(--l24); }
body.tpl-live24 .topbox .hd, body.tpl-live24 .sh .more { border-radius: 4px; }

/* ---------- Responsive ---------- */
@media (max-width: 1200px) {
    .l24-row1 { grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); }
    .l24-right { grid-column: 1 / -1; display: grid; grid-template-columns: 1fr 1fr; }
    .l24-tiles { grid-template-columns: repeat(7, minmax(0, 1fr)); }
    .l24-cols, .l24-latest .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 900px) {
    .l24-banner { display: none; }
    .l24-head .wrap { justify-content: space-between; min-height: 84px; }
    .l24-nav .menu-btn { display: inline-flex; }
    .l24-nav .dd { display: none; }
    .l24-row1 { grid-template-columns: 1fr; }
    .l24-slider { min-height: 300px; } .l24-slider .cap b { font-size: 21px; }
    .l24-side { grid-template-rows: none; }
    .l24-side .sc { min-height: 96px; }
    .l24-right { grid-template-columns: 1fr; }
    .l24-tiles { grid-template-columns: none; grid-auto-flow: column; grid-auto-columns: 30%; overflow-x: auto; scrollbar-width: none; }
    .mega .grid4 { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 600px) {
    .l24-top .hide-sm { display: none !important; } .l24-top .soc { display: none; }
    .l24-logo .img { height: 62px; max-width: 190px; }
    .l24-logo .mk b { font-size: 30px; } .l24-logo .mk i { font-size: 20px; } .l24-logo .tg { font-size: 11.5px; }
    .l24-livebtn { padding: 8px 10px; gap: 7px; } .l24-livebtn .pi { width: 32px; height: 24px; font-size: 12px; } .l24-livebtn b { font-size: 16px; } .l24-livebtn small { font-size: 9.5px; }
    .l24-cols, .l24-latest .grid { grid-template-columns: 1fr; }
    .l24-nav .n { font-size: 14.5px; padding: 0 10px; }
    .l24-brk .lbl { font-size: 11px; padding: 6px 9px; }
    .l24-slider .arr { display: none; }
}

@keyframes grPulse { 0%, 100% { opacity: 1; transform: scale(1); } 50% { opacity: .35; transform: scale(.7); } }
