/* ═══════════════════════════════════════════════════════════════
   CHOMP — VIDEO-FIRST TikTok/Shorts Style
   ═══════════════════════════════════════════════════════════════ */

/* ── Design Tokens ───────────────────────────────────────────── */
:root {
  --pink:        #ff0077;
  --pink-light:  #ff4da6;
  --pink-glow:   rgba(255,0,119,0.5);
  --pink-glow-sm:rgba(255,0,119,0.12);
  --purple:      #bf00ff;
  --black:       #0a0a0a;
  --black-mid:   #111111;
  --black-card:  #161616;
  --black-hover: #1c1c1c;
  --grey-dark:   #222222;
  --grey-mid:    #3a3a3a;
  --grey-text:   #888888;
  --white:       #ffffff;
  --white-dim:   #dddddd;
  --white-muted: #aaaaaa;
  --white-faint: rgba(255,255,255,0.06);
  --nav-height:  56px;
  --ticker-h:    36px;
  --pill-h:      44px;
  --bottom-nav-h:0px;
  --feed-top:    calc(var(--nav-height) + var(--pill-h));
  --slide-h:     calc(100dvh - var(--feed-top) - var(--ticker-h));
  --radius-sm:   8px;
  --radius-md:   12px;
  --gap-sm:      8px;
  --gap-md:      12px;
  --gap-lg:      20px;
  --gap-xl:      32px;
  --trans-fast:  0.18s ease;
  --trans-mid:   0.3s ease;
  --trans-slow:  0.45s ease;
  --shadow-pink: 0 4px 20px rgba(255,0,119,0.35);
  --font-body:   'Inter', 'Segoe UI', sans-serif;
  --font-heading:'Barlow Condensed', 'Impact', sans-serif;
}

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

/* ── Reset ───────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  background: var(--black);
  color: var(--white);
  font-family: var(--font-body);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  /* Reserve space for bottom nav on all devices */
  padding-bottom: calc(var(--bottom-nav-h) + env(safe-area-inset-bottom));
}
a { text-decoration: none; color: inherit; }
button { cursor: pointer; font-family: inherit; }
img { display: block; max-width: 100%; }

/* ── Scrollbar ───────────────────────────────────────────────── */
::-webkit-scrollbar { width: 4px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--grey-mid); border-radius: 2px; }

/* ─────────────────────────────────────────────────────────────
   LOADING SCREEN
───────────────────────────────────────────────────────────── */
.loading-screen {
  position: fixed; inset: 0;
  background: var(--black);
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  z-index: 9999;
  transition: opacity 0.5s ease, visibility 0.5s ease;
}
.loading-screen.hidden { opacity: 0; visibility: hidden; pointer-events: none; }
.loading-logo {
  max-width: 340px; width: 80%; height: auto;
  margin-bottom: var(--gap-xl);
  animation: fadeInDown 0.5s ease;
  filter: drop-shadow(0 0 24px var(--pink));
}
.loading-bar-wrap { width: 180px; height: 3px; background: var(--grey-dark); border-radius: 2px; overflow: hidden; margin-bottom: var(--gap-md); }
.loading-bar { height: 100%; background: var(--pink); border-radius: 2px; transition: width 0.3s ease; box-shadow: 0 0 8px var(--pink); width: 0%; }
.loading-text { font-family: var(--font-heading); font-size: 0.7rem; font-weight: 700; letter-spacing: 2px; text-transform: uppercase; color: var(--grey-text); }

/* ─────────────────────────────────────────────────────────────
   SEARCH OVERLAY
───────────────────────────────────────────────────────────── */
.search-overlay {
  position: fixed; inset: 0;
  background: rgba(10,10,10,0.97);
  backdrop-filter: blur(20px);
  z-index: 2000;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  opacity: 0; visibility: hidden;
  transition: opacity var(--trans-mid), visibility var(--trans-mid);
}
.search-overlay.active { opacity: 1; visibility: visible; }
.search-close {
  position: absolute; top: 20px; right: 20px;
  width: 40px; height: 40px;
  background: var(--grey-dark); border: none; border-radius: 50%;
  color: var(--white); font-size: 1rem;
  display: flex; align-items: center; justify-content: center;
  transition: all var(--trans-fast);
}
.search-close:hover { background: var(--pink); }
.search-box { width: min(600px, 90vw); }
.search-box input {
  width: 100%; padding: 18px 24px;
  background: var(--grey-dark); border: 2px solid var(--grey-mid);
  border-radius: 50px; color: var(--white);
  font-size: 1.1rem; font-family: var(--font-body);
  transition: border-color var(--trans-fast);
  outline: none;
}
.search-box input:focus { border-color: var(--pink); }
.search-result-count { font-family: var(--font-heading); font-size: 0.72rem; font-weight: 600; color: var(--grey-text); letter-spacing: 1px; text-align: center; margin-top: var(--gap-md); }
.search-hint { font-size: 0.68rem; color: var(--grey-text); text-align: center; margin-top: var(--gap-sm); opacity: 0.5; }

/* ─────────────────────────────────────────────────────────────
   BOOKMARKS PANEL
───────────────────────────────────────────────────────────── */
.menu-backdrop {
  position: fixed; inset: 0; background: rgba(0,0,0,0.6); z-index: 1499;
  opacity: 0; visibility: hidden; transition: all var(--trans-mid);
}
.menu-backdrop.open { opacity: 1; visibility: visible; }
.bookmarks-panel {
  position: fixed; top: 0; right: 0;
  width: 360px; height: 100vh;
  background: var(--black-mid); border-left: 1px solid var(--grey-dark);
  z-index: 1500; transform: translateX(100%);
  transition: transform var(--trans-slow);
  overflow-y: auto; padding: var(--gap-lg);
  display: flex; flex-direction: column;
}
@media (max-width: 480px) { .bookmarks-panel { width: 100vw; } }
.bookmarks-panel.open { transform: translateX(0); }
.bookmarks-panel-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: var(--gap-xl); padding-top: var(--gap-md); flex-shrink: 0; }
.bookmarks-panel-title { font-family: var(--font-heading); font-size: 0.85rem; font-weight: 800; color: var(--white); text-transform: uppercase; letter-spacing: 2px; }
.bookmarks-panel-close { width: 32px; height: 32px; display: flex; align-items: center; justify-content: center; color: var(--grey-text); font-size: 1rem; background: none; border: none; border-radius: 50%; transition: all var(--trans-fast); }
.bookmarks-panel-close:hover { color: var(--pink); background: var(--white-faint); }
.bookmarks-list { flex: 1; }
.bookmark-item { display: flex; gap: var(--gap-md); padding: var(--gap-md) 0; border-bottom: 1px solid var(--grey-dark); cursor: pointer; position: relative; }
.bookmark-item:last-child { border-bottom: none; }
.bookmark-item:hover .bookmark-item-title { color: var(--pink); }
.bookmark-item-thumb { width: 72px; height: 54px; object-fit: cover; border-radius: var(--radius-sm); flex-shrink: 0; background: var(--grey-dark); }
.bookmark-item-info { flex: 1; min-width: 0; padding-right: 28px; }
.bookmark-item-cat { font-family: var(--font-heading); font-size: 0.58rem; font-weight: 800; letter-spacing: 1.5px; text-transform: uppercase; color: var(--pink); margin-bottom: 4px; }
.bookmark-item-title { font-family: var(--font-heading); font-size: 0.82rem; font-weight: 600; color: var(--white-dim); line-height: 1.3; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; transition: color var(--trans-fast); }
.bookmark-item-time { font-size: 0.7rem; color: var(--grey-text); margin-top: 4px; }
.bookmark-remove { position: absolute; top: 50%; right: 0; transform: translateY(-50%); width: 26px; height: 26px; display: flex; align-items: center; justify-content: center; color: var(--grey-text); font-size: 0.75rem; cursor: pointer; border-radius: 50%; transition: all var(--trans-fast); opacity: 0; background: none; border: none; }
.bookmark-item:hover .bookmark-remove { opacity: 1; }
.bookmark-remove:hover { color: var(--pink); background: var(--white-faint); }
.bookmarks-empty { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: var(--gap-xl); color: var(--grey-text); }
.bookmarks-empty i { font-size: 2.5rem; margin-bottom: var(--gap-md); opacity: 0.25; }
.bookmarks-empty p { font-family: var(--font-heading); font-size: 0.85rem; font-weight: 600; line-height: 1.6; }

/* ─────────────────────────────────────────────────────────────
   TOP NAV
───────────────────────────────────────────────────────── */
.nav {
  position: fixed; top: 0; left: 0; right: 0;
  height: var(--nav-height);
  background: rgba(10,10,10,0.92);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(255,255,255,0.05);
  z-index: 1000;
}
.nav .container { max-width: 100%; padding: 0 16px; height: 100%; display: flex; align-items: center; justify-content: space-between; gap: 12px; position: relative; }
.nav-left { display: flex; align-items: center; gap: 8px; }
.nav-right { display: flex; align-items: center; gap: 4px; }
.nav-logo { position: absolute; left: 50%; transform: translateX(-50%); display: flex; align-items: center; pointer-events: auto; }
.nav-logo img { height: clamp(28px, 5vh, 42px); width: auto; max-width: 180px; object-fit: contain; }
@media (max-width: 420px) {
  .nav-icon { width: 32px; height: 32px; font-size: 0.9rem; }
  .nav-admin-btn { display: none !important; }
  .manual-refresh-btn { width: 24px; height: 24px; }
}
.live-badge { display: flex; align-items: center; gap: 5px; font-family: var(--font-heading); font-size: 0.65rem; font-weight: 800; letter-spacing: 1.5px; color: var(--pink); text-transform: uppercase; cursor: default; }
.live-dot { width: 7px; height: 7px; background: var(--pink); border-radius: 50%; animation: ping 1.5s ease-in-out infinite; box-shadow: 0 0 8px var(--pink); }
@keyframes ping { 0%,100%{opacity:1;transform:scale(1)} 50%{opacity:0.6;transform:scale(1.3)} }
.manual-refresh-btn { width: 28px; height: 28px; display: flex; align-items: center; justify-content: center; color: var(--grey-text); font-size: 0.8rem; background: none; border: none; border-radius: var(--radius-sm); transition: all var(--trans-fast); }
.manual-refresh-btn:hover { color: var(--pink); background: var(--white-faint); }
.manual-refresh-btn.spinning i { animation: chomp-spin 0.8s linear; }
@keyframes chomp-spin { from{transform:rotate(0deg)} to{transform:rotate(360deg)} }
.nav-icon { width: 38px; height: 38px; display: flex; align-items: center; justify-content: center; color: var(--white-muted); font-size: 1rem; background: none; border: none; border-radius: var(--radius-sm); transition: all var(--trans-fast); position: relative; }
.nav-icon:hover { color: var(--pink); background: var(--white-faint); }
.nav-bookmark-icon { position: relative; }
.bm-count { position: absolute; top: 2px; right: 2px; min-width: 14px; height: 14px; background: var(--pink); border-radius: 7px; font-size: 0.5rem; font-weight: 800; color: white; display: none; align-items: center; justify-content: center; padding: 0 3px; }
.bm-count.visible { display: flex; }

/* Discreet admin nav button — subtle, nearly invisible to casual users */
.nav-admin-btn {
  opacity: 0.2;
  font-size: 0.7rem !important;
  width: 28px !important;
  height: 28px !important;
  color: var(--white-muted) !important;
  transition: opacity 0.3s ease !important;
}
.nav-admin-btn:hover { opacity: 0.7 !important; background: none !important; color: var(--white-muted) !important; }

/* ── Admin / Advertiser Login Modal ──────────────────────────────────────── */
.admin-modal-overlay {
  position: fixed; inset: 0; z-index: 1100;
  background: rgba(0,0,0,0.8); backdrop-filter: blur(10px);
  display: flex; align-items: center; justify-content: center;
  padding: 24px; opacity: 0; pointer-events: none;
  transition: opacity 0.2s ease;
}
.admin-modal-overlay.open { opacity: 1; pointer-events: all; }

.admin-modal {
  background: #0f0f1a;
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 20px;
  padding: 36px 32px;
  width: 100%; max-width: 360px;
  text-align: center;
  box-shadow: 0 24px 80px rgba(0,0,0,0.7);
  transform: translateY(20px) scale(0.97);
  transition: transform 0.2s ease;
  position: relative;
}
.admin-modal-overlay.open .admin-modal { transform: none; }

.admin-modal-close {
  position: absolute; top: 14px; right: 14px;
  background: none; border: none; color: rgba(255,255,255,0.35);
  font-size: 0.9rem; cursor: pointer; padding: 6px;
  border-radius: 6px; transition: color 0.15s;
}
.admin-modal-close:hover { color: rgba(255,255,255,0.7); }

.admin-modal-logo { margin-bottom: 20px; }

.admin-modal-title {
  font-family: var(--font-heading, 'Outfit', sans-serif);
  font-size: 1.2rem; font-weight: 900; color: #fff;
  margin-bottom: 6px;
}
.admin-modal-sub {
  font-size: 0.8rem; color: rgba(255,255,255,0.4);
  margin-bottom: 24px;
}

.admin-input-group {
  position: relative; margin-bottom: 12px;
}
.admin-input-icon {
  position: absolute; left: 14px; top: 50%;
  transform: translateY(-50%);
  color: rgba(255,255,255,0.3); font-size: 0.8rem;
}
.admin-input-group input {
  width: 100%; background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 10px; padding: 12px 14px 12px 38px;
  color: #fff; font-size: 0.9rem; font-family: var(--font-body, 'Inter', sans-serif);
  outline: none; transition: border-color 0.2s;
}
.admin-input-group input:focus { border-color: var(--pink); }

.admin-error {
  font-size: 0.75rem; color: #ff4444;
  min-height: 18px; margin-bottom: 8px;
  text-align: left; padding-left: 4px;
}

.admin-submit-btn {
  width: 100%; padding: 13px;
  background: var(--pink); color: #fff; border: none;
  border-radius: 10px; font-family: var(--font-heading, 'Outfit', sans-serif);
  font-size: 0.9rem; font-weight: 700; cursor: pointer;
  display: flex; align-items: center; justify-content: center; gap: 8px;
  transition: background 0.15s, transform 0.12s;
}
.admin-submit-btn:hover { background: #e0005f; transform: translateY(-1px); }
.admin-submit-btn:active { transform: scale(0.98); }

.admin-modal-footer { margin-top: 20px; }
.admin-enquire-link {
  font-size: 0.75rem; color: rgba(255,255,255,0.3);
  text-decoration: none; transition: color 0.15s;
  display: inline-flex; align-items: center; gap: 5px;
}
.admin-enquire-link:hover { color: var(--pink); }

@keyframes admin-shake {
  0%,100% { transform: translateX(0); }
  20%,60%  { transform: translateX(-6px); }
  40%,80%  { transform: translateX(6px); }
}
.admin-shake { animation: admin-shake 0.4s ease; }


/* ─────────────────────────────────────────────────────────────
   BREAKING NEWS TICKER
───────────────────────────────────────────────────────── */
.ticker-bar, .breaking-ticker {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  top: auto;
  height: var(--ticker-h);
  background: rgba(12,12,12,0.96);
  border-top: 1px solid rgba(255,0,119,0.2);
  display: flex; align-items: center;
  overflow: hidden;
  z-index: 999;
}
.ticker-label {
  flex-shrink: 0;
  background: var(--pink);
  color: white;
  font-family: var(--font-heading);
  font-size: 0.65rem;
  font-weight: 900;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  padding: 0 14px;
  height: 100%;
  display: flex;
  align-items: center;
  gap: 6px;
}
.ticker-track {
  display: flex;
  gap: 48px;
  white-space: nowrap;
  animation: ticker-scroll 60s linear infinite;
}
.ticker-track:hover { animation-play-state: paused; }
.ticker-item {
  font-family: var(--font-heading);
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--white-dim);
  cursor: pointer;
  transition: color var(--trans-fast);
  white-space: nowrap;
}
.ticker-item:hover { color: var(--pink); }
.ticker-sep { color: var(--pink); opacity: 0.4; }
@keyframes ticker-scroll { from{transform:translateX(0)} to{transform:translateX(-50%)} }

/* ─────────────────────────────────────────────────────────────
   CATEGORY FILTER PILLS (below ticker)
───────────────────────────────────────────────────────── */
.feed-category-bar {
  position: fixed;
  top: var(--nav-height);
  left: 0; right: 0;
  height: var(--pill-h);
  background: rgba(10,10,10,0.95);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--grey-dark);
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 16px;
  overflow-x: auto;
  overflow-y: hidden;
  scrollbar-width: none;
  z-index: 998;
  -webkit-overflow-scrolling: touch;
}
.feed-category-bar::-webkit-scrollbar { display: none; }
.feed-cat-pill {
  flex-shrink: 0;
  padding: 6px 14px;
  border: 1px solid var(--grey-dark);
  border-radius: 50px;
  background: transparent;
  color: var(--grey-text);
  font-family: var(--font-heading);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.5px;
  white-space: nowrap;
  transition: all var(--trans-fast);
}
.feed-cat-pill:hover { border-color: var(--pink); color: var(--white); }
.feed-cat-pill.active {
  background: var(--pink);
  border-color: var(--pink);
  color: white;
  box-shadow: 0 0 12px rgba(255,0,119,0.4);
}
.live-pill { border-color: #ff0000 !important; color: #ff4444; }
.live-pill:hover, .live-pill.active { background: #cc0000 !important; border-color: #cc0000 !important; box-shadow: 0 0 14px rgba(255,0,0,0.5); }
@keyframes livePulse { 0%,100%{box-shadow:0 0 6px rgba(255,0,0,0.4)} 50%{box-shadow:0 0 16px rgba(255,0,0,0.8)} }
.live-pill { animation: livePulse 2s ease-in-out infinite; }

/* ─────────────────────────────────────────────────────────────
   VIDEO FEED — Main snap-scroll container
───────────────────────────────────────────────────────── */
.video-feed {
  position: fixed;
  top: var(--feed-top);
  left: 0; right: 0;
  bottom: calc(var(--ticker-h) + env(safe-area-inset-bottom));
  overflow-y: scroll;
  scroll-snap-type: y mandatory;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  overscroll-behavior: contain;
  display: flex;
  flex-direction: column;
}
.video-feed::-webkit-scrollbar { display: none; }

/* ── Individual video slide ─────────────────────────────── */
.video-slide {
  position: relative;
  width: 100%;
  height: var(--slide-h);         /* explicit height = 100dvh - all chrome */
  min-height: var(--slide-h);     /* prevent collapse in scroll container */
  flex-shrink: 0;
  scroll-snap-align: start;
  scroll-snap-stop: always;
  background: var(--black);
  overflow: hidden;
}

/* Full-screen background thumbnail / video */
.slide-bg-blur {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  filter: blur(24px) brightness(0.5) saturate(1.2);
  transform: scale(1.08); /* slightly enlarged to hide blur edges */
  z-index: 0;
}
.slide-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
  background: var(--black-card);
  transition: opacity 0.3s ease;
}

/* ── Sponsored Slides ───────────────────────────────────────────────────────── */
.sponsored-slide { cursor: pointer; }

.sponsored-gradient {
  position: absolute; inset: 0; z-index: 1;
  opacity: 0.88;
}

.sponsored-badge {
  position: absolute; top: 80px; right: 16px; z-index: 10;
  background: rgba(0,0,0,0.55);
  border: 1px solid rgba(255,255,255,0.18);
  color: rgba(255,255,255,0.75);
  font-family: var(--font-heading);
  font-size: 0.65rem; font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 4px 10px;
  border-radius: 20px;
  backdrop-filter: blur(6px);
  display: flex; align-items: center; gap: 5px;
}

.sponsored-brand {
  position: absolute; top: 80px; left: 16px; z-index: 10;
  font-family: var(--font-heading);
  font-size: 0.75rem; font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.55);
}

.sponsored-content {
  position: absolute;
  inset: 0; z-index: 10;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  padding: 40px 28px;
  text-align: center;
}

.sponsored-headline {
  font-family: var(--font-heading);
  font-size: clamp(1.5rem, 4vw, 2.2rem);
  font-weight: 900;
  line-height: 1.15;
  color: #fff;
  margin-bottom: 14px;
  text-shadow: 0 2px 12px rgba(0,0,0,0.4);
  letter-spacing: -0.01em;
}

.sponsored-subline {
  font-family: var(--font-body);
  font-size: clamp(0.85rem, 2vw, 1rem);
  color: rgba(255,255,255,0.75);
  margin-bottom: 32px;
  max-width: 320px;
  line-height: 1.5;
}

.sponsored-cta {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--font-heading);
  font-weight: 800; font-size: 0.95rem;
  letter-spacing: 0.04em;
  color: #fff; text-decoration: none;
  padding: 14px 32px;
  border-radius: 50px;
  box-shadow: 0 8px 30px rgba(0,0,0,0.35);
  transition: transform 0.18s ease, box-shadow 0.18s ease, filter 0.18s ease;
}
.sponsored-cta:hover {
  transform: translateY(-2px) scale(1.04);
  box-shadow: 0 14px 40px rgba(0,0,0,0.45);
  filter: brightness(1.1);
}
.sponsored-cta:active { transform: scale(0.97); }
.slide-iframe-wrap {
  position: absolute;
  inset: 0;
  z-index: 1;
  overflow: hidden;
  background: #000;
}
/* YouTube iframe: oversized to hide controls + fill screen */
/* Portrait: show full 16:9 video at natural width — no cropping */
.slide-iframe-wrap iframe {
  position: absolute;
  top: 0; left: 0;
  width: 100%;
  height: 56.25vw;  /* natural 16:9 height */
  min-height: 100%;
  border: none;
  pointer-events: none;
}
/* Landscape: cover the full screen */
@media (orientation: landscape) {
  .slide-iframe-wrap iframe {
    top: 50%; left: 50%;
    width: 177.78vh;
    height: 100%;
    min-width: 100%;
    transform: translate(-50%, -50%);
  }
}
/* When user taps to interact, we enable pointer events */
.slide-iframe-wrap.interactive iframe { pointer-events: all; }

/* Dark gradient overlay — bottom heavy for text legibility */
/* Cinematic mode — hides title/overlay for clean video view */
.video-slide.cinematic .slide-overlay,
.video-slide.cinematic .slide-meta { opacity: 0; pointer-events: none; transition: opacity 0.3s ease; }
.slide-overlay { transition: opacity 0.3s ease; }

.slide-overlay {
  position: absolute;
  inset: 0;
  z-index: 2;
  background: linear-gradient(
    to top,
    rgba(0,0,0,0.92) 0%,
    rgba(0,0,0,0.5) 35%,
    rgba(0,0,0,0.15) 65%,
    rgba(0,0,0,0.4) 100%
  );
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 0 16px 20px;
}

/* Top-left: category + source + time */
.slide-top-meta {
  position: absolute;
  top: 12px; left: 16px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  z-index: 3;
}
.slide-category-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: rgba(255,0,119,0.85);
  color: white;
  font-family: var(--font-heading);
  font-size: 0.65rem;
  font-weight: 800;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  padding: 4px 10px;
  border-radius: 4px;
  backdrop-filter: blur(4px);
  width: fit-content;
}
.slide-source {
  font-family: var(--font-heading);
  font-size: 0.7rem;
  font-weight: 700;
  color: rgba(255,255,255,0.85);
  text-shadow: 0 1px 4px rgba(0,0,0,0.8);
}
.slide-time {
  font-size: 0.65rem;
  color: rgba(255,255,255,0.55);
}

/* Alert badge — top right */
.slide-alert-badge {
  position: absolute;
  top: 12px; right: 16px;
  color: white;
  font-family: var(--font-heading);
  font-size: 0.6rem;
  font-weight: 900;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  padding: 4px 9px;
  border-radius: 4px;
  z-index: 3;
}
.slide-alert-badge.breaking { background: #ff2200; animation: badge-pulse 1.5s ease-in-out infinite; box-shadow: 0 0 12px rgba(255,34,0,0.6); }
.slide-alert-badge.viral    { background: linear-gradient(135deg, #ff0077, #bf00ff); }
.slide-alert-badge.exclusive{ background: #ff6600; }
@keyframes badge-pulse { 0%,100%{opacity:1} 50%{opacity:0.65} }

/* Right-side action column (TikTok style) */
.slide-actions {
  position: absolute;
  right: 12px;
  bottom: 100px;
  z-index: 5;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
}
.slide-action-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  color: white;
  font-size: 1.5rem;
  filter: drop-shadow(0 2px 6px rgba(0,0,0,0.9));
  cursor: pointer;
  transition: transform var(--trans-fast);
  background: none;
  border: none;
  padding: 4px;
  -webkit-tap-highlight-color: transparent;
}
.slide-action-btn:active { transform: scale(0.82); }
.slide-action-btn span {
  font-family: var(--font-heading);
  font-size: 0.6rem;
  font-weight: 700;
  letter-spacing: 0.5px;
  text-shadow: 0 1px 4px rgba(0,0,0,.8);
}
.slide-action-btn.saved i { color: var(--pink); filter: drop-shadow(0 0 8px var(--pink)); }

/* Bottom info — title + read more */
.slide-info { z-index: 4; padding-right: 72px; }
.slide-title {
  font-family: var(--font-heading);
  font-size: clamp(1.1rem, 4vw, 1.5rem);
  font-weight: 800;
  line-height: 1.2;
  color: white;
  text-shadow: 0 2px 12px rgba(0,0,0,0.8);
  margin-bottom: 8px;
  display: -webkit-box;
  -webkit-line-clamp: 4;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.slide-desc {
  font-size: 0.82rem;
  color: rgba(255,255,255,0.75);
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin-bottom: 14px;
  text-shadow: 0 1px 4px rgba(0,0,0,0.7);
}
.slide-read-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(255,255,255,0.15);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255,255,255,0.3);
  color: white;
  font-family: var(--font-heading);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  padding: 9px 18px;
  border-radius: 50px;
  transition: all var(--trans-fast);
  cursor: pointer;
}
.slide-read-btn:hover { background: var(--pink); border-color: var(--pink); box-shadow: var(--shadow-pink); }

/* Tap-to-play overlay (shows over thumbnail before play) */
.tap-to-play {
  position: absolute;
  inset: 0;
  z-index: 3;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}
.tap-to-play-circle {
  width: 72px; height: 72px;
  background: rgba(0,0,0,0.55);
  backdrop-filter: blur(8px);
  border: 2px solid rgba(255,255,255,0.6);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.8rem;
  color: white;
  transition: transform var(--trans-fast), background var(--trans-fast);
  filter: drop-shadow(0 4px 12px rgba(0,0,0,0.6));
}
.tap-to-play:hover .tap-to-play-circle { transform: scale(1.1); background: rgba(255,0,119,0.5); }
.tap-to-play.hidden { display: none; }

/* Progress bar at bottom of slide */
.slide-progress {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 3px;
  background: rgba(255,255,255,0.15);
  z-index: 6;
}
.slide-progress-bar {
  height: 100%;
  background: var(--pink);
  border-radius: 0 2px 2px 0;
  width: 0%;
  transition: width 0.5s linear;
  box-shadow: 0 0 6px var(--pink);
}

/* Skeleton loader slide */
.skeleton-slide .slide-skeleton-bg {
  position: absolute; inset: 0;
  background: linear-gradient(135deg, var(--black-card) 0%, var(--grey-dark) 100%);
  animation: skeleton-pulse 1.5s ease-in-out infinite;
}
@keyframes skeleton-pulse { 0%,100%{opacity:1} 50%{opacity:0.5} }
.skeleton-line { background: rgba(255,255,255,0.1); border-radius: 4px; margin-bottom: 8px; height: 12px; }
.skeleton-line.short  { width: 40%; }
.skeleton-line.medium { width: 65%; }
.skeleton-line.long   { width: 90%; }

/* ── "No video" slide — shows thumbnail with play button ── */
.slide-no-video .tap-to-play-circle::before { content: '▶'; margin-left: 4px; }

/* ── Load more sentinel ──────────────────────────────────── */
.feed-sentinel { height: 1px; visibility: hidden; }

/* ─────────────────────────────────────────────────────────────
   MUTE INDICATOR
───────────────────────────────────────────────────────── */
.mute-indicator {
  position: fixed;
  bottom: calc(var(--ticker-h) + env(safe-area-inset-bottom) + 60px);
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  background: rgba(10,10,10,0.85);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255,255,255,0.15);
  color: rgba(255,255,255,0.8);
  font-family: var(--font-heading);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 1px;
  padding: 8px 18px;
  border-radius: 50px;
  z-index: 900;
  opacity: 0;
  transition: all var(--trans-mid);
  pointer-events: none;
  white-space: nowrap;
}
.mute-indicator.show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ── Banner Ad Slot ─────────────────────────────────────────── */
.banner-ad-slot {
  position: fixed;
  bottom: var(--ticker-h);
  left: 0; right: 0;
  height: 50px;
  z-index: 998;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(8,8,8,0.95);
  border-top: 1px solid rgba(255,255,255,0.05);
}
.banner-ad-placeholder {
  width: 100%;
  max-width: 320px;
  height: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px dashed rgba(255,255,255,0.1);
  border-radius: 4px;
}
.banner-ad-placeholder span {
  font-size: 0.6rem;
  color: rgba(255,255,255,0.2);
  text-transform: uppercase;
  letter-spacing: 2px;
}

/* ─────────────────────────────────────────────────────────────
   BOTTOM NAV
───────────────────────────────────────────────────────── */
.bottom-nav {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  height: calc(var(--bottom-nav-h) + env(safe-area-inset-bottom));
  background: rgba(10,10,10,0.97);
  backdrop-filter: blur(20px);
  border-top: 1px solid rgba(255,0,119,0.2);
  z-index: 1200;
  padding-bottom: env(safe-area-inset-bottom);
}
.bottom-nav-inner { display: flex; align-items: center; justify-content: space-around; height: var(--bottom-nav-h); }
.bottom-nav-btn {
  flex: 1;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 3px; padding: 8px 4px;
  color: var(--grey-text);
  font-size: 1.15rem;
  background: none; border: none;
  min-height: 44px;
  transition: all var(--trans-fast);
  position: relative;
}
.bottom-nav-btn span { font-family: var(--font-heading); font-size: 0.55rem; font-weight: 700; letter-spacing: 0.5px; text-transform: uppercase; }
.bottom-nav-btn.active { color: var(--pink); }
.bottom-nav-btn.active i { filter: drop-shadow(0 0 6px var(--pink)); }
.bottom-nav-btn:hover { color: var(--white); }
.bnav-badge { position: absolute; top: 4px; right: 50%; transform: translateX(8px); min-width: 14px; height: 14px; background: var(--pink); border-radius: 7px; font-size: 0.5rem; font-weight: 800; color: white; display: none; align-items: center; justify-content: center; padding: 0 3px; }
.bnav-badge.visible { display: flex; }

/* ─────────────────────────────────────────────────────────────
   PULL-TO-REFRESH
───────────────────────────────────────────────────────── */
.pull-refresh-indicator {
  position: fixed;
  top: var(--feed-top);
  left: 50%;
  transform: translateX(-50%) translateY(-80px);
  background: var(--black-card);
  border: 1px solid var(--pink);
  color: var(--pink);
  font-family: var(--font-heading);
  font-size: 0.7rem; font-weight: 700;
  letter-spacing: 1px; text-transform: uppercase;
  padding: 8px 18px;
  border-radius: 50px;
  z-index: 1100;
  display: flex; align-items: center; gap: 8px;
  transition: transform 0.25s cubic-bezier(0.34,1.56,0.64,1), opacity 0.25s ease;
  opacity: 0; box-shadow: var(--shadow-pink); pointer-events: none;
}
.pull-refresh-indicator.visible { transform: translateX(-50%) translateY(8px); opacity: 1; }
.pull-refresh-indicator.loading i { animation: chomp-spin 0.7s linear infinite; }

/* ─────────────────────────────────────────────────────────────
   NEW STORIES TOAST + BOOKMARK TOAST
───────────────────────────────────────────────────────── */
.new-articles-toast {
  position: fixed;
  top: var(--feed-top);
  left: 50%;
  transform: translateX(-50%) translateY(-10px);
  background: var(--pink); color: white;
  font-family: var(--font-heading); font-size: 0.75rem; font-weight: 700;
  letter-spacing: 1px; padding: 10px 20px;
  border-radius: 50px; z-index: 500;
  opacity: 0; pointer-events: none;
  transition: all var(--trans-mid);
  box-shadow: var(--shadow-pink); cursor: pointer;
}
.new-articles-toast.show { opacity: 1; pointer-events: all; transform: translateX(-50%) translateY(8px); }

/* Reading progress bar */
#reading-progress { position: fixed; top: 0; left: 0; height: 3px; background: linear-gradient(to right, var(--pink), var(--purple)); z-index: 10000; width: 0%; transition: width 0.08s linear; box-shadow: 0 0 8px var(--pink); pointer-events: none; }

/* Bookmark toast */
.bookmark-toast {
  position: fixed;
  bottom: calc(var(--bottom-nav-h) + env(safe-area-inset-bottom) + 16px);
  left: 50%;
  transform: translateX(-50%) translateY(12px);
  background: var(--black-card); border: 1px solid var(--grey-dark);
  color: var(--white-dim);
  font-family: var(--font-heading); font-size: 0.75rem; font-weight: 700;
  padding: 10px 22px; border-radius: 50px;
  z-index: 5000; opacity: 0; pointer-events: none;
  transition: all var(--trans-mid); white-space: nowrap; letter-spacing: 0.5px;
}
.bookmark-toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }
.bookmark-toast.saved { border-color: var(--pink); color: var(--pink); }

/* ─────────────────────────────────────────────────────────────
   ANIMATIONS
───────────────────────────────────────────────────────── */
@keyframes fadeInDown { from{opacity:0;transform:translateY(-20px)} to{opacity:1;transform:translateY(0)} }
@keyframes fadeInUp   { from{opacity:0;transform:translateY(20px)}  to{opacity:1;transform:translateY(0)} }
.animate-in { opacity:0; transform:translateY(16px); transition: opacity 0.4s ease, transform 0.4s ease; }
.animate-in.visible { opacity:1; transform:translateY(0); }

/* ── Focus styles (accessibility) ──────────────────────────── */
:focus-visible { outline: 2px solid var(--pink); outline-offset: 2px; }

/* ─────────────────────────────────────────────────────────────
   ARTICLE PAGE
───────────────────────────────────────────────────────── */
.article-hero {
  margin-top: var(--nav-height);
  background: var(--black);
  overflow: hidden;
  position: relative;
}

.article-body {
  background: var(--black);
  padding: var(--gap-xl) 0;
  min-height: 60vh;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 clamp(16px, 4vw, 40px);
}

.article-layout {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 40px;
  align-items: start;
}
@media (max-width: 768px) {
  .article-layout { grid-template-columns: 1fr; }
  .sidebar { order: 2; }
}

/* Breadcrumb */
.article-breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.72rem;
  color: var(--grey-text);
  margin-bottom: var(--gap-md);
  flex-wrap: wrap;
}
.article-breadcrumb a { color: var(--grey-text); transition: color var(--trans-fast); }
.article-breadcrumb a:hover { color: var(--pink); }
.article-breadcrumb span { opacity: 0.5; }

/* Article tag */
.article-tag {
  font-family: var(--font-heading);
  font-size: 0.65rem;
  font-weight: 800;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--pink);
  margin-bottom: var(--gap-md);
}

/* Headline */
.article-headline {
  font-family: var(--font-heading);
  font-size: clamp(1.6rem, 4vw, 2.4rem);
  font-weight: 900;
  line-height: 1.15;
  color: var(--white);
  margin-bottom: var(--gap-lg);
}

/* Byline */
.article-byline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--gap-md);
  padding: var(--gap-md) 0;
  border-top: 1px solid var(--grey-dark);
  border-bottom: 1px solid var(--grey-dark);
  margin-bottom: var(--gap-xl);
  flex-wrap: wrap;
}
.article-source-info { display: flex; align-items: center; gap: var(--gap-md); }
.source-avatar {
  width: 36px; height: 36px;
  border-radius: 50%;
  background: var(--pink);
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-heading);
  font-size: 0.85rem; font-weight: 800;
  color: white; flex-shrink: 0;
}
.source-name { font-family: var(--font-heading); font-size: 0.78rem; font-weight: 700; color: var(--white); }
.source-date { font-size: 0.7rem; color: var(--grey-text); margin-top: 2px; }

/* Share buttons */
.article-share { display: flex; align-items: center; gap: var(--gap-sm); }
.article-bookmark-btn {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 8px 14px;
  background: var(--grey-dark); border: 1px solid var(--grey-mid);
  border-radius: 50px; color: var(--white-dim);
  font-family: var(--font-heading); font-size: 0.68rem; font-weight: 700;
  transition: all var(--trans-fast); cursor: pointer;
}
.article-bookmark-btn:hover { border-color: var(--pink); color: var(--pink); }
.article-bookmark-btn.saved { background: rgba(255,0,119,0.15); border-color: var(--pink); color: var(--pink); }
.share-btn {
  width: 36px; height: 36px;
  display: flex; align-items: center; justify-content: center;
  background: var(--grey-dark); border: 1px solid var(--grey-mid);
  border-radius: 50%; color: var(--white-dim); font-size: 0.85rem;
  transition: all var(--trans-fast); cursor: pointer;
}
.share-btn:hover { background: var(--pink); border-color: var(--pink); color: white; }

/* Summary box */
.article-summary {
  background: rgba(255,0,119,0.08);
  border-left: 3px solid var(--pink);
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
  padding: var(--gap-md) var(--gap-lg);
  margin-bottom: var(--gap-xl);
}
.article-summary h3 {
  font-family: var(--font-heading);
  font-size: 0.68rem; font-weight: 800;
  letter-spacing: 1.5px; text-transform: uppercase;
  color: var(--pink); margin-bottom: var(--gap-sm);
}
.article-summary h3 i { margin-right: 6px; }
.article-summary p { color: var(--white-dim); font-size: 0.9rem; line-height: 1.7; }

/* Article body text */
.article-text { color: var(--white-dim); font-size: 0.95rem; line-height: 1.8; margin-bottom: var(--gap-xl); }
.article-text p { margin-bottom: var(--gap-md); }

/* Read more button */
.read-more-btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 14px 28px;
  background: var(--pink); border-radius: 50px;
  color: white; font-family: var(--font-heading);
  font-size: 0.8rem; font-weight: 800; letter-spacing: 1px;
  text-transform: uppercase; transition: all var(--trans-fast);
  box-shadow: var(--shadow-pink);
}
.read-more-btn:hover { background: #ff2288; transform: translateY(-2px); box-shadow: 0 8px 32px rgba(255,0,119,0.5); }

/* Back button */
.back-btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 10px 20px;
  background: var(--grey-dark); border: 1px solid var(--grey-mid);
  border-radius: 50px; color: var(--white-dim);
  font-family: var(--font-heading); font-size: 0.72rem; font-weight: 700;
  transition: all var(--trans-fast); cursor: pointer;
}
.back-btn:hover { border-color: var(--pink); color: var(--pink); }
.back-arrow-btn { color: var(--white-muted); }

/* ── Sidebar ─────────────────────────────────────────────── */
.sidebar { display: flex; flex-direction: column; gap: var(--gap-xl); }
.sidebar-widget {
  background: var(--black-card);
  border: 1px solid var(--grey-dark);
  border-radius: var(--radius-md);
  overflow: hidden;
}
.widget-header {
  display: flex; align-items: center; gap: var(--gap-sm);
  padding: var(--gap-md) var(--gap-md);
  border-bottom: 1px solid var(--grey-dark);
}
.widget-title-bar { width: 3px; height: 16px; background: var(--pink); border-radius: 2px; flex-shrink: 0; }
.widget-title { font-family: var(--font-heading); font-size: 0.72rem; font-weight: 800; letter-spacing: 1.5px; text-transform: uppercase; color: var(--white); }
.widget-body { padding: var(--gap-md); display: flex; flex-direction: column; gap: var(--gap-md); }

/* Related article item */
.sidebar-article {
  display: flex; gap: var(--gap-sm); align-items: flex-start;
  padding: var(--gap-sm) 0; border-bottom: 1px solid var(--grey-dark);
  transition: all var(--trans-fast);
}
.sidebar-article:last-child { border-bottom: none; padding-bottom: 0; }
.sidebar-article:hover .sidebar-art-title { color: var(--pink); }
.sidebar-art-thumb { width: 64px; height: 48px; object-fit: cover; border-radius: var(--radius-sm); flex-shrink: 0; background: var(--grey-dark); }
.sidebar-art-info { flex: 1; min-width: 0; }
.sidebar-art-cat { font-family: var(--font-heading); font-size: 0.58rem; font-weight: 800; letter-spacing: 1px; text-transform: uppercase; color: var(--pink); margin-bottom: 3px; }
.sidebar-art-title { font-family: var(--font-heading); font-size: 0.78rem; font-weight: 600; color: var(--white-dim); line-height: 1.3; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; transition: color var(--trans-fast); }
.sidebar-art-time { font-size: 0.65rem; color: var(--grey-text); margin-top: 3px; }

/* Video item in sidebar */
.sidebar-video-item { cursor: pointer; }
.sidebar-video-item:hover .sidebar-video-title { color: var(--pink); }
.sidebar-video-thumb { position: relative; width: 100%; padding-bottom: 56.25%; border-radius: var(--radius-sm); overflow: hidden; background: var(--grey-dark); margin-bottom: var(--gap-sm); }
.sidebar-video-thumb img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.sidebar-video-play {
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  background: rgba(0,0,0,0.3); transition: background var(--trans-fast);
}
.sidebar-video-item:hover .sidebar-video-play { background: rgba(255,0,119,0.3); }
.sidebar-video-play svg { width: 28px; height: 28px; fill: white; filter: drop-shadow(0 2px 8px rgba(0,0,0,0.8)); }
.sidebar-video-title { font-family: var(--font-heading); font-size: 0.78rem; font-weight: 600; color: var(--white-dim); line-height: 1.3; display: -webkit-box; -webkit-line-clamp: 2; line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; transition: color var(--trans-fast); }

/* No video chip */
.no-video-chip {
  position: absolute; bottom: 12px; right: 12px;
  background: rgba(10,10,10,0.85); border: 1px solid rgba(255,255,255,0.15);
  color: var(--grey-text); font-family: var(--font-heading);
  font-size: 0.62rem; font-weight: 700; letter-spacing: 0.5px;
  padding: 5px 10px; border-radius: 50px;
  display: flex; align-items: center; gap: 4px;
}

/* ── Footer ─────────────────────────────────────────────── */
.footer {
  background: var(--black-mid);
  border-top: 1px solid var(--grey-dark);
  padding: var(--gap-xl) 0;
  margin-top: var(--gap-xl);
}
.footer-bottom { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: var(--gap-md); }
.footer-copy { font-size: 0.75rem; color: var(--grey-text); }
.footer-copy span { color: var(--pink); font-weight: 700; }
.footer-social { display: flex; gap: var(--gap-md); }
.footer-social a { color: var(--grey-text); font-size: 1rem; transition: color var(--trans-fast); }
.footer-social a:hover { color: var(--pink); }

/* ══════════════════════════════════════════════════
   LANDSCAPE MOBILE — maximise video, hide chrome
   ══════════════════════════════════════════════════ */
@media (orientation: landscape) and (max-height: 500px) {
  :root {
    --nav-height:   38px;
    --ticker-h:     0px;
    --pill-h:       0px;
    --bottom-nav-h: 0px;
    --feed-top:     var(--nav-height);
    --slide-h:      calc(100dvh - var(--nav-height));
  }

  /* Hide non-essential chrome */
  .breaking-ticker,
  .pill-bar,
  .bottom-nav { display: none !important; }

  /* Compact nav */
  .nav { height: var(--nav-height); }
  .nav-logo img { height: 22px; }
  .live-badge { display: none; }

  /* Video fills remaining height */
  .video-feed { top: var(--nav-height) !important; bottom: 0; height: calc(100dvh - var(--nav-height)) !important; }
  .video-slide { height: calc(100dvh - var(--nav-height)) !important; }

  /* Compact sidebar — icons only */
  .slide-actions { gap: 10px; padding: 8px 4px; }
  .slide-action-btn { width: 34px; height: 34px; font-size: 0.9rem; }
  .slide-action-btn span { display: none; }
}
