:root {
  --amber-700: #b45309;
  --amber-600: #d97706;
  --amber-500: #f59e0b;
  --orange-700: #c2410c;
  --stone-950: #0c0a09;
  --stone-900: #1c1917;
  --stone-800: #292524;
  --stone-700: #44403c;
  --stone-600: #57534e;
  --stone-500: #78716c;
  --stone-300: #d6d3d1;
  --stone-200: #e7e5e4;
  --stone-100: #f5f5f4;
  --stone-50: #fafaf9;
  --white: #ffffff;
  --shadow-soft: 0 18px 45px rgba(28, 25, 23, 0.16);
  --shadow-card: 0 12px 30px rgba(28, 25, 23, 0.12);
  --radius-lg: 22px;
  --radius-md: 16px;
  --radius-sm: 10px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--stone-800);
  background: var(--stone-50);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
}

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

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

button,
input {
  font: inherit;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  color: var(--white);
  background: linear-gradient(90deg, var(--amber-700), var(--amber-600), var(--orange-700));
  box-shadow: 0 10px 30px rgba(120, 53, 15, 0.28);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 68px;
  gap: 24px;
}

.brand,
.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-weight: 800;
}

.brand-mark {
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  color: var(--amber-700);
  background: var(--white);
  border-radius: 14px;
  box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.35);
  transition: transform 0.25s ease;
}

.brand:hover .brand-mark {
  transform: scale(1.08) rotate(-3deg);
}

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

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

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

.site-nav {
  display: flex;
  align-items: center;
  gap: 22px;
  font-weight: 700;
}

.site-nav a {
  color: rgba(255, 255, 255, 0.92);
  transition: color 0.2s ease, transform 0.2s ease;
}

.site-nav a:hover {
  color: #fef3c7;
  transform: translateY(-1px);
}

.menu-toggle {
  display: none;
  width: 42px;
  height: 42px;
  padding: 9px;
  border: 0;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.12);
  cursor: pointer;
}

.menu-toggle span {
  display: block;
  height: 2px;
  margin: 5px 0;
  background: var(--white);
  border-radius: 999px;
}

.hero {
  position: relative;
  height: min(720px, 72vh);
  min-height: 520px;
  overflow: hidden;
  background: var(--stone-900);
}

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

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

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

.hero-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(12, 10, 9, 0.92), rgba(12, 10, 9, 0.45) 45%, rgba(12, 10, 9, 0.18)), radial-gradient(circle at 20% 70%, rgba(245, 158, 11, 0.32), transparent 34%);
}

.hero-copy {
  position: absolute;
  left: 50%;
  bottom: 88px;
  transform: translateX(-50%);
  color: var(--white);
}

.eyebrow {
  margin: 0 0 12px;
  color: #fed7aa;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.hero-copy h1,
.page-hero h1,
.detail-copy h1 {
  margin: 0;
  font-size: clamp(36px, 6vw, 68px);
  line-height: 1.04;
  letter-spacing: -0.04em;
}

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

.hero-actions,
.detail-tags,
.tag-row,
.filter-buttons,
.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.hero-actions {
  margin-top: 30px;
}

.btn,
.search-form button,
.filter-buttons button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 20px;
  border: 0;
  border-radius: 12px;
  font-weight: 800;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.btn:hover,
.search-form button:hover,
.filter-buttons button:hover {
  transform: translateY(-2px);
}

.btn.primary,
.search-form button {
  color: var(--white);
  background: linear-gradient(135deg, var(--amber-600), var(--orange-700));
  box-shadow: 0 12px 24px rgba(217, 119, 6, 0.3);
}

.btn.ghost {
  color: var(--white);
  background: rgba(255, 255, 255, 0.16);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.25);
  backdrop-filter: blur(12px);
}

.hero-arrow {
  position: absolute;
  top: 50%;
  z-index: 5;
  width: 48px;
  height: 48px;
  border: 0;
  border-radius: 999px;
  color: var(--white);
  background: rgba(255, 255, 255, 0.18);
  font-size: 42px;
  line-height: 1;
  cursor: pointer;
  backdrop-filter: blur(12px);
  transform: translateY(-50%);
  transition: background 0.2s ease, transform 0.2s ease;
}

.hero-arrow:hover {
  background: rgba(255, 255, 255, 0.28);
  transform: translateY(-50%) scale(1.06);
}

.hero-prev {
  left: 24px;
}

.hero-next {
  right: 24px;
}

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

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

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

.search-band {
  padding: 28px 0;
  background: linear-gradient(180deg, #fffbeb, var(--white));
}

.search-panel,
.filter-panel {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 24px;
  background: var(--white);
  border: 1px solid rgba(214, 211, 209, 0.9);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
}

.search-panel h2,
.search-panel p {
  margin: 0;
}

.search-panel p {
  margin-top: 6px;
  color: var(--stone-600);
}

.search-form {
  display: flex;
  width: min(520px, 100%);
  gap: 12px;
}

.search-form input,
.filter-search input {
  width: 100%;
  min-height: 48px;
  padding: 0 16px;
  border: 1px solid var(--stone-300);
  border-radius: 12px;
  color: var(--stone-800);
  background: var(--stone-50);
  outline: 0;
}

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

.section {
  padding: 72px 0;
}

.warm-section {
  background: linear-gradient(180deg, #fff7ed, var(--white));
}

.category-section {
  background: var(--white);
}

.split-section,
.related-section {
  background: linear-gradient(135deg, #fffbeb, #fff7ed 45%, #fafaf9);
}

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

.section-head h2 {
  margin: 0;
  color: var(--stone-900);
  font-size: clamp(26px, 3vw, 36px);
  letter-spacing: -0.03em;
}

.section-head p {
  margin: 8px 0 0;
  color: var(--stone-600);
}

.section-head a {
  color: var(--amber-700);
  font-weight: 800;
}

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

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

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

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

.card-link {
  display: flex;
  height: 100%;
  flex-direction: column;
  overflow: hidden;
  background: var(--white);
  border: 1px solid rgba(231, 229, 228, 0.92);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-card);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.card-link:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-soft);
}

.poster-frame {
  position: relative;
  aspect-ratio: 2 / 3;
  margin: 0;
  overflow: hidden;
  background: linear-gradient(135deg, var(--stone-200), var(--stone-100));
}

.featured-grid .poster-frame {
  aspect-ratio: 16 / 10;
}

.poster-frame img,
.category-tile img,
.category-card img,
.rank-item img,
.detail-cover img,
.player-poster img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.45s ease;
}

.card-link:hover .poster-frame img,
.category-tile:hover img,
.category-card:hover img {
  transform: scale(1.07);
}

.poster-frame::after,
.category-tile::after {
  position: absolute;
  inset: auto 0 0;
  height: 50%;
  content: "";
  background: linear-gradient(0deg, rgba(12, 10, 9, 0.74), transparent);
}

.poster-frame figcaption {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 2;
  padding: 5px 9px;
  color: var(--white);
  background: var(--amber-600);
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
}

.rank-badge {
  position: absolute;
  left: 10px;
  top: 10px;
  z-index: 2;
  display: grid;
  min-width: 34px;
  height: 34px;
  place-items: center;
  color: var(--white);
  background: rgba(12, 10, 9, 0.74);
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 999px;
  font-weight: 900;
}

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

.card-body h2 {
  display: -webkit-box;
  min-height: 2.8em;
  margin: 0;
  overflow: hidden;
  color: var(--stone-900);
  font-size: 17px;
  line-height: 1.4;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

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

.meta-row {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  margin-top: auto;
  color: var(--stone-500);
  font-size: 12px;
  font-weight: 700;
}

.tag-row span,
.detail-tags span {
  padding: 5px 8px;
  color: var(--stone-700);
  background: var(--stone-100);
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
}

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

.category-tile {
  position: relative;
  min-height: 210px;
  overflow: hidden;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
  background: var(--stone-900);
}

.category-tile span,
.category-tile p {
  position: absolute;
  z-index: 2;
  left: 22px;
  right: 22px;
  color: var(--white);
}

.category-tile span {
  bottom: 72px;
  font-size: 24px;
  font-weight: 900;
}

.category-tile p {
  bottom: 22px;
  margin: 0;
  color: rgba(255, 255, 255, 0.82);
  font-size: 14px;
  line-height: 1.5;
}

.split-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(340px, 0.92fr);
  gap: 34px;
}

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

.rank-item {
  display: grid;
  grid-template-columns: 42px 96px minmax(0, 1fr) auto;
  align-items: center;
  gap: 16px;
  padding: 12px;
  background: var(--white);
  border: 1px solid rgba(231, 229, 228, 0.9);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-card);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.rank-item:hover {
  transform: translateX(4px);
  box-shadow: var(--shadow-soft);
}

.rank-number {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  color: var(--white);
  background: linear-gradient(135deg, var(--amber-600), var(--orange-700));
  border-radius: 999px;
  font-weight: 900;
}

.rank-item img {
  aspect-ratio: 16 / 10;
  border-radius: 12px;
}

.rank-copy {
  display: grid;
  gap: 5px;
  min-width: 0;
}

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

.rank-copy em,
.rank-meta {
  color: var(--stone-500);
  font-size: 13px;
  font-style: normal;
}

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

.page-hero {
  color: var(--white);
  background: radial-gradient(circle at 15% 40%, rgba(245, 158, 11, 0.36), transparent 35%), linear-gradient(135deg, var(--stone-900), var(--stone-800));
}

.compact-hero {
  padding: 76px 0;
}

.compact-hero h1 {
  max-width: 820px;
}

.compact-hero p:not(.eyebrow) {
  max-width: 780px;
  margin: 18px 0 0;
  color: rgba(255, 255, 255, 0.82);
  font-size: 18px;
  line-height: 1.75;
}

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

.category-card {
  display: grid;
  gap: 16px;
  padding: 18px;
  background: var(--white);
  border: 1px solid rgba(231, 229, 228, 0.9);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

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

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

.category-thumbs img {
  aspect-ratio: 2 / 3;
  overflow: hidden;
  border-radius: 12px;
}

.category-card strong {
  color: var(--stone-900);
  font-size: 22px;
}

.category-card em {
  color: var(--stone-600);
  font-size: 14px;
  font-style: normal;
  line-height: 1.65;
}

.filter-panel {
  align-items: end;
  margin-bottom: 28px;
}

.filter-search {
  display: grid;
  flex: 1;
  gap: 8px;
  color: var(--stone-700);
  font-weight: 800;
}

.filter-buttons button {
  min-height: 40px;
  color: var(--stone-700);
  background: var(--stone-100);
}

.filter-buttons button.is-active {
  color: var(--white);
  background: linear-gradient(135deg, var(--amber-600), var(--orange-700));
}

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

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

.detail-hero {
  position: relative;
  overflow: hidden;
  color: var(--white);
  background: var(--stone-950);
}

.detail-backdrop {
  position: absolute;
  inset: 0;
  opacity: 0.28;
  filter: blur(2px);
}

.detail-hero::after {
  position: absolute;
  inset: 0;
  content: "";
  background: linear-gradient(90deg, rgba(12, 10, 9, 0.96), rgba(12, 10, 9, 0.72), rgba(12, 10, 9, 0.5));
}

.detail-top {
  position: relative;
  z-index: 2;
  padding: 34px 0 64px;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 30px;
  color: rgba(255, 255, 255, 0.72);
  font-size: 14px;
}

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

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

.detail-cover {
  margin: 0;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: var(--radius-lg);
  box-shadow: 0 28px 60px rgba(0, 0, 0, 0.38);
}

.detail-cover img {
  aspect-ratio: 2 / 3;
}

.detail-copy h1 {
  max-width: 850px;
}

.detail-one-line {
  max-width: 860px;
  margin: 22px 0 0;
  color: rgba(255, 255, 255, 0.84);
  font-size: 20px;
  line-height: 1.75;
}

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

.detail-tags span {
  color: #fed7aa;
  background: rgba(255, 255, 255, 0.12);
}

.detail-section {
  background: var(--stone-50);
}

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

.main-detail,
.side-detail {
  display: grid;
  gap: 22px;
  align-content: start;
}

.player-shell,
.text-card,
.info-card {
  overflow: hidden;
  background: var(--white);
  border: 1px solid rgba(231, 229, 228, 0.95);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
}

.player-stage {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #000000;
}

.movie-video {
  position: absolute;
  inset: 0;
  z-index: 1;
  width: 100%;
  height: 100%;
  background: #000000;
}

.player-poster {
  position: absolute;
  inset: 0;
  z-index: 3;
  display: grid;
  width: 100%;
  height: 100%;
  padding: 0;
  overflow: hidden;
  border: 0;
  color: var(--white);
  background: #000000;
  cursor: pointer;
  place-items: center;
}

.player-poster::after {
  position: absolute;
  inset: 0;
  content: "";
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.72), rgba(0, 0, 0, 0.18));
}

.player-poster.is-hidden {
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.22s ease;
}

.play-orb {
  position: absolute;
  z-index: 4;
  display: grid;
  width: 86px;
  height: 86px;
  place-items: center;
  padding-left: 6px;
  color: var(--white);
  background: linear-gradient(135deg, var(--amber-600), var(--orange-700));
  border: 4px solid rgba(255, 255, 255, 0.38);
  border-radius: 999px;
  font-size: 34px;
  box-shadow: 0 18px 38px rgba(217, 119, 6, 0.42);
}

.text-card,
.info-card {
  padding: 26px;
}

.text-card h2,
.info-card h2 {
  margin: 0 0 14px;
  color: var(--stone-900);
  font-size: 24px;
}

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

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

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

.info-card dd {
  margin: 0;
  color: var(--stone-800);
  line-height: 1.6;
}

.site-footer {
  color: var(--stone-300);
  background: linear-gradient(90deg, var(--stone-900), var(--stone-800), var(--stone-900));
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr;
  gap: 34px;
  padding: 46px 0;
}

.footer-brand {
  color: var(--white);
  font-size: 22px;
}

.site-footer p {
  max-width: 460px;
  color: var(--stone-300);
  line-height: 1.8;
}

.site-footer h2 {
  margin: 0 0 14px;
  color: var(--white);
  font-size: 18px;
}

.footer-links a {
  color: var(--stone-300);
  font-size: 14px;
}

.footer-links a:hover {
  color: #fbbf24;
}

@media (max-width: 1080px) {
  .featured-grid,
  .poster-grid,
  .listing-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

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

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

@media (max-width: 840px) {
  .header-inner {
    min-height: 62px;
  }

  .menu-toggle {
    display: block;
  }

  .site-nav {
    position: absolute;
    top: 62px;
    left: 16px;
    right: 16px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 4px;
    padding: 14px;
    background: rgba(180, 83, 9, 0.98);
    border-radius: 16px;
    box-shadow: var(--shadow-soft);
  }

  .site-nav.is-open {
    display: flex;
  }

  .site-nav a {
    padding: 11px 12px;
    border-radius: 10px;
  }

  .site-nav a:hover {
    background: rgba(255, 255, 255, 0.12);
    transform: none;
  }

  .hero {
    height: 70vh;
    min-height: 560px;
  }

  .hero-copy {
    bottom: 78px;
  }

  .hero-copy p {
    -webkit-line-clamp: 4;
    display: -webkit-box;
    overflow: hidden;
    -webkit-box-orient: vertical;
  }

  .hero-arrow {
    display: none;
  }

  .search-panel,
  .filter-panel {
    align-items: stretch;
    flex-direction: column;
  }

  .search-form {
    width: 100%;
  }

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

  .detail-cover {
    width: min(240px, 70vw);
  }

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

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

  .brand-text em {
    display: none;
  }

  .hero-copy h1,
  .page-hero h1,
  .detail-copy h1 {
    font-size: 36px;
  }

  .section {
    padding: 48px 0;
  }

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

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

  .card-body {
    padding: 12px;
  }

  .card-body h2 {
    font-size: 15px;
  }

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

  .category-tile {
    min-height: 180px;
  }

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

  .rank-meta {
    display: none;
  }

  .compact-hero {
    padding: 54px 0;
  }

  .detail-top {
    padding-bottom: 42px;
  }

  .text-card,
  .info-card {
    padding: 20px;
  }
}
