:root {
  --bg: #020617;
  --bg-2: #0f172a;
  --panel: rgba(15, 23, 42, 0.78);
  --panel-strong: rgba(15, 23, 42, 0.94);
  --line: rgba(251, 191, 36, 0.18);
  --gold: #f59e0b;
  --gold-2: #fbbf24;
  --gold-soft: rgba(245, 158, 11, 0.18);
  --text: #fafafa;
  --muted: #cbd5e1;
  --soft: #94a3b8;
  --radius: 24px;
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.34);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at top left, rgba(251, 191, 36, 0.16), transparent 28rem),
    radial-gradient(circle at 80% 10%, rgba(30, 64, 175, 0.28), transparent 32rem),
    linear-gradient(180deg, #020617 0%, #0f172a 48%, #020617 100%);
  min-height: 100vh;
}

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

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

button,
input {
  font: inherit;
}

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

.container.wide {
  width: min(1380px, calc(100% - 32px));
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 60;
  backdrop-filter: blur(18px);
  background: rgba(2, 6, 23, 0.78);
  border-bottom: 1px solid rgba(251, 191, 36, 0.12);
}

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

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

.brand-mark {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 14px;
  color: #020617;
  background: linear-gradient(135deg, var(--gold-2), var(--gold));
  box-shadow: 0 10px 30px rgba(245, 158, 11, 0.3);
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 6px;
}

.site-nav a {
  padding: 10px 14px;
  border-radius: 999px;
  color: var(--muted);
  transition: color 0.2s ease, background 0.2s ease;
}

.site-nav a:hover,
.site-nav a.active {
  color: var(--gold-2);
  background: rgba(251, 191, 36, 0.09);
}

.nav-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 1px solid rgba(251, 191, 36, 0.2);
  border-radius: 14px;
  background: rgba(15, 23, 42, 0.7);
  color: var(--text);
}

.nav-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  margin: 4px auto;
  border-radius: 999px;
  background: currentColor;
}

.hero {
  position: relative;
  min-height: 680px;
  overflow: hidden;
  border-bottom: 1px solid rgba(251, 191, 36, 0.12);
}

.hero-slides,
.hero-slide {
  position: absolute;
  inset: 0;
}

.hero-slide {
  opacity: 0;
  transform: scale(1.02);
  transition: opacity 0.6s ease, transform 0.8s ease;
  pointer-events: none;
}

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

.hero-bg,
.detail-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(1.05) contrast(1.03);
}

.hero-shade,
.detail-overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(2, 6, 23, 0.94) 0%, rgba(2, 6, 23, 0.72) 45%, rgba(2, 6, 23, 0.28) 100%),
    linear-gradient(180deg, rgba(2, 6, 23, 0.16) 0%, #020617 100%);
}

.hero-content {
  position: relative;
  z-index: 2;
  width: min(1280px, calc(100% - 32px));
  min-height: 680px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) 380px;
  align-items: center;
  gap: 52px;
  padding: 92px 0 110px;
}

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

.eyebrow,
.section-title span,
.watch-title span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--gold-2);
  font-size: 0.84rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.14em;
}

.hero h1,
.page-hero h1,
.detail-copy h1 {
  margin: 16px 0 18px;
  font-size: clamp(2.6rem, 7vw, 5.6rem);
  line-height: 0.95;
  letter-spacing: -0.06em;
  max-width: 840px;
}

.hero p,
.page-hero p,
.detail-copy .lead {
  margin: 0;
  color: var(--muted);
  font-size: clamp(1rem, 2vw, 1.22rem);
  line-height: 1.8;
  max-width: 720px;
}

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

.hero-tags span,
.tag-row span {
  display: inline-flex;
  padding: 6px 10px;
  border: 1px solid rgba(251, 191, 36, 0.18);
  border-radius: 999px;
  color: #fde68a;
  background: rgba(251, 191, 36, 0.09);
  font-size: 0.78rem;
}

.hero-actions,
.detail-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-radius: 999px;
  font-weight: 800;
  transition: transform 0.2s ease, background 0.2s ease, border-color 0.2s ease;
}

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

.btn.primary {
  color: #020617;
  background: linear-gradient(135deg, var(--gold-2), var(--gold));
  box-shadow: 0 14px 36px rgba(245, 158, 11, 0.28);
}

.btn.ghost {
  color: var(--text);
  border: 1px solid rgba(251, 191, 36, 0.26);
  background: rgba(15, 23, 42, 0.66);
}

.hero-poster,
.detail-poster {
  position: relative;
  display: block;
  border-radius: 30px;
  overflow: hidden;
  box-shadow: var(--shadow);
  transform: rotate(2deg);
  border: 1px solid rgba(251, 191, 36, 0.22);
}

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

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

.hero-controls {
  position: absolute;
  z-index: 5;
  left: 50%;
  bottom: 112px;
  transform: translateX(-50%);
  width: min(1280px, calc(100% - 32px));
  display: flex;
  align-items: center;
  gap: 14px;
}

.slider-arrow,
.slider-dot {
  border: 1px solid rgba(251, 191, 36, 0.24);
  background: rgba(15, 23, 42, 0.74);
  color: var(--text);
  backdrop-filter: blur(12px);
  cursor: pointer;
}

.slider-arrow {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  font-size: 1.7rem;
  line-height: 1;
}

.slider-dots {
  display: flex;
  gap: 8px;
}

.slider-dot {
  width: 34px;
  height: 8px;
  padding: 0;
  border-radius: 999px;
}

.slider-dot.is-active {
  background: var(--gold-2);
}

.hero-search,
.page-search {
  position: relative;
  z-index: 8;
  display: flex;
  gap: 10px;
  width: min(560px, calc(100% - 32px));
  padding: 8px;
  border: 1px solid rgba(251, 191, 36, 0.2);
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.82);
  backdrop-filter: blur(18px);
}

.hero-search {
  position: absolute;
  left: 50%;
  bottom: 36px;
  transform: translateX(-50%);
}

.hero-search input,
.page-search input,
.live-search {
  flex: 1;
  width: 100%;
  min-width: 0;
  border: 0;
  outline: 0;
  color: var(--text);
  background: transparent;
  padding: 0 14px;
}

.hero-search button,
.page-search button,
.filter-buttons button,
.filter-link {
  border: 0;
  border-radius: 999px;
  color: #020617;
  background: linear-gradient(135deg, var(--gold-2), var(--gold));
  padding: 10px 18px;
  font-weight: 800;
  cursor: pointer;
}

.section {
  padding: 78px 0;
}

.section-title {
  margin-bottom: 30px;
}

.section-title.centered {
  text-align: center;
  margin-inline: auto;
  max-width: 720px;
}

.section-title.align-left {
  max-width: 420px;
}

.section-title h2,
.watch-title h2,
.content-card h2 {
  margin: 10px 0 10px;
  font-size: clamp(1.8rem, 4vw, 3rem);
  letter-spacing: -0.04em;
}

.section-title p,
.content-card p,
.site-footer p {
  margin: 0;
  color: var(--muted);
  line-height: 1.8;
}

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

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

.movie-card {
  position: relative;
  min-width: 0;
  overflow: hidden;
  border: 1px solid rgba(251, 191, 36, 0.13);
  border-radius: 22px;
  background: rgba(15, 23, 42, 0.62);
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.18);
  transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  border-color: rgba(251, 191, 36, 0.44);
  box-shadow: 0 20px 64px rgba(0, 0, 0, 0.32);
}

.poster-link {
  position: relative;
  display: block;
  overflow: hidden;
  background: #0f172a;
}

.poster-link img {
  width: 100%;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  transition: transform 0.35s ease;
}

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

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

.rank-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  display: grid;
  place-items: center;
  min-width: 34px;
  height: 34px;
  padding: 0 8px;
  border-radius: 12px;
  color: #020617;
  background: linear-gradient(135deg, #fde68a, var(--gold));
  font-weight: 900;
}

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

.movie-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  color: var(--soft);
  font-size: 0.76rem;
}

.movie-card h3 {
  margin: 8px 0 8px;
  font-size: 1.02rem;
  line-height: 1.35;
}

.movie-card h3 a:hover {
  color: var(--gold-2);
}

.movie-card p {
  min-height: 3.8em;
  margin: 0;
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.6;
}

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

.category-pill,
.category-overview-card,
.content-card,
.watch-panel,
.ranking-panel,
.info-grid div {
  border: 1px solid rgba(251, 191, 36, 0.14);
  border-radius: var(--radius);
  background: var(--panel);
  box-shadow: 0 18px 70px rgba(0, 0, 0, 0.16);
  backdrop-filter: blur(14px);
}

.category-pill {
  display: block;
  padding: 22px;
  min-height: 138px;
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.category-pill:hover,
.category-overview-card:hover {
  transform: translateY(-4px);
  border-color: rgba(251, 191, 36, 0.38);
}

.category-pill strong,
.category-overview-head span {
  display: block;
  margin-bottom: 10px;
  color: var(--gold-2);
  font-size: 1.2rem;
}

.category-pill span,
.category-overview-card p {
  color: var(--muted);
  line-height: 1.7;
}

.split-section {
  display: grid;
  grid-template-columns: 0.8fr 1.2fr;
  gap: 36px;
  align-items: start;
}

.ranking-panel {
  padding: 18px;
  display: grid;
  gap: 10px;
}

.ranking-item {
  display: grid;
  grid-template-columns: 42px 56px 1fr;
  gap: 12px;
  align-items: center;
  padding: 10px;
  border-radius: 18px;
  transition: background 0.2s ease;
}

.ranking-item:hover {
  background: rgba(251, 191, 36, 0.08);
}

.ranking-number {
  color: var(--gold-2);
  font-weight: 900;
  font-size: 1.3rem;
}

.ranking-item img {
  width: 56px;
  height: 78px;
  object-fit: cover;
  border-radius: 12px;
}

.ranking-text strong,
.ranking-text small {
  display: block;
}

.ranking-text small {
  margin-top: 4px;
  color: var(--soft);
}

.page-hero,
.detail-hero {
  position: relative;
  overflow: hidden;
  padding: 110px 0 70px;
  border-bottom: 1px solid rgba(251, 191, 36, 0.12);
}

.small-hero {
  background:
    radial-gradient(circle at 20% 30%, rgba(251, 191, 36, 0.16), transparent 24rem),
    linear-gradient(135deg, rgba(15, 23, 42, 0.96), rgba(2, 6, 23, 0.98));
}

.category-hero {
  background:
    radial-gradient(circle at 80% 10%, rgba(251, 191, 36, 0.18), transparent 26rem),
    linear-gradient(135deg, rgba(15, 23, 42, 0.96), rgba(2, 6, 23, 0.98));
}

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

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

.filter-bar,
.filter-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  margin-bottom: 24px;
}

.filter-bar {
  padding: 10px;
  border: 1px solid rgba(251, 191, 36, 0.16);
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.68);
}

.filter-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.filter-buttons button {
  color: var(--muted);
  border: 1px solid rgba(251, 191, 36, 0.16);
  background: rgba(15, 23, 42, 0.72);
}

.filter-buttons button.is-active,
.filter-buttons button:hover {
  color: #020617;
  background: linear-gradient(135deg, var(--gold-2), var(--gold));
}

.empty-state {
  display: none;
  padding: 36px;
  text-align: center;
  color: var(--muted);
  border: 1px solid rgba(251, 191, 36, 0.14);
  border-radius: var(--radius);
  background: var(--panel);
}

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

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

.category-overview-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.category-overview-head a {
  color: var(--gold-2);
  font-size: 0.9rem;
}

.category-preview-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin-top: 16px;
}

.category-preview-row a {
  position: relative;
  overflow: hidden;
  border-radius: 14px;
}

.category-preview-row img {
  width: 100%;
  aspect-ratio: 2 / 3;
  object-fit: cover;
}

.category-preview-row span {
  position: absolute;
  inset: auto 0 0;
  padding: 18px 8px 8px;
  font-size: 0.72rem;
  background: linear-gradient(180deg, transparent, rgba(2, 6, 23, 0.88));
}

.detail-hero {
  min-height: 660px;
  display: flex;
  align-items: end;
}

.detail-layout {
  position: relative;
  z-index: 3;
  display: grid;
  grid-template-columns: 330px 1fr;
  gap: 44px;
  align-items: end;
}

.detail-copy {
  padding-bottom: 18px;
}

.detail-poster {
  transform: none;
}

.watch-section {
  padding-top: 54px;
}

.watch-panel {
  padding: 22px;
}

.watch-title {
  margin-bottom: 18px;
}

.player-shell {
  position: relative;
  overflow: hidden;
  border-radius: 24px;
  background: #000;
  box-shadow: var(--shadow);
}

.movie-video {
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #000;
}

.player-cover {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  border: 0;
  color: var(--text);
  background: #020617;
  cursor: pointer;
  transition: opacity 0.28s ease, visibility 0.28s ease;
}

.player-cover.is-hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.player-cover img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.62;
}

.player-cover::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at center, rgba(251, 191, 36, 0.16), rgba(2, 6, 23, 0.72));
}

.play-orb {
  position: relative;
  z-index: 2;
  display: grid;
  place-items: center;
  width: 86px;
  height: 86px;
  padding-left: 6px;
  border-radius: 50%;
  color: #020617;
  background: linear-gradient(135deg, var(--gold-2), var(--gold));
  box-shadow: 0 18px 48px rgba(245, 158, 11, 0.4);
  font-size: 2rem;
}

.player-cover strong {
  position: absolute;
  z-index: 2;
  left: 28px;
  bottom: 24px;
  max-width: calc(100% - 56px);
  font-size: clamp(1.4rem, 4vw, 2.5rem);
  text-align: left;
}

.detail-text {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}

.content-card {
  padding: 24px;
}

.info-grid {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

.info-grid div {
  padding: 18px;
}

.info-grid span,
.info-grid strong {
  display: block;
}

.info-grid span {
  color: var(--soft);
  margin-bottom: 6px;
}

.info-grid strong {
  color: var(--text);
  line-height: 1.5;
}

.site-footer {
  border-top: 1px solid rgba(251, 191, 36, 0.12);
  padding: 48px 0 34px;
  background: rgba(2, 6, 23, 0.86);
}

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

.footer-brand {
  margin-bottom: 12px;
  color: var(--gold-2);
  font-size: 1.2rem;
}

.footer-links {
  display: grid;
  gap: 10px;
}

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

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

.copyright {
  width: min(1180px, calc(100% - 32px));
  margin: 24px auto 0;
  color: var(--soft);
  font-size: 0.9rem;
}

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

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

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

  .nav-toggle {
    display: block;
  }

  .site-nav {
    position: absolute;
    top: 64px;
    left: 16px;
    right: 16px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    padding: 12px;
    border: 1px solid rgba(251, 191, 36, 0.16);
    border-radius: 22px;
    background: rgba(2, 6, 23, 0.96);
  }

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

  .hero,
  .hero-content {
    min-height: 760px;
  }

  .hero-content {
    grid-template-columns: 1fr;
    gap: 24px;
    padding-top: 88px;
  }

  .hero-poster {
    width: min(230px, 70vw);
    transform: rotate(0deg);
  }

  .hero-controls {
    bottom: 96px;
  }

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

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

  .split-section,
  .detail-layout,
  .detail-text,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .detail-layout {
    align-items: start;
  }

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

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

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

  .hero h1,
  .page-hero h1,
  .detail-copy h1 {
    font-size: 2.45rem;
  }

  .hero-search,
  .page-search,
  .filter-bar {
    border-radius: 22px;
    flex-direction: column;
    align-items: stretch;
  }

  .hero-search button,
  .page-search button,
  .filter-link {
    width: 100%;
  }

  .movie-grid,
  .compact-grid {
    grid-template-columns: 1fr 1fr;
    gap: 12px;
  }

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

  .movie-card p {
    display: none;
  }

  .tag-row {
    display: none;
  }

  .section {
    padding: 52px 0;
  }

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

  .player-cover strong {
    font-size: 1.25rem;
  }
}
