:root {
  --bg: #09080f;
  --bg-soft: #12101c;
  --panel: rgba(21, 18, 32, 0.86);
  --panel-strong: #171321;
  --line: rgba(255, 255, 255, 0.08);
  --text: #f7f2e8;
  --muted: #b6ad9e;
  --dim: #827a70;
  --gold: #f7b733;
  --gold-dark: #c27b14;
  --red: #d44834;
  --green: #41c27a;
  --shadow: 0 24px 60px rgba(0, 0, 0, 0.42);
  --radius: 22px;
  color-scheme: dark;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at top left, rgba(247, 183, 51, 0.18), transparent 34rem),
    radial-gradient(circle at 85% 12%, rgba(212, 72, 52, 0.12), transparent 30rem),
    linear-gradient(180deg, #08070c 0%, #11101a 42%, #08070c 100%);
  color: var(--text);
  font-family: "Inter", "PingFang SC", "Microsoft YaHei", "Noto Sans CJK SC", Arial, sans-serif;
  line-height: 1.7;
}

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: 100;
  background: rgba(9, 8, 15, 0.82);
  backdrop-filter: blur(18px);
  border-bottom: 1px solid var(--line);
}

.header-inner {
  max-width: 1260px;
  margin: 0 auto;
  padding: 14px 20px;
  display: flex;
  align-items: center;
  gap: 22px;
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 900;
  letter-spacing: 0.08em;
  white-space: nowrap;
}

.logo-mark {
  width: 38px;
  height: 38px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, var(--gold), var(--red));
  color: #1c1003;
  box-shadow: 0 12px 32px rgba(247, 183, 51, 0.26);
}

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

.nav-links a {
  color: var(--muted);
  padding: 9px 13px;
  border-radius: 999px;
  transition: color 0.2s ease, background 0.2s ease;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--text);
  background: rgba(247, 183, 51, 0.14);
}

.global-search {
  display: flex;
  align-items: center;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 4px;
  min-width: 250px;
}

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

.global-search button,
.mobile-menu-button,
.action-button,
.filter-button,
.play-button {
  border: 0;
  color: #1d1204;
  background: linear-gradient(135deg, var(--gold), #ffde7a);
  border-radius: 999px;
  padding: 9px 15px;
  font-weight: 800;
  box-shadow: 0 10px 26px rgba(247, 183, 51, 0.22);
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.global-search button:hover,
.mobile-menu-button:hover,
.action-button:hover,
.filter-button:hover,
.play-button:hover {
  transform: translateY(-1px);
  box-shadow: 0 16px 32px rgba(247, 183, 51, 0.30);
}

.mobile-menu-button {
  display: none;
  padding: 8px 12px;
}

main {
  overflow: hidden;
}

.container {
  max-width: 1260px;
  margin: 0 auto;
  padding: 0 20px;
}

.hero {
  position: relative;
  min-height: 690px;
  display: flex;
  align-items: center;
  overflow: hidden;
  border-bottom: 1px solid var(--line);
}

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

.hero-slide.active {
  display: block;
  animation: heroFade 0.8s ease both;
}

@keyframes heroFade {
  from {
    opacity: 0.18;
    transform: scale(1.015);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

.hero-bg {
  position: absolute;
  inset: -4% -4% 0 -4%;
  background-size: cover;
  background-position: center;
  filter: blur(2px) saturate(1.1);
  opacity: 0.38;
  transform: scale(1.03);
}

.hero-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(8, 7, 12, 0.95) 0%, rgba(8, 7, 12, 0.76) 42%, rgba(8, 7, 12, 0.22) 100%),
    linear-gradient(0deg, rgba(8, 7, 12, 1) 0%, transparent 38%, rgba(8, 7, 12, 0.42) 100%);
}

.hero-content {
  position: relative;
  z-index: 2;
  min-height: 690px;
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) 430px;
  align-items: center;
  gap: 46px;
}

.hero-copy {
  padding: 96px 0 90px;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--gold);
  background: rgba(247, 183, 51, 0.12);
  border: 1px solid rgba(247, 183, 51, 0.24);
  border-radius: 999px;
  padding: 7px 12px;
  margin-bottom: 20px;
  font-size: 14px;
}

.hero h1 {
  margin: 0;
  max-width: 760px;
  font-size: clamp(40px, 7vw, 78px);
  line-height: 1.04;
  letter-spacing: -0.06em;
  text-shadow: 0 20px 54px rgba(0, 0, 0, 0.48);
}

.hero p {
  max-width: 720px;
  margin: 20px 0 0;
  color: #ddd4c8;
  font-size: 18px;
}

.hero-meta,
.movie-meta,
.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin: 18px 0 0;
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: #f7e4be;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 5px 10px;
  font-size: 13px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  margin-top: 30px;
}

.ghost-button {
  color: var(--text);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 999px;
  padding: 10px 16px;
  background: rgba(255, 255, 255, 0.08);
  transition: background 0.2s ease, transform 0.2s ease;
}

.ghost-button:hover {
  background: rgba(255, 255, 255, 0.14);
  transform: translateY(-1px);
}

.hero-poster-wrap {
  position: relative;
  justify-self: end;
}

.hero-poster-wrap::before {
  content: "";
  position: absolute;
  inset: 32px -22px -22px 22px;
  border: 1px solid rgba(247, 183, 51, 0.34);
  border-radius: 30px;
}

.hero-poster {
  position: relative;
  width: 370px;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  border-radius: 30px;
  box-shadow: var(--shadow);
  border: 1px solid rgba(255, 255, 255, 0.16);
}

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

.hero-dot {
  width: 34px;
  height: 6px;
  border: 0;
  padding: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.28);
  cursor: pointer;
}

.hero-dot.active {
  background: var(--gold);
}

.section {
  padding: 72px 0 0;
}

.section.compact {
  padding-top: 42px;
}

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

.section-title {
  margin: 0;
  font-size: clamp(26px, 3vw, 40px);
  line-height: 1.2;
}

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

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

.movie-card {
  position: relative;
  display: flex;
  flex-direction: column;
  min-width: 0;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 18px;
  overflow: hidden;
  box-shadow: 0 16px 34px rgba(0, 0, 0, 0.22);
  transition: transform 0.22s ease, border-color 0.22s ease, box-shadow 0.22s ease;
}

.movie-card:hover {
  transform: translateY(-5px);
  border-color: rgba(247, 183, 51, 0.32);
  box-shadow: 0 24px 42px rgba(0, 0, 0, 0.30);
}

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

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

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

.quality-badge,
.rank-badge,
.type-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  z-index: 2;
  color: #1c1003;
  background: linear-gradient(135deg, var(--gold), #ffe49c);
  border-radius: 999px;
  padding: 4px 8px;
  font-size: 12px;
  font-weight: 900;
}

.type-badge {
  left: auto;
  right: 10px;
  color: #fff;
  background: rgba(0, 0, 0, 0.46);
  border: 1px solid rgba(255, 255, 255, 0.16);
}

.movie-card-body {
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex: 1;
  padding: 13px 13px 15px;
}

.movie-title {
  margin: 0;
  font-size: 16px;
  line-height: 1.35;
}

.movie-title a:hover {
  color: var(--gold);
}

.movie-desc {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
}

.muted {
  color: var(--muted);
}

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

.category-card {
  min-height: 170px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  background:
    radial-gradient(circle at top right, rgba(247, 183, 51, 0.16), transparent 58%),
    var(--panel);
  border: 1px solid var(--line);
  border-radius: 24px;
  padding: 20px;
  box-shadow: 0 16px 38px rgba(0, 0, 0, 0.20);
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.category-card:hover {
  transform: translateY(-4px);
  border-color: rgba(247, 183, 51, 0.32);
}

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

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

.category-count {
  color: var(--gold);
  font-weight: 900;
}

.page-hero {
  padding: 76px 0 34px;
  background:
    radial-gradient(circle at 20% 0%, rgba(247, 183, 51, 0.16), transparent 34rem),
    linear-gradient(180deg, rgba(255, 255, 255, 0.03), transparent);
  border-bottom: 1px solid var(--line);
}

.page-hero h1 {
  margin: 0;
  font-size: clamp(34px, 5vw, 58px);
  letter-spacing: -0.04em;
}

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

.filter-panel {
  margin: 26px 0 28px;
  display: grid;
  grid-template-columns: minmax(220px, 1fr) 170px 170px auto;
  gap: 12px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 22px;
  padding: 12px;
}

.filter-panel input,
.filter-panel select {
  width: 100%;
  border: 1px solid var(--line);
  outline: 0;
  color: var(--text);
  background: rgba(255, 255, 255, 0.06);
  border-radius: 16px;
  padding: 11px 12px;
}

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

.detail-poster {
  position: sticky;
  top: 88px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 28px;
  padding: 14px;
  box-shadow: var(--shadow);
}

.detail-poster img {
  width: 100%;
  border-radius: 20px;
  aspect-ratio: 2 / 3;
  object-fit: cover;
}

.detail-content {
  min-width: 0;
}

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

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

.detail-content h1 {
  margin: 0;
  font-size: clamp(34px, 5vw, 60px);
  line-height: 1.1;
  letter-spacing: -0.05em;
}

.detail-lead {
  color: #eadfcd;
  margin: 18px 0 0;
  font-size: 18px;
}

.player-card {
  margin-top: 30px;
  background: #050407;
  border: 1px solid rgba(247, 183, 51, 0.22);
  border-radius: 28px;
  overflow: hidden;
  box-shadow: var(--shadow);
}

.player-stage {
  position: relative;
  aspect-ratio: 16 / 9;
  background:
    radial-gradient(circle at center, rgba(247, 183, 51, 0.18), transparent 34%),
    #050407;
}

.player-stage video {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #000;
}

.player-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.12), rgba(0, 0, 0, 0.62));
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

.player-overlay.hidden {
  opacity: 0;
  visibility: hidden;
}

.play-button {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 22px;
  font-size: 17px;
}

.player-status {
  padding: 12px 16px;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.04);
  border-top: 1px solid var(--line);
}

.article-block {
  margin-top: 28px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 24px;
  padding: 24px;
}

.article-block h2 {
  margin: 0 0 12px;
  font-size: 24px;
}

.article-block p {
  margin: 0;
  color: #d8cec0;
  white-space: pre-wrap;
}

.ranking-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.ranking-row {
  display: grid;
  grid-template-columns: 46px 72px minmax(0, 1fr);
  gap: 13px;
  align-items: center;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 10px;
}

.ranking-row:hover {
  border-color: rgba(247, 183, 51, 0.32);
}

.ranking-number {
  color: var(--gold);
  font-size: 22px;
  font-weight: 900;
  text-align: center;
}

.ranking-thumb {
  width: 72px;
  height: 96px;
  object-fit: cover;
  border-radius: 12px;
}

.search-results-note {
  color: var(--muted);
  margin-bottom: 18px;
}

.empty-state {
  padding: 46px;
  text-align: center;
  color: var(--muted);
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 24px;
}

.site-footer {
  margin-top: 86px;
  border-top: 1px solid var(--line);
  background: rgba(0, 0, 0, 0.22);
}

.footer-inner {
  max-width: 1260px;
  margin: 0 auto;
  padding: 34px 20px;
  color: var(--muted);
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 18px;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

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

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

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

@media (max-width: 980px) {
  .header-inner {
    flex-wrap: wrap;
  }

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

  .nav-links {
    display: none;
    width: 100%;
    order: 4;
    flex-direction: column;
    align-items: stretch;
    margin-left: 0;
  }

  .nav-links.open {
    display: flex;
  }

  .global-search {
    order: 3;
    width: 100%;
  }

  .hero-content {
    grid-template-columns: 1fr;
    gap: 20px;
    padding-top: 58px;
  }

  .hero-poster-wrap {
    display: none;
  }

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

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

  .detail-poster {
    position: relative;
    top: auto;
    max-width: 360px;
  }

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

  .ranking-list {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 680px) {
  .container,
  .header-inner,
  .footer-inner {
    padding-left: 14px;
    padding-right: 14px;
  }

  .hero,
  .hero-content {
    min-height: 620px;
  }

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

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

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

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

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

  .movie-title {
    font-size: 15px;
  }

  .article-block {
    padding: 18px;
  }
}
