:root {
  --bg: #f3f7ff;
  --panel: #ffffff;
  --ink: #0f172a;
  --muted: #64748b;
  --line: rgba(148, 163, 184, 0.28);
  --blue: #2563eb;
  --blue-deep: #1d4ed8;
  --cyan: #06b6d4;
  --green: #16a34a;
  --red: #ef4444;
  --shadow: 0 20px 55px rgba(15, 23, 42, 0.12);
  --soft-shadow: 0 12px 34px rgba(37, 99, 235, 0.12);
  --radius: 24px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: radial-gradient(circle at top left, rgba(14, 165, 233, 0.12), transparent 34rem), var(--bg);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  line-height: 1.6;
}

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

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

button,
input,
select {
  font: inherit;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(18px);
  box-shadow: 0 8px 28px rgba(15, 23, 42, 0.08);
}

.site-nav {
  min-height: 76px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

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

.brand-icon {
  width: 48px;
  height: 48px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  color: white;
  background: linear-gradient(135deg, var(--blue), var(--cyan));
  box-shadow: 0 0 24px rgba(6, 182, 212, 0.42);
}

.brand-icon svg {
  width: 24px;
  height: 24px;
  fill: currentColor;
}

.brand-text strong {
  display: block;
  font-size: 1.35rem;
  line-height: 1.1;
  background: linear-gradient(90deg, var(--blue-deep), var(--cyan));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.brand-text small {
  color: var(--muted);
  font-size: 0.78rem;
}

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

.nav-link {
  position: relative;
  padding: 10px 14px;
  border-radius: 999px;
  color: #334155;
  font-weight: 700;
  transition: color 0.25s ease, background 0.25s ease, transform 0.25s ease;
}

.nav-link:hover,
.nav-link.active {
  color: var(--blue-deep);
  background: rgba(37, 99, 235, 0.08);
  transform: translateY(-1px);
}

.mobile-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 14px;
  background: rgba(37, 99, 235, 0.08);
  cursor: pointer;
}

.mobile-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  margin: 5px auto;
  border-radius: 2px;
  background: var(--blue-deep);
}

.mobile-nav {
  display: none;
  padding: 0 16px 16px;
}

.mobile-nav.open {
  display: grid;
  gap: 8px;
}

.hero-slider {
  position: relative;
  min-height: 680px;
  overflow: hidden;
  background: #0f172a;
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.8s ease;
}

.hero-slide.active {
  opacity: 1;
  pointer-events: auto;
}

.hero-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(1.08) contrast(1.05);
}

.hero-slide::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(15, 23, 42, 0.92), rgba(30, 64, 175, 0.66), rgba(14, 165, 233, 0.24));
}

.hero-slide::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 180px;
  background: linear-gradient(0deg, var(--bg), transparent);
}

.hero-inner {
  position: relative;
  z-index: 2;
  min-height: 680px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  align-items: center;
  gap: 64px;
  color: white;
}

.hero-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.28);
  background: rgba(37, 99, 235, 0.32);
  backdrop-filter: blur(10px);
  color: #dbeafe;
  font-weight: 800;
}

.hero-inner h1 {
  margin: 20px 0 18px;
  max-width: 820px;
  font-size: clamp(2.6rem, 7vw, 5.8rem);
  line-height: 0.98;
  letter-spacing: -0.06em;
}

.hero-inner p {
  max-width: 760px;
  margin: 0 0 24px;
  color: #dbeafe;
  font-size: 1.15rem;
}

.hero-meta,
.detail-meta,
.meta-line {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 0 0 28px;
}

.hero-meta span,
.detail-meta span,
.meta-line span {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 6px 12px;
  background: rgba(255, 255, 255, 0.16);
  color: #eff6ff;
  font-size: 0.9rem;
  font-weight: 700;
}

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

.primary-btn,
.secondary-btn,
.ghost-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 22px;
  border-radius: 999px;
  font-weight: 800;
  transition: transform 0.25s ease, box-shadow 0.25s ease, background 0.25s ease;
}

.primary-btn {
  color: white;
  background: linear-gradient(135deg, var(--blue), var(--cyan));
  box-shadow: 0 12px 30px rgba(37, 99, 235, 0.36);
}

.secondary-btn {
  color: white;
  border: 1px solid rgba(255, 255, 255, 0.34);
  background: rgba(255, 255, 255, 0.16);
  backdrop-filter: blur(10px);
}

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

.hero-poster {
  padding: 16px;
  border-radius: 32px;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.26);
  backdrop-filter: blur(18px);
  box-shadow: var(--shadow);
}

.hero-poster img {
  aspect-ratio: 3 / 4;
  width: 100%;
  object-fit: cover;
  border-radius: 22px;
}

.hero-dots {
  position: absolute;
  z-index: 4;
  left: 50%;
  bottom: 44px;
  transform: translateX(-50%);
  display: flex;
  gap: 10px;
}

.hero-dots button {
  width: 42px;
  height: 6px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.42);
  cursor: pointer;
}

.hero-dots button.active {
  background: white;
}

.quick-panel {
  position: relative;
  z-index: 5;
  margin-top: -64px;
}

.quick-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  padding: 22px;
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(18px);
  box-shadow: var(--shadow);
}

.quick-card {
  min-height: 126px;
  padding: 22px;
  border-radius: 22px;
  color: white;
  background: linear-gradient(135deg, var(--blue), var(--cyan));
  overflow: hidden;
  position: relative;
}

.quick-card:nth-child(2) {
  background: linear-gradient(135deg, #7c3aed, #2563eb);
}

.quick-card:nth-child(3) {
  background: linear-gradient(135deg, #0f766e, #06b6d4);
}

.quick-card strong {
  display: block;
  margin-bottom: 8px;
  font-size: 1.35rem;
}

.quick-card p {
  margin: 0;
  color: rgba(255, 255, 255, 0.86);
}

.section {
  padding: 72px 0;
}

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

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

.section-head > div {
  display: grid;
  gap: 6px;
}

.section-icon {
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  border-radius: 16px;
  background: rgba(37, 99, 235, 0.1);
  font-size: 1.5rem;
}

.section-head h2 {
  margin: 0;
  font-size: clamp(1.75rem, 3vw, 2.5rem);
  line-height: 1.1;
}

.section-head p {
  margin: 0;
  color: var(--muted);
}

.section-more {
  color: var(--blue-deep);
  font-weight: 800;
}

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

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

.movie-card {
  min-width: 0;
  border-radius: 24px;
  overflow: hidden;
  background: var(--panel);
  box-shadow: var(--soft-shadow);
  border: 1px solid var(--line);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow);
}

.poster-wrap {
  position: relative;
  display: block;
  overflow: hidden;
  background: #dbeafe;
}

.poster-wrap img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  transition: transform 0.35s ease;
}

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

.year-badge,
.play-badge {
  position: absolute;
  z-index: 2;
  border-radius: 999px;
  padding: 6px 11px;
  color: white;
  font-size: 0.82rem;
  font-weight: 800;
}

.year-badge {
  left: 12px;
  top: 12px;
  background: rgba(15, 23, 42, 0.66);
  backdrop-filter: blur(8px);
}

.play-badge {
  right: 12px;
  bottom: 12px;
  background: linear-gradient(135deg, var(--blue), var(--cyan));
}

.card-body {
  padding: 18px;
}

.eyebrow {
  margin: 0 0 8px;
  color: var(--blue-deep);
  font-size: 0.82rem;
  font-weight: 800;
  letter-spacing: 0.02em;
}

.card-body h2,
.rank-info h2 {
  margin: 0 0 8px;
  font-size: 1.15rem;
  line-height: 1.25;
}

.card-body p,
.rank-info p {
  margin: 0;
  color: var(--muted);
  font-size: 0.94rem;
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}

.tag-row span {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 4px 9px;
  background: #eff6ff;
  color: #1d4ed8;
  font-size: 0.76rem;
  font-weight: 800;
}

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

.category-card {
  position: relative;
  min-height: 228px;
  overflow: hidden;
  border-radius: 24px;
  color: white;
  background: #0f172a;
  box-shadow: var(--soft-shadow);
}

.category-card img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.72;
  transition: transform 0.35s ease, opacity 0.35s ease;
}

.category-card:hover img {
  transform: scale(1.06);
  opacity: 0.88;
}

.category-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent, rgba(15, 23, 42, 0.92));
}

.category-card div {
  position: absolute;
  z-index: 2;
  left: 18px;
  right: 18px;
  bottom: 18px;
}

.category-card strong {
  display: block;
  margin-bottom: 8px;
  font-size: 1.28rem;
}

.category-card p {
  margin: 0;
  color: rgba(255, 255, 255, 0.84);
  font-size: 0.9rem;
}

.page-hero {
  position: relative;
  overflow: hidden;
  color: white;
  background: linear-gradient(135deg, #1d4ed8, #06b6d4);
}

.page-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 18% 20%, rgba(255, 255, 255, 0.28), transparent 28rem), radial-gradient(circle at 82% 10%, rgba(255, 255, 255, 0.18), transparent 20rem);
}

.page-hero .container {
  position: relative;
  padding: 68px 0;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  align-items: center;
  margin-bottom: 18px;
  color: #dbeafe;
  font-size: 0.94rem;
}

.breadcrumb a {
  color: white;
  font-weight: 800;
}

.page-hero h1 {
  margin: 0 0 12px;
  font-size: clamp(2rem, 5vw, 4rem);
  line-height: 1.08;
}

.page-hero p {
  max-width: 780px;
  margin: 0;
  color: #dbeafe;
  font-size: 1.08rem;
}

.filter-box {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 180px 180px 160px;
  gap: 14px;
  padding: 18px;
  margin-bottom: 28px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: var(--soft-shadow);
}

.filter-box input,
.filter-box select {
  width: 100%;
  height: 48px;
  padding: 0 14px;
  border: 1px solid rgba(148, 163, 184, 0.42);
  border-radius: 14px;
  color: var(--ink);
  background: white;
  outline: none;
}

.filter-box input:focus,
.filter-box select:focus {
  border-color: var(--blue);
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.12);
}

.empty-result {
  display: none;
  padding: 40px;
  text-align: center;
  color: var(--muted);
  border-radius: 24px;
  border: 1px dashed rgba(100, 116, 139, 0.38);
  background: rgba(255, 255, 255, 0.72);
}

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

.rank-row {
  display: grid;
  grid-template-columns: 112px minmax(0, 1fr) auto;
  align-items: center;
  gap: 18px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: white;
  box-shadow: var(--soft-shadow);
}

.rank-poster img {
  width: 112px;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: 18px;
}

.rank-info h2 {
  font-size: 1.35rem;
}

.ghost-link {
  color: var(--blue-deep);
  background: #eff6ff;
}

.detail-main {
  padding: 42px 0 78px;
}

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

.player-card,
.detail-card,
.related-card {
  border: 1px solid var(--line);
  border-radius: 28px;
  background: white;
  box-shadow: var(--shadow);
  overflow: hidden;
}

.video-shell {
  position: relative;
  background: #020617;
  aspect-ratio: 16 / 9;
}

.video-shell video {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: contain;
  background: #020617;
  cursor: pointer;
}

.poster-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  border: 0;
  color: white;
  background: rgba(2, 6, 23, 0.36);
  cursor: pointer;
}

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

.poster-overlay img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.46;
}

.poster-overlay span {
  position: relative;
  z-index: 2;
  width: 86px;
  height: 86px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  color: white;
  background: linear-gradient(135deg, var(--blue), var(--cyan));
  box-shadow: 0 18px 46px rgba(37, 99, 235, 0.38);
  font-size: 2rem;
}

.player-copy {
  padding: 24px;
}

.player-copy h1 {
  margin: 0 0 12px;
  font-size: clamp(1.7rem, 4vw, 3.2rem);
  line-height: 1.08;
}

.player-copy p {
  color: var(--muted);
  margin: 0;
}

.detail-card {
  padding: 22px;
}

.detail-cover {
  overflow: hidden;
  border-radius: 22px;
  margin-bottom: 18px;
}

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

.detail-card h2,
.related-card h2 {
  margin: 0 0 12px;
  font-size: 1.35rem;
}

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

.detail-meta span {
  color: #1d4ed8;
  background: #eff6ff;
}

.related-card {
  margin-top: 28px;
  padding: 22px;
}

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

.text-block {
  margin-top: 24px;
  display: grid;
  gap: 18px;
}

.text-block section {
  padding: 22px;
  border-radius: 22px;
  background: rgba(239, 246, 255, 0.72);
}

.text-block h2 {
  margin: 0 0 10px;
  font-size: 1.4rem;
}

.text-block p {
  margin: 0;
  color: #334155;
}

.site-footer {
  color: white;
  background: linear-gradient(135deg, #0f172a, #1e3a8a 58%, #111827);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1.2fr;
  gap: 42px;
  padding: 52px 0;
}

.site-footer h2 {
  margin: 0 0 14px;
  font-size: 1.25rem;
  background: linear-gradient(90deg, #93c5fd, #67e8f9);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.site-footer p {
  margin: 0;
  color: #cbd5e1;
}

.footer-links {
  display: grid;
  gap: 10px;
}

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

.footer-links a {
  color: #dbeafe;
  transition: color 0.25s ease;
}

.footer-links a:hover {
  color: white;
}

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

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

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

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

  .mobile-toggle {
    display: block;
  }

  .hero-inner {
    min-height: 700px;
    grid-template-columns: 1fr;
    gap: 24px;
    padding: 92px 0 96px;
  }

  .hero-poster {
    display: none;
  }

  .quick-grid,
  .filter-box,
  .footer-grid {
    grid-template-columns: 1fr;
  }

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

  .rank-row {
    grid-template-columns: 86px minmax(0, 1fr);
  }

  .rank-row .ghost-link {
    grid-column: 1 / -1;
  }

  .rank-poster img {
    width: 86px;
  }
}

@media (max-width: 560px) {
  .container {
    width: min(100% - 24px, 1180px);
  }

  .site-nav {
    min-height: 68px;
  }

  .brand-icon {
    width: 42px;
    height: 42px;
  }

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

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

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

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

  .footer-links.compact {
    grid-template-columns: 1fr;
  }
}
