:root {
  --earth-950: #24170f;
  --earth-900: #33251c;
  --earth-800: #4d382a;
  --earth-700: #6c4f3b;
  --earth-600: #8a6650;
  --sand-50: #fffaf2;
  --sand-100: #fff0d4;
  --sand-200: #f8d7a4;
  --desert-50: #fff5ed;
  --desert-100: #ffe4cf;
  --desert-500: #d9823d;
  --desert-600: #c56d28;
  --desert-700: #a9541c;
  --dune-600: #8e6b37;
  --dune-700: #735425;
  --white: #ffffff;
  --soft-shadow: 0 20px 55px rgba(96, 64, 37, 0.14);
  --card-shadow: 0 10px 30px rgba(72, 46, 25, 0.12);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background: linear-gradient(180deg, var(--sand-50) 0%, #ffffff 52%, var(--desert-50) 100%);
  color: var(--earth-800);
  font-family: Inter, "Noto Sans SC", "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
}

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

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

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 250, 242, 0.88);
  border-bottom: 1px solid rgba(142, 107, 55, 0.15);
  backdrop-filter: blur(18px);
}

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

.brand,
.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 22px;
  font-weight: 900;
  color: var(--earth-900);
  letter-spacing: -0.03em;
}

.brand-mark {
  width: 42px;
  height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--desert-600), var(--dune-700));
  box-shadow: 0 12px 24px rgba(169, 84, 28, 0.24);
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 10px;
}

.site-nav a {
  padding: 10px 14px;
  border-radius: 999px;
  color: var(--earth-700);
  font-weight: 700;
  transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.site-nav a:hover,
.site-nav a.active {
  color: var(--earth-950);
  background: var(--sand-100);
  transform: translateY(-1px);
}

.nav-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 12px;
  background: var(--sand-100);
}

.nav-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  margin: 4px auto;
  background: var(--earth-800);
  border-radius: 4px;
}

.hero-section {
  position: relative;
  overflow: hidden;
  padding: 34px 0 54px;
}

.hero-shell {
  position: relative;
  min-height: 560px;
  border-radius: 34px;
  overflow: hidden;
  background: linear-gradient(135deg, var(--earth-950), var(--dune-700));
  box-shadow: var(--soft-shadow);
}

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

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

.hero-slide img.hero-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(1.08);
}

.hero-slide::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 72% 42%, rgba(255, 228, 207, 0.16), transparent 30%), linear-gradient(90deg, rgba(36, 23, 15, 0.92), rgba(51, 37, 28, 0.62), rgba(36, 23, 15, 0.22));
}

.hero-content {
  position: relative;
  z-index: 2;
  width: min(670px, 100%);
  padding: 74px 58px;
  color: #ffffff;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  border-radius: 999px;
  color: var(--sand-100);
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.18);
  font-size: 14px;
  font-weight: 800;
}

.hero-content h1,
.hero-content h2 {
  margin: 22px 0 18px;
  font-size: clamp(36px, 7vw, 72px);
  line-height: 0.98;
  letter-spacing: -0.06em;
  font-weight: 950;
}

.hero-content p {
  margin: 0 0 28px;
  color: rgba(255, 250, 242, 0.88);
  font-size: 18px;
  line-height: 1.85;
}

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

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 12px 18px;
  border: 0;
  border-radius: 14px;
  color: var(--earth-900);
  background: #ffffff;
  font-weight: 900;
  box-shadow: 0 14px 30px rgba(30, 18, 9, 0.18);
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.button:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 36px rgba(30, 18, 9, 0.24);
}

.button.primary {
  color: #ffffff;
  background: linear-gradient(135deg, var(--desert-600), var(--dune-700));
}

.button.ghost {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.22);
  box-shadow: none;
}

.hero-panel {
  position: absolute;
  right: 34px;
  bottom: 34px;
  z-index: 4;
  width: min(410px, calc(100% - 68px));
  padding: 20px;
  border-radius: 24px;
  background: rgba(255, 250, 242, 0.88);
  box-shadow: var(--soft-shadow);
  backdrop-filter: blur(18px);
}

.hero-panel h3 {
  margin: 0 0 14px;
  color: var(--earth-900);
  font-size: 18px;
  font-weight: 950;
}

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

.hero-mini-list a {
  display: grid;
  grid-template-columns: 54px 1fr;
  gap: 12px;
  align-items: center;
  padding: 8px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.62);
}

.hero-mini-list img {
  width: 54px;
  height: 68px;
  object-fit: cover;
  border-radius: 13px;
}

.hero-mini-list strong,
.compact-card strong {
  display: block;
  color: var(--earth-900);
  font-size: 15px;
  line-height: 1.35;
}

.hero-mini-list span,
.compact-card em {
  display: block;
  margin-top: 4px;
  color: var(--earth-600);
  font-size: 13px;
  font-style: normal;
  line-height: 1.45;
}

.hero-dots {
  position: absolute;
  left: 58px;
  bottom: 36px;
  z-index: 5;
  display: flex;
  gap: 10px;
}

.hero-dot {
  width: 12px;
  height: 12px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.42);
}

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

.search-band {
  position: relative;
  z-index: 6;
  margin-top: -26px;
}

.search-card {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 14px;
  align-items: center;
  padding: 18px;
  border-radius: 24px;
  background: #ffffff;
  box-shadow: var(--soft-shadow);
}

.search-card input,
.filter-input {
  width: 100%;
  height: 50px;
  padding: 0 18px;
  border: 1px solid rgba(142, 107, 55, 0.2);
  border-radius: 16px;
  color: var(--earth-900);
  background: var(--sand-50);
  outline: none;
  font-size: 15px;
}

.search-card input:focus,
.filter-input:focus {
  border-color: var(--desert-500);
  box-shadow: 0 0 0 4px rgba(217, 130, 61, 0.14);
}

main {
  display: block;
}

.section {
  padding: 58px 0;
}

.section.tight {
  padding-top: 28px;
}

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

.section-title h1,
.section-title h2 {
  margin: 0;
  color: var(--earth-900);
  font-size: clamp(28px, 4vw, 44px);
  line-height: 1.12;
  letter-spacing: -0.04em;
  font-weight: 950;
}

.section-title p {
  margin: 12px 0 0;
  max-width: 720px;
  color: var(--earth-600);
  font-size: 16px;
  line-height: 1.8;
}

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

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

.movie-card {
  position: relative;
  overflow: hidden;
  border-radius: 24px;
  background: #ffffff;
  box-shadow: var(--card-shadow);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.movie-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 18px 44px rgba(72, 46, 25, 0.18);
}

.poster-link {
  position: relative;
  display: block;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  background: var(--sand-100);
}

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

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

.poster-shade {
  position: absolute;
  inset: auto 0 0;
  height: 45%;
  background: linear-gradient(180deg, transparent, rgba(36, 23, 15, 0.54));
}

.rank-badge {
  position: absolute;
  left: 12px;
  top: 12px;
  z-index: 2;
  padding: 7px 10px;
  border-radius: 999px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--desert-600), var(--dune-700));
  font-size: 12px;
  letter-spacing: 0.02em;
}

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

.movie-meta-line {
  margin-bottom: 7px;
  color: var(--desert-700);
  font-size: 12px;
  font-weight: 900;
  line-height: 1.45;
}

.movie-card h3 {
  margin: 0;
  color: var(--earth-900);
  font-size: 18px;
  line-height: 1.35;
  font-weight: 950;
}

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

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

.tag-list span,
.meta-pill {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 5px 9px;
  border-radius: 999px;
  color: var(--earth-700);
  background: var(--sand-100);
  font-size: 12px;
  font-weight: 800;
}

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

.category-tile {
  min-height: 188px;
  padding: 24px;
  border-radius: 26px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--earth-800), var(--desert-600));
  box-shadow: var(--card-shadow);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.category-tile:nth-child(2n) {
  background: linear-gradient(135deg, var(--dune-700), var(--desert-500));
}

.category-tile:nth-child(3n) {
  background: linear-gradient(135deg, var(--earth-950), var(--earth-700));
}

.category-tile:hover {
  transform: translateY(-4px);
  box-shadow: 0 20px 48px rgba(72, 46, 25, 0.22);
}

.category-tile h2,
.category-tile h3 {
  margin: 0 0 10px;
  font-size: 22px;
  font-weight: 950;
}

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

.category-tile span {
  margin-top: 20px;
  font-weight: 900;
}

.feature-layout {
  display: grid;
  grid-template-columns: 1.4fr 0.8fr;
  gap: 22px;
  align-items: start;
}

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

.compact-card {
  display: grid;
  grid-template-columns: 42px 62px 1fr;
  gap: 12px;
  align-items: center;
  min-height: 86px;
  padding: 12px;
  border-radius: 20px;
  background: #ffffff;
  box-shadow: var(--card-shadow);
  transition: transform 0.2s ease;
}

.compact-card:hover {
  transform: translateX(4px);
}

.compact-card img {
  width: 62px;
  height: 76px;
  object-fit: cover;
  border-radius: 14px;
}

.compact-rank {
  display: inline-flex;
  width: 34px;
  height: 34px;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--desert-600), var(--dune-700));
  font-weight: 950;
  font-size: 13px;
}

.page-hero {
  padding: 54px 0 34px;
  background: radial-gradient(circle at top right, rgba(217, 130, 61, 0.18), transparent 32%), linear-gradient(180deg, var(--sand-50), #ffffff);
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-bottom: 22px;
  color: var(--earth-600);
  font-size: 14px;
}

.breadcrumb a {
  color: var(--desert-700);
  font-weight: 800;
}

.filter-bar {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 14px;
  margin: 22px 0 28px;
  padding: 18px;
  border-radius: 24px;
  background: #ffffff;
  box-shadow: var(--card-shadow);
}

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

.filter-chip {
  min-height: 40px;
  padding: 8px 14px;
  border: 1px solid rgba(142, 107, 55, 0.18);
  border-radius: 999px;
  color: var(--earth-700);
  background: #ffffff;
  font-weight: 800;
}

.filter-chip.active,
.filter-chip:hover {
  color: #ffffff;
  background: linear-gradient(135deg, var(--desert-600), var(--dune-700));
}

.no-results {
  display: none;
  padding: 30px;
  border-radius: 24px;
  text-align: center;
  color: var(--earth-600);
  background: #ffffff;
  box-shadow: var(--card-shadow);
}

.no-results.show {
  display: block;
}

.detail-wrap {
  padding: 42px 0 66px;
}

.detail-hero {
  display: grid;
  grid-template-columns: 340px 1fr;
  gap: 34px;
  align-items: center;
  padding: 28px;
  border-radius: 34px;
  background: linear-gradient(135deg, #ffffff, var(--sand-50));
  box-shadow: var(--soft-shadow);
}

.detail-cover {
  border-radius: 28px;
  overflow: hidden;
  box-shadow: 0 22px 48px rgba(72, 46, 25, 0.2);
}

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

.detail-info h1 {
  margin: 14px 0;
  color: var(--earth-900);
  font-size: clamp(34px, 5vw, 58px);
  line-height: 1.05;
  letter-spacing: -0.05em;
  font-weight: 950;
}

.detail-info p {
  color: var(--earth-600);
  font-size: 17px;
  line-height: 1.85;
}

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

.watch-panel {
  margin-top: 34px;
  border-radius: 30px;
  overflow: hidden;
  background: var(--earth-950);
  box-shadow: var(--soft-shadow);
}

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

.player-box video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  cursor: pointer;
}

.player-layer {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: radial-gradient(circle at center, rgba(255, 255, 255, 0.08), rgba(0, 0, 0, 0.32));
  cursor: pointer;
}

.watch-panel.is-playing .player-layer {
  display: none;
}

.player-start {
  width: 88px;
  height: 88px;
  border: 0;
  border-radius: 999px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--desert-600), var(--dune-700));
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.32);
  font-weight: 950;
  font-size: 16px;
}

.watch-caption {
  padding: 18px 22px;
  color: var(--sand-100);
  background: linear-gradient(135deg, var(--earth-950), var(--earth-800));
}

.watch-caption h2 {
  margin: 0;
  color: #ffffff;
  font-size: 22px;
  font-weight: 950;
}

.watch-caption p {
  margin: 8px 0 0;
  color: rgba(255, 250, 242, 0.74);
  line-height: 1.7;
}

.content-card {
  margin-top: 34px;
  padding: 30px;
  border-radius: 30px;
  background: #ffffff;
  box-shadow: var(--card-shadow);
}

.content-card h2 {
  margin: 0 0 16px;
  color: var(--earth-900);
  font-size: 28px;
  line-height: 1.2;
  font-weight: 950;
}

.content-card p {
  margin: 0 0 16px;
  color: var(--earth-700);
  line-height: 1.9;
  font-size: 16px;
}

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

.related-grid .movie-card h3 {
  font-size: 16px;
}

.related-grid .movie-card p {
  display: none;
}

.site-footer {
  padding: 46px 0;
  color: var(--sand-100);
  background: linear-gradient(135deg, var(--earth-950), var(--earth-800));
}

.footer-grid {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.footer-brand {
  color: #ffffff;
}

.site-footer p {
  margin: 10px 0 0;
  max-width: 650px;
  color: rgba(255, 250, 242, 0.72);
  line-height: 1.7;
}

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

.footer-links a {
  padding: 9px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.1);
  font-weight: 800;
}

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

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

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

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

  .detail-cover {
    max-width: 360px;
  }
}

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

  .nav-toggle {
    display: block;
  }

  .site-nav {
    position: absolute;
    left: 12px;
    right: 12px;
    top: 74px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    padding: 14px;
    border-radius: 22px;
    background: #ffffff;
    box-shadow: var(--soft-shadow);
  }

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

  .site-nav a {
    border-radius: 14px;
  }

  .hero-shell {
    min-height: 680px;
    border-radius: 24px;
  }

  .hero-content {
    padding: 42px 24px;
  }

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

  .hero-panel {
    right: 16px;
    left: 16px;
    bottom: 72px;
    width: auto;
  }

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

  .search-card,
  .filter-bar {
    grid-template-columns: 1fr;
  }

  .section-head,
  .footer-grid {
    display: block;
  }

  .section-actions,
  .footer-links {
    margin-top: 18px;
  }

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

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

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

  .detail-wrap {
    padding-top: 24px;
  }

  .detail-hero,
  .content-card {
    padding: 18px;
    border-radius: 24px;
  }

  .player-start {
    width: 72px;
    height: 72px;
    font-size: 14px;
  }
}

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

  .compact-card {
    grid-template-columns: 34px 56px 1fr;
  }
}
