:root {
  --bg-color: #05070d;
  --card-bg: #0b111e;
  --border-blue: #1e3a8a;
  --accent-blue: #2563eb;
  --accent-yellow: #facc15;
  --accent-green: #22c55e;
  --accent-red: #ef4444;
  --text-white: #f8fafc;
  --text-muted: #94a3b8;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  font-family: 'Padauk', Arial, sans-serif;
}

body {
  background-color: var(--bg-color);
  color: var(--text-white);
  padding-bottom: 120px;
  overflow-x: hidden;
  user-select: none;
  -webkit-user-select: none;
}

/* Inverted Custom Scroll Indicator */
#scrollTrack {
  position: fixed;
  top: 0;
  right: 4px;
  width: 6px;
  height: 100vh;
  z-index: 99999;
  pointer-events: none;
}

#scrollThumb {
  position: absolute;
  width: 100%;
  height: 40px;
  background: var(--accent-blue);
  border-radius: 4px;
  box-shadow: 0 0 10px var(--accent-blue);
  top: 100%;
  transform: translateY(-100%);
}

/* Header & Dynamic Island */
header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 16px;
  background: #080d1a;
  border-bottom: 1px solid var(--border-blue);
  position: sticky;
  top: 0;
  z-index: 1000;
}

.logo-container {
  display: flex;
  align-items: center;
  gap: 8px;
}

.logo-img {
  height: 38px;
  width: auto;
  border-radius: 6px;
  object-fit: cover;
}

.dynamic-island {
  display: flex;
  align-items: center;
  gap: 8px;
  background: #000;
  padding: 6px 14px;
  border-radius: 24px;
  border: 1px solid #1f2937;
  font-size: 13px;
  box-shadow: 0 0 12px rgba(0,0,0,0.8);
}

.pulse-dot {
  width: 8px;
  height: 8px;
  background-color: var(--accent-green);
  border-radius: 50%;
  box-shadow: 0 0 8px var(--accent-green);
  animation: blink 1.2s infinite ease-in-out;
}

@keyframes blink {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.2; transform: scale(0.7); }
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 16px;
}

/* Search Box */
.search-box {
  display: flex;
  background: var(--card-bg);
  border: 2px solid var(--border-blue);
  border-radius: 10px;
  overflow: hidden;
  margin-bottom: 16px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.4);
}

.search-box input {
  flex: 1;
  padding: 12px 16px;
  background: transparent;
  border: none;
  outline: none;
  color: var(--text-white);
  font-size: 15px;
}

.search-box button {
  background: var(--accent-blue);
  border: none;
  padding: 0 18px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.search-box button svg {
  width: 20px;
  height: 20px;
  fill: #fff;
}

/* Ads Section */
.ads-banner {
  width: 100%;
  min-height: 80px;
  background: #111827;
  border: 1px dashed var(--border-blue);
  border-radius: 8px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
  color: var(--text-muted);
  font-size: 13px;
  text-align: center;
}

/* Dropdown Categories */
.dropdown-btn {
  width: 100%;
  background: var(--card-bg);
  border: 2px solid var(--border-blue);
  color: var(--text-white);
  padding: 10px 14px;
  border-radius: 8px;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 15px;
  margin-bottom: 8px;
}

.category-group {
  display: none;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin-bottom: 20px;
}

.category-group.show {
  display: grid;
}

.cat-btn {
  padding: 10px;
  background: var(--card-bg);
  border: 1px solid var(--border-blue);
  color: var(--text-white);
  border-radius: 6px;
  cursor: pointer;
  font-weight: bold;
  transition: 0.2s;
}

.cat-btn.active {
  background: var(--accent-yellow);
  color: #000;
  border-color: var(--accent-yellow);
  box-shadow: 0 0 10px rgba(250, 204, 21, 0.4);
}

/* Video Grid */
.video-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 16px;
}

.video-card {
  background: var(--card-bg);
  border: 2px solid var(--border-blue);
  border-radius: 10px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.2s;
}

.video-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 4px 15px rgba(37, 99, 235, 0.2);
}

/* 16:9 Ratio Wrapper */
.thumbnail-wrapper {
  position: relative;
  width: 100%;
  padding-top: 56.25%;
  background: #000;
  overflow: hidden;
}

.thumbnail-wrapper img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Shimmer Loading */
.shimmer {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, #111827 25%, #1f293d 50%, #111827 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
  z-index: 2;
}

@keyframes shimmer {
  0% { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}

.video-info {
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.discussion-text {
  color: #eab308;
  font-size: 14px;
  font-weight: bold;
  line-height: 1.4;
}

.meta-footer {
  display: flex;
  flex-direction: column;
  gap: 4px;
  border-top: 1px solid rgba(255,255,255,0.06);
  padding-top: 6px;
}

.views-box {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 12px;
  color: var(--text-muted);
}

.views-box svg {
  width: 14px;
  height: 14px;
  fill: var(--text-muted);
}

.watermark {
  font-size: 11px;
  font-weight: 700;
  color: var(--accent-blue);
  letter-spacing: 0.5px;
}

/* Pagination */
.pagination-container {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 6px;
  margin: 30px 0 10px;
}

.page-box {
  background: var(--accent-blue);
  color: #ffffff;
  padding: 8px 12px;
  border-radius: 6px;
  border: 1px solid #3b82f6;
  font-size: 13px;
  font-weight: bold;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  min-width: 38px;
}

.page-box.info {
  background: #0f172a;
  border-color: var(--border-blue);
  cursor: default;
}

.page-box.active {
  background: var(--accent-yellow);
  color: #000;
  border-color: var(--accent-yellow);
}

/* Bottom Popup Ad */
.bottom-popup {
  position: fixed;
  bottom: 74px;
  left: 50%;
  transform: translateX(-50%);
  width: 90%;
  max-width: 480px;
  background: #111827;
  border: 2px solid var(--accent-blue);
  border-radius: 8px;
  padding: 8px 12px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  box-shadow: 0 4px 20px rgba(0,0,0,0.8);
  z-index: 999;
}

.bottom-popup button.close-pop {
  background: none;
  border: none;
  color: var(--accent-red);
  font-size: 16px;
  font-weight: bold;
  cursor: pointer;
}

/* Floating Bottom Navbar */
.bottom-navbar {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  background: #090d16;
  border-top: 1px solid var(--border-blue);
  display: flex;
  justify-content: space-around;
  padding: 8px 0 12px;
  box-shadow: 0 -4px 25px rgba(0, 0, 0, 0.9);
  z-index: 10000;
}

.nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  border: none;
  background: transparent;
  cursor: pointer;
  font-size: 11px;
  font-weight: bold;
  text-decoration: none;
}

.nav-item svg {
  width: 22px;
  height: 22px;
}

.nav-home { color: var(--accent-red); }
.nav-home svg { fill: var(--accent-red); }

.nav-ads { color: var(--accent-green); }
.nav-ads svg { fill: var(--accent-green); }

.nav-cat { color: var(--accent-yellow); }
.nav-cat svg { fill: var(--accent-yellow); }

footer {
  text-align: center;
  margin-top: 40px;
  padding: 10px;
  font-size: 13px;
  color: var(--text-muted);
  border-top: 1px solid #111827;
}
