:root {
  --bg: #020617;
  --bg-soft: #0f172a;
  --panel: rgba(15, 23, 42, 0.76);
  --panel-solid: #111827;
  --border: rgba(148, 163, 184, 0.18);
  --text: #f8fafc;
  --muted: #94a3b8;
  --muted-strong: #cbd5e1;
  --accent: #fbbf24;
  --accent-deep: #f59e0b;
  --rose: #fb7185;
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.38);
  color-scheme: dark;
}

* {
  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;
  color: var(--text);
  background:
    radial-gradient(circle at 18% 0%, rgba(245, 158, 11, 0.16), transparent 28rem),
    radial-gradient(circle at 100% 12%, rgba(244, 63, 94, 0.11), transparent 30rem),
    linear-gradient(180deg, #020617 0%, #0f172a 48%, #020617 100%);
}

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

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

button,
input,
select {
  font: inherit;
}

main {
  min-height: 70vh;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  border-bottom: 1px solid var(--border);
  background: rgba(2, 6, 23, 0.78);
  backdrop-filter: blur(18px);
}

.nav-wrap {
  width: min(1240px, calc(100% - 32px));
  margin: 0 auto;
  min-height: 72px;
  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 {
  font-size: 22px;
}

.brand-mark {
  width: 36px;
  height: 36px;
  display: inline-grid;
  place-items: center;
  border-radius: 14px;
  color: #111827;
  background: linear-gradient(135deg, var(--accent), #fde68a);
  box-shadow: 0 0 32px rgba(251, 191, 36, 0.32);
}

.nav-panel {
  display: flex;
  align-items: center;
  gap: 28px;
  flex: 1;
  justify-content: flex-end;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 26px;
  color: var(--muted-strong);
  font-weight: 700;
}

.nav-links a {
  transition: color 0.2s ease;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--accent);
}

.site-search {
  display: flex;
  align-items: center;
  min-width: 300px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.7);
  overflow: hidden;
}

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

.site-search input::placeholder {
  color: #64748b;
}

.site-search button {
  border: 0;
  cursor: pointer;
  color: #111827;
  font-weight: 800;
  padding: 11px 18px;
  background: linear-gradient(135deg, var(--accent), var(--accent-deep));
}

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

.nav-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  margin: 5px auto;
  border-radius: 999px;
  background: var(--text);
}

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

.hero {
  padding: 42px 0 28px;
}

.hero-title-block {
  max-width: 900px;
  margin-bottom: 24px;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--accent);
  font-size: 13px;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.hero-title-block h1,
.page-hero h1 {
  margin: 12px 0 14px;
  font-size: clamp(34px, 5vw, 66px);
  line-height: 1.05;
  letter-spacing: -0.06em;
}

.hero-title-block p,
.page-hero p,
.section-head p,
.quick-panel p {
  color: var(--muted-strong);
  line-height: 1.8;
}

.hero-stage {
  position: relative;
  overflow: hidden;
  min-height: 560px;
  border: 1px solid var(--border);
  border-radius: 34px;
  background: #020617;
  box-shadow: var(--shadow);
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(260px, 0.62fr);
  gap: 36px;
  align-items: center;
  min-height: 560px;
  padding: clamp(28px, 5vw, 64px);
  opacity: 0;
  pointer-events: none;
  transform: scale(1.02);
  transition: opacity 0.55s ease, transform 0.55s ease;
}

.hero-slide::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(2, 6, 23, 0.96) 0%, rgba(2, 6, 23, 0.72) 46%, rgba(2, 6, 23, 0.28) 100%),
    linear-gradient(180deg, rgba(2, 6, 23, 0.12), rgba(2, 6, 23, 0.98)),
    var(--hero-bg) center / cover no-repeat;
  filter: saturate(1.08);
}

.hero-slide::after {
  content: "";
  position: absolute;
  inset: auto 9% -20% auto;
  width: 360px;
  height: 360px;
  border-radius: 999px;
  background: rgba(251, 191, 36, 0.18);
  filter: blur(54px);
}

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

.hero-copy,
.hero-poster {
  position: relative;
  z-index: 2;
}

.hero-copy h2 {
  margin: 14px 0 18px;
  max-width: 760px;
  font-size: clamp(34px, 5vw, 72px);
  line-height: 0.98;
  letter-spacing: -0.06em;
}

.hero-copy p {
  max-width: 720px;
  color: #dbeafe;
  font-size: 18px;
  line-height: 1.85;
}

.hero-tags,
.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.hero-tags span,
.tag-row span {
  display: inline-flex;
  align-items: center;
  border: 1px solid rgba(251, 191, 36, 0.24);
  border-radius: 999px;
  color: #fde68a;
  background: rgba(251, 191, 36, 0.09);
}

.hero-tags span {
  padding: 8px 12px;
}

.tag-row span {
  padding: 5px 9px;
  font-size: 12px;
}

.hero-actions,
.page-actions,
.detail-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 26px;
}

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

.btn:hover,
.section-link:hover,
.movie-card:hover,
.category-tile:hover,
.ranking-item:hover {
  transform: translateY(-3px);
}

.btn.primary,
.section-link {
  color: #111827;
  background: linear-gradient(135deg, var(--accent), var(--accent-deep));
  box-shadow: 0 12px 32px rgba(251, 191, 36, 0.23);
}

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

.hero-poster {
  justify-self: end;
  width: min(360px, 100%);
  aspect-ratio: 2 / 3;
  border: 1px solid rgba(251, 191, 36, 0.34);
  border-radius: 28px;
  overflow: hidden;
  background: linear-gradient(135deg, rgba(251, 191, 36, 0.16), rgba(15, 23, 42, 0.88));
  box-shadow: 0 32px 90px rgba(0, 0, 0, 0.48);
}

.hero-poster img,
.poster-link img,
.ranking-cover img,
.detail-side img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-controls {
  margin-top: 18px;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 18px;
}

.hero-controls button,
.hero-dots button {
  border: 0;
  cursor: pointer;
}

.hero-controls > button {
  width: 44px;
  height: 44px;
  border-radius: 999px;
  color: var(--text);
  background: rgba(15, 23, 42, 0.92);
  border: 1px solid var(--border);
  font-size: 28px;
}

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

.hero-dots button {
  width: 26px;
  height: 8px;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.35);
}

.hero-dots button.is-active {
  width: 42px;
  background: var(--accent);
}

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

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

.section-head h2,
.quick-panel h2,
.detail-article h2 {
  margin: 8px 0 0;
  font-size: clamp(26px, 3vw, 38px);
  letter-spacing: -0.04em;
}

.section-head p {
  max-width: 760px;
  margin: 10px 0 0;
}

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

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

.movie-card {
  display: flex;
  flex-direction: column;
  min-width: 0;
  border: 1px solid var(--border);
  border-radius: 24px;
  overflow: hidden;
  background: rgba(15, 23, 42, 0.62);
  box-shadow: 0 16px 46px rgba(0, 0, 0, 0.22);
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.movie-card:hover {
  border-color: rgba(251, 191, 36, 0.38);
  box-shadow: 0 22px 60px rgba(0, 0, 0, 0.34);
}

.poster-link {
  position: relative;
  display: block;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  background: linear-gradient(135deg, rgba(251, 191, 36, 0.14), rgba(15, 23, 42, 0.96));
}

.poster-link img {
  transition: transform 0.32s ease;
}

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

.poster-badge {
  position: absolute;
  left: 10px;
  top: 10px;
  padding: 5px 9px;
  border-radius: 999px;
  color: #111827;
  background: var(--accent);
  font-size: 12px;
  font-weight: 900;
}

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

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

.card-meta span + span::before {
  content: "·";
  margin-right: 8px;
  color: #475569;
}

.movie-card h3 {
  margin: 10px 0 8px;
  font-size: 17px;
  line-height: 1.35;
}

.movie-card h3 a:hover,
.ranking-content a:hover,
.detail-side a:hover {
  color: var(--accent);
}

.movie-card p {
  margin: 0 0 12px;
  color: var(--muted-strong);
  font-size: 13px;
  line-height: 1.65;
}

.tag-row {
  margin-top: auto;
}

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

.quick-panel,
.filter-panel,
.detail-article,
.detail-side,
.page-hero,
.category-tile,
.ranking-item {
  border: 1px solid var(--border);
  background: var(--panel);
  box-shadow: 0 18px 54px rgba(0, 0, 0, 0.22);
}

.quick-panel {
  position: sticky;
  top: 96px;
  border-radius: 28px;
  padding: 28px;
}

.quick-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}

.quick-links a,
.footer-links a {
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 8px 12px;
  color: var(--muted-strong);
  background: rgba(15, 23, 42, 0.5);
}

.quick-links a:hover,
.footer-links a:hover {
  color: var(--accent);
  border-color: rgba(251, 191, 36, 0.34);
}

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

.ranking-list.small .ranking-item {
  grid-template-columns: 46px 70px minmax(0, 1fr);
}

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

.ranking-item {
  display: grid;
  grid-template-columns: 54px 88px minmax(0, 1fr);
  gap: 14px;
  align-items: center;
  border-radius: 22px;
  padding: 12px;
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.ranking-number {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  color: #111827;
  background: linear-gradient(135deg, var(--accent), var(--accent-deep));
  font-weight: 950;
}

.ranking-cover {
  display: block;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  border-radius: 14px;
  background: var(--bg-soft);
}

.ranking-content h3 {
  margin: 0 0 7px;
  font-size: 17px;
}

.ranking-content p {
  margin: 0;
  color: var(--muted-strong);
  line-height: 1.65;
  font-size: 13px;
}

.page-hero {
  margin-top: 42px;
  padding: clamp(28px, 5vw, 54px);
  border-radius: 30px;
}

.simple-hero,
.category-hero {
  background:
    radial-gradient(circle at 90% 18%, rgba(251, 191, 36, 0.18), transparent 24rem),
    linear-gradient(135deg, rgba(15, 23, 42, 0.96), rgba(30, 41, 59, 0.74));
}

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

.category-tile {
  min-height: 220px;
  padding: 22px;
  border-radius: 26px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.category-tile:hover {
  border-color: rgba(251, 191, 36, 0.34);
}

.category-icon {
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border-radius: 18px;
  color: #111827;
  background: linear-gradient(135deg, var(--accent), #fde68a);
  font-weight: 950;
}

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

.category-tile p,
.category-tile em {
  color: var(--muted-strong);
  line-height: 1.65;
  font-style: normal;
}

.category-tile em {
  margin-top: auto;
  font-size: 13px;
  color: var(--accent);
}

.filter-panel {
  width: min(1240px, calc(100% - 32px));
  margin: 24px auto 0;
  border-radius: 24px;
  padding: 18px;
  display: grid;
  grid-template-columns: 2fr repeat(3, 1fr);
  gap: 14px;
}

.filter-panel label {
  display: grid;
  gap: 8px;
  color: var(--muted-strong);
  font-size: 13px;
  font-weight: 800;
}

.filter-panel input,
.filter-panel select {
  width: 100%;
  min-height: 44px;
  border: 1px solid var(--border);
  border-radius: 14px;
  outline: 0;
  color: var(--text);
  background: rgba(2, 6, 23, 0.48);
  padding: 0 12px;
}

.empty-state {
  width: min(1240px, calc(100% - 32px));
  margin: 24px auto 0;
  padding: 22px;
  border: 1px solid var(--border);
  border-radius: 20px;
  color: var(--muted-strong);
  background: rgba(15, 23, 42, 0.72);
}

.detail-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.18fr) minmax(320px, 0.82fr);
  gap: 28px;
  align-items: stretch;
  padding: 42px 0 24px;
}

.player-shell {
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border: 1px solid rgba(251, 191, 36, 0.24);
  border-radius: 30px;
  background: #000;
  box-shadow: var(--shadow);
}

.player-shell video {
  width: 100%;
  height: 100%;
  display: block;
  background: #000;
}

.play-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  border: 0;
  cursor: pointer;
  color: #111827;
  background: radial-gradient(circle, rgba(2, 6, 23, 0.12), rgba(2, 6, 23, 0.58));
  transition: opacity 0.22s ease, visibility 0.22s ease;
}

.play-overlay span {
  width: 88px;
  height: 88px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--accent), #fde68a);
  box-shadow: 0 18px 60px rgba(251, 191, 36, 0.34);
  font-size: 34px;
  text-indent: 5px;
}

.play-overlay.is-hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.detail-copy {
  border: 1px solid var(--border);
  border-radius: 30px;
  padding: clamp(24px, 4vw, 42px);
  background:
    radial-gradient(circle at 100% 0%, rgba(251, 191, 36, 0.18), transparent 22rem),
    rgba(15, 23, 42, 0.74);
}

.detail-copy h1 {
  margin: 12px 0 16px;
  font-size: clamp(34px, 4.8vw, 58px);
  line-height: 1.05;
  letter-spacing: -0.05em;
}

.detail-one-line {
  color: var(--muted-strong);
  line-height: 1.85;
  font-size: 17px;
}

.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 24px;
  align-items: start;
  padding: 18px 0 32px;
}

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

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

.detail-side {
  position: sticky;
  top: 96px;
}

.detail-side img {
  aspect-ratio: 2 / 3;
  border-radius: 20px;
  overflow: hidden;
  background: var(--bg-soft);
}

.detail-side dl {
  display: grid;
  gap: 12px;
  margin: 18px 0 0;
}

.detail-side dl div {
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr);
  gap: 12px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border);
}

.detail-side dt {
  color: var(--muted);
}

.detail-side dd {
  margin: 0;
  color: var(--muted-strong);
}

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

.footer-inner {
  width: min(1240px, calc(100% - 32px));
  margin: 0 auto;
  padding: 34px 0;
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: 28px;
}

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

.footer-inner p {
  max-width: 560px;
  color: var(--muted-strong);
  line-height: 1.8;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  align-content: start;
  gap: 10px;
  justify-content: flex-end;
}

.footer-bottom {
  width: min(1240px, calc(100% - 32px));
  margin: 0 auto;
  padding: 18px 0 28px;
  color: var(--muted);
  font-size: 13px;
}

[hidden] {
  display: none !important;
}

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

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

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

  .quick-panel,
  .detail-side {
    position: static;
  }
}

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

  .nav-panel {
    position: absolute;
    left: 16px;
    right: 16px;
    top: 78px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 18px;
    padding: 18px;
    border: 1px solid var(--border);
    border-radius: 22px;
    background: rgba(2, 6, 23, 0.96);
    box-shadow: var(--shadow);
  }

  body.nav-open .nav-panel {
    display: flex;
  }

  .nav-links {
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
  }

  .site-search {
    min-width: 0;
    width: 100%;
  }

  .hero-stage,
  .hero-slide {
    min-height: 720px;
  }

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

  .hero-poster {
    justify-self: start;
    width: min(260px, 70vw);
  }

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

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

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

@media (max-width: 640px) {
  .nav-wrap,
  .hero,
  .page-hero,
  .content-section,
  .detail-hero,
  .detail-layout,
  .filter-panel,
  .empty-state,
  .footer-inner,
  .footer-bottom {
    width: min(100% - 22px, 1240px);
  }

  .brand {
    font-size: 18px;
  }

  .hero-title-block h1,
  .page-hero h1 {
    font-size: 34px;
  }

  .hero-stage,
  .hero-slide {
    min-height: 680px;
  }

  .hero-slide {
    padding: 24px;
  }

  .hero-copy h2 {
    font-size: 40px;
  }

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

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

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

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

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

  .ranking-item,
  .ranking-list.small .ranking-item {
    grid-template-columns: 42px 64px minmax(0, 1fr);
    gap: 10px;
  }

  .ranking-number {
    width: 36px;
    height: 36px;
    border-radius: 12px;
    font-size: 13px;
  }

  .detail-copy,
  .detail-article,
  .detail-side,
  .page-hero {
    border-radius: 22px;
  }
}
