:root {
  color-scheme: light;
  --bg: #fff7ed;
  --panel: #ffffff;
  --panel-soft: #fffbeb;
  --ink: #1f2937;
  --muted: #6b7280;
  --line: #fde68a;
  --brand: #d97706;
  --brand-dark: #92400e;
  --brand-soft: #f59e0b;
  --shadow: 0 22px 45px rgba(146, 64, 14, 0.16);
  --radius: 22px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background: linear-gradient(180deg, #fffbeb 0%, #fff7ed 46%, #fffbeb 100%);
  color: var(--ink);
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
}

img {
  max-width: 100%;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: linear-gradient(90deg, rgba(255, 251, 235, 0.94), rgba(255, 237, 213, 0.94));
  border-bottom: 1px solid var(--line);
  box-shadow: 0 8px 24px rgba(146, 64, 14, 0.08);
  backdrop-filter: blur(16px);
}

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

.brand,
.nav-link,
.mobile-link,
.footer-links a,
.category-strip a,
.section-heading a {
  color: inherit;
  text-decoration: none;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 900;
}

.brand-mark,
.footer-brand span {
  width: 34px;
  height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: linear-gradient(135deg, #f59e0b, #ea580c);
  color: #fff;
  box-shadow: 0 10px 24px rgba(217, 119, 6, 0.28);
}

.brand-text {
  font-size: 24px;
  line-height: 1;
  background: linear-gradient(90deg, #92400e, #ea580c);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 26px;
  font-weight: 700;
  color: #4b5563;
}

.nav-link {
  transition: color 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
  color: var(--brand);
}

.menu-button {
  display: none;
  width: 42px;
  height: 42px;
  border: 0;
  background: transparent;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 5px;
}

.menu-button span {
  width: 24px;
  height: 2px;
  border-radius: 2px;
  background: #78350f;
}

.mobile-nav {
  display: none;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 12px 0 18px;
  border-top: 1px solid var(--line);
}

.mobile-link {
  display: block;
  padding: 11px 0;
  font-weight: 700;
  color: #4b5563;
}

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

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

.hero-shell {
  position: relative;
  height: 70vh;
  min-height: 540px;
  overflow: hidden;
  background: #111827;
}

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

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

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

.hero-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(17, 24, 39, 0.88), rgba(17, 24, 39, 0.56), rgba(17, 24, 39, 0.1));
}

.hero-content {
  position: relative;
  z-index: 2;
  width: min(1180px, calc(100% - 32px));
  height: 100%;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  justify-content: center;
  color: #fff;
  max-width: 1180px;
}

.hero-content > * {
  max-width: 720px;
}

.hero-kicker,
.section-kicker,
.page-hero span {
  width: fit-content;
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 8px 14px;
  background: rgba(245, 158, 11, 0.92);
  color: #fff;
  font-size: 13px;
  font-weight: 900;
  letter-spacing: 0.08em;
}

.hero-content h1 {
  margin: 18px 0 16px;
  font-size: clamp(42px, 6vw, 76px);
  line-height: 0.98;
  font-weight: 950;
}

.hero-content p {
  margin: 0 0 22px;
  color: #e5e7eb;
  font-size: clamp(17px, 2vw, 22px);
  line-height: 1.75;
}

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

.hero-meta span,
.tag-list span {
  border-radius: 999px;
  padding: 7px 12px;
  background: rgba(255, 255, 255, 0.18);
  color: #fff;
  backdrop-filter: blur(10px);
  font-size: 14px;
}

.hero-actions {
  margin-top: 28px;
}

.primary-button,
.ghost-button,
.search-panel button,
.search-page-form button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  border-radius: 12px;
  padding: 0 22px;
  border: 0;
  font-weight: 900;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}

.primary-button,
.search-panel button,
.search-page-form button {
  background: linear-gradient(135deg, #f59e0b, #ea580c);
  color: #fff;
  box-shadow: 0 14px 28px rgba(217, 119, 6, 0.28);
}

.ghost-button {
  background: rgba(255, 255, 255, 0.16);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.22);
  backdrop-filter: blur(10px);
}

.primary-button:hover,
.ghost-button:hover,
.search-panel button:hover,
.search-page-form button:hover {
  transform: translateY(-2px);
}

.full-button {
  width: 100%;
  margin-top: 18px;
}

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

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

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

.search-band,
.content-section,
.breadcrumb {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
}

.search-band {
  position: relative;
  z-index: 5;
  margin-top: -42px;
  padding: 22px;
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.92);
  box-shadow: var(--shadow);
  backdrop-filter: blur(14px);
}

.search-panel label {
  display: block;
  margin-bottom: 10px;
  font-weight: 900;
  color: #78350f;
}

.search-panel div,
.search-page-form {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
}

.search-panel input,
.search-page-form input,
.inline-filter input {
  width: 100%;
  min-height: 46px;
  border-radius: 14px;
  border: 1px solid #fcd34d;
  background: #fffbeb;
  color: #1f2937;
  padding: 0 16px;
  outline: none;
  font-size: 16px;
}

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

.category-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 16px;
}

.category-strip a,
.filter-chips button {
  border: 1px solid #fcd34d;
  border-radius: 999px;
  background: #fffbeb;
  color: #92400e;
  padding: 8px 13px;
  font-weight: 800;
}

.filter-chips button.is-active,
.category-strip a:hover {
  background: #f59e0b;
  color: #fff;
}

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

.white-section {
  width: 100%;
  max-width: none;
  padding-left: max(16px, calc((100vw - 1180px) / 2));
  padding-right: max(16px, calc((100vw - 1180px) / 2));
  background: #fff;
}

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

.section-heading h2 {
  margin: 12px 0 0;
  color: #111827;
  font-size: clamp(28px, 3vw, 38px);
  line-height: 1.1;
  font-weight: 950;
}

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

.section-heading a {
  color: var(--brand);
  font-weight: 900;
}

.movie-grid,
.wide-grid,
.category-grid,
.category-overview-grid,
.ranking-grid {
  display: grid;
  gap: 22px;
}

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

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

.search-grid,
.category-page-grid {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}

.movie-card {
  position: relative;
  display: block;
  overflow: hidden;
  border-radius: 20px;
  background: #fff;
  color: inherit;
  text-decoration: none;
  box-shadow: 0 14px 28px rgba(146, 64, 14, 0.11);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 24px 46px rgba(146, 64, 14, 0.18);
}

.poster-wrap {
  position: relative;
  display: block;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  background: #451a03;
}

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

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

.poster-glow {
  position: absolute;
  inset: auto 0 0 0;
  height: 55%;
  background: linear-gradient(180deg, transparent, rgba(0, 0, 0, 0.72));
}

.rank-badge,
.list-rank {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 2;
  min-width: 34px;
  height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: #f59e0b;
  color: #fff;
  font-style: normal;
  font-weight: 950;
  box-shadow: 0 10px 22px rgba(0, 0, 0, 0.2);
}

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

.movie-card-body strong,
.horizontal-card strong {
  display: block;
  color: #111827;
  font-size: 17px;
  line-height: 1.35;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.movie-card-body small,
.horizontal-card small,
.card-genre,
.card-desc {
  display: block;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
}

.card-genre {
  color: #d97706;
  font-weight: 800;
  margin-top: 6px;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.card-desc {
  margin-top: 7px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.movie-card.compact .movie-card-body {
  min-height: 150px;
}

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

.category-card,
.category-overview-card {
  position: relative;
  min-height: 170px;
  display: flex;
  align-items: end;
  overflow: hidden;
  border-radius: 20px;
  color: #fff;
  text-decoration: none;
  box-shadow: var(--shadow);
  background: #451a03;
}

.category-card img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.7;
  transition: transform 0.5s ease;
}

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

.category-card span,
.category-overview-body {
  position: relative;
  display: block;
  width: 100%;
  padding: 20px;
  background: linear-gradient(180deg, transparent, rgba(0, 0, 0, 0.78));
}

.category-card strong,
.category-overview-body strong {
  display: block;
  font-size: 22px;
  font-weight: 950;
}

.category-card small,
.category-overview-body small {
  display: block;
  margin-top: 8px;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.84);
}

.split-section {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 32px;
}

.rank-panel {
  align-self: start;
  position: sticky;
  top: 88px;
  border-radius: 22px;
  background: #fff;
  padding: 22px;
  box-shadow: var(--shadow);
}

.rank-panel h2 {
  margin: 0 0 16px;
  font-size: 24px;
  font-weight: 950;
  color: #78350f;
}

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

.horizontal-card {
  position: relative;
  display: grid;
  grid-template-columns: 78px 1fr;
  gap: 12px;
  align-items: center;
  color: inherit;
  text-decoration: none;
  border-radius: 14px;
  background: #fffbeb;
  overflow: hidden;
  padding-right: 12px;
}

.horizontal-card img {
  width: 78px;
  height: 78px;
  object-fit: cover;
}

.horizontal-card .list-rank {
  left: 8px;
  top: 8px;
  right: auto;
  min-width: 28px;
  height: 28px;
  font-size: 13px;
}

.inner-page {
  padding-top: 30px;
}

.page-hero {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  border-radius: 28px;
  padding: 54px;
  color: #fff;
  background:
    radial-gradient(circle at 78% 20%, rgba(251, 191, 36, 0.32), transparent 30%),
    linear-gradient(135deg, #78350f, #ea580c);
  box-shadow: var(--shadow);
}

.page-hero h1 {
  margin: 18px 0 12px;
  font-size: clamp(34px, 5vw, 58px);
  line-height: 1.06;
  font-weight: 950;
}

.page-hero p {
  max-width: 760px;
  margin: 0;
  color: rgba(255, 255, 255, 0.86);
  font-size: 18px;
  line-height: 1.8;
}

.inline-filter,
.search-page-form {
  margin-top: 26px;
  max-width: 760px;
}

.filter-chips {
  margin-top: 16px;
}

.category-overview-card {
  min-height: 240px;
  background: linear-gradient(135deg, #78350f, #f59e0b);
}

.category-covers {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  opacity: 0.55;
}

.category-covers img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.category-overview-body {
  margin-top: auto;
}

.breadcrumb {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 9px;
  margin-bottom: 22px;
  color: #92400e;
  font-weight: 800;
}

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

.breadcrumb em {
  font-style: normal;
  color: #6b7280;
}

.detail-layout {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 30px;
}

.player-box {
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-radius: 24px;
  background: #111827;
  box-shadow: 0 24px 54px rgba(17, 24, 39, 0.26);
}

.player-box video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  background: #111827;
}

.player-mask {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 0;
  color: #fff;
  background: linear-gradient(180deg, rgba(17, 24, 39, 0.18), rgba(17, 24, 39, 0.62));
  cursor: pointer;
}

.player-mask span {
  width: 86px;
  height: 86px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: linear-gradient(135deg, #f59e0b, #ea580c);
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.32);
  font-size: 34px;
  padding-left: 6px;
}

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

.detail-copy,
.detail-meta-card {
  margin-top: 24px;
  border-radius: 24px;
  background: #fff;
  padding: 28px;
  box-shadow: var(--shadow);
}

.detail-copy h1 {
  margin: 0 0 12px;
  color: #111827;
  font-size: clamp(28px, 4vw, 44px);
  line-height: 1.12;
  font-weight: 950;
}

.detail-copy h2 {
  margin: 28px 0 10px;
  color: #78350f;
  font-size: 24px;
  font-weight: 950;
}

.detail-copy p {
  margin: 0;
  color: #374151;
  font-size: 17px;
  line-height: 1.9;
}

.lead-text {
  color: #6b7280 !important;
  font-size: 19px !important;
}

.detail-sidebar {
  align-self: start;
  position: sticky;
  top: 92px;
}

.detail-cover {
  width: 100%;
  aspect-ratio: 3 / 4;
  border-radius: 24px;
  object-fit: cover;
  box-shadow: var(--shadow);
  background: #451a03;
}

.detail-meta-card h2 {
  margin: 0 0 16px;
  font-size: 24px;
  font-weight: 950;
  color: #111827;
}

.detail-meta-card dl {
  display: grid;
  grid-template-columns: 64px 1fr;
  gap: 10px 14px;
  margin: 0;
}

.detail-meta-card dt {
  color: #92400e;
  font-weight: 950;
}

.detail-meta-card dd {
  margin: 0;
  color: #4b5563;
}

.detail-meta-card .tag-list {
  margin-top: 18px;
}

.detail-meta-card .tag-list span {
  background: #fffbeb;
  color: #92400e;
  border: 1px solid #fcd34d;
}

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

.site-footer {
  margin-top: 40px;
  background: linear-gradient(135deg, #78350f, #431407);
  color: #fffbeb;
}

.footer-grid {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 54px 0 30px;
  display: grid;
  grid-template-columns: 1.35fr 1fr 1fr;
  gap: 30px;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 22px;
  font-weight: 950;
}

.site-footer p {
  color: #fde68a;
  line-height: 1.8;
}

.site-footer h2 {
  margin: 0 0 12px;
  font-size: 18px;
  font-weight: 950;
}

.footer-links {
  display: grid;
  gap: 9px;
}

.footer-links a {
  color: #fde68a;
}

.footer-bottom {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 22px 0 30px;
  border-top: 1px solid rgba(253, 230, 138, 0.24);
  color: #fde68a;
  font-size: 14px;
}

.is-filter-hidden {
  display: none !important;
}

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

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

  .rank-panel,
  .detail-sidebar {
    position: static;
  }

  .detail-sidebar {
    display: grid;
    grid-template-columns: 260px 1fr;
    gap: 22px;
  }

  .detail-meta-card {
    margin-top: 0;
  }
}

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

  .menu-button {
    display: inline-flex;
  }

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

  .hero-shell {
    height: 78vh;
    min-height: 620px;
  }

  .hero-shade {
    background: linear-gradient(180deg, rgba(17, 24, 39, 0.28), rgba(17, 24, 39, 0.9));
  }

  .hero-content {
    justify-content: flex-end;
    padding-bottom: 88px;
  }

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

  .search-panel div,
  .search-page-form {
    grid-template-columns: 1fr;
  }

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

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

  .movie-grid,
  .wide-grid,
  .ranking-grid,
  .search-grid,
  .category-page-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
  }

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

  .page-hero {
    padding: 34px 22px;
  }

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

  .detail-cover {
    max-width: 320px;
    margin: 0 auto;
  }

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

@media (max-width: 480px) {
  .movie-grid,
  .wide-grid,
  .ranking-grid,
  .search-grid,
  .category-page-grid {
    grid-template-columns: 1fr;
  }

  .movie-card.compact {
    display: grid;
    grid-template-columns: 128px 1fr;
  }

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

  .movie-card.compact .movie-card-body {
    min-height: 0;
  }
}
