:root {
  --amber-50: #fffbeb;
  --amber-100: #fef3c7;
  --amber-200: #fde68a;
  --amber-500: #f59e0b;
  --amber-600: #d97706;
  --orange-50: #fff7ed;
  --orange-100: #ffedd5;
  --orange-500: #f97316;
  --gray-50: #f9fafb;
  --gray-100: #f3f4f6;
  --gray-200: #e5e7eb;
  --gray-500: #6b7280;
  --gray-600: #4b5563;
  --gray-700: #374151;
  --gray-800: #1f2937;
  --gray-900: #111827;
  --shadow-soft: 0 18px 45px rgba(17, 24, 39, 0.12);
  --shadow-card: 0 14px 34px rgba(17, 24, 39, 0.14);
  --radius-lg: 18px;
  --radius-md: 14px;
  --header-height: 76px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
  color: var(--gray-900);
  background: linear-gradient(180deg, var(--amber-50), var(--orange-50) 46%, var(--amber-50));
}

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

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

button,
input,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.86);
  backdrop-filter: blur(18px);
  border-bottom: 1px solid rgba(245, 158, 11, 0.16);
}

.nav-shell {
  height: var(--header-height);
  display: flex;
  align-items: center;
  gap: 22px;
}

.site-logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex: 0 0 auto;
  font-size: 22px;
  font-weight: 800;
  color: var(--gray-900);
  letter-spacing: -0.02em;
}

.logo-mark {
  width: 36px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  color: #fff;
  background: linear-gradient(135deg, var(--amber-500), var(--orange-500));
  box-shadow: 0 10px 24px rgba(249, 115, 22, 0.32);
  font-size: 15px;
}

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

.desktop-nav a {
  font-size: 15px;
  font-weight: 650;
  color: var(--gray-700);
  transition: color 0.2s ease;
}

.desktop-nav a:hover,
.desktop-nav a.is-active {
  color: var(--amber-600);
}

.top-search {
  width: 260px;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 7px;
  border: 1px solid rgba(245, 158, 11, 0.18);
  border-radius: 999px;
  background: rgba(255, 251, 235, 0.92);
}

.top-search input {
  width: 100%;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--gray-800);
  padding: 0 8px;
  font-size: 14px;
}

.top-search button,
.btn {
  border: 0;
  border-radius: 999px;
  font-weight: 800;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease, color 0.2s ease;
}

.top-search button {
  padding: 7px 14px;
  color: #fff;
  background: var(--amber-500);
}

.menu-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 12px;
  color: var(--gray-800);
  background: var(--amber-100);
}

.mobile-nav {
  display: none;
  padding: 0 24px 24px;
  border-top: 1px solid rgba(245, 158, 11, 0.16);
  background: rgba(255, 255, 255, 0.96);
}

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

.mobile-logo {
  margin-top: 18px;
  font-weight: 800;
  color: var(--amber-600);
}

.mobile-nav a {
  padding: 12px 0;
  color: var(--gray-700);
  font-weight: 700;
  border-bottom: 1px solid var(--gray-100);
}

.hero {
  position: relative;
  min-height: 500px;
  height: calc(70vh - 10px);
  overflow: hidden;
  background: var(--gray-900);
}

.hero-track,
.hero-slide,
.hero-slide > img,
.hero-shade {
  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-slide > img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.02);
}

.hero-shade {
  background: linear-gradient(90deg, rgba(0, 0, 0, 0.84), rgba(0, 0, 0, 0.52) 46%, rgba(0, 0, 0, 0.12)), linear-gradient(0deg, rgba(0, 0, 0, 0.46), transparent 48%);
}

.hero-content {
  position: relative;
  z-index: 2;
  height: 100%;
  display: flex;
  align-items: center;
}

.hero-copy {
  width: min(680px, 100%);
  color: #fff;
}

.hero-label,
.section-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #fff;
  background: rgba(245, 158, 11, 0.92);
  border-radius: 999px;
  padding: 8px 16px;
  font-size: 14px;
  font-weight: 800;
  letter-spacing: 0.02em;
}

.hero h1,
.hero h2 {
  margin: 18px 0 16px;
  font-size: clamp(42px, 6vw, 74px);
  line-height: 1.03;
  font-weight: 900;
  letter-spacing: -0.045em;
}

.hero p {
  max-width: 720px;
  margin: 0 0 24px;
  font-size: clamp(17px, 2vw, 22px);
  line-height: 1.72;
  color: rgba(255, 255, 255, 0.88);
}

.hero-tags,
.detail-meta,
.tag-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.hero-tags span,
.detail-meta span,
.tag-cloud span {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 6px 12px;
  border-radius: 999px;
  color: #fff;
  background: rgba(255, 255, 255, 0.18);
  backdrop-filter: blur(12px);
  font-size: 14px;
  font-weight: 700;
}

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

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 24px;
  border: 1px solid transparent;
}

.btn:hover {
  transform: translateY(-2px);
}

.btn-primary {
  color: #fff;
  background: var(--amber-500);
  box-shadow: 0 14px 30px rgba(245, 158, 11, 0.36);
}

.btn-primary:hover {
  background: var(--amber-600);
}

.btn-glass {
  color: #fff;
  background: rgba(255, 255, 255, 0.18);
  border-color: rgba(255, 255, 255, 0.28);
  backdrop-filter: blur(12px);
}

.btn-light {
  color: var(--amber-700, #b45309);
  background: #fff;
  border-color: var(--amber-200);
}

.hero-dots {
  position: absolute;
  z-index: 4;
  left: 50%;
  bottom: 28px;
  display: flex;
  gap: 10px;
  transform: translateX(-50%);
}

.hero-dot {
  width: 32px;
  height: 8px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.44);
  transition: width 0.2s ease, background 0.2s ease;
}

.hero-dot.is-active {
  width: 52px;
  background: var(--amber-500);
}

.section {
  padding: 72px 0;
}

.white-section {
  background: rgba(255, 255, 255, 0.78);
}

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

.section-heading h2 {
  margin: 10px 0 0;
  font-size: clamp(28px, 3vw, 38px);
  line-height: 1.15;
  font-weight: 900;
  color: var(--gray-900);
}

.section-heading .section-kicker,
.page-hero .section-kicker,
.detail-info .section-kicker {
  color: var(--amber-700, #b45309);
  background: var(--amber-100);
}

.section-link {
  color: var(--amber-600);
  font-weight: 800;
}

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

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

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

.movie-card {
  position: relative;
  overflow: hidden;
  background: #fff;
  box-shadow: 0 1px 0 rgba(17, 24, 39, 0.04);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

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

.grid-card,
.large-card {
  border-radius: var(--radius-md);
}

.poster-frame,
.wide-poster,
.thumb-square {
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, var(--amber-100), var(--orange-100));
}

.poster-frame {
  aspect-ratio: 3 / 4;
}

.wide-poster {
  aspect-ratio: 16 / 9;
}

.thumb-square {
  width: 132px;
  height: 132px;
  flex: 0 0 132px;
}

.poster-frame img,
.wide-poster img,
.thumb-square img,
.detail-poster img,
.player-cover img,
.category-tile img,
.overview-covers img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

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

.movie-card img {
  transition: transform 0.45s ease;
}

.movie-badge,
.rank-num {
  position: absolute;
  z-index: 3;
  border-radius: 10px;
  color: #fff;
  font-size: 12px;
  font-weight: 900;
}

.movie-badge {
  top: 10px;
  right: 10px;
  padding: 5px 9px;
  background: var(--amber-500);
}

.rank-num {
  top: 10px;
  left: 10px;
  width: 34px;
  height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--orange-500), var(--amber-500));
  box-shadow: 0 10px 22px rgba(249, 115, 22, 0.28);
}

.poster-hover,
.wide-overlay {
  position: absolute;
  inset: auto 0 0;
  display: flex;
  gap: 8px;
  align-items: center;
  padding: 18px 14px;
  color: #fff;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.82), transparent);
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.wide-overlay h3 {
  margin: 0;
  font-size: 20px;
}

.movie-card:hover .poster-hover,
.movie-card:hover .wide-overlay {
  opacity: 1;
  transform: translateY(0);
}

.card-body {
  padding: 16px;
}

.card-body h3,
.horizontal-body h3 {
  margin: 0 0 8px;
  font-size: 17px;
  line-height: 1.35;
  font-weight: 850;
  color: var(--gray-900);
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
}

.card-body p,
.horizontal-body p {
  margin: 0;
  color: var(--gray-600);
  font-size: 14px;
  line-height: 1.62;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.card-meta,
.small-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 12px;
  color: var(--gray-500);
  font-size: 13px;
}

.horizontal-card {
  display: flex;
  gap: 16px;
  border-radius: var(--radius-md);
}

.horizontal-body {
  min-width: 0;
  display: flex;
  flex: 1;
  flex-direction: column;
  justify-content: center;
  padding: 14px 16px 14px 0;
}

.category-grid,
.overview-grid {
  display: grid;
  gap: 22px;
}

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

.category-tile,
.category-overview-card {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-lg);
  background: #fff;
  box-shadow: 0 1px 0 rgba(17, 24, 39, 0.05);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.category-tile:hover,
.category-overview-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-card);
}

.category-tile {
  min-height: 190px;
  display: grid;
  align-items: end;
}

.category-tile img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.category-tile::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.78), rgba(0, 0, 0, 0.18));
}

.category-tile > div {
  position: relative;
  z-index: 2;
  padding: 22px;
  color: #fff;
}

.category-tile h3,
.overview-body h2 {
  margin: 0 0 8px;
  font-size: 22px;
  font-weight: 900;
}

.category-tile p,
.overview-body p {
  margin: 0;
  font-size: 14px;
  line-height: 1.6;
}

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

.category-overview-card {
  display: grid;
  grid-template-columns: 220px 1fr;
}

.overview-covers {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 4px;
  height: 220px;
  background: var(--amber-100);
}

.overview-body {
  padding: 28px;
}

.overview-body span {
  display: inline-flex;
  margin-top: 18px;
  color: var(--amber-600);
  font-weight: 900;
}

.page-hero,
.detail-hero {
  position: relative;
  overflow: hidden;
  padding: 64px 0;
  background: radial-gradient(circle at 20% 20%, rgba(245, 158, 11, 0.24), transparent 32%), linear-gradient(135deg, var(--amber-50), var(--orange-50));
}

.compact-hero h1,
.detail-info h1 {
  margin: 16px 0;
  font-size: clamp(36px, 5vw, 58px);
  line-height: 1.08;
  font-weight: 950;
  letter-spacing: -0.04em;
}

.compact-hero p,
.detail-lead {
  max-width: 780px;
  margin: 0;
  color: var(--gray-600);
  font-size: 18px;
  line-height: 1.75;
}

.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-bottom: 18px;
  color: var(--gray-500);
  font-size: 14px;
}

.breadcrumbs a {
  color: var(--amber-600);
  font-weight: 800;
}

.filter-panel {
  display: grid;
  grid-template-columns: 1fr 180px 180px;
  gap: 14px;
  margin-bottom: 28px;
  padding: 14px;
  border: 1px solid rgba(245, 158, 11, 0.2);
  border-radius: var(--radius-lg);
  background: rgba(255, 255, 255, 0.74);
  box-shadow: 0 10px 30px rgba(17, 24, 39, 0.06);
}

.filter-panel input,
.filter-panel select {
  width: 100%;
  height: 48px;
  padding: 0 16px;
  border: 1px solid var(--gray-200);
  border-radius: 14px;
  outline: 0;
  color: var(--gray-800);
  background: #fff;
}

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

.empty-state {
  display: none;
  margin: 38px 0 0;
  padding: 24px;
  border-radius: var(--radius-lg);
  color: var(--gray-600);
  background: #fff;
  text-align: center;
}

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

.detail-layout {
  display: grid;
  grid-template-columns: 300px 1fr;
  gap: 42px;
  align-items: center;
}

.detail-poster {
  aspect-ratio: 3 / 4;
  overflow: hidden;
  border: 10px solid #fff;
  border-radius: 28px;
  background: var(--amber-100);
  box-shadow: var(--shadow-soft);
}

.detail-info {
  min-width: 0;
}

.detail-meta span {
  color: var(--amber-700, #b45309);
  background: #fff;
  border: 1px solid var(--amber-200);
}

.player-section {
  background: var(--gray-900);
}

.player-section .section-heading h2 {
  color: #fff;
}

.player-panel {
  position: relative;
  overflow: hidden;
  border-radius: 26px;
  background: #000;
  aspect-ratio: 16 / 9;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.35);
}

.movie-video,
.player-cover {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.movie-video {
  z-index: 1;
  object-fit: contain;
  background: #000;
}

.player-cover {
  z-index: 2;
  border: 0;
  padding: 0;
  background: #000;
}

.player-cover::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.54), rgba(0, 0, 0, 0.16));
}

.player-cover.is-hidden {
  display: none;
}

.play-ring {
  position: absolute;
  z-index: 3;
  left: 50%;
  top: 50%;
  width: 90px;
  height: 90px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding-left: 6px;
  border-radius: 999px;
  color: #fff;
  background: linear-gradient(135deg, var(--amber-500), var(--orange-500));
  box-shadow: 0 20px 45px rgba(249, 115, 22, 0.38);
  transform: translate(-50%, -50%);
  font-size: 34px;
}

.detail-content {
  display: grid;
  gap: 42px;
}

.content-card {
  padding: 34px;
  border-radius: var(--radius-lg);
  background: #fff;
  box-shadow: 0 1px 0 rgba(17, 24, 39, 0.05);
}

.content-card h2 {
  margin: 0 0 14px;
  font-size: 28px;
  font-weight: 900;
}

.content-card h2:not(:first-child) {
  margin-top: 30px;
}

.content-card p {
  margin: 0;
  color: var(--gray-700);
  font-size: 17px;
  line-height: 1.9;
}

.tag-cloud span {
  color: var(--amber-700, #b45309);
  background: var(--amber-100);
}

.related-heading {
  margin-bottom: -12px;
}

.site-footer {
  color: #fff;
  background: linear-gradient(135deg, #78350f, #92400e 46%, #451a03);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 0.8fr 1fr;
  gap: 38px;
  padding: 48px 0;
}

.footer-logo {
  margin-bottom: 12px;
  font-size: 24px;
  font-weight: 950;
}

.site-footer p {
  max-width: 520px;
  margin: 0;
  color: rgba(255, 255, 255, 0.78);
  line-height: 1.75;
}

.site-footer h2 {
  margin: 0 0 12px;
  font-size: 18px;
}

.site-footer a {
  display: block;
  margin: 9px 0;
  color: rgba(255, 255, 255, 0.78);
}

.site-footer a:hover {
  color: #fff;
}

.footer-bottom {
  padding: 20px 0;
  color: rgba(255, 255, 255, 0.7);
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  text-align: center;
}

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

  .top-search {
    margin-left: auto;
  }

  .menu-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

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

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

@media (max-width: 860px) {
  .top-search {
    display: none;
  }

  .hero {
    height: auto;
    min-height: 620px;
  }

  .hero-content {
    padding: 88px 0 110px;
  }

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

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

  .category-overview-card {
    grid-template-columns: 1fr;
  }

  .overview-covers {
    height: 180px;
  }

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

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

  .detail-poster {
    width: min(320px, 100%);
  }

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

@media (max-width: 560px) {
  .container {
    width: min(100% - 24px, 1180px);
  }

  .site-logo {
    font-size: 19px;
  }

  .hero h1,
  .hero h2 {
    font-size: 40px;
  }

  .hero p {
    font-size: 16px;
  }

  .movie-grid,
  .large-grid,
  .category-grid,
  .overview-grid,
  .horizontal-grid {
    grid-template-columns: 1fr;
  }

  .horizontal-card {
    align-items: stretch;
  }

  .thumb-square {
    width: 112px;
    height: 126px;
    flex-basis: 112px;
  }

  .content-card {
    padding: 24px;
  }

  .play-ring {
    width: 72px;
    height: 72px;
    font-size: 28px;
  }
}
