:root {
  --page-bg: #f8fafc;
  --card-bg: #ffffff;
  --ink: #111827;
  --muted: #64748b;
  --line: #e2e8f0;
  --brand: #0284c7;
  --brand-dark: #0369a1;
  --brand-soft: #e0f2fe;
  --gold: #f59e0b;
  --shadow: 0 18px 45px rgba(15, 23, 42, 0.12);
  --radius: 22px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

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

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

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.92);
  border-bottom: 1px solid rgba(226, 232, 240, 0.9);
  backdrop-filter: blur(18px);
}

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

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

.brand-mark {
  width: 40px;
  height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  border-radius: 14px;
  background: linear-gradient(135deg, #0ea5e9, #2563eb);
  box-shadow: 0 10px 25px rgba(2, 132, 199, 0.28);
}

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

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-left: auto;
}

.nav-link,
.mobile-link {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 0 14px;
  color: #475569;
  font-weight: 650;
  border-radius: 999px;
  transition: 0.18s ease;
}

.nav-link:hover,
.nav-link.is-active,
.mobile-link:hover,
.mobile-link.is-active {
  color: var(--brand-dark);
  background: var(--brand-soft);
}

.header-search,
.mobile-search {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px;
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
  border-radius: 999px;
}

.header-search input,
.mobile-search input,
.big-search input,
.category-toolbar input,
.category-toolbar select {
  width: 100%;
  border: 0;
  outline: none;
  color: #0f172a;
  background: transparent;
  font: inherit;
}

.header-search input {
  width: 190px;
  padding-left: 12px;
}

.header-search button,
.mobile-search button,
.big-search button {
  border: 0;
  color: #ffffff;
  cursor: pointer;
  font-weight: 750;
  background: var(--brand);
  border-radius: 999px;
  transition: 0.18s ease;
}

.header-search button,
.mobile-search button {
  padding: 8px 14px;
}

.header-search button:hover,
.mobile-search button:hover,
.big-search button:hover,
.primary-btn:hover {
  background: var(--brand-dark);
  transform: translateY(-1px);
}

.menu-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 14px;
  background: #e0f2fe;
  cursor: pointer;
}

.menu-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  margin: 4px auto;
  background: var(--brand-dark);
  border-radius: 999px;
}

.mobile-panel {
  display: none;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto 16px;
  padding: 16px;
  background: #ffffff;
  border: 1px solid var(--line);
  border-radius: 22px;
  box-shadow: var(--shadow);
}

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

.mobile-nav {
  display: grid;
  gap: 8px;
  margin-top: 12px;
}

.hero-section {
  padding: 28px 16px 0;
}

.hero-shell {
  position: relative;
  width: min(1180px, 100%);
  min-height: 560px;
  margin: 0 auto;
  overflow: hidden;
  border-radius: 34px;
  background: #0f172a;
  box-shadow: 0 28px 70px rgba(15, 23, 42, 0.22);
}

.hero-slide {
  min-height: 560px;
  display: none;
  grid-template-columns: minmax(0, 1.05fr) 360px;
  align-items: center;
  gap: 42px;
  padding: 72px;
  color: #ffffff;
  background-image: linear-gradient(90deg, rgba(8, 13, 26, 0.96), rgba(8, 13, 26, 0.74), rgba(8, 13, 26, 0.35)), var(--hero-image);
  background-size: cover;
  background-position: center;
}

.hero-slide.is-active {
  display: grid;
  animation: fadeSlide 0.55s ease both;
}

@keyframes fadeSlide {
  from {
    opacity: 0;
    transform: scale(1.015);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

.eyebrow,
.section-kicker {
  display: inline-flex;
  width: fit-content;
  align-items: center;
  gap: 8px;
  padding: 6px 12px;
  color: #0369a1;
  background: #e0f2fe;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.04em;
}

.hero-content .eyebrow {
  color: #bae6fd;
  background: rgba(14, 165, 233, 0.24);
  border: 1px solid rgba(186, 230, 253, 0.3);
}

.hero-content h1 {
  max-width: 780px;
  margin: 20px 0 14px;
  font-size: clamp(42px, 7vw, 82px);
  line-height: 0.96;
  letter-spacing: -0.07em;
}

.hero-content p {
  max-width: 690px;
  margin: 0;
  color: rgba(255, 255, 255, 0.82);
  font-size: 18px;
}

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

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

.hero-tags span,
.detail-tags a,
.tag-row span,
.quick-tags a {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 4px 10px;
  color: #0369a1;
  background: #e0f2fe;
  border-radius: 999px;
  font-size: 13px;
  font-style: normal;
  font-weight: 700;
}

.hero-tags span {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.22);
}

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

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

.primary-btn {
  color: #ffffff;
  background: var(--brand);
  box-shadow: 0 12px 28px rgba(2, 132, 199, 0.35);
}

.ghost-btn {
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.35);
  background: rgba(255, 255, 255, 0.12);
}

.ghost-btn:hover {
  background: rgba(255, 255, 255, 0.22);
  transform: translateY(-1px);
}

.hero-poster {
  display: block;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  border-radius: 28px;
  background: linear-gradient(135deg, #075985, #0f172a);
  box-shadow: 0 24px 55px rgba(0, 0, 0, 0.35);
  transform: rotate(2deg);
}

.hero-poster img,
.poster-wrap img,
.side-poster img,
.ranking-card img,
.rank-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-controls {
  position: absolute;
  left: 72px;
  bottom: 38px;
  display: flex;
  gap: 10px;
}

.hero-dot {
  width: 38px;
  height: 5px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.3);
  cursor: pointer;
}

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

.quick-panel,
.content-section,
.split-section,
.page-main,
.overview-grid,
.ranking-grid {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
}

.quick-panel {
  padding: 24px 0 0;
}

.quick-inner {
  display: grid;
  gap: 16px;
  padding: 18px;
  background: #ffffff;
  border: 1px solid var(--line);
  border-radius: 28px;
  box-shadow: 0 16px 34px rgba(15, 23, 42, 0.08);
}

.big-search {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  padding: 8px;
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
  border-radius: 999px;
}

.big-search input {
  padding: 0 18px;
}

.big-search button {
  min-height: 48px;
  padding: 0 26px;
}

.content-section,
.split-section,
.overview-grid,
.ranking-grid {
  padding-top: 58px;
}

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

.section-head h2,
.page-hero h1,
.detail-card h1 {
  margin: 10px 0 0;
  color: #0f172a;
  line-height: 1.08;
  letter-spacing: -0.04em;
}

.section-head h2 {
  font-size: clamp(28px, 4vw, 44px);
}

.section-head > a,
.text-link {
  color: var(--brand-dark);
  font-weight: 800;
}

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

.movie-card {
  display: grid;
  min-width: 0;
  color: inherit;
  background: var(--card-bg);
  border: 1px solid rgba(226, 232, 240, 0.92);
  border-radius: 24px;
  overflow: hidden;
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.08);
  transition: 0.2s ease;
}

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

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

.poster-wrap img {
  transition: transform 0.22s ease;
}

.movie-card:hover .poster-wrap img {
  transform: scale(1.045);
}

.rating-badge,
.play-chip,
.score-pill {
  position: absolute;
  top: 12px;
  z-index: 2;
  min-height: 28px;
  padding: 4px 9px;
  color: #0f172a;
  background: rgba(255, 255, 255, 0.9);
  border-radius: 999px;
  font-size: 12px;
  font-weight: 900;
  backdrop-filter: blur(12px);
}

.rating-badge {
  left: 12px;
}

.play-chip {
  right: 12px;
  color: #ffffff;
  background: rgba(2, 132, 199, 0.9);
}

.movie-info {
  display: grid;
  gap: 8px;
  padding: 16px;
}

.movie-info strong {
  color: #0f172a;
  font-size: 18px;
  line-height: 1.25;
}

.movie-info em,
.rank-copy em,
.ranking-card em,
.meta-row,
.movie-info p,
.category-tile em,
.overview-body p,
.footer-inner p {
  color: var(--muted);
  font-style: normal;
}

.movie-info p {
  margin: 0;
  font-size: 14px;
}

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

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

.category-tile,
.category-overview-card,
.ranking-card,
.detail-card,
.side-card,
.category-toolbar,
.page-hero {
  background: #ffffff;
  border: 1px solid var(--line);
  border-radius: 28px;
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.08);
}

.category-tile {
  display: grid;
  gap: 12px;
  padding: 16px;
  transition: 0.18s ease;
}

.category-tile:hover,
.category-overview-card:hover,
.ranking-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 20px 38px rgba(15, 23, 42, 0.12);
}

.tile-images,
.overview-cover {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
}

.tile-images img,
.overview-cover img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 14px;
  background: #e2e8f0;
}

.ranking-panel {
  padding: 22px;
  background: #0f172a;
  border-radius: 30px;
  color: #ffffff;
  box-shadow: var(--shadow);
}

.ranking-panel .section-head h2,
.ranking-panel .section-head a {
  color: #ffffff;
}

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

.rank-item {
  display: grid;
  grid-template-columns: 36px 58px 1fr;
  gap: 12px;
  align-items: center;
  min-width: 0;
  padding: 10px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 18px;
  transition: 0.18s ease;
}

.rank-item:hover {
  background: rgba(255, 255, 255, 0.14);
}

.rank-num {
  color: #7dd3fc;
  font-weight: 900;
}

.rank-item img {
  width: 58px;
  height: 74px;
  border-radius: 12px;
  background: #1e293b;
}

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

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

.rank-copy strong {
  font-weight: 800;
}

.rank-copy em {
  color: #cbd5e1;
  font-size: 13px;
}

.page-main {
  padding: 34px 0 70px;
}

.page-hero {
  position: relative;
  overflow: hidden;
  padding: 52px;
}

.page-hero h1 {
  font-size: clamp(34px, 6vw, 64px);
}

.page-hero p {
  max-width: 780px;
  margin: 16px 0 0;
  color: var(--muted);
  font-size: 18px;
}

.category-hero {
  color: #ffffff;
  background-image: linear-gradient(90deg, rgba(8, 13, 26, 0.9), rgba(8, 13, 26, 0.58)), var(--hero-image);
  background-size: cover;
  background-position: center;
}

.category-hero h1,
.category-hero p {
  color: #ffffff;
}

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

.category-overview-card {
  display: grid;
  grid-template-columns: 210px 1fr;
  gap: 22px;
  padding: 18px;
  transition: 0.18s ease;
}

.overview-cover {
  grid-template-columns: repeat(2, 1fr);
}

.overview-cover img {
  aspect-ratio: 2 / 3;
}

.overview-body h2 {
  margin: 0 0 8px;
}

.overview-body ul {
  margin: 14px 0 0;
  padding-left: 18px;
  color: var(--muted);
}

.category-toolbar {
  display: grid;
  grid-template-columns: 1fr 220px;
  gap: 14px;
  margin: 24px 0 0;
  padding: 16px;
}

.category-toolbar label {
  display: grid;
  gap: 6px;
  color: #475569;
  font-weight: 800;
}

.category-toolbar input,
.category-toolbar select {
  height: 48px;
  padding: 0 14px;
  background: #f8fafc;
  border: 1px solid var(--line);
  border-radius: 16px;
}

.category-layout {
  width: 100%;
}

.sticky-side {
  position: sticky;
  top: 98px;
}

.ranking-grid {
  display: grid;
  gap: 14px;
}

.ranking-card {
  position: relative;
  display: grid;
  grid-template-columns: 64px 96px 1fr auto;
  gap: 18px;
  align-items: center;
  padding: 16px;
  transition: 0.18s ease;
}

.ranking-number {
  color: var(--brand-dark);
  font-size: 22px;
  font-weight: 900;
}

.ranking-card img {
  width: 96px;
  height: 132px;
  border-radius: 18px;
  background: #e2e8f0;
}

.ranking-card strong {
  display: block;
  font-size: 20px;
}

.ranking-card p {
  margin: 8px 0 10px;
  color: var(--muted);
}

.score-pill {
  position: static;
  color: #ffffff;
  background: var(--brand);
}

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

.breadcrumb a {
  color: var(--brand-dark);
}

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

.detail-primary {
  display: grid;
  gap: 22px;
}

.player-shell {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16 / 9;
  background: #000000;
  border-radius: 30px;
  box-shadow: var(--shadow);
}

.player-shell video {
  position: relative;
  z-index: 1;
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #000000;
}

.player-overlay {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
  background: radial-gradient(circle, rgba(14, 165, 233, 0.18), rgba(0, 0, 0, 0.32));
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

.player-button {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-height: 58px;
  padding: 0 26px;
  border: 0;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(2, 132, 199, 0.94);
  box-shadow: 0 18px 40px rgba(2, 132, 199, 0.38);
  cursor: pointer;
  font: inherit;
  font-weight: 900;
  pointer-events: auto;
}

.player-button span {
  width: 0;
  height: 0;
  border-top: 9px solid transparent;
  border-bottom: 9px solid transparent;
  border-left: 14px solid #ffffff;
}

.player-shell.is-playing .player-overlay {
  opacity: 0;
  visibility: hidden;
}

.detail-card,
.side-card {
  padding: 26px;
}

.detail-card h1 {
  font-size: clamp(30px, 5vw, 48px);
}

.detail-card h2,
.side-card h2 {
  margin: 28px 0 10px;
  color: #0f172a;
}

.detail-card p {
  color: #334155;
  font-size: 17px;
}

.meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 18px 0;
}

.meta-row span {
  padding: 4px 10px;
  background: #f1f5f9;
  border-radius: 999px;
}

.detail-tags {
  margin: 18px 0 22px;
}

.detail-side {
  display: grid;
  gap: 18px;
}

.side-poster {
  overflow: hidden;
  border-radius: 28px;
  aspect-ratio: 2 / 3;
  background: #e2e8f0;
  box-shadow: var(--shadow);
}

.side-card dl {
  display: grid;
  grid-template-columns: 70px 1fr;
  gap: 10px 12px;
  margin: 0;
}

.side-card dt {
  color: var(--muted);
  font-weight: 800;
}

.side-card dd {
  margin: 0;
}

.side-related .rank-item {
  grid-template-columns: 30px 52px 1fr;
  color: #ffffff;
  background: #0f172a;
}

.side-related .rank-item img {
  width: 52px;
  height: 68px;
}

.related-section {
  width: 100%;
}

.search-results {
  margin-top: 28px;
}

.empty-state {
  padding: 46px;
  text-align: center;
  color: var(--muted);
  background: #ffffff;
  border: 1px solid var(--line);
  border-radius: 28px;
}

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

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

.footer-brand {
  color: #ffffff;
  font-size: 22px;
}

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

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

.footer-bottom {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 18px 0 26px;
  color: #94a3b8;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

[hidden] {
  display: none !important;
}

@media (max-width: 1100px) {
  .desktop-nav,
  .header-search {
    display: none;
  }

  .menu-toggle {
    display: block;
    margin-left: auto;
  }

  .hero-slide,
  .split-section,
  .detail-layout {
    grid-template-columns: 1fr;
  }

  .hero-slide {
    padding: 42px;
  }

  .hero-poster {
    max-width: 280px;
    transform: none;
  }

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

  .sticky-side {
    position: static;
  }
}

@media (max-width: 760px) {
  .header-inner {
    width: min(100% - 22px, 1180px);
  }

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

  .hero-section {
    padding: 16px 10px 0;
  }

  .hero-shell,
  .hero-slide {
    min-height: auto;
    border-radius: 24px;
  }

  .hero-slide {
    padding: 34px 22px 84px;
  }

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

  .hero-controls {
    left: 22px;
    bottom: 26px;
  }

  .quick-panel,
  .content-section,
  .split-section,
  .page-main,
  .overview-grid,
  .ranking-grid {
    width: min(100% - 22px, 1180px);
  }

  .big-search,
  .category-toolbar,
  .footer-inner,
  .category-overview-card,
  .ranking-card {
    grid-template-columns: 1fr;
  }

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

  .page-hero {
    padding: 32px 22px;
    border-radius: 24px;
  }

  .ranking-card img {
    width: 100%;
    height: auto;
    aspect-ratio: 2 / 3;
  }

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

@media (max-width: 520px) {
  .movie-grid {
    grid-template-columns: 1fr;
  }

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

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