:root {
  color-scheme: dark;
  --bg: #020617;
  --bg-soft: #0f172a;
  --panel: rgba(15, 23, 42, 0.78);
  --panel-strong: rgba(15, 23, 42, 0.96);
  --line: rgba(148, 163, 184, 0.18);
  --text: #f8fafc;
  --muted: #cbd5e1;
  --soft: #94a3b8;
  --amber: #fbbf24;
  --amber-dark: #f59e0b;
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.45);
  --radius: 22px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  background:
    radial-gradient(circle at top left, rgba(251, 191, 36, 0.13), transparent 34rem),
    radial-gradient(circle at 80% 12%, rgba(59, 130, 246, 0.12), transparent 28rem),
    linear-gradient(135deg, #020617 0%, #0f172a 48%, #111827 100%);
  color: var(--text);
}

body.no-scroll {
  overflow: hidden;
}

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

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

button,
input,
select {
  font: inherit;
}

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 80;
  transition: background 0.3s ease, box-shadow 0.3s ease, backdrop-filter 0.3s ease;
  background: linear-gradient(180deg, rgba(2, 6, 23, 0.9), rgba(2, 6, 23, 0));
}

.site-header.is-scrolled,
.site-header.is-open {
  background: rgba(2, 6, 23, 0.94);
  backdrop-filter: blur(18px);
  box-shadow: 0 14px 40px rgba(0, 0, 0, 0.28);
}

.nav-shell {
  max-width: 1240px;
  height: 72px;
  margin: 0 auto;
  padding: 0 22px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

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

.brand-icon {
  width: 38px;
  height: 38px;
  border-radius: 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #111827;
  background: linear-gradient(135deg, var(--amber), var(--amber-dark));
  box-shadow: 0 12px 30px rgba(251, 191, 36, 0.25);
}

.brand-icon svg {
  width: 24px;
  height: 24px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.brand-text {
  font-size: clamp(1.1rem, 2vw, 1.55rem);
  color: #ffffff;
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 28px;
  color: var(--muted);
  font-weight: 650;
}

.desktop-nav a,
.footer-links a,
.section-more {
  transition: color 0.2s ease;
}

.desktop-nav a:hover,
.footer-links a:hover,
.section-more:hover {
  color: var(--amber);
}

.nav-search {
  position: relative;
  display: flex;
  width: min(310px, 28vw);
  background: rgba(15, 23, 42, 0.75);
  border: 1px solid var(--line);
  border-radius: 999px;
  overflow: hidden;
}

.nav-search input,
.mobile-panel input,
.filter-bar input,
.filter-bar select {
  width: 100%;
  border: 0;
  outline: 0;
  color: var(--text);
  background: transparent;
}

.nav-search input {
  padding: 11px 16px;
}

.nav-search button {
  border: 0;
  padding: 0 18px;
  color: #111827;
  font-weight: 800;
  background: var(--amber);
  cursor: pointer;
}

.mobile-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(15, 23, 42, 0.7);
  cursor: pointer;
}

.mobile-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  margin: 4px auto;
  background: #fff;
  border-radius: 99px;
}

.mobile-panel {
  display: none;
  padding: 12px 22px 24px;
  background: rgba(2, 6, 23, 0.98);
  border-top: 1px solid var(--line);
}

.mobile-panel a {
  display: block;
  padding: 14px 0;
  color: var(--muted);
  font-weight: 700;
}

.mobile-panel form {
  display: flex;
  margin-top: 8px;
  border: 1px solid var(--line);
  border-radius: 16px;
  overflow: hidden;
}

.mobile-panel input {
  padding: 12px 14px;
}

.mobile-panel button {
  border: 0;
  padding: 0 16px;
  background: var(--amber);
  color: #111827;
  font-weight: 800;
}

.hero {
  position: relative;
  min-height: 100vh;
  display: grid;
  align-items: center;
  overflow: hidden;
  isolation: isolate;
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: grid;
  align-items: center;
  opacity: 0;
  transform: scale(1.015);
  transition: opacity 0.7s ease, transform 0.7s ease;
  pointer-events: none;
}

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

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

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

.hero-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(0deg, #020617 0%, rgba(2, 6, 23, 0.76) 38%, rgba(2, 6, 23, 0.28) 100%),
    linear-gradient(90deg, rgba(2, 6, 23, 0.93) 0%, rgba(15, 23, 42, 0.72) 42%, rgba(2, 6, 23, 0.72) 100%);
}

.hero-content {
  max-width: 880px;
  padding: 150px 24px 120px;
  margin: 0 auto;
  text-align: center;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px 16px;
  border: 1px solid rgba(251, 191, 36, 0.32);
  border-radius: 999px;
  color: var(--amber);
  background: rgba(251, 191, 36, 0.12);
  font-weight: 800;
  letter-spacing: 0.08em;
}

.hero h1,
.page-hero h1,
.detail-intro h1 {
  margin: 24px 0 18px;
  font-size: clamp(2.5rem, 7vw, 6.2rem);
  line-height: 0.98;
  letter-spacing: -0.05em;
}

.hero p,
.page-hero p,
.detail-intro .lead-text {
  margin: 0 auto;
  max-width: 760px;
  color: var(--muted);
  font-size: clamp(1rem, 2vw, 1.35rem);
  line-height: 1.8;
}

.hero-tags,
.detail-meta,
.tag-list {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin-top: 26px;
}

.hero-tags span,
.detail-meta span,
.tag-list span {
  padding: 8px 14px;
  border-radius: 999px;
  color: var(--muted);
  background: rgba(15, 23, 42, 0.72);
  border: 1px solid var(--line);
  backdrop-filter: blur(12px);
}

.hero-tags span:first-child,
.detail-meta span:first-child {
  color: var(--amber);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 14px;
  margin-top: 34px;
}

.primary-button,
.ghost-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 50px;
  padding: 0 24px;
  border-radius: 999px;
  font-weight: 900;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.primary-button {
  color: #111827;
  background: linear-gradient(135deg, var(--amber), var(--amber-dark));
  box-shadow: 0 18px 44px rgba(251, 191, 36, 0.26);
}

.ghost-button {
  color: var(--text);
  border: 1px solid var(--line);
  background: rgba(15, 23, 42, 0.6);
}

.primary-button:hover,
.ghost-button:hover {
  transform: translateY(-2px) scale(1.02);
}

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

.hero-dot {
  width: 34px;
  height: 6px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.32);
  cursor: pointer;
  transition: width 0.25s ease, background 0.25s ease;
}

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

.hero-side-list {
  position: absolute;
  right: max(24px, calc((100vw - 1240px) / 2));
  bottom: 86px;
  z-index: 5;
  display: grid;
  gap: 12px;
  width: min(360px, 30vw);
}

.compact-card {
  display: grid;
  grid-template-columns: 58px 1fr;
  align-items: center;
  gap: 12px;
  padding: 10px;
  border-radius: 18px;
  border: 1px solid var(--line);
  background: rgba(15, 23, 42, 0.72);
  backdrop-filter: blur(16px);
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.compact-card:hover {
  transform: translateX(-4px);
  border-color: rgba(251, 191, 36, 0.45);
}

.compact-card img {
  width: 58px;
  height: 78px;
  object-fit: cover;
  border-radius: 12px;
}

.compact-card span {
  color: #fff;
  font-weight: 800;
  line-height: 1.35;
}

.quick-panel {
  position: relative;
  z-index: 8;
  max-width: 1180px;
  margin: -54px auto 44px;
  padding: 0 22px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.quick-panel a,
.category-tile,
.category-card,
.movie-card,
.rank-row,
.detail-content article,
.player-shell {
  border: 1px solid var(--line);
  background: var(--panel);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}

.quick-panel a {
  display: grid;
  gap: 7px;
  padding: 24px;
  border-radius: var(--radius);
}

.quick-panel strong {
  font-size: 1.15rem;
}

.quick-panel span {
  color: var(--soft);
}

.content-section,
.page-main,
.detail-main {
  max-width: 1240px;
  margin: 0 auto;
  padding: 76px 22px;
}

.page-main,
.detail-main {
  padding-top: 112px;
}

.alt-section {
  max-width: none;
  padding-left: max(22px, calc((100vw - 1240px) / 2));
  padding-right: max(22px, calc((100vw - 1240px) / 2));
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.35), rgba(2, 6, 23, 0));
}

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

.section-heading h2 {
  margin: 0;
  font-size: clamp(1.7rem, 3vw, 2.45rem);
  line-height: 1.1;
}

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

.section-more {
  color: var(--amber);
  font-weight: 800;
}

.movie-grid {
  display: grid;
  gap: 22px;
}

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

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

.movie-card {
  overflow: hidden;
  border-radius: var(--radius);
  transition: transform 0.24s ease, border-color 0.24s ease, box-shadow 0.24s ease;
}

.movie-card:hover {
  transform: translateY(-7px);
  border-color: rgba(251, 191, 36, 0.45);
  box-shadow: 0 26px 80px rgba(0, 0, 0, 0.52), 0 0 36px rgba(251, 191, 36, 0.08);
}

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

.card-feature .poster-frame {
  aspect-ratio: 16 / 10;
}

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

.movie-card:hover .poster-frame img {
  transform: scale(1.07);
  filter: brightness(0.78);
}

.poster-frame::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(2, 6, 23, 0.72), rgba(2, 6, 23, 0.02) 54%);
}

.card-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  z-index: 2;
  padding: 6px 10px;
  border-radius: 999px;
  color: #111827;
  background: var(--amber);
  font-size: 0.78rem;
  font-weight: 900;
}

.play-mark {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 3;
  width: 54px;
  height: 54px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  color: #111827;
  background: rgba(251, 191, 36, 0.95);
  opacity: 0;
  transform: translate(-50%, -50%) scale(0.86);
  transition: opacity 0.25s ease, transform 0.25s ease;
}

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

.card-body {
  padding: 16px;
}

.card-body h2 {
  margin: 0;
  font-size: 1rem;
  line-height: 1.35;
}

.card-body p {
  min-height: 48px;
  margin: 8px 0 0;
  color: var(--soft);
  font-size: 0.92rem;
  line-height: 1.7;
}

.card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-top: 12px;
  color: var(--amber);
  font-size: 0.84rem;
  font-weight: 800;
}

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

.category-tile,
.category-card {
  position: relative;
  overflow: hidden;
  min-height: 150px;
  padding: 24px;
  border-radius: var(--radius);
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.category-tile::before,
.category-card::before {
  content: "";
  position: absolute;
  inset: auto -30px -52px auto;
  width: 140px;
  height: 140px;
  border-radius: 999px;
  background: rgba(251, 191, 36, 0.12);
}

.category-tile:hover,
.category-card:hover {
  transform: translateY(-4px);
  border-color: rgba(251, 191, 36, 0.42);
}

.category-tile span,
.category-card span {
  position: relative;
  display: block;
  color: #fff;
  font-size: 1.2rem;
  font-weight: 900;
}

.category-tile p,
.category-card p {
  position: relative;
  margin: 12px 0 0;
  color: var(--soft);
  line-height: 1.7;
}

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

.category-card {
  min-height: 230px;
}

.category-card img {
  height: 138px;
  object-fit: cover;
  border-radius: 18px;
  margin-bottom: 16px;
}

.rank-list,
.rank-board {
  display: grid;
  gap: 12px;
}

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

.rank-row {
  display: grid;
  grid-template-columns: 52px 58px 1fr auto;
  align-items: center;
  gap: 14px;
  padding: 12px;
  border-radius: 18px;
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.rank-row:hover {
  transform: translateX(4px);
  border-color: rgba(251, 191, 36, 0.42);
}

.rank-number {
  color: var(--amber);
  font-size: 1.25rem;
  font-weight: 950;
}

.rank-row img {
  width: 58px;
  height: 78px;
  border-radius: 12px;
  object-fit: cover;
}

.rank-info {
  display: grid;
  gap: 6px;
}

.rank-info strong {
  color: #fff;
}

.rank-info em {
  color: var(--soft);
  font-style: normal;
  font-size: 0.9rem;
}

.rank-action {
  color: #111827;
  padding: 8px 12px;
  border-radius: 999px;
  background: var(--amber);
  font-weight: 900;
}

.page-hero {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 30px;
  background:
    linear-gradient(135deg, rgba(251, 191, 36, 0.13), rgba(59, 130, 246, 0.07)),
    rgba(15, 23, 42, 0.78);
  box-shadow: var(--shadow);
}

.compact-hero {
  padding: clamp(34px, 8vw, 72px);
  text-align: center;
}

.compact-hero h1 {
  font-size: clamp(2.1rem, 5vw, 4.8rem);
}

.filter-bar {
  display: grid;
  grid-template-columns: 1fr 180px;
  gap: 14px;
  margin-bottom: 26px;
}

.wide-filter {
  grid-template-columns: 1fr 190px 170px;
}

.filter-bar input,
.filter-bar select {
  min-height: 50px;
  padding: 0 16px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(15, 23, 42, 0.78);
}

.detail-hero {
  position: relative;
  overflow: hidden;
  border-radius: 30px;
  min-height: 660px;
  display: grid;
  align-items: end;
  box-shadow: var(--shadow);
}

.detail-backdrop {
  position: absolute;
  inset: 0;
  z-index: -1;
}

.detail-backdrop img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: blur(7px) brightness(0.5);
  transform: scale(1.04);
}

.detail-backdrop::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(0deg, #020617 0%, rgba(2, 6, 23, 0.76) 50%, rgba(2, 6, 23, 0.32) 100%),
    linear-gradient(90deg, rgba(2, 6, 23, 0.92), rgba(2, 6, 23, 0.38));
}

.detail-wrap {
  display: grid;
  grid-template-columns: minmax(220px, 320px) 1fr;
  gap: clamp(24px, 5vw, 54px);
  padding: clamp(24px, 5vw, 58px);
  align-items: end;
}

.detail-poster img {
  aspect-ratio: 2 / 3;
  object-fit: cover;
  border-radius: 26px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.62);
}

.detail-intro h1 {
  max-width: 820px;
  margin-top: 14px;
  font-size: clamp(2.25rem, 5vw, 5rem);
}

.detail-intro .lead-text {
  margin: 0;
  max-width: 840px;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  color: var(--muted);
}

.breadcrumb a {
  color: var(--amber);
  font-weight: 800;
}

.detail-meta,
.tag-list {
  justify-content: flex-start;
}

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

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

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

.player-overlay {
  position: absolute;
  inset: 0;
  z-index: 5;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 16px;
  border: 0;
  color: #fff;
  background: linear-gradient(0deg, rgba(2, 6, 23, 0.72), rgba(2, 6, 23, 0.28));
  cursor: pointer;
}

.player-shell.is-playing .player-overlay {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

.play-button {
  width: 78px;
  height: 78px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  color: #111827;
  background: var(--amber);
  box-shadow: 0 18px 54px rgba(251, 191, 36, 0.32);
  font-size: 2rem;
}

.player-overlay strong {
  max-width: 80%;
  text-align: center;
  font-size: clamp(1.1rem, 2vw, 1.65rem);
}

.detail-content {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 24px;
  padding: 34px 0 0;
}

.detail-content article {
  border-radius: 24px;
  padding: 28px;
}

.detail-content h2 {
  margin: 0 0 14px;
  color: #fff;
  font-size: 1.45rem;
}

.detail-content p {
  margin: 0;
  color: var(--muted);
  line-height: 1.95;
}

.related-section {
  padding-left: 0;
  padding-right: 0;
}

.site-footer {
  border-top: 1px solid var(--line);
  background: rgba(2, 6, 23, 0.72);
}

.footer-grid {
  max-width: 1240px;
  margin: 0 auto;
  padding: 54px 22px;
  display: grid;
  grid-template-columns: 1.2fr 0.9fr 0.9fr;
  gap: 40px;
}

.footer-brand {
  color: #fff;
  font-size: 1.35rem;
}

.site-footer p {
  max-width: 460px;
  color: var(--soft);
  line-height: 1.8;
}

.site-footer h2 {
  margin: 0 0 16px;
  font-size: 1rem;
}

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

.is-hidden {
  display: none !important;
}

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

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

  .hero-side-list {
    display: none;
  }
}

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

  .mobile-toggle {
    display: block;
  }

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

  .hero-content {
    padding-top: 122px;
  }

  .quick-panel,
  .category-grid,
  .footer-grid,
  .rank-board,
  .detail-wrap,
  .detail-content {
    grid-template-columns: 1fr;
  }

  .quick-panel {
    margin-top: -34px;
  }

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

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

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

  .detail-wrap {
    padding-top: 110px;
  }

  .detail-poster {
    max-width: 240px;
  }
}

@media (max-width: 560px) {
  .nav-shell {
    height: 64px;
    padding: 0 16px;
  }

  .brand-icon {
    width: 34px;
    height: 34px;
  }

  .brand-text {
    font-size: 1.12rem;
  }

  .hero-content {
    text-align: left;
    padding-left: 18px;
    padding-right: 18px;
  }

  .hero p {
    margin-left: 0;
  }

  .hero-tags,
  .hero-actions {
    justify-content: flex-start;
  }

  .content-section,
  .page-main,
  .detail-main {
    padding-left: 16px;
    padding-right: 16px;
  }

  .small-grid,
  .all-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
  }

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

  .card-body {
    padding: 12px;
  }

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

  .rank-row {
    grid-template-columns: 42px 50px 1fr;
  }

  .rank-action {
    display: none;
  }

  .detail-wrap {
    padding: 92px 18px 28px;
  }

  .detail-poster {
    max-width: 190px;
  }

  .player-shell {
    border-radius: 18px;
  }
}
