:root {
  color-scheme: dark;
  --page-bg: #020617;
  --panel-bg: rgba(15, 23, 42, 0.88);
  --panel-soft: rgba(30, 41, 59, 0.68);
  --line: rgba(148, 163, 184, 0.18);
  --text: #f8fafc;
  --muted: #94a3b8;
  --soft: #cbd5e1;
  --amber: #f59e0b;
  --amber-strong: #d97706;
  --shadow: 0 22px 60px rgba(0, 0, 0, 0.35);
}

html {
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  background:
    radial-gradient(circle at top left, rgba(245, 158, 11, 0.12), transparent 36rem),
    radial-gradient(circle at top right, rgba(59, 130, 246, 0.1), transparent 32rem),
    var(--page-bg);
  color: var(--text);
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

body.menu-open {
  overflow: hidden;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(15, 23, 42, 0.98);
  border-bottom: 1px solid var(--line);
  transition: box-shadow 0.25s ease, backdrop-filter 0.25s ease, background 0.25s ease;
}

.site-header.is-scrolled {
  background: rgba(15, 23, 42, 0.92);
  backdrop-filter: blur(16px);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.3);
}

.nav-shell {
  max-width: 80rem;
  height: 4rem;
  margin: 0 auto;
  padding: 0 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  color: #ffffff;
  font-size: 1.15rem;
  font-weight: 800;
  white-space: nowrap;
}

.brand-icon {
  width: 2rem;
  height: 2rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--amber), var(--amber-strong));
  box-shadow: 0 0 24px rgba(245, 158, 11, 0.32);
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.nav-link,
.nav-trigger {
  display: inline-flex;
  align-items: center;
  min-height: 2.35rem;
  padding: 0 0.85rem;
  border-radius: 0.65rem;
  color: #cbd5e1;
  font-size: 0.95rem;
  transition: color 0.2s ease, background 0.2s ease;
}

.nav-link:hover,
.nav-trigger:hover,
.nav-link.active {
  color: #ffffff;
  background: rgba(30, 41, 59, 0.9);
}

.nav-dropdown {
  position: relative;
}

.dropdown-menu {
  position: absolute;
  left: 0;
  top: calc(100% + 0.55rem);
  width: 13rem;
  padding: 0.5rem;
  border: 1px solid var(--line);
  border-radius: 0.9rem;
  background: rgba(15, 23, 42, 0.98);
  box-shadow: var(--shadow);
  opacity: 0;
  visibility: hidden;
  transform: translateY(0.35rem);
  transition: all 0.2s ease;
}

.nav-dropdown:hover .dropdown-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.dropdown-menu a {
  display: block;
  padding: 0.55rem 0.7rem;
  border-radius: 0.55rem;
  color: #cbd5e1;
  font-size: 0.9rem;
}

.dropdown-menu a:hover {
  color: #ffffff;
  background: rgba(51, 65, 85, 0.9);
}

.header-search {
  display: flex;
  align-items: center;
  width: min(19rem, 28vw);
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(2, 6, 23, 0.45);
  overflow: hidden;
}

.header-search input {
  width: 100%;
  min-width: 0;
  padding: 0.55rem 0.85rem;
  background: transparent;
  color: #ffffff;
  outline: none;
  font-size: 0.9rem;
}

.header-search button {
  padding: 0.55rem 0.85rem;
  color: #ffffff;
  background: rgba(245, 158, 11, 0.92);
}

.mobile-menu-button {
  display: none;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 0.8rem;
  color: #ffffff;
  background: rgba(30, 41, 59, 0.9);
}

.mobile-panel {
  display: none;
  padding: 0.8rem 1rem 1.1rem;
  border-top: 1px solid var(--line);
  background: rgba(15, 23, 42, 0.98);
}

.mobile-panel a {
  display: block;
  padding: 0.75rem 0.25rem;
  color: #cbd5e1;
}

.mobile-panel a:hover {
  color: #ffffff;
}

.page-shell {
  max-width: 80rem;
  margin: 0 auto;
  padding: 3rem 1rem 4rem;
}

.hero {
  position: relative;
  height: 70vh;
  min-height: 500px;
  max-height: 800px;
  overflow: hidden;
  background: #000000;
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  pointer-events: none;
  transition: opacity 1s ease;
}

.hero-slide.is-active {
  opacity: 1;
  pointer-events: auto;
}

.hero-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(0, 0, 0, 0.92), rgba(0, 0, 0, 0.62), rgba(0, 0, 0, 0.08));
}

.hero-content-wrap {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
}

.hero-content {
  max-width: 80rem;
  width: 100%;
  margin: 0 auto;
  padding: 0 1rem;
}

.hero-copy {
  max-width: 42rem;
}

.hero-kicker {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 1rem;
  padding: 0.4rem 0.75rem;
  border: 1px solid rgba(245, 158, 11, 0.4);
  border-radius: 999px;
  color: #fbbf24;
  background: rgba(245, 158, 11, 0.1);
  font-weight: 700;
  font-size: 0.9rem;
}

.hero-title {
  margin: 0 0 1rem;
  color: #ffffff;
  font-size: clamp(2.3rem, 6vw, 4.8rem);
  font-weight: 900;
  line-height: 1.02;
  letter-spacing: -0.04em;
}

.hero-desc {
  max-width: 40rem;
  margin-bottom: 1.4rem;
  color: #d1d5db;
  font-size: clamp(1rem, 2vw, 1.25rem);
  line-height: 1.75;
}

.hero-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem 1.25rem;
  margin-bottom: 2rem;
  color: #cbd5e1;
}

.hero-year {
  color: #fbbf24;
  font-size: 1.6rem;
  font-weight: 900;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
}

.button-primary,
.button-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 3rem;
  padding: 0 1.25rem;
  border-radius: 0.85rem;
  color: #ffffff;
  font-weight: 800;
  transition: transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}

.button-primary {
  background: linear-gradient(135deg, var(--amber), var(--amber-strong));
  box-shadow: 0 18px 45px rgba(245, 158, 11, 0.24);
}

.button-secondary {
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(15, 23, 42, 0.72);
}

.button-primary:hover,
.button-secondary:hover {
  transform: translateY(-2px) scale(1.02);
}

.hero-arrow {
  position: absolute;
  top: 50%;
  z-index: 5;
  width: 3rem;
  height: 3rem;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(8px);
  transform: translateY(-50%);
  transition: background 0.2s ease;
}

.hero-arrow:hover {
  background: rgba(0, 0, 0, 0.72);
}

.hero-prev {
  left: 1rem;
}

.hero-next {
  right: 1rem;
}

.hero-dots {
  position: absolute;
  left: 50%;
  bottom: 2rem;
  z-index: 5;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  transform: translateX(-50%);
}

.hero-dot {
  width: 0.55rem;
  height: 0.55rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.55);
  transition: all 0.2s ease;
}

.hero-dot.is-active {
  width: 3rem;
  background: var(--amber);
}

.section-block {
  margin-bottom: 4rem;
}

.section-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.section-title {
  color: #ffffff;
  font-size: clamp(1.65rem, 3vw, 2.15rem);
  font-weight: 900;
  letter-spacing: -0.03em;
}

.section-desc {
  max-width: 45rem;
  margin-top: 0.5rem;
  color: var(--muted);
  line-height: 1.7;
}

.section-link {
  flex: none;
  color: #fbbf24;
  font-weight: 800;
}

.movie-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 1rem;
}

.movie-grid.large {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1.25rem;
}

.movie-grid.search-grid {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}

.movie-card {
  min-width: 0;
}

.movie-card a {
  display: block;
}

.poster-frame {
  position: relative;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  border-radius: 1rem;
  background: #0f172a;
  box-shadow: 0 16px 38px rgba(0, 0, 0, 0.28);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.movie-card:hover .poster-frame {
  transform: translateY(-0.35rem);
  box-shadow: 0 24px 55px rgba(0, 0, 0, 0.42);
}

.poster-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.35s ease;
}

.movie-card:hover .poster-frame img {
  transform: scale(1.055);
}

.poster-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.03), rgba(0, 0, 0, 0.78));
}

.play-mark {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 3.2rem;
  height: 3.2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(245, 158, 11, 0.92);
  opacity: 0;
  transform: translate(-50%, -50%) scale(0.75);
  transition: all 0.24s ease;
}

.movie-card:hover .play-mark {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
}

.year-badge,
.rank-badge {
  position: absolute;
  top: 0.6rem;
  right: 0.6rem;
  padding: 0.22rem 0.55rem;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(0, 0, 0, 0.64);
  backdrop-filter: blur(6px);
  font-size: 0.78rem;
  font-weight: 800;
}

.rank-badge {
  left: 0.6rem;
  right: auto;
  background: rgba(245, 158, 11, 0.92);
}

.poster-info {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 0.85rem;
}

.poster-info h3 {
  color: #ffffff;
  font-size: 0.98rem;
  font-weight: 850;
  line-height: 1.35;
  display: -webkit-box;
  overflow: hidden;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.poster-info p {
  margin-top: 0.3rem;
  color: #cbd5e1;
  font-size: 0.78rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.card-copy {
  padding: 0.7rem 0.1rem 0;
}

.card-copy p {
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.55;
  display: -webkit-box;
  overflow: hidden;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1.2rem;
}

.feature-card .poster-frame {
  aspect-ratio: 16 / 10;
  border-radius: 1.2rem;
}

.category-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1rem;
}

.category-tile {
  position: relative;
  min-height: 14rem;
  overflow: hidden;
  border-radius: 1.1rem;
  background: #0f172a;
  box-shadow: 0 16px 38px rgba(0, 0, 0, 0.28);
}

.category-tile img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.category-tile:hover img {
  transform: scale(1.06);
}

.category-tile::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.1), rgba(0, 0, 0, 0.86));
}

.category-tile-content {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 2;
  padding: 1.1rem;
}

.category-tile h3 {
  color: #ffffff;
  font-size: 1.35rem;
  font-weight: 900;
}

.category-tile p {
  margin-top: 0.45rem;
  color: #cbd5e1;
  line-height: 1.6;
  font-size: 0.92rem;
}

.wide-list {
  display: grid;
  gap: 0.85rem;
}

.wide-card,
.rank-row {
  display: grid;
  grid-template-columns: 5rem minmax(0, 1fr) auto;
  align-items: center;
  gap: 1rem;
  padding: 0.75rem;
  border: 1px solid var(--line);
  border-radius: 1rem;
  background: rgba(15, 23, 42, 0.62);
  transition: background 0.2s ease, transform 0.2s ease;
}

.wide-card:hover,
.rank-row:hover {
  background: rgba(30, 41, 59, 0.85);
  transform: translateY(-2px);
}

.wide-card img,
.rank-row img {
  width: 5rem;
  height: 7rem;
  object-fit: cover;
  border-radius: 0.75rem;
}

.wide-card h3,
.rank-row h3 {
  color: #ffffff;
  font-size: 1.05rem;
  font-weight: 850;
}

.wide-card p,
.rank-row p {
  margin-top: 0.3rem;
  max-width: 46rem;
  color: var(--muted);
  line-height: 1.55;
  display: -webkit-box;
  overflow: hidden;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.rank-num {
  width: 3rem;
  color: #fbbf24;
  font-size: 1.55rem;
  font-weight: 900;
  text-align: center;
}

.page-hero {
  position: relative;
  margin-bottom: 2rem;
  padding: 3rem;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 1.5rem;
  background:
    linear-gradient(135deg, rgba(245, 158, 11, 0.12), transparent 55%),
    rgba(15, 23, 42, 0.72);
  box-shadow: var(--shadow);
}

.page-hero h1 {
  max-width: 48rem;
  color: #ffffff;
  font-size: clamp(2rem, 4vw, 3.8rem);
  font-weight: 900;
  letter-spacing: -0.04em;
  line-height: 1.08;
}

.page-hero p {
  max-width: 52rem;
  margin-top: 1rem;
  color: #cbd5e1;
  font-size: 1.05rem;
  line-height: 1.8;
}

.filter-panel {
  margin-bottom: 1.5rem;
  padding: 1rem;
  border: 1px solid var(--line);
  border-radius: 1.1rem;
  background: rgba(15, 23, 42, 0.72);
}

.filter-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
  align-items: center;
}

.filter-input {
  flex: 1 1 18rem;
  min-height: 2.8rem;
  padding: 0 1rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(2, 6, 23, 0.58);
  color: #ffffff;
  outline: none;
}

.filter-chip {
  min-height: 2.5rem;
  padding: 0 0.9rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: #cbd5e1;
  background: rgba(30, 41, 59, 0.48);
  font-weight: 700;
}

.filter-chip.is-active,
.filter-chip:hover {
  color: #ffffff;
  border-color: rgba(245, 158, 11, 0.62);
  background: rgba(245, 158, 11, 0.25);
}

.empty-state {
  display: none;
  padding: 2rem;
  border: 1px solid var(--line);
  border-radius: 1.1rem;
  color: #cbd5e1;
  background: rgba(15, 23, 42, 0.72);
  text-align: center;
}

.empty-state.is-visible {
  display: block;
}

.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-bottom: 1.1rem;
  color: #94a3b8;
  font-size: 0.92rem;
}

.breadcrumbs a:hover {
  color: #ffffff;
}

.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(18rem, 0.82fr);
  gap: 1.5rem;
}

.panel {
  border: 1px solid var(--line);
  border-radius: 1.25rem;
  background: rgba(15, 23, 42, 0.72);
  box-shadow: 0 16px 45px rgba(0, 0, 0, 0.22);
}

.player-panel {
  overflow: hidden;
  background: #000000;
}

.movie-player {
  position: relative;
  aspect-ratio: 16 / 9;
  background: #000000;
}

.movie-player video {
  width: 100%;
  height: 100%;
  background: #000000;
}

.player-cover {
  position: absolute;
  inset: 0;
  z-index: 4;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: #000000;
  cursor: pointer;
}

.player-cover.is-hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

.player-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.72;
}

.player-cover::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at center, rgba(245, 158, 11, 0.12), rgba(0, 0, 0, 0.58));
}

.player-start {
  position: absolute;
  z-index: 5;
  width: 5.2rem;
  height: 5.2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(245, 158, 11, 0.94);
  box-shadow: 0 22px 60px rgba(0, 0, 0, 0.45);
  font-size: 2rem;
  transform: scale(1);
  transition: transform 0.2s ease, background 0.2s ease;
}

.player-start:hover {
  background: var(--amber-strong);
  transform: scale(1.05);
}

.detail-panel {
  padding: 1.5rem;
}

.detail-title {
  color: #ffffff;
  font-size: clamp(1.8rem, 3vw, 2.6rem);
  font-weight: 900;
  line-height: 1.18;
  letter-spacing: -0.03em;
}

.meta-row,
.tag-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.65rem;
  margin-top: 1rem;
}

.meta-pill,
.tag-pill {
  display: inline-flex;
  align-items: center;
  min-height: 2rem;
  padding: 0 0.75rem;
  border-radius: 999px;
  color: #cbd5e1;
  background: rgba(30, 41, 59, 0.88);
  font-size: 0.88rem;
  font-weight: 700;
}

.meta-pill strong {
  color: #fbbf24;
}

.article-copy {
  margin-top: 1.5rem;
}

.article-copy h2 {
  margin: 1.3rem 0 0.6rem;
  color: #ffffff;
  font-size: 1.25rem;
  font-weight: 900;
}

.article-copy p {
  color: #cbd5e1;
  line-height: 1.85;
}

.side-cover {
  width: 100%;
  border-radius: 1rem;
  aspect-ratio: 2 / 3;
  object-fit: cover;
}

.side-panel {
  padding: 1rem;
}

.side-panel h2 {
  margin: 1rem 0 0.55rem;
  color: #ffffff;
  font-size: 1.2rem;
  font-weight: 900;
}

.side-panel p {
  color: #cbd5e1;
  line-height: 1.7;
}

.site-footer {
  border-top: 1px solid var(--line);
  background: rgba(2, 6, 23, 0.6);
}

.footer-shell {
  max-width: 80rem;
  margin: 0 auto;
  padding: 2rem 1rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  color: #94a3b8;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

.footer-links a:hover {
  color: #ffffff;
}

@media (max-width: 1100px) {
  .movie-grid,
  .movie-grid.search-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .feature-grid,
  .category-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 860px) {
  .desktop-nav,
  .header-search {
    display: none;
  }

  .mobile-menu-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  body.menu-open .mobile-panel {
    display: block;
  }

  .hero {
    min-height: 520px;
    height: 68vh;
  }

  .hero-arrow {
    display: none;
  }

  .movie-grid,
  .movie-grid.large,
  .movie-grid.search-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .feature-grid,
  .category-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .detail-layout {
    grid-template-columns: 1fr;
  }

  .page-hero {
    padding: 2rem 1.2rem;
  }
}

@media (max-width: 620px) {
  .nav-shell {
    height: 3.75rem;
  }

  .brand {
    font-size: 1rem;
  }

  .hero-content {
    padding: 0 1.2rem;
  }

  .hero-meta {
    gap: 0.55rem 0.9rem;
  }

  .movie-grid,
  .movie-grid.large,
  .movie-grid.search-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .feature-grid,
  .category-grid {
    grid-template-columns: 1fr;
  }

  .wide-card,
  .rank-row {
    grid-template-columns: 4rem minmax(0, 1fr);
  }

  .wide-card img,
  .rank-row img {
    width: 4rem;
    height: 5.8rem;
  }

  .rank-num {
    display: none;
  }

  .footer-shell {
    display: block;
  }

  .footer-links {
    margin-top: 1rem;
  }
}
