* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: #ffffff;
  background:
    radial-gradient(circle at 15% 5%, rgba(34, 211, 238, 0.18), transparent 30rem),
    radial-gradient(circle at 85% 12%, rgba(124, 58, 237, 0.18), transparent 28rem),
    linear-gradient(180deg, #020617 0%, #0f172a 46%, #020617 100%);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
}

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

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

button,
input,
select {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 60;
  border-bottom: 1px solid rgba(148, 163, 184, 0.14);
  background: rgba(2, 6, 23, 0.84);
  backdrop-filter: blur(20px);
}

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

.brand,
.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 900;
  letter-spacing: 0.06em;
}

.brand-mark {
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  color: #08111f;
  background: linear-gradient(135deg, #22d3ee, #a78bfa 55%, #f472b6);
  box-shadow: 0 16px 36px rgba(34, 211, 238, 0.25);
}

.brand-text {
  font-size: 22px;
}

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

.nav-link,
.mobile-nav-link {
  padding: 10px 14px;
  border-radius: 999px;
  color: #cbd5e1;
  transition: color 0.22s ease, background 0.22s ease, transform 0.22s ease;
}

.nav-link:hover,
.nav-link.is-active,
.mobile-nav-link:hover,
.mobile-nav-link.is-active {
  color: #ffffff;
  background: rgba(34, 211, 238, 0.12);
}

.nav-search {
  position: relative;
  display: flex;
  align-items: center;
  width: 310px;
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.84);
  overflow: visible;
}

.nav-search input {
  width: 100%;
  min-width: 0;
  padding: 11px 14px;
  color: #ffffff;
  border: 0;
  outline: 0;
  background: transparent;
}

.nav-search button,
.hero-search button {
  margin-right: 4px;
  padding: 8px 14px;
  border: 0;
  border-radius: 999px;
  color: #06121f;
  background: linear-gradient(135deg, #22d3ee, #67e8f9);
  cursor: pointer;
}

.quick-results {
  position: absolute;
  top: calc(100% + 12px);
  right: 0;
  width: min(420px, 90vw);
  display: none;
  padding: 10px;
  border: 1px solid rgba(148, 163, 184, 0.18);
  border-radius: 20px;
  background: rgba(15, 23, 42, 0.96);
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.45);
}

.quick-results.is-open {
  display: grid;
  gap: 8px;
}

.quick-results a {
  display: grid;
  grid-template-columns: 44px 1fr;
  gap: 10px;
  align-items: center;
  padding: 8px;
  border-radius: 14px;
  color: #e2e8f0;
}

.quick-results a:hover {
  background: rgba(148, 163, 184, 0.12);
}

.quick-results img {
  width: 44px;
  height: 58px;
  object-fit: cover;
  border-radius: 10px;
}

.quick-results span {
  display: block;
  color: #94a3b8;
  font-size: 12px;
  margin-top: 2px;
}

.menu-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 1px solid rgba(148, 163, 184, 0.24);
  border-radius: 14px;
  background: rgba(15, 23, 42, 0.8);
}

.menu-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  margin: 4px auto;
  background: #e2e8f0;
}

.mobile-panel {
  display: none;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto 16px;
  padding: 14px;
  border: 1px solid rgba(148, 163, 184, 0.18);
  border-radius: 22px;
  background: rgba(15, 23, 42, 0.96);
}

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

.mobile-brand {
  margin-bottom: 10px;
  color: #22d3ee;
  font-weight: 800;
}

.mobile-panel nav {
  display: grid;
  gap: 8px;
}

.hero-section {
  position: relative;
  width: min(1180px, calc(100% - 32px));
  margin: 28px auto 0;
}

.hero-stage {
  position: relative;
  min-height: 620px;
  border: 1px solid rgba(148, 163, 184, 0.18);
  border-radius: 34px;
  overflow: hidden;
  box-shadow: 0 28px 100px rgba(0, 0, 0, 0.42);
  background: #020617;
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  pointer-events: none;
  transform: scale(1.02);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

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

.hero-backdrop,
.detail-hero-bg {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(90deg, rgba(2, 6, 23, 0.96) 0%, rgba(2, 6, 23, 0.72) 45%, rgba(2, 6, 23, 0.35) 100%),
    var(--hero-image);
  background-size: cover;
  background-position: center;
  filter: saturate(1.15);
}

.hero-backdrop::after,
.detail-hero-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 20% 30%, rgba(34, 211, 238, 0.22), transparent 22rem),
    linear-gradient(0deg, #020617 0%, transparent 48%);
}

.hero-content {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 330px;
  gap: 48px;
  align-items: center;
  min-height: 620px;
  padding: 70px;
}

.eyebrow,
.section-kicker {
  display: inline-flex;
  align-items: center;
  width: max-content;
  gap: 6px;
  margin-bottom: 12px;
  padding: 7px 12px;
  border: 1px solid rgba(34, 211, 238, 0.28);
  border-radius: 999px;
  color: #67e8f9;
  background: rgba(8, 145, 178, 0.11);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.04em;
}

.hero-copy h1,
.page-hero h1,
.detail-copy h1 {
  margin: 0;
  max-width: 820px;
  font-size: clamp(42px, 7vw, 80px);
  line-height: 0.98;
  letter-spacing: -0.05em;
}

.hero-copy p,
.page-hero p,
.detail-one-line {
  max-width: 720px;
  margin: 22px 0 0;
  color: #cbd5e1;
  font-size: 18px;
  line-height: 1.85;
}

.hero-tags,
.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 22px;
}

.hero-tags span,
.tag-row span,
.detail-meta span,
.card-meta span {
  display: inline-flex;
  align-items: center;
  padding: 6px 10px;
  border-radius: 999px;
  color: #cbd5e1;
  background: rgba(148, 163, 184, 0.14);
  font-size: 12px;
}

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

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

.primary-btn {
  color: #04111d;
  background: linear-gradient(135deg, #22d3ee, #a5f3fc);
  box-shadow: 0 18px 36px rgba(34, 211, 238, 0.24);
}

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

.primary-btn:hover,
.ghost-btn:hover,
.movie-card:hover,
.category-card:hover,
.category-overview-card:hover {
  transform: translateY(-4px);
}

.hero-poster {
  position: relative;
  display: block;
  border-radius: 30px;
  overflow: hidden;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.5);
}

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

.hero-control {
  position: absolute;
  z-index: 4;
  top: 50%;
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.24);
  border-radius: 999px;
  color: #ffffff;
  background: rgba(2, 6, 23, 0.64);
  cursor: pointer;
}

.hero-prev {
  left: 18px;
}

.hero-next {
  right: 18px;
}

.hero-thumbs {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 12px;
  margin-top: 14px;
}

.hero-thumb {
  display: grid;
  grid-template-columns: 52px 1fr;
  gap: 10px;
  align-items: center;
  min-width: 0;
  padding: 8px;
  border: 1px solid rgba(148, 163, 184, 0.18);
  border-radius: 18px;
  color: #cbd5e1;
  background: rgba(15, 23, 42, 0.62);
  cursor: pointer;
}

.hero-thumb.is-active {
  color: #ffffff;
  border-color: rgba(34, 211, 238, 0.58);
  background: rgba(8, 145, 178, 0.22);
}

.hero-thumb img {
  width: 52px;
  height: 64px;
  object-fit: cover;
  border-radius: 12px;
}

.hero-thumb span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  text-align: left;
}

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

.section-shell {
  padding: 58px 0;
}

.intro-strip {
  display: grid;
  grid-template-columns: 1fr minmax(280px, 420px);
  gap: 28px;
  align-items: center;
}

.intro-strip h2,
.section-head h2,
.filter-panel h2,
.text-panel h2 {
  margin: 0;
  font-size: clamp(26px, 4vw, 42px);
  letter-spacing: -0.035em;
}

.intro-strip p,
.text-panel p,
.category-overview-card p {
  color: #cbd5e1;
  line-height: 1.85;
}

.hero-search {
  display: flex;
  gap: 8px;
  padding: 8px;
  border: 1px solid rgba(148, 163, 184, 0.2);
  border-radius: 22px;
  background: rgba(15, 23, 42, 0.72);
}

.hero-search input {
  flex: 1;
  min-width: 0;
  padding: 0 12px;
  color: #ffffff;
  border: 0;
  outline: 0;
  background: transparent;
}

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

.section-head a {
  color: #67e8f9;
  font-weight: 800;
}

.compact-head h2 {
  font-size: 30px;
}

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

.featured-grid .movie-card:first-child {
  grid-column: span 2;
  grid-row: span 2;
}

.movie-card {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 24px;
  background: rgba(15, 23, 42, 0.72);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.22);
  transition: transform 0.24s ease, border-color 0.24s ease, box-shadow 0.24s ease;
}

.movie-card:hover {
  border-color: rgba(34, 211, 238, 0.48);
  box-shadow: 0 26px 72px rgba(34, 211, 238, 0.12);
}

.poster-link {
  position: relative;
  display: block;
  overflow: hidden;
}

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

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

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

.rank-number {
  position: absolute;
  z-index: 3;
  top: 12px;
  left: 12px;
  min-width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  color: #06121f;
  background: linear-gradient(135deg, #fde68a, #f97316);
  font-weight: 900;
}

.card-body {
  padding: 16px;
}

.card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 10px;
}

.movie-card h3 {
  margin: 0;
  font-size: 19px;
  line-height: 1.35;
}

.movie-card p {
  margin: 10px 0 0;
  min-height: 48px;
  color: #94a3b8;
  font-size: 14px;
  line-height: 1.7;
}

.movie-card-compact h3 {
  font-size: 17px;
}

.movie-card-compact p {
  min-height: 42px;
}

.movie-row {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(220px, 1fr);
  gap: 16px;
  overflow-x: auto;
  padding-bottom: 8px;
  scroll-snap-type: x mandatory;
}

.movie-row .movie-card {
  scroll-snap-align: start;
}

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

.category-card,
.category-overview-card,
.filter-panel,
.text-panel,
.player-card,
.ranking-panel {
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 26px;
  background:
    linear-gradient(135deg, rgba(15, 23, 42, 0.92), rgba(30, 41, 59, 0.62)),
    radial-gradient(circle at top right, rgba(34, 211, 238, 0.18), transparent 16rem);
  box-shadow: 0 22px 70px rgba(0, 0, 0, 0.22);
}

.category-card {
  display: grid;
  gap: 14px;
  min-height: 190px;
  padding: 24px;
  transition: transform 0.24s ease, border-color 0.24s ease;
}

.category-card:hover {
  border-color: rgba(34, 211, 238, 0.45);
}

.category-kicker {
  color: #67e8f9;
  font-weight: 900;
}

.category-card strong {
  color: #f8fafc;
  line-height: 1.7;
}

.category-preview {
  display: grid;
  gap: 6px;
  color: #cbd5e1;
  font-size: 14px;
}

.category-preview a:hover {
  color: #67e8f9;
}

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

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

.ranking-list,
.ranking-wall {
  display: grid;
  gap: 10px;
}

.ranking-item {
  display: grid;
  grid-template-columns: 42px 54px 1fr;
  gap: 12px;
  align-items: center;
  padding: 10px;
  border-radius: 18px;
  color: #e2e8f0;
  background: rgba(2, 6, 23, 0.34);
  transition: background 0.22s ease, transform 0.22s ease;
}

.ranking-item:hover {
  transform: translateX(4px);
  background: rgba(34, 211, 238, 0.12);
}

.ranking-index {
  color: #67e8f9;
  font-size: 20px;
  font-weight: 900;
  text-align: center;
}

.ranking-item img {
  width: 54px;
  height: 72px;
  object-fit: cover;
  border-radius: 12px;
}

.ranking-title {
  font-weight: 800;
}

.ranking-info {
  display: block;
  margin-top: 3px;
  color: #94a3b8;
  font-size: 12px;
}

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

.page-hero,
.detail-hero {
  position: relative;
  overflow: hidden;
  margin-top: 0;
}

.page-hero {
  width: min(1180px, calc(100% - 32px));
  margin: 28px auto 0;
  padding: 76px;
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 34px;
  background:
    radial-gradient(circle at 82% 10%, rgba(124, 58, 237, 0.32), transparent 28rem),
    radial-gradient(circle at 18% 24%, rgba(34, 211, 238, 0.28), transparent 25rem),
    linear-gradient(135deg, rgba(15, 23, 42, 0.96), rgba(2, 6, 23, 0.88));
}

.slim-hero {
  min-height: 320px;
  display: flex;
  align-items: center;
}

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

.category-overview-card {
  padding: 22px;
  transition: transform 0.24s ease, border-color 0.24s ease;
}

.category-overview-card:hover {
  border-color: rgba(34, 211, 238, 0.42);
}

.category-overview-top {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 12px;
}

.category-overview-top span {
  color: #ffffff;
  font-size: 22px;
  font-weight: 900;
}

.category-overview-top a {
  color: #67e8f9;
  font-weight: 800;
}

.category-overview-card ul {
  display: grid;
  gap: 10px;
  margin: 18px 0 0;
  padding: 0;
  list-style: none;
}

.category-overview-card li a {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  color: #e2e8f0;
}

.category-overview-card li span {
  color: #94a3b8;
  font-size: 12px;
  white-space: nowrap;
}

.filter-panel {
  padding: 24px;
  margin-bottom: 26px;
}

.filter-grid {
  display: grid;
  grid-template-columns: 2fr repeat(3, 1fr);
  gap: 14px;
}

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

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

.filter-grid select option {
  color: #0f172a;
}

.empty-hint {
  display: none;
  margin: 18px 0 0;
  color: #fda4af;
}

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

.detail-hero {
  min-height: 620px;
}

.detail-hero-bg {
  background-image:
    linear-gradient(90deg, rgba(2, 6, 23, 0.98) 0%, rgba(2, 6, 23, 0.72) 54%, rgba(2, 6, 23, 0.38) 100%),
    var(--detail-bg);
  background-size: cover;
  background-position: center;
}

.detail-shell {
  position: relative;
  z-index: 2;
  padding: 38px 0 70px;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-bottom: 36px;
  color: #94a3b8;
}

.breadcrumb a:hover {
  color: #67e8f9;
}

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

.detail-poster {
  display: block;
  overflow: hidden;
  border-radius: 30px;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.52);
}

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

.detail-copy h1 {
  font-size: clamp(40px, 6vw, 70px);
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin-top: 20px;
}

.detail-main {
  margin-top: -90px;
  position: relative;
  z-index: 5;
}

.player-card {
  padding: 12px;
}

.video-wrap {
  position: relative;
  overflow: hidden;
  border-radius: 22px;
  background: #000000;
}

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

.player-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  border: 0;
  color: #ffffff;
  background: radial-gradient(circle at center, rgba(2, 6, 23, 0.28), rgba(2, 6, 23, 0.72));
  cursor: pointer;
}

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

.play-core {
  width: 86px;
  height: 86px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  color: #06121f;
  background: linear-gradient(135deg, #22d3ee, #a5f3fc);
  box-shadow: 0 18px 54px rgba(34, 211, 238, 0.32);
  font-weight: 900;
}

.detail-text-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-top: 24px;
}

.text-panel {
  padding: 26px;
}

.text-panel h2 {
  margin-bottom: 16px;
  font-size: 28px;
}

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

.search-shell {
  padding-top: 36px;
}

.site-footer {
  margin-top: 30px;
  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: 34px 0;
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: 24px;
  color: #94a3b8;
}

.footer-brand {
  color: #ffffff;
  font-size: 24px;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 12px 18px;
}

.footer-links a:hover {
  color: #67e8f9;
}

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

  .menu-toggle {
    display: block;
    margin-left: auto;
  }

  .hero-content,
  .detail-layout,
  .intro-strip,
  .split-layout,
  .detail-text-grid,
  .footer-shell {
    grid-template-columns: 1fr;
  }

  .hero-content {
    padding: 46px;
  }

  .hero-poster,
  .detail-poster {
    max-width: 320px;
  }

  .hero-thumbs {
    grid-template-columns: repeat(2, 1fr);
  }

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

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

  .ranking-panel {
    position: relative;
    top: auto;
  }

  .footer-links {
    justify-content: flex-start;
  }
}

@media (max-width: 640px) {
  .header-shell,
  .section-shell,
  .detail-shell,
  .footer-shell,
  .hero-section,
  .page-hero {
    width: min(100% - 22px, 1180px);
  }

  .hero-stage,
  .hero-content {
    min-height: 560px;
  }

  .hero-content,
  .page-hero {
    padding: 30px;
  }

  .hero-copy h1,
  .page-hero h1,
  .detail-copy h1 {
    font-size: 38px;
  }

  .hero-copy p,
  .page-hero p,
  .detail-one-line {
    font-size: 16px;
  }

  .hero-thumbs,
  .featured-grid,
  .movie-grid,
  .category-grid,
  .category-overview-grid,
  .ranking-wall,
  .related-grid,
  .filter-grid {
    grid-template-columns: 1fr;
  }

  .featured-grid .movie-card:first-child {
    grid-column: auto;
    grid-row: auto;
  }

  .hero-control {
    top: auto;
    bottom: 16px;
  }

  .detail-layout {
    gap: 26px;
  }

  .detail-main {
    margin-top: -48px;
  }

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

  .ranking-item {
    grid-template-columns: 36px 50px 1fr;
  }
}
