:root {
  color-scheme: dark;
  --bg: #020617;
  --bg-soft: #0f172a;
  --bg-card: rgba(15, 23, 42, 0.74);
  --line: rgba(56, 189, 248, 0.22);
  --line-strong: rgba(34, 211, 238, 0.48);
  --text: #f8fafc;
  --muted: #94a3b8;
  --muted-2: #64748b;
  --cyan: #22d3ee;
  --blue: #2563eb;
  --purple: #a855f7;
  --orange: #fb923c;
  --green: #34d399;
  --radius: 24px;
  --shadow: 0 28px 80px rgba(8, 47, 73, 0.35);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  background:
    radial-gradient(circle at top left, rgba(34, 211, 238, 0.16), transparent 35rem),
    radial-gradient(circle at 85% 20%, rgba(37, 99, 235, 0.18), transparent 30rem),
    linear-gradient(180deg, #020617 0%, #08112a 46%, #020617 100%);
  color: var(--text);
  min-height: 100vh;
}

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

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

button,
input {
  font: inherit;
}

button {
  cursor: pointer;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 80;
  background: linear-gradient(90deg, rgba(15, 23, 42, 0.92), rgba(30, 58, 138, 0.86), rgba(15, 23, 42, 0.92));
  border-bottom: 1px solid rgba(59, 130, 246, 0.28);
  backdrop-filter: blur(18px);
}

.nav-wrap {
  min-height: 72px;
  display: flex;
  align-items: center;
  gap: 24px;
}

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

.brand-icon {
  width: 42px;
  height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  color: #fff;
  background: linear-gradient(135deg, var(--cyan), var(--blue));
  box-shadow: 0 14px 40px rgba(34, 211, 238, 0.28);
}

.brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.1;
}

.brand-text strong {
  font-size: 22px;
  letter-spacing: 0.02em;
}

.brand-text em {
  margin-top: 5px;
  font-style: normal;
  font-size: 12px;
  color: #67e8f9;
}

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

.desktop-nav a,
.mobile-panel nav a {
  color: #cbd5e1;
  font-weight: 650;
  transition: color 0.2s ease, background 0.2s ease;
}

.desktop-nav a:hover,
.desktop-nav a.is-active,
.mobile-panel nav a:hover,
.mobile-panel nav a.is-active {
  color: var(--cyan);
}

.header-search,
.mobile-search {
  position: relative;
  display: flex;
  align-items: center;
  gap: 8px;
}

.header-search input,
.mobile-search input,
.search-box input {
  width: 240px;
  border: 1px solid rgba(96, 165, 250, 0.28);
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.66);
  color: var(--text);
  padding: 11px 14px;
  outline: none;
  transition: border 0.2s ease, box-shadow 0.2s ease;
}

.header-search input:focus,
.mobile-search input:focus,
.search-box input:focus {
  border-color: rgba(34, 211, 238, 0.8);
  box-shadow: 0 0 0 4px rgba(34, 211, 238, 0.12);
}

.header-search button,
.mobile-search button,
.search-box button,
.hero-button,
.btn,
.pagination a,
.pagination span,
.player-start {
  border: 0;
  color: #fff;
  background: linear-gradient(135deg, var(--cyan), var(--blue));
  box-shadow: 0 18px 50px rgba(34, 211, 238, 0.22);
}

.header-search button,
.mobile-search button {
  border-radius: 999px;
  padding: 10px 14px;
  font-weight: 700;
}

.menu-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 12px;
  background: rgba(15, 23, 42, 0.72);
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 5px;
}

.menu-toggle span {
  width: 20px;
  height: 2px;
  border-radius: 9px;
  background: #fff;
}

.mobile-panel {
  display: none;
  border-top: 1px solid rgba(59, 130, 246, 0.28);
  background: rgba(2, 6, 23, 0.96);
}

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

.mobile-panel-inner {
  padding: 16px 0 20px;
}

.mobile-search {
  margin-bottom: 14px;
}

.mobile-search input {
  width: 100%;
}

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

.mobile-panel nav a {
  padding: 10px 12px;
  border-radius: 12px;
  background: rgba(15, 23, 42, 0.55);
}

.hero {
  position: relative;
  min-height: 78vh;
  overflow: hidden;
  display: flex;
  align-items: center;
}

.hero-bg {
  position: absolute;
  inset: 0;
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 0.8s ease;
}

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

.hero-slide .poster {
  position: absolute;
  inset: 0;
}

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

.hero-slide::after,
.hero-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(2, 6, 23, 0.95) 0%, rgba(2, 6, 23, 0.74) 42%, rgba(2, 6, 23, 0.42) 100%),
    linear-gradient(0deg, #020617 0%, rgba(2, 6, 23, 0.08) 45%, rgba(2, 6, 23, 0.78) 100%);
}

.hero-inner {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(320px, 0.92fr);
  gap: 42px;
  align-items: center;
  padding: 72px 0;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #67e8f9;
  background: rgba(8, 47, 73, 0.48);
  border: 1px solid rgba(34, 211, 238, 0.32);
  border-radius: 999px;
  padding: 8px 14px;
  font-size: 14px;
  font-weight: 700;
}

.hero h1 {
  margin: 24px 0 18px;
  font-size: clamp(44px, 7vw, 84px);
  line-height: 0.96;
  letter-spacing: -0.055em;
}

.hero h1 span {
  display: block;
  margin-top: 12px;
  font-size: clamp(26px, 3.5vw, 46px);
  color: var(--cyan);
}

.hero-lead {
  max-width: 700px;
  color: #cbd5e1;
  font-size: clamp(17px, 2vw, 22px);
  line-height: 1.8;
}

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

.hero-button,
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  border-radius: 999px;
  padding: 14px 22px;
  font-weight: 800;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.hero-button:hover,
.btn:hover,
.player-start:hover {
  transform: translateY(-2px);
  box-shadow: 0 24px 60px rgba(34, 211, 238, 0.32);
}

.btn.secondary {
  background: rgba(15, 23, 42, 0.72);
  border: 1px solid rgba(148, 163, 184, 0.24);
  box-shadow: none;
}

.hero-feature {
  position: relative;
  padding: 18px;
  border: 1px solid rgba(34, 211, 238, 0.28);
  border-radius: 30px;
  background: linear-gradient(135deg, rgba(15, 23, 42, 0.78), rgba(30, 58, 138, 0.38));
  box-shadow: var(--shadow);
  backdrop-filter: blur(20px);
}

.hero-feature-cover {
  height: 330px;
  border-radius: 24px;
  overflow: hidden;
  background: #0f172a;
}

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

.hero-feature h2 {
  margin: 18px 0 8px;
  font-size: 26px;
}

.hero-feature p {
  color: #cbd5e1;
  line-height: 1.7;
}

.hero-dots {
  display: flex;
  gap: 8px;
  margin-top: 18px;
}

.hero-dot {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  border: 0;
  background: rgba(148, 163, 184, 0.45);
}

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

.main-section {
  padding: 62px 0;
}

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

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

.section-head p {
  margin: 10px 0 0;
  color: var(--muted);
  line-height: 1.7;
}

.section-action {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--cyan);
  font-weight: 800;
  white-space: nowrap;
}

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

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

.movie-card,
.wide-card,
.compact-card,
.link-card,
.detail-panel,
.player-shell,
.category-card,
.search-box,
.index-block {
  background: var(--bg-card);
  border: 1px solid rgba(59, 130, 246, 0.24);
  box-shadow: 0 18px 50px rgba(2, 6, 23, 0.22);
  backdrop-filter: blur(14px);
}

.movie-card {
  display: block;
  overflow: hidden;
  border-radius: 22px;
  transition: transform 0.25s ease, border 0.25s ease, box-shadow 0.25s ease;
}

.movie-card:hover,
.wide-card:hover,
.compact-card:hover,
.category-card:hover {
  transform: translateY(-6px);
  border-color: var(--line-strong);
  box-shadow: 0 22px 70px rgba(34, 211, 238, 0.16);
}

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

.movie-poster img,
.wide-cover img,
.compact-cover img,
.related-cover img,
.index-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.45s ease;
}

.movie-card:hover img,
.wide-card:hover img,
.compact-card:hover img {
  transform: scale(1.08);
}

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

.year-badge,
.rank-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  color: #fff;
  background: rgba(2, 6, 23, 0.74);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 999px;
  padding: 5px 9px;
  font-size: 12px;
  font-weight: 800;
}

.rank-badge {
  left: 12px;
  right: auto;
  background: linear-gradient(135deg, #fb923c, #db2777);
}

.play-mark {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 54px;
  height: 54px;
  display: flex;
  align-items: center;
  justify-content: center;
  transform: translate(-50%, -50%) scale(0.78);
  border-radius: 999px;
  background: rgba(34, 211, 238, 0.92);
  color: #fff;
  opacity: 0;
  transition: opacity 0.25s ease, transform 0.25s ease;
}

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

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

.pill-row,
.meta-row,
.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.pill,
.tag,
.meta-row span {
  display: inline-flex;
  border-radius: 999px;
  padding: 5px 9px;
  font-size: 12px;
  font-weight: 800;
  border: 1px solid rgba(148, 163, 184, 0.18);
  color: #cbd5e1;
  background: rgba(15, 23, 42, 0.68);
}

.pill.cyan {
  color: var(--cyan);
  border-color: rgba(34, 211, 238, 0.26);
  background: rgba(8, 145, 178, 0.16);
}

.pill.purple {
  color: #d8b4fe;
  border-color: rgba(168, 85, 247, 0.24);
  background: rgba(88, 28, 135, 0.2);
}

.movie-card h3,
.wide-card h3,
.compact-card h3 {
  margin: 12px 0 8px;
  color: #fff;
  font-size: 17px;
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

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

.spotlight {
  border-radius: 34px;
  padding: 34px;
  background: linear-gradient(120deg, rgba(30, 58, 138, 0.36), rgba(15, 23, 42, 0.64));
  border: 1px solid rgba(59, 130, 246, 0.25);
}

.wide-list {
  display: grid;
  gap: 18px;
}

.wide-card {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  overflow: hidden;
  border-radius: 20px;
  transition: transform 0.25s ease, border 0.25s ease, box-shadow 0.25s ease;
}

.wide-cover {
  position: relative;
  min-height: 150px;
  overflow: hidden;
}

.wide-body {
  padding: 20px;
}

.compact-list {
  display: grid;
  gap: 14px;
}

.compact-card {
  display: grid;
  grid-template-columns: 96px minmax(0, 1fr);
  gap: 14px;
  align-items: center;
  padding: 10px;
  border-radius: 16px;
  transition: transform 0.25s ease, border 0.25s ease, box-shadow 0.25s ease;
}

.compact-cover {
  position: relative;
  aspect-ratio: 4 / 3;
  border-radius: 12px;
  overflow: hidden;
}

.compact-body h3 {
  margin-top: 0;
  font-size: 15px;
}

.compact-body p {
  font-size: 12px;
}

.catalog-hero,
.page-hero {
  padding: 58px 0 28px;
}

.page-hero h1,
.catalog-hero h1 {
  margin: 0 0 14px;
  font-size: clamp(36px, 5vw, 62px);
  letter-spacing: -0.045em;
}

.page-hero p,
.catalog-hero p {
  max-width: 760px;
  margin: 0;
  color: var(--muted);
  line-height: 1.8;
  font-size: 18px;
}

.pagination {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin: 44px 0 8px;
}

.pagination a,
.pagination span {
  min-width: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  padding: 10px 13px;
  font-weight: 800;
}

.pagination a {
  background: rgba(15, 23, 42, 0.88);
  border: 1px solid rgba(59, 130, 246, 0.28);
  box-shadow: none;
}

.pagination a:hover,
.pagination span {
  background: linear-gradient(135deg, var(--cyan), var(--blue));
}

.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 28px;
  padding: 32px 0 64px;
}

.player-shell {
  position: relative;
  overflow: hidden;
  border-radius: 24px;
  background: #000;
}

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

.player-start {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 86px;
  height: 86px;
  transform: translate(-50%, -50%);
  border-radius: 999px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 34px;
  z-index: 3;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.player-shell.is-playing .player-start {
  opacity: 0;
  pointer-events: none;
}

.player-status {
  position: absolute;
  left: 18px;
  bottom: 18px;
  z-index: 4;
  color: #cbd5e1;
  background: rgba(2, 6, 23, 0.72);
  border-radius: 999px;
  padding: 6px 12px;
  font-size: 13px;
  pointer-events: none;
}

.detail-panel {
  margin-top: 22px;
  border-radius: 24px;
  padding: 26px;
}

.detail-panel h1 {
  margin: 18px 0 14px;
  font-size: clamp(30px, 4vw, 48px);
  line-height: 1.08;
  letter-spacing: -0.035em;
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  color: var(--muted);
}

.one-line {
  margin: 20px 0;
  padding: 18px 20px;
  border-left: 4px solid var(--cyan);
  border-radius: 16px;
  color: #a5f3fc;
  background: linear-gradient(90deg, rgba(8, 47, 73, 0.44), rgba(15, 23, 42, 0.25));
  line-height: 1.8;
}

.prose h2,
.sidebar h2 {
  margin: 28px 0 12px;
  font-size: 24px;
}

.prose p {
  color: #cbd5e1;
  line-height: 1.95;
  margin: 0 0 16px;
}

.sidebar {
  position: sticky;
  top: 96px;
  align-self: start;
}

.sidebar h2 {
  margin-top: 0;
}

.related-list {
  display: grid;
  gap: 14px;
}

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

.category-card,
.link-card,
.index-block {
  border-radius: 18px;
  padding: 18px;
}

.category-card h3,
.link-card h3,
.index-block h2 {
  margin: 0 0 8px;
  color: #fff;
}

.category-card p,
.link-card p,
.index-block p {
  margin: 0;
  color: var(--muted);
  line-height: 1.6;
}

.search-box {
  border-radius: 24px;
  padding: 20px;
  max-width: 840px;
}

.search-box form {
  display: flex;
  gap: 10px;
}

.search-box input {
  width: 100%;
  border-radius: 16px;
  padding: 16px;
}

.search-box button {
  border-radius: 16px;
  border: 0;
  padding: 0 22px;
  font-weight: 900;
}

.index-block ul {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px 18px;
  padding: 0;
  margin: 14px 0 0;
  list-style: none;
}

.index-block a {
  color: #cbd5e1;
}

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

.poster.cover-fallback {
  background:
    radial-gradient(circle at 25% 20%, rgba(34, 211, 238, 0.35), transparent 34%),
    radial-gradient(circle at 80% 70%, rgba(168, 85, 247, 0.28), transparent 34%),
    linear-gradient(135deg, #0f172a, #1e3a8a 48%, #020617);
}

.poster.cover-fallback img {
  display: none;
}

.poster.cover-fallback::before {
  content: attr(data-title);
  position: absolute;
  inset: 16px;
  display: flex;
  align-items: flex-end;
  color: rgba(255, 255, 255, 0.86);
  font-weight: 900;
  font-size: clamp(16px, 3vw, 26px);
  line-height: 1.22;
  text-shadow: 0 10px 30px rgba(0, 0, 0, 0.45);
  z-index: 1;
}

.site-footer {
  border-top: 1px solid rgba(59, 130, 246, 0.22);
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.72), #020617);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.25fr repeat(3, 1fr);
  gap: 32px;
  padding: 46px 0;
}

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

.site-footer h3 {
  margin: 0 0 14px;
  color: #fff;
}

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

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

.footer-bottom {
  border-top: 1px solid rgba(59, 130, 246, 0.16);
}

.footer-bottom .container {
  min-height: 54px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

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

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

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

  .hero-feature {
    max-width: 560px;
  }

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

  .sidebar {
    position: static;
  }

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

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

  .brand-text strong {
    font-size: 18px;
  }

  .hero {
    min-height: auto;
  }

  .hero-inner {
    padding: 48px 0;
  }

  .hero-feature-cover {
    height: 230px;
  }

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

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

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

  .wide-card {
    grid-template-columns: 120px minmax(0, 1fr);
  }

  .wide-body {
    padding: 14px;
  }

  .wide-cover {
    min-height: 132px;
  }

  .detail-panel {
    padding: 18px;
  }

  .player-start {
    width: 66px;
    height: 66px;
    font-size: 26px;
  }

  .search-box form {
    flex-direction: column;
  }

  .search-box button {
    padding: 14px 20px;
  }

  .index-block ul {
    grid-template-columns: 1fr;
  }

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

  .footer-bottom .container {
    align-items: flex-start;
    flex-direction: column;
    padding: 16px 0;
  }
}

@media (max-width: 460px) {
  .movie-grid,
  .movie-grid.six,
  .category-grid,
  .index-grid {
    grid-template-columns: 1fr;
  }

  .wide-card {
    grid-template-columns: 1fr;
  }

  .wide-cover {
    aspect-ratio: 16 / 9;
  }
}
