:root {
  --bg: #050816;
  --bg-soft: #0b1023;
  --panel: rgba(15, 23, 42, 0.82);
  --panel-solid: #111827;
  --border: rgba(148, 163, 184, 0.18);
  --text: #f8fafc;
  --muted: #94a3b8;
  --muted-strong: #cbd5e1;
  --primary: #ef4444;
  --primary-dark: #b91c1c;
  --accent: #f59e0b;
  --accent-soft: rgba(245, 158, 11, 0.14);
  --pink: #ec4899;
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.42);
  --radius-xl: 28px;
  --radius-lg: 20px;
  --radius-md: 14px;
  --header-height: 72px;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--text);
  background:
    radial-gradient(circle at 12% 8%, rgba(239, 68, 68, 0.18), transparent 28rem),
    radial-gradient(circle at 82% 0%, rgba(245, 158, 11, 0.13), transparent 24rem),
    linear-gradient(180deg, #050816 0%, #08111f 40%, #060914 100%);
  min-height: 100vh;
}

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

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

button,
input {
  font: inherit;
}

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: rgba(5, 8, 22, 0.88);
  border-bottom: 1px solid rgba(148, 163, 184, 0.13);
  backdrop-filter: blur(18px);
}

.nav-shell {
  width: min(1240px, calc(100% - 32px));
  height: var(--header-height);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-width: max-content;
}

.brand-mark {
  width: 38px;
  height: 38px;
  border-radius: 13px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  color: white;
  font-size: 16px;
  box-shadow: 0 12px 32px rgba(239, 68, 68, 0.32);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.brand:hover .brand-mark {
  transform: scale(1.08) rotate(-3deg);
  box-shadow: 0 16px 42px rgba(245, 158, 11, 0.34);
}

.brand-text {
  font-size: 21px;
  font-weight: 900;
  letter-spacing: 0.02em;
}

.brand-text span {
  color: var(--accent);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 10px;
}

.nav-links a {
  padding: 10px 14px;
  border-radius: 999px;
  color: var(--muted-strong);
  font-size: 14px;
  font-weight: 700;
  transition: color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.nav-links a:hover,
.nav-links a.active {
  color: white;
  background: rgba(255, 255, 255, 0.08);
  transform: translateY(-1px);
}

.nav-toggle {
  display: none;
  width: 42px;
  height: 42px;
  padding: 0;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.06);
  color: white;
  cursor: pointer;
}

.nav-toggle span {
  display: block;
  width: 19px;
  height: 2px;
  margin: 5px auto;
  border-radius: 999px;
  background: currentColor;
}

main {
  padding-top: var(--header-height);
}

.hero-carousel {
  position: relative;
  min-height: 760px;
  overflow: hidden;
  border-bottom: 1px solid var(--border);
}

.hero-slider,
.hero-slide,
.hero-backdrop {
  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-backdrop {
  background-size: cover;
  background-position: center;
  transform: scale(1.05);
  filter: saturate(1.06);
}

.hero-backdrop::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 72% 22%, rgba(245, 158, 11, 0.16), transparent 24rem),
    linear-gradient(180deg, rgba(5, 8, 22, 0.1), rgba(5, 8, 22, 0.88));
}

.hero-content {
  position: relative;
  width: min(1240px, calc(100% - 32px));
  min-height: 760px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) 420px;
  align-items: center;
  gap: 56px;
  z-index: 2;
}

.hero-copy {
  padding-top: 42px;
}

.hero-kicker,
.section-heading span,
.page-hero span,
.category-preview-head span {
  display: inline-flex;
  align-items: center;
  width: max-content;
  padding: 8px 13px;
  border: 1px solid rgba(245, 158, 11, 0.26);
  border-radius: 999px;
  color: #fed7aa;
  background: rgba(245, 158, 11, 0.12);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.hero-copy h1,
.hero-copy h2 {
  max-width: 780px;
  margin: 24px 0 18px;
  font-size: clamp(42px, 6vw, 76px);
  line-height: 0.96;
  letter-spacing: -0.06em;
}

.hero-copy p {
  max-width: 680px;
  margin: 0;
  color: var(--muted-strong);
  font-size: 18px;
  line-height: 1.85;
}

.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;
  background: rgba(255, 255, 255, 0.08);
  color: #e2e8f0;
  border: 1px solid rgba(255, 255, 255, 0.09);
  font-size: 12px;
  font-weight: 700;
}

.hero-tags span {
  padding: 8px 12px;
}

.tag-row span {
  padding: 6px 9px;
}

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

.primary-button,
.ghost-button,
.outline-button,
.text-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  font-weight: 900;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.primary-button {
  min-height: 48px;
  padding: 0 24px;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  color: white;
  box-shadow: 0 18px 42px rgba(239, 68, 68, 0.28);
}

.ghost-button,
.outline-button {
  min-height: 48px;
  padding: 0 22px;
  border: 1px solid rgba(255, 255, 255, 0.17);
  color: #f8fafc;
  background: rgba(255, 255, 255, 0.06);
}

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

.primary-button:hover {
  box-shadow: 0 22px 52px rgba(245, 158, 11, 0.32);
}

.ghost-button:hover,
.outline-button:hover {
  border-color: rgba(245, 158, 11, 0.45);
  background: rgba(245, 158, 11, 0.12);
}

.hero-poster {
  position: relative;
  display: block;
  width: 100%;
  max-width: 420px;
  aspect-ratio: 3 / 4;
  border-radius: 32px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.14);
  box-shadow: var(--shadow);
  transform: rotate(2deg);
  transition: transform 0.35s ease;
}

.hero-poster:hover {
  transform: rotate(0deg) scale(1.02);
}

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

.hero-poster::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 42%, rgba(0, 0, 0, 0.7));
}

.hero-poster span {
  position: absolute;
  right: 18px;
  bottom: 18px;
  z-index: 2;
  padding: 9px 14px;
  border-radius: 999px;
  color: white;
  background: rgba(0, 0, 0, 0.62);
  border: 1px solid rgba(255, 255, 255, 0.16);
  font-weight: 900;
}

.hero-controls {
  position: absolute;
  left: 50%;
  bottom: 36px;
  z-index: 5;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 10px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.72);
  border: 1px solid var(--border);
  backdrop-filter: blur(20px);
}

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

.hero-arrow {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.09);
  font-size: 30px;
  line-height: 1;
}

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

.hero-dot {
  width: 9px;
  height: 9px;
  padding: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.38);
  transition: width 0.25s ease, background 0.25s ease;
}

.hero-dot.is-active {
  width: 26px;
  background: linear-gradient(135deg, var(--primary), var(--accent));
}

.hero-search,
.page-search {
  position: absolute;
  left: 50%;
  bottom: 104px;
  z-index: 5;
  width: min(620px, calc(100% - 32px));
  transform: translateX(-50%);
  display: flex;
  padding: 8px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.76);
  border: 1px solid var(--border);
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.34);
  backdrop-filter: blur(18px);
}

.hero-search input,
.page-search input {
  flex: 1;
  min-width: 0;
  border: 0;
  outline: 0;
  padding: 0 18px;
  background: transparent;
  color: white;
}

.hero-search input::placeholder,
.page-search input::placeholder,
.search-box input::placeholder {
  color: #64748b;
}

.hero-search button,
.page-search button {
  border: 0;
  cursor: pointer;
  padding: 12px 20px;
  border-radius: 999px;
  color: white;
  font-weight: 900;
  background: linear-gradient(135deg, var(--primary), var(--accent));
}

.section-shell,
.category-preview {
  width: min(1240px, calc(100% - 32px));
  margin: 0 auto;
  padding: 78px 0;
}

.section-heading {
  max-width: 760px;
  margin: 0 auto 34px;
  text-align: center;
}

.left-heading {
  margin-left: 0;
  text-align: left;
}

.section-heading h2,
.page-hero h1,
.category-preview-head h2 {
  margin: 16px 0 10px;
  font-size: clamp(30px, 4vw, 46px);
  letter-spacing: -0.04em;
}

.section-heading p,
.page-hero p,
.category-preview-head p {
  margin: 0;
  color: var(--muted);
  line-height: 1.8;
}

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

.category-tile {
  min-height: 190px;
  padding: 22px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  background:
    radial-gradient(circle at 82% 0%, rgba(245, 158, 11, 0.18), transparent 14rem),
    rgba(15, 23, 42, 0.7);
  overflow: hidden;
  transition: transform 0.25s ease, border-color 0.25s ease, background 0.25s ease;
}

.category-tile:hover {
  transform: translateY(-6px);
  border-color: rgba(245, 158, 11, 0.42);
  background:
    radial-gradient(circle at 82% 0%, rgba(239, 68, 68, 0.24), transparent 15rem),
    rgba(15, 23, 42, 0.92);
}

.category-tile span {
  color: var(--accent);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.category-tile h3 {
  margin: 28px 0 10px;
  font-size: 23px;
}

.category-tile p {
  margin: 0;
  color: var(--muted);
  line-height: 1.65;
  font-size: 14px;
}

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

.movie-card {
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: rgba(15, 23, 42, 0.74);
  border: 1px solid rgba(148, 163, 184, 0.15);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.14);
  transition: transform 0.25s ease, border-color 0.25s ease, background 0.25s ease;
}

.movie-card:hover {
  transform: translateY(-7px);
  border-color: rgba(245, 158, 11, 0.4);
  background: rgba(17, 24, 39, 0.96);
}

.poster-link {
  position: relative;
  display: block;
  aspect-ratio: 3 / 4;
  overflow: hidden;
}

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

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

.poster-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 38%, rgba(0, 0, 0, 0.78));
}

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

.corner-badge {
  top: 12px;
  right: 12px;
  padding: 6px 9px;
  font-size: 12px;
  background: rgba(0, 0, 0, 0.62);
  border: 1px solid rgba(255, 255, 255, 0.16);
}

.play-chip {
  left: 12px;
  bottom: 12px;
  width: 36px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  box-shadow: 0 12px 28px rgba(239, 68, 68, 0.32);
}

.card-body {
  padding: 15px;
}

.card-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 7px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.card-meta span {
  padding: 5px 8px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
}

.movie-card h3 {
  min-height: 46px;
  margin: 12px 0 8px;
  font-size: 16px;
  line-height: 1.42;
}

.movie-card h3 a:hover,
.rank-card h3 a:hover {
  color: var(--accent);
}

.movie-card p {
  min-height: 64px;
  margin: 0 0 12px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.65;
}

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

.card-compact .card-body {
  padding: 13px;
}

.card-compact p {
  display: none;
}

.card-compact h3 {
  min-height: 44px;
}

.tool-bar {
  display: grid;
  gap: 22px;
}

.search-box {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px 10px 18px;
  border-radius: 18px;
  border: 1px solid var(--border);
  background: rgba(15, 23, 42, 0.74);
}

.search-box span {
  color: var(--accent);
  font-weight: 900;
  white-space: nowrap;
}

.search-box input {
  width: 100%;
  border: 0;
  outline: 0;
  color: white;
  background: transparent;
  min-height: 42px;
}

.big-search-box {
  max-width: 760px;
  margin: 0 auto;
  width: 100%;
}

.quick-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.quick-filters button {
  cursor: pointer;
  min-height: 38px;
  padding: 0 15px;
  border-radius: 999px;
  border: 1px solid var(--border);
  color: var(--muted-strong);
  background: rgba(255, 255, 255, 0.05);
  transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.quick-filters button:hover,
.quick-filters button.active {
  color: white;
  border-color: rgba(245, 158, 11, 0.44);
  background: rgba(245, 158, 11, 0.13);
}

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

.rank-card {
  position: relative;
  display: grid;
  grid-template-columns: auto 88px minmax(0, 1fr) auto;
  align-items: center;
  gap: 16px;
  padding: 14px;
  border: 1px solid rgba(148, 163, 184, 0.14);
  border-radius: 20px;
  background: rgba(15, 23, 42, 0.74);
  transition: transform 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

.rank-card:hover {
  transform: translateX(4px);
  border-color: rgba(245, 158, 11, 0.38);
  background: rgba(17, 24, 39, 0.95);
}

.rank-number {
  width: 48px;
  height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 16px;
  color: white;
  font-size: 18px;
  font-weight: 950;
  background: linear-gradient(135deg, var(--primary), var(--accent));
}

.small-rank {
  font-size: 14px;
}

.rank-poster {
  display: block;
  width: 88px;
  aspect-ratio: 3 / 4;
  border-radius: 14px;
  overflow: hidden;
}

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

.rank-info h3 {
  margin: 8px 0 7px;
  font-size: 18px;
}

.rank-info p {
  margin: 0;
  color: var(--muted);
  line-height: 1.6;
}

.text-button {
  min-height: 38px;
  padding: 0 14px;
  color: #fed7aa;
  background: rgba(245, 158, 11, 0.11);
  border: 1px solid rgba(245, 158, 11, 0.24);
}

.center-action {
  display: flex;
  justify-content: center;
  margin-top: 28px;
}

.page-hero {
  position: relative;
  min-height: 360px;
  padding: 78px max(16px, calc((100vw - 1240px) / 2)) 70px;
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 32px;
  overflow: hidden;
  border-bottom: 1px solid var(--border);
  background:
    radial-gradient(circle at 82% 4%, rgba(245, 158, 11, 0.16), transparent 28rem),
    radial-gradient(circle at 10% 16%, rgba(239, 68, 68, 0.18), transparent 26rem),
    linear-gradient(135deg, rgba(15, 23, 42, 0.98), rgba(5, 8, 22, 0.98));
}

.page-hero > div {
  max-width: 760px;
  z-index: 2;
}

.page-hero h1 {
  margin-top: 18px;
}

.page-search {
  position: relative;
  left: auto;
  bottom: auto;
  transform: none;
  flex: 1;
  max-width: 520px;
}

.channel-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 24px;
}

.channel-nav a {
  padding: 10px 14px;
  border-radius: 999px;
  color: var(--muted-strong);
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.05);
  font-weight: 800;
}

.channel-nav a.active,
.channel-nav a:hover {
  color: white;
  border-color: rgba(245, 158, 11, 0.45);
  background: rgba(245, 158, 11, 0.14);
}

.category-preview {
  padding-top: 26px;
  padding-bottom: 52px;
}

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

.category-preview-head > div {
  max-width: 720px;
}

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

.detail-hero {
  position: relative;
  min-height: 640px;
  overflow: hidden;
  border-bottom: 1px solid var(--border);
}

.detail-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  transform: scale(1.05);
}

.detail-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(5, 8, 22, 0.18), var(--bg));
}

.detail-shell {
  position: relative;
  z-index: 2;
  width: min(1240px, calc(100% - 32px));
  margin: 0 auto;
  padding: 38px 0 70px;
}

.breadcrumb {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 9px;
  color: var(--muted);
  font-size: 14px;
  margin-bottom: 36px;
}

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

.detail-layout {
  display: grid;
  grid-template-columns: 320px minmax(0, 1fr);
  gap: 46px;
  align-items: center;
}

.detail-poster {
  position: relative;
  border-radius: 28px;
  overflow: hidden;
  box-shadow: var(--shadow);
  border: 1px solid rgba(255, 255, 255, 0.14);
}

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

.detail-poster span {
  position: absolute;
  right: 16px;
  bottom: 16px;
  padding: 8px 12px;
  border-radius: 999px;
  color: white;
  font-weight: 900;
  background: linear-gradient(135deg, var(--primary), var(--accent));
}

.detail-copy h1 {
  margin: 22px 0 16px;
  font-size: clamp(38px, 5vw, 68px);
  line-height: 1.02;
  letter-spacing: -0.055em;
}

.detail-line {
  margin: 0;
  max-width: 760px;
  color: var(--muted-strong);
  font-size: 18px;
  line-height: 1.8;
}

.detail-meta-list {
  list-style: none;
  padding: 0;
  margin: 26px 0 0;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.detail-meta-list li {
  padding: 14px;
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.06);
}

.detail-meta-list span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  margin-bottom: 6px;
}

.detail-meta-list strong {
  font-size: 15px;
}

.watch-section {
  padding-top: 56px;
}

.player-frame {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: var(--radius-xl);
  overflow: hidden;
  background: #000;
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: var(--shadow);
}

.video-player {
  width: 100%;
  height: 100%;
  display: block;
  background: #000;
  object-fit: contain;
}

.player-overlay {
  position: absolute;
  inset: 0;
  z-index: 4;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  color: white;
  border: 0;
  cursor: pointer;
  background:
    radial-gradient(circle at 50% 42%, rgba(239, 68, 68, 0.22), transparent 17rem),
    linear-gradient(180deg, rgba(5, 8, 22, 0.22), rgba(5, 8, 22, 0.74));
}

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

.player-icon {
  width: 82px;
  height: 82px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  box-shadow: 0 22px 56px rgba(239, 68, 68, 0.34);
  font-size: 32px;
}

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

.player-overlay em {
  max-width: 86%;
  color: var(--muted-strong);
  font-style: normal;
  text-align: center;
}

.article-section {
  padding-top: 34px;
}

.story-card {
  padding: 32px;
  border-radius: var(--radius-xl);
  border: 1px solid var(--border);
  background: rgba(15, 23, 42, 0.78);
}

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

.story-card h2:not(:first-child) {
  margin-top: 30px;
}

.story-card p {
  margin: 0;
  color: var(--muted-strong);
  line-height: 2;
  font-size: 16px;
}

.inline-tags {
  margin-top: 0;
}

.empty-state {
  display: none;
  padding: 28px;
  border: 1px dashed var(--border);
  border-radius: 18px;
  color: var(--muted);
  text-align: center;
  background: rgba(255, 255, 255, 0.04);
}

.site-footer {
  margin-top: 60px;
  border-top: 1px solid var(--border);
  background: rgba(5, 8, 22, 0.88);
}

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

.footer-brand {
  margin-bottom: 16px;
}

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

.site-footer h3 {
  margin: 0 0 16px;
}

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

.footer-links a {
  color: var(--muted);
  transition: color 0.2s ease;
}

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

.footer-bottom {
  padding: 20px 16px 26px;
  color: #64748b;
  text-align: center;
  border-top: 1px solid rgba(148, 163, 184, 0.1);
}

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

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

  .hero-content {
    grid-template-columns: minmax(0, 1fr) 320px;
    gap: 32px;
  }

  .hero-poster {
    max-width: 320px;
  }

  .detail-layout {
    grid-template-columns: 260px minmax(0, 1fr);
  }
}

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

  .nav-shell {
    width: min(100% - 24px, 1240px);
  }

  .nav-toggle {
    display: block;
  }

  .nav-links {
    position: absolute;
    top: calc(100% + 1px);
    left: 12px;
    right: 12px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    padding: 14px;
    border: 1px solid var(--border);
    border-radius: 18px;
    background: rgba(15, 23, 42, 0.96);
    box-shadow: var(--shadow);
  }

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

  .nav-links a {
    border-radius: 12px;
  }

  .brand-text {
    font-size: 18px;
  }

  .hero-carousel,
  .hero-content {
    min-height: 820px;
  }

  .hero-content {
    grid-template-columns: 1fr;
    align-content: center;
    padding: 34px 0 150px;
  }

  .hero-poster {
    display: none;
  }

  .hero-copy h1,
  .hero-copy h2 {
    font-size: clamp(38px, 12vw, 58px);
  }

  .hero-search {
    bottom: 92px;
  }

  .hero-controls {
    bottom: 28px;
  }

  .section-shell,
  .category-preview {
    padding: 52px 0;
  }

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

  .rank-card {
    grid-template-columns: auto 76px minmax(0, 1fr);
  }

  .rank-card .text-button {
    grid-column: 2 / -1;
    width: max-content;
  }

  .page-hero {
    display: block;
    min-height: 330px;
    padding-top: 58px;
  }

  .page-search {
    margin-top: 24px;
  }

  .category-preview-head {
    display: block;
  }

  .category-preview-head .text-button {
    margin-top: 18px;
  }

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

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

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

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

@media (max-width: 520px) {
  .category-grid,
  .movie-grid,
  .compact-grid,
  .mini-grid {
    grid-template-columns: 1fr;
  }

  .hero-search,
  .page-search {
    border-radius: 20px;
    flex-direction: column;
  }

  .hero-search input,
  .page-search input {
    min-height: 42px;
  }

  .hero-search button,
  .page-search button {
    width: 100%;
  }

  .rank-card {
    grid-template-columns: 54px 74px minmax(0, 1fr);
    gap: 11px;
  }

  .rank-number {
    width: 42px;
    height: 42px;
    border-radius: 13px;
    font-size: 15px;
  }

  .rank-poster {
    width: 74px;
  }

  .rank-info p {
    display: none;
  }

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

  .story-card {
    padding: 22px;
  }
}
