/*
  # CineFlix Custom Styles
  Supplementary styles beyond Tailwind CSS
*/

/* Scrollbar Hide */
.scrollbar-hide::-webkit-scrollbar {
  display: none;
}
.scrollbar-hide {
  -ms-overflow-style: none;
  scrollbar-width: none;
}

/* Smooth Scroll */
html {
  scroll-behavior: smooth;
}

/* Body transitions */
body {
  transition: background-color 0.3s ease;
}

.theme-toggle {
  width: 38px;
  height: 38px;
  display: inline-grid;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 999px;
  color: #d1d5db;
  background: #2a2a2a;
  transition: background 0.16s ease, color 0.16s ease, border-color 0.16s ease;
}

.theme-toggle:hover {
  color: #fff;
  border-color: rgba(14, 165, 233, 0.45);
  background: #333;
}

.theme-toggle svg {
  width: 19px;
  height: 19px;
}

[data-theme-toggle] .theme-sun,
html.light [data-theme-toggle] .theme-moon {
  display: none;
}

html.light [data-theme-toggle] .theme-sun {
  display: block;
}

@media (max-width: 767px) {
  .desktop-theme-toggle {
    display: none;
  }
}

html.light body {
  background: #f4f7fb;
  color: #111827;
}

html.light .bg-surface-50 {
  background-color: #f4f7fb !important;
}

html.light .bg-surface-100,
html.light footer {
  background-color: #ffffff !important;
}

html.light .bg-surface-200 {
  background-color: #edf2f7 !important;
}

html.light .bg-surface-300 {
  background-color: #d7dee8 !important;
}

html.light .from-surface-200 {
  --tw-gradient-from: #ffffff var(--tw-gradient-from-position) !important;
  --tw-gradient-to: rgba(255, 255, 255, 0) var(--tw-gradient-to-position) !important;
  --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to) !important;
}

html.light .to-surface-300 {
  --tw-gradient-to: #e5ebf3 var(--tw-gradient-to-position) !important;
}

html.light .hover\:from-primary\/20:hover {
  --tw-gradient-from: rgba(229, 9, 20, 0.1) var(--tw-gradient-from-position) !important;
  --tw-gradient-to: rgba(229, 9, 20, 0) var(--tw-gradient-to-position) !important;
  --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to) !important;
}

html.light .hover\:to-accent\/20:hover {
  --tw-gradient-to: rgba(14, 165, 233, 0.12) var(--tw-gradient-to-position) !important;
}

html.light .border-surface-300 {
  border-color: #d7dee8 !important;
}

html.light .text-gray-100,
html.light .text-gray-200,
html.light .text-gray-300,
html.light main .text-white,
html.light footer .text-white {
  color: #111827 !important;
}

html.light .text-gray-400,
html.light .text-gray-500,
html.light .text-gray-600 {
  color: #4b5563 !important;
}

html.light .bg-primary.text-white,
html.light .bg-accent.text-white,
html.light .bg-primary .text-white,
html.light .bg-accent .text-white {
  color: #fff !important;
}

html.light #main-nav,
html.light #main-nav.scrolled {
  background: rgba(255, 255, 255, 0.94);
  border-bottom: 1px solid rgba(215, 222, 232, 0.9);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

html.light .theme-toggle {
  color: #111827;
  border-color: #d7dee8;
  background: #edf2f7;
}

html.light input,
html.light select,
html.light textarea {
  background-color: #ffffff !important;
  border-color: #cbd5e1 !important;
  color: #111827 !important;
}

html.light input::placeholder,
html.light textarea::placeholder {
  color: #64748b !important;
}

html.light input:focus,
html.light select:focus,
html.light textarea:focus {
  border-color: #0ea5e9 !important;
  box-shadow: 0 0 0 1px rgba(14, 165, 233, 0.42) !important;
}

html.light .hover\:bg-surface-200:hover {
  background-color: #e2e8f0 !important;
}

html.light .hover\:bg-surface-300:hover {
  background-color: #cbd5e1 !important;
}

html.light .hover\:text-white:hover {
  color: #111827 !important;
}

html.light .group:hover .group-hover\:text-white {
  color: #111827 !important;
}

html.light .hover\:text-accent:hover,
html.light .group:hover .group-hover\:text-accent {
  color: #0284c7 !important;
}

html.light .bg-primary,
html.light .hover\:bg-primary:hover,
html.light .bg-accent,
html.light .bg-primary\/90,
html.light .bg-accent\/90 {
  color: #fff !important;
}

html.light .bg-primary .text-white,
html.light .bg-primary\/90 .text-white,
html.light .bg-accent .text-white,
html.light .bg-accent\/90 .text-white {
  color: #fff !important;
}

html.light .glass,
html.light #nav-search-results,
html.light [class*="shadow-2xl"] {
  border-color: rgba(203, 213, 225, 0.85);
}

html.light .hero-slide .bg-gradient-to-r,
html.light .hero-slide .bg-gradient-to-t {
  opacity: 0.92;
}

html.light .movie-row h2,
html.light h1,
html.light h2,
html.light h3 {
  color: #111827;
}

html.light .rating-star.text-gray-600 {
  color: #94a3b8 !important;
}

html.light .watch-sidebar {
  background: #ffffff;
  border-color: #d7dee8;
}

html.light .watch-sidebar-header h2,
html.light .watch-related-copy h3 {
  color: #111827;
}

html.light .watch-related-copy p,
html.light .watch-related-copy .movie-inline-stats {
  color: #64748b;
}

/* Line Clamp */
.line-clamp-2 {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.line-clamp-3 {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* Navbar scroll effect */
#main-nav {
  background: transparent;
}
#main-nav.scrolled {
  background: rgba(24, 24, 24, 0.95);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(51, 51, 51, 0.5);
}

/* Hero Slider */
.hero-slide {
  transition: opacity 0.7s ease-in-out;
}

/* Movie Card Glow */
.group\/card:hover .rounded-lg {
  box-shadow: 0 0 20px rgba(229, 9, 20, 0.15);
}

.movie-inline-stats,
.movie-detail-stat {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #9ca3af;
  font-size: 0.75rem;
  font-weight: 600;
  line-height: 1.2;
  white-space: nowrap;
}

.movie-inline-stats span,
.movie-detail-stat {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.movie-inline-stats svg,
.movie-detail-stat svg {
  flex-shrink: 0;
}

html.light .movie-inline-stats,
html.light .movie-detail-stat {
  color: #64748b;
}

.movie-hero-title {
  color: #fff !important;
  text-shadow: none;
}

.movie-hero-meta {
  color: #fff;
}

.movie-meta-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  min-height: 28px;
  padding: 5px 9px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 999px;
  color: #fff !important;
  background: rgba(0, 0, 0, 0.58);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.22);
  font-weight: 700;
  line-height: 1;
  text-shadow: 0 1px 8px rgba(0, 0, 0, 0.55);
}

.movie-meta-chip.is-rating {
  color: #38bdf8 !important;
  border-color: rgba(56, 189, 248, 0.35);
}

.movie-meta-chip.movie-detail-stat {
  color: #fff !important;
  font-size: 0.82rem;
}

html.light .movie-hero-title {
  color: #fff !important;
}

@media (min-width: 768px) {
  main .movie-hero-title.text-white,
  html.light main .movie-hero-title.text-white {
    color: #fff !important;
  }
}

@media (max-width: 767px) {
  main .movie-hero-title.text-white {
    color: #fff !important;
  }

  html.light main .movie-hero-title.text-white {
    color: #111827 !important;
  }
}

html.light .movie-meta-chip,
html.light .movie-meta-chip.movie-detail-stat {
  color: #fff !important;
  background: rgba(15, 23, 42, 0.72);
  border-color: rgba(255, 255, 255, 0.24);
}

html.light .movie-meta-chip.is-rating {
  color: #7dd3fc !important;
}

/* Rating Stars */
.rating-star {
  cursor: pointer;
  transition: color 0.15s ease;
}
.rating-star:hover,
.rating-star.active {
  color: #facc15;
}

/* Stream Player */
.stream-player {
  width: 100%;
  height: 100%;
  border: none;
}

/* Slider Dots */
.slider-dot {
  transition: all 0.3s ease;
}
.slider-dot.active {
  background-color: #e50914;
  width: 2rem;
}

/* Skeleton Loading */
.skeleton {
  background: linear-gradient(90deg, #2a2a2a 25%, #333333 50%, #2a2a2a 75%);
  background-size: 200% 100%;
  animation: skeleton-loading 1.5s ease-in-out infinite;
  border-radius: 0.5rem;
}

@keyframes skeleton-loading {
  0% {
    background-position: 200% 0;
  }
  100% {
    background-position: -200% 0;
  }
}

/* Glassmorphism */
.glass {
  background: rgba(31, 31, 31, 0.7);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(51, 51, 51, 0.5);
}

/* Neon Glow Effects */
.neon-red {
  text-shadow:
    0 0 7px rgba(229, 9, 20, 0.6),
    0 0 20px rgba(229, 9, 20, 0.3);
}
.neon-blue {
  text-shadow:
    0 0 7px rgba(14, 165, 233, 0.6),
    0 0 20px rgba(14, 165, 233, 0.3);
}
.neon-border-red {
  box-shadow:
    0 0 5px rgba(229, 9, 20, 0.4),
    inset 0 0 5px rgba(229, 9, 20, 0.1);
}
.neon-border-blue {
  box-shadow:
    0 0 5px rgba(14, 165, 233, 0.4),
    inset 0 0 5px rgba(14, 165, 233, 0.1);
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}
::-webkit-scrollbar-track {
  background: #181818;
}
::-webkit-scrollbar-thumb {
  background: #333333;
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: #444444;
}

/* Pulse animation for live indicators */
@keyframes pulse-dot {
  0%,
  100% {
    opacity: 1;
  }
  50% {
    opacity: 0.5;
  }
}
.pulse-dot {
  animation: pulse-dot 2s ease-in-out infinite;
}

/* Fade in animation */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
.fade-in {
  animation: fadeIn 0.5s ease-out;
}

/* Toast notification */
#flash-message {
  animation: slideInRight 0.3s ease-out;
}
@keyframes slideInRight {
  from {
    transform: translateX(100%);
    opacity: 0;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}

/* Image lazy loading placeholder */
img[loading="lazy"] {
  background: #2a2a2a;
}

/* Video player overlays */
.player-overlay-gradient {
  background: linear-gradient(to top, rgba(0, 0, 0, 0.8) 0%, transparent 100%);
}

/* CineFlix custom watch player */
.cine-player-section {
  background: #0d0f14;
  box-shadow: 0 22px 70px rgba(0, 0, 0, 0.45);
}

.cine-player-shell {
  background:
    linear-gradient(90deg, rgba(229, 9, 20, 0.08), transparent 32%),
    #0d0f14;
}

.cine-watch-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(300px, 420px);
  align-items: stretch;
  gap: 18px;
}

.cine-player-wrapper {
  min-width: 0;
}

.watch-sidebar {
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 8px;
  background: #202020;
  box-shadow: 0 20px 52px rgba(0, 0, 0, 0.3);
  min-height: 0;
  max-height: clamp(420px, calc(100vw * 0.5625 - 120px), 760px);
}

.watch-sidebar-header {
  padding: 20px 20px 12px;
  background: linear-gradient(to bottom, rgba(255, 255, 255, 0.03), transparent);
}

.watch-sidebar-header h2 {
  color: #f3f4f6;
  font-size: 1.05rem;
  font-weight: 900;
  text-transform: uppercase;
}

.watch-related-list {
  height: calc(100% - 56px);
  overflow-y: auto;
  padding: 0 14px 14px 20px;
}

.watch-related-list::-webkit-scrollbar {
  width: 7px;
}

.watch-related-list::-webkit-scrollbar-track {
  background: rgba(255, 255, 255, 0.04);
}

.watch-related-list::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.34);
  border-radius: 999px;
}

.watch-related-item {
  display: grid;
  grid-template-columns: 124px minmax(0, 1fr);
  gap: 12px;
  padding: 8px 0;
  color: #d1d5db;
  transition: color 0.16s ease, transform 0.16s ease;
}

.watch-related-item:hover {
  color: #fff;
  transform: translateX(2px);
}

.watch-related-thumb {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16 / 9;
  border-radius: 5px;
  background: #111;
}

.watch-related-thumb::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.35), transparent 62%);
}

.watch-related-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(0.82) contrast(1.05);
  transition: transform 0.24s ease, filter 0.24s ease;
}

.watch-related-item:hover .watch-related-thumb img {
  transform: scale(1.06);
  filter: saturate(1) contrast(1.08);
}

.watch-related-copy {
  min-width: 0;
  align-self: center;
}

.watch-related-copy h3 {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  color: currentColor;
  font-size: 0.92rem;
  font-weight: 800;
  line-height: 1.28;
}

.watch-related-copy p {
  margin-top: 7px;
  color: rgba(255, 255, 255, 0.38);
  font-size: 0.82rem;
  font-weight: 600;
}

.watch-related-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.watch-related-meta .movie-inline-stats {
  margin-top: 7px;
  font-size: 0.72rem;
}

.cine-player-section.theater-active {
  padding: 0;
}

.cine-player-section.theater-active .cine-player-shell {
  max-width: none;
  width: 100%;
  height: 100%;
  padding: 0;
}

.cine-player-section.theater-active .cine-watch-grid {
  display: block;
  height: 100%;
}

.cine-player-section.theater-active .watch-sidebar {
  display: none;
}

.cine-player-section.theater-active .cine-player-wrapper,
.cine-player-section.theater-active .cine-player {
  height: 100%;
}

.cine-player-section.theater-active .cine-player {
  aspect-ratio: auto;
}

.cine-player {
  overflow: hidden;
  cursor: pointer;
}

.cine-player.is-embed-video {
  cursor: default;
}

.cine-player-topbar {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  z-index: 7;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
  padding: 14px 16px 42px;
  pointer-events: none;
  background: linear-gradient(to bottom, rgba(0, 0, 0, 0.72), transparent);
  opacity: 1;
  transition: opacity 0.22s ease, transform 0.22s ease;
}

.cine-player.is-playing:not(.controls-visible) .cine-player-topbar {
  opacity: 0;
  transform: translateY(-10px);
}

.cine-player-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  pointer-events: auto;
}

.cine-player-section:not(.theater-active) #player-minimize-btn,
.cine-player-section.theater-active #player-theater-btn {
  display: none;
}

.cine-video {
  display: block;
  object-fit: contain;
  background: #000;
}

.cine-player::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  background:
    linear-gradient(to top, rgba(0, 0, 0, 0.88), rgba(0, 0, 0, 0.26) 30%, transparent 58%),
    linear-gradient(to bottom, rgba(0, 0, 0, 0.34), transparent 28%);
  opacity: 1;
  transition: opacity 0.25s ease;
}

.cine-player.is-embed-video::before {
  content: none;
  display: none;
}

.cine-player.is-embed-video .cine-player-topbar {
  display: none;
}

.cine-player.is-playing:not(.controls-visible)::before {
  opacity: 0;
}

.cine-center-play {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 4;
  width: 76px;
  height: 76px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 999px;
  background: rgba(12, 12, 12, 0.78);
  color: #fff;
  transform: translate(-50%, -50%) scale(1);
  box-shadow: 0 18px 45px rgba(0, 0, 0, 0.55);
  transition: transform 0.2s ease, opacity 0.2s ease, background 0.2s ease;
}

.cine-center-play:hover {
  background: rgba(229, 9, 20, 0.92);
  transform: translate(-50%, -50%) scale(1.04);
}

.cine-center-play svg {
  width: 34px;
  height: 34px;
  margin-left: 4px;
  fill: currentColor;
}

.cine-player.is-playing .cine-center-play {
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, -50%) scale(0.92);
}

.cine-player.is-loading .cine-center-play {
  opacity: 0;
  pointer-events: none;
}

.cine-loading-overlay {
  position: absolute;
  inset: 0;
  z-index: 6;
  display: grid;
  place-items: center;
  background: rgba(0, 0, 0, 0.18);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.18s ease;
}

.cine-player.is-loading .cine-loading-overlay {
  opacity: 1;
}

.cine-player.has-error .cine-loading-overlay {
  opacity: 0;
}

.cine-loading-spinner {
  width: 48px;
  height: 48px;
  border: 4px solid rgba(255, 255, 255, 0.22);
  border-top-color: #e50914;
  border-radius: 999px;
  animation: cineLoadingSpin 0.8s linear infinite;
  box-shadow: none;
}

@keyframes cineLoadingSpin {
  to {
    transform: rotate(360deg);
  }
}

.cine-player-error {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 7;
  width: min(420px, calc(100% - 32px));
  transform: translate(-50%, -50%);
  padding: 18px 20px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 8px;
  background: rgba(10, 12, 16, 0.88);
  color: #f5f5f5;
  text-align: center;
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.35);
}

.cine-player-error strong,
.cine-player-error span {
  display: block;
}

.cine-player-error strong {
  margin-bottom: 6px;
  font-size: 0.98rem;
}

.cine-player-error span {
  color: #aeb4c0;
  font-size: 0.86rem;
  line-height: 1.45;
}

.cine-player.is-embed-fallback .cine-center-play,
.cine-player.is-embed-fallback .cine-loading-overlay,
.cine-player.is-embed-fallback .cine-controls,
.cine-player.is-embed-fallback .cine-player-topbar,
.cine-player.is-embed-fallback .cine-player-error,
.cine-player.is-embed-fallback .cine-skip-indicator {
  display: none;
}

.cine-controls {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 5;
  padding: 18px 22px 20px;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.88), rgba(0, 0, 0, 0.58) 58%, transparent);
  opacity: 1;
  transform: translateY(0);
  transition: opacity 0.22s ease, transform 0.22s ease;
}

.cine-player.is-playing:not(.controls-visible) .cine-controls {
  opacity: 0;
  pointer-events: none;
  transform: translateY(16px);
}

.cine-progress-row,
.cine-control-row,
.cine-control-group {
  display: flex;
  align-items: center;
}

.cine-progress-row {
  gap: 12px;
  margin-bottom: 12px;
}

.cine-control-row {
  justify-content: space-between;
  gap: 18px;
}

.cine-control-group {
  flex-shrink: 0;
  gap: 8px;
}

.cine-time {
  width: 48px;
  flex-shrink: 0;
  color: rgba(255, 255, 255, 0.78);
  font-size: 0.78rem;
  font-variant-numeric: tabular-nums;
}

.cine-time:last-child {
  text-align: right;
}

.cine-progress,
.cine-volume {
  appearance: none;
  -webkit-appearance: none;
  border-radius: 999px;
  background: linear-gradient(to right, #e50914 0%, #e50914 var(--value, 0%), rgba(255, 255, 255, 0.22) var(--value, 0%));
  cursor: pointer;
}

.cine-progress {
  width: 100%;
  height: 6px;
}

.cine-volume {
  width: 86px;
  height: 4px;
}

.cine-progress::-webkit-slider-thumb,
.cine-volume::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 14px;
  height: 14px;
  border-radius: 999px;
  background: #fff;
  border: 2px solid #e50914;
  box-shadow: 0 0 0 5px rgba(229, 9, 20, 0.18);
}

.cine-progress::-moz-range-thumb,
.cine-volume::-moz-range-thumb {
  width: 14px;
  height: 14px;
  border: 0;
  border-radius: 999px;
  background: #fff;
  box-shadow: 0 0 0 3px #e50914;
}

.cine-icon-btn,
.cine-speed,
.cine-quality {
  height: 38px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.86);
  transition: background 0.16s ease, color 0.16s ease, border-color 0.16s ease;
}

.cine-icon-btn {
  width: 38px;
  display: inline-grid;
  place-items: center;
}

.cine-icon-btn:hover,
.cine-speed:hover,
.cine-quality:hover {
  color: #fff;
  background: rgba(229, 9, 20, 0.88);
  border-color: rgba(229, 9, 20, 0.95);
}

.cine-icon-btn svg {
  width: 20px;
  height: 20px;
  fill: currentColor;
}

.cine-speed,
.cine-quality {
  width: 72px;
  padding: 0 8px;
  font-weight: 700;
  font-size: 0.82rem;
  outline: none;
}

.cine-quality {
  width: 86px;
  background-color: rgba(0, 0, 0, 0.54);
}

.cine-icon-btn {
  position: relative;
}

.cine-skip-mark {
  color: currentColor;
  font-size: 0.82rem;
  font-weight: 900;
  line-height: 1;
  letter-spacing: 0;
  pointer-events: none;
}

.cine-player .icon-pause,
.cine-player.is-playing .icon-play,
.cine-player .icon-muted,
.cine-player.is-muted .icon-volume {
  display: none;
}

.cine-player.is-playing .icon-pause,
.cine-player.is-muted .icon-muted {
  display: block;
}

.cine-skip-indicator {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 6;
  display: grid;
  place-items: center;
  min-width: 76px;
  padding: 12px 16px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 999px;
  color: #fff;
  background: rgba(0, 0, 0, 0.72);
  box-shadow: 0 20px 55px rgba(0, 0, 0, 0.55);
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, -50%) scale(0.9);
}

.cine-skip-indicator.is-visible {
  animation: cineSkipPop 0.65s ease forwards;
}

.cine-skip-indicator span {
  font-size: 1rem;
  font-weight: 500;
  font-variant-numeric: tabular-nums;
}

@keyframes cineSkipPop {
  0% {
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.84);
  }
  18% {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
  }
  72% {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
  }
  100% {
    opacity: 0;
    transform: translate(-50%, -50%) scale(1.05);
  }
}

.cine-embed-actions {
  position: absolute;
  right: 16px;
  bottom: 16px;
  z-index: 4;
}

.cine-embed-action {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 40px;
  padding: 0 14px;
  border-radius: 8px;
  background: rgba(229, 9, 20, 0.92);
  color: #fff;
  font-size: 0.86rem;
  font-weight: 800;
  box-shadow: 0 14px 32px rgba(0, 0, 0, 0.35);
}

.cine-embed-action svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
}

@media (max-width: 768px) {
  .cine-watch-grid {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .watch-sidebar {
    max-height: 380px;
  }

  .watch-related-item {
    grid-template-columns: 112px minmax(0, 1fr);
  }

  .cine-controls {
    padding: 14px 12px;
  }

  .cine-player-topbar {
    padding: 10px 10px 34px;
  }

  .cine-control-row {
    gap: 10px;
  }

  .cine-volume {
    display: none;
  }

  .cine-icon-btn {
    width: 34px;
    height: 34px;
  }

  .cine-speed,
  .cine-quality {
    width: 64px;
    height: 34px;
  }

  .cine-center-play {
    width: 62px;
    height: 62px;
  }
}

/* Watch comments */
.watch-comments-section {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 1rem 3rem;
}

.watch-comments-panel {
  overflow: hidden;
  border-radius: 8px;
  background: #fff;
  color: #202124;
  padding: 28px clamp(18px, 4vw, 48px) 34px;
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.18);
}

.watch-comments-header,
.watch-comments-title,
.watch-comment-sort,
.watch-comment-meta,
.watch-comment-actions,
.watch-comment-action {
  display: flex;
  align-items: center;
}

.watch-comments-header {
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 28px;
}

.watch-comments-title {
  gap: 12px;
}

.watch-comments-title h2 {
  color: #202124;
  font-size: 1.45rem;
  font-weight: 900;
  line-height: 1;
}

#comment-count-badge {
  min-width: 34px;
  height: 27px;
  display: inline-grid;
  place-items: center;
  border-radius: 999px;
  background: #f25a05;
  color: #fff;
  padding: 0 10px;
  font-size: 0.86rem;
  font-weight: 900;
}

.watch-comment-sort {
  gap: 7px;
  color: #303134;
  font-size: 1.08rem;
  font-weight: 500;
  white-space: nowrap;
}

.watch-comment-sort svg {
  width: 21px;
  height: 21px;
  fill: #5f6368;
}

.watch-comment-sort .chevron {
  width: 18px;
  height: 18px;
}

.watch-comment-form {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 14px;
  margin-bottom: 26px;
}

.watch-current-avatar,
.watch-comment-avatar {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  overflow: hidden;
  border-radius: 999px;
  background: #0ea5e9;
  color: #fff;
  font-weight: 900;
  object-fit: cover;
}

.watch-comment-avatar.is-brand {
  background: #f25a05;
}

.watch-comment-avatar.is-reply {
  width: 44px;
  height: 44px;
}

.watch-comment-input textarea,
.watch-reply-form textarea {
  width: 100%;
  border: 1px solid #d7dee8;
  border-radius: 8px;
  background: #fff;
  color: #202124;
  padding: 12px 14px;
  resize: vertical;
  outline: none;
}

.watch-comment-input textarea:focus,
.watch-reply-form textarea:focus {
  border-color: #f25a05;
  box-shadow: 0 0 0 2px rgba(242, 90, 5, 0.12);
}

.watch-comment-input button,
.watch-reply-form button {
  margin-top: 9px;
  border-radius: 8px;
  background: #f25a05;
  color: #fff;
  padding: 9px 16px;
  font-size: 0.9rem;
  font-weight: 800;
}

.watch-comments-list {
  display: grid;
  gap: 24px;
}

.watch-comment {
  position: relative;
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 14px;
}

.watch-comment.is-reply {
  grid-template-columns: 44px minmax(0, 1fr);
  gap: 14px;
}

.watch-comment:not(.is-reply) > .watch-comment-body::before {
  content: "";
  position: absolute;
  left: 20px;
  top: 48px;
  bottom: -10px;
  width: 1px;
  background: #d5d7da;
}

.watch-comment-body {
  min-width: 0;
}

.watch-comment-meta {
  gap: 10px;
  margin-bottom: 10px;
}

.watch-comment-name {
  color: #202124;
  font-size: 1.12rem;
  font-weight: 900;
  line-height: 1.2;
}

.watch-comment-time {
  color: #6b7280;
  font-size: 1rem;
}

.watch-verified {
  width: 18px;
  height: 18px;
  color: #2d9bf0;
}

.watch-verified svg {
  width: 100%;
  height: 100%;
  fill: currentColor;
}

.watch-comment-text {
  color: #202124;
  font-size: 1.04rem;
  line-height: 1.55;
}

.watch-comment-actions {
  gap: 15px;
  margin-top: 14px;
  color: #5f6368;
}

.watch-comment-action {
  gap: 7px;
  color: #5f6368;
  font-size: 0.95rem;
  font-weight: 700;
}

.watch-comment-action svg {
  width: 19px;
  height: 19px;
  fill: currentColor;
}

.watch-comment-action.is-liked {
  color: #f25a05;
}

.watch-comment-more {
  color: #5f6368;
  font-size: 1.15rem;
  font-weight: 900;
  letter-spacing: 1px;
  line-height: 1;
}

.watch-comment-replies {
  display: grid;
  gap: 22px;
  margin-top: 28px;
}

.watch-reply-form {
  margin-top: 14px;
}

.watch-comment-login,
.watch-comments-empty {
  color: #6b7280;
  font-size: 0.98rem;
}

.watch-comment-login {
  margin-bottom: 24px;
}

.watch-comment-login a {
  color: #f25a05;
  font-weight: 800;
}

html.light .watch-comments-panel,
html.light .watch-comments-title h2,
html.light .watch-comment-name,
html.light .watch-comment-text {
  color: #202124 !important;
}

@media (max-width: 640px) {
  .watch-comments-header {
    align-items: flex-start;
    flex-direction: column;
    gap: 14px;
  }

  .watch-comment-sort {
    font-size: 0.96rem;
  }

  .watch-comment-form,
  .watch-comment {
    grid-template-columns: 36px minmax(0, 1fr);
    gap: 12px;
  }

  .watch-current-avatar,
  .watch-comment-avatar {
    width: 36px;
    height: 36px;
  }

  .watch-comment:not(.is-reply) > .watch-comment-body::before {
    left: 17px;
  }

  .watch-comment-name {
    font-size: 1rem;
  }

  .watch-comment-time,
  .watch-comment-text {
    font-size: 0.92rem;
  }

  .watch-comment-actions {
    flex-wrap: wrap;
    gap: 12px;
  }
}

.watch-comments-section {
  --comment-bg: #181818;
  --comment-text: #f1f1f1;
  --comment-muted: #aaa;
  --comment-border: #3f3f3f;
  --comment-hover: rgba(255, 255, 255, 0.1);
  --comment-active: #3ea6ff;
  --comment-avatar: #0ea5e9;
  max-width: 1280px;
  padding: 0 1rem 3rem;
}

html.light .watch-comments-section {
  --comment-bg: #f4f7fb;
  --comment-text: #0f172a;
  --comment-muted: #64748b;
  --comment-border: #cbd5e1;
  --comment-hover: rgba(15, 23, 42, 0.08);
  --comment-active: #0284c7;
}

.watch-comments-panel {
  padding: 8px 0 32px;
  border-radius: 0;
  background: transparent;
  color: var(--comment-text);
  box-shadow: none;
}

.watch-comments-header {
  justify-content: flex-start;
  gap: 28px;
  margin-bottom: 28px;
}

.watch-comments-title h2 {
  color: var(--comment-text) !important;
  font-size: 1.45rem;
  font-weight: 900;
}

#comment-count-badge {
  min-width: auto;
  height: auto;
  padding: 0;
  border-radius: 0;
  background: transparent;
  color: var(--comment-text);
  font-size: 1.45rem;
}

#comment-count-badge::after {
  content: " Komentar";
}

.watch-comment-sort {
  position: relative;
  gap: 10px;
  color: var(--comment-text);
  font-size: 0.98rem;
  font-weight: 800;
}

.watch-comment-sort svg {
  width: 24px;
  height: 24px;
  fill: currentColor;
}

.watch-comment-sort .chevron {
  display: none;
}

.watch-sort-menu,
.watch-comment-menu {
  position: absolute;
  z-index: 20;
  min-width: 138px;
  padding: 8px 0;
  border: 1px solid var(--comment-border);
  border-radius: 8px;
  background: var(--comment-bg);
  box-shadow: 0 14px 32px rgba(0, 0, 0, 0.28);
}

.watch-sort-menu {
  top: 34px;
  left: 0;
}

.watch-sort-menu a,
.watch-comment-menu button {
  display: block;
  width: 100%;
  padding: 9px 14px;
  color: var(--comment-text);
  text-align: left;
  font-size: 0.92rem;
}

.watch-sort-menu a:hover,
.watch-comment-menu button:hover {
  background: var(--comment-hover);
}

.watch-comment-form {
  grid-template-columns: 40px minmax(0, 1fr);
  gap: 14px;
  margin-bottom: 36px;
}

.watch-current-avatar,
.watch-comment-avatar {
  width: 40px;
  height: 40px;
  background: var(--comment-avatar);
  color: #fff;
  font-size: 1rem;
}

.watch-comment-avatar.is-reply {
  width: 32px;
  height: 32px;
  font-size: 0.86rem;
}

.watch-comment-input textarea,
.watch-reply-form textarea {
  min-height: 32px;
  max-height: 180px;
  overflow: hidden;
  border: 0;
  border-bottom: 1px solid var(--comment-border);
  border-radius: 0;
  background: transparent !important;
  color: var(--comment-text) !important;
  padding: 5px 0 7px;
  line-height: 1.45;
}

.watch-comment-input textarea:focus,
.watch-reply-form textarea:focus {
  border-color: var(--comment-text);
  box-shadow: none;
}

.watch-comment-input textarea::placeholder,
.watch-reply-form textarea::placeholder {
  color: var(--comment-muted) !important;
}

.watch-reply-actions {
  display: none;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 10px;
}

.watch-comment-form.has-text .watch-reply-actions,
.watch-reply-form.has-text .watch-reply-actions {
  display: flex;
}

.watch-comment-input button,
.watch-reply-form button {
  min-height: 36px;
  margin-top: 0;
  border-radius: 999px;
  padding: 0 16px;
  background: var(--comment-active);
  color: #fff;
  font-size: 0.86rem;
  font-weight: 800;
}

.watch-reply-actions button[type="button"] {
  background: transparent;
  color: var(--comment-text);
}

.watch-reply-actions button[type="button"]:hover,
.watch-comment-action:hover,
.watch-comment-more:hover {
  background: var(--comment-hover);
}

.watch-comments-list {
  display: grid;
  gap: 20px;
}

.watch-comment {
  grid-template-columns: 40px minmax(0, 1fr) 28px;
  gap: 12px;
  align-items: start;
}

.watch-comment.is-reply {
  grid-template-columns: 32px minmax(0, 1fr) 28px;
  gap: 12px;
}

.watch-comment:not(.is-reply) > .watch-comment-body::before {
  left: -33px;
  top: 50px;
  bottom: -12px;
  background: var(--comment-border);
  opacity: 0.55;
}

.watch-comment-body {
  position: relative;
}

.watch-comment-meta {
  gap: 6px;
  margin-bottom: 4px;
}

.watch-comment-name {
  color: var(--comment-text) !important;
  font-size: 0.94rem;
  font-weight: 900;
}

.watch-comment-time {
  color: var(--comment-muted);
  font-size: 0.86rem;
}

.watch-comment-text {
  color: var(--comment-text) !important;
  font-size: 0.96rem;
  font-weight: 600;
  line-height: 1.45;
}

.watch-comment-actions {
  gap: 6px;
  margin-top: 8px;
  color: var(--comment-text);
}

.watch-comment-action,
.watch-comment-more {
  min-height: 32px;
  border-radius: 999px;
  color: var(--comment-text);
  font-size: 0.84rem;
  font-weight: 800;
}

.watch-comment-action {
  gap: 6px;
  padding: 0 8px;
}

.watch-comment-action svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
}

.watch-comment-action.is-active {
  color: var(--comment-active);
}

.watch-comment-action.is-active svg {
  fill: currentColor;
  stroke: currentColor;
}

.watch-comment-menu-wrap {
  position: absolute;
  top: -4px;
  right: 0;
}

.watch-comment-more {
  width: 32px;
  display: grid;
  place-items: center;
  opacity: 0;
}

.watch-comment:hover .watch-comment-more,
.watch-comment-more:focus {
  opacity: 1;
}

.watch-comment-more svg {
  width: 20px;
  height: 20px;
  fill: currentColor;
}

.watch-comment-menu {
  top: 34px;
  right: 0;
}

.watch-comment-replies {
  display: grid;
  gap: 18px;
  margin-top: 14px;
}

.watch-reply-form {
  margin-top: 8px;
}

.watch-comment-login,
.watch-comments-empty {
  color: var(--comment-muted);
}

.watch-comment-login a {
  color: var(--comment-active);
}

@media (max-width: 640px) {
  .watch-comments-header {
    flex-direction: row;
    align-items: center;
    gap: 16px;
  }

  .watch-comments-title h2,
  #comment-count-badge {
    font-size: 1.12rem;
  }

  .watch-comment-form,
  .watch-comment {
    grid-template-columns: 36px minmax(0, 1fr) 24px;
    gap: 10px;
  }

  .watch-current-avatar,
  .watch-comment-avatar {
    width: 36px;
    height: 36px;
  }

  .watch-comment:not(.is-reply) > .watch-comment-body::before {
    left: -29px;
  }
}

/* Focus visible for accessibility */
.watch-comments-title {
  display: flex;
  align-items: center;
  gap: 0;
}

.watch-comments-title h2 {
  display: inline-flex;
  align-items: baseline;
  gap: 7px;
  margin: 0;
  line-height: 1.2;
}

#comment-count-badge {
  display: inline;
  min-width: 0;
  height: auto;
  padding: 0;
  background: transparent;
  color: inherit;
  font: inherit;
}

#comment-count-badge::after {
  content: "";
}

.watch-comment-form,
.watch-comment,
.watch-comment.is-reply {
  grid-template-columns: 40px minmax(0, 1fr);
}

.watch-comment.is-reply {
  margin-left: clamp(34px, calc(var(--comment-depth, 1) * 44px), 352px);
}

.watch-comment.is-reply::before {
  content: "";
  position: absolute;
  left: calc(-22px - min(var(--comment-depth, 1), 8) * 0px);
  top: -20px;
  width: 20px;
  height: 38px;
  border-left: 2px solid var(--comment-border);
  border-bottom: 2px solid var(--comment-border);
  border-bottom-left-radius: 18px;
  opacity: 0.65;
  pointer-events: none;
}

.watch-comment-replies {
  position: relative;
}

.watch-comment-replies::before {
  content: "";
  position: absolute;
  left: 19px;
  top: -4px;
  bottom: 18px;
  width: 2px;
  background: var(--comment-border);
  opacity: 0.28;
}

.watch-comment:not(.is-reply) > .watch-comment-body::before {
  display: none;
}

.watch-replies-toggle {
  position: relative;
  z-index: 1;
  width: max-content;
  margin: 2px 0 4px;
  border-radius: 999px;
  color: var(--comment-active);
  padding: 7px 13px;
  font-size: 0.92rem;
  font-weight: 900;
}

.watch-replies-toggle:hover {
  background: color-mix(in srgb, var(--comment-active) 14%, transparent);
}

.watch-replies-toggle::after {
  content: "⌄";
  display: inline-block;
  margin-left: 8px;
  font-size: 1rem;
  transform: translateY(-1px);
}

.watch-replies-toggle[aria-expanded="false"]::after {
  transform: rotate(-90deg) translateX(1px);
}

.watch-comment-sort {
  min-height: 36px;
  border-radius: 999px;
  padding: 0 10px;
}

.watch-comment-sort:hover {
  background: var(--comment-hover);
}

.watch-comment-input textarea,
.watch-reply-form textarea {
  resize: none;
}

@media (max-width: 640px) {
  .watch-comment-form,
  .watch-comment,
  .watch-comment.is-reply {
    grid-template-columns: 36px minmax(0, 1fr);
  }

  .watch-comment.is-reply {
    margin-left: clamp(24px, calc(var(--comment-depth, 1) * 30px), 160px);
  }

  .watch-comment-replies::before {
    left: 17px;
  }
}

*:focus-visible {
  outline: 2px solid #0ea5e9;
  outline-offset: 2px;
}

/* Mobile touch improvements */
@media (hover: none) {
  .group\/card:hover .rounded-lg {
    box-shadow: none;
  }
  a,
  button {
    -webkit-tap-highlight-color: transparent;
  }
}

/* Final YouTube-like comment threading and scrolling */
.watch-comments-panel {
  display: flex;
  max-height: min(760px, 74vh);
  flex-direction: column;
  overflow: hidden !important;
}

.watch-comments-list {
  max-height: clamp(340px, 54vh, 620px);
  overflow-y: auto;
  overflow-x: hidden;
  padding: 4px 14px 12px 0;
  scrollbar-width: thin;
}

.watch-comments-list::-webkit-scrollbar {
  width: 8px;
}

.watch-comments-list::-webkit-scrollbar-track {
  background: transparent;
}

.watch-comments-list::-webkit-scrollbar-thumb {
  border-radius: 999px;
  background: color-mix(in srgb, var(--comment-border) 72%, transparent);
}

.watch-comment,
.watch-comment.is-reply {
  --avatar-size: 40px;
  --avatar-center: calc(var(--avatar-size) / 2);
  --avatar-gap: 14px;
  --thread-indent: 54px;
  position: relative;
  display: grid !important;
  grid-template-columns: var(--avatar-size) minmax(0, 1fr) !important;
  gap: var(--avatar-gap) !important;
  margin-left: 0 !important;
  overflow: visible !important;
}

.watch-comment[hidden] {
  display: none !important;
}

.watch-comment.is-reply {
  --avatar-size: 32px;
  --avatar-gap: 12px;
  --thread-indent: 54px;
}

.watch-comment-avatar,
.watch-current-avatar {
  width: var(--avatar-size, 40px) !important;
  height: var(--avatar-size, 40px) !important;
}

.watch-comment-avatar.is-reply {
  width: 32px !important;
  height: 32px !important;
}

.watch-comment-body {
  position: relative;
  min-width: 0;
}

.watch-comment-replies {
  position: relative;
  display: grid;
  gap: 18px;
  margin-top: 14px;
  margin-left: calc((var(--avatar-size) + var(--avatar-gap)) * -1) !important;
  padding-left: calc(var(--avatar-center) + var(--thread-indent));
}

.watch-comment-replies::before {
  display: none !important;
}

.watch-comment:has(> .watch-comment-body > .watch-comment-replies)::after {
  content: "";
  position: absolute;
  z-index: 0;
  left: calc(var(--avatar-center) - 1px);
  top: calc(var(--avatar-size) + 8px);
  bottom: 12px;
  width: 2px;
  border-radius: 999px;
  background: var(--comment-border);
  opacity: 0.72;
  pointer-events: none;
}

.watch-comment.is-reply::before {
  content: "";
  position: absolute;
  z-index: 0;
  left: calc((var(--thread-indent) + var(--avatar-center)) * -1);
  top: calc((18px + var(--avatar-center)) * -1);
  width: calc(var(--thread-indent) + var(--avatar-center));
  height: calc(18px + var(--avatar-center));
  border-left: 2px solid var(--comment-border);
  border-bottom: 2px solid var(--comment-border);
  border-bottom-left-radius: 20px;
  opacity: 0.72;
  pointer-events: none;
}

.watch-comment:not(.is-reply)::before,
.watch-comment:not(.is-reply) > .watch-comment-body::before {
  display: none !important;
}

.watch-comment > .watch-comment-avatar,
.watch-comment > .watch-comment-body {
  position: relative;
  z-index: 1;
}

.watch-replies-toggle {
  position: relative;
  z-index: 1;
  width: max-content;
  margin: 0 0 2px -13px;
  border-radius: 999px;
  color: var(--comment-active);
  padding: 7px 13px;
  font-size: 0.92rem;
  font-weight: 900;
}

.watch-replies-toggle:hover {
  background: color-mix(in srgb, var(--comment-active) 14%, transparent);
}

.watch-replies-toggle::after {
  content: "";
  width: 8px;
  height: 8px;
  border-right: 3px solid currentColor;
  border-bottom: 3px solid currentColor;
  transform: rotate(45deg) translateY(-2px);
}

.watch-replies-toggle[aria-expanded="false"]::after {
  transform: rotate(-45deg) translateY(1px);
}

@media (max-width: 640px) {
  .watch-comments-panel {
    max-height: min(720px, 76vh);
  }

  .watch-comments-list {
    max-height: clamp(300px, 58vh, 560px);
  }

  .watch-comment,
  .watch-comment.is-reply {
    --avatar-size: 36px;
    --avatar-gap: 10px;
    --thread-indent: 38px;
  }

  .watch-comment.is-reply {
    --avatar-size: 30px;
  }
}

/* No-line reply layout with subtle mode-aware scrolling */
.watch-comments-panel {
  max-height: min(720px, 72vh);
}

.watch-comments-list {
  max-height: clamp(320px, 50vh, 560px);
  padding-right: 10px;
  scrollbar-width: thin;
  scrollbar-color: rgba(148, 163, 184, 0.45) transparent;
}

html.light .watch-comments-list {
  scrollbar-color: rgba(100, 116, 139, 0.42) transparent;
}

.watch-comments-list::-webkit-scrollbar {
  width: 6px !important;
}

.watch-comments-list::-webkit-scrollbar-track,
.watch-comments-list::-webkit-scrollbar-track-piece {
  background: transparent !important;
}

.watch-comments-list::-webkit-scrollbar-thumb {
  min-height: 44px;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.42) !important;
}

.watch-comments-list::-webkit-scrollbar-thumb:hover {
  background: rgba(148, 163, 184, 0.66) !important;
}

html.light .watch-comments-list::-webkit-scrollbar-thumb {
  background: rgba(100, 116, 139, 0.36) !important;
}

html.light .watch-comments-list::-webkit-scrollbar-thumb:hover {
  background: rgba(100, 116, 139, 0.58) !important;
}

.watch-comment:has(> .watch-comment-body > .watch-comment-replies)::after,
.watch-comment.is-reply::before,
.watch-comment-replies::before,
.watch-comment:not(.is-reply) > .watch-comment-body::before {
  display: none !important;
  content: none !important;
}

.watch-comment-replies {
  margin-left: 0 !important;
  padding-left: 0 !important;
  gap: 16px;
}

.watch-reply-form.hidden {
  display: none !important;
}

.watch-comment.is-reply {
  --avatar-size: 32px;
  --avatar-gap: 12px;
}

.watch-comment-mention {
  color: var(--comment-muted);
  font-weight: 800;
  margin-right: 4px;
}

.watch-replies-toggle {
  margin-left: -10px;
}

/* Smooth in-app notifications and confirmations */
.cine-notification-shell {
  position: relative;
  display: inline-flex;
}

.cine-notification-button {
  position: relative;
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  color: #d1d5db;
  transition: background 0.18s ease, color 0.18s ease, transform 0.18s ease;
}

.cine-notification-button:hover,
.cine-notification-button[aria-expanded="true"] {
  background: rgba(14, 165, 233, 0.16);
  color: #fff;
  transform: translateY(-1px);
}

.cine-notification-button svg {
  width: 20px;
  height: 20px;
  fill: currentColor;
}

.cine-notification-badge {
  position: absolute;
  top: 4px;
  right: 3px;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  display: grid;
  place-items: center;
  border: 2px solid #181818;
  border-radius: 999px;
  background: #e50914;
  color: #fff;
  font-size: 0.66rem;
  font-weight: 900;
  line-height: 1;
  transform-origin: center;
  box-shadow: 0 0 0 0 rgba(229, 9, 20, 0.38);
}

.cine-notification-badge.is-pulsing {
  animation: cineBadgePulse 0.72s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.cine-notification-menu {
  position: absolute;
  top: calc(100% + 12px);
  right: 0;
  z-index: 80;
  width: min(360px, calc(100vw - 24px));
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 18px;
  background: rgba(24, 24, 24, 0.96);
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.48);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  opacity: 0;
  transform: translateY(-8px) scale(0.98);
  transform-origin: top right;
  transition: opacity 0.18s ease, transform 0.18s ease;
}

.cine-notification-menu.is-open {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.cine-notification-menu.is-closing {
  pointer-events: none;
}

.cine-notification-menu-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.cine-notification-menu-head strong {
  color: #fff;
  font-size: 0.95rem;
}

.cine-notification-menu-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.cine-notification-menu-head button {
  color: #38bdf8;
  font-size: 0.78rem;
  font-weight: 800;
}

.cine-notification-list {
  max-height: 420px;
  overflow-y: auto;
  padding: 8px;
}

.cine-notification-item {
  position: relative;
  display: grid;
  grid-template-columns: 52px minmax(0, 1fr);
  gap: 12px;
  padding: 10px;
  border-radius: 14px;
  color: inherit;
  opacity: 0;
  transform: translateY(6px);
  animation: cineNotificationItemIn 0.24s ease forwards;
  animation-delay: calc(var(--notif-index, 0) * 28ms);
  transition: background 0.18s ease, transform 0.18s ease;
}

.cine-notification-item:hover {
  background: rgba(255, 255, 255, 0.06);
  transform: translateY(-1px) scale(1.01);
}

.cine-notification-item.is-unread::after {
  content: "";
  position: absolute;
  top: 18px;
  right: 12px;
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: #0ea5e9;
}

.cine-notification-thumb {
  width: 52px;
  height: 72px;
  overflow: hidden;
  display: grid;
  place-items: center;
  border-radius: 10px;
  background: #2a2a2a;
  color: #fff;
  font-size: 0.76rem;
  font-weight: 900;
}

.cine-notification-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.cine-notification-text {
  min-width: 0;
  display: grid;
  align-content: center;
  gap: 3px;
  padding-right: 14px;
}

.cine-notification-text strong {
  color: #fff;
  font-size: 0.9rem;
  line-height: 1.25;
}

.cine-notification-text span,
.cine-notification-empty {
  color: #9ca3af;
  font-size: 0.82rem;
  line-height: 1.35;
}

.cine-notification-text em {
  color: #6b7280;
  font-size: 0.74rem;
  font-style: normal;
  font-weight: 700;
}

.cine-notification-empty {
  padding: 26px 16px;
  text-align: center;
}

.cine-toast-stack {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 120;
  display: grid;
  gap: 12px;
  pointer-events: none;
}

.cine-movie-toast {
  width: min(380px, calc(100vw - 36px));
  display: grid;
  grid-template-columns: 62px minmax(0, 1fr) 30px;
  gap: 12px;
  align-items: center;
  padding: 12px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 18px;
  background: rgba(24, 24, 24, 0.96);
  color: #fff;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.42);
  opacity: 0;
  transform: translateY(16px) scale(0.98);
  pointer-events: auto;
  overflow: hidden;
  transition: opacity 0.24s ease, transform 0.24s ease;
}

.cine-movie-toast.is-visible {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.cine-movie-toast.is-leaving {
  opacity: 0;
  transform: translateY(12px) scale(0.98);
}

.cine-movie-toast-media {
  width: 62px;
  height: 86px;
  overflow: hidden;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: linear-gradient(135deg, #e50914, #0ea5e9);
  font-weight: 900;
}

.cine-movie-toast-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.cine-movie-toast-copy {
  min-width: 0;
  display: grid;
  gap: 3px;
}

.cine-movie-toast-copy small {
  color: #38bdf8;
  font-size: 0.72rem;
  font-weight: 900;
  text-transform: uppercase;
}

.cine-movie-toast-copy strong {
  overflow: hidden;
  color: #fff;
  font-size: 0.96rem;
  line-height: 1.22;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.cine-movie-toast-copy em {
  color: #a1a1aa;
  font-size: 0.8rem;
  font-style: normal;
}

.cine-movie-toast button {
  width: 28px;
  height: 28px;
  border-radius: 999px;
  color: #9ca3af;
  font-size: 1rem;
  font-weight: 900;
}

.cine-movie-toast button:hover {
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
}

.cine-movie-toast-progress {
  position: absolute;
  left: 0;
  right: auto;
  bottom: 0;
  width: 100%;
  height: 3px;
  background: linear-gradient(90deg, #e50914, #38bdf8);
  transform-origin: left;
  animation: cineToastProgress 7s linear forwards;
}

.cine-push-prompt {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 130;
  width: min(430px, calc(100vw - 36px));
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  padding: 18px 52px 18px 18px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 18px;
  background: rgba(24, 24, 24, 0.97);
  color: #fff;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.44);
  opacity: 0;
  transform: translateY(18px) scale(0.98);
  transition: opacity 0.24s ease, transform 0.24s ease;
}

.cine-push-prompt.is-visible {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.cine-push-prompt.is-leaving {
  opacity: 0;
  transform: translateY(14px) scale(0.98);
}

.cine-push-prompt-close {
  position: absolute;
  top: 16px;
  right: 18px;
  width: 28px;
  height: 28px;
  z-index: 2;
  border-radius: 999px;
  color: #ef4444;
  font-size: 1.3rem;
  font-weight: 900;
  line-height: 1;
}

.cine-push-prompt-close:hover {
  background: rgba(239, 68, 68, 0.14);
  color: #f87171;
}

.cine-push-prompt-icon {
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  background: linear-gradient(135deg, rgba(229, 9, 20, 0.24), rgba(14, 165, 233, 0.2));
  color: #38bdf8;
}

.cine-push-prompt-icon svg {
  width: 24px;
  height: 24px;
  fill: currentColor;
}

.cine-push-prompt-copy {
  min-width: 0;
  display: grid;
  gap: 3px;
  padding-right: 16px;
}

.cine-push-prompt-copy strong {
  color: #fff;
  font-size: 0.96rem;
  line-height: 1.25;
}

.cine-push-prompt-copy span {
  color: #a1a1aa;
  font-size: 0.82rem;
  line-height: 1.35;
}

.cine-push-prompt-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.cine-push-prompt-action {
  min-height: 36px;
  padding: 0 14px;
  border-radius: 999px;
  background: #e50914;
  color: #fff;
  font-size: 0.78rem;
  font-weight: 900;
  white-space: nowrap;
}

.cine-push-prompt-action:hover {
  background: #b20710;
}

.cine-push-prompt-later {
  min-height: 36px;
  padding: 0 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  color: #d1d5db;
  font-size: 0.78rem;
  font-weight: 800;
  white-space: nowrap;
}

.cine-push-prompt-later:hover {
  background: rgba(255, 255, 255, 0.13);
  color: #fff;
}

.cine-confirm-modal[hidden] {
  display: none !important;
}

.cine-confirm-modal {
  position: fixed;
  inset: 0;
  z-index: 150;
  display: grid;
  place-items: center;
  padding: 20px;
}

.cine-confirm-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.58);
  opacity: 0;
  transition: opacity 0.18s ease;
}

.cine-confirm-dialog {
  position: relative;
  width: min(420px, 100%);
  display: grid;
  gap: 16px;
  padding: 22px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 20px;
  background: rgba(24, 24, 24, 0.98);
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.58);
  opacity: 0;
  transform: translateY(18px) scale(0.97);
  transition: opacity 0.18s ease, transform 0.18s ease;
}

.cine-confirm-modal.is-open .cine-confirm-backdrop,
.cine-confirm-modal.is-open .cine-confirm-dialog {
  opacity: 1;
}

.cine-confirm-modal.is-open .cine-confirm-dialog {
  transform: translateY(0) scale(1);
}

.cine-confirm-icon {
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: rgba(229, 9, 20, 0.14);
  color: #ef4444;
}

.cine-confirm-icon svg {
  width: 24px;
  height: 24px;
  fill: currentColor;
}

.cine-confirm-copy h2 {
  margin: 0 0 6px;
  color: #fff;
  font-size: 1.08rem;
  font-weight: 900;
}

.cine-confirm-copy p {
  margin: 0;
  color: #a1a1aa;
  font-size: 0.92rem;
  line-height: 1.45;
}

.cine-confirm-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
}

.cine-confirm-actions button {
  min-height: 38px;
  border-radius: 999px;
  padding: 0 16px;
  font-size: 0.86rem;
  font-weight: 900;
}

.cine-confirm-cancel {
  background: rgba(255, 255, 255, 0.08);
  color: #e5e7eb;
}

.cine-confirm-accept {
  background: #e50914;
  color: #fff;
}

html.light .cine-notification-button {
  border-color: rgba(15, 23, 42, 0.1);
  background: rgba(15, 23, 42, 0.04);
  color: #475569;
}

html.light .cine-notification-menu,
html.light .cine-movie-toast,
html.light .cine-push-prompt,
html.light .cine-confirm-dialog {
  border-color: rgba(15, 23, 42, 0.12);
  background: rgba(255, 255, 255, 0.98);
  box-shadow: 0 24px 70px rgba(15, 23, 42, 0.16);
}

html.light .cine-notification-menu-head strong,
html.light .cine-notification-text strong,
html.light .cine-movie-toast-copy strong,
html.light .cine-push-prompt-copy strong,
html.light .cine-confirm-copy h2 {
  color: #0f172a;
}

html.light .cine-notification-text span,
html.light .cine-notification-empty,
html.light .cine-movie-toast-copy em,
html.light .cine-push-prompt-copy span,
html.light .cine-confirm-copy p {
  color: #64748b;
}

html.light .cine-push-prompt-later {
  background: rgba(15, 23, 42, 0.08);
  color: #334155;
}

html.light .cine-confirm-cancel {
  background: rgba(15, 23, 42, 0.08);
  color: #0f172a;
}

@keyframes cineBadgePulse {
  0% {
    transform: scale(1);
    box-shadow: 0 0 0 0 rgba(229, 9, 20, 0.45);
  }
  45% {
    transform: scale(1.18);
    box-shadow: 0 0 0 8px rgba(229, 9, 20, 0.14);
  }
  100% {
    transform: scale(1);
    box-shadow: 0 0 0 14px rgba(229, 9, 20, 0);
  }
}

@keyframes cineNotificationItemIn {
  from {
    opacity: 0;
    transform: translateY(6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes cineToastProgress {
  from {
    transform: scaleX(1);
  }
  to {
    transform: scaleX(0);
  }
}

@media (max-width: 640px) {
  .cine-notification-menu {
    right: -64px;
  }

  .cine-toast-stack {
    right: 12px;
    bottom: 12px;
  }

  .cine-push-prompt {
    right: 12px;
    bottom: 12px;
    grid-template-columns: 42px minmax(0, 1fr);
  }

  .cine-push-prompt-actions {
    grid-column: 1 / -1;
    width: 100%;
  }

  .cine-push-prompt-action,
  .cine-push-prompt-later {
    flex: 1;
    width: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  .cine-notification-badge.is-pulsing,
  .cine-notification-item,
  .cine-movie-toast-progress {
    animation: none;
  }

  .cine-notification-menu,
  .cine-notification-button,
  .cine-notification-item,
  .cine-movie-toast,
  .cine-push-prompt {
    transition: none;
  }

  .cine-notification-item {
    opacity: 1;
    transform: none;
  }
}
