* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: #020617;
  color: #f8fafc;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
  line-height: 1.6;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -2;
  background:
    radial-gradient(circle at 20% 20%, rgba(6, 182, 212, 0.18), transparent 32rem),
    radial-gradient(circle at 82% 8%, rgba(88, 28, 135, 0.22), transparent 30rem),
    linear-gradient(180deg, #020617 0%, #0f172a 46%, #000 100%);
}

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

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

button,
input,
select {
  font: inherit;
}

[hidden] {
  display: none !important;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid rgba(30, 64, 175, 0.3);
  background: rgba(2, 6, 23, 0.82);
  backdrop-filter: blur(14px);
}

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

.logo,
.footer-logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 24px;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: #fff;
}

.logo-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 999px;
  color: #020617;
  background: linear-gradient(135deg, #22d3ee, #60a5fa);
  box-shadow: 0 12px 30px rgba(34, 211, 238, 0.28);
  font-size: 14px;
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 28px;
}

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

.nav-link:hover,
.nav-link.active {
  color: #22d3ee;
}

.menu-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 0;
  color: #fff;
  background: rgba(15, 23, 42, 0.75);
  border-radius: 12px;
  cursor: pointer;
}

.menu-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  margin: 5px auto;
  background: currentColor;
}

.mobile-nav {
  display: none;
  width: min(1280px, calc(100% - 32px));
  margin: 0 auto 16px;
  padding: 12px;
  border-radius: 18px;
  background: rgba(15, 23, 42, 0.96);
}

.mobile-nav.open {
  display: grid;
  gap: 10px;
}

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

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  pointer-events: none;
  transition: opacity 1s ease;
}

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

.hero-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.04);
  filter: saturate(1.06) contrast(1.03);
}

.hero-shade {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(2, 6, 23, 0.94), rgba(2, 6, 23, 0.42), rgba(2, 6, 23, 0.18)),
    linear-gradient(0deg, #020617 0%, rgba(2, 6, 23, 0.24) 48%, rgba(2, 6, 23, 0.74) 100%);
}

.hero-content {
  position: absolute;
  left: max(24px, calc((100% - 1280px) / 2));
  right: 24px;
  bottom: 13vh;
  max-width: 760px;
}

.eyebrow {
  display: inline-flex;
  margin-bottom: 14px;
  color: #22d3ee;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.hero-content h1,
.page-hero h1,
.detail-info h1 {
  margin: 0;
  color: #fff;
  font-size: clamp(40px, 7vw, 76px);
  line-height: 1.04;
  letter-spacing: -0.045em;
  text-shadow: 0 18px 45px rgba(0, 0, 0, 0.48);
}

.hero-content p {
  max-width: 680px;
  margin: 20px 0 28px;
  color: #e2e8f0;
  font-size: clamp(17px, 2vw, 22px);
  text-shadow: 0 10px 24px rgba(0, 0, 0, 0.55);
}

.hero-actions,
.detail-info .btn {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

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

.btn.primary {
  color: #00111a;
  background: linear-gradient(135deg, #22d3ee, #60a5fa);
  box-shadow: 0 16px 38px rgba(34, 211, 238, 0.3);
}

.btn.ghost {
  color: #f8fafc;
  background: rgba(15, 23, 42, 0.68);
  border: 1px solid rgba(148, 163, 184, 0.28);
}

.btn:hover {
  transform: translateY(-2px) scale(1.02);
}

.hero-dots {
  position: absolute;
  right: max(24px, calc((100% - 1280px) / 2));
  bottom: 42px;
  display: flex;
  gap: 8px;
}

.hero-dot {
  width: 10px;
  height: 10px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.52);
  cursor: pointer;
  transition: width 0.2s ease, background 0.2s ease;
}

.hero-dot.active {
  width: 34px;
  background: #22d3ee;
}

.search-band,
.section-wrap,
.page-hero,
.detail-content {
  width: min(1280px, calc(100% - 32px));
  margin-left: auto;
  margin-right: auto;
}

.search-band {
  margin-top: -48px;
  position: relative;
  z-index: 3;
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(280px, 0.6fr);
  gap: 18px;
  padding: 22px;
  border: 1px solid rgba(30, 64, 175, 0.36);
  border-radius: 28px;
  background: rgba(15, 23, 42, 0.86);
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.38);
  backdrop-filter: blur(16px);
}

.quick-search label {
  display: block;
  margin-bottom: 10px;
  color: #cbd5e1;
  font-weight: 700;
}

.search-row {
  display: flex;
  gap: 12px;
}

.search-row input,
.filter-bar input,
.filter-bar select {
  width: 100%;
  border: 1px solid rgba(148, 163, 184, 0.25);
  outline: 0;
  border-radius: 16px;
  background: rgba(2, 6, 23, 0.78);
  color: #f8fafc;
  padding: 14px 16px;
}

.search-row button {
  border: 0;
  border-radius: 16px;
  color: #00111a;
  background: #22d3ee;
  padding: 0 26px;
  font-weight: 800;
  cursor: pointer;
}

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

.quick-links a {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  border-radius: 16px;
  background: rgba(51, 65, 85, 0.58);
  color: #dbeafe;
  font-weight: 750;
  transition: background 0.2s ease, color 0.2s ease;
}

.quick-links a:hover {
  background: rgba(8, 145, 178, 0.4);
  color: #fff;
}

.section-wrap {
  padding: 72px 0 0;
}

.section-title {
  margin-bottom: 24px;
}

.section-title p {
  margin: 0 0 6px;
  color: #22d3ee;
  font-weight: 850;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.section-title h2 {
  margin: 0;
  color: #fff;
  font-size: clamp(28px, 3vw, 42px);
  line-height: 1.1;
}

.section-title.small h2 {
  font-size: 28px;
}

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

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

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

.movie-card {
  overflow: hidden;
  border: 1px solid rgba(30, 64, 175, 0.3);
  border-radius: 24px;
  background: linear-gradient(145deg, rgba(30, 41, 59, 0.88), rgba(15, 23, 42, 0.8));
  box-shadow: 0 20px 55px rgba(0, 0, 0, 0.26);
  transition: transform 0.22s ease, border-color 0.22s ease, box-shadow 0.22s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  border-color: rgba(34, 211, 238, 0.42);
  box-shadow: 0 26px 70px rgba(0, 0, 0, 0.38);
}

.poster-link {
  position: relative;
  display: block;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  background: linear-gradient(135deg, rgba(8, 47, 73, 0.8), rgba(30, 41, 59, 0.8));
}

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

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

.badge {
  position: absolute;
  top: 12px;
  left: 12px;
  padding: 4px 9px;
  border-radius: 999px;
  color: #07111f;
  background: #22d3ee;
  font-size: 12px;
  font-weight: 850;
}

.card-body {
  padding: 16px;
}

.card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 8px;
  color: #94a3b8;
  font-size: 13px;
}

.card-title {
  margin: 0 0 8px;
  color: #fff;
  font-size: 19px;
  line-height: 1.32;
}

.card-title a:hover {
  color: #67e8f9;
}

.card-text {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  min-height: 76px;
  overflow: hidden;
  margin: 0 0 14px;
  color: #cbd5e1;
  font-size: 14px;
}

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

.tag-row span,
.detail-tags a {
  border-radius: 999px;
  padding: 4px 9px;
  color: #bae6fd;
  background: rgba(8, 145, 178, 0.18);
  font-size: 12px;
  font-weight: 700;
}

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

.ranking-panel,
.ranking-list-card,
.ranking-side,
.detail-copy article,
.category-card-large,
.category-tile {
  border: 1px solid rgba(30, 64, 175, 0.3);
  border-radius: 28px;
  background: linear-gradient(145deg, rgba(30, 41, 59, 0.82), rgba(15, 23, 42, 0.76));
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.25);
}

.ranking-panel,
.ranking-list-card,
.ranking-side {
  padding: 24px;
}

.rank-list,
.ranking-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.rank-list li + li {
  margin-top: 10px;
}

.rank-list a {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  padding: 12px;
  border-radius: 16px;
  background: rgba(2, 6, 23, 0.38);
}

.rank-list span,
.rank-num {
  color: #22d3ee;
  font-weight: 900;
}

.rank-list strong {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.rank-list em,
.ranking-list em {
  color: #94a3b8;
  font-style: normal;
  font-size: 13px;
}

.text-link {
  display: inline-flex;
  margin-top: 18px;
  color: #22d3ee;
  font-weight: 800;
}

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

.category-tile,
.category-card-large {
  padding: 22px;
}

.category-tile h2,
.category-card-large h2 {
  margin: 0 0 10px;
  font-size: 25px;
  line-height: 1.2;
}

.category-tile p,
.category-card-large p {
  margin: 0 0 18px;
  color: #cbd5e1;
}

.mini-strip,
.poster-row {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

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

.compact-card {
  display: block;
  overflow: hidden;
  border-radius: 16px;
  background: rgba(2, 6, 23, 0.45);
}

.compact-card img {
  width: 100%;
  aspect-ratio: 2 / 3;
  object-fit: cover;
}

.compact-card span {
  display: block;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  padding: 8px;
  color: #dbeafe;
  font-size: 12px;
  font-weight: 700;
}

.page-main {
  padding-bottom: 80px;
}

.page-hero {
  padding: 82px 0 18px;
}

.page-hero.slim h1 {
  font-size: clamp(38px, 5vw, 60px);
}

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

.filter-bar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 180px 180px;
  gap: 12px;
  margin-bottom: 24px;
  padding: 16px;
  border: 1px solid rgba(30, 64, 175, 0.3);
  border-radius: 24px;
  background: rgba(15, 23, 42, 0.75);
}

.ranking-list.full li + li {
  margin-top: 14px;
}

.ranking-list.full a {
  display: grid;
  grid-template-columns: 44px 70px minmax(0, 1fr);
  gap: 14px;
  align-items: center;
  padding: 12px;
  border-radius: 18px;
  background: rgba(2, 6, 23, 0.36);
}

.ranking-list.full img {
  width: 70px;
  aspect-ratio: 2 / 3;
  border-radius: 12px;
  object-fit: cover;
}

.ranking-list.full strong {
  display: block;
  color: #fff;
  font-size: 17px;
}

.ranking-list.full p {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin: 4px 0;
  color: #cbd5e1;
  font-size: 14px;
}

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

.detail-main {
  padding-bottom: 80px;
}

.detail-hero {
  position: relative;
  overflow: hidden;
  min-height: 62vh;
}

.detail-bg {
  position: absolute;
  inset: 0;
  z-index: -2;
}

.detail-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: blur(12px) saturate(1.1);
  transform: scale(1.08);
  opacity: 0.55;
}

.detail-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(2, 6, 23, 0.95), rgba(2, 6, 23, 0.6)),
    linear-gradient(0deg, #020617, rgba(2, 6, 23, 0.15));
}

.detail-content {
  padding: 58px 0 34px;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 26px;
  color: #cbd5e1;
  font-size: 14px;
}

.breadcrumb a {
  color: #67e8f9;
}

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

.detail-poster {
  overflow: hidden;
  border-radius: 28px;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.42);
}

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

.detail-one-line {
  max-width: 800px;
  margin: 18px 0 18px;
  color: #e2e8f0;
  font-size: 19px;
}

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

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

.player-card {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(34, 211, 238, 0.25);
  border-radius: 30px;
  background: #000;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.46);
  aspect-ratio: 16 / 9;
}

.movie-video {
  width: 100%;
  height: 100%;
  background: #000;
}

.play-layer {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  border: 0;
  color: #fff;
  background: linear-gradient(0deg, rgba(2, 6, 23, 0.75), rgba(2, 6, 23, 0.28));
  cursor: pointer;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

.play-layer.is-hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.play-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 82px;
  height: 82px;
  border-radius: 999px;
  color: #020617;
  background: linear-gradient(135deg, #22d3ee, #60a5fa);
  box-shadow: 0 18px 48px rgba(34, 211, 238, 0.36);
  font-size: 30px;
}

.play-layer strong {
  max-width: 80%;
  font-size: clamp(22px, 4vw, 42px);
  line-height: 1.15;
  text-align: center;
}

.detail-copy {
  display: grid;
  grid-template-columns: 1fr;
  gap: 18px;
}

.detail-copy article {
  padding: 26px;
}

.detail-copy h2 {
  margin: 0 0 14px;
  color: #fff;
  font-size: 28px;
}

.detail-copy p {
  margin: 0;
  color: #dbeafe;
  font-size: 17px;
}

.meta-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin: 0;
}

.meta-list div {
  padding: 12px;
  border-radius: 16px;
  background: rgba(2, 6, 23, 0.42);
}

.meta-list dt {
  color: #94a3b8;
  font-size: 13px;
}

.meta-list dd {
  margin: 4px 0 0;
  color: #fff;
  font-weight: 750;
}

.site-footer {
  margin-top: 80px;
  border-top: 1px solid rgba(30, 64, 175, 0.28);
  background: rgba(2, 6, 23, 0.86);
}

.footer-inner {
  width: min(1280px, calc(100% - 32px));
  margin: 0 auto;
  padding: 28px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  color: #94a3b8;
}

.footer-logo {
  font-size: 20px;
}

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

  .two-column-section,
  .ranking-layout {
    grid-template-columns: 1fr;
  }

  .ranking-panel {
    order: -1;
  }
}

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

  .menu-toggle {
    display: inline-block;
  }

  .hero-content {
    bottom: 11vh;
  }

  .search-band {
    grid-template-columns: 1fr;
    margin-top: -34px;
  }

  .search-row,
  .filter-bar,
  .detail-grid,
  .footer-inner {
    grid-template-columns: 1fr;
    flex-direction: column;
  }

  .search-row {
    display: grid;
  }

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

  .detail-grid {
    display: grid;
  }

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

@media (max-width: 640px) {
  .nav-wrap,
  .search-band,
  .section-wrap,
  .page-hero,
  .detail-content,
  .footer-inner {
    width: min(100% - 24px, 1280px);
  }

  .logo {
    font-size: 20px;
  }

  .hero-carousel {
    min-height: 72vh;
  }

  .hero-content h1,
  .page-hero.slim h1,
  .detail-info h1 {
    font-size: 38px;
  }

  .hero-dots {
    left: 24px;
    right: auto;
    bottom: 22px;
  }

  .movie-grid,
  .featured-grid,
  .compact-grid,
  .related-grid,
  .all-grid,
  .side-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
  }

  .card-body {
    padding: 12px;
  }

  .card-title {
    font-size: 16px;
  }

  .card-text {
    min-height: 66px;
    font-size: 13px;
  }

  .poster-row,
  .mini-strip {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .detail-poster {
    display: none;
  }

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