:root {
  --bg: #f8fafc;
  --ink: #1f2937;
  --muted: #64748b;
  --soft: #e2e8f0;
  --line: #e5e7eb;
  --dark: #0f172a;
  --dark-2: #1e293b;
  --accent: #10b981;
  --accent-2: #0d9488;
  --accent-soft: #d1fae5;
  --white: #ffffff;
  --shadow: 0 20px 50px rgba(15, 23, 42, 0.14);
  --shadow-soft: 0 10px 30px rgba(15, 23, 42, 0.10);
  color-scheme: light;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  color: var(--ink);
  background: linear-gradient(180deg, #f8fafc 0%, #ffffff 42%, #f8fafc 100%);
  -webkit-font-smoothing: antialiased;
}

body.menu-open {
  overflow: hidden;
}

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

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

button,
input,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: linear-gradient(90deg, rgba(15, 23, 42, 0.98), rgba(30, 41, 59, 0.96), rgba(15, 23, 42, 0.98));
  color: #fff;
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.24);
  backdrop-filter: blur(12px);
}

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

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.brand-mark,
.footer-logo span {
  width: 42px;
  height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  color: #fff;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  box-shadow: 0 12px 28px rgba(16, 185, 129, 0.32);
  transition: transform 0.25s ease;
}

.brand:hover .brand-mark {
  transform: scale(1.08);
}

.brand-text {
  display: grid;
  gap: 2px;
}

.brand-text strong {
  font-size: 24px;
  line-height: 1.1;
  letter-spacing: -0.02em;
}

.brand-text small {
  color: #94a3b8;
  font-size: 12px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 22px;
  color: #cbd5e1;
  font-weight: 600;
}

.nav-links > a,
.nav-submenu > button {
  position: relative;
  border: 0;
  background: transparent;
  color: inherit;
  padding: 8px 0;
  transition: color 0.2s ease;
}

.nav-links > a:hover,
.nav-links > a.is-active,
.nav-submenu > button:hover {
  color: #fff;
}

.nav-submenu {
  position: relative;
}

.submenu-panel {
  position: absolute;
  top: calc(100% + 14px);
  right: 0;
  display: grid;
  gap: 8px;
  width: 210px;
  padding: 14px;
  border: 1px solid rgba(148, 163, 184, 0.18);
  border-radius: 18px;
  background: rgba(15, 23, 42, 0.96);
  box-shadow: var(--shadow);
  opacity: 0;
  pointer-events: none;
  transform: translateY(10px);
  transition: all 0.2s ease;
}

.submenu-panel a {
  padding: 8px 10px;
  border-radius: 12px;
  color: #d1d5db;
}

.submenu-panel a:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.08);
}

.nav-submenu:hover .submenu-panel,
.nav-submenu:focus-within .submenu-panel {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

.mobile-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
}

.mobile-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  margin: 4px auto;
  background: currentColor;
  border-radius: 2px;
}

.hero {
  position: relative;
  height: min(760px, 76vh);
  min-height: 560px;
  color: #fff;
  background: #020617;
  overflow: hidden;
}

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

.hero-slide {
  opacity: 0;
  transform: scale(1.015);
  pointer-events: none;
  transition: opacity 0.7s ease, transform 1.2s ease;
}

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

.hero-bg {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(1.04) contrast(1.04);
}

.hero-gradient {
  background:
    radial-gradient(circle at 82% 18%, rgba(16, 185, 129, 0.22), transparent 26%),
    linear-gradient(90deg, rgba(2, 6, 23, 0.92) 0%, rgba(15, 23, 42, 0.78) 42%, rgba(15, 23, 42, 0.36) 68%, rgba(2, 6, 23, 0.70) 100%),
    linear-gradient(0deg, rgba(2, 6, 23, 0.92), rgba(2, 6, 23, 0.08));
}

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

.hero-copy {
  max-width: 760px;
  animation: fadeUp 0.8s ease both;
}

.hero-kicker,
.section-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--accent);
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.hero h1 {
  margin: 18px 0 8px;
  font-size: clamp(34px, 5vw, 64px);
  line-height: 1.06;
  letter-spacing: -0.05em;
}

.hero h2 {
  margin: 0 0 16px;
  font-size: clamp(30px, 4.6vw, 56px);
  line-height: 1.08;
  letter-spacing: -0.04em;
}

.hero p {
  margin: 0;
  max-width: 720px;
  color: #dbeafe;
  font-size: clamp(17px, 1.8vw, 22px);
  line-height: 1.75;
}

.hero-tags,
.detail-tags-line,
.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.hero-tags {
  margin: 28px 0;
}

.hero-tags span,
.hero-tags a,
.detail-tags-line span,
.tag-list span {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 6px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.14);
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  backdrop-filter: blur(8px);
}

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

.primary-action,
.ghost-action,
.section-more {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 20px;
  border-radius: 999px;
  font-weight: 800;
  transition: transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}

.primary-action {
  color: #fff;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  box-shadow: 0 18px 36px rgba(16, 185, 129, 0.28);
}

.ghost-action {
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.3);
  background: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(8px);
}

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

.hero-poster {
  position: relative;
  display: block;
  border-radius: 28px;
  overflow: hidden;
  box-shadow: 0 35px 80px rgba(0, 0, 0, 0.42);
  transform: rotate(1.5deg);
}

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

.hero-poster span {
  position: absolute;
  left: 18px;
  right: 18px;
  bottom: 18px;
  padding: 14px;
  border-radius: 18px;
  color: #fff;
  font-weight: 900;
  background: rgba(15, 23, 42, 0.72);
  backdrop-filter: blur(12px);
}

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

.hero-controls > button {
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 999px;
  color: #fff;
  background: rgba(255, 255, 255, 0.13);
  backdrop-filter: blur(8px);
  font-size: 28px;
  line-height: 1;
}

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

.hero-dots button {
  width: 11px;
  height: 11px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.42);
  transition: width 0.2s ease, background 0.2s ease;
}

.hero-dots button.is-active {
  width: 30px;
  background: var(--accent);
}

.page-shell {
  width: min(1240px, calc(100% - 32px));
  margin: 0 auto;
}

.inner-page {
  padding-top: 40px;
}

.content-section,
.filter-panel,
.page-hero,
.ranking-list {
  margin-top: 48px;
}

.filter-panel {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 24px;
  align-items: end;
  padding: 24px;
  border: 1px solid rgba(226, 232, 240, 0.9);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.86);
  box-shadow: var(--shadow-soft);
}

.filter-panel h2,
.section-head h2,
.page-hero h1 {
  margin: 8px 0 0;
  color: #0f172a;
  font-size: clamp(26px, 3vw, 38px);
  line-height: 1.15;
  letter-spacing: -0.03em;
}

.filter-controls {
  display: grid;
  grid-template-columns: minmax(180px, 1.3fr) repeat(3, minmax(130px, 0.8fr));
  gap: 14px;
}

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

.filter-controls input,
.filter-controls select {
  width: 100%;
  min-height: 46px;
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 0 14px;
  color: var(--ink);
  background: #fff;
  outline: none;
  transition: border 0.2s ease, box-shadow 0.2s ease;
}

.filter-controls input:focus,
.filter-controls select:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 4px rgba(16, 185, 129, 0.12);
}

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

.section-head.compact {
  margin-bottom: 16px;
}

.section-more {
  min-height: 38px;
  color: var(--accent-2);
  background: var(--accent-soft);
}

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

.category-tile,
.category-card-large {
  position: relative;
  display: grid;
  gap: 12px;
  padding: 22px;
  border: 1px solid rgba(226, 232, 240, 0.9);
  border-radius: 22px;
  background: #fff;
  box-shadow: var(--shadow-soft);
  overflow: hidden;
  transition: transform 0.24s ease, box-shadow 0.24s ease;
}

.category-tile::before,
.category-card-large::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 90% 8%, rgba(16, 185, 129, 0.15), transparent 34%);
  pointer-events: none;
}

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

.category-tile strong,
.category-card-large h2 {
  position: relative;
  margin: 0;
  color: #0f172a;
  font-size: 22px;
}

.category-tile em,
.category-card-large p {
  position: relative;
  color: var(--muted);
  font-style: normal;
  line-height: 1.7;
}

.category-samples {
  position: relative;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.category-samples span {
  max-width: 100%;
  padding: 5px 9px;
  border-radius: 999px;
  color: #047857;
  background: #ecfdf5;
  font-size: 12px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.category-card-large ul {
  position: relative;
  display: grid;
  gap: 7px;
  margin: 0;
  padding: 0;
  list-style: none;
}

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

.category-card-large li a:hover {
  color: var(--accent-2);
}

.category-icon {
  position: relative;
  width: 46px;
  height: 46px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  color: #fff;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
}

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

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

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

.movie-card-link {
  height: 100%;
  display: grid;
  overflow: hidden;
  border-radius: 18px;
  background: #fff;
  box-shadow: var(--shadow-soft);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

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

.poster-frame {
  position: relative;
  display: block;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: #0f172a;
}

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

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

.poster-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(15, 23, 42, 0.64), transparent 56%);
}

.poster-region,
.poster-year {
  position: absolute;
  top: 12px;
  padding: 5px 9px;
  border-radius: 8px;
  color: #fff;
  font-size: 12px;
  font-weight: 800;
  backdrop-filter: blur(8px);
}

.poster-region {
  left: 12px;
  background: var(--accent);
}

.poster-year {
  right: 12px;
  background: rgba(15, 23, 42, 0.72);
}

.movie-card-body {
  display: grid;
  gap: 10px;
  padding: 16px;
}

.movie-card-body strong {
  color: #111827;
  font-size: 18px;
  line-height: 1.3;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.movie-card-body em {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.6;
  font-style: normal;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.movie-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: #64748b;
  font-size: 12px;
  font-weight: 700;
}

.movie-meta span:first-child {
  min-width: 0;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

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

.ranking-panel,
.watch-side,
.detail-card,
.info-table,
.side-section,
.player-card,
.side-poster,
.prev-next a {
  border: 1px solid rgba(226, 232, 240, 0.9);
  border-radius: 22px;
  background: #fff;
  box-shadow: var(--shadow-soft);
}

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

.compact-card a {
  display: grid;
  grid-template-columns: 34px 74px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  padding: 10px 0;
  border-bottom: 1px solid #f1f5f9;
}

.compact-card:last-child a {
  border-bottom: 0;
}

.compact-card img {
  width: 74px;
  height: 48px;
  border-radius: 10px;
  object-fit: cover;
}

.compact-card strong,
.compact-card em {
  display: block;
  min-width: 0;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.compact-card strong {
  color: #111827;
  font-size: 15px;
}

.compact-card em {
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
}

.rank-index {
  width: 30px;
  height: 30px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  color: #047857;
  background: #ecfdf5;
  font-weight: 900;
}

.page-hero {
  padding: 44px;
  border-radius: 28px;
  color: #fff;
  background:
    radial-gradient(circle at 88% 20%, rgba(16, 185, 129, 0.24), transparent 30%),
    linear-gradient(135deg, #0f172a, #1e293b 60%, #0f172a);
  box-shadow: var(--shadow);
}

.slim-hero p {
  max-width: 760px;
  margin: 16px 0 0;
  color: #cbd5e1;
  font-size: 18px;
  line-height: 1.8;
}

.slim-hero h1 {
  color: #fff;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 18px;
  color: #bbf7d0;
  font-size: 14px;
  font-weight: 700;
}

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

.ranking-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px 28px;
  padding: 26px;
  border-radius: 24px;
  background: #fff;
  box-shadow: var(--shadow-soft);
}

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

.watch-main {
  display: grid;
  gap: 22px;
}

.detail-breadcrumb {
  color: var(--muted);
}

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

.player-card {
  position: relative;
  overflow: hidden;
  background: #020617;
  aspect-ratio: 16 / 9;
}

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

.player-overlay {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  border: 0;
  color: #fff;
  background: linear-gradient(0deg, rgba(2, 6, 23, 0.76), rgba(15, 23, 42, 0.24));
  transition: opacity 0.25s ease;
}

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

.play-circle {
  width: 76px;
  height: 76px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  box-shadow: 0 18px 40px rgba(16, 185, 129, 0.34);
  font-size: 30px;
  text-indent: 4px;
}

.player-overlay strong {
  width: min(80%, 620px);
  text-align: center;
  font-size: clamp(22px, 3vw, 38px);
  line-height: 1.2;
}

.player-message {
  position: absolute;
  left: 16px;
  right: 16px;
  bottom: 14px;
  z-index: 3;
  color: #fecaca;
  font-weight: 700;
  text-align: center;
  pointer-events: none;
}

.player-message:empty {
  display: none;
}

.detail-card {
  padding: 28px;
}

.detail-tags-line span,
.tag-list span {
  color: #047857;
  background: #ecfdf5;
}

.detail-card h1 {
  margin: 18px 0 14px;
  color: #0f172a;
  font-size: clamp(30px, 4vw, 46px);
  line-height: 1.12;
  letter-spacing: -0.04em;
}

.lead-text {
  margin: 0 0 24px;
  padding-bottom: 22px;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  font-size: 19px;
  line-height: 1.8;
}

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

.detail-card h2,
.side-section h2,
.info-table h2 {
  margin: 0 0 12px;
  color: #111827;
  font-size: 22px;
  line-height: 1.3;
}

.detail-card p {
  color: #374151;
  line-height: 2;
  margin: 0 0 12px;
}

.watch-side {
  position: sticky;
  top: 96px;
  display: grid;
  gap: 18px;
  padding: 18px;
  background: transparent;
  border: 0;
  box-shadow: none;
}

.side-poster {
  overflow: hidden;
}

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

.side-poster div {
  display: grid;
  gap: 7px;
  padding: 16px;
}

.side-poster strong {
  color: #111827;
  font-size: 20px;
}

.side-poster span {
  color: var(--muted);
  font-size: 14px;
}

.info-table {
  padding: 18px;
}

.info-table dl {
  display: grid;
  gap: 0;
  margin: 0;
}

.info-table div {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  padding: 12px 0;
  border-bottom: 1px solid #f1f5f9;
}

.info-table div:last-child {
  border-bottom: 0;
}

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

.info-table dd {
  margin: 0;
  color: #111827;
  font-weight: 800;
  text-align: right;
}

.info-table a {
  color: var(--accent-2);
}

.side-section {
  padding: 18px;
}

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

.movie-card.is-small .movie-card-link {
  grid-template-columns: 96px minmax(0, 1fr);
  align-items: stretch;
}

.movie-card.is-small .poster-frame {
  aspect-ratio: auto;
  height: 100%;
}

.movie-card.is-small .movie-card-body {
  padding: 12px;
}

.movie-card.is-small .movie-card-body strong {
  font-size: 15px;
  -webkit-line-clamp: 1;
}

.movie-card.is-small .movie-card-body em {
  font-size: 12px;
  -webkit-line-clamp: 2;
}

.movie-card.is-small .movie-meta {
  display: none;
}

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

.prev-next a {
  display: grid;
  gap: 6px;
  padding: 18px;
}

.prev-next span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.prev-next strong {
  color: #0f172a;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.site-footer {
  margin-top: 80px;
  color: #cbd5e1;
  background: linear-gradient(135deg, #0f172a, #1e293b 55%, #0f172a);
}

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

.footer-logo {
  display: flex;
  align-items: center;
  gap: 12px;
  color: #fff;
  font-size: 20px;
}

.footer-brand p,
.footer-column p {
  color: #94a3b8;
  line-height: 1.8;
}

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

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

.footer-column a {
  color: #94a3b8;
}

.footer-column a:hover {
  color: #34d399;
}

.footer-bottom {
  width: min(1240px, calc(100% - 32px));
  margin: 0 auto;
  padding: 20px 0;
  display: flex;
  justify-content: space-between;
  gap: 16px;
  border-top: 1px solid rgba(148, 163, 184, 0.24);
  color: #94a3b8;
  font-size: 14px;
}

@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(24px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 1080px) {
  .hero-inner,
  .watch-layout,
  .split-layout,
  .filter-panel,
  .footer-inner {
    grid-template-columns: 1fr;
  }

  .hero-poster {
    display: none;
  }

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

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

@media (max-width: 820px) {
  .mobile-toggle {
    display: block;
  }

  .nav-links {
    position: fixed;
    top: 72px;
    left: 0;
    right: 0;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 14px 20px 24px;
    background: rgba(15, 23, 42, 0.98);
    box-shadow: 0 20px 40px rgba(15, 23, 42, 0.28);
  }

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

  .nav-links > a,
  .nav-submenu > button {
    padding: 14px 0;
    text-align: left;
  }

  .nav-submenu {
    display: none;
  }

  .hero {
    min-height: 620px;
    height: 82vh;
  }

  .hero-inner {
    align-items: end;
    padding-bottom: 92px;
  }

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

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

  .page-hero,
  .detail-card {
    padding: 24px;
  }
}

@media (max-width: 560px) {
  .nav-shell,
  .page-shell,
  .footer-inner,
  .footer-bottom {
    width: min(100% - 24px, 1240px);
  }

  .brand-text strong {
    font-size: 20px;
  }

  .brand-text small {
    display: none;
  }

  .hero h1,
  .hero h2 {
    letter-spacing: -0.03em;
  }

  .hero-tags {
    margin: 20px 0;
  }

  .hero-actions,
  .section-head,
  .footer-bottom,
  .prev-next {
    flex-direction: column;
    align-items: stretch;
    display: flex;
  }

  .movie-grid,
  .category-grid,
  .category-large-grid,
  .ranking-list {
    grid-template-columns: 1fr;
  }

  .compact-card a {
    grid-template-columns: 30px 82px minmax(0, 1fr);
  }

  .watch-side {
    padding: 0;
  }
}
