:root {
  --bg: #020617;
  --bg-soft: #0f172a;
  --panel: rgba(255, 255, 255, 0.06);
  --panel-strong: rgba(255, 255, 255, 0.10);
  --text: #f8fafc;
  --muted: #cbd5e1;
  --dim: #94a3b8;
  --line: rgba(255, 255, 255, 0.12);
  --gold: #facc15;
  --gold-dark: #ca8a04;
  --purple: #581c87;
  --pink: #be185d;
  --radius: 22px;
  --shadow: 0 24px 70px rgba(0, 0, 0, 0.45);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--text);
  background:
    radial-gradient(circle at 16% 0%, rgba(250, 204, 21, 0.16), transparent 34rem),
    radial-gradient(circle at 80% 12%, rgba(190, 24, 93, 0.22), transparent 38rem),
    linear-gradient(180deg, #0f172a 0%, #020617 58%, #000000 100%);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", Arial, sans-serif;
  line-height: 1.6;
}

body.no-scroll {
  overflow: hidden;
}

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

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

button,
input {
  font: inherit;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: linear-gradient(90deg, rgba(15, 23, 42, 0.96), rgba(88, 28, 135, 0.92), rgba(15, 23, 42, 0.96));
  border-bottom: 1px solid rgba(255, 255, 255, 0.10);
  box-shadow: 0 10px 35px rgba(0, 0, 0, 0.35);
  backdrop-filter: blur(18px);
}

.header-inner {
  width: min(1180px, calc(100% - 32px));
  min-height: 74px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 24px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}

.brand-mark,
.footer-logo span {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  color: #111827;
  background: linear-gradient(135deg, #fde047, #f59e0b);
  box-shadow: 0 12px 28px rgba(250, 204, 21, 0.25);
}

.brand-text {
  display: grid;
  line-height: 1.12;
}

.brand-name {
  font-size: 21px;
  font-weight: 900;
  letter-spacing: 0.02em;
  background: linear-gradient(90deg, #fde047, #fff7b2);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

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

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

.nav-link {
  color: var(--muted);
  font-weight: 700;
  transition: color 0.2s ease, transform 0.2s ease;
}

.nav-link:hover,
.nav-link.is-active {
  color: var(--gold);
  transform: translateY(-1px);
}

.site-search {
  display: flex;
  align-items: center;
  gap: 8px;
}

.site-search input,
.filter-bar input,
.large-search input {
  width: 210px;
  color: var(--text);
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 999px;
  padding: 11px 16px;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.site-search input:focus,
.filter-bar input:focus,
.large-search input:focus {
  border-color: rgba(250, 204, 21, 0.85);
  box-shadow: 0 0 0 4px rgba(250, 204, 21, 0.14);
  background: rgba(255, 255, 255, 0.12);
}

.site-search button,
.large-search button {
  border: 0;
  color: #111827;
  background: linear-gradient(135deg, #facc15, #f59e0b);
  border-radius: 999px;
  padding: 11px 18px;
  font-weight: 900;
  cursor: pointer;
  box-shadow: 0 10px 28px rgba(250, 204, 21, 0.18);
}

.menu-toggle {
  display: none;
  margin-left: auto;
  border: 0;
  color: var(--text);
  background: rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  padding: 9px 12px;
  cursor: pointer;
}

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

.hero-slide {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(260px, 420px);
  align-items: center;
  gap: 56px;
  padding: 92px max(32px, calc((100vw - 1180px) / 2)) 110px;
  background-size: cover;
  background-position: center;
  opacity: 0;
  pointer-events: none;
  transform: scale(1.02);
  transition: opacity 0.6s ease, transform 0.8s ease;
}

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

.hero-content {
  max-width: 720px;
  position: relative;
  z-index: 2;
}

.eyebrow,
.section-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--gold);
  font-size: 13px;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.hero-content h1 {
  margin: 18px 0 18px;
  max-width: 800px;
  font-size: clamp(42px, 7vw, 82px);
  line-height: 0.98;
  letter-spacing: -0.06em;
}

.hero-summary {
  max-width: 700px;
  color: #e2e8f0;
  font-size: 18px;
}

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

.hero-tags span,
.detail-tags a,
.tag-row span {
  color: #111827;
  background: rgba(250, 204, 21, 0.95);
  border-radius: 999px;
  padding: 7px 12px;
  font-size: 12px;
  font-weight: 900;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 34px;
}

.primary-button,
.ghost-button,
.section-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: 999px;
  font-weight: 900;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease, color 0.2s ease;
}

.primary-button {
  color: #111827;
  background: linear-gradient(135deg, #fde047, #f59e0b);
  padding: 14px 24px;
  box-shadow: 0 14px 34px rgba(250, 204, 21, 0.25);
}

.ghost-button,
.section-link {
  color: var(--text);
  background: rgba(255, 255, 255, 0.10);
  border: 1px solid rgba(255, 255, 255, 0.14);
  padding: 12px 20px;
}

.primary-button:hover,
.ghost-button:hover,
.section-link:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 38px rgba(0, 0, 0, 0.26);
}

.ghost-button:hover,
.section-link:hover {
  color: var(--gold);
  background: rgba(255, 255, 255, 0.14);
}

.hero-poster {
  position: relative;
  isolation: isolate;
  display: block;
  border-radius: 30px;
  overflow: hidden;
  box-shadow: var(--shadow);
  border: 1px solid rgba(255, 255, 255, 0.16);
}

.hero-poster::before {
  content: "";
  position: absolute;
  inset: -1px;
  z-index: 1;
  background: linear-gradient(180deg, transparent 20%, rgba(0, 0, 0, 0.50));
}

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

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

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

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

.section {
  margin: 76px auto;
}

.page-main {
  padding: 48px 0 24px;
}

.section-heading {
  margin-bottom: 28px;
}

.section-heading.row,
.category-overview-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 20px;
}

.section-heading h2,
.page-hero h1,
.content-card h2,
.footer-links h2 {
  margin: 6px 0 0;
  line-height: 1.15;
}

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

.section-heading p,
.page-hero p,
.category-overview-head p,
.cta-panel p {
  color: var(--muted);
  max-width: 760px;
}

.intro-section {
  margin-top: 44px;
}

.section-heading.wide {
  padding: 34px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.scroll-row {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(300px, 360px);
  gap: 22px;
  overflow-x: auto;
  padding-bottom: 12px;
  scrollbar-width: thin;
}

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

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

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

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

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

.card-link {
  display: block;
  height: 100%;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.055);
  border: 1px solid rgba(255, 255, 255, 0.10);
  border-radius: 20px;
  box-shadow: 0 20px 55px rgba(0, 0, 0, 0.22);
  transition: transform 0.22s ease, border-color 0.22s ease, background 0.22s ease;
}

.card-link:hover {
  transform: translateY(-7px);
  border-color: rgba(250, 204, 21, 0.55);
  background: rgba(255, 255, 255, 0.085);
}

.card-image-wrap {
  position: relative;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  background: #111827;
}

.movie-card.large .card-image-wrap {
  aspect-ratio: 16 / 9;
}

.movie-card.mini .card-body p,
.movie-card.mini .tag-row {
  display: none;
}

.card-image-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.45s ease, filter 0.45s ease;
}

.card-link:hover img {
  transform: scale(1.08);
  filter: saturate(1.12);
}

.card-image-wrap::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 34%, rgba(0, 0, 0, 0.66));
}

.play-badge {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 2;
  width: 56px;
  height: 56px;
  display: grid;
  place-items: center;
  color: #111827;
  background: rgba(250, 204, 21, 0.95);
  border-radius: 50%;
  opacity: 0;
  transform: translate(-50%, -50%) scale(0.82);
  transition: opacity 0.2s ease, transform 0.2s ease;
}

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

.card-category {
  position: absolute;
  left: 12px;
  bottom: 12px;
  z-index: 2;
  color: #111827;
  background: rgba(250, 204, 21, 0.95);
  border-radius: 999px;
  padding: 5px 10px;
  font-size: 12px;
  font-weight: 900;
}

.card-body {
  padding: 16px;
}

.card-body h3 {
  margin: 0 0 8px;
  font-size: 17px;
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.card-body p {
  min-height: 48px;
  margin: 0 0 12px;
  color: var(--muted);
  font-size: 14px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.card-meta,
.rank-meta,
.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: var(--dim);
  font-size: 13px;
}

.card-meta span,
.rank-meta span,
.detail-meta span {
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  padding: 4px 8px;
}

.tag-row {
  margin-top: 12px;
  gap: 6px;
}

.tag-row span {
  padding: 4px 8px;
  font-size: 11px;
}

.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: 24px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: var(--shadow);
  background: var(--panel);
}

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

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

.tile-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(88, 28, 135, 0.86), rgba(190, 24, 93, 0.62), rgba(2, 6, 23, 0.88));
}

.tile-content {
  position: absolute;
  inset: auto 18px 18px 18px;
  display: grid;
  gap: 8px;
}

.tile-content strong {
  font-size: 24px;
}

.tile-content em {
  color: var(--muted);
  font-style: normal;
  font-size: 14px;
}

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

.ranking-panel {
  position: sticky;
  top: 98px;
  padding: 24px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

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

.rank-card a {
  display: grid;
  grid-template-columns: auto 78px minmax(0, 1fr);
  gap: 14px;
  align-items: center;
  padding: 12px;
  background: rgba(255, 255, 255, 0.055);
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 18px;
  transition: transform 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

.rank-card a:hover {
  transform: translateY(-3px);
  border-color: rgba(250, 204, 21, 0.45);
  background: rgba(255, 255, 255, 0.08);
}

.rank-number {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  color: #111827;
  background: linear-gradient(135deg, #fde047, #f59e0b);
  border-radius: 13px;
  font-weight: 900;
}

.rank-card img {
  width: 78px;
  height: 104px;
  border-radius: 12px;
  object-fit: cover;
}

.rank-card h3 {
  margin: 0 0 6px;
  font-size: 16px;
}

.rank-card p {
  margin: 0 0 8px;
  color: var(--muted);
  font-size: 13px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

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

.tag-cloud a,
.quick-links a {
  color: var(--text);
  background: rgba(255, 255, 255, 0.065);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 999px;
  padding: 10px 15px;
  transition: transform 0.2s ease, background 0.2s ease, color 0.2s ease;
}

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

.cta-panel,
.page-hero,
.category-overview-card,
.content-card,
.filter-bar {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 28px;
  box-shadow: var(--shadow);
}

.cta-panel,
.page-hero {
  padding: clamp(30px, 5vw, 56px);
}

.cta-panel {
  text-align: center;
  background: linear-gradient(135deg, rgba(88, 28, 135, 0.50), rgba(190, 24, 93, 0.28));
}

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

.page-hero {
  margin-bottom: 34px;
  background-size: cover;
  background-position: center;
}

.page-hero h1 {
  font-size: clamp(36px, 5vw, 62px);
  letter-spacing: -0.04em;
}

.category-overview-list {
  display: grid;
  gap: 28px;
}

.category-overview-card {
  padding: 26px;
}

.filter-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 30px;
  padding: 18px 22px;
}

.filter-bar label {
  color: var(--gold);
  font-weight: 900;
}

.filter-bar input {
  width: min(460px, 100%);
}

.detail-main {
  padding-bottom: 20px;
}

.detail-hero {
  min-height: 660px;
  display: flex;
  align-items: center;
  background-size: cover;
  background-position: center;
}

.detail-hero-inner {
  padding: 56px 0;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 28px;
  color: var(--muted);
}

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

.detail-intro {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  gap: 38px;
  align-items: center;
}

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

.detail-copy h1 {
  margin: 10px 0 16px;
  max-width: 780px;
  font-size: clamp(38px, 6vw, 74px);
  line-height: 1.02;
  letter-spacing: -0.06em;
}

.detail-one-line {
  max-width: 760px;
  color: #e2e8f0;
  font-size: 18px;
}

.detail-meta,
.detail-tags {
  margin-top: 18px;
}

.detail-copy .primary-button {
  margin-top: 28px;
}

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

.player-shell {
  position: relative;
  overflow: hidden;
  border-radius: 28px;
  background: #000000;
  border: 1px solid rgba(255, 255, 255, 0.14);
  box-shadow: var(--shadow);
  aspect-ratio: 16 / 9;
}

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

.player-start {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  border: 0;
  cursor: pointer;
  color: #111827;
  background: linear-gradient(180deg, rgba(2, 6, 23, 0.22), rgba(2, 6, 23, 0.70));
}

.player-start span {
  width: 92px;
  height: 92px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: linear-gradient(135deg, #fde047, #f59e0b);
  box-shadow: 0 20px 60px rgba(250, 204, 21, 0.30);
  font-size: 34px;
  transform: translateX(3px);
}

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

.detail-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  margin-top: 34px;
}

.content-card {
  padding: 28px;
}

.content-card h2 {
  font-size: 26px;
}

.content-card p {
  color: var(--muted);
  font-size: 16px;
}

.search-hero .large-search {
  max-width: 680px;
  margin-top: 28px;
}

.large-search input {
  flex: 1;
  width: auto;
  padding: 15px 20px;
}

.large-search button {
  padding: 15px 26px;
}

.site-footer {
  margin-top: 100px;
  color: var(--muted);
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.30), rgba(0, 0, 0, 0.95));
  border-top: 1px solid rgba(255, 255, 255, 0.10);
}

.footer-inner {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 50px 0 30px;
  display: grid;
  grid-template-columns: 2fr 1fr 1.2fr;
  gap: 34px;
}

.footer-logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  font-size: 22px;
  font-weight: 900;
}

.footer-about p {
  max-width: 520px;
}

.footer-links h2 {
  color: var(--text);
  font-size: 18px;
}

.footer-links ul {
  list-style: none;
  margin: 16px 0 0;
  padding: 0;
  display: grid;
  gap: 8px;
}

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

.footer-bottom {
  padding: 18px;
  text-align: center;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.empty-message {
  grid-column: 1 / -1;
  padding: 34px;
  color: var(--muted);
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 18px;
  text-align: center;
}

@media (max-width: 1100px) {
  .site-search {
    display: none;
  }

  .hero-slide {
    grid-template-columns: minmax(0, 1fr) 300px;
  }

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

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

  .ranking-panel {
    position: static;
  }
}

@media (max-width: 860px) {
  .header-inner {
    flex-wrap: wrap;
    padding: 12px 0;
  }

  .menu-toggle {
    display: inline-flex;
  }

  .site-nav {
    display: none;
    width: 100%;
    order: 3;
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
    margin-left: 0;
  }

  .site-nav.is-open {
    display: flex;
  }

  .nav-link {
    padding: 12px 14px;
    background: rgba(255, 255, 255, 0.06);
    border-radius: 12px;
  }

  .hero-carousel {
    min-height: 760px;
  }

  .hero-slide {
    grid-template-columns: 1fr;
    align-content: center;
    gap: 28px;
    padding: 78px 18px 92px;
  }

  .hero-poster {
    max-width: 260px;
  }

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

  .section-heading.row,
  .category-overview-head,
  .filter-bar {
    align-items: flex-start;
    flex-direction: column;
  }

  .detail-intro,
  .detail-content,
  .footer-inner {
    grid-template-columns: 1fr;
  }

  .detail-poster {
    max-width: 280px;
  }

  .rank-card a {
    grid-template-columns: auto 68px minmax(0, 1fr);
  }
}

@media (max-width: 540px) {
  .container,
  .header-inner,
  .footer-inner {
    width: min(100% - 22px, 1180px);
  }

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

  .brand-subtitle {
    font-size: 11px;
  }

  .hero-content h1,
  .detail-copy h1 {
    letter-spacing: -0.04em;
  }

  .hero-actions,
  .large-search {
    flex-direction: column;
    align-items: stretch;
  }

  .hero-poster {
    display: none;
  }

  .category-grid,
  .movie-grid,
  .movie-grid.compact,
  .listing-grid,
  .mini-grid {
    grid-template-columns: 1fr;
  }

  .scroll-row {
    grid-auto-columns: 86%;
  }

  .page-hero,
  .category-overview-card,
  .content-card,
  .cta-panel {
    border-radius: 20px;
    padding: 22px;
  }

  .rank-card a {
    grid-template-columns: 1fr;
  }

  .rank-card img {
    width: 100%;
    height: auto;
    aspect-ratio: 16 / 9;
  }
}
