:root {
  color-scheme: dark;
  --bg: #020617;
  --bg-soft: #0f172a;
  --panel: rgba(15, 23, 42, 0.72);
  --panel-strong: rgba(15, 23, 42, 0.92);
  --line: rgba(148, 163, 184, 0.18);
  --text: #f8fafc;
  --muted: #94a3b8;
  --faint: #64748b;
  --cyan: #22d3ee;
  --cyan-2: #06b6d4;
  --blue: #3b82f6;
  --shadow: 0 20px 50px rgba(8, 145, 178, 0.16);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "PingFang SC", "Microsoft YaHei", sans-serif;
  background:
    radial-gradient(circle at top left, rgba(34, 211, 238, 0.12), transparent 32rem),
    radial-gradient(circle at top right, rgba(59, 130, 246, 0.1), transparent 34rem),
    var(--bg);
  color: var(--text);
}

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

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

button,
input,
select {
  font: inherit;
}

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

.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 100;
  background: linear-gradient(90deg, rgba(2, 6, 23, 0.94), rgba(15, 23, 42, 0.94), rgba(2, 6, 23, 0.94));
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(18px);
}

.header-inner {
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.brand,
.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
}

.brand-mark,
.footer-brand span {
  width: 34px;
  height: 34px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  background: rgba(34, 211, 238, 0.16);
  color: var(--cyan);
  box-shadow: 0 0 28px rgba(34, 211, 238, 0.25);
}

.brand-copy {
  display: grid;
  line-height: 1.1;
}

.brand-copy strong,
.footer-brand strong {
  font-size: 19px;
  font-weight: 800;
  letter-spacing: 0.03em;
}

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

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 20px;
  overflow: hidden;
  white-space: nowrap;
}

.nav-link {
  position: relative;
  color: #cbd5e1;
  font-size: 15px;
  font-weight: 600;
  transition: color 0.25s ease;
}

.nav-link::after {
  content: "";
  position: absolute;
  left: 0;
  right: 100%;
  bottom: -8px;
  height: 2px;
  background: var(--cyan);
  transition: right 0.25s ease;
}

.nav-link:hover,
.nav-link.active {
  color: var(--cyan);
}

.nav-link:hover::after,
.nav-link.active::after {
  right: 0;
}

.menu-toggle {
  display: none;
  border: 0;
  color: #cbd5e1;
  background: transparent;
  font-size: 26px;
  padding: 6px 8px;
}

.mobile-nav {
  display: none;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto 12px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--panel-strong);
}

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

.mobile-link {
  padding: 10px 12px;
  border-radius: 12px;
  color: #cbd5e1;
}

.mobile-link:hover,
.mobile-link.active {
  background: rgba(34, 211, 238, 0.1);
  color: var(--cyan);
}

main {
  min-height: 70vh;
}

.hero-slider {
  position: relative;
  height: 78vh;
  min-height: 560px;
  overflow: hidden;
  margin-top: 64px;
  background: #020617;
}

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

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

.hero-bg {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.04);
}

.hero-layer {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(0deg, #020617 0%, rgba(2, 6, 23, 0.84) 34%, rgba(2, 6, 23, 0.22) 100%),
    linear-gradient(90deg, rgba(2, 6, 23, 0.9) 0%, rgba(2, 6, 23, 0.5) 43%, rgba(2, 6, 23, 0.08) 100%);
}

.hero-content {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
}

.hero-copy {
  max-width: 720px;
  padding-top: 22px;
}

.hero-kicker,
.pill-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.pill,
.hero-kicker span,
.meta-pill {
  border: 1px solid rgba(34, 211, 238, 0.28);
  background: rgba(34, 211, 238, 0.11);
  color: var(--cyan);
  border-radius: 999px;
  padding: 6px 12px;
  font-size: 13px;
  font-weight: 700;
}

.hero-kicker span + span,
.meta-pill.dim {
  border-color: rgba(148, 163, 184, 0.22);
  background: rgba(15, 23, 42, 0.68);
  color: #cbd5e1;
}

.hero-copy h1 {
  margin: 18px 0 16px;
  font-size: clamp(42px, 7vw, 76px);
  line-height: 1.02;
  letter-spacing: -0.04em;
}

.hero-copy p {
  margin: 0;
  max-width: 680px;
  color: #cbd5e1;
  font-size: clamp(17px, 2.1vw, 23px);
  line-height: 1.8;
}

.hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin: 26px 0 32px;
  color: var(--muted);
  font-weight: 600;
}

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

.btn,
.section-more,
.search-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  border-radius: 999px;
  border: 1px solid rgba(34, 211, 238, 0.22);
  background: rgba(15, 23, 42, 0.72);
  color: #e2e8f0;
  padding: 0 20px;
  font-weight: 800;
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.btn.primary,
.search-button {
  border: 0;
  background: linear-gradient(90deg, var(--cyan-2), var(--blue));
  color: white;
  box-shadow: 0 18px 38px rgba(8, 145, 178, 0.28);
}

.btn:hover,
.section-more:hover,
.search-button:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow);
  border-color: rgba(34, 211, 238, 0.55);
}

.hero-arrow {
  position: absolute;
  z-index: 5;
  top: 50%;
  transform: translateY(-50%);
  width: 46px;
  height: 46px;
  border: 0;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.44);
  color: white;
  backdrop-filter: blur(12px);
  font-size: 26px;
}

.hero-arrow.prev {
  left: 18px;
}

.hero-arrow.next {
  right: 18px;
}

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

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

.hero-dot.active {
  width: 34px;
  background: var(--cyan);
}

.page-hero {
  padding: 130px 0 48px;
  background:
    radial-gradient(circle at 18% 10%, rgba(34, 211, 238, 0.16), transparent 28rem),
    linear-gradient(180deg, rgba(15, 23, 42, 0.74), rgba(2, 6, 23, 0));
}

.page-hero h1 {
  margin: 0 0 14px;
  font-size: clamp(34px, 5vw, 56px);
  line-height: 1.12;
}

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

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

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

.section-head h2 {
  position: relative;
  display: inline-block;
  margin: 0 0 8px;
  font-size: clamp(24px, 3vw, 36px);
}

.section-head h2::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -4px;
  width: 52%;
  height: 3px;
  background: linear-gradient(90deg, var(--cyan), transparent);
}

.section-head p {
  margin: 0;
  color: var(--muted);
}

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

.movie-card {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: rgba(15, 23, 42, 0.56);
  transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

.movie-card:hover {
  transform: translateY(-4px);
  border-color: rgba(34, 211, 238, 0.48);
  box-shadow: var(--shadow);
}

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

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

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

.poster-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.78), transparent 48%);
  opacity: 0;
  transition: opacity 0.25s ease;
}

.movie-card:hover .poster-shade {
  opacity: 1;
}

.play-badge {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 58px;
  height: 58px;
  transform: translate(-50%, -50%) scale(0.88);
  opacity: 0;
  border-radius: 999px;
  display: grid;
  place-items: center;
  background: rgba(6, 182, 212, 0.88);
  color: white;
  transition: opacity 0.25s ease, transform 0.25s ease;
}

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

.year-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  padding: 4px 9px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.62);
  color: #f8fafc;
  font-size: 12px;
  font-weight: 800;
}

.card-body {
  padding: 14px;
}

.card-body h2,
.card-body h3 {
  margin: 0 0 8px;
  font-size: 16px;
  line-height: 1.35;
}

.card-body h2 a:hover,
.card-body h3 a:hover {
  color: var(--cyan);
}

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

.card-meta,
.card-tags {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  color: var(--faint);
  font-size: 12px;
}

.card-meta span,
.card-tags {
  padding: 4px 8px;
  border-radius: 8px;
  background: rgba(51, 65, 85, 0.55);
}

.scroll-row {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(180px, 1fr);
  gap: 16px;
  overflow-x: auto;
  padding-bottom: 12px;
  scrollbar-width: none;
}

.scroll-row::-webkit-scrollbar {
  display: none;
}

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

.category-card {
  min-height: 164px;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background:
    radial-gradient(circle at top right, rgba(34, 211, 238, 0.16), transparent 12rem),
    rgba(15, 23, 42, 0.58);
  transition: transform 0.25s ease, border-color 0.25s ease;
}

.category-card:hover {
  transform: translateY(-4px);
  border-color: rgba(34, 211, 238, 0.5);
}

.category-card h2,
.category-card h3 {
  margin: 0 0 10px;
  font-size: 22px;
}

.category-card p {
  margin: 0 0 16px;
  color: var(--muted);
  line-height: 1.7;
}

.category-card span {
  color: var(--cyan);
  font-weight: 800;
}

.rank-layout {
  display: grid;
  grid-template-columns: 1.4fr 0.8fr;
  gap: 22px;
}

.rank-list,
.side-list {
  display: grid;
  gap: 12px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.rank-item,
.side-panel,
.text-panel {
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(15, 23, 42, 0.6);
}

.rank-link {
  display: grid;
  grid-template-columns: 54px 70px 1fr;
  align-items: center;
  gap: 14px;
  padding: 12px;
}

.rank-num {
  color: var(--cyan);
  font-size: 22px;
  font-weight: 900;
  text-align: center;
}

.rank-link img {
  width: 70px;
  height: 96px;
  object-fit: cover;
  border-radius: 12px;
}

.rank-copy strong {
  display: block;
  margin-bottom: 8px;
  font-size: 17px;
}

.rank-copy small {
  color: var(--muted);
  line-height: 1.5;
}

.side-panel {
  padding: 20px;
}

.side-panel h2,
.side-panel h3 {
  margin: 0 0 16px;
  font-size: 22px;
}

.search-panel {
  display: grid;
  grid-template-columns: 1fr 180px 180px auto;
  gap: 12px;
  margin-top: 28px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: rgba(15, 23, 42, 0.66);
}

.search-panel input,
.search-panel select {
  width: 100%;
  min-height: 46px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(2, 6, 23, 0.62);
  color: var(--text);
  padding: 0 14px;
  outline: none;
}

.search-panel input:focus,
.search-panel select:focus {
  border-color: rgba(34, 211, 238, 0.56);
}

.result-note {
  color: var(--muted);
  margin: 0 0 18px;
}

.detail-hero {
  padding: 112px 0 34px;
  background:
    radial-gradient(circle at 80% 0%, rgba(34, 211, 238, 0.14), transparent 28rem),
    linear-gradient(180deg, rgba(15, 23, 42, 0.78), rgba(2, 6, 23, 0));
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 22px;
  color: var(--muted);
  font-size: 14px;
}

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

.detail-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 330px;
  gap: 26px;
  align-items: start;
}

.player-card,
.detail-card {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: rgba(15, 23, 42, 0.62);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.22);
}

.player-shell {
  position: relative;
  background: #000;
}

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

.player-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.58), rgba(0, 0, 0, 0.22));
  cursor: pointer;
  z-index: 3;
}

.player-overlay.hidden {
  display: none;
}

.play-circle {
  display: grid;
  place-items: center;
  width: 86px;
  height: 86px;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--cyan-2), var(--blue));
  color: white;
  font-size: 34px;
  box-shadow: 0 18px 50px rgba(8, 145, 178, 0.35);
}

.player-copy,
.detail-body {
  padding: 22px;
}

.player-copy h1 {
  margin: 0 0 12px;
  font-size: clamp(28px, 4vw, 46px);
  line-height: 1.16;
}

.player-copy p,
.detail-body p,
.text-panel p {
  margin: 0;
  color: #cbd5e1;
  line-height: 1.9;
}

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

.detail-body h2,
.text-panel h2 {
  margin: 0 0 12px;
  font-size: 24px;
}

.info-list {
  display: grid;
  gap: 10px;
  margin: 18px 0 0;
  padding: 0;
  list-style: none;
  color: var(--muted);
}

.info-list strong {
  color: var(--text);
}

.text-panel {
  padding: 24px;
}

.text-stack {
  display: grid;
  gap: 18px;
}

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

.empty-card {
  display: none;
  padding: 26px;
  border: 1px solid var(--line);
  border-radius: 18px;
  color: var(--muted);
  background: rgba(15, 23, 42, 0.62);
}

.empty-card.show {
  display: block;
}

.site-footer {
  margin-top: 50px;
  border-top: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.72), rgba(2, 6, 23, 1));
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 0.8fr 0.8fr;
  gap: 30px;
  padding: 42px 0 28px;
}

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

.site-footer h2 {
  margin: 0 0 14px;
  font-size: 18px;
}

.site-footer ul {
  display: grid;
  gap: 6px;
  margin: 0;
  padding: 0;
  list-style: none;
}

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

.footer-bottom {
  border-top: 1px solid var(--line);
  padding: 18px 0 24px;
  color: var(--faint);
  text-align: center;
  font-size: 14px;
}

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

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

  .desktop-nav {
    gap: 14px;
  }
}

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

  .menu-toggle {
    display: block;
  }

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

  .hero-arrow {
    display: none;
  }

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

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

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

@media (max-width: 520px) {
  .container {
    width: min(100% - 22px, 1180px);
  }

  .brand-copy small {
    display: none;
  }

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

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

  .movie-grid,
  .category-grid,
  .related-grid {
    gap: 12px;
  }

  .card-body {
    padding: 12px;
  }

  .rank-link {
    grid-template-columns: 44px 58px 1fr;
  }

  .rank-link img {
    width: 58px;
    height: 82px;
  }
}

.site-index-list { column-count: 4; margin: 0; padding-left: 18px; color: var(--muted); line-height: 1.9; }
.site-index-list a:hover { color: var(--cyan); }
@media (max-width: 860px) { .site-index-list { column-count: 2; } }
@media (max-width: 520px) { .site-index-list { column-count: 1; } }
