:root {
  --slate-950: #020617;
  --slate-900: #0f172a;
  --slate-800: #1e293b;
  --slate-700: #334155;
  --slate-600: #475569;
  --slate-500: #64748b;
  --slate-200: #e2e8f0;
  --slate-100: #f1f5f9;
  --emerald-700: #047857;
  --emerald-600: #059669;
  --emerald-500: #10b981;
  --emerald-100: #d1fae5;
  --teal-500: #14b8a6;
  --white: #ffffff;
  --shadow-soft: 0 18px 45px rgba(15, 23, 42, 0.12);
  --shadow-card: 0 12px 30px rgba(15, 23, 42, 0.1);
  --radius-lg: 18px;
  --radius-xl: 28px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--slate-900);
  background: #f8fafc;
  font-family: Inter, "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
  line-height: 1.6;
}

body.menu-open {
  overflow: hidden;
}

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

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

button,
input {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  color: #fff;
  background: rgba(15, 23, 42, 0.96);
  border-bottom: 1px solid rgba(148, 163, 184, 0.18);
  backdrop-filter: blur(18px);
}

.nav-shell {
  width: min(1180px, calc(100% - 32px));
  min-height: 72px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 24px;
}

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

.brand-mark {
  width: 34px;
  height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  color: #fff;
  background: linear-gradient(135deg, var(--emerald-500), var(--teal-500));
  box-shadow: 0 12px 28px rgba(16, 185, 129, 0.28);
}

.brand-name {
  white-space: nowrap;
  font-size: 18px;
}

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

.nav-link {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 0 14px;
  border: 0;
  border-radius: 12px;
  color: #e2e8f0;
  background: transparent;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease;
}

.nav-link:hover,
.nav-link.is-current {
  color: #fff;
  background: rgba(148, 163, 184, 0.16);
}

.nav-dropdown {
  position: relative;
}

.drop-panel {
  position: absolute;
  top: calc(100% + 12px);
  left: 0;
  width: 210px;
  padding: 10px;
  display: grid;
  gap: 4px;
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 16px;
  background: rgba(15, 23, 42, 0.98);
  box-shadow: var(--shadow-soft);
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
  transition: opacity 0.18s ease, transform 0.18s ease, visibility 0.18s ease;
}

.drop-panel a {
  padding: 9px 12px;
  border-radius: 12px;
  color: #e2e8f0;
}

.drop-panel a:hover {
  color: #fff;
  background: rgba(148, 163, 184, 0.14);
}

.nav-dropdown:hover .drop-panel,
.nav-dropdown:focus-within .drop-panel {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

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

.nav-search input,
.mobile-search input {
  width: 230px;
  height: 40px;
  padding: 0 14px;
  color: #fff;
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 12px;
  outline: 0;
  background: rgba(51, 65, 85, 0.78);
}

.nav-search input:focus,
.mobile-search input:focus,
.filter-input:focus,
.hero-search input:focus {
  border-color: var(--emerald-500);
  box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.18);
}

.nav-search button,
.mobile-search button,
.hero-search button {
  height: 40px;
  padding: 0 14px;
  border: 0;
  border-radius: 12px;
  color: #fff;
  background: var(--emerald-600);
  cursor: pointer;
}

.menu-button {
  display: none;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 12px;
  color: #fff;
  background: rgba(148, 163, 184, 0.14);
  cursor: pointer;
}

.mobile-panel {
  display: none;
  padding: 16px;
  border-top: 1px solid rgba(148, 163, 184, 0.16);
  background: var(--slate-900);
}

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

.mobile-search {
  display: flex;
  gap: 8px;
  margin-bottom: 14px;
}

.mobile-search input {
  flex: 1;
  width: auto;
}

.mobile-link {
  display: block;
  padding: 12px 14px;
  border-radius: 12px;
  color: #e2e8f0;
}

.mobile-link:hover,
.mobile-link.is-current {
  color: #fff;
  background: rgba(148, 163, 184, 0.14);
}

.mobile-category-title {
  padding: 12px 14px 8px;
  color: #6ee7b7;
  font-weight: 700;
}

.mobile-category-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  padding: 0 14px 6px;
}

.mobile-category-grid a {
  padding: 10px 12px;
  border-radius: 12px;
  color: #e2e8f0;
  background: rgba(148, 163, 184, 0.1);
}

.hero-carousel {
  position: relative;
  min-height: 670px;
  overflow: hidden;
  color: #fff;
  background: var(--slate-950);
}

.hero-stage,
.hero-slide {
  position: absolute;
  inset: 0;
}

.hero-slide {
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.7s ease;
}

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

.hero-bg,
.detail-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.03);
}

.hero-shade,
.detail-shade {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(2, 6, 23, 0.94) 0%, rgba(15, 23, 42, 0.72) 42%, rgba(15, 23, 42, 0.24) 100%),
    linear-gradient(0deg, rgba(2, 6, 23, 0.88) 0%, rgba(2, 6, 23, 0) 45%);
}

.hero-inner {
  position: relative;
  z-index: 2;
  width: min(1180px, calc(100% - 32px));
  height: 100%;
  margin: 0 auto;
  display: flex;
  align-items: center;
}

.hero-copy {
  max-width: 680px;
  padding-top: 40px;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  margin-bottom: 16px;
  padding: 7px 12px;
  border: 1px solid rgba(16, 185, 129, 0.36);
  border-radius: 999px;
  color: #a7f3d0;
  background: rgba(16, 185, 129, 0.13);
  font-size: 14px;
  font-weight: 700;
}

.hero-copy h1,
.hero-copy h2,
.page-hero h1,
.detail-copy h1 {
  margin: 0;
  line-height: 1.08;
  font-weight: 900;
  letter-spacing: -0.04em;
}

.hero-copy h1,
.hero-copy h2 {
  max-width: 760px;
  font-size: clamp(42px, 7vw, 86px);
}

.hero-copy h3 {
  margin: 18px 0 0;
  color: #ecfdf5;
  font-size: clamp(26px, 3vw, 40px);
}

.hero-copy p,
.page-hero p,
.detail-copy p {
  max-width: 760px;
  margin: 20px 0 0;
  color: #cbd5e1;
  font-size: 18px;
}

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

.hero-tags {
  margin-top: 24px;
}

.hero-tags span,
.tag-row span {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  font-size: 13px;
}

.hero-tags span {
  padding: 6px 11px;
  color: #fff;
  background: rgba(255, 255, 255, 0.18);
  backdrop-filter: blur(12px);
}

.tag-row span {
  padding: 4px 8px;
  color: var(--slate-600);
  background: var(--slate-100);
}

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

.btn-primary,
.btn-ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 24px;
  border-radius: 999px;
  font-weight: 800;
  transition: transform 0.18s ease, background 0.18s ease, box-shadow 0.18s ease;
}

.btn-primary {
  color: #fff;
  background: var(--emerald-500);
  box-shadow: 0 18px 42px rgba(16, 185, 129, 0.25);
}

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

.btn-primary:hover {
  background: var(--emerald-600);
}

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

.hero-control {
  position: absolute;
  top: 50%;
  z-index: 5;
  width: 46px;
  height: 46px;
  border: 0;
  border-radius: 999px;
  color: #fff;
  background: rgba(2, 6, 23, 0.55);
  cursor: pointer;
  font-size: 32px;
  line-height: 1;
}

.hero-control:hover {
  background: rgba(2, 6, 23, 0.78);
}

.hero-prev {
  left: 24px;
}

.hero-next {
  right: 24px;
}

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

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

.hero-dot.is-active {
  width: 34px;
  background: var(--emerald-500);
}

.quick-search-section,
.content-section,
.filter-section,
.player-section,
.detail-content-grid {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
}

.quick-search-section {
  position: relative;
  z-index: 8;
  margin-top: -66px;
}

.quick-search-shell {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 440px);
  gap: 24px;
  align-items: center;
  padding: 28px;
  border: 1px solid rgba(148, 163, 184, 0.24);
  border-radius: var(--radius-xl);
  background: rgba(255, 255, 255, 0.94);
  box-shadow: var(--shadow-soft);
  backdrop-filter: blur(18px);
}

.quick-search-shell h2,
.section-head h2 {
  margin: 0;
  color: var(--slate-900);
  font-size: clamp(24px, 3vw, 36px);
  line-height: 1.16;
}

.quick-search-shell p,
.section-head p {
  margin: 8px 0 0;
  color: var(--slate-600);
}

.hero-search,
.filter-bar {
  display: flex;
  gap: 12px;
}

.hero-search input {
  flex: 1;
  min-width: 0;
  height: 48px;
  padding: 0 16px;
  border: 1px solid var(--slate-200);
  border-radius: 999px;
  outline: 0;
  background: #fff;
}

.hero-search button {
  height: 48px;
  padding: 0 20px;
  border-radius: 999px;
}

.content-section,
.filter-section,
.player-section {
  padding: 72px 0 0;
}

.content-section:last-child {
  padding-bottom: 72px;
}

.soft-section {
  width: 100%;
  max-width: none;
  padding: 72px max(16px, calc((100% - 1180px) / 2)) 72px;
  background: linear-gradient(135deg, #ecfdf5, #f0fdfa);
}

.dark-section {
  width: 100%;
  max-width: none;
  padding: 72px max(16px, calc((100% - 1180px) / 2));
  background: var(--slate-900);
}

.dark-section .section-head h2,
.dark-section .section-head p {
  color: #fff;
}

.dark-section .section-link {
  color: #6ee7b7;
}

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

.section-link {
  white-space: nowrap;
  color: var(--emerald-600);
  font-weight: 800;
}

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

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

.movie-card {
  min-width: 0;
}

.card-link {
  display: block;
  height: 100%;
  overflow: hidden;
  border: 1px solid rgba(226, 232, 240, 0.88);
  border-radius: var(--radius-lg);
  background: #fff;
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.06);
  transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
}

.card-link:hover {
  transform: translateY(-6px);
  border-color: rgba(16, 185, 129, 0.4);
  box-shadow: var(--shadow-card);
}

.card-poster {
  position: relative;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: linear-gradient(135deg, #0f172a, #064e3b);
}

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

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

.card-poster::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 35%, rgba(2, 6, 23, 0.66));
}

.card-year,
.play-pill {
  position: absolute;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
}

.card-year {
  top: 12px;
  left: 12px;
  padding: 5px 9px;
  color: #065f46;
  background: #d1fae5;
}

.play-pill {
  right: 12px;
  bottom: 12px;
  padding: 6px 10px;
  color: #fff;
  background: rgba(2, 6, 23, 0.76);
}

.card-body {
  padding: 16px;
}

.card-meta,
.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.card-meta span,
.detail-meta span {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
}

.card-meta span {
  padding: 4px 8px;
  color: var(--emerald-700);
  background: #ecfdf5;
}

.card-body h3 {
  margin: 12px 0 8px;
  color: var(--slate-900);
  font-size: 17px;
  line-height: 1.32;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.card-body p {
  min-height: 46px;
  margin: 0 0 12px;
  color: var(--slate-600);
  font-size: 14px;
  line-height: 1.55;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.scroll-row {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 280px;
  gap: 18px;
  overflow-x: auto;
  padding-bottom: 12px;
  scroll-snap-type: x proximity;
}

.scroll-row .movie-card {
  scroll-snap-align: start;
}

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

.category-card,
.category-overview-card {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-lg);
  background: #fff;
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.08);
}

.category-card {
  min-height: 168px;
  padding: 22px;
  border: 1px solid rgba(16, 185, 129, 0.12);
}

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

.category-card span {
  display: block;
  margin-bottom: 10px;
  color: var(--emerald-700);
  font-size: 20px;
  font-weight: 900;
}

.category-card p {
  margin: 0;
  color: var(--slate-600);
  font-size: 14px;
}

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

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

.rank-card a {
  display: grid;
  grid-template-columns: 62px 150px minmax(0, 1fr);
  gap: 16px;
  align-items: center;
  padding: 14px;
  border: 1px solid rgba(226, 232, 240, 0.9);
  border-radius: var(--radius-lg);
  background: #fff;
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.05);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

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

.rank-number {
  width: 50px;
  height: 50px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 16px;
  color: #fff;
  background: linear-gradient(135deg, var(--emerald-500), var(--teal-500));
  font-size: 22px;
  font-weight: 900;
}

.rank-card img {
  width: 150px;
  height: 92px;
  object-fit: cover;
  border-radius: 14px;
  background: var(--slate-800);
}

.rank-card h3 {
  margin: 9px 0 4px;
  font-size: 18px;
}

.rank-card p {
  margin: 0;
  color: var(--slate-600);
  font-size: 14px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.page-hero {
  color: #fff;
  background:
    radial-gradient(circle at 18% 20%, rgba(16, 185, 129, 0.32), transparent 34%),
    linear-gradient(135deg, #020617 0%, #0f172a 52%, #064e3b 100%);
}

.compact-hero {
  width: 100%;
  padding: 86px max(16px, calc((100% - 1180px) / 2));
}

.compact-hero h1 {
  font-size: clamp(38px, 6vw, 64px);
}

.compact-hero p {
  color: #cbd5e1;
}

.filter-bar {
  flex-direction: column;
  margin-bottom: 26px;
  padding: 20px;
  border: 1px solid rgba(226, 232, 240, 0.9);
  border-radius: var(--radius-xl);
  background: #fff;
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.05);
}

.filter-input {
  width: 100%;
  height: 50px;
  padding: 0 16px;
  border: 1px solid var(--slate-200);
  border-radius: 16px;
  outline: 0;
}

.filter-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.filter-chip {
  padding: 9px 14px;
  border: 1px solid var(--slate-200);
  border-radius: 999px;
  color: var(--slate-700);
  background: #fff;
  cursor: pointer;
}

.filter-chip:hover,
.filter-chip.is-active {
  color: #fff;
  border-color: var(--emerald-600);
  background: var(--emerald-600);
}

.filter-empty {
  display: none;
  margin-top: 24px;
  padding: 24px;
  border: 1px dashed var(--slate-200);
  border-radius: 18px;
  color: var(--slate-600);
  text-align: center;
  background: #fff;
}

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

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

.category-overview-card {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: 22px;
  padding: 18px;
  align-items: center;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.category-overview-card img {
  width: 220px;
  height: 144px;
  object-fit: cover;
  border-radius: 16px;
  background: var(--slate-800);
}

.category-overview-card span {
  color: var(--emerald-700);
  font-weight: 800;
}

.category-overview-card h2 {
  margin: 6px 0 8px;
  font-size: 28px;
}

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

.detail-hero {
  position: relative;
  min-height: 620px;
  overflow: hidden;
  color: #fff;
  background: var(--slate-950);
}

.detail-shell {
  position: relative;
  z-index: 2;
  width: min(1180px, calc(100% - 32px));
  min-height: 620px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 320px minmax(0, 1fr);
  gap: 44px;
  align-items: center;
  padding: 48px 0;
}

.detail-poster {
  overflow: hidden;
  border-radius: var(--radius-xl);
  box-shadow: 0 30px 80px rgba(2, 6, 23, 0.45);
  background: var(--slate-800);
}

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

.detail-copy h1 {
  font-size: clamp(42px, 6vw, 76px);
}

.detail-meta {
  margin: 22px 0 0;
}

.detail-meta span {
  padding: 6px 10px;
  color: #ecfdf5;
  background: rgba(255, 255, 255, 0.14);
}

.player-section {
  padding-top: 64px;
}

.player-frame {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-xl);
  background: #000;
  box-shadow: var(--shadow-soft);
  aspect-ratio: 16 / 9;
}

.movie-player {
  width: 100%;
  height: 100%;
  display: block;
  background: #000;
}

.player-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  border: 0;
  color: #fff;
  background: linear-gradient(180deg, rgba(2, 6, 23, 0.12), rgba(2, 6, 23, 0.68));
  cursor: pointer;
}

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

.play-circle {
  width: 76px;
  height: 76px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: var(--emerald-500);
  box-shadow: 0 16px 40px rgba(16, 185, 129, 0.32);
  font-size: 30px;
  text-indent: 4px;
}

.detail-content-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 22px;
  padding-top: 40px;
}

.content-card {
  padding: 28px;
  border: 1px solid rgba(226, 232, 240, 0.9);
  border-radius: var(--radius-xl);
  background: #fff;
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.05);
}

.content-card h2 {
  margin: 0 0 14px;
  font-size: 28px;
}

.content-card p {
  margin: 0;
  color: var(--slate-700);
  font-size: 17px;
}

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

.site-footer {
  margin-top: 72px;
  color: #cbd5e1;
  background: var(--slate-900);
}

.footer-shell {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 46px 0;
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(180px, 0.6fr) minmax(220px, 0.8fr);
  gap: 36px;
}

.footer-brand {
  color: #fff;
  font-size: 20px;
}

.footer-shell p {
  max-width: 520px;
  margin: 14px 0 0;
  color: #94a3b8;
}

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

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

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

.footer-links a:hover {
  color: #6ee7b7;
}

.footer-bottom {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 18px 0 28px;
  border-top: 1px solid rgba(148, 163, 184, 0.16);
  color: #94a3b8;
}

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

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

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

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

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

  .menu-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-left: auto;
  }

  .hero-carousel,
  .detail-hero,
  .detail-shell {
    min-height: 560px;
  }

  .hero-control {
    display: none;
  }

  .quick-search-shell {
    grid-template-columns: 1fr;
  }

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

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

  .detail-shell {
    grid-template-columns: 1fr;
    gap: 26px;
  }

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

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

@media (max-width: 640px) {
  .nav-shell {
    width: calc(100% - 24px);
    min-height: 64px;
  }

  .brand-name {
    font-size: 16px;
  }

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

  .hero-inner,
  .quick-search-section,
  .content-section,
  .filter-section,
  .player-section,
  .detail-content-grid,
  .detail-shell,
  .footer-shell,
  .footer-bottom {
    width: calc(100% - 24px);
  }

  .hero-copy h1,
  .hero-copy h2,
  .detail-copy h1 {
    font-size: 40px;
  }

  .hero-copy p,
  .page-hero p,
  .detail-copy p {
    font-size: 16px;
  }

  .quick-search-shell,
  .filter-bar,
  .content-card {
    padding: 20px;
    border-radius: 20px;
  }

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

  .movie-grid,
  .all-grid,
  .related-grid,
  .category-grid {
    grid-template-columns: 1fr;
  }

  .rank-card a {
    grid-template-columns: 50px 96px minmax(0, 1fr);
    gap: 12px;
  }

  .rank-card img {
    width: 96px;
    height: 68px;
  }

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

  .category-overview-card img {
    width: 100%;
  }

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