:root {
  --cream-50: #fefdfb;
  --cream-100: #fdf9f3;
  --cream-200: #f8efd9;
  --cream-300: #f5e8d0;
  --coffee-50: #faf8f5;
  --coffee-100: #efe7dc;
  --coffee-200: #d9c8ad;
  --coffee-300: #c7ac82;
  --coffee-400: #b89968;
  --coffee-500: #8b6f47;
  --coffee-600: #6f5536;
  --coffee-700: #54402a;
  --coffee-800: #3d2e1f;
  --coffee-900: #2a1f15;
  --white: #ffffff;
  --black: #070504;
  --shadow-soft: 0 18px 50px rgba(42, 31, 21, 0.12);
  --shadow-card: 0 12px 30px rgba(42, 31, 21, 0.10);
  --radius-lg: 24px;
  --radius-md: 18px;
  --radius-sm: 12px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--cream-50);
  color: var(--coffee-900);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
  line-height: 1.6;
}

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

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

button,
input,
select {
  font: inherit;
}

button {
  border: 0;
  cursor: pointer;
}

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

.section-padding {
  padding: 72px 0;
}

.bg-white {
  background: var(--white);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(254, 253, 251, 0.92);
  border-bottom: 1px solid rgba(111, 85, 54, 0.12);
  backdrop-filter: blur(18px);
}

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

.brand,
.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-width: max-content;
}

.brand-mark {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--coffee-700), var(--coffee-400));
  color: var(--cream-50);
  font-weight: 800;
  box-shadow: 0 12px 24px rgba(84, 64, 42, 0.18);
}

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

.brand-name {
  color: var(--coffee-800);
  font-size: 21px;
  font-weight: 800;
  letter-spacing: 0.02em;
}

.brand-subtitle {
  margin-top: 4px;
  color: var(--coffee-500);
  font-size: 12px;
}

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

.nav-link,
.mobile-link {
  border-radius: 999px;
  color: var(--coffee-600);
  font-weight: 650;
  transition: background 0.25s ease, color 0.25s ease;
}

.nav-link {
  padding: 9px 16px;
  font-size: 14px;
}

.nav-link:hover,
.nav-link.is-active,
.mobile-link:hover,
.mobile-link.is-active {
  background: var(--coffee-100);
  color: var(--coffee-800);
}

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

.header-search input,
.mobile-search input,
.filter-panel input,
.filter-panel select {
  border: 1px solid rgba(111, 85, 54, 0.18);
  outline: 0;
  background: var(--cream-100);
  color: var(--coffee-800);
  transition: box-shadow 0.25s ease, border-color 0.25s ease, background 0.25s ease;
}

.header-search input {
  width: 240px;
  height: 42px;
  padding: 0 16px;
  border-radius: 999px;
}

.header-search button,
.mobile-search button,
.clear-filters {
  height: 42px;
  padding: 0 18px;
  border-radius: 999px;
  background: var(--coffee-600);
  color: var(--white);
  font-weight: 700;
  box-shadow: 0 10px 22px rgba(111, 85, 54, 0.18);
}

.header-search input:focus,
.mobile-search input:focus,
.filter-panel input:focus,
.filter-panel select:focus {
  border-color: rgba(139, 111, 71, 0.7);
  background: var(--white);
  box-shadow: 0 0 0 4px rgba(139, 111, 71, 0.12);
}

.menu-toggle {
  display: none;
  width: 44px;
  height: 44px;
  margin-left: auto;
  border-radius: 14px;
  background: var(--cream-100);
}

.menu-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  margin: 4px auto;
  border-radius: 999px;
  background: var(--coffee-700);
}

.mobile-panel {
  display: none;
  padding: 0 16px 18px;
  border-top: 1px solid rgba(111, 85, 54, 0.12);
  background: var(--cream-50);
}

.mobile-link {
  display: block;
  padding: 12px 16px;
}

.mobile-search {
  display: flex;
  gap: 10px;
  margin-top: 10px;
}

.mobile-search input {
  min-width: 0;
  flex: 1;
  height: 44px;
  padding: 0 14px;
  border-radius: 14px;
}

.hero {
  position: relative;
  height: min(80vh, 760px);
  min-height: 520px;
  overflow: hidden;
  background: var(--coffee-900);
}

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

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

.hero-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.03);
}

.hero-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(42, 31, 21, 0.98) 0%, rgba(42, 31, 21, 0.62) 46%, rgba(42, 31, 21, 0.16) 100%);
}

.hero-content {
  position: relative;
  z-index: 2;
  height: 100%;
  display: flex;
  align-items: flex-end;
  padding-bottom: 88px;
}

.hero-copy {
  width: min(720px, 100%);
  color: var(--white);
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 16px;
  color: var(--cream-200);
  font-weight: 700;
  letter-spacing: 0.08em;
}

.eyebrow::before {
  content: "";
  width: 24px;
  height: 2px;
  border-radius: 999px;
  background: var(--cream-200);
}

.hero h1,
.page-title h1,
.detail-title h1 {
  margin: 0;
  font-size: clamp(36px, 7vw, 72px);
  line-height: 1.06;
  letter-spacing: -0.04em;
}

.hero p {
  max-width: 650px;
  margin: 18px 0 0;
  color: var(--cream-100);
  font-size: 18px;
}

.hero-meta,
.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}

.hero-meta span,
.detail-meta span {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 6px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.14);
  color: var(--cream-50);
  font-size: 13px;
  font-weight: 700;
}

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

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

.btn-primary {
  background: var(--cream-50);
  color: var(--coffee-800);
  box-shadow: 0 18px 36px rgba(0, 0, 0, 0.18);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.16);
  color: var(--white);
  border: 1px solid rgba(255, 255, 255, 0.26);
}

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

.hero-control {
  position: absolute;
  top: 50%;
  z-index: 3;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.18);
  color: var(--white);
  font-size: 28px;
  backdrop-filter: blur(12px);
  transform: translateY(-50%);
}

.hero-control.prev {
  left: 24px;
}

.hero-control.next {
  right: 24px;
}

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

.hero-dot {
  width: 18px;
  height: 5px;
  padding: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.45);
  transition: width 0.25s ease, background 0.25s ease;
}

.hero-dot.is-active {
  width: 36px;
  background: var(--white);
}

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

.section-head h2,
.page-title h1,
.detail-title h1 {
  color: var(--coffee-900);
}

.section-head h2 {
  margin: 0;
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1.15;
  letter-spacing: -0.03em;
}

.section-head p,
.page-title p {
  max-width: 720px;
  margin: 10px 0 0;
  color: var(--coffee-600);
}

.section-link {
  color: var(--coffee-600);
  font-weight: 800;
}

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

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

.movie-card {
  overflow: hidden;
  border-radius: var(--radius-md);
  background: var(--white);
  box-shadow: var(--shadow-card);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

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

.movie-card-link {
  display: block;
  height: 100%;
}

.movie-poster {
  position: relative;
  height: 260px;
  overflow: hidden;
  background: var(--coffee-200);
}

.movie-card.compact .movie-poster {
  height: 210px;
}

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

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

.poster-badge,
.rank-badge {
  position: absolute;
  top: 12px;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 26px;
  padding: 3px 9px;
  border-radius: 999px;
  color: var(--white);
  font-size: 12px;
  font-weight: 800;
  background: rgba(0, 0, 0, 0.62);
  backdrop-filter: blur(10px);
}

.poster-badge {
  right: 12px;
}

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

.poster-play {
  position: absolute;
  left: 50%;
  top: 50%;
  display: grid;
  width: 58px;
  height: 58px;
  place-items: center;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.88);
  color: var(--coffee-800);
  font-weight: 900;
  opacity: 0;
  transform: translate(-50%, -50%) scale(0.8);
  transition: opacity 0.25s ease, transform 0.25s ease;
}

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

.movie-info {
  padding: 18px;
}

.movie-info h3 {
  min-height: 52px;
  margin: 0 0 10px;
  color: var(--coffee-900);
  font-size: 18px;
  line-height: 1.45;
  display: -webkit-box;
  overflow: hidden;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.movie-info p {
  min-height: 45px;
  margin: 0 0 14px;
  color: var(--coffee-600);
  font-size: 14px;
  display: -webkit-box;
  overflow: hidden;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.movie-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
  color: var(--coffee-500);
  font-size: 13px;
  font-weight: 800;
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.tag-row span {
  padding: 3px 9px;
  border-radius: 999px;
  background: var(--cream-200);
  color: var(--coffee-700);
  font-size: 12px;
  font-weight: 750;
}

.scroll-row {
  overflow-x: auto;
  padding: 4px 0 14px;
}

.scroll-row .movie-grid {
  display: flex;
  min-width: max-content;
}

.scroll-row .movie-card {
  width: 242px;
  flex: 0 0 auto;
}

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

.category-card {
  position: relative;
  min-height: 170px;
  overflow: hidden;
  border-radius: var(--radius-md);
  padding: 22px;
  background: linear-gradient(135deg, var(--cream-100), var(--coffee-100));
  box-shadow: var(--shadow-card);
}

.category-card::after {
  content: "";
  position: absolute;
  right: -40px;
  bottom: -44px;
  width: 132px;
  height: 132px;
  border-radius: 50%;
  background: rgba(111, 85, 54, 0.12);
}

.category-card h3 {
  position: relative;
  z-index: 1;
  margin: 0 0 10px;
  color: var(--coffee-900);
  font-size: 22px;
}

.category-card p {
  position: relative;
  z-index: 1;
  margin: 0;
  color: var(--coffee-600);
  font-size: 14px;
}

.category-card span {
  position: relative;
  z-index: 1;
  display: inline-flex;
  margin-top: 20px;
  color: var(--coffee-700);
  font-weight: 800;
}

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

.rank-item {
  display: flex;
  gap: 14px;
  align-items: center;
  padding: 14px;
  border-radius: var(--radius-sm);
  background: var(--white);
  box-shadow: 0 8px 22px rgba(42, 31, 21, 0.08);
}

.rank-num {
  display: grid;
  width: 38px;
  height: 38px;
  flex: 0 0 auto;
  place-items: center;
  border-radius: 12px;
  background: var(--coffee-700);
  color: var(--white);
  font-weight: 900;
}

.rank-item img {
  width: 92px;
  height: 58px;
  flex: 0 0 auto;
  border-radius: 10px;
  object-fit: cover;
}

.rank-item h3 {
  margin: 0 0 4px;
  font-size: 16px;
  line-height: 1.35;
}

.rank-item p {
  margin: 0;
  color: var(--coffee-600);
  font-size: 13px;
}

.page-hero {
  padding: 64px 0 46px;
  background: radial-gradient(circle at 20% 0%, rgba(184, 153, 104, 0.26), transparent 36%), linear-gradient(135deg, var(--cream-100), var(--cream-50));
}

.page-title h1 {
  font-size: clamp(34px, 5vw, 58px);
}

.filter-panel {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 28px;
  padding: 18px;
  border-radius: var(--radius-md);
  background: var(--white);
  box-shadow: 0 10px 26px rgba(42, 31, 21, 0.08);
}

.filter-search-wrap {
  flex: 1;
  min-width: 220px;
}

.filter-panel input,
.filter-panel select {
  height: 46px;
  border-radius: 14px;
  padding: 0 14px;
}

.filter-panel input {
  width: 100%;
}

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

.empty-state {
  display: none;
  padding: 36px;
  border-radius: var(--radius-md);
  background: var(--cream-100);
  color: var(--coffee-600);
  text-align: center;
  font-weight: 800;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  align-items: center;
  margin-bottom: 24px;
  color: var(--coffee-500);
  font-size: 14px;
  font-weight: 700;
}

.breadcrumb a:hover {
  color: var(--coffee-800);
}

.breadcrumb em {
  font-style: normal;
  color: var(--coffee-300);
}

.detail-hero {
  position: relative;
  overflow: hidden;
  padding: 72px 0;
  background: var(--coffee-900);
  color: var(--white);
}

.detail-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(42, 31, 21, 0.95), rgba(42, 31, 21, 0.78), rgba(42, 31, 21, 0.38));
}

.detail-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.38;
  filter: blur(2px);
}

.detail-hero-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 320px minmax(0, 1fr);
  gap: 42px;
  align-items: center;
}

.detail-cover {
  overflow: hidden;
  border-radius: var(--radius-lg);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.32);
}

.detail-cover img {
  width: 100%;
  height: 440px;
  object-fit: cover;
}

.detail-title h1 {
  color: var(--white);
}

.detail-title p {
  max-width: 760px;
  margin: 18px 0 0;
  color: var(--cream-100);
  font-size: 18px;
}

.detail-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 20px;
}

.detail-tags span {
  padding: 6px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.15);
  color: var(--cream-50);
  font-size: 13px;
  font-weight: 750;
}

.player-section {
  background: var(--coffee-900);
  padding: 0 0 64px;
}

.player-box {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-lg);
  background: var(--black);
  box-shadow: 0 26px 70px rgba(0, 0, 0, 0.30);
}

.player-video {
  width: 100%;
  aspect-ratio: 16 / 9;
  background: var(--black);
}

.player-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.52), rgba(0, 0, 0, 0.12));
  color: var(--white);
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

.player-overlay span {
  display: grid;
  width: 86px;
  height: 86px;
  place-items: center;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.9);
  color: var(--coffee-800);
  font-size: 36px;
  box-shadow: 0 18px 46px rgba(0, 0, 0, 0.24);
}

.player-box.is-started .player-overlay {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

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

.content-card,
.info-card {
  border-radius: var(--radius-md);
  background: var(--white);
  box-shadow: var(--shadow-card);
}

.content-card {
  padding: 30px;
}

.content-card + .content-card {
  margin-top: 22px;
}

.content-card h2,
.info-card h2 {
  margin: 0 0 16px;
  color: var(--coffee-900);
  font-size: 24px;
}

.content-card p {
  margin: 0;
  color: var(--coffee-700);
  font-size: 17px;
}

.content-card p + p {
  margin-top: 14px;
}

.info-card {
  position: sticky;
  top: 102px;
  padding: 24px;
}

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

.info-list div {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--cream-200);
}

.info-list dt {
  color: var(--coffee-500);
}

.info-list dd {
  margin: 0;
  color: var(--coffee-900);
  font-weight: 800;
  text-align: right;
}

.site-footer {
  background: var(--coffee-800);
  color: var(--cream-100);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1.2fr;
  gap: 32px;
  padding: 58px 0;
}

.footer-brand {
  color: var(--cream-50);
  font-size: 20px;
  font-weight: 850;
}

.site-footer p {
  max-width: 360px;
  margin: 16px 0 0;
  color: var(--cream-300);
  font-size: 14px;
}

.site-footer h3 {
  margin: 0 0 14px;
  color: var(--cream-50);
  font-size: 16px;
}

.site-footer ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.site-footer li + li {
  margin-top: 9px;
}

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

.site-footer a:hover {
  color: var(--cream-50);
}

.footer-bottom {
  padding: 18px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  color: var(--cream-300);
  font-size: 13px;
  text-align: center;
}

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

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

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

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

  .menu-toggle {
    display: block;
  }

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

  .hero {
    min-height: 560px;
  }

  .hero-content {
    padding-bottom: 78px;
  }

  .hero-control {
    display: none;
  }

  .section-padding {
    padding: 52px 0;
  }

  .section-head {
    display: block;
  }

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

  .movie-poster,
  .movie-card.compact .movie-poster {
    height: 230px;
  }

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

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

  .filter-panel {
    display: block;
  }

  .filter-selects {
    margin-top: 12px;
  }

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

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

  .detail-cover img {
    height: 430px;
  }

  .info-card {
    position: static;
  }

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

@media (max-width: 560px) {
  .container-custom {
    width: min(100% - 24px, 1280px);
  }

  .header-inner {
    height: 68px;
    gap: 12px;
  }

  .brand-mark {
    width: 38px;
    height: 38px;
    border-radius: 12px;
  }

  .brand-name {
    font-size: 18px;
  }

  .brand-subtitle {
    display: none;
  }

  .hero {
    min-height: 540px;
  }

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

  .movie-grid,
  .movie-grid.compact-grid,
  .rank-grid,
  .category-strip {
    grid-template-columns: 1fr;
  }

  .movie-poster,
  .movie-card.compact .movie-poster {
    height: 300px;
  }

  .detail-hero {
    padding: 44px 0;
  }

  .detail-cover img {
    height: 390px;
  }

  .player-overlay span {
    width: 70px;
    height: 70px;
    font-size: 30px;
  }

  .content-card {
    padding: 22px;
  }

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