:root {
  --sky-50: #f0f9ff;
  --sky-100: #e0f2fe;
  --sky-500: #0ea5e9;
  --sky-600: #0284c7;
  --emerald-50: #ecfdf5;
  --emerald-500: #10b981;
  --emerald-600: #059669;
  --amber-400: #fbbf24;
  --amber-500: #f59e0b;
  --neutral-50: #fafafa;
  --neutral-100: #f5f5f5;
  --neutral-200: #e5e5e5;
  --neutral-300: #d4d4d4;
  --neutral-500: #737373;
  --neutral-600: #525252;
  --neutral-700: #404040;
  --neutral-800: #262626;
  --neutral-900: #171717;
  --radius: 18px;
  --shadow: 0 20px 45px rgba(15, 23, 42, 0.10);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--neutral-900);
  background: var(--neutral-50);
  line-height: 1.65;
}

a {
  color: inherit;
  text-decoration: none;
}

img,
video {
  display: block;
  max-width: 100%;
}

button,
input {
  font: inherit;
}

.container-custom {
  width: min(100% - 32px, 1280px);
  margin: 0 auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(18px);
  border-bottom: 1px solid rgba(229, 229, 229, 0.75);
}

.nav-wrap {
  min-height: 76px;
  display: flex;
  align-items: center;
  gap: 24px;
}

.brand,
.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  letter-spacing: -0.03em;
}

.brand-text,
.footer-brand span:last-child {
  font-size: 22px;
  background: linear-gradient(90deg, var(--sky-600), var(--emerald-600));
  -webkit-background-clip: text;
  color: transparent;
}

.brand-mark {
  width: 36px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--sky-500), var(--emerald-500));
  color: #fff;
  box-shadow: 0 12px 28px rgba(14, 165, 233, 0.28);
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-left: auto;
}

.desktop-nav a,
.mobile-nav a {
  padding: 10px 14px;
  border-radius: 12px;
  font-size: 15px;
  font-weight: 650;
  color: var(--neutral-700);
  transition: all 0.22s ease;
}

.desktop-nav a:hover,
.desktop-nav a.is-active,
.mobile-nav a:hover {
  color: var(--sky-600);
  background: var(--sky-50);
}

.nav-search {
  display: flex;
  align-items: center;
  gap: 8px;
  border: 1px solid var(--neutral-200);
  background: #fff;
  padding: 6px;
  border-radius: 999px;
  box-shadow: 0 8px 26px rgba(15, 23, 42, 0.06);
}

.nav-search input {
  width: 210px;
  border: 0;
  outline: 0;
  padding: 8px 10px;
  background: transparent;
  color: var(--neutral-800);
}

.nav-search button,
.btn-primary,
.btn-secondary,
.btn-ghost {
  border: 0;
  border-radius: 999px;
  padding: 10px 18px;
  font-weight: 750;
  cursor: pointer;
  transition: all 0.22s ease;
}

.nav-search button,
.btn-primary {
  color: #fff;
  background: linear-gradient(135deg, var(--sky-500), var(--emerald-500));
  box-shadow: 0 14px 28px rgba(14, 165, 233, 0.25);
}

.nav-search button:hover,
.btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 18px 36px rgba(14, 165, 233, 0.30);
}

.btn-secondary {
  color: var(--neutral-900);
  background: #fff;
  border: 1px solid rgba(255, 255, 255, 0.55);
}

.btn-secondary:hover {
  background: var(--sky-50);
  color: var(--sky-600);
}

.btn-ghost {
  color: var(--neutral-700);
  background: var(--neutral-100);
}

.btn-ghost:hover {
  color: var(--sky-600);
  background: var(--sky-100);
}

.menu-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 14px;
  background: var(--neutral-100);
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 5px;
}

.menu-toggle span {
  width: 20px;
  height: 2px;
  background: var(--neutral-800);
  border-radius: 999px;
}

.mobile-nav {
  display: none;
  border-top: 1px solid var(--neutral-200);
}

.mobile-nav.is-open {
  display: block;
}

.mobile-nav-panel {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
  padding-top: 16px;
  padding-bottom: 16px;
}

.hero-slider {
  position: relative;
  overflow: hidden;
  min-height: 640px;
  background: var(--neutral-900);
}

.hero-slide {
  min-height: 640px;
  display: none;
  position: relative;
  isolation: isolate;
}

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

.hero-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(1.05);
  z-index: -3;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  z-index: -2;
  background:
    radial-gradient(circle at 75% 35%, rgba(14, 165, 233, 0.32), transparent 32%),
    linear-gradient(90deg, rgba(2, 6, 23, 0.94), rgba(15, 23, 42, 0.72) 48%, rgba(15, 23, 42, 0.34)),
    linear-gradient(0deg, rgba(2, 6, 23, 0.78), transparent 45%);
}

.hero-inner {
  min-height: 640px;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(280px, 0.55fr);
  align-items: center;
  gap: 56px;
  padding-top: 44px;
  padding-bottom: 44px;
}

.hero-copy {
  color: #fff;
  max-width: 780px;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 18px;
  padding: 8px 14px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.13);
  backdrop-filter: blur(12px);
  font-size: 14px;
  font-weight: 750;
}

.hero-copy h1,
.hero-copy h2 {
  margin: 0;
}

.hero-copy h1 {
  font-size: clamp(40px, 6vw, 76px);
  line-height: 1.02;
  letter-spacing: -0.06em;
}

.hero-copy h2 {
  margin-top: 14px;
  font-size: clamp(24px, 3vw, 42px);
  line-height: 1.16;
}

.hero-copy p {
  margin: 22px 0 0;
  max-width: 680px;
  color: rgba(255, 255, 255, 0.82);
  font-size: 18px;
}

.hero-tags,
.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.hero-tags {
  margin-top: 24px;
}

.hero-tags span,
.tag-row span,
.pill {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 6px 10px;
  font-size: 13px;
  font-weight: 700;
}

.hero-tags span {
  color: #fff;
  background: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.18);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 30px;
}

.hero-poster {
  justify-self: end;
  width: min(100%, 420px);
  border-radius: 28px;
  overflow: hidden;
  box-shadow: 0 32px 90px rgba(0, 0, 0, 0.45);
  transform: rotate(1.2deg);
  background: rgba(255, 255, 255, 0.08);
  padding: 10px;
  backdrop-filter: blur(12px);
}

.hero-poster img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: 22px;
}

.hero-dots {
  position: absolute;
  left: 50%;
  bottom: 30px;
  transform: translateX(-50%);
  display: flex;
  gap: 10px;
  z-index: 5;
}

.hero-dot {
  width: 34px;
  height: 8px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.35);
  cursor: pointer;
  transition: all 0.22s ease;
}

.hero-dot.is-active {
  width: 52px;
  background: #fff;
}

.section-spacing {
  padding: 72px 0;
}

.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 28px;
}

.section-head h1,
.section-head h2,
.page-hero h1,
.detail-title h1 {
  margin: 0;
  line-height: 1.12;
  letter-spacing: -0.04em;
}

.section-head h1,
.page-hero h1 {
  font-size: clamp(34px, 4vw, 56px);
}

.section-head h2 {
  font-size: clamp(28px, 3vw, 42px);
}

.section-head p,
.page-hero p {
  margin: 10px 0 0;
  color: var(--neutral-600);
  max-width: 680px;
}

.light-section {
  background: #fff;
}

.tint-section {
  background: linear-gradient(135deg, var(--sky-50), var(--emerald-50));
}

.dark-section {
  background: var(--neutral-900);
  color: #fff;
}

.dark-section .section-head p {
  color: var(--neutral-300);
}

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

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

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

.card {
  background: #fff;
  border-radius: var(--radius);
  border: 1px solid rgba(229, 229, 229, 0.82);
  overflow: hidden;
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.06);
}

.card-hover {
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.card-hover:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow);
  border-color: rgba(14, 165, 233, 0.30);
}

.movie-cover {
  position: relative;
  display: block;
  overflow: hidden;
  background: var(--neutral-900);
  aspect-ratio: 16 / 9;
}

.movie-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.55s ease;
}

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

.play-badge {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%) scale(0.88);
  width: 58px;
  height: 58px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  color: var(--sky-600);
  background: rgba(255, 255, 255, 0.92);
  opacity: 0;
  transition: all 0.25s ease;
  backdrop-filter: blur(10px);
}

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

.duration-badge {
  position: absolute;
  right: 12px;
  bottom: 12px;
  padding: 4px 8px;
  color: #fff;
  background: rgba(0, 0, 0, 0.68);
  border-radius: 999px;
  font-size: 12px;
}

.movie-card-body {
  padding: 18px;
}

.movie-meta-line {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-bottom: 10px;
  color: var(--neutral-500);
  font-size: 13px;
}

.movie-meta-line a {
  color: var(--sky-600);
  font-weight: 750;
  background: var(--sky-50);
  border-radius: 999px;
  padding: 4px 9px;
}

.movie-card h2,
.rank-row h2 {
  margin: 0;
  font-size: 18px;
  line-height: 1.35;
}

.movie-card h2 a:hover,
.rank-row h2 a:hover {
  color: var(--sky-600);
}

.movie-card p,
.rank-row p {
  color: var(--neutral-600);
  margin: 10px 0 14px;
  font-size: 14px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.tag-row span {
  color: var(--neutral-700);
  background: var(--neutral-100);
}

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

.category-card {
  position: relative;
  min-height: 180px;
  padding: 22px;
  border-radius: 22px;
  overflow: hidden;
  background: linear-gradient(135deg, #fff, var(--sky-50));
  border: 1px solid rgba(229, 229, 229, 0.78);
  box-shadow: 0 16px 36px rgba(15, 23, 42, 0.06);
  transition: all 0.24s ease;
}

.category-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow);
}

.category-card h2,
.category-card h3 {
  margin: 0 0 8px;
  font-size: 22px;
  letter-spacing: -0.03em;
}

.category-card p {
  margin: 0;
  color: var(--neutral-600);
  font-size: 14px;
}

.category-card span {
  position: absolute;
  right: 18px;
  bottom: 14px;
  color: var(--sky-600);
  font-weight: 800;
}

.page-hero {
  padding: 72px 0;
  background:
    radial-gradient(circle at 20% 20%, rgba(14, 165, 233, 0.18), transparent 30%),
    linear-gradient(135deg, #fff, var(--sky-50) 52%, var(--emerald-50));
  border-bottom: 1px solid var(--neutral-200);
}

.filter-panel {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  margin-bottom: 28px;
  padding: 16px;
  border-radius: 20px;
  background: #fff;
  border: 1px solid var(--neutral-200);
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.05);
}

.filter-panel input,
.filter-panel select {
  min-width: 220px;
  border: 1px solid var(--neutral-200);
  border-radius: 999px;
  padding: 11px 14px;
  outline: none;
  background: var(--neutral-50);
  color: var(--neutral-800);
}

.filter-panel input:focus,
.filter-panel select:focus {
  border-color: var(--sky-500);
  box-shadow: 0 0 0 4px rgba(14, 165, 233, 0.12);
}

.no-results {
  display: none;
  padding: 30px;
  border: 1px dashed var(--neutral-300);
  border-radius: 20px;
  text-align: center;
  color: var(--neutral-600);
  background: #fff;
}

.no-results.is-visible {
  display: block;
}

.rank-list {
  display: grid;
  gap: 14px;
}

.rank-row {
  display: grid;
  grid-template-columns: 56px 112px minmax(0, 1fr) 78px;
  align-items: center;
  gap: 18px;
  padding: 14px;
  background: #fff;
  border: 1px solid var(--neutral-200);
  border-radius: 20px;
  box-shadow: 0 10px 26px rgba(15, 23, 42, 0.05);
}

.rank-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 14px;
  color: #fff;
  font-weight: 850;
  background: linear-gradient(135deg, var(--sky-500), var(--emerald-500));
}

.rank-thumb {
  overflow: hidden;
  border-radius: 14px;
  aspect-ratio: 16 / 10;
  background: var(--neutral-900);
}

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

.rank-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: var(--neutral-500);
  font-size: 13px;
}

.rank-score {
  justify-self: end;
  padding: 8px 12px;
  border-radius: 999px;
  color: #92400e;
  background: #fef3c7;
  font-weight: 850;
}

.detail-wrap {
  padding: 40px 0 76px;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-bottom: 22px;
  color: var(--neutral-600);
  font-size: 14px;
}

.breadcrumb a:hover {
  color: var(--sky-600);
}

.detail-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 34px;
  align-items: start;
}

.player-shell {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16 / 9;
  border-radius: 24px;
  background: #000;
  box-shadow: 0 26px 80px rgba(0, 0, 0, 0.22);
}

.player-shell video {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #000;
  cursor: pointer;
}

.player-poster-layer,
.player-loading,
.player-message {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.player-poster-layer {
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.55), rgba(0, 0, 0, 0.18));
  transition: opacity 0.22s ease, visibility 0.22s ease;
}

.player-shell.is-started .player-poster-layer {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.player-play {
  width: 86px;
  height: 86px;
  border: 0;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--sky-600);
  background: rgba(255, 255, 255, 0.92);
  cursor: pointer;
  transition: all 0.22s ease;
}

.player-play:hover {
  transform: scale(1.08);
  background: #fff;
}

.player-loading,
.player-message {
  color: #fff;
  background: rgba(0, 0, 0, 0.62);
}

.player-loading {
  display: none;
}

.player-shell.is-loading .player-loading {
  display: flex;
}

.player-shell.is-started .player-loading {
  display: none;
}

.player-message {
  display: none;
  padding: 24px;
}

.player-message.is-visible {
  display: flex;
}

.detail-panel,
.info-card {
  background: #fff;
  border: 1px solid var(--neutral-200);
  border-radius: 24px;
  box-shadow: 0 16px 38px rgba(15, 23, 42, 0.06);
}

.detail-panel {
  margin-top: 24px;
  padding: 28px;
}

.detail-title h1 {
  font-size: clamp(32px, 4vw, 54px);
}

.detail-title p {
  margin: 14px 0 0;
  color: var(--neutral-600);
  font-size: 18px;
}

.meta-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 22px 0;
}

.meta-strip span {
  padding: 7px 11px;
  border-radius: 999px;
  color: var(--neutral-700);
  background: var(--neutral-100);
  font-weight: 700;
  font-size: 13px;
}

.content-block {
  margin-top: 26px;
}

.content-block h2 {
  margin: 0 0 12px;
  font-size: 24px;
  letter-spacing: -0.03em;
}

.content-block p {
  margin: 0;
  color: var(--neutral-700);
}

.info-card {
  padding: 18px;
  position: sticky;
  top: 100px;
}

.info-card img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: 18px;
  background: var(--neutral-900);
}

.info-list {
  display: grid;
  gap: 10px;
  margin-top: 18px;
}

.info-list div {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--neutral-100);
  color: var(--neutral-600);
}

.info-list strong {
  color: var(--neutral-900);
  text-align: right;
}

.related-section {
  margin-top: 48px;
}

.site-footer {
  color: var(--neutral-300);
  background: var(--neutral-900);
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 42px;
  padding: 56px 0 36px;
}

.footer-about p {
  max-width: 520px;
  color: var(--neutral-400);
}

.site-footer h2 {
  margin: 0 0 14px;
  color: #fff;
  font-size: 16px;
}

.site-footer a {
  display: block;
  margin: 8px 0;
  color: var(--neutral-400);
}

.site-footer a:hover {
  color: var(--sky-500);
}

.footer-bottom {
  padding: 22px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  color: var(--neutral-500);
}

[data-movie-card].is-hidden {
  display: none;
}

@media (max-width: 1120px) {
  .movie-grid,
  .category-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

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

  .info-card {
    position: static;
  }
}

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

  .menu-toggle {
    display: inline-flex;
    margin-left: auto;
  }

  .hero-inner {
    grid-template-columns: 1fr;
    gap: 28px;
  }

  .hero-poster {
    justify-self: start;
    width: min(100%, 310px);
  }

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

  .footer-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .container-custom {
    width: min(100% - 24px, 1280px);
  }

  .brand-text {
    font-size: 18px;
  }

  .hero-slider,
  .hero-slide,
  .hero-inner {
    min-height: 720px;
  }

  .hero-copy p {
    font-size: 16px;
  }

  .section-spacing,
  .page-hero {
    padding: 48px 0;
  }

  .section-head {
    display: block;
  }

  .movie-grid,
  .movie-grid.three,
  .movie-grid.two,
  .category-grid {
    grid-template-columns: 1fr;
  }

  .rank-row {
    grid-template-columns: 44px 80px 1fr;
  }

  .rank-score {
    grid-column: 3;
    justify-self: start;
  }

  .detail-panel {
    padding: 20px;
  }
}
