/* ==========================================================================
   Cineora cinema design system
   ========================================================================== */

:root {
  /* Color Tokens */
  --bg-main: #07090e;
  --bg-surface: #0e121a;
  --bg-card: rgba(19, 25, 38, 0.7);
  --bg-glass: rgba(23, 30, 46, 0.55);
  --bg-hover: rgba(35, 45, 68, 0.6);
  
  --border-subtle: rgba(255, 255, 255, 0.08);
  --border-active: rgba(229, 9, 20, 0.6);
  --border-glow: rgba(255, 255, 255, 0.15);

  --accent-red: #e50914;
  --accent-red-hover: #f40612;
  --accent-red-glow: rgba(229, 9, 20, 0.4);
  
  --accent-amber: #f59e0b;
  --accent-amber-glow: rgba(245, 158, 11, 0.3);

  --accent-cyan: #06b6d4;
  --accent-emerald: #10b981;

  --text-primary: #f8fafc;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;

  /* Typography */
  --font-heading: 'Outfit', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;

  /* Elevations & Shadows */
  --shadow-card: 0 10px 25px -5px rgba(0, 0, 0, 0.5), 0 8px 10px -6px rgba(0, 0, 0, 0.5);
  --shadow-hover: 0 20px 35px -5px rgba(0, 0, 0, 0.7), 0 0 20px rgba(229, 9, 20, 0.25);
  --shadow-glow: 0 0 35px rgba(229, 9, 20, 0.35);

  /* Transitions */
  --ease-smooth: cubic-bezier(0.16, 1, 0.3, 1);
  --duration-fast: 0.2s;
  --duration-normal: 0.35s;

  /* Radii */
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 18px;
  --radius-full: 9999px;
}

/* Reset & Box Sizing */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  color-scheme: dark;
}

body {
  font-family: var(--font-body);
  background-color: var(--bg-main);
  color: var(--text-primary);
  min-height: 100vh;
  line-height: 1.5;
  overflow-x: hidden;
  position: relative;
  background-image: 
    radial-gradient(circle at 15% 10%, rgba(229, 9, 20, 0.07) 0%, transparent 40%),
    radial-gradient(circle at 85% 60%, rgba(6, 182, 212, 0.05) 0%, transparent 40%);
  background-attachment: fixed;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}
::-webkit-scrollbar-track {
  background: var(--bg-main);
}
::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.15);
  border-radius: var(--radius-full);
}
::-webkit-scrollbar-thumb:hover {
  background: var(--accent-red);
}

/* ==========================================================================
   Top Bar Navigation — Redesigned with React Bits <PillNav /> Component
   ========================================================================== */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 64px;
  z-index: 1000;
  background: rgba(8, 12, 22, 0.86);
  backdrop-filter: blur(28px) saturate(180%);
  -webkit-backdrop-filter: blur(28px) saturate(180%);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  transition: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  align-items: center;
}

/* Ambient Top Hairline / Aurora Edge (ReactBits BorderBeam inspiration) */
.site-header::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent 0%, rgba(229, 9, 20, 0.9) 20%, rgba(0, 240, 255, 0.9) 50%, rgba(168, 85, 247, 0.9) 80%, transparent 100%);
  background-size: 200% 100%;
  animation: auroraHeaderShift 7s linear infinite;
  pointer-events: none;
  opacity: 0.95;
  z-index: 1002;
}

@keyframes auroraHeaderShift {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

.site-header.scrolled {
  background: rgba(6, 8, 15, 0.96);
  border-bottom-color: rgba(255, 255, 255, 0.12);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.8), 0 0 1px rgba(255, 255, 255, 0.1);
}

.header-container {
  width: 100%;
  max-width: 1720px;
  margin: 0 auto;
  padding: 0 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;
}

.header-left {
  display: flex;
  align-items: center;
  gap: 1.2rem;
  flex-shrink: 0;
  min-width: 0;
}

/* ==========================================================================
   REACT BITS <PillNav /> COMPONENT CSS
   ========================================================================== */
.pill-nav-container {
  position: relative;
  z-index: 99;
  display: flex;
  align-items: center;
}

.pill-nav {
  --nav-h: 40px;
  --logo: 34px;
  --pill-pad-x: 15px;
  --pill-gap: 3px;
  width: max-content;
  display: flex;
  align-items: center;
  box-sizing: border-box;
}

.pill-nav-items {
  position: relative;
  display: flex;
  align-items: center;
  height: var(--nav-h);
  background: rgba(13, 18, 30, 0.82);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 9999px;
  padding: 3px;
  backdrop-filter: blur(14px);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06), 0 4px 20px rgba(0, 0, 0, 0.4);
}

.pill-logo {
  width: var(--nav-h);
  height: var(--nav-h);
  border-radius: 50%;
  background: var(--base, #e50914);
  padding: 8px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  margin-right: 6px;
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.pill-logo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.pill-list {
  list-style: none;
  display: flex;
  align-items: stretch;
  gap: var(--pill-gap);
  margin: 0;
  padding: 0;
  height: 100%;
}

.pill-list > li {
  display: flex;
  height: 100%;
}

.pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  padding: 0 var(--pill-pad-x);
  background: var(--pill-bg, rgba(20, 26, 40, 0.85));
  color: var(--pill-text, #cbd5e1);
  text-decoration: none;
  border-radius: 9999px;
  box-sizing: border-box;
  font-family: inherit;
  font-weight: 600;
  font-size: 13.5px;
  line-height: 1;
  letter-spacing: 0.2px;
  white-space: nowrap;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.04);
  outline: none;
  transition: color 0.2s ease, border-color 0.2s ease, background-color 0.2s ease;
}

.pill .hover-circle {
  position: absolute;
  left: 50%;
  bottom: 0;
  border-radius: 50%;
  background: var(--base, #e50914);
  z-index: 1;
  display: block;
  pointer-events: none;
  will-change: transform;
}

.pill .label-stack {
  position: relative;
  display: inline-flex;
  align-items: center;
  line-height: 1;
  z-index: 2;
}

.pill .pill-label {
  position: relative;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  line-height: 1;
  will-change: transform;
}

.pill .pill-label-hover {
  position: absolute;
  left: 0;
  top: 0;
  color: var(--hover-text, #ffffff);
  z-index: 3;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  line-height: 1;
  white-space: nowrap;
  will-change: transform, opacity;
}

.pill .pill-label i,
.pill .pill-label-hover i {
  font-size: 0.98rem;
}

.pill.is-active,
.pill.active {
  background: rgba(229, 9, 20, 0.2);
  border-color: rgba(229, 9, 20, 0.5);
  color: #ffffff;
}

.pill.is-active::after,
.pill.active::after {
  content: '';
  position: absolute;
  bottom: -6px;
  left: 50%;
  transform: translateX(-50%);
  width: 12px;
  height: 12px;
  background: var(--base, #e50914);
  border-radius: 50px;
  z-index: 4;
  box-shadow: 0 0 10px #e50914;
}

.desktop-only {
  display: flex;
}

.mobile-only {
  display: none;
}

/* React Bits Mobile Hamburger Button */
.mobile-menu-button {
  width: var(--nav-h);
  height: var(--nav-h);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  cursor: pointer;
  padding: 0;
  position: relative;
  transition: all 0.2s ease;
}

.mobile-menu-button:hover {
  background: rgba(255, 255, 255, 0.16);
}

.hamburger-line {
  width: 16px;
  height: 2px;
  background: #ffffff;
  border-radius: 1px;
  transition: all 0.01s ease;
  transform-origin: center;
}

/* React Bits Mobile Popover */
.mobile-menu-popover {
  position: absolute;
  top: calc(100% + 10px);
  left: 0;
  width: 230px;
  background: var(--base, #0c101c);
  border-radius: 18px;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.65), 0 0 1px rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.1);
  z-index: 998;
  opacity: 0;
  transform-origin: top center;
  visibility: hidden;
  padding: 6px;
}

@media (max-width: 768px) {
  .mobile-menu-popover {
    position: fixed;
    top: 68px;
    left: 12px;
    right: 12px;
    width: auto;
    max-width: calc(100vw - 24px);
    border-radius: 20px;
    background: rgba(12, 16, 28, 0.96);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border: 1px solid rgba(255, 255, 255, 0.12);
    box-shadow: 0 20px 48px rgba(0, 0, 0, 0.8), 0 0 1px rgba(255, 255, 255, 0.2);
    padding: 8px;
  }
}

.mobile-menu-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.mobile-menu-popover .mobile-menu-link {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  padding: 10px 14px;
  color: var(--pill-text, #cbd5e1);
  background-color: var(--pill-bg, rgba(255, 255, 255, 0.04));
  text-decoration: none;
  font-size: 14px;
  font-weight: 600;
  border-radius: 12px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: all 0.2s ease;
}

.mobile-menu-popover .mobile-menu-link:hover,
.mobile-menu-popover .mobile-menu-link.is-active {
  cursor: pointer;
  background-color: rgba(229, 9, 20, 0.2);
  color: var(--hover-text, #fff);
  border-color: rgba(229, 9, 20, 0.4);
}

/* ==========================================================================
   Header Right: Controls, Search, Telemetry, Sync
   ========================================================================== */
.header-right {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  flex-shrink: 0;
}

/* Live Search Bar Pill */
.header-search-pill,
.search-box {
  display: flex;
  align-items: center;
  gap: 8px;
  background: rgba(14, 20, 32, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 999px;
  padding: 0 12px;
  height: 38px;
  width: 210px;
  color: #ffffff;
  transition: all 0.28s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.header-search-pill:focus-within,
.search-box:focus-within {
  width: 260px;
  border-color: rgba(229, 9, 20, 0.6);
  box-shadow: 0 0 18px rgba(229, 9, 20, 0.22), inset 0 1px 0 rgba(255, 255, 255, 0.1);
  background: rgba(18, 25, 40, 0.94);
}

.header-search-pill .search-icon,
.search-box .search-icon {
  color: #94a3b8;
  font-size: 1rem;
  flex-shrink: 0;
  transition: color 0.2s ease, transform 0.2s ease;
}

.header-search-pill:focus-within .search-icon,
.search-box:focus-within .search-icon {
  color: #ff202e;
  transform: scale(1.1);
}

.header-search-pill input,
.search-box input {
  background: transparent;
  border: none;
  outline: none;
  color: #ffffff;
  font-size: 0.84rem;
  width: 100%;
  font-family: inherit;
}

.header-search-pill input::placeholder,
.search-box input::placeholder {
  color: #64748b;
  font-size: 0.82rem;
}

.search-kbd-chip,
.search-kbd {
  font-size: 0.66rem;
  font-weight: 700;
  padding: 2px 6px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 6px;
  color: #94a3b8;
  font-family: monospace;
  white-space: nowrap;
  pointer-events: none;
  flex-shrink: 0;
}

.header-search-pill.has-query .search-kbd-chip,
.search-box.has-query .search-kbd {
  display: none;
}

.header-search-pill .search-clear,
.search-box .search-clear {
  display: none;
  background: transparent;
  border: none;
  color: #94a3b8;
  cursor: pointer;
  padding: 0;
  font-size: 0.95rem;
  transition: color 0.2s ease, transform 0.2s ease;
}

.header-search-pill .search-clear:hover,
.search-box .search-clear:hover {
  color: #ffffff;
  transform: scale(1.2);
}

.header-search-pill.has-query .search-clear,
.search-box.has-query .search-clear {
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Action Icons */
.header-action-icon,
.action-icon-btn {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.09);
  color: #cbd5e1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.15rem;
  position: relative;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  flex-shrink: 0;
}

.header-action-icon:hover,
.action-icon-btn:hover {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.2);
  transform: translateY(-1px);
}

.notification-red-dot {
  position: absolute;
  top: 7px;
  right: 8px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #ff202e;
  box-shadow: 0 0 8px #ff202e;
}

.header-action-icon .watchlist-badge,
.action-icon-btn .badge {
  position: absolute;
  top: -3px;
  right: -3px;
  background: linear-gradient(135deg, #e50914, #ff5722);
  color: #fff;
  font-size: 0.62rem;
  font-weight: 800;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid #080b13;
  box-shadow: 0 0 10px rgba(229, 9, 20, 0.6);
}

/* Library Refresh Live Telemetry Status Pill */
.header-sync-status-pill,
.library-refresh-chip {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 0 12px;
  height: 34px;
  border-radius: 999px;
  background: rgba(16, 185, 129, 0.08);
  border: 1px solid rgba(16, 185, 129, 0.32);
  color: #34d399;
  font-size: 0.74rem;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 0 12px rgba(16, 185, 129, 0.12);
  transition: all 0.25s ease;
  white-space: nowrap;
  flex-shrink: 0;
}

.header-sync-status-pill:hover,
.library-refresh-chip:hover {
  background: rgba(16, 185, 129, 0.18);
  border-color: rgba(16, 185, 129, 0.55);
  box-shadow: 0 0 18px rgba(16, 185, 129, 0.28);
  transform: translateY(-1px);
}

.header-sync-status-pill .sync-dot,
.library-refresh-chip .sync-dot {
  position: relative;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #10b981;
  box-shadow: 0 0 8px #10b981;
}

.header-sync-status-pill .sync-dot::after,
.library-refresh-chip .sync-dot::after {
  content: '';
  position: absolute;
  inset: -3px;
  border-radius: 50%;
  border: 1px solid #10b981;
  animation: radarPing 2s infinite cubic-bezier(0, 0.2, 0.8, 1);
}

@keyframes radarPing {
  0% { transform: scale(0.6); opacity: 1; }
  100% { transform: scale(2.2); opacity: 0; }
}

/* Rescan "Refresh" Button */
.header-sync-now-btn,
.rescan-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 0 14px;
  height: 34px;
  border-radius: 999px;
  background: linear-gradient(135deg, rgba(229, 9, 20, 0.2) 0%, rgba(255, 87, 34, 0.2) 100%);
  border: 1px solid rgba(229, 9, 20, 0.5);
  color: #ffffff;
  font-size: 0.74rem;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 0 14px rgba(229, 9, 20, 0.25);
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  white-space: nowrap;
  flex-shrink: 0;
}

.header-sync-now-btn i,
.rescan-btn i {
  color: #ff3b30;
  font-size: 0.88rem;
  transition: transform 0.2s ease;
}

.header-sync-now-btn:hover,
.rescan-btn:hover {
  background: linear-gradient(135deg, #e50914 0%, #ff5722 100%);
  border-color: transparent;
  color: #ffffff;
  box-shadow: 0 4px 20px rgba(229, 9, 20, 0.6);
  transform: translateY(-1px);
}

.header-sync-now-btn:hover i,
.rescan-btn:hover i {
  color: #ffffff;
}

.header-sync-now-btn.scanning #rescanIcon,
.rescan-btn.scanning #rescanIcon {
  animation: spin 0.9s linear infinite;
  color: #fff;
}

/* Responsive Rules for Header & PillNav */
@media (max-width: 1200px) {
  .pill-nav {
    --pill-pad-x: 12px;
  }
  .header-search-pill {
    width: 170px;
  }
  .header-search-pill:focus-within {
    width: 210px;
  }
}

@media (max-width: 992px) {
  .header-sync-status-pill {
    display: none;
  }
  .pill-nav {
    --pill-pad-x: 10px;
  }
}

@media (max-width: 768px) {
  .desktop-only {
    display: none !important;
  }
  .mobile-only {
    display: flex !important;
  }
  .header-container {
    padding: 0 1rem;
  }
  .header-search-pill {
    display: none;
  }
  .header-sync-now-btn {
    padding: 0 10px;
  }
  .header-sync-now-btn span {
    display: none;
  }
}

/* ========================================================================== 
   Top 10 Stylized Outlined Numbers
   ========================================================================== */
.top10-card-wrap {
  position: relative;
  flex: 0 0 268px;
  display: flex;
  align-items: flex-end;
  padding-left: 64px;
  margin-right: 18px;
  scroll-snap-align: start;
}

.top10-rank-num {
  position: absolute;
  left: -6px;
  bottom: 12px;
  font-size: 7.2rem;
  font-family: var(--font-heading);
  font-weight: 900;
  line-height: 0.72;
  letter-spacing: -6px;
  background: linear-gradient(180deg, #ffffff 0%, #cbd5e1 38%, #64748b 80%, #334155 100%);
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  filter: drop-shadow(2px 6px 14px rgba(0, 0, 0, 0.95)) drop-shadow(0 0 1px rgba(255, 255, 255, 0.35));
  z-index: 2;
  pointer-events: none;
  transition: transform 0.4s cubic-bezier(0.22, 1, 0.36, 1), filter 0.4s ease;
  user-select: none;
}

.top10-card-wrap .movie-card {
  flex: 0 0 205px;
  width: 205px;
  scroll-snap-align: none;
}

.top10-card-wrap:hover .top10-rank-num {
  transform: scale(1.08) translateY(-4px);
  background: linear-gradient(180deg, #ffffff 0%, #ff6b6b 35%, #e50914 80%, #7f0005 100%);
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 0 24px rgba(229, 9, 20, 0.8)) drop-shadow(2px 6px 16px rgba(0, 0, 0, 0.95));
}

/* ==========================================================================
   Filter & Category Chips Bar
   ========================================================================== */
.filters-container {
  max-width: 1600px;
  margin: -1.5rem auto 2rem;
  padding: 0 2rem;
  position: relative;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}

.categories-scroll {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  overflow-x: auto;
  padding-bottom: 0.5rem;
  scrollbar-width: none;
}

.categories-scroll::-webkit-scrollbar {
  display: none;
}

.chip {
  white-space: nowrap;
  background: rgba(23, 30, 46, 0.6);
  backdrop-filter: blur(12px);
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  font-family: var(--font-body);
  font-size: 0.85rem;
  font-weight: 500;
  padding: 0.5rem 1rem;
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: all var(--duration-fast) ease;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.chip:hover {
  background: rgba(35, 45, 68, 0.8);
  color: #fff;
  border-color: rgba(255, 255, 255, 0.2);
}

.chip.active {
  background: linear-gradient(135deg, #e50914 0%, #ff3b30 100%);
  color: #fff;
  border-color: rgba(255, 255, 255, 0.35);
  font-weight: 600;
  box-shadow: 0 4px 18px rgba(229, 9, 20, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

.filters-right {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-shrink: 0;
}

.custom-select select {
  background: rgba(23, 30, 46, 0.6);
  backdrop-filter: blur(12px);
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  font-family: var(--font-body);
  font-size: 0.82rem;
  font-weight: 500;
  padding: 0.5rem 1rem;
  border-radius: var(--radius-full);
  cursor: pointer;
  outline: none;
  transition: all var(--duration-fast) ease;
}

.custom-select select:hover, .custom-select select:focus {
  border-color: var(--accent-red);
  color: #fff;
}

/* ==========================================================================
   Rails & Grids Layout
   ========================================================================== */
.content-wrapper {
  position: relative;
  z-index: 2;
  max-width: 1600px;
  margin: 0 auto;
  padding: 0 2rem 4rem;
}

.rails-container {
  position: relative;
  z-index: 2;
}

.rail-section {
  position: relative;
  z-index: 2;
  margin-bottom: 3.5rem;
}

.section-header {
  position: relative;
  z-index: 3;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  margin-bottom: 1.25rem;
  gap: 1rem;
}

.section-title-wrap {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.35rem;
  max-width: 100%;
}

.section-title {
  font-family: var(--font-heading);
  font-size: 1.65rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: #ffffff !important;
  text-shadow: 0 2px 14px rgba(0, 0, 0, 0.85);
  display: flex;
  align-items: center;
  gap: 0.55rem;
  flex-wrap: wrap;
}

.section-subtitle {
  font-size: 0.88rem;
  font-weight: 500;
  color: #94a3b8;
  margin-top: 0.2rem;
  line-height: 1.4;
}

.section-view-all {
  background: rgba(229, 9, 20, 0.12);
  border: 1px solid rgba(229, 9, 20, 0.38);
  color: #ffffff !important;
  font-size: 0.82rem;
  font-weight: 700;
  padding: 6px 14px;
  border-radius: 999px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  transition: all var(--duration-fast) ease;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.6);
  flex-shrink: 0;
}

.section-view-all:hover {
  background: rgba(229, 9, 20, 0.28);
  border-color: rgba(229, 9, 20, 0.65);
  transform: translateX(4px);
  box-shadow: 0 0 16px rgba(229, 9, 20, 0.45);
}

.rail-wrapper {
  position: relative;
  width: 100%;
}

.rail-scroll-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(14, 18, 26, 0.9);
  border: 1px solid rgba(255, 255, 255, 0.16);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  cursor: pointer;
  z-index: 10;
  backdrop-filter: blur(12px);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.6);
  transition: all 0.25s var(--ease-smooth);
  opacity: 0;
}

.rail-wrapper:hover .rail-scroll-btn {
  opacity: 1;
}

.rail-scroll-btn:hover {
  background: var(--accent-red);
  border-color: var(--accent-red);
  transform: translateY(-50%) scale(1.1);
  box-shadow: 0 0 20px rgba(229, 9, 20, 0.5);
}

.rail-scroll-btn.left {
  left: -20px;
}

.rail-scroll-btn.right {
  right: -20px;
}

.rail-carousel {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 210px;
  gap: 1.25rem;
  overflow-x: auto;
  padding: 0.5rem 0.2rem 1.2rem;
  scroll-behavior: smooth;
  scroll-snap-type: x mandatory;
}

.rail-carousel::-webkit-scrollbar {
  height: 6px;
}
.rail-carousel::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.1);
  border-radius: 10px;
}

/* ==========================================================================
   Animation & Family Adventures Thematic Styling
   ========================================================================== */
.rail-section.anime-rail {
  position: relative;
  background: linear-gradient(180deg, rgba(236, 72, 153, 0.04) 0%, rgba(139, 92, 246, 0.02) 100%);
  border-radius: 20px;
  padding: 1.25rem 1rem 0.5rem;
  margin: 1.5rem 0;
  border: 1px solid rgba(236, 72, 153, 0.15);
  box-shadow: 0 10px 30px -10px rgba(236, 72, 153, 0.1);
}

.anime-sparkle-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.72rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  padding: 4px 12px;
  border-radius: 999px;
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.18), rgba(236, 72, 153, 0.18));
  border: 1px solid rgba(236, 72, 153, 0.4);
  color: #f472b6;
  margin-bottom: 0.35rem;
  box-shadow: 0 0 12px rgba(236, 72, 153, 0.25);
}

.anime-sparkle-pill i {
  color: #fbbf24;
  animation: sparkleTwinkle 2s ease-in-out infinite alternate;
}

@keyframes sparkleTwinkle {
  0% { transform: scale(0.9) rotate(0deg); opacity: 0.7; }
  100% { transform: scale(1.2) rotate(20deg); opacity: 1; }
}

.anime-header .section-title {
  display: flex;
  align-items: center;
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 800;
  background: linear-gradient(90deg, #ffffff 30%, #f472b6 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 0.2rem;
}

.anime-title-icon {
  display: inline-block;
  color: #ec4899;
  margin-right: 0.5rem;
  animation: balloonFloat 3s ease-in-out infinite alternate;
}

@keyframes balloonFloat {
  0% { transform: translateY(0px) rotate(-3deg); }
  100% { transform: translateY(-4px) rotate(4deg); }
}

.section-subtitle {
  font-size: 0.85rem;
  color: var(--text-secondary);
  font-weight: 400;
  line-height: 1.4;
  margin: 0.1rem 0 0.5rem;
}

.anime-view-all {
  background: linear-gradient(135deg, rgba(236, 72, 153, 0.12), rgba(139, 92, 246, 0.12));
  border: 1px solid rgba(236, 72, 153, 0.3);
  color: #f472b6;
  padding: 0.45rem 1rem;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.8rem;
  transition: all 0.25s ease;
}

.anime-view-all:hover {
  background: linear-gradient(135deg, #ec4899, #8b5cf6);
  color: #fff;
  box-shadow: 0 4px 16px rgba(236, 72, 153, 0.4);
  transform: translateX(3px);
}

.anime-carousel .movie-card {
  border-color: rgba(236, 72, 153, 0.15);
}

.anime-carousel .movie-card:hover {
  border-color: rgba(236, 72, 153, 0.5);
  box-shadow: 0 16px 36px rgba(236, 72, 153, 0.25), 0 0 20px rgba(139, 92, 246, 0.2);
}

.movies-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
  gap: 1.5rem;
}

/* ==========================================================================
   Movie Card Component
   ========================================================================== */
.movie-card {
  position: relative;
  background: linear-gradient(180deg, rgba(20, 26, 38, 0.8) 0%, rgba(13, 17, 26, 0.96) 100%);
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
  transition: all var(--duration-normal) var(--ease-smooth);
  cursor: pointer;
  display: flex;
  flex-direction: column;
  scroll-snap-align: start;
}

.movie-card:hover {
  transform: translateY(-8px) scale(1.02);
  border-color: rgba(229, 9, 20, 0.5);
  box-shadow: 0 18px 36px -8px rgba(229, 9, 20, 0.3), 0 8px 24px rgba(0, 0, 0, 0.7);
  z-index: 5;
}

.card-poster-wrap {
  position: relative;
  width: 100%;
  padding-top: 145%; /* 2:3 aspect ratio */
  background: #111520;
  overflow: hidden;
}

/* Subtle inner border and smooth gradient to eliminate raw/harsh high-res downsampling */
.card-poster-wrap::after {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 1;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.09);
  background: linear-gradient(180deg, rgba(7, 9, 14, 0) 45%, rgba(7, 9, 14, 0.4) 80%, rgba(7, 9, 14, 0.85) 100%);
  border-radius: inherit;
  transition: opacity 0.3s ease;
}

.card-poster {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  image-rendering: auto;
  transform: translateZ(0);
  backface-visibility: hidden;
  transition: transform 0.5s var(--ease-smooth);
}

.movie-card:hover .card-poster {
  transform: scale(1.08);
}

.card-badges {
  position: absolute;
  top: 0.6rem;
  left: 0.6rem;
  right: 0.6rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  pointer-events: none;
  z-index: 2;
}

.badge-quality {
  background: rgba(10, 14, 23, 0.85);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: #fff;
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.4px;
  padding: 3px 8px;
  border-radius: 6px;
  text-transform: uppercase;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
}

.badge-quality.fhd {
  background: linear-gradient(135deg, rgba(229, 9, 20, 0.95), rgba(185, 28, 28, 0.95));
  border-color: rgba(255, 255, 255, 0.25);
  box-shadow: 0 2px 10px rgba(229, 9, 20, 0.4);
}

.badge-audio {
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.92), rgba(217, 119, 6, 0.95));
  color: #07090e;
  font-size: 0.64rem;
  font-weight: 800;
  letter-spacing: 0.3px;
  padding: 3px 7px;
  border-radius: 6px;
  box-shadow: 0 2px 8px rgba(245, 158, 11, 0.35);
}

.card-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(7, 9, 14, 0.95) 0%, rgba(7, 9, 14, 0.6) 40%, transparent 100%);
  opacity: 0;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 1rem;
  transition: opacity var(--duration-fast) ease;
  z-index: 3;
}

.movie-card:hover .card-overlay {
  opacity: 1;
}

.card-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 0.75rem;
}

.action-play-btn {
  flex: 1;
  background: var(--accent-red);
  color: #fff;
  border: none;
  padding: 0.5rem;
  border-radius: var(--radius-sm);
  font-size: 0.8rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  cursor: pointer;
  transition: background var(--duration-fast) ease;
}

.action-play-btn:hover {
  background: var(--accent-red-hover);
}

.action-btn-sm {
  width: 32px;
  height: 32px;
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.95rem;
  cursor: pointer;
  transition: all var(--duration-fast) ease;
  text-decoration: none;
}

.action-btn-sm:hover {
  background: rgba(255, 255, 255, 0.3);
}

.card-info {
  padding: 0.85rem;
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  flex-grow: 1;
}

.card-title {
  font-family: var(--font-heading);
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.76rem;
  color: var(--text-muted);
}

.card-size {
  color: var(--accent-amber);
  font-weight: 600;
}

/* ==========================================================================
   Streaming Modal & Video Player
   ========================================================================== */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(4, 6, 10, 0.85);
  backdrop-filter: blur(25px);
  -webkit-backdrop-filter: blur(25px);
  z-index: 2000;
  display: none;
  align-items: flex-start;
  justify-content: center;
  padding: 2rem 1.5rem;
  overflow-y: auto;
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--duration-normal) var(--ease-smooth);
}

.modal-overlay.active {
  display: flex;
  opacity: 1;
  pointer-events: auto;
}

.modal-dialog {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  width: 100%;
  max-width: 1050px;
  overflow: hidden;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.8), 0 0 40px rgba(229, 9, 20, 0.15);
  transform: scale(0.95) translateY(20px);
  transition: transform var(--duration-normal) var(--ease-smooth);
  margin: auto;
  position: relative;
}

.modal-dialog.cinema-theater-dialog {
  max-width: 1180px;
  background: rgba(10, 14, 22, 0.96);
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: 0 35px 90px -10px rgba(0, 0, 0, 0.95), 0 0 50px rgba(229, 9, 20, 0.15);
  overflow: visible;
}

.cinema-ambient-glow {
  position: absolute;
  inset: -25px;
  background: radial-gradient(circle at 50% 30%, rgba(229, 9, 20, 0.15), rgba(56, 189, 248, 0.08) 60%, transparent 85%);
  border-radius: 35px;
  filter: blur(35px);
  pointer-events: none;
  z-index: -1;
  opacity: 0.75;
  transition: opacity 0.5s ease;
}

.modal-overlay.active .modal-dialog {
  transform: scale(1) translateY(0);
}

.modal-header.cinema-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.9rem 1.4rem;
  background: linear-gradient(180deg, rgba(16, 21, 33, 0.98) 0%, rgba(10, 14, 22, 0.92) 100%);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 20px 20px 0 0;
  gap: 1rem;
}

.modal-title-group {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  min-width: 0;
  flex: 1;
}

.live-stream-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.65rem;
  font-weight: 800;
  letter-spacing: 0.8px;
  color: #34d399;
  background: rgba(16, 185, 129, 0.12);
  border: 1px solid rgba(16, 185, 129, 0.35);
  padding: 2px 8px;
  border-radius: 999px;
  white-space: nowrap;
}

.pulse-emerald {
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #10b981;
  box-shadow: 0 0 8px #10b981;
  animation: pulseGreen 1.6s ease-in-out infinite alternate;
}

@keyframes pulseGreen {
  0% { transform: scale(0.8); opacity: 0.6; }
  100% { transform: scale(1.3); opacity: 1; }
}

.modal-badge {
  font-size: 0.72rem;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 4px;
  white-space: nowrap;
}
.modal-badge.red {
  background: linear-gradient(135deg, #e50914, #b20710);
  color: #fff;
  box-shadow: 0 0 10px rgba(229, 9, 20, 0.4);
}
.modal-badge.amber {
  background: rgba(245, 158, 11, 0.15);
  color: #fbbf24;
  border: 1px solid rgba(245, 158, 11, 0.35);
}

.modal-title {
  font-family: var(--font-heading);
  font-size: 1.1rem;
  font-weight: 700;
  color: #fff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  letter-spacing: -0.2px;
}

.modal-header-actions {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  flex-shrink: 0;
}

.cinema-hdr-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  height: 32px;
  padding: 0 0.75rem;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #cbd5e1;
  font-size: 0.75rem;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  white-space: nowrap;
}

.cinema-hdr-btn:hover {
  background: rgba(255, 255, 255, 0.15);
  color: #fff;
  border-color: rgba(255, 255, 255, 0.25);
  transform: translateY(-1px);
}

.cinema-hdr-btn:active {
  transform: scale(0.96);
}

.cinema-hdr-btn.download-highlight {
  background: linear-gradient(135deg, #e50914, #ff5252);
  border-color: rgba(255, 255, 255, 0.3);
  color: #fff;
  box-shadow: 0 4px 14px rgba(229, 9, 20, 0.4);
}

.cinema-hdr-btn.download-highlight:hover {
  background: linear-gradient(135deg, #f40612, #ff6b6b);
  box-shadow: 0 6px 20px rgba(229, 9, 20, 0.6);
}

.cinema-hdr-btn.icon-only {
  width: 32px;
  height: 32px;
  padding: 0;
  justify-content: center;
  font-size: 0.95rem;
}

.modal-close-btn {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #cbd5e1;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  cursor: pointer;
  transition: all 0.2s ease;
  margin-left: 0.2rem;
}

.modal-close-btn:hover {
  background: rgba(229, 9, 20, 0.8);
  border-color: #e50914;
  color: #fff;
  transform: rotate(90deg) scale(1.08);
}

/* ==========================================================================
   Cinema Video Player Wrapper & Controls
   ========================================================================== */
.cinema-player-wrapper {
  position: relative;
  width: 100%;
  background: #000;
  aspect-ratio: 16 / 9;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  user-select: none;
  outline: none;
  transition: border-color 0.2s ease, background-color 0.2s ease;
}

.cinema-player-wrapper.drag-active {
  border: 2px dashed var(--accent-cyan) !important;
  background: rgba(0, 240, 255, 0.08) !important;
}

.cinema-player-wrapper.drag-active::after {
  content: 'Drop .SRT or .VTT Subtitle File Here';
  position: absolute;
  color: #fff;
  font-family: var(--font-heading);
  font-size: 1.05rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  background: rgba(6, 8, 13, 0.9);
  padding: 10px 24px;
  border-radius: 8px;
  border: 1px solid var(--accent-cyan);
  box-shadow: 0 8px 24px rgba(0, 240, 255, 0.3);
  pointer-events: none;
  z-index: 25;
}

.cinema-player-wrapper video {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
  outline: none;
  cursor: pointer;
  background: #000;
}

/* Aspect ratio variations */
.cinema-player-wrapper video.aspect-fit { object-fit: contain; }
.cinema-player-wrapper video.aspect-fill { object-fit: fill; }
.cinema-player-wrapper video.aspect-cover { object-fit: cover; }
.cinema-player-wrapper video.aspect-cinema { object-fit: cover; aspect-ratio: 21 / 9; }

/* Theater Mode */
.modal-overlay.theater-active .modal-dialog {
  max-width: 96vw !important;
  width: 96vw !important;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.modal-overlay.theater-active .cinema-player-wrapper {
  max-height: 80vh;
}

/* Custom Subtitle Display Layer */
.custom-subtitle-layer {
  position: absolute;
  bottom: 68px;
  left: 5%;
  right: 5%;
  text-align: center;
  pointer-events: none;
  z-index: 15;
  transition: bottom 0.2s ease;
}

.cinema-controls.hidden ~ .custom-subtitle-layer {
  bottom: 25px;
}

.sub-cue-box {
  display: inline-block;
  background: rgba(0, 0, 0, 0.78);
  color: #fff;
  padding: 4px 14px;
  border-radius: 6px;
  font-family: var(--font-body), sans-serif;
  font-weight: 600;
  line-height: 1.45;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.95);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
  max-width: 85%;
  word-break: break-word;
}

.sub-cue-box.sub-small { font-size: 1rem; }
.sub-cue-box.sub-medium { font-size: 1.25rem; }
.sub-cue-box.sub-large { font-size: 1.6rem; font-weight: 700; }

/* Buffering / Loader */
.player-loader {
  position: absolute;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
  color: var(--text-secondary);
  font-size: 0.9rem;
  pointer-events: none;
  z-index: 20;
}

.player-loader.hidden {
  display: none;
}

.spinner {
  width: 44px;
  height: 44px;
  border: 3px solid rgba(229, 9, 20, 0.2);
  border-top-color: var(--accent-red);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

/* Center Feedback Animation Overlay */
.center-feedback-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
  z-index: 22;
}

.feedback-bubble {
  width: 74px;
  height: 74px;
  border-radius: 50%;
  background: rgba(10, 14, 22, 0.85);
  backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.15);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  font-size: 2.2rem;
  color: #fff;
  opacity: 0;
  transform: scale(0.6);
  transition: all 0.25s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6), 0 0 20px rgba(229, 9, 20, 0.4);
}

.feedback-bubble.active {
  opacity: 1;
  transform: scale(1.1);
}

.feedback-bubble span {
  font-size: 0.75rem;
  font-weight: 700;
  margin-top: -2px;
}

/* Double-Click Seek Ripples */
.seek-ripple {
  position: absolute;
  top: 0;
  bottom: 60px;
  width: 35%;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
  opacity: 0;
  z-index: 21;
  transition: opacity 0.2s ease;
}

.seek-ripple.seek-left {
  left: 0;
  background: radial-gradient(circle at left center, rgba(255, 255, 255, 0.12), transparent 70%);
  border-top-right-radius: 50%;
  border-bottom-right-radius: 50%;
}

.seek-ripple.seek-right {
  right: 0;
  background: radial-gradient(circle at right center, rgba(255, 255, 255, 0.12), transparent 70%);
  border-top-left-radius: 50%;
  border-bottom-left-radius: 50%;
}

.seek-ripple.active {
  opacity: 1;
  animation: seekRipplePop 0.6s ease-out forwards;
}

@keyframes seekRipplePop {
  0% { transform: scale(0.9); opacity: 0.9; }
  100% { transform: scale(1); opacity: 0; }
}

.ripple-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.3rem;
  color: #fff;
  font-size: 1.8rem;
  font-weight: 700;
}

.ripple-content span {
  font-size: 0.85rem;
  letter-spacing: 0.5px;
}

/* Resume Playback Floating Banner */
.resume-banner {
  position: absolute;
  top: 1.25rem;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(14, 18, 28, 0.92);
  backdrop-filter: blur(16px);
  border: 1px solid rgba(229, 9, 20, 0.4);
  border-radius: 9999px;
  padding: 0.5rem 1rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  z-index: 30;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.7);
  animation: bannerSlideDown 0.3s ease;
}

@keyframes bannerSlideDown {
  from { transform: translate(-50%, -20px); opacity: 0; }
  to { transform: translate(-50%, 0); opacity: 1; }
}

.resume-content {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: #fff;
  font-size: 0.85rem;
  font-weight: 600;
}

.resume-content i {
  color: var(--accent-red);
  font-size: 1.1rem;
}

.resume-actions {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.btn-resume {
  background: var(--accent-red);
  color: #fff;
  border: none;
  border-radius: 9999px;
  padding: 4px 12px;
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.2s ease;
}

.btn-resume:hover {
  background: #f40612;
}

.btn-resume-alt {
  background: rgba(255, 255, 255, 0.12);
  color: #e2e8f0;
  border: none;
  border-radius: 9999px;
  padding: 4px 10px;
  font-size: 0.78rem;
  cursor: pointer;
  transition: background 0.2s ease;
}

.btn-resume-alt:hover {
  background: rgba(255, 255, 255, 0.22);
}

/* Audio Codec Alert Banner — Modern Glassmorphism */
.audio-codec-alert {
  position: absolute;
  top: 1.25rem;
  left: 1.5rem;
  right: 1.5rem;
  background: rgba(18, 22, 34, 0.88);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border: 1px solid rgba(245, 158, 11, 0.35);
  border-radius: 12px;
  padding: 0.75rem 1.15rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  z-index: 35;
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.75), 0 0 24px rgba(245, 158, 11, 0.12);
  animation: slideDownAlert 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes slideDownAlert {
  from { opacity: 0; transform: translateY(-12px); }
  to { opacity: 1; transform: translateY(0); }
}

.codec-alert-left {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  min-width: 0;
}

.codec-alert-icon {
  font-size: 1.6rem;
  color: #f59e0b;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.codec-alert-title {
  font-size: 0.88rem;
  font-weight: 700;
  color: #ffffff;
  letter-spacing: 0.2px;
}

.codec-alert-desc {
  font-size: 0.78rem;
  color: #94a3b8;
  margin-top: 2px;
  line-height: 1.35;
}

.codec-alert-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-shrink: 0;
}

.codec-pill-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.44rem 0.9rem;
  border-radius: 8px;
  font-size: 0.78rem;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  outline: none;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  white-space: nowrap;
}

.codec-pill-btn.vlc {
  background: rgba(245, 158, 11, 0.16);
  border: 1px solid rgba(245, 158, 11, 0.45);
  color: #fbbf24;
}
.codec-pill-btn.vlc:hover {
  background: rgba(245, 158, 11, 0.3);
  border-color: #f59e0b;
  color: #fff;
  transform: translateY(-1px);
  box-shadow: 0 4px 14px rgba(245, 158, 11, 0.3);
}

.codec-pill-btn.potplayer {
  background: rgba(56, 189, 248, 0.12);
  border: 1px solid rgba(56, 189, 248, 0.38);
  color: #38bdf8;
}
.codec-pill-btn.potplayer:hover {
  background: rgba(56, 189, 248, 0.25);
  border-color: #38bdf8;
  color: #fff;
  transform: translateY(-1px);
  box-shadow: 0 4px 14px rgba(56, 189, 248, 0.25);
}

.codec-pill-btn.download {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: #e2e8f0;
}
.codec-pill-btn.download:hover {
  background: rgba(255, 255, 255, 0.18);
  border-color: rgba(255, 255, 255, 0.35);
  color: #fff;
  transform: translateY(-1px);
}

.codec-close-btn {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #94a3b8;
  cursor: pointer;
  transition: all 0.2s ease;
  font-size: 0.95rem;
  margin-left: 0.2rem;
}
.codec-close-btn:hover {
  background: rgba(255, 255, 255, 0.18);
  border-color: rgba(255, 255, 255, 0.25);
  color: #fff;
  transform: rotate(90deg);
}

.cinema-player-wrapper::after {
  display: none !important;
}

.cinema-controls {
  position: absolute;
  bottom: 16px;
  left: 20px;
  right: 20px;
  z-index: 25;
  display: flex;
  flex-direction: column;
  padding: 8px 16px 10px;
  background: rgba(8, 12, 20, 0.76);
  backdrop-filter: blur(28px) saturate(190%);
  -webkit-backdrop-filter: blur(28px) saturate(190%);
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.75), 0 0 0 1px rgba(255, 255, 255, 0.05), inset 0 1px 0 rgba(255, 255, 255, 0.16);
  transition: opacity 0.35s cubic-bezier(0.16, 1, 0.3, 1), transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

.cinema-controls.hidden {
  opacity: 0;
  pointer-events: none;
  transform: translateY(22px);
}

.cinema-player-wrapper:not(.controls-visible) video {
  cursor: none;
}

.controls-backdrop {
  display: none;
}

/* Center Big Floating Play Trigger (Shows when paused/idle) */
.center-play-trigger {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) scale(1);
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: rgba(15, 23, 42, 0.75);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border: 2px solid rgba(255, 255, 255, 0.25);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 22;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.7), 0 0 30px rgba(229, 9, 20, 0.4);
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.center-play-trigger:hover {
  transform: translate(-50%, -50%) scale(1.12);
  background: rgba(229, 9, 20, 0.9);
  border-color: rgba(255, 255, 255, 0.6);
  box-shadow: 0 16px 50px rgba(229, 9, 20, 0.8), 0 0 40px rgba(255, 82, 82, 0.8);
}

.center-play-trigger:active {
  transform: translate(-50%, -50%) scale(0.95);
}

.center-play-trigger i {
  font-size: 2.4rem;
  color: #ffffff;
  margin-left: 4px;
  transition: transform 0.2s ease;
}

.center-play-trigger.hidden {
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, -50%) scale(0.6);
}

.center-play-ring {
  position: absolute;
  inset: -6px;
  border-radius: 50%;
  border: 2px dashed rgba(255, 255, 255, 0.35);
  animation: spinRingSlow 14s linear infinite;
  pointer-events: none;
}

@keyframes spinRingSlow {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

/* Scrub Timeline Progress Bar */
.scrub-container {
  position: relative;
  height: 32px;
  display: flex;
  align-items: center;
  cursor: pointer;
  padding: 0;
  margin-bottom: 0.25rem;
}

.scrub-track {
  position: relative;
  width: 100%;
  height: 6px;
  background: rgba(255, 255, 255, 0.16);
  border-radius: 999px;
  transition: height 0.22s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.scrub-container:hover .scrub-track,
.scrub-container.scrubbing .scrub-track {
  height: 10px;
}

.scrub-buffer {
  position: absolute;
  left: 0;
  top: 0;
  height: 100%;
  width: 0%;
  background: rgba(255, 255, 255, 0.28);
  border-radius: 999px;
  transition: width 0.25s ease;
}

.scrub-progress {
  position: absolute;
  left: 0;
  top: 0;
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, #ff1a40 0%, #ff5252 50%, #ff9800 100%);
  border-radius: 999px;
  box-shadow: 0 0 16px rgba(255, 26, 64, 0.85), 0 0 6px rgba(255, 152, 0, 0.6);
}

.scrub-thumb {
  position: absolute;
  right: -8px;
  top: 50%;
  width: 16px;
  height: 16px;
  background: #ffffff;
  border-radius: 50%;
  transform: translateY(-50%) scale(0.6);
  box-shadow: 0 0 0 4px rgba(255, 26, 64, 0.45), 0 0 12px rgba(255, 26, 64, 0.8), 0 2px 8px rgba(0, 0, 0, 0.7);
  transition: transform 0.22s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.scrub-container:hover .scrub-thumb,
.scrub-container.scrubbing .scrub-thumb {
  transform: translateY(-50%) scale(1.2);
}

.scrub-hover-tooltip {
  position: absolute;
  bottom: 32px;
  left: 0;
  transform: translateX(-50%);
  background: rgba(15, 23, 42, 0.96);
  backdrop-filter: blur(14px);
  color: #fff;
  padding: 4px 10px;
  border-radius: 7px;
  font-size: 0.75rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.15s ease;
  border: 1px solid rgba(255, 42, 75, 0.4);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.7), 0 0 12px rgba(255, 42, 75, 0.25);
  white-space: nowrap;
}

.scrub-hover-tooltip::after {
  content: '';
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  border-width: 5px;
  border-style: solid;
  border-color: rgba(15, 23, 42, 0.96) transparent transparent transparent;
}

.scrub-container:hover .scrub-hover-tooltip {
  opacity: 1;
}

/* Controls Buttons Row */
.controls-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.15rem 0.25rem 0.35rem;
  gap: 0.5rem;
}

.controls-left,
.controls-right {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.c-btn {
  position: relative;
  width: 38px;
  height: 38px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.06);
  color: #cbd5e1;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.15rem;
  cursor: pointer;
  outline: none;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.c-btn:focus,
.c-btn:focus-visible {
  outline: none !important;
  border-color: rgba(229, 9, 20, 0.8) !important;
  box-shadow: 0 0 14px rgba(229, 9, 20, 0.4) !important;
}

.c-btn:hover {
  background: rgba(255, 255, 255, 0.16);
  border-color: rgba(255, 255, 255, 0.25);
  color: #fff;
  transform: translateY(-2px) scale(1.08);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.35);
}

.c-btn:active {
  transform: scale(0.92);
}

/* Main Play/Pause prominent circle button */
#ctrlPlayBtn {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: linear-gradient(135deg, #e50914 0%, #ff3b30 100%);
  border: 1px solid rgba(255, 255, 255, 0.25);
  font-size: 1.4rem;
  color: #fff;
  box-shadow: 0 4px 18px rgba(229, 9, 20, 0.55), inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

#ctrlPlayBtn:hover {
  background: linear-gradient(135deg, #ff1a2b 0%, #ff5252 100%);
  box-shadow: 0 6px 24px rgba(229, 9, 20, 0.8), 0 0 20px rgba(255, 82, 82, 0.5);
  transform: scale(1.12);
}

.skip-btn {
  display: flex;
  align-items: center;
  justify-content: center;
}

.skip-btn svg {
  transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  overflow: visible;
}

.skip-btn:hover svg {
  transform: scale(1.14);
}

/* Audio Track Button & Non-overlapping Badge */
#ctrlAudioTrackBtn {
  width: auto;
  min-width: 38px;
  padding: 0 10px;
  gap: 6px;
  border-radius: 999px;
}

#ctrlAudioTrackBtn #audioTrackBadge {
  position: static;
  font-size: 0.68rem;
  font-weight: 700;
  background: rgba(229, 9, 20, 0.25);
  border: 1px solid rgba(229, 9, 20, 0.5);
  color: #ff8a80;
  padding: 2px 7px;
  border-radius: 999px;
  box-shadow: none;
  display: none;
  white-space: nowrap;
}

.c-btn-badge {
  position: absolute;
  top: 1px;
  right: 1px;
  font-size: 0.55rem;
  font-weight: 800;
  background: linear-gradient(135deg, #e50914, #ff5252);
  color: #fff;
  padding: 1px 4px;
  border-radius: 999px;
  box-shadow: 0 0 8px rgba(229, 9, 20, 0.6);
  white-space: nowrap;
}

/* Cinema Volume Controller (Non-overlapping, strictly bounded) */
.volume-group {
  position: relative;
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.volume-slider-box {
  position: relative;
  width: 0;
  opacity: 0;
  height: 32px;
  display: flex;
  align-items: center;
  cursor: pointer;
  overflow: visible;
  transition: width 0.25s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.2s ease, margin 0.2s ease;
  user-select: none;
  touch-action: none;
}

.volume-group:hover .volume-slider-box,
.volume-group:focus-within .volume-slider-box,
.volume-slider-box.active-volume {
  width: 82px;
  opacity: 1;
  margin-left: 0.3rem;
  margin-right: 0.4rem;
}

.volume-track {
  position: relative;
  width: 100%;
  height: 5px;
  background: rgba(255, 255, 255, 0.22);
  border-radius: 999px;
  pointer-events: none;
  transition: height 0.15s ease;
}

.volume-slider-box:hover .volume-track,
.volume-slider-box.active-volume .volume-track {
  height: 6px;
}

.volume-fill {
  position: absolute;
  left: 0;
  top: 0;
  height: 100%;
  width: 100%;
  max-width: 100%;
  background: linear-gradient(90deg, #e50914 0%, #ff5252 100%);
  border-radius: 999px;
  box-shadow: 0 0 10px rgba(229, 9, 20, 0.6);
  pointer-events: none;
}

.volume-thumb {
  position: absolute;
  top: 50%;
  left: 100%;
  transform: translate(-50%, -50%) scale(0);
  width: 13px;
  height: 13px;
  background: #ffffff;
  border-radius: 50%;
  box-shadow: 0 0 0 3px rgba(229, 9, 20, 0.45), 0 2px 6px rgba(0, 0, 0, 0.7);
  pointer-events: none;
  transition: transform 0.15s ease;
}

.volume-slider-box:hover .volume-thumb,
.volume-slider-box.active-volume .volume-thumb {
  transform: translate(-50%, -50%) scale(1);
}

.volume-tooltip {
  position: absolute;
  bottom: 28px;
  left: 50%;
  transform: translateX(-50%) translateY(4px);
  background: rgba(15, 23, 42, 0.96);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  color: #fff;
  font-size: 0.72rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  padding: 2px 7px;
  border-radius: 6px;
  border: 1px solid rgba(229, 9, 20, 0.5);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.6);
  pointer-events: none;
  opacity: 0;
  white-space: nowrap;
  transition: opacity 0.18s ease, transform 0.18s ease;
  z-index: 30;
}

.volume-tooltip::after {
  content: '';
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  border-width: 4px;
  border-style: solid;
  border-color: rgba(15, 23, 42, 0.96) transparent transparent transparent;
}

.volume-slider-box:hover .volume-tooltip,
.volume-slider-box.active-volume .volume-tooltip {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* Time Display */
.time-display {
  color: #cbd5e1;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.4px;
  font-variant-numeric: tabular-nums;
  padding: 0 0.45rem;
  cursor: pointer;
  user-select: none;
  white-space: nowrap;
}

.time-display:hover {
  color: #fff;
}

.speed-label {
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: -0.2px;
}

/* ======================= ULTRA-SLEEK DROPDOWN PANELS ======================= */
.dropdown-wrapper {
  position: relative;
}

.dropdown-panel {
  position: absolute;
  bottom: 48px;
  right: 0;
  background: rgba(13, 17, 27, 0.96);
  backdrop-filter: blur(28px);
  -webkit-backdrop-filter: blur(28px);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 14px;
  padding: 0.6rem;
  min-width: 225px;
  max-width: 320px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.9), 0 0 1px 1px rgba(255, 255, 255, 0.1);
  display: none;
  flex-direction: column;
  gap: 0.25rem;
  z-index: 100;
  animation: dropUpSleek 0.22s cubic-bezier(0.16, 1, 0.3, 1);
}

#audioTrackPanel {
  min-width: 295px;
  max-width: 350px;
  padding: 0.75rem 0.65rem;
  background: rgba(12, 16, 26, 0.97);
  border: 1px solid rgba(255, 255, 255, 0.16);
}

@keyframes dropUpSleek {
  from { opacity: 0; transform: translateY(12px) scale(0.96); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

.dropdown-panel.active {
  display: flex;
}

.dropdown-header {
  font-size: 0.68rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.9px;
  color: var(--text-muted);
  padding: 0.25rem 0.5rem 0.2rem;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.dropdown-list {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  max-height: 240px;
  overflow-y: auto;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.dropdown-list::-webkit-scrollbar {
  display: none;
}

#audioPassthroughSection {
  margin-top: 0.45rem;
  padding-top: 0.45rem;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.dropdown-section-title {
  font-size: 0.68rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  color: var(--text-muted);
  padding: 0.2rem 0.5rem 0.3rem;
}

.external-player-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 0.5rem 0.75rem;
  border-radius: 8px;
  font-size: 0.8rem;
  font-weight: 600;
  transition: all 0.18s ease;
}

.external-player-item.vlc {
  color: #fbbf24;
}
.external-player-item.vlc:hover {
  background: rgba(245, 158, 11, 0.12);
  color: #fcd34d;
}

.external-player-item.potplayer {
  color: #38bdf8;
}
.external-player-item.potplayer:hover {
  background: rgba(56, 189, 248, 0.12);
  color: #7dd3fc;
}

.external-player-item.copy-link {
  color: #94a3b8;
}
.external-player-item.copy-link:hover {
  background: rgba(255, 255, 255, 0.08);
  color: #e2e8f0;
}

.dropdown-note {
  font-size: 0.73rem;
  line-height: 1.4;
  color: #64748b;
  margin-top: 0.45rem;
  padding: 0.45rem 0.65rem;
  background: rgba(255, 255, 255, 0.03);
  border-radius: 6px;
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.dropdown-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 0.5rem 0.7rem;
  border: 1px solid transparent;
  border-radius: 8px;
  background: transparent;
  color: #cbd5e1;
  font-size: 0.8rem;
  font-weight: 500;
  cursor: pointer;
  text-align: left;
  transition: all 0.18s ease;
  gap: 0.5rem;
}

.dropdown-item:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.12);
  color: #fff;
  transform: translateX(2px);
}

.dropdown-item.active {
  background: rgba(229, 9, 20, 0.15);
  border-color: rgba(229, 9, 20, 0.35);
  color: #ff6b6b;
  font-weight: 700;
}

.track-item-content {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  min-width: 0;
  flex: 1;
}

.track-icon {
  font-size: 0.95rem;
  color: var(--accent-red);
  flex-shrink: 0;
}

.track-title-text {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  flex: 1;
}

.track-codec-pill {
  font-size: 0.65rem;
  font-weight: 700;
  padding: 1px 5px;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.08);
  color: #94a3b8;
  flex-shrink: 0;
}

.track-check {
  color: var(--accent-red);
  font-size: 0.95rem;
  flex-shrink: 0;
}

.dropdown-divider {
  height: 1px;
  background: rgba(255, 255, 255, 0.08);
  margin: 0.35rem 0;
}

.dropdown-upload-btn {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.5rem 0.7rem;
  border-radius: 8px;
  background: rgba(56, 189, 248, 0.08);
  border: 1px dashed rgba(56, 189, 248, 0.35);
  color: #38bdf8;
  font-size: 0.76rem;
  font-weight: 600;
  cursor: pointer;
  margin-top: 0.25rem;
  transition: all 0.2s ease;
}

.dropdown-upload-btn:hover {
  background: rgba(56, 189, 248, 0.18);
  border-color: #38bdf8;
}

.dropdown-note {
  font-size: 0.68rem;
  color: var(--text-muted);
  padding: 0.35rem 0.5rem;
  line-height: 1.35;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  margin-top: 0.3rem;
}

.sync-controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.2rem 0.5rem;
  gap: 0.5rem;
}

.sync-btn {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #fff;
  border-radius: 6px;
  padding: 3px 8px;
  font-size: 0.72rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.15s ease;
}

.sync-btn:hover {
  background: rgba(255, 255, 255, 0.2);
}

.sync-offset-label {
  font-size: 0.75rem;
  font-weight: 700;
  color: #38bdf8;
  min-width: 35px;
  text-align: center;
}

.sub-size-row {
  display: flex;
  gap: 0.35rem;
  padding: 0.2rem 0.5rem 0.3rem;
}

.size-btn {
  flex: 1;
  padding: 4px 0;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #cbd5e1;
  border-radius: 6px;
  font-size: 0.72rem;
  cursor: pointer;
  transition: all 0.15s ease;
}

.size-btn.active {
  background: var(--accent-red);
  color: #fff;
  border-color: var(--accent-red);
}

/* ======================= ANIMATION EFFECTS & OVERLAYS ======================= */
/* Camera Flash Shutter Overlay */
.camera-flash-overlay {
  position: absolute;
  inset: 0;
  background: #ffffff;
  pointer-events: none;
  z-index: 50;
  opacity: 0;
}

.camera-flash-overlay.active {
  animation: cameraFlashAnim 0.45s ease-out forwards;
}

@keyframes cameraFlashAnim {
  0% { opacity: 0.85; }
  100% { opacity: 0; }
}

/* Floating HUD Pill (Volume, Speed, Feedback) */
.player-hud-pill {
  position: absolute;
  top: 1.5rem;
  left: 50%;
  transform: translateX(-50%) translateY(-10px) scale(0.92);
  background: rgba(10, 14, 24, 0.94);
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: #fff;
  padding: 0.45rem 1.25rem;
  border-radius: 999px;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.85rem;
  font-weight: 700;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.8), 0 0 20px rgba(229, 9, 20, 0.3);
  z-index: 45;
  opacity: 0;
  pointer-events: none;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.player-hud-pill.active {
  opacity: 1;
  transform: translateX(-50%) translateY(0) scale(1);
}

.hud-bar-wrap {
  width: 70px;
  height: 5px;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 999px;
  overflow: hidden;
}

.hud-bar-fill {
  height: 100%;
  width: 100%;
  background: linear-gradient(90deg, #e50914, #ff7a00);
  border-radius: 999px;
  transition: width 0.15s ease;
}

/* Center Feedback Bubble & Liquid Bloom */
.center-feedback-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
  z-index: 30;
}

.feedback-bubble {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transform: scale(0.65);
  transition: opacity 0.25s ease, transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.feedback-bubble.active {
  opacity: 1;
  transform: scale(1);
}

.bloom-core {
  width: 76px;
  height: 76px;
  border-radius: 50%;
  background: rgba(10, 14, 24, 0.85);
  backdrop-filter: blur(16px);
  border: 2px solid rgba(229, 9, 20, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.2rem;
  color: #fff;
  box-shadow: 0 0 35px rgba(229, 9, 20, 0.6), 0 10px 30px rgba(0, 0, 0, 0.7);
  animation: bloomPulse 0.6s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes bloomPulse {
  0% { transform: scale(0.8); }
  50% { transform: scale(1.12); }
  100% { transform: scale(1); }
}

/* Cinema Buffering Spinner */
.player-loader {
  position: absolute;
  inset: 0;
  background: rgba(6, 8, 14, 0.85);
  backdrop-filter: blur(12px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  z-index: 35;
  transition: opacity 0.25s ease;
}

.player-loader.hidden {
  opacity: 0;
  pointer-events: none;
}

.spinner-cinema {
  position: relative;
  width: 60px;
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.spinner-ring {
  position: absolute;
  inset: 0;
  border: 3px solid rgba(255, 255, 255, 0.1);
  border-top-color: #e50914;
  border-right-color: #ff7a00;
  border-radius: 50%;
  animation: spinRing 0.9s linear infinite;
}

@keyframes spinRing {
  to { transform: rotate(360deg); }
}

.play-center-pulse {
  font-size: 1.4rem;
  color: #fff;
  animation: centerPulsing 1.4s ease-in-out infinite alternate;
}

@keyframes centerPulsing {
  0% { transform: scale(0.85); opacity: 0.6; }
  100% { transform: scale(1.15); opacity: 1; }
}

.loader-text {
  font-size: 0.85rem;
  font-weight: 600;
  color: #cbd5e1;
  letter-spacing: 0.3px;
}

/* YouTube Style Seek Ripples */
.seek-ripple {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 25%;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
  opacity: 0;
  z-index: 20;
}

.seek-ripple.seek-left { left: 0; border-radius: 0 50% 50% 0; }
.seek-ripple.seek-right { right: 0; border-radius: 50% 0 0 50%; }

.seek-ripple.active {
  animation: rippleGlow 0.6s ease-out forwards;
}

@keyframes rippleGlow {
  0% { background: rgba(255, 255, 255, 0.18); opacity: 1; }
  100% { background: transparent; opacity: 0; }
}

.ripple-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.25rem;
  font-size: 1.5rem;
  font-weight: 800;
  color: #fff;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.8);
}

.ripple-content span {
  font-size: 0.9rem;
}

/* Shortcuts Modal Overlay */
.shortcuts-overlay {
  position: absolute;
  inset: 0;
  background: rgba(4, 6, 12, 0.92);
  backdrop-filter: blur(16px);
  z-index: 60;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

.shortcuts-card {
  background: rgba(14, 18, 28, 0.98);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 16px;
  width: 100%;
  max-width: 500px;
  padding: 1.4rem 1.6rem;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.9);
}

.shortcuts-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.2rem;
  padding-bottom: 0.6rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.shortcuts-header h4 {
  font-size: 1.05rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: #fff;
}

.close-shortcuts-btn {
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-size: 1.2rem;
  cursor: pointer;
  transition: color 0.15s ease;
}

.close-shortcuts-btn:hover {
  color: #fff;
}

.shortcuts-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.7rem 1.2rem;
}

.shortcut-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.8rem;
  color: var(--text-secondary);
}

.shortcut-item kbd {
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 4px;
  padding: 2px 6px;
  font-family: monospace;
  font-size: 0.75rem;
  color: #fff;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.4);
}

/* ==========================================================================
   Sleek Modern Cinema Spec & Status Dock
   ========================================================================== */
.cinema-spec-dock {
  background: linear-gradient(180deg, rgba(10, 14, 22, 0.96) 0%, rgba(7, 10, 15, 0.98) 100%);
  padding: 0.85rem 1.4rem;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 0 0 20px 20px;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.spec-chips {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem 1rem;
}

.spec-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.78rem;
  color: #94a3b8;
}

.spec-chip strong {
  color: #fff;
  font-weight: 600;
}

.spec-chip.stream-mode {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: rgba(16, 185, 129, 0.1);
  border: 1px solid rgba(16, 185, 129, 0.25);
  color: #34d399;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 0.7rem;
  font-weight: 700;
  margin-left: auto;
}

.spec-source-line {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.75rem;
  color: var(--text-muted);
  border-top: 1px dashed rgba(255, 255, 255, 0.08);
  padding-top: 0.45rem;
}

.source-label {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  color: var(--text-secondary);
  font-weight: 600;
  flex-shrink: 0;
}

.raw-file-span {
  font-family: monospace;
  background: rgba(255, 255, 255, 0.05);
  padding: 2px 6px;
  border-radius: 4px;
  color: #cbd5e1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ==========================================================================
   Ultra-Premium Glassmorphism Toast System
   ========================================================================== */
.toast-container {
  position: fixed;
  bottom: 1.8rem;
  right: 1.8rem;
  z-index: 100000;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.5rem;
  pointer-events: none;
  width: 280px;
}

.toast {
  pointer-events: auto;
  position: relative;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 7px 11px 9px;
  width: 280px;
  min-width: 280px;
  max-width: 280px;
  min-height: 46px;
  box-sizing: border-box;
  background: rgba(12, 17, 28, 0.58);
  backdrop-filter: blur(24px) saturate(190%);
  -webkit-backdrop-filter: blur(24px) saturate(190%);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 
    0 12px 30px -4px rgba(0, 0, 0, 0.5),
    inset 0 1px 0 rgba(255, 255, 255, 0.16),
    inset 0 -1px 0 rgba(255, 255, 255, 0.04);
  color: #fff;
  cursor: default;
  user-select: none;
  transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.2s ease, border-color 0.2s ease, background-color 0.2s ease;
  animation: toastEnter 0.32s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.toast:hover {
  transform: translateY(-2px);
  background: rgba(14, 20, 34, 0.72);
  border-color: rgba(255, 255, 255, 0.22);
}

/* Subtle glow accents per type */
.toast.info {
  border-color: rgba(6, 182, 212, 0.32);
  box-shadow: 
    0 10px 28px -4px rgba(0, 0, 0, 0.5),
    0 0 20px -4px rgba(6, 182, 212, 0.18),
    inset 0 1px 0 rgba(6, 182, 212, 0.3);
}

.toast.info:hover {
  box-shadow: 
    0 14px 34px -4px rgba(0, 0, 0, 0.6),
    0 0 24px -2px rgba(6, 182, 212, 0.28),
    inset 0 1px 0 rgba(6, 182, 212, 0.4);
}

.toast.success {
  border-color: rgba(16, 185, 129, 0.32);
  box-shadow: 
    0 10px 28px -4px rgba(0, 0, 0, 0.5),
    0 0 20px -4px rgba(16, 185, 129, 0.18),
    inset 0 1px 0 rgba(16, 185, 129, 0.3);
}

.toast.success:hover {
  box-shadow: 
    0 14px 34px -4px rgba(0, 0, 0, 0.6),
    0 0 24px -2px rgba(16, 185, 129, 0.28),
    inset 0 1px 0 rgba(16, 185, 129, 0.4);
}

.toast.error {
  border-color: rgba(229, 9, 20, 0.34);
  box-shadow: 
    0 10px 28px -4px rgba(0, 0, 0, 0.5),
    0 0 20px -4px rgba(229, 9, 20, 0.2),
    inset 0 1px 0 rgba(229, 9, 20, 0.3);
}

.toast.error:hover {
  box-shadow: 
    0 14px 34px -4px rgba(0, 0, 0, 0.6),
    0 0 24px -2px rgba(229, 9, 20, 0.3),
    inset 0 1px 0 rgba(229, 9, 20, 0.4);
}

/* Compact Indicator Icon */
.toast-indicator {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-size: 0.95rem;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.14);
  color: #fff;
}

.toast.info .toast-indicator {
  background: rgba(6, 182, 212, 0.14);
  border-color: rgba(6, 182, 212, 0.35);
  color: #06b6d4;
}

.toast.success .toast-indicator {
  background: rgba(16, 185, 129, 0.14);
  border-color: rgba(16, 185, 129, 0.35);
  color: #10b981;
}

.toast.error .toast-indicator {
  background: rgba(229, 9, 20, 0.14);
  border-color: rgba(229, 9, 20, 0.35);
  color: #ff4d4f;
}

.toast-indicator .ph-arrows-clockwise.spin {
  animation: toastSpin 1.2s linear infinite;
}

@keyframes toastSpin {
  100% { transform: rotate(360deg); }
}

/* Content Area */
.toast-body {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-width: 0;
  gap: 1px;
}

.toast-title {
  font-family: var(--font-heading);
  font-size: 0.65rem;
  font-weight: 750;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  line-height: 1.1;
  color: rgba(255, 255, 255, 0.9);
}

.toast.info .toast-title { color: #38bdf8; }
.toast.success .toast-title { color: #34d399; }
.toast.error .toast-title { color: #ff6b6b; }

.toast-desc {
  font-family: var(--font-body);
  font-size: 0.76rem;
  font-weight: 500;
  color: #f1f5f9;
  line-height: 1.25;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Dismiss Close Button */
.toast-close-btn {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: transparent;
  border: none;
  color: rgba(255, 255, 255, 0.38);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.78rem;
  cursor: pointer;
  flex-shrink: 0;
  transition: all 0.15s ease;
  padding: 0;
}

.toast-close-btn:hover {
  background: rgba(255, 255, 255, 0.14);
  color: #ffffff;
  transform: scale(1.1);
}

/* Progress Countdown Bar */
.toast-progress-bar {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: rgba(255, 255, 255, 0.06);
  overflow: hidden;
}

.toast-progress-fill {
  height: 100%;
  width: 100%;
  transform-origin: left;
  animation: toastDrain linear forwards;
}

.toast:hover .toast-progress-fill {
  animation-play-state: paused;
}

.toast.info .toast-progress-fill {
  background: linear-gradient(90deg, #00e5ff, #38bdf8);
}

.toast.success .toast-progress-fill {
  background: linear-gradient(90deg, #10b981, #34d399);
}

.toast.error .toast-progress-fill {
  background: linear-gradient(90deg, #e50914, #ff5252);
}

@keyframes toastDrain {
  from { transform: scaleX(1); }
  to { transform: scaleX(0); }
}

/* Silky smooth enter and exit animations */
@keyframes toastEnter {
  0% {
    opacity: 0;
    transform: translateY(18px) scale(0.95);
    filter: blur(8px);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
    filter: blur(0px);
  }
}

.toast.dismissing {
  animation: toastExit 0.28s cubic-bezier(0.16, 1, 0.3, 1) forwards !important;
}

@keyframes toastExit {
  0% {
    opacity: 1;
    transform: translateY(0) scale(1);
    max-height: 60px;
    margin-bottom: 0;
  }
  100% {
    opacity: 0;
    transform: translateY(12px) scale(0.92);
    max-height: 0;
    padding-top: 0;
    padding-bottom: 0;
    margin-bottom: -0.5rem;
    filter: blur(4px);
  }
}

@media (max-width: 640px) {
  .toast-container {
    bottom: 4.8rem;
    right: 50%;
    transform: translateX(50%);
    width: 280px;
    align-items: center;
  }
}

/* ==========================================================================
   Footer
   ========================================================================== */
.site-footer {
  background: #040609;
  border-top: 1px solid var(--border-subtle);
  padding: 4rem 2rem 2rem;
  margin-top: 5rem;
}

.footer-container {
  max-width: 1600px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 2fr 2fr 1.5fr;
  gap: 3rem;
  padding-bottom: 3rem;
  border-bottom: 1px solid var(--border-subtle);
}

.footer-brand h3 {
  font-family: var(--font-heading);
  font-size: 1.4rem;
  margin: 0.75rem 0 0.5rem;
}
.footer-brand h3 span { color: var(--accent-red); }
.footer-brand p {
  color: var(--text-muted);
  font-size: 0.88rem;
  max-width: 380px;
}

.footer-links h4, .footer-stats h4 {
  font-family: var(--font-heading);
  font-size: 1rem;
  color: #fff;
  margin-bottom: 1rem;
}

.footer-links ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.footer-links a {
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 0.85rem;
  transition: color var(--duration-fast) ease;
}

.footer-links a:hover {
  color: var(--accent-red);
}

.footer-stats {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.stat-pill {
  background: rgba(255, 255, 255, 0.04);
  padding: 0.5rem 0.85rem;
  border-radius: var(--radius-sm);
  font-size: 0.82rem;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.stat-pill i {
  color: var(--accent-red);
}

.footer-bottom {
  max-width: 1600px;
  margin: 2rem auto 0;
  text-align: center;
  color: var(--text-muted);
  font-size: 0.82rem;
}

/* ==========================================================================
   Rail Navigation Buttons & Wrapper
   ========================================================================== */
.rail-wrapper {
  position: relative;
  width: 100%;
}

.rail-scroll-btn {
  position: absolute;
  top: 45%;
  transform: translateY(-50%);
  width: 44px;
  height: 80px;
  background: rgba(14, 18, 26, 0.92);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid rgba(255, 255, 255, 0.16);
  color: #fff;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 25;
  opacity: 0;
  pointer-events: none;
  transition: all 0.25s var(--ease-smooth);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.8);
  font-size: 1.4rem;
}

.rail-wrapper:hover .rail-scroll-btn {
  opacity: 1;
  pointer-events: auto;
}

.rail-scroll-btn.left { left: 4px; }
.rail-scroll-btn.right { right: 4px; }

.rail-scroll-btn:hover {
  background: var(--accent-red);
  border-color: var(--accent-red);
  transform: translateY(-50%) scale(1.06);
  box-shadow: 0 0 25px rgba(229, 9, 20, 0.6);
}


/* ==========================================================================
   Dedicated Game Card Component
   ========================================================================== */
.game-card {
  flex: 0 0 270px;
  background: linear-gradient(160deg, rgba(28, 20, 52, 0.8) 0%, rgba(13, 17, 27, 0.95) 100%);
  border: 1px solid rgba(139, 92, 246, 0.3);
  border-radius: var(--radius-md);
  overflow: hidden;
  cursor: pointer;
  transition: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.6);
  position: relative;
  display: flex;
  flex-direction: column;
}

.game-card:hover {
  transform: translateY(-8px) scale(1.02);
  border-color: #a855f7;
  box-shadow: 0 16px 36px rgba(139, 92, 246, 0.38), 0 0 25px rgba(6, 182, 212, 0.3);
}

.game-card .card-poster-wrap {
  position: relative;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: #090c14;
}

.game-card .card-poster-wrap::after {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 1;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.08);
  background: linear-gradient(180deg, rgba(9, 12, 20, 0) 50%, rgba(9, 12, 20, 0.5) 85%, rgba(9, 12, 20, 0.85) 100%);
  border-radius: inherit;
}

.game-card .card-poster {
  width: 100%;
  height: 100%;
  object-fit: cover;
  image-rendering: auto;
  transform: translateZ(0);
  backface-visibility: hidden;
  transition: transform 0.4s ease;
}

.game-card:hover .card-poster {
  transform: scale(1.08);
}

.game-platform-badge {
  padding: 0.25rem 0.6rem;
  border-radius: 6px;
  font-size: 0.68rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
}

.game-platform-badge.pc {
  background: linear-gradient(135deg, #0284c7, #2563eb);
  color: #fff;
}

.game-platform-badge.android {
  background: linear-gradient(135deg, #10b981, #059669);
  color: #fff;
}

.game-platform-badge.console {
  background: linear-gradient(135deg, #8b5cf6, #6d28d9);
  color: #fff;
}

.game-platform-badge.software {
  background: linear-gradient(135deg, #d97706, #b45309);
  color: #fff;
}

.game-repack-badge {
  padding: 0.25rem 0.5rem;
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(8px);
  border-radius: 6px;
  font-size: 0.68rem;
  font-weight: 600;
  color: #e2e8f0;
}

.game-card-info {
  padding: 0.85rem 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  flex: 1;
}

.game-card-title {
  font-family: var(--font-heading);
  font-size: 0.95rem;
  font-weight: 700;
  color: #fff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.game-card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.78rem;
  color: var(--text-secondary);
}

.game-download-cta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  margin-top: 0.4rem;
  padding: 0.45rem;
  background: rgba(139, 92, 246, 0.2);
  border: 1px solid rgba(139, 92, 246, 0.4);
  border-radius: 6px;
  color: #c4b5fd;
  font-size: 0.78rem;
  font-weight: 700;
  transition: all 0.2s ease;
}

.game-card:hover .game-download-cta {
  background: #8b5cf6;
  color: #fff;
  box-shadow: 0 0 15px rgba(139, 92, 246, 0.5);
}

/* ==========================================================================
   Series Seasons & Episodes Explorer in Modal
   ========================================================================== */
.series-section {
  padding: 1.25rem 1.5rem;
  border-top: 1px solid var(--border-subtle);
  background: rgba(10, 14, 22, 0.65);
}

.series-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.75rem;
}

.series-header h4 {
  font-size: 1rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: #fff;
}

.series-season-status {
  font-size: 0.8rem;
  color: var(--text-muted);
}

.series-season-bar {
  display: flex;
  gap: 0.5rem;
  overflow-x: auto;
  padding-bottom: 0.6rem;
  scrollbar-width: none;
}

.season-tab-btn {
  padding: 0.4rem 1rem;
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: var(--text-secondary);
  font-weight: 600;
  font-size: 0.82rem;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.season-tab-btn:hover {
  background: rgba(255, 255, 255, 0.15);
  color: #fff;
}

.season-tab-btn.active {
  background: var(--accent-red);
  border-color: var(--accent-red);
  color: #fff;
  box-shadow: 0 0 15px rgba(229, 9, 20, 0.4);
}

.episodes-grid {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  max-height: 340px;
  overflow-y: auto;
  overflow-x: hidden;
  margin-top: 0.75rem;
  padding: 4px 6px 8px 2px;
  scrollbar-width: thin;
  scrollbar-color: rgba(229, 9, 20, 0.45) rgba(255, 255, 255, 0.04);
}

.episodes-grid::-webkit-scrollbar {
  width: 6px;
}

.episodes-grid::-webkit-scrollbar-track {
  background: rgba(255, 255, 255, 0.04);
  border-radius: 4px;
}

.episodes-grid::-webkit-scrollbar-thumb {
  background: rgba(229, 9, 20, 0.45);
  border-radius: 4px;
}

.episodes-grid::-webkit-scrollbar-thumb:hover {
  background: var(--accent-red);
}

.episode-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.75rem 1.1rem;
  min-height: 62px;
  flex-shrink: 0 !important;
  box-sizing: border-box;
  background: rgba(18, 24, 38, 0.65);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.22s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
  overflow: hidden;
}

.episode-row:hover {
  background: rgba(28, 38, 58, 0.8);
  border-color: rgba(255, 255, 255, 0.22);
  transform: translateX(4px);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.35);
}

.episode-row.now-playing,
.episode-row.active {
  background: linear-gradient(90deg, rgba(229, 9, 20, 0.22) 0%, rgba(20, 26, 40, 0.92) 100%);
  border-color: rgba(229, 9, 20, 0.65);
  box-shadow: 0 0 24px rgba(229, 9, 20, 0.28), inset 0 0 20px rgba(229, 9, 20, 0.1);
}

.ep-left-wrap {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  overflow: hidden;
  flex: 1;
  min-width: 0;
}

/* Episode Num or Equalizer Icon */
.ep-num-badge {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 0.82rem;
  color: #94a3b8;
  flex-shrink: 0;
  position: relative;
  transition: all 0.2s ease;
}

.ep-hover-play {
  display: none;
  font-size: 1rem;
  color: #fff;
}

.episode-row:not(.now-playing):hover .ep-num-text {
  display: none;
}
.episode-row:not(.now-playing):hover .ep-hover-play {
  display: block;
}

.episode-row:hover .ep-num-badge {
  background: rgba(229, 9, 20, 0.25);
  border-color: rgba(229, 9, 20, 0.5);
  color: #fff;
}

.episode-row.now-playing .ep-num-badge,
.episode-row.active .ep-num-badge {
  background: linear-gradient(135deg, #e50914, #ff5252);
  border-color: transparent;
  color: #fff;
  box-shadow: 0 0 16px rgba(229, 9, 20, 0.6);
}

/* 3-Bar Animated Audio Equalizer */
.playing-equalizer {
  display: inline-flex;
  align-items: flex-end;
  gap: 2.5px;
  height: 14px;
}

.playing-equalizer .eq-bar {
  width: 3px;
  background: #ffffff;
  border-radius: 2px;
  animation: eqBounce 1s ease-in-out infinite alternate;
}

.playing-equalizer .eq-bar:nth-child(1) { height: 40%; animation-delay: 0.1s; }
.playing-equalizer .eq-bar:nth-child(2) { height: 100%; animation-delay: 0.35s; }
.playing-equalizer .eq-bar:nth-child(3) { height: 60%; animation-delay: 0.2s; }

@keyframes eqBounce {
  0% { height: 25%; }
  50% { height: 95%; }
  100% { height: 45%; }
}

/* Title & Tags */
.ep-info-col {
  display: flex;
  flex-direction: column;
  gap: 3px;
  overflow: hidden;
  flex: 1;
  min-width: 0;
}

.ep-title-line {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  flex-wrap: wrap;
  line-height: 1.3;
}

.ep-title-text {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.92rem;
  color: #ffffff;
  letter-spacing: -0.2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ep-now-playing-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 0.65rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  padding: 2px 8px;
  border-radius: 999px;
  background: rgba(229, 9, 20, 0.25);
  border: 1px solid rgba(229, 9, 20, 0.6);
  color: #ff8a80;
  box-shadow: 0 0 10px rgba(229, 9, 20, 0.4);
}

.ep-meta-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
  font-size: 0.72rem;
}

.ep-chip {
  padding: 1px 6px;
  border-radius: 4px;
  font-weight: 600;
  font-size: 0.68rem;
  display: inline-flex;
  align-items: center;
  gap: 3px;
}

.ep-chip.quality {
  background: rgba(229, 9, 20, 0.15);
  border: 1px solid rgba(229, 9, 20, 0.35);
  color: #ff8a80;
}

.ep-chip.audio {
  background: rgba(245, 158, 11, 0.15);
  border: 1px solid rgba(245, 158, 11, 0.35);
  color: #fbbf24;
}

.ep-chip.size {
  color: var(--text-muted);
  font-family: monospace;
}

.ep-chip.date {
  color: var(--text-muted);
}

.ep-right-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-shrink: 0;
}

.ep-dl-btn {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.14);
  color: #cbd5e1;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  transition: all 0.2s ease;
}

.ep-dl-btn:hover {
  background: var(--accent-red);
  border-color: var(--accent-red);
  color: #fff;
  transform: scale(1.08);
  box-shadow: 0 0 12px rgba(229, 9, 20, 0.5);
}

/* ==========================================================================
   Dedicated Game Modal
   ========================================================================== */
.game-modal-dialog {
  max-width: 820px;
  background: linear-gradient(170deg, #110f24 0%, #090c14 100%);
  border: 1px solid rgba(139, 92, 246, 0.35);
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.8), 0 0 40px rgba(139, 92, 246, 0.25);
}

.game-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.9rem 1.4rem;
  border-bottom: 1px solid rgba(139, 92, 246, 0.2);
  gap: 1rem;
}

.game-modal-header .modal-close-btn {
  margin-left: auto;
  flex-shrink: 0;
}

.game-banner {
  display: flex;
  gap: 1.5rem;
  padding: 1.5rem;
  background: rgba(139, 92, 246, 0.05);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.game-cover-img {
  width: 140px;
  height: 190px;
  border-radius: 10px;
  object-fit: cover;
  border: 1px solid rgba(255, 255, 255, 0.15);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.6);
  flex-shrink: 0;
}

.game-banner-info {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 0.6rem;
  overflow: hidden;
}

.game-banner-info h4 {
  font-size: 1.15rem;
  font-weight: 700;
  color: #fff;
  line-height: 1.3;
}

.game-meta-tags {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
  font-size: 0.82rem;
  color: var(--text-secondary);
}

.meta-tag {
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.game-action-row {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  margin-top: 0.5rem;
}

.btn-game {
  background: linear-gradient(135deg, #8b5cf6 0%, #6366f1 100%) !important;
  box-shadow: 0 0 20px rgba(139, 92, 246, 0.4) !important;
}

.btn-game:hover {
  box-shadow: 0 0 30px rgba(139, 92, 246, 0.6) !important;
}

.game-install-tips {
  margin: 1rem 1.5rem;
  padding: 0.9rem 1.2rem;
  background: rgba(139, 92, 246, 0.1);
  border: 1px solid rgba(139, 92, 246, 0.3);
  border-radius: 10px;
  font-size: 0.84rem;
  color: #e2e8f0;
}

.game-install-tips ul {
  margin: 0.4rem 0 0 1.2rem;
  line-height: 1.6;
  color: var(--text-secondary);
}

.game-files-box {
  padding: 0 1.5rem 1.5rem;
}

.game-files-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.6rem;
}

.game-files-header h5 {
  font-size: 0.9rem;
  color: #cbd5e1;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.game-file-list {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  max-height: 220px;
  overflow-y: auto;
}

.game-file-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.5rem 0.85rem;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 6px;
  font-size: 0.82rem;
}

.game-file-row a {
  color: #38bdf8;
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 0.3rem;
  font-weight: 600;
}

.game-file-row a:hover {
  text-decoration: underline;
}

/* Sub-filter Pills */
.grid-title-wrap {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  flex-wrap: wrap;
}

.sub-filter-pills {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.sub-pill {
  padding: 0.35rem 0.85rem;
  border-radius: var(--radius-full);
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: var(--text-secondary);
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

.sub-pill:hover {
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
}

.sub-pill.active {
  background: var(--accent-red);
  border-color: var(--accent-red);
  color: #fff;
  box-shadow: 0 0 12px rgba(229, 9, 20, 0.4);
}

.sub-pill.purple.active {
  background: #8b5cf6;
  border-color: #8b5cf6;
  box-shadow: 0 0 12px rgba(139, 92, 246, 0.5);
}

/* Navigation button styling with icons */
.main-nav .nav-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
}

.main-nav .nav-btn i {
  font-size: 1.05rem;
}

/* ==========================================================================
   Responsive Adaptations
   ========================================================================== */
@media (max-width: 1024px) {
  .footer-container { grid-template-columns: 1fr 1fr; }
  .main-nav { display: none; }
}

@media (max-width: 768px) {
  .header-container { padding: 0.75rem 1rem; }
  .search-box { width: 150px; }
  .search-box:focus-within {
  border-color: rgba(100, 160, 200, 0.35);
  background: rgba(15, 23, 38, 0.7);
  box-shadow: 0 0 0 3px rgba(100, 160, 200, 0.08);
}
  .filters-container { flex-direction: column; align-items: stretch; }
  .movies-grid { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 1rem; }
  .footer-container { grid-template-columns: 1fr; }
  .top10-rank-num { font-size: 4.5rem; left: -1rem; }
}

/* ==========================================================================
   Library Refresh Live Indicator
   ========================================================================== */
.library-refresh-chip {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.35rem 0.75rem;
  background: rgba(16, 185, 129, 0.08);
  border: 1px solid rgba(16, 185, 129, 0.25);
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 600;
  color: #34d399;
  user-select: none;
  transition: all 0.2s ease;
  cursor: default;
}

.library-refresh-chip:hover {
  background: rgba(16, 185, 129, 0.16);
  border-color: rgba(16, 185, 129, 0.45);
  box-shadow: 0 0 14px rgba(16, 185, 129, 0.25);
}

.sync-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #10b981;
  box-shadow: 0 0 8px #10b981;
  animation: syncPulse 2s infinite ease-in-out;
}

@keyframes syncPulse {
  0%, 100% {
    transform: scale(0.95);
    opacity: 0.7;
    box-shadow: 0 0 4px #10b981;
  }
  50% {
    transform: scale(1.25);
    opacity: 1;
    box-shadow: 0 0 12px #34d399;
  }
}

.library-refresh-chip.syncing {
  color: #38bdf8;
  background: rgba(56, 189, 248, 0.1);
  border-color: rgba(56, 189, 248, 0.3);
}

.library-refresh-chip.syncing .sync-dot {
  background: #38bdf8;
  box-shadow: 0 0 10px #38bdf8;
  animation: syncRotate 1s infinite linear;
}

@keyframes syncRotate {
  0% { transform: scale(1); opacity: 0.8; }
  50% { transform: scale(1.4); opacity: 1; }
  100% { transform: scale(1); opacity: 0.8; }
}

@media (max-width: 600px) {
  .library-refresh-chip { display: none; }
}

/* ==========================================================================
   React Bits-Inspired Modern Effects & Animation Engine
   ========================================================================== */

/* 1. Ambient Hero Canvas */
.hero-ambient-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 2;
  opacity: 0.85;
}

/* 2. Spotlight Card (Mouse-following radial border & glass glow) */
.spotlight-card {
  position: relative;
  overflow: hidden;
  --mouse-x: -300px;
  --mouse-y: -300px;
}

.spotlight-card::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: radial-gradient(
    480px circle at var(--mouse-x) var(--mouse-y),
    rgba(229, 9, 20, 0.12),
    rgba(6, 182, 212, 0.05) 45%,
    transparent 75%
  );
  opacity: 0;
  transition: opacity 0.35s ease;
  pointer-events: none;
  z-index: 2;
}

.spotlight-card.spotlight-hover::before,
.spotlight-card:hover::before {
  opacity: 1;
}

/* Dynamic border illumination */
.spotlight-card::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 1.5px;
  background: radial-gradient(
    360px circle at var(--mouse-x) var(--mouse-y),
    rgba(229, 9, 20, 0.65),
    rgba(6, 182, 212, 0.45) 40%,
    transparent 75%
  );
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
  z-index: 3;
}

.spotlight-card.spotlight-hover::after,
.spotlight-card:hover::after {
  opacity: 1;
}

/* 4. Shiny Button Shimmer */
.btn-shiny {
  position: relative;
  overflow: hidden;
}

.btn-shiny::after {
  content: '';
  position: absolute;
  top: -50%;
  left: -70%;
  width: 45%;
  height: 200%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.28),
    transparent
  );
  transform: rotate(25deg);
  animation: shimmerSweep 4.8s infinite ease-in-out;
  pointer-events: none;
  z-index: 3;
}

.btn-shiny:hover::after {
  animation: shimmerSweep 2s infinite ease-in-out;
}

@keyframes shimmerSweep {
  0% { left: -70%; }
  28%, 100% { left: 160%; }
}

/* 5. BlurText / SplitText Cinematic Transitions */
.blur-text-container {
  display: flex;
  flex-wrap: wrap;
  gap: 0.28em;
}

.blur-word {
  display: inline-flex;
  white-space: nowrap;
}

.blur-char {
  display: inline-block;
  opacity: 0;
  filter: blur(12px);
  transform: translateY(14px) scale(0.96);
  animation: blurInChar 0.65s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes blurInChar {
  0% {
    opacity: 0;
    filter: blur(12px);
    transform: translateY(14px) scale(0.96);
  }
  100% {
    opacity: 1;
    filter: blur(0px);
    transform: translateY(0) scale(1);
  }
}

/* 6. Border Trail / Animated Beam */
.border-beam-badge {
  position: relative;
  overflow: hidden;
}

.border-beam-badge::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(229, 9, 20, 0.9) 50%,
    rgba(6, 182, 212, 0.9) 75%,
    transparent 100%
  );
  background-size: 200% 100%;
  animation: beamRun 3.2s linear infinite;
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
}

@keyframes beamRun {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* 7. Magnetic Button Transition */
.btn-magnetic {
  display: inline-flex;
  will-change: transform;
}

/* 8. ScrollFloat / FadeContent Reveal */
.scroll-reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.75s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.75s cubic-bezier(0.16, 1, 0.3, 1);
  will-change: opacity, transform;
}

.scroll-reveal.revealed {
  opacity: 1;
  transform: translateY(0);
}

/* 9. Accessibility & Reduced Motion */
@media (prefers-reduced-motion: reduce) {
  .btn-shiny::after,
  .border-beam-badge::after {
    animation: none !important;
  }
  .blur-char {
    animation: none !important;
    opacity: 1 !important;
    filter: none !important;
    transform: none !important;
  }
  .scroll-reveal {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
  }
}

/* ==========================================================================
   Mobile Navigation Drawer & Bottom Bar
   ========================================================================== */
.mobile-nav-toggle {
  display: none;
}

.mobile-nav-drawer {
  display: none;
  background: rgba(10, 14, 22, 0.96);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  max-height: 0;
  opacity: 0;
  overflow: hidden;
  transition: max-height 0.4s cubic-bezier(0.16, 1, 0.3, 1),
              opacity 0.3s ease,
              padding 0.3s ease;
  padding: 0 1.5rem;
}

.mobile-nav-drawer.open {
  max-height: 380px;
  opacity: 1;
  padding: 1rem 1.5rem 1.5rem;
  box-shadow: 0 20px 30px rgba(0, 0, 0, 0.7);
}

.mobile-nav-content {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.mobile-nav-btn {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.06);
  color: var(--text-secondary);
  padding: 0.75rem 1.1rem;
  border-radius: var(--radius-md);
  font-size: 0.92rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  text-align: left;
}

.mobile-nav-btn i {
  font-size: 1.25rem;
  color: var(--accent-red);
}

.mobile-nav-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  transform: translateX(4px);
}

.mobile-nav-btn.active {
  background: rgba(229, 9, 20, 0.2);
  border-color: rgba(229, 9, 20, 0.4);
  color: #fff;
}

/* Mobile Floating Bottom Bar */
.mobile-bottom-bar {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: rgba(9, 12, 18, 0.92);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding: 0.5rem 0.75rem calc(0.5rem + env(safe-area-inset-bottom));
  align-items: center;
  justify-content: space-around;
  box-shadow: 0 -8px 25px rgba(0, 0, 0, 0.6);
}

.bottom-bar-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.25rem;
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-size: 0.68rem;
  font-weight: 600;
  cursor: pointer;
  padding: 0.25rem 0.65rem;
  border-radius: var(--radius-sm);
  transition: all 0.2s ease;
  min-width: 54px;
}

.bottom-bar-item i {
  font-size: 1.28rem;
  transition: transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.bottom-bar-item:hover,
.bottom-bar-item.active {
  color: #fff;
}

.bottom-bar-item.active i {
  color: var(--accent-red);
  transform: scale(1.15);
}

/* Poster Card Fallbacks & Micro-Styling */
.card-poster-wrap {
  background: radial-gradient(circle at center, rgba(229, 9, 20, 0.16) 0%, rgba(14, 18, 26, 0.96) 100%);
  position: relative;
}

.game-card .card-poster-wrap {
  background: radial-gradient(circle at center, rgba(139, 92, 246, 0.22) 0%, rgba(14, 18, 26, 0.96) 100%);
}

.card-poster-wrap::before {
  content: '';
  position: absolute;
  inset: 0;
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: inherit;
  pointer-events: none;
  z-index: 1;
}

/* Responsive Overrides */
@media (max-width: 880px) {
  .desktop-only,
  .pill-nav-items {
    display: none !important;
  }
  .mobile-nav-toggle {
    display: flex !important;
  }
  .mobile-nav-drawer {
    display: block;
  }
  .rescan-btn,
  .library-refresh-chip {
    display: none !important;
  }
  .search-box {
    width: 160px;
  }
}

@media (max-width: 768px) {
  body {
    padding-bottom: 68px;
  }
  .header-container {
    padding: 0.45rem 0.75rem;
    gap: 0.5rem;
  }
  .header-left {
    gap: 0.4rem;
  }
  .brand-logo {
    gap: 0.35rem;
  }
  .logo-badge {
    width: 30px;
    height: 30px;
    font-size: 1rem;
  }
  .brand-name {
    font-size: 1.15rem;
  }
  .header-right {
    gap: 0.4rem;
  }
  .search-box {
    width: 130px;
    padding: 0.32rem 0.6rem;
  }
  .search-box:focus-within {
    width: 160px;
    border-color: rgba(100, 160, 200, 0.35);
    background: rgba(15, 23, 38, 0.7);
    box-shadow: 0 0 0 3px rgba(100, 160, 200, 0.08);
  }
  .search-kbd {
    display: none;
  }
  .rescan-btn,
  .library-refresh-chip,
  #watchlistBtn {
    display: none !important; /* Accessible via mobile bottom bar */
  }
  .mobile-bottom-bar {
    display: flex;
  }
}

@media (max-width: 480px) {
  .search-box {
    width: 100px;
  }
  .search-box:focus-within {
    width: 135px;
  }
  .action-icon-btn {
    width: 34px;
    height: 34px;
    font-size: 1.05rem;
  }
}

/* ==========================================================================
   React Bits Masterpiece: StarBorder & Radiant Glow Action Buttons
   ========================================================================== */
.pagination-container,
.load-more-container {
  display: flex;
  justify-content: center;
  align-items: center;
  margin: 3.5rem 0 2.5rem;
  width: 100%;
}

/* ==========================================================================
   Load More / Pagination Button — Ultra-Clean Frosted Glass Pill
   ========================================================================== */
.btn-load-more {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  padding: 8px 22px 8px 10px;
  border-radius: 999px;
  background: linear-gradient(180deg, rgba(28, 34, 52, 0.8) 0%, rgba(15, 20, 32, 0.9) 100%);
  backdrop-filter: blur(24px) saturate(180%);
  -webkit-backdrop-filter: blur(24px) saturate(180%);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #ffffff;
  font-family: var(--font-body);
  font-size: 0.88rem;
  font-weight: 650;
  letter-spacing: 0.2px;
  cursor: pointer;
  text-decoration: none;
  box-shadow: 
    0 10px 30px -4px rgba(0, 0, 0, 0.55),
    inset 0 1px 0 rgba(255, 255, 255, 0.18),
    inset 0 -1px 0 rgba(0, 0, 0, 0.25);
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  user-select: none;
  position: relative;
}

.btn-load-more .load-icon-circle {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: rgba(229, 9, 20, 0.15);
  border: 1px solid rgba(229, 9, 20, 0.35);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  flex-shrink: 0;
}

.btn-load-more .load-icon-circle i {
  font-size: 0.95rem;
  color: #ff3b47;
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.btn-load-more .load-text {
  color: #f8fafc;
  font-size: 0.88rem;
  font-weight: 650;
  letter-spacing: 0.2px;
}

.btn-load-more .load-badge-pill {
  font-size: 0.72rem;
  font-weight: 650;
  color: #cbd5e1;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.12);
  padding: 3px 10px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  line-height: 1.2;
  transition: all 0.25s ease;
}

.btn-load-more .load-badge-pill::before {
  content: '';
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #e50914;
  box-shadow: 0 0 6px rgba(229, 9, 20, 0.8);
  display: inline-block;
  flex-shrink: 0;
}

.btn-load-more:hover {
  background: linear-gradient(180deg, rgba(36, 44, 66, 0.88) 0%, rgba(20, 26, 44, 0.94) 100%);
  border-color: rgba(229, 9, 20, 0.45);
  transform: translateY(-2px);
  box-shadow: 
    0 14px 38px -4px rgba(0, 0, 0, 0.65),
    0 0 28px rgba(229, 9, 20, 0.22),
    inset 0 1px 0 rgba(255, 255, 255, 0.28);
}

.btn-load-more:hover .load-icon-circle {
  background: rgba(229, 9, 20, 0.28);
  border-color: rgba(229, 9, 20, 0.6);
  box-shadow: 0 0 12px rgba(229, 9, 20, 0.45);
}

.btn-load-more:hover .load-icon-circle i:not(.spin) {
  transform: translateY(2px);
  color: #ffffff;
}

.btn-load-more:hover .load-badge-pill {
  background: rgba(229, 9, 20, 0.12);
  border-color: rgba(229, 9, 20, 0.35);
  color: #fecaca;
}

.btn-load-more:active {
  transform: translateY(0) scale(0.98);
}

.btn-load-more.loading {
  pointer-events: none;
  opacity: 0.9;
}

.btn-load-more.loading .load-icon-circle {
  background: rgba(56, 189, 248, 0.15);
  border-color: rgba(56, 189, 248, 0.4);
}

.btn-load-more.loading .load-icon-circle i {
  color: #38bdf8;
  animation: spin 0.8s linear infinite;
}

/* ==========================================================================
   Generic .btn, .btn-primary, .btn-glass Elevated Modern Styling
   ========================================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.65rem;
  padding: 10px 24px;
  font-family: var(--font-body);
  font-size: 0.88rem;
  font-weight: 650;
  line-height: 1.25;
  border-radius: 999px;
  cursor: pointer;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  text-decoration: none;
  white-space: nowrap;
  box-sizing: border-box;
  letter-spacing: 0.25px;
  user-select: none;
}

.btn i {
  font-size: 1.05rem;
  line-height: 1;
}

.btn-primary {
  background: linear-gradient(135deg, #e50914 0%, #b80710 100%);
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.22);
  box-shadow: 
    0 6px 20px -2px rgba(229, 9, 20, 0.45),
    inset 0 1px 0 rgba(255, 255, 255, 0.35),
    inset 0 -1px 0 rgba(0, 0, 0, 0.25);
  position: relative;
  overflow: hidden;
}

.btn-primary::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.22), transparent);
  transition: transform 0.6s ease;
  pointer-events: none;
}

.btn-primary:hover {
  background: linear-gradient(135deg, #ff1a26 0%, #c90812 100%);
  transform: translateY(-2px);
  box-shadow: 
    0 10px 28px -2px rgba(229, 9, 20, 0.65),
    0 0 22px rgba(229, 9, 20, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.45);
  color: #ffffff;
}

.btn-primary:hover::before {
  transform: translateX(200%);
}

.btn-primary:active {
  transform: translateY(0) scale(0.98);
  box-shadow: 0 3px 12px rgba(229, 9, 20, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.btn-glass {
  background: rgba(255, 255, 255, 0.07);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border: 1px solid rgba(255, 255, 255, 0.14);
  color: #f1f5f9;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.16);
}

.btn-glass:hover {
  background: rgba(255, 255, 255, 0.14);
  border-color: rgba(255, 255, 255, 0.28);
  color: #ffffff;
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.25);
}

.btn-glass:active {
  transform: translateY(0) scale(0.98);
}

/* ==========================================================================
   Ultra-Clean Delivery Gigabit Sync & Telemetry Modal
   ========================================================================== */
.sync-modal-dialog {
  max-width: 840px;
  width: 95%;
  max-height: 86vh;
  display: flex;
  flex-direction: column;
  background: rgba(10, 14, 22, 0.92);
  backdrop-filter: blur(32px) saturate(180%);
  -webkit-backdrop-filter: blur(32px) saturate(180%);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 20px;
  box-shadow: 
    0 30px 80px -10px rgba(0, 0, 0, 0.88),
    inset 0 1px 0 rgba(255, 255, 255, 0.16),
    inset 0 -1px 0 rgba(255, 255, 255, 0.04);
  overflow: hidden;
  margin: auto;
  position: relative;
}

/* Modal Header */
.sync-modal-header {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.15rem 1.75rem;
  background: rgba(14, 19, 31, 0.7);
  border-bottom: 1px solid rgba(255, 255, 255, 0.07);
  flex-shrink: 0;
}

.sync-header-left {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.sync-header-top {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.sync-modal-header .modal-title {
  font-family: var(--font-heading);
  font-size: 1.15rem;
  font-weight: 750;
  color: #ffffff;
  margin: 0;
  letter-spacing: -0.2px;
}

.sync-status-pill {
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.4px;
  background: rgba(16, 185, 129, 0.1);
  border: 1px solid rgba(16, 185, 129, 0.25);
  color: #34d399;
  padding: 2.5px 8px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.sync-status-pill .pulse-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #10b981;
  box-shadow: 0 0 8px #10b981;
}

.sync-modal-header .modal-subtitle {
  font-size: 0.78rem;
  color: #94a3b8;
  margin: 0;
}

.sync-modal-header .modal-close-btn {
  width: 32px;
  height: 32px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: #94a3b8;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  cursor: pointer;
  transition: all 0.2s ease;
}

.sync-modal-header .modal-close-btn:hover {
  background: rgba(255, 255, 255, 0.12);
  color: #ffffff;
}

/* Modal Body */
.sync-modal-body {
  position: relative;
  z-index: 2;
  padding: 1.25rem 1.75rem;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  flex: 1;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.15) transparent;
}

.sync-modal-body::-webkit-scrollbar {
  width: 5px;
}

.sync-modal-body::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.15);
  border-radius: 999px;
}

/* Cluster Health Overview Bento */
.sync-bento-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.75rem;
}

@media (max-width: 768px) {
  .sync-bento-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

.sync-stat-card {
  background: rgba(255, 255, 255, 0.025);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 14px;
  padding: 0.9rem 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  transition: border-color 0.2s ease, background-color 0.2s ease;
}

.sync-stat-card:hover {
  background: rgba(255, 255, 255, 0.04);
  border-color: rgba(255, 255, 255, 0.12);
}

.sync-stat-card .stat-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.sync-stat-card .stat-label {
  font-size: 0.7rem;
  font-weight: 650;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: #94a3b8;
  display: flex;
  align-items: center;
  gap: 6px;
}

.sync-stat-card .stat-label i {
  font-size: 0.88rem;
  color: #64748b;
}

.sync-stat-card .stat-number {
  font-family: var(--font-heading);
  font-size: 1.45rem;
  font-weight: 750;
  color: #ffffff;
  line-height: 1.15;
  letter-spacing: -0.3px;
}

.sync-stat-card .stat-number small {
  font-size: 0.75rem;
  font-weight: 600;
  color: #94a3b8;
}

.sync-stat-card .stat-number.text-emerald {
  color: #34d399;
}

.sync-stat-card .stat-meta {
  font-size: 0.7rem;
  color: #64748b;
  margin-top: auto;
}

/* Scanning Progress Area */
.sync-progress-area {
  background: rgba(14, 20, 32, 0.75);
  border: 1px solid rgba(6, 182, 212, 0.25);
  border-radius: 12px;
  padding: 1rem 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.sync-progress-hud-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.hud-tag {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.5px;
  color: #38bdf8;
}

.hud-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #38bdf8;
  box-shadow: 0 0 8px #38bdf8;
}

.hud-speed {
  font-family: ui-monospace, monospace;
  font-size: 0.72rem;
  color: #34d399;
  font-weight: 600;
}

.sync-progress-bar-wrap {
  width: 100%;
  height: 5px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 999px;
  overflow: hidden;
}

.sync-progress-fill {
  height: 100%;
  width: 0%;
  border-radius: 999px;
  background: linear-gradient(90deg, #06b6d4, #3b82f6);
  transition: width 0.35s ease;
}

.sync-progress-text {
  font-size: 0.78rem;
  color: #94a3b8;
  display: flex;
  align-items: center;
  gap: 8px;
}

/* Nodes Section */
.sync-nodes-section {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.section-subheading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 0.1rem;
}

.subheading-title-group {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 0.82rem;
  font-weight: 700;
  color: #cbd5e1;
}

.subheading-title-group i {
  color: #64748b;
  font-size: 0.95rem;
}

.node-health-tag {
  font-size: 0.68rem;
  font-weight: 650;
  color: #34d399;
  background: rgba(16, 185, 129, 0.1);
  border: 1px solid rgba(16, 185, 129, 0.22);
  padding: 2.5px 8px;
  border-radius: 999px;
  display: flex;
  align-items: center;
  gap: 5px;
}

.node-matrix-grid {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}

/* Streamlined Server Blade Row */
.node-blade-row {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 11px;
  padding: 0.65rem 0.95rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.node-blade-row:hover {
  background: rgba(255, 255, 255, 0.045);
  border-color: rgba(255, 255, 255, 0.12);
  transform: translateX(2px);
}

.node-main-col {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  min-width: 0;
  flex: 1;
}

.node-indicator {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #10b981;
  box-shadow: 0 0 8px #10b981;
  flex-shrink: 0;
}

.node-name {
  font-weight: 750;
  font-size: 0.86rem;
  color: #ffffff;
  flex-shrink: 0;
}

.node-ip {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 0.72rem;
  color: #94a3b8;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  padding: 1.5px 6px;
  border-radius: 5px;
  flex-shrink: 0;
}

.node-role {
  font-size: 0.75rem;
  color: #64748b;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 0;
}

.node-meta-col {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-shrink: 0;
}

.node-count-badge {
  font-size: 0.7rem;
  font-weight: 600;
  color: #cbd5e1;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.07);
  padding: 2px 7px;
  border-radius: 6px;
  white-space: nowrap;
}

.node-latency-badge {
  font-size: 0.7rem;
  font-weight: 600;
  color: #34d399;
  background: rgba(16, 185, 129, 0.08);
  border: 1px solid rgba(16, 185, 129, 0.2);
  padding: 2px 7px;
  border-radius: 6px;
  white-space: nowrap;
}

.node-link-btn {
  width: 26px;
  height: 26px;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: #94a3b8;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8rem;
  text-decoration: none;
  transition: all 0.15s ease;
}

.node-link-btn:hover {
  background: rgba(255, 255, 255, 0.12);
  color: #ffffff;
  border-color: rgba(255, 255, 255, 0.2);
}

/* Modal Footer */
.sync-modal-footer {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.75rem;
  background: rgba(12, 17, 26, 0.7);
  border-top: 1px solid rgba(255, 255, 255, 0.07);
  flex-wrap: wrap;
  gap: 0.85rem;
  flex-shrink: 0;
}

.sync-footer-note {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 0.74rem;
  color: #64748b;
}

.sync-footer-note i {
  color: #10b981;
  font-size: 0.88rem;
}

.sync-footer-btns {
  display: flex;
  align-items: center;
  gap: 0.65rem;
}

.sync-footer-btns .btn {
  font-size: 0.82rem;
  padding: 6px 14px;
  border-radius: 9px;
}

.sync-action-btn {
  background: var(--accent-red);
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.15);
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 0 4px 14px rgba(229, 9, 20, 0.35);
}

.sync-action-btn:hover {
  background: var(--accent-red-hover);
  box-shadow: 0 6px 20px rgba(229, 9, 20, 0.5);
}

.sync-action-btn.scanning i {
  animation: spin 0.9s linear infinite;
}

@media (max-width: 640px) {
  .sync-modal-header {
    padding: 1rem 1.25rem;
  }
  .sync-modal-body {
    padding: 1rem 1.25rem;
  }
  .sync-modal-footer {
    padding: 0.85rem 1.25rem;
  }
  .node-blade-row {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
  }
  .node-main-col {
    width: 100%;
    flex-wrap: wrap;
  }
  .node-meta-col {
    width: 100%;
    justify-content: flex-end;
  }
}

/* ==========================================================================
   ReactBits Elevation: Game & Media Modals Glassmorphism
   ========================================================================== */
.game-modal-dialog {
  max-width: 820px;
  max-height: 90vh;
  overflow-y: auto;
  background: rgba(12, 16, 26, 0.96);
  backdrop-filter: blur(36px) saturate(190%);
  -webkit-backdrop-filter: blur(36px) saturate(190%);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 24px;
  box-shadow: 0 35px 90px rgba(0, 0, 0, 0.95), 0 0 60px rgba(139, 92, 246, 0.15);
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.2) transparent;
}

.game-modal-dialog::-webkit-scrollbar {
  width: 6px;
}

.game-modal-dialog::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.2);
  border-radius: 999px;
}

/* ==========================================================================
   ReactBits: PillNav Component
   ========================================================================== */
.pill-nav {
  --nav-h: 38px;
  --logo: 34px;
  --pill-pad-x: 9.5px;
  --pill-gap: 2px;
  width: max-content;
  display: flex;
  align-items: center;
  box-sizing: border-box;
}

.pill-logo {
  width: var(--nav-h);
  height: var(--nav-h);
  border-radius: 50%;
  background: linear-gradient(135deg, rgba(229, 9, 20, 0.25) 0%, rgba(255, 87, 34, 0.25) 100%);
  border: 1px solid rgba(229, 9, 20, 0.5);
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  cursor: pointer;
  box-shadow: 0 0 14px rgba(229, 9, 20, 0.35);
  margin-right: 0.6rem;
  flex-shrink: 0;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.pill-logo:hover {
  transform: scale(1.08);
  box-shadow: 0 0 22px rgba(229, 9, 20, 0.7);
}

.pill-logo-inner {
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 1.15rem;
  width: 100%;
  height: 100%;
}

.pill-brand-text {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  margin-right: 0.65rem;
}

.pill-nav-items {
  position: relative;
  display: flex;
  align-items: center;
  height: var(--nav-h);
  background: rgba(10, 14, 23, 0.95);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 9999px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.1);
  padding: 2px;
}

.pill-list {
  list-style: none;
  display: flex;
  align-items: stretch;
  gap: var(--pill-gap);
  margin: 0;
  padding: 0;
  height: 100%;
}

.pill-list > li {
  display: flex;
  height: 100%;
}

.pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  padding: 0 var(--pill-pad-x);
  background: rgba(18, 25, 40, 0.75);
  color: #94a3b8;
  text-decoration: none;
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 9999px;
  box-sizing: border-box;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.81rem;
  letter-spacing: 0.1px;
  white-space: nowrap;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  transition: background 0.25s ease, color 0.2s ease, border-color 0.2s ease, box-shadow 0.25s ease;
}

.pill .hover-circle {
  position: absolute;
  left: 50%;
  bottom: 0;
  border-radius: 50%;
  background: linear-gradient(135deg, #e50914 0%, #ff3b30 100%);
  z-index: 1;
  display: block;
  pointer-events: none;
  will-change: transform;
}

.pill .label-stack {
  position: relative;
  display: inline-block;
  line-height: 1;
  z-index: 2;
  overflow: hidden;
}

.pill .pill-label {
  position: relative;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  line-height: 1;
  white-space: nowrap;
  font-size: 0.85rem;
  font-weight: 600;
  will-change: transform, opacity;
  opacity: 1;
}

.pill .pill-label-hover {
  position: absolute;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  color: #ffffff;
  z-index: 3;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  line-height: 1;
  white-space: nowrap;
  font-size: 0.85rem;
  font-weight: 600;
  will-change: transform, opacity;
  opacity: 0;
}

.pill.is-active, .pill.active {
  color: #ffffff;
  background: rgba(229, 9, 20, 0.25);
  border-color: rgba(229, 9, 20, 0.55);
  box-shadow: 0 0 16px rgba(229, 9, 20, 0.45);
}

.pill.is-active::after, .pill.active::after {
  content: '';
  position: absolute;
  bottom: 2px;
  left: 50%;
  transform: translateX(-50%);
  width: 16px;
  height: 3px;
  background: #ff3b30;
  border-radius: 50px;
  box-shadow: 0 0 10px #ff3b30;
  z-index: 4;
}

/* ==========================================================================
   ReactBits: SpecularButton Component
   ========================================================================== */
.specular-button {
  --sb-radius: 14px;
  --sb-tint: #ffffff;
  --sb-tint-opacity: 0;
  --sb-blur: 0px;
  --sb-text-color: #f5f5f5;

  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  border: none;
  margin: 0;
  font-family: var(--font-body);
  font-weight: 600;
  letter-spacing: 0.01em;
  line-height: 1;
  color: var(--sb-text-color);
  background: color-mix(in srgb, var(--sb-tint) calc(var(--sb-tint-opacity) * 100%), transparent);
  border-radius: var(--sb-radius);
  backdrop-filter: blur(var(--sb-blur));
  -webkit-backdrop-filter: blur(var(--sb-blur));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.15),
    0 8px 24px rgba(0, 0, 0, 0.35);
  cursor: pointer;
  outline: none;
  transition: transform 0.15s ease, box-shadow 0.25s ease;
  overflow: visible !important;
}

.specular-button:active {
  transform: scale(0.97);
}

.specular-button:focus-visible {
  outline: 2px solid color-mix(in srgb, var(--sb-text-color) 60%, transparent);
  outline-offset: 3px;
}

.specular-button:disabled {
  opacity: 0.55;
  cursor: default;
}

.specular-button:disabled:active {
  transform: none;
}

.specular-button--sm {
  font-size: 0.82rem;
  padding: 8px 18px;
}

.specular-button--md {
  font-size: 0.92rem;
  padding: 12px 24px;
}

.specular-button--lg {
  font-size: 1.05rem;
  padding: 16px 32px;
}

/* Canvas rim light is cleanly contained inside button boundary with smooth falloff */
.specular-button__fx {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 1;
  overflow: hidden;
  border-radius: inherit;
}

.specular-button__fx canvas {
  display: block;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.specular-button__label {
  position: relative;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  pointer-events: none;
}

/* ElasticSlider replaced with Cinema Volume Controller */

/* ==========================================================================
   ReactBits: FaultyTerminal Full-Page Ambient Digital Background
   ========================================================================== */
.specular-button::before,
.specular-button::after {
  display: none !important;
}

.faulty-terminal-bg {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  pointer-events: none;
  z-index: 0;
  opacity: 0.55;
  mix-blend-mode: screen;
}

@media (max-width: 768px) {
  .content-wrapper {
    padding: 0 1rem 3rem;
  }

  .section-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.75rem;
  }

  .section-title-wrap {
    width: 100%;
    max-width: 100%;
  }

  .section-title {
    font-size: 1.25rem;
    word-break: break-word;
  }

  .section-view-all {
    align-self: flex-start;
  }

  .rail-section.anime-rail {
    padding: 1rem 0.75rem 0.5rem;
    margin: 1.25rem 0;
  }

  .rail-scroll-btn {
    display: none !important;
  }

  .rail-carousel {
    grid-auto-columns: 160px;
    gap: 0.85rem;
    padding: 0.5rem 0 1rem;
  }
}

@media (max-width: 480px) {
  .hero-content-wrapper {
    padding: 0 0.75rem;
  }

  .hero-main-title {
    font-size: clamp(2rem, 8.5vw, 3.2rem);
  }

  .poster-frame {
    width: min(200px, 65vw);
  }

  .up-next-section {
    padding: 0 0.75rem 2rem;
  }

  .content-wrapper {
    padding: 0 0.75rem 3rem;
  }

  .rail-carousel {
    grid-auto-columns: 145px;
    gap: 0.75rem;
  }
}

/* Watchlist counter badge */
.watchlist-badge {
  position: absolute;
  top: -4px;
  right: -4px;
  background: var(--accent-red, #ff202e);
  color: #ffffff;
  font-size: 0.65rem;
  font-weight: 800;
  min-width: 17px;
  height: 17px;
  padding: 0 4px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1.5px solid var(--bg-primary, #030712);
  line-height: 1;
  pointer-events: none;
  box-shadow: 0 0 8px rgba(255, 32, 46, 0.6);
  z-index: 5;
}

.bottom-bar-item .watchlist-badge {
  top: 4px;
  right: calc(50% - 18px);
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
  .hero-bg-image,
  .poster-frame {
    animation: none;
  }
  
  .title-line {
    animation: none;
  }
}

/* Notification Dot */
.notification-dot {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 6px;
  height: 6px;
  background: #ff202e;
  border-radius: 50%;
  border: 1px solid rgba(8, 11, 19, 0.9);
  box-shadow: 0 0 8px rgba(255, 32, 46, 0.6);
  animation: notificationPulse 2.5s ease-in-out infinite;
}

@keyframes notificationPulse {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.2); opacity: 0.8; }
}


/* ==========================================================================
   Catalog & Grid View Layout (Clearance below fixed header)
   ========================================================================== */
body.is-catalog-view .main-content {
  padding-top: calc(70px + 1.25rem) !important;
}

body.is-catalog-view .filters-container {
  margin: 0 auto 1.5rem !important;
}

body.is-catalog-view .grid-section {
  padding-top: 0.25rem !important;
}

@media (max-width: 1400px) {
  .search-box { width: 170px !important; }
  .search-box:focus-within { width: 220px !important; }
  .pill-nav { --pill-pad-x: 9px !important; }
  .library-refresh-chip .sync-label { display: none; }
  .library-refresh-chip { padding: 0.4rem !important; }
}

@media (max-width: 1240px) {
  .rescan-btn .btn-text { display: none; }
  .rescan-btn { padding: 0.4rem 0.6rem !important; }
  .pill-brand-text .brand-name { display: none; }
}

/* ==========================================================================
   HERO & HEADER RECONSTRUCTION
   Matches TARGET REFERENCE IMAGE:
   - Header: Brand logo mark, Delivery ULTRA cyan badge, 6 stacked nav cards (active red card + bottom glow dot), search pill, library-refresh ON teal pill, refresh red pill
   - Hero Background: Apocalyptic street, golden sunset, kaiju, helicopters, wet road reflections, left/bottom cinematic gradients
   - Hero Left: Eyebrow, "THE / END OF / OAK STREET" title, tagline, 6 metadata pills, description, 3 CTAs, 3 inline feature indicators
   - Hero Right: Featured poster with dual neon (red/cyan) border & play button, IMAX label, vertical 01-05 slider
   - Bottom: "UP NEXT" carousel with 6 landscape thumbnails, active red border, "MORE STORIES A BRIGHTER TOMORROW"
   ========================================================================== */

/* --- Hero Section V2 (Cinema Homepage Reference Reconstruction) --- */
.hero-section-v2 {
  position: relative;
  width: 100%;
  min-height: 720px;
  box-sizing: border-box;
  padding: 68px 2rem 1.6rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  overflow: hidden;
  background: #03070d;
  margin-bottom: 2.2rem;
}

.hero-bg-wrapper {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  overflow: hidden;
}

.hero-bg-image {
  position: absolute;
  inset: 0;
  background-image: url('../assets/backdrops/blade_runner_2049.jpg');
  background-size: cover;
  background-position: center 25%;
  background-repeat: no-repeat;
  filter: brightness(0.95) contrast(1.06);
  transition: opacity 0.4s ease;
}

.hero-bg-gradient-left {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  width: 54%;
  background: linear-gradient(90deg, rgba(3, 7, 13, 0.98) 0%, rgba(3, 7, 13, 0.93) 42%, rgba(3, 7, 13, 0.45) 75%, transparent 100%);
}

.hero-bg-gradient-top {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 90px;
  background: linear-gradient(180deg, rgba(3, 7, 13, 0.85) 0%, transparent 100%);
}

.hero-bg-gradient-bottom {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 140px;
  background: linear-gradient(0deg, #03070d 0%, rgba(3, 7, 13, 0.9) 45%, transparent 100%);
}

.hero-bg-vignette {
  display: none;
}

.hero-content-wrapper {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 1540px;
  margin: 0 auto;
  padding-top: 0.8rem;
  gap: 2rem;
}

/* Left Hero Column */
.hero-left {
  flex: 1;
  max-width: 680px;
  display: flex;
  flex-direction: column;
}

.hero-eyebrow {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.3em;
  color: #a0b2c6;
  text-transform: uppercase;
  margin-bottom: 0.4rem;
}

/* Cinematic Main Title Typography */
.hero-main-title {
  font-family: 'Bebas Neue', 'Oswald', 'Outfit', -apple-system, sans-serif;
  margin: 0;
  padding: 0;
  text-transform: uppercase;
  color: #ffffff;
  line-height: 0.92;
  display: flex;
  flex-direction: column;
  letter-spacing: 0.02em;
}

.title-line-the {
  font-size: 1.65rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: #ffffff;
  margin-bottom: 2px;
}

.title-line-end-of {
  display: flex;
  align-items: baseline;
  gap: 0.45rem;
  line-height: 0.9;
}

.title-line-end-of .word-end {
  font-size: 4.8rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  color: #ffffff;
}

.title-line-end-of .word-of {
  font-size: 2.1rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: #ffffff;
}

.title-line-oak-street {
  display: flex;
  align-items: baseline;
  gap: 0.55rem;
  font-size: 4.8rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  color: #ffffff;
  line-height: 0.92;
}

.title-line-oak-street .letter-o {
  position: relative;
  display: inline-block;
  background: linear-gradient(135deg, #ff202e 0%, #ff573d 35%, #ff953d 65%, #ffffff 95%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  filter: drop-shadow(-2px 0 8px rgba(255, 32, 46, 0.85)) drop-shadow(0 0 16px rgba(255, 87, 61, 0.6));
}

.hero-tagline {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.28em;
  color: #a0b2c6;
  text-transform: uppercase;
  margin: 0.5rem 0 0.75rem;
}

/* 6 Semantic Metadata Pills */
.hero-metadata-row {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  flex-wrap: wrap;
  margin-bottom: 0.75rem;
}

.meta-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  height: 24px;
  padding: 0 10px;
  border-radius: 999px;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.3px;
  background: rgba(10, 16, 26, 0.85);
  border: 1px solid rgba(255, 255, 255, 0.14);
  color: #ffffff;
}

.meta-pill.meta-amzn {
  border-color: rgba(255, 32, 46, 0.45);
}

.meta-dot-red {
  color: #ff202e;
  font-size: 0.62rem;
  line-height: 1;
}

.meta-pill.meta-imdb {
  border-color: rgba(255, 196, 0, 0.4);
  color: #ffc400;
}

.meta-pill.meta-imdb i {
  color: #ffc400;
}

.meta-pill.meta-quality {
  border-color: rgba(255, 32, 46, 0.45);
  color: #ffffff;
}

.meta-pill.meta-audio {
  border-color: rgba(255, 196, 0, 0.4);
  color: #ffc400;
}

.meta-pill.meta-audio i {
  color: #ffc400;
}

.meta-pill.meta-year {
  border-color: rgba(140, 160, 185, 0.3);
  color: #cbd5e1;
}

.meta-pill.meta-year i {
  color: #cbd5e1;
}

.meta-pill.meta-server {
  border-color: rgba(0, 216, 240, 0.45);
  color: #00d8f0;
}

.meta-pill.meta-server i {
  color: #00d8f0;
}

/* Description */
.hero-description {
  font-size: 0.88rem;
  line-height: 1.55;
  color: #cbd5e1;
  margin: 0 0 1.15rem;
  max-width: 540px;
}

/* CTA Buttons */
.hero-cta-row {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1.1rem;
}

.cta-btn {
  height: 42px;
  border-radius: 8px;
  font-size: 0.84rem;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  text-decoration: none;
}

.cta-btn.cta-primary {
  background: linear-gradient(90deg, #ff202e 0%, #ff573d 100%);
  color: #ffffff;
  border: none;
  padding: 0 1.45rem;
  box-shadow: 0 4px 16px rgba(255, 32, 46, 0.45);
}

.cta-btn.cta-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 22px rgba(255, 32, 46, 0.65);
}

.cta-btn.cta-secondary {
  background: rgba(14, 22, 34, 0.85);
  border: 1px solid rgba(120, 160, 190, 0.32);
  color: #ffffff;
  padding: 0 1.25rem;
}

.cta-btn.cta-secondary:hover {
  background: rgba(20, 32, 50, 0.9);
  border-color: rgba(120, 160, 190, 0.5);
  transform: translateY(-1px);
}

.cta-btn.cta-list {
  background: rgba(14, 22, 34, 0.85);
  border: 1px solid rgba(120, 160, 190, 0.32);
  color: #ffffff;
  padding: 0 1.15rem;
}

.cta-btn.cta-list:hover {
  background: rgba(20, 32, 50, 0.9);
  border-color: rgba(120, 160, 190, 0.5);
  transform: translateY(-1px);
}

.cta-list-circle {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  border: 1.5px solid #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
}

/* Inline Feature Indicators */
.hero-features-row {
  display: flex;
  align-items: center;
  gap: 1.3rem;
  margin-top: 0.3rem;
}

.feature-item {
  display: flex;
  align-items: center;
  gap: 0.55rem;
}

.feature-item > i {
  color: #ff202e;
  font-size: 1.15rem;
}

.feature-title {
  font-size: 0.74rem;
  font-weight: 700;
  color: #ffffff;
  line-height: 1.2;
}

.feature-sub {
  font-size: 0.64rem;
  color: #94a3b8;
  line-height: 1.2;
}

.feature-separator {
  width: 1px;
  height: 24px;
  background: rgba(255, 255, 255, 0.14);
}

/* Right Hero Column: Featured Poster & Slider */
.hero-right {
  display: flex;
  align-items: center;
  gap: 1.1rem;
  flex-shrink: 0;
}

.hero-poster-wrapper {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.45rem;
}

.poster-frame {
  position: relative;
  width: 205px;
  height: 295px;
  border-radius: 14px;
  overflow: hidden;
  border: 1.5px solid transparent;
  background: linear-gradient(#03070d, #03070d) padding-box,
              linear-gradient(135deg, #ff202e 0%, #ff202e 35%, #ff573d 50%, #00d8f0 75%, #00e5ff 100%) border-box;
  box-shadow: -3px -3px 20px rgba(255, 32, 46, 0.45),
               4px 4px 20px rgba(0, 216, 240, 0.4),
               0 12px 35px rgba(0, 0, 0, 0.85);
  cursor: pointer;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.poster-frame:hover {
  transform: scale(1.025);
  box-shadow: -4px -4px 26px rgba(255, 32, 46, 0.6),
               5px 5px 26px rgba(0, 216, 240, 0.55),
               0 14px 40px rgba(0, 0, 0, 0.95);
}

.poster-top-cast {
  position: absolute;
  top: 10px;
  left: 12px;
  right: 12px;
  display: flex;
  justify-content: space-between;
  font-size: 0.56rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  color: #e2e8f0;
  text-transform: uppercase;
  z-index: 2;
  pointer-events: none;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.85);
}

.poster-sub-caption {
  position: absolute;
  bottom: 12px;
  left: 0;
  right: 0;
  text-align: center;
  font-size: 0.48rem;
  font-weight: 700;
  letter-spacing: 0.22em;
  color: #a0aec0;
  text-transform: uppercase;
  z-index: 2;
  pointer-events: none;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.9);
}

.poster-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.poster-play-btn {
  position: absolute;
  bottom: 32px;
  left: 50%;
  transform: translateX(-50%);
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: rgba(220, 20, 35, 0.92);
  border: 2px solid rgba(255, 255, 255, 0.5);
  color: #ffffff;
  font-size: 1.1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 16px rgba(255, 32, 46, 0.75);
  cursor: pointer;
  z-index: 2;
  transition: all 0.2s ease;
}

.poster-play-btn:hover {
  transform: translateX(-50%) scale(1.1);
  background: #ff202e;
}

.poster-imax-label {
  font-size: 0.6rem;
  font-weight: 800;
  letter-spacing: 0.24em;
  color: #cbd5e1;
  text-transform: uppercase;
}

/* Vertical 01-10 Indicator */
.slide-indicator {
  display: flex;
  flex-direction: column;
  gap: 0.32rem;
  justify-content: center;
}

.slide-num {
  width: 24px;
  height: 23px;
  border-radius: 5px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(12, 18, 28, 0.75);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.55);
  font-size: 0.66rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
  padding: 0;
}

.slide-num:hover {
  color: #ffffff;
  border-color: rgba(255, 32, 46, 0.55);
  background: rgba(25, 35, 52, 0.9);
}

.slide-num.active {
  background: rgba(220, 20, 35, 0.35);
  border: 1.5px solid #ff202e;
  color: #ffffff;
  box-shadow: 0 0 12px rgba(255, 32, 46, 0.6);
}

/* --- Bottom UP NEXT Carousel --- */
.up-next-section {
  width: 100%;
  max-width: 1540px;
  margin: 1.25rem auto 0;
  position: relative;
  z-index: 3;
}

.up-next-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.55rem;
}

.up-next-title {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin: 0;
  font-size: 0.88rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  color: #ffffff;
}

.title-accent-bar {
  width: 26px;
  height: 2px;
  background: #ff202e;
  display: inline-block;
}

.up-next-header-right {
  display: flex;
  align-items: center;
  gap: 0.85rem;
}

.see-all-link {
  font-size: 0.76rem;
  font-weight: 700;
  color: #cbd5e1;
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 0.3rem;
  transition: color 0.2s ease;
}

.see-all-link:hover {
  color: #ff202e;
}

.carousel-nav-buttons {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.carousel-nav {
  width: 26px;
  height: 26px;
  border-radius: 6px;
  background: rgba(15, 22, 34, 0.8);
  border: 1px solid rgba(120, 160, 190, 0.3);
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
  cursor: pointer;
  transition: all 0.2s ease;
}

.carousel-nav:hover {
  background: rgba(25, 36, 55, 0.95);
  border-color: rgba(120, 160, 190, 0.55);
}

.up-next-carousel-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;
  width: 100%;
}

.up-next-carousel {
  flex: 1;
  overflow: hidden;
}

.carousel-track {
  display: flex;
  align-items: flex-start;
  gap: 0.85rem;
  overflow-x: auto;
  scrollbar-width: none;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
  padding: 4px 0 8px;
}

.carousel-track::-webkit-scrollbar {
  display: none;
}

.carousel-item {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  cursor: pointer;
  transition: transform 0.2s ease;
  width: 145px;
  flex-shrink: 0;
  position: relative;
}

.carousel-thumb {
  width: 100%;
  height: 72px;
  border-radius: 8px;
  overflow: hidden;
  background: #060a12;
  border: 1px solid rgba(120, 160, 190, 0.24);
  position: relative;
  transition: all 0.2s ease;
}

.carousel-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.carousel-rank-badge {
  position: absolute;
  top: 4px;
  left: 4px;
  background: linear-gradient(135deg, #e50914 0%, #b30710 100%);
  color: #ffffff;
  font-size: 0.58rem;
  font-weight: 800;
  padding: 2px 5px;
  border-radius: 4px;
  letter-spacing: 0.04em;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.85);
  z-index: 2;
  pointer-events: none;
}

.carousel-item.active .carousel-thumb {
  border: 2px solid #ff202e;
  box-shadow: 0 0 16px rgba(255, 32, 46, 0.6);
}

.carousel-item:hover .carousel-thumb {
  border-color: rgba(255, 32, 46, 0.65);
  transform: translateY(-2px);
}

.carousel-title {
  font-size: 0.72rem;
  font-weight: 600;
  color: #cbd5e1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.carousel-item.active .carousel-title {
  color: #ffffff;
  font-weight: 700;
}

/* Cinematic Ambient Glow Background Canvas */
.cinematic-ambient-bg {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  pointer-events: none;
  z-index: -1 !important;
  opacity: 0.6;
}

/* Far Right Tagline Column */
.up-next-tagline-col {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.25rem;
  flex-shrink: 0;
  margin-left: 0.35rem;
}

.tagline-text {
  display: flex;
  flex-direction: column;
  text-align: right;
  font-size: 0.54rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  line-height: 1.3;
  color: #6f7f95;
}

.tagline-red-dash {
  width: 18px;
  height: 2px;
  background: #ff202e;
  border-radius: 2px;
  margin-top: 1px;
}

/* --- Responsive Adjustments (1024x426 widescreen desktop match) --- */
@media (max-width: 1100px) {
  .site-header {
    height: 44px;
  }
  .header-container {
    padding: 0 0.75rem;
  }
  .brand-play-polygon {
    width: 20px;
    height: 20px;
    font-size: 0.6rem;
  }
  .brand-name {
    font-size: 1.02rem;
  }
  .cinema-header-nav {
    gap: 0.1rem;
    margin-left: 0.15rem;
  }
  .nav-card-item {
    min-width: 38px;
    height: 34px;
    padding: 2px 4px;
  }
  .nav-card-item i {
    font-size: 0.82rem;
  }
  .nav-card-item .nav-label {
    font-size: 0.56rem;
  }
  .header-search-pill {
    width: 172px;
    height: 26px;
    padding: 0 8px;
  }
  .header-search-pill:focus-within {
    width: 190px;
  }
  .header-search-pill input {
    font-size: 0.62rem;
  }
  .header-action-icon {
    width: 26px;
    height: 26px;
    font-size: 0.9rem;
  }
  .header-sync-status-pill {
    height: 24px;
    padding: 2px 6px;
    font-size: 0.58rem;
  }
  .header-sync-now-btn {
    height: 24px;
    padding: 2px 6px;
    font-size: 0.58rem;
  }
  .hero-section-v2 {
    min-height: 640px;
    height: auto;
    padding: 62px 1.5rem 1.4rem;
  }
  .hero-left {
    max-width: 560px;
  }
  .title-line-the { font-size: 1.35rem; letter-spacing: 0.06em; margin-bottom: 0px; }
  .title-line-end-of .word-end { font-size: 3.8rem; }
  .title-line-end-of .word-of { font-size: 1.7rem; }
  .title-line-oak-street { font-size: 3.8rem; }
  .hero-eyebrow { font-size: 0.65rem; }
  .hero-tagline { font-size: 0.65rem; margin: 0.35rem 0 0.55rem; }
  .meta-pill { height: 22px; padding: 0 8px; font-size: 0.62rem; gap: 0.3rem; }
  .hero-description { font-size: 0.78rem; max-width: 440px; margin-bottom: 0.85rem; line-height: 1.45; }
  .cta-btn { height: 38px; font-size: 0.78rem; padding: 0 1.2rem; }
  .feature-item > i { font-size: 1.05rem; }
  .feature-title { font-size: 0.66rem; }
  .feature-sub { font-size: 0.56rem; }
  .poster-frame { width: 175px; height: 250px; border-radius: 12px; }
  .poster-play-btn { width: 34px; height: 34px; bottom: 24px; font-size: 0.95rem; }
  .poster-imax-label { font-size: 0.56rem; }
  .poster-top-cast { font-size: 0.5rem; top: 8px; left: 10px; right: 10px; }
  .poster-sub-caption { font-size: 0.44rem; bottom: 9px; }
  .slide-num { width: 22px; height: 21px; font-size: 0.62rem; }
  .carousel-item { width: 125px; }
  .carousel-thumb { height: 58px; }
  .carousel-title { font-size: 0.65rem; }
}

.mobile-nav-toggle {
  display: none !important;
}

@media (max-width: 880px) {
  .cinema-header-nav {
    display: none;
  }
  .mobile-nav-toggle {
    display: flex !important;
  }
  .hero-right {
    display: none;
  }
  .up-next-tagline-col {
    display: none;
  }
}
