:root {
  color-scheme: dark;
  --bg: #020617;
  --panel: rgba(15, 23, 42, 0.86);
  --panel-strong: #0f172a;
  --panel-soft: rgba(30, 41, 59, 0.72);
  --line: rgba(148, 163, 184, 0.18);
  --text: #f8fafc;
  --muted: #94a3b8;
  --soft: #cbd5e1;
  --cyan: #22d3ee;
  --blue: #38bdf8;
  --emerald: #34d399;
  --orange: #f59e0b;
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.4);
  --radius: 24px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at 15% 5%, rgba(34, 211, 238, 0.16), transparent 32rem),
    radial-gradient(circle at 85% 12%, rgba(16, 185, 129, 0.13), transparent 30rem),
    linear-gradient(180deg, #020617 0%, #07111f 48%, #020617 100%);
}

body.nav-open {
  overflow: hidden;
}

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

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

button,
input {
  font: inherit;
}

button {
  cursor: pointer;
}

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

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

.logo {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-weight: 900;
  letter-spacing: -0.03em;
}

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

.logo-text {
  font-size: 1.18rem;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 26px;
  color: var(--soft);
}

.nav-links a,
.nav-links button {
  color: var(--soft);
  border: 0;
  background: transparent;
  padding: 10px 0;
  transition: color 0.2s ease;
}

.nav-links a:hover,
.nav-links button:hover,
.nav-links .active {
  color: #fff;
}

.nav-dropdown {
  position: relative;
}

.dropdown-menu {
  position: absolute;
  top: 100%;
  left: 0;
  width: 210px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(15, 23, 42, 0.97);
  box-shadow: var(--shadow);
  opacity: 0;
  pointer-events: none;
  transform: translateY(8px);
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.nav-dropdown:hover .dropdown-menu,
.nav-dropdown:focus-within .dropdown-menu {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

.dropdown-menu a {
  display: block;
  padding: 10px 12px;
  border-radius: 12px;
}

.dropdown-menu a:hover {
  color: #fff;
  background: rgba(51, 65, 85, 0.85);
}

.header-search {
  display: flex;
  align-items: center;
  gap: 8px;
  width: min(330px, 28vw);
}

.header-search input,
.filter-box input {
  width: 100%;
  color: #fff;
  border: 1px solid var(--line);
  border-radius: 999px;
  outline: none;
  background: rgba(15, 23, 42, 0.92);
  padding: 11px 16px;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.header-search input:focus,
.filter-box input:focus {
  border-color: rgba(34, 211, 238, 0.8);
  box-shadow: 0 0 0 4px rgba(34, 211, 238, 0.12);
}

.search-btn,
.menu-btn {
  border: 0;
  color: #fff;
  background: rgba(30, 41, 59, 0.92);
  border-radius: 999px;
  padding: 11px 14px;
}

.menu-btn {
  display: none;
}

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

.mobile-panel-inner {
  width: min(1280px, calc(100% - 32px));
  margin: 0 auto;
  padding: 18px 0 24px;
  display: grid;
  gap: 12px;
}

.mobile-panel a {
  color: var(--soft);
  padding: 12px 0;
  border-bottom: 1px solid rgba(148, 163, 184, 0.08);
}

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

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

.hero-stage {
  position: relative;
  min-height: 72vh;
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.6s ease;
}

.hero-slide.active {
  opacity: 1;
  pointer-events: auto;
}

.hero-bg {
  position: absolute;
  inset: 0;
  overflow: hidden;
}

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

.hero-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(2, 6, 23, 0.98) 0%, rgba(2, 6, 23, 0.78) 42%, rgba(2, 6, 23, 0.26) 100%),
    linear-gradient(180deg, rgba(2, 6, 23, 0.1) 0%, rgba(2, 6, 23, 0.92) 100%);
}

.hero-content {
  position: relative;
  z-index: 2;
  min-height: 72vh;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  align-items: end;
  gap: 48px;
  padding: 90px 0 74px;
}

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

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 18px;
  padding: 8px 13px;
  border: 1px solid rgba(34, 211, 238, 0.28);
  border-radius: 999px;
  color: #a5f3fc;
  background: rgba(14, 116, 144, 0.18);
  font-size: 0.9rem;
}

.hero h1,
.page-hero h1,
.detail-title h1 {
  margin: 0;
  font-size: clamp(2.45rem, 6vw, 5.2rem);
  line-height: 0.96;
  letter-spacing: -0.06em;
}

.hero h1 span {
  background: linear-gradient(135deg, #fff 0%, #a5f3fc 45%, #67e8f9 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-desc {
  max-width: 720px;
  margin: 22px 0 0;
  color: #dbeafe;
  font-size: 1.08rem;
  line-height: 1.8;
}

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

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 46px;
  padding: 12px 18px;
  border-radius: 999px;
  color: #00111a;
  border: 1px solid transparent;
  background: linear-gradient(135deg, var(--cyan), var(--emerald));
  font-weight: 800;
  box-shadow: 0 18px 42px rgba(34, 211, 238, 0.18);
  transition: transform 0.2s ease, filter 0.2s ease;
}

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

.btn.secondary {
  color: #fff;
  background: rgba(15, 23, 42, 0.75);
  border-color: var(--line);
  box-shadow: none;
}

.hero-card {
  align-self: center;
  border: 1px solid rgba(148, 163, 184, 0.18);
  border-radius: 32px;
  overflow: hidden;
  background: rgba(15, 23, 42, 0.68);
  box-shadow: var(--shadow);
  backdrop-filter: blur(16px);
}

.hero-card img {
  height: 440px;
  object-fit: cover;
}

.hero-card-body {
  padding: 18px;
}

.hero-card-title {
  margin: 0 0 8px;
  font-size: 1.3rem;
  font-weight: 900;
}

.meta-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: 0.92rem;
}

.badge {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 4px 10px;
  border-radius: 999px;
  color: #a5f3fc;
  background: rgba(34, 211, 238, 0.12);
  border: 1px solid rgba(34, 211, 238, 0.2);
}

.badge.hot {
  color: #fed7aa;
  background: rgba(245, 158, 11, 0.12);
  border-color: rgba(245, 158, 11, 0.2);
}

.hero-controls {
  position: absolute;
  z-index: 5;
  right: max(16px, calc((100vw - 1280px) / 2));
  bottom: 26px;
  display: flex;
  gap: 10px;
}

.hero-controls button {
  width: 42px;
  height: 42px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: #fff;
  background: rgba(15, 23, 42, 0.78);
}

.section {
  padding: 64px 0;
}

.section.compact {
  padding-top: 42px;
}

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

.section-kicker {
  margin: 0 0 8px;
  color: var(--cyan);
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-size: 0.82rem;
}

.section-title {
  margin: 0;
  font-size: clamp(1.7rem, 3vw, 2.4rem);
  letter-spacing: -0.04em;
}

.section-desc {
  margin: 8px 0 0;
  color: var(--muted);
  line-height: 1.7;
}

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

.category-tile {
  min-height: 138px;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background:
    linear-gradient(135deg, rgba(15, 23, 42, 0.94), rgba(30, 41, 59, 0.74)),
    radial-gradient(circle at top right, rgba(34, 211, 238, 0.18), transparent 70%);
  box-shadow: 0 14px 38px rgba(0, 0, 0, 0.18);
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.category-tile:hover {
  transform: translateY(-4px);
  border-color: rgba(34, 211, 238, 0.45);
}

.category-tile strong {
  display: block;
  font-size: 1.22rem;
  margin-bottom: 10px;
}

.category-tile span {
  color: var(--muted);
  line-height: 1.55;
}

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

.movie-card {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: rgba(15, 23, 42, 0.82);
  box-shadow: 0 16px 44px rgba(0, 0, 0, 0.16);
  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 64px rgba(0, 0, 0, 0.32);
}

.poster {
  position: relative;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  background:
    linear-gradient(135deg, rgba(14, 165, 233, 0.18), rgba(16, 185, 129, 0.12)),
    #0f172a;
}

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

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

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

.score {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 2;
  border-radius: 999px;
  padding: 5px 9px;
  color: #0f172a;
  background: linear-gradient(135deg, #fde68a, #f59e0b);
  font-weight: 900;
  font-size: 0.86rem;
}

.card-body {
  padding: 16px;
}

.card-title {
  margin: 0 0 8px;
  font-size: 1.06rem;
  line-height: 1.35;
  font-weight: 900;
}

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

.card-desc {
  min-height: 46px;
  margin: 12px 0 0;
  color: var(--muted);
  line-height: 1.6;
  font-size: 0.92rem;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}

.tags span {
  border-radius: 999px;
  padding: 4px 9px;
  color: #c4b5fd;
  background: rgba(124, 58, 237, 0.14);
  font-size: 0.82rem;
}

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

.rank-item {
  display: grid;
  grid-template-columns: 68px 78px minmax(0, 1fr) auto;
  gap: 16px;
  align-items: center;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: rgba(15, 23, 42, 0.78);
}

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

.rank-cover {
  width: 78px;
  height: 104px;
  border-radius: 14px;
  overflow: hidden;
  background: #0f172a;
}

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

.rank-title {
  margin: 0 0 8px;
  font-size: 1.12rem;
  font-weight: 900;
}

.rank-summary {
  margin: 8px 0 0;
  color: var(--muted);
  line-height: 1.6;
}

.page-hero {
  padding: 64px 0 42px;
  border-bottom: 1px solid var(--line);
  background:
    radial-gradient(circle at 10% 10%, rgba(34, 211, 238, 0.12), transparent 30rem),
    rgba(15, 23, 42, 0.18);
}

.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 20px;
  color: var(--muted);
  font-size: 0.95rem;
}

.breadcrumbs a:hover {
  color: #fff;
}

.filter-box {
  margin-top: 24px;
  max-width: 560px;
}

.archive-nav,
.pagination {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 28px;
}

.archive-nav a,
.pagination a {
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 9px 14px;
  color: var(--soft);
  background: rgba(15, 23, 42, 0.72);
}

.archive-nav a:hover,
.pagination a:hover,
.pagination .active {
  color: #fff;
  border-color: rgba(34, 211, 238, 0.45);
}

.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(280px, 0.65fr);
  gap: 28px;
  align-items: start;
}

.detail-title {
  padding: 42px 0 24px;
}

.detail-title h1 {
  font-size: clamp(2.1rem, 4vw, 4.2rem);
}

.detail-intro {
  color: #dbeafe;
  margin-top: 18px;
  line-height: 1.8;
  font-size: 1.06rem;
}

.player-shell {
  position: relative;
  overflow: hidden;
  border-radius: 28px;
  border: 1px solid var(--line);
  background: #000;
  box-shadow: var(--shadow);
  aspect-ratio: 16 / 9;
}

.movie-video {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #000;
}

.player-cover {
  position: absolute;
  inset: 0;
  z-index: 4;
  display: grid;
  place-items: center;
  padding: 0;
  border: 0;
  color: #fff;
  background: transparent;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

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

.player-cover::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at center, rgba(34, 211, 238, 0.22), transparent 22rem),
    linear-gradient(180deg, rgba(2, 6, 23, 0.2), rgba(2, 6, 23, 0.82));
}

.play-icon {
  position: relative;
  z-index: 2;
  width: 86px;
  height: 86px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  color: #00111a;
  background: linear-gradient(135deg, var(--cyan), var(--emerald));
  box-shadow: 0 24px 60px rgba(34, 211, 238, 0.32);
  font-size: 2rem;
  transform: translateZ(0);
}

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

.detail-panel,
.content-panel {
  border: 1px solid var(--line);
  border-radius: 26px;
  background: rgba(15, 23, 42, 0.8);
  box-shadow: 0 18px 44px rgba(0, 0, 0, 0.18);
}

.detail-panel {
  overflow: hidden;
}

.detail-poster {
  aspect-ratio: 2 / 3;
  overflow: hidden;
  background: #0f172a;
}

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

.detail-info,
.content-panel {
  padding: 22px;
}

.info-list {
  display: grid;
  gap: 12px;
  color: var(--soft);
}

.info-list div {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  border-bottom: 1px solid rgba(148, 163, 184, 0.1);
  padding-bottom: 12px;
}

.info-list span:first-child {
  color: var(--muted);
}

.article-content {
  display: grid;
  gap: 18px;
  margin-top: 24px;
}

.article-content h2 {
  margin: 0;
  font-size: 1.45rem;
}

.article-content p {
  margin: 0;
  color: var(--soft);
  line-height: 1.9;
}

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

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

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

.footer-links a:hover {
  color: #fff;
}

.empty-state {
  display: none;
  margin-top: 24px;
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: 22px;
  color: var(--muted);
  background: rgba(15, 23, 42, 0.72);
}

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

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

  .hero-card {
    display: none;
  }
}

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

  .menu-btn {
    display: inline-flex;
  }

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

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

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

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

  .rank-item {
    grid-template-columns: 44px 64px minmax(0, 1fr);
  }

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

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

  .logo-text {
    font-size: 1rem;
  }

  .hero-content {
    padding: 72px 0 54px;
  }

  .movie-grid {
    gap: 14px;
  }

  .card-body {
    padding: 13px;
  }

  .section-head {
    display: block;
  }
}
