:root {
  --bg: #fff7ed;
  --bg-soft: #f5f5f4;
  --panel: #ffffff;
  --ink: #2f1d12;
  --muted: #7c5c45;
  --line: rgba(180, 83, 9, 0.16);
  --brand: #b45309;
  --brand-dark: #7c2d12;
  --brand-soft: #fef3c7;
  --shadow: 0 24px 55px rgba(120, 53, 15, 0.14);
  --radius: 22px;
  --container: 1180px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background: linear-gradient(180deg, var(--bg) 0%, var(--bg-soft) 100%);
  font-family: "PingFang SC", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
  line-height: 1.6;
}

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

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

button,
input {
  font: inherit;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid rgba(180, 83, 9, 0.13);
  background: rgba(255, 247, 237, 0.88);
  backdrop-filter: blur(18px);
}

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

.site-logo,
.footer-logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 900;
  letter-spacing: 0.02em;
  color: var(--brand-dark);
}

.site-logo {
  font-size: 22px;
}

.logo-mark {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  color: #fff;
  border-radius: 14px;
  background: linear-gradient(135deg, #dc2626, #d97706 52%, #f59e0b);
  box-shadow: 0 12px 24px rgba(180, 83, 9, 0.25);
}

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

.nav-link {
  padding: 10px 16px;
  color: #6b3a1b;
  border-radius: 999px;
  transition: color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.nav-link:hover,
.nav-link.is-active {
  color: #fff;
  background: var(--brand);
  transform: translateY(-1px);
}

.nav-toggle {
  display: none;
  width: 42px;
  height: 42px;
  padding: 9px;
  border: 0;
  border-radius: 13px;
  background: var(--brand-soft);
  cursor: pointer;
}

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

.hero {
  position: relative;
  height: 70vh;
  min-height: 520px;
  overflow: hidden;
  background: #140f0b;
}

.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 {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.04);
  transition: transform 5.5s ease;
}

.hero-slide.is-active img {
  transform: scale(1);
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 20% 25%, rgba(245, 158, 11, 0.28), transparent 28%),
    linear-gradient(90deg, rgba(0, 0, 0, 0.84), rgba(0, 0, 0, 0.42) 48%, rgba(0, 0, 0, 0.24)),
    linear-gradient(0deg, rgba(0, 0, 0, 0.86), rgba(0, 0, 0, 0.08) 58%);
}

.hero-content {
  position: absolute;
  left: 50%;
  bottom: 76px;
  transform: translateX(-50%);
  color: #fff;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  gap: 8px;
  margin-bottom: 14px;
  padding: 7px 14px;
  color: #fff7ed;
  font-size: 14px;
  font-weight: 800;
  border: 1px solid rgba(255, 255, 255, 0.26);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.16);
  backdrop-filter: blur(10px);
}

.eyebrow.dark {
  color: var(--brand-dark);
  border-color: rgba(180, 83, 9, 0.18);
  background: rgba(254, 243, 199, 0.72);
}

.hero h1 {
  max-width: 850px;
  margin: 0 0 18px;
  font-size: clamp(40px, 6vw, 74px);
  line-height: 1.05;
  font-weight: 950;
  text-shadow: 0 10px 30px rgba(0, 0, 0, 0.45);
}

.hero p {
  max-width: 760px;
  margin: 0 0 28px;
  color: #ffedd5;
  font-size: clamp(17px, 2vw, 22px);
}

.hero-actions,
.detail-meta,
.filter-row,
.tag-cloud {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
}

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

.btn-primary,
.search-box button {
  color: #fff;
  border: 0;
  background: linear-gradient(135deg, #dc2626, #d97706);
  box-shadow: 0 18px 34px rgba(180, 83, 9, 0.32);
}

.btn-primary:hover,
.search-box button:hover,
.section-more:hover {
  transform: translateY(-2px);
  box-shadow: 0 22px 42px rgba(180, 83, 9, 0.26);
}

.btn-ghost,
.hero-pill {
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.3);
  background: rgba(255, 255, 255, 0.14);
  backdrop-filter: blur(10px);
}

.hero-arrow {
  position: absolute;
  top: 50%;
  z-index: 4;
  width: 50px;
  height: 50px;
  border: 0;
  color: #fff;
  font-size: 36px;
  line-height: 1;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.32);
  cursor: pointer;
  transform: translateY(-50%);
  transition: background 0.2s ease, transform 0.2s ease;
}

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

.hero-prev {
  left: 24px;
}

.hero-next {
  right: 24px;
}

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

.hero-dot {
  width: 28px;
  height: 6px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.42);
  cursor: pointer;
  transition: width 0.2s ease, background 0.2s ease;
}

.hero-dot.is-active {
  width: 48px;
  background: #f59e0b;
}

.intro-panel,
.page-hero {
  margin-top: 48px;
  padding: 34px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.82);
  box-shadow: var(--shadow);
}

.intro-panel {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 30px;
  align-items: center;
}

.intro-panel h2,
.page-hero h1,
.section-head h2 {
  margin: 0;
  color: var(--brand-dark);
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1.18;
  font-weight: 950;
}

.intro-panel p,
.page-hero p,
.section-head p,
.footer-grid p {
  margin: 12px 0 0;
  color: var(--muted);
}

.search-panel {
  position: relative;
}

.search-box {
  display: flex;
  gap: 10px;
  padding: 8px;
  border: 1px solid rgba(180, 83, 9, 0.16);
  border-radius: 999px;
  background: #fff;
  box-shadow: 0 14px 30px rgba(120, 53, 15, 0.08);
}

.search-box input {
  width: 100%;
  min-width: 0;
  border: 0;
  outline: 0;
  padding: 0 14px;
  color: var(--ink);
  background: transparent;
}

.filter-row {
  margin-top: 14px;
}

.filter-chip {
  border: 1px solid rgba(180, 83, 9, 0.18);
  color: #8a3d0b;
  padding: 8px 14px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.78);
  cursor: pointer;
  transition: color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.filter-chip:hover,
.filter-chip.is-active {
  color: #fff;
  background: var(--brand);
  transform: translateY(-1px);
}

.empty-state {
  display: none;
  margin: 18px 0 0;
  color: #9f1239;
  font-weight: 800;
}

.empty-state.is-visible {
  display: block;
}

.section-block {
  padding: 58px 0 8px;
}

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

.section-head h2 {
  font-size: clamp(26px, 3vw, 36px);
}

.section-more {
  flex: 0 0 auto;
  color: var(--brand-dark);
  background: var(--brand-soft);
}

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

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

.movie-card {
  min-width: 0;
  border: 1px solid rgba(180, 83, 9, 0.12);
  border-radius: var(--radius);
  background: #fff;
  box-shadow: 0 16px 32px rgba(120, 53, 15, 0.10);
  overflow: hidden;
  transition: transform 0.24s ease, box-shadow 0.24s ease, border-color 0.24s ease;
}

.movie-card:hover {
  border-color: rgba(180, 83, 9, 0.28);
  box-shadow: 0 24px 48px rgba(120, 53, 15, 0.18);
  transform: translateY(-6px);
}

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

.poster-wrap {
  position: relative;
  display: block;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: linear-gradient(135deg, #451a03, #78350f);
}

.poster-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.34s ease, opacity 0.34s ease;
}

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

.poster-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 30%, rgba(0, 0, 0, 0.74));
}

.poster-meta,
.rank-badge {
  position: absolute;
  z-index: 2;
  color: #fff;
  font-weight: 900;
}

.poster-meta {
  left: 14px;
  bottom: 12px;
  font-size: 13px;
}

.rank-badge {
  top: 12px;
  left: 12px;
  min-width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: linear-gradient(135deg, #dc2626, #f59e0b);
  box-shadow: 0 10px 22px rgba(0, 0, 0, 0.24);
}

.card-body {
  display: grid;
  gap: 9px;
  padding: 16px;
}

.card-body strong {
  display: -webkit-box;
  color: var(--brand-dark);
  font-size: 18px;
  font-style: normal;
  font-weight: 900;
  line-height: 1.35;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.card-body span {
  display: -webkit-box;
  min-height: 45px;
  color: #6b4a36;
  font-size: 14px;
  line-height: 1.55;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.card-body em {
  width: fit-content;
  max-width: 100%;
  color: #92400e;
  font-size: 13px;
  font-style: normal;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  padding: 5px 10px;
  border-radius: 999px;
  background: #ffedd5;
}

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

.category-card {
  min-height: 150px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 24px;
  color: #fff;
  border-radius: var(--radius);
  background:
    radial-gradient(circle at 78% 12%, rgba(255, 255, 255, 0.24), transparent 30%),
    linear-gradient(135deg, #7c2d12, #b45309 54%, #d97706);
  box-shadow: 0 22px 44px rgba(120, 53, 15, 0.16);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.category-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 28px 54px rgba(120, 53, 15, 0.22);
}

.category-card span {
  font-size: 22px;
  font-weight: 950;
}

.category-card strong {
  color: #ffedd5;
  font-size: 14px;
  font-weight: 600;
}

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

.small-hero {
  margin-top: 34px;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 18px;
  color: #8a5533;
  font-size: 14px;
}

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

.category-overview-block {
  padding: 48px 0 8px;
  border-bottom: 1px solid rgba(180, 83, 9, 0.11);
}

.detail-main {
  padding-top: 34px;
}

.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 28px;
  align-items: start;
}

.detail-primary {
  min-width: 0;
}

.player-card,
.detail-info-card,
.sidebar-card {
  border: 1px solid rgba(180, 83, 9, 0.12);
  border-radius: var(--radius);
  background: #fff;
  box-shadow: var(--shadow);
  overflow: hidden;
}

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

.video-player {
  width: 100%;
  height: 100%;
  display: block;
  background: #050505;
}

.player-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  gap: 12px;
  border: 0;
  color: #fff;
  text-align: center;
  cursor: pointer;
  background:
    radial-gradient(circle at center, rgba(0, 0, 0, 0.12), rgba(0, 0, 0, 0.72)),
    linear-gradient(180deg, rgba(0, 0, 0, 0.05), rgba(0, 0, 0, 0.55));
}

.player-overlay.is-hidden {
  display: none;
}

.play-icon {
  width: 76px;
  height: 76px;
  display: grid;
  place-items: center;
  padding-left: 5px;
  font-size: 28px;
  color: #fff;
  border-radius: 999px;
  background: linear-gradient(135deg, #dc2626, #d97706);
  box-shadow: 0 20px 42px rgba(0, 0, 0, 0.32);
}

.player-overlay strong {
  padding: 0 22px;
  font-size: clamp(20px, 4vw, 32px);
  font-weight: 950;
  text-shadow: 0 8px 22px rgba(0, 0, 0, 0.4);
}

.detail-info-card {
  margin-top: 24px;
  padding: 28px;
}

.detail-info-card h1 {
  margin: 0 0 18px;
  color: var(--brand-dark);
  font-size: clamp(30px, 4vw, 48px);
  line-height: 1.14;
  font-weight: 950;
}

.detail-meta span {
  padding: 7px 12px;
  color: #8a3d0b;
  font-weight: 800;
  border-radius: 999px;
  background: #ffedd5;
}

.one-line {
  margin: 22px 0;
  color: #6b3a1b;
  font-size: 19px;
  font-weight: 700;
}

.text-section {
  margin-top: 26px;
}

.text-section h2,
.sidebar-card h2 {
  margin: 0 0 12px;
  color: var(--brand-dark);
  font-size: 22px;
  font-weight: 950;
}

.text-section p {
  margin: 0;
  color: #4b3427;
  font-size: 17px;
  line-height: 1.9;
}

.tag-cloud {
  margin-top: 26px;
}

.tag-cloud span {
  padding: 7px 12px;
  color: #7c2d12;
  font-weight: 800;
  border-radius: 999px;
  background: rgba(254, 243, 199, 0.88);
}

.detail-sidebar {
  position: sticky;
  top: 96px;
}

.sidebar-card {
  padding: 20px;
}

.side-related {
  display: grid;
  grid-template-columns: 110px 1fr;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid rgba(180, 83, 9, 0.10);
}

.side-related:last-child {
  border-bottom: 0;
}

.side-related img {
  width: 110px;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  border-radius: 14px;
}

.side-related span {
  min-width: 0;
}

.side-related strong {
  display: -webkit-box;
  color: var(--brand-dark);
  font-weight: 900;
  line-height: 1.4;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.side-related em {
  display: block;
  margin-top: 6px;
  color: var(--muted);
  font-size: 13px;
  font-style: normal;
}

.related-block {
  padding-bottom: 64px;
}

.site-footer {
  margin-top: 72px;
  color: #7c5c45;
  border-top: 1px solid rgba(180, 83, 9, 0.13);
  background: rgba(255, 255, 255, 0.62);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: 28px;
  padding: 42px 0;
}

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

.footer-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 12px;
}

.footer-links a {
  padding: 8px 12px;
  border-radius: 999px;
  background: #ffedd5;
}

.footer-links a:hover {
  color: #fff;
  background: var(--brand);
}

.footer-bottom {
  padding: 16px;
  text-align: center;
  border-top: 1px solid rgba(180, 83, 9, 0.10);
}

.is-hidden-by-search {
  display: none;
}

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

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

  .detail-sidebar {
    position: static;
  }
}

@media (max-width: 820px) {
  .nav-toggle {
    display: block;
  }

  .site-nav {
    position: absolute;
    top: 72px;
    left: 16px;
    right: 16px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    padding: 14px;
    border: 1px solid var(--line);
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.96);
    box-shadow: var(--shadow);
  }

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

  .nav-link {
    text-align: center;
  }

  .hero {
    min-height: 570px;
    height: 74vh;
  }

  .hero-content {
    bottom: 74px;
  }

  .hero-arrow {
    width: 42px;
    height: 42px;
    font-size: 30px;
  }

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

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

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

  .footer-links {
    justify-content: flex-start;
  }
}

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

  .site-logo {
    font-size: 18px;
  }

  .logo-mark {
    width: 34px;
    height: 34px;
  }

  .hero {
    min-height: 610px;
  }

  .hero-content {
    bottom: 84px;
  }

  .hero-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .btn,
  .hero-pill {
    width: 100%;
  }

  .hero-prev {
    left: 10px;
  }

  .hero-next {
    right: 10px;
  }

  .intro-panel,
  .page-hero,
  .detail-info-card {
    padding: 22px;
    border-radius: 18px;
  }

  .search-box {
    align-items: stretch;
    flex-direction: column;
    border-radius: 20px;
  }

  .search-box input {
    min-height: 44px;
  }

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

  .side-related {
    grid-template-columns: 96px 1fr;
  }

  .side-related img {
    width: 96px;
  }
}
