:root {
  --bg: #0f172a;
  --bg-deep: #020617;
  --panel: rgba(255, 255, 255, 0.055);
  --panel-strong: rgba(255, 255, 255, 0.095);
  --line: rgba(255, 255, 255, 0.13);
  --text: #ffffff;
  --muted: #cbd5e1;
  --soft: #94a3b8;
  --gold: #facc15;
  --gold-dark: #eab308;
  --purple: #581c87;
  --pink: #be185d;
  --radius: 18px;
  --shadow: 0 24px 70px rgba(0, 0, 0, 0.35);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--text);
  background:
    radial-gradient(circle at top left, rgba(147, 51, 234, 0.22), transparent 34rem),
    linear-gradient(180deg, #0f172a 0%, #111827 45%, #020617 100%);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
  line-height: 1.6;
}

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

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

button,
input,
select {
  font: inherit;
}

button {
  border: 0;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(15, 23, 42, 0.82);
  backdrop-filter: blur(18px);
  border-bottom: 1px solid var(--line);
}

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

.brand,
.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: #ffffff;
}

.brand-mark {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  color: #111827;
  background: linear-gradient(135deg, var(--gold), #fde68a);
  border-radius: 14px;
  box-shadow: 0 12px 30px rgba(250, 204, 21, 0.25);
}

.brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
}

.brand-text strong,
.footer-brand {
  font-size: 20px;
  font-weight: 800;
  letter-spacing: 0.02em;
  background: linear-gradient(90deg, #facc15, #fff7ad);
  color: transparent;
  -webkit-background-clip: text;
  background-clip: text;
}

.brand-text small {
  color: var(--muted);
  font-size: 12px;
}

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

.nav-link {
  color: #e2e8f0;
  transition: color 0.2s ease, transform 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
  color: var(--gold);
}

.nav-link:hover {
  transform: translateY(-1px);
}

.nav-search,
.mobile-search,
.search-panel form {
  display: flex;
  align-items: center;
  gap: 8px;
}

.nav-search input,
.mobile-search input,
.search-panel input,
.filter-panel input,
.filter-panel select {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 999px;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.nav-search input {
  width: 190px;
  padding: 9px 14px;
}

.nav-search input:focus,
.mobile-search input:focus,
.search-panel input:focus,
.filter-panel input:focus,
.filter-panel select:focus {
  border-color: var(--gold);
  box-shadow: 0 0 0 4px rgba(250, 204, 21, 0.15);
  background: rgba(255, 255, 255, 0.12);
}

.nav-search button,
.mobile-search button,
.search-panel button {
  color: #111827;
  background: var(--gold);
  border-radius: 999px;
  padding: 9px 16px;
  cursor: pointer;
  font-weight: 700;
}

.menu-toggle {
  display: none;
  margin-left: auto;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  padding: 9px 12px;
}

.mobile-panel {
  display: none;
  border-top: 1px solid var(--line);
  padding: 14px 16px 18px;
  background: rgba(15, 23, 42, 0.96);
}

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

.mobile-panel nav {
  display: grid;
  gap: 10px;
  margin-bottom: 12px;
}

.mobile-search input {
  flex: 1;
  min-width: 0;
  padding: 10px 14px;
}

.hero-slider {
  position: relative;
  height: 72vh;
  min-height: 560px;
  overflow: hidden;
  background: #020617;
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transform: scale(1.02);
  transition: opacity 0.65s ease, transform 0.65s ease;
  pointer-events: none;
}

.hero-slide.is-active {
  opacity: 1;
  transform: scale(1);
  pointer-events: auto;
}

.hero-image,
.detail-bg {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-mask,
.detail-mask {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(15, 23, 42, 0.96) 0%, rgba(15, 23, 42, 0.62) 45%, rgba(15, 23, 42, 0.78) 100%),
    linear-gradient(0deg, rgba(15, 23, 42, 1) 0%, transparent 44%);
}

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

.hero-copy {
  width: min(700px, 100%);
  padding-top: 40px;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 16px;
  color: var(--gold);
  font-weight: 800;
  letter-spacing: 0.08em;
}

.hero-copy h1,
.page-hero h1,
.detail-copy h1 {
  margin: 0;
  font-size: clamp(40px, 8vw, 78px);
  line-height: 1.02;
  letter-spacing: -0.04em;
}

.hero-copy p,
.page-hero p,
.detail-copy p {
  color: #e2e8f0;
  font-size: 19px;
  max-width: 720px;
}

.hero-tags,
.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 24px 0;
}

.hero-tags span,
.detail-meta span,
.corner-chip,
.rank-no {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 6px 12px;
  font-size: 13px;
  font-weight: 700;
}

.hero-tags span,
.detail-meta span {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.11);
  border: 1px solid rgba(255, 255, 255, 0.16);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px;
}

.btn-primary,
.btn-ghost,
.btn-link,
.text-link,
.section-more {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.2s ease, background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.btn-primary {
  color: #111827;
  background: linear-gradient(90deg, var(--gold), var(--gold-dark));
  border-radius: 999px;
  padding: 14px 26px;
  font-weight: 900;
  box-shadow: 0 16px 40px rgba(250, 204, 21, 0.25);
}

.btn-primary:hover,
.btn-ghost:hover,
.category-tile:hover,
.movie-card:hover,
.movie-row:hover,
.category-card-wide:hover {
  transform: translateY(-3px);
}

.btn-ghost {
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 999px;
  padding: 13px 24px;
  background: rgba(255, 255, 255, 0.08);
}

.btn-ghost:hover {
  border-color: var(--gold);
}

.btn-link,
.text-link,
.section-more {
  color: var(--gold);
  font-weight: 800;
}

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

.hero-dot {
  width: 12px;
  height: 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.52);
  cursor: pointer;
  transition: width 0.2s ease, background 0.2s ease;
}

.hero-dot.is-active {
  width: 34px;
  background: var(--gold);
}

.hero-rail {
  position: relative;
  margin-top: -66px;
  z-index: 5;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 14px;
}

.hero-thumb,
.category-tile,
.movie-card,
.movie-row,
.category-card-wide,
.side-card,
.detail-article,
.filter-panel,
.search-panel,
.callout {
  background: var(--panel);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  backdrop-filter: blur(14px);
}

.hero-thumb {
  min-height: 116px;
  overflow: hidden;
  position: relative;
  border-radius: 18px;
}

.hero-thumb img {
  width: 100%;
  height: 116px;
  object-fit: cover;
  filter: brightness(0.78);
}

.hero-thumb span {
  position: absolute;
  left: 12px;
  right: 12px;
  bottom: 10px;
  font-weight: 800;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.65);
}

.content-section,
.page-shell {
  padding-top: 76px;
}

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

.section-head h2 {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0;
  font-size: clamp(26px, 4vw, 38px);
  line-height: 1.2;
}

.section-head h2 span {
  color: var(--gold);
}

.section-head p {
  margin: 8px 0 0;
  color: var(--muted);
}

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

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

.movie-card {
  display: block;
  overflow: hidden;
  border-radius: 18px;
  transition: transform 0.22s ease, border-color 0.22s ease, background 0.22s ease;
}

.movie-card:hover {
  border-color: rgba(250, 204, 21, 0.42);
  background: var(--panel-strong);
}

.poster-wrap {
  position: relative;
  display: block;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  background: #111827;
}

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

.movie-card:hover .poster-wrap img,
.category-tile:hover img,
.category-card-wide:hover img,
.hero-thumb:hover img {
  transform: scale(1.08);
}

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

.card-play,
.play-circle {
  display: grid;
  place-items: center;
  border-radius: 999px;
  color: #111827;
  background: var(--gold);
}

.card-play {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 58px;
  height: 58px;
  opacity: 0;
  transform: translate(-50%, -50%) scale(0.86);
  transition: opacity 0.25s ease, transform 0.25s ease;
}

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

.corner-chip {
  position: absolute;
  top: 12px;
  background: rgba(0, 0, 0, 0.62);
  color: #ffffff;
}

.corner-chip.left {
  left: 12px;
}

.corner-chip.right {
  right: 12px;
  color: #111827;
  background: rgba(250, 204, 21, 0.94);
}

.rank-no {
  position: absolute;
  left: 12px;
  bottom: 12px;
  color: #111827;
  background: var(--gold);
  font-size: 18px;
}

.card-body {
  display: grid;
  gap: 7px;
  padding: 15px;
}

.card-body strong,
.row-content strong {
  font-size: 17px;
  line-height: 1.35;
}

.card-body em,
.row-content em,
.card-meta,
.tag-line {
  color: var(--muted);
  font-style: normal;
  font-size: 13px;
}

.card-body em,
.row-content em {
  display: -webkit-box;
  overflow: hidden;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.tag-line {
  color: var(--gold);
}

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

.category-tile {
  position: relative;
  min-height: 210px;
  overflow: hidden;
  border-radius: 20px;
  padding: 24px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  transition: transform 0.22s ease, border-color 0.22s ease;
}

.category-tile img,
.category-tile span,
.category-cover img,
.category-cover span {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.category-tile img,
.category-cover img {
  object-fit: cover;
  transition: transform 0.5s ease;
}

.category-tile span,
.category-cover span {
  background:
    linear-gradient(145deg, rgba(88, 28, 135, 0.84), rgba(190, 24, 93, 0.72)),
    linear-gradient(0deg, rgba(0, 0, 0, 0.66), transparent);
}

.category-tile strong,
.category-tile em {
  position: relative;
  z-index: 1;
}

.category-tile strong {
  font-size: 24px;
  margin-bottom: 8px;
}

.category-tile em {
  color: #e2e8f0;
  font-style: normal;
  font-size: 14px;
}

.two-col-section {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 32px;
}

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

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

.movie-row {
  display: flex;
  gap: 14px;
  overflow: hidden;
  border-radius: 16px;
  padding: 10px;
  transition: transform 0.22s ease, background 0.22s ease, border-color 0.22s ease;
}

.movie-row:hover {
  border-color: rgba(250, 204, 21, 0.32);
  background: var(--panel-strong);
}

.row-poster {
  flex: 0 0 128px;
  height: 82px;
  overflow: hidden;
  border-radius: 12px;
  background: #111827;
}

.row-poster img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.row-content {
  min-width: 0;
  display: grid;
  align-content: center;
  gap: 3px;
}

.row-content span {
  color: var(--soft);
  font-size: 12px;
}

.tag-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.tag-cloud a,
.tag-box a {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 10px 16px;
  transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.tag-cloud a:hover,
.tag-box a:hover {
  color: #111827;
  background: var(--gold);
  transform: translateY(-2px);
}

.callout {
  margin: 82px auto 0;
  text-align: center;
  border-radius: 28px;
  padding: 56px 24px;
  background: linear-gradient(90deg, rgba(88, 28, 135, 0.6), rgba(190, 24, 93, 0.42));
}

.callout h2 {
  margin: 0 0 12px;
  font-size: clamp(28px, 5vw, 46px);
}

.callout p {
  max-width: 760px;
  margin: 0 auto 26px;
  color: var(--muted);
}

.page-shell {
  min-height: 60vh;
}

.compact-hero {
  position: relative;
  overflow: hidden;
  border-radius: 28px;
  padding: 60px;
  margin-bottom: 34px;
  background:
    radial-gradient(circle at top right, rgba(250, 204, 21, 0.18), transparent 20rem),
    linear-gradient(135deg, rgba(88, 28, 135, 0.64), rgba(15, 23, 42, 0.92));
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
}

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

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

.category-list-wide {
  display: grid;
  gap: 22px;
}

.category-card-wide {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 24px;
  border-radius: 22px;
  padding: 18px;
  transition: transform 0.22s ease, border-color 0.22s ease;
}

.category-card-wide:hover {
  border-color: rgba(250, 204, 21, 0.34);
}

.category-cover {
  position: relative;
  min-height: 190px;
  overflow: hidden;
  border-radius: 18px;
}

.category-card-wide h2 {
  margin: 2px 0 8px;
  font-size: 28px;
}

.category-card-wide p {
  color: var(--muted);
}

.category-card-wide ul {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 0;
  margin: 18px 0;
  list-style: none;
}

.category-card-wide li a {
  display: inline-flex;
  padding: 7px 11px;
  border-radius: 999px;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.07);
}

.category-card-wide li a:hover {
  color: var(--gold);
}

.filter-panel,
.search-panel {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 14px;
  border-radius: 20px;
  padding: 18px;
  margin-bottom: 30px;
}

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

.search-panel form {
  width: 100%;
}

.search-panel input {
  flex: 1;
  padding: 14px 18px;
}

.search-panel p {
  color: var(--muted);
  margin: 0;
}

.filter-panel input,
.filter-panel select {
  width: 100%;
  padding: 12px 14px;
}

.filter-panel select option {
  color: #111827;
}

.empty-state {
  display: none;
  text-align: center;
  color: var(--muted);
  padding: 42px 0;
}

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

.detail-hero {
  position: relative;
  min-height: 620px;
  overflow: hidden;
  background: #020617;
}

.detail-bg,
.detail-mask {
  position: absolute;
  inset: 0;
}

.detail-hero-inner {
  position: relative;
  min-height: 620px;
  display: grid;
  grid-template-columns: 320px 1fr;
  gap: 42px;
  align-items: center;
  padding-top: 42px;
  z-index: 1;
}

.detail-poster {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: 24px;
  box-shadow: var(--shadow);
  border: 1px solid rgba(255, 255, 255, 0.18);
}

.detail-copy p {
  margin: 18px 0 0;
}

.player-section {
  margin-top: -76px;
  position: relative;
  z-index: 2;
}

.player-box {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16 / 9;
  border-radius: 26px;
  background: #000000;
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
}

.player-box video {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #000000;
}

.player-start {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  color: #ffffff;
  background: radial-gradient(circle, rgba(0, 0, 0, 0.18), rgba(0, 0, 0, 0.68));
  cursor: pointer;
  z-index: 3;
}

.player-start.is-hidden {
  display: none;
}

.play-circle {
  width: 88px;
  height: 88px;
  font-size: 36px;
  padding-left: 5px;
  box-shadow: 0 18px 42px rgba(250, 204, 21, 0.35);
}

.player-start strong {
  font-size: 24px;
}

.detail-layout {
  display: grid;
  grid-template-columns: 1fr 330px;
  gap: 28px;
  margin-top: 42px;
}

.detail-article,
.side-card {
  border-radius: 24px;
  padding: 28px;
}

.detail-article h2,
.side-card h2 {
  margin: 0 0 14px;
  font-size: 26px;
}

.detail-article p,
.side-card p {
  color: var(--muted);
  margin: 0 0 20px;
}

.detail-side {
  display: grid;
  gap: 18px;
  align-content: start;
}

.tag-box div {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

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

.site-footer {
  margin-top: 88px;
  padding: 56px 0 28px;
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.35), #020617);
  border-top: 1px solid var(--line);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.6fr 1fr 1fr;
  gap: 32px;
}

.site-footer p,
.site-footer a {
  color: var(--muted);
}

.site-footer h2 {
  margin: 0 0 14px;
  font-size: 18px;
}

.site-footer a {
  display: table;
  margin-bottom: 8px;
}

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

.footer-bottom {
  margin-top: 36px;
  padding-top: 22px;
  color: var(--soft);
  border-top: 1px solid var(--line);
  font-size: 14px;
}

.back-top {
  position: fixed;
  right: 22px;
  bottom: 22px;
  width: 46px;
  height: 46px;
  display: none;
  color: #111827;
  background: var(--gold);
  border-radius: 999px;
  cursor: pointer;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.3);
  z-index: 40;
}

.back-top.is-visible {
  display: block;
}

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

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

  .hero-rail {
    grid-template-columns: repeat(3, 1fr);
  }

  .hero-thumb:nth-child(n + 4) {
    display: none;
  }
}

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

  .menu-toggle {
    display: block;
  }

  .nav-wrap {
    min-height: 64px;
  }

  .hero-slider {
    min-height: 620px;
    height: 76vh;
  }

  .hero-rail,
  .two-col-section,
  .detail-layout,
  .footer-grid,
  .category-card-wide,
  .detail-hero-inner {
    grid-template-columns: 1fr;
  }

  .detail-poster {
    width: min(260px, 70vw);
  }

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

  .compact-hero {
    padding: 36px 24px;
  }

  .related-list {
    grid-template-columns: 1fr;
  }
}

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

  .brand-text strong {
    font-size: 17px;
  }

  .hero-copy h1,
  .page-hero h1,
  .detail-copy h1 {
    font-size: 38px;
  }

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

  .hero-rail {
    display: none;
  }

  .content-section,
  .page-shell {
    padding-top: 52px;
  }

  .movie-grid,
  .catalogue-grid,
  .rank-grid,
  .category-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
  }

  .card-body {
    padding: 12px;
  }

  .card-body strong,
  .row-content strong {
    font-size: 15px;
  }

  .row-poster {
    flex-basis: 104px;
    height: 74px;
  }

  .category-tile {
    min-height: 170px;
    padding: 18px;
  }

  .category-tile strong {
    font-size: 20px;
  }

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

  .player-section {
    margin-top: -40px;
  }

  .player-box {
    border-radius: 18px;
  }

  .detail-article,
  .side-card {
    padding: 22px;
  }
}

@media (max-width: 420px) {
  .movie-grid,
  .catalogue-grid,
  .rank-grid,
  .category-grid {
    grid-template-columns: 1fr;
  }
}
