:root {
  color-scheme: dark;
  --bg: #020617;
  --bg-soft: #0f172a;
  --panel: #1e293b;
  --panel-2: #0f172a;
  --line: #1f2a3d;
  --text: #f8fafc;
  --muted: #94a3b8;
  --muted-2: #64748b;
  --accent: #0ea5e9;
  --accent-2: #38bdf8;
  --shadow: 0 24px 70px rgba(2, 6, 23, 0.45);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background: linear-gradient(180deg, #020617 0%, #0f172a 44%, #020617 100%);
  color: var(--text);
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

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

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

button,
input {
  font: inherit;
}

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

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

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

.site-logo,
.footer-logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.logo-mark {
  width: 34px;
  height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #fff;
  font-size: 14px;
  box-shadow: 0 12px 35px rgba(14, 165, 233, 0.28);
}

.logo-copy {
  display: flex;
  flex-direction: column;
  line-height: 1.1;
}

.logo-copy strong {
  font-size: 20px;
  letter-spacing: 0.02em;
}

.logo-copy small {
  color: var(--muted);
  font-size: 12px;
  margin-top: 4px;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 22px;
  color: #cbd5e1;
  font-size: 15px;
  white-space: nowrap;
}

.site-nav a:hover,
.footer-links a:hover {
  color: #fff;
}

.header-search {
  position: relative;
  display: flex;
  width: min(280px, 30vw);
  border: 1px solid #334155;
  border-radius: 999px;
  overflow: hidden;
  background: #0f172a;
}

.header-search input {
  min-width: 0;
  flex: 1;
  border: 0;
  outline: 0;
  padding: 10px 14px;
  background: transparent;
  color: #fff;
}

.header-search button,
.filter-search button {
  border: 0;
  padding: 0 15px;
  background: var(--accent);
  color: #fff;
  cursor: pointer;
}

.mobile-menu-button {
  display: none;
  width: 42px;
  height: 42px;
  border: 0;
  background: transparent;
  color: #fff;
  cursor: pointer;
}

.mobile-menu-button span {
  display: block;
  width: 24px;
  height: 2px;
  margin: 5px auto;
  background: #fff;
  transition: transform 0.25s ease, opacity 0.25s ease;
}

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

.mobile-menu.is-open {
  display: grid;
  gap: 12px;
}

.mobile-menu a {
  color: #cbd5e1;
}

.mobile-menu form {
  display: flex;
  border: 1px solid #334155;
  border-radius: 999px;
  overflow: hidden;
}

.mobile-menu input {
  min-width: 0;
  flex: 1;
  border: 0;
  outline: 0;
  padding: 10px 14px;
  background: #0f172a;
  color: #fff;
}

.mobile-menu button {
  border: 0;
  padding: 0 16px;
  background: var(--accent);
  color: #fff;
}

.hero {
  position: relative;
  height: 620px;
  overflow: hidden;
  background: #020617;
}

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

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

.hero-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.02);
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 70% 30%, rgba(14, 165, 233, 0.18), transparent 30%),
    linear-gradient(180deg, rgba(2, 6, 23, 0.15), rgba(2, 6, 23, 0.98)),
    linear-gradient(90deg, rgba(2, 6, 23, 0.88), rgba(2, 6, 23, 0.25));
}

.hero-content {
  position: absolute;
  left: 50%;
  bottom: 88px;
  transform: translateX(-50%);
  max-width: 1180px;
}

.hero-content h1,
.hero-content h2 {
  max-width: 760px;
  margin: 14px 0 14px;
  font-size: clamp(34px, 6vw, 70px);
  line-height: 1.04;
  letter-spacing: -0.04em;
}

.hero-content p {
  max-width: 700px;
  margin: 0 0 20px;
  color: #cbd5e1;
  font-size: 18px;
}

.hero-badge,
.section-kicker {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  border-radius: 999px;
  padding: 6px 12px;
  background: var(--accent);
  color: #fff;
  font-size: 13px;
  font-weight: 700;
}

.hero-meta,
.detail-meta,
.movie-card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  color: var(--muted);
}

.hero-meta span,
.detail-meta span,
.movie-card-meta span {
  border-radius: 999px;
  padding: 4px 10px;
  background: rgba(15, 23, 42, 0.72);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 26px;
}

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

.primary-button {
  background: #fff;
  color: #0f172a;
}

.ghost-button {
  border: 1px solid rgba(255, 255, 255, 0.24);
  background: rgba(15, 23, 42, 0.45);
  color: #fff;
}

.primary-button:hover,
.ghost-button:hover {
  transform: translateY(-2px);
  background: var(--accent-2);
  color: #fff;
}

.hero-control {
  position: absolute;
  top: 50%;
  z-index: 5;
  width: 52px;
  height: 52px;
  border: 0;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.36);
  color: #fff;
  font-size: 36px;
  cursor: pointer;
  backdrop-filter: blur(8px);
}

.hero-prev {
  left: 24px;
}

.hero-next {
  right: 24px;
}

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

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

.hero-dot.is-active {
  width: 32px;
  background: #fff;
}

.page-shell {
  padding-top: 42px;
}

.content-section {
  padding: 44px 0;
}

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

.section-heading h2 {
  margin: 10px 0 0;
  font-size: clamp(26px, 4vw, 38px);
  line-height: 1.15;
}

.section-heading p {
  margin: 8px 0 0;
  color: var(--muted);
}

.section-heading a {
  color: var(--accent-2);
  font-weight: 700;
}

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

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

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

.movie-card {
  min-width: 0;
}

.movie-card-link {
  display: block;
  height: 100%;
  overflow: hidden;
  border: 1px solid rgba(51, 65, 85, 0.7);
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(30, 41, 59, 0.95), rgba(15, 23, 42, 0.96));
  box-shadow: 0 18px 50px rgba(2, 6, 23, 0.22);
  transition: transform 0.28s ease, box-shadow 0.28s ease, border-color 0.28s ease;
}

.movie-card-link:hover {
  transform: translateY(-6px);
  border-color: rgba(14, 165, 233, 0.45);
  box-shadow: 0 24px 70px rgba(14, 165, 233, 0.16);
}

.movie-poster {
  position: relative;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  background: #0f172a;
}

.movie-grid-compact .movie-poster {
  aspect-ratio: 3 / 4;
}

.movie-grid-large .movie-poster {
  aspect-ratio: 16 / 10;
}

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

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

.movie-poster-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 35%, rgba(0, 0, 0, 0.85));
  opacity: 0.75;
}

.movie-play-mark {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 56px;
  height: 56px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.22);
  color: #fff;
  transform: translate(-50%, -50%) scale(0.86);
  opacity: 0;
  backdrop-filter: blur(8px);
  transition: transform 0.28s ease, opacity 0.28s ease;
}

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

.movie-category,
.rank-badge {
  position: absolute;
  top: 12px;
  border-radius: 999px;
  padding: 5px 10px;
  background: rgba(2, 6, 23, 0.72);
  color: #fff;
  font-size: 12px;
  font-weight: 800;
}

.movie-category {
  right: 12px;
}

.rank-badge {
  left: 12px;
  background: var(--accent);
}

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

.movie-card-body h2,
.movie-card-body h3 {
  margin: 0 0 9px;
  font-size: 17px;
  line-height: 1.35;
}

.movie-card-body p {
  display: -webkit-box;
  min-height: 44px;
  margin: 0 0 14px;
  overflow: hidden;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  color: var(--muted);
  font-size: 14px;
}

.movie-card-meta {
  gap: 6px;
  font-size: 12px;
}

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

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

.category-tile {
  position: relative;
  min-height: 170px;
  overflow: hidden;
  border: 1px solid rgba(51, 65, 85, 0.68);
  border-radius: 20px;
  padding: 22px;
  background: linear-gradient(135deg, #1e293b, #0f172a);
  box-shadow: var(--shadow);
}

.category-tile img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.22;
  transition: transform 0.45s ease, opacity 0.45s ease;
}

.category-tile span {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(14, 165, 233, 0.22), rgba(2, 6, 23, 0.88));
}

.category-tile strong,
.category-tile em {
  position: relative;
  display: block;
}

.category-tile strong {
  font-size: 24px;
}

.category-tile em {
  max-width: 18em;
  margin-top: 10px;
  color: #cbd5e1;
  font-style: normal;
}

.category-tile:hover img {
  opacity: 0.36;
  transform: scale(1.08);
}

.masonry-grid {
  columns: 3 280px;
  column-gap: 22px;
}

.masonry-grid .movie-card {
  break-inside: avoid;
  margin-bottom: 22px;
}

.page-hero {
  border: 1px solid rgba(51, 65, 85, 0.7);
  border-radius: 28px;
  padding: clamp(28px, 5vw, 56px);
  background:
    radial-gradient(circle at top right, rgba(14, 165, 233, 0.20), transparent 34%),
    linear-gradient(135deg, rgba(30, 41, 59, 0.92), rgba(2, 6, 23, 0.92));
  box-shadow: var(--shadow);
}

.small-hero h1 {
  margin: 14px 0 8px;
  font-size: clamp(34px, 6vw, 58px);
  line-height: 1.06;
}

.small-hero p {
  max-width: 760px;
  margin: 0;
  color: var(--muted);
  font-size: 18px;
}

.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 9px;
  margin-bottom: 22px;
  color: var(--muted);
  font-size: 14px;
}

.breadcrumbs a:hover {
  color: #fff;
}

.filter-panel {
  margin-top: 28px;
  border: 1px solid rgba(51, 65, 85, 0.7);
  border-radius: 22px;
  padding: 18px;
  background: rgba(15, 23, 42, 0.72);
}

.filter-search {
  display: flex;
  overflow: hidden;
  border: 1px solid #334155;
  border-radius: 999px;
  background: #020617;
}

.filter-search input {
  flex: 1;
  min-width: 0;
  border: 0;
  outline: 0;
  padding: 13px 18px;
  background: transparent;
  color: #fff;
}

.filter-search-wide {
  max-width: 780px;
}

.filter-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 14px;
}

.filter-tags button {
  border: 1px solid rgba(51, 65, 85, 0.86);
  border-radius: 999px;
  padding: 8px 12px;
  background: rgba(30, 41, 59, 0.68);
  color: #cbd5e1;
  cursor: pointer;
}

.filter-tags button:hover {
  border-color: var(--accent);
  color: #fff;
}

.empty-message {
  display: none;
  margin: 28px 0;
  color: var(--muted);
  text-align: center;
}

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

.ranking-list {
  padding: 42px 0;
}

.ranking-row {
  margin-bottom: 12px;
}

.ranking-link {
  display: grid;
  grid-template-columns: 58px 82px 1fr auto;
  gap: 18px;
  align-items: center;
  border: 1px solid rgba(51, 65, 85, 0.7);
  border-radius: 18px;
  padding: 12px 18px;
  background: rgba(15, 23, 42, 0.82);
  transition: transform 0.22s ease, border-color 0.22s ease, background 0.22s ease;
}

.ranking-link:hover {
  transform: translateY(-2px);
  border-color: rgba(14, 165, 233, 0.45);
  background: rgba(30, 41, 59, 0.9);
}

.ranking-number {
  font-size: 26px;
  font-weight: 900;
  color: var(--accent-2);
}

.ranking-link img {
  width: 82px;
  height: 58px;
  border-radius: 12px;
  object-fit: cover;
}

.ranking-copy strong,
.ranking-copy em {
  display: block;
}

.ranking-copy em {
  color: var(--muted);
  font-style: normal;
  font-size: 14px;
}

.ranking-meta {
  color: var(--muted);
  font-size: 14px;
  white-space: nowrap;
}

.detail-hero {
  padding-top: 18px;
}

.detail-layout {
  display: grid;
  grid-template-columns: minmax(220px, 330px) 1fr;
  gap: clamp(24px, 5vw, 52px);
  align-items: center;
}

.detail-cover {
  overflow: hidden;
  border: 1px solid rgba(51, 65, 85, 0.76);
  border-radius: 26px;
  background: #0f172a;
  box-shadow: var(--shadow);
}

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

.detail-copy h1 {
  margin: 14px 0 12px;
  font-size: clamp(34px, 6vw, 64px);
  line-height: 1.05;
}

.detail-one-line {
  max-width: 820px;
  color: #cbd5e1;
  font-size: 19px;
}

.detail-meta {
  margin: 22px 0;
}

.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin: 0 0 28px;
}

.tag-chip {
  border: 1px solid rgba(56, 189, 248, 0.28);
  border-radius: 999px;
  padding: 7px 11px;
  background: rgba(14, 165, 233, 0.10);
  color: #bae6fd;
  font-size: 13px;
}

.player-section {
  padding: 42px 0 22px;
}

.video-shell {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(51, 65, 85, 0.8);
  border-radius: 26px;
  background: #000;
  box-shadow: var(--shadow);
}

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

.player-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  border: 0;
  background: radial-gradient(circle, rgba(14, 165, 233, 0.20), rgba(0, 0, 0, 0.34));
  color: #fff;
  cursor: pointer;
}

.player-overlay span {
  width: 86px;
  height: 86px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.22);
  font-size: 34px;
  backdrop-filter: blur(10px);
  box-shadow: 0 22px 60px rgba(2, 6, 23, 0.45);
}

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

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

.story-card {
  border: 1px solid rgba(51, 65, 85, 0.7);
  border-radius: 22px;
  padding: clamp(22px, 4vw, 34px);
  background: rgba(15, 23, 42, 0.78);
}

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

.story-card p {
  margin: 0;
  color: #cbd5e1;
  white-space: pre-line;
}

.site-footer {
  margin-top: 48px;
  border-top: 1px solid rgba(51, 65, 85, 0.75);
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.82), #020617);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 34px;
  padding: 46px 0;
}

.footer-grid h2 {
  margin: 0 0 12px;
  font-size: 18px;
}

.footer-grid p {
  max-width: 520px;
  color: var(--muted);
}

.footer-links {
  display: grid;
  gap: 8px;
  color: var(--muted);
}

.footer-bottom {
  border-top: 1px solid rgba(51, 65, 85, 0.6);
  padding: 18px;
  color: var(--muted-2);
  text-align: center;
  font-size: 14px;
}

@media (max-width: 1180px) {
  .movie-grid,
  .category-grid,
  .category-grid-wide {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

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

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

  .mobile-menu-button {
    display: block;
  }

  .hero {
    height: 560px;
  }

  .hero-content {
    bottom: 70px;
  }

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

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

  .detail-cover {
    max-width: 330px;
  }

  .ranking-link {
    grid-template-columns: 42px 72px 1fr;
  }

  .ranking-meta {
    grid-column: 3;
  }
}

@media (max-width: 640px) {
  .container,
  .site-header-inner,
  .mobile-menu {
    width: min(100% - 22px, 1180px);
  }

  .logo-copy small {
    display: none;
  }

  .hero {
    height: 520px;
  }

  .hero-control {
    display: none;
  }

  .hero-content p {
    font-size: 16px;
  }

  .movie-grid,
  .movie-grid-compact,
  .movie-grid-large,
  .category-grid,
  .category-grid-wide,
  .detail-content,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .section-heading {
    display: block;
  }

  .section-heading a {
    display: inline-block;
    margin-top: 12px;
  }

  .filter-search {
    border-radius: 18px;
  }

  .ranking-link {
    grid-template-columns: 38px 64px 1fr;
    gap: 12px;
    padding: 12px;
  }

  .ranking-link img {
    width: 64px;
    height: 64px;
  }

  .ranking-meta {
    grid-column: 1 / -1;
  }
}
