:root { --blue: #003366; --red: #e60000; --dark: #111; }
* { margin:0; padding:0; box-sizing: border-box; font-family: 'Segoe UI', sans-serif; }
body { background: #f4f4f4; overflow-x: hidden; }

header { background: var(--blue); position: sticky; top:0; z-index: 1000; border-bottom: 4px solid var(--red); }
.main-nav { padding: 10px 5%; display: flex; align-items: center; justify-content: space-between; }
.main-site-logo { height: 42px; width: auto; }
.nav-buttons { display: flex; background: rgba(0,0,0,0.2); border-radius: 5px; height: 38px; }
.scroll-links { display: flex; overflow-x: auto; white-space: nowrap; scrollbar-width: none; }
.scroll-links a { color: #fff; text-decoration: none; padding: 0 15px; display: flex; align-items: center; font-size: 11px; font-weight: bold; text-transform: uppercase; }

.breaking-ticker { background: var(--dark); color: #fff; display: flex; height: 40px; align-items: center; overflow: hidden; }
.ticker-label { background: var(--red); padding: 0 20px; font-weight: 900; z-index: 10; height: 100%; display: flex; align-items: center; }
.ticker-content { display: flex; white-space: nowrap; animation: tickerScroll 30s linear infinite; }
@keyframes tickerScroll { from { transform: translateX(100%); } to { transform: translateX(-100%); } }

/* TV9 HERO GRID DESKTOP FIX */
.hero-section { padding: 20px 5%; max-width: 1400px; margin: auto; }
.tv9-grid { display: grid; grid-template-columns: 2fr 1.1fr; gap: 12px; height: 550px; }
.big-tile-item, .small-tile-item { position: relative; border-radius: 8px; overflow: hidden; cursor: pointer; background: #000; }
.side-tiles-grid { display: grid; grid-template-columns: 1fr 1fr; grid-template-rows: 1fr 1fr; gap: 10px; height: 100%; }

.big-tile-item img, .small-tile-item img { width: 100%; height: 100%; object-fit: cover; transition: 0.5s; }
.big-tile-item:hover img, .small-tile-item:hover img { transform: scale(1.05); }

/* CLICK FIX */
.tile-overlay { position: absolute; bottom: 0; width: 100%; padding: 25px 20px; background: linear-gradient(transparent, rgba(0,0,0,0.95)); color: #fff; pointer-events: none; }
.big-tile-item h1 { font-size: 28px; line-height: 1.2; font-weight: 700; }
.small-tile-item h3 { font-size: 14px; line-height: 1.3; font-weight: 600; }

/* PLAY ICONS */
.play-icon, .play-icon-s { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); color: #fff; background: rgba(230,0,0,0.8); border-radius: 50%; display: flex; align-items: center; justify-content: center; z-index: 5; }
.play-icon { width: 60px; height: 60px; font-size: 24px; }
.play-icon-s { width: 35px; height: 35px; font-size: 14px; }

/* CATEGORY SECTIONS */
.cat-block { padding: 30px 5%; max-width: 1400px; margin: auto; }
.cat-header { display: flex; justify-content: space-between; align-items: center; border-bottom: 2px solid #ddd; margin-bottom: 20px; }
.cat-title { color: var(--blue); border-left: 5px solid var(--red); padding-left: 10px; }
.cat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 20px; }
.news-card { background: #fff; border-radius: 8px; overflow: hidden; box-shadow: 0 4px 10px rgba(0,0,0,0.05); cursor: pointer; }
.img-wrapper { height: 150px; }
.img-wrapper img { width: 100%; height: 100%; object-fit: cover; }
.card-info { padding: 15px; pointer-events: none; }
.card-info h4 { font-size: 15px; color: var(--blue); margin-bottom: 5px; height: 42px; overflow: hidden; }
.card-info p { font-size: 12px; color: #666; }

/* POPUP */
.overlay { display: none; position: fixed; top:0; left:0; width:100%; height:100%; background: rgba(0,0,0,0.9); z-index: 2000; padding: 20px; overflow-y: auto; }
.overlay-card { max-width: 600px; margin: auto; background: #fff; border-radius: 12px; overflow: hidden; }
.overlay-header { background: var(--blue); color: #fff; padding: 15px 25px; display: flex; justify-content: space-between; align-items: center; }
.close-x { background: none; border: none; color: #fff; font-size: 30px; cursor: pointer; }
.photo-container { position: relative; background: #000; }
#overlayImage { width: 100%; display: block; object-fit: contain; max-height: 400px; }
.watermark { position: absolute; top: 15px; right: 15px; height: 35px; }
.popup-actions { display: flex; }
.btn-wa, .btn-dl { flex: 1; padding: 18px; border: none; font-weight: bold; color: #fff; cursor: pointer; }
.btn-wa { background: #25d366; }
.btn-dl { background: #28a745; }

@media (max-width: 900px) {
    .tv9-grid { grid-template-columns: 1fr; height: auto; }
    .big-tile-item { height: 280px; }
    .side-tiles-grid { grid-template-columns: 1fr 1fr; height: 320px; }
}