* {
  box-sizing: border-box;
}

:root {
  color-scheme: dark;
  --bg: #020617;
  --bg-soft: #0f172a;
  --panel: rgba(15, 23, 42, 0.78);
  --panel-strong: rgba(15, 23, 42, 0.96);
  --line: rgba(148, 163, 184, 0.18);
  --text: #e5edf8;
  --muted: #94a3b8;
  --weak: #64748b;
  --cyan: #22d3ee;
  --blue: #60a5fa;
  --pink: #fb7185;
  --amber: #fbbf24;
  --green: #34d399;
  --radius: 24px;
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.36);
}

html {
  scroll-behavior: smooth;
}

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

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(148, 163, 184, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(148, 163, 184, 0.05) 1px, transparent 1px);
  background-size: 54px 54px;
  mask-image: linear-gradient(to bottom, black, transparent 75%);
}

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

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

button,
input {
  font: inherit;
}

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

.header-inner {
  max-width: 1440px;
  margin: 0 auto;
  padding: 16px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-weight: 900;
  letter-spacing: -0.04em;
}

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

.brand-name {
  font-size: 24px;
  background: linear-gradient(90deg, #67e8f9, #93c5fd 60%, #f0abfc);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 28px;
}

.nav-link {
  color: #cbd5e1;
  font-size: 15px;
  font-weight: 700;
  transition: color 0.2s ease, transform 0.2s ease;
}

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

.menu-button {
  display: none;
  width: 42px;
  height: 42px;
  border-radius: 14px;
  background: rgba(148, 163, 184, 0.10);
  border: 1px solid var(--line);
  cursor: pointer;
}

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

.mobile-nav {
  display: none;
  padding: 0 24px 16px;
  border-top: 1px solid rgba(148, 163, 184, 0.12);
}

.mobile-nav a {
  display: block;
  padding: 12px 0;
  color: #cbd5e1;
  font-weight: 700;
}

.main-wrap {
  max-width: 1440px;
  margin: 0 auto;
  padding: 28px 24px 64px;
}

.hero {
  position: relative;
  min-height: 660px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 36px;
  box-shadow: var(--shadow);
  background: #020617;
  isolation: isolate;
}

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

.hero-slide {
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.7s ease;
}

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

.hero-bg {
  background-size: cover;
  background-position: center;
  transform: scale(1.05);
  filter: saturate(1.12);
}

.hero-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 24% 26%, rgba(34, 211, 238, 0.26), transparent 22rem),
    linear-gradient(180deg, rgba(2, 6, 23, 0.05), rgba(2, 6, 23, 0.94));
}

.hero-content {
  position: absolute;
  left: clamp(28px, 6vw, 84px);
  bottom: clamp(86px, 12vw, 150px);
  width: min(660px, calc(100% - 56px));
  z-index: 2;
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--cyan);
  font-size: 13px;
  font-weight: 900;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.hero h1 {
  margin: 0;
  max-width: 820px;
  font-size: clamp(42px, 7vw, 92px);
  line-height: 0.95;
  letter-spacing: -0.08em;
  text-shadow: 0 12px 40px rgba(0, 0, 0, 0.45);
}

.hero-summary {
  margin: 22px 0 0;
  max-width: 700px;
  color: #dbeafe;
  font-size: 18px;
  line-height: 1.85;
}

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

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

.hero-tags span,
.tag-row span,
.info-chip,
.breadcrumb a,
.breadcrumb span {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid rgba(34, 211, 238, 0.22);
  background: rgba(15, 23, 42, 0.56);
  color: #cffafe;
  font-size: 12px;
  font-weight: 800;
}

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

.primary-button,
.ghost-button,
.section-more {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 22px;
  border-radius: 999px;
  font-weight: 900;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.primary-button {
  background: linear-gradient(135deg, var(--cyan), var(--blue));
  color: #020617;
  box-shadow: 0 16px 36px rgba(34, 211, 238, 0.28);
}

.ghost-button,
.section-more {
  border: 1px solid rgba(148, 163, 184, 0.28);
  background: rgba(15, 23, 42, 0.50);
  color: #e2e8f0;
}

.primary-button:hover,
.ghost-button:hover,
.section-more:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 44px rgba(14, 165, 233, 0.16);
}

.hero-poster {
  position: absolute;
  right: clamp(26px, 6vw, 88px);
  top: 92px;
  z-index: 2;
  width: min(330px, 24vw);
  aspect-ratio: 2 / 3;
  border-radius: 30px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.22);
  box-shadow: 0 40px 110px rgba(0, 0, 0, 0.52);
  transform: rotate(2deg);
}

.hero-poster img {
  height: 100%;
  object-fit: cover;
}

.hero-control {
  position: absolute;
  left: clamp(28px, 6vw, 84px);
  bottom: 32px;
  z-index: 3;
  display: flex;
  align-items: center;
  gap: 14px;
}

.hero-control button {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: 1px solid rgba(148, 163, 184, 0.28);
  background: rgba(15, 23, 42, 0.60);
  color: #e2e8f0;
  cursor: pointer;
}

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

.hero-dots button {
  width: 11px;
  height: 11px;
  min-width: 11px;
  border-radius: 999px;
  padding: 0;
}

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

.hero-rank {
  position: absolute;
  right: 30px;
  bottom: 30px;
  z-index: 4;
  width: min(390px, 32vw);
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 26px;
  background: rgba(2, 6, 23, 0.68);
  backdrop-filter: blur(18px);
}

.hero-rank h2 {
  margin: 0 0 14px;
  font-size: 20px;
}

.mini-item {
  display: grid;
  grid-template-columns: auto 56px 1fr;
  align-items: center;
  gap: 12px;
  padding: 10px;
  border-radius: 18px;
  transition: background 0.2s ease, transform 0.2s ease;
}

.mini-item:hover {
  background: rgba(148, 163, 184, 0.10);
  transform: translateX(3px);
}

.mini-rank {
  width: 28px;
  height: 28px;
  display: inline-grid;
  place-items: center;
  border-radius: 10px;
  background: rgba(34, 211, 238, 0.16);
  color: var(--cyan);
  font-size: 13px;
  font-weight: 900;
}

.mini-item img {
  width: 56px;
  height: 76px;
  border-radius: 12px;
  object-fit: cover;
}

.mini-item strong,
.mini-item em {
  display: block;
}

.mini-item strong {
  color: #f8fafc;
  font-size: 14px;
}

.mini-item em {
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  line-height: 1.5;
}

.content-section,
.page-hero,
.detail-shell,
.player-section {
  margin-top: 36px;
}

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

.section-heading h1,
.section-heading h2,
.page-hero h1,
.detail-info h1 {
  margin: 0;
  font-size: clamp(30px, 4vw, 54px);
  line-height: 1.05;
  letter-spacing: -0.06em;
}

.section-heading p,
.page-hero p,
.detail-info p,
.category-card em {
  color: var(--muted);
  line-height: 1.8;
}

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

.movie-card {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.88), rgba(15, 23, 42, 0.46));
  box-shadow: 0 18px 44px rgba(0, 0, 0, 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 24px 64px rgba(8, 145, 178, 0.18);
}

.poster-link {
  position: relative;
  display: block;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  background: rgba(15, 23, 42, 0.62);
}

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

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

.poster-shine {
  position: absolute;
  inset: auto 0 0;
  height: 46%;
  background: linear-gradient(180deg, transparent, rgba(2, 6, 23, 0.90));
}

.card-rank {
  position: absolute;
  left: 10px;
  top: 10px;
  z-index: 2;
  min-width: 36px;
  height: 36px;
  display: inline-grid;
  place-items: center;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--amber), var(--pink));
  color: #020617;
  font-size: 16px;
  box-shadow: 0 12px 28px rgba(251, 191, 36, 0.24);
}

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

.meta-line,
.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

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

.movie-card p {
  min-height: 52px;
  margin: 0 0 12px;
  color: #aebfd2;
  font-size: 13px;
  line-height: 1.7;
}

.tag-row span {
  min-height: 24px;
  padding: 4px 8px;
  color: #bae6fd;
  background: rgba(14, 165, 233, 0.10);
}

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

.category-card {
  position: relative;
  min-height: 260px;
  overflow: hidden;
  border-radius: 28px;
  border: 1px solid var(--line);
  padding: 22px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  box-shadow: var(--shadow);
}

.category-card img,
.category-overlay {
  position: absolute;
  inset: 0;
  height: 100%;
  object-fit: cover;
}

.category-overlay {
  background: linear-gradient(180deg, rgba(2, 6, 23, 0.12), rgba(2, 6, 23, 0.92));
  z-index: 1;
}

.category-card strong,
.category-card em {
  position: relative;
  z-index: 2;
}

.category-card strong {
  font-size: 24px;
}

.category-card em {
  margin-top: 8px;
  font-style: normal;
  font-size: 14px;
}

.page-hero {
  padding: clamp(34px, 6vw, 70px);
  border: 1px solid var(--line);
  border-radius: 34px;
  background:
    radial-gradient(circle at top right, rgba(34, 211, 238, 0.18), transparent 26rem),
    linear-gradient(135deg, rgba(15, 23, 42, 0.96), rgba(8, 47, 73, 0.55));
  box-shadow: var(--shadow);
}

.page-hero p {
  max-width: 820px;
  margin: 18px 0 0;
}

.filter-panel {
  margin: 26px 0 24px;
  padding: 18px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: rgba(15, 23, 42, 0.70);
}

.search-box {
  flex: 1 1 320px;
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--muted);
  font-weight: 800;
}

.search-box input {
  width: 100%;
  min-height: 46px;
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 999px;
  outline: none;
  padding: 0 18px;
  background: rgba(2, 6, 23, 0.64);
  color: var(--text);
}

.filter-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.filter-chips button {
  min-height: 40px;
  padding: 0 14px;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.24);
  background: rgba(30, 41, 59, 0.74);
  color: #cbd5e1;
  cursor: pointer;
}

.filter-chips button.is-active {
  border-color: rgba(34, 211, 238, 0.56);
  color: #020617;
  background: linear-gradient(135deg, var(--cyan), var(--blue));
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 24px 0;
}

.detail-shell {
  display: grid;
  grid-template-columns: 360px 1fr;
  gap: 34px;
  align-items: start;
}

.detail-cover {
  position: sticky;
  top: 94px;
  overflow: hidden;
  border-radius: 30px;
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
}

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

.detail-info {
  padding: clamp(24px, 4vw, 46px);
  border-radius: 34px;
  border: 1px solid var(--line);
  background: rgba(15, 23, 42, 0.74);
  box-shadow: var(--shadow);
}

.detail-info h1 {
  margin-top: 10px;
}

.detail-meta {
  margin: 18px 0;
}

.detail-text {
  display: grid;
  gap: 22px;
  margin-top: 24px;
}

.detail-text h2 {
  margin: 0 0 10px;
  font-size: 22px;
}

.detail-text p {
  margin: 0;
  color: #cbd5e1;
  font-size: 16px;
  line-height: 1.95;
}

.player-section {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 34px;
  background: rgba(2, 6, 23, 0.88);
  box-shadow: var(--shadow);
}

.player-heading {
  padding: 24px 26px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  border-bottom: 1px solid var(--line);
}

.player-heading h2 {
  margin: 0;
  font-size: 24px;
}

.media-player {
  position: relative;
  background: #000;
}

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

.play-layer {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  border: 0;
  cursor: pointer;
  background: linear-gradient(180deg, rgba(2, 6, 23, 0.10), rgba(2, 6, 23, 0.56));
}

.play-layer[hidden] {
  display: none;
}

.play-layer span {
  width: 84px;
  height: 84px;
  display: inline-grid;
  place-items: center;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--cyan), var(--blue));
  color: #020617;
  font-size: 32px;
  box-shadow: 0 0 50px rgba(34, 211, 238, 0.42);
}

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

.rank-row {
  display: grid;
  grid-template-columns: 64px 92px 1fr auto;
  align-items: center;
  gap: 16px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: rgba(15, 23, 42, 0.72);
}

.rank-row:hover {
  border-color: rgba(34, 211, 238, 0.42);
}

.rank-row b {
  color: var(--cyan);
  font-size: 26px;
  text-align: center;
}

.rank-row img {
  width: 92px;
  height: 126px;
  object-fit: cover;
  border-radius: 16px;
}

.rank-row h3 {
  margin: 0 0 8px;
  font-size: 22px;
}

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

.rank-score {
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(34, 211, 238, 0.13);
  color: #67e8f9;
  font-weight: 900;
}

.site-footer {
  border-top: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.52), rgba(2, 6, 23, 0.95));
}

.footer-grid,
.footer-bottom {
  max-width: 1440px;
  margin: 0 auto;
  padding-left: 24px;
  padding-right: 24px;
}

.footer-grid {
  padding-top: 42px;
  padding-bottom: 32px;
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 36px;
}

.footer-grid h2,
.footer-grid h3 {
  margin: 0 0 14px;
}

.footer-grid p,
.footer-grid a,
.footer-bottom {
  color: var(--muted);
  line-height: 1.8;
}

.footer-grid ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 8px;
}

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

.footer-bottom {
  padding-top: 18px;
  padding-bottom: 28px;
  border-top: 1px solid rgba(148, 163, 184, 0.12);
  display: flex;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
  font-size: 14px;
}

.hidden-card {
  display: none !important;
}

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

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

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

  .menu-button {
    display: block;
  }

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

  .hero {
    min-height: 820px;
  }

  .hero-poster,
  .hero-rank {
    display: none;
  }

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

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

  .detail-cover {
    position: static;
    max-width: 360px;
  }

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

  .rank-score {
    grid-column: 2 / -1;
    justify-self: start;
  }

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

@media (max-width: 680px) {
  .header-inner,
  .main-wrap,
  .footer-grid,
  .footer-bottom {
    padding-left: 16px;
    padding-right: 16px;
  }

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

  .hero {
    border-radius: 24px;
    min-height: 720px;
  }

  .hero-content {
    left: 20px;
    bottom: 90px;
    width: calc(100% - 40px);
  }

  .hero-summary {
    font-size: 15px;
  }

  .hero-actions {
    flex-direction: column;
  }

  .primary-button,
  .ghost-button,
  .section-more {
    width: 100%;
  }

  .hero-control {
    left: 20px;
    bottom: 28px;
  }

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

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

  .movie-card h3 {
    font-size: 16px;
  }

  .movie-card p {
    display: none;
  }

  .page-hero,
  .detail-info {
    border-radius: 24px;
    padding: 24px;
  }

  .filter-panel {
    padding: 14px;
  }

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

  .rank-row img {
    width: 74px;
    height: 102px;
  }

  .rank-row h3 {
    font-size: 17px;
  }
}
