:root {
  color-scheme: dark;
  --bg: #020617;
  --bg-soft: #0f172a;
  --panel: rgba(15, 23, 42, 0.78);
  --panel-strong: rgba(30, 41, 59, 0.92);
  --line: rgba(148, 163, 184, 0.18);
  --text: #f8fafc;
  --muted: #94a3b8;
  --cyan: #22d3ee;
  --blue: #2563eb;
  --cyan-soft: rgba(34, 211, 238, 0.16);
  --shadow: 0 20px 60px rgba(0, 0, 0, 0.36);
  --radius: 24px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

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

body.menu-open {
  overflow: hidden;
}

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

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

button,
input,
select {
  font: inherit;
}

main {
  min-height: 60vh;
}

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

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

.site-logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  white-space: nowrap;
}

.logo-mark {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--cyan), var(--blue));
  color: #ffffff;
  box-shadow: 0 10px 24px rgba(34, 211, 238, 0.28);
}

.logo-text {
  font-size: 1.24rem;
  background: linear-gradient(90deg, #67e8f9, #60a5fa);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

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

.nav-link,
.mobile-link {
  color: #cbd5e1;
  font-weight: 650;
  transition: color 0.2s ease, transform 0.2s ease;
}

.nav-link:hover,
.nav-link.is-active,
.mobile-link:hover,
.mobile-link.is-active {
  color: var(--cyan);
}

.nav-search {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(15, 23, 42, 0.86);
}

.nav-search input,
.mobile-search input {
  width: 210px;
  border: 0;
  outline: 0;
  color: var(--text);
  background: transparent;
  padding: 8px 10px;
}

.nav-search button,
.mobile-search button {
  border: 0;
  border-radius: 11px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--cyan), var(--blue));
  padding: 8px 13px;
  cursor: pointer;
}

.mobile-toggle {
  display: none;
  width: 44px;
  height: 44px;
  margin-left: auto;
  border: 0;
  border-radius: 12px;
  background: rgba(30, 41, 59, 0.88);
  cursor: pointer;
}

.mobile-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  margin: 5px auto;
  background: #e2e8f0;
  border-radius: 8px;
}

.mobile-panel {
  display: none;
  border-top: 1px solid var(--line);
  background: rgba(15, 23, 42, 0.98);
  padding: 16px;
}

.mobile-panel.is-open {
  display: grid;
  gap: 14px;
}

.mobile-search {
  display: flex;
  gap: 8px;
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 5px;
}

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

.hero {
  position: relative;
  min-height: 72vh;
  overflow: hidden;
  background: #020617;
}

.hero-stage {
  position: relative;
  min-height: 72vh;
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  opacity: 0;
  visibility: hidden;
  background-position: center;
  background-size: cover;
  transition: opacity 0.8s ease, visibility 0.8s ease;
}

.hero-slide.is-active {
  opacity: 1;
  visibility: visible;
}

.hero-slide::after {
  content: "";
  position: absolute;
  inset: auto 0 0 0;
  height: 42%;
  background: linear-gradient(180deg, transparent, #020617 92%);
}

.hero-content {
  position: relative;
  z-index: 2;
  width: min(920px, calc(100% - 34px));
  text-align: center;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 14px;
  color: var(--cyan);
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.hero-content h1,
.hero-content h2 {
  margin: 0;
}

.hero-content h1 {
  font-size: clamp(3rem, 8vw, 6.6rem);
  line-height: 1;
  background: linear-gradient(90deg, #a5f3fc, #60a5fa, #22d3ee);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-content h2 {
  margin-top: 18px;
  font-size: clamp(2rem, 5vw, 4.4rem);
  line-height: 1.08;
}

.hero-content p {
  width: min(780px, 100%);
  margin: 22px auto 0;
  color: #cbd5e1;
  font-size: clamp(1.05rem, 2.3vw, 1.45rem);
  line-height: 1.8;
}

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

.inline-actions {
  justify-content: flex-start;
}

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

.primary-button {
  color: #ffffff;
  background: linear-gradient(135deg, var(--cyan), var(--blue));
  box-shadow: 0 14px 32px rgba(37, 99, 235, 0.34);
}

.ghost-button {
  color: #dbeafe;
  border: 1px solid rgba(34, 211, 238, 0.36);
  background: rgba(15, 23, 42, 0.52);
}

.primary-button:hover,
.ghost-button:hover {
  transform: translateY(-2px) scale(1.02);
  box-shadow: 0 16px 36px rgba(34, 211, 238, 0.28);
}

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

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

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

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

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

.section-heading h2,
.split-feature h2,
.footer-column h2,
.related-box h2 {
  margin: 0;
  color: #f8fafc;
}

.section-heading h2,
.split-feature h2 {
  font-size: clamp(1.8rem, 4vw, 2.5rem);
}

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

.featured-row {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(280px, 360px);
  gap: 22px;
  overflow-x: auto;
  padding: 4px 0 18px;
  scrollbar-color: rgba(34, 211, 238, 0.55) transparent;
}

.featured-card {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel);
  box-shadow: var(--shadow);
  transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
}

.featured-card:hover {
  transform: translateY(-6px);
  border-color: rgba(34, 211, 238, 0.45);
  box-shadow: 0 22px 58px rgba(34, 211, 238, 0.18);
}

.featured-card img {
  width: 100%;
  height: 210px;
  object-fit: cover;
}

.featured-card-body {
  padding: 18px;
}

.featured-card-body span,
.movie-meta,
.rank-meta,
.detail-meta {
  color: var(--muted);
}

.featured-card-body h3 {
  margin: 8px 0;
  font-size: 1.2rem;
}

.featured-card-body p,
.movie-one-line,
.category-tile p,
.category-overview-card p,
.split-feature p,
.page-hero p,
.detail-block p,
.footer-brand p {
  color: #cbd5e1;
  line-height: 1.75;
}

.split-feature {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 34px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 34px;
  padding: 42px;
  background: linear-gradient(135deg, rgba(30, 41, 59, 0.94), rgba(15, 23, 42, 0.78));
  box-shadow: var(--shadow);
}

.rank-preview,
.rank-list {
  display: grid;
  gap: 12px;
}

.rank-row {
  display: grid;
  grid-template-columns: 64px 64px minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 14px;
  min-height: 78px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(15, 23, 42, 0.78);
  padding: 8px 14px;
  transition: transform 0.18s ease, border-color 0.18s ease, background 0.18s ease;
}

.rank-row:hover {
  transform: translateX(4px);
  border-color: rgba(34, 211, 238, 0.38);
  background: rgba(30, 41, 59, 0.86);
}

.rank-number {
  color: var(--cyan);
  font-size: 1.2rem;
  font-weight: 900;
}

.rank-row img {
  width: 56px;
  height: 56px;
  border-radius: 14px;
  object-fit: cover;
}

.rank-title {
  min-width: 0;
  overflow: hidden;
  color: #f8fafc;
  font-weight: 800;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.rank-heat {
  color: #67e8f9;
  font-weight: 800;
}

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

.category-tile,
.category-overview-card a {
  display: grid;
  min-height: 210px;
  border: 1px solid var(--line);
  border-radius: 28px;
  background:
    linear-gradient(135deg, rgba(34, 211, 238, 0.12), transparent 38%),
    rgba(15, 23, 42, 0.82);
  padding: 24px;
  box-shadow: var(--shadow);
  transition: transform 0.2s ease, border-color 0.2s ease;
}

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

.category-tile span {
  color: var(--cyan);
  font-weight: 900;
}

.category-tile h3,
.category-overview-card h2 {
  margin: 16px 0 8px;
  line-height: 1.35;
}

.category-cover-stack {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-bottom: 18px;
}

.category-cover-stack img {
  width: 100%;
  aspect-ratio: 3 / 4;
  border-radius: 16px;
  object-fit: cover;
}

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

.movie-card {
  border: 1px solid var(--line);
  border-radius: 24px;
  background: rgba(15, 23, 42, 0.76);
  box-shadow: var(--shadow);
  overflow: hidden;
  transition: transform 0.22s ease, border-color 0.22s ease, box-shadow 0.22s ease;
}

.movie-card:hover {
  transform: translateY(-7px) scale(1.01);
  border-color: rgba(34, 211, 238, 0.5);
  box-shadow: 0 22px 58px rgba(34, 211, 238, 0.14);
}

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

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

.movie-poster img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  transition: transform 0.3s ease;
}

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

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

.movie-badge,
.play-pill {
  position: absolute;
  z-index: 2;
  border-radius: 999px;
  padding: 6px 11px;
  font-size: 0.78rem;
  font-weight: 800;
}

.movie-badge {
  top: 12px;
  left: 12px;
  background: rgba(34, 211, 238, 0.82);
  color: #ffffff;
}

.play-pill {
  right: 12px;
  bottom: 12px;
  color: #ffffff;
  background: rgba(37, 99, 235, 0.86);
}

.movie-info {
  padding: 18px;
}

.movie-info h2 {
  display: -webkit-box;
  margin: 0 0 8px;
  overflow: hidden;
  font-size: 1.12rem;
  line-height: 1.35;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.movie-one-line {
  display: -webkit-box;
  min-height: 3.45em;
  margin: 12px 0;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

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

.tag-row span {
  border: 1px solid rgba(148, 163, 184, 0.18);
  border-radius: 999px;
  color: #cbd5e1;
  background: rgba(30, 41, 59, 0.78);
  padding: 5px 10px;
  font-size: 0.78rem;
}

.page-hero {
  width: min(1180px, calc(100% - 32px));
  margin: 34px auto 0;
  border: 1px solid var(--line);
  border-radius: 34px;
  background:
    radial-gradient(circle at top right, rgba(34, 211, 238, 0.16), transparent 36rem),
    linear-gradient(135deg, rgba(30, 41, 59, 0.9), rgba(15, 23, 42, 0.78));
  box-shadow: var(--shadow);
  padding: 42px;
}

.slim-hero {
  min-height: 260px;
}

.page-hero h1 {
  margin: 0;
  font-size: clamp(2.3rem, 5.5vw, 4.4rem);
  line-height: 1.08;
}

.page-hero p {
  max-width: 760px;
  margin-bottom: 0;
  font-size: 1.08rem;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-top: 22px;
  color: var(--muted);
}

.breadcrumb a {
  color: #67e8f9;
}

.filter-panel {
  width: min(1180px, calc(100% - 32px));
  margin: 26px auto 0;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: rgba(15, 23, 42, 0.72);
  padding: 20px;
}

.filter-grid {
  display: grid;
  grid-template-columns: 1.4fr 0.8fr 0.8fr 0.8fr;
  gap: 14px;
}

.filter-grid label {
  display: grid;
  gap: 8px;
  color: #cbd5e1;
  font-weight: 700;
}

.filter-grid input,
.filter-grid select {
  width: 100%;
  min-height: 46px;
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 14px;
  color: var(--text);
  outline: none;
  background: rgba(2, 6, 23, 0.66);
  padding: 0 14px;
}

.filter-grid input:focus,
.filter-grid select:focus {
  border-color: rgba(34, 211, 238, 0.68);
}

.filter-empty {
  display: none;
  margin: 18px 0 0;
  color: #fbbf24;
  font-weight: 700;
}

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

.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 28px;
  width: min(1180px, calc(100% - 32px));
  margin: 34px auto 0;
}

.player-panel {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(34, 211, 238, 0.22);
  border-radius: 28px;
  background: #000000;
  box-shadow: var(--shadow);
}

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

.player-cover {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 14px;
  border: 0;
  color: #ffffff;
  background: linear-gradient(180deg, rgba(2, 6, 23, 0.32), rgba(2, 6, 23, 0.78));
  cursor: pointer;
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

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

.player-icon {
  display: grid;
  place-items: center;
  width: 76px;
  height: 76px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--cyan), var(--blue));
  box-shadow: 0 16px 34px rgba(34, 211, 238, 0.28);
  font-size: 2rem;
}

.movie-detail-content,
.poster-card,
.related-box {
  border: 1px solid var(--line);
  border-radius: 28px;
  background: rgba(15, 23, 42, 0.78);
  box-shadow: var(--shadow);
}

.movie-detail-content {
  margin-top: 24px;
  padding: 28px;
}

.movie-detail-content h1 {
  margin: 0 0 14px;
  font-size: clamp(2rem, 4vw, 3.2rem);
  line-height: 1.12;
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 18px;
}

.detail-meta span {
  border-radius: 999px;
  background: rgba(30, 41, 59, 0.88);
  padding: 8px 12px;
}

.detail-tags {
  margin-bottom: 22px;
}

.detail-block {
  margin-top: 24px;
}

.detail-block h2 {
  margin: 0 0 10px;
  font-size: 1.35rem;
}

.detail-block p {
  margin: 0;
  font-size: 1.03rem;
}

.detail-side {
  display: grid;
  align-content: start;
  gap: 22px;
}

.poster-card {
  padding: 18px;
}

.poster-card img {
  width: 100%;
  border-radius: 22px;
  object-fit: cover;
}

.full-button {
  width: 100%;
  margin-top: 16px;
}

.related-box {
  padding: 18px;
}

.related-box h2 {
  margin-bottom: 14px;
}

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

.related-list .featured-card {
  display: grid;
  grid-template-columns: 96px 1fr;
  border-radius: 18px;
}

.related-list .featured-card img {
  height: 126px;
}

.related-list .featured-card-body {
  padding: 13px;
}

.related-list .featured-card-body h3 {
  display: -webkit-box;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.related-list .featured-card-body p {
  display: none;
}

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

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

.footer-brand p {
  max-width: 520px;
}

.footer-column h2 {
  font-size: 1rem;
  margin-bottom: 14px;
}

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

.footer-column a {
  color: var(--muted);
}

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

.footer-bottom {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  border-top: 1px solid var(--line);
  color: var(--muted);
  padding: 18px 0 26px;
}

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

  .mobile-toggle {
    display: block;
  }

  .split-feature,
  .detail-layout,
  .footer-inner {
    grid-template-columns: 1fr;
  }

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

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

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

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

  .logo-text {
    font-size: 1.02rem;
  }

  .hero,
  .hero-stage {
    min-height: 76vh;
  }

  .hero-content p {
    font-size: 1rem;
  }

  .hero-actions,
  .inline-actions {
    justify-content: stretch;
  }

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

  .content-section,
  .page-hero,
  .filter-panel,
  .detail-layout,
  .footer-inner,
  .footer-bottom {
    width: calc(100% - 24px);
  }

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

  .split-feature,
  .page-hero,
  .movie-detail-content {
    padding: 24px;
    border-radius: 24px;
  }

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

  .rank-row {
    grid-template-columns: 44px 54px minmax(0, 1fr);
  }

  .rank-meta,
  .rank-heat {
    grid-column: 3;
  }

  .related-list .featured-card {
    grid-template-columns: 84px 1fr;
  }
}
