:root {
  color-scheme: dark;
  --site-blue: #38bdf8;
  --site-blue-strong: #2563eb;
  --site-cyan: #22d3ee;
  --site-bg: #030712;
  --site-panel: rgba(17, 24, 39, 0.82);
  --site-border: rgba(148, 163, 184, 0.18);
  --site-text: #f8fafc;
  --site-muted: #94a3b8;
}

html {
  scroll-behavior: smooth;
}

body {
  background:
    radial-gradient(circle at top left, rgba(37, 99, 235, 0.22), transparent 34rem),
    radial-gradient(circle at top right, rgba(6, 182, 212, 0.12), transparent 30rem),
    var(--site-bg);
}

img {
  display: block;
}

.site-header {
  border-bottom: 1px solid rgba(148, 163, 184, 0.08);
}

.logo-mark {
  width: 2rem;
  height: 2rem;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  font-size: 0.78rem;
  background: linear-gradient(135deg, #2563eb, #06b6d4);
  box-shadow: 0 12px 30px rgba(37, 99, 235, 0.35);
}

.logo-mark.small {
  width: 1.5rem;
  height: 1.5rem;
  font-size: 0.62rem;
}

.menu-line {
  display: block;
  width: 1.5rem;
  height: 2px;
  margin: 5px 0;
  background: currentColor;
  border-radius: 999px;
}

.mobile-menu {
  padding: 0 0 1rem;
}

.mobile-menu-link {
  display: block;
  padding: 0.65rem 0;
  font-size: 0.95rem;
  font-weight: 600;
  border-top: 1px solid rgba(148, 163, 184, 0.12);
}

.hero-carousel {
  position: relative;
  min-height: 760px;
  overflow: hidden;
  isolation: isolate;
}

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

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

.hero-backdrop {
  position: absolute;
  inset: 0;
  overflow: hidden;
  background:
    linear-gradient(120deg, rgba(2, 6, 23, 0.96) 0%, rgba(15, 23, 42, 0.84) 42%, rgba(15, 23, 42, 0.48) 100%),
    var(--hero-image) center / cover no-repeat;
}

.hero-backdrop img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: blur(10px) saturate(1.15);
  transform: scale(1.08);
  opacity: 0.36;
}

.hero-backdrop::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(to top, #030712 0%, rgba(3, 7, 18, 0.18) 50%, rgba(3, 7, 18, 0.9) 100%),
    radial-gradient(circle at 72% 34%, rgba(59, 130, 246, 0.34), transparent 26rem);
}

.hero-content {
  position: relative;
  z-index: 2;
  min-height: 760px;
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(280px, 0.72fr);
  gap: 4rem;
  align-items: center;
  padding-top: 7rem;
  padding-bottom: 5.5rem;
}

.hero-copy {
  max-width: 760px;
}

.hero-kicker {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.45rem 0.85rem;
  border: 1px solid rgba(56, 189, 248, 0.35);
  border-radius: 999px;
  color: #bfdbfe;
  background: rgba(14, 165, 233, 0.12);
  backdrop-filter: blur(12px);
  font-size: 0.9rem;
  font-weight: 700;
  margin-bottom: 1.35rem;
}

.hero-copy h1 {
  color: #ffffff;
  font-size: clamp(2.8rem, 7vw, 5.8rem);
  line-height: 0.95;
  letter-spacing: -0.055em;
  font-weight: 900;
  margin: 0 0 1.2rem;
}

.hero-one-line {
  color: #e2e8f0;
  font-size: clamp(1.15rem, 2.4vw, 1.55rem);
  line-height: 1.65;
  max-width: 680px;
  margin-bottom: 1rem;
}

.hero-summary {
  color: #94a3b8;
  font-size: 1rem;
  line-height: 1.85;
  max-width: 720px;
}

.hero-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  margin: 1.5rem 0 2rem;
}

.hero-tags span,
.tag-pill {
  display: inline-flex;
  align-items: center;
  padding: 0.32rem 0.68rem;
  border-radius: 999px;
  font-size: 0.78rem;
  color: #bfdbfe;
  background: rgba(30, 64, 175, 0.34);
  border: 1px solid rgba(96, 165, 250, 0.2);
}

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

.primary-button,
.secondary-button,
.section-link,
.filter-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  font-weight: 800;
  transition: transform 180ms ease, border-color 180ms ease, background 180ms ease;
}

.primary-button {
  min-height: 3.25rem;
  padding: 0 1.55rem;
  color: #ffffff;
  background: linear-gradient(135deg, #2563eb, #06b6d4);
  box-shadow: 0 18px 36px rgba(37, 99, 235, 0.35);
}

.secondary-button {
  min-height: 3.25rem;
  padding: 0 1.4rem;
  color: #e2e8f0;
  border: 1px solid rgba(226, 232, 240, 0.22);
  background: rgba(15, 23, 42, 0.62);
}

.primary-button:hover,
.secondary-button:hover,
.section-link:hover,
.filter-button:hover {
  transform: translateY(-2px);
}

.hero-poster {
  position: relative;
  overflow: hidden;
  border-radius: 1.7rem;
  min-height: 480px;
  background: rgba(15, 23, 42, 0.9);
  box-shadow: 0 32px 80px rgba(2, 6, 23, 0.6);
  border: 1px solid rgba(148, 163, 184, 0.18);
}

.hero-poster img {
  width: 100%;
  height: 100%;
  min-height: 480px;
  object-fit: cover;
  transition: transform 600ms ease;
}

.hero-poster:hover img {
  transform: scale(1.05);
}

.hero-play,
.play-circle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 4.6rem;
  height: 4.6rem;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(37, 99, 235, 0.9);
  box-shadow: 0 16px 40px rgba(37, 99, 235, 0.42);
}

.hero-play {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
}

.hero-controls {
  position: absolute;
  z-index: 5;
  left: 50%;
  bottom: 2.2rem;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.5rem;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.62);
  border: 1px solid rgba(148, 163, 184, 0.18);
  backdrop-filter: blur(14px);
}

.hero-arrow,
.hero-dot {
  border: 0;
  cursor: pointer;
}

.hero-arrow {
  width: 2.4rem;
  height: 2.4rem;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(51, 65, 85, 0.75);
  font-size: 1.5rem;
  line-height: 1;
}

.hero-dots {
  display: flex;
  gap: 0.5rem;
}

.hero-dot {
  width: 0.62rem;
  height: 0.62rem;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.6);
  transition: width 200ms ease, background 200ms ease;
}

.hero-dot.is-active {
  width: 1.75rem;
  background: #38bdf8;
}

.page-hero {
  padding: 9.5rem 1rem 3.5rem;
  background:
    radial-gradient(circle at 18% 0%, rgba(37, 99, 235, 0.24), transparent 32rem),
    radial-gradient(circle at 80% 25%, rgba(14, 165, 233, 0.12), transparent 28rem);
}

.page-hero-inner {
  max-width: 80rem;
  margin: 0 auto;
}

.page-kicker {
  color: #38bdf8;
  font-weight: 800;
  margin-bottom: 0.8rem;
}

.page-title {
  color: #ffffff;
  font-size: clamp(2.25rem, 5vw, 4.6rem);
  font-weight: 900;
  line-height: 1.05;
  letter-spacing: -0.045em;
  margin: 0 0 1rem;
}

.page-desc {
  max-width: 780px;
  color: #94a3b8;
  font-size: 1.05rem;
  line-height: 1.85;
}

.content-section {
  max-width: 80rem;
  margin: 0 auto;
  padding: 3rem 1rem;
}

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

.section-heading h2 {
  color: #ffffff;
  font-size: clamp(1.65rem, 3vw, 2.3rem);
  font-weight: 900;
  margin: 0;
}

.section-heading p {
  margin: 0.45rem 0 0;
  color: #94a3b8;
}

.section-link,
.filter-button {
  color: #dbeafe;
  border: 1px solid rgba(96, 165, 250, 0.25);
  background: rgba(30, 64, 175, 0.28);
  padding: 0.7rem 1rem;
  white-space: nowrap;
}

.movie-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 1.25rem;
}

.movie-grid.compact {
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
}

.movie-card {
  border-radius: 1rem;
  overflow: hidden;
  background: rgba(17, 24, 39, 0.78);
  border: 1px solid rgba(148, 163, 184, 0.13);
  box-shadow: 0 18px 48px rgba(2, 6, 23, 0.28);
  transition: transform 220ms ease, border-color 220ms ease, background 220ms ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  border-color: rgba(56, 189, 248, 0.42);
  background: rgba(17, 24, 39, 0.94);
}

.movie-card-link {
  display: block;
  height: 100%;
}

.movie-card-cover {
  position: relative;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  background: linear-gradient(135deg, rgba(30, 41, 59, 0.9), rgba(15, 23, 42, 0.95));
}

.movie-card-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 520ms ease, opacity 200ms ease;
}

.movie-card:hover .movie-card-cover img {
  transform: scale(1.08);
}

.movie-card-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.86), rgba(0, 0, 0, 0.08));
  transition: opacity 240ms ease;
}

.movie-card:hover .movie-card-overlay {
  opacity: 1;
}

.play-circle {
  width: 3.6rem;
  height: 3.6rem;
}

.year-badge,
.rank-badge {
  position: absolute;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  backdrop-filter: blur(10px);
}

.year-badge {
  right: 0.65rem;
  bottom: 0.65rem;
  padding: 0.25rem 0.55rem;
  color: #cbd5e1;
  font-size: 0.72rem;
  background: rgba(0, 0, 0, 0.74);
}

.rank-badge {
  left: 0.65rem;
  top: 0.65rem;
  width: 2.2rem;
  height: 2.2rem;
  color: #ffffff;
  font-weight: 900;
  background: linear-gradient(135deg, #f97316, #ef4444);
  box-shadow: 0 10px 24px rgba(239, 68, 68, 0.28);
}

.movie-card-body {
  padding: 1rem;
}

.movie-card-title {
  color: #ffffff;
  font-size: 1rem;
  line-height: 1.45;
  font-weight: 800;
  min-height: 2.9em;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin: 0 0 0.45rem;
}

.movie-card-desc {
  color: #94a3b8;
  font-size: 0.86rem;
  line-height: 1.6;
  min-height: 4.1em;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin: 0 0 0.75rem;
}

.movie-card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  color: #cbd5e1;
  font-size: 0.78rem;
  margin-bottom: 0.75rem;
}

.movie-card-meta span {
  padding: 0.18rem 0.5rem;
  border-radius: 999px;
  background: rgba(51, 65, 85, 0.72);
}

.movie-card-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.category-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1.25rem;
}

.category-card {
  overflow: hidden;
  border-radius: 1.25rem;
  background: rgba(17, 24, 39, 0.78);
  border: 1px solid rgba(148, 163, 184, 0.14);
  transition: transform 220ms ease, border-color 220ms ease;
}

.category-card:hover {
  transform: translateY(-5px);
  border-color: rgba(56, 189, 248, 0.42);
}

.category-collage {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.25rem;
  padding: 0.5rem;
  background: rgba(15, 23, 42, 0.85);
}

.category-collage img {
  width: 100%;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  border-radius: 0.75rem;
}

.category-card-body {
  padding: 1rem;
}

.category-card h3 {
  color: #ffffff;
  font-size: 1.18rem;
  font-weight: 900;
  margin: 0 0 0.5rem;
}

.category-card p {
  color: #94a3b8;
  font-size: 0.9rem;
  line-height: 1.65;
  margin: 0 0 0.75rem;
}

.category-card span {
  color: #38bdf8;
  font-size: 0.86rem;
  font-weight: 800;
}

.filter-panel {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) repeat(3, minmax(150px, 0.25fr));
  gap: 0.8rem;
  padding: 1rem;
  border-radius: 1.25rem;
  background: rgba(15, 23, 42, 0.78);
  border: 1px solid rgba(148, 163, 184, 0.14);
  margin-bottom: 1.5rem;
}

.filter-panel input,
.filter-panel select {
  width: 100%;
  height: 3rem;
  border-radius: 0.9rem;
  border: 1px solid rgba(148, 163, 184, 0.18);
  background: rgba(2, 6, 23, 0.86);
  color: #e2e8f0;
  padding: 0 0.9rem;
  outline: none;
}

.filter-panel input:focus,
.filter-panel select:focus {
  border-color: rgba(56, 189, 248, 0.62);
}

.filter-count {
  color: #94a3b8;
  font-size: 0.9rem;
  margin-bottom: 1.2rem;
}

.empty-state {
  display: none;
  padding: 2rem;
  border-radius: 1rem;
  color: #94a3b8;
  text-align: center;
  background: rgba(15, 23, 42, 0.75);
  border: 1px solid rgba(148, 163, 184, 0.14);
}

.detail-hero {
  padding: 8rem 1rem 3rem;
  background: radial-gradient(circle at top left, rgba(37, 99, 235, 0.22), transparent 32rem);
}

.detail-layout {
  max-width: 80rem;
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(270px, 0.42fr);
  gap: 2rem;
  align-items: start;
}

.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  color: #94a3b8;
  font-size: 0.9rem;
  margin-bottom: 1rem;
}

.breadcrumbs a {
  color: #93c5fd;
}

.detail-title {
  color: #ffffff;
  font-size: clamp(2rem, 5vw, 4.4rem);
  font-weight: 950;
  line-height: 1.05;
  letter-spacing: -0.045em;
  margin: 0 0 1rem;
}

.detail-desc {
  color: #cbd5e1;
  line-height: 1.85;
  font-size: 1.05rem;
  margin-bottom: 1.2rem;
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-bottom: 1.4rem;
}

.detail-meta span {
  padding: 0.42rem 0.75rem;
  border-radius: 999px;
  color: #dbeafe;
  background: rgba(30, 64, 175, 0.28);
  border: 1px solid rgba(96, 165, 250, 0.18);
  font-size: 0.85rem;
  font-weight: 700;
}

.detail-poster {
  overflow: hidden;
  border-radius: 1.35rem;
  background: rgba(15, 23, 42, 0.85);
  border: 1px solid rgba(148, 163, 184, 0.14);
  box-shadow: 0 30px 70px rgba(2, 6, 23, 0.42);
}

.detail-poster img {
  width: 100%;
  aspect-ratio: 2 / 3;
  object-fit: cover;
}

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

.player-card {
  position: relative;
  overflow: hidden;
  border-radius: 1.3rem;
  background: #000000;
  border: 1px solid rgba(148, 163, 184, 0.14);
  box-shadow: 0 30px 70px rgba(2, 6, 23, 0.42);
}

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

.video-stage video {
  width: 100%;
  height: 100%;
  display: block;
  background: #000000;
}

.play-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 0;
  cursor: pointer;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.68), rgba(0, 0, 0, 0.12));
  z-index: 3;
}

.play-overlay.is-hidden {
  display: none;
}

.play-overlay span {
  width: 5rem;
  height: 5rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  color: #ffffff;
  background: linear-gradient(135deg, #2563eb, #06b6d4);
  box-shadow: 0 20px 50px rgba(37, 99, 235, 0.44);
  font-size: 1.35rem;
}

.detail-content {
  max-width: 80rem;
  margin: 0 auto;
  padding: 0 1rem 3rem;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(260px, 0.35fr);
  gap: 1.5rem;
}

.story-panel,
.side-panel {
  border-radius: 1.2rem;
  background: rgba(17, 24, 39, 0.76);
  border: 1px solid rgba(148, 163, 184, 0.14);
  padding: 1.25rem;
}

.story-panel h2,
.side-panel h2 {
  color: #ffffff;
  font-weight: 900;
  font-size: 1.35rem;
  margin: 0 0 0.9rem;
}

.story-panel p {
  color: #cbd5e1;
  line-height: 1.9;
  margin: 0 0 1.2rem;
}

.side-panel ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.side-panel li + li {
  margin-top: 0.75rem;
  padding-top: 0.75rem;
  border-top: 1px solid rgba(148, 163, 184, 0.12);
}

.side-panel a {
  color: #e2e8f0;
  font-weight: 700;
}

.side-panel p {
  color: #94a3b8;
  font-size: 0.85rem;
  line-height: 1.6;
  margin: 0.35rem 0 0;
}

.related-grid {
  max-width: 80rem;
  margin: 0 auto;
  padding: 0 1rem 4rem;
}

.ranking-list {
  display: grid;
  gap: 1rem;
}

.ranking-row {
  display: grid;
  grid-template-columns: 3.5rem 7rem minmax(0, 1fr) auto;
  gap: 1rem;
  align-items: center;
  padding: 0.85rem;
  border-radius: 1.1rem;
  background: rgba(17, 24, 39, 0.76);
  border: 1px solid rgba(148, 163, 184, 0.14);
}

.ranking-row strong {
  color: #ffffff;
  font-size: 1.5rem;
  text-align: center;
}

.ranking-row img {
  width: 7rem;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  border-radius: 0.75rem;
}

.ranking-row h3 {
  color: #ffffff;
  font-size: 1.1rem;
  font-weight: 900;
  margin: 0 0 0.35rem;
}

.ranking-row p {
  color: #94a3b8;
  margin: 0;
  line-height: 1.55;
}

.ranking-row .score {
  color: #38bdf8;
  font-weight: 900;
  padding-right: 0.5rem;
}

.sitemap-list {
  column-width: 18rem;
  column-gap: 2rem;
}

.sitemap-list a {
  display: block;
  break-inside: avoid;
  padding: 0.4rem 0;
  color: #cbd5e1;
}

.sitemap-list a:hover {
  color: #38bdf8;
}

.pagination {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.55rem;
  margin-top: 2rem;
}

.pagination-link {
  min-width: 2.4rem;
  height: 2.4rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  color: #cbd5e1;
  background: rgba(15, 23, 42, 0.82);
  border: 1px solid rgba(148, 163, 184, 0.16);
}

.pagination-link.active {
  color: #ffffff;
  background: linear-gradient(135deg, #2563eb, #06b6d4);
}

@media (max-width: 900px) {
  .hero-carousel,
  .hero-content {
    min-height: auto;
  }

  .hero-slide {
    position: relative;
    display: none;
  }

  .hero-slide.is-active {
    display: block;
  }

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

  .hero-content {
    gap: 2rem;
    padding-top: 6.5rem;
    padding-bottom: 6rem;
  }

  .hero-poster {
    min-height: auto;
  }

  .hero-poster img {
    min-height: auto;
    aspect-ratio: 16 / 10;
  }

  .filter-panel {
    grid-template-columns: 1fr;
  }

  .ranking-row {
    grid-template-columns: 2.4rem 5.2rem minmax(0, 1fr);
  }

  .ranking-row .score {
    grid-column: 3;
  }
}

@media (max-width: 640px) {
  .hero-copy h1 {
    font-size: 2.6rem;
  }

  .hero-actions,
  .section-heading {
    align-items: stretch;
    flex-direction: column;
  }

  .primary-button,
  .secondary-button,
  .section-link {
    width: 100%;
  }

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

  .movie-card-body {
    padding: 0.8rem;
  }

  .movie-card-desc {
    min-height: auto;
    -webkit-line-clamp: 2;
  }

  .category-collage {
    grid-template-columns: repeat(4, 1fr);
  }

  .page-hero {
    padding-top: 7.5rem;
  }
}
