:root {
  --brown-950: #3f2f1e;
  --brown-900: #5a442c;
  --brown-800: #6d5336;
  --brown-700: #8a6640;
  --brown-600: #a37d4d;
  --beige-50: #fdfbf7;
  --beige-100: #f9f5ed;
  --beige-200: #f1e7d2;
  --beige-300: #e7d9ba;
  --green-100: #eaf3e7;
  --green-700: #4a6e3b;
  --green-600: #5d8a49;
  --text: #1f2937;
  --muted: #667085;
  --line: rgba(109, 83, 54, 0.15);
  --shadow: 0 18px 45px rgba(63, 47, 30, 0.14);
  --radius: 18px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
  color: var(--text);
  background: linear-gradient(180deg, var(--beige-50), #ffffff 52%, var(--beige-100));
  -webkit-font-smoothing: antialiased;
}

body.nav-open {
  overflow: hidden;
}

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

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

button,
input,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 80;
  color: #ffffff;
  background: rgba(109, 83, 54, 0.96);
  box-shadow: 0 10px 30px rgba(63, 47, 30, 0.25);
  backdrop-filter: blur(14px);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  letter-spacing: 0.02em;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  padding-left: 2px;
  color: var(--brown-900);
  background: var(--beige-300);
  border-radius: 50%;
  box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.28);
}

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

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

.nav-link,
.mobile-link {
  color: var(--beige-100);
  font-weight: 600;
  transition: color 0.2s ease, transform 0.2s ease;
}

.nav-link:hover,
.nav-link.active,
.mobile-link:hover,
.mobile-link.active {
  color: #ffffff;
}

.nav-link:hover {
  transform: translateY(-1px);
}

.nav-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.1);
}

.nav-toggle span {
  display: block;
  width: 21px;
  height: 2px;
  margin: 5px auto;
  background: #ffffff;
  border-radius: 99px;
}

.mobile-nav {
  display: none;
  padding: 0 16px 18px;
  background: var(--brown-800);
}

.mobile-link {
  display: block;
  padding: 12px 0;
  border-top: 1px solid rgba(249, 245, 237, 0.14);
}

.hero {
  position: relative;
  height: 600px;
  overflow: hidden;
  background: var(--brown-900);
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transform: scale(1.02);
  transition: opacity 0.7s ease, transform 0.7s ease;
  pointer-events: none;
}

.hero-slide.is-active {
  opacity: 1;
  transform: scale(1);
  pointer-events: auto;
}

.hero-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.42;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 75% 30%, rgba(231, 217, 186, 0.26), transparent 28%),
    linear-gradient(90deg, rgba(63, 47, 30, 0.96), rgba(90, 68, 44, 0.75) 48%, rgba(90, 68, 44, 0.42));
}

.hero-content {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  min-height: 100%;
}

.hero-copy {
  width: min(660px, 100%);
  color: #ffffff;
}

.hero-kicker,
.section-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--beige-300);
  font-weight: 800;
  letter-spacing: 0.08em;
}

.hero h1 {
  margin: 16px 0 18px;
  font-size: clamp(42px, 6vw, 72px);
  line-height: 1.05;
  font-weight: 900;
  letter-spacing: -0.04em;
}

.hero p {
  max-width: 620px;
  margin: 0 0 26px;
  color: var(--beige-100);
  font-size: 20px;
  line-height: 1.75;
}

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

.hero-meta span,
.detail-meta span,
.detail-meta strong,
.tag-row span,
.tag-cloud span {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 700;
}

.hero-meta span {
  padding: 8px 13px;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(12px);
}

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

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 22px;
  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(--brown-900);
  background: var(--beige-300);
  box-shadow: 0 16px 35px rgba(231, 217, 186, 0.28);
}

.btn.ghost {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.14);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(12px);
}

.hero-search {
  display: flex;
  width: min(560px, 100%);
  padding: 8px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.16);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.18);
  backdrop-filter: blur(16px);
}

.hero-search input {
  flex: 1;
  min-width: 0;
  border: 0;
  outline: 0;
  color: #ffffff;
  background: transparent;
  padding: 0 16px;
}

.hero-search input::placeholder {
  color: rgba(255, 255, 255, 0.76);
}

.hero-search button {
  border: 0;
  border-radius: 999px;
  padding: 10px 20px;
  color: var(--brown-900);
  background: #ffffff;
  font-weight: 800;
}

.hero-control {
  position: absolute;
  top: 50%;
  z-index: 4;
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border: 0;
  border-radius: 50%;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.14);
  transform: translateY(-50%);
  backdrop-filter: blur(12px);
  transition: background 0.2s ease;
}

.hero-control:hover {
  background: rgba(255, 255, 255, 0.24);
}

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

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

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

.hero-dot {
  width: 10px;
  height: 10px;
  padding: 0;
  border: 0;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.45);
  transition: width 0.2s ease, background 0.2s ease;
}

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

.quick-categories {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
  margin-top: -42px;
  position: relative;
  z-index: 8;
}

.category-card,
.category-tile,
.movie-card,
.side-card,
.filter-panel,
.ranking-row {
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
}

.category-card {
  display: grid;
  gap: 14px;
  padding: 16px;
  border-radius: var(--radius);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.category-card:hover,
.category-tile:hover,
.movie-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 22px 55px rgba(63, 47, 30, 0.18);
}

.category-images,
.tile-covers {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
}

.category-images img,
.tile-covers img {
  width: 100%;
  height: 84px;
  border-radius: 12px;
  object-fit: cover;
  background: var(--beige-200);
}

.category-card strong,
.category-tile strong {
  color: var(--brown-800);
  font-size: 19px;
}

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

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

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

.section-head h2 {
  margin: 8px 0 8px;
  color: var(--brown-800);
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1.1;
  font-weight: 900;
  letter-spacing: -0.03em;
}

.section-head p {
  margin: 0;
  color: var(--muted);
  line-height: 1.75;
}

.section-more {
  flex: 0 0 auto;
  color: var(--brown-700);
  font-weight: 800;
}

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

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

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

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

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

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

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

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

.play-chip {
  position: absolute;
  inset: 50% auto auto 50%;
  display: grid;
  place-items: center;
  width: 50px;
  height: 50px;
  padding-left: 3px;
  color: var(--brown-900);
  background: rgba(255, 255, 255, 0.9);
  border-radius: 50%;
  opacity: 0;
  transform: translate(-50%, -50%) scale(0.86);
  transition: opacity 0.2s ease, transform 0.2s ease;
}

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

.year-chip,
.rank-badge {
  position: absolute;
  right: 10px;
  top: 10px;
  padding: 5px 9px;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(0, 0, 0, 0.68);
  font-size: 12px;
  font-weight: 800;
}

.card-body {
  padding: 16px;
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 10px;
}

.tag-row span:nth-child(1) {
  padding: 4px 9px;
  color: var(--brown-700);
  background: var(--beige-100);
}

.tag-row span:nth-child(2) {
  padding: 4px 9px;
  color: var(--green-700);
  background: var(--green-100);
}

.card-body h3 {
  margin: 0 0 9px;
  color: var(--brown-800);
  font-size: 18px;
  line-height: 1.35;
  font-weight: 900;
}

.card-body h3 a:hover {
  color: var(--brown-600);
}

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

.card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: #7a6f63;
  font-size: 14px;
}

.card-meta strong {
  color: var(--green-700);
}

.split-section {
  padding: 76px 0;
  background: linear-gradient(180deg, var(--beige-100), #ffffff);
}

.split-grid {
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: 40px;
  align-items: start;
}

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

.compact-card {
  display: flex;
  gap: 14px;
  padding: 12px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.9);
  transition: background 0.2s ease, transform 0.2s ease;
}

.compact-card:hover {
  background: var(--beige-50);
  transform: translateX(3px);
}

.compact-poster {
  position: relative;
  flex: 0 0 120px;
  height: 78px;
  overflow: hidden;
  border-radius: 12px;
  background: var(--beige-200);
}

.compact-poster img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.compact-info {
  display: grid;
  min-width: 0;
  gap: 4px;
}

.compact-info strong {
  overflow: hidden;
  color: var(--brown-800);
  font-weight: 900;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.compact-info small {
  color: #807568;
}

.compact-info em {
  display: -webkit-box;
  overflow: hidden;
  color: var(--muted);
  font-size: 13px;
  font-style: normal;
  line-height: 1.5;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.page-main {
  min-height: 60vh;
}

.page-hero {
  color: #ffffff;
  background:
    radial-gradient(circle at 78% 20%, rgba(231, 217, 186, 0.24), transparent 28%),
    linear-gradient(135deg, var(--brown-950), var(--brown-800));
}

.compact-hero {
  padding: 74px 0 82px;
}

.compact-hero h1 {
  max-width: 850px;
  margin: 14px 0 16px;
  font-size: clamp(36px, 5vw, 58px);
  line-height: 1.1;
  font-weight: 900;
  letter-spacing: -0.04em;
}

.compact-hero p {
  max-width: 720px;
  margin: 0;
  color: var(--beige-100);
  font-size: 18px;
  line-height: 1.75;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 24px;
  color: var(--brown-700);
  font-size: 14px;
  font-weight: 700;
}

.breadcrumb.dark {
  color: var(--beige-200);
}

.breadcrumb a:hover {
  text-decoration: underline;
}

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

.category-tile {
  display: grid;
  gap: 16px;
  padding: 18px;
  border-radius: var(--radius);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.tile-covers {
  grid-template-columns: repeat(2, 1fr);
}

.tile-covers img {
  height: 110px;
}

.tile-content {
  display: grid;
  gap: 8px;
}

.filter-panel {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) 170px 170px auto;
  gap: 14px;
  align-items: end;
  margin-bottom: 28px;
  padding: 18px;
  border-radius: var(--radius);
}

.filter-field {
  display: grid;
  gap: 8px;
}

.filter-field span {
  color: var(--brown-700);
  font-size: 13px;
  font-weight: 800;
}

.filter-field input,
.filter-field select {
  width: 100%;
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: 12px;
  outline: 0;
  padding: 0 13px;
  color: var(--text);
  background: #ffffff;
}

.filter-field input:focus,
.filter-field select:focus {
  border-color: var(--brown-600);
  box-shadow: 0 0 0 4px rgba(163, 125, 77, 0.12);
}

.filter-clear {
  min-height: 44px;
  border: 0;
  border-radius: 12px;
  color: #ffffff;
  background: var(--brown-700);
  padding: 0 18px;
  font-weight: 800;
}

.empty-state {
  margin: 30px 0;
  padding: 38px;
  color: var(--muted);
  text-align: center;
  background: var(--beige-100);
  border-radius: var(--radius);
}

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

.ranking-row {
  display: grid;
  grid-template-columns: 56px 86px minmax(0, 1fr) 160px 70px;
  gap: 16px;
  align-items: center;
  padding: 12px 16px;
  border-radius: 18px;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.ranking-row:hover {
  transform: translateX(4px);
  box-shadow: 0 18px 45px rgba(63, 47, 30, 0.18);
}

.ranking-num {
  color: var(--brown-700);
  font-size: 24px;
  font-weight: 900;
}

.ranking-row img {
  width: 86px;
  height: 58px;
  object-fit: cover;
  border-radius: 12px;
  background: var(--beige-200);
}

.ranking-main {
  display: grid;
  gap: 5px;
  min-width: 0;
}

.ranking-main strong {
  color: var(--brown-800);
  font-size: 18px;
}

.ranking-main em {
  overflow: hidden;
  color: var(--muted);
  font-size: 14px;
  font-style: normal;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.ranking-meta {
  color: #73695f;
  font-size: 13px;
  line-height: 1.55;
}

.ranking-score {
  color: var(--green-700);
  font-size: 22px;
  font-weight: 900;
  text-align: right;
}

.player-section {
  padding: 24px 0 36px;
  background: #090805;
}

.player-frame {
  position: relative;
  overflow: hidden;
  border-radius: 22px;
  background: #000000;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.35);
  aspect-ratio: 16 / 9;
}

.movie-video {
  width: 100%;
  height: 100%;
  background: #000000;
  object-fit: contain;
}

.player-cover {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  border: 0;
  color: #ffffff;
  background:
    radial-gradient(circle at center, rgba(255, 255, 255, 0.1), transparent 25%),
    linear-gradient(180deg, rgba(0, 0, 0, 0.08), rgba(0, 0, 0, 0.55));
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

.player-cover.is-hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.big-play {
  display: grid;
  place-items: center;
  width: 86px;
  height: 86px;
  padding-left: 6px;
  color: var(--brown-900);
  background: rgba(255, 255, 255, 0.9);
  border-radius: 50%;
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.3);
  font-size: 34px;
}

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

.detail-content h1 {
  margin: 0 0 18px;
  color: var(--brown-800);
  font-size: clamp(34px, 5vw, 54px);
  line-height: 1.1;
  font-weight: 900;
  letter-spacing: -0.04em;
}

.detail-meta span,
.detail-meta strong {
  padding: 7px 12px;
  color: var(--brown-700);
  background: var(--beige-100);
}

.detail-meta strong {
  color: var(--green-700);
  background: var(--green-100);
}

.lead-text {
  color: var(--brown-900);
  font-size: 20px;
  line-height: 1.8;
}

.detail-content h2 {
  margin: 34px 0 12px;
  color: var(--brown-800);
  font-size: 26px;
  font-weight: 900;
}

.detail-content p {
  margin: 0;
  color: #4b5563;
  font-size: 17px;
  line-height: 1.9;
}

.tag-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 22px;
}

.tag-cloud span {
  padding: 7px 12px;
  color: var(--green-700);
  background: var(--green-100);
}

.detail-side {
  display: grid;
  align-content: start;
  gap: 18px;
}

.detail-cover {
  width: 100%;
  border-radius: 22px;
  background: var(--beige-200);
  box-shadow: var(--shadow);
  aspect-ratio: 4 / 3;
  object-fit: cover;
}

.side-card {
  padding: 20px;
  border-radius: 20px;
}

.side-card h2 {
  margin: 0 0 16px;
  color: var(--brown-800);
  font-size: 22px;
}

.side-card dl {
  display: grid;
  grid-template-columns: 70px 1fr;
  gap: 10px 12px;
  margin: 0;
}

.side-card dt {
  color: #7a6f63;
  font-weight: 800;
}

.side-card dd {
  margin: 0;
  color: var(--text);
}

.related-section {
  padding-top: 36px;
}

.site-footer {
  color: var(--beige-100);
  background: var(--brown-950);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 0.8fr 0.8fr;
  gap: 34px;
  padding: 48px 0;
}

.site-footer h2,
.site-footer h3 {
  margin: 0 0 14px;
  color: #ffffff;
}

.site-footer p {
  max-width: 520px;
  margin: 0;
  color: var(--beige-200);
  line-height: 1.75;
}

.site-footer a {
  display: block;
  margin: 8px 0;
  color: var(--beige-200);
}

.site-footer a:hover {
  color: #ffffff;
}

.footer-bottom {
  padding: 18px 0;
  border-top: 1px solid rgba(249, 245, 237, 0.12);
  color: var(--beige-200);
  text-align: center;
}

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

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

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

  .filter-panel {
    grid-template-columns: 1fr 1fr;
  }
}

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

  .nav-toggle {
    display: block;
  }

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

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

  .hero {
    height: 660px;
  }

  .hero-content {
    align-items: end;
    padding-bottom: 76px;
  }

  .hero p {
    font-size: 17px;
  }

  .hero-control {
    display: none;
  }

  .hero-search {
    border-radius: 20px;
    flex-direction: column;
    gap: 8px;
  }

  .hero-search input {
    min-height: 42px;
  }

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

  .category-images img {
    height: 70px;
  }

  .section-head {
    display: grid;
  }

  .filter-panel {
    grid-template-columns: 1fr;
  }

  .ranking-row {
    grid-template-columns: 38px 72px minmax(0, 1fr);
  }

  .ranking-meta,
  .ranking-score {
    display: none;
  }

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

  .player-frame {
    border-radius: 14px;
  }

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

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

  .quick-categories,
  .category-grid,
  .movie-grid,
  .small-grid {
    grid-template-columns: 1fr;
  }

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

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

  .compact-poster {
    flex-basis: 104px;
  }

  .side-card dl {
    grid-template-columns: 1fr;
  }
}
