:root {
  --bg: #020617;
  --bg-soft: #0f172a;
  --panel: rgba(15, 23, 42, 0.76);
  --panel-strong: rgba(15, 23, 42, 0.94);
  --line: rgba(148, 163, 184, 0.22);
  --text: #f8fafc;
  --muted: #94a3b8;
  --cyan: #22d3ee;
  --blue: #3b82f6;
  --amber: #f59e0b;
  --radius-xl: 28px;
  --radius-lg: 20px;
  --shadow: 0 24px 70px rgba(2, 6, 23, 0.55);
  color-scheme: dark;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at top left, rgba(34, 211, 238, 0.18), transparent 30rem),
    radial-gradient(circle at 80% 10%, rgba(59, 130, 246, 0.18), transparent 32rem),
    linear-gradient(180deg, #020617 0%, #0f172a 48%, #020617 100%);
  color: var(--text);
  font-family: Inter, "PingFang SC", "Microsoft YaHei", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

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

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

button,
input,
select {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  border-bottom: 1px solid var(--line);
  background: rgba(2, 6, 23, 0.86);
  backdrop-filter: blur(18px);
}

.header-inner {
  width: min(1440px, calc(100% - 32px));
  height: 72px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 22px;
}

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

.brand-mark {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--cyan), var(--blue));
  box-shadow: 0 0 30px rgba(34, 211, 238, 0.42);
  color: #00111a;
}

.brand-text {
  font-size: 1.35rem;
  background: linear-gradient(90deg, #ffffff, var(--cyan));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

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

.main-nav a,
.mobile-nav a {
  padding: 10px 14px;
  border-radius: 14px;
  color: #cbd5e1;
  transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.main-nav a:hover,
.mobile-nav a:hover {
  background: rgba(34, 211, 238, 0.14);
  color: #ffffff;
  transform: translateY(-1px);
}

.header-search {
  display: flex;
  align-items: center;
  gap: 8px;
  width: min(320px, 25vw);
}

.header-search input,
.hero-search input,
.toolbar input,
.toolbar select {
  width: 100%;
  border: 1px solid var(--line);
  outline: none;
  border-radius: 16px;
  color: var(--text);
  background: rgba(15, 23, 42, 0.88);
  padding: 12px 14px;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.header-search input:focus,
.hero-search input:focus,
.toolbar input:focus,
.toolbar select:focus {
  border-color: rgba(34, 211, 238, 0.7);
  box-shadow: 0 0 0 4px rgba(34, 211, 238, 0.12);
}

.header-search button,
.hero-search button,
.primary-button,
.ghost-button {
  border: 0;
  border-radius: 16px;
  padding: 12px 18px;
  font-weight: 800;
  cursor: pointer;
  white-space: nowrap;
}

.header-search button,
.hero-search button,
.primary-button {
  background: linear-gradient(135deg, var(--cyan), var(--blue));
  color: #00111a;
  box-shadow: 0 16px 40px rgba(34, 211, 238, 0.25);
}

.ghost-button {
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.08);
  color: #ffffff;
}

.full-button {
  display: flex;
  justify-content: center;
  margin-top: 18px;
}

.menu-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(15, 23, 42, 0.82);
  color: white;
  cursor: pointer;
}

.menu-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  margin: 4px auto;
  border-radius: 4px;
  background: white;
}

.mobile-nav {
  display: none;
  width: min(1440px, calc(100% - 32px));
  margin: 0 auto 14px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(15, 23, 42, 0.92);
}

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

.hero {
  width: min(1440px, calc(100% - 32px));
  min-height: calc(100vh - 72px);
  margin: 0 auto;
  padding: 30px 0 54px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 390px;
  gap: 26px;
  align-items: stretch;
}

.hero-stage {
  position: relative;
  min-height: 620px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius-xl);
  background: #020617;
  box-shadow: var(--shadow);
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: none;
  overflow: hidden;
}

.hero-slide.is-active {
  display: block;
}

.hero-backdrop {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(90deg, rgba(2, 6, 23, 0.95), rgba(2, 6, 23, 0.66) 48%, rgba(2, 6, 23, 0.18)),
    linear-gradient(180deg, rgba(2, 6, 23, 0.04), rgba(2, 6, 23, 0.9)),
    var(--hero-image);
  background-size: cover;
  background-position: center;
  transform: scale(1.03);
  filter: saturate(1.06);
}

.hero-content {
  position: relative;
  z-index: 2;
  height: 100%;
  padding: clamp(34px, 6vw, 72px);
  display: grid;
  grid-template-columns: minmax(0, 1fr) 280px;
  gap: 34px;
  align-items: center;
}

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

.eyebrow,
.panel-kicker,
.tile-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 14px;
  color: var(--cyan);
  font-size: 0.9rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.hero h1,
.page-hero h1,
.detail-copy h1 {
  margin: 0;
  font-size: clamp(2.6rem, 6vw, 5.8rem);
  line-height: 0.98;
  letter-spacing: -0.07em;
  text-shadow: 0 24px 60px rgba(0, 0, 0, 0.52);
}

.hero p,
.page-hero p,
.detail-copy .lead {
  max-width: 760px;
  margin: 24px 0 0;
  color: #cbd5e1;
  font-size: clamp(1rem, 1.5vw, 1.22rem);
  line-height: 1.9;
}

.hero-tags,
.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 22px;
}

.hero-tags span,
.tag-row span {
  border: 1px solid rgba(34, 211, 238, 0.26);
  border-radius: 999px;
  padding: 7px 11px;
  background: rgba(34, 211, 238, 0.12);
  color: #dffbff;
  font-size: 0.82rem;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 32px;
}

.hero-poster {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.08);
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.42);
  transform: rotate(2deg);
}

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

.hero-poster span {
  position: absolute;
  left: 16px;
  bottom: 16px;
  border-radius: 999px;
  padding: 8px 12px;
  background: rgba(2, 6, 23, 0.76);
  color: white;
  font-weight: 800;
  backdrop-filter: blur(12px);
}

.hero-control-row {
  position: absolute;
  z-index: 4;
  left: clamp(28px, 6vw, 72px);
  bottom: 30px;
  display: flex;
  align-items: center;
  gap: 14px;
}

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

.hero-arrow {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: rgba(15, 23, 42, 0.8);
  border: 1px solid rgba(255, 255, 255, 0.16);
  font-size: 1.8rem;
  line-height: 1;
}

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

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

.hero-dot.is-active {
  width: 30px;
  background: var(--cyan);
}

.hero-panel,
.ranking-panel,
.side-panel,
.info-card {
  border: 1px solid var(--line);
  border-radius: var(--radius-xl);
  background: var(--panel);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}

.hero-panel {
  padding: 28px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.hero-panel h2,
.ranking-panel h2,
.side-panel h2,
.info-card h2 {
  margin: 0 0 12px;
  font-size: 1.7rem;
}

.hero-panel p,
.side-panel p,
.info-card p {
  color: var(--muted);
  line-height: 1.75;
}

.hero-search {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  margin: 20px 0;
}

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

.mini-card {
  display: grid;
  grid-template-columns: 68px 1fr;
  gap: 12px;
  align-items: center;
  padding: 10px;
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 18px;
  background: rgba(2, 6, 23, 0.34);
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.mini-card:hover {
  transform: translateX(4px);
  border-color: rgba(34, 211, 238, 0.44);
}

.mini-card img {
  width: 68px;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  border-radius: 12px;
}

.mini-card strong,
.mini-card small {
  display: block;
}

.mini-card small {
  margin-top: 5px;
  color: var(--muted);
}

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

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

.section-heading span {
  display: block;
  margin-bottom: 8px;
  color: var(--cyan);
  font-weight: 900;
  letter-spacing: 0.08em;
}

.section-heading h2 {
  margin: 0;
  font-size: clamp(1.8rem, 3vw, 3rem);
  letter-spacing: -0.04em;
}

.section-heading a {
  color: var(--cyan);
  font-weight: 800;
}

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

.category-tile {
  min-height: 230px;
  position: relative;
  overflow: hidden;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: rgba(15, 23, 42, 0.7);
  box-shadow: 0 18px 48px rgba(2, 6, 23, 0.34);
  transition: transform 0.24s ease, border-color 0.24s ease;
}

.category-tile:hover {
  transform: translateY(-6px);
  border-color: rgba(34, 211, 238, 0.52);
}

.category-tile strong {
  display: block;
  margin-bottom: 12px;
  font-size: 1.45rem;
}

.category-tile p {
  margin: 0;
  color: #cbd5e1;
  line-height: 1.7;
}

.category-tile::before {
  content: "";
  position: absolute;
  inset: -40% -30% auto auto;
  width: 180px;
  height: 180px;
  border-radius: 999px;
  opacity: 0.22;
  background: var(--tile-color, var(--cyan));
  filter: blur(10px);
}

.tone-cyan { --tile-color: #22d3ee; }
.tone-blue { --tile-color: #3b82f6; }
.tone-violet { --tile-color: #8b5cf6; }
.tone-amber { --tile-color: #f59e0b; }
.tone-rose { --tile-color: #fb7185; }
.tone-orange { --tile-color: #fb923c; }
.tone-emerald { --tile-color: #34d399; }
.tone-sky { --tile-color: #38bdf8; }
.tone-lime { --tile-color: #a3e635; }
.tone-fuchsia { --tile-color: #e879f9; }

.category-samples {
  position: absolute;
  right: 18px;
  bottom: 18px;
  display: flex;
  align-items: end;
}

.category-samples img {
  width: 44px;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  border: 2px solid rgba(255, 255, 255, 0.32);
  border-radius: 10px;
  margin-left: -10px;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.36);
}

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

.movie-card {
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 22px;
  background: rgba(15, 23, 42, 0.72);
  box-shadow: 0 18px 46px rgba(2, 6, 23, 0.24);
  transition: transform 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  border-color: rgba(34, 211, 238, 0.46);
  background: rgba(15, 23, 42, 0.94);
}

.poster-wrap {
  position: relative;
  display: block;
  overflow: hidden;
  background: rgba(15, 23, 42, 0.9);
}

.poster-wrap img {
  width: 100%;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  transition: transform 0.25s ease, filter 0.25s ease;
}

.movie-card:hover .poster-wrap img {
  transform: scale(1.045);
  filter: brightness(1.06);
}

.poster-glow {
  position: absolute;
  inset: auto 0 0;
  height: 52%;
  background: linear-gradient(180deg, transparent, rgba(2, 6, 23, 0.9));
}

.play-chip,
.rank-badge {
  position: absolute;
  z-index: 2;
  border-radius: 999px;
  font-weight: 900;
}

.play-chip {
  right: 12px;
  bottom: 12px;
  padding: 7px 11px;
  background: rgba(34, 211, 238, 0.94);
  color: #00111a;
}

.rank-badge {
  left: 12px;
  top: 12px;
  min-width: 32px;
  text-align: center;
  padding: 7px 9px;
  background: rgba(245, 158, 11, 0.94);
  color: #1f1300;
}

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

.movie-card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 9px;
  color: var(--muted);
  font-size: 0.78rem;
}

.movie-card-meta span:not(:last-child)::after {
  content: "·";
  margin-left: 6px;
  color: rgba(148, 163, 184, 0.5);
}

.movie-card h3 {
  margin: 0;
  font-size: 1.02rem;
  line-height: 1.35;
}

.movie-card h3 a:hover {
  color: var(--cyan);
}

.movie-card p {
  margin: 10px 0 0;
  color: #a8b5c7;
  font-size: 0.88rem;
  line-height: 1.65;
}

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

.ranking-panel {
  align-self: start;
  position: sticky;
  top: 96px;
  padding: 24px;
}

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

.rank-row {
  display: grid;
  grid-template-columns: 34px 1fr;
  gap: 10px;
  align-items: center;
  padding: 12px;
  border: 1px solid rgba(148, 163, 184, 0.14);
  border-radius: 14px;
  background: rgba(2, 6, 23, 0.28);
}

.rank-row span {
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  background: rgba(34, 211, 238, 0.14);
  color: var(--cyan);
  font-weight: 900;
}

.rank-row em {
  grid-column: 2;
  color: var(--muted);
  font-style: normal;
  font-size: 0.82rem;
}

.page-hero {
  width: min(1440px, calc(100% - 32px));
  margin: 0 auto;
  padding: 74px 0 42px;
}

.page-hero > div {
  position: relative;
  overflow: hidden;
  min-height: 280px;
  padding: clamp(28px, 6vw, 64px);
  border: 1px solid var(--line);
  border-radius: var(--radius-xl);
  background:
    radial-gradient(circle at 78% 22%, rgba(34, 211, 238, 0.24), transparent 26rem),
    linear-gradient(135deg, rgba(15, 23, 42, 0.96), rgba(2, 6, 23, 0.86));
  box-shadow: var(--shadow);
}

.compact-page-hero > div {
  min-height: 220px;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 18px;
  color: var(--muted);
  font-size: 0.94rem;
}

.breadcrumb a:hover {
  color: var(--cyan);
}

.catalog-layout {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  gap: 24px;
  align-items: start;
}

.side-panel {
  position: sticky;
  top: 96px;
  padding: 22px;
}

.side-links {
  display: grid;
  gap: 8px;
}

.side-link {
  padding: 12px 14px;
  border-radius: 14px;
  color: #cbd5e1;
  background: rgba(2, 6, 23, 0.28);
}

.side-link:hover {
  color: #ffffff;
  background: rgba(34, 211, 238, 0.16);
}

.toolbar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 220px;
  gap: 14px;
  margin-bottom: 16px;
}

.search-toolbar {
  grid-template-columns: minmax(0, 1fr) 240px;
}

.large-input {
  font-size: 1.05rem;
}

.chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin-bottom: 24px;
}

.filter-chip {
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 9px 13px;
  background: rgba(15, 23, 42, 0.72);
  color: #cbd5e1;
  cursor: pointer;
}

.filter-chip:hover,
.filter-chip.is-active {
  border-color: rgba(34, 211, 238, 0.58);
  background: rgba(34, 211, 238, 0.16);
  color: #ffffff;
}

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

.empty-message {
  display: none;
  margin: 40px 0;
  color: var(--muted);
  text-align: center;
  font-size: 1.08rem;
}

.empty-message.is-visible {
  display: block;
}

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

.wide-rank {
  display: grid;
  grid-template-columns: 42px 82px 1fr;
  gap: 14px;
  align-items: center;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: rgba(15, 23, 42, 0.75);
}

.wide-rank span {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--amber), #facc15);
  color: #1f1300;
  font-weight: 900;
}

.wide-rank img {
  width: 82px;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  border-radius: 14px;
}

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

.wide-rank em {
  margin-top: 8px;
  color: var(--muted);
  font-style: normal;
  line-height: 1.5;
}

.detail-shell {
  width: min(1440px, calc(100% - 32px));
  margin: 0 auto;
  padding: 34px 0 0;
}

.detail-breadcrumb {
  margin: 0 0 18px;
}

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

.detail-main,
.detail-aside,
.detail-copy,
.player-card,
.info-card {
  min-width: 0;
}

.player-card {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius-xl);
  background: black;
  box-shadow: var(--shadow);
}

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

.player-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  gap: 14px;
  border: 0;
  background:
    radial-gradient(circle, rgba(34, 211, 238, 0.18), transparent 18rem),
    linear-gradient(180deg, rgba(2, 6, 23, 0.18), rgba(2, 6, 23, 0.74));
  color: white;
  cursor: pointer;
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

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

.play-circle {
  width: 84px;
  height: 84px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--cyan), var(--blue));
  color: #00111a;
  font-size: 2rem;
  box-shadow: 0 0 44px rgba(34, 211, 238, 0.48);
}

.player-overlay strong {
  max-width: min(80%, 720px);
  text-align: center;
  font-size: clamp(1.4rem, 3vw, 2.6rem);
}

.detail-copy {
  margin-top: 22px;
  padding: clamp(22px, 4vw, 34px);
  border: 1px solid var(--line);
  border-radius: var(--radius-xl);
  background: rgba(15, 23, 42, 0.7);
}

.detail-copy h1 {
  font-size: clamp(2rem, 4vw, 4rem);
}

.detail-copy h2 {
  margin: 32px 0 12px;
  font-size: 1.45rem;
}

.detail-copy p:not(.lead) {
  margin: 0;
  color: #cbd5e1;
  line-height: 1.9;
  font-size: 1.02rem;
}

.detail-aside {
  display: grid;
  gap: 18px;
  align-self: start;
  position: sticky;
  top: 96px;
}

.detail-poster {
  width: 100%;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  border-radius: var(--radius-xl);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
}

.info-card {
  padding: 22px;
}

.info-card dl {
  display: grid;
  grid-template-columns: 72px 1fr;
  gap: 10px 12px;
  margin: 14px 0;
}

.info-card dt {
  color: var(--muted);
}

.info-card dd {
  margin: 0;
  color: #e2e8f0;
}

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

.site-footer {
  margin-top: 46px;
  border-top: 1px solid var(--line);
  background: rgba(2, 6, 23, 0.78);
}

.footer-inner {
  width: min(1440px, calc(100% - 32px));
  margin: 0 auto;
  padding: 40px 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 520px);
  gap: 34px;
}

.footer-inner p {
  max-width: 560px;
  color: var(--muted);
  line-height: 1.8;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  align-content: start;
  gap: 10px;
}

.footer-links a {
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 9px 13px;
  color: #cbd5e1;
}

.footer-links a:hover {
  color: #ffffff;
  border-color: rgba(34, 211, 238, 0.5);
}

.footer-bottom {
  width: min(1440px, calc(100% - 32px));
  margin: 0 auto;
  padding: 20px 0 30px;
  color: var(--muted);
  font-size: 0.94rem;
}

@media (max-width: 1200px) {
  .hero {
    grid-template-columns: 1fr;
  }

  .hero-panel {
    min-height: auto;
  }

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

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

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

  .ranking-panel,
  .side-panel,
  .detail-aside {
    position: static;
  }

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

@media (max-width: 820px) {
  .header-inner {
    height: 64px;
  }

  .main-nav,
  .header-search {
    display: none;
  }

  .menu-toggle {
    display: block;
    margin-left: auto;
  }

  .hero {
    min-height: auto;
    padding-top: 18px;
  }

  .hero-stage {
    min-height: 680px;
  }

  .hero-content {
    grid-template-columns: 1fr;
    align-items: end;
    padding: 28px;
  }

  .hero-poster {
    width: min(220px, 58vw);
    transform: none;
  }

  .hero-control-row {
    left: 28px;
    bottom: 22px;
  }

  .hero-search,
  .toolbar,
  .search-toolbar {
    grid-template-columns: 1fr;
  }

  .section-heading {
    display: block;
  }

  .category-grid,
  .movie-grid,
  .catalog-grid,
  .wide-rank-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

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

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

  .hero,
  .section,
  .page-hero,
  .detail-shell,
  .header-inner,
  .mobile-nav,
  .footer-inner,
  .footer-bottom {
    width: min(100% - 22px, 1440px);
  }

  .hero-stage {
    min-height: 640px;
    border-radius: 22px;
  }

  .hero h1,
  .page-hero h1 {
    font-size: 2.3rem;
    letter-spacing: -0.04em;
  }

  .category-grid,
  .movie-grid,
  .catalog-grid,
  .wide-rank-grid {
    grid-template-columns: 1fr;
  }

  .wide-rank {
    grid-template-columns: 36px 70px 1fr;
  }

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

  .poster-wrap img {
    height: 100%;
  }

  .detail-copy,
  .info-card {
    padding: 18px;
  }
}
