:root {
  color-scheme: dark;
  --site-dark: #0a0e1a;
  --site-panel: rgba(15, 23, 42, 0.72);
  --site-panel-strong: rgba(15, 23, 42, 0.92);
  --site-border: rgba(56, 189, 248, 0.22);
  --site-primary: #38bdf8;
  --site-primary-strong: #0284c7;
  --site-text: #ffffff;
  --site-muted: #94a3b8;
  --site-soft: #cbd5e1;
  --site-radius: 1.25rem;
  --site-shadow: 0 24px 70px rgba(2, 8, 23, 0.46);
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at top left, rgba(56, 189, 248, 0.14), transparent 34rem),
    radial-gradient(circle at bottom right, rgba(14, 165, 233, 0.1), transparent 30rem),
    var(--site-dark);
  color: var(--site-text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
}

body::selection {
  background: rgba(56, 189, 248, 0.35);
}

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

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

.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 50;
  border-bottom: 1px solid rgba(56, 189, 248, 0.18);
  background: rgba(10, 14, 26, 0.92);
  backdrop-filter: blur(18px);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;
  height: 5rem;
}

.site-logo {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  min-width: max-content;
}

.logo-mark {
  display: grid;
  place-items: center;
  width: 2.45rem;
  height: 2.45rem;
  border-radius: 999px;
  color: #ffffff;
  background: linear-gradient(135deg, #0ea5e9, #0284c7);
  box-shadow: 0 0 30px rgba(56, 189, 248, 0.42);
}

.logo-copy {
  display: grid;
  gap: 0.1rem;
}

.logo-name {
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: 0.05em;
}

.logo-subtitle {
  font-size: 0.72rem;
  color: var(--site-muted);
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 1.35rem;
}

.nav-link,
.mobile-nav-link {
  color: var(--site-soft);
  font-weight: 600;
  transition: color 0.2s ease, background 0.2s ease;
}

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

.header-search,
.mobile-search,
.search-page-form {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.header-search input,
.mobile-search input,
.search-page-form input,
.filter-panel input,
.filter-panel select {
  width: 100%;
  border: 1px solid var(--site-border);
  border-radius: 999px;
  outline: none;
  background: rgba(15, 23, 42, 0.72);
  color: #ffffff;
  padding: 0.68rem 1rem;
  transition: border 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.header-search input {
  width: min(18vw, 16rem);
}

.header-search input:focus,
.mobile-search input:focus,
.search-page-form input:focus,
.filter-panel input:focus,
.filter-panel select:focus {
  border-color: var(--site-primary);
  box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.12);
}

.header-search button,
.mobile-search button,
.search-page-form button,
.filter-panel button,
.primary-action,
.ghost-action,
.section-more,
.ranking-action {
  border: 0;
  border-radius: 999px;
  padding: 0.7rem 1.05rem;
  color: #ffffff;
  background: var(--site-primary-strong);
  font-weight: 700;
  cursor: pointer;
  transition: transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}

.header-search button:hover,
.mobile-search button:hover,
.search-page-form button:hover,
.filter-panel button:hover,
.primary-action:hover,
.section-more:hover,
.ranking-action:hover {
  transform: translateY(-1px);
  background: #0369a1;
  box-shadow: 0 0 22px rgba(56, 189, 248, 0.28);
}

.ghost-action {
  background: rgba(15, 23, 42, 0.78);
  border: 1px solid var(--site-border);
}

.menu-toggle {
  display: none;
  width: 2.6rem;
  height: 2.6rem;
  border: 1px solid var(--site-border);
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.72);
  cursor: pointer;
}

.menu-toggle span {
  display: block;
  width: 1.1rem;
  height: 2px;
  margin: 4px auto;
  background: #ffffff;
  border-radius: 999px;
}

.mobile-panel {
  display: none;
  padding: 0 0 1rem;
}

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

.mobile-nav {
  display: grid;
  gap: 0.45rem;
  margin-top: 0.9rem;
}

.mobile-nav-link {
  display: block;
  border-radius: 0.9rem;
  padding: 0.75rem 0.9rem;
  background: rgba(15, 23, 42, 0.4);
}

.hero-slider {
  position: relative;
  height: 80vh;
  min-height: 36rem;
  overflow: hidden;
}

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

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

.hero-slide img,
.detail-bg {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-shade,
.detail-bg-shade {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(to top, #0a0e1a 5%, rgba(10, 14, 26, 0.72) 46%, rgba(10, 14, 26, 0.25)),
    linear-gradient(to right, rgba(10, 14, 26, 0.9), rgba(10, 14, 26, 0.08));
}

.hero-content {
  position: absolute;
  inset: auto 0 6rem 0;
  z-index: 2;
}

.hero-copy {
  width: min(48rem, 92vw);
}

.hero-kicker,
.section-kicker {
  display: inline-flex;
  align-items: center;
  width: max-content;
  border: 1px solid rgba(56, 189, 248, 0.28);
  border-radius: 999px;
  margin-bottom: 0.9rem;
  padding: 0.45rem 0.85rem;
  color: #bae6fd;
  background: rgba(2, 132, 199, 0.18);
  font-size: 0.85rem;
  font-weight: 700;
}

.hero-copy h1,
.hero-copy h2,
.page-hero h1,
.detail-copy h1 {
  margin: 0;
  color: #ffffff;
  font-size: clamp(2.5rem, 6vw, 5.5rem);
  line-height: 1.05;
  letter-spacing: -0.04em;
  text-shadow: 0 20px 60px rgba(2, 8, 23, 0.58);
}

.hero-copy p,
.page-hero p,
.detail-one-line {
  max-width: 46rem;
  margin: 1rem 0 0;
  color: var(--site-soft);
  font-size: clamp(1rem, 2vw, 1.22rem);
  line-height: 1.8;
}

.hero-tags,
.detail-meta,
.card-meta,
.tag-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
}

.hero-tags {
  margin: 1.35rem 0 1.6rem;
}

.hero-tags span,
.detail-meta span,
.card-meta span,
.tag-cloud span {
  border: 1px solid rgba(148, 163, 184, 0.24);
  border-radius: 999px;
  padding: 0.4rem 0.7rem;
  color: var(--site-soft);
  background: rgba(15, 23, 42, 0.56);
  font-size: 0.83rem;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
}

.primary-action,
.ghost-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.86rem 1.35rem;
}

.hero-control {
  position: absolute;
  top: 50%;
  z-index: 4;
  display: grid;
  place-items: center;
  width: 3rem;
  height: 3rem;
  border: 1px solid var(--site-border);
  border-radius: 999px;
  color: #ffffff;
  background: rgba(10, 14, 26, 0.54);
  backdrop-filter: blur(10px);
  cursor: pointer;
  transform: translateY(-50%);
}

.hero-prev {
  left: 1rem;
}

.hero-next {
  right: 1rem;
}

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

.hero-dot {
  width: 0.56rem;
  height: 0.56rem;
  border: 0;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.8);
  cursor: pointer;
  transition: width 0.2s ease, background 0.2s ease;
}

.hero-dot.is-active {
  width: 2.3rem;
  background: var(--site-primary);
}

.content-section {
  padding-top: 4.2rem;
  padding-bottom: 1rem;
}

.section-heading,
.category-block-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.45rem;
}

.section-heading h2,
.category-block-head h2,
.detail-article h2,
.detail-side-card h2 {
  margin: 0;
  color: #ffffff;
  font-size: clamp(1.6rem, 3vw, 2.25rem);
  line-height: 1.15;
}

.section-heading p,
.category-block-head p {
  max-width: 42rem;
  margin: 0.55rem 0 0;
  color: var(--site-muted);
  line-height: 1.75;
}

.section-more {
  flex: none;
  padding: 0.72rem 1rem;
  background: rgba(15, 23, 42, 0.72);
  border: 1px solid var(--site-border);
}

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

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

.featured-list {
  display: grid;
  gap: 1.25rem;
}

.movie-card {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(56, 189, 248, 0.18);
  border-radius: var(--site-radius);
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.82), rgba(15, 23, 42, 0.46));
  box-shadow: 0 16px 46px rgba(2, 8, 23, 0.24);
  transition: transform 0.22s ease, border 0.22s ease, box-shadow 0.22s ease;
}

.movie-card:hover {
  transform: translateY(-0.28rem);
  border-color: rgba(56, 189, 248, 0.46);
  box-shadow: var(--site-shadow);
}

.featured-card {
  display: grid;
  grid-template-columns: minmax(16rem, 34%) 1fr;
}

.card-poster {
  position: relative;
  display: block;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  background: #020617;
}

.featured-card .card-poster {
  aspect-ratio: 16 / 10;
  height: 100%;
}

.card-poster img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.45s ease, opacity 0.45s ease;
}

.movie-card:hover .card-poster img,
.category-tile:hover img,
.ranking-thumb:hover img {
  transform: scale(1.08);
  opacity: 0.9;
}

.type-badge,
.rank-badge {
  position: absolute;
  top: 0.8rem;
  z-index: 2;
  border-radius: 999px;
  color: #ffffff;
  font-size: 0.78rem;
  font-weight: 800;
}

.type-badge {
  right: 0.8rem;
  padding: 0.35rem 0.65rem;
  background: rgba(2, 132, 199, 0.9);
}

.rank-badge {
  left: 0.8rem;
  display: grid;
  place-items: center;
  width: 2.2rem;
  height: 2.2rem;
  background: rgba(2, 8, 23, 0.82);
  border: 1px solid rgba(56, 189, 248, 0.32);
}

.play-badge {
  position: absolute;
  inset: 50% auto auto 50%;
  display: grid;
  place-items: center;
  width: 3rem;
  height: 3rem;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(2, 132, 199, 0.88);
  opacity: 0;
  transform: translate(-50%, -50%) scale(0.88);
  transition: opacity 0.22s ease, transform 0.22s ease;
}

.movie-card:hover .play-badge {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
}

.card-body {
  display: grid;
  align-content: start;
  gap: 0.7rem;
  padding: 1rem;
}

.featured-card .card-body {
  padding: 1.35rem;
}

.card-body h2 {
  margin: 0;
  color: #ffffff;
  font-size: 1.1rem;
  line-height: 1.35;
}

.card-body h2 a:hover,
.ranking-info h2 a:hover {
  color: var(--site-primary);
}

.card-body p {
  display: -webkit-box;
  min-height: 3.2rem;
  margin: 0;
  overflow: hidden;
  color: var(--site-muted);
  font-size: 0.92rem;
  line-height: 1.7;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.featured-card .card-body p {
  -webkit-line-clamp: 3;
}

.card-meta span {
  padding: 0.3rem 0.55rem;
  font-size: 0.76rem;
}

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

.category-tile {
  position: relative;
  min-height: 14rem;
  overflow: hidden;
  border: 1px solid rgba(56, 189, 248, 0.2);
  border-radius: var(--site-radius);
  background: rgba(15, 23, 42, 0.72);
  box-shadow: 0 16px 42px rgba(2, 8, 23, 0.22);
}

.category-tile::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(2, 8, 23, 0.95), rgba(2, 8, 23, 0.18));
}

.category-tile img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.42s ease;
}

.category-tile span,
.category-tile p {
  position: absolute;
  left: 1rem;
  right: 1rem;
  z-index: 2;
}

.category-tile span {
  bottom: 3.7rem;
  color: #ffffff;
  font-size: 1.15rem;
  font-weight: 800;
}

.category-tile p {
  bottom: 0.95rem;
  margin: 0;
  color: var(--site-soft);
  font-size: 0.88rem;
  line-height: 1.55;
}

.ranking-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
}

.inner-page {
  min-height: 70vh;
  padding-top: 5rem;
}

.page-hero,
.detail-hero {
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, rgba(2, 132, 199, 0.16), rgba(15, 23, 42, 0.5));
}

.small-hero {
  padding: 6rem 0 4rem;
}

.page-hero h1 {
  font-size: clamp(2.4rem, 6vw, 4.5rem);
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  margin-bottom: 1.1rem;
  color: var(--site-muted);
  font-size: 0.92rem;
}

.breadcrumb a:hover {
  color: var(--site-primary);
}

.filter-panel {
  display: grid;
  grid-template-columns: minmax(16rem, 1fr) minmax(9rem, 14rem) minmax(9rem, 14rem) auto;
  gap: 0.8rem;
  align-items: end;
  border: 1px solid rgba(56, 189, 248, 0.18);
  border-radius: var(--site-radius);
  margin-bottom: 1.3rem;
  padding: 1rem;
  background: rgba(15, 23, 42, 0.54);
}

.filter-panel label {
  display: grid;
  gap: 0.4rem;
  color: var(--site-muted);
  font-size: 0.85rem;
}

.empty-state,
.search-status {
  margin-top: 1.5rem;
  border: 1px solid rgba(56, 189, 248, 0.18);
  border-radius: var(--site-radius);
  padding: 1.5rem;
  color: var(--site-soft);
  background: rgba(15, 23, 42, 0.54);
  text-align: center;
}

.category-overview {
  display: grid;
  gap: 2rem;
}

.category-block {
  border: 1px solid rgba(56, 189, 248, 0.14);
  border-radius: calc(var(--site-radius) + 0.25rem);
  padding: 1.2rem;
  background: rgba(15, 23, 42, 0.36);
}

.ranking-page-list {
  display: grid;
  gap: 0.85rem;
}

.ranking-row {
  display: grid;
  grid-template-columns: 3.5rem 6rem 1fr auto;
  gap: 1rem;
  align-items: center;
  border: 1px solid rgba(56, 189, 248, 0.14);
  border-radius: var(--site-radius);
  padding: 0.8rem;
  background: rgba(15, 23, 42, 0.55);
}

.ranking-rank {
  display: grid;
  place-items: center;
  width: 3rem;
  height: 3rem;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(2, 132, 199, 0.8);
  font-weight: 900;
}

.ranking-thumb {
  display: block;
  overflow: hidden;
  border-radius: 0.85rem;
  aspect-ratio: 2 / 3;
  background: #020617;
}

.ranking-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.ranking-info h2 {
  margin: 0 0 0.35rem;
  font-size: 1.1rem;
}

.ranking-info p {
  margin: 0 0 0.55rem;
  color: var(--site-muted);
  line-height: 1.65;
}

.detail-hero {
  min-height: 44rem;
  padding-top: 7rem;
}

.detail-bg,
.detail-bg-shade {
  position: absolute;
  inset: 0;
}

.detail-bg {
  filter: blur(3px) saturate(1.05);
  transform: scale(1.04);
}

.detail-hero-inner {
  position: relative;
  z-index: 2;
}

.detail-layout {
  display: grid;
  grid-template-columns: minmax(14rem, 20rem) 1fr;
  gap: 2rem;
  align-items: end;
  padding-bottom: 4rem;
}

.detail-cover {
  overflow: hidden;
  border: 1px solid rgba(56, 189, 248, 0.26);
  border-radius: var(--site-radius);
  box-shadow: var(--site-shadow);
  aspect-ratio: 2 / 3;
  background: #020617;
}

.detail-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.detail-copy h1 {
  font-size: clamp(2.5rem, 6vw, 5.2rem);
}

.detail-meta {
  margin: 1.25rem 0;
}

.tag-cloud {
  margin-top: 1rem;
}

.player-shell {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(56, 189, 248, 0.24);
  border-radius: calc(var(--site-radius) + 0.25rem);
  background: #020617;
  box-shadow: var(--site-shadow);
  aspect-ratio: 16 / 9;
}

.movie-video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  cursor: pointer;
}

.player-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  border: 0;
  color: #ffffff;
  background: linear-gradient(180deg, rgba(2, 8, 23, 0.2), rgba(2, 8, 23, 0.72));
  font-size: 1.05rem;
  font-weight: 800;
  cursor: pointer;
}

.player-icon {
  display: grid;
  place-items: center;
  width: 5rem;
  height: 5rem;
  border-radius: 999px;
  background: rgba(2, 132, 199, 0.88);
  box-shadow: 0 0 40px rgba(56, 189, 248, 0.38);
  font-size: 2rem;
}

.detail-content-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(18rem, 25rem);
  gap: 1.25rem;
  align-items: start;
}

.detail-article,
.detail-side-card {
  border: 1px solid rgba(56, 189, 248, 0.15);
  border-radius: var(--site-radius);
  padding: 1.3rem;
  background: rgba(15, 23, 42, 0.54);
}

.detail-article p {
  margin: 0.8rem 0 1.5rem;
  color: var(--site-soft);
  font-size: 1rem;
  line-height: 1.9;
}

.detail-side-card dl {
  display: grid;
  grid-template-columns: 5rem 1fr;
  gap: 0.75rem 1rem;
  margin: 1rem 0 0;
}

.detail-side-card dt {
  color: var(--site-muted);
}

.detail-side-card dd {
  margin: 0;
  color: #ffffff;
}

.search-page-form {
  max-width: 48rem;
  margin-bottom: 1rem;
}

.search-page-form input {
  flex: 1;
  border-radius: 1rem;
  padding: 0.9rem 1rem;
}

.search-page-form button {
  border-radius: 1rem;
  padding: 0.9rem 1.3rem;
}

.site-footer {
  margin-top: 4rem;
  border-top: 1px solid rgba(56, 189, 248, 0.14);
  background: rgba(2, 8, 23, 0.42);
  padding: 2.5rem 0 1.5rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(16rem, 24rem);
  gap: 2rem;
}

.footer-logo {
  color: #ffffff;
  font-size: 1.35rem;
  font-weight: 900;
}

.site-footer p,
.footer-bottom {
  color: var(--site-muted);
  line-height: 1.8;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
}

.footer-links h2 {
  flex: 0 0 100%;
  margin: 0 0 0.3rem;
  font-size: 1rem;
}

.footer-links a {
  border: 1px solid rgba(56, 189, 248, 0.14);
  border-radius: 999px;
  padding: 0.45rem 0.75rem;
  color: var(--site-soft);
  background: rgba(15, 23, 42, 0.44);
}

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

.footer-bottom {
  border-top: 1px solid rgba(56, 189, 248, 0.1);
  margin-top: 1.7rem;
  padding-top: 1rem;
  font-size: 0.9rem;
}

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

  .menu-toggle {
    display: block;
  }

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

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

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

@media (max-width: 820px) {
  .hero-slider {
    height: 72vh;
    min-height: 34rem;
  }

  .hero-content {
    bottom: 5rem;
  }

  .hero-control {
    display: none;
  }

  .section-heading,
  .category-block-head {
    align-items: start;
    flex-direction: column;
  }

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

  .featured-card,
  .detail-layout,
  .detail-content-grid,
  .footer-grid {
    grid-template-columns: 1fr;
  }

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

  .ranking-row {
    grid-template-columns: 2.8rem 4.8rem 1fr;
  }

  .ranking-action {
    grid-column: 2 / -1;
    text-align: center;
  }

  .detail-hero {
    min-height: auto;
  }

  .detail-layout {
    padding-bottom: 3rem;
  }

  .detail-cover {
    width: min(62vw, 18rem);
  }
}

@media (max-width: 560px) {
  .header-inner {
    height: 4.35rem;
  }

  .logo-subtitle {
    display: none;
  }

  .inner-page {
    padding-top: 4.35rem;
  }

  .hero-slider {
    min-height: 31rem;
  }

  .hero-copy h1,
  .hero-copy h2,
  .page-hero h1,
  .detail-copy h1 {
    font-size: 2.25rem;
  }

  .hero-tags span,
  .detail-meta span,
  .card-meta span,
  .tag-cloud span {
    font-size: 0.75rem;
  }

  .movie-grid,
  .compact-grid,
  .category-grid {
    gap: 0.75rem;
  }

  .card-body {
    padding: 0.85rem;
  }

  .card-body p {
    min-height: auto;
  }

  .category-tile {
    min-height: 11rem;
  }

  .player-icon {
    width: 4rem;
    height: 4rem;
  }
}
