:root {
  color-scheme: dark;
  --bg: #020617;
  --panel: rgba(15, 23, 42, 0.86);
  --panel-strong: rgba(15, 23, 42, 0.96);
  --line: rgba(148, 163, 184, 0.18);
  --line-strong: rgba(34, 211, 238, 0.28);
  --text: #e2e8f0;
  --muted: #94a3b8;
  --soft: #cbd5e1;
  --cyan: #22d3ee;
  --blue: #38bdf8;
  --indigo: #818cf8;
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.35);
  --radius: 24px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at 12% 8%, rgba(34, 211, 238, 0.16), transparent 28rem),
    radial-gradient(circle at 86% 12%, rgba(99, 102, 241, 0.18), transparent 30rem),
    linear-gradient(180deg, #020617 0%, #0f172a 48%, #020617 100%);
}

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

button,
input,
select {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid rgba(148, 163, 184, 0.14);
  background: rgba(15, 23, 42, 0.88);
  backdrop-filter: blur(18px);
  box-shadow: 0 12px 40px rgba(2, 6, 23, 0.36);
}

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

.brand,
.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 21px;
  font-weight: 900;
  letter-spacing: -0.03em;
  background: linear-gradient(90deg, #22d3ee, #60a5fa, #a78bfa);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.brand-mark {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  color: #020617;
  background: linear-gradient(135deg, var(--cyan), var(--indigo));
  box-shadow: 0 12px 24px rgba(34, 211, 238, 0.24);
}

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

.nav-link,
.dropdown-trigger {
  display: inline-flex;
  align-items: center;
  min-height: 38px;
  padding: 0 12px;
  border: 0;
  border-radius: 999px;
  color: var(--soft);
  background: transparent;
  cursor: pointer;
  transition: color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.nav-link:hover,
.nav-link.is-active,
.dropdown-trigger:hover {
  color: #ffffff;
  background: rgba(34, 211, 238, 0.12);
  transform: translateY(-1px);
}

.nav-dropdown {
  position: relative;
}

.dropdown-panel {
  position: absolute;
  top: calc(100% + 12px);
  right: 0;
  min-width: 180px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(15, 23, 42, 0.98);
  box-shadow: var(--shadow);
  opacity: 0;
  pointer-events: none;
  transform: translateY(8px);
  transition: opacity 0.2s ease, transform 0.2s ease;
}

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

.dropdown-panel a,
.mobile-links a {
  display: block;
  padding: 10px 12px;
  border-radius: 12px;
  color: var(--soft);
}

.dropdown-panel a:hover,
.mobile-links a:hover {
  color: #ffffff;
  background: rgba(34, 211, 238, 0.12);
}

.header-search,
.mobile-search {
  display: flex;
  align-items: center;
  gap: 8px;
}

.header-search input,
.mobile-search input,
.search-page-form input,
.filter-panel input,
.filter-panel select {
  width: 230px;
  border: 1px solid rgba(148, 163, 184, 0.2);
  border-radius: 14px;
  outline: none;
  color: #e2e8f0;
  background: rgba(2, 6, 23, 0.52);
  padding: 11px 13px;
  transition: border 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.header-search input:focus,
.mobile-search input:focus,
.search-page-form input:focus,
.filter-panel input:focus,
.filter-panel select:focus {
  border-color: rgba(34, 211, 238, 0.7);
  box-shadow: 0 0 0 4px rgba(34, 211, 238, 0.1);
  background: rgba(2, 6, 23, 0.74);
}

.header-search button,
.mobile-search button {
  border: 0;
  border-radius: 14px;
  color: #020617;
  background: linear-gradient(135deg, var(--cyan), var(--blue));
  padding: 11px 14px;
  cursor: pointer;
  font-weight: 800;
}

.nav-toggle {
  display: none;
  width: 42px;
  height: 42px;
  margin-left: auto;
  border: 1px solid var(--line);
  border-radius: 13px;
  background: rgba(2, 6, 23, 0.48);
  cursor: pointer;
}

.nav-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  margin: 4px auto;
  border-radius: 999px;
  background: var(--text);
}

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

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

.mobile-search input {
  width: 100%;
}

.mobile-links {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 4px;
  margin-top: 10px;
}

.hero-section {
  position: relative;
  min-height: 70vh;
  overflow: hidden;
  border-bottom: 1px solid rgba(148, 163, 184, 0.12);
}

.hero-section::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 70% 28%, rgba(34, 211, 238, 0.16), transparent 22rem),
    linear-gradient(180deg, transparent 0%, rgba(2, 6, 23, 0.78) 100%);
  pointer-events: none;
  z-index: 2;
}

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

.hero-slide {
  display: flex;
  align-items: center;
  background-position: center;
  background-size: cover;
  opacity: 0;
  transition: opacity 0.8s ease, transform 6s ease;
  transform: scale(1.02);
}

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

.hero-copy {
  position: relative;
  z-index: 3;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding-top: 34px;
}

.hero-kicker,
.section-kicker {
  display: inline-flex;
  width: fit-content;
  align-items: center;
  gap: 8px;
  padding: 7px 12px;
  border: 1px solid rgba(34, 211, 238, 0.28);
  border-radius: 999px;
  color: var(--cyan);
  background: rgba(8, 47, 73, 0.4);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.hero-copy h1,
.hero-copy h2,
.page-hero h1,
.detail-info h1 {
  max-width: 780px;
  margin: 18px 0 16px;
  color: #ffffff;
  font-size: clamp(40px, 7vw, 82px);
  line-height: 0.95;
  letter-spacing: -0.065em;
}

.hero-copy p,
.page-hero p,
.detail-one-line {
  max-width: 700px;
  color: #cbd5e1;
  font-size: clamp(16px, 2vw, 20px);
  line-height: 1.8;
}

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

.primary-button,
.ghost-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 20px;
  border-radius: 999px;
  font-weight: 900;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border 0.2s ease;
}

.primary-button {
  color: #020617;
  background: linear-gradient(135deg, var(--cyan), var(--blue));
  box-shadow: 0 18px 40px rgba(34, 211, 238, 0.24);
  border: 0;
  cursor: pointer;
}

.ghost-button {
  color: #e2e8f0;
  border: 1px solid rgba(148, 163, 184, 0.28);
  background: rgba(15, 23, 42, 0.52);
}

.primary-button:hover,
.ghost-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 20px 46px rgba(14, 165, 233, 0.18);
}

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

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

.hero-tags span,
.tag-row span,
.detail-meta span,
.detail-meta a {
  padding: 7px 10px;
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 999px;
  color: #cbd5e1;
  background: rgba(15, 23, 42, 0.58);
  font-size: 13px;
}

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

.hero-dot {
  width: 38px;
  height: 4px;
  border: 0;
  border-radius: 999px;
  background: rgba(226, 232, 240, 0.32);
  cursor: pointer;
}

.hero-dot.is-active {
  background: linear-gradient(90deg, var(--cyan), var(--blue));
}

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

.elevated-panel {
  margin-top: 32px;
  padding: 34px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(15, 23, 42, 0.62);
  box-shadow: var(--shadow);
}

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

.section-heading h2 {
  margin: 8px 0 0;
  color: #ffffff;
  font-size: clamp(28px, 4vw, 42px);
  letter-spacing: -0.04em;
}

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

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

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

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

.movie-card:hover {
  transform: translateY(-6px);
  border-color: rgba(34, 211, 238, 0.36);
  box-shadow: 0 24px 70px rgba(8, 47, 73, 0.28);
}

.poster-frame,
.rank-poster,
.detail-poster {
  position: relative;
  display: block;
  background-position: center;
  background-size: cover;
  background-color: rgba(15, 23, 42, 0.96);
}

.poster-frame {
  aspect-ratio: 3 / 4;
}

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

.poster-year {
  top: 12px;
  left: 12px;
  padding: 6px 10px;
  color: #020617;
  background: rgba(34, 211, 238, 0.9);
}

.poster-play {
  right: 12px;
  bottom: 12px;
  padding: 8px 12px;
  color: #ffffff;
  background: rgba(2, 6, 23, 0.68);
  backdrop-filter: blur(8px);
}

.movie-card-body,
.rank-body {
  padding: 16px;
}

.movie-title {
  display: -webkit-box;
  min-height: 2.7em;
  overflow: hidden;
  color: #ffffff;
  font-size: 17px;
  font-weight: 900;
  line-height: 1.35;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.movie-title:hover {
  color: var(--cyan);
}

.movie-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 10px 0;
  color: var(--muted);
  font-size: 13px;
}

.movie-meta span {
  padding: 4px 8px;
  border-radius: 999px;
  background: rgba(2, 6, 23, 0.44);
}

.movie-card p,
.rank-card p {
  min-height: 4.8em;
  margin: 0 0 12px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.6;
}

.tag-row span {
  padding: 5px 8px;
  font-size: 12px;
}

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

.category-tile,
.category-card {
  min-height: 210px;
  display: flex;
  flex-direction: column;
  justify-content: end;
  padding: 24px;
  border: 1px solid rgba(148, 163, 184, 0.14);
  border-radius: var(--radius);
  background-position: center;
  background-size: cover;
  box-shadow: var(--shadow);
  transition: transform 0.24s ease, border-color 0.24s ease;
}

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

.category-tile span,
.category-card h2 {
  color: #ffffff;
  font-size: 28px;
  font-weight: 950;
  letter-spacing: -0.04em;
}

.category-tile p,
.category-card p {
  max-width: 560px;
  color: #cbd5e1;
  line-height: 1.7;
}

.category-card {
  min-height: 300px;
  justify-content: space-between;
}

.category-samples {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 16px;
}

.category-samples span {
  padding: 6px 10px;
  border-radius: 999px;
  color: #dbeafe;
  background: rgba(15, 23, 42, 0.66);
  font-size: 13px;
}

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

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

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

.rank-poster {
  min-height: 180px;
}

.rank-number {
  top: 12px;
  left: 12px;
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  color: #020617;
  background: linear-gradient(135deg, #fef08a, #22d3ee);
}

.page-hero,
.detail-hero {
  border-bottom: 1px solid rgba(148, 163, 184, 0.12);
  background-position: center;
  background-size: cover;
}

.page-hero {
  min-height: 360px;
  display: flex;
  align-items: center;
  padding: 72px max(16px, calc((100% - 1180px) / 2));
}

.compact-hero {
  background:
    radial-gradient(circle at 72% 24%, rgba(34, 211, 238, 0.14), transparent 24rem),
    linear-gradient(135deg, rgba(15, 23, 42, 0.96), rgba(2, 6, 23, 0.96));
}

.channel-hero {
  min-height: 430px;
}

.filter-panel {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 14px;
  margin-bottom: 22px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: rgba(2, 6, 23, 0.36);
}

.filter-panel label {
  display: grid;
  gap: 8px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.filter-panel input,
.filter-panel select {
  width: 100%;
}

.detail-hero {
  padding: 42px 0 32px;
}

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

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

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

.detail-poster {
  min-height: 460px;
  border: 1px solid rgba(148, 163, 184, 0.18);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.detail-info h1 {
  font-size: clamp(38px, 6vw, 68px);
}

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

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

.player-card {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(34, 211, 238, 0.24);
  border-radius: 26px;
  background: #000000;
  box-shadow: var(--shadow);
  aspect-ratio: 16 / 9;
}

.movie-player,
.player-overlay {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.movie-player {
  display: block;
  background: #000000;
}

.player-overlay {
  z-index: 3;
  display: grid;
  place-items: center;
  gap: 10px;
  border: 0;
  color: #ffffff;
  background-position: center;
  background-size: cover;
  cursor: pointer;
  text-align: center;
}

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

.play-circle {
  width: 82px;
  height: 82px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: #020617;
  background: linear-gradient(135deg, var(--cyan), #ffffff);
  font-size: 28px;
  box-shadow: 0 20px 58px rgba(34, 211, 238, 0.34);
}

.player-overlay strong {
  display: block;
  max-width: min(720px, calc(100% - 32px));
  font-size: clamp(24px, 4vw, 46px);
  letter-spacing: -0.04em;
}

.player-overlay em {
  color: var(--cyan);
  font-style: normal;
  font-weight: 900;
}

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

.content-panel,
.search-panel {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(15, 23, 42, 0.72);
  box-shadow: var(--shadow);
}

.content-panel {
  padding: 28px;
}

.content-panel h2 {
  margin: 0 0 14px;
  color: #ffffff;
  font-size: 26px;
}

.content-panel p {
  margin: 0;
  color: #cbd5e1;
  line-height: 1.9;
}

.search-panel {
  padding: 28px;
}

.search-page-form {
  display: flex;
  gap: 12px;
  margin-bottom: 18px;
}

.search-page-form input {
  width: 100%;
}

.search-status {
  margin-bottom: 18px;
  color: var(--muted);
}

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

.site-footer {
  margin-top: 40px;
  border-top: 1px solid rgba(148, 163, 184, 0.14);
  background: rgba(2, 6, 23, 0.72);
}

.footer-shell {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 44px 0;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 34px;
}

.footer-shell p,
.footer-shell a,
.footer-bottom {
  color: var(--muted);
  line-height: 1.7;
}

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

.footer-shell ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.footer-shell li + li {
  margin-top: 8px;
}

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

.footer-bottom {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 18px 0 28px;
  border-top: 1px solid rgba(148, 163, 184, 0.1);
  font-size: 14px;
}

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

  .nav-toggle {
    display: block;
  }

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

  .compact-rank-list,
  .category-grid,
  .category-overview-grid,
  .detail-content {
    grid-template-columns: 1fr;
  }

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

@media (max-width: 760px) {
  .nav-shell {
    height: 62px;
  }

  .hero-section {
    min-height: 660px;
  }

  .hero-copy h1,
  .hero-copy h2,
  .page-hero h1,
  .detail-info h1 {
    font-size: 42px;
  }

  .section-shell,
  .elevated-panel {
    width: min(100% - 24px, 1180px);
    padding-top: 34px;
    padding-bottom: 34px;
  }

  .elevated-panel,
  .search-panel {
    padding: 20px;
  }

  .section-heading {
    display: block;
  }

  .movie-grid,
  .feature-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
  }

  .movie-card-body,
  .rank-body {
    padding: 13px;
  }

  .movie-card p {
    display: none;
  }

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

  .rank-poster {
    min-height: 150px;
  }

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

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

  .detail-poster {
    min-height: 420px;
  }

  .player-card {
    border-radius: 18px;
  }

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

@media (max-width: 480px) {
  .brand-text {
    font-size: 18px;
  }

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

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

  .rank-poster {
    aspect-ratio: 16 / 10;
  }

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

  .search-page-form,
  .hero-actions {
    flex-direction: column;
  }

  .primary-button,
  .ghost-button {
    width: 100%;
  }
}
