:root {
  --brand: #f59e0b;
  --brand-deep: #ea580c;
  --brand-soft: #fff7ed;
  --ink: #111827;
  --muted: #6b7280;
  --line: rgba(17, 24, 39, 0.08);
  --card: rgba(255, 255, 255, 0.92);
  --shadow: 0 22px 60px rgba(17, 24, 39, 0.12);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: "PingFang SC", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
  color: var(--ink);
  background: linear-gradient(135deg, #fff7ed 0%, #ffffff 42%, #fff1e6 100%);
  min-height: 100vh;
}

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

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

button,
input {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: linear-gradient(90deg, var(--brand) 0%, var(--brand-deep) 100%);
  box-shadow: 0 10px 30px rgba(194, 65, 12, 0.22);
}

.nav-inner {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  min-height: 68px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand,
.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: #ffffff;
  font-weight: 900;
  letter-spacing: 0.02em;
  font-size: clamp(20px, 3vw, 26px);
}

.brand-mark {
  width: 34px;
  height: 34px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.18);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.3);
  font-size: 15px;
}

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

.nav-link,
.mobile-link {
  color: rgba(255, 255, 255, 0.9);
  font-weight: 700;
  padding: 10px 15px;
  border-radius: 999px;
  transition: background 0.2s ease, transform 0.2s ease, color 0.2s ease;
}

.nav-link:hover,
.nav-link.active,
.mobile-link:hover,
.mobile-link.active {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.18);
  transform: translateY(-1px);
}

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

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

.mobile-nav {
  display: none;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 0 0 14px;
  gap: 8px;
  flex-wrap: wrap;
}

.hero {
  position: relative;
  min-height: min(74vh, 720px);
  overflow: hidden;
  isolation: isolate;
  border-radius: 0 0 42px 42px;
  background: radial-gradient(circle at 18% 20%, rgba(255, 255, 255, 0.32), transparent 32%), linear-gradient(135deg, #f59e0b 0%, #f97316 45%, #7c2d12 100%);
}

.hero-backdrop {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(17, 24, 39, 0.32), rgba(17, 24, 39, 0.1));
  z-index: -1;
}

.hero-slide {
  display: none;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  min-height: min(74vh, 720px);
  align-items: center;
  grid-template-columns: minmax(0, 1.1fr) minmax(280px, 0.74fr);
  gap: clamp(24px, 5vw, 70px);
  padding: 56px 0 88px;
}

.hero-slide.active {
  display: grid;
  animation: heroFade 0.65s ease both;
}

@keyframes heroFade {
  from {
    opacity: 0;
    transform: translateY(18px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.hero-copy {
  color: #ffffff;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
  color: #ffffff;
  font-weight: 800;
  font-size: 13px;
  letter-spacing: 0.08em;
}

.eyebrow.dark {
  background: rgba(245, 158, 11, 0.12);
  color: #b45309;
}

.hero h1,
.hero-title {
  margin: 20px 0 8px;
  font-size: clamp(34px, 6vw, 72px);
  line-height: 1.02;
  letter-spacing: -0.05em;
  font-weight: 950;
}

.hero h2:not(.hero-title) {
  margin: 0 0 18px;
  font-size: clamp(24px, 4vw, 46px);
  line-height: 1.1;
  font-weight: 900;
}

.hero p {
  margin: 0;
  max-width: 700px;
  color: rgba(255, 255, 255, 0.88);
  line-height: 1.9;
  font-size: clamp(16px, 2vw, 19px);
}

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

.hero-tags {
  margin: 24px 0 30px;
}

.hero-tags span,
.detail-meta span,
.tag-row span {
  display: inline-flex;
  padding: 7px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.16);
  color: rgba(255, 255, 255, 0.92);
  font-size: 13px;
  font-weight: 700;
}

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

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

.primary-btn {
  background: #ffffff;
  color: #c2410c;
  box-shadow: 0 15px 30px rgba(124, 45, 18, 0.22);
}

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

.ghost-btn {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.16);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.28);
}

.ghost-btn.dark {
  color: #c2410c;
  background: rgba(245, 158, 11, 0.12);
  box-shadow: inset 0 0 0 1px rgba(245, 158, 11, 0.2);
}

.hero-poster {
  position: relative;
  display: block;
  border-radius: 34px;
  padding: 12px;
  background: rgba(255, 255, 255, 0.2);
  box-shadow: 0 35px 80px rgba(17, 24, 39, 0.28);
  backdrop-filter: blur(16px);
}

.hero-poster::before {
  content: "";
  position: absolute;
  inset: 8%;
  background: rgba(255, 255, 255, 0.22);
  filter: blur(42px);
  z-index: -1;
}

.hero-poster img {
  width: 100%;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  border-radius: 24px;
  background: linear-gradient(135deg, #fed7aa, #fb923c);
}

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

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

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

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

.search-entry {
  display: grid;
  grid-template-columns: 1fr minmax(280px, 520px);
  align-items: center;
  gap: 24px;
}

.search-entry h2,
.section-heading h2,
.page-hero h1 {
  margin: 10px 0 0;
  font-size: clamp(28px, 4vw, 44px);
  line-height: 1.15;
  letter-spacing: -0.04em;
}

.search-box,
.filter-panel {
  display: flex;
  gap: 12px;
  padding: 12px;
  border-radius: 24px;
  background: var(--card);
  box-shadow: var(--shadow);
  border: 1px solid rgba(245, 158, 11, 0.16);
}

.search-box input,
.filter-panel input {
  flex: 1;
  min-width: 0;
  border: 0;
  outline: 0;
  background: #fff7ed;
  border-radius: 16px;
  padding: 0 16px;
  color: var(--ink);
}

.search-box button,
.filter-chips button {
  border: 0;
  border-radius: 16px;
  padding: 12px 18px;
  background: linear-gradient(90deg, var(--brand), var(--brand-deep));
  color: #ffffff;
  font-weight: 900;
  cursor: pointer;
}

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

.section-heading.compact {
  align-items: center;
}

.section-link {
  color: #c2410c;
  font-weight: 900;
  padding: 10px 14px;
  border-radius: 999px;
  background: rgba(245, 158, 11, 0.12);
}

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

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

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

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

.movie-card {
  min-width: 0;
}

.movie-card-link {
  display: flex;
  flex-direction: column;
  height: 100%;
  border-radius: 24px;
  overflow: hidden;
  background: var(--card);
  box-shadow: 0 14px 38px rgba(17, 24, 39, 0.08);
  border: 1px solid rgba(245, 158, 11, 0.12);
  transition: transform 0.24s ease, box-shadow 0.24s ease;
}

.movie-card-link:hover {
  transform: translateY(-6px);
  box-shadow: 0 22px 60px rgba(194, 65, 12, 0.16);
}

.card-cover {
  position: relative;
  background: linear-gradient(135deg, #fed7aa, #f97316);
  overflow: hidden;
}

.card-cover img {
  width: 100%;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  transition: transform 0.32s ease, opacity 0.2s ease;
}

.movie-card-link:hover .card-cover img {
  transform: scale(1.06);
}

.cover-img.is-missing {
  opacity: 0;
}

.card-badge {
  position: absolute;
  left: 12px;
  top: 12px;
  padding: 7px 10px;
  border-radius: 999px;
  background: rgba(17, 24, 39, 0.62);
  color: #ffffff;
  font-size: 12px;
  font-weight: 900;
  backdrop-filter: blur(8px);
}

.card-body {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 16px;
  flex: 1;
}

.card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

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

.card-body p {
  margin: 0;
  color: #4b5563;
  line-height: 1.7;
  font-size: 14px;
}

.tag-row span {
  background: rgba(245, 158, 11, 0.11);
  color: #b45309;
}

.tag-row.large span {
  font-size: 14px;
}

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

.category-tile {
  position: relative;
  min-height: 210px;
  overflow: hidden;
  border-radius: 26px;
  padding: 22px;
  color: #ffffff;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  box-shadow: var(--shadow);
  isolation: isolate;
}

.category-tile::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(17, 24, 39, 0.1), rgba(17, 24, 39, 0.72));
  z-index: -1;
}

.category-tile img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: -2;
  background: linear-gradient(135deg, #fdba74, #ea580c);
}

.category-tile span {
  font-size: 24px;
  font-weight: 950;
}

.category-tile p {
  margin: 8px 0 0;
  color: rgba(255, 255, 255, 0.84);
  line-height: 1.6;
}

.split-section {
  display: grid;
  grid-template-columns: minmax(0, 0.78fr) minmax(0, 1.22fr);
  gap: 28px;
}

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

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

.rank-item {
  display: grid;
  grid-template-columns: 44px 72px minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  padding: 12px;
  background: var(--card);
  border: 1px solid rgba(245, 158, 11, 0.12);
  border-radius: 20px;
  box-shadow: 0 12px 30px rgba(17, 24, 39, 0.06);
}

.rank-num {
  color: #c2410c;
  font-size: 20px;
  font-weight: 950;
}

.rank-thumb {
  width: 72px;
  height: 54px;
  object-fit: cover;
  border-radius: 12px;
  background: linear-gradient(135deg, #fed7aa, #f97316);
}

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

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

.rank-info strong {
  font-size: 16px;
}

.rank-info em {
  color: var(--muted);
  font-style: normal;
  font-size: 13px;
  margin-top: 4px;
}

.rank-score {
  color: #b45309;
  font-weight: 950;
}

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

.page-hero {
  width: min(1180px, calc(100% - 32px));
  margin: 28px auto 0;
  border-radius: 34px;
  padding: clamp(34px, 7vw, 72px);
  background: linear-gradient(135deg, #f59e0b, #ea580c 60%, #7c2d12);
  color: #ffffff;
  box-shadow: var(--shadow);
  overflow: hidden;
  position: relative;
}

.page-hero::after {
  content: "";
  position: absolute;
  right: -120px;
  top: -120px;
  width: 280px;
  height: 280px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
}

.page-hero p {
  max-width: 760px;
  margin: 18px 0 0;
  color: rgba(255, 255, 255, 0.88);
  line-height: 1.9;
  font-size: 17px;
}

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

.filter-panel.single {
  max-width: 680px;
}

.filter-panel input {
  min-height: 52px;
}

.filter-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.filter-chips button {
  background: rgba(245, 158, 11, 0.11);
  color: #b45309;
}

.filter-chips button.active {
  background: linear-gradient(90deg, var(--brand), var(--brand-deep));
  color: #ffffff;
}

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

.category-overview-card {
  background: var(--card);
  border: 1px solid rgba(245, 158, 11, 0.12);
  border-radius: 26px;
  padding: 22px;
  box-shadow: 0 14px 38px rgba(17, 24, 39, 0.08);
}

.category-overview-head {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
  font-weight: 950;
  font-size: 22px;
}

.category-overview-head strong {
  color: #c2410c;
  font-size: 14px;
}

.category-overview-card p {
  color: var(--muted);
  line-height: 1.7;
}

.category-overview-card ul {
  padding: 0;
  margin: 16px 0 0;
  list-style: none;
  display: grid;
  gap: 8px;
}

.category-overview-card li a {
  color: #374151;
  font-weight: 700;
}

.detail-hero {
  background: linear-gradient(135deg, #fff7ed, #ffffff);
  padding: 36px 0 20px;
}

.detail-layout {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: 320px minmax(0, 1fr);
  gap: clamp(24px, 5vw, 58px);
  align-items: center;
}

.detail-poster {
  border-radius: 30px;
  overflow: hidden;
  box-shadow: var(--shadow);
  background: linear-gradient(135deg, #fed7aa, #ea580c);
}

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

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: #9a3412;
  font-size: 14px;
  font-weight: 800;
  margin-bottom: 18px;
}

.detail-info .eyebrow {
  color: #b45309;
  background: rgba(245, 158, 11, 0.12);
}

.detail-info h1 {
  margin: 16px 0;
  font-size: clamp(34px, 5vw, 64px);
  letter-spacing: -0.05em;
  line-height: 1.08;
}

.detail-one-line {
  color: #4b5563;
  line-height: 1.9;
  font-size: 18px;
  margin: 0 0 20px;
}

.detail-meta span {
  background: #ffffff;
  color: #9a3412;
  box-shadow: inset 0 0 0 1px rgba(245, 158, 11, 0.14);
}

.detail-actions {
  margin-top: 26px;
}

.detail-actions .primary-btn {
  color: #ffffff;
  background: linear-gradient(90deg, var(--brand), var(--brand-deep));
}

.player-section {
  padding-top: 34px;
}

.player-panel {
  position: relative;
  border-radius: 30px;
  overflow: hidden;
  background: #0f172a;
  box-shadow: var(--shadow);
}

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

.play-mask {
  position: absolute;
  inset: 0;
  border: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  color: #ffffff;
  cursor: pointer;
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.18), rgba(15, 23, 42, 0.78));
  z-index: 2;
}

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

.play-circle {
  width: 78px;
  height: 78px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--brand), var(--brand-deep));
  box-shadow: 0 18px 40px rgba(194, 65, 12, 0.4);
  font-size: 30px;
}

.play-mask strong {
  font-size: clamp(20px, 3vw, 34px);
}

.detail-content-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) 320px;
  gap: 22px;
}

.content-card {
  background: var(--card);
  border: 1px solid rgba(245, 158, 11, 0.12);
  border-radius: 26px;
  padding: 24px;
  box-shadow: 0 14px 38px rgba(17, 24, 39, 0.08);
}

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

.content-card p {
  margin: 0;
  color: #4b5563;
  line-height: 1.9;
}

.info-card dl {
  display: grid;
  grid-template-columns: 72px 1fr;
  gap: 12px;
  margin: 0;
}

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

.info-card dd {
  margin: 0;
  color: #111827;
  font-weight: 700;
}

.info-card dd span {
  display: inline-flex;
  margin: 0 6px 6px 0;
  padding: 5px 8px;
  border-radius: 999px;
  background: rgba(245, 158, 11, 0.11);
  color: #b45309;
  font-size: 12px;
}

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

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

.footer-brand {
  color: #ffffff;
  margin-bottom: 14px;
}

.site-footer p {
  color: #9ca3af;
  line-height: 1.8;
  margin: 0;
}

.site-footer h3 {
  margin: 0 0 16px;
  color: #ffffff;
}

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

.footer-links a {
  color: #d1d5db;
  padding: 8px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
}

.footer-bottom {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 18px 0 26px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  color: #9ca3af;
  font-size: 14px;
}

.movie-card.is-hidden {
  display: none;
}

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

  .split-section,
  .detail-content-grid {
    grid-template-columns: 1fr;
  }

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

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

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

  .mobile-nav.open {
    display: flex;
  }

  .hero-slide {
    grid-template-columns: 1fr;
    padding-top: 38px;
    text-align: left;
  }

  .hero-poster {
    max-width: 360px;
    margin: 0 auto;
  }

  .search-entry,
  .detail-layout,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .search-box {
    flex-direction: column;
  }

  .search-box input {
    min-height: 52px;
  }

  .long-rank-list {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .nav-inner,
  .mobile-nav,
  .section,
  .page-hero,
  .detail-layout,
  .footer-grid,
  .footer-bottom {
    width: min(100% - 22px, 1180px);
  }

  .hero {
    border-radius: 0 0 28px 28px;
  }

  .hero-slide {
    width: min(100% - 22px, 1180px);
  }

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

  .card-body {
    padding: 12px;
  }

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

  .card-body p,
  .tag-row {
    display: none;
  }

  .rank-item {
    grid-template-columns: 36px 58px minmax(0, 1fr);
  }

  .rank-score {
    display: none;
  }

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

  .detail-info h1 {
    font-size: 34px;
  }
}
