/*
Theme Name: Bangla TV Serial - MovieFlix Edition
Theme URI: https://banglatvserial.live
Author: Antigravity
Author URI: https://banglatvserial.live
Description: MovieFlix dark luxury entertainment theme with HDJan24 clean download system and hero trailer video slider.
Version: 4.0.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: bangla-serial
*/

:root {
  --bg-main: #0f0617;
  --bg-card: #1a1025;
  --bg-card-hover: #261738;
  --bg-header: rgba(15, 6, 23, 0.95);
  --primary-purple: #a855f7;
  --primary-pink: #ec4899;
  --accent-gold: #fbbf24;
  --accent-amber: #f59e0b;
  --accent-green: #22c55e;
  --telegram-blue: #0088cc;
  --facebook-blue: #1877f2;
  --gradient-gold: linear-gradient(135deg, #fbbf24 0%, #d97706 100%);
  --gradient-purple-pink: linear-gradient(90deg, #a855f7 0%, #ec4899 100%);
  --gradient-purple-blue: linear-gradient(90deg, #a855f7 0%, #6366f1 100%);
  --text-primary: #ffffff;
  --text-muted: #9ca3af;
  --text-dim: #6b7280;
  --border-subtle: rgba(255, 255, 255, 0.1);
  --font-main: 'Hind Siliguri', 'Outfit', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: var(--font-main);
  background-color: var(--bg-main);
  color: var(--text-primary);
  min-height: 100vh;
  overflow-x: hidden;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  line-height: 1.6;
}

a {
  color: inherit;
  text-decoration: none;
}

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

/* =========================================
   1. SITE HEADER & 3D ANIMATED LOGO
========================================= */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--bg-header);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-subtle);
  height: 64px;
}

.header-container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 16px;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.shimmer-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none !important;
  position: relative;
  transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.shimmer-logo:hover {
  transform: scale(1.05) translateY(-1px);
}

.logo-badge-3d {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: radial-gradient(circle at 35% 35%, #2a153d 0%, #0f0617 100%);
  border: 2px solid #fbbf24;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
  box-shadow: 0 0 16px rgba(251, 191, 36, 0.8), inset 0 2px 6px rgba(255, 255, 255, 0.4);
  animation: logoBadgeGlow 3s ease-in-out infinite alternate;
  flex-shrink: 0;
}

@keyframes logoBadgeGlow {
  0% { border-color: #fbbf24; box-shadow: 0 0 14px rgba(251, 191, 36, 0.8); }
  50% { border-color: #ec4899; box-shadow: 0 0 20px rgba(236, 72, 153, 0.9); }
  100% { border-color: #a855f7; box-shadow: 0 0 18px rgba(168, 85, 247, 0.9); }
}

.logo-sparkle {
  position: absolute;
  font-size: 10px;
  z-index: 3;
  pointer-events: none;
}
.logo-sparkle.s1 { top: -4px; left: -4px; color: #fbbf24; }
.logo-sparkle.s2 { top: -4px; right: -4px; color: #ec4899; }

.logo-text-wrap {
  position: relative;
  display: inline-flex;
  align-items: center;
  padding: 5px 14px;
  border-radius: 12px;
  background: rgba(26, 16, 37, 0.85);
  border: 1.5px solid rgba(251, 191, 36, 0.9);
  box-shadow: 0 0 14px rgba(251, 191, 36, 0.6);
  overflow: hidden;
}

.logo-text-3d {
  font-size: 20px;
  font-weight: 800;
  letter-spacing: -0.01em;
  background: linear-gradient(90deg, #fbbf24 0%, #ffffff 25%, #ec4899 50%, #a855f7 75%, #fbbf24 100%);
  background-size: 300% auto;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: text3DWave 4s linear infinite;
  display: inline-block;
}

@keyframes text3DWave {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

.logo-shine-bar {
  position: absolute;
  top: 0;
  left: -100%;
  width: 60%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.7), transparent);
  transform: skewX(-25deg);
  animation: shineBarSweep 2.5s infinite;
}

@keyframes shineBarSweep {
  0% { left: -100%; }
  30% { left: 150%; }
  100% { left: 150%; }
}

/* =========================================
   2. SHIMMERING SEARCH BOX
========================================= */
.search-container {
  position: relative;
  flex: 1;
  max-width: 440px;
}

.search-input-wrap {
  position: relative;
  width: 100%;
}

.search-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--accent-gold);
}

.search-input-wrap input {
  width: 100%;
  padding: 9px 16px 9px 40px;
  border-radius: 9999px;
  background: var(--bg-card);
  border: 1.5px solid rgba(168, 85, 247, 0.7);
  color: var(--text-primary);
  font-size: 13.5px;
  transition: all 0.3s ease;
}
.search-input-wrap input:focus {
  outline: none;
  background: #231238;
  border-color: var(--accent-gold);
  box-shadow: 0 0 15px rgba(251, 191, 36, 0.5);
}

.home-nav-btn {
  color: #fbbf24 !important;
  font-weight: 700;
  font-size: 13.5px;
  padding: 6px 14px;
  background: rgba(251,191,36,0.1);
  border: 1px solid rgba(251,191,36,0.4);
  border-radius: 8px;
  transition: all 0.2s ease;
}
.home-nav-btn:hover {
  background: rgba(251,191,36,0.25);
  transform: translateY(-1px);
}

/* =========================================
   3. CIRCULAR CHANNELS ROW
========================================= */
.channels-row-section {
  padding: 14px 0;
  background: rgba(15, 6, 23, 0.5);
  border-top: 1px solid var(--border-subtle);
  border-bottom: 1px solid var(--border-subtle);
  margin: 10px 0 16px 0;
}

.channels-scroll {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.channel-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  cursor: pointer;
  text-decoration: none !important;
  transition: transform 0.25s ease;
}

.channel-circle {
  width: 66px;
  height: 66px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, rgba(255, 255, 255, 0.15), rgba(20, 10, 30, 0.95));
  border: 2px solid var(--circle-color, #a855f7);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.6), 0 0 10px var(--glow-color, rgba(168, 85, 247, 0.3));
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  padding: 4px;
  text-align: center;
  transition: all 0.25s ease;
}

.channel-item:hover .channel-circle {
  transform: translateY(-4px) scale(1.08);
  border-color: #ffffff;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.8), 0 0 16px var(--circle-color, #a855f7);
}

.circle-text {
  font-size: 9.5px;
  font-weight: 800;
  line-height: 1.1;
  color: #ffffff;
}

/* =========================================
   4. NOTICE BANNERS (Dark Mode Harmony)
========================================= */
.premium-notice {
  text-align: center;
  font-size: 16px;
  font-weight: 700;
  line-height: 1.6;
  margin: 10px auto;
  padding: 10px 14px;
  background: var(--bg-card);
  border: 1.5px solid rgba(168, 85, 247, 0.4);
  border-radius: 10px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.4);
}

.hdjan24-download-box {
  width: 100%;
  margin: 10px auto;
  padding: 9px 14px;
  text-align: center;
  background: var(--bg-card);
  border: 2px solid var(--primary-purple);
  border-radius: 10px;
  box-shadow: 0 0 16px rgba(168, 85, 247, 0.25);
}

.hdjan24-download-text {
  font-size: 16px;
  font-weight: bold;
  line-height: 38px;
  color: #ffffff;
}
.hdjan24-warning { color: #ff4d4d; margin-right: 4px; }
.hdjan24-main-text { color: #c084fc; }
.hdjan24-arrow { color: #fbbf24; font-size: 18px; margin: 0 4px; }

.hdjan24-download-btn {
  display: inline-block;
  padding: 8px 22px;
  margin-left: 6px;
  color: #fff !important;
  text-decoration: none !important;
  font-size: 14.5px;
  font-weight: bold;
  background: linear-gradient(135deg, #a855f7, #6366f1);
  border: 1.5px solid #c084fc;
  border-radius: 6px;
  box-shadow: 0 4px 14px rgba(168, 85, 247, 0.4);
  animation: hdjan24-pulse 1.8s infinite;
  transition: all 0.2s ease;
}
.hdjan24-download-btn:hover {
  background: linear-gradient(135deg, #9333ea, #4f46e5);
  transform: translateY(-2px);
}

@keyframes hdjan24-pulse {
  0% { box-shadow: 0 0 0 0 rgba(168, 85, 247, 0.6); }
  70% { box-shadow: 0 0 0 8px rgba(168, 85, 247, 0); }
  100% { box-shadow: 0 0 0 0 rgba(168, 85, 247, 0); }
}

.whatsapp-box {
  display: table;
  margin: 10px auto 16px;
  padding: 6px 18px;
  border: 2px solid #ef4444;
  border-radius: 12px;
  background: var(--bg-card);
  text-align: center;
  font-size: 15px;
  font-weight: 700;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
}
.whatsapp-box .urgent { color: #ff4d4d; }
.whatsapp-box .contact { color: #4ade80; }
.whatsapp-box .number { color: #fbbf24; }

.whatsapp-btn {
  display: inline-flex !important;
  align-items: center !important;
  background: #25D366 !important;
  color: #ffffff !important;
  padding: 3px 12px !important;
  border-radius: 20px !important;
  font-size: 13.5px !important;
  font-weight: 700 !important;
  text-decoration: none !important;
  margin: 0 4px !important;
}

/* =========================================
   5. HERO SLIDER SECTION
========================================= */
.hero-slider-section {
  margin-bottom: 24px;
}
.slider-wrapper {
  display: grid;
  grid-template-columns: 220px 1fr 220px;
  gap: 16px;
  align-items: stretch;
  background: var(--bg-card);
  padding: 12px;
  border-radius: 12px;
  border: 1px solid var(--border-subtle);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.6);
}
.side-slide {
  position: relative;
  display: block;
  overflow: hidden;
  border-radius: 8px;
  background: #11071c;
  height: 320px;
  border: 2px solid rgba(168, 85, 247, 0.5);
  text-decoration: none !important;
  transition: transform 0.25s ease, border-color 0.25s ease;
}
.side-slide:hover {
  transform: scale(1.03);
  border-color: var(--accent-gold);
}
.side-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.side-slide-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(15, 6, 23, 0.95) 0%, transparent 60%);
  display: flex;
  align-items: flex-end;
  padding: 10px;
}
.side-slide-title {
  color: #ffffff;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.3;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin: 0;
}
.card-episode-tag {
  background: #ef4444;
  color: #ffffff;
  font-size: 10px;
  font-weight: 800;
  padding: 2px 6px;
  border-radius: 3px;
  display: inline-block;
}
.main-slide {
  position: relative;
  border-radius: 8px;
  overflow: hidden;
  background: #000;
  height: 320px;
  border: 2px solid rgba(168, 85, 247, 0.5);
}
.main-slide iframe {
  width: 100%;
  height: 100%;
  border: none;
}
.main-slide-overlay {
  position: absolute;
  bottom: 8px;
  left: 12px;
  right: 12px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  pointer-events: none;
}
.trailer-tag-badge {
  background: rgba(15, 6, 23, 0.85);
  border: 1px solid var(--accent-gold);
  color: #fbbf24;
  padding: 4px 10px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 700;
}

/* =========================================
   6. TWO COLUMN LAYOUT (Left Main, Right Side)
========================================= */
.main-two-col {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 22px;
}

.section-header {
  margin-bottom: 16px;
}
.section-title {
  font-size: 20px;
  font-weight: 800;
  color: #fff;
  border-left: 4px solid var(--primary-purple);
  padding-left: 10px;
}

.page-title, .widget-title {
  font-size: 16px;
  font-weight: 700;
  color: #ffffff;
  background: var(--gradient-purple-blue);
  padding: 8px 14px;
  margin-bottom: 14px;
  border-radius: 6px;
  display: flex;
  align-items: center;
  gap: 8px;
  box-shadow: 0 4px 12px rgba(168, 85, 247, 0.3);
}

.page-meta {
  margin-bottom: 14px;
}
.page-meta span {
  font-weight: 600;
  background: #261738;
  color: #fbbf24;
  border: 1px solid rgba(168, 85, 247, 0.4);
  padding: 4px 10px;
  font-size: 12px;
  border-radius: 4px;
}

/* =========================================
   7. SINGLE POST CONTENT (MovieFlix Dark Look)
========================================= */
.post-main-content {
  background: var(--bg-card);
  padding: 20px 22px;
  border-radius: 12px;
  border: 1px solid var(--border-subtle);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
}

.hdjan-poster-center {
  text-align: center;
  margin: 15px 0 20px;
}
.hdjan-poster-center img {
  max-width: 350px;
  width: 100%;
  height: auto;
  border-radius: 6px;
  display: inline-block;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.6);
}

.hdjan-body-inner {
  text-align: center;
  font-size: 15px;
  margin-bottom: 25px;
  color: #e2e8f0;
}
.hdjan-body-inner img {
  max-width: 100%;
  height: auto;
  display: block;
  margin: 12px auto;
  border-radius: 6px;
}
.hdjan-body-inner p {
  text-align: center;
  margin: 8px 0;
}
.hdjan-body-inner p:first-of-type img {
  max-width: 350px;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.6);
}

/* RED QUALITY BADGES (HDJan24 Signature) */
.hdjan-body-inner h2,
.download-badge-header {
  text-align: center;
  margin: 22px 0 10px 0;
}
.hdjan-body-inner h2 span,
.download-badge-header span {
  background-color: #ff0000 !important;
  border-top: 3px solid #867de6 !important;
  border-bottom: 3px solid #867de6 !important;
  border-radius: 10px !important;
  color: white !important;
  font-size: 16px !important;
  font-weight: 700 !important;
  padding: 4px 26px !important;
  display: inline-block !important;
  box-shadow: 0 3px 10px rgba(255, 0, 0, 0.4) !important;
}

.hdjan-body-inner h4,
.hdjan-download-links-list {
  text-align: center;
  margin: 6px 0 !important;
}
.hdjan-link-item {
  margin: 6px 0;
}
.hdjan-body-inner h4 a,
.hdjan-link-item a {
  display: inline-block;
  font-size: 15px;
  font-weight: 700;
  color: #60a5fa !important;
  text-decoration: underline !important;
  padding: 2px 8px;
  transition: color 0.15s ease;
}
.hdjan-body-inner h4 a:hover,
.hdjan-link-item a:hover {
  color: #fbbf24 !important;
}

.hdjan-helpline {
  text-align: center;
  margin: 25px 0 6px 0;
  font-size: 15px;
  color: #fbbf24;
  font-weight: 700;
}
.hdjan-helpline-number {
  text-align: center;
  font-size: 20px;
  color: #fbbf24;
  font-weight: 800;
  margin-bottom: 25px;
}

/* =========================================
   8. SIDEBAR (Dark Categories & Recent Cards)
========================================= */
.primary-sidebar {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.sidebar-box {
  background: var(--bg-card);
  padding: 16px;
  border-radius: 12px;
  border: 1px solid var(--border-subtle);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.4);
}

.category-pills-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
}
.category-pills-grid a {
  background: #231238;
  border: 1px solid rgba(168, 85, 247, 0.3);
  color: #e9d5ff !important;
  padding: 6px 8px;
  text-align: center;
  border-radius: 4px;
  font-size: 12px;
  font-weight: 600;
  text-decoration: none !important;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  transition: all 0.2s ease;
}
.category-pills-grid a:hover {
  background: var(--primary-purple);
  color: #ffffff !important;
  border-color: #ffffff;
  transform: translateY(-1px);
}

.sidebar-posts-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}

.sidebar-card figure {
  position: relative;
  border-radius: 6px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: #000;
  aspect-ratio: 2/3;
  margin: 0;
  transition: transform 0.2s ease, border-color 0.2s ease;
}
.sidebar-card:hover figure {
  transform: scale(1.04);
  border-color: var(--primary-purple);
  box-shadow: 0 0 12px rgba(168, 85, 247, 0.5);
}
.sidebar-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.sidebar-card figcaption {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: rgba(15, 6, 23, 0.9);
  padding: 4px 2px;
  text-align: center;
}
.sidebar-card figcaption p {
  color: #fff;
  font-size: 10px;
  font-weight: 600;
  line-height: 1.2;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin: 0;
}
.sidebar-card:hover figcaption p {
  color: var(--accent-gold);
}

/* =========================================
   9. HOMEPAGE EPISODES GRID (MovieFlix Style)
========================================= */
.episodes-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
  gap: 16px;
}

.episode-card {
  background: var(--bg-card);
  border-radius: 10px;
  overflow: hidden;
  cursor: pointer;
  border: 1.5px solid rgba(255, 255, 255, 0.08);
  transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

.episode-card:hover {
  transform: translateY(-5px) scale(1.02);
  border-color: var(--primary-purple);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.8), 0 0 18px rgba(168, 85, 247, 0.4);
}

.thumbnail-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 2/3;
  overflow: hidden;
  background: #11071c;
}
.thumbnail-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.3s ease;
}
.episode-card:hover .thumbnail-wrap img {
  transform: scale(1.08);
}

.play-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.25s ease;
}
.episode-card:hover .play-overlay {
  background: rgba(0, 0, 0, 0.5);
}

.play-circle-btn {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.95);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.25s ease, background 0.25s ease;
}
.play-circle-btn svg {
  fill: #000;
  width: 16px;
  height: 16px;
  margin-left: 2px;
}
.episode-card:hover .play-circle-btn {
  transform: scale(1.15);
  background: var(--gradient-purple-pink);
}
.episode-card:hover .play-circle-btn svg {
  fill: #ffffff;
}

.card-quality-tag {
  position: absolute;
  top: 6px;
  left: 6px;
  background: rgba(15, 6, 23, 0.85);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #fbbf24;
  font-size: 10px;
  font-weight: 800;
  padding: 2px 6px;
  border-radius: 4px;
}

.card-episode-tag {
  position: absolute;
  top: 6px;
  right: 6px;
  background: #ef4444;
  color: #fff;
  font-size: 10px;
  font-weight: 800;
  padding: 2px 6px;
  border-radius: 4px;
}

.card-info {
  padding: 10px 12px;
  background: #130a1e;
}
.card-title {
  font-size: 13px;
  font-weight: 700;
  color: #ffffff;
  line-height: 1.3;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.episode-card:hover .card-title {
  color: var(--accent-gold);
}

/* =========================================
   10. FOOTER
========================================= */
.site-footer {
  background: #09030e;
  border-top: 1px solid var(--border-subtle);
  margin-top: 40px;
  color: var(--text-muted);
  padding: 24px 0 20px;
  text-align: center;
}

/* =========================================
   11. MOBILE RESPONSIVE
========================================= */
@media (max-width: 850px) {
  .main-two-col {
    grid-template-columns: 1fr;
  }
  .slider-wrapper {
    grid-template-columns: 1fr;
  }
  .side-slide {
    display: none;
  }
  .main-slide {
    height: 240px;
  }
  .episodes-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
  }
}

@media (max-width: 550px) {
  .episodes-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
  }
  .sidebar-posts-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}
