:root {
  color-scheme: dark;
  --page-bg: #05070b;
  --panel-bg: rgba(13, 18, 28, 0.78);
  --panel-strong: rgba(16, 24, 39, 0.94);
  --line: rgba(148, 163, 184, 0.18);
  --text: #f8fafc;
  --muted: #94a3b8;
  --soft: #cbd5e1;
  --brand: #10b981;
  --brand-2: #34d399;
  --brand-dark: #064e3b;
  --gold: #f59e0b;
  --radius: 24px;
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.35);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--text);
  background:
    radial-gradient(circle at top left, rgba(16, 185, 129, 0.22), transparent 34rem),
    radial-gradient(circle at 78% 10%, rgba(59, 130, 246, 0.16), transparent 30rem),
    linear-gradient(180deg, #080b12 0%, var(--page-bg) 48%, #02040a 100%);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
}

body.no-scroll {
  overflow: hidden;
}

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

img {
  max-width: 100%;
}

.site-shell {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid var(--line);
  background: rgba(5, 7, 11, 0.82);
  backdrop-filter: blur(22px);
}

.navbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 72px;
  gap: 18px;
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 900;
  letter-spacing: -0.04em;
  font-size: 1.18rem;
}

.logo-mark {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 15px;
  background: linear-gradient(135deg, var(--brand), #047857);
  box-shadow: 0 12px 34px rgba(16, 185, 129, 0.28);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 4px;
  color: var(--soft);
  font-size: 0.94rem;
}

.nav-links a {
  padding: 10px 14px;
  border-radius: 999px;
  transition: color 0.2s ease, background 0.2s ease;
}

.nav-links a:hover,
.nav-links a.is-active {
  color: #fff;
  background: rgba(16, 185, 129, 0.13);
}

.nav-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 1px solid var(--line);
  border-radius: 14px;
  color: #fff;
  background: rgba(255,255,255,0.06);
}

.nav-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  margin: 4px auto;
  background: currentColor;
  border-radius: 999px;
}

.hero {
  position: relative;
  overflow: hidden;
  min-height: 680px;
  border-bottom: 1px solid var(--line);
}

.hero-stage {
  position: relative;
  padding: 42px 0 54px;
}

.hero-slide {
  position: relative;
  display: none;
  min-height: 560px;
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, 0.20);
  border-radius: 36px;
  background: linear-gradient(135deg, rgba(15, 23, 42, 0.94), rgba(4, 47, 46, 0.72));
  box-shadow: var(--shadow);
}

.hero-slide.is-active {
  display: grid;
  grid-template-columns: 1.08fr 0.92fr;
  align-items: stretch;
}

.hero-backdrop {
  position: absolute;
  inset: 0;
  opacity: 0.32;
  filter: blur(18px) saturate(1.15);
  transform: scale(1.1);
}

.hero-backdrop img,
.hero-poster img,
.player-cover img,
.poster-wrap img,
.mini-poster img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-backdrop:after,
.hero-slide:after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 18% 15%, rgba(16, 185, 129, 0.34), transparent 24rem),
    linear-gradient(90deg, rgba(5, 7, 11, 0.94), rgba(5, 7, 11, 0.46), rgba(5, 7, 11, 0.72));
}

.hero-copy {
  position: relative;
  z-index: 3;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: clamp(28px, 6vw, 70px);
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  width: fit-content;
  padding: 8px 13px;
  border: 1px solid rgba(52, 211, 153, 0.30);
  border-radius: 999px;
  color: #bbf7d0;
  background: rgba(6, 78, 59, 0.45);
  font-size: 0.86rem;
  font-weight: 700;
}

.hero h1,
.page-title h1,
.detail-title h1 {
  margin: 18px 0 14px;
  max-width: 820px;
  font-size: clamp(2.4rem, 7vw, 5.8rem);
  line-height: 0.96;
  font-weight: 950;
  letter-spacing: -0.075em;
}

.hero-desc {
  max-width: 680px;
  color: #dbeafe;
  font-size: clamp(1.02rem, 2vw, 1.25rem);
  line-height: 1.85;
}

.hero-meta,
.meta-line,
.breadcrumb,
.card-meta,
.detail-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 9px;
  color: var(--muted);
}

.hero-meta {
  margin-top: 18px;
}

.chip,
.tag,
.card-badge,
.rank-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 999px;
  color: #d1fae5;
  background: rgba(15, 23, 42, 0.58);
  white-space: nowrap;
}

.chip,
.tag {
  padding: 7px 11px;
  font-size: 0.82rem;
}

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

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  min-height: 46px;
  padding: 0 18px;
  border: 1px solid transparent;
  border-radius: 999px;
  font-weight: 850;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

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

.btn-primary {
  color: #022c22;
  background: linear-gradient(135deg, var(--brand-2), var(--brand));
  box-shadow: 0 18px 40px rgba(16, 185, 129, 0.24);
}

.btn-ghost {
  color: #fff;
  border-color: rgba(255,255,255,0.14);
  background: rgba(255,255,255,0.08);
}

.hero-visual {
  position: relative;
  z-index: 3;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: clamp(22px, 4vw, 54px);
}

.hero-poster {
  position: relative;
  width: min(360px, 78%);
  aspect-ratio: 2 / 3;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,0.18);
  border-radius: 30px;
  background: linear-gradient(145deg, #0f172a, #064e3b);
  box-shadow: 0 30px 90px rgba(0,0,0,0.48);
}

.poster-title,
.cover-title {
  position: absolute;
  left: 18px;
  right: 18px;
  bottom: 18px;
  z-index: 2;
  font-weight: 900;
  line-height: 1.25;
  text-shadow: 0 8px 24px rgba(0,0,0,0.65);
}

.hero-poster:after,
.poster-wrap:after,
.mini-poster:after,
.player-cover:after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 34%, rgba(0,0,0,0.78) 100%);
  pointer-events: none;
}

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

.hero-dot {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: rgba(255,255,255,0.34);
  border: 0;
  transition: width 0.2s ease, background 0.2s ease;
}

.hero-dot.is-active {
  width: 30px;
  background: var(--brand-2);
}

.section {
  padding: 54px 0;
}

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

.section-head h2,
.page-title h1,
.detail-title h1 {
  margin: 0;
  font-size: clamp(1.8rem, 4vw, 3.2rem);
  line-height: 1.08;
  font-weight: 950;
  letter-spacing: -0.05em;
}

.section-head p,
.page-title p,
.detail-lead,
.topic-card p {
  color: var(--muted);
  line-height: 1.75;
}

.search-panel {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
  width: min(760px, 100%);
  margin-top: 26px;
  padding: 10px;
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.72);
  box-shadow: 0 16px 54px rgba(0,0,0,0.25);
}

.search-panel input,
.filter-bar input,
.filter-bar select {
  width: 100%;
  border: 0;
  outline: 0;
  color: #fff;
  background: transparent;
}

.search-panel input {
  padding: 0 16px;
}

.filter-bar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 180px 180px;
  gap: 12px;
  margin-bottom: 24px;
}

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

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

.movie-card {
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 22px;
  background: rgba(15, 23, 42, 0.72);
  box-shadow: 0 18px 50px rgba(0,0,0,0.18);
  transition: transform 0.22s ease, border-color 0.22s ease, box-shadow 0.22s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  border-color: rgba(52, 211, 153, 0.40);
  box-shadow: 0 24px 70px rgba(0,0,0,0.28);
}

.poster-wrap {
  position: relative;
  display: block;
  overflow: hidden;
  aspect-ratio: 2 / 3;
  background:
    radial-gradient(circle at 30% 10%, rgba(52, 211, 153, 0.28), transparent 12rem),
    linear-gradient(145deg, #111827, #052e2b);
}

.poster-wrap img {
  position: absolute;
  inset: 0;
  transition: transform 0.32s ease, opacity 0.2s ease;
}

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

.card-badge {
  position: absolute;
  left: 11px;
  top: 11px;
  z-index: 3;
  padding: 5px 9px;
  font-size: 0.74rem;
  color: #ecfdf5;
  background: rgba(2, 6, 23, 0.68);
  backdrop-filter: blur(10px);
}

.play-float {
  position: absolute;
  right: 12px;
  bottom: 12px;
  z-index: 3;
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 999px;
  color: #022c22;
  background: var(--brand-2);
  box-shadow: 0 12px 32px rgba(16, 185, 129, 0.32);
}

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

.card-title {
  display: -webkit-box;
  min-height: 2.7em;
  overflow: hidden;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  font-weight: 850;
  line-height: 1.35;
}

.card-desc {
  display: -webkit-box;
  margin-top: 9px;
  min-height: 3.95em;
  overflow: hidden;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.52;
}

.card-meta {
  margin-top: 10px;
  font-size: 0.78rem;
}

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

.topic-card,
.rank-card,
.content-box {
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: var(--radius);
  background: var(--panel-bg);
  box-shadow: 0 18px 50px rgba(0,0,0,0.18);
}

.topic-card {
  display: flex;
  flex-direction: column;
  min-height: 190px;
  padding: 22px;
  transition: transform 0.22s ease, border-color 0.22s ease;
}

.topic-card:hover {
  transform: translateY(-5px);
  border-color: rgba(52, 211, 153, 0.34);
}

.topic-card strong {
  font-size: 1.25rem;
  font-weight: 900;
}

.topic-card span {
  margin-top: auto;
  color: #6ee7b7;
  font-weight: 800;
}

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

.rank-card {
  display: grid;
  grid-template-columns: 76px 1fr auto;
  align-items: center;
  gap: 14px;
  padding: 12px;
}

.rank-badge {
  justify-content: center;
  width: 42px;
  height: 42px;
  padding: 0;
  color: #022c22;
  background: linear-gradient(135deg, #fde68a, var(--gold));
  font-weight: 950;
}

.mini-poster {
  position: relative;
  overflow: hidden;
  width: 76px;
  aspect-ratio: 2 / 3;
  border-radius: 15px;
  background: linear-gradient(145deg, #111827, #064e3b);
}

.rank-info strong {
  display: block;
  margin-bottom: 6px;
  font-weight: 900;
}

.rank-info p {
  display: -webkit-box;
  overflow: hidden;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  color: var(--muted);
  font-size: 0.86rem;
  line-height: 1.5;
}

.breadcrumb {
  margin: 22px 0;
  font-size: 0.9rem;
}

.breadcrumb a {
  color: #a7f3d0;
}

.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(280px, 0.9fr);
  gap: 28px;
  align-items: start;
}

.player-box {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, 0.18);
  border-radius: 30px;
  background: #000;
  box-shadow: var(--shadow);
}

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

.player-cover {
  position: absolute;
  inset: 0;
  z-index: 4;
  display: grid;
  place-items: center;
  overflow: hidden;
  width: 100%;
  border: 0;
  color: #fff;
  background: #020617;
}

.player-cover.is-hidden {
  display: none;
}

.player-cover img {
  position: absolute;
  inset: 0;
  opacity: 0.66;
  filter: saturate(1.08);
}

.play-ring {
  position: relative;
  z-index: 5;
  display: grid;
  place-items: center;
  width: 86px;
  height: 86px;
  border-radius: 999px;
  color: #022c22;
  background: var(--brand-2);
  box-shadow: 0 20px 55px rgba(16,185,129,0.36);
  font-size: 1.7rem;
}

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

.detail-title {
  margin-bottom: 18px;
}

.detail-meta {
  margin-bottom: 18px;
}

.detail-lead {
  font-size: 1.06rem;
}

.prose h2 {
  margin: 28px 0 12px;
  font-size: 1.35rem;
  font-weight: 900;
}

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

.side-card {
  padding: 20px;
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 24px;
  background: rgba(15, 23, 42, 0.72);
}

.side-card h2 {
  margin: 0 0 14px;
  font-size: 1.12rem;
  font-weight: 900;
}

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

.related-item {
  display: grid;
  grid-template-columns: 56px 1fr;
  gap: 12px;
  align-items: center;
  padding: 9px;
  border-radius: 18px;
  transition: background 0.2s ease;
}

.related-item:hover {
  background: rgba(255,255,255,0.06);
}

.related-item .mini-poster {
  width: 56px;
  border-radius: 12px;
}

.related-item strong {
  display: block;
  font-size: 0.94rem;
}

.related-item span {
  color: var(--muted);
  font-size: 0.78rem;
}

.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 18px 0 2px;
}

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

.footer-inner {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 30px;
  padding: 34px 0;
  color: var(--muted);
}

.footer-inner strong {
  display: block;
  margin-bottom: 10px;
  color: #fff;
  font-size: 1.1rem;
}

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

.footer-links a:hover {
  color: #a7f3d0;
}

.empty-state {
  display: none;
  padding: 34px;
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 24px;
  color: var(--muted);
  background: rgba(15,23,42,0.7);
  text-align: center;
}

.empty-state.is-visible {
  display: block;
}

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

@media (max-width: 920px) {
  .nav-toggle {
    display: block;
  }
  .nav-links {
    position: fixed;
    inset: 72px 16px auto 16px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    padding: 14px;
    border: 1px solid var(--line);
    border-radius: 22px;
    background: rgba(2, 6, 23, 0.96);
    box-shadow: var(--shadow);
  }
  .nav-links.is-open {
    display: flex;
  }
  .hero {
    min-height: auto;
  }
  .hero-slide.is-active {
    grid-template-columns: 1fr;
  }
  .hero-copy {
    padding-bottom: 20px;
  }
  .hero-visual {
    padding-top: 0;
  }
  .movie-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .rank-list,
  .detail-layout,
  .footer-inner {
    grid-template-columns: 1fr;
  }
  .footer-links {
    justify-content: flex-start;
  }
}

@media (max-width: 680px) {
  .site-shell {
    width: min(100% - 22px, 1180px);
  }
  .navbar {
    min-height: 66px;
  }
  .hero-stage {
    padding: 22px 0 34px;
  }
  .hero-slide {
    border-radius: 26px;
    min-height: 0;
  }
  .search-panel,
  .filter-bar {
    grid-template-columns: 1fr;
    border-radius: 22px;
  }
  .section-head,
  .page-title {
    align-items: flex-start;
    flex-direction: column;
  }
  .movie-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
  }
  .topic-grid {
    grid-template-columns: 1fr;
  }
  .rank-card {
    grid-template-columns: 56px 1fr;
  }
  .rank-badge {
    display: none;
  }
  .detail-panel {
    padding: 18px;
  }
  .play-ring {
    width: 68px;
    height: 68px;
  }
}
