* {
  box-sizing: border-box;
}

:root {
  --bg: #fffaf1;
  --surface: #ffffff;
  --surface-soft: #fff7ed;
  --text: #23190f;
  --muted: #746452;
  --line: rgba(146, 100, 46, 0.18);
  --brand: #d97706;
  --brand-dark: #b45309;
  --brand-soft: #fef3c7;
  --accent: #ea580c;
  --shadow: 0 22px 60px rgba(120, 53, 15, 0.12);
  --radius: 24px;
}

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
  color: var(--text);
  background: linear-gradient(180deg, #fffaf1 0%, #ffffff 38%, #fff7ed 100%);
  min-height: 100vh;
}

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

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(18px);
  border-bottom: 1px solid rgba(217, 119, 6, 0.16);
  box-shadow: 0 10px 28px rgba(120, 53, 15, 0.08);
}

.header-inner {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  min-height: 74px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

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

.brand-mark {
  width: 42px;
  height: 42px;
  border-radius: 16px;
  color: #ffffff;
  display: inline-grid;
  place-items: center;
  background: linear-gradient(135deg, #f59e0b, #ea580c);
  box-shadow: 0 16px 28px rgba(234, 88, 12, 0.28);
}

.brand-text {
  font-size: 20px;
  background: linear-gradient(135deg, #b45309, #ea580c);
  -webkit-background-clip: text;
  color: transparent;
}

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

.nav-link {
  padding: 10px 16px;
  border-radius: 999px;
  color: #5f4b32;
  font-weight: 700;
  transition: color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
  color: #b45309;
  background: #fef3c7;
  transform: translateY(-1px);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.global-search {
  position: relative;
  width: min(280px, 34vw);
}

.global-search input,
.page-filter input {
  width: 100%;
  border: 1px solid rgba(217, 119, 6, 0.25);
  outline: none;
  border-radius: 999px;
  padding: 12px 44px 12px 16px;
  background: rgba(255, 255, 255, 0.86);
  color: var(--text);
  transition: border 0.2s ease, box-shadow 0.2s ease;
}

.global-search input:focus,
.page-filter input:focus {
  border-color: #f59e0b;
  box-shadow: 0 0 0 4px rgba(245, 158, 11, 0.16);
}

.search-submit {
  position: absolute;
  right: 5px;
  top: 5px;
  width: 34px;
  height: 34px;
  border: 0;
  border-radius: 50%;
  color: #ffffff;
  background: linear-gradient(135deg, #f59e0b, #ea580c);
  cursor: pointer;
}

.search-panel {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  width: min(460px, 92vw);
  max-height: 520px;
  overflow: auto;
  background: rgba(255, 255, 255, 0.98);
  border: 1px solid rgba(217, 119, 6, 0.18);
  border-radius: 22px;
  box-shadow: var(--shadow);
  padding: 10px;
}

.search-item {
  display: grid;
  grid-template-columns: 58px 1fr;
  gap: 12px;
  padding: 10px;
  border-radius: 16px;
  transition: background 0.2s ease;
}

.search-item:hover {
  background: #fff7ed;
}

.search-item img {
  width: 58px;
  height: 78px;
  object-fit: cover;
  border-radius: 12px;
  background: #f8ecd9;
}

.search-item strong {
  display: block;
  font-size: 15px;
  margin-bottom: 4px;
}

.search-item span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.5;
}

.menu-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 14px;
  color: #ffffff;
  background: linear-gradient(135deg, #f59e0b, #ea580c);
  cursor: pointer;
  font-size: 20px;
}

.mobile-nav {
  display: none;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto 14px;
  padding: 12px;
  border-radius: 18px;
  background: #fff7ed;
}

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

.hero {
  position: relative;
  overflow: hidden;
  min-height: 680px;
  color: #ffffff;
  background: radial-gradient(circle at top left, rgba(251, 191, 36, 0.78), transparent 34%), linear-gradient(135deg, #7c2d12, #d97706 52%, #fb923c);
}

.hero-stage {
  position: relative;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  min-height: 680px;
  display: flex;
  align-items: center;
  padding: 86px 0 72px;
}

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

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

.hero-backdrop {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  transform: scale(1.05);
  filter: saturate(1.1);
}

.hero-backdrop::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(67, 20, 7, 0.94), rgba(120, 53, 15, 0.76) 46%, rgba(124, 45, 18, 0.18)), linear-gradient(0deg, rgba(67, 20, 7, 0.72), transparent 48%);
}

.hero-content {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) 380px;
  align-items: center;
  gap: 44px;
  width: 100%;
}

.hero-copy {
  max-width: 700px;
}

.hero-pill,
.kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border-radius: 999px;
  color: #92400e;
  background: #fef3c7;
  padding: 8px 14px;
  font-weight: 800;
  font-size: 14px;
}

.hero .hero-pill {
  color: #fff7ed;
  background: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.24);
  backdrop-filter: blur(12px);
}

.hero h1 {
  margin: 24px 0 18px;
  font-size: clamp(40px, 6vw, 76px);
  line-height: 1.02;
  letter-spacing: -0.04em;
}

.hero p {
  margin: 0 0 24px;
  color: rgba(255, 255, 255, 0.88);
  font-size: 18px;
  line-height: 1.8;
}

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

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  padding: 13px 22px;
  border-radius: 999px;
  font-weight: 900;
  border: 0;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.button.primary {
  color: #ffffff;
  background: linear-gradient(135deg, #f59e0b, #ea580c);
  box-shadow: 0 18px 36px rgba(234, 88, 12, 0.28);
}

.button.light {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.18);
  border: 1px solid rgba(255, 255, 255, 0.38);
  backdrop-filter: blur(10px);
}

.button.soft {
  color: #b45309;
  background: #fef3c7;
}

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

.hero-poster {
  position: relative;
  border-radius: 32px;
  overflow: hidden;
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.38);
  transform: rotate(2deg);
  background: rgba(255, 255, 255, 0.1);
}

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

.hero-poster-info {
  position: absolute;
  left: 18px;
  right: 18px;
  bottom: 18px;
  border-radius: 22px;
  padding: 16px;
  background: rgba(0, 0, 0, 0.42);
  backdrop-filter: blur(18px);
}

.hero-poster-info strong {
  display: block;
  font-size: 18px;
  margin-bottom: 6px;
}

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

.hero-dot {
  width: 42px;
  height: 6px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.38);
  cursor: pointer;
}

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

.section {
  padding: 70px 0;
}

.section.soft {
  background: linear-gradient(180deg, #ffffff, #fff7ed);
}

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

.section-heading h2 {
  margin: 12px 0 10px;
  font-size: clamp(28px, 4vw, 42px);
  letter-spacing: -0.03em;
}

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

.section-more {
  white-space: nowrap;
  color: #b45309;
  font-weight: 900;
}

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

.movie-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 16px 45px rgba(120, 53, 15, 0.08);
  transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  border-color: rgba(217, 119, 6, 0.34);
  box-shadow: var(--shadow);
}

.poster-link {
  position: relative;
  display: block;
  overflow: hidden;
  background: #f8ecd9;
}

.poster-link img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  transition: transform 0.32s ease;
}

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

.poster-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  color: #ffffff;
  background: rgba(234, 88, 12, 0.92);
  border-radius: 999px;
  padding: 5px 10px;
  font-size: 12px;
  font-weight: 900;
}

.poster-play {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 54px;
  height: 54px;
  transform: translate(-50%, -50%) scale(0.86);
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: #ffffff;
  background: rgba(0, 0, 0, 0.42);
  opacity: 0;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

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

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

.movie-meta-line {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  color: #9a6b2f;
  font-size: 12px;
  font-weight: 800;
  margin-bottom: 8px;
}

.movie-card h3 {
  margin: 0 0 10px;
  font-size: 19px;
  line-height: 1.35;
}

.movie-card p {
  margin: 0 0 14px;
  color: var(--muted);
  line-height: 1.7;
  font-size: 14px;
}

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

.tag-row span,
.detail-tags span {
  display: inline-flex;
  border-radius: 999px;
  background: #fff7ed;
  color: #b45309;
  padding: 5px 9px;
  font-size: 12px;
  font-weight: 800;
}

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

.category-card {
  min-height: 170px;
  border: 1px solid var(--line);
  border-radius: 28px;
  background: linear-gradient(145deg, #ffffff, #fff7ed);
  padding: 22px;
  box-shadow: 0 16px 45px rgba(120, 53, 15, 0.08);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

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

.category-card strong {
  display: block;
  font-size: 21px;
  margin-bottom: 10px;
}

.category-card p {
  margin: 0 0 18px;
  color: var(--muted);
  line-height: 1.7;
}

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

.rank-item {
  display: grid;
  grid-template-columns: 68px 92px 1fr auto;
  gap: 16px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.92);
  padding: 12px 18px 12px 12px;
  box-shadow: 0 12px 28px rgba(120, 53, 15, 0.06);
}

.rank-number {
  color: #d97706;
  font-size: 30px;
  font-weight: 950;
  text-align: center;
}

.rank-item img {
  width: 92px;
  height: 122px;
  border-radius: 14px;
  object-fit: cover;
  background: #f8ecd9;
}

.rank-copy strong {
  display: block;
  font-size: 20px;
  margin-bottom: 8px;
}

.rank-copy p {
  margin: 0;
  color: var(--muted);
  line-height: 1.7;
}

.rank-score {
  min-width: 92px;
  text-align: right;
  color: #b45309;
  font-weight: 900;
}

.page-hero {
  padding: 72px 0 42px;
  background: radial-gradient(circle at 12% 5%, rgba(251, 191, 36, 0.42), transparent 30%), linear-gradient(180deg, #fff7ed, #ffffff);
}

.page-hero h1 {
  margin: 16px 0 14px;
  font-size: clamp(34px, 5vw, 58px);
  letter-spacing: -0.04em;
}

.page-hero p {
  max-width: 760px;
  color: var(--muted);
  font-size: 18px;
  line-height: 1.85;
  margin: 0;
}

.toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin: 0 0 28px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 14px 38px rgba(120, 53, 15, 0.06);
}

.page-filter {
  flex: 1;
  max-width: 420px;
}

.filter-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
}

.filter-button {
  border: 0;
  border-radius: 999px;
  padding: 10px 14px;
  color: #8a5a1f;
  background: #fef3c7;
  font-weight: 900;
  cursor: pointer;
}

.filter-button.active {
  color: #ffffff;
  background: linear-gradient(135deg, #f59e0b, #ea580c);
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: #8a5a1f;
  font-size: 14px;
  font-weight: 800;
  margin-bottom: 20px;
}

.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) 360px;
  gap: 34px;
  align-items: start;
}

.player-card,
.detail-card {
  border: 1px solid var(--line);
  border-radius: 30px;
  background: rgba(255, 255, 255, 0.94);
  overflow: hidden;
  box-shadow: var(--shadow);
}

.player-frame {
  position: relative;
  background: #130c07;
}

.player-frame video {
  width: 100%;
  aspect-ratio: 16 / 9;
  display: block;
  background: #130c07;
  cursor: pointer;
}

.player-cover {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 24px;
  background: linear-gradient(180deg, rgba(19, 12, 7, 0.18), rgba(19, 12, 7, 0.72));
  cursor: pointer;
  z-index: 2;
}

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

.play-button {
  width: 88px;
  height: 88px;
  border: 0;
  border-radius: 50%;
  color: #ffffff;
  background: linear-gradient(135deg, #f59e0b, #ea580c);
  font-size: 34px;
  cursor: pointer;
  box-shadow: 0 22px 48px rgba(234, 88, 12, 0.38);
}

.player-info {
  padding: 26px;
}

.player-info h1 {
  margin: 0 0 12px;
  font-size: clamp(28px, 4vw, 42px);
  letter-spacing: -0.03em;
}

.detail-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 16px 0;
}

.detail-prose {
  padding: 28px;
}

.detail-prose h2 {
  margin: 0 0 14px;
  font-size: 24px;
}

.detail-prose p {
  color: var(--muted);
  line-height: 1.9;
  margin: 0 0 20px;
}

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

.detail-side-body {
  padding: 20px;
}

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

.detail-side-body dt {
  color: #9a6b2f;
  font-weight: 900;
}

.detail-side-body dd {
  margin: 0;
  color: var(--muted);
}

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

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

.site-footer {
  margin-top: 50px;
  padding: 48px 0 24px;
  background: #23190f;
  color: #fff7ed;
}

.footer-inner {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  gap: 28px;
}

.footer-inner p {
  color: rgba(255, 247, 237, 0.7);
  line-height: 1.8;
  max-width: 620px;
}

.footer-links {
  display: flex;
  gap: 16px;
  align-items: start;
  font-weight: 800;
}

.copyright {
  width: min(1180px, calc(100% - 32px));
  margin: 22px auto 0;
  color: rgba(255, 247, 237, 0.56);
  font-size: 14px;
}

.empty-state {
  display: none;
  padding: 32px;
  border-radius: 24px;
  background: #fff7ed;
  color: var(--muted);
  text-align: center;
}

@media (max-width: 1080px) {
  .movie-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));
  }

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

  .hero-poster {
    max-width: 360px;
  }
}

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

  .menu-toggle {
    display: inline-grid;
    place-items: center;
  }

  .mobile-nav.open {
    display: grid;
    gap: 8px;
  }

  .global-search {
    width: min(210px, 50vw);
  }

  .hero,
  .hero-stage {
    min-height: 720px;
  }

  .hero-stage {
    padding-top: 58px;
  }

  .hero-content {
    gap: 24px;
  }

  .hero-dots {
    bottom: 24px;
  }

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

  .section {
    padding: 48px 0;
  }

  .section-heading,
  .toolbar,
  .footer-inner {
    align-items: stretch;
    flex-direction: column;
  }

  .page-filter {
    max-width: none;
  }

  .rank-item {
    grid-template-columns: 44px 70px 1fr;
  }

  .rank-item img {
    width: 70px;
    height: 94px;
  }

  .rank-score {
    grid-column: 3;
    text-align: left;
  }
}

@media (max-width: 480px) {
  .header-inner {
    width: min(100% - 20px, 1180px);
    gap: 8px;
  }

  .brand-text {
    font-size: 17px;
  }

  .brand-mark {
    width: 36px;
    height: 36px;
    border-radius: 13px;
  }

  .global-search {
    display: none;
  }

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

  .hero h1 {
    font-size: 42px;
  }

  .hero-poster {
    transform: none;
  }
}
