:root {
  --bg: #fff7ed;
  --bg-soft: #fffbeb;
  --paper: #ffffff;
  --ink: #1f2937;
  --muted: #6b7280;
  --line: #fde68a;
  --amber: #d97706;
  --amber-dark: #92400e;
  --orange: #ea580c;
  --red: #dc2626;
  --pink: #db2777;
  --shadow: 0 18px 45px rgba(120, 53, 15, 0.12);
  --shadow-soft: 0 10px 30px rgba(120, 53, 15, 0.08);
  --radius: 22px;
  --max: 1180px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

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

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

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

button,
input,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.92);
  border-bottom: 1px solid rgba(253, 230, 138, 0.85);
  box-shadow: 0 8px 28px rgba(120, 53, 15, 0.08);
  backdrop-filter: blur(16px);
}

.header-inner {
  max-width: var(--max);
  margin: 0 auto;
  min-height: 72px;
  padding: 0 20px;
  display: flex;
  align-items: center;
  gap: 24px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 22px;
  font-weight: 850;
  color: var(--amber-dark);
  white-space: nowrap;
}

.brand-icon {
  width: 38px;
  height: 38px;
  border-radius: 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  background: linear-gradient(135deg, var(--amber), var(--orange), var(--red));
  box-shadow: 0 12px 24px rgba(217, 119, 6, 0.28);
  font-size: 14px;
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-left: auto;
}

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

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

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

.header-search {
  width: 270px;
}

.site-search-form input {
  width: 100%;
  border: 1px solid #fde68a;
  background: #ffffff;
  color: var(--ink);
  border-radius: 999px;
  padding: 10px 14px;
  outline: none;
  transition: border 0.2s ease, box-shadow 0.2s ease;
}

.site-search-form input:focus,
.filter-grid input:focus,
.filter-grid select:focus {
  border-color: #f59e0b;
  box-shadow: 0 0 0 4px rgba(245, 158, 11, 0.18);
}

.site-search-form button,
.primary-btn,
.hero-watch,
.cta-band a,
.rank-action,
.filter-reset {
  border: none;
  color: #ffffff;
  border-radius: 999px;
  padding: 10px 18px;
  font-weight: 800;
  background: linear-gradient(135deg, var(--amber), var(--orange));
  box-shadow: 0 12px 26px rgba(234, 88, 12, 0.22);
  transition: transform 0.2s ease, box-shadow 0.2s ease, filter 0.2s ease;
}

.site-search-form button:hover,
.primary-btn:hover,
.hero-watch:hover,
.cta-band a:hover,
.rank-action:hover,
.filter-reset:hover {
  transform: translateY(-2px) scale(1.02);
  filter: saturate(1.08);
  box-shadow: 0 18px 32px rgba(234, 88, 12, 0.28);
}

.mobile-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: none;
  border-radius: 14px;
  background: #fff7ed;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 5px;
}

.mobile-toggle span {
  width: 20px;
  height: 2px;
  background: var(--amber-dark);
  border-radius: 99px;
}

.mobile-panel {
  display: none;
  border-top: 1px solid #fde68a;
  padding: 14px 20px 20px;
  background: rgba(255, 255, 255, 0.97);
}

.mobile-panel.open {
  display: block;
}

.mobile-panel nav {
  display: grid;
  gap: 8px;
  margin-bottom: 12px;
}

.home-hero {
  position: relative;
  overflow: hidden;
  color: #ffffff;
  background: linear-gradient(115deg, #b45309 0%, #f97316 46%, #dc2626 100%);
}

.home-hero-inner {
  position: relative;
  max-width: var(--max);
  min-height: 620px;
  margin: 0 auto;
  padding: 86px 20px 72px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(360px, 480px);
  gap: 48px;
  align-items: center;
}

.hero-glow {
  position: absolute;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.16);
  filter: blur(18px);
}

.hero-glow-one {
  width: 360px;
  height: 360px;
  left: 8%;
  top: -120px;
}

.hero-glow-two {
  width: 520px;
  height: 520px;
  right: -160px;
  bottom: -160px;
}

.eyebrow,
.hero-label,
.page-kicker {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
  color: #fffbeb;
  padding: 7px 12px;
  font-weight: 800;
  letter-spacing: 0.04em;
}

.hero-main h1 {
  margin: 22px 0 20px;
  font-size: clamp(38px, 6vw, 68px);
  line-height: 1.08;
  letter-spacing: -0.04em;
}

.hero-main p {
  max-width: 680px;
  margin: 0;
  color: #ffedd5;
  font-size: clamp(18px, 2vw, 24px);
}

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

.ghost-btn {
  border: 2px solid rgba(255, 255, 255, 0.82);
  color: #ffffff;
  border-radius: 999px;
  padding: 10px 18px;
  font-weight: 800;
  transition: background 0.2s ease, transform 0.2s ease;
}

.ghost-btn:hover {
  background: rgba(255, 255, 255, 0.12);
  transform: translateY(-2px);
}

.hero-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 28px;
}

.hero-chips a {
  border-radius: 999px;
  padding: 8px 13px;
  color: #fffbeb;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.18);
  transition: background 0.2s ease, transform 0.2s ease;
}

.hero-chips a:hover {
  background: rgba(255, 255, 255, 0.24);
  transform: translateY(-2px);
}

.hero-carousel {
  position: relative;
  min-height: 478px;
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: 1fr 180px;
  gap: 22px;
  align-items: stretch;
  opacity: 0;
  transform: translateY(18px) scale(0.98);
  pointer-events: none;
  transition: opacity 0.45s ease, transform 0.45s ease;
}

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

.hero-copy {
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 30px;
  padding: 28px;
  background: rgba(0, 0, 0, 0.22);
  box-shadow: 0 25px 70px rgba(0, 0, 0, 0.18);
  backdrop-filter: blur(18px);
}

.hero-copy h2 {
  margin: 18px 0 12px;
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1.15;
}

.hero-copy p {
  color: #ffedd5;
  margin: 0 0 16px;
}

.hero-meta,
.detail-meta,
.rank-meta,
.movie-line {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

.hero-meta span,
.detail-meta span,
.detail-meta a,
.genre-row span,
.rank-meta span {
  border-radius: 999px;
  padding: 5px 10px;
  background: rgba(255, 255, 255, 0.18);
  color: #fffbeb;
  font-size: 13px;
  font-weight: 700;
}

.hero-watch {
  display: inline-flex;
  margin-top: 22px;
  background: #ffffff;
  color: var(--amber-dark);
}

.hero-poster {
  border-radius: 28px;
  overflow: hidden;
  box-shadow: 0 26px 80px rgba(0, 0, 0, 0.32);
  background: rgba(255, 255, 255, 0.16);
}

.hero-poster img {
  width: 100%;
  height: 100%;
  min-height: 420px;
  object-fit: cover;
}

.hero-dots {
  position: absolute;
  left: 28px;
  bottom: 28px;
  display: flex;
  gap: 8px;
}

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

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

.stats-row,
.content-section,
.cta-band,
.page-hero-inner,
.detail-shell {
  max-width: var(--max);
  margin-left: auto;
  margin-right: auto;
}

.stats-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
  padding: 34px 20px 10px;
}

.stat-card {
  display: grid;
  gap: 6px;
  border-radius: var(--radius);
  padding: 24px;
  color: #ffffff;
  background: linear-gradient(135deg, #f59e0b, #ea580c);
  box-shadow: var(--shadow);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.stat-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 22px 52px rgba(120, 53, 15, 0.18);
}

.stat-card strong {
  font-size: 28px;
  line-height: 1.2;
}

.stat-card span {
  color: #ffedd5;
}

.stat-orange {
  background: linear-gradient(135deg, #f97316, #dc2626);
}

.stat-red {
  background: linear-gradient(135deg, #dc2626, #db2777);
}

.content-section {
  padding: 56px 20px 12px;
}

.alt-section {
  position: relative;
}

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

.section-head h2 {
  margin: 0;
  font-size: clamp(26px, 4vw, 36px);
  letter-spacing: -0.03em;
}

.section-head p {
  margin: 8px 0 0;
  color: var(--muted);
}

.section-link,
.text-link {
  color: var(--amber-dark);
  font-weight: 850;
}

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

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

.movie-card {
  overflow: hidden;
  border-radius: var(--radius);
  background: var(--paper);
  box-shadow: var(--shadow-soft);
  border: 1px solid rgba(253, 230, 138, 0.82);
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  border-color: #fbbf24;
  box-shadow: var(--shadow);
}

.movie-poster {
  position: relative;
  display: block;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  background: linear-gradient(135deg, #fef3c7, #fed7aa);
}

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

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

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

.year-badge,
.type-badge,
.rank-badge {
  position: absolute;
  border-radius: 999px;
  padding: 5px 9px;
  color: #ffffff;
  font-size: 12px;
  font-weight: 850;
  background: rgba(0, 0, 0, 0.62);
  backdrop-filter: blur(8px);
}

.year-badge {
  left: 10px;
  top: 10px;
}

.type-badge {
  right: 10px;
  top: 10px;
}

.rank-badge {
  left: 10px;
  bottom: 10px;
  background: linear-gradient(135deg, var(--amber), var(--red));
}

.movie-body {
  padding: 16px;
}

.movie-line {
  color: var(--muted);
  font-size: 13px;
  justify-content: space-between;
}

.category-pill {
  display: inline-flex;
  border-radius: 999px;
  padding: 4px 9px;
  color: var(--amber-dark);
  background: #fef3c7;
  font-weight: 800;
}

.movie-body h3 {
  margin: 12px 0 8px;
  font-size: 18px;
  line-height: 1.35;
}

.movie-body h3 a:hover,
.rank-title:hover,
.category-samples a:hover {
  color: var(--orange);
}

.movie-body p {
  min-height: 3.2em;
  margin: 0;
  color: var(--muted);
  font-size: 14px;
}

.movie-tags,
.detail-tags,
.tag-cloud,
.category-samples,
.genre-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.movie-tags {
  margin-top: 12px;
}

.movie-tags span,
.detail-tags a,
.tag-cloud a {
  border-radius: 999px;
  padding: 5px 9px;
  color: var(--amber-dark);
  background: #fff7ed;
  border: 1px solid #fed7aa;
  font-size: 12px;
  font-weight: 750;
}

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

.category-card,
.category-overview-card,
.detail-card,
.side-box,
.filter-panel {
  border-radius: var(--radius);
  border: 1px solid rgba(253, 230, 138, 0.82);
  background: rgba(255, 255, 255, 0.92);
  box-shadow: var(--shadow-soft);
}

.category-card {
  overflow: hidden;
  padding: 18px;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

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

.category-covers {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 6px;
  margin-bottom: 16px;
}

.category-covers img,
.category-overview-covers img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: 12px;
  background: #fef3c7;
}

.category-card h3,
.category-overview-card h2 {
  margin: 0 0 8px;
}

.category-card p,
.category-overview-card p {
  margin: 0;
  color: var(--muted);
}

.tag-section {
  padding-bottom: 50px;
}

.tag-cloud a {
  padding: 9px 13px;
  font-size: 14px;
  transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.tag-cloud a:hover {
  color: #ffffff;
  background: linear-gradient(135deg, var(--amber), var(--orange));
  transform: translateY(-2px);
}

.cta-band {
  margin-top: 60px;
  margin-bottom: 70px;
  padding: 54px 28px;
  border-radius: 34px;
  text-align: center;
  color: #ffffff;
  background: linear-gradient(135deg, #d97706, #ea580c, #dc2626);
  box-shadow: var(--shadow);
}

.cta-band h2 {
  margin: 0 0 10px;
  font-size: clamp(30px, 5vw, 44px);
}

.cta-band p {
  margin: 0 auto 24px;
  max-width: 620px;
  color: #ffedd5;
}

.cta-band a {
  display: inline-flex;
  background: #ffffff;
  color: var(--amber-dark);
}

.page-hero {
  color: #ffffff;
  background: linear-gradient(115deg, #b45309, #ea580c 54%, #dc2626);
}

.page-hero-inner {
  padding: 64px 20px;
}

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

.page-hero p {
  max-width: 760px;
  margin: 0;
  color: #ffedd5;
  font-size: 18px;
}

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

.category-overview-card {
  display: grid;
  grid-template-columns: 180px 1fr;
  gap: 20px;
  padding: 18px;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

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

.category-overview-covers {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 7px;
}

.category-samples {
  margin: 14px 0;
}

.category-samples a {
  color: var(--muted);
  font-size: 14px;
}

.filter-panel {
  margin-bottom: 24px;
  padding: 18px;
}

.filter-grid {
  display: grid;
  grid-template-columns: minmax(230px, 1fr) repeat(3, minmax(140px, 180px)) auto;
  gap: 14px;
  align-items: end;
}

.filter-grid label {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.filter-grid input,
.filter-grid select {
  width: 100%;
  border: 1px solid #fde68a;
  border-radius: 14px;
  background: #ffffff;
  color: var(--ink);
  padding: 11px 12px;
  outline: none;
}

.filter-reset {
  align-self: end;
  min-height: 46px;
}

.filter-result-count {
  min-height: 22px;
  margin-top: 12px;
  color: var(--muted);
  font-weight: 700;
}

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

.rank-item {
  display: grid;
  grid-template-columns: 90px 54px 1fr auto;
  align-items: center;
  gap: 18px;
  border-radius: 22px;
  border: 1px solid rgba(253, 230, 138, 0.82);
  background: #ffffff;
  padding: 14px;
  box-shadow: var(--shadow-soft);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.rank-item:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow);
}

.rank-poster {
  overflow: hidden;
  border-radius: 16px;
  aspect-ratio: 3 / 4;
  background: #fef3c7;
}

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

.rank-number {
  width: 48px;
  height: 48px;
  border-radius: 18px;
  display: grid;
  place-items: center;
  color: #ffffff;
  background: linear-gradient(135deg, var(--amber), var(--red));
  font-weight: 900;
  box-shadow: 0 12px 26px rgba(220, 38, 38, 0.18);
}

.rank-title {
  display: inline-flex;
  font-size: 20px;
  font-weight: 850;
}

.rank-content p {
  margin: 5px 0 10px;
  color: var(--muted);
}

.rank-meta span {
  color: var(--amber-dark);
  background: #fff7ed;
}

.rank-action {
  white-space: nowrap;
}

.detail-page {
  padding: 30px 20px 70px;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 10px 0 22px;
  color: var(--muted);
}

.breadcrumb a {
  color: var(--amber-dark);
  font-weight: 800;
}

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

.stream-player {
  position: relative;
  overflow: hidden;
  border-radius: 28px;
  background: #000000;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.24);
}

.stream-video {
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #000000;
}

.player-cover {
  position: absolute;
  inset: 0;
  border: 0;
  display: grid;
  place-items: center;
  gap: 14px;
  padding: 20px;
  color: #ffffff;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.14), rgba(0, 0, 0, 0.58));
  text-align: center;
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

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

.play-circle {
  width: 82px;
  height: 82px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  color: var(--amber-dark);
  background: #ffffff;
  font-size: 30px;
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.28);
}

.play-title {
  max-width: 90%;
  font-size: clamp(20px, 4vw, 34px);
  font-weight: 900;
  text-shadow: 0 2px 16px rgba(0, 0, 0, 0.48);
}

.player-message {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  border-radius: 16px;
  padding: 14px 18px;
  color: #ffffff;
  background: rgba(0, 0, 0, 0.72);
  font-weight: 800;
}

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

.detail-card h1 {
  margin: 0 0 14px;
  font-size: clamp(28px, 5vw, 42px);
  line-height: 1.15;
}

.detail-meta span,
.detail-meta a,
.genre-row span {
  color: var(--amber-dark);
  background: #fff7ed;
}

.detail-one-line {
  margin: 18px 0;
  color: #374151;
  font-size: 18px;
}

.prose-card h2 {
  margin: 8px 0 10px;
  font-size: 24px;
}

.prose-card p {
  margin: 0 0 24px;
  color: #374151;
  white-space: pre-line;
}

.detail-tags {
  border-top: 1px solid #fde68a;
  padding-top: 18px;
}

.detail-side {
  position: sticky;
  top: 96px;
  display: grid;
  gap: 20px;
}

.side-poster {
  overflow: hidden;
  border-radius: 28px;
  background: #fef3c7;
  box-shadow: var(--shadow);
}

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

.side-box {
  padding: 18px;
}

.side-box h2 {
  margin: 0 0 16px;
}

.side-related {
  display: grid;
  gap: 14px;
}

.side-related .movie-card {
  display: grid;
  grid-template-columns: 94px 1fr;
  border-radius: 18px;
}

.side-related .movie-poster {
  aspect-ratio: 3 / 4;
}

.side-related .movie-body {
  padding: 12px;
}

.side-related .movie-body h3 {
  font-size: 15px;
  margin: 8px 0 6px;
}

.side-related .movie-body p,
.side-related .movie-tags,
.side-related .type-badge,
.side-related .year-badge,
.side-related .poster-shade,
.side-related .rank-badge {
  display: none;
}

.movie-card.is-hidden,
.rank-item.is-hidden {
  display: none;
}

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

.footer-inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 44px 20px;
  display: grid;
  grid-template-columns: 1.3fr 1fr 1.2fr;
  gap: 34px;
}

.footer-brand {
  color: #ffffff;
}

.site-footer p {
  max-width: 360px;
  color: #fde68a;
}

.site-footer h3 {
  margin: 0 0 12px;
  color: #ffffff;
}

.site-footer a:not(.brand) {
  display: inline-flex;
  margin: 0 16px 8px 0;
  color: #fde68a;
}

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

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  padding: 16px 20px;
  text-align: center;
  color: #fed7aa;
}

@media (max-width: 1060px) {
  .header-search {
    display: none;
  }

  .home-hero-inner {
    grid-template-columns: 1fr;
    min-height: auto;
  }

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

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

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

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

  .detail-side {
    position: static;
  }
}

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

  .mobile-toggle {
    display: inline-flex;
    margin-left: auto;
  }

  .header-inner {
    min-height: 64px;
  }

  .home-hero-inner,
  .page-hero-inner {
    padding-top: 46px;
    padding-bottom: 46px;
  }

  .hero-slide {
    grid-template-columns: 1fr;
  }

  .hero-poster {
    display: none;
  }

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

  .stats-row,
  .category-grid,
  .category-overview-grid,
  .footer-inner {
    grid-template-columns: 1fr;
  }

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

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

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

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

  .rank-action {
    grid-column: 3;
    justify-self: start;
  }
}

@media (max-width: 520px) {
  .brand {
    font-size: 19px;
  }

  .brand-icon {
    width: 34px;
    height: 34px;
  }

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

  .hero-copy {
    padding: 22px;
  }

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

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

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

  .rank-number {
    position: absolute;
    margin-left: 6px;
    margin-top: 6px;
    width: 38px;
    height: 38px;
    border-radius: 14px;
  }

  .rank-content,
  .rank-action {
    grid-column: 2;
  }

  .side-related .movie-card {
    grid-template-columns: 82px 1fr;
  }
}
