* {
  box-sizing: border-box;
}

:root {
  color-scheme: dark;
  --bg: #070816;
  --panel: rgba(17, 24, 39, 0.72);
  --panel-strong: rgba(17, 24, 39, 0.92);
  --text: #f8fafc;
  --muted: #a7b0c2;
  --line: rgba(255, 255, 255, 0.12);
  --yellow: #facc15;
  --pink: #f472b6;
  --purple: #a855f7;
  --cyan: #22d3ee;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at 15% 5%, rgba(168, 85, 247, 0.24), transparent 34rem),
    radial-gradient(circle at 90% 0%, rgba(236, 72, 153, 0.2), transparent 32rem),
    linear-gradient(180deg, #080816 0%, #0b1020 48%, #05060d 100%);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
}

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

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

button,
input,
select {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 60;
  background: linear-gradient(90deg, rgba(49, 46, 129, 0.96), rgba(88, 28, 135, 0.96), rgba(131, 24, 67, 0.96));
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.3);
  backdrop-filter: blur(18px);
}

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

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: clamp(20px, 2.6vw, 28px);
  font-weight: 900;
  letter-spacing: -0.04em;
  white-space: nowrap;
}

.brand span:last-child {
  background: linear-gradient(90deg, #fde047, #f9a8d4);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.brand-symbol {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 15px;
  background: rgba(250, 204, 21, 0.16);
  color: var(--yellow);
  box-shadow: inset 0 0 0 1px rgba(250, 204, 21, 0.35);
}

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

.desktop-nav a,
.nav-dropdown > button {
  border: 0;
  background: transparent;
  color: rgba(255, 255, 255, 0.88);
  padding: 8px 0;
  cursor: pointer;
  transition: color 0.2s ease;
}

.desktop-nav a:hover,
.nav-dropdown > button:hover,
.desktop-nav a.is-active {
  color: var(--yellow);
}

.nav-dropdown {
  position: relative;
}

.dropdown-panel {
  position: absolute;
  top: 100%;
  left: -16px;
  width: 180px;
  padding: 8px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(12, 17, 31, 0.98);
  box-shadow: 0 24px 50px rgba(0, 0, 0, 0.45);
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  transition: 0.2s ease;
}

.nav-dropdown:hover .dropdown-panel {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.dropdown-panel a {
  display: block;
  padding: 10px 12px;
  border-radius: 12px;
}

.dropdown-panel a:hover {
  background: rgba(255, 255, 255, 0.08);
}

.nav-search {
  display: flex;
  align-items: center;
  margin-left: 4px;
}

.nav-search input,
.mobile-nav input,
.filter-input,
.filter-select {
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  outline: 0;
}

.nav-search input {
  width: 170px;
  padding: 10px 14px;
  border-radius: 999px 0 0 999px;
}

.nav-search button,
.mobile-nav button,
.primary-button,
.secondary-button {
  border: 0;
  cursor: pointer;
  font-weight: 800;
  color: #111827;
  background: linear-gradient(135deg, #facc15, #fb7185);
  box-shadow: 0 14px 28px rgba(251, 113, 133, 0.2);
}

.nav-search button {
  padding: 11px 16px;
  border-radius: 0 999px 999px 0;
}

.menu-toggle {
  display: none;
  margin-left: auto;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.08);
  color: white;
  padding: 9px 12px;
}

.mobile-nav {
  display: none;
  width: min(1200px, calc(100% - 32px));
  margin: 0 auto;
  padding: 0 0 18px;
}

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

.mobile-nav a {
  padding: 12px 14px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.08);
}

.mobile-nav form {
  display: flex;
  gap: 8px;
}

.mobile-nav input {
  min-width: 0;
  flex: 1;
  padding: 12px 14px;
  border-radius: 14px;
}

.mobile-nav button {
  border-radius: 14px;
  padding: 0 16px;
}

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

.hero-carousel {
  position: relative;
  min-height: clamp(560px, 74vh, 760px);
  margin: 24px auto 0;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 34px;
  background: rgba(9, 12, 25, 0.9);
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.38);
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: grid;
  align-items: center;
  grid-template-columns: minmax(0, 1.08fr) minmax(280px, 0.72fr);
  gap: 42px;
  padding: clamp(28px, 5vw, 72px);
  background-position: center;
  background-size: cover;
  opacity: 0;
  visibility: hidden;
  transform: scale(1.02);
  transition: opacity 0.7s ease, transform 1.2s ease, visibility 0.7s ease;
}

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

.hero-copy {
  max-width: 720px;
  position: relative;
  z-index: 2;
}

.hero-label,
.section-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 18px;
  padding: 8px 14px;
  border: 1px solid rgba(250, 204, 21, 0.32);
  border-radius: 999px;
  background: rgba(250, 204, 21, 0.12);
  color: #fde68a;
  font-size: 14px;
  font-weight: 800;
}

.hero-copy h1,
.hero-copy h2 {
  margin: 0;
  font-size: clamp(42px, 7vw, 82px);
  line-height: 0.95;
  letter-spacing: -0.06em;
}

.hero-copy p {
  max-width: 650px;
  margin: 22px 0 0;
  color: rgba(255, 255, 255, 0.84);
  font-size: clamp(16px, 2vw, 20px);
  line-height: 1.78;
}

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

.primary-button,
.secondary-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 22px;
  border-radius: 999px;
  transition: transform 0.2s ease, filter 0.2s ease;
}

.secondary-button {
  color: white;
  background: rgba(255, 255, 255, 0.1);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.18);
}

.primary-button:hover,
.secondary-button:hover {
  transform: translateY(-2px);
  filter: brightness(1.08);
}

.hero-poster {
  position: relative;
  z-index: 2;
  justify-self: center;
  width: min(320px, 100%);
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.06);
  box-shadow: 0 30px 60px rgba(0, 0, 0, 0.45);
}

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

.hero-poster figcaption {
  padding: 18px;
  background: rgba(4, 6, 15, 0.78);
}

.hero-poster strong {
  display: block;
  font-size: 20px;
}

.hero-poster span {
  display: block;
  margin-top: 6px;
  color: var(--muted);
}

.hero-dots {
  position: absolute;
  left: clamp(28px, 5vw, 72px);
  bottom: 26px;
  z-index: 4;
  display: flex;
  gap: 10px;
}

.hero-dots button {
  width: 36px;
  height: 6px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.28);
  cursor: pointer;
}

.hero-dots button.is-active {
  background: linear-gradient(90deg, var(--yellow), var(--pink));
}

.section {
  padding: clamp(42px, 7vw, 82px) 0;
}

.section.alt {
  width: 100vw;
  margin-left: calc(50% - 50vw);
  padding-left: max(16px, calc((100vw - 1200px) / 2));
  padding-right: max(16px, calc((100vw - 1200px) / 2));
  background: linear-gradient(90deg, rgba(6, 78, 59, 0.22), rgba(22, 78, 99, 0.2));
}

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

.section-head h2,
.page-title h1,
.detail-title h1 {
  margin: 0;
  font-size: clamp(28px, 4vw, 44px);
  letter-spacing: -0.04em;
}

.section-head p,
.page-title p {
  max-width: 760px;
  margin: 10px 0 0;
  color: var(--muted);
  line-height: 1.8;
}

.section-link {
  color: var(--yellow);
  font-weight: 800;
  white-space: nowrap;
}

.category-strip {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 14px;
}

.category-chip,
.category-card {
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: linear-gradient(145deg, rgba(31, 41, 55, 0.74), rgba(17, 24, 39, 0.7));
  transition: transform 0.22s ease, border-color 0.22s ease, box-shadow 0.22s ease;
}

.category-chip {
  min-height: 82px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 22px;
  color: white;
  font-weight: 900;
}

.category-chip:hover,
.category-card:hover,
.movie-card:hover,
.mini-movie:hover {
  transform: translateY(-4px);
  border-color: rgba(250, 204, 21, 0.35);
  box-shadow: 0 20px 45px rgba(168, 85, 247, 0.16);
}

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

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

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

.poster-wrap {
  position: relative;
  margin: 0;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.05);
}

.poster-wrap img {
  width: 100%;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  transition: transform 0.38s ease;
}

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

.play-mark {
  position: absolute;
  right: 12px;
  bottom: 12px;
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: rgba(250, 204, 21, 0.95);
  color: #111827;
  font-size: 15px;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.28);
}

.rank-badge,
.mini-rank {
  display: inline-grid;
  place-items: center;
  font-weight: 900;
  color: #111827;
  background: linear-gradient(135deg, #fde047, #fb7185);
}

.rank-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  min-width: 34px;
  height: 34px;
  border-radius: 12px;
}

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

.movie-card h3 {
  min-height: 48px;
  margin: 0;
  font-size: 17px;
  line-height: 1.42;
}

.movie-card p {
  min-height: 58px;
  margin: 10px 0 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.6;
}

.meta-line,
.tag-line {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 12px;
}

.meta-line span,
.tag-line span,
.detail-tags span {
  padding: 5px 9px;
  border-radius: 999px;
  background: rgba(168, 85, 247, 0.18);
  color: #d8b4fe;
  font-size: 12px;
  font-weight: 800;
}

.tag-line span {
  background: rgba(37, 99, 235, 0.18);
  color: #93c5fd;
}

.feature-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 24px;
}

.mini-list {
  display: grid;
  gap: 12px;
}

.mini-movie {
  display: grid;
  grid-template-columns: 44px 66px minmax(0, 1fr);
  gap: 14px;
  align-items: center;
  min-height: 96px;
  padding: 12px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 20px;
  background: rgba(17, 24, 39, 0.66);
  transition: 0.22s ease;
}

.mini-movie img {
  width: 66px;
  height: 82px;
  border-radius: 14px;
  object-fit: cover;
}

.mini-rank {
  width: 34px;
  height: 34px;
  border-radius: 12px;
}

.mini-movie strong {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.mini-movie small {
  display: block;
  margin-top: 6px;
  color: var(--muted);
}

.page-title {
  padding: 54px 0 24px;
}

.filter-bar {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) 190px 190px;
  gap: 12px;
  margin: 24px 0 30px;
  padding: 14px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 22px;
  background: rgba(17, 24, 39, 0.7);
}

.filter-input,
.filter-select {
  width: 100%;
  min-height: 48px;
  padding: 0 14px;
  border-radius: 16px;
}

.category-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
  padding-bottom: 64px;
}

.category-card {
  display: block;
  min-height: 180px;
  padding: 26px;
  border-radius: 28px;
}

.category-card h2 {
  margin: 0;
  font-size: 24px;
}

.category-card p {
  color: var(--muted);
  line-height: 1.75;
}

.category-card span {
  color: var(--yellow);
  font-weight: 900;
}

.category-preview {
  display: flex;
  gap: 8px;
  margin: 18px 0;
}

.category-preview img {
  width: 56px;
  height: 76px;
  border-radius: 12px;
  object-fit: cover;
  background: rgba(255, 255, 255, 0.05);
}


.detail-layout {
  display: grid;
  grid-template-columns: 330px minmax(0, 1fr);
  gap: 34px;
  padding: 48px 0;
}

.detail-poster {
  margin: 0;
  overflow: hidden;
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.06);
  box-shadow: 0 24px 52px rgba(0, 0, 0, 0.34);
}

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

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

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

.detail-title p {
  color: var(--muted);
  line-height: 1.85;
  font-size: 17px;
}

.detail-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 18px;
}

.watch-section,
.content-panel,
.related-panel {
  margin-bottom: 40px;
  padding: clamp(18px, 3vw, 30px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 28px;
  background: rgba(17, 24, 39, 0.68);
}

.watch-section h2,
.content-panel h2,
.related-panel h2 {
  margin: 0 0 18px;
  font-size: 26px;
}

.player {
  position: relative;
  overflow: hidden;
  border-radius: 26px;
  background: black;
  aspect-ratio: 16 / 9;
}

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

.player-cover {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  border: 0;
  padding: 0;
  overflow: hidden;
  cursor: pointer;
  color: white;
  background: #000;
}

.player-cover img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.52;
  filter: blur(1px);
  transform: scale(1.02);
}

.player-cover span {
  position: relative;
  z-index: 2;
  display: inline-grid;
  place-items: center;
  width: 86px;
  height: 86px;
  border-radius: 50%;
  background: linear-gradient(135deg, #facc15, #fb7185);
  color: #111827;
  font-size: 18px;
  font-weight: 900;
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.35);
}

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

.content-panel p {
  color: #dbe4f0;
  line-height: 2;
  font-size: 17px;
}

.content-panel p:last-child {
  margin-bottom: 0;
}

.site-footer {
  margin-top: 80px;
  background: linear-gradient(180deg, rgba(17, 24, 39, 0.8), rgba(0, 0, 0, 0.96));
  color: var(--muted);
}

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

.site-footer h2 {
  margin: 0 0 14px;
  color: white;
  font-size: 20px;
}

.site-footer p {
  line-height: 1.75;
}

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

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

.copyright {
  width: min(1200px, calc(100% - 32px));
  margin: 0 auto;
  padding: 0 0 28px;
  color: rgba(255, 255, 255, 0.48);
}

[data-movie-card].is-hidden {
  display: none;
}

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

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

  .hero-slide,
  .detail-layout,
  .feature-grid {
    grid-template-columns: 1fr;
  }

  .hero-poster {
    display: none;
  }

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

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

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

  .brand {
    font-size: 20px;
  }

  .hero-carousel {
    min-height: 620px;
    border-radius: 24px;
  }

  .hero-slide {
    padding: 28px;
  }

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

  .section-head,
  .hero-actions {
    align-items: flex-start;
    flex-direction: column;
  }

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

  .category-strip,
  .category-grid,
  .filter-bar,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .detail-layout {
    padding: 30px 0;
  }

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

  .mini-movie {
    grid-template-columns: 38px 58px minmax(0, 1fr);
  }

  .mini-movie img {
    width: 58px;
    height: 74px;
  }
}
