:root {
  color-scheme: dark;
  --bg: #020617;
  --bg-soft: #0f172a;
  --panel: rgba(15, 23, 42, 0.82);
  --panel-strong: #111827;
  --line: rgba(125, 211, 252, 0.18);
  --text: #f8fafc;
  --muted: #94a3b8;
  --cyan: #22d3ee;
  --blue: #2563eb;
  --purple: #9333ea;
  --pink: #db2777;
  --green: #22c55e;
  --amber: #f59e0b;
  --radius-lg: 28px;
  --radius: 18px;
  --shadow: 0 24px 80px rgba(2, 6, 23, 0.45);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at top left, rgba(37, 99, 235, 0.18), transparent 34rem),
    radial-gradient(circle at top right, rgba(147, 51, 234, 0.18), transparent 30rem),
    linear-gradient(180deg, #020617 0%, #0f172a 48%, #020617 100%);
  color: var(--text);
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  line-height: 1.65;
}

body.nav-open {
  overflow: hidden;
}

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

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

button,
input {
  font: inherit;
}

.container,
.content-section,
.header-inner,
.footer-inner,
.detail-inner {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid rgba(125, 211, 252, 0.14);
  background: rgba(2, 6, 23, 0.82);
  backdrop-filter: blur(20px);
}

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

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

.logo-mark {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--cyan), var(--blue), var(--purple));
  box-shadow: 0 14px 36px rgba(34, 211, 238, 0.22);
}

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

.site-nav a {
  padding: 10px 16px;
  border-radius: 999px;
  color: #cbd5e1;
  transition: color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.site-nav a:hover,
.site-nav a.is-active {
  color: #ffffff;
  background: rgba(34, 211, 238, 0.14);
  transform: translateY(-1px);
}

.nav-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border: 1px solid rgba(125, 211, 252, 0.18);
  border-radius: 14px;
  background: rgba(15, 23, 42, 0.86);
  color: #ffffff;
  cursor: pointer;
}

.nav-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  margin: 4px auto;
  background: #ffffff;
  border-radius: 999px;
}

.hero {
  position: relative;
  min-height: 680px;
  overflow: hidden;
  background: #020617;
}

.hero-track,
.hero-slide {
  position: absolute;
  inset: 0;
}

.hero-slide {
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.7s ease, transform 0.7s ease;
  transform: scale(1.02);
}

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

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

.hero-shade {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(2, 6, 23, 0.95) 0%, rgba(2, 6, 23, 0.76) 42%, rgba(2, 6, 23, 0.26) 100%),
    linear-gradient(0deg, #020617 0%, transparent 44%);
}

.hero-content {
  position: absolute;
  left: max(24px, calc((100vw - 1180px) / 2));
  bottom: 120px;
  width: min(650px, calc(100% - 48px));
}

.hero-kicker,
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 14px;
  color: var(--cyan);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.hero h1 {
  margin: 0 0 20px;
  font-size: clamp(42px, 8vw, 88px);
  line-height: 0.96;
  letter-spacing: -0.06em;
  text-shadow: 0 18px 60px rgba(0, 0, 0, 0.6);
}

.hero p {
  width: min(600px, 100%);
  margin: 0 0 28px;
  color: #cbd5e1;
  font-size: clamp(16px, 2vw, 20px);
}

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

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 20px;
  border-radius: 999px;
  border: 1px solid rgba(125, 211, 252, 0.22);
  font-weight: 800;
  color: #ffffff;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

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

.btn-primary {
  border: 0;
  background: linear-gradient(135deg, var(--cyan), var(--blue), var(--purple));
  box-shadow: 0 18px 48px rgba(37, 99, 235, 0.28);
}

.btn-ghost {
  background: rgba(15, 23, 42, 0.72);
  backdrop-filter: blur(12px);
}

.btn-small {
  min-height: 36px;
  padding: 0 14px;
  font-size: 14px;
  background: rgba(34, 211, 238, 0.12);
}

.hero-dots {
  position: absolute;
  left: max(24px, calc((100vw - 1180px) / 2));
  bottom: 54px;
  z-index: 3;
  display: flex;
  gap: 10px;
}

.hero-dots button {
  width: 42px;
  height: 5px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.36);
  cursor: pointer;
}

.hero-dots button.is-active {
  background: var(--cyan);
}

.home-search,
.page-hero {
  padding: 72px 0 36px;
}

.home-search .container,
.page-hero .container {
  position: relative;
  padding: 34px;
  border: 1px solid rgba(125, 211, 252, 0.16);
  border-radius: var(--radius-lg);
  background: linear-gradient(135deg, rgba(15, 23, 42, 0.86), rgba(30, 41, 59, 0.64));
  box-shadow: var(--shadow);
  overflow: hidden;
}

.home-search .container::before,
.page-hero .container::before {
  content: "";
  position: absolute;
  inset: -1px;
  background: radial-gradient(circle at top right, rgba(34, 211, 238, 0.22), transparent 24rem);
  pointer-events: none;
}

.home-search h2,
.page-hero h1 {
  position: relative;
  margin: 0 0 12px;
  font-size: clamp(30px, 5vw, 56px);
  line-height: 1.05;
  letter-spacing: -0.04em;
}

.home-search p,
.page-hero p {
  position: relative;
  max-width: 760px;
  margin: 0 0 24px;
  color: #cbd5e1;
}

.search-panel {
  position: relative;
  display: flex;
  width: min(720px, 100%);
  padding: 8px;
  border: 1px solid rgba(125, 211, 252, 0.2);
  border-radius: 999px;
  background: rgba(2, 6, 23, 0.7);
}

.search-panel input {
  flex: 1;
  min-width: 0;
  border: 0;
  outline: 0;
  padding: 0 18px;
  color: #ffffff;
  background: transparent;
}

.search-panel button {
  border: 0;
  border-radius: 999px;
  padding: 12px 22px;
  color: #ffffff;
  font-weight: 800;
  background: linear-gradient(135deg, var(--cyan), var(--blue));
  cursor: pointer;
}

.content-section {
  padding: 54px 0;
}

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

.section-heading.compact {
  margin-bottom: 18px;
}

.section-heading h2 {
  margin: 0;
  font-size: clamp(28px, 4vw, 44px);
  line-height: 1.08;
  letter-spacing: -0.04em;
}

.section-heading p {
  max-width: 520px;
  margin: 0;
  color: var(--muted);
}

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

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

.category-tile,
.category-overview-card {
  position: relative;
  overflow: hidden;
  min-height: 160px;
  padding: 22px;
  border: 1px solid rgba(125, 211, 252, 0.16);
  border-radius: var(--radius);
  background: linear-gradient(135deg, rgba(15, 23, 42, 0.92), rgba(30, 41, 59, 0.68));
  box-shadow: 0 18px 56px rgba(2, 6, 23, 0.28);
}

.category-tile::after,
.category-overview-card::after {
  content: "";
  position: absolute;
  right: -40px;
  bottom: -40px;
  width: 120px;
  height: 120px;
  border-radius: 999px;
  background: rgba(34, 211, 238, 0.14);
}

.category-tile span,
.category-overview-head span {
  display: block;
  margin-bottom: 10px;
  font-size: 22px;
  font-weight: 900;
}

.category-tile small,
.category-overview-card p {
  color: #cbd5e1;
}

.category-overview-card {
  min-height: 260px;
}

.category-overview-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

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

.mini-links {
  position: relative;
  display: grid;
  gap: 8px;
  margin-top: 18px;
}

.mini-links a {
  color: #e2e8f0;
  font-weight: 700;
}

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

.movie-card {
  overflow: hidden;
  border: 1px solid rgba(125, 211, 252, 0.14);
  border-radius: var(--radius);
  background: rgba(15, 23, 42, 0.76);
  box-shadow: 0 18px 56px rgba(2, 6, 23, 0.22);
  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 26px 80px rgba(2, 6, 23, 0.42);
}

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

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

.movie-card:hover .poster-link img {
  transform: scale(1.06);
  filter: saturate(1.1);
}

.poster-link::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(2, 6, 23, 0.76), transparent 52%);
}

.poster-year,
.poster-play {
  position: absolute;
  z-index: 2;
}

.poster-year {
  top: 12px;
  left: 12px;
  padding: 4px 10px;
  border-radius: 999px;
  color: #ffffff;
  font-size: 12px;
  font-weight: 800;
  background: rgba(2, 6, 23, 0.68);
  backdrop-filter: blur(10px);
}

.poster-play {
  right: 12px;
  bottom: 12px;
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 999px;
  color: #020617;
  background: var(--cyan);
  box-shadow: 0 12px 34px rgba(34, 211, 238, 0.34);
}

.movie-card-body {
  padding: 15px;
}

.movie-meta-line {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 8px;
  color: var(--muted);
  font-size: 12px;
}

.movie-meta-line span {
  overflow: hidden;
  max-width: 100%;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.movie-card h3 {
  margin: 0 0 8px;
  min-height: 52px;
  font-size: 17px;
  line-height: 1.35;
}

.movie-card p {
  display: -webkit-box;
  min-height: 66px;
  margin: 0 0 12px;
  overflow: hidden;
  color: #cbd5e1;
  font-size: 14px;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
}

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

.tag-row span {
  padding: 4px 8px;
  border-radius: 999px;
  color: #bae6fd;
  font-size: 12px;
  background: rgba(14, 165, 233, 0.12);
}

.tag-row.large span {
  padding: 7px 12px;
  font-size: 13px;
}

.rank-strip {
  padding: 34px 0;
}

.rank-panel {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 28px;
  border: 1px solid rgba(125, 211, 252, 0.16);
  border-radius: var(--radius-lg);
  background: linear-gradient(135deg, rgba(15, 23, 42, 0.92), rgba(88, 28, 135, 0.34));
  box-shadow: var(--shadow);
}

.rank-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.rank-list a {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 4px 12px;
  align-items: center;
  padding: 14px;
  border-radius: 16px;
  background: rgba(2, 6, 23, 0.34);
}

.rank-no {
  grid-row: span 2;
  color: var(--cyan);
  font-size: 24px;
  font-weight: 900;
}

.rank-list strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.rank-list em {
  overflow: hidden;
  color: var(--muted);
  font-size: 13px;
  font-style: normal;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.breadcrumbs {
  position: relative;
  margin-bottom: 20px;
  color: #cbd5e1;
  font-size: 14px;
}

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

.detail-hero {
  position: relative;
  overflow: hidden;
  padding: 72px 0 64px;
  background: #020617;
}

.detail-backdrop {
  position: absolute;
  inset: 0;
  opacity: 0.22;
  filter: blur(8px) saturate(1.2);
  transform: scale(1.04);
}

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

.detail-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(2, 6, 23, 0.96), rgba(2, 6, 23, 0.72)),
    linear-gradient(0deg, #020617 0%, transparent 64%);
}

.detail-inner {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: 290px 1fr;
  gap: 38px;
  align-items: end;
}

.detail-inner .breadcrumbs {
  grid-column: 1 / -1;
}

.detail-cover {
  margin: 0;
  overflow: hidden;
  border: 1px solid rgba(125, 211, 252, 0.18);
  border-radius: 26px;
  box-shadow: 0 26px 80px rgba(0, 0, 0, 0.45);
}

.detail-cover img {
  aspect-ratio: 2 / 3;
  object-fit: cover;
}

.detail-info h1 {
  margin: 0 0 18px;
  font-size: clamp(40px, 7vw, 78px);
  line-height: 0.98;
  letter-spacing: -0.06em;
}

.lead {
  max-width: 780px;
  margin: 0 0 22px;
  color: #dbeafe;
  font-size: clamp(17px, 2vw, 22px);
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 18px;
}

.detail-meta span {
  padding: 8px 12px;
  border: 1px solid rgba(125, 211, 252, 0.16);
  border-radius: 999px;
  color: #e0f2fe;
  background: rgba(15, 23, 42, 0.62);
}

.watch-section {
  padding: 48px 0 28px;
}

.watch-card {
  overflow: hidden;
  border: 1px solid rgba(125, 211, 252, 0.16);
  border-radius: var(--radius-lg);
  background: rgba(15, 23, 42, 0.78);
  box-shadow: var(--shadow);
}

.watch-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 18px 22px;
  border-bottom: 1px solid rgba(125, 211, 252, 0.12);
}

.watch-heading h2 {
  margin: 0;
  font-size: 22px;
}

.watch-heading span {
  color: var(--muted);
}

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

.movie-player video {
  display: block;
  width: 100%;
  height: 100%;
  background: #000000;
}

.player-cover {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  gap: 14px;
  border: 0;
  color: #ffffff;
  background: radial-gradient(circle at center, rgba(34, 211, 238, 0.18), rgba(2, 6, 23, 0.76));
  cursor: pointer;
}

.player-cover.is-hidden {
  display: none;
}

.play-orb {
  display: grid;
  place-items: center;
  width: 86px;
  height: 86px;
  border-radius: 999px;
  color: #020617;
  font-size: 34px;
  background: linear-gradient(135deg, var(--cyan), #ffffff);
  box-shadow: 0 20px 60px rgba(34, 211, 238, 0.35);
}

.player-cover strong {
  font-size: 18px;
}

.article-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 24px;
  align-items: start;
}

.article-block,
.side-panel {
  padding: 26px;
  border: 1px solid rgba(125, 211, 252, 0.14);
  border-radius: var(--radius);
  background: rgba(15, 23, 42, 0.68);
}

.article-block + .article-block {
  margin-top: 18px;
}

.article-block h2,
.side-panel h2 {
  margin: 0 0 14px;
  font-size: 26px;
}

.article-block p {
  margin: 0;
  color: #dbeafe;
  text-align: justify;
}

.article-block p + p {
  margin-top: 14px;
}

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

.side-panel dl {
  display: grid;
  grid-template-columns: 72px 1fr;
  gap: 12px;
  margin: 0;
}

.side-panel dt {
  color: var(--muted);
}

.side-panel dd {
  margin: 0;
  color: #ffffff;
}

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

.pager-card {
  padding: 22px;
  border: 1px solid rgba(125, 211, 252, 0.14);
  border-radius: var(--radius);
  background: rgba(15, 23, 42, 0.68);
}

.pager-card span {
  display: block;
  margin-bottom: 8px;
  color: var(--cyan);
  font-weight: 800;
}

.pager-card strong {
  font-size: 20px;
}

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

.rank-row {
  display: grid;
  grid-template-columns: 86px 1fr auto;
  gap: 18px;
  align-items: center;
  padding: 14px;
  border: 1px solid rgba(125, 211, 252, 0.14);
  border-radius: var(--radius);
  background: rgba(15, 23, 42, 0.68);
}

.rank-cover {
  overflow: hidden;
  border-radius: 14px;
}

.rank-cover img {
  aspect-ratio: 2 / 3;
  object-fit: cover;
}

.rank-row-title {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 20px;
  font-weight: 900;
}

.rank-row-title span {
  color: var(--cyan);
}

.rank-row p {
  margin: 6px 0 10px;
  color: #cbd5e1;
}

.site-footer {
  margin-top: 42px;
  padding: 42px 0;
  border-top: 1px solid rgba(125, 211, 252, 0.14);
  background: rgba(2, 6, 23, 0.86);
}

.footer-inner {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 18px 32px;
  align-items: center;
}

.footer-inner strong {
  font-size: 22px;
}

.footer-inner p {
  margin: 6px 0 0;
  color: var(--muted);
}

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

.copyright {
  grid-column: 1 / -1;
  font-size: 14px;
}

.is-filter-hidden {
  display: none !important;
}

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

@media (max-width: 980px) {
  .nav-toggle {
    display: block;
  }

  .site-nav {
    position: fixed;
    top: 72px;
    right: 16px;
    left: 16px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    padding: 16px;
    border: 1px solid rgba(125, 211, 252, 0.18);
    border-radius: 20px;
    background: rgba(2, 6, 23, 0.96);
    box-shadow: var(--shadow);
  }

  body.nav-open .site-nav {
    display: flex;
  }

  .hero {
    min-height: 600px;
  }

  .hero-content {
    bottom: 100px;
  }

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

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

  .detail-inner {
    grid-template-columns: 220px 1fr;
  }

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

  .side-panel {
    position: static;
  }
}

@media (max-width: 760px) {
  .hero {
    min-height: 560px;
  }

  .hero-shade {
    background:
      linear-gradient(0deg, #020617 0%, rgba(2, 6, 23, 0.74) 54%, rgba(2, 6, 23, 0.42) 100%);
  }

  .hero-content {
    bottom: 92px;
  }

  .home-search,
  .page-hero {
    padding-top: 42px;
  }

  .home-search .container,
  .page-hero .container {
    padding: 24px;
  }

  .search-panel {
    flex-direction: column;
    border-radius: 22px;
  }

  .search-panel input {
    min-height: 44px;
  }

  .section-heading {
    display: block;
  }

  .section-heading p,
  .section-link {
    display: block;
    margin-top: 12px;
  }

  .category-grid,
  .category-overview-grid,
  .rank-list,
  .pager-section {
    grid-template-columns: 1fr;
  }

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

  .detail-hero {
    padding-top: 42px;
  }

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

  .detail-cover {
    width: min(240px, 78vw);
  }

  .watch-heading {
    display: block;
  }

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

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

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

@media (max-width: 440px) {
  .movie-grid {
    grid-template-columns: 1fr;
  }

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

  .btn {
    width: 100%;
  }
}
