:root {
  --night-950: #020617;
  --night-900: #0f172a;
  --night-850: #111827;
  --night-800: #1e293b;
  --night-700: #334155;
  --gold-300: #fde047;
  --gold-400: #facc15;
  --gold-500: #eab308;
  --gold-600: #ca8a04;
  --blue-400: #60a5fa;
  --red-400: #f87171;
  --text: #f8fafc;
  --muted: #94a3b8;
  --soft: #cbd5e1;
  --border: rgba(234, 179, 8, 0.18);
  --shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
  --glow: 0 0 24px rgba(234, 179, 8, 0.28);
  color-scheme: dark;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at 15% 8%, rgba(234, 179, 8, 0.16), transparent 30rem),
    radial-gradient(circle at 85% 14%, rgba(96, 165, 250, 0.13), transparent 32rem),
    linear-gradient(180deg, #020617 0%, #0f172a 46%, #020617 100%);
  color: var(--text);
  font-family: "Microsoft YaHei", "PingFang SC", "Hiragino Sans GB", Arial, sans-serif;
  line-height: 1.6;
}

body.menu-open {
  overflow: hidden;
}

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

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid var(--border);
  background: rgba(2, 6, 23, 0.95);
  backdrop-filter: blur(10px);
}

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

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

.brand-mark {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 12px;
  background: rgba(234, 179, 8, 0.12);
  border: 1px solid rgba(234, 179, 8, 0.35);
  color: var(--gold-400);
  box-shadow: var(--glow);
}

.brand-text {
  font-size: 1.24rem;
  background: linear-gradient(90deg, var(--gold-300), var(--gold-600));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  white-space: nowrap;
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 18px;
  color: #d1d5db;
  font-size: 0.95rem;
}

.desktop-nav a,
.mobile-nav a,
.site-footer a {
  transition: color 0.25s ease, transform 0.25s ease;
}

.desktop-nav a:hover,
.desktop-nav a.active,
.mobile-nav a:hover,
.site-footer a:hover {
  color: var(--gold-400);
}

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

.header-search input,
.mobile-search input,
.search-panel input,
.filter-select {
  width: 100%;
  border: 1px solid rgba(51, 65, 85, 0.95);
  border-radius: 14px;
  background: rgba(15, 23, 42, 0.92);
  color: var(--soft);
  outline: none;
  transition: border 0.2s ease, box-shadow 0.2s ease;
}

.header-search input {
  width: 220px;
  padding: 10px 12px;
}

.header-search input:focus,
.mobile-search input:focus,
.search-panel input:focus,
.filter-select:focus {
  border-color: var(--gold-500);
  box-shadow: 0 0 0 1px rgba(234, 179, 8, 0.35);
}

button,
.button,
.header-search button,
.mobile-search button {
  border: 0;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--gold-500), var(--gold-600));
  color: #020617;
  cursor: pointer;
  font-weight: 800;
  transition: transform 0.25s ease, box-shadow 0.25s ease, background 0.25s ease;
}

.header-search button,
.mobile-search button {
  padding: 10px 14px;
}

button:hover,
.button:hover {
  transform: translateY(-2px);
  box-shadow: var(--glow);
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 12px 20px;
}

.button.secondary {
  border: 1px solid rgba(234, 179, 8, 0.4);
  background: rgba(15, 23, 42, 0.76);
  color: var(--gold-300);
}

.menu-toggle {
  display: none;
  width: 44px;
  height: 44px;
  padding: 10px;
  background: transparent;
  border: 1px solid rgba(234, 179, 8, 0.25);
}

.menu-toggle span {
  display: block;
  height: 2px;
  margin: 5px 0;
  border-radius: 1px;
  background: var(--gold-400);
}

.mobile-nav {
  display: none;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 16px 0 22px;
  border-top: 1px solid rgba(51, 65, 85, 0.7);
}

.mobile-nav.is-open {
  display: grid;
  gap: 14px;
}

.mobile-search input {
  padding: 12px;
}

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

.hero {
  position: relative;
  min-height: 78vh;
  overflow: hidden;
  border-bottom: 1px solid rgba(234, 179, 8, 0.14);
  background: #020617;
}

.hero::after {
  position: absolute;
  inset: auto 0 0;
  height: 160px;
  content: "";
  background: linear-gradient(180deg, transparent, #020617);
  pointer-events: none;
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: grid;
  align-items: center;
  opacity: 0;
  transition: opacity 0.6s ease;
  background-size: cover;
  background-position: center;
}

.hero-slide.is-active {
  opacity: 1;
  z-index: 2;
}

.hero-slide::before {
  position: absolute;
  inset: 0;
  content: "";
  background:
    linear-gradient(90deg, rgba(2, 6, 23, 0.96) 0%, rgba(2, 6, 23, 0.78) 45%, rgba(2, 6, 23, 0.35) 100%),
    linear-gradient(180deg, rgba(2, 6, 23, 0.5), rgba(2, 6, 23, 0.95));
}

.hero-content {
  position: relative;
  z-index: 3;
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(260px, 0.85fr);
  gap: 42px;
  align-items: center;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 96px 0 112px;
}

.eyebrow {
  display: inline-flex;
  width: fit-content;
  align-items: center;
  gap: 8px;
  margin-bottom: 20px;
  padding: 8px 12px;
  border: 1px solid rgba(234, 179, 8, 0.34);
  border-radius: 999px;
  background: rgba(234, 179, 8, 0.1);
  color: var(--gold-300);
  font-size: 0.88rem;
  font-weight: 700;
}

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

.hero p {
  max-width: 720px;
  margin: 0 0 24px;
  color: #d1d5db;
  font-size: clamp(1rem, 2vw, 1.18rem);
}

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

.hero-poster-card {
  position: relative;
  overflow: hidden;
  min-height: 430px;
  border: 1px solid rgba(234, 179, 8, 0.28);
  border-radius: 30px;
  background: rgba(15, 23, 42, 0.68);
  box-shadow: var(--shadow);
}

.hero-poster-card img {
  width: 100%;
  height: 100%;
  min-height: 430px;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.hero-poster-card:hover img {
  transform: scale(1.05);
}

.hero-card-caption {
  position: absolute;
  inset: auto 18px 18px;
  padding: 16px;
  border: 1px solid rgba(234, 179, 8, 0.22);
  border-radius: 22px;
  background: rgba(2, 6, 23, 0.76);
  backdrop-filter: blur(8px);
}

.hero-card-caption strong {
  display: block;
  margin-bottom: 5px;
  color: var(--gold-300);
  font-size: 1.15rem;
}

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

.hero-dot {
  width: 38px;
  height: 4px;
  padding: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.25);
}

.hero-dot.is-active {
  background: var(--gold-400);
}

.section-block {
  padding: 70px 0 0;
}

.section-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 22px;
  margin-bottom: 26px;
}

.section-heading h2,
.page-title h1,
.detail-title h1 {
  margin: 0;
  font-size: clamp(1.8rem, 4vw, 3rem);
  line-height: 1.15;
}

.section-heading p,
.page-title p,
.detail-title p {
  max-width: 760px;
  margin: 10px 0 0;
  color: var(--muted);
}

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

.movie-card {
  overflow: hidden;
  border: 1px solid rgba(51, 65, 85, 0.95);
  border-radius: 22px;
  background: rgba(15, 23, 42, 0.78);
  box-shadow: 0 16px 34px rgba(0, 0, 0, 0.24);
  transition: transform 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  border-color: rgba(234, 179, 8, 0.55);
  box-shadow: var(--glow), 0 24px 46px rgba(0, 0, 0, 0.35);
}

.poster-wrap,
.mini-poster,
.category-cover {
  position: relative;
  display: block;
  overflow: hidden;
  background:
    linear-gradient(135deg, rgba(234, 179, 8, 0.16), rgba(96, 165, 250, 0.1)),
    #0f172a;
}

.poster-wrap {
  aspect-ratio: 2 / 3;
}

.poster-wrap::after,
.mini-poster::after,
.hero-poster-card::after {
  position: absolute;
  inset: 0;
  display: none;
  place-items: center;
  padding: 18px;
  content: attr(data-title);
  color: rgba(250, 204, 21, 0.74);
  font-weight: 800;
  text-align: center;
  background: radial-gradient(circle at 50% 30%, rgba(234, 179, 8, 0.16), rgba(2, 6, 23, 0.88));
}

.poster-wrap.is-missing::after,
.mini-poster.is-missing::after,
.hero-poster-card.is-missing::after {
  display: grid;
}

.poster-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.45s ease, opacity 0.25s ease;
}

.poster-image.is-hidden {
  opacity: 0;
}

.movie-card:hover .poster-image,
.mini-card:hover .poster-image {
  transform: scale(1.08);
}

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

.play-chip,
.rank-badge {
  position: absolute;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  font-weight: 800;
}

.play-chip {
  right: 12px;
  bottom: 12px;
  min-width: 54px;
  min-height: 30px;
  background: rgba(234, 179, 8, 0.92);
  color: #020617;
  font-size: 0.78rem;
}

.rank-badge {
  left: 12px;
  top: 12px;
  min-width: 34px;
  height: 34px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(2, 6, 23, 0.72);
  color: var(--gold-300);
}

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

.movie-title,
.mini-title {
  display: -webkit-box;
  overflow: hidden;
  color: #ffffff;
  font-weight: 800;
  line-height: 1.35;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.movie-title:hover,
.mini-title:hover {
  color: var(--gold-400);
}

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

.movie-meta {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  color: #64748b;
  font-size: 0.78rem;
}

.movie-meta span:last-child {
  color: var(--gold-400);
  white-space: nowrap;
}

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

.category-card {
  position: relative;
  overflow: hidden;
  min-height: 220px;
  padding: 24px;
  border: 1px solid rgba(234, 179, 8, 0.2);
  border-radius: 24px;
  background:
    linear-gradient(135deg, rgba(15, 23, 42, 0.9), rgba(30, 41, 59, 0.65)),
    radial-gradient(circle at top right, rgba(234, 179, 8, 0.2), transparent 15rem);
  box-shadow: var(--shadow);
  transition: transform 0.3s ease, border-color 0.3s ease;
}

.category-card:hover {
  transform: translateY(-5px);
  border-color: rgba(234, 179, 8, 0.55);
}

.category-card h2,
.category-card h3 {
  margin: 0 0 12px;
  font-size: 1.35rem;
}

.category-card p {
  margin: 0 0 22px;
  color: var(--muted);
}

.page-hero {
  padding: 72px 0 36px;
  border-bottom: 1px solid rgba(234, 179, 8, 0.1);
  background:
    radial-gradient(circle at 15% 0%, rgba(234, 179, 8, 0.12), transparent 28rem),
    radial-gradient(circle at 88% 15%, rgba(96, 165, 250, 0.12), transparent 28rem);
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
  color: var(--muted);
  font-size: 0.92rem;
}

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

.filter-bar,
.search-panel {
  display: grid;
  gap: 14px;
  margin: 0 0 28px;
  padding: 18px;
  border: 1px solid rgba(51, 65, 85, 0.84);
  border-radius: 22px;
  background: rgba(15, 23, 42, 0.68);
}

.filter-bar {
  grid-template-columns: 1fr 180px 180px;
}

.search-panel {
  grid-template-columns: minmax(0, 1fr) 140px;
}

.search-panel input,
.filter-select {
  padding: 12px 14px;
}

.search-result-note {
  color: var(--muted);
  margin: 0 0 24px;
}

.ranking-list {
  display: grid;
  gap: 16px;
}

.ranking-item {
  display: grid;
  grid-template-columns: 84px 108px minmax(0, 1fr) auto;
  gap: 18px;
  align-items: center;
  padding: 16px;
  border: 1px solid rgba(51, 65, 85, 0.9);
  border-radius: 22px;
  background: rgba(15, 23, 42, 0.74);
}

.ranking-number {
  color: var(--gold-400);
  font-size: 2rem;
  font-weight: 900;
  text-align: center;
}

.ranking-poster {
  overflow: hidden;
  aspect-ratio: 2 / 3;
  border-radius: 14px;
  background: #0f172a;
}

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

.ranking-info h2 {
  margin: 0 0 8px;
  font-size: 1.25rem;
}

.ranking-info p {
  margin: 0;
  color: var(--muted);
}

.detail-hero {
  padding: 50px 0 26px;
  background:
    radial-gradient(circle at 20% 0%, rgba(234, 179, 8, 0.15), transparent 28rem),
    linear-gradient(180deg, rgba(15, 23, 42, 0.85), rgba(2, 6, 23, 0));
}

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

.player-card,
.detail-panel,
.related-panel,
.text-panel {
  border: 1px solid rgba(51, 65, 85, 0.88);
  border-radius: 26px;
  background: rgba(15, 23, 42, 0.78);
  box-shadow: var(--shadow);
}

.player-card {
  overflow: hidden;
}

.player-wrap {
  position: relative;
  aspect-ratio: 16 / 9;
  background: #000000;
}

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

.player-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background:
    radial-gradient(circle at 50% 45%, rgba(234, 179, 8, 0.18), transparent 16rem),
    linear-gradient(180deg, rgba(2, 6, 23, 0.28), rgba(2, 6, 23, 0.78));
  cursor: pointer;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

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

.big-play {
  width: 86px;
  height: 86px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--gold-400), var(--gold-600));
  color: #020617;
  font-size: 2.3rem;
  line-height: 1;
  box-shadow: var(--glow);
}

.player-caption {
  padding: 18px 20px;
  color: var(--muted);
}

.detail-poster {
  overflow: hidden;
  border-radius: 26px;
  background: #0f172a;
}

.detail-poster img {
  width: 100%;
  display: block;
}

.detail-panel {
  padding: 22px;
}

.detail-panel h2,
.related-panel h2,
.text-panel h2 {
  margin: 0 0 16px;
  color: var(--gold-300);
  font-size: 1.28rem;
}

.detail-facts {
  display: grid;
  gap: 10px;
  margin: 0;
}

.detail-facts div {
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr);
  gap: 12px;
  color: var(--soft);
}

.detail-facts dt {
  color: var(--muted);
}

.detail-facts dd {
  margin: 0;
}

.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 18px;
}

.tag-list span {
  padding: 6px 10px;
  border: 1px solid rgba(234, 179, 8, 0.25);
  border-radius: 999px;
  background: rgba(234, 179, 8, 0.1);
  color: var(--gold-300);
  font-size: 0.84rem;
}

.text-panel {
  margin-top: 28px;
  padding: 26px;
}

.text-panel p {
  margin: 0 0 16px;
  color: #d1d5db;
}

.related-panel {
  margin-top: 28px;
  padding: 26px;
}

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

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

.mini-poster {
  aspect-ratio: 2 / 3;
  margin-bottom: 10px;
  border-radius: 16px;
}

.mini-card span {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 0.78rem;
}

.static-page {
  padding: 68px 0;
}

.static-page article {
  padding: 30px;
  border: 1px solid rgba(51, 65, 85, 0.88);
  border-radius: 26px;
  background: rgba(15, 23, 42, 0.72);
}

.static-page h1 {
  margin: 0 0 18px;
  font-size: clamp(2rem, 5vw, 3.4rem);
}

.static-page h2 {
  color: var(--gold-300);
}

.static-page p {
  color: #d1d5db;
}

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

  .menu-toggle {
    display: block;
  }

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

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

  .hero-poster-card {
    max-width: 440px;
  }
}

@media (max-width: 820px) {
  .hero {
    min-height: auto;
  }

  .hero-slide {
    position: relative;
    display: none;
  }

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

  .hero-content {
    padding: 64px 0 96px;
  }

  .section-heading,
  .ranking-item {
    align-items: stretch;
  }

  .section-heading,
  .hero-actions,
  .section-actions,
  .detail-actions {
    flex-direction: column;
  }

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

  .filter-bar,
  .search-panel,
  .ranking-item {
    grid-template-columns: 1fr;
  }

  .ranking-number {
    text-align: left;
  }
}

@media (max-width: 520px) {
  .header-inner,
  .page-shell,
  .section-block,
  .detail-shell,
  .mobile-nav {
    width: min(100% - 22px, 1180px);
  }

  .brand-text {
    font-size: 1.05rem;
  }

  .movie-grid,
  .category-grid,
  .mini-grid {
    gap: 14px;
  }

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

  .hero-poster-card {
    min-height: 330px;
  }

  .hero-poster-card img {
    min-height: 330px;
  }

  .detail-panel,
  .related-panel,
  .text-panel,
  .static-page article {
    padding: 20px;
  }
}
