:root {
  --bg: #020617;
  --bg-deep: #000000;
  --panel: rgba(15, 23, 42, 0.84);
  --panel-solid: #0f172a;
  --line: rgba(30, 41, 59, 0.9);
  --text: #f8fafc;
  --muted: #94a3b8;
  --soft: #cbd5e1;
  --cyan: #22d3ee;
  --blue: #3b82f6;
  --orange: #fb923c;
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.38);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: radial-gradient(circle at top left, rgba(8, 145, 178, 0.16), transparent 34rem), var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "PingFang SC", "Microsoft YaHei", sans-serif;
}

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

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

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

.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 50;
  border-bottom: 1px solid rgba(30, 41, 59, 0.72);
  background: rgba(15, 23, 42, 0.78);
  backdrop-filter: blur(18px);
}

.header-inner {
  height: 76px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand,
.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-weight: 800;
}

.brand-mark {
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  color: #001018;
  background: linear-gradient(135deg, var(--cyan), var(--blue));
  box-shadow: 0 0 28px rgba(34, 211, 238, 0.42);
}

.brand-copy {
  display: grid;
  gap: 2px;
}

.brand-title,
.footer-brand,
.text-gradient {
  background: linear-gradient(90deg, var(--cyan), var(--blue));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.brand-subtitle {
  color: var(--muted);
  font-size: 12px;
  font-weight: 500;
}

.desktop-nav,
.mobile-nav {
  align-items: center;
  gap: 26px;
}

.desktop-nav {
  display: flex;
}

.nav-link {
  position: relative;
  color: var(--soft);
  font-weight: 600;
  transition: color 0.25s ease;
}

.nav-link::after {
  content: "";
  position: absolute;
  left: 0;
  right: 100%;
  bottom: -8px;
  height: 2px;
  border-radius: 999px;
  background: var(--cyan);
  transition: right 0.25s ease;
}

.nav-link:hover,
.nav-link.active {
  color: var(--cyan);
}

.nav-link:hover::after,
.nav-link.active::after {
  right: 0;
}

.menu-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(15, 23, 42, 0.72);
}

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

.mobile-nav {
  display: none;
  padding: 12px 16px 20px;
  border-top: 1px solid rgba(30, 41, 59, 0.72);
}

main {
  padding-top: 76px;
}

.hero {
  position: relative;
  min-height: calc(100vh - 76px);
  overflow: hidden;
  background: var(--bg-deep);
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transform: scale(1.02);
  transition: opacity 0.8s ease, transform 1.2s ease;
  pointer-events: none;
}

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

.hero-image,
.detail-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-overlay,
.detail-bg::after {
  position: absolute;
  inset: 0;
  content: "";
  background:
    linear-gradient(90deg, rgba(2, 6, 23, 0.96) 0%, rgba(2, 6, 23, 0.74) 42%, rgba(2, 6, 23, 0.36) 100%),
    linear-gradient(0deg, var(--bg) 0%, transparent 36%);
}

.hero-content {
  position: relative;
  z-index: 2;
  min-height: calc(100vh - 76px);
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 48px;
  align-items: center;
  padding: 72px 0;
}

.hero-copy h1 {
  margin: 18px 0 12px;
  max-width: 760px;
  font-size: clamp(42px, 7vw, 86px);
  line-height: 0.95;
  letter-spacing: -0.06em;
}

.hero-copy h2 {
  margin: 0 0 18px;
  color: var(--cyan);
  font-size: clamp(26px, 3.4vw, 48px);
}

.hero-copy p {
  max-width: 760px;
  color: var(--soft);
  font-size: 18px;
  line-height: 1.8;
}

.eyebrow,
.section-kicker {
  display: inline-flex;
  width: fit-content;
  align-items: center;
  gap: 8px;
  border: 1px solid rgba(34, 211, 238, 0.28);
  border-radius: 999px;
  padding: 8px 14px;
  color: var(--cyan);
  background: rgba(8, 145, 178, 0.12);
  font-size: 13px;
  font-weight: 700;
}

.hero-actions,
.detail-copy .btn-primary {
  margin-top: 28px;
}

.btn-primary,
.btn-ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  border-radius: 14px;
  padding: 0 22px;
  font-weight: 800;
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.btn-primary {
  color: #031018;
  background: linear-gradient(135deg, var(--cyan), var(--blue));
  box-shadow: 0 14px 30px rgba(34, 211, 238, 0.28);
}

.btn-ghost {
  margin-left: 12px;
  border: 1px solid rgba(148, 163, 184, 0.34);
  color: var(--text);
  background: rgba(15, 23, 42, 0.46);
}

.btn-primary:hover,
.btn-ghost:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 36px rgba(59, 130, 246, 0.32);
}

.hero-poster {
  overflow: hidden;
  border: 1px solid rgba(34, 211, 238, 0.3);
  border-radius: 28px;
  background: rgba(15, 23, 42, 0.72);
  box-shadow: var(--shadow);
}

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

.hero-poster span {
  display: block;
  padding: 18px;
  color: var(--cyan);
  font-weight: 800;
  text-align: center;
}

.hero-controls {
  position: absolute;
  z-index: 4;
  left: 50%;
  bottom: 26px;
  display: flex;
  align-items: center;
  gap: 14px;
  transform: translateX(-50%);
}

.hero-controls button {
  border: 1px solid rgba(148, 163, 184, 0.35);
  background: rgba(15, 23, 42, 0.72);
  color: var(--text);
  cursor: pointer;
}

.hero-controls > button {
  width: 42px;
  height: 42px;
  border-radius: 14px;
  font-size: 26px;
}

.hero-dots {
  display: flex;
  gap: 8px;
}

.hero-dot {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  padding: 0;
}

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

.section {
  padding: 78px 0;
}

.section-dark {
  background: var(--bg);
}

.section-muted {
  background: #030b1a;
}

.section-glow {
  background:
    radial-gradient(circle at top right, rgba(34, 211, 238, 0.14), transparent 34rem),
    #020817;
}

.section-heading {
  margin-bottom: 34px;
}

.section-heading h2,
.page-hero h1 {
  margin: 12px 0;
  font-size: clamp(30px, 4vw, 48px);
  line-height: 1.08;
}

.section-heading p,
.page-hero p {
  max-width: 760px;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.8;
}

.row-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
}

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

.grid {
  display: grid;
}

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

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

.movie-card,
.ranking-item,
.content-card,
.category-card,
.category-overview-card,
.filter-panel {
  border: 1px solid rgba(30, 41, 59, 0.88);
  border-radius: 22px;
  background: rgba(15, 23, 42, 0.82);
  box-shadow: 0 18px 56px rgba(0, 0, 0, 0.2);
}

.movie-card {
  overflow: hidden;
  transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

.movie-card:hover,
.ranking-item:hover,
.category-card:hover,
.category-overview-card:hover {
  transform: translateY(-4px);
  border-color: rgba(34, 211, 238, 0.5);
  box-shadow: 0 24px 80px rgba(8, 145, 178, 0.18);
}

.card-cover {
  position: relative;
  display: block;
  overflow: hidden;
  background: #0f172a;
}

.card-cover img {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.movie-card-large .card-cover img {
  aspect-ratio: 16 / 11;
}

.movie-card:hover .card-cover img {
  transform: scale(1.08);
}

.card-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(2, 6, 23, 0.78), transparent 60%);
}

.play-chip,
.rank-badge {
  position: absolute;
  z-index: 2;
  border-radius: 999px;
  padding: 6px 11px;
  font-size: 12px;
  font-weight: 800;
}

.play-chip {
  right: 12px;
  bottom: 12px;
  color: #031018;
  background: var(--cyan);
}

.rank-badge {
  top: 12px;
  left: 12px;
  color: var(--text);
  background: rgba(251, 146, 60, 0.92);
}

.card-body {
  padding: 16px;
}

.card-meta,
.detail-meta,
.ranking-topline {
  color: var(--muted);
  font-size: 13px;
}

.card-body h2,
.ranking-main h2 {
  margin: 8px 0;
  color: var(--text);
  font-size: 20px;
  line-height: 1.35;
}

.card-body p,
.ranking-main p {
  display: -webkit-box;
  min-height: 48px;
  margin: 0 0 14px;
  overflow: hidden;
  color: var(--soft);
  line-height: 1.65;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

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

.tag {
  border: 1px solid rgba(148, 163, 184, 0.24);
  border-radius: 999px;
  padding: 5px 9px;
  color: var(--muted);
  font-size: 12px;
  background: rgba(15, 23, 42, 0.55);
}

.category-grid,
.category-overview-grid {
  display: grid;
  gap: 22px;
}

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

.category-card a,
.category-overview-card a {
  display: block;
  height: 100%;
  padding: 22px;
}

.category-icon {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border-radius: 14px;
  color: #031018;
  background: linear-gradient(135deg, var(--cyan), var(--blue));
}

.category-card h2,
.category-overview-card h2 {
  margin: 18px 0 10px;
  font-size: 22px;
}

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

.category-links {
  display: grid;
  gap: 8px;
  margin-top: 18px;
}

.category-links a {
  padding: 0;
  color: var(--cyan);
  font-size: 13px;
}

.page-hero,
.detail-hero {
  position: relative;
  overflow: hidden;
  background: radial-gradient(circle at top right, rgba(34, 211, 238, 0.18), transparent 32rem), #030712;
}

.small-hero {
  padding: 86px 0 64px;
}

.filter-panel {
  display: grid;
  grid-template-columns: 1fr 220px 220px;
  gap: 14px;
  margin-bottom: 26px;
  padding: 18px;
}

.filter-panel label {
  display: grid;
  gap: 8px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.filter-panel input,
.filter-panel select {
  width: 100%;
  border: 1px solid rgba(30, 41, 59, 0.9);
  border-radius: 14px;
  padding: 13px 14px;
  color: var(--text);
  background: rgba(2, 6, 23, 0.86);
  outline: none;
}

.filter-panel input:focus,
.filter-panel select:focus {
  border-color: rgba(34, 211, 238, 0.64);
  box-shadow: 0 0 0 3px rgba(34, 211, 238, 0.12);
}

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

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

.ranking-item {
  display: grid;
  grid-template-columns: 142px minmax(0, 1fr);
  gap: 18px;
  padding: 14px;
  transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

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

.ranking-cover img {
  width: 100%;
  height: 100%;
  min-height: 110px;
  object-fit: cover;
}

.ranking-topline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: var(--cyan);
  font-weight: 800;
}

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

.category-overview-card {
  overflow: hidden;
}

.category-overview-card a {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 22px;
  align-items: center;
}

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

.category-covers img {
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 12px;
  object-fit: cover;
}

.category-overview-copy span {
  color: var(--cyan);
  font-weight: 800;
}

.detail-hero {
  padding: 54px 0 64px;
}

.detail-bg {
  position: absolute;
  inset: 0;
  opacity: 0.24;
}

.detail-bg::after {
  background: linear-gradient(0deg, var(--bg) 0%, rgba(2, 6, 23, 0.62) 54%, rgba(2, 6, 23, 0.92) 100%);
}

.detail-hero-inner {
  position: relative;
  z-index: 2;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 30px;
  color: var(--muted);
  font-size: 14px;
}

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

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

.detail-poster {
  overflow: hidden;
  border: 1px solid rgba(34, 211, 238, 0.32);
  border-radius: 28px;
  box-shadow: var(--shadow);
}

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

.detail-copy h1 {
  margin: 16px 0;
  font-size: clamp(36px, 6vw, 72px);
  line-height: 1.02;
  letter-spacing: -0.04em;
}

.lead-text {
  max-width: 820px;
  color: var(--soft);
  font-size: 18px;
  line-height: 1.82;
}

.player-shell {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(34, 211, 238, 0.3);
  border-radius: 28px;
  background: #000;
  box-shadow: var(--shadow);
}

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

.player-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  gap: 18px;
  padding: 28px;
  text-align: center;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.76), rgba(0, 0, 0, 0.18));
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

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

.play-button {
  width: 82px;
  height: 82px;
  border: 0;
  border-radius: 999px;
  color: #031018;
  background: linear-gradient(135deg, var(--cyan), var(--blue));
  cursor: pointer;
  box-shadow: 0 16px 44px rgba(34, 211, 238, 0.36);
}

.play-button span {
  display: inline-block;
  margin-left: 5px;
  font-size: 34px;
}

.player-overlay h2 {
  margin: 0 0 8px;
  font-size: 30px;
}

.player-overlay p {
  margin: 0;
  color: var(--soft);
}

.detail-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 22px;
}

.content-card {
  padding: 26px;
}

.content-card h2 {
  margin: 0 0 16px;
  color: var(--cyan);
}

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

.site-footer {
  border-top: 1px solid rgba(30, 41, 59, 0.9);
  background: #010409;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.3fr 1fr 1fr;
  gap: 34px;
  padding: 54px 0 34px;
}

.site-footer p {
  max-width: 420px;
  color: var(--muted);
  line-height: 1.7;
}

.site-footer h2 {
  margin: 0 0 16px;
  font-size: 18px;
}

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

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

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

.footer-bottom {
  border-top: 1px solid rgba(30, 41, 59, 0.8);
  padding: 18px 0;
  color: #64748b;
  text-align: center;
}

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

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

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

  .compact-list,
  .category-overview-grid {
    grid-template-columns: 1fr;
  }
}

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

  .menu-toggle {
    display: block;
  }

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

  .hero-content,
  .detail-grid,
  .detail-content,
  .footer-grid,
  .filter-panel,
  .category-overview-card a {
    grid-template-columns: 1fr;
  }

  .hero-content {
    padding: 44px 0 96px;
  }

  .hero-poster,
  .detail-poster {
    max-width: 320px;
  }

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

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

  .brand-subtitle {
    display: none;
  }

  .hero-copy h1 {
    font-size: 40px;
  }

  .hero-actions {
    display: grid;
    gap: 12px;
  }

  .btn-ghost {
    margin-left: 0;
  }

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

  .ranking-item {
    grid-template-columns: 110px 1fr;
  }

  .section {
    padding: 56px 0;
  }
}
