:root {
  --bg: #020617;
  --panel: rgba(15, 23, 42, 0.84);
  --panel-strong: #0f172a;
  --line: rgba(148, 163, 184, 0.18);
  --muted: #94a3b8;
  --text: #f8fafc;
  --cyan: #22d3ee;
  --blue: #38bdf8;
  --rose: #fb7185;
  --shadow: 0 24px 70px rgba(0, 0, 0, 0.36);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--text);
  background:
    radial-gradient(circle at top left, rgba(34, 211, 238, 0.16), transparent 34rem),
    radial-gradient(circle at top right, rgba(59, 130, 246, 0.14), transparent 32rem),
    linear-gradient(180deg, #020617 0%, #08111f 48%, #020617 100%);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  line-height: 1.65;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  background-image:
    linear-gradient(rgba(34, 211, 238, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(34, 211, 238, 0.04) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: linear-gradient(to bottom, #000, transparent 72%);
}

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

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

button,
input,
select {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid rgba(148, 163, 184, 0.2);
  background: linear-gradient(90deg, rgba(15, 23, 42, 0.96), rgba(30, 41, 59, 0.92), rgba(15, 23, 42, 0.96));
  backdrop-filter: blur(18px);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.22);
}

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

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

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

.brand-text {
  font-size: 20px;
}

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

.desktop-nav {
  display: flex;
}

.nav-link {
  padding: 9px 14px;
  border-radius: 999px;
  color: #cbd5e1;
  transition: 0.25s ease;
}

.nav-link:hover,
.nav-link.is-active {
  color: #fff;
  background: rgba(34, 211, 238, 0.14);
  box-shadow: inset 0 0 0 1px rgba(34, 211, 238, 0.16);
}

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

.menu-button span {
  display: block;
  width: 18px;
  height: 2px;
  margin: 4px auto;
  border-radius: 999px;
  background: #e2e8f0;
}

.mobile-nav {
  display: none;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto 14px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: rgba(15, 23, 42, 0.96);
}

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

.hero-shell {
  position: relative;
  min-height: 680px;
  overflow: hidden;
  border-bottom: 1px solid rgba(148, 163, 184, 0.16);
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: grid;
  align-items: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.7s ease;
}

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

.hero-slide > img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(1.12) contrast(1.05);
  transform: scale(1.02);
}

.hero-shade {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 68% 38%, rgba(34, 211, 238, 0.2), transparent 28rem),
    linear-gradient(90deg, rgba(2, 6, 23, 0.95) 0%, rgba(2, 6, 23, 0.74) 43%, rgba(2, 6, 23, 0.28) 100%),
    linear-gradient(0deg, rgba(2, 6, 23, 0.98) 0%, transparent 45%);
}

.hero-content {
  position: relative;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 138px 0 190px;
}

.hero-kicker,
.section-kicker {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  margin-bottom: 14px;
  padding: 7px 12px;
  border: 1px solid rgba(34, 211, 238, 0.26);
  border-radius: 999px;
  color: var(--cyan);
  background: rgba(34, 211, 238, 0.1);
  font-size: 13px;
  font-weight: 700;
}

.hero-content h1 {
  max-width: 780px;
  margin: 0 0 20px;
  font-size: clamp(42px, 7vw, 82px);
  line-height: 1.02;
  letter-spacing: -0.05em;
  background: linear-gradient(90deg, #f8fafc, #67e8f9, #38bdf8);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-content p {
  max-width: 680px;
  margin: 0;
  color: #cbd5e1;
  font-size: clamp(17px, 2vw, 21px);
}

.hero-tags,
.detail-meta,
.card-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}

.hero-tags {
  margin-top: 24px;
}

.hero-tags span,
.detail-meta span,
.card-meta span {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 4px 10px;
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 999px;
  color: #cbd5e1;
  background: rgba(15, 23, 42, 0.55);
  font-size: 13px;
}

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

.primary-button,
.secondary-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 20px;
  border-radius: 999px;
  font-weight: 800;
  transition: 0.25s ease;
}

.primary-button {
  color: #001018;
  background: linear-gradient(135deg, var(--cyan), var(--blue));
  box-shadow: 0 18px 44px rgba(34, 211, 238, 0.32);
}

.secondary-button {
  border: 1px solid rgba(148, 163, 184, 0.25);
  color: #e2e8f0;
  background: rgba(15, 23, 42, 0.68);
}

.primary-button:hover,
.secondary-button:hover {
  transform: translateY(-2px);
}

.hero-thumbs {
  position: absolute;
  left: 50%;
  bottom: 34px;
  z-index: 5;
  width: min(1180px, calc(100% - 32px));
  transform: translateX(-50%);
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 12px;
}

.hero-thumb {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  padding: 10px;
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 18px;
  color: #e2e8f0;
  background: rgba(15, 23, 42, 0.72);
  backdrop-filter: blur(12px);
}

.hero-thumb.is-active {
  border-color: rgba(34, 211, 238, 0.55);
  background: rgba(8, 47, 73, 0.78);
}

.hero-thumb img {
  width: 58px;
  height: 48px;
  flex: 0 0 auto;
  object-fit: cover;
  border-radius: 12px;
}

.hero-thumb span {
  overflow: hidden;
  text-align: left;
  text-overflow: ellipsis;
  white-space: nowrap;
}

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

.page-main {
  padding-top: 34px;
}

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

.section-heading h2,
.intro-panel h2,
.rank-panel h2,
.page-hero h1,
.detail-copy h1,
.detail-article h2,
.category-overview-card h2 {
  margin: 0;
  line-height: 1.18;
  letter-spacing: -0.03em;
}

.section-heading h2,
.intro-panel h2,
.rank-panel h2 {
  font-size: clamp(26px, 3vw, 38px);
}

.section-heading a {
  color: var(--cyan);
  font-weight: 700;
}

.intro-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(320px, 0.8fr);
  gap: 22px;
}

.intro-panel,
.rank-panel,
.category-overview-card,
.filter-panel,
.detail-article {
  border: 1px solid var(--line);
  border-radius: 28px;
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.86), rgba(15, 23, 42, 0.58));
  box-shadow: var(--shadow);
}

.intro-panel,
.rank-panel {
  padding: 28px;
}

.intro-panel p,
.rank-panel p,
.page-hero p,
.detail-one-line,
.detail-article p,
.category-overview-card p,
.site-footer p {
  color: var(--muted);
}

.stat-row {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 28px;
}

.stat-row span {
  padding: 12px 16px;
  border-radius: 18px;
  color: #cbd5e1;
  background: rgba(2, 6, 23, 0.42);
}

.stat-row strong {
  display: block;
  color: var(--cyan);
  font-size: 30px;
  line-height: 1;
}

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

.compact-card {
  display: grid;
  grid-template-columns: 68px 1fr;
  gap: 12px;
  align-items: center;
  min-width: 0;
  padding: 8px;
  border-radius: 18px;
  transition: 0.25s ease;
}

.compact-card:hover {
  background: rgba(34, 211, 238, 0.1);
}

.compact-card img {
  width: 68px;
  height: 52px;
  object-fit: cover;
  border-radius: 13px;
}

.compact-card span {
  min-width: 0;
}

.compact-card strong,
.compact-card em {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.compact-card strong {
  color: #f8fafc;
}

.compact-card em {
  color: var(--muted);
  font-size: 13px;
  font-style: normal;
}

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

.category-tile {
  position: relative;
  min-height: 180px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 26px;
  box-shadow: var(--shadow);
}

.category-tile img,
.tile-shade {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.category-tile img {
  object-fit: cover;
  transition: 0.45s ease;
}

.category-tile:hover img {
  transform: scale(1.08);
}

.tile-shade {
  background: linear-gradient(0deg, rgba(2, 6, 23, 0.9), rgba(2, 6, 23, 0.12));
}

.category-tile strong,
.category-tile em {
  position: absolute;
  left: 16px;
  right: 16px;
}

.category-tile strong {
  bottom: 42px;
  font-size: 20px;
}

.category-tile em {
  bottom: 16px;
  color: #cbd5e1;
  font-style: normal;
}

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

.search-box,
.select-box {
  display: grid;
  gap: 6px;
  color: #cbd5e1;
  font-size: 13px;
  font-weight: 700;
}

.search-box input,
.select-box select {
  width: 100%;
  min-height: 46px;
  border: 1px solid rgba(148, 163, 184, 0.2);
  border-radius: 16px;
  outline: none;
  color: #f8fafc;
  background: rgba(2, 6, 23, 0.55);
  padding: 0 14px;
}

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

.movie-card {
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 24px;
  background: rgba(15, 23, 42, 0.62);
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.2);
  transition: 0.28s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  border-color: rgba(34, 211, 238, 0.36);
  box-shadow: 0 24px 65px rgba(34, 211, 238, 0.12);
}

.poster-link {
  position: relative;
  display: block;
  aspect-ratio: 16 / 10;
  overflow: hidden;
}

.poster-link img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: 0.45s ease;
}

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

.poster-gradient {
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(2, 6, 23, 0.86), transparent 54%);
}

.card-year {
  position: absolute;
  right: 12px;
  top: 12px;
  padding: 5px 10px;
  border-radius: 999px;
  color: #001018;
  background: var(--cyan);
  font-size: 12px;
  font-weight: 900;
}

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

.card-tags,
.detail-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.card-tags span,
.detail-tags span {
  display: inline-flex;
  padding: 4px 8px;
  border-radius: 999px;
  color: #a5f3fc;
  background: rgba(34, 211, 238, 0.11);
  font-size: 12px;
}

.movie-card h3 {
  margin: 10px 0 8px;
  font-size: 19px;
  line-height: 1.25;
}

.movie-card h3 a:hover,
.rank-info h2 a:hover,
.category-overview-card h2 a:hover {
  color: var(--cyan);
}

.movie-card p {
  min-height: 54px;
  margin: 0 0 12px;
  color: var(--muted);
  font-size: 14px;
}

.card-meta {
  gap: 6px;
}

.card-meta span {
  min-height: 24px;
  font-size: 12px;
}

.page-hero {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 74px 0 34px;
}

.small-hero,
.category-hero {
  min-height: 280px;
}

.page-hero h1 {
  max-width: 850px;
  font-size: clamp(38px, 6vw, 68px);
}

.page-hero p {
  max-width: 760px;
  font-size: 18px;
}

.hero-inline-list {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-top: 26px;
}

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

.category-overview-card {
  display: grid;
  grid-template-columns: 190px 1fr;
  gap: 20px;
  padding: 18px;
}

.category-cover-pair {
  position: relative;
  min-height: 150px;
}

.category-cover-pair img {
  position: absolute;
  width: 64%;
  height: 82%;
  object-fit: cover;
  border-radius: 20px;
  box-shadow: var(--shadow);
}

.category-cover-pair img:first-child {
  left: 0;
  top: 0;
  z-index: 2;
}

.category-cover-pair img:last-child {
  right: 0;
  bottom: 0;
  opacity: 0.78;
}

.category-overview-card h2 {
  font-size: 26px;
}

.category-overview-card span {
  display: inline-flex;
  margin-top: 12px;
  color: var(--cyan);
  font-weight: 800;
}

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

.rank-row {
  display: grid;
  grid-template-columns: 74px 140px 1fr;
  gap: 16px;
  align-items: center;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: rgba(15, 23, 42, 0.64);
}

.rank-num {
  display: grid;
  place-items: center;
  width: 58px;
  height: 58px;
  border-radius: 18px;
  color: #001018;
  background: linear-gradient(135deg, var(--cyan), var(--blue));
  font-size: 20px;
  font-weight: 900;
}

.rank-poster img {
  width: 140px;
  height: 90px;
  object-fit: cover;
  border-radius: 18px;
}

.rank-info h2 {
  margin: 0 0 6px;
  font-size: 24px;
}

.rank-info p {
  margin: 0 0 10px;
  color: var(--muted);
}

.breadcrumb {
  width: min(1180px, calc(100% - 32px));
  margin: 24px auto 0;
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  color: #94a3b8;
  font-size: 14px;
}

.breadcrumb a {
  color: #cbd5e1;
}

.breadcrumb em {
  color: var(--cyan);
  font-style: normal;
}

.detail-hero {
  width: min(1180px, calc(100% - 32px));
  margin: 24px auto 0;
  display: grid;
  grid-template-columns: 320px 1fr;
  gap: 34px;
  align-items: center;
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: 34px;
  background:
    radial-gradient(circle at 80% 20%, rgba(34, 211, 238, 0.14), transparent 24rem),
    rgba(15, 23, 42, 0.68);
  box-shadow: var(--shadow);
}

.detail-poster img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: 28px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.36);
}

.detail-copy h1 {
  font-size: clamp(36px, 5vw, 68px);
}

.detail-one-line {
  margin: 16px 0 20px;
  font-size: 19px;
}

.detail-tags {
  margin-top: 18px;
}

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

.player-frame {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16 / 9;
  border: 1px solid rgba(34, 211, 238, 0.24);
  border-radius: 30px;
  background: #000;
  box-shadow: var(--shadow);
}

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

.play-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background: radial-gradient(circle, rgba(34, 211, 238, 0.16), rgba(2, 6, 23, 0.54));
  cursor: pointer;
}

.play-overlay.is-hidden {
  display: none;
}

.play-button {
  width: 92px;
  height: 92px;
  border: 0;
  border-radius: 999px;
  color: #001018;
  background: linear-gradient(135deg, var(--cyan), var(--blue));
  box-shadow: 0 0 0 14px rgba(34, 211, 238, 0.12), 0 22px 60px rgba(34, 211, 238, 0.32);
}

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

.detail-text-wrap {
  padding-top: 34px;
  padding-bottom: 20px;
}

.detail-article {
  padding: 30px;
}

.detail-article h2 {
  margin: 0 0 12px;
  font-size: 28px;
}

.detail-article p + h2 {
  margin-top: 28px;
}

.detail-article p {
  margin: 0;
  font-size: 17px;
}

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

.footer-inner {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 36px 0;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 26px;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 12px;
}

.footer-links a {
  color: #cbd5e1;
}

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

.to-top {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 40;
  width: 46px;
  height: 46px;
  border: 1px solid rgba(34, 211, 238, 0.34);
  border-radius: 16px;
  color: #001018;
  background: var(--cyan);
  opacity: 0;
  pointer-events: none;
  transition: 0.25s ease;
}

.to-top.is-visible {
  opacity: 1;
  pointer-events: auto;
}

.is-filtered-out {
  display: none !important;
}

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

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

  .intro-grid,
  .detail-hero,
  .category-overview-grid {
    grid-template-columns: 1fr;
  }

  .detail-poster {
    max-width: 360px;
  }
}

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

  .menu-button {
    display: block;
  }

  .hero-shell {
    min-height: 760px;
  }

  .hero-content {
    padding-top: 90px;
    padding-bottom: 250px;
  }

  .hero-thumbs,
  .category-grid,
  .movie-grid,
  .filter-panel,
  .footer-inner {
    grid-template-columns: 1fr;
  }

  .hero-thumb:nth-child(n+4) {
    display: none;
  }

  .section-heading {
    align-items: flex-start;
    flex-direction: column;
  }

  .rank-row {
    grid-template-columns: 52px 96px 1fr;
    gap: 10px;
  }

  .rank-num {
    width: 46px;
    height: 46px;
    font-size: 16px;
  }

  .rank-poster img {
    width: 96px;
    height: 74px;
  }

  .rank-info h2 {
    font-size: 18px;
  }

  .rank-info p {
    display: none;
  }

  .category-overview-card {
    grid-template-columns: 1fr;
  }

  .category-cover-pair {
    min-height: 190px;
  }

  .detail-hero {
    padding: 18px;
  }

  .footer-links {
    justify-content: flex-start;
  }
}
