:root {
  color-scheme: dark;
  --page: #020617;
  --panel: rgba(15, 23, 42, 0.82);
  --panel-solid: #0f172a;
  --panel-soft: rgba(30, 41, 59, 0.72);
  --text: #f8fafc;
  --muted: #cbd5e1;
  --weak: #94a3b8;
  --line: rgba(148, 163, 184, 0.22);
  --brand: #10b981;
  --brand-2: #34d399;
  --brand-dark: #047857;
  --accent: #22d3ee;
  --danger: #fb7185;
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.38);
  --radius: 18px;
  --radius-sm: 12px;
  --container: 1180px;
  font-family:
    "Inter",
    "PingFang SC",
    "Microsoft YaHei",
    "Noto Sans SC",
    Arial,
    sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  background: var(--page);
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--text);
  background:
    radial-gradient(circle at top left, rgba(16, 185, 129, 0.16), transparent 34rem),
    radial-gradient(circle at 80% 0%, rgba(34, 211, 238, 0.10), transparent 32rem),
    linear-gradient(180deg, #020617 0%, #0f172a 46%, #020617 100%);
}

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

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

button,
input,
select {
  font: inherit;
}

.container {
  width: min(100% - 32px, var(--container));
  margin-inline: auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 80;
  border-bottom: 1px solid rgba(148, 163, 184, 0.16);
  background: rgba(2, 6, 23, 0.90);
  backdrop-filter: blur(18px);
}

.header-inner {
  display: grid;
  grid-template-columns: auto 1fr auto auto;
  gap: 22px;
  align-items: center;
  min-height: 72px;
}

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

.logo-mark {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 14px;
  color: #ffffff;
  background:
    linear-gradient(135deg, var(--brand), var(--accent));
  box-shadow: 0 16px 36px rgba(16, 185, 129, 0.28);
}

.logo-text {
  display: grid;
  gap: 1px;
}

.logo-title {
  font-size: 20px;
  line-height: 1.1;
}

.logo-subtitle {
  font-size: 12px;
  color: var(--brand-2);
  font-weight: 600;
}

.main-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.main-nav a {
  padding: 10px 12px;
  border-radius: 999px;
  color: var(--muted);
  font-weight: 700;
  transition:
    color 180ms ease,
    background-color 180ms ease;
}

.main-nav a:hover,
.main-nav a.is-active {
  color: #ffffff;
  background: rgba(16, 185, 129, 0.16);
}

.header-search {
  position: relative;
  width: 250px;
}

.header-search input {
  width: 100%;
  border: 1px solid rgba(148, 163, 184, 0.20);
  border-radius: 999px;
  outline: none;
  padding: 11px 42px 11px 16px;
  color: #ffffff;
  background: rgba(15, 23, 42, 0.74);
  transition:
    border-color 180ms ease,
    box-shadow 180ms ease;
}

.header-search input:focus {
  border-color: rgba(16, 185, 129, 0.72);
  box-shadow: 0 0 0 4px rgba(16, 185, 129, 0.13);
}

.header-search button {
  position: absolute;
  right: 6px;
  top: 50%;
  width: 34px;
  height: 34px;
  border: 0;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(16, 185, 129, 0.88);
  transform: translateY(-50%);
  cursor: pointer;
}

.menu-button {
  display: none;
  width: 42px;
  height: 42px;
  border: 1px solid rgba(148, 163, 184, 0.25);
  border-radius: 12px;
  color: #ffffff;
  background: rgba(15, 23, 42, 0.76);
  cursor: pointer;
}

.mobile-nav {
  display: none;
  padding: 0 0 18px;
}

.mobile-nav a {
  display: block;
  padding: 13px 0;
  color: var(--muted);
  border-top: 1px solid rgba(148, 163, 184, 0.14);
  font-weight: 700;
}

.hero {
  position: relative;
  min-height: 74vh;
  overflow: hidden;
  border-bottom: 1px solid rgba(148, 163, 184, 0.16);
  background:
    linear-gradient(135deg, rgba(2, 6, 23, 0.92), rgba(15, 23, 42, 0.55)),
    radial-gradient(circle at 82% 32%, rgba(16, 185, 129, 0.16), transparent 22rem);
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 900ms ease;
}

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

.hero-image {
  position: absolute;
  inset: 0;
  z-index: 0;
  background:
    radial-gradient(circle at 72% 36%, rgba(16, 185, 129, 0.20), transparent 24rem),
    linear-gradient(135deg, rgba(15, 23, 42, 0.94), rgba(2, 6, 23, 0.98));
}

.hero-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.42;
  transform: scale(1.02);
}

.hero-image img.is-hidden {
  display: none;
}

.hero-shade {
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    linear-gradient(90deg, rgba(2, 6, 23, 0.95) 0%, rgba(2, 6, 23, 0.76) 44%, rgba(2, 6, 23, 0.20) 100%),
    linear-gradient(0deg, rgba(2, 6, 23, 0.92) 0%, transparent 40%);
}

.hero-content {
  position: relative;
  z-index: 2;
  display: grid;
  align-content: center;
  min-height: 74vh;
  padding: 110px 0 92px;
}

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

.badges {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 0 0 18px;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 999px;
  padding: 6px 12px;
  color: #ffffff;
  background: rgba(15, 23, 42, 0.64);
  backdrop-filter: blur(10px);
  font-size: 13px;
  font-weight: 700;
}

.badge.brand {
  border-color: transparent;
  background: linear-gradient(135deg, var(--brand), var(--brand-dark));
}

.hero h1,
.hero h2 {
  margin: 0 0 18px;
  color: #ffffff;
  font-size: clamp(42px, 7vw, 76px);
  line-height: 0.98;
  letter-spacing: -0.06em;
  text-shadow: 0 20px 46px rgba(0, 0, 0, 0.40);
}

.hero p {
  max-width: 650px;
  margin: 0 0 28px;
  color: #e2e8f0;
  font-size: clamp(16px, 2vw, 20px);
  line-height: 1.82;
}

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

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  border: 0;
  border-radius: 12px;
  padding: 12px 18px;
  color: #ffffff;
  background: rgba(30, 41, 59, 0.86);
  font-weight: 800;
  cursor: pointer;
  transition:
    transform 180ms ease,
    box-shadow 180ms ease,
    background 180ms ease;
}

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

.btn.primary {
  background: linear-gradient(135deg, var(--brand), var(--brand-dark));
  box-shadow: 0 18px 40px rgba(16, 185, 129, 0.22);
}

.btn.ghost {
  border: 1px solid rgba(148, 163, 184, 0.25);
  background: rgba(15, 23, 42, 0.52);
}

.hero-controls {
  position: absolute;
  inset: auto 0 34px 0;
  z-index: 4;
  display: flex;
  justify-content: center;
  gap: 10px;
}

.hero-dot {
  width: 13px;
  height: 13px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.46);
  cursor: pointer;
  transition:
    width 180ms ease,
    background 180ms ease;
}

.hero-dot.is-active {
  width: 38px;
  background: var(--brand);
}

.hero-arrow {
  position: absolute;
  top: 50%;
  z-index: 5;
  width: 46px;
  height: 46px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 999px;
  color: #ffffff;
  background: rgba(2, 6, 23, 0.48);
  transform: translateY(-50%);
  cursor: pointer;
  backdrop-filter: blur(12px);
}

.hero-arrow.prev {
  left: 22px;
}

.hero-arrow.next {
  right: 22px;
}

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

.page-kicker {
  margin: 0 0 12px;
  color: var(--brand-2);
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.page-title {
  margin: 0;
  color: #ffffff;
  font-size: clamp(34px, 5vw, 58px);
  line-height: 1.1;
  letter-spacing: -0.04em;
}

.page-desc {
  max-width: 820px;
  margin: 18px 0 0;
  color: var(--muted);
  font-size: 17px;
  line-height: 1.8;
}

.section {
  padding: 44px 0;
}

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

.section-title {
  margin: 0;
  color: #ffffff;
  font-size: clamp(26px, 4vw, 38px);
  letter-spacing: -0.04em;
}

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

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

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

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

.movie-card {
  position: relative;
  min-width: 0;
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: var(--radius);
  overflow: hidden;
  background: rgba(15, 23, 42, 0.74);
  box-shadow: 0 18px 60px rgba(0, 0, 0, 0.22);
  transition:
    transform 180ms ease,
    border-color 180ms ease,
    background 180ms ease;
}

.movie-card:hover {
  transform: translateY(-5px);
  border-color: rgba(16, 185, 129, 0.45);
  background: rgba(15, 23, 42, 0.92);
}

.poster {
  position: relative;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  background:
    radial-gradient(circle at 35% 22%, rgba(16, 185, 129, 0.26), transparent 42%),
    linear-gradient(135deg, rgba(15, 23, 42, 0.96), rgba(2, 6, 23, 0.98));
}

.poster.wide {
  aspect-ratio: 16 / 9;
}

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

.poster img.is-hidden {
  display: none;
}

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

.poster::after {
  position: absolute;
  inset: auto 0 0 0;
  height: 46%;
  content: "";
  background: linear-gradient(0deg, rgba(2, 6, 23, 0.92), transparent);
}

.poster-label {
  position: absolute;
  left: 10px;
  top: 10px;
  z-index: 2;
  border-radius: 999px;
  padding: 5px 9px;
  color: #ffffff;
  background: rgba(16, 185, 129, 0.88);
  font-size: 12px;
  font-weight: 900;
}

.card-body {
  display: grid;
  gap: 9px;
  padding: 14px;
}

.card-title {
  margin: 0;
  color: #ffffff;
  font-size: 17px;
  line-height: 1.35;
}

.card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  color: var(--weak);
  font-size: 13px;
}

.card-text {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.65;
}

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

.category-card {
  min-height: 168px;
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: var(--radius);
  padding: 22px;
  background:
    radial-gradient(circle at top right, rgba(16, 185, 129, 0.20), transparent 60%),
    rgba(15, 23, 42, 0.78);
  box-shadow: var(--shadow);
  transition:
    transform 180ms ease,
    border-color 180ms ease;
}

.category-card:hover {
  transform: translateY(-4px);
  border-color: rgba(16, 185, 129, 0.42);
}

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

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

.filter-panel {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 14px;
  margin: 0 0 26px;
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: var(--radius);
  padding: 14px;
  background: rgba(15, 23, 42, 0.68);
}

.filter-panel input,
.filter-panel select {
  width: 100%;
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 12px;
  outline: none;
  padding: 12px 14px;
  color: #ffffff;
  background: rgba(2, 6, 23, 0.72);
}

.filter-panel button {
  white-space: nowrap;
}

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

.rank-item {
  display: grid;
  grid-template-columns: 72px 84px 1fr auto;
  gap: 16px;
  align-items: center;
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: var(--radius);
  padding: 12px;
  background: rgba(15, 23, 42, 0.72);
}

.rank-num {
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  border-radius: 18px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--brand), var(--brand-dark));
  font-size: 19px;
  font-weight: 900;
}

.rank-cover {
  aspect-ratio: 2 / 3;
  border-radius: 12px;
  overflow: hidden;
  background:
    radial-gradient(circle at 40% 20%, rgba(16, 185, 129, 0.26), transparent 46%),
    rgba(15, 23, 42, 0.92);
}

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

.rank-cover img.is-hidden {
  display: none;
}

.rank-info h3 {
  margin: 0 0 8px;
  font-size: 20px;
}

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

.hot-score {
  color: var(--brand-2);
  font-weight: 900;
}

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

.player-panel,
.detail-card,
.side-panel {
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: var(--radius);
  background: rgba(15, 23, 42, 0.74);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.player-wrap {
  position: relative;
  background: #000000;
}

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

.play-layer {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background:
    radial-gradient(circle at center, rgba(16, 185, 129, 0.20), transparent 38%),
    rgba(2, 6, 23, 0.52);
  transition:
    opacity 180ms ease,
    visibility 180ms ease;
}

.play-layer.is-hidden {
  opacity: 0;
  visibility: hidden;
}

.play-button {
  display: grid;
  place-items: center;
  width: 86px;
  height: 86px;
  border: 0;
  border-radius: 999px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--brand), var(--brand-dark));
  box-shadow: 0 24px 70px rgba(16, 185, 129, 0.36);
  cursor: pointer;
}

.player-note {
  padding: 13px 16px;
  color: var(--muted);
  border-top: 1px solid rgba(148, 163, 184, 0.14);
  background: rgba(2, 6, 23, 0.54);
  line-height: 1.65;
}

.detail-card {
  padding: 24px;
}

.detail-card h2,
.side-panel h2 {
  margin: 0 0 16px;
  font-size: 24px;
  letter-spacing: -0.02em;
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 0 0 20px;
}

.detail-meta span {
  border-radius: 999px;
  padding: 7px 11px;
  color: #ffffff;
  background: rgba(30, 41, 59, 0.86);
  font-size: 13px;
  font-weight: 800;
}

.detail-card p {
  margin: 0 0 18px;
  color: var(--muted);
  line-height: 1.9;
}

.side-panel {
  padding: 18px;
}

.side-list {
  display: grid;
  gap: 13px;
}

.side-link {
  display: grid;
  grid-template-columns: 54px 1fr;
  gap: 12px;
  align-items: center;
  border-radius: 14px;
  padding: 9px;
  background: rgba(2, 6, 23, 0.34);
  transition:
    background 180ms ease,
    transform 180ms ease;
}

.side-link:hover {
  transform: translateX(3px);
  background: rgba(16, 185, 129, 0.12);
}

.side-thumb {
  aspect-ratio: 2 / 3;
  border-radius: 10px;
  overflow: hidden;
  background:
    radial-gradient(circle at 35% 20%, rgba(16, 185, 129, 0.24), transparent 45%),
    rgba(15, 23, 42, 0.94);
}

.side-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.side-thumb img.is-hidden {
  display: none;
}

.side-link strong {
  display: block;
  margin-bottom: 4px;
  color: #ffffff;
  line-height: 1.35;
}

.side-link span {
  color: var(--weak);
  font-size: 13px;
}

.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin-top: 18px;
}

.tag {
  border: 1px solid rgba(148, 163, 184, 0.18);
  border-radius: 999px;
  padding: 6px 10px;
  color: var(--muted);
  background: rgba(2, 6, 23, 0.38);
  font-size: 13px;
}

.site-footer {
  margin-top: 54px;
  border-top: 1px solid rgba(148, 163, 184, 0.16);
  padding: 34px 0;
  color: var(--weak);
  background: rgba(2, 6, 23, 0.56);
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  line-height: 1.7;
}

.empty-state {
  display: none;
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: var(--radius);
  padding: 26px;
  color: var(--muted);
  background: rgba(15, 23, 42, 0.72);
  text-align: center;
}

@media (max-width: 1080px) {
  .header-inner {
    grid-template-columns: auto 1fr auto;
  }

  .main-nav {
    display: none;
  }

  .menu-button {
    display: inline-grid;
    place-items: center;
  }

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

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

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

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

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

  .header-inner {
    grid-template-columns: 1fr auto;
    gap: 12px;
  }

  .header-search {
    grid-column: 1 / -1;
    width: 100%;
    padding-bottom: 14px;
  }

  .hero {
    min-height: 68vh;
  }

  .hero-content {
    min-height: 68vh;
    padding: 88px 0 78px;
  }

  .hero-arrow {
    display: none;
  }

  .section-header,
  .footer-inner {
    display: grid;
  }

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

  .filter-panel {
    grid-template-columns: 1fr;
  }

  .rank-item {
    grid-template-columns: 52px 64px 1fr;
  }

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

  .page-hero {
    padding-top: 48px;
  }
}

@media (max-width: 420px) {
  .movie-grid,
  .movie-grid.compact,
  .category-grid {
    grid-template-columns: 1fr;
  }

  .logo-subtitle {
    display: none;
  }
}
