:root {
  color-scheme: dark;
  --moon-950: #05070f;
  --moon-925: #080b16;
  --moon-900: #0d1020;
  --moon-850: #12172a;
  --moon-800: #182033;
  --moon-700: #242d45;
  --lunar-100: #f8fafc;
  --lunar-200: #e8edf6;
  --lunar-300: #c9d2e3;
  --lunar-400: #93a0b8;
  --gold-300: #fde68a;
  --gold-400: #f6c453;
  --gold-500: #e6a932;
  --gold-600: #c8871f;
  --line: rgba(255, 255, 255, 0.08);
  --shadow: 0 22px 70px rgba(0, 0, 0, 0.35);
  font-family: Inter, "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--lunar-200);
  background:
    radial-gradient(circle at 18% 10%, rgba(246, 196, 83, 0.12), transparent 34%),
    radial-gradient(circle at 80% 0%, rgba(88, 124, 255, 0.1), transparent 30%),
    linear-gradient(180deg, var(--moon-900), var(--moon-950) 58%);
}

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;
  border-bottom: 1px solid var(--line);
  background: rgba(5, 7, 15, 0.78);
  backdrop-filter: blur(18px);
}

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

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

.logo-mark {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  color: var(--moon-950);
  background: linear-gradient(135deg, var(--gold-300), var(--gold-600));
  box-shadow: 0 8px 26px rgba(230, 169, 50, 0.32);
}

.logo-text {
  font-size: 20px;
  color: var(--lunar-100);
}

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

.nav-link,
.mobile-link {
  color: var(--lunar-300);
  border-radius: 999px;
  transition: background 0.2s ease, color 0.2s ease;
}

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

.nav-link:hover,
.nav-link.active,
.mobile-link:hover,
.mobile-link.active {
  color: var(--moon-950);
  background: var(--gold-400);
}

.mobile-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.05);
  cursor: pointer;
}

.mobile-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  margin: 4px auto;
  border-radius: 4px;
  background: var(--lunar-100);
}

.mobile-nav {
  display: none;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto 14px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(13, 16, 32, 0.95);
}

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

.mobile-link {
  padding: 12px 14px;
}

.hero-slider {
  position: relative;
  min-height: 72vh;
  overflow: hidden;
  border-bottom: 1px solid var(--line);
  background: var(--moon-950);
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(260px, 390px);
  align-items: center;
  gap: 48px;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 80px 0 70px;
  opacity: 0;
  pointer-events: none;
  transform: translateY(18px) scale(0.985);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.hero-slide.active {
  position: relative;
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0) scale(1);
}

.hero-bg {
  position: fixed;
  inset: 0;
  background-size: cover;
  background-position: center;
  opacity: 0.18;
  filter: blur(12px) saturate(1.05);
  transform: scale(1.05);
}

.hero-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(5, 7, 15, 0.94), rgba(5, 7, 15, 0.68), rgba(5, 7, 15, 0.94)),
    linear-gradient(180deg, rgba(5, 7, 15, 0.4), var(--moon-950));
}

.hero-content,
.hero-poster {
  position: relative;
  z-index: 2;
}

.hero-kicker,
.section-kicker {
  display: inline-flex;
  align-items: center;
  margin-bottom: 12px;
  color: var(--gold-300);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.hero-content h1 {
  margin: 0;
  color: var(--lunar-100);
  font-size: clamp(42px, 8vw, 84px);
  line-height: 0.98;
  letter-spacing: -0.06em;
}

.hero-content p {
  max-width: 680px;
  margin: 24px 0 0;
  color: var(--lunar-300);
  font-size: clamp(17px, 2vw, 22px);
  line-height: 1.8;
}

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

.hero-tags {
  margin-top: 26px;
}

.hero-tags span,
.tag-row span {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 5px 10px;
  border: 1px solid rgba(246, 196, 83, 0.24);
  border-radius: 999px;
  color: var(--gold-300);
  background: rgba(246, 196, 83, 0.08);
  font-size: 12px;
}

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

.primary-btn,
.ghost-btn,
.section-more {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  font-weight: 800;
  transition: transform 0.2s ease, background 0.2s ease, border-color 0.2s ease;
}

.primary-btn {
  min-height: 48px;
  padding: 0 22px;
  color: var(--moon-950);
  background: linear-gradient(135deg, var(--gold-300), var(--gold-600));
  box-shadow: 0 14px 34px rgba(230, 169, 50, 0.28);
}

.primary-btn.small {
  min-height: 40px;
  padding: 0 16px;
  border-radius: 12px;
  font-size: 14px;
}

.ghost-btn,
.section-more {
  min-height: 48px;
  padding: 0 20px;
  color: var(--lunar-200);
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.06);
}

.primary-btn:hover,
.ghost-btn:hover,
.section-more:hover {
  transform: translateY(-2px);
}

.hero-poster {
  display: block;
  padding: 10px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 34px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0.04));
  box-shadow: var(--shadow);
}

.hero-poster img {
  width: 100%;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  border-radius: 25px;
}

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

.hero-dot {
  width: 11px;
  height: 11px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.32);
  cursor: pointer;
}

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

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

.section-soft {
  background: rgba(255, 255, 255, 0.03);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

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

.section-heading h2,
.quick-search h2,
.ranking-column h2,
.text-panel h2,
.side-panel h2,
.player-heading h2 {
  margin: 0;
  color: var(--lunar-100);
  font-size: clamp(28px, 4vw, 42px);
  letter-spacing: -0.04em;
}

.section-heading p,
.quick-search p,
.sub-hero p,
.category-info p {
  max-width: 760px;
  margin: 10px 0 0;
  color: var(--lunar-400);
  line-height: 1.8;
}

.quick-search-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
  margin-bottom: 24px;
}

.search-panel {
  margin-bottom: 28px;
}

.search-box {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 14px;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.06);
}

.search-box span {
  color: var(--gold-300);
  font-weight: 800;
}

.search-box input {
  width: 100%;
  border: 0;
  outline: 0;
  color: var(--lunar-100);
  background: transparent;
}

.filter-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 14px;
}

.filter-buttons button {
  min-height: 38px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--lunar-300);
  background: rgba(255, 255, 255, 0.05);
  cursor: pointer;
}

.filter-buttons button.active {
  color: var(--moon-950);
  border-color: transparent;
  background: var(--gold-400);
  font-weight: 800;
}

.empty-state {
  display: none;
  margin: 24px 0 0;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 16px;
  color: var(--lunar-400);
  background: rgba(255, 255, 255, 0.04);
}

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

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

.movie-card,
.wide-card,
.category-tile,
.category-card-large,
.text-panel,
.side-panel,
.player-card {
  border: 1px solid var(--line);
  background: rgba(13, 16, 32, 0.68);
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.2);
}

.movie-card {
  overflow: hidden;
  border-radius: 24px;
  transition: transform 0.22s ease, border-color 0.22s ease, box-shadow 0.22s ease;
}

.movie-card:hover,
.wide-card:hover,
.category-tile:hover,
.category-card-large:hover {
  transform: translateY(-5px);
  border-color: rgba(246, 196, 83, 0.32);
  box-shadow: 0 22px 56px rgba(0, 0, 0, 0.32);
}

.poster-link {
  position: relative;
  display: block;
  overflow: hidden;
  background: var(--moon-800);
}

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

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

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

.movie-meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: var(--lunar-400);
  font-size: 12px;
}

.movie-card h3,
.wide-card h3 {
  margin: 10px 0 0;
  color: var(--lunar-100);
  font-size: 17px;
  line-height: 1.35;
}

.movie-card p,
.wide-card p {
  margin: 8px 0 12px;
  color: var(--lunar-400);
  font-size: 13px;
  line-height: 1.7;
}

.rank-badge,
.wide-rank {
  position: absolute;
  z-index: 2;
  display: grid;
  place-items: center;
  color: var(--moon-950);
  background: linear-gradient(135deg, var(--gold-300), var(--gold-600));
  font-weight: 900;
}

.rank-badge {
  top: 10px;
  left: 10px;
  min-width: 34px;
  height: 34px;
  border-radius: 12px;
}

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

.wide-card {
  position: relative;
  display: grid;
  grid-template-columns: 112px minmax(0, 1fr);
  gap: 16px;
  align-items: center;
  padding: 12px;
  border-radius: 22px;
  transition: transform 0.22s ease, border-color 0.22s ease, box-shadow 0.22s ease;
}

.wide-cover {
  overflow: hidden;
  border-radius: 16px;
}

.wide-cover img {
  width: 112px;
  aspect-ratio: 2 / 3;
  object-fit: cover;
}

.wide-body {
  min-width: 0;
  position: relative;
}

.wide-rank {
  top: -4px;
  right: 0;
  width: 30px;
  height: 30px;
  border-radius: 10px;
  font-size: 13px;
}

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

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

.category-tile img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.34;
}

.category-tile::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent, rgba(5, 7, 15, 0.92));
}

.category-tile span,
.category-tile p {
  position: relative;
  z-index: 2;
}

.category-tile span {
  color: var(--lunar-100);
  font-size: 22px;
  font-weight: 900;
}

.category-tile p {
  margin: 8px 0 0;
  color: var(--lunar-300);
  font-size: 13px;
  line-height: 1.6;
}

.sub-hero {
  padding: 86px 0 70px;
  border-bottom: 1px solid var(--line);
  background:
    radial-gradient(circle at 20% 0%, rgba(246, 196, 83, 0.14), transparent 34%),
    linear-gradient(180deg, rgba(18, 23, 42, 0.92), rgba(5, 7, 15, 0.95));
}

.sub-hero h1 {
  margin: 0;
  color: var(--lunar-100);
  font-size: clamp(42px, 7vw, 76px);
  letter-spacing: -0.06em;
}

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

.category-card-large {
  display: grid;
  grid-template-columns: 240px minmax(0, 1fr);
  gap: 24px;
  padding: 16px;
  border-radius: 28px;
  transition: transform 0.22s ease, border-color 0.22s ease, box-shadow 0.22s ease;
}

.category-art {
  overflow: hidden;
  border-radius: 22px;
}

.category-art img {
  width: 100%;
  height: 100%;
  min-height: 260px;
  object-fit: cover;
}

.category-info {
  align-self: center;
}

.category-info h2 {
  margin: 0;
  color: var(--lunar-100);
  font-size: 32px;
}

.category-preview {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 16px 0 22px;
}

.category-preview span {
  padding: 6px 10px;
  border-radius: 999px;
  color: var(--lunar-300);
  background: rgba(255, 255, 255, 0.06);
  font-size: 13px;
}

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

.ranking-column {
  min-width: 0;
}

.ranking-column h2 {
  margin-bottom: 18px;
  font-size: 28px;
}

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

.ranking-list .wide-card {
  grid-template-columns: 86px minmax(0, 1fr);
}

.ranking-list .wide-cover img {
  width: 86px;
}

.detail-head {
  padding: 70px 0;
  border-bottom: 1px solid var(--line);
  background:
    radial-gradient(circle at 78% 12%, rgba(246, 196, 83, 0.13), transparent 30%),
    linear-gradient(180deg, rgba(18, 23, 42, 0.86), rgba(5, 7, 15, 0.98));
}

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

.detail-poster {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 30px;
  padding: 10px;
  background: rgba(255, 255, 255, 0.06);
  box-shadow: var(--shadow);
}

.detail-poster img {
  width: 100%;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  border-radius: 22px;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin-bottom: 16px;
  color: var(--lunar-400);
  font-size: 14px;
}

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

.detail-info h1 {
  margin: 0;
  color: var(--lunar-100);
  font-size: clamp(38px, 6vw, 66px);
  letter-spacing: -0.06em;
}

.detail-lead {
  max-width: 760px;
  margin: 18px 0 0;
  color: var(--lunar-300);
  font-size: 19px;
  line-height: 1.8;
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 22px;
}

.detail-meta span {
  padding: 8px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--lunar-300);
  background: rgba(255, 255, 255, 0.05);
  font-size: 13px;
}

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

.player-card {
  padding: 18px;
  border-radius: 28px;
}

.player-heading {
  margin-bottom: 16px;
}

.player-heading h2 {
  font-size: 30px;
}

.video-frame {
  position: relative;
  overflow: hidden;
  border-radius: 22px;
  background: #000;
  aspect-ratio: 16 / 9;
}

.movie-video {
  width: 100%;
  height: 100%;
  display: block;
  background: #000;
}

.play-layer {
  position: absolute;
  inset: 0;
  z-index: 3;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  border: 0;
  color: var(--lunar-100);
  background: linear-gradient(180deg, rgba(5, 7, 15, 0.28), rgba(5, 7, 15, 0.72));
  cursor: pointer;
}

.play-layer.is-hidden {
  display: none;
}

.play-icon {
  width: 76px;
  height: 76px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--gold-300), var(--gold-600));
  box-shadow: 0 12px 44px rgba(230, 169, 50, 0.35);
}

.play-icon::before {
  content: "";
  width: 0;
  height: 0;
  margin-left: 6px;
  border-top: 15px solid transparent;
  border-bottom: 15px solid transparent;
  border-left: 23px solid var(--moon-950);
}

.article-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 24px;
  align-items: start;
}

.text-panel,
.side-panel {
  border-radius: 26px;
  padding: 26px;
}

.text-panel h2,
.side-panel h2 {
  margin-top: 0;
  font-size: 28px;
}

.text-panel p {
  color: var(--lunar-300);
  font-size: 17px;
  line-height: 2;
}

.side-panel dl {
  display: grid;
  grid-template-columns: 70px minmax(0, 1fr);
  gap: 12px;
  margin: 0;
}

.side-panel dt {
  color: var(--gold-300);
  font-weight: 800;
}

.side-panel dd {
  margin: 0;
  color: var(--lunar-300);
}

.site-footer {
  border-top: 1px solid var(--line);
  background: rgba(5, 7, 15, 0.86);
}

.footer-inner {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 34px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.footer-logo {
  color: var(--lunar-100);
  font-size: 20px;
}

.site-footer p {
  margin: 10px 0 0;
  color: var(--lunar-400);
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  color: var(--lunar-300);
}

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

[data-movie-card].is-hidden {
  display: none;
}

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

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

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

  .mobile-toggle {
    display: block;
  }

  .hero-slide {
    grid-template-columns: 1fr;
    gap: 26px;
    padding-top: 58px;
  }

  .hero-poster {
    max-width: 280px;
    margin: 0 auto;
  }

  .section-heading,
  .quick-search-inner,
  .footer-inner {
    align-items: start;
    flex-direction: column;
  }

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

  .wide-grid,
  .category-card-large,
  .detail-layout,
  .article-layout,
  .ranking-layout {
    grid-template-columns: 1fr;
  }

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

  .category-art img {
    max-height: 300px;
  }
}

@media (max-width: 560px) {
  .container,
  .header-inner,
  .footer-inner,
  .mobile-nav {
    width: min(100% - 24px, 1180px);
  }

  .header-inner {
    height: 64px;
  }

  .logo-text {
    font-size: 18px;
  }

  .hero-slider {
    min-height: auto;
  }

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

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

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

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

  .movie-card h3 {
    font-size: 15px;
  }

  .movie-card p {
    display: none;
  }

  .wide-card {
    grid-template-columns: 86px minmax(0, 1fr);
  }

  .wide-cover img {
    width: 86px;
  }

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

  .detail-head,
  .sub-hero {
    padding: 50px 0;
  }

  .detail-poster {
    max-width: 260px;
    margin: 0 auto;
  }

  .text-panel,
  .side-panel,
  .player-card {
    padding: 18px;
    border-radius: 22px;
  }
}
