:root {
  color-scheme: dark;
  --moonlight-950: #020617;
  --moonlight-900: #0f172a;
  --moonlight-850: #172033;
  --moonlight-800: #1e293b;
  --moonlight-700: #334155;
  --lunar-50: #fafafa;
  --lunar-100: #f5f5f5;
  --lunar-200: #e5e5e5;
  --lunar-300: #d4d4d4;
  --lunar-400: #a3a3a3;
  --golden-300: #fcd34d;
  --golden-400: #fbbf24;
  --golden-500: #f59e0b;
  --golden-900: #78350f;
  --card-border: rgba(148, 163, 184, 0.18);
  --shadow-lunar: 0 8px 30px rgba(0, 0, 0, 0.22);
  --shadow-glow: 0 0 36px rgba(251, 191, 36, 0.14);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--lunar-100);
  background:
    radial-gradient(circle at top left, rgba(251, 191, 36, 0.11), transparent 34rem),
    radial-gradient(circle at 80% 10%, rgba(59, 130, 246, 0.08), transparent 28rem),
    var(--moonlight-950);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  line-height: 1.65;
}

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

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

button,
input {
  font: inherit;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 80;
  border-bottom: 1px solid rgba(30, 41, 59, 0.96);
  background: rgba(15, 23, 42, 0.94);
  backdrop-filter: blur(14px);
}

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

.site-logo {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  font-size: 1.18rem;
  font-weight: 800;
  letter-spacing: 0.02em;
  background: linear-gradient(90deg, var(--golden-300), var(--golden-500));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.logo-mark {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 12px;
  color: var(--moonlight-950);
  background: linear-gradient(135deg, var(--golden-300), var(--golden-500));
  box-shadow: var(--shadow-glow);
  transition: transform 0.3s ease;
}

.site-logo:hover .logo-mark {
  transform: rotate(12deg) scale(1.04);
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.nav-link {
  color: var(--lunar-300);
  font-size: 0.95rem;
  transition: color 0.2s ease;
}

.nav-link:hover,
.nav-link.is-active {
  color: var(--golden-400);
}

.nav-divider {
  width: 1px;
  height: 18px;
  background: var(--moonlight-700);
}

.menu-toggle {
  display: none;
  width: 42px;
  height: 42px;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 5px;
  border: 1px solid var(--moonlight-700);
  border-radius: 12px;
  color: var(--lunar-200);
  background: rgba(15, 23, 42, 0.4);
  cursor: pointer;
}

.menu-toggle span {
  width: 18px;
  height: 2px;
  border-radius: 2px;
  background: currentColor;
}

.mobile-nav {
  display: none;
  border-top: 1px solid var(--moonlight-800);
  padding: 0.75rem 1rem 1rem;
  background: rgba(15, 23, 42, 0.98);
}

.mobile-nav.is-open {
  display: grid;
  gap: 0.25rem;
}

.mobile-link {
  padding: 0.75rem;
  border-radius: 12px;
  color: var(--lunar-300);
}

.mobile-link:hover,
.mobile-link.is-active {
  color: var(--golden-400);
  background: rgba(30, 41, 59, 0.65);
}

.hero-carousel {
  position: relative;
  min-height: 680px;
  overflow: hidden;
  background: var(--moonlight-950);
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: grid;
  align-items: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.8s ease;
}

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

.hero-backdrop {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(2, 6, 23, 0.98), rgba(2, 6, 23, 0.78), rgba(2, 6, 23, 0.5)),
    linear-gradient(0deg, var(--moonlight-950), transparent 42%),
    var(--hero-image) center / cover no-repeat;
  filter: saturate(1.08);
}

.hero-content-grid {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(280px, 0.56fr);
  align-items: center;
  gap: clamp(2rem, 5vw, 5rem);
  padding: 5rem 0 6rem;
}

.eyebrow,
.section-kicker {
  color: var(--golden-400);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.hero-copy h1 {
  max-width: 760px;
  margin: 0.7rem 0 1rem;
  font-size: clamp(2.6rem, 8vw, 5.7rem);
  line-height: 0.96;
  letter-spacing: -0.06em;
}

.hero-copy p {
  max-width: 690px;
  margin: 0;
  color: var(--lunar-300);
  font-size: clamp(1rem, 2vw, 1.22rem);
}

.hero-tags,
.card-tags,
.detail-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  margin-top: 1.2rem;
}

.hero-tags span,
.card-tags span,
.detail-tags span {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0.22rem 0.64rem;
  border: 1px solid rgba(251, 191, 36, 0.26);
  border-radius: 999px;
  color: var(--golden-300);
  background: rgba(120, 53, 15, 0.28);
  font-size: 0.78rem;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.9rem;
  margin-top: 2rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 1.15rem;
  border-radius: 14px;
  border: 1px solid transparent;
  font-weight: 800;
  transition: transform 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

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

.btn.primary {
  color: var(--moonlight-950);
  background: linear-gradient(135deg, var(--golden-300), var(--golden-500));
  box-shadow: var(--shadow-glow);
}

.btn.ghost {
  color: var(--lunar-200);
  border-color: rgba(251, 191, 36, 0.3);
  background: rgba(15, 23, 42, 0.52);
}

.btn.ghost:hover {
  border-color: var(--golden-400);
}

.hero-poster {
  position: relative;
  justify-self: center;
  width: min(330px, 82vw);
  aspect-ratio: 2 / 3;
  overflow: hidden;
  border: 1px solid rgba(251, 191, 36, 0.28);
  border-radius: 28px;
  background: linear-gradient(150deg, rgba(30, 41, 59, 0.9), rgba(15, 23, 42, 0.94));
  box-shadow: 0 34px 80px rgba(0, 0, 0, 0.45), var(--shadow-glow);
}

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

.hero-poster:hover img {
  transform: scale(1.05);
}

.hero-poster span {
  position: absolute;
  right: 1rem;
  bottom: 1rem;
  padding: 0.35rem 0.7rem;
  border-radius: 999px;
  color: var(--golden-300);
  background: rgba(0, 0, 0, 0.72);
}

.hero-controls {
  position: absolute;
  z-index: 5;
  left: 50%;
  bottom: 32px;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.8rem;
}

.hero-arrow,
.hero-dot {
  border: 0;
  cursor: pointer;
}

.hero-arrow {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 999px;
  color: var(--lunar-100);
  background: rgba(15, 23, 42, 0.72);
  border: 1px solid var(--card-border);
}

.hero-arrow:hover {
  color: var(--golden-400);
}

.hero-dots {
  display: flex;
  gap: 0.42rem;
}

.hero-dot {
  width: 10px;
  height: 10px;
  border-radius: 99px;
  background: rgba(212, 212, 212, 0.38);
}

.hero-dot.is-active {
  width: 32px;
  background: var(--golden-400);
}

.section {
  padding: 4.5rem 0;
}

.section-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.4rem;
}

.section-head h2,
.rank-panel h2,
.detail-article h2 {
  margin: 0.15rem 0 0;
  font-size: clamp(1.55rem, 3vw, 2.4rem);
  line-height: 1.08;
}

.section-link {
  color: var(--golden-400);
  font-weight: 700;
}

.movie-grid {
  display: grid;
  gap: 1rem;
}

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

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

.movie-card {
  overflow: hidden;
  border: 1px solid var(--card-border);
  border-radius: 18px;
  background: rgba(15, 23, 42, 0.64);
  box-shadow: 0 0 0 rgba(0, 0, 0, 0);
  transition: transform 0.24s ease, border-color 0.24s ease, box-shadow 0.24s ease, background 0.24s ease;
}

.movie-card:hover {
  transform: translateY(-5px);
  border-color: rgba(251, 191, 36, 0.46);
  background: rgba(30, 41, 59, 0.62);
  box-shadow: var(--shadow-lunar);
}

.poster-wrap {
  position: relative;
  margin: 0;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  background: linear-gradient(150deg, var(--moonlight-800), var(--moonlight-900));
}

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

.poster-wrap img.image-missing,
.hero-poster img.image-missing,
.detail-poster img.image-missing,
.category-card img.image-missing,
.ranking-row img.image-missing,
.rank-item img.image-missing {
  opacity: 0;
}

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

.poster-shade {
  position: absolute;
  inset: 0;
  opacity: 0;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.82), rgba(0, 0, 0, 0.12));
  transition: opacity 0.24s ease;
}

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

.play-badge {
  position: absolute;
  inset: 50% auto auto 50%;
  transform: translate(-50%, -50%) scale(0.95);
  opacity: 0;
  display: grid;
  place-items: center;
  width: 58px;
  height: 58px;
  border-radius: 999px;
  color: var(--moonlight-950);
  background: var(--golden-400);
  font-size: 0.86rem;
  font-weight: 800;
  transition: opacity 0.24s ease, transform 0.24s ease;
}

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

.type-badge {
  position: absolute;
  top: 0.7rem;
  left: 0.7rem;
  padding: 0.18rem 0.52rem;
  border-radius: 999px;
  color: var(--golden-300);
  background: rgba(120, 53, 15, 0.78);
  font-size: 0.72rem;
  font-weight: 700;
}

.card-body {
  padding: 0.95rem;
}

.card-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
  color: var(--lunar-400);
  font-size: 0.76rem;
}

.card-meta .score,
.ranking-score {
  color: var(--golden-400);
}

.card-body h3 {
  margin: 0.45rem 0 0.35rem;
  color: var(--lunar-100);
  font-size: 1rem;
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.movie-card:hover h3 {
  color: var(--golden-400);
}

.card-body p {
  margin: 0;
  min-height: 3.2em;
  color: var(--lunar-400);
  font-size: 0.86rem;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.card-tags {
  margin-top: 0.78rem;
}

.card-tags span {
  min-height: 22px;
  font-size: 0.68rem;
}

.movie-card.compact {
  display: grid;
  grid-template-columns: 34% 1fr;
  min-height: 170px;
}

.movie-card.compact .poster-wrap {
  height: 100%;
  aspect-ratio: auto;
}

.movie-card.compact .card-body {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.category-chip-grid,
.category-card-grid {
  display: grid;
  gap: 1rem;
}

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

.category-chip {
  min-height: 158px;
  padding: 1.2rem;
  border: 1px solid var(--card-border);
  border-radius: 22px;
  background:
    radial-gradient(circle at top right, rgba(251, 191, 36, 0.16), transparent 60%),
    rgba(15, 23, 42, 0.66);
  transition: transform 0.22s ease, border-color 0.22s ease;
}

.category-chip:hover {
  transform: translateY(-4px);
  border-color: rgba(251, 191, 36, 0.42);
}

.category-chip strong {
  display: block;
  margin-bottom: 0.6rem;
  font-size: 1.2rem;
}

.category-chip span {
  color: var(--lunar-400);
  font-size: 0.92rem;
}

.split-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 330px;
  gap: 1.25rem;
  align-items: start;
}

.rank-panel {
  position: sticky;
  top: 86px;
  padding: 1.2rem;
  border: 1px solid var(--card-border);
  border-radius: 24px;
  background: rgba(15, 23, 42, 0.72);
}

.rank-list {
  display: grid;
  gap: 0.65rem;
  margin-top: 1rem;
}

.rank-item {
  display: grid;
  grid-template-columns: 34px 54px 1fr;
  gap: 0.75rem;
  align-items: center;
  padding: 0.55rem;
  border-radius: 14px;
  background: rgba(30, 41, 59, 0.45);
}

.rank-item:hover {
  background: rgba(30, 41, 59, 0.8);
}

.rank-num {
  color: var(--golden-400);
  font-weight: 900;
}

.rank-item img {
  width: 54px;
  height: 72px;
  border-radius: 10px;
  object-fit: cover;
  background: var(--moonlight-800);
}

.rank-text strong,
.rank-text em {
  display: block;
}

.rank-text strong {
  color: var(--lunar-100);
  font-size: 0.92rem;
}

.rank-text em {
  color: var(--lunar-400);
  font-size: 0.76rem;
  font-style: normal;
}

.filter-panel {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) auto;
  gap: 1rem;
  align-items: center;
  margin-bottom: 1.15rem;
  padding: 0.9rem;
  border: 1px solid var(--card-border);
  border-radius: 18px;
  background: rgba(15, 23, 42, 0.62);
}

.search-box,
.global-search-box {
  display: grid;
  gap: 0.35rem;
  color: var(--lunar-300);
  font-size: 0.85rem;
}

.search-box input,
.global-search-box input {
  width: 100%;
  border: 1px solid var(--moonlight-700);
  border-radius: 14px;
  outline: none;
  padding: 0.8rem 0.95rem;
  color: var(--lunar-100);
  background: rgba(2, 6, 23, 0.5);
}

.search-box input:focus,
.global-search-box input:focus {
  border-color: rgba(251, 191, 36, 0.55);
  box-shadow: 0 0 0 4px rgba(251, 191, 36, 0.08);
}

.filter-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  justify-content: flex-end;
}

.filter-buttons button {
  border: 1px solid var(--card-border);
  border-radius: 999px;
  padding: 0.55rem 0.78rem;
  color: var(--lunar-300);
  background: rgba(30, 41, 59, 0.46);
  cursor: pointer;
}

.filter-buttons button:hover,
.filter-buttons button.is-active {
  color: var(--moonlight-950);
  border-color: var(--golden-400);
  background: var(--golden-400);
}

.empty-state {
  margin: 1rem 0;
  padding: 1rem;
  border: 1px dashed rgba(251, 191, 36, 0.4);
  border-radius: 16px;
  color: var(--golden-300);
  background: rgba(120, 53, 15, 0.15);
}

.page-hero,
.detail-hero {
  position: relative;
  overflow: hidden;
  min-height: 360px;
  display: grid;
  align-items: center;
  background:
    linear-gradient(90deg, rgba(2, 6, 23, 0.98), rgba(2, 6, 23, 0.78)),
    var(--page-hero-image, none) center / cover no-repeat,
    var(--moonlight-900);
}

.compact-page-hero {
  min-height: 300px;
}

.page-hero-inner {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 1rem;
}

.page-hero h1,
.compact-page-hero h1,
.detail-copy h1 {
  margin: 0.35rem 0 0.65rem;
  font-size: clamp(2.3rem, 6vw, 4.4rem);
  line-height: 1;
  letter-spacing: -0.05em;
}

.page-hero p {
  max-width: 760px;
  margin: 0;
  color: var(--lunar-300);
}

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

.category-card {
  position: relative;
  min-height: 260px;
  overflow: hidden;
  border: 1px solid var(--card-border);
  border-radius: 26px;
  background: var(--moonlight-800);
}

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

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

.category-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.88), rgba(0, 0, 0, 0.12));
}

.category-card strong,
.category-card em {
  position: absolute;
  left: 1.1rem;
  right: 1.1rem;
}

.category-card strong {
  bottom: 4.6rem;
  font-size: 1.3rem;
}

.category-card em {
  bottom: 1.15rem;
  color: var(--lunar-300);
  font-size: 0.86rem;
  font-style: normal;
}

.ranking-list {
  display: grid;
  gap: 0.7rem;
}

.ranking-row {
  display: grid;
  grid-template-columns: 56px 72px minmax(0, 1fr) auto 80px;
  gap: 1rem;
  align-items: center;
  padding: 0.75rem;
  border: 1px solid var(--card-border);
  border-radius: 18px;
  background: rgba(15, 23, 42, 0.62);
}

.ranking-row:hover {
  border-color: rgba(251, 191, 36, 0.45);
  background: rgba(30, 41, 59, 0.62);
}

.ranking-number {
  color: var(--golden-400);
  font-size: 1.45rem;
  font-weight: 900;
  text-align: center;
}

.ranking-row img {
  width: 72px;
  height: 96px;
  border-radius: 12px;
  object-fit: cover;
  background: var(--moonlight-800);
}

.ranking-title strong,
.ranking-title em {
  display: block;
}

.ranking-title strong {
  font-size: 1.08rem;
}

.ranking-title em,
.ranking-meta {
  color: var(--lunar-400);
  font-size: 0.88rem;
  font-style: normal;
}

.global-search-box {
  max-width: 720px;
  margin-top: 1.4rem;
}

.detail-hero {
  min-height: 560px;
  background:
    linear-gradient(90deg, rgba(2, 6, 23, 0.98), rgba(2, 6, 23, 0.82), rgba(2, 6, 23, 0.62)),
    linear-gradient(0deg, var(--moonlight-950), transparent 48%),
    var(--detail-bg) center / cover no-repeat,
    var(--moonlight-900);
}

.detail-hero-grid {
  display: grid;
  grid-template-columns: 300px minmax(0, 1fr);
  gap: clamp(1.8rem, 5vw, 4rem);
  align-items: center;
  padding: 4rem 0;
}

.detail-poster {
  position: relative;
  overflow: hidden;
  aspect-ratio: 2 / 3;
  border: 1px solid rgba(251, 191, 36, 0.28);
  border-radius: 26px;
  background: var(--moonlight-800);
  box-shadow: var(--shadow-lunar), var(--shadow-glow);
}

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

.detail-poster span {
  position: absolute;
  right: 0.9rem;
  bottom: 0.9rem;
  padding: 0.25rem 0.62rem;
  border-radius: 999px;
  color: var(--golden-300);
  background: rgba(0, 0, 0, 0.72);
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  color: var(--lunar-400);
  font-size: 0.9rem;
}

.breadcrumb a {
  color: var(--golden-400);
}

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

.detail-one-line {
  max-width: 820px;
  margin: 0 0 1rem;
  color: var(--lunar-200);
  font-size: 1.1rem;
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
}

.detail-meta span {
  padding: 0.35rem 0.68rem;
  border: 1px solid var(--card-border);
  border-radius: 999px;
  color: var(--lunar-300);
  background: rgba(15, 23, 42, 0.55);
}

.detail-copy .btn {
  margin-top: 1.6rem;
}

.player-shell {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(251, 191, 36, 0.25);
  border-radius: 24px;
  background: #000;
  box-shadow: var(--shadow-lunar);
}

.movie-player {
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #000;
}

.player-overlay {
  position: absolute;
  inset: 0;
  z-index: 4;
  display: grid;
  place-content: center;
  gap: 0.75rem;
  border: 0;
  color: var(--lunar-50);
  background: radial-gradient(circle, rgba(0, 0, 0, 0.18), rgba(0, 0, 0, 0.66));
  cursor: pointer;
  text-align: center;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

.player-shell.is-playing .player-overlay,
.player-shell.is-ready .player-overlay.is-hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.big-play {
  display: grid;
  place-items: center;
  width: 86px;
  height: 86px;
  margin-inline: auto;
  border-radius: 999px;
  color: var(--moonlight-950);
  background: linear-gradient(135deg, var(--golden-300), var(--golden-500));
  box-shadow: var(--shadow-glow);
  font-size: 2rem;
}

.player-message {
  position: absolute;
  left: 1rem;
  bottom: 1rem;
  z-index: 5;
  margin: 0;
  color: var(--golden-300);
  background: rgba(0, 0, 0, 0.62);
  border-radius: 999px;
  padding: 0.4rem 0.7rem;
  font-size: 0.84rem;
}

.player-message:empty {
  display: none;
}

.detail-text-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(280px, 0.8fr);
  gap: 1rem;
}

.detail-article {
  padding: 1.3rem;
  border: 1px solid var(--card-border);
  border-radius: 22px;
  background: rgba(15, 23, 42, 0.62);
}

.detail-article p:last-child {
  margin-bottom: 0;
  color: var(--lunar-300);
}

.site-footer {
  margin-top: 4rem;
  border-top: 1px solid var(--moonlight-800);
  background: rgba(15, 23, 42, 0.78);
}

.footer-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(160px, 0.5fr) minmax(240px, 0.8fr);
  gap: 2rem;
  padding: 3rem 0;
}

.footer-logo {
  margin-bottom: 1rem;
}

.footer-text {
  max-width: 460px;
  color: var(--lunar-400);
}

.site-footer h2 {
  margin: 0 0 0.8rem;
  font-size: 1rem;
}

.footer-links {
  display: grid;
  gap: 0.45rem;
}

.footer-links.two-col {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.footer-links a {
  color: var(--lunar-400);
  font-size: 0.92rem;
}

.footer-links a:hover {
  color: var(--golden-400);
}

.footer-bottom {
  padding: 1rem 0 1.5rem;
  border-top: 1px solid var(--moonlight-800);
  color: var(--lunar-400);
  text-align: center;
  font-size: 0.9rem;
}

[hidden] {
  display: none !important;
}

@media (max-width: 1120px) {
  .featured-grid,
  .category-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .latest-grid,
  .related-grid,
  .search-grid,
  .category-chip-grid,
  .category-card-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

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

  .rank-panel {
    position: static;
  }
}

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

  .menu-toggle {
    display: flex;
  }

  .hero-carousel {
    min-height: 720px;
  }

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

  .hero-poster,
  .detail-poster {
    width: min(260px, 74vw);
  }

  .hero-content-grid {
    padding-top: 3rem;
  }

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

  .filter-buttons {
    justify-content: flex-start;
  }

  .featured-grid,
  .category-grid,
  .latest-grid,
  .related-grid,
  .search-grid,
  .category-chip-grid,
  .category-card-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

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

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

  .page-hero-inner {
    align-items: flex-start;
    flex-direction: column;
  }
}

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

  .hero-carousel {
    min-height: 690px;
  }

  .hero-copy h1,
  .page-hero h1,
  .detail-copy h1 {
    font-size: 2.4rem;
  }

  .featured-grid,
  .category-grid,
  .latest-grid,
  .related-grid,
  .search-grid,
  .category-chip-grid,
  .category-card-grid {
    grid-template-columns: 1fr;
  }

  .movie-card.compact {
    grid-template-columns: 38% 1fr;
  }

  .section {
    padding: 3rem 0;
  }
}
