:root {
  color-scheme: dark;
  --bg: #020617;
  --bg-soft: #0f172a;
  --panel: rgba(15, 23, 42, 0.76);
  --panel-solid: #111827;
  --line: rgba(148, 163, 184, 0.18);
  --text: #f8fafc;
  --muted: #94a3b8;
  --cyan: #22d3ee;
  --blue: #3b82f6;
  --violet: #8b5cf6;
  --pink: #ec4899;
  --radius: 22px;
  --shadow: 0 24px 70px rgba(0, 0, 0, 0.35);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--text);
  font-family: Inter, "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
  background:
    radial-gradient(circle at 12% 8%, rgba(34, 211, 238, 0.18), transparent 30rem),
    radial-gradient(circle at 88% 0%, rgba(59, 130, 246, 0.22), transparent 32rem),
    linear-gradient(180deg, #020617 0%, #08111f 48%, #020617 100%);
}

body.menu-open {
  overflow: hidden;
}

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

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

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

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

.nav-bar {
  min-height: 68px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 22px;
  font-weight: 900;
  letter-spacing: -0.03em;
  white-space: nowrap;
}

.logo span:last-child {
  background: linear-gradient(90deg, var(--cyan), var(--blue), var(--violet));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.logo-mark {
  width: 34px;
  height: 34px;
  display: inline-grid;
  place-items: center;
  border-radius: 12px;
  color: #00111a;
  background: linear-gradient(135deg, var(--cyan), var(--blue));
  box-shadow: 0 10px 30px rgba(34, 211, 238, 0.24);
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 24px;
  color: #dbeafe;
  font-size: 15px;
}

.desktop-nav > a,
.nav-dropdown > a {
  padding: 24px 0;
  transition: color 0.2s ease;
}

.desktop-nav a:hover,
.desktop-nav .is-active {
  color: var(--cyan);
}

.nav-dropdown {
  position: relative;
}

.dropdown-panel {
  position: absolute;
  top: 64px;
  left: -18px;
  min-width: 170px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(15, 23, 42, 0.96);
  box-shadow: var(--shadow);
  opacity: 0;
  pointer-events: none;
  transform: translateY(10px);
  transition: all 0.2s ease;
}

.nav-dropdown:hover .dropdown-panel {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

.dropdown-panel a {
  display: block;
  padding: 10px 12px;
  color: #dbeafe;
  border-radius: 10px;
}

.dropdown-panel a:hover {
  color: white;
  background: rgba(34, 211, 238, 0.12);
}

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

.nav-search input,
.filter-bar input,
.filter-bar select {
  border: 1px solid rgba(148, 163, 184, 0.28);
  outline: none;
  color: white;
  background: rgba(15, 23, 42, 0.82);
  border-radius: 999px;
  padding: 11px 14px;
}

.nav-search input {
  width: 230px;
}

.nav-search button,
.btn,
.player-button,
.filter-bar button {
  border: 0;
  color: #00111a;
  cursor: pointer;
  border-radius: 999px;
  font-weight: 800;
  padding: 11px 18px;
  background: linear-gradient(135deg, var(--cyan), var(--blue));
  box-shadow: 0 12px 28px rgba(34, 211, 238, 0.22);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.nav-search button:hover,
.btn:hover,
.player-button:hover,
.filter-bar button:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 36px rgba(34, 211, 238, 0.32);
}

.menu-toggle {
  display: none;
  border: 1px solid var(--line);
  border-radius: 12px;
  color: white;
  background: rgba(15, 23, 42, 0.8);
  width: 44px;
  height: 44px;
  font-size: 22px;
}

.mobile-panel {
  display: none;
  border-top: 1px solid var(--line);
  background: rgba(2, 6, 23, 0.96);
}

.mobile-panel a {
  display: block;
  padding: 16px 24px;
  border-bottom: 1px solid rgba(148, 163, 184, 0.1);
}

.hero {
  position: relative;
  min-height: 720px;
  overflow: hidden;
  border-bottom: 1px solid var(--line);
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(2, 6, 23, 0.98) 0%, rgba(2, 6, 23, 0.8) 45%, rgba(2, 6, 23, 0.35) 100%),
    radial-gradient(circle at 70% 30%, rgba(34, 211, 238, 0.28), transparent 24rem),
    radial-gradient(circle at 85% 65%, rgba(139, 92, 246, 0.18), transparent 26rem);
  z-index: 2;
}

.hero-bg {
  position: absolute;
  inset: 0;
  opacity: 0;
  transform: scale(1.04);
  transition: opacity 0.8s ease, transform 1.4s ease;
}

.hero-bg.is-active {
  opacity: 0.5;
  transform: scale(1);
}

.hero-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(1.05) contrast(1.05);
}

.hero-inner {
  position: relative;
  z-index: 3;
  display: grid;
  grid-template-columns: 1.04fr 0.96fr;
  gap: 44px;
  align-items: center;
  min-height: 720px;
  padding: 70px 0 54px;
}

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

.hero-kicker,
.section-kicker,
.breadcrumbs {
  color: var(--cyan);
  font-size: 14px;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.hero h1 {
  margin: 16px 0;
  font-size: clamp(42px, 7vw, 86px);
  line-height: 0.98;
  letter-spacing: -0.065em;
}

.hero h1 span {
  display: block;
  background: linear-gradient(90deg, #ffffff, #bae6fd, #67e8f9);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-desc {
  color: #cbd5e1;
  font-size: 18px;
  line-height: 1.9;
  margin: 0 0 26px;
}

.hero-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 14px;
  margin-bottom: 30px;
}

.btn-ghost {
  color: white;
  border: 1px solid rgba(148, 163, 184, 0.28);
  background: rgba(15, 23, 42, 0.62);
  box-shadow: none;
}

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

.hero-tags span,
.tag-row span,
.meta-pill {
  color: #dbeafe;
  border: 1px solid rgba(148, 163, 184, 0.22);
  background: rgba(15, 23, 42, 0.72);
  border-radius: 999px;
  padding: 7px 11px;
  font-size: 12px;
}

.hero-panel {
  position: relative;
  display: grid;
  gap: 16px;
}

.hero-feature {
  position: relative;
  min-height: 420px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 32px;
  overflow: hidden;
  background: rgba(15, 23, 42, 0.55);
  box-shadow: var(--shadow);
}

.hero-feature img {
  width: 100%;
  height: 100%;
  min-height: 420px;
  object-fit: cover;
}

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

.hero-feature-content {
  position: absolute;
  left: 26px;
  right: 26px;
  bottom: 24px;
  z-index: 2;
}

.hero-feature-content h2 {
  margin: 8px 0 8px;
  font-size: 30px;
  letter-spacing: -0.04em;
}

.hero-feature-content p {
  color: #cbd5e1;
  line-height: 1.8;
  margin: 0;
}

.hero-thumbs {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}

.hero-thumb {
  border: 1px solid rgba(148, 163, 184, 0.2);
  border-radius: 18px;
  overflow: hidden;
  min-height: 108px;
  background: rgba(15, 23, 42, 0.7);
  cursor: pointer;
  opacity: 0.76;
  transition: opacity 0.2s ease, transform 0.2s ease, border-color 0.2s ease;
}

.hero-thumb.is-active,
.hero-thumb:hover {
  opacity: 1;
  transform: translateY(-3px);
  border-color: rgba(34, 211, 238, 0.62);
}

.hero-thumb img {
  width: 100%;
  height: 108px;
  object-fit: cover;
}

main {
  position: relative;
}

.section {
  padding: 76px 0 0;
}

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

.section-head h2 {
  margin: 6px 0;
  font-size: clamp(28px, 4vw, 42px);
  letter-spacing: -0.04em;
}

.section-head p {
  margin: 0;
  color: var(--muted);
  line-height: 1.7;
}

.section-link {
  color: var(--cyan);
  font-weight: 800;
}

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

.movie-card {
  border: 1px solid rgba(148, 163, 184, 0.14);
  border-radius: var(--radius);
  overflow: hidden;
  background: rgba(15, 23, 42, 0.68);
  box-shadow: 0 16px 46px rgba(0, 0, 0, 0.18);
  transition: transform 0.22s ease, border-color 0.22s ease, box-shadow 0.22s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  border-color: rgba(34, 211, 238, 0.42);
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.28);
}

.poster {
  position: relative;
  display: block;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  background:
    linear-gradient(135deg, rgba(34, 211, 238, 0.18), rgba(59, 130, 246, 0.16)),
    #111827;
}

.poster img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.32s ease;
}

.poster img.is-missing {
  opacity: 0;
}

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

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

.poster-badge {
  position: absolute;
  left: 12px;
  bottom: 12px;
  z-index: 2;
  color: #00111a;
  font-weight: 900;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--cyan), #e0f2fe);
  padding: 6px 10px;
  font-size: 12px;
}

.card-body {
  padding: 16px;
}

.card-meta {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  color: var(--muted);
  font-size: 12px;
  margin-bottom: 10px;
}

.card-meta a {
  color: var(--cyan);
}

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

.card-body p {
  display: -webkit-box;
  min-height: 68px;
  margin: 0 0 14px;
  color: #aab8ca;
  line-height: 1.7;
  overflow: hidden;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
}

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

.rank-item {
  display: grid;
  grid-template-columns: 58px 90px 1fr auto;
  gap: 18px;
  align-items: center;
  border: 1px solid rgba(148, 163, 184, 0.14);
  border-radius: 18px;
  background: rgba(15, 23, 42, 0.66);
  padding: 12px;
}

.rank-index {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border-radius: 16px;
  color: #00111a;
  font-size: 20px;
  font-weight: 900;
  background: linear-gradient(135deg, var(--cyan), var(--blue));
}

.rank-item img {
  width: 90px;
  height: 112px;
  object-fit: cover;
  border-radius: 14px;
  background: #111827;
}

.rank-item h3 {
  margin: 0 0 8px;
}

.rank-item p {
  margin: 0;
  color: var(--muted);
  line-height: 1.7;
}

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

.category-card {
  position: relative;
  min-height: 168px;
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 24px;
  background:
    radial-gradient(circle at top right, rgba(34, 211, 238, 0.2), transparent 60%),
    rgba(15, 23, 42, 0.72);
  padding: 22px;
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.category-card:hover {
  transform: translateY(-5px);
  border-color: rgba(34, 211, 238, 0.42);
}

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

.category-card p {
  margin: 0;
  color: var(--muted);
  line-height: 1.7;
}

.category-card strong {
  position: absolute;
  right: 20px;
  bottom: 16px;
  color: rgba(255, 255, 255, 0.16);
  font-size: 52px;
}

.page-hero {
  padding: 72px 0 34px;
}

.page-hero h1 {
  margin: 10px 0 12px;
  font-size: clamp(34px, 5vw, 58px);
  letter-spacing: -0.05em;
}

.page-hero p {
  max-width: 820px;
  margin: 0;
  color: #cbd5e1;
  line-height: 1.9;
  font-size: 17px;
}

.filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  border: 1px solid rgba(148, 163, 184, 0.14);
  border-radius: 20px;
  background: rgba(15, 23, 42, 0.64);
  padding: 14px;
  margin-bottom: 24px;
}

.filter-bar input {
  flex: 1 1 300px;
}

.detail-hero {
  padding: 58px 0 30px;
}

.breadcrumbs {
  margin-bottom: 18px;
  letter-spacing: 0.08em;
}

.breadcrumbs a {
  color: #bae6fd;
}

.detail-layout {
  display: grid;
  grid-template-columns: 360px 1fr;
  gap: 34px;
  align-items: start;
}

.detail-poster {
  border-radius: 30px;
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, 0.16);
  box-shadow: var(--shadow);
  background:
    linear-gradient(135deg, rgba(34, 211, 238, 0.18), rgba(59, 130, 246, 0.16)),
    #111827;
}

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

.detail-info h1 {
  margin: 0 0 16px;
  font-size: clamp(36px, 5.6vw, 64px);
  line-height: 1.05;
  letter-spacing: -0.06em;
}

.meta-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 18px 0 22px;
}

.detail-info p {
  color: #d7e3f1;
  line-height: 1.9;
  font-size: 17px;
}

.content-panel {
  border: 1px solid rgba(148, 163, 184, 0.14);
  border-radius: 28px;
  background: rgba(15, 23, 42, 0.62);
  padding: 26px;
  margin-top: 24px;
}

.content-panel h2 {
  margin: 0 0 14px;
}

.player-wrap {
  position: relative;
  overflow: hidden;
  border-radius: 28px;
  border: 1px solid rgba(148, 163, 184, 0.18);
  background: #000;
  box-shadow: var(--shadow);
}

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

.player-cover {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background:
    linear-gradient(180deg, rgba(2, 6, 23, 0.15), rgba(2, 6, 23, 0.88)),
    var(--player-image, none) center / cover;
  z-index: 2;
}

.player-wrap.is-playing .player-cover {
  display: none;
}

.player-cover-inner {
  text-align: center;
  padding: 24px;
}

.player-button {
  width: 86px;
  height: 86px;
  padding: 0;
  font-size: 30px;
  border-radius: 999px;
}

.player-cover h2 {
  margin: 18px 0 8px;
}

.player-cover p {
  margin: 0;
  color: #cbd5e1;
}

.search-results-note {
  color: var(--muted);
  margin-bottom: 18px;
}

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

.footer-grid {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
}

.footer-logo {
  font-size: 20px;
}

.site-footer p {
  color: var(--muted);
  line-height: 1.8;
  margin: 14px 0 0;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  color: #cbd5e1;
}

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

  .menu-toggle {
    display: block;
  }

  .mobile-panel.is-open {
    display: block;
  }

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

  .hero {
    min-height: auto;
  }

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

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

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

@media (max-width: 720px) {
  .container {
    width: min(100% - 22px, 1200px);
  }

  .hero h1 {
    font-size: 42px;
  }

  .hero-desc,
  .detail-info p {
    font-size: 15px;
  }

  .hero-feature,
  .hero-feature img {
    min-height: 330px;
  }

  .hero-thumbs {
    grid-template-columns: repeat(2, 1fr);
  }

  .section {
    padding-top: 52px;
  }

  .section-head,
  .footer-grid {
    display: block;
  }

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

  .card-body {
    padding: 13px;
  }

  .card-body h3 {
    font-size: 16px;
  }

  .rank-item {
    grid-template-columns: 42px 68px 1fr;
  }

  .rank-item .btn {
    grid-column: 1 / -1;
    text-align: center;
  }

  .rank-index {
    width: 38px;
    height: 38px;
    font-size: 16px;
  }

  .rank-item img {
    width: 68px;
    height: 90px;
  }

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