:root {
  --slate-950: #020617;
  --slate-900: #0f172a;
  --slate-800: #1e293b;
  --slate-700: #334155;
  --slate-600: #475569;
  --slate-500: #64748b;
  --slate-200: #e2e8f0;
  --slate-100: #f1f5f9;
  --slate-50: #f8fafc;
  --amber-700: #b45309;
  --amber-600: #d97706;
  --amber-500: #f59e0b;
  --amber-400: #fbbf24;
  --amber-200: #fde68a;
  --rose-500: #f43f5e;
  --orange-500: #f97316;
  --white: #ffffff;
  --shadow-sm: 0 8px 20px rgba(15, 23, 42, 0.08);
  --shadow-md: 0 18px 45px rgba(15, 23, 42, 0.16);
  --shadow-lg: 0 24px 70px rgba(15, 23, 42, 0.24);
  --radius-lg: 18px;
  --radius-xl: 26px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
  color: var(--slate-900);
  background: linear-gradient(180deg, var(--slate-50), var(--slate-100));
  line-height: 1.6;
}

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

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

button,
input,
select {
  font: inherit;
}

.site-nav {
  position: sticky;
  top: 0;
  z-index: 50;
  color: var(--white);
  background: linear-gradient(90deg, var(--slate-900), var(--slate-800), var(--slate-900));
  box-shadow: var(--shadow-sm);
  backdrop-filter: blur(12px);
}

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

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

.brand-icon {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 10px;
  color: var(--slate-900);
  background: linear-gradient(135deg, var(--amber-200), var(--amber-500));
  box-shadow: 0 12px 32px rgba(245, 158, 11, 0.35);
}

.brand-text {
  font-size: 1.2rem;
  color: transparent;
  background: linear-gradient(90deg, var(--amber-200), var(--amber-400));
  -webkit-background-clip: text;
  background-clip: text;
}

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

.nav-link {
  padding: 9px 16px;
  border-radius: 12px;
  color: var(--slate-200);
  transition: color 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}

.nav-link:hover,
.nav-link.is-active {
  color: var(--white);
  background: var(--amber-500);
  box-shadow: 0 12px 30px rgba(245, 158, 11, 0.3);
}

.nav-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 12px;
  color: var(--white);
  background: rgba(255, 255, 255, 0.08);
}

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

.page-shell {
  min-height: 70vh;
}

.hero {
  position: relative;
  min-height: 70vh;
  overflow: hidden;
  background: var(--slate-900);
}

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

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

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

.hero-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.02);
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 18% 28%, rgba(245, 158, 11, 0.26), transparent 28%),
    linear-gradient(0deg, rgba(15, 23, 42, 0.98), rgba(15, 23, 42, 0.55) 45%, rgba(15, 23, 42, 0.18));
}

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

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 14px;
  color: var(--amber-400);
  font-size: 0.92rem;
  font-weight: 800;
  letter-spacing: 0.08em;
}

.eyebrow::before {
  content: "";
  width: 9px;
  height: 9px;
  border-radius: 999px;
  background: var(--amber-400);
  box-shadow: 0 0 0 6px rgba(251, 191, 36, 0.18);
}

.hero h1,
.page-hero h1,
.detail-copy h1 {
  margin: 0;
  font-size: clamp(2.3rem, 6vw, 4.8rem);
  line-height: 1.05;
  font-weight: 900;
  letter-spacing: -0.04em;
}

.hero p {
  max-width: 58ch;
  margin: 18px 0 22px;
  color: var(--slate-200);
  font-size: 1.08rem;
}

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

.hero-meta span,
.detail-meta span {
  padding: 5px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.14);
  color: var(--slate-100);
  font-size: 0.9rem;
}

.primary-button,
.text-button,
.section-more {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: 14px;
  font-weight: 800;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.primary-button {
  margin-top: 24px;
  padding: 13px 26px;
  color: var(--white);
  background: var(--amber-500);
  box-shadow: 0 18px 40px rgba(245, 158, 11, 0.35);
}

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

.primary-button:hover {
  background: var(--amber-600);
  box-shadow: 0 24px 55px rgba(245, 158, 11, 0.45);
}

.hero-thumbs {
  position: absolute;
  right: max(24px, calc((100vw - 1180px) / 2));
  bottom: 44px;
  width: min(470px, calc(100% - 48px));
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 10px;
}

.hero-thumb {
  min-width: 0;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 16px;
  overflow: hidden;
  color: var(--white);
  background: rgba(15, 23, 42, 0.68);
  box-shadow: var(--shadow-sm);
  cursor: pointer;
  opacity: 0.72;
  transition: transform 0.2s ease, opacity 0.2s ease, border-color 0.2s ease;
}

.hero-thumb.is-active,
.hero-thumb:hover {
  opacity: 1;
  border-color: var(--amber-400);
  transform: translateY(-4px);
}

.hero-thumb img {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
}

.hero-thumb span {
  display: block;
  padding: 8px;
  overflow: hidden;
  font-size: 0.78rem;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.content-section,
.category-overview-card,
.detail-content-grid,
.player-section,
.page-hero {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
}

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

.content-section.no-top-space {
  padding-top: 26px;
}

.section-head,
.panel-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 24px;
}

.section-head h2,
.panel-head h2,
.detail-article h2,
.detail-info-card h2 {
  margin: 0;
  font-size: clamp(1.45rem, 3vw, 2rem);
  line-height: 1.2;
  font-weight: 900;
  color: var(--slate-900);
}

.section-head p {
  margin: 8px 0 0;
  color: var(--slate-600);
}

.section-more,
.text-button {
  color: var(--amber-700);
}

.movie-grid {
  display: grid;
  gap: 22px;
}

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

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

.movie-card {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-lg);
  background: var(--white);
  box-shadow: var(--shadow-sm);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-md);
}

.card-cover {
  position: relative;
  margin: 0;
  overflow: hidden;
  background: var(--slate-800);
}

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

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

.card-cover figcaption,
.rank-badge {
  position: absolute;
  z-index: 2;
  color: var(--white);
  border-radius: 10px;
  font-weight: 800;
  background: rgba(2, 6, 23, 0.78);
  backdrop-filter: blur(8px);
}

.card-cover figcaption {
  right: 10px;
  bottom: 10px;
  padding: 4px 9px;
  font-size: 0.78rem;
}

.rank-badge {
  top: 10px;
  left: 10px;
  padding: 5px 11px;
  background: var(--amber-500);
  box-shadow: 0 12px 24px rgba(245, 158, 11, 0.32);
}

.card-body {
  padding: 16px;
}

.card-body h3 {
  min-height: 3rem;
  margin: 0;
  color: var(--slate-900);
  font-size: 1rem;
  line-height: 1.45;
  font-weight: 850;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.card-body p {
  min-height: 2.8rem;
  margin: 9px 0 12px;
  color: var(--slate-600);
  font-size: 0.9rem;
  line-height: 1.55;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.card-meta {
  justify-content: space-between;
  color: var(--slate-500);
  font-size: 0.8rem;
}

.card-meta span:first-child {
  padding: 3px 8px;
  border-radius: 999px;
  color: var(--amber-700);
  background: #fef3c7;
}

.card-tags {
  margin-top: 10px;
  color: var(--slate-500);
  font-size: 0.78rem;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.split-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 350px;
  gap: 28px;
  align-items: start;
}

.ranking-panel,
.detail-info-card,
.detail-article,
.filter-bar,
.category-overview-card {
  border: 1px solid rgba(148, 163, 184, 0.24);
  border-radius: var(--radius-xl);
  background: rgba(255, 255, 255, 0.86);
  box-shadow: var(--shadow-sm);
  backdrop-filter: blur(14px);
}

.ranking-panel {
  position: sticky;
  top: 88px;
  padding: 22px;
}

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

.rank-item a {
  display: grid;
  grid-template-columns: auto 72px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  padding: 10px;
  border-radius: 16px;
  background: var(--slate-50);
  transition: background 0.2s ease, transform 0.2s ease;
}

.rank-item a:hover {
  transform: translateX(3px);
  background: #fff7ed;
}

.rank-item img {
  width: 72px;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  border-radius: 12px;
}

.list-rank {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  color: var(--white);
  font-weight: 900;
  background: var(--amber-500);
}

.rank-copy {
  min-width: 0;
}

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

.rank-copy strong {
  color: var(--slate-900);
  font-size: 0.95rem;
}

.rank-copy em {
  color: var(--slate-500);
  font-style: normal;
  font-size: 0.82rem;
}

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

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

.category-card {
  position: relative;
  min-height: 210px;
  overflow: hidden;
  border-radius: var(--radius-xl);
  color: var(--white);
  box-shadow: var(--shadow-sm);
  background: var(--slate-900);
}

.category-card img {
  width: 100%;
  height: 100%;
  min-height: 210px;
  object-fit: cover;
  transition: transform 0.35s ease;
}

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

.category-mask {
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(2, 6, 23, 0.88), rgba(2, 6, 23, 0.2));
}

.category-info {
  position: absolute;
  inset: auto 18px 18px;
}

.category-info strong,
.category-info em {
  display: block;
}

.category-info strong {
  margin-bottom: 8px;
  font-size: 1.2rem;
  font-weight: 900;
}

.category-info em {
  color: var(--slate-200);
  font-style: normal;
  font-size: 0.9rem;
}

.site-footer {
  color: var(--slate-300);
  background: linear-gradient(90deg, var(--slate-900), var(--slate-800), var(--slate-900));
}

.footer-inner {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 48px 0 28px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 36px;
  padding-bottom: 30px;
  border-bottom: 1px solid rgba(226, 232, 240, 0.12);
}

.footer-brand {
  margin-bottom: 12px;
  color: var(--white);
  font-size: 1.1rem;
}

.footer-grid p {
  margin: 0;
  color: var(--slate-500);
}

.footer-grid h2 {
  margin: 0 0 14px;
  color: var(--white);
  font-size: 1rem;
}

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

.footer-links a {
  color: var(--slate-400);
  transition: color 0.2s ease;
}

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

.footer-bottom {
  padding-top: 22px;
  color: var(--slate-500);
  text-align: center;
  font-size: 0.9rem;
}

.page-hero {
  margin-top: 28px;
  padding: 44px;
  border-radius: var(--radius-xl);
  color: var(--white);
  background:
    radial-gradient(circle at top right, rgba(245, 158, 11, 0.28), transparent 30%),
    linear-gradient(135deg, var(--slate-900), var(--slate-800));
  box-shadow: var(--shadow-md);
}

.page-hero.compact-hero {
  padding: 48px;
}

.page-hero p {
  max-width: 780px;
  margin: 16px 0 0;
  color: var(--slate-200);
  font-size: 1rem;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 24px;
  color: var(--slate-300);
  font-size: 0.9rem;
}

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

.filter-bar {
  width: min(1180px, calc(100% - 32px));
  margin: 24px auto 0;
  padding: 18px;
  display: grid;
  grid-template-columns: 1.5fr 0.75fr 0.75fr auto;
  gap: 14px;
  align-items: end;
}

.filter-bar label,
.search-box {
  display: grid;
  gap: 6px;
}

.filter-bar span {
  color: var(--slate-600);
  font-size: 0.84rem;
  font-weight: 800;
}

.filter-bar input,
.filter-bar select,
.filter-bar button,
.search-box input,
.search-box select,
.search-box button {
  width: 100%;
  min-height: 46px;
  border: 1px solid rgba(100, 116, 139, 0.22);
  border-radius: 14px;
  padding: 0 14px;
  background: var(--white);
  color: var(--slate-900);
  outline: none;
}

.filter-bar input:focus,
.filter-bar select:focus,
.search-box input:focus,
.search-box select:focus {
  border-color: var(--amber-500);
  box-shadow: 0 0 0 4px rgba(245, 158, 11, 0.12);
}

.filter-bar button,
.search-box button {
  border: 0;
  color: var(--white);
  font-weight: 900;
  background: var(--amber-500);
  cursor: pointer;
}

.empty-state {
  margin: 30px 0 0;
  padding: 30px;
  border-radius: var(--radius-lg);
  color: var(--slate-600);
  text-align: center;
  background: var(--white);
}

.category-overview-card {
  margin-top: 26px;
  padding: 24px;
}

.category-overview-copy {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: 22px;
  align-items: center;
  margin-bottom: 22px;
}

.category-overview-copy img {
  width: 100%;
  aspect-ratio: 16 / 10;
  border-radius: 20px;
  object-fit: cover;
}

.category-overview-copy h2 {
  margin: 0;
  font-size: 2rem;
  line-height: 1.15;
}

.category-overview-copy p {
  margin: 8px 0 14px;
  color: var(--slate-600);
}

.mini-grid .movie-card:nth-child(n+5) {
  display: none;
}

.detail-shell {
  padding-bottom: 40px;
}

.detail-breadcrumb {
  width: min(1180px, calc(100% - 32px));
  margin: 28px auto 18px;
  color: var(--slate-600);
}

.detail-hero {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: 420px minmax(0, 1fr);
  gap: 34px;
  align-items: end;
  padding: 30px;
  border-radius: var(--radius-xl);
  color: var(--white);
  background:
    radial-gradient(circle at 25% 0%, rgba(245, 158, 11, 0.25), transparent 34%),
    linear-gradient(135deg, var(--slate-950), var(--slate-800));
  box-shadow: var(--shadow-md);
}

.detail-cover {
  overflow: hidden;
  border-radius: 24px;
  box-shadow: var(--shadow-lg);
}

.detail-cover img {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
}

.detail-copy h1 {
  font-size: clamp(2rem, 5vw, 4rem);
}

.detail-one-line {
  margin: 18px 0 18px;
  color: var(--slate-200);
  font-size: 1.08rem;
}

.tag-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin-top: 18px;
}

.tag-cloud span {
  padding: 6px 11px;
  border-radius: 999px;
  color: var(--amber-200);
  background: rgba(251, 191, 36, 0.14);
}

.player-section {
  margin-top: 28px;
}

.player-frame {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-xl);
  background: #000;
  box-shadow: var(--shadow-lg);
}

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

.play-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  gap: 10px;
  border: 0;
  color: var(--white);
  background: radial-gradient(circle, rgba(15, 23, 42, 0.3), rgba(15, 23, 42, 0.72));
  cursor: pointer;
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

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

.play-icon {
  display: grid;
  place-items: center;
  width: 78px;
  height: 78px;
  padding-left: 5px;
  border-radius: 999px;
  color: var(--slate-900);
  background: var(--amber-400);
  box-shadow: 0 0 0 18px rgba(251, 191, 36, 0.16);
  font-size: 2rem;
}

.play-overlay strong {
  display: block;
  margin-top: 18px;
  font-size: 1.05rem;
}

.player-note {
  margin: 12px 0 0;
  color: var(--slate-600);
}

.detail-content-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 330px;
  gap: 24px;
  margin-top: 28px;
}

.detail-article,
.detail-info-card {
  padding: 28px;
}

.detail-article p {
  margin: 12px 0 26px;
  color: var(--slate-700);
  font-size: 1.02rem;
}

.detail-info-card dl {
  margin: 18px 0 0;
  display: grid;
  gap: 13px;
}

.detail-info-card dl div {
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr);
  gap: 12px;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(148, 163, 184, 0.16);
}

.detail-info-card dt {
  color: var(--slate-500);
  font-weight: 800;
}

.detail-info-card dd {
  margin: 0;
  color: var(--slate-900);
}

.detail-info-card a {
  color: var(--amber-700);
  font-weight: 800;
}

.related-section {
  padding-bottom: 0;
}

.search-box {
  margin-top: 24px;
  grid-template-columns: minmax(0, 1fr) 180px 120px;
  gap: 12px;
  max-width: 820px;
}

[hidden] {
  display: none !important;
}

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

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

  .ranking-panel {
    position: static;
  }

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

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

  .nav-menu {
    position: absolute;
    left: 0;
    right: 0;
    top: 64px;
    display: none;
    padding: 10px 16px 16px;
    background: var(--slate-900);
    border-top: 1px solid rgba(226, 232, 240, 0.12);
  }

  .nav-menu.is-open {
    display: grid;
    gap: 6px;
  }

  .nav-link {
    display: block;
  }

  .hero {
    min-height: 78vh;
  }

  .hero-content {
    bottom: 178px;
  }

  .hero-thumbs {
    left: 16px;
    right: 16px;
    width: auto;
    grid-template-columns: repeat(5, minmax(86px, 1fr));
    overflow-x: auto;
    padding-bottom: 4px;
  }

  .hero-thumb span {
    display: none;
  }

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

  .filter-bar,
  .search-box,
  .footer-grid,
  .category-overview-copy {
    grid-template-columns: 1fr;
  }

  .page-hero,
  .page-hero.compact-hero,
  .detail-hero,
  .detail-article,
  .detail-info-card,
  .category-overview-card {
    padding: 22px;
  }

  .card-body {
    padding: 13px;
  }

  .rank-item a {
    grid-template-columns: auto 58px minmax(0, 1fr);
  }

  .rank-score {
    display: none;
  }
}

@media (max-width: 480px) {
  .brand-text {
    font-size: 1rem;
  }

  .hero h1,
  .page-hero h1,
  .detail-copy h1 {
    font-size: 2rem;
  }

  .movie-grid.four-cols,
  .movie-grid.three-cols,
  .category-grid {
    grid-template-columns: 1fr;
  }

  .hero-content {
    bottom: 150px;
  }

  .hero-thumbs {
    grid-template-columns: repeat(5, 74px);
  }
}
