:root {
  --bg: #f8fafc;
  --paper: #ffffff;
  --paper-soft: #f1f5f9;
  --text: #111827;
  --muted: #64748b;
  --line: #e5e7eb;
  --shadow: 0 18px 45px rgba(15, 23, 42, 0.10);
  --shadow-soft: 0 10px 24px rgba(15, 23, 42, 0.08);
  --radius: 22px;
  --red: #ef4444;
  --orange: #f97316;
  --yellow: #eab308;
  --green: #22c55e;
  --cyan: #06b6d4;
  --blue: #3b82f6;
  --purple: #8b5cf6;
  --pink: #ec4899;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", "PingFang SC", sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.65;
}

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

button,
input,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

main {
  min-height: 65vh;
}

.rainbow-bar {
  height: 4px;
  background: linear-gradient(90deg, #f43f5e, #fb923c, #facc15, #22c55e, #06b6d4, #3b82f6, #a855f7);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.92);
  border-bottom: 1px solid rgba(226, 232, 240, 0.8);
  backdrop-filter: blur(18px);
  box-shadow: 0 6px 24px rgba(15, 23, 42, 0.06);
}

.nav-wrap {
  width: min(1240px, calc(100% - 32px));
  height: 72px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 24px;
}

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

.logo-mark {
  width: 42px;
  height: 42px;
  display: inline-grid;
  place-items: center;
  color: #fff;
  border-radius: 14px;
  background: linear-gradient(135deg, #ef4444, #f59e0b, #22c55e, #3b82f6, #8b5cf6);
  box-shadow: 0 10px 24px rgba(59, 130, 246, 0.25);
}

.logo-text {
  font-size: 20px;
  color: #111827;
}

.nav-links {
  justify-self: center;
  display: flex;
  align-items: center;
  gap: 28px;
}

.nav-link {
  position: relative;
  font-weight: 700;
  color: #475569;
  transition: color 0.2s ease;
}

.nav-link::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -10px;
  height: 3px;
  border-radius: 999px;
  background: linear-gradient(90deg, #ef4444, #3b82f6, #8b5cf6);
  opacity: 0;
  transform: scaleX(0.5);
  transition: all 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
  color: #2563eb;
}

.nav-link:hover::after,
.nav-link.active::after {
  opacity: 1;
  transform: scaleX(1);
}

.header-search {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 4px;
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
  border-radius: 999px;
}

.header-search input {
  width: 170px;
  border: 0;
  outline: 0;
  background: transparent;
  padding: 9px 4px 9px 12px;
  color: #111827;
}

.header-search button {
  border: 0;
  padding: 8px 14px;
  color: #fff;
  border-radius: 999px;
  background: linear-gradient(135deg, #3b82f6, #8b5cf6);
  font-weight: 800;
}

.nav-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border: 0;
  background: #f1f5f9;
  border-radius: 14px;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 5px;
}

.nav-toggle span {
  width: 20px;
  height: 2px;
  background: #334155;
  border-radius: 999px;
}

.hero-shell {
  position: relative;
  min-height: 70vh;
  overflow: hidden;
  background: linear-gradient(120deg, #fb7185, #f59e0b, #22c55e, #06b6d4, #3b82f6, #8b5cf6);
}

.hero-slides {
  min-height: 70vh;
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 96px 20px 110px;
  background-image: linear-gradient(180deg, rgba(2, 6, 23, 0.35), rgba(2, 6, 23, 0.72)), var(--hero-image), linear-gradient(120deg, #fb7185, #06b6d4, #8b5cf6);
  background-size: cover;
  background-position: center;
  opacity: 0;
  transform: scale(1.04);
  transition: opacity 0.65s ease, transform 1.2s ease;
}

.hero-slide.active {
  opacity: 1;
  transform: scale(1);
  z-index: 1;
}

.hero-content {
  width: min(920px, 100%);
  text-align: center;
  color: #fff;
  text-shadow: 0 8px 28px rgba(0, 0, 0, 0.38);
}

.hero-logo-card {
  width: 96px;
  height: 96px;
  margin: 0 auto 24px;
  display: grid;
  place-items: center;
  border: 2px solid rgba(255, 255, 255, 0.34);
  border-radius: 26px;
  background: rgba(255, 255, 255, 0.15);
  box-shadow: 0 28px 65px rgba(15, 23, 42, 0.3);
  backdrop-filter: blur(14px);
}

.hero-mark {
  width: 64px;
  height: 64px;
  font-size: 28px;
}

.eyebrow {
  margin: 0 0 12px;
  font-size: 14px;
  font-weight: 900;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.88);
}

.hero-content h1 {
  margin: 0;
  font-size: clamp(36px, 7vw, 72px);
  line-height: 1.05;
  font-weight: 950;
}

.hero-content h2 {
  margin: 18px 0 10px;
  font-size: clamp(24px, 4vw, 42px);
  font-weight: 900;
}

.hero-desc {
  max-width: 760px;
  margin: 0 auto 22px;
  font-size: clamp(16px, 2vw, 22px);
  color: rgba(255, 255, 255, 0.92);
}

.hero-tags,
.detail-badges,
.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.hero-tags {
  justify-content: center;
  margin-bottom: 30px;
}

.hero-tags span,
.detail-badges span,
.tag-row span {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 800;
}

.hero-tags span,
.detail-badges span {
  color: #fff;
  background: rgba(255, 255, 255, 0.18);
  border: 1px solid rgba(255, 255, 255, 0.28);
  backdrop-filter: blur(10px);
}

.tag-row span {
  color: #475569;
  background: #eef2ff;
}

.hero-actions {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 14px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 10px 20px;
  border-radius: 999px;
  font-weight: 900;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 32px rgba(15, 23, 42, 0.16);
}

.btn-light {
  color: #111827;
  background: #fff;
}

.btn-ghost {
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.45);
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(12px);
}

.btn-dark {
  color: #fff;
  background: linear-gradient(135deg, #111827, #334155);
}

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

.hero-controls > button {
  width: 42px;
  height: 42px;
  border: 1px solid rgba(255, 255, 255, 0.42);
  color: #fff;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.16);
  font-size: 28px;
  line-height: 1;
  backdrop-filter: blur(12px);
}

.hero-dots {
  display: flex;
  gap: 9px;
}

.hero-dot {
  width: 11px;
  height: 11px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.45);
}

.hero-dot.active {
  width: 32px;
  background: #fff;
}

.section-wrap {
  width: min(1240px, calc(100% - 32px));
  margin: 0 auto;
  padding: 72px 0;
}

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

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

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

.section-kicker {
  margin: 0 0 8px;
  color: #ef4444;
  font-size: 14px;
  font-weight: 950;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.section-kicker.blue {
  color: #3b82f6;
}

.section-kicker.green {
  color: #22c55e;
}

.section-kicker.purple {
  color: #8b5cf6;
}

.section-kicker.rose {
  color: #ec4899;
}

.text-link {
  color: #2563eb;
  font-weight: 900;
}

.movie-grid {
  display: grid;
  gap: 24px;
}

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

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

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

.movie-card {
  overflow: hidden;
  background: #fff;
  border: 1px solid rgba(226, 232, 240, 0.95);
  border-radius: var(--radius);
  box-shadow: var(--shadow-soft);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

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

.poster-bg {
  position: relative;
  display: block;
  overflow: hidden;
  min-height: 0;
  background-image: linear-gradient(180deg, rgba(15, 23, 42, 0.04), rgba(15, 23, 42, 0.62)), var(--poster-image), linear-gradient(135deg, #dbeafe, #ede9fe, #fee2e2);
  background-size: cover;
  background-position: center;
}

.movie-card .poster-bg {
  aspect-ratio: 2 / 3;
}

.poster-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0), rgba(2, 6, 23, 0.42));
  opacity: 0;
  transition: opacity 0.25s ease;
}

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

.poster-year,
.rank-badge {
  position: absolute;
  z-index: 2;
  display: inline-grid;
  place-items: center;
  color: #fff;
  font-weight: 950;
  border-radius: 999px;
  backdrop-filter: blur(10px);
}

.poster-year {
  right: 12px;
  bottom: 12px;
  min-width: 54px;
  height: 30px;
  padding: 0 10px;
  background: rgba(15, 23, 42, 0.62);
}

.rank-badge {
  left: 12px;
  top: 12px;
  width: 36px;
  height: 36px;
  background: linear-gradient(135deg, #f43f5e, #f59e0b);
  box-shadow: 0 10px 24px rgba(244, 63, 94, 0.35);
}

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

.movie-meta-line {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  color: #64748b;
  font-size: 13px;
  font-weight: 800;
}

.movie-meta-line span + span::before {
  content: "·";
  margin-right: 8px;
  color: #cbd5e1;
}

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

.movie-card h3 a:hover,
.ranking-info h2 a:hover,
.category-panel li a:hover {
  color: #2563eb;
}

.movie-card p {
  min-height: 52px;
  margin: 0 0 14px;
  color: #64748b;
  font-size: 14px;
}

.movie-card.list {
  display: grid;
  grid-template-columns: 160px 1fr;
}

.movie-card.list .poster-bg {
  height: 100%;
  min-height: 220px;
  aspect-ratio: auto;
}

.movie-card.large .poster-bg {
  aspect-ratio: 16 / 10;
}

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

.category-tile,
.category-panel-main {
  position: relative;
  overflow: hidden;
  color: #fff;
  border-radius: var(--radius);
  box-shadow: var(--shadow-soft);
}

.category-tile {
  min-height: 178px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 10px;
  padding: 24px;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.category-tile:hover {
  transform: translateY(-6px) scale(1.02);
  box-shadow: var(--shadow);
}

.category-icon {
  font-size: 26px;
  opacity: 0.9;
}

.category-tile strong,
.category-panel h2 {
  font-size: 22px;
  line-height: 1.2;
}

.category-tile em,
.category-panel p {
  color: rgba(255, 255, 255, 0.86);
  font-style: normal;
  font-size: 14px;
}

.grad-red {
  background: linear-gradient(135deg, #ef4444, #fb7185);
}

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

.grad-yellow {
  background: linear-gradient(135deg, #eab308, #84cc16);
}

.grad-green {
  background: linear-gradient(135deg, #22c55e, #14b8a6);
}

.grad-cyan {
  background: linear-gradient(135deg, #06b6d4, #3b82f6);
}

.grad-blue {
  background: linear-gradient(135deg, #3b82f6, #6366f1);
}

.grad-purple {
  background: linear-gradient(135deg, #8b5cf6, #d946ef);
}

.grad-pink {
  background: linear-gradient(135deg, #ec4899, #f43f5e);
}

.grad-teal {
  background: linear-gradient(135deg, #14b8a6, #22c55e);
}

.grad-indigo {
  background: linear-gradient(135deg, #6366f1, #8b5cf6);
}

.ranking-preview {
  width: 100%;
  max-width: none;
  padding-left: max(16px, calc((100% - 1240px) / 2));
  padding-right: max(16px, calc((100% - 1240px) / 2));
  background: linear-gradient(135deg, #f5f3ff, #eff6ff, #fdf2f8);
}

.rank-preview-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.rank-preview-item {
  display: grid;
  grid-template-columns: 44px 1fr;
  gap: 12px;
  align-items: center;
  padding: 16px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.86);
  box-shadow: var(--shadow-soft);
}

.rank-preview-item span {
  grid-row: span 2;
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  color: #fff;
  border-radius: 14px;
  background: linear-gradient(135deg, #ef4444, #8b5cf6);
  font-weight: 950;
}

.rank-preview-item strong {
  font-size: 17px;
}

.rank-preview-item em {
  color: #64748b;
  font-style: normal;
  font-size: 13px;
}

.spotlight-section {
  background: var(--bg);
}

.page-hero {
  position: relative;
  color: #fff;
  background: linear-gradient(120deg, #ef4444, #f59e0b, #22c55e, #06b6d4, #3b82f6, #8b5cf6);
}

.compact-hero {
  min-height: 300px;
  display: grid;
  place-items: center;
  text-align: center;
  padding: 72px 20px;
}

.page-hero-inner {
  width: min(860px, 100%);
}

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

.page-hero p:not(.eyebrow) {
  margin: 0 auto;
  max-width: 720px;
  color: rgba(255, 255, 255, 0.88);
  font-size: 18px;
}

.filter-panel {
  margin-bottom: 28px;
  padding: 22px;
  border: 1px solid rgba(226, 232, 240, 0.95);
  border-radius: var(--radius);
  background: #fff;
  box-shadow: var(--shadow-soft);
}

.filter-row {
  display: grid;
  grid-template-columns: minmax(240px, 1fr) repeat(3, minmax(160px, 220px));
  gap: 14px;
}

.filter-row label {
  display: grid;
  gap: 8px;
  color: #475569;
  font-size: 14px;
  font-weight: 900;
}

.filter-row input,
.filter-row select {
  width: 100%;
  height: 46px;
  border: 1px solid #dbe3ef;
  border-radius: 14px;
  background: #f8fafc;
  outline: 0;
  padding: 0 14px;
  color: #111827;
}

.filter-row input:focus,
.filter-row select:focus {
  border-color: #3b82f6;
  box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.14);
}

.empty-result {
  display: none;
  margin-top: 18px;
  padding: 22px;
  color: #64748b;
  text-align: center;
  border-radius: 16px;
  background: #f8fafc;
}

.empty-result.show {
  display: block;
}

.movie-card.hidden {
  display: none;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 22px;
  color: #64748b;
  font-size: 14px;
  font-weight: 800;
}

.breadcrumb a:hover {
  color: #2563eb;
}

.breadcrumb.light {
  color: rgba(255, 255, 255, 0.82);
}

.breadcrumb.light a:hover {
  color: #fff;
}

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

.category-panel {
  overflow: hidden;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.category-panel-main {
  display: block;
  padding: 28px;
  border-radius: 0;
}

.category-panel h2,
.category-panel p {
  margin: 0;
}

.category-panel h2 {
  margin-top: 10px;
  margin-bottom: 8px;
  color: #fff;
}

.category-panel ul {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin: 0;
  padding: 18px;
  list-style: none;
  background: #fff;
}

.category-panel li a {
  display: block;
  padding: 10px 12px;
  color: #334155;
  border-radius: 12px;
  background: #f8fafc;
  font-weight: 800;
}

.ranking-hero {
  background: linear-gradient(135deg, #111827, #312e81, #7e22ce);
}

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

.ranking-row {
  display: grid;
  grid-template-columns: 124px 1fr auto;
  align-items: center;
  gap: 18px;
  padding: 14px;
  border: 1px solid rgba(226, 232, 240, 0.95);
  border-radius: var(--radius);
  background: #fff;
  box-shadow: var(--shadow-soft);
}

.ranking-poster {
  width: 124px;
  aspect-ratio: 2 / 3;
  border-radius: 18px;
}

.ranking-info h2 {
  margin: 0 0 8px;
  font-size: 22px;
}

.ranking-info p {
  margin: 0 0 12px;
  color: #64748b;
}

.detail-hero {
  position: relative;
  display: grid;
  place-items: end start;
  min-height: 480px;
  padding: 96px max(16px, calc((100% - 1240px) / 2)) 52px;
  color: #fff;
  background-image: linear-gradient(90deg, rgba(2, 6, 23, 0.92), rgba(15, 23, 42, 0.52), rgba(15, 23, 42, 0.85)), var(--hero-image), linear-gradient(135deg, #111827, #1d4ed8, #7e22ce);
  background-size: cover;
  background-position: center;
}

.detail-hero-inner {
  width: min(940px, 100%);
}

.detail-hero h1 {
  margin: 0 0 14px;
  font-size: clamp(36px, 6vw, 64px);
  line-height: 1.08;
}

.detail-hero p {
  max-width: 820px;
  margin: 0 0 20px;
  color: rgba(255, 255, 255, 0.9);
  font-size: 18px;
}

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

.video-frame {
  position: relative;
  overflow: hidden;
  border-radius: 26px;
  background: #020617;
  box-shadow: var(--shadow);
  aspect-ratio: 16 / 9;
}

.movie-video {
  width: 100%;
  height: 100%;
  display: block;
  background: #020617;
}

.player-overlay {
  position: absolute;
  inset: 0;
  z-index: 3;
  display: grid;
  place-content: center;
  gap: 14px;
  border: 0;
  color: #fff;
  background: radial-gradient(circle, rgba(59, 130, 246, 0.22), rgba(2, 6, 23, 0.82));
  text-align: center;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

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

.play-icon {
  width: 86px;
  height: 86px;
  display: grid;
  place-items: center;
  margin: 0 auto;
  padding-left: 5px;
  border-radius: 999px;
  color: #111827;
  background: #fff;
  font-size: 34px;
  box-shadow: 0 18px 40px rgba(255, 255, 255, 0.25);
}

.player-overlay strong {
  font-size: 22px;
}

.detail-article {
  margin-top: 28px;
  padding: 30px;
  border: 1px solid rgba(226, 232, 240, 0.95);
  border-radius: var(--radius);
  background: #fff;
  box-shadow: var(--shadow-soft);
}

.detail-article h2 {
  margin: 0 0 12px;
  font-size: 26px;
}

.detail-article h2:not(:first-child) {
  margin-top: 28px;
}

.detail-article p {
  margin: 0;
  color: #334155;
  font-size: 17px;
}

.movie-side {
  position: sticky;
  top: 96px;
  display: grid;
  gap: 18px;
}

.detail-poster {
  aspect-ratio: 2 / 3;
  border-radius: 24px;
  box-shadow: var(--shadow);
}

.side-card {
  padding: 22px;
  border-radius: var(--radius);
  background: #fff;
  box-shadow: var(--shadow-soft);
}

.side-card h2 {
  margin: 0 0 16px;
  font-size: 24px;
}

.side-card dl {
  display: grid;
  gap: 10px;
  margin: 0 0 18px;
}

.side-card dl div {
  display: grid;
  grid-template-columns: 58px 1fr;
  gap: 12px;
  padding-bottom: 10px;
  border-bottom: 1px solid #eef2f7;
}

.side-card dt {
  color: #94a3b8;
  font-weight: 900;
}

.side-card dd {
  margin: 0;
  color: #334155;
  font-weight: 800;
}

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

.site-footer {
  color: #cbd5e1;
  background: #0f172a;
}

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

.footer-logo .logo-text {
  color: #fff;
}

.footer-brand p,
.footer-col p {
  margin: 16px 0 0;
  color: #94a3b8;
}

.footer-col h2 {
  margin: 0 0 14px;
  color: #fff;
  font-size: 18px;
}

.footer-col ul {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.footer-col a:hover {
  color: #fff;
}

.footer-bottom {
  width: min(1240px, calc(100% - 32px));
  margin: 0 auto;
  padding: 22px 0;
  color: #94a3b8;
  border-top: 1px solid rgba(148, 163, 184, 0.18);
  font-size: 14px;
}

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

  .nav-wrap {
    grid-template-columns: auto 1fr auto;
  }

  .nav-links {
    justify-self: end;
  }

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

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

  .movie-side {
    position: static;
    grid-template-columns: 220px 1fr;
  }

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

@media (max-width: 820px) {
  .nav-toggle {
    display: flex;
    justify-self: end;
  }

  .nav-wrap {
    height: auto;
    min-height: 70px;
    grid-template-columns: auto auto;
    padding: 13px 0;
  }

  .nav-links {
    grid-column: 1 / -1;
    width: 100%;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding-top: 12px;
  }

  .nav-links.open {
    display: flex;
  }

  .nav-link {
    padding: 13px 4px;
    border-top: 1px solid #e2e8f0;
  }

  .nav-link::after {
    display: none;
  }

  .hero-shell,
  .hero-slides {
    min-height: 76vh;
  }

  .hero-slide {
    padding-top: 88px;
  }

  .hero-logo-card {
    width: 78px;
    height: 78px;
  }

  .hero-mark {
    width: 52px;
    height: 52px;
  }

  .section-wrap,
  .white-section,
  .ranking-preview {
    padding-top: 48px;
    padding-bottom: 48px;
  }

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

  .three-cols,
  .four-cols,
  .list-grid,
  .category-grid,
  .rank-preview-list,
  .category-panel-grid {
    grid-template-columns: 1fr;
  }

  .movie-card.list {
    grid-template-columns: 130px 1fr;
  }

  .movie-card.list .poster-bg {
    min-height: 190px;
  }

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

  .ranking-row {
    grid-template-columns: 96px 1fr;
  }

  .ranking-row .btn {
    grid-column: 1 / -1;
  }

  .ranking-poster {
    width: 96px;
  }

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

  .detail-poster {
    max-width: 260px;
  }

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

@media (max-width: 560px) {
  .section-wrap,
  .white-section,
  .ranking-preview {
    width: min(100% - 24px, 1240px);
    padding-left: 0;
    padding-right: 0;
  }

  .hero-actions {
    flex-direction: column;
  }

  .btn {
    width: 100%;
  }

  .hero-controls {
    gap: 10px;
  }

  .hero-controls > button {
    width: 38px;
    height: 38px;
  }

  .movie-card.list {
    display: block;
  }

  .movie-card.list .poster-bg {
    min-height: 0;
    aspect-ratio: 2 / 3;
  }

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

  .detail-hero {
    min-height: 440px;
    padding-top: 84px;
  }

  .detail-article,
  .side-card {
    padding: 22px;
  }
}
