:root {
  --bg: #020617;
  --panel: rgba(15, 23, 42, 0.72);
  --panel-strong: rgba(15, 23, 42, 0.92);
  --border: rgba(148, 163, 184, 0.16);
  --text: #f8fafc;
  --muted: #94a3b8;
  --soft: #cbd5e1;
  --amber: #fbbf24;
  --amber-deep: #f59e0b;
  --orange: #f97316;
  --cyan: #22d3ee;
  --violet: #a78bfa;
  --radius: 18px;
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.38);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--text);
  background:
    radial-gradient(circle at top left, rgba(251, 191, 36, 0.13), transparent 28rem),
    radial-gradient(circle at top right, rgba(34, 211, 238, 0.10), transparent 32rem),
    linear-gradient(180deg, #020617 0%, #0f172a 48%, #020617 100%);
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  min-height: 100vh;
}

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

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

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 80;
  background: rgba(2, 6, 23, 0.94);
  border-bottom: 1px solid var(--border);
  backdrop-filter: blur(18px);
  box-shadow: 0 14px 38px rgba(0, 0, 0, 0.28);
}

.site-nav {
  min-height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--amber);
  font-size: 22px;
  font-weight: 800;
  letter-spacing: 0.02em;
}

.logo-mark {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #111827;
  background: linear-gradient(135deg, var(--amber), var(--orange));
  box-shadow: 0 0 28px rgba(251, 191, 36, 0.32);
  font-size: 14px;
}

.nav-menu {
  display: flex;
  align-items: center;
  gap: 20px;
}

.nav-link {
  color: var(--soft);
  font-weight: 650;
  transition: color 0.2s ease, transform 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
  color: var(--amber);
  transform: translateY(-1px);
}

.menu-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 12px;
  background: rgba(30, 41, 59, 0.85);
  color: var(--text);
  font-size: 21px;
}

.hero {
  position: relative;
  height: 590px;
  overflow: hidden;
  margin-bottom: 60px;
  background: #020617;
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.72s ease, transform 0.72s ease;
  background-size: cover;
  background-position: center;
  transform: scale(1.03);
}

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

.hero-slide::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(2, 6, 23, 0.98), rgba(15, 23, 42, 0.88) 43%, rgba(2, 6, 23, 0.24)),
    linear-gradient(0deg, rgba(2, 6, 23, 0.92), transparent 42%);
}

.hero-inner {
  position: relative;
  z-index: 2;
  height: 100%;
  display: flex;
  align-items: center;
}

.hero-copy {
  width: min(680px, 100%);
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--amber);
  font-weight: 800;
  margin-bottom: 18px;
}

.hero h1 {
  margin: 0 0 18px;
  font-size: clamp(38px, 7vw, 68px);
  line-height: 1.05;
  letter-spacing: -0.04em;
}

.hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin: 0 0 20px;
  color: var(--soft);
}

.hero-meta span,
.pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 32px;
  padding: 6px 12px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.70);
  border: 1px solid rgba(148, 163, 184, 0.16);
}

.hero-meta span:first-child {
  color: var(--amber);
  background: rgba(251, 191, 36, 0.16);
  border-color: rgba(251, 191, 36, 0.22);
}

.hero p {
  color: var(--soft);
  font-size: 18px;
  line-height: 1.8;
  margin: 0 0 30px;
}

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

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 0;
  border-radius: 999px;
  min-height: 46px;
  padding: 0 22px;
  font-weight: 800;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
  cursor: pointer;
}

.btn-primary {
  color: #111827;
  background: linear-gradient(135deg, var(--amber), var(--orange));
  box-shadow: 0 18px 46px rgba(251, 191, 36, 0.25);
}

.btn-secondary {
  color: var(--text);
  border: 1px solid rgba(148, 163, 184, 0.22);
  background: rgba(15, 23, 42, 0.76);
}

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

.hero-search {
  width: min(450px, 100%);
  display: flex;
  background: rgba(15, 23, 42, 0.86);
  border: 1px solid rgba(148, 163, 184, 0.20);
  border-radius: 999px;
  overflow: hidden;
  backdrop-filter: blur(12px);
}

.hero-search input,
.filter-bar input {
  min-width: 0;
  flex: 1;
  border: 0;
  outline: 0;
  color: var(--text);
  background: transparent;
  padding: 0 18px;
  font-size: 15px;
}

.hero-search button {
  border: 0;
  background: var(--amber);
  color: #111827;
  font-weight: 800;
  padding: 0 18px;
  cursor: pointer;
}

.hero-control {
  position: absolute;
  top: 50%;
  z-index: 4;
  width: 48px;
  height: 48px;
  border: 0;
  border-radius: 50%;
  background: rgba(2, 6, 23, 0.58);
  color: white;
  font-size: 28px;
  cursor: pointer;
  backdrop-filter: blur(10px);
}

.hero-control.prev {
  left: 20px;
}

.hero-control.next {
  right: 20px;
}

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

.hero-dot {
  width: 42px;
  height: 5px;
  border: 0;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.45);
  cursor: pointer;
  transition: width 0.25s ease, background 0.25s ease;
}

.hero-dot.active {
  width: 64px;
  background: var(--amber);
}

main {
  padding-bottom: 48px;
}

.section {
  margin-bottom: 62px;
}

.section-title {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 24px;
}

.section-title span {
  color: var(--amber);
  font-size: 24px;
}

.section-title h2 {
  margin: 0;
  font-size: clamp(25px, 3.4vw, 36px);
  letter-spacing: -0.03em;
}

.section-title i {
  height: 1px;
  flex: 1;
  background: linear-gradient(90deg, rgba(251, 191, 36, 0.52), transparent);
}

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

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

.movie-card {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius);
  background: var(--panel);
  border: 1px solid rgba(148, 163, 184, 0.13);
  box-shadow: 0 12px 42px rgba(0, 0, 0, 0.22);
  transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

.movie-card:hover {
  transform: translateY(-6px) scale(1.015);
  border-color: rgba(251, 191, 36, 0.58);
  box-shadow: 0 22px 62px rgba(0, 0, 0, 0.36);
}

.poster-link {
  position: relative;
  display: block;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  background: #0f172a;
}

.poster-link img,
.mini-card img,
.detail-poster img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.55s ease;
}

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

.poster-link::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 44%, rgba(2, 6, 23, 0.82));
  opacity: 0;
  transition: opacity 0.25s ease;
}

.movie-card:hover .poster-link::after {
  opacity: 1;
}

.play-hover {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #111827;
  opacity: 0;
  font-size: 28px;
  transition: opacity 0.22s ease;
}

.play-hover::before {
  content: "";
  position: absolute;
  width: 66px;
  height: 66px;
  border-radius: 50%;
  background: rgba(251, 191, 36, 0.92);
  z-index: -1;
}

.movie-card:hover .play-hover {
  opacity: 1;
}

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

.rating-badge {
  top: 10px;
  right: 10px;
  padding: 5px 9px;
  color: white;
  font-size: 12px;
  background: rgba(2, 6, 23, 0.82);
  backdrop-filter: blur(10px);
}

.rank-badge {
  top: 10px;
  left: 10px;
  min-width: 34px;
  height: 34px;
  color: #111827;
  background: linear-gradient(135deg, var(--amber), var(--orange));
}

.card-body {
  padding: 14px;
}

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

.card-body h3 a:hover {
  color: var(--amber);
}

.card-meta,
.card-desc {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
}

.card-desc {
  margin-top: 8px;
  line-height: 1.55;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 12px;
}

.tag-list span {
  color: var(--soft);
  background: rgba(51, 65, 85, 0.70);
  border-radius: 7px;
  padding: 3px 7px;
  font-size: 12px;
}

.scroller-wrap {
  position: relative;
}

.horizontal-scroller {
  display: flex;
  gap: 18px;
  overflow-x: auto;
  scroll-behavior: smooth;
  padding: 4px 0 18px;
  scrollbar-width: none;
}

.horizontal-scroller::-webkit-scrollbar {
  display: none;
}

.horizontal-scroller .movie-card {
  width: 210px;
  flex: 0 0 auto;
}

.scroll-button {
  position: absolute;
  top: 44%;
  z-index: 8;
  width: 46px;
  height: 46px;
  border: 0;
  border-radius: 50%;
  color: white;
  background: rgba(2, 6, 23, 0.88);
  cursor: pointer;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.36);
}

.scroll-button.left {
  left: -10px;
}

.scroll-button.right {
  right: -10px;
}

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

.category-card {
  min-height: 178px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 22px;
  border-radius: 24px;
  background:
    radial-gradient(circle at top right, rgba(251, 191, 36, 0.16), transparent 12rem),
    linear-gradient(145deg, rgba(30, 41, 59, 0.82), rgba(15, 23, 42, 0.92));
  border: 1px solid rgba(148, 163, 184, 0.14);
  transition: transform 0.24s ease, border-color 0.24s ease;
}

.category-card:hover {
  transform: translateY(-5px);
  border-color: rgba(251, 191, 36, 0.48);
}

.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 {
  display: inline-flex;
  margin-top: 18px;
  color: var(--amber);
}

.page-hero {
  padding: 58px 0 42px;
}

.page-hero-card {
  padding: clamp(28px, 5vw, 52px);
  border-radius: 30px;
  background:
    radial-gradient(circle at 82% 22%, rgba(251, 191, 36, 0.18), transparent 20rem),
    radial-gradient(circle at 20% 20%, rgba(34, 211, 238, 0.12), transparent 18rem),
    linear-gradient(135deg, rgba(15, 23, 42, 0.96), rgba(2, 6, 23, 0.92));
  border: 1px solid rgba(148, 163, 184, 0.16);
  box-shadow: var(--shadow);
}

.page-hero h1 {
  margin: 0 0 14px;
  font-size: clamp(34px, 5vw, 54px);
  letter-spacing: -0.04em;
}

.page-hero p {
  margin: 0;
  color: var(--soft);
  font-size: 17px;
  line-height: 1.8;
  max-width: 820px;
}

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

.filter-bar input {
  min-height: 44px;
  border-radius: 999px;
  background: rgba(2, 6, 23, 0.58);
}

.filter-bar .pill {
  color: var(--amber);
}

.empty-message {
  display: none;
  color: var(--muted);
  padding: 28px;
  border-radius: 18px;
  background: rgba(15, 23, 42, 0.74);
}

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

.rank-row {
  display: grid;
  grid-template-columns: 54px 74px 1fr auto;
  gap: 14px;
  align-items: center;
  padding: 12px;
  border-radius: 18px;
  background: rgba(15, 23, 42, 0.72);
  border: 1px solid rgba(148, 163, 184, 0.13);
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.rank-row:hover {
  transform: translateY(-3px);
  border-color: rgba(251, 191, 36, 0.42);
}

.rank-number {
  width: 42px;
  height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  color: #111827;
  background: linear-gradient(135deg, var(--amber), var(--orange));
  font-weight: 900;
}

.rank-row img {
  width: 74px;
  height: 104px;
  object-fit: cover;
  border-radius: 12px;
}

.rank-row h3 {
  margin: 0 0 7px;
  font-size: 18px;
}

.rank-row p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}

.rank-score {
  color: var(--amber);
  font-weight: 900;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  color: var(--muted);
  padding: 26px 0 18px;
  font-size: 14px;
}

.breadcrumb a:hover {
  color: var(--amber);
}

.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(310px, 0.92fr);
  gap: 30px;
  align-items: start;
  margin-bottom: 46px;
}

.player-card,
.info-panel,
.text-panel,
.side-panel {
  border-radius: 24px;
  background: rgba(15, 23, 42, 0.75);
  border: 1px solid rgba(148, 163, 184, 0.14);
  box-shadow: 0 18px 60px rgba(0, 0, 0, 0.24);
  overflow: hidden;
}

.player-card {
  background: #020617;
}

.movie-player {
  position: relative;
  aspect-ratio: 16 / 9;
  background: #000;
  overflow: hidden;
}

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

.player-overlay {
  position: absolute;
  inset: 0;
  z-index: 4;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(0deg, rgba(2, 6, 23, 0.62), rgba(2, 6, 23, 0.16));
  transition: opacity 0.22s ease, visibility 0.22s ease;
}

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

.player-play {
  width: 82px;
  height: 82px;
  border: 0;
  border-radius: 50%;
  color: #111827;
  background: linear-gradient(135deg, var(--amber), var(--orange));
  font-size: 34px;
  cursor: pointer;
  box-shadow: 0 20px 52px rgba(251, 191, 36, 0.32);
}

.player-status {
  position: absolute;
  left: 18px;
  bottom: 14px;
  z-index: 5;
  color: var(--soft);
  background: rgba(2, 6, 23, 0.76);
  border-radius: 999px;
  padding: 7px 12px;
  font-size: 13px;
  backdrop-filter: blur(10px);
}

.player-card-body {
  padding: 18px;
  color: var(--muted);
}

.info-panel,
.text-panel,
.side-panel {
  padding: 24px;
}

.info-panel h1 {
  margin: 0 0 14px;
  font-size: clamp(30px, 4vw, 44px);
  line-height: 1.15;
  letter-spacing: -0.04em;
}

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

.meta-item {
  padding: 12px;
  border-radius: 15px;
  background: rgba(2, 6, 23, 0.38);
  color: var(--soft);
}

.meta-item b {
  display: block;
  color: var(--amber);
  font-size: 12px;
  margin-bottom: 4px;
}

.one-line {
  color: var(--soft);
  line-height: 1.8;
  padding: 18px;
  border-radius: 18px;
  background: rgba(2, 6, 23, 0.38);
  border-left: 4px solid var(--amber);
}

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

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

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

.side-panel {
  position: sticky;
  top: 96px;
}

.side-panel .tag-list span {
  font-size: 13px;
  padding: 7px 10px;
}

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

.mini-card {
  display: block;
  overflow: hidden;
  border-radius: 17px;
  background: rgba(15, 23, 42, 0.76);
  border: 1px solid rgba(148, 163, 184, 0.13);
  transition: transform 0.22s ease, border-color 0.22s ease;
}

.mini-card:hover {
  transform: translateY(-4px);
  border-color: rgba(251, 191, 36, 0.46);
}

.mini-card img {
  aspect-ratio: 2 / 3;
}

.mini-card span,
.mini-card small {
  display: block;
  padding: 0 12px;
}

.mini-card span {
  margin-top: 10px;
  color: var(--text);
  font-weight: 750;
  line-height: 1.35;
}

.mini-card small {
  margin: 6px 0 12px;
  color: var(--muted);
}

.site-footer {
  margin-top: 52px;
  padding: 46px 0 0;
  background: rgba(2, 6, 23, 0.96);
  border-top: 1px solid rgba(148, 163, 184, 0.13);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 32px;
}

.footer-logo {
  margin-bottom: 16px;
}

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

.site-footer h3 {
  margin: 0 0 14px;
}

.footer-links {
  display: grid;
  gap: 9px;
}

.footer-links a {
  color: var(--muted);
}

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

.footer-bottom {
  margin-top: 38px;
  padding: 18px;
  text-align: center;
  color: var(--muted);
  border-top: 1px solid rgba(148, 163, 184, 0.11);
}

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

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

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

  .side-panel {
    position: static;
  }

  .rank-list {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 820px) {
  .menu-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  .nav-menu {
    position: absolute;
    top: 72px;
    left: 16px;
    right: 16px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 12px;
    border-radius: 18px;
    background: rgba(2, 6, 23, 0.98);
    border: 1px solid rgba(148, 163, 184, 0.16);
    box-shadow: var(--shadow);
  }

  .nav-menu.open {
    display: flex;
  }

  .nav-link {
    padding: 12px;
    border-radius: 12px;
  }

  .nav-link:hover,
  .nav-link.active {
    background: rgba(251, 191, 36, 0.10);
  }

  .hero {
    height: auto;
    min-height: 640px;
  }

  .hero-inner {
    padding: 70px 0 90px;
  }

  .hero-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .hero-search,
  .btn {
    width: 100%;
  }

  .hero-control {
    display: none;
  }

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

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

  .rank-row {
    grid-template-columns: 44px 64px 1fr;
  }

  .rank-score {
    grid-column: 3;
  }

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

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

  .logo {
    font-size: 18px;
  }

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

  .card-body {
    padding: 11px;
  }

  .card-desc,
  .tag-list {
    display: none;
  }

  .horizontal-scroller .movie-card {
    width: 170px;
  }

  .filter-bar {
    flex-direction: column;
    align-items: stretch;
  }
}
