:root {
  --canyon-50: #faf8f5;
  --canyon-100: #f5f0e8;
  --canyon-200: #e8dbc8;
  --canyon-500: #b8895a;
  --canyon-600: #a6714a;
  --canyon-700: #8a5c3f;
  --canyon-800: #704c37;
  --canyon-900: #5c3f2f;
  --earth-600: #7a6752;
  --earth-700: #655545;
  --earth-800: #56483c;
  --earth-900: #4a3e34;
  --forest-50: #f4f6f4;
  --forest-100: #e5eae5;
  --forest-600: #4a5e4d;
  --forest-700: #3d4d40;
  --gold-300: #ffdf8f;
  --gold-400: #ffc94a;
  --gold-500: #ffb41e;
  --gold-600: #f09200;
  --sand-50: #fdfcfa;
  --sand-100: #faf7f0;
  --sand-200: #f5eedd;
  --sand-700: #b88a51;
  --text: #2f261f;
  --muted: #7a6752;
  --white: #ffffff;
  --shadow: 0 10px 30px rgba(138, 92, 63, 0.12);
  --shadow-soft: 0 4px 12px rgba(138, 92, 63, 0.1);
  --radius: 22px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: Inter, "Noto Sans SC", "Microsoft YaHei", system-ui, sans-serif;
  color: var(--text);
  background: linear-gradient(135deg, var(--canyon-50), var(--white) 48%, var(--sand-50));
  line-height: 1.6;
}

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

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

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(--canyon-800), var(--earth-800));
  box-shadow: 0 10px 24px rgba(92, 63, 47, 0.18);
}

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

.logo,
.footer-logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  letter-spacing: 0.03em;
  white-space: nowrap;
}

.logo {
  font-size: clamp(20px, 2.4vw, 28px);
}

.logo-mark {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  color: var(--canyon-900);
  background: linear-gradient(135deg, var(--gold-400), var(--gold-600));
  box-shadow: 0 8px 20px rgba(255, 180, 30, 0.28);
}

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

.desktop-nav a,
.mobile-panel a,
.footer-links a {
  transition: color 0.2s ease, transform 0.2s ease;
}

.desktop-nav a:hover,
.mobile-panel a:hover,
.footer-links a:hover {
  color: var(--gold-300);
}

.search-form,
.mobile-search,
.large-search {
  display: flex;
  align-items: center;
  gap: 8px;
}

.search-form input,
.mobile-search input {
  width: 220px;
  padding: 10px 14px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 999px;
  color: var(--white);
  background: rgba(255, 255, 255, 0.1);
  outline: none;
}

.search-form input::placeholder,
.mobile-search input::placeholder {
  color: rgba(255, 255, 255, 0.65);
}

.search-form button,
.mobile-search button,
.large-search button {
  border: 0;
  border-radius: 999px;
  padding: 10px 16px;
  font-weight: 700;
  color: var(--canyon-900);
  background: var(--gold-500);
  cursor: pointer;
}

.mobile-toggle {
  display: none;
  margin-left: auto;
  border: 0;
  color: var(--white);
  font-size: 28px;
  cursor: pointer;
  background: transparent;
}

.mobile-panel {
  display: none;
  padding: 0 16px 18px;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
}

.mobile-panel.is-open {
  display: grid;
  gap: 14px;
}

.hero-carousel {
  position: relative;
  height: clamp(500px, 68vh, 650px);
  overflow: hidden;
  background: var(--earth-900);
}

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

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

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

.hero-overlay,
.detail-mask {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(0deg, rgba(0, 0, 0, 0.86), rgba(0, 0, 0, 0.2) 55%, rgba(0, 0, 0, 0.14)),
    radial-gradient(circle at 20% 80%, rgba(255, 180, 30, 0.24), transparent 34%);
}

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

.hero-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 13px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 999px;
  color: var(--gold-300);
  background: rgba(0, 0, 0, 0.32);
  backdrop-filter: blur(10px);
  font-weight: 700;
}

.hero-content h1,
.detail-info h1 {
  max-width: 850px;
  margin: 18px 0 16px;
  font-size: clamp(36px, 6vw, 68px);
  line-height: 1.08;
}

.hero-content p,
.detail-info p {
  max-width: 760px;
  margin: 0 0 26px;
  color: rgba(255, 255, 255, 0.9);
  font-size: clamp(17px, 2.2vw, 22px);
}

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

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

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

.btn-primary {
  color: var(--canyon-900);
  background: linear-gradient(135deg, var(--gold-400), var(--gold-600));
  box-shadow: 0 12px 22px rgba(255, 180, 30, 0.28);
}

.btn-glass {
  color: var(--white);
  border: 1px solid rgba(255, 255, 255, 0.22);
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(12px);
}

.hero-arrow {
  position: absolute;
  top: 50%;
  z-index: 3;
  width: 48px;
  height: 48px;
  border: 0;
  border-radius: 50%;
  color: var(--white);
  background: rgba(0, 0, 0, 0.48);
  font-size: 36px;
  line-height: 1;
  cursor: pointer;
  transition: background 0.2s ease, transform 0.2s ease;
}

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

.hero-prev {
  left: 18px;
  transform: translateY(-50%);
}

.hero-next {
  right: 18px;
  transform: translateY(-50%);
}

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

.hero-dot {
  width: 12px;
  height: 12px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.52);
  cursor: pointer;
  transition: width 0.25s ease, background 0.25s ease;
}

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

.content-section {
  padding: 54px 0 10px;
}

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

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

.section-heading h2 {
  margin: 0;
  color: var(--canyon-900);
  font-size: clamp(26px, 3vw, 36px);
  line-height: 1.15;
}

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

.section-more {
  color: var(--gold-600);
  font-weight: 800;
}

.horizontal-row {
  display: flex;
  gap: 22px;
  margin: 0 -16px;
  padding: 4px 16px 22px;
  overflow-x: auto;
  scroll-snap-type: x proximity;
}

.horizontal-row .movie-card {
  width: 290px;
  flex: 0 0 290px;
  scroll-snap-align: start;
}

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

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

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

.movie-card {
  position: relative;
  display: block;
  overflow: hidden;
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: var(--shadow-soft);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

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

.poster {
  position: relative;
  display: block;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: var(--canyon-100);
}

.movie-card-small .poster {
  aspect-ratio: 3 / 4;
}

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

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

.poster-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.64), transparent 54%);
  opacity: 0;
  transition: opacity 0.25s ease;
}

.movie-card:hover .poster-shade {
  opacity: 1;
}

.play-dot,
.big-play {
  position: absolute;
  left: 50%;
  top: 50%;
  display: grid;
  place-items: center;
  color: var(--white);
  background: var(--gold-500);
  border-radius: 50%;
  transform: translate(-50%, -50%) scale(0.9);
  opacity: 0;
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.play-dot {
  width: 54px;
  height: 54px;
  font-size: 20px;
}

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

.year-badge,
.rank-badge {
  position: absolute;
  top: 12px;
  z-index: 2;
  padding: 5px 10px;
  border-radius: 999px;
  color: var(--white);
  font-size: 12px;
  font-weight: 800;
  background: rgba(0, 0, 0, 0.62);
  backdrop-filter: blur(10px);
}

.year-badge {
  right: 12px;
}

.rank-badge {
  left: 12px;
  background: linear-gradient(135deg, var(--gold-400), var(--gold-600));
}

.card-body {
  display: block;
  padding: 16px;
}

.card-body strong {
  display: -webkit-box;
  min-height: 3em;
  overflow: hidden;
  color: var(--canyon-900);
  font-size: 17px;
  line-height: 1.48;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.movie-card-small .card-body strong {
  min-height: 2.8em;
  font-size: 15px;
}

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

.meta-row,
.tag-row,
.detail-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.meta-row {
  justify-content: space-between;
  color: var(--earth-600);
  font-size: 13px;
}

.meta-row span:first-child,
.tag-row span,
.detail-tags span {
  padding: 4px 9px;
  border-radius: 999px;
  color: var(--forest-700);
  background: var(--forest-100);
  font-size: 12px;
  font-weight: 700;
}

.tag-row {
  margin-top: 10px;
}

.tag-row span {
  color: var(--canyon-700);
  background: var(--canyon-100);
}

.category-panel,
.year-panel {
  margin-top: 42px;
  padding: 34px;
  border-radius: 30px;
  background: linear-gradient(135deg, var(--forest-50), var(--canyon-50));
}

.category-grid {
  display: grid;
  gap: 30px;
}

.category-strip-title {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 15px;
}

.category-strip-title h3,
.year-block h3 {
  margin: 0;
  color: var(--forest-700);
  font-size: 22px;
}

.category-strip-title a {
  color: var(--gold-600);
  font-weight: 800;
}

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

.year-block {
  padding-left: 18px;
  border-left: 4px solid var(--gold-500);
}

.year-list {
  display: grid;
  gap: 16px;
  margin-top: 16px;
}

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

.latest-item {
  display: grid;
  grid-template-columns: 190px 1fr;
  gap: 18px;
  padding: 16px;
  border-radius: 18px;
  background: var(--white);
  box-shadow: var(--shadow-soft);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

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

.latest-item img {
  width: 190px;
  height: 116px;
  border-radius: 14px;
  object-fit: cover;
}

.latest-item strong,
.latest-item em,
.latest-item b {
  display: block;
}

.latest-item strong {
  color: var(--canyon-900);
  font-size: 20px;
}

.latest-item em {
  margin: 8px 0;
  color: var(--earth-600);
  font-style: normal;
}

.latest-item b {
  color: var(--forest-700);
  font-size: 13px;
}

.page-main {
  padding: 38px 0 70px;
}

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

.breadcrumb.light {
  color: rgba(255, 255, 255, 0.82);
}

.breadcrumb a:hover {
  color: var(--gold-600);
}

.page-title {
  margin-bottom: 30px;
  padding: 34px;
  border-radius: 28px;
  background: linear-gradient(135deg, var(--white), var(--canyon-50));
  box-shadow: var(--shadow-soft);
}

.page-title span {
  color: var(--gold-600);
  font-weight: 900;
}

.page-title h1 {
  margin: 8px 0 8px;
  color: var(--canyon-900);
  font-size: clamp(32px, 5vw, 52px);
  line-height: 1.1;
}

.page-title p {
  margin: 0;
  color: var(--earth-600);
  font-size: 18px;
}

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

.category-overview-card {
  display: block;
  position: relative;
  overflow: hidden;
  padding: 28px;
  border-radius: 28px;
  background: linear-gradient(135deg, var(--white), var(--sand-50));
  box-shadow: var(--shadow-soft);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

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

.category-count {
  position: absolute;
  right: 24px;
  top: 20px;
  color: var(--gold-600);
  font-size: 28px;
  font-weight: 900;
}

.category-overview-card h2 {
  margin: 0 0 8px;
  color: var(--canyon-900);
  font-size: 28px;
}

.category-overview-card p {
  margin: 0 0 18px;
  color: var(--earth-600);
}

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

.category-samples .movie-card {
  pointer-events: none;
}

.category-samples .card-body {
  display: none;
}

.filter-box,
.search-panel {
  margin-bottom: 30px;
  padding: 20px;
  border-radius: 22px;
  background: var(--white);
  box-shadow: var(--shadow-soft);
}

.local-filter,
.large-search input {
  width: 100%;
  padding: 14px 16px;
  border: 1px solid var(--canyon-200);
  border-radius: 16px;
  outline: none;
  color: var(--text);
  background: var(--sand-50);
}

.local-filter:focus,
.large-search input:focus {
  border-color: var(--gold-400);
  box-shadow: 0 0 0 4px rgba(255, 201, 74, 0.18);
}

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

.filter-chips button {
  border: 0;
  border-radius: 999px;
  padding: 8px 13px;
  color: var(--forest-700);
  background: var(--forest-100);
  cursor: pointer;
}

.filter-item.is-hidden {
  display: none;
}

.detail-hero {
  position: relative;
  min-height: 620px;
  overflow: hidden;
  color: var(--white);
  background: var(--earth-900);
}

.detail-bg {
  position: absolute;
  inset: 0;
  filter: blur(1px);
  transform: scale(1.02);
}

.detail-hero-inner {
  position: relative;
  z-index: 2;
  padding: 34px 0 56px;
}

.detail-layout {
  display: grid;
  grid-template-columns: 300px 1fr;
  gap: 36px;
  align-items: end;
  margin-top: 40px;
}

.detail-poster {
  width: 300px;
  aspect-ratio: 3 / 4;
  border: 6px solid rgba(255, 255, 255, 0.18);
  border-radius: 28px;
  object-fit: cover;
  box-shadow: 0 30px 60px rgba(0, 0, 0, 0.35);
}

.detail-info h1 {
  font-size: clamp(36px, 5vw, 64px);
}

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

.detail-tags span {
  color: var(--white);
  background: rgba(255, 255, 255, 0.16);
  backdrop-filter: blur(8px);
}

.player-section {
  margin-top: -56px;
  position: relative;
  z-index: 5;
}

.player-shell {
  position: relative;
  overflow: hidden;
  border-radius: 28px;
  background: #000;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.28);
  aspect-ratio: 16 / 9;
}

.player-shell video,
.player-cover,
.player-cover img {
  width: 100%;
  height: 100%;
}

.player-shell video {
  display: block;
  background: #000;
}

.player-cover {
  position: absolute;
  inset: 0;
  border: 0;
  padding: 0;
  cursor: pointer;
  background: #000;
}

.player-cover img {
  object-fit: cover;
}

.player-cover-mask {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.42);
}

.big-play {
  width: 88px;
  height: 88px;
  opacity: 1;
  font-size: 34px;
  box-shadow: 0 16px 32px rgba(255, 180, 30, 0.28);
}

.player-shell.is-playing .player-cover {
  display: none;
}

.detail-content-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 310px;
  gap: 26px;
  padding-top: 42px;
}

.detail-article,
.detail-side {
  border-radius: 24px;
  background: var(--white);
  box-shadow: var(--shadow-soft);
}

.detail-article {
  padding: 30px;
}

.detail-article h2,
.detail-side h2 {
  margin: 0 0 16px;
  color: var(--canyon-900);
  font-size: 26px;
}

.detail-article p {
  margin: 0 0 16px;
  color: var(--earth-700);
  font-size: 17px;
}

.detail-side {
  align-self: start;
  padding: 26px;
}

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

.detail-side dt {
  color: var(--canyon-700);
  font-weight: 900;
}

.detail-side dd {
  margin: 0;
  color: var(--earth-700);
}

.large-search {
  display: grid;
  grid-template-columns: 1fr auto;
}

.large-search input {
  border-radius: 999px;
}

.search-summary {
  min-height: 1.5em;
  margin: 14px 0 0;
  color: var(--earth-600);
  font-weight: 700;
}

.site-footer {
  margin-top: 60px;
  color: rgba(255, 255, 255, 0.82);
  background: linear-gradient(90deg, var(--canyon-900), var(--earth-900));
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  gap: 30px;
  padding: 34px 0;
}

.footer-logo {
  color: var(--gold-300);
  font-size: 22px;
}

.site-footer p {
  margin: 8px 0 0;
}

.footer-links {
  display: flex;
  gap: 18px;
  align-items: center;
  font-weight: 700;
}

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

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

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

  .mobile-toggle {
    display: block;
  }
}

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

  .header-inner {
    height: 66px;
  }

  .hero-carousel {
    height: 560px;
  }

  .hero-content {
    bottom: 82px;
  }

  .hero-arrow {
    display: none;
  }

  .movie-grid,
  .ranking-grid,
  .category-overview-grid,
  .year-columns,
  .detail-content-grid,
  .detail-layout {
    grid-template-columns: 1fr;
  }

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

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

  .detail-poster {
    width: min(260px, 70vw);
  }

  .latest-item {
    grid-template-columns: 1fr;
  }

  .latest-item img {
    width: 100%;
    height: 210px;
  }

  .footer-inner {
    flex-direction: column;
  }
}

@media (max-width: 520px) {
  .page-title,
  .category-panel,
  .year-panel {
    padding: 22px;
    border-radius: 22px;
  }

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

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

  .horizontal-row .movie-card {
    width: 250px;
    flex-basis: 250px;
  }

  .card-body {
    padding: 13px;
  }

  .large-search {
    grid-template-columns: 1fr;
  }
}
