/* ============================================
   PHIMHAY — VIP CINEMA THEME
   Font: Outfit + Be Vietnam Pro
   ============================================ */

@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@400;500;600;700;800;900&family=Be+Vietnam+Pro:wght@300;400;500;600;700&display=swap');

:root {
  --bg-primary: #030306;
  --bg-secondary: #0a0a12;
  --bg-card: #101018;
  --bg-hover: #181824;
  --bg-glass: rgba(12, 12, 20, 0.72);
  --accent: #e11d48;
  --accent-hover: #fb2c5e;
  --accent-glow: rgba(225, 29, 72, 0.45);
  --accent-soft: rgba(225, 29, 72, 0.12);
  --gold: #e8c547;
  --gold-light: #f5e6a8;
  --gold-dark: #b8942e;
  --gold-glow: rgba(232, 197, 71, 0.35);
  --text-primary: #fafafa;
  --text-secondary: #b4b4c8;
  --text-muted: #6b6b82;
  --border: rgba(255, 255, 255, 0.07);
  --border-hover: rgba(232, 197, 71, 0.28);
  --border-gold: rgba(232, 197, 71, 0.2);
  --gradient-hero: linear-gradient(135deg, #030306 0%, #120818 45%, #060612 100%);
  --gradient-gold: linear-gradient(135deg, #f5e6a8 0%, #e8c547 50%, #b8942e 100%);
  --gradient-accent: linear-gradient(135deg, #fb2c5e 0%, #e11d48 50%, #be123c 100%);
  --gradient-vip: linear-gradient(135deg, #e11d48 0%, #c41e3a 40%, #b8942e 100%);
  --gradient-card: linear-gradient(145deg, rgba(255,255,255,0.04) 0%, transparent 50%);
  --font-heading: 'Outfit', sans-serif;
  --font-body: 'Be Vietnam Pro', sans-serif;
  --radius: 12px;
  --radius-lg: 20px;
  --radius-xl: 28px;
  --shadow: 0 8px 32px rgba(0, 0, 0, 0.55);
  --shadow-card: 0 16px 48px rgba(0, 0, 0, 0.65), 0 0 0 1px rgba(255,255,255,0.04);
  --shadow-glow: 0 0 40px var(--accent-glow), 0 0 80px rgba(232, 197, 71, 0.08);
  --transition: all 0.15s cubic-bezier(0.4, 0, 0.2, 1);
  --nav-height: 72px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  background: var(--bg-primary);
  color: var(--text-primary);
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.6;
  min-height: 100vh;
  overflow-x: hidden;
  position: relative;
  display: flex;
  flex-direction: column;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
}

.navbar-home {
  background: transparent !important;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
  box-shadow: none !important;
  border-bottom-color: transparent !important;
}

.navbar-home.scrolled {
  background: rgba(3, 3, 6, 0.92) !important;
  backdrop-filter: blur(12px) saturate(130%) !important;
  -webkit-backdrop-filter: blur(12px) saturate(130%) !important;
  box-shadow: 0 8px 40px rgba(0, 0, 0, 0.7), 0 1px 0 rgba(232, 197, 71, 0.08) !important;
  border-bottom-color: var(--border) !important;
}

.navbar-home::after {
  display: none !important;
  opacity: 0 !important;
  background: transparent !important;
}

body::before {
  content: '';
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background: none;
}

body > *:not(.navbar):not(#progress-bar):not(.scroll-top-btn):not(.toast-container):not(.m-bottom-nav):not(.m-header):not(.m-drawer):not(.m-drawer-backdrop) {
  position: relative;
  z-index: 1;
}

a {
  color: inherit;
  text-decoration: none;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
}

img {
  max-width: 100%;
  display: block;
  -webkit-user-drag: none;
  user-drag: none;
  -webkit-touch-callout: none;
}

/* ---- NO SELECT / COPY FOR FRONTEND ---- */
body *:not(input):not(textarea):not([contenteditable="true"]):not([contenteditable=""]):not(code):not(pre):not(.admin-card *):not(.admin-table *):not(.admin-form *):not(.admin-page *):not(.admin-sidebar *):not(.admin-header *) {
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
  -webkit-touch-callout: none;
}

/* ---- SCROLLBAR ---- */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}

::-webkit-scrollbar-track {
  background: var(--bg-secondary);
}

::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, var(--gold) 0%, var(--accent) 100%);
  border-radius: 3px;
}

/* ============================================
   HEADER / NAVBAR
   ============================================ */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 9999;
  background: transparent;
  border-bottom: 1px solid transparent;
  padding: 0 28px;
  height: var(--nav-height);
  display: flex;
  align-items: center;
  gap: 32px;
}

.navbar::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--border-gold), transparent);
  opacity: 0.6;
}

.navbar.scrolled {
  background: rgba(3, 3, 6, 0.96);
  box-shadow: 0 8px 40px rgba(0, 0, 0, 0.7), 0 1px 0 rgba(232, 197, 71, 0.08);
}

.nav-inner {
  display: flex;
  align-items: center;
  gap: 24px;
  width: 100%;
  max-width: 1600px;
  margin: 0 auto;
  padding: 0;
}

.nav-logo {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  transition: var(--transition);
  padding: 4px 6px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.nav-logo:hover {
  transform: scale(1.02);
}

.nav-logo-img {
  display: block;
  width: auto;
  height: 40px;
  max-width: 180px;
  object-fit: contain;
  image-rendering: -webkit-optimize-contrast;
  image-rendering: crisp-edges;
}

.nav-logo-badge {
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  padding: 3px 8px;
  border-radius: 4px;
  background: var(--gradient-vip);
  color: #fff;
  box-shadow: 0 2px 12px var(--gold-glow);
  line-height: 1;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 4px;
  list-style: none;
  flex: 1;
}

.nav-links a {
  padding: 9px 16px;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-secondary);
  transition: var(--transition);
  white-space: nowrap;
  position: relative;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--text-primary);
  background: rgba(255, 255, 255, 0.06);
}

.nav-links a.active {
  color: var(--gold-light);
}

.nav-links a.active::after {
  content: '';
  position: absolute;
  bottom: 4px;
  left: 50%;
  transform: translateX(-50%);
  width: 20px;
  height: 2px;
  background: var(--gradient-gold);
  border-radius: 2px;
}

.nav-links .dropdown {
  position: relative;
}

.nav-links .dropdown-menu {
  /* Ẩn bằng opacity+pointer-events thay vì display:none để có thể transition */
  display: block;
  opacity: 0;
  pointer-events: none;
  transform: translateX(-50%) translateY(-6px);
  transition: opacity 0.18s ease, transform 0.18s ease;

  position: absolute;
  /* top = 100% (sát mép dưới nav item), padding-top tạo vùng cầu nối trong suốt */
  top: 100%;
  padding-top: 10px;
  /* ← cầu nối — chuột đi qua đây vẫn tính là hover */
  left: 50%;
  min-width: 220px;
  z-index: 100;
}

/* Box thật nằm bên trong, để padding-top không có background */
.nav-links .dropdown-menu::before {
  content: '';
  display: block;
}

.dropdown-menu-inner {
  background: var(--bg-glass);
  backdrop-filter: blur(20px);
  border: 1px solid var(--border-gold);
  border-radius: var(--radius);
  padding: 8px;
  box-shadow: var(--shadow-card);
}

/* Mở bằng JS — thêm class .open */
.nav-links .dropdown.open .dropdown-menu {
  opacity: 1;
  pointer-events: auto;
  transform: translateX(-50%) translateY(0);
}

.dropdown-menu a {
  display: block;
  padding: 8px 14px !important;
  border-radius: 6px;
  font-size: 13px;
}

.dropdown-menu a:hover {
  background: var(--bg-hover) !important;
  color: var(--text-primary) !important;
}

.nav-search {
  display: flex;
  align-items: center;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 0 18px;
  gap: 10px;
  transition: var(--transition);
  width: 240px;
}

.nav-search:focus-within {
  border-color: var(--border-gold);
  box-shadow: 0 0 0 3px var(--gold-glow), 0 0 24px rgba(232, 197, 71, 0.1);
  width: 300px;
  background: rgba(255, 255, 255, 0.06);
}

.nav-search input {
  background: none;
  border: none;
  outline: none;
  color: var(--text-primary);
  font-size: 14px;
  font-family: var(--font-body);
  width: 100%;
  padding: 9px 0;
}

.nav-search input::placeholder {
  color: var(--text-muted);
}

.nav-search svg {
  color: var(--text-muted);
  flex-shrink: 0;
}

.nav-notification-btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  margin: 0 14px 0 10px;
  border-radius: 999px;
  color: var(--text-secondary);
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border);
  transition: var(--transition);
  flex-shrink: 0;
}

.nav-notification-btn:hover {
  color: var(--gold-light);
  background: rgba(232, 197, 71, 0.08);
  border-color: var(--border-gold);
  transform: translateY(-1px);
  box-shadow: 0 0 0 3px var(--gold-glow);
}

.nav-notification-btn svg {
  display: block;
}

.nav-notification-badge {
  position: absolute;
  top: -4px;
  right: -4px;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 999px;
  background: #ef4444;
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
  box-shadow: 0 4px 12px rgba(239, 68, 68, 0.35);
}

.nav-auth {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 20px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  border: none;
  transition: var(--transition);
  font-family: var(--font-body);
  white-space: nowrap;
}

.btn-primary {
  background: var(--gradient-accent);
  color: white;
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 4px 20px var(--accent-glow);
}

.btn-primary::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(105deg, transparent 40%, rgba(255,255,255,0.2) 50%, transparent 60%);
  transform: translateX(-100%);
  transition: transform 0.5s ease;
}

.btn-primary:hover::before {
  transform: translateX(100%);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 28px var(--accent-glow), 0 0 20px var(--gold-glow);
}

.btn-ghost {
  background: rgba(255, 255, 255, 0.03);
  color: var(--text-secondary);
  border: 1px solid var(--border);
  backdrop-filter: blur(8px);
}

.btn-ghost:hover {
  border-color: var(--border-gold);
  color: var(--gold-light);
  background: rgba(232, 197, 71, 0.06);
}

.btn-lg {
  padding: 14px 32px;
  font-size: 16px;
  border-radius: 10px;
}

.btn-sm {
  padding: 6px 14px;
  font-size: 13px;
}

/* ============================================
   HERO BANNER — full width crossfade
   ============================================ */
.hero {
  position: relative;
  z-index: 0;
  height: 100vh;
  max-height: 780px;
  min-height: 520px;
  margin-top: 0 !important;
  overflow: hidden;
  background: var(--bg-primary);
  contain: layout paint;
}

.hero-viewport {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  isolation: isolate;
}

.hero-viewport--empty {
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--gradient-hero);
}

.hero-fallback {
  text-align: center;
  padding: 24px;
}

.hero-track {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
}

.hero-slide {
  display: none;
  position: absolute;
  inset: 0;
  overflow: hidden;
  z-index: 0;
  pointer-events: none;
}

.hero-slide.is-active {
  display: block;
  z-index: 2;
  pointer-events: auto;
  animation: heroFadeIn 0.6s ease forwards;
}

@keyframes heroFadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.hero-slide-media {
  position: absolute;
  inset: 0;
  overflow: hidden;
}

.hero-bg {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
  transform: scale(1);
  filter: brightness(0.5) saturate(1.1);
  transition: transform 8s ease-out, filter 0.65s ease;
}

.hero-slide.is-active .hero-bg {
  filter: brightness(0.55) saturate(1.15);
  transform: scale(1.04);
}

.hero-slide:not(.is-active) .hero-bg {
  transform: none;
}

.hero-slide-shade,
.hero-bottom-fade {
  display: none !important;
}

/* Film grain — hiệu ứng nhám hạt chấm tròn Halftone kiểu ảnh mẫu */
.hero-viewport::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 3;
  pointer-events: none;
  background-repeat: repeat;
  background-size: 3px 3px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='3' height='3'%3E%3Ccircle cx='1' cy='1' r='0.65' fill='rgba(0,0,0,0.22)'/%3E%3Ccircle cx='2.5' cy='2.5' r='0.55' fill='rgba(255,255,255,0.08)'/%3E%3C/svg%3E");
}

.detail-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 1; /* Place behind movie details text/poster context, but in front of backdrop */
  pointer-events: none;
  background-repeat: repeat;
  background-size: 3px 3px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='3' height='3'%3E%3Ccircle cx='1' cy='1' r='0.65' fill='rgba(0,0,0,0.22)'/%3E%3Ccircle cx='2.5' cy='2.5' r='0.55' fill='rgba(255,255,255,0.08)'/%3E%3C/svg%3E");
}

@media (max-width: 768px) {
  .detail-hero::before,
  .hero-viewport::before {
    display: none !important;
    background: none !important;
  }
}


/* Vô hiệu hóa lớp phủ phụ để tối ưu hóa hiệu năng */
.hero-viewport::after,
.detail-hero::after {
  content: none !important;
  display: none !important;
}

.hero-ui {
  position: absolute;
  inset: 0;
  z-index: 5;
  pointer-events: none;
}

/* Chỉ carousel trang chủ — tránh ẩn .hero-info trên trang phim */
#hero-slider .hero-info {
  position: absolute;
  left: clamp(20px, 3vw, 48px);
  bottom: clamp(88px, 12vh, 128px);
  max-width: min(560px, 42vw);
  z-index: 6;
  opacity: 0;
  visibility: hidden;
  transform: translateY(14px);
  transition: opacity 0.45s ease, transform 0.45s ease, visibility 0.45s;
  pointer-events: none;
}

#hero-slider .hero-info.active {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
  pointer-events: auto;
}

.movie-hero .hero-info,
.detail-hero .hero-info {
  position: static;
  opacity: 1;
  visibility: visible;
  transform: none;
  max-width: none;
  pointer-events: auto;
}

#hero-slider .hero-info-title {
  font-family: var(--font-heading);
  font-size: clamp(26px, 3.2vw, 44px);
  font-weight: 800;
  line-height: 1.1;
  margin-bottom: 10px;
  letter-spacing: -0.02em;
  text-shadow: 0 4px 28px rgba(0, 0, 0, 0.85);
  color: var(--text-primary);
}

#hero-slider .hero-info-sub {
  font-size: clamp(14px, 1.5vw, 18px);
  font-weight: 600;
  color: var(--gold);
  margin-bottom: 18px;
  text-shadow: 0 2px 16px rgba(0, 0, 0, 0.7);
}

#hero-slider .hero-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 14px;
}

#hero-slider .hero-tag {
  padding: 5px 12px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--text-primary);
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.45);
  border-radius: 4px;
  backdrop-filter: blur(6px);
}

#hero-slider .hero-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 8px;
  margin-bottom: 14px;
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.5;
}

#hero-slider .hero-meta a {
  color: var(--text-primary);
  font-weight: 600;
  pointer-events: auto;
}

#hero-slider .hero-meta a:hover {
  color: var(--gold);
}

#hero-slider .hero-meta-sep {
  opacity: 0.45;
  user-select: none;
}

#hero-slider .hero-meta-ep {
  color: var(--accent-hover);
  font-weight: 600;
}

#hero-slider .hero-meta-views {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

#hero-slider .hero-info-desc {
  font-size: 14px;
  line-height: 1.65;
  color: var(--text-secondary);
  margin-bottom: 20px;
  max-width: 520px;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-shadow: 0 1px 12px rgba(0, 0, 0, 0.8);
}

#hero-slider .hero-actions {
  display: flex;
  align-items: center;
  gap: 14px;
  pointer-events: auto;
}

#hero-slider .hero-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: none;
  cursor: pointer;
  text-decoration: none;
  transition: var(--transition);
}

#hero-slider .hero-btn-play {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: var(--gradient-gold);
  color: #1a1208;
  box-shadow: 0 4px 24px var(--gold-glow);
}

#hero-slider .hero-btn-play:hover {
  transform: scale(1.06);
  box-shadow: 0 6px 32px var(--gold-glow);
}

#hero-slider .hero-btn-icon {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.45);
  border: 1px solid rgba(255, 255, 255, 0.22);
  color: var(--text-primary);
  backdrop-filter: blur(10px);
}

#hero-slider .hero-btn-icon:hover {
  border-color: var(--gold);
  color: var(--gold);
}

#hero-slider .hero-thumbs {
  position: absolute;
  right: clamp(20px, 4vw, 56px);
  bottom: clamp(28px, 5vh, 48px);
  display: flex;
  gap: 10px;
  pointer-events: auto;
}

#hero-slider .hero-thumb {
  width: 76px;
  height: 46px;
  padding: 0;
  border: 2px solid transparent;
  border-radius: 6px;
  background-color: var(--bg-card);
  background-size: cover;
  background-position: center;
  cursor: pointer;
  opacity: 0.5;
  transition: var(--transition);
}

#hero-slider .hero-thumb:hover {
  opacity: 0.85;
}

#hero-slider .hero-thumb.active {
  opacity: 1;
  border-color: #fff;
  box-shadow: 0 0 16px rgba(255, 255, 255, 0.25);
}

/* Legacy hero classes (detail pages) */
.hero-badges {
  display: flex;
  gap: 8px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}

.badge {
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

.badge-quality {
  background: var(--gradient-gold);
  color: #1a1208;
  box-shadow: 0 2px 12px var(--gold-glow);
}

.badge-type {
  background: var(--gradient-accent);
  color: white;
  box-shadow: 0 2px 12px var(--accent-glow);
}

.badge-lang {
  background: rgba(255, 255, 255, 0.1);
  color: white;
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.hero-title {
  font-family: var(--font-heading);
  font-size: clamp(28px, 4vw, 56px);
  font-weight: 800;
  line-height: 1.08;
  margin-bottom: 12px;
  letter-spacing: -0.02em;
  text-shadow: 0 4px 32px rgba(0, 0, 0, 0.8);
}

.hero-origin {
  font-size: 16px;
  color: var(--text-secondary);
  margin-bottom: 12px;
  font-weight: 400;
}

.hero-meta {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 16px;
  font-size: 14px;
  color: var(--text-secondary);
}

.hero-meta .dot {
  width: 4px;
  height: 4px;
  background: var(--text-muted);
  border-radius: 50%;
}

.hero-meta .rating {
  color: var(--gold);
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 4px;
}

.hero-desc {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: 28px;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* ============================================
   MAIN CONTENT
   ============================================ */
.container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 24px;
}

main {
  flex: 1 0 auto;
  padding-bottom: 60px;
}

.section {
  margin: 56px 0;
  padding-top: 8px;
}

.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 24px;
}

.section-title {
  font-family: var(--font-heading);
  font-size: 24px;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 14px;
  letter-spacing: -0.02em;
}

.section-title::before {
  content: '';
  display: block;
  width: 4px;
  height: 28px;
  background: var(--gradient-gold);
  border-radius: 3px;
  box-shadow: 0 0 16px var(--gold-glow);
}

.section-link {
  font-size: 13px;
  color: var(--gold);
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: var(--transition);
  padding: 8px 14px;
  border-radius: 999px;
  border: 1px solid transparent;
}

.section-link:hover {
  gap: 10px;
  color: var(--gold-light);
  border-color: var(--border-gold);
  background: rgba(232, 197, 71, 0.06);
}

/* ============================================
   MOVIE CARDS
   ============================================ */
.movies-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 16px;
}

.movies-grid.grid-6 {
  grid-template-columns: repeat(6, 1fr);
}

.movies-grid.grid-5 {
  grid-template-columns: repeat(5, 1fr);
}

.movies-grid.grid-4 {
  grid-template-columns: repeat(4, 1fr);
}

.movie-card {
  background: var(--bg-card);
  border-radius: var(--radius);
  overflow: hidden;
  cursor: pointer;
  transition: var(--transition);
  border: 1px solid var(--border);
  position: relative;
  group: true;
}

.movie-card::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(145deg, rgba(232,197,71,0.35), transparent 40%, rgba(225,29,72,0.2));
  -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.35s ease;
  z-index: 2;
  pointer-events: none;
}

.movie-card:hover {
  transform: translateY(-8px) scale(1.02);
  border-color: var(--border-gold);
  box-shadow: var(--shadow-card), 0 0 32px rgba(232, 197, 71, 0.12);
}

.movie-card:hover::before {
  opacity: 1;
}

.movie-thumb {
  position: relative;
  aspect-ratio: 2/3;
  overflow: hidden;
}

.movie-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.movie-card:hover .movie-thumb img {
  transform: scale(1.05);
}

.movie-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.85) 0%, transparent 60%);
  opacity: 0;
  transition: opacity 0.3s;
  display: flex;
  align-items: center;
  justify-content: center;
}

.movie-card:hover .movie-overlay {
  opacity: 1;
}

.play-btn {
  width: 56px;
  height: 56px;
  background: var(--gradient-vip);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 32px var(--accent-glow), 0 0 24px var(--gold-glow);
  transform: scale(0.75);
  transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
  border: 2px solid rgba(255, 255, 255, 0.25);
}

.movie-card:hover .play-btn {
  transform: scale(1);
}

.movie-quality {
  position: absolute;
  top: 8px;
  left: 8px;
  background: var(--gold);
  color: #000;
  font-size: 10px;
  font-weight: 800;
  padding: 2px 8px;
  border-radius: 4px;
  letter-spacing: 0.3px;
}

.movie-ep {
  position: absolute;
  top: 8px;
  right: 8px;
  background: rgba(229, 9, 20, 0.9);
  color: white;
  font-size: 10px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 4px;
}

.movie-info {
  padding: 12px;
}

.movie-title {
  font-size: 14px;
  font-weight: 700;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin-bottom: 6px;
  font-family: var(--font-heading);
}

.movie-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  color: var(--text-muted);
}

.movie-meta .year {
  color: var(--text-secondary);
}

.movie-meta .views {
  display: flex;
  align-items: center;
  gap: 3px;
}

/* ============================================
   HORIZONTAL SCROLL (Top phim)
   ============================================ */
.movies-scroll {
  display: flex;
  gap: 14px;
  overflow-x: auto;
  padding-bottom: 8px;
  scrollbar-width: none;
}

.movies-scroll::-webkit-scrollbar {
  display: none;
}

.movies-scroll .movie-card {
  flex-shrink: 0;
  width: 160px;
}

/* ============================================
   FILM RAIL (carousel ngang + hover)
   ============================================ */
.section--film-rail {
  overflow: visible;
  position: relative;
  z-index: 1;
}

.section--film-rail.has-film-expanded,
.section--film-rail:has(.film-card.is-expanded) {
  z-index: 200;
}

.section--film-rail .container {
  overflow: visible;
}

.section--film-rail .section-header {
  margin-left: -8px;
  margin-right: -8px;
  padding-left: 44px;
  padding-right: 44px;
}

.film-rail {
  position: relative;
  z-index: 1;
  margin: 0 -8px;
  padding: 0 44px;
  --film-card-w: calc((100% - 56px) / 5);
  --film-poster-h: calc(var(--film-card-w) * 9 / 16);
  --film-caption-h: 62px;
  --film-card-h: calc(var(--film-poster-h) + var(--film-caption-h));
  /* Cân giữa mũi tên theo chiều dọc ảnh poster thay vì cả card chữ */
  --film-nav-top: calc(48px + var(--film-poster-h) / 2);
}

.film-rail-viewport {
  /* Tính theo viewport — 5 card + 4 gap 14px */
  --film-card-w: calc((100% - 56px) / 5);
  container-type: inline-size;
  container-name: film-rail;
  overflow-x: auto;
  overflow-y: visible;
  scroll-behavior: smooth;
  scrollbar-width: none;
  cursor: grab;
  /* Padding đủ lớn sẵn để popup không bị cắt ở các cạnh */
  padding: 48px 50px 200px;
  margin: -48px -46px -200px;
}

@supports (width: 1cqw) {
  .film-rail-viewport {
    --film-card-w: calc((100cqw - 56px) / 5);
  }
}

/* Khi expand: chỉ ẩn scrollbar ngang, KHÔNG thay đổi padding/margin → tránh layout reflow */
.section--film-rail.has-film-expanded .film-rail-viewport,
.section--film-rail:has(.film-card.is-expanded) .film-rail-viewport {
  overflow-x: hidden;
}

.film-rail-viewport::-webkit-scrollbar {
  display: none;
}

.film-rail-viewport.is-dragging {
  cursor: grabbing;
  scroll-behavior: auto;
  user-select: none;
}

.film-rail-track {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  width: max-content;
  position: relative;
}

.film-rail-track:has(.film-card.is-expanded) .film-card:not(.is-expanded) {
  pointer-events: none;
}

.film-rail-nav {
  position: absolute;
  top: var(--film-nav-top);
  transform: translateY(-50%);
  z-index: 30;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: none;
  background: rgba(255, 255, 255, 0.95);
  color: #111;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.45);
  transition: transform 0.25s cubic-bezier(0.25, 0.8, 0.25, 1), opacity 0.25s, background-color 0.25s, box-shadow 0.25s;
  opacity: 0.85;
  pointer-events: auto;
}

.film-rail:hover .film-rail-nav {
  opacity: 0.85;
}

.film-rail-nav:hover:not(:disabled) {
  transform: translateY(-50%) scale(1.08);
  background: #ffffff;
  opacity: 1 !important;
  box-shadow: 0 6px 24px rgba(0, 0, 0, 0.55);
}

.film-rail-nav:disabled {
  opacity: 0 !important;
  pointer-events: none !important;
}

.film-rail-nav--prev {
  left: 0;
}

.film-rail-nav--next {
  right: 0;
}

.film-card {
  flex: 0 0 var(--film-card-w, 240px);
  width: var(--film-card-w, 240px);
  min-width: 0;
  max-width: var(--film-card-w, 240px);
  display: flex;
  flex-direction: column;
  position: relative;
  z-index: 1;
  overflow: visible;
}

.film-card:hover,
.film-card.is-expanded {
  z-index: 100;
}

.film-card-anchor {
  position: relative;
  width: 100%;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.film-card-rank {
  position: absolute;
  top: 6px;
  left: 6px;
  z-index: 5;
  min-width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-heading);
  font-weight: 900;
  font-size: 13px;
  background: var(--gradient-accent);
  color: #fff;
  border-radius: 6px 0 6px 0;
  box-shadow: 0 2px 10px var(--accent-glow);
}

.film-card-inner {
  position: relative;
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  background: transparent !important;
  border-radius: 0 !important;
  overflow: visible !important;
  border: none !important;
  box-shadow: none !important;
  transition: transform 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.film-card-media {
  display: block !important;
  position: relative !important;
  width: 100% !important;
  aspect-ratio: 16 / 9 !important;
  height: auto !important;
  overflow: hidden !important;
  background: var(--bg-secondary);
  border-radius: 8px !important;
  border: 1px solid rgba(255, 255, 255, 0.06);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.4);
  transition: transform 0.4s cubic-bezier(0.25, 0.8, 0.25, 1), box-shadow 0.4s, border-color 0.4s;
}

.film-card-media img {
  position: absolute !important;
  top: 0 !important;
  left: 0 !important;
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
  transition: transform 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
}

/* Micro-animations hover — tắt khi popup đang mở để tránh xung đột transform */
.film-card:not(.is-expanded):hover .film-card-media {
  transform: translateY(-3px);
  border-color: rgba(255, 255, 255, 0.15);
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.55), 0 0 8px rgba(255, 255, 255, 0.04);
}

.film-card:not(.is-expanded):hover .film-card-media img {
  transform: scale(1.03);
}

.film-card-media-badges {
  position: absolute;
  bottom: 8px;
  left: 8px;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  z-index: 3;
  pointer-events: none;
}

.film-badge {
  font-size: 10px;
  font-weight: 800;
  padding: 3px 8px;
  border-radius: 4px;
  line-height: 1.2;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
}

.film-badge-pd {
  background: rgba(18, 18, 24, 0.82) !important;
  color: #f1f5f9 !important;
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.film-badge-tm {
  background: #10b981 !important;
  color: #fff !important;
}

.film-card-caption {
  flex: 1;
  min-height: auto;
  padding: 8px 2px 2px 2px;
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  overflow: hidden;
}

.film-card-meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 8px;
}

.film-card-meta-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 4px 8px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: #d7d7e5;
  font-size: 10px;
  font-weight: 700;
  line-height: 1;
}

.film-card-title {
  font-family: var(--font-heading);
  font-size: 14px;
  font-weight: 700;
  line-height: 1.4;
  color: #ffffff;
  margin-bottom: 2px;
  transition: color 0.3s ease;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.film-card:hover .film-card-title {
  color: var(--gold);
}

.film-card-sub {
  font-family: var(--font-body);
  font-size: 12px;
  color: #8a8a9e;
  margin-top: 2px;
  line-height: 1.4;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.film-card-body {
  position: relative;
  flex: 1;
  display: flex;
  flex-direction: column;
}

/* Premium absolute Netflix-style hover popout — GPU-accelerated, mượt mà */
.film-card-expand {
  position: absolute;
  top: -8px;
  left: 50%;
  width: 320px;
  background: #161622;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  z-index: 500;
  transform: translateX(-50%) scale(0.96);
  transform-origin: top center;
  opacity: 0;
  pointer-events: none;
  visibility: hidden;
  will-change: transform, opacity;
  transition: opacity 0.25s ease-out, transform 0.25s ease-out, visibility 0s 0.25s;
  overflow: hidden;
}

.film-card.is-expanded .film-card-expand {
  opacity: 1;
  pointer-events: auto;
  visibility: visible;
  transform: translateX(-50%) scale(1);
  transition: opacity 0.25s ease-out, transform 0.25s ease-out, visibility 0s 0s;
}


.film-card-expand-media {
  display: block !important;
  position: relative !important;
  width: 100% !important;
  aspect-ratio: 16 / 9 !important;
  height: auto !important;
  overflow: hidden !important;
  background: #08080c;
}

.film-card-expand-media img {
  position: absolute !important;
  top: 0 !important;
  left: 0 !important;
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
  transition: transform 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.film-card.is-expanded .film-card-expand-media img {
  transform: scale(1.02);
}

.film-card-expand-body {
  padding: 16px;
  box-sizing: border-box;
}

.film-card-expand-title {
  font-family: var(--font-heading);
  font-size: 15px;
  font-weight: 700;
  line-height: 1.4;
  color: #ffffff;
  margin: 0 0 4px 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.film-card-expand-sub {
  font-family: var(--font-body);
  font-size: 11px;
  color: var(--gold);
  margin: 0 0 14px 0;
  line-height: 1.35;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.film-card-expand-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 14px;
}

.film-btn-play-yellow {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  background: var(--gradient-gold);
  color: #1a1208;
  border: none;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 800;
  padding: 8px 14px;
  cursor: pointer;
  transition: var(--transition);
  text-decoration: none;
  white-space: nowrap;
}

.film-btn-play-yellow:hover {
  filter: brightness(1.08);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px var(--gold-glow);
}

.film-btn-dark-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--border);
  color: var(--text-secondary);
  border-radius: 6px;
  font-size: 11px;
  font-weight: 700;
  padding: 8px 12px;
  cursor: pointer;
  transition: var(--transition);
  text-decoration: none;
  white-space: nowrap;
}

.film-btn-dark-icon:hover,
.film-btn-dark-icon.is-liked {
  background: rgba(255, 255, 255, 0.15);
  color: var(--text-primary);
  border-color: rgba(255, 255, 255, 0.2);
  transform: translateY(-1px);
}

.film-card-expand-meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 12px;
  align-items: center;
}

.film-meta-pill {
  font-size: 10px;
  font-weight: 600;
  padding: 3px 7px;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.08);
  color: var(--text-secondary);
  border: 1px solid var(--border);
}

.film-meta-imdb {
  background: rgba(232, 197, 71, 0.15);
  color: var(--gold-light);
  border-color: rgba(232, 197, 71, 0.3);
}

.film-meta-age {
  background: rgba(225, 29, 72, 0.1);
  color: #fb2c5e;
  border-color: rgba(225, 29, 72, 0.25);
  font-weight: 700;
}

.film-card-expand-genres {
  font-size: 11px;
  color: var(--text-muted);
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

@media (max-width: 768px) {
  .section--film-rail .section-header {
    padding-left: 36px;
    padding-right: 36px;
  }

  .film-rail {
    padding: 0 36px;
    --film-card-w: calc((100% - 14px) / 2);
    --film-nav-top: calc(48px + var(--film-card-h) / 2);
  }

  .film-rail-viewport {
    --film-card-w: calc((100% - 14px) / 2);
  }

  @supports (width: 1cqw) {
    .film-rail-viewport {
      --film-card-w: calc((100cqw - 14px) / 2);
    }
  }

  .film-rail-nav {
    width: 36px;
    height: 36px;
    opacity: 1;
    pointer-events: auto;
  }

}

/* ============================================
   TABS
   ============================================ */
.tabs {
  display: flex;
  gap: 4px;
  background: var(--bg-card);
  border-radius: var(--radius);
  padding: 4px;
  border: 1px solid var(--border);
}

.tab {
  padding: 8px 18px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-muted);
  cursor: pointer;
  transition: var(--transition);
  border: none;
  background: none;
  font-family: var(--font-body);
}

.tab.active,
.tab:hover {
  background: var(--gradient-accent);
  color: white;
  box-shadow: 0 4px 16px var(--accent-glow);
}

/* ============================================
   DETAIL PAGE
   ============================================ */
.detail-hero {
  position: relative;
  background: var(--bg-secondary);
  overflow: hidden;
  padding-top: var(--nav-height);
}

.detail-backdrop {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  filter: blur(20px) brightness(0.3);
  transform: scale(1.1);
}

.detail-content {
  position: relative;
  z-index: 1;
  padding: 60px 0 40px;
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 48px;
  align-items: start;
}

.detail-poster {
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.6);
  aspect-ratio: 2/3;
}

.detail-poster img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.detail-info {}

.detail-title {
  font-family: var(--font-heading);
  font-size: clamp(24px, 3vw, 40px);
  font-weight: 900;
  margin-bottom: 8px;
  line-height: 1.2;
}

.detail-origin {
  font-size: 16px;
  color: var(--text-secondary);
  margin-bottom: 20px;
}

.detail-meta-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  margin-bottom: 24px;
}

.meta-item {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.meta-label {
  font-size: 11px;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.8px;
  font-weight: 600;
}

.meta-value {
  font-size: 14px;
  color: var(--text-primary);
  font-weight: 500;
}

.detail-desc {
  color: var(--text-secondary);
  line-height: 1.8;
  font-size: 14px;
  margin-bottom: 28px;
}

.genre-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 24px;
}

.genre-tag {
  padding: 5px 14px;
  border-radius: 20px;
  border: 1px solid var(--border);
  font-size: 12px;
  color: var(--text-secondary);
  cursor: pointer;
  transition: var(--transition);
}

.genre-tag:hover {
  border-color: var(--accent);
  color: var(--accent);
}

/* ============================================
   VIDEO PLAYER
   ============================================ */
.player-section {
  background: #000;
  border-radius: var(--radius-lg);
  overflow: hidden;
  margin: 32px 0;
  box-shadow: var(--shadow-card);
}

.player-wrapper {
  position: relative;
  aspect-ratio: 16/9;
  background: #000;
}

.player-wrapper iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: none;
}

.ep-section {
  margin: 32px 0;
}

.server-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}

.server-tab {
  padding: 7px 16px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: 13px;
  color: var(--text-secondary);
  cursor: pointer;
  transition: var(--transition);
  font-family: var(--font-body);
  font-weight: 500;
}

.server-tab.active {
  background: var(--accent);
  border-color: var(--accent);
  color: white;
}

.ep-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.ep-btn {
  min-width: 52px;
  padding: 8px 14px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: 13px;
  color: var(--text-secondary);
  cursor: pointer;
  transition: var(--transition);
  text-align: center;
  font-family: var(--font-body);
  font-weight: 500;
}

.ep-btn:hover {
  border-color: var(--border-hover);
  color: var(--text-primary);
}

.ep-btn.active {
  background: var(--accent);
  border-color: var(--accent);
  color: white;
  font-weight: 700;
}

/* ============================================
   SEARCH RESULTS
   ============================================ */
.search-header {
  padding: 100px 0 40px;
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border);
}

.search-input-large {
  display: flex;
  background: var(--bg-card);
  border: 2px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  max-width: 700px;
  transition: var(--transition);
}

.search-input-large:focus-within {
  border-color: var(--accent);
  box-shadow: 0 0 0 4px var(--accent-glow);
}

.search-input-large input {
  flex: 1;
  background: none;
  border: none;
  outline: none;
  padding: 18px 24px;
  font-size: 18px;
  color: var(--text-primary);
  font-family: var(--font-body);
}

.search-input-large button {
  background: var(--accent);
  border: none;
  padding: 0 28px;
  cursor: pointer;
  color: white;
  font-size: 18px;
  transition: var(--transition);
}

.search-input-large button:hover {
  background: var(--accent-hover);
}

/* ============================================
   FILTER BAR
   ============================================ */
.filter-bar {
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border);
  padding: 16px 0;
  position: sticky;
  top: var(--nav-height);
  z-index: 100;
}

.filter-inner {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.filter-select {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 8px 14px;
  font-size: 13px;
  color: var(--text-secondary);
  cursor: pointer;
  font-family: var(--font-body);
  outline: none;
  transition: var(--transition);
}

.filter-select:focus {
  border-color: var(--accent);
  color: var(--text-primary);
}

/* ============================================
   PAGINATION
   ============================================ */
.pagination {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 48px;
  flex-wrap: wrap;
}

.page-btn {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: 14px;
  color: var(--text-secondary);
  cursor: pointer;
  transition: var(--transition);
  font-family: var(--font-body);
}

.page-btn:hover {
  border-color: var(--border-hover);
  color: var(--text-primary);
}

.page-btn.active {
  background: var(--accent);
  border-color: var(--accent);
  color: white;
  font-weight: 700;
}

.page-btn.disabled {
  opacity: 0.3;
  cursor: not-allowed;
}

/* ============================================
   COMMENTS
   ============================================ */
.comments-section {
  margin: 48px 0;
}

.comment-form {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px;
  margin-bottom: 24px;
}

.form-group {
  margin-bottom: 16px;
}

.form-label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 8px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.form-control {
  width: 100%;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 12px 16px;
  font-size: 14px;
  color: var(--text-primary);
  font-family: var(--font-body);
  outline: none;
  transition: var(--transition);
}

.form-control:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-glow);
}

textarea.form-control {
  resize: vertical;
  min-height: 100px;
}

.comment-item {
  display: flex;
  gap: 16px;
  padding: 20px 0;
  border-bottom: 1px solid var(--border);
}

.comment-avatar {
  width: 40px;
  height: 40px;
  background: var(--accent);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 16px;
  flex-shrink: 0;
}

.comment-meta {
  font-size: 12px;
  color: var(--text-muted);
  margin-bottom: 8px;
}

.comment-meta strong {
  color: var(--text-secondary);
}

.comment-text {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.7;
}

.star-rating {
  display: flex;
  gap: 4px;
  cursor: pointer;
  margin-bottom: 12px;
}

.star-rating span {
  font-size: 20px;
  color: var(--text-muted);
  transition: color 0.15s;
}

.star-rating span.active,
.star-rating span:hover {
  color: var(--gold);
}

/* ============================================
   FOOTER
   ============================================ */
footer {
  background: linear-gradient(to bottom, var(--bg-secondary) 0%, #050508 100%);
  border-top: 1px solid var(--border);
  padding: 72px 0 36px;
  margin-top: 80px;
  position: relative;
}

footer::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--gold), var(--accent), var(--gold), transparent);
  opacity: 0.5;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 48px;
  margin-bottom: 48px;
}

.footer-brand {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding-left: 0;
  margin-left: 0;
}

.footer-logo-link {
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
  margin: 0 0 12px 0;
  padding: 0;
  align-self: flex-start;
}

.footer-logo-img {
  display: block;
  width: auto;
  height: 72px;
  max-width: none;
  object-fit: contain;
  margin: 0;
}

.footer-social {
  display: flex;
  gap: 12px;
  margin-top: 16px;
}

.footer-social-link {
  width: 40px;
  height: 40px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-secondary);
  transition: var(--transition);
}

.footer-social-link:hover {
  color: var(--gold-light);
  border-color: var(--border-gold);
  background: rgba(232, 197, 71, 0.08);
  transform: translateY(-2px);
}

.footer-brand p {
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.7;
  max-width: 280px;
}

.footer-col h4 {
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--gold);
  margin-bottom: 16px;
}

.footer-col ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-col ul a {
  font-size: 14px;
  color: var(--text-muted);
  transition: var(--transition);
}

.footer-col ul a:hover {
  color: var(--text-primary);
  padding-left: 4px;
}

.footer-bottom {
  border-top: 1px solid var(--border);
  padding-top: 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 13px;
  color: var(--text-muted);
}

/* ============================================
   TOAST NOTIFICATIONS
   ============================================ */
.toast-container {
  position: fixed;
  top: calc(var(--nav-height) + 12px);
  right: 24px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.toast {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 14px 18px;
  font-size: 14px;
  box-shadow: var(--shadow-card);
  display: flex;
  align-items: center;
  gap: 10px;
  animation: slideIn 0.3s ease;
  max-width: 300px;
}

.toast.success {
  border-left: 3px solid #22c55e;
}

.toast.error {
  border-left: 3px solid var(--accent);
}

.toast.info {
  border-left: 3px solid #3b82f6;
}

@keyframes slideIn {
  from {
    transform: translateX(100%);
    opacity: 0;
  }

  to {
    transform: translateX(0);
    opacity: 1;
  }
}

/* ============================================
   LOADING SKELETON
   ============================================ */
.skeleton {
  background: linear-gradient(90deg, var(--bg-card) 25%, var(--bg-hover) 50%, var(--bg-card) 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
  border-radius: var(--radius);
}

@keyframes shimmer {
  0% {
    background-position: 200% 0;
  }

  100% {
    background-position: -200% 0;
  }
}

/* ============================================
   ADMIN PANEL
   ============================================ */
.admin-layout {
  display: flex;
  min-height: 100vh;
  padding-top: var(--nav-height);
}

.admin-sidebar {
  width: 240px;
  background: var(--bg-secondary);
  border-right: 1px solid var(--border);
  padding: 24px 12px;
  position: sticky;
  top: var(--nav-height);
  height: calc(100vh - var(--nav-height));
  overflow-y: auto;
  flex-shrink: 0;
}

.admin-main {
  flex: 1;
  padding: 32px;
  min-width: 0;
}

.sidebar-section {
  margin-bottom: 24px;
}

.sidebar-label {
  font-size: 11px;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
  padding: 8px 12px;
  margin-bottom: 4px;
}

.sidebar-link {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 8px;
  font-size: 14px;
  color: var(--text-secondary);
  transition: var(--transition);
  cursor: pointer;
  border: none;
  background: none;
  width: 100%;
  text-align: left;
  font-family: var(--font-body);
}

.sidebar-link:hover {
  background: var(--bg-hover);
  color: var(--text-primary);
}

.sidebar-link.active {
  background: rgba(229, 9, 20, 0.15);
  color: var(--accent);
}

.admin-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px;
  margin-bottom: 24px;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 16px;
  margin-bottom: 32px;
}

.stat-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.stat-value {
  font-size: 28px;
  font-weight: 800;
  font-family: var(--font-heading);
}

.stat-label {
  font-size: 13px;
  color: var(--text-muted);
}

.stat-card.accent {
  border-left: 3px solid var(--accent);
}

.stat-card.gold {
  border-left: 3px solid var(--gold);
}

.stat-card.green {
  border-left: 3px solid #22c55e;
}

.stat-card.blue {
  border-left: 3px solid #3b82f6;
}

/* Table */
.admin-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

.admin-table th {
  text-align: left;
  padding: 12px 16px;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: var(--text-muted);
  border-bottom: 1px solid var(--border);
}

.admin-table td {
  padding: 14px 16px;
  border-bottom: 1px solid var(--border);
  color: var(--text-secondary);
  vertical-align: middle;
}

.admin-table tr:hover td {
  background: var(--bg-hover);
}

.admin-table img {
  width: 48px;
  height: 64px;
  object-fit: cover;
  border-radius: 4px;
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 1200px) {
  .movies-grid.grid-6 {
    grid-template-columns: repeat(5, 1fr);
  }
}

@media (max-width: 992px) {

  .nav-logo-img {
    height: 34px;
    max-width: 140px;
  }

  .movies-grid.grid-6,
  .movies-grid.grid-5 {
    grid-template-columns: repeat(4, 1fr);
  }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }

  .detail-content {
    grid-template-columns: 200px 1fr;
    gap: 32px;
  }

  .nav-links {
    display: none;
  }

  .nav-logo-img {
    height: 30px;
    max-width: 150px;
  }
}

@media (max-width: 768px) {
  .footer-logo-img {
    height: 56px;
  }

  .footer-brand {
    align-items: flex-start;
  }

  .navbar {
    padding: 0 16px;
    gap: 12px;
  }

  .nav-search {
    width: 160px;
  }

  .nav-search:focus-within {
    width: 180px;
  }

  .hero {
    max-height: 600px;
  }

  #hero-slider .hero-info {
    left: 20px;
    right: 20px;
    bottom: 96px;
    max-width: none;
  }

  #hero-slider .hero-thumbs {
    right: 20px;
    bottom: 20px;
    max-width: calc(100% - 40px);
    overflow-x: auto;
    padding-bottom: 4px;
  }

  #hero-slider .hero-thumb {
    width: 64px;
    height: 40px;
    flex-shrink: 0;
  }

  #hero-slider .hero-btn-play {
    width: 56px;
    height: 56px;
  }

  #hero-slider .hero-btn-icon {
    width: 44px;
    height: 44px;
  }

  .movies-grid,
  .movies-grid.grid-6,
  .movies-grid.grid-5 {
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
  }

  .detail-content {
    grid-template-columns: 1fr;
  }

  .detail-poster {
    max-width: 200px;
  }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 32px;
  }

  .admin-sidebar {
    display: none;
  }
}

@media (max-width: 480px) {
  .movies-grid,
  .movies-grid.grid-6,
  .movies-grid.grid-5,
  .movies-grid.grid-4 {
    grid-template-columns: repeat(2, 1fr);
  }

  .container {
    padding: 0 14px;
  }

  #hero-slider .hero-info-title {
    font-size: 22px;
  }
}

/* ============================================
   UTILITIES
   ============================================ */
.text-accent {
  color: var(--accent);
}

.text-gold {
  color: var(--gold);
}

.text-muted {
  color: var(--text-muted);
}

.text-secondary {
  color: var(--text-secondary);
}

.flex {
  display: flex;
}

.items-center {
  align-items: center;
}

.justify-between {
  justify-content: space-between;
}

.gap-2 {
  gap: 8px;
}

.gap-3 {
  gap: 12px;
}

.gap-4 {
  gap: 16px;
}

.mt-2 {
  margin-top: 8px;
}

.mt-4 {
  margin-top: 16px;
}

.mt-6 {
  margin-top: 24px;
}

.mb-2 {
  margin-bottom: 8px;
}

.mb-4 {
  margin-bottom: 16px;
}

.mb-6 {
  margin-bottom: 24px;
}

.hidden {
  display: none !important;
}

.text-center {
  text-align: center;
}

/* Search autocomplete */
.search-suggestions {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  right: 0;
  background: var(--bg-glass);
  backdrop-filter: blur(20px);
  border: 1px solid var(--border-gold);
  border-radius: var(--radius);
  box-shadow: var(--shadow-card);
  z-index: 1001;
  max-height: 360px;
  overflow-y: auto;
}

.search-suggestion-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  cursor: pointer;
  transition: var(--transition);
  text-decoration: none;
  color: inherit;
}

.search-suggestion-item:hover {
  background: var(--bg-hover);
}

.suggestion-thumb {
  width: 36px;
  height: 48px;
  object-fit: cover;
  border-radius: 4px;
  flex-shrink: 0;
}

.suggestion-name {
  font-size: 14px;
  font-weight: 600;
  line-height: 1.3;
}

.suggestion-meta {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 2px;
}

@media (max-width: 768px) {
  .search-suggestions {
    max-height: 300px;
    left: -12px;
    right: -12px;
    border-radius: 0 0 var(--radius) var(--radius);
    z-index: 1001;
  }

  .search-suggestion-item {
    padding: 12px 14px;
    gap: 10px;
  }

  .suggestion-thumb {
    width: 32px;
    height: 44px;
  }

  .suggestion-name {
    font-size: 13px;
  }

  .suggestion-meta {
    font-size: 11px;
  }
}

.nav-search-wrap {
  position: relative;
  margin-left: auto;
}

/* ============================================
   AUTH (Đăng nhập / Đăng ký)
   ============================================ */
.auth-page {
  min-height: auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  padding: 12px 20px 48px;
  position: relative;
  overflow: hidden;
}

.auth-page::before,
.auth-page::after {
  content: '';
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
  filter: blur(80px);
}

.auth-page::before {
  width: 420px;
  height: 420px;
  top: 10%;
  left: -8%;
  background: rgba(225, 29, 72, 0.18);
}

.auth-page::after {
  width: 360px;
  height: 360px;
  bottom: 5%;
  right: -6%;
  background: rgba(232, 197, 71, 0.12);
}

.auth-wrap {
  width: 100%;
  max-width: 440px;
  position: relative;
  z-index: 1;
}

.auth-card {
  background: var(--bg-glass);
  backdrop-filter: blur(24px) saturate(1.3);
  -webkit-backdrop-filter: blur(24px) saturate(1.3);
  border: 1px solid var(--border-gold);
  border-radius: var(--radius-xl);
  padding: 44px 40px;
  box-shadow: var(--shadow-card), 0 0 60px rgba(232, 197, 71, 0.06);
  position: relative;
  overflow: hidden;
}

.auth-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--gradient-vip);
}

.auth-brand {
  text-align: center;
  margin-bottom: 28px;
}

.auth-brand-logo {
  font-family: var(--font-heading);
  font-size: 32px;
  font-weight: 800;
  letter-spacing: -0.5px;
  margin-bottom: 6px;
}

.auth-brand-logo span:first-child {
  background: var(--gradient-gold);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.auth-brand-logo span:last-child {
  color: var(--text-primary);
}

.auth-brand-tag {
  display: inline-block;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  padding: 4px 10px;
  border-radius: 4px;
  background: var(--gradient-vip);
  color: #fff;
  margin-left: 8px;
  vertical-align: middle;
}

.auth-title {
  font-family: var(--font-heading);
  font-size: 26px;
  font-weight: 700;
  text-align: center;
  margin-bottom: 8px;
  letter-spacing: -0.02em;
}

.auth-subtitle {
  color: var(--text-secondary);
  text-align: center;
  margin-bottom: 28px;
  font-size: 14px;
  line-height: 1.6;
}

.auth-alert {
  background: rgba(225, 29, 72, 0.1);
  border: 1px solid rgba(225, 29, 72, 0.35);
  border-radius: var(--radius);
  padding: 12px 16px;
  margin-bottom: 20px;
  color: #ff8a9b;
  font-size: 14px;
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.auth-alert.success {
  background: rgba(34, 197, 94, 0.1);
  border-color: rgba(34, 197, 94, 0.35);
  color: #86efac;
}

.auth-field {
  margin-bottom: 18px;
}

.auth-label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  margin-bottom: 8px;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.auth-input {
  width: 100%;
  padding: 13px 16px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text-primary);
  font-size: 15px;
  font-family: var(--font-body);
  outline: none;
  transition: var(--transition);
  box-sizing: border-box;
}

.auth-input::placeholder {
  color: var(--text-muted);
}

@media (max-width: 768px) {
  .auth-input:focus {
    box-shadow: 0 0 0 2px rgba(232, 197, 71, 0.25);
    background: rgba(255, 255, 255, 0.08);
  }
}

.auth-submit {
  width: 100%;
  margin-top: 8px;
  padding: 14px;
  font-size: 15px;
  font-weight: 700;
  font-family: var(--font-heading);
  letter-spacing: 0.02em;
}

.auth-footer {
  text-align: center;
  margin-top: 24px;
  font-size: 14px;
  color: var(--text-secondary);
}

.auth-footer a {
  color: var(--gold);
  font-weight: 600;
  transition: var(--transition);
}

.auth-footer a:hover {
  color: var(--gold-light);
}

.auth-divider {
  display: flex;
  align-items: center;
  gap: 16px;
  margin: 24px 0;
  color: var(--text-muted);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.auth-divider::before,
.auth-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--border), transparent);
}

.auth-back {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: 20px;
  transition: var(--transition);
}

.auth-back:hover {
  color: var(--gold);
}

@media (max-width: 768px) {
  .auth-page {
    padding: 8px 16px 32px;
    min-height: auto;
    justify-content: flex-start;
  }

  .auth-wrap {
    max-width: 100%;
    width: 100%;
    margin-top: 8px;
  }

  .auth-card {
    padding: 24px 20px;
    border-radius: var(--radius-lg);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
  }

  .auth-card::before {
    height: 2px;
  }

  .auth-brand {
    margin-bottom: 12px;
  }

  .auth-brand-logo {
    font-size: 22px;
  }

  .auth-title {
    font-size: 20px;
    margin-bottom: 4px;
  }

  .auth-subtitle {
    font-size: 12px;
    margin-bottom: 16px;
    line-height: 1.5;
  }

  .auth-field {
    margin-bottom: 12px;
  }

  .auth-label {
    font-size: 11px;
    margin-bottom: 5px;
  }

  .auth-input {
    padding: 10px 12px;
    font-size: 16px;
    border-radius: 8px;
  }

  .auth-submit {
    padding: 11px 12px;
    font-size: 13px;
    margin-top: 4px;
  }

  .auth-alert {
    padding: 10px 12px;
    font-size: 12px;
    margin-bottom: 12px;
  }

  .auth-divider {
    gap: 10px;
    margin: 14px 0;
    font-size: 10px;
  }

  .auth-footer {
    margin-top: 12px;
    font-size: 12px;
  }

  .auth-back {
    font-size: 12px;
    margin-bottom: 8px;
  }

  /* Reduce blur effects for better performance on mobile */
  .auth-page::before,
  .auth-page::after {
    display: none;
  }
}

@media (max-width: 480px) {
  .auth-page {
    padding: calc(var(--nav-height) + 12px) 12px 24px;
  }

  .auth-card {
    padding: 24px 16px;
  }

  .auth-brand-logo {
    font-size: 20px;
  }

  .auth-title {
    font-size: 20px;
  }

  .auth-subtitle {
    font-size: 12px;
  }

  .auth-input {
    padding: 10px 12px;
    font-size: 16px;
  }

  .auth-submit {
    padding: 11px;
    font-size: 13px;
  }
}

/* Progress bar top */
#progress-bar {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  background: var(--gradient-vip);
  z-index: 9999;
  width: 0%;
  transition: width 0.3s ease;
  box-shadow: 0 0 12px var(--gold-glow), 0 0 20px var(--accent-glow);
}
/* ============================================
   NAV USER MENU — Avatar + Dropdown
   ============================================ */
.nav-user-menu {
  position: relative;
  display: flex;
  align-items: center;
}

.nav-user-trigger {
  display: flex;
  align-items: center;
  gap: 10px;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 6px 10px 6px 6px;
  cursor: pointer;
  color: var(--text-primary);
  transition: var(--transition);
  white-space: nowrap;
}

.nav-user-trigger:hover {
  background: var(--bg-card);
  border-color: var(--accent);
}

.nav-user-avatar-wrap {
  position: relative;
  flex-shrink: 0;
}

.nav-user-avatar {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  object-fit: cover;
  display: block;
}

.nav-user-avatar-fallback {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  font-weight: 700;
  font-size: 15px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.nav-user-status {
  position: absolute;
  bottom: 1px;
  right: 1px;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #22c55e;
  border: 2px solid var(--bg);
}

.nav-user-meta {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 1px;
}

.nav-user-name {
  font-size: 13px;
  font-weight: 700;
  color: var(--text-primary);
  max-width: 100px;
  overflow: hidden;
  text-overflow: ellipsis;
}

.nav-user-sub {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 11px;
  color: var(--text-muted);
}

.nav-user-role {
  color: var(--text-muted);
}

.nav-user-role.is-admin {
  color: var(--gold, #f5c518);
  font-weight: 600;
}

.nav-user-chevron {
  margin-left: 2px;
  color: var(--text-muted);
  transition: transform 0.2s ease;
  flex-shrink: 0;
}

.nav-user-menu.open .nav-user-chevron {
  transform: rotate(180deg);
}

/* Dropdown */
.nav-user-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  min-width: 160px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 6px;
  display: none;
  flex-direction: column;
  z-index: 1000;
  box-shadow: 0 8px 32px rgba(0,0,0,0.4);
}

.nav-user-menu.open .nav-user-dropdown {
  display: flex;
}

.nav-user-dropdown a {
  padding: 9px 12px;
  border-radius: var(--radius);
  font-size: 13px;
  font-weight: 500;
  color: var(--text-primary);
  text-decoration: none;
  transition: background 0.15s;
}

.nav-user-dropdown a:hover {
  background: var(--bg-hover, rgba(255,255,255,0.06));
}

.nav-user-logout {
  color: #ef4444 !important;
  margin-top: 4px;
  border-top: 1px solid var(--border);
  padding-top: 9px !important;
}

/* ============================================
   USER PROFILE PAGE
   ============================================ */
.profile-page {
  padding: 100px 0 60px;
}

.profile-layout {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 24px;
  align-items: start;
}

.profile-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  margin-bottom: 16px;
}

.profile-hero-card {
  padding: 28px 24px;
  text-align: center;
}

.profile-avatar-wrap {
  position: relative;
  display: inline-block;
  margin-bottom: 16px;
}

.profile-username {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 4px;
}

.profile-email {
  color: var(--text-secondary);
  font-size: 13px;
  margin-bottom: 16px;
}

.profile-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}

.profile-info-card {
  padding: 16px 20px;
}

.profile-nav {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
}

.profile-nav-link {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 13px 18px;
  text-decoration: none;
  font-size: 14px;
  color: var(--text-secondary);
  border-left: 3px solid transparent;
  transition: background 0.15s, color 0.15s, border-color 0.15s;
}

.profile-nav-link.is-active {
  font-weight: 600;
  background: var(--bg-hover);
  color: var(--text-primary);
  border-left-color: var(--accent);
}

.profile-nav-link:hover {
  background: var(--bg-hover);
  color: var(--text-primary);
}

.profile-nav-logout {
  border-top: 1px solid var(--border);
  color: #ff6b6b !important;
}

.profile-nav-logout:hover {
  color: #ff8585 !important;
}

.profile-poster-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}

.profile-panel {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px;
  margin-bottom: 20px;
}

.profile-panel:last-child {
  margin-bottom: 0;
}

/* ============================================
   ANIME SHOWCASE BANNER
   ============================================ */
.anime-showcase-container {
  margin: 48px 0;
  width: 100%;
}

.anime-showcase-banner {
  position: relative;
  width: 100%;
  height: 440px;
  background: #0a0a0f;
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.7);
}

/* Lớp phủ hạt chấm tròn tĩnh như ảnh mẫu */
.anime-showcase-overlay-dots {
  position: absolute;
  inset: 0;
  z-index: 4;
  pointer-events: none;
  background-repeat: repeat;
  background-size: 3px 3px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='3' height='3'%3E%3Ccircle cx='1' cy='1' r='0.65' fill='rgba(0,0,0,0.22)'/%3E%3Ccircle cx='2.5' cy='2.5' r='0.55' fill='rgba(255,255,255,0.08)'/%3E%3C/svg%3E");
}

.anime-showcase-slides {
  position: relative;
  width: 100%;
  height: 100%;
}

.anime-showcase-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  z-index: 1;
  pointer-events: none;
  transition: opacity 0.8s cubic-bezier(0.25, 0.8, 0.25, 1);
  display: flex;
  align-items: center;
}

.anime-showcase-slide.active {
  opacity: 1;
  z-index: 2;
  pointer-events: auto;
}

.anime-showcase-bg-wrap {
  position: absolute;
  right: 0;
  top: 0;
  width: 60%;
  height: 100%;
  overflow: hidden;
  z-index: 1;
}

.anime-showcase-bg {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  filter: brightness(0.65) saturate(1.1);
  transform: scale(1.02);
  transition: transform 8s ease-out;
}

.anime-showcase-slide.active .anime-showcase-bg {
  transform: scale(1);
}

.anime-showcase-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(to right, #0a0a0f 0%, #0a0a0f 35%, rgba(10, 10, 15, 0.8) 55%, rgba(10, 10, 15, 0) 90%);
  pointer-events: none;
}

.anime-showcase-info {
  position: relative;
  z-index: 5;
  padding: 40px;
  max-width: 50%;
  display: flex;
  flex-direction: column;
  height: 100%;
  justify-content: flex-start;
}

.anime-showcase-title {
  font-family: var(--font-heading);
  font-size: 32px;
  font-weight: 900;
  line-height: 1.15;
  color: #fff;
  margin-bottom: 4px;
  text-shadow: 0 4px 24px rgba(0, 0, 0, 0.6);
  letter-spacing: -0.02em;
}

.anime-showcase-subtitle {
  font-size: 14px;
  font-weight: 500;
  color: var(--gold);
  margin-bottom: 16px;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
}

.anime-showcase-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 12px;
}

.anime-badge {
  padding: 4px 10px;
  font-size: 11px;
  font-weight: 700;
  border-radius: 4px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.anime-badge.badge-gold {
  background: var(--gradient-gold);
  color: #1a1208;
  box-shadow: 0 2px 10px var(--gold-glow);
}

.anime-badge.badge-outline {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.25);
  color: #fff;
  backdrop-filter: blur(4px);
}

.anime-showcase-genre-wrap {
  margin-bottom: 16px;
}

.anime-tag-genre {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
  background: rgba(255, 255, 255, 0.04);
  padding: 3px 8px;
  border-radius: 4px;
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.anime-showcase-desc {
  font-size: 13.5px;
  line-height: 1.65;
  color: var(--text-secondary);
  max-width: 480px;
  margin-bottom: 24px;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.7);
}

.anime-showcase-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.anime-btn-play {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--gradient-gold);
  color: #1a1208;
  border: none;
  cursor: pointer;
  box-shadow: 0 4px 20px var(--gold-glow);
  transition: transform 0.3s cubic-bezier(0.25, 0.8, 0.25, 1), box-shadow 0.3s;
  text-decoration: none;
}

.anime-btn-play:hover {
  transform: scale(1.08);
  box-shadow: 0 6px 28px var(--gold-glow);
}

.anime-btn-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.45);
  border: 1px solid rgba(255, 255, 255, 0.22);
  color: var(--text-primary);
  cursor: pointer;
  backdrop-filter: blur(8px);
  transition: border-color 0.3s, color 0.3s, background 0.3s;
}

.anime-btn-icon:hover {
  border-color: var(--gold);
  color: var(--gold);
  background: rgba(232, 197, 71, 0.08);
}

/* Khay cuộn thumbnail ở đáy */
.anime-showcase-thumbs-wrap {
  position: absolute;
  left: 40px;
  right: 40px;
  bottom: 24px;
  z-index: 10;
  pointer-events: auto;
}

.anime-showcase-thumbs {
  display: flex;
  gap: 12px; /* Distinct spacing gap as in Image 2 */
  overflow-x: auto;
  scrollbar-width: none; /* Firefox */
  padding: 8px 4px;
  align-items: center;
}

.anime-showcase-thumbs::-webkit-scrollbar {
  display: none; /* Chrome/Safari */
}

.anime-showcase-thumb {
  flex-shrink: 0;
  width: 52px; /* Wider and taller cards as in Image 2 */
  height: 76px;
  border-radius: 6px;
  background-size: cover;
  background-position: center;
  border: 1.5px solid rgba(255, 255, 255, 0.15);
  cursor: pointer;
  opacity: 0.55;
  transition: transform 0.3s cubic-bezier(0.25, 0.8, 0.25, 1), border-color 0.3s, opacity 0.3s, box-shadow 0.3s;
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.55);
}

.anime-showcase-thumb:hover {
  opacity: 0.9;
  transform: translateY(-3px) scale(1.06);
  border-color: rgba(255, 255, 255, 0.4);
}

.anime-showcase-thumb.active {
  opacity: 1;
  border-color: #ffffff;
  border-width: 2.5px; /* Pronounced white border highlight as in Image 2 */
  transform: translateY(-5px) scale(1.12);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.7), 0 0 14px rgba(255, 255, 255, 0.4);
}

/* Đảm bảo giao diện co giãn tốt */
@media (max-width: 992px) {
  .anime-showcase-info {
    max-width: 70%;
  }
  .anime-showcase-bg-wrap {
    width: 75%;
  }
  .anime-showcase-shade {
    background: linear-gradient(to right, #0a0a0f 0%, #0a0a0f 45%, rgba(10, 10, 15, 0.8) 65%, rgba(10, 10, 15, 0) 95%);
  }
}

@media (max-width: 768px) {
  .anime-showcase-banner {
    height: 480px;
  }
  .anime-showcase-bg-wrap {
    width: 100%;
    height: 60%;
    top: 0;
    right: 0;
  }
  .anime-showcase-shade {
    background: linear-gradient(to top, #0a0a0f 0%, #0a0a0f 30%, rgba(10, 10, 15, 0.6) 60%, rgba(10, 10, 15, 0) 100%);
  }
  .anime-showcase-info {
    max-width: 100%;
    padding: 24px;
    height: auto;
    position: absolute;
    bottom: 100px;
    left: 0;
    right: 0;
  }
  .anime-showcase-thumbs-wrap {
    left: 20px;
    right: 20px;
    bottom: 16px;
  }
}

/* ============================================
   COVERFLOW CAROUSEL - 3D Perspective Card Layout
   ============================================ */
.section--coverflow {
  margin: 48px 0;
  position: relative;
}

.coverflow-container {
  position: relative;
  margin-top: 24px;
  overflow: hidden;
  padding: 24px 20px;
}

.coverflow-swiper {
  width: 100%;
  margin: 0 auto;
  overflow: visible !important;
  padding: 0;
  perspective: 1200px;
}

.swiper-wrapper {
  display: flex;
  align-items: stretch;
}

.coverflow-swiper .swiper-slide {
  width: auto;
  height: auto !important;
  display: flex;
  flex-direction: column;
  position: relative;
  transition: z-index 0.3s ease;
  z-index: 1;
}

.coverflow-swiper .swiper-slide:hover {
  z-index: 50 !important;
}

.coverflow-card {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  background: transparent !important;
  border: none !important;
  border-radius: 0 !important;
  overflow: visible !important;
  box-shadow: none !important;
  transition: none !important;
}

.coverflow-card-link {
  display: flex;
  flex-direction: column;
  text-decoration: none;
  color: inherit;
  overflow: visible !important;
}

.coverflow-card-image {
  position: relative;
  width: 100%;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  background: var(--bg-secondary);
  flex-shrink: 0;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  transform-style: preserve-3d;
  transform: rotateY(20deg) rotateZ(-3deg) scale(0.92);
  transition: transform 0.45s cubic-bezier(0.165, 0.84, 0.44, 1), border-color 0.45s ease;
}

.coverflow-card-image img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.45s ease;
}

/* Hover effects */
.swiper-slide:hover .coverflow-card-image {
  transform: rotateY(0deg) rotateZ(0deg) scale(1.06);
  border-color: rgba(255, 255, 255, 0.25);
}

.swiper-slide:hover .coverflow-card-image img {
  transform: scale(1.04);
}

.coverflow-card-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.3s ease, background-color 0.3s ease;
  z-index: 5;
}

.swiper-slide:hover .coverflow-card-overlay {
  background: rgba(0, 0, 0, 0.3);
  opacity: 1;
}

.coverflow-card-overlay svg {
  color: #fff;
  filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.6));
  transform: scale(0.9);
  transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.swiper-slide:hover .coverflow-card-overlay svg {
  transform: scale(1.1);
}

/* Badges centered at the bottom */
.coverflow-card-badges {
  position: absolute;
  bottom: 10px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: row;
  gap: 4px;
  z-index: 10;
  pointer-events: none;
  width: max-content;
}

.coverflow-badge {
  display: inline-block;
  padding: 3px 6px;
  font-size: 9px;
  font-weight: 700;
  border-radius: 4px;
  text-transform: uppercase;
  letter-spacing: 0.2px;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.coverflow-badge-pd {
  background: rgba(30, 41, 59, 0.85);
  color: #cbd5e1;
}

.coverflow-badge-tm {
  background: rgba(16, 185, 129, 0.85);
  color: #fff;
  border-color: rgba(255, 255, 255, 0.15);
}

.coverflow-card-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  padding: 8px 4px 0 4px;
  background: transparent !important;
  text-align: center;
}

.coverflow-card-title {
  font-size: 13px;
  font-weight: 600;
  line-height: 1.35;
  color: #e2e8f0;
  margin: 6px 0 0 0;
  text-align: center;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  height: 36px;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.5);
  transition: color 0.3s ease;
}

.swiper-slide:hover .coverflow-card-title {
  color: var(--gold, #f5c518);
}

.coverflow-card-subtitle {
  font-size: 11px;
  color: var(--text-muted);
  margin: 3px 0 0 0;
  text-align: center;
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
}

.coverflow-nav {
  display: flex;
  gap: 12px;
  margin-top: 20px;
  justify-content: center;
}

.coverflow-nav-prev,
.coverflow-nav-next {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--bg-card);
  border: 1px solid var(--border);
  color: var(--text-primary);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}

.coverflow-nav-prev:hover,
.coverflow-nav-next:hover {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
  transform: scale(1.1);
}

@media (max-width: 768px) {
  .coverflow-swiper .swiper-slide {
    width: auto;
  }
  
  .coverflow-card-image {
    transform: rotateY(15deg) rotateZ(-2deg) scale(0.94);
  }
  
  .coverflow-card-title {
    font-size: 12px;
    height: 32px;
  }
  
  .coverflow-nav {
    margin-top: 16px;
    gap: 10px;
  }
  
  .coverflow-nav-prev,
  .coverflow-nav-next {
    width: 36px;
    height: 36px;
  }
}

/* ============================================
   THEATRICAL MOVIES — Grid Card Layout
   ============================================ */
.theatrical-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-bottom: 24px;
}

.theatrical-card {
  display: flex;
  flex-direction: column;
  background: transparent; /* No container background, matches dark page */
  border: none; /* No border box surrounding everything */
  border-radius: 12px;
  overflow: visible; /* CRITICAL: Allows vertical poster to overlap outside! */
  transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
  position: relative;
}

.theatrical-card:hover {
  transform: translateY(-6px);
}

.theatrical-card-banner-link {
  display: block;
  width: 100%;
  text-decoration: none;
}

.theatrical-card-banner {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: 12px; /* Round only the landscape banner */
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.35);
}

.theatrical-banner-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.6s ease;
}

.theatrical-card:hover .theatrical-banner-img {
  transform: scale(1.06);
}

.theatrical-banner-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, rgba(0,0,0,0) 40%, rgba(12, 15, 23, 0.8) 100%);
  z-index: 1;
}

.theatrical-quality-badge {
  position: absolute;
  top: 8px;
  right: 8px;
  font-size: 9px;
  font-weight: 800;
  background: #f5c518; /* TMDB Gold color */
  color: #000;
  padding: 2px 4px;
  border-radius: 4px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  z-index: 3;
  box-shadow: 0 2px 6px rgba(0,0,0,0.3);
}

.theatrical-card-content {
  position: relative;
  display: flex;
  padding: 12px 0 0 0;
  padding-left: 104px; /* 12px indent + 80px poster + 12px gap */
  background: transparent;
  min-height: 90px;
}

.theatrical-card-poster-link {
  position: absolute;
  left: 12px;
  top: -32px; /* Overlaps the bottom of the banner by 32px */
  width: 80px;
  height: 120px;
  border-radius: 8px;
  overflow: hidden;
  border: 1.5px solid rgba(255, 255, 255, 0.2);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.7);
  z-index: 5;
  transition: border-color 0.3s ease, transform 0.3s ease;
}

.theatrical-card:hover .theatrical-card-poster-link {
  border-color: #f5c518;
  transform: scale(1.04);
}

.theatrical-poster-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.theatrical-card-details {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  min-width: 0;
}

.theatrical-badge-lang {
  position: absolute;
  bottom: 10px;
  left: 104px; /* Aligned with text area start */
  z-index: 3;
  display: inline-block;
  font-size: 10px;
  font-weight: 700;
  background: rgba(12, 15, 23, 0.8);
  color: #fff;
  padding: 2px 8px;
  border-radius: 4px;
  border: 1.5px solid rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(8px);
  box-shadow: 0 2px 6px rgba(0,0,0,0.4);
}

.theatrical-title-link {
  text-decoration: none;
  color: inherit;
}

.theatrical-title {
  font-family: var(--font-heading), sans-serif;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.35;
  color: #fff;
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 2; /* Support up to 2 lines title */
  -webkit-box-orient: vertical;
  overflow: hidden;
  word-break: break-word;
  transition: color 0.2s ease;
}

.theatrical-card:hover .theatrical-title {
  color: #f5c518;
}

.theatrical-origin {
  font-size: 11.5px;
  color: #8892b0;
  margin: 4px 0 6px 0;
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.theatrical-meta-row {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 11px;
  color: #8892b0;
  margin-top: auto;
}

.theatrical-meta-age {
  font-weight: 800;
  background: rgba(255, 255, 255, 0.08);
  color: #e2e8f0;
  padding: 1px 4px;
  border-radius: 3px;
  font-size: 10px;
}

.theatrical-meta-bullet {
  color: rgba(255, 255, 255, 0.15);
}

/* ============================================
   THEATRICAL — RESPONSIVE
   ============================================ */
@media (max-width: 1400px) {
  .theatrical-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 14px;
  }
}

@media (max-width: 1024px) {
  .theatrical-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
  }
  
  .theatrical-card-content {
    padding: 10px 0 0 0;
    padding-left: 80px;
    min-height: 80px;
  }
  
  .theatrical-card-poster-link {
    width: 68px;
    height: 102px;
    left: 0;
    top: -26px;
  }
  
  .theatrical-badge-lang {
    left: 80px;
    bottom: 8px;
    font-size: 9px;
  }
  
  .theatrical-title {
    font-size: 12.5px;
  }
  
  .theatrical-origin {
    font-size: 10px;
    margin-bottom: 4px;
  }
}

@media (max-width: 768px) {
  .theatrical-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
  }
  
  .theatrical-card-content {
    padding: 8px 0 0 0;
    padding-left: 68px;
    min-height: 70px;
  }
  
  .theatrical-card-poster-link {
    width: 58px;
    height: 87px;
    left: 0;
    top: -22px;
    border-width: 1px;
  }
  
  .theatrical-badge-lang {
    left: 68px;
    bottom: 6px;
    font-size: 8px;
    padding: 1px 6px;
  }
  
  .theatrical-title {
    font-size: 12px;
  }
  
  .theatrical-origin {
    font-size: 9.5px;
    margin-bottom: 3px;
  }
  
  .theatrical-meta-row {
    font-size: 10px;
    gap: 4px;
  }
}

@media (max-width: 480px) {
  .theatrical-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
  }
}

/* ============================================
   THEATRICAL MOVIES — Horizontal Rail Layout
   ============================================ */
.theatrical-rail {
  --film-nav-top: 50% !important; /* Centered vertically since no expanding hover popup is needed */
  margin: 0 -8px;
  padding: 0 44px;
}

.theatrical-rail-viewport {
  overflow-x: auto;
  overflow-y: hidden !important;
  scroll-behavior: smooth;
  scrollbar-width: none;
  cursor: grab;
  padding: 8px 0 !important;
  margin: 0 !important;
}

.theatrical-rail-viewport::-webkit-scrollbar {
  display: none;
}

.theatrical-rail-track {
  display: flex;
  align-items: stretch;
  gap: 16px;
  width: max-content;
  position: relative;
}

.theatrical-rail-track .theatrical-card {
  width: calc((100cqw - 48px) / 3.1); /* 3.5 cards visible: 3 full + half peek */
  flex-shrink: 0;
  margin: 0;
}

/* Responsive Overrides for Theatrical Rail */
@media (max-width: 1024px) {
  .theatrical-rail-track .theatrical-card {
    width: calc((100cqw - 32px) / 3); /* Exactly 3 cards with 2 gaps of 16px */
  }
}

@media (max-width: 768px) {
  .theatrical-rail-track .theatrical-card {
    width: calc((100cqw - 16px) / 2); /* Exactly 2 cards with 1 gap of 16px */
  }
}

@media (max-width: 480px) {
  .theatrical-rail-track .theatrical-card {
    width: 100cqw; /* Exactly 1 card */
  }
}

