:root {
  --slate-950: #020617;
  --slate-900: #0f172a;
  --slate-800: #1e293b;
  --slate-700: #334155;
  --slate-100: #f1f5f9;
  --slate-50: #f8fafc;
  --red: #dc2626;
  --red-dark: #b91c1c;
  --orange: #f97316;
  --blue: #2563eb;
  --text: #111827;
  --muted: #64748b;
  --line: #e2e8f0;
  --shadow: 0 18px 45px rgba(15, 23, 42, 0.16);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
  background: linear-gradient(180deg, #f8fafc 0%, #eef2f7 100%);
  color: var(--text);
}

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

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: linear-gradient(90deg, var(--slate-900), var(--slate-800), var(--slate-900));
  color: #fff;
  box-shadow: 0 10px 30px rgba(2, 6, 23, 0.35);
}

.nav-wrap {
  max-width: 1280px;
  height: 66px;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

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

.brand-mark,
.footer-brand span {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--red), var(--orange));
  color: #fff;
  box-shadow: 0 10px 22px rgba(220, 38, 38, 0.35);
}

.brand-text {
  font-size: 21px;
  background: linear-gradient(90deg, #f87171, #fb923c);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 28px;
  font-size: 15px;
}

.nav-link {
  color: #e5e7eb;
  transition: color 0.2s ease;
}

.nav-link:hover,
.nav-link.active,
.mobile-link.active {
  color: #fb7185;
}

.nav-search,
.mobile-search,
.hero-search-panel form,
.search-panel {
  display: flex;
  align-items: center;
  gap: 10px;
}

.nav-search input,
.mobile-search input,
.hero-search-panel input,
.search-panel input,
.filter-bar input,
.filter-bar select,
.search-panel select {
  border: 1px solid rgba(226, 232, 240, 0.95);
  border-radius: 999px;
  padding: 12px 16px;
  outline: none;
  background: #fff;
  color: var(--text);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.nav-search input {
  width: 210px;
  background: rgba(51, 65, 85, 0.92);
  border-color: rgba(148, 163, 184, 0.25);
  color: #fff;
}

.nav-search input::placeholder,
.mobile-search input::placeholder {
  color: #cbd5e1;
}

.nav-search button,
.mobile-search button,
.hero-search-panel button,
.search-panel button {
  border: 0;
  border-radius: 999px;
  padding: 12px 18px;
  color: #fff;
  background: linear-gradient(90deg, var(--red), var(--orange));
  cursor: pointer;
  font-weight: 700;
  box-shadow: 0 12px 26px rgba(220, 38, 38, 0.25);
}

.menu-button {
  display: none;
  border: 0;
  background: transparent;
  color: #fff;
  font-size: 28px;
  cursor: pointer;
}

.mobile-panel {
  display: none;
  padding: 16px 24px 20px;
  border-top: 1px solid rgba(148, 163, 184, 0.2);
  background: var(--slate-800);
}

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

.mobile-link {
  display: block;
  padding: 13px 0;
  color: #e5e7eb;
  border-bottom: 1px solid rgba(148, 163, 184, 0.12);
}

.hero-carousel {
  position: relative;
  height: 72vh;
  min-height: 560px;
  overflow: hidden;
  background: linear-gradient(90deg, var(--slate-950), #7f1d1d, #9a3412);
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.65s ease;
}

.hero-slide.active {
  opacity: 1;
  pointer-events: auto;
}

.hero-bg {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.34;
  transform: scale(1.04);
}

.hero-shade {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 70% 20%, rgba(248, 113, 113, 0.22), transparent 34%),
    linear-gradient(90deg, rgba(2, 6, 23, 0.92), rgba(15, 23, 42, 0.72), rgba(2, 6, 23, 0.45)),
    linear-gradient(0deg, rgba(2, 6, 23, 0.95), transparent 52%);
}

.hero-content {
  position: absolute;
  inset: 0;
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  color: #fff;
}

.hero-label,
.page-hero span,
.section-title span {
  display: inline-flex;
  width: fit-content;
  align-items: center;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--red), var(--orange));
  color: #fff;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.hero-label {
  padding: 9px 16px;
  margin-bottom: 18px;
  font-size: 13px;
}

.hero-content h1 {
  max-width: 780px;
  margin: 0 0 8px;
  font-size: clamp(34px, 5.6vw, 72px);
  line-height: 1.02;
  letter-spacing: -0.04em;
}

.hero-content h2 {
  margin: 0 0 16px;
  font-size: clamp(24px, 3.2vw, 44px);
  color: #fed7aa;
}

.hero-content p {
  max-width: 720px;
  margin: 0 0 26px;
  color: #e5e7eb;
  font-size: 19px;
  line-height: 1.72;
}

.hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 30px;
}

.hero-meta span,
.detail-meta span {
  border-radius: 999px;
  padding: 8px 13px;
  background: rgba(15, 23, 42, 0.55);
  color: #e5e7eb;
  backdrop-filter: blur(10px);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

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

.primary-btn {
  background: linear-gradient(90deg, var(--red), var(--orange));
  color: #fff;
  box-shadow: 0 15px 35px rgba(220, 38, 38, 0.35);
}

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

.primary-btn:hover,
.ghost-btn:hover,
.movie-card:hover,
.category-tile:hover,
.horizontal-card:hover,
.rank-card:hover,
.category-overview-card:hover {
  transform: translateY(-3px);
}

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

.hero-dot {
  width: 34px;
  height: 6px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.38);
  cursor: pointer;
}

.hero-dot.active {
  background: #fff;
}

.hero-search-panel {
  margin-top: -44px;
  position: relative;
  z-index: 5;
  padding: 0 24px;
}

.panel-inner {
  max-width: 1180px;
  margin: 0 auto;
  padding: 24px;
  display: grid;
  grid-template-columns: 1fr minmax(320px, 520px);
  gap: 20px;
  align-items: center;
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}

.panel-inner strong {
  display: block;
  font-size: 24px;
}

.panel-inner span {
  color: var(--muted);
}

.hero-search-panel input,
.search-panel input {
  flex: 1;
}

.section-wrap {
  max-width: 1280px;
  margin: 0 auto;
  padding: 70px 24px;
}

.white-block {
  max-width: none;
  background: #fff;
  padding-left: max(24px, calc((100vw - 1280px) / 2 + 24px));
  padding-right: max(24px, calc((100vw - 1280px) / 2 + 24px));
}

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

.section-title span,
.page-hero span {
  padding: 7px 12px;
  margin-bottom: 8px;
  font-size: 12px;
}

.section-title h2,
.page-hero h1 {
  margin: 0;
  font-size: clamp(28px, 3.2vw, 42px);
  letter-spacing: -0.03em;
}

.section-title a {
  color: var(--red);
  font-weight: 800;
}

.movie-grid {
  display: grid;
  gap: 24px;
}

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

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

.movie-card {
  display: block;
  overflow: hidden;
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.1);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.movie-card:hover {
  box-shadow: 0 20px 45px rgba(15, 23, 42, 0.18);
}

.poster-wrap {
  position: relative;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  background: linear-gradient(135deg, var(--slate-900), var(--slate-700));
}

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

.movie-card:hover .poster-wrap img,
.category-tile:hover img,
.horizontal-card:hover img,
.rank-card:hover img,
.ranking-row:hover img {
  transform: scale(1.08);
}

.badge {
  position: absolute;
  top: 10px;
  right: 10px;
  border-radius: 999px;
  padding: 5px 8px;
  background: rgba(2, 6, 23, 0.72);
  color: #fff;
  font-size: 12px;
}

.play-dot {
  position: absolute;
  left: 50%;
  top: 50%;
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  border-radius: 999px;
  color: #fff;
  background: rgba(220, 38, 38, 0.85);
  opacity: 0;
  transform: translate(-50%, -50%) scale(0.8);
  transition: opacity 0.2s ease, transform 0.2s ease;
}

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

.card-body {
  padding: 16px;
}

.card-body h3 {
  min-height: 45px;
  margin: 8px 0;
  font-size: 17px;
  line-height: 1.35;
}

.card-body p {
  min-height: 44px;
  margin: 0 0 12px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.55;
}

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

.tag-row span,
.detail-tags a {
  border-radius: 999px;
  padding: 5px 9px;
  color: #991b1b;
  background: #fee2e2;
  font-size: 12px;
}

.meta-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  color: var(--muted);
  font-size: 13px;
}

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

.horizontal-card {
  display: grid;
  grid-template-columns: 180px 1fr;
  gap: 18px;
  overflow: hidden;
  align-items: center;
  border-radius: 18px;
  padding: 12px;
  background: var(--slate-50);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.horizontal-card img {
  width: 180px;
  height: 116px;
  object-fit: cover;
  border-radius: 14px;
  transition: transform 0.35s ease;
}

.horizontal-card strong,
.rank-card strong {
  display: block;
  margin-bottom: 8px;
  font-size: 18px;
}

.horizontal-card p,
.rank-card p {
  margin: 0 0 8px;
  color: var(--muted);
  line-height: 1.55;
}

.horizontal-card span,
.rank-card em,
.ranking-row small {
  color: var(--muted);
  font-style: normal;
  font-size: 13px;
}

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

.category-tile {
  position: relative;
  min-height: 220px;
  overflow: hidden;
  border-radius: 22px;
  padding: 24px;
  color: #fff;
  background: var(--slate-900);
  box-shadow: var(--shadow);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.category-tile img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.34;
  transition: transform 0.35s ease;
}

.category-tile::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(2, 6, 23, 0.92), rgba(2, 6, 23, 0.25));
}

.category-tile span,
.category-tile p {
  position: relative;
  z-index: 1;
}

.category-tile span {
  display: block;
  margin-top: 72px;
  font-size: 24px;
  font-weight: 900;
}

.category-tile p {
  margin: 10px 0 0;
  color: #e5e7eb;
  line-height: 1.6;
}

.rank-section {
  padding-top: 40px;
}

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

.rank-card {
  position: relative;
  display: grid;
  grid-template-columns: 42px 110px 1fr;
  gap: 14px;
  align-items: center;
  border-radius: 18px;
  padding: 14px;
  background: #fff;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.1);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.rank-num {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: 12px;
  color: #fff;
  font-weight: 900;
  background: linear-gradient(135deg, var(--red), var(--orange));
}

.rank-card img {
  width: 110px;
  height: 76px;
  object-fit: cover;
  border-radius: 12px;
  transition: transform 0.35s ease;
}

.page-main {
  min-height: 60vh;
}

.page-hero {
  position: relative;
  overflow: hidden;
  padding: 86px 24px;
  color: #fff;
  background:
    radial-gradient(circle at 80% 20%, rgba(249, 115, 22, 0.35), transparent 32%),
    linear-gradient(120deg, var(--slate-950), #7f1d1d 52%, #1e293b);
}

.page-hero.small {
  padding: 74px 24px;
}

.page-hero > div {
  max-width: 1280px;
  margin: 0 auto;
}

.page-hero p {
  max-width: 760px;
  margin: 16px 0 0;
  color: #e2e8f0;
  font-size: 18px;
  line-height: 1.7;
}

.filter-bar,
.search-panel {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 28px;
  padding: 18px;
  border-radius: 22px;
  background: #fff;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.08);
}

.filter-bar input {
  min-width: min(100%, 320px);
  flex: 1;
}

.filter-bar select,
.search-panel select {
  min-width: 160px;
}

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

.category-overview-card {
  overflow: hidden;
  border-radius: 24px;
  background: #fff;
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.1);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.thumb-stack {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  height: 150px;
  background: var(--slate-900);
}

.thumb-stack img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.overview-copy {
  padding: 22px;
}

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

.overview-copy p {
  min-height: 52px;
  color: var(--muted);
  line-height: 1.6;
}

.overview-copy span {
  display: inline-flex;
  color: var(--red);
  font-weight: 800;
}

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

.ranking-row {
  display: grid;
  grid-template-columns: 56px 120px 1fr 80px;
  gap: 18px;
  align-items: center;
  border-radius: 20px;
  padding: 14px;
}

.ranking-index {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 14px;
  color: #fff;
  font-weight: 900;
  background: linear-gradient(135deg, var(--red), var(--orange));
}

.ranking-row img {
  width: 120px;
  height: 78px;
  object-fit: cover;
  border-radius: 14px;
  transition: transform 0.35s ease;
}

.ranking-row h2 {
  margin: 0 0 7px;
  font-size: 19px;
}

.ranking-row p {
  margin: 0 0 6px;
  color: var(--muted);
}

.ranking-row strong {
  color: #b45309;
  font-size: 20px;
}

.search-wrap {
  padding-top: 36px;
}

.detail-main {
  background: #f8fafc;
}

.detail-hero {
  position: relative;
  overflow: hidden;
  color: #fff;
  background: var(--slate-950);
}

.detail-bg {
  position: absolute;
  inset: 0;
}

.detail-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.22;
  filter: blur(2px);
}

.detail-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(2, 6, 23, 0.96), rgba(15, 23, 42, 0.78), rgba(127, 29, 29, 0.56));
}

.detail-shell {
  position: relative;
  max-width: 1280px;
  margin: 0 auto;
  padding: 34px 24px 58px;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 28px;
  color: #cbd5e1;
  font-size: 14px;
}

.breadcrumb a:hover {
  color: #fff;
}

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

.detail-poster {
  overflow: hidden;
  border-radius: 24px;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.45);
}

.detail-poster img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
}

.detail-copy h1 {
  margin: 0 0 14px;
  font-size: clamp(34px, 5vw, 58px);
  line-height: 1.05;
}

.detail-line {
  max-width: 780px;
  margin: 0 0 22px;
  color: #e5e7eb;
  font-size: 19px;
  line-height: 1.75;
}

.detail-meta,
.detail-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 24px;
}

.detail-tags a {
  color: #fecaca;
  background: rgba(220, 38, 38, 0.28);
}

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

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

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

.player-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  gap: 14px;
  border: 0;
  color: #fff;
  background: linear-gradient(0deg, rgba(2, 6, 23, 0.62), rgba(2, 6, 23, 0.12));
  cursor: pointer;
}

.player-overlay.hidden {
  display: none;
}

.player-overlay span {
  display: grid;
  place-items: center;
  width: 86px;
  height: 86px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--red), var(--orange));
  box-shadow: 0 18px 40px rgba(220, 38, 38, 0.38);
  font-size: 34px;
}

.player-overlay strong {
  padding: 0 20px;
  font-size: clamp(20px, 3vw, 34px);
}

.content-card {
  margin-top: 28px;
  padding: 30px;
  border-radius: 24px;
  background: #fff;
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.08);
}

.content-card h2 {
  margin: 0 0 14px;
  font-size: 25px;
}

.content-card p {
  color: #334155;
  line-height: 1.88;
  font-size: 17px;
}

.content-card .lead {
  color: #111827;
  font-weight: 700;
}

.next-prev {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  margin-top: 18px;
}

.next-prev a {
  flex: 1;
  padding: 16px 18px;
  border-radius: 16px;
  background: #fff;
  color: var(--red);
  font-weight: 800;
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.08);
}

.site-footer {
  color: #cbd5e1;
  background: linear-gradient(180deg, var(--slate-900), var(--slate-950));
}

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

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

.footer-grid p {
  max-width: 360px;
  line-height: 1.7;
}

.footer-grid a:not(.footer-brand) {
  display: block;
  margin: 8px 0;
  color: #cbd5e1;
}

.footer-grid a:hover {
  color: #fb7185;
}

.footer-bottom {
  max-width: 1280px;
  margin: 0 auto;
  padding: 18px 24px 28px;
  border-top: 1px solid rgba(148, 163, 184, 0.18);
  color: #94a3b8;
  font-size: 14px;
}

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

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

  .desktop-nav,
  .nav-search {
    display: none;
  }

  .menu-button {
    display: block;
  }
}

@media (max-width: 760px) {
  .nav-wrap {
    padding: 0 16px;
  }

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

  .hero-carousel {
    min-height: 680px;
    height: 78vh;
  }

  .hero-content {
    padding: 0 18px;
  }

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

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

  .hero-search-panel form,
  .search-panel,
  .filter-bar,
  .next-prev {
    flex-direction: column;
    align-items: stretch;
  }

  .section-wrap,
  .white-block {
    padding: 44px 16px;
  }

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

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

  .horizontal-card,
  .rank-card,
  .ranking-row,
  .detail-grid {
    grid-template-columns: 1fr;
  }

  .horizontal-card img,
  .rank-card img,
  .ranking-row img {
    width: 100%;
    height: 190px;
  }

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

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

  .mobile-search {
    align-items: stretch;
  }
}
