* {
  box-sizing: border-box;
}

:root {
  --amber-50: #fff7ed;
  --amber-100: #ffedd5;
  --amber-200: #fed7aa;
  --amber-500: #f59e0b;
  --orange-500: #f97316;
  --orange-600: #ea580c;
  --orange-700: #c2410c;
  --orange-900: #7c2d12;
  --stone-50: #fafaf9;
  --stone-100: #f5f5f4;
  --stone-300: #d6d3d1;
  --stone-600: #57534e;
  --stone-800: #292524;
  --stone-900: #1c1917;
  --white: #ffffff;
  --shadow: 0 24px 70px rgba(124, 45, 18, 0.16);
  --soft-shadow: 0 14px 38px rgba(124, 45, 18, 0.12);
  --radius-xl: 28px;
  --radius-lg: 22px;
  --radius-md: 16px;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: "Inter", "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
  color: var(--stone-900);
  background:
    radial-gradient(circle at top left, rgba(251, 191, 36, 0.28), transparent 36rem),
    linear-gradient(180deg, #fff7ed 0%, #fffbeb 36%, #ffffff 100%);
  min-height: 100vh;
}

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

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: linear-gradient(90deg, var(--orange-600), var(--orange-500), var(--amber-500));
  box-shadow: 0 12px 32px rgba(194, 65, 12, 0.28);
}

.topbar {
  max-width: 1240px;
  height: 72px;
  margin: 0 auto;
  padding: 0 22px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: #fff;
}

.brand-icon {
  width: 48px;
  height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: #fff;
  box-shadow: 0 10px 22px rgba(124, 45, 18, 0.2);
  font-size: 24px;
  transition: transform 0.25s ease;
}

.brand:hover .brand-icon {
  transform: scale(1.08) rotate(-4deg);
}

.brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
}

.brand-text strong {
  font-size: 21px;
  letter-spacing: 0.04em;
}

.brand-text small {
  margin-top: 4px;
  color: #ffedd5;
  font-size: 12px;
}

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

.nav-link,
.mobile-link {
  border-radius: 14px;
  font-weight: 700;
  transition: all 0.22s ease;
}

.nav-link {
  color: #fff7ed;
  padding: 10px 16px;
}

.nav-link:hover,
.nav-link.is-active {
  background: #fff;
  color: var(--orange-600);
  box-shadow: 0 12px 24px rgba(124, 45, 18, 0.18);
}

.menu-toggle {
  width: 44px;
  height: 44px;
  display: none;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 5px;
  border: 0;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.18);
  cursor: pointer;
}

.menu-toggle span {
  width: 22px;
  height: 2px;
  border-radius: 99px;
  background: #fff;
}

.mobile-nav {
  display: none;
  border-top: 1px solid rgba(255, 255, 255, 0.24);
  padding: 8px 18px 16px;
  background: rgba(194, 65, 12, 0.96);
}

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

.mobile-link {
  color: #fff;
  padding: 11px 14px;
}

.mobile-link:hover,
.mobile-link.is-active {
  background: #fff;
  color: var(--orange-600);
}

main {
  overflow: hidden;
}

.hero {
  position: relative;
  max-width: 1240px;
  margin: 28px auto 0;
  padding: 0 22px 22px;
}

.hero-shell {
  position: relative;
  min-height: 560px;
  border-radius: 34px;
  overflow: hidden;
  background: linear-gradient(135deg, #7c2d12, #f97316 48%, #fbbf24);
  box-shadow: var(--shadow);
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(300px, 0.75fr);
  gap: 30px;
  align-items: center;
  padding: 54px;
  opacity: 0;
  pointer-events: none;
  transform: translateX(22px);
  transition: opacity 0.65s ease, transform 0.65s ease;
}

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

.hero-slide::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(28, 25, 23, 0.86), rgba(28, 25, 23, 0.54), rgba(28, 25, 23, 0.16)),
    radial-gradient(circle at 30% 20%, rgba(255, 255, 255, 0.22), transparent 24rem);
  z-index: 1;
}

.hero-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.64;
  transform: scale(1.04);
}

.hero-content,
.hero-poster-panel {
  position: relative;
  z-index: 2;
}

.hero-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 18px;
  padding: 8px 14px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
  color: #ffedd5;
  backdrop-filter: blur(12px);
  font-weight: 800;
}

.hero h1 {
  margin: 0 0 18px;
  color: #fff;
  font-size: clamp(38px, 7vw, 72px);
  line-height: 0.98;
  letter-spacing: -0.06em;
}

.hero-description {
  max-width: 720px;
  margin: 0 0 24px;
  color: #ffedd5;
  font-size: 18px;
  line-height: 1.8;
}

.hero-meta,
.movie-meta,
.detail-meta,
.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

.hero-meta span,
.movie-meta span,
.detail-meta span,
.breadcrumbs a,
.breadcrumbs span {
  border-radius: 999px;
  padding: 6px 10px;
  background: rgba(255, 255, 255, 0.2);
  color: #fff7ed;
  font-size: 13px;
  font-weight: 700;
}

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

.btn-primary,
.btn-ghost,
.btn-light {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 12px 20px;
  border-radius: 999px;
  font-weight: 900;
  transition: all 0.22s ease;
}

.btn-primary {
  color: #fff;
  background: linear-gradient(90deg, var(--orange-600), var(--amber-500));
  box-shadow: 0 16px 30px rgba(234, 88, 12, 0.28);
}

.btn-primary:hover,
.btn-light:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 36px rgba(234, 88, 12, 0.32);
}

.btn-ghost {
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.42);
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(10px);
}

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

.btn-light {
  color: var(--orange-700);
  background: #fff;
}

.hero-poster-panel {
  justify-self: center;
  width: min(100%, 360px);
  padding: 14px;
  border-radius: 30px;
  background: rgba(255, 255, 255, 0.18);
  box-shadow: 0 28px 70px rgba(28, 25, 23, 0.32);
  backdrop-filter: blur(18px);
  transform: rotate(2deg);
}

.hero-poster-panel img {
  width: 100%;
  height: 460px;
  object-fit: cover;
  border-radius: 24px;
}

.hero-dots {
  position: absolute;
  z-index: 3;
  left: 54px;
  bottom: 34px;
  display: flex;
  gap: 10px;
}

.hero-dot {
  width: 12px;
  height: 12px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.46);
  cursor: pointer;
  transition: all 0.22s ease;
}

.hero-dot.is-active {
  width: 34px;
  background: #fff;
}

.section,
.page-section {
  max-width: 1240px;
  margin: 0 auto;
  padding: 42px 22px;
}

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

.section-title {
  margin: 0;
  color: var(--stone-900);
  font-size: clamp(28px, 4vw, 42px);
  letter-spacing: -0.04em;
}

.section-subtitle {
  margin: 8px 0 0;
  color: var(--stone-600);
  font-size: 16px;
  line-height: 1.7;
}

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

.movie-card {
  position: relative;
  border-radius: 26px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: var(--soft-shadow);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.movie-card:hover {
  transform: translateY(-7px);
  box-shadow: 0 28px 58px rgba(124, 45, 18, 0.18);
}

.poster-link {
  position: relative;
  display: block;
  height: 300px;
  overflow: hidden;
  background: linear-gradient(135deg, #fb923c, #fbbf24);
}

.compact-card .poster-link {
  height: 250px;
}

.poster-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.42s ease, opacity 0.2s ease;
}

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

.poster-link::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 42%, rgba(28, 25, 23, 0.72));
}

.poster-type,
.rank-badge {
  position: absolute;
  z-index: 2;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 900;
}

.poster-type {
  right: 12px;
  top: 12px;
  padding: 7px 10px;
  color: var(--orange-700);
  background: #fff;
}

.rank-badge {
  left: 12px;
  top: 12px;
  width: 38px;
  height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  background: linear-gradient(135deg, #ef4444, #f97316);
  box-shadow: 0 10px 24px rgba(239, 68, 68, 0.32);
}

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

.movie-meta {
  margin-bottom: 10px;
}

.movie-meta span {
  background: #ffedd5;
  color: var(--orange-700);
}

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

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

.movie-card p {
  margin: 0 0 14px;
  min-height: 48px;
  color: var(--stone-600);
  line-height: 1.65;
  font-size: 14px;
}

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

.tag-row span {
  border-radius: 999px;
  padding: 5px 9px;
  color: var(--orange-700);
  background: #fff7ed;
  font-size: 12px;
  font-weight: 800;
}

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

.category-tile {
  position: relative;
  min-height: 230px;
  padding: 20px;
  border-radius: 28px;
  overflow: hidden;
  color: #fff;
  background: linear-gradient(135deg, #7c2d12, #f97316);
  box-shadow: var(--soft-shadow);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.category-tile:hover {
  transform: translateY(-6px);
  box-shadow: 0 26px 52px rgba(124, 45, 18, 0.22);
}

.category-cover {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.38;
  transition: transform 0.45s ease, opacity 0.25s ease;
}

.category-tile:hover .category-cover {
  transform: scale(1.08);
  opacity: 0.48;
}

.category-glow {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(28, 25, 23, 0.14), rgba(28, 25, 23, 0.84));
  z-index: 1;
}

.category-name,
.category-desc,
.category-action {
  position: relative;
  z-index: 2;
  display: block;
}

.category-name {
  margin-top: 66px;
  font-size: 24px;
  font-weight: 900;
}

.category-desc {
  margin-top: 10px;
  color: #ffedd5;
  line-height: 1.6;
  font-size: 14px;
}

.category-action {
  margin-top: 18px;
  font-weight: 900;
}

.rank-panel {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}

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

.rank-item {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.86);
  box-shadow: 0 8px 20px rgba(124, 45, 18, 0.08);
  transition: all 0.22s ease;
}

.rank-item:hover {
  transform: translateX(5px);
  background: #fff;
  color: var(--orange-600);
}

.mini-rank {
  width: 30px;
  height: 30px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  color: #fff;
  background: linear-gradient(135deg, var(--orange-600), var(--amber-500));
  font-weight: 900;
}

.rank-title {
  font-weight: 900;
}

.rank-meta {
  color: var(--stone-600);
  font-size: 13px;
}

.page-hero {
  max-width: 1240px;
  margin: 28px auto 0;
  padding: 52px 22px;
}

.page-hero-inner {
  border-radius: 34px;
  padding: clamp(30px, 6vw, 64px);
  color: #fff;
  background:
    radial-gradient(circle at 78% 20%, rgba(255, 255, 255, 0.22), transparent 18rem),
    linear-gradient(135deg, #7c2d12, #ea580c 52%, #f59e0b);
  box-shadow: var(--shadow);
}

.breadcrumbs {
  margin-bottom: 16px;
}

.breadcrumbs a,
.breadcrumbs span {
  background: rgba(255, 255, 255, 0.18);
}

.page-hero h1,
.detail-title {
  margin: 0;
  font-size: clamp(34px, 6vw, 60px);
  line-height: 1.05;
  letter-spacing: -0.05em;
}

.page-hero p {
  max-width: 820px;
  margin: 18px 0 0;
  color: #ffedd5;
  font-size: 17px;
  line-height: 1.8;
}

.filter-panel {
  margin-bottom: 24px;
}

.filter-line {
  display: grid;
  grid-template-columns: 1fr 170px 170px 150px;
  gap: 12px;
  padding: 14px;
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.78);
  box-shadow: var(--soft-shadow);
}

.search-input,
.filter-line select {
  width: 100%;
  min-height: 48px;
  border: 1px solid #fed7aa;
  border-radius: 16px;
  padding: 0 15px;
  background: #fff;
  color: var(--stone-900);
  font: inherit;
  outline: none;
}

.search-input:focus,
.filter-line select:focus {
  border-color: var(--orange-500);
  box-shadow: 0 0 0 4px rgba(249, 115, 22, 0.12);
}

.filter-empty {
  display: none;
  margin: 18px 0;
  padding: 24px;
  border-radius: 20px;
  text-align: center;
  color: var(--stone-600);
  background: #fff;
  box-shadow: var(--soft-shadow);
}

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

.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(320px, 0.65fr);
  gap: 26px;
  align-items: start;
}

.player-card,
.detail-card {
  border-radius: 30px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: var(--soft-shadow);
  overflow: hidden;
}

.player-box {
  position: relative;
  aspect-ratio: 16 / 9;
  background: #111827;
}

.player-box video {
  width: 100%;
  height: 100%;
  display: block;
  background: #000;
  cursor: pointer;
}

.play-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 0;
  background: linear-gradient(180deg, rgba(28, 25, 23, 0.12), rgba(28, 25, 23, 0.68));
  cursor: pointer;
  z-index: 2;
}

.play-overlay.is-hidden {
  display: none;
}

.play-circle {
  width: 96px;
  height: 96px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  color: #fff;
  background: linear-gradient(135deg, var(--orange-600), var(--amber-500));
  box-shadow: 0 20px 50px rgba(249, 115, 22, 0.35);
  font-size: 34px;
  transition: transform 0.22s ease;
}

.play-overlay:hover .play-circle {
  transform: scale(1.08);
}

.player-info {
  padding: 24px;
}

.player-info h2,
.detail-card h2 {
  margin: 0 0 12px;
  font-size: 24px;
}

.player-info p,
.detail-card p {
  margin: 0;
  color: var(--stone-600);
  line-height: 1.8;
}

.detail-card {
  padding: 24px;
}

.detail-poster {
  height: 430px;
  border-radius: 24px;
  overflow: hidden;
  background: linear-gradient(135deg, #fb923c, #fbbf24);
  margin-bottom: 20px;
}

.detail-poster img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.detail-meta span {
  background: #ffedd5;
  color: var(--orange-700);
}

.article-block {
  margin-top: 22px;
  padding-top: 22px;
  border-top: 1px solid #fed7aa;
}

.article-block h2,
.article-block h3 {
  margin: 0 0 12px;
}

.article-block p {
  color: var(--stone-600);
  line-height: 1.9;
}

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

.hot-entry {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 16px;
  align-items: center;
  margin-top: 18px;
  padding: 18px;
  border-radius: 24px;
  background: linear-gradient(90deg, #fff, #fff7ed);
  box-shadow: var(--soft-shadow);
}

.hot-entry strong {
  font-size: 18px;
}

.hot-entry p {
  margin: 6px 0 0;
  color: var(--stone-600);
}

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

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

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

  .hero-poster-panel {
    display: none;
  }
}

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

  .menu-toggle {
    display: inline-flex;
  }

  .topbar {
    height: 66px;
  }

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

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

  .hero-slide {
    padding: 34px 24px 70px;
  }

  .hero-dots {
    left: 28px;
    bottom: 24px;
  }

  .section-heading,
  .hot-entry {
    display: block;
  }

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

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

@media (max-width: 580px) {
  .movie-grid,
  .related-grid,
  .category-grid,
  .rank-panel {
    grid-template-columns: 1fr;
  }

  .hero,
  .section,
  .page-section,
  .page-hero {
    padding-left: 14px;
    padding-right: 14px;
  }

  .hero-shell,
  .page-hero-inner {
    border-radius: 24px;
  }

  .poster-link {
    height: 260px;
  }

  .detail-poster {
    height: 360px;
  }

  .rank-item {
    grid-template-columns: auto 1fr;
  }

  .rank-meta {
    grid-column: 2;
  }
}
