:root {
  --bg: #080a0f;
  --bg-soft: #111827;
  --surface: #ffffff;
  --surface-soft: #f6f7fb;
  --text: #111827;
  --muted: #6b7280;
  --line: rgba(17, 24, 39, 0.12);
  --amber: #f59e0b;
  --amber-dark: #d97706;
  --orange: #ea580c;
  --white: #ffffff;
  --radius: 24px;
  --shadow: 0 24px 60px rgba(15, 23, 42, 0.16);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: Inter, "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
  color: var(--text);
  background: var(--surface-soft);
  line-height: 1.6;
}

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

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

button,
input,
select {
  font: inherit;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 90;
  background: rgba(8, 10, 15, 0.82);
  backdrop-filter: blur(18px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

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

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--white);
  font-weight: 800;
  letter-spacing: 0.02em;
}

.brand-mark {
  width: 42px;
  height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  color: var(--white);
  background: linear-gradient(135deg, var(--amber), var(--orange));
  box-shadow: 0 0 36px rgba(245, 158, 11, 0.5);
}

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

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

.nav-link,
.mobile-link {
  color: rgba(255, 255, 255, 0.78);
  padding: 10px 16px;
  border-radius: 999px;
  transition: 0.25s ease;
}

.nav-link:hover,
.nav-link.active,
.mobile-link:hover,
.mobile-link.active {
  color: var(--white);
  background: rgba(255, 255, 255, 0.14);
}

.menu-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.1);
  cursor: pointer;
}

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

.mobile-nav {
  display: none;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto 16px;
  padding: 10px;
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.08);
}

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

.hero {
  position: relative;
  min-height: calc(100vh - 76px);
  overflow: hidden;
  background: radial-gradient(circle at 50% 0%, rgba(245, 158, 11, 0.18), transparent 40%), #07080d;
}

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

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

.hero-bg,
.detail-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.52;
}

.image-soft {
  opacity: 0.08 !important;
  filter: blur(1px);
}

.hero-overlay,
.detail-bg-shade {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(8, 10, 15, 0.96) 0%, rgba(8, 10, 15, 0.74) 45%, rgba(8, 10, 15, 0.3) 100%),
    linear-gradient(0deg, rgba(8, 10, 15, 0.95) 0%, transparent 55%);
}

.hero-content {
  position: relative;
  z-index: 2;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 92px 0 160px;
  min-height: calc(100vh - 76px);
  display: flex;
  flex-direction: column;
  justify-content: center;
  color: var(--white);
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--amber);
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.hero h1 {
  max-width: 860px;
  margin: 0 0 16px;
  font-size: clamp(40px, 7vw, 86px);
  line-height: 1.02;
  letter-spacing: -0.05em;
}

.hero h2 {
  max-width: 760px;
  margin: 0 0 18px;
  font-size: clamp(28px, 4vw, 52px);
  line-height: 1.1;
  color: rgba(255, 255, 255, 0.92);
}

.hero-desc {
  max-width: 720px;
  margin: 0 0 22px;
  color: rgba(255, 255, 255, 0.76);
  font-size: 19px;
}

.hero-tags,
.card-tags,
.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.hero-tags span,
.card-tags span,
.detail-meta span {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 5px 11px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.13);
  color: rgba(255, 255, 255, 0.9);
  font-size: 13px;
}

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

.hero-actions.left {
  justify-content: flex-start;
}

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

.primary-btn {
  color: var(--white);
  background: linear-gradient(135deg, var(--amber), var(--orange));
  box-shadow: 0 18px 34px rgba(217, 119, 6, 0.32);
}

.primary-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 24px 42px rgba(217, 119, 6, 0.42);
}

.primary-btn.dark {
  background: linear-gradient(135deg, #111827, #374151);
}

.ghost-btn {
  color: var(--white);
  border: 1px solid rgba(255, 255, 255, 0.32);
  background: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(10px);
}

.ghost-btn:hover {
  background: rgba(255, 255, 255, 0.18);
}

.dark-border {
  color: var(--text);
  border-color: rgba(17, 24, 39, 0.16);
  background: var(--white);
}

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

.hero-arrow {
  width: 54px;
  height: 54px;
  border: 0;
  border-radius: 50%;
  color: var(--white);
  background: rgba(255, 255, 255, 0.16);
  font-size: 34px;
  cursor: pointer;
  transition: 0.25s ease;
}

.hero-arrow:hover {
  background: rgba(245, 158, 11, 0.85);
}

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

.hero-thumb {
  display: grid;
  grid-template-columns: 54px 1fr;
  align-items: center;
  gap: 10px;
  min-height: 70px;
  padding: 8px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 18px;
  color: rgba(255, 255, 255, 0.75);
  background: rgba(255, 255, 255, 0.1);
  text-align: left;
  cursor: pointer;
  transition: 0.25s ease;
  overflow: hidden;
}

.hero-thumb img {
  width: 54px;
  height: 54px;
  border-radius: 14px;
  object-fit: cover;
}

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

.hero-thumb.active,
.hero-thumb:hover {
  color: var(--white);
  border-color: rgba(245, 158, 11, 0.72);
  background: rgba(245, 158, 11, 0.2);
}

.section {
  padding: 82px 0;
}

.section-light {
  background: var(--surface);
}

.section-muted {
  background: var(--surface-soft);
}

.section-dark {
  color: var(--white);
  background: linear-gradient(180deg, #0b0f19, #06070b);
}

.section-head {
  width: min(780px, calc(100% - 32px));
  margin: 0 auto 38px;
  text-align: center;
}

.section-head h2 {
  margin: 0 0 14px;
  font-size: clamp(30px, 4vw, 48px);
  line-height: 1.1;
  letter-spacing: -0.03em;
}

.section-head p:last-child {
  margin: 0;
  color: var(--muted);
  font-size: 18px;
}

.section-head.inverse p:last-child {
  color: rgba(255, 255, 255, 0.62);
}

.filter-panel {
  display: grid;
  grid-template-columns: 2fr repeat(3, 1fr);
  gap: 14px;
  padding: 18px;
  margin-bottom: 32px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.9);
  box-shadow: var(--shadow);
}

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

.filter-panel input,
.filter-panel select {
  width: 100%;
  height: 48px;
  padding: 0 14px;
  border: 1px solid rgba(17, 24, 39, 0.14);
  border-radius: 14px;
  color: var(--text);
  background: var(--white);
  outline: none;
}

.filter-panel input:focus,
.filter-panel select:focus {
  border-color: rgba(245, 158, 11, 0.65);
  box-shadow: 0 0 0 4px rgba(245, 158, 11, 0.14);
}

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

.movie-card {
  overflow: hidden;
  border-radius: 24px;
  background: var(--white);
  box-shadow: 0 18px 38px rgba(15, 23, 42, 0.1);
  transition: 0.25s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 26px 62px rgba(15, 23, 42, 0.16);
}

.poster-link {
  position: relative;
  display: block;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  background: linear-gradient(135deg, #111827, #3f2a0a);
}

.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-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.72), transparent 54%);
  opacity: 0.85;
}

.poster-play {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 58px;
  height: 58px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transform: translate(-50%, -50%) scale(0.8);
  border-radius: 50%;
  color: var(--white);
  background: rgba(245, 158, 11, 0.9);
  opacity: 0;
  transition: 0.25s ease;
}

.movie-card:hover .poster-play {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
}

.rank-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  min-width: 42px;
  height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  color: var(--white);
  background: linear-gradient(135deg, var(--amber), var(--orange));
  font-style: normal;
  font-weight: 900;
}

.card-body {
  padding: 18px;
}

.card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-bottom: 10px;
  color: var(--muted);
  font-size: 12px;
}

.card-meta span {
  padding: 4px 8px;
  border-radius: 999px;
  background: #f3f4f6;
}

.card-body h3 {
  margin: 0 0 10px;
  font-size: 18px;
  line-height: 1.32;
}

.card-body h3 a:hover {
  color: var(--amber-dark);
}

.card-body p {
  display: -webkit-box;
  min-height: 45px;
  margin: 0 0 14px;
  overflow: hidden;
  color: var(--muted);
  font-size: 14px;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.card-tags span {
  color: #78350f;
  background: #fef3c7;
}

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

.category-card {
  min-height: 220px;
  padding: 24px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  border-radius: 24px;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0.04));
  border: 1px solid rgba(255, 255, 255, 0.12);
  transition: 0.25s ease;
}

.category-card:hover {
  transform: translateY(-5px);
  border-color: rgba(245, 158, 11, 0.65);
}

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

.category-card p {
  color: rgba(255, 255, 255, 0.62);
}

.category-card div {
  display: grid;
  gap: 4px;
  color: rgba(255, 255, 255, 0.72);
  font-size: 13px;
}

.ranking-layout {
  display: grid;
  grid-template-columns: 0.9fr 1.6fr;
  gap: 28px;
  align-items: start;
}

.ranking-list {
  display: grid;
  gap: 10px;
  padding: 14px;
  border-radius: 24px;
  background: var(--surface-soft);
}

.compact-link {
  display: grid;
  grid-template-columns: 40px 1fr;
  gap: 10px 12px;
  align-items: center;
  min-height: 62px;
  padding: 10px;
  border-radius: 16px;
  background: var(--white);
  transition: 0.25s ease;
}

.compact-link:hover {
  transform: translateX(4px);
  box-shadow: 0 12px 24px rgba(15, 23, 42, 0.08);
}

.compact-link span {
  width: 36px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  color: var(--white);
  background: linear-gradient(135deg, var(--amber), var(--orange));
  font-weight: 900;
  grid-row: span 2;
}

.compact-link strong {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.compact-link small {
  overflow: hidden;
  color: var(--muted);
  white-space: nowrap;
  text-overflow: ellipsis;
}

.center-action {
  display: flex;
  justify-content: center;
  margin-top: 36px;
}

.page-main {
  background: var(--surface-soft);
}

.page-hero {
  position: relative;
  padding: 120px 0 86px;
  color: var(--white);
  background:
    radial-gradient(circle at 18% 20%, rgba(245, 158, 11, 0.36), transparent 34%),
    linear-gradient(135deg, #0b0f19, #2a1502);
  overflow: hidden;
}

.page-hero.slim {
  padding: 96px 0 76px;
}

.page-hero h1 {
  max-width: 780px;
  margin: 0 0 16px;
  font-size: clamp(38px, 6vw, 70px);
  line-height: 1.05;
  letter-spacing: -0.04em;
}

.page-hero p:last-child {
  max-width: 720px;
  margin: 0;
  color: rgba(255, 255, 255, 0.72);
  font-size: 19px;
}

.categories-overview {
  display: grid;
  gap: 28px;
}

.category-overview-card {
  display: grid;
  grid-template-columns: 360px 1fr;
  gap: 28px;
  padding: 26px;
  border-radius: 30px;
  background: var(--white);
  box-shadow: var(--shadow);
}

.category-cover-stack {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
}

.category-cover-stack img {
  width: 100%;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  border-radius: 18px;
  background: #111827;
}

.category-overview-body h2 {
  margin: 0 0 10px;
  font-size: 34px;
}

.category-overview-body p {
  color: var(--muted);
}

.mini-list {
  display: grid;
  gap: 10px;
  margin: 18px 0;
}

.text-link {
  display: inline-flex;
  width: fit-content;
  margin-right: 12px;
  color: var(--amber-dark);
  font-weight: 800;
}

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

.ranking-page-layout {
  display: grid;
  grid-template-columns: 0.75fr 1.25fr;
  gap: 28px;
}

.ranking-list.large {
  max-height: 980px;
  overflow: auto;
}

.detail-main {
  background: var(--surface);
}

.detail-hero {
  position: relative;
  min-height: 650px;
  display: flex;
  align-items: center;
  overflow: hidden;
  background: #080a0f;
}

.detail-wrap {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: 330px 1fr;
  gap: 48px;
  align-items: center;
  padding: 88px 0;
  color: var(--white);
}

.detail-poster img {
  width: 100%;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  border-radius: 28px;
  box-shadow: 0 34px 70px rgba(0, 0, 0, 0.44);
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 16px;
  color: rgba(255, 255, 255, 0.66);
}

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

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

.detail-one-line {
  max-width: 760px;
  margin: 22px 0;
  color: rgba(255, 255, 255, 0.76);
  font-size: 20px;
}

.detail-tags {
  margin-bottom: 8px;
}

.detail-section {
  padding-top: 54px;
}

.detail-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 30px;
  align-items: start;
}

.player-shell {
  position: relative;
  overflow: hidden;
  border-radius: 28px;
  background: #000;
  box-shadow: var(--shadow);
}

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

.play-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 0;
  color: var(--white);
  background: radial-gradient(circle at center, rgba(0, 0, 0, 0.08), rgba(0, 0, 0, 0.48));
  cursor: pointer;
  transition: 0.25s ease;
}

.play-overlay span {
  width: 88px;
  height: 88px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--amber), var(--orange));
  box-shadow: 0 24px 48px rgba(217, 119, 6, 0.45);
  font-size: 34px;
}

.play-overlay:hover span {
  transform: scale(1.06);
}

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

.article-content {
  margin-top: 28px;
  padding: 30px;
  border-radius: 28px;
  background: var(--surface-soft);
}

.article-content h2 {
  margin: 0 0 14px;
  font-size: 28px;
}

.article-content p {
  margin: 0 0 24px;
  color: #374151;
  font-size: 17px;
}

.article-content p:last-child {
  margin-bottom: 0;
}

.side-column {
  display: grid;
  gap: 22px;
  position: sticky;
  top: 98px;
}

.side-card {
  padding: 22px;
  border-radius: 24px;
  background: var(--surface-soft);
}

.side-card h2 {
  margin: 0 0 14px;
  font-size: 24px;
}

.site-footer {
  color: rgba(255, 255, 255, 0.72);
  background: #06070b;
}

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

.footer-brand p {
  max-width: 420px;
  margin: 18px 0 0;
}

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

.footer-links a {
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
}

.footer-links a:hover {
  color: var(--white);
  background: rgba(245, 158, 11, 0.28);
}

[hidden] {
  display: none !important;
}

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

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

  .ranking-layout,
  .ranking-page-layout,
  .detail-grid {
    grid-template-columns: 1fr;
  }

  .side-column {
    position: static;
  }
}

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

  .menu-toggle {
    display: block;
  }

  .hero-content {
    padding: 72px 0 210px;
  }

  .hero-controls {
    grid-template-columns: 44px 1fr 44px;
  }

  .hero-thumbs {
    grid-template-columns: 1fr;
    max-height: 240px;
    overflow: auto;
  }

  .hero-thumb {
    min-height: 58px;
  }

  .filter-panel {
    grid-template-columns: 1fr;
  }

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

  .category-overview-card,
  .detail-wrap,
  .footer-inner {
    grid-template-columns: 1fr;
  }

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

@media (max-width: 560px) {
  .header-inner {
    height: 68px;
  }

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

  .hero {
    min-height: 780px;
  }

  .hero-content {
    min-height: 780px;
  }

  .hero h1 {
    font-size: 42px;
  }

  .hero h2 {
    font-size: 30px;
  }

  .hero-desc,
  .detail-one-line {
    font-size: 16px;
  }

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

  .primary-btn,
  .ghost-btn {
    width: 100%;
  }

  .section {
    padding: 58px 0;
  }

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

  .card-body p {
    min-height: auto;
  }

  .page-hero {
    padding: 76px 0 56px;
  }

  .detail-wrap {
    padding: 58px 0;
  }

  .article-content,
  .side-card {
    padding: 22px;
  }
}
