:root {
  --orange: #f97316;
  --orange-dark: #ea580c;
  --red: #dc2626;
  --ink: #1f2937;
  --muted: #6b7280;
  --line: #e5e7eb;
  --soft: #fff7ed;
  --page: #f9fafb;
  --card: #ffffff;
  --shadow: 0 16px 35px rgba(15, 23, 42, 0.12);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", Arial, sans-serif;
  color: var(--ink);
  background: var(--page);
  line-height: 1.6;
}

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

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

button,
input,
select {
  font: inherit;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  color: #ffffff;
  background: linear-gradient(90deg, var(--orange), var(--red));
  box-shadow: 0 10px 30px rgba(220, 38, 38, 0.22);
}

.header-inner {
  height: 64px;
  display: flex;
  align-items: center;
  gap: 24px;
}

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

.brand-mark {
  display: inline-grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.22);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.28);
  font-size: 16px;
}

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

.desktop-nav a {
  font-weight: 650;
  opacity: 0.94;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.desktop-nav a:hover,
.desktop-nav a.active {
  opacity: 1;
  transform: translateY(-1px);
}

.header-search {
  width: 280px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.header-search input,
.mobile-panel input {
  width: 100%;
  border: 0;
  outline: 0;
  border-radius: 999px;
  padding: 10px 14px;
  color: var(--ink);
  background: rgba(255, 255, 255, 0.96);
}

.header-search button,
.mobile-panel button,
.filter-panel button,
.btn,
.play-button {
  border: 0;
  cursor: pointer;
  border-radius: 999px;
  padding: 10px 18px;
  font-weight: 750;
  color: #ffffff;
  background: var(--orange);
  transition: transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}

.header-search button {
  color: var(--orange-dark);
  background: #ffffff;
  white-space: nowrap;
}

.header-search button:hover,
.mobile-panel button:hover,
.filter-panel button:hover,
.btn:hover,
.play-button:hover {
  transform: translateY(-1px);
  box-shadow: 0 8px 18px rgba(249, 115, 22, 0.3);
}

.menu-toggle {
  display: none;
  margin-left: auto;
  border: 0;
  color: #ffffff;
  background: transparent;
  font-size: 28px;
  cursor: pointer;
}

.mobile-panel {
  display: none;
  width: min(1200px, calc(100% - 32px));
  margin: 0 auto;
  padding: 0 0 18px;
}

.mobile-panel form {
  display: flex;
  gap: 8px;
  margin-bottom: 14px;
}

.mobile-panel nav {
  display: grid;
  gap: 10px;
}

.mobile-panel nav a {
  padding: 10px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.22);
}

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

.hero {
  position: relative;
  height: 600px;
  overflow: hidden;
  background: #000000;
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 1s ease;
}

.hero-slide.active {
  opacity: 1;
}

.hero-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-slide::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.96) 0%, rgba(0, 0, 0, 0.62) 44%, rgba(0, 0, 0, 0.16) 100%);
}

.hero-content {
  position: absolute;
  left: 50%;
  bottom: 72px;
  z-index: 2;
  transform: translateX(-50%);
  color: #ffffff;
}

.hero-badge,
.section-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border-radius: 999px;
  padding: 6px 14px;
  color: #ffffff;
  background: var(--orange);
  font-size: 14px;
  font-weight: 800;
}

.hero-title {
  max-width: 820px;
  margin: 18px 0 14px;
  font-size: clamp(34px, 6vw, 64px);
  line-height: 1.1;
  font-weight: 900;
  letter-spacing: -0.04em;
}

.hero-text {
  max-width: 720px;
  margin: 0 0 28px;
  font-size: 18px;
  color: #e5e7eb;
}

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

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
}

.btn-light {
  color: var(--orange-dark);
  background: #ffffff;
}

.hero-control {
  position: absolute;
  top: 50%;
  z-index: 3;
  width: 46px;
  height: 46px;
  border: 0;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(0, 0, 0, 0.5);
  cursor: pointer;
  transform: translateY(-50%);
  transition: background 0.2s ease;
}

.hero-control:hover {
  background: rgba(0, 0, 0, 0.75);
}

.hero-prev {
  left: 18px;
}

.hero-next {
  right: 18px;
}

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

.hero-dot {
  width: 9px;
  height: 9px;
  border: 0;
  border-radius: 999px;
  padding: 0;
  background: rgba(255, 255, 255, 0.55);
  cursor: pointer;
  transition: width 0.2s ease, background 0.2s ease;
}

.hero-dot.active {
  width: 32px;
  background: var(--orange);
}

.page-main {
  padding: 48px 0 0;
}

.page-hero {
  padding: 54px 0;
  color: #ffffff;
  background: linear-gradient(135deg, #111827, #7f1d1d 58%, var(--orange));
}

.page-hero h1 {
  margin: 0 0 12px;
  font-size: clamp(32px, 5vw, 52px);
  line-height: 1.12;
  font-weight: 900;
}

.page-hero p {
  max-width: 780px;
  margin: 0;
  color: #f3f4f6;
  font-size: 17px;
}

.section {
  margin-bottom: 64px;
}

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

.section-heading h2,
.section-heading h1 {
  margin: 0;
  color: var(--ink);
  font-size: clamp(26px, 4vw, 36px);
  line-height: 1.2;
  font-weight: 900;
}

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

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

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

.movie-grid-small {
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 16px;
}

.movie-card {
  overflow: hidden;
  border-radius: 16px;
  background: var(--card);
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.08);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

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

.poster-frame {
  position: relative;
  display: block;
  height: 230px;
  overflow: hidden;
  background: #e5e7eb;
}

.movie-card-small .poster-frame {
  height: 164px;
}

.movie-card-large .poster-frame {
  height: 360px;
}

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

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

.poster-shade {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background: rgba(0, 0, 0, 0);
  transition: background 0.25s ease;
}

.poster-play {
  display: grid;
  place-items: center;
  width: 58px;
  height: 58px;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(249, 115, 22, 0.9);
  opacity: 0;
  transform: scale(0.88);
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.movie-card:hover .poster-shade {
  background: rgba(0, 0, 0, 0.38);
}

.movie-card:hover .poster-play {
  opacity: 1;
  transform: scale(1);
}

.year-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  border-radius: 8px;
  padding: 4px 8px;
  color: #ffffff;
  background: rgba(0, 0, 0, 0.72);
  font-size: 12px;
  font-weight: 700;
}

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

.movie-card-body h3 {
  margin: 0 0 8px;
  font-size: 18px;
  line-height: 1.35;
  font-weight: 850;
}

.movie-card-small .movie-card-body h3 {
  font-size: 16px;
}

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

.movie-card-body p {
  display: -webkit-box;
  margin: 0 0 14px;
  min-height: 44px;
  overflow: hidden;
  color: var(--muted);
  font-size: 14px;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

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

.movie-meta span {
  border-radius: 999px;
  padding: 4px 9px;
  background: #f3f4f6;
}

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

.feature-panel {
  border-radius: 24px;
  padding: 30px;
  background: linear-gradient(135deg, #fff7ed, #fef2f2);
}

.category-strip {
  display: grid;
  gap: 28px;
}

.category-block h3 {
  margin: 0 0 14px;
  font-size: 22px;
}

.category-block h3 a:hover {
  color: var(--orange-dark);
}

.latest-list,
.compact-list,
.rank-list {
  display: grid;
  gap: 16px;
}

.compact-item,
.latest-item {
  display: flex;
  gap: 16px;
  align-items: center;
  border-radius: 16px;
  padding: 14px;
  background: var(--card);
  box-shadow: 0 6px 16px rgba(15, 23, 42, 0.06);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.compact-item:hover,
.latest-item:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow);
}

.compact-item img,
.latest-item img {
  width: 138px;
  height: 82px;
  flex: 0 0 138px;
  border-radius: 12px;
  object-fit: cover;
}

.compact-item strong,
.latest-item strong {
  display: block;
  margin-bottom: 4px;
  font-size: 16px;
}

.compact-item em,
.latest-item em {
  display: block;
  color: var(--muted);
  font-size: 13px;
  font-style: normal;
}

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

.category-tile {
  display: flex;
  min-height: 148px;
  flex-direction: column;
  justify-content: space-between;
  border-radius: 22px;
  padding: 22px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--orange), var(--red));
  box-shadow: 0 16px 30px rgba(220, 38, 38, 0.18);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.category-tile:hover {
  transform: translateY(-4px);
  box-shadow: 0 20px 36px rgba(220, 38, 38, 0.28);
}

.category-tile strong {
  font-size: 23px;
}

.category-tile span {
  color: rgba(255, 255, 255, 0.88);
}

.filter-panel {
  margin-bottom: 28px;
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 18px;
  background: #ffffff;
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.05);
}

.filter-row {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) 160px 160px 160px auto;
  gap: 12px;
}

.filter-row input,
.filter-row select {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 999px;
  outline: 0;
  padding: 10px 14px;
  background: #ffffff;
}

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

.empty-state {
  margin: 14px 0 0;
  color: var(--muted);
}

.rank-item {
  display: grid;
  grid-template-columns: 54px 140px minmax(0, 1fr);
  gap: 18px;
  align-items: center;
  border-radius: 18px;
  padding: 16px;
  background: #ffffff;
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.06);
}

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

.rank-cover img {
  width: 140px;
  height: 82px;
  border-radius: 12px;
  object-fit: cover;
}

.rank-content h3 {
  margin: 0 0 6px;
  font-size: 18px;
}

.rank-content h3 a:hover {
  color: var(--orange-dark);
}

.rank-content p {
  display: -webkit-box;
  margin: 0 0 10px;
  overflow: hidden;
  color: var(--muted);
  font-size: 14px;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.breadcrumb {
  margin: 22px auto;
  color: var(--muted);
  font-size: 14px;
}

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

.detail-hero {
  padding: 34px 0 48px;
  color: #ffffff;
  background: radial-gradient(circle at 20% 0%, rgba(249, 115, 22, 0.75), transparent 32%), linear-gradient(135deg, #111827, #7f1d1d 54%, #111827);
}

.detail-layout {
  display: grid;
  grid-template-columns: 320px minmax(0, 1fr);
  gap: 34px;
  align-items: center;
}

.detail-poster img {
  width: 100%;
  height: 430px;
  border-radius: 24px;
  object-fit: cover;
  box-shadow: 0 22px 45px rgba(0, 0, 0, 0.28);
}

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

.detail-info p {
  max-width: 820px;
  color: #e5e7eb;
  font-size: 17px;
}

.detail-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 18px 0 24px;
}

.detail-tags span {
  border-radius: 999px;
  padding: 7px 12px;
  background: rgba(255, 255, 255, 0.14);
}

.player-section {
  margin-top: 44px;
}

.player-section h2,
.detail-content h2,
.related-section h2 {
  margin: 0 0 18px;
  font-size: 28px;
  line-height: 1.25;
}

.player-card {
  position: relative;
  overflow: hidden;
  border-radius: 24px;
  background: #000000;
  box-shadow: var(--shadow);
}

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

.play-mask {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  border: 0;
  cursor: pointer;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.65), rgba(0, 0, 0, 0.12));
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

.play-mask span {
  display: grid;
  place-items: center;
  width: 82px;
  height: 82px;
  border-radius: 999px;
  color: #ffffff;
  background: var(--orange);
  box-shadow: 0 18px 32px rgba(249, 115, 22, 0.36);
  font-size: 28px;
}

.play-mask.is-hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.detail-main-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 330px;
  gap: 28px;
  align-items: start;
  margin-top: 36px;
}

.detail-content,
.related-box {
  border-radius: 22px;
  padding: 26px;
  background: #ffffff;
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.06);
}

.detail-content p {
  margin: 0 0 24px;
  color: #374151;
  font-size: 16px;
  line-height: 1.9;
}

.related-box {
  position: sticky;
  top: 88px;
}

.related-box .compact-item {
  box-shadow: none;
  border: 1px solid var(--line);
}

.pagination-links {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  margin-top: 34px;
}

.pagination-links a {
  border-radius: 14px;
  padding: 12px 16px;
  color: var(--orange-dark);
  background: #fff7ed;
  font-weight: 750;
}

.site-footer {
  margin-top: 72px;
  color: #d1d5db;
  background: #111827;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 32px;
  padding: 44px 0;
}

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

.site-footer p {
  margin: 0;
  max-width: 520px;
}

.site-footer a {
  display: block;
  margin: 6px 0;
}

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

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.09);
  padding: 18px 16px;
  text-align: center;
  color: #9ca3af;
  font-size: 14px;
}

[hidden] {
  display: none !important;
}

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

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

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

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

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

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

  .related-box {
    position: static;
  }
}

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

  .desktop-nav {
    display: none;
  }

  .menu-toggle {
    display: block;
  }

  .brand {
    font-size: 20px;
  }

  .hero {
    height: 540px;
  }

  .hero-content {
    bottom: 74px;
  }

  .hero-title {
    font-size: 34px;
  }

  .hero-control {
    display: none;
  }

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

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

  .poster-frame,
  .movie-card-large .poster-frame,
  .movie-card-small .poster-frame {
    height: 220px;
  }

  .feature-panel {
    padding: 20px;
  }

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

  .rank-item {
    grid-template-columns: 42px 98px minmax(0, 1fr);
    gap: 12px;
    padding: 12px;
  }

  .rank-cover img {
    width: 98px;
    height: 68px;
  }

  .rank-number {
    width: 38px;
    height: 38px;
  }

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

  .detail-poster img {
    max-height: 420px;
  }

  .detail-content,
  .related-box {
    padding: 20px;
  }

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

@media (max-width: 480px) {
  .movie-grid,
  .movie-grid-large,
  .movie-grid-small,
  .category-overview-grid {
    grid-template-columns: 1fr;
  }

  .poster-frame,
  .movie-card-large .poster-frame,
  .movie-card-small .poster-frame {
    height: 260px;
  }

  .compact-item img,
  .latest-item img {
    width: 108px;
    height: 72px;
    flex-basis: 108px;
  }
}
