:root {
  color-scheme: dark;
  --bg: #020617;
  --panel: rgba(15, 23, 42, 0.72);
  --panel-strong: rgba(15, 23, 42, 0.94);
  --line: rgba(96, 165, 250, 0.18);
  --line-strong: rgba(96, 165, 250, 0.34);
  --text: #ffffff;
  --muted: #94a3b8;
  --blue: #3b82f6;
  --blue-soft: rgba(59, 130, 246, 0.18);
  --cyan: #38bdf8;
  --yellow: #facc15;
  --radius: 22px;
  --shadow: 0 28px 70px rgba(0, 0, 0, 0.42);
}

* {
  box-sizing: border-box;
}

html {
  background: var(--bg);
}

body {
  min-height: 100vh;
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  background:
    radial-gradient(circle at 15% 5%, rgba(59, 130, 246, 0.18), transparent 34rem),
    radial-gradient(circle at 85% 12%, rgba(168, 85, 247, 0.16), transparent 32rem),
    linear-gradient(180deg, #020617 0%, #0f172a 38%, #082f49 100%);
}

img {
  display: block;
}

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

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 50;
  transition: background 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
  border-bottom: 1px solid transparent;
}

.site-header.is-scrolled {
  background: rgba(2, 6, 23, 0.92);
  border-color: rgba(96, 165, 250, 0.18);
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.34);
  backdrop-filter: blur(18px);
}

.header-inner {
  width: min(1280px, calc(100% - 32px));
  height: 74px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand,
.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-weight: 800;
}

.brand-mark {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  color: #fff;
  background: linear-gradient(135deg, #2563eb, #38bdf8);
  box-shadow: 0 16px 32px rgba(37, 99, 235, 0.35);
}

.brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.1;
}

.brand-text strong {
  font-size: 1.24rem;
  letter-spacing: 0.02em;
}

.brand-text em {
  color: #93c5fd;
  font-size: 0.78rem;
  font-style: normal;
  margin-top: 4px;
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 6px;
}

.nav-link,
.mobile-link {
  color: rgba(255, 255, 255, 0.88);
  border-radius: 14px;
  transition: all 0.24s ease;
}

.nav-link {
  padding: 10px 16px;
}

.nav-link:hover,
.nav-link.active,
.mobile-link:hover,
.mobile-link.active {
  color: #fff;
  background: rgba(255, 255, 255, 0.1);
}

.menu-toggle {
  display: none;
  width: 44px;
  height: 44px;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 5px;
  border: 0;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.08);
}

.menu-toggle span {
  width: 20px;
  height: 2px;
  border-radius: 999px;
  background: #fff;
}

.mobile-nav {
  display: none;
  width: min(1280px, calc(100% - 32px));
  margin: 0 auto 12px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(15, 23, 42, 0.96);
  backdrop-filter: blur(18px);
}

.mobile-link {
  display: block;
  padding: 13px 14px;
}

.hero {
  position: relative;
  min-height: 700px;
  overflow: hidden;
  display: flex;
  align-items: center;
}

.hero-media,
.hero-media img,
.hero-shade,
.hero-glow {
  position: absolute;
  inset: 0;
}

.hero-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.02);
}

.hero-shade {
  background:
    linear-gradient(180deg, rgba(2, 6, 23, 0.56), rgba(15, 23, 42, 0.94)),
    linear-gradient(90deg, rgba(2, 6, 23, 0.84), rgba(15, 23, 42, 0.28));
}

.hero-glow {
  background: linear-gradient(90deg, rgba(37, 99, 235, 0.24), rgba(147, 51, 234, 0.16), transparent);
  mix-blend-mode: screen;
}

.hero-inner {
  position: relative;
  width: min(1280px, calc(100% - 32px));
  margin: 0 auto;
  padding-top: 84px;
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(280px, 0.58fr);
  align-items: center;
  gap: 48px;
}

.hero-kicker,
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--yellow);
  font-weight: 700;
  letter-spacing: 0.04em;
}

.hero h1,
.page-hero h1,
.movie-detail h1 {
  margin: 18px 0 20px;
  font-size: clamp(2.5rem, 6vw, 5.7rem);
  line-height: 1.02;
  font-weight: 900;
  letter-spacing: -0.05em;
}

.hero h1 span,
.page-hero h1 span {
  color: #60a5fa;
}

.hero p {
  max-width: 760px;
  color: #dbeafe;
  font-size: clamp(1.05rem, 2vw, 1.28rem);
  line-height: 1.8;
}

.hero-actions,
.action-row,
.filter-row {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  align-items: center;
}

.hero-actions {
  margin-top: 34px;
}

.btn-primary,
.btn-secondary,
.btn-ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 24px;
  border-radius: 999px;
  font-weight: 800;
  transition: all 0.22s ease;
}

.btn-primary {
  color: #fff;
  background: linear-gradient(135deg, #2563eb, #38bdf8);
  box-shadow: 0 16px 32px rgba(37, 99, 235, 0.35);
}

.btn-secondary,
.btn-ghost {
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.24);
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
}

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

.hero-panel {
  border: 1px solid rgba(96, 165, 250, 0.22);
  border-radius: 30px;
  overflow: hidden;
  background: rgba(15, 23, 42, 0.58);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}

.hero-panel img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
}

.hero-panel-info {
  padding: 22px;
}

.hero-panel-info strong {
  display: block;
  font-size: 1.3rem;
  margin-bottom: 8px;
}

.hero-panel-info p,
.page-hero p,
.movie-detail .lead,
.copy-block p,
.footer-inner p {
  color: var(--muted);
  line-height: 1.8;
}

.main-section {
  padding: 72px 0;
}

.main-section.alt {
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.24), rgba(8, 47, 73, 0.36));
}

.container {
  width: min(1280px, calc(100% - 32px));
  margin: 0 auto;
}

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

.section-title h2 {
  font-size: clamp(1.65rem, 3.5vw, 2.3rem);
  line-height: 1.15;
  font-weight: 900;
}

.section-more {
  color: #60a5fa;
  font-weight: 700;
}

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

.movie-card,
.wide-card,
.rank-card,
.category-card,
.copy-block,
.filter-panel,
.player-card {
  border: 1px solid var(--line);
  background: linear-gradient(145deg, rgba(30, 41, 59, 0.72), rgba(30, 64, 175, 0.18));
  box-shadow: 0 22px 46px rgba(0, 0, 0, 0.22);
  backdrop-filter: blur(14px);
}

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

.movie-card:hover,
.wide-card:hover,
.category-card:hover,
.rank-card:hover {
  transform: translateY(-6px);
  border-color: var(--line-strong);
  box-shadow: 0 30px 58px rgba(37, 99, 235, 0.2);
}

.poster-wrap,
.wide-poster {
  position: relative;
  overflow: hidden;
}

.poster-wrap {
  aspect-ratio: 3 / 4;
}

.poster-wrap img,
.wide-poster img,
.category-card img,
.rank-poster img,
.mini-card img,
.detail-poster img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.45s ease;
}

.movie-card:hover img,
.wide-card:hover img,
.category-card:hover img,
.rank-card:hover img {
  transform: scale(1.08);
}

.poster-wrap::after,
.wide-poster::after,
.rank-poster::after,
.detail-poster::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 35%, rgba(0, 0, 0, 0.78));
}

.type-badge,
.year-badge,
.rank-badge {
  position: absolute;
  z-index: 2;
  border-radius: 999px;
  color: #fff;
  font-size: 0.75rem;
  font-weight: 800;
  backdrop-filter: blur(8px);
}

.type-badge {
  top: 12px;
  left: 12px;
  padding: 6px 10px;
  background: rgba(37, 99, 235, 0.88);
}

.year-badge {
  right: 12px;
  bottom: 12px;
  padding: 5px 9px;
  background: rgba(0, 0, 0, 0.58);
}

.poster-play,
.play-dot {
  position: absolute;
  z-index: 3;
  left: 50%;
  top: 50%;
  display: grid;
  place-items: center;
  color: #fff;
  background: rgba(37, 99, 235, 0.86);
  box-shadow: 0 12px 28px rgba(37, 99, 235, 0.38);
  transform: translate(-50%, -50%) scale(0.85);
  opacity: 0;
  transition: all 0.26s ease;
}

.poster-play {
  width: 58px;
  height: 58px;
  border-radius: 999px;
}

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

.card-body {
  padding: 18px;
}

.card-body h3,
.wide-info strong,
.rank-info strong,
.mini-card strong {
  display: -webkit-box;
  overflow: hidden;
  color: #fff;
  font-weight: 850;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.card-body h3 {
  min-height: 3em;
  font-size: 1.05rem;
  line-height: 1.45;
}

.card-body p,
.wide-info p,
.rank-info p {
  display: -webkit-box;
  overflow: hidden;
  color: var(--muted);
  line-height: 1.65;
  -webkit-box-orient: vertical;
}

.card-body p {
  min-height: 3.3em;
  margin: 10px 0 14px;
  font-size: 0.92rem;
  -webkit-line-clamp: 2;
}

.card-meta,
.meta-row,
.tag-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}

.card-meta {
  justify-content: space-between;
  color: #93c5fd;
  font-size: 0.82rem;
}

.wide-list {
  display: grid;
  gap: 18px;
}

.wide-card {
  display: grid;
  grid-template-columns: 170px 1fr;
  gap: 20px;
  padding: 16px;
  border-radius: var(--radius);
  transition: all 0.26s ease;
}

.wide-poster {
  aspect-ratio: 3 / 4;
  border-radius: 18px;
}

.play-dot {
  width: 48px;
  height: 48px;
  border-radius: 999px;
}

.wide-info {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.wide-info strong {
  font-size: 1.35rem;
}

.wide-info p {
  margin: 12px 0;
  -webkit-line-clamp: 3;
}

.meta-row span,
.tag-row span,
.info-pill {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 11px;
  color: #bfdbfe;
  border: 1px solid rgba(96, 165, 250, 0.22);
  border-radius: 999px;
  background: rgba(37, 99, 235, 0.14);
  font-size: 0.84rem;
}

.home-split {
  display: grid;
  grid-template-columns: minmax(0, 1.65fr) minmax(280px, 0.85fr);
  gap: 28px;
}

.side-panel {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 22px;
  background: rgba(15, 23, 42, 0.55);
  backdrop-filter: blur(14px);
}

.side-panel h2,
.side-panel h3 {
  margin: 0 0 18px;
  font-size: 1.28rem;
  font-weight: 900;
}

.mini-stack {
  display: grid;
  gap: 10px;
}

.mini-card {
  display: grid;
  grid-template-columns: 64px 1fr;
  align-items: center;
  gap: 12px;
  padding: 10px;
  border-radius: 16px;
  transition: background 0.22s ease;
}

.mini-card:hover {
  background: rgba(255, 255, 255, 0.08);
}

.mini-card img {
  aspect-ratio: 3 / 4;
  border-radius: 12px;
}

.mini-card span {
  min-width: 0;
}

.mini-card em {
  display: block;
  margin-top: 5px;
  color: var(--muted);
  font-size: 0.82rem;
  font-style: normal;
}

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

.category-card {
  position: relative;
  min-height: 156px;
  overflow: hidden;
  border-radius: var(--radius);
}

.category-card img {
  position: absolute;
  inset: 0;
}

.category-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(2, 6, 23, 0.1), rgba(2, 6, 23, 0.88));
}

.category-card span {
  position: absolute;
  left: 18px;
  right: 18px;
  bottom: 18px;
  z-index: 2;
  font-size: 1.08rem;
  font-weight: 900;
}

.rank-list {
  display: grid;
  gap: 16px;
}

.rank-card {
  display: grid;
  grid-template-columns: 58px 110px 1fr;
  align-items: center;
  gap: 16px;
  padding: 14px;
  border-radius: 20px;
  transition: all 0.26s ease;
}

.rank-number {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border-radius: 16px;
  color: #fff;
  background: linear-gradient(135deg, #2563eb, #7c3aed);
  font-size: 1.2rem;
  font-weight: 900;
}

.rank-poster {
  position: relative;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  border-radius: 14px;
}

.rank-info strong {
  font-size: 1.12rem;
}

.rank-info p {
  margin: 8px 0 10px;
  -webkit-line-clamp: 2;
}

.page-hero {
  padding: 150px 0 64px;
  background:
    radial-gradient(circle at 18% 35%, rgba(59, 130, 246, 0.22), transparent 28rem),
    linear-gradient(180deg, rgba(15, 23, 42, 0.8), rgba(2, 6, 23, 0));
}

.page-hero h1 {
  max-width: 980px;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: #93c5fd;
  margin-bottom: 18px;
}

.breadcrumb a:hover {
  color: #fff;
}

.copy-block,
.filter-panel,
.player-card {
  border-radius: var(--radius);
  padding: 24px;
}

.filter-panel {
  margin-bottom: 26px;
}

.filter-row input,
.filter-row select {
  min-height: 46px;
  border: 1px solid var(--line);
  border-radius: 14px;
  color: #fff;
  background: rgba(15, 23, 42, 0.88);
  padding: 0 14px;
  outline: none;
}

.filter-row input {
  flex: 1 1 320px;
}

.filter-row select {
  flex: 0 1 160px;
}

.search-status {
  margin: 0 0 16px;
  color: var(--muted);
}

.movie-detail {
  padding: 122px 0 0;
}

.detail-head {
  position: relative;
  overflow: hidden;
  padding: 66px 0;
}

.detail-backdrop,
.detail-backdrop img,
.detail-backdrop::after {
  position: absolute;
  inset: 0;
}

.detail-backdrop img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: blur(5px);
  transform: scale(1.08);
  opacity: 0.42;
}

.detail-backdrop::after {
  content: "";
  background: linear-gradient(180deg, rgba(2, 6, 23, 0.68), rgba(2, 6, 23, 0.98));
}

.detail-inner {
  position: relative;
  display: grid;
  grid-template-columns: minmax(240px, 330px) 1fr;
  gap: 36px;
  align-items: center;
}

.detail-poster {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--line-strong);
  border-radius: 28px;
  box-shadow: var(--shadow);
  aspect-ratio: 3 / 4;
}

.detail-info h1 {
  font-size: clamp(2.2rem, 5vw, 4.8rem);
}

.detail-info .lead {
  max-width: 850px;
  font-size: 1.12rem;
}

.detail-content {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 28px;
  padding: 48px 0 76px;
}

.player-card {
  overflow: hidden;
  padding: 0;
}

.player-frame {
  position: relative;
  aspect-ratio: 16 / 9;
  background: #000;
}

.player-frame video {
  width: 100%;
  height: 100%;
  background: #000;
}

.player-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background:
    linear-gradient(180deg, rgba(2, 6, 23, 0.08), rgba(2, 6, 23, 0.92)),
    rgba(0, 0, 0, 0.2);
}

.player-overlay[hidden] {
  display: none;
}

.play-button {
  width: 92px;
  height: 92px;
  border: 0;
  border-radius: 999px;
  color: #fff;
  background: linear-gradient(135deg, #2563eb, #38bdf8);
  box-shadow: 0 20px 52px rgba(37, 99, 235, 0.45);
  font-size: 2rem;
  transition: all 0.22s ease;
}

.play-button:hover {
  transform: scale(1.08);
}

.copy-stack {
  display: grid;
  gap: 20px;
  padding: 24px;
}

.copy-block h2,
.copy-stack h2 {
  margin-bottom: 12px;
  font-size: 1.45rem;
  font-weight: 900;
}

.detail-side {
  display: grid;
  align-content: start;
  gap: 22px;
}

.site-footer {
  border-top: 1px solid rgba(96, 165, 250, 0.14);
  background: rgba(2, 6, 23, 0.82);
}

.footer-inner {
  width: min(1280px, calc(100% - 32px));
  margin: 0 auto;
  padding: 50px 0;
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1.2fr;
  gap: 28px;
}

.footer-inner h2 {
  margin-bottom: 14px;
  font-size: 1rem;
  font-weight: 900;
}

.footer-inner a {
  display: block;
  margin: 9px 0;
  color: var(--muted);
}

.footer-inner a:hover,
.footer-bottom button:hover {
  color: #60a5fa;
}

.footer-bottom {
  width: min(1280px, calc(100% - 32px));
  margin: 0 auto;
  padding: 22px 0;
  border-top: 1px solid rgba(148, 163, 184, 0.16);
  display: flex;
  justify-content: space-between;
  color: var(--muted);
}

.footer-bottom button {
  border: 0;
  color: var(--muted);
  background: transparent;
}

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

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

  .hero-panel {
    display: none;
  }
}

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

  .menu-toggle {
    display: inline-flex;
  }

  .mobile-nav.is-open {
    display: block;
  }

  .hero {
    min-height: 620px;
  }

  .hero-inner,
  .detail-inner {
    grid-template-columns: 1fr;
  }

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

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

  .wide-card,
  .rank-card {
    grid-template-columns: 92px 1fr;
  }

  .rank-number {
    grid-column: 1 / -1;
    width: auto;
  }
}

@media (max-width: 560px) {
  .header-inner {
    width: min(100% - 20px, 1280px);
  }

  .brand-text strong {
    font-size: 1rem;
  }

  .brand-text em {
    display: none;
  }

  .container,
  .hero-inner,
  .footer-inner,
  .footer-bottom,
  .mobile-nav {
    width: min(100% - 24px, 1280px);
  }

  .movie-grid,
  .category-grid {
    gap: 14px;
  }

  .card-body {
    padding: 14px;
  }

  .footer-bottom {
    flex-direction: column;
    gap: 12px;
  }
}
