:root {
  --bg: #020617;
  --bg-soft: #0f172a;
  --panel: rgba(15, 23, 42, 0.72);
  --panel-strong: rgba(15, 23, 42, 0.94);
  --line: rgba(148, 163, 184, 0.18);
  --text: #f8fafc;
  --muted: #94a3b8;
  --subtle: #64748b;
  --gold: #f59e0b;
  --gold-light: #fde68a;
  --orange: #fb923c;
  --red: #ef4444;
  --shadow: 0 24px 70px rgba(0, 0, 0, 0.42);
  --radius: 24px;
  font-family: Inter, "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  min-width: 320px;
  scroll-behavior: smooth;
  background: var(--bg);
}

body {
  min-height: 100vh;
  margin: 0;
  color: var(--text);
  background:
    radial-gradient(circle at top left, rgba(245, 158, 11, 0.18), transparent 34rem),
    radial-gradient(circle at top right, rgba(239, 68, 68, 0.12), transparent 30rem),
    linear-gradient(180deg, #020617 0%, #0f172a 44%, #020617 100%);
}

body::before {
  position: fixed;
  inset: 0;
  z-index: -1;
  content: "";
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.025) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.75), transparent 82%);
}

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

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

button,
input {
  font: inherit;
}

.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 50;
  border-bottom: 1px solid rgba(148, 163, 184, 0.16);
  background: linear-gradient(90deg, rgba(2, 6, 23, 0.86), rgba(15, 23, 42, 0.82));
  backdrop-filter: blur(18px);
}

.header-inner {
  width: min(1200px, calc(100% - 32px));
  height: 76px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

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

.brand-mark {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 16px;
  color: #111827;
  font-size: 18px;
  background: linear-gradient(135deg, var(--gold-light), var(--gold), var(--orange));
  box-shadow: 0 0 28px rgba(245, 158, 11, 0.42);
}

.brand-copy {
  display: grid;
  gap: 2px;
}

.brand-name {
  font-size: 22px;
  font-weight: 800;
  letter-spacing: 0.02em;
  background: linear-gradient(90deg, #fde68a, #f59e0b, #fb923c);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

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

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 8px;
}

.nav-link,
.mobile-link {
  border: 1px solid transparent;
  border-radius: 999px;
  color: #cbd5e1;
  transition: 0.22s ease;
}

.nav-link {
  padding: 10px 16px;
  font-size: 14px;
}

.mobile-link {
  display: block;
  padding: 14px 18px;
}

.nav-link:hover,
.mobile-link:hover,
.nav-link.is-active,
.mobile-link.is-active {
  color: #fff;
  border-color: rgba(245, 158, 11, 0.32);
  background: rgba(245, 158, 11, 0.12);
}

.nav-toggle {
  width: 44px;
  height: 44px;
  display: none;
  padding: 0;
  border: 0;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.08);
  cursor: pointer;
}

.nav-toggle span {
  width: 20px;
  height: 2px;
  display: block;
  margin: 5px auto;
  border-radius: 999px;
  background: #fff;
}

.mobile-nav {
  display: none;
  width: min(1200px, calc(100% - 32px));
  margin: 0 auto 14px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: rgba(15, 23, 42, 0.96);
  box-shadow: var(--shadow);
}

main {
  padding-top: 76px;
}

.hero {
  position: relative;
  overflow: hidden;
  min-height: 720px;
  padding: 72px 0 44px;
}

.hero::before {
  position: absolute;
  inset: 0;
  content: "";
  background:
    linear-gradient(90deg, rgba(2, 6, 23, 0.98) 0%, rgba(2, 6, 23, 0.78) 44%, rgba(2, 6, 23, 0.36) 100%),
    radial-gradient(circle at 70% 28%, rgba(245, 158, 11, 0.36), transparent 28rem);
}

.hero-slider {
  position: relative;
  z-index: 1;
  width: min(1200px, calc(100% - 32px));
  margin: 0 auto;
}

.hero-slide {
  display: none;
  grid-template-columns: minmax(0, 1fr) minmax(330px, 460px);
  gap: 44px;
  align-items: center;
}

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

.hero-copy {
  min-width: 0;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 18px;
  padding: 8px 14px;
  border: 1px solid rgba(245, 158, 11, 0.24);
  border-radius: 999px;
  color: var(--gold-light);
  background: rgba(245, 158, 11, 0.1);
}

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

.hero h1 span,
.section-heading span,
.page-title span {
  background: linear-gradient(90deg, #fde68a, #f59e0b, #fb923c);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero p {
  max-width: 760px;
  margin: 0 0 26px;
  color: #cbd5e1;
  font-size: 18px;
  line-height: 1.85;
}

.hero-meta,
.detail-meta,
.rank-row-meta,
.card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  color: var(--muted);
}

.hero-meta span,
.detail-meta span,
.rank-row-meta span,
.card-meta span {
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.62);
}

.hero-meta span,
.detail-meta span {
  padding: 8px 12px;
}

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

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 20px;
  border: 1px solid transparent;
  border-radius: 999px;
  font-weight: 700;
  transition: 0.22s ease;
}

.btn-primary {
  color: #111827;
  background: linear-gradient(135deg, #fde68a, #f59e0b, #fb923c);
  box-shadow: 0 18px 40px rgba(245, 158, 11, 0.25);
}

.btn-secondary {
  color: #fff;
  border-color: rgba(255, 255, 255, 0.15);
  background: rgba(255, 255, 255, 0.08);
}

.btn:hover {
  transform: translateY(-2px);
}

.hero-poster {
  position: relative;
  border-radius: 34px;
  overflow: hidden;
  border: 1px solid rgba(245, 158, 11, 0.24);
  box-shadow: 0 32px 80px rgba(0, 0, 0, 0.5);
  background: rgba(15, 23, 42, 0.72);
  aspect-ratio: 3 / 4;
}

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

.hero-poster::after {
  position: absolute;
  inset: 0;
  content: "";
  background: linear-gradient(180deg, transparent 32%, rgba(2, 6, 23, 0.86) 100%);
}

.hero-poster-caption {
  position: absolute;
  inset: auto 22px 22px;
  z-index: 1;
}

.hero-poster-caption strong {
  display: block;
  margin-bottom: 8px;
  font-size: 24px;
}

.hero-dots {
  position: relative;
  z-index: 2;
  display: flex;
  gap: 10px;
  width: min(1200px, calc(100% - 32px));
  margin: 34px auto 0;
}

.hero-dot {
  width: 44px;
  height: 6px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
  cursor: pointer;
}

.hero-dot.is-active {
  background: linear-gradient(90deg, var(--gold-light), var(--gold));
}

.section,
.page-shell {
  width: min(1200px, calc(100% - 32px));
  margin: 0 auto;
}

.section {
  padding: 56px 0;
}

.page-shell {
  padding: 56px 0 72px;
}

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

.section-heading,
.page-title {
  margin: 0;
  font-size: clamp(28px, 4vw, 46px);
  line-height: 1.1;
  letter-spacing: -0.035em;
}

.section-intro,
.page-intro {
  max-width: 820px;
  margin: 12px 0 0;
  color: var(--muted);
  line-height: 1.8;
}

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

.movie-card {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: rgba(15, 23, 42, 0.62);
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.16);
  transition: 0.25s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  border-color: rgba(245, 158, 11, 0.42);
  background: rgba(15, 23, 42, 0.9);
}

.poster-link {
  position: relative;
  display: block;
  overflow: hidden;
  aspect-ratio: 16 / 10;
  background: rgba(2, 6, 23, 0.56);
}

.movie-card .poster-link img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: 0.36s ease;
}

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

.poster-gradient {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 26%, rgba(2, 6, 23, 0.82) 100%);
}

.play-chip {
  position: absolute;
  right: 14px;
  bottom: 14px;
  display: inline-flex;
  padding: 7px 12px;
  border-radius: 999px;
  color: #111827;
  font-size: 13px;
  font-weight: 800;
  background: linear-gradient(135deg, #fde68a, #f59e0b);
}

.rank-badge {
  position: absolute;
  left: 12px;
  top: 12px;
  z-index: 2;
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  color: #111827;
  font-weight: 900;
  background: linear-gradient(135deg, #fde68a, #f59e0b);
}

.card-body {
  padding: 18px;
}

.card-meta {
  margin-bottom: 10px;
  font-size: 12px;
}

.card-meta span {
  padding: 4px 8px;
}

.movie-card h3 {
  margin: 0 0 10px;
  font-size: 19px;
  line-height: 1.35;
}

.movie-card h3 a:hover,
.rank-row h3 a:hover {
  color: var(--gold-light);
}

.movie-card p {
  min-height: 44px;
  margin: 0 0 14px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.65;
}

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

.tag-row span,
.filter-pill {
  display: inline-flex;
  border: 1px solid rgba(148, 163, 184, 0.18);
  border-radius: 999px;
  color: #cbd5e1;
  background: rgba(255, 255, 255, 0.05);
}

.tag-row span {
  padding: 5px 9px;
  font-size: 12px;
}

.filter-panel {
  display: grid;
  gap: 16px;
  margin: 28px 0;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: rgba(15, 23, 42, 0.58);
}

.search-input {
  width: 100%;
  min-height: 48px;
  padding: 0 18px;
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 16px;
  color: #fff;
  outline: none;
  background: rgba(2, 6, 23, 0.52);
}

.search-input:focus {
  border-color: rgba(245, 158, 11, 0.55);
  box-shadow: 0 0 0 4px rgba(245, 158, 11, 0.12);
}

.filter-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.filter-pill {
  padding: 8px 13px;
  cursor: pointer;
  transition: 0.22s ease;
}

.filter-pill.is-active,
.filter-pill:hover {
  color: #111827;
  border-color: transparent;
  background: linear-gradient(135deg, #fde68a, #f59e0b);
}

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

.category-card {
  position: relative;
  overflow: hidden;
  min-height: 250px;
  display: flex;
  align-items: flex-end;
  border: 1px solid var(--line);
  border-radius: 26px;
  background: var(--panel);
  box-shadow: 0 18px 46px rgba(0, 0, 0, 0.18);
}

.category-card img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.42;
  transition: 0.35s ease;
}

.category-card:hover img {
  transform: scale(1.05);
  opacity: 0.6;
}

.category-card::after {
  position: absolute;
  inset: 0;
  content: "";
  background: linear-gradient(180deg, transparent, rgba(2, 6, 23, 0.92));
}

.category-card-content {
  position: relative;
  z-index: 1;
  padding: 20px;
}

.category-card h3 {
  margin: 0 0 10px;
  font-size: 22px;
}

.category-card p {
  margin: 0 0 14px;
  color: #cbd5e1;
  line-height: 1.65;
}

.category-card span {
  color: var(--gold-light);
  font-weight: 800;
}

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

.rank-row {
  display: grid;
  grid-template-columns: 116px minmax(0, 1fr) auto;
  gap: 18px;
  align-items: center;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: rgba(15, 23, 42, 0.58);
}

.rank-row-poster {
  overflow: hidden;
  border-radius: 18px;
  aspect-ratio: 16 / 10;
}

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

.rank-title-line {
  display: flex;
  align-items: center;
  gap: 12px;
}

.rank-row h3 {
  margin: 0;
  font-size: 20px;
}

.rank-row p {
  margin: 9px 0 12px;
  color: var(--muted);
  line-height: 1.7;
}

.list-rank,
.list-dot {
  flex: none;
  display: grid;
  place-items: center;
  border-radius: 12px;
  font-weight: 900;
}

.list-rank {
  width: 34px;
  height: 34px;
  color: #111827;
  background: linear-gradient(135deg, #fde68a, #f59e0b);
}

.list-dot {
  width: 12px;
  height: 12px;
  background: var(--gold);
}

.rank-row-meta {
  font-size: 13px;
}

.rank-row-meta span {
  padding: 5px 9px;
}

.row-action {
  padding: 10px 14px;
  border-radius: 999px;
  color: #111827;
  font-weight: 800;
  background: linear-gradient(135deg, #fde68a, #f59e0b);
}

.detail-hero {
  position: relative;
  overflow: hidden;
  padding: 70px 0 50px;
}

.detail-hero::before {
  position: absolute;
  inset: 0;
  content: "";
  background:
    linear-gradient(90deg, rgba(2, 6, 23, 0.98), rgba(2, 6, 23, 0.7)),
    var(--detail-bg, none);
  background-size: cover;
  background-position: center;
  filter: saturate(1.1);
}

.detail-hero-inner {
  position: relative;
  z-index: 1;
  width: min(1200px, calc(100% - 32px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: 330px minmax(0, 1fr);
  gap: 36px;
  align-items: center;
}

.detail-poster {
  overflow: hidden;
  border: 1px solid rgba(245, 158, 11, 0.25);
  border-radius: 30px;
  aspect-ratio: 3 / 4;
  box-shadow: var(--shadow);
}

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

.breadcrumb {
  margin-bottom: 18px;
  color: var(--muted);
  font-size: 14px;
}

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

.detail-copy h1 {
  margin: 0 0 18px;
  font-size: clamp(36px, 6vw, 72px);
  line-height: 1.02;
  letter-spacing: -0.045em;
}

.detail-copy p {
  max-width: 820px;
  color: #cbd5e1;
  line-height: 1.86;
}

.watch-section {
  width: min(1200px, calc(100% - 32px));
  margin: 0 auto;
  padding: 54px 0;
}

.player-frame {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(245, 158, 11, 0.22);
  border-radius: 30px;
  background: #000;
  box-shadow: var(--shadow);
}

.player-frame video {
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #000;
  cursor: pointer;
}

.play-overlay {
  position: absolute;
  inset: 0;
  z-index: 3;
  display: grid;
  place-items: center;
  padding: 24px;
  background:
    linear-gradient(180deg, rgba(2, 6, 23, 0.18), rgba(2, 6, 23, 0.72)),
    var(--poster-bg, none);
  background-size: cover;
  background-position: center;
  cursor: pointer;
  transition: 0.25s ease;
}

.play-overlay.is-hidden {
  opacity: 0;
  pointer-events: none;
}

.play-button {
  width: 86px;
  height: 86px;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 50%;
  color: #111827;
  font-size: 32px;
  background: linear-gradient(135deg, #fde68a, #f59e0b);
  box-shadow: 0 0 0 16px rgba(245, 158, 11, 0.16), 0 28px 60px rgba(0, 0, 0, 0.45);
  cursor: pointer;
}

.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 24px;
  margin-top: 26px;
}

.content-card {
  padding: 26px;
  border: 1px solid var(--line);
  border-radius: 26px;
  background: rgba(15, 23, 42, 0.62);
}

.content-card h2 {
  margin: 0 0 14px;
  font-size: 25px;
}

.content-card p {
  color: #cbd5e1;
  line-height: 1.9;
}

.side-card {
  display: grid;
  gap: 12px;
  align-content: start;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 26px;
  background: rgba(15, 23, 42, 0.62);
}

.side-card h2 {
  margin: 0 0 6px;
  font-size: 22px;
}

.side-link {
  display: grid;
  grid-template-columns: 86px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  padding: 10px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.04);
}

.side-link:hover {
  background: rgba(245, 158, 11, 0.1);
}

.side-link img {
  width: 86px;
  height: 58px;
  border-radius: 14px;
  object-fit: cover;
}

.side-link strong {
  display: block;
  margin-bottom: 6px;
}

.side-link span {
  color: var(--muted);
  font-size: 12px;
}

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

.footer-inner {
  width: min(1200px, calc(100% - 32px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 520px);
  gap: 32px;
  padding: 34px 0;
}

.footer-brand {
  display: inline-flex;
  margin-bottom: 10px;
  color: var(--gold-light);
  font-size: 22px;
  font-weight: 900;
}

.footer-inner p {
  max-width: 620px;
  margin: 0;
  color: var(--muted);
  line-height: 1.75;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: flex-end;
}

.footer-links a {
  padding: 8px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: #cbd5e1;
  background: rgba(255, 255, 255, 0.04);
}

.empty-state {
  display: none;
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: 24px;
  color: var(--muted);
  text-align: center;
  background: rgba(15, 23, 42, 0.62);
}

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

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

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

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

  .nav-toggle {
    display: block;
  }

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

  .hero {
    min-height: auto;
    padding-top: 44px;
  }

  .hero-slide,
  .detail-hero-inner {
    grid-template-columns: 1fr;
  }

  .hero-poster,
  .detail-poster {
    max-width: 360px;
  }

  .section-head,
  .page-head {
    display: block;
  }

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

  .rank-row {
    grid-template-columns: 96px minmax(0, 1fr);
  }

  .row-action {
    grid-column: 1 / -1;
    text-align: center;
  }

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

  .footer-links {
    justify-content: flex-start;
  }
}

@media (max-width: 560px) {
  .header-inner {
    height: 66px;
  }

  main {
    padding-top: 66px;
  }

  .brand-mark {
    width: 38px;
    height: 38px;
  }

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

  .brand-subtitle {
    display: none;
  }

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

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

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

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

  .rank-row-poster {
    aspect-ratio: 16 / 9;
  }

  .detail-hero-inner,
  .section,
  .page-shell,
  .watch-section {
    width: min(100% - 24px, 1200px);
  }

  .content-card {
    padding: 20px;
  }
}
