:root {
  --page-bg: #f3f6fb;
  --surface: #ffffff;
  --ink: #111827;
  --muted: #6b7280;
  --line: #e5e7eb;
  --blue: #2563eb;
  --blue-dark: #1e3a8a;
  --blue-soft: #dbeafe;
  --shadow: 0 18px 45px rgba(15, 23, 42, 0.12);
  --radius: 22px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

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

body.is-locked {
  overflow: hidden;
}

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

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

img.is-missing {
  opacity: 0;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: linear-gradient(90deg, #1e3a8a, #2563eb, #4f46e5);
  color: #ffffff;
  box-shadow: 0 12px 32px rgba(30, 64, 175, 0.25);
}

.header-inner {
  max-width: 1280px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  min-height: 72px;
  padding: 0 24px;
}

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

.brand-mark {
  display: inline-flex;
  width: 34px;
  height: 34px;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  color: #1d4ed8;
  background: #ffffff;
  box-shadow: 0 10px 25px rgba(255, 255, 255, 0.2);
}

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

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

.nav-link,
.mobile-link {
  border-radius: 999px;
  color: rgba(255, 255, 255, 0.86);
  transition: color 0.2s ease, background-color 0.2s ease;
}

.nav-link {
  padding: 9px 16px;
}

.nav-link:hover,
.nav-link.is-active,
.mobile-link:hover,
.mobile-link.is-active {
  background: rgba(255, 255, 255, 0.16);
  color: #ffffff;
}

.mobile-menu-button {
  display: none;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.14);
  padding: 9px;
  cursor: pointer;
}

.mobile-menu-button span {
  display: block;
  height: 2px;
  margin: 5px 0;
  border-radius: 999px;
  background: #ffffff;
}

.mobile-nav {
  display: none;
  padding: 0 18px 16px;
}

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

.mobile-link {
  padding: 12px 14px;
}

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

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

.hero-slide {
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.65s 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 72% 34%, rgba(59, 130, 246, 0.18), transparent 34%),
    linear-gradient(90deg, rgba(15, 23, 42, 0.95), rgba(30, 58, 138, 0.72) 48%, rgba(15, 23, 42, 0.3)),
    linear-gradient(0deg, rgba(15, 23, 42, 0.92), transparent 42%);
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 780px;
  padding: 128px 24px 120px;
  margin-left: calc((100vw - min(1280px, 100vw)) / 2);
  color: #ffffff;
}

.hero-kicker,
.section-kicker {
  margin: 0 0 12px;
  color: #60a5fa;
  font-size: 14px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.hero-content h1 {
  margin: 0;
  font-size: clamp(42px, 7vw, 78px);
  line-height: 1.05;
  letter-spacing: -0.04em;
}

.hero-content p {
  max-width: 680px;
  margin: 22px 0 0;
  color: rgba(255, 255, 255, 0.86);
  font-size: clamp(17px, 2.2vw, 22px);
}

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

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

.primary-button {
  color: #ffffff;
  background: linear-gradient(135deg, #2563eb, #60a5fa);
  box-shadow: 0 16px 28px rgba(37, 99, 235, 0.34);
}

.primary-button.dark {
  background: linear-gradient(135deg, #1e3a8a, #2563eb);
}

.ghost-button {
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.38);
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(14px);
}

.ghost-button.blue {
  color: #1d4ed8;
  border-color: #bfdbfe;
  background: #eff6ff;
}

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

.hero-controls {
  position: absolute;
  right: calc((100vw - min(1280px, 100vw)) / 2 + 24px);
  bottom: 34px;
  z-index: 3;
  display: flex;
  align-items: center;
  gap: 14px;
}

.hero-arrow,
.hero-dot {
  border: 0;
  cursor: pointer;
}

.hero-arrow {
  width: 42px;
  height: 42px;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.16);
  font-size: 28px;
}

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

.hero-dot {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.45);
}

.hero-dot.is-active {
  width: 28px;
  background: #ffffff;
}

.intro-panel,
.section-block,
.ranking-section,
.detail-content,
.player-section,
.category-preview {
  max-width: 1280px;
  margin: 34px auto;
  padding: 0 24px;
}

.intro-panel {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin-top: -58px;
  position: relative;
  z-index: 5;
  padding: 34px;
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.92);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}

.intro-panel h2,
.section-heading h2,
.page-hero h1,
.detail-copy h1,
.story-card h2,
.player-section h2 {
  margin: 0;
  color: var(--ink);
  letter-spacing: -0.03em;
}

.intro-panel h2 {
  font-size: clamp(26px, 4vw, 42px);
}

.intro-panel p:last-child {
  max-width: 720px;
  margin: 10px 0 0;
  color: var(--muted);
}

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

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

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

.section-heading > a {
  color: var(--blue);
  font-weight: 800;
}

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

.category-card {
  min-height: 150px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  border-radius: var(--radius);
  padding: 22px;
  color: #ffffff;
  background:
    radial-gradient(circle at 82% 16%, rgba(255, 255, 255, 0.26), transparent 30%),
    linear-gradient(135deg, #1e40af, #2563eb 45%, #4f46e5);
  box-shadow: 0 18px 40px rgba(37, 99, 235, 0.22);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.category-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 26px 54px rgba(37, 99, 235, 0.28);
}

.category-card span {
  font-size: 22px;
  font-weight: 900;
}

.category-card strong {
  color: rgba(255, 255, 255, 0.84);
  font-size: 14px;
  font-weight: 500;
}

.filter-panel {
  display: grid;
  grid-template-columns: minmax(220px, 1.7fr) repeat(3, minmax(150px, 1fr));
  gap: 14px;
  margin-bottom: 22px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.06);
}

.filter-panel label {
  display: grid;
  gap: 7px;
  color: #374151;
  font-size: 13px;
  font-weight: 800;
}

.filter-panel input,
.filter-panel select {
  min-height: 44px;
  border: 1px solid #d1d5db;
  border-radius: 14px;
  padding: 0 14px;
  color: var(--ink);
  background: #ffffff;
  outline: none;
}

.filter-panel input:focus,
.filter-panel select:focus {
  border-color: var(--blue);
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.1);
}

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

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

.movie-card {
  overflow: hidden;
  border: 1px solid rgba(226, 232, 240, 0.95);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: 0 14px 36px rgba(15, 23, 42, 0.08);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 24px 54px rgba(15, 23, 42, 0.14);
}

.movie-card.is-hidden {
  display: none;
}

.poster-frame {
  position: relative;
  display: block;
  overflow: hidden;
  min-height: 260px;
  border-radius: var(--radius) var(--radius) 0 0;
  background:
    radial-gradient(circle at 70% 20%, rgba(96, 165, 250, 0.35), transparent 34%),
    linear-gradient(135deg, #0f172a, #1e3a8a);
}

.movie-card.is-compact .poster-frame {
  min-height: 220px;
}

.poster-frame img {
  width: 100%;
  height: 100%;
  min-height: inherit;
  object-fit: cover;
  transition: transform 0.35s ease;
}

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

.poster-glow {
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(15, 23, 42, 0.65), transparent 48%);
}

.play-icon,
.rank-badge {
  position: absolute;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.play-icon {
  left: 50%;
  top: 50%;
  width: 52px;
  height: 52px;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(37, 99, 235, 0.86);
  transform: translate(-50%, -50%) scale(0.92);
  opacity: 0;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

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

.rank-badge {
  left: 12px;
  top: 12px;
  width: 38px;
  height: 38px;
  border-radius: 12px;
  color: #ffffff;
  background: linear-gradient(135deg, #f97316, #ef4444);
  font-weight: 900;
  box-shadow: 0 12px 24px rgba(239, 68, 68, 0.28);
}

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

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

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

.movie-card h3 a:hover {
  color: var(--blue);
}

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

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}

.tag-row span {
  border-radius: 999px;
  padding: 5px 10px;
  color: #1d4ed8;
  background: #eff6ff;
  font-size: 12px;
  font-weight: 800;
}

.tag-row.large span {
  padding: 8px 12px;
  font-size: 14px;
}

.empty-state {
  display: none;
  margin: 20px 0;
  padding: 22px;
  border-radius: var(--radius);
  color: var(--muted);
  background: #ffffff;
  text-align: center;
}

.empty-state.is-visible {
  display: block;
}

.ranking-section {
  display: grid;
  grid-template-columns: minmax(260px, 0.9fr) minmax(320px, 1.1fr);
  gap: 28px;
  align-items: stretch;
  padding: 34px;
  border-radius: 28px;
  color: #ffffff;
  background:
    radial-gradient(circle at 92% 18%, rgba(96, 165, 250, 0.3), transparent 32%),
    linear-gradient(135deg, #0f172a, #1e3a8a 58%, #2563eb);
  box-shadow: var(--shadow);
}

.ranking-copy h2 {
  margin: 0;
  font-size: clamp(30px, 4vw, 52px);
  letter-spacing: -0.04em;
}

.ranking-copy p:not(.section-kicker) {
  color: rgba(255, 255, 255, 0.78);
}

.ranking-list {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.ranking-list a {
  display: grid;
  grid-template-columns: 40px 1fr;
  gap: 10px 14px;
  align-items: center;
  padding: 13px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.08);
}

.ranking-list span {
  grid-row: span 2;
  display: inline-flex;
  width: 36px;
  height: 36px;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  color: #1d4ed8;
  background: #ffffff;
  font-weight: 900;
}

.ranking-list em {
  color: rgba(255, 255, 255, 0.68);
  font-style: normal;
  font-size: 13px;
}

.page-hero {
  max-width: 1280px;
  margin: 32px auto;
  padding: 54px 34px;
  border-radius: 30px;
  color: #ffffff;
  background:
    radial-gradient(circle at 84% 16%, rgba(96, 165, 250, 0.3), transparent 30%),
    linear-gradient(135deg, #0f172a, #1e3a8a 56%, #2563eb);
  box-shadow: var(--shadow);
}

.page-hero h1 {
  color: #ffffff;
  font-size: clamp(34px, 5vw, 58px);
}

.page-hero p:not(.section-kicker) {
  max-width: 760px;
  color: rgba(255, 255, 255, 0.78);
  font-size: 18px;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-bottom: 20px;
  color: var(--muted);
  font-size: 14px;
}

.breadcrumb a {
  color: var(--blue);
  font-weight: 800;
}

.breadcrumb.light,
.breadcrumb.light a {
  color: rgba(255, 255, 255, 0.86);
}

.category-preview {
  padding: 28px 24px;
  border-radius: 26px;
  background: rgba(255, 255, 255, 0.68);
  box-shadow: 0 12px 32px rgba(15, 23, 42, 0.05);
}

.ranking-table-wrap {
  overflow-x: auto;
  border-radius: var(--radius);
  background: #ffffff;
  box-shadow: 0 12px 32px rgba(15, 23, 42, 0.08);
}

.ranking-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 760px;
}

.ranking-table th,
.ranking-table td {
  padding: 15px 18px;
  border-bottom: 1px solid var(--line);
  text-align: left;
}

.ranking-table th {
  color: #374151;
  background: #f8fafc;
}

.ranking-table td:first-child {
  color: #1d4ed8;
  font-weight: 900;
}

.ranking-table a {
  color: var(--ink);
  font-weight: 800;
}

.ranking-table a:hover {
  color: var(--blue);
}

.detail-hero {
  position: relative;
  overflow: hidden;
  color: #ffffff;
  background: #0f172a;
}

.detail-backdrop {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: blur(10px) saturate(1.1);
  transform: scale(1.08);
}

.detail-shade {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(15, 23, 42, 0.94), rgba(30, 58, 138, 0.72)),
    linear-gradient(0deg, rgba(15, 23, 42, 0.92), transparent 46%);
}

.detail-inner {
  position: relative;
  z-index: 2;
  max-width: 1280px;
  min-height: 600px;
  display: grid;
  grid-template-columns: 330px 1fr;
  gap: 46px;
  align-items: center;
  margin: 0 auto;
  padding: 70px 24px;
}

.detail-poster {
  min-height: 480px;
  border-radius: 28px;
  box-shadow: 0 28px 70px rgba(0, 0, 0, 0.34);
}

.detail-poster img {
  border-radius: inherit;
}

.detail-copy h1 {
  color: #ffffff;
  font-size: clamp(38px, 5vw, 68px);
  line-height: 1.08;
}

.detail-copy p:not(.section-kicker) {
  max-width: 780px;
  color: rgba(255, 255, 255, 0.82);
  font-size: 19px;
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 20px;
}

.detail-meta span {
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 999px;
  padding: 8px 12px;
  color: rgba(255, 255, 255, 0.9);
  background: rgba(255, 255, 255, 0.1);
}

.player-section {
  scroll-margin-top: 92px;
}

.video-player {
  position: relative;
  overflow: hidden;
  border-radius: 28px;
  background: #020617;
  box-shadow: 0 28px 70px rgba(2, 6, 23, 0.28);
}

.main-video {
  width: 100%;
  aspect-ratio: 16 / 9;
  display: block;
  background: #020617;
}

.player-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  border: 0;
  color: #ffffff;
  background: linear-gradient(0deg, rgba(2, 6, 23, 0.78), rgba(15, 23, 42, 0.38));
  cursor: pointer;
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

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

.player-play-icon {
  display: inline-flex;
  width: 88px;
  height: 88px;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: linear-gradient(135deg, #2563eb, #60a5fa);
  box-shadow: 0 18px 44px rgba(37, 99, 235, 0.4);
  font-size: 34px;
}

.player-overlay strong {
  font-size: 20px;
}

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

.story-card {
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: 0 12px 32px rgba(15, 23, 42, 0.06);
}

.story-card:last-child {
  grid-column: 1 / -1;
}

.story-card p {
  color: #374151;
  font-size: 16px;
}

.site-footer {
  margin-top: 70px;
  color: #cbd5e1;
  background: #0f172a;
}

.footer-inner {
  max-width: 1280px;
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 30px;
  margin: 0 auto;
  padding: 46px 24px;
}

.footer-brand p {
  max-width: 500px;
  color: #94a3b8;
}

.footer-logo .brand-mark {
  color: #ffffff;
  background: #2563eb;
}

.footer-group h2 {
  margin: 0 0 14px;
  color: #ffffff;
  font-size: 18px;
}

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

.footer-group a:hover {
  color: #60a5fa;
}

.footer-bottom {
  border-top: 1px solid rgba(148, 163, 184, 0.16);
  padding: 18px 24px;
  color: #94a3b8;
  text-align: center;
}

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

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

  .mobile-menu-button {
    display: block;
  }

  .hero-carousel {
    min-height: 610px;
  }

  .hero-content {
    padding-top: 108px;
  }

  .intro-panel,
  .ranking-section,
  .detail-inner,
  .detail-content,
  .footer-inner {
    grid-template-columns: 1fr;
  }

  .intro-panel {
    align-items: flex-start;
    flex-direction: column;
  }

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

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

  .detail-inner {
    min-height: auto;
  }

  .detail-poster {
    max-width: 320px;
    min-height: 430px;
  }
}

@media (max-width: 640px) {
  .header-inner {
    min-height: 64px;
    padding: 0 16px;
  }

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

  .hero-carousel {
    min-height: 560px;
  }

  .hero-content {
    padding: 96px 18px 110px;
  }

  .hero-controls {
    left: 18px;
    right: 18px;
    justify-content: space-between;
  }

  .intro-panel,
  .section-block,
  .ranking-section,
  .detail-content,
  .player-section,
  .category-preview,
  .page-hero {
    margin-left: 14px;
    margin-right: 14px;
    padding-left: 16px;
    padding-right: 16px;
  }

  .intro-panel {
    margin-top: -34px;
  }

  .filter-panel,
  .category-grid,
  .movie-grid,
  .compact-grid {
    grid-template-columns: 1fr;
  }

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

  .poster-frame,
  .movie-card.is-compact .poster-frame {
    min-height: 280px;
  }

  .detail-inner {
    padding: 38px 18px;
  }

  .detail-poster {
    min-height: 390px;
  }

  .player-play-icon {
    width: 72px;
    height: 72px;
  }
}
