:root {
  --bg: #080d17;
  --bg-soft: #0f172a;
  --bg-card: rgba(15, 23, 42, 0.86);
  --line: rgba(148, 163, 184, 0.22);
  --text: #f8fafc;
  --muted: #cbd5e1;
  --soft: #94a3b8;
  --amber: #f59e0b;
  --amber-strong: #fbbf24;
  --red: #ef4444;
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.38);
  --radius: 24px;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--text);
  background:
    radial-gradient(circle at top left, rgba(245, 158, 11, 0.18), transparent 32rem),
    radial-gradient(circle at 80% 10%, rgba(59, 130, 246, 0.16), transparent 30rem),
    linear-gradient(180deg, #0f172a 0%, #080d17 38%, #030712 100%);
  min-height: 100vh;
}

body.no-scroll {
  overflow: hidden;
}

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

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

button,
input,
select {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid var(--line);
  background: rgba(15, 23, 42, 0.9);
  backdrop-filter: blur(18px);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.28);
}

.header-inner {
  width: min(1200px, calc(100% - 32px));
  min-height: 72px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 24px;
}

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

.brand-mark {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  color: #111827;
  background: linear-gradient(135deg, var(--amber-strong), #f97316);
  box-shadow: 0 14px 26px rgba(245, 158, 11, 0.28);
}

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

.brand-copy strong {
  font-size: 20px;
  letter-spacing: 0.04em;
}

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

.site-nav {
  display: flex;
  align-items: center;
  gap: 18px;
  justify-content: center;
  color: var(--muted);
}

.site-nav a,
.nav-dropdown > button {
  border: 0;
  color: inherit;
  cursor: pointer;
  background: transparent;
  padding: 9px 4px;
  transition: color 0.2s ease;
}

.site-nav a:hover,
.nav-dropdown > button:hover {
  color: var(--amber-strong);
}

.nav-dropdown {
  position: relative;
}

.nav-dropdown-panel {
  position: absolute;
  top: calc(100% + 12px);
  left: 50%;
  width: 210px;
  transform: translateX(-50%) translateY(8px);
  display: grid;
  gap: 2px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(15, 23, 42, 0.98);
  box-shadow: var(--shadow);
  opacity: 0;
  pointer-events: none;
  transition: all 0.2s ease;
}

.nav-dropdown:hover .nav-dropdown-panel,
.nav-dropdown:focus-within .nav-dropdown-panel {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
  pointer-events: auto;
}

.nav-dropdown-panel a {
  border-radius: 10px;
  padding: 10px 12px;
}

.nav-dropdown-panel a:hover {
  background: rgba(245, 158, 11, 0.14);
}

.nav-search {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 5px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(2, 6, 23, 0.42);
}

.nav-search input {
  width: 210px;
  border: 0;
  outline: 0;
  color: var(--text);
  background: transparent;
  padding: 8px 10px 8px 14px;
}

.nav-search input::placeholder {
  color: var(--soft);
}

.nav-search button,
.mobile-menu-button {
  border: 0;
  cursor: pointer;
  color: #111827;
  background: var(--amber-strong);
  border-radius: 999px;
  padding: 8px 14px;
  font-weight: 700;
}

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

main {
  overflow: hidden;
}

.hero {
  position: relative;
  min-height: calc(100vh - 72px);
  isolation: isolate;
}

.hero-background,
.hero-background-item,
.hero-overlay {
  position: absolute;
  inset: 0;
}

.hero-background-item {
  background-size: cover;
  background-position: center;
  opacity: 0;
  transform: scale(1.05);
  transition: opacity 0.8s ease, transform 4s ease;
}

.hero-background-item.is-active {
  opacity: 0.36;
  transform: scale(1);
}

.hero-overlay {
  background:
    linear-gradient(90deg, rgba(3, 7, 18, 0.96) 0%, rgba(15, 23, 42, 0.82) 48%, rgba(15, 23, 42, 0.42) 100%),
    radial-gradient(circle at 76% 18%, rgba(245, 158, 11, 0.24), transparent 24rem),
    linear-gradient(180deg, transparent 0%, rgba(3, 7, 18, 0.92) 96%);
  z-index: -1;
}

.hero-background {
  z-index: -2;
  background: linear-gradient(135deg, #111827, #020617);
}

.hero-inner {
  width: min(1200px, calc(100% - 32px));
  min-height: calc(100vh - 72px);
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(420px, 1.05fr);
  align-items: center;
  gap: 48px;
  padding: 72px 0;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--amber-strong);
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 12px;
  font-weight: 800;
}

.hero h1,
.page-hero h1,
.detail-copy h1 {
  margin: 18px 0;
  font-size: clamp(36px, 5vw, 72px);
  line-height: 1.04;
  letter-spacing: -0.05em;
}

.hero-copy p,
.page-hero p,
.detail-one-line {
  max-width: 620px;
  color: var(--muted);
  line-height: 1.9;
  font-size: 17px;
}

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

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

.button:hover {
  transform: translateY(-2px);
}

.button-primary {
  color: #111827;
  background: linear-gradient(135deg, var(--amber-strong), #f97316);
  box-shadow: 0 18px 40px rgba(245, 158, 11, 0.28);
}

.button-ghost {
  color: var(--text);
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.08);
}

.button-ghost:hover {
  border-color: rgba(251, 191, 36, 0.6);
  background: rgba(245, 158, 11, 0.12);
}

.hero-carousel {
  overflow: hidden;
  position: relative;
  min-height: 460px;
  border: 1px solid var(--line);
  border-radius: 32px;
  background: rgba(15, 23, 42, 0.58);
  box-shadow: var(--shadow);
  backdrop-filter: blur(16px);
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: 0.92fr 1fr;
  gap: 26px;
  align-items: end;
  padding: 26px;
  opacity: 0;
  transform: translateX(26px);
  transition: opacity 0.45s ease, transform 0.45s ease;
  pointer-events: none;
}

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

.hero-poster {
  height: 100%;
  min-height: 360px;
}

.poster-wrap {
  position: relative;
  display: block;
  overflow: hidden;
  border-radius: 22px;
  background:
    radial-gradient(circle at 30% 20%, rgba(245, 158, 11, 0.28), transparent 48%),
    linear-gradient(135deg, #1e293b, #020617);
}

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

.poster-wrap.cover-fallback img {
  opacity: 0;
}

.poster-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 30%, rgba(0, 0, 0, 0.68) 100%);
  pointer-events: none;
}

.hero-slide-copy {
  padding-bottom: 14px;
}

.hero-slide-copy h2 {
  margin: 12px 0 10px;
  font-size: clamp(28px, 3vw, 42px);
  line-height: 1.1;
}

.hero-slide-copy p {
  color: var(--muted);
  line-height: 1.8;
}

.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 16px 0 22px;
}

.tag {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  border: 1px solid rgba(251, 191, 36, 0.24);
  border-radius: 999px;
  color: #fde68a;
  background: rgba(245, 158, 11, 0.1);
  font-size: 12px;
}

.hero-controls {
  position: absolute;
  right: 24px;
  bottom: 22px;
  display: flex;
  align-items: center;
  gap: 12px;
  z-index: 3;
}

.hero-controls button {
  cursor: pointer;
  border: 1px solid var(--line);
  color: var(--text);
  background: rgba(2, 6, 23, 0.6);
  border-radius: 999px;
  width: 38px;
  height: 38px;
}

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

.hero-dot {
  width: 9px !important;
  height: 9px !important;
  padding: 0 !important;
  background: rgba(203, 213, 225, 0.38) !important;
}

.hero-dot.is-active {
  width: 28px !important;
  background: var(--amber-strong) !important;
}

.section-block,
.page-hero,
.detail-layout,
.player-section {
  width: min(1200px, calc(100% - 32px));
  margin: 0 auto;
}

.section-block {
  padding: 56px 0;
}

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

.section-heading h2 {
  margin: 8px 0 0;
  font-size: clamp(26px, 3vw, 42px);
}

.section-heading a {
  color: var(--amber-strong);
  font-weight: 800;
}

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

.category-tile,
.category-overview-card,
.hot-panel,
.detail-article,
.detail-side,
.player-card,
.search-page-box,
.filter-bar {
  border: 1px solid var(--line);
  background: var(--bg-card);
  box-shadow: 0 18px 60px rgba(0, 0, 0, 0.22);
  backdrop-filter: blur(14px);
}

.category-tile {
  min-height: 210px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  border-radius: var(--radius);
  padding: 20px;
  transition: transform 0.25s ease, border-color 0.25s ease;
}

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

.category-icon {
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border-radius: 16px;
  color: #111827;
  background: linear-gradient(135deg, var(--amber-strong), #fb7185);
  font-size: 22px;
  font-weight: 900;
}

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

.category-tile small {
  color: var(--muted);
  line-height: 1.7;
}

.category-tile em {
  color: var(--soft);
  font-size: 12px;
  font-style: normal;
  line-height: 1.6;
}

.section-split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 28px;
  align-items: start;
}

.hot-panel {
  position: sticky;
  top: 96px;
  border-radius: var(--radius);
  padding: 22px;
}

.compact-heading {
  display: block;
}

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

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

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

.movie-card:hover {
  transform: translateY(-6px);
  border-color: rgba(251, 191, 36, 0.46);
  box-shadow: 0 26px 60px rgba(0, 0, 0, 0.34);
}

.movie-card .poster-wrap {
  aspect-ratio: 16 / 9;
  border-radius: 0;
}

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

.year-badge,
.play-badge {
  position: absolute;
  z-index: 2;
  border-radius: 999px;
  padding: 6px 10px;
  font-size: 12px;
  font-weight: 800;
}

.year-badge {
  top: 12px;
  left: 12px;
  color: #111827;
  background: var(--amber-strong);
}

.play-badge {
  right: 12px;
  bottom: 12px;
  color: #fff;
  background: rgba(239, 68, 68, 0.88);
}

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

.movie-title {
  display: -webkit-box;
  min-height: 48px;
  overflow: hidden;
  color: #fff;
  font-size: 17px;
  font-weight: 900;
  line-height: 1.4;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.movie-title:hover {
  color: var(--amber-strong);
}

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

.movie-meta,
.rank-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: var(--soft);
  font-size: 12px;
}

.movie-meta span,
.rank-meta span {
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 999px;
  padding: 5px 8px;
  background: rgba(2, 6, 23, 0.28);
}

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

.rank-item {
  display: grid;
  grid-template-columns: auto 84px minmax(0, 1fr);
  gap: 14px;
  align-items: center;
  border: 1px solid rgba(148, 163, 184, 0.14);
  border-radius: 18px;
  padding: 12px;
  background: rgba(2, 6, 23, 0.28);
}

.rank-list-large .rank-item {
  grid-template-columns: auto 130px minmax(0, 1fr);
  padding: 16px;
}

.rank-index {
  color: var(--amber-strong);
  font-size: 18px;
  font-weight: 900;
}

.rank-cover {
  display: block;
  overflow: hidden;
  border-radius: 14px;
  aspect-ratio: 16 / 10;
  background: linear-gradient(135deg, #1e293b, #020617);
}

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

.rank-title {
  color: #fff;
  font-weight: 900;
}

.rank-copy p {
  display: -webkit-box;
  margin: 8px 0;
  overflow: hidden;
  color: var(--muted);
  line-height: 1.6;
  font-size: 14px;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.page-hero {
  padding: 64px 0 20px;
}

.small-hero > div {
  border: 1px solid var(--line);
  border-radius: 34px;
  padding: clamp(28px, 5vw, 54px);
  background:
    radial-gradient(circle at 82% 20%, rgba(245, 158, 11, 0.16), transparent 20rem),
    linear-gradient(135deg, rgba(15, 23, 42, 0.96), rgba(2, 6, 23, 0.82));
  box-shadow: var(--shadow);
}

.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 18px;
  color: var(--soft);
  font-size: 14px;
}

.breadcrumbs a:hover {
  color: var(--amber-strong);
}

.filter-bar,
.search-page-box {
  display: flex;
  gap: 12px;
  align-items: center;
  margin-bottom: 24px;
  border-radius: 22px;
  padding: 14px;
}

.filter-bar input,
.search-page-box input,
.filter-bar select,
.search-page-box select {
  min-height: 48px;
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 999px;
  outline: 0;
  color: var(--text);
  background: rgba(2, 6, 23, 0.42);
  padding: 0 18px;
}

.filter-bar input,
.search-page-box input {
  flex: 1;
}

.filter-bar select,
.search-page-box select {
  width: 180px;
}

.empty-state {
  border: 1px dashed rgba(251, 191, 36, 0.32);
  border-radius: 20px;
  padding: 28px;
  color: var(--muted);
  text-align: center;
}

.category-overview {
  width: min(1200px, calc(100% - 32px));
  margin: 0 auto;
  padding: 32px 0 64px;
  display: grid;
  gap: 24px;
}

.category-overview-card {
  border-radius: 30px;
  padding: 26px;
}

.category-overview-head {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  align-items: center;
  margin-bottom: 20px;
}

.category-overview-head h2 {
  margin: 8px 0;
}

.category-overview-head p {
  color: var(--muted);
  line-height: 1.8;
}

.detail-hero {
  position: relative;
  isolation: isolate;
  padding: 64px 0 36px;
}

.detail-backdrop {
  position: absolute;
  inset: 0;
  z-index: -2;
  background-size: cover;
  background-position: center;
  opacity: 0.26;
  filter: blur(8px);
  transform: scale(1.05);
}

.detail-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(180deg, rgba(3, 7, 18, 0.84), rgba(3, 7, 18, 0.98));
}

.detail-inner {
  width: min(1200px, calc(100% - 32px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: 330px minmax(0, 1fr);
  gap: 38px;
  align-items: center;
}

.detail-poster {
  aspect-ratio: 3 / 4;
  box-shadow: var(--shadow);
}

.detail-copy h1 {
  margin-bottom: 16px;
}

.player-section {
  padding: 18px 0 52px;
}

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

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

.player-overlay {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: grid;
  place-items: center;
  gap: 12px;
  cursor: pointer;
  border: 0;
  color: #fff;
  background: radial-gradient(circle, rgba(245, 158, 11, 0.16), rgba(0, 0, 0, 0.62));
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

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

.play-circle {
  width: 76px;
  height: 76px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  color: #111827;
  background: var(--amber-strong);
  box-shadow: 0 22px 50px rgba(245, 158, 11, 0.35);
}

.player-status {
  position: absolute;
  left: 18px;
  bottom: 14px;
  z-index: 3;
  margin: 0;
  color: var(--muted);
  background: rgba(2, 6, 23, 0.7);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 8px 12px;
  font-size: 12px;
}

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

.detail-article,
.detail-side {
  border-radius: 30px;
  padding: clamp(22px, 4vw, 34px);
}

.detail-article h2,
.detail-side h2 {
  margin: 26px 0 14px;
  font-size: 26px;
}

.detail-article h2:first-of-type,
.detail-side h2:first-child {
  margin-top: 0;
}

.detail-article p {
  color: var(--muted);
  line-height: 2;
  font-size: 16px;
}

.info-table {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 28px;
}

.info-table dl {
  margin: 0;
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 16px;
  padding: 14px;
  background: rgba(2, 6, 23, 0.28);
}

.info-table dt {
  color: var(--soft);
  font-size: 12px;
  margin-bottom: 6px;
}

.info-table dd {
  margin: 0;
  color: #fff;
  font-weight: 700;
}

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

.footer-inner {
  width: min(1200px, calc(100% - 32px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: 0.8fr 1.2fr;
  gap: 32px;
  padding: 36px 0;
}

.footer-brand strong {
  font-size: 22px;
}

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

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 20px;
  justify-content: flex-end;
  align-content: start;
  color: var(--muted);
}

.footer-links a:hover {
  color: var(--amber-strong);
}

[hidden] {
  display: none !important;
}

@media (max-width: 1080px) {
  .header-inner {
    grid-template-columns: auto auto;
  }

  .mobile-menu-button {
    display: inline-flex;
    justify-self: end;
  }

  .site-nav,
  .nav-search {
    display: none;
  }

  .site-nav.is-open,
  .nav-search.is-open {
    display: grid;
    grid-column: 1 / -1;
    width: 100%;
    justify-content: stretch;
  }

  .site-nav.is-open {
    gap: 6px;
    padding-bottom: 8px;
  }

  .nav-dropdown-panel {
    position: static;
    width: 100%;
    transform: none;
    opacity: 1;
    pointer-events: auto;
    margin-top: 6px;
  }

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

  .hot-panel {
    position: static;
  }

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

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

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

  .footer-links {
    justify-content: flex-start;
  }
}

@media (max-width: 760px) {
  .hero-inner {
    padding: 38px 0;
  }

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

  .hero-slide {
    grid-template-columns: 1fr;
    align-items: start;
  }

  .hero-poster {
    min-height: 280px;
  }

  .hero-controls {
    left: 24px;
    right: auto;
  }

  .category-grid,
  .movie-grid,
  .movie-grid-compact {
    grid-template-columns: 1fr;
  }

  .section-heading,
  .category-overview-head,
  .filter-bar,
  .search-page-box {
    align-items: stretch;
    flex-direction: column;
  }

  .filter-bar select,
  .search-page-box select {
    width: 100%;
  }

  .rank-item,
  .rank-list-large .rank-item {
    grid-template-columns: auto 92px minmax(0, 1fr);
  }

  .detail-inner {
    gap: 24px;
  }

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

  .info-table {
    grid-template-columns: 1fr;
  }
}
