:root {
  --bg: #f6f8fb;
  --card: #ffffff;
  --ink: #111827;
  --muted: #64748b;
  --line: #e5e7eb;
  --brand: #2563eb;
  --brand-2: #06b6d4;
  --accent: #ec4899;
  --dark: #0f172a;
  --shadow: 0 18px 45px rgba(15, 23, 42, 0.12);
  --soft-shadow: 0 10px 24px rgba(15, 23, 42, 0.08);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background: radial-gradient(circle at top left, rgba(59, 130, 246, 0.10), transparent 34rem), var(--bg);
  line-height: 1.6;
}

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

img {
  display: block;
  width: 100%;
  height: auto;
}

button,
input {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(226, 232, 240, 0.9);
}

.nav-wrap {
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 24px;
  height: 68px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.brand-mark {
  width: 38px;
  height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 13px;
  color: #fff;
  background: linear-gradient(135deg, var(--brand), var(--brand-2));
  box-shadow: 0 12px 26px rgba(37, 99, 235, 0.28);
}

.brand-text {
  font-size: 20px;
  background: linear-gradient(90deg, var(--brand), var(--brand-2));
  color: transparent;
  background-clip: text;
  -webkit-background-clip: text;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 22px;
  color: #334155;
  font-size: 15px;
  font-weight: 650;
}

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

.nav-links a:hover {
  color: var(--brand);
}

.nav-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 12px;
  background: #f1f5f9;
  padding: 10px;
}

.nav-toggle span {
  display: block;
  width: 100%;
  height: 2px;
  margin: 5px 0;
  border-radius: 2px;
  background: #334155;
}

.mobile-menu {
  display: none;
  padding: 12px 24px 20px;
  border-top: 1px solid var(--line);
  background: #fff;
}

.mobile-menu a {
  display: block;
  padding: 11px 14px;
  border-radius: 12px;
  color: #334155;
  font-weight: 650;
}

.mobile-menu a:hover {
  color: var(--brand);
  background: #eff6ff;
}

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

.hero-carousel {
  position: relative;
  min-height: 680px;
  overflow: hidden;
  background: var(--dark);
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.7s ease, transform 0.7s ease;
  transform: scale(1.02);
}

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

.hero-slide > img {
  width: 100%;
  height: 100%;
  min-height: 680px;
  object-fit: cover;
  filter: saturate(1.08);
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(15, 23, 42, 0.92) 0%, rgba(15, 23, 42, 0.70) 43%, rgba(15, 23, 42, 0.22) 100%),
    linear-gradient(0deg, rgba(15, 23, 42, 0.78), transparent 55%);
}

.hero-content {
  position: absolute;
  left: max(24px, calc((100vw - 1240px) / 2 + 24px));
  bottom: 140px;
  max-width: 680px;
  color: #fff;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #bfdbfe;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-size: 13px;
}

.hero-content h1 {
  margin: 18px 0 16px;
  font-size: clamp(42px, 8vw, 78px);
  line-height: 0.98;
  letter-spacing: -0.06em;
}

.hero-content p {
  max-width: 620px;
  color: #dbeafe;
  font-size: 19px;
}

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

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

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

.btn.primary {
  color: #fff;
  background: linear-gradient(135deg, var(--brand), var(--brand-2));
  box-shadow: 0 18px 35px rgba(37, 99, 235, 0.35);
}

.btn.ghost {
  color: #fff;
  background: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.22);
}

.hero-tools {
  position: absolute;
  left: 50%;
  bottom: 42px;
  transform: translateX(-50%);
  width: min(1192px, calc(100% - 48px));
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

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

.hero-dot {
  width: 42px;
  height: 5px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.34);
  cursor: pointer;
}

.hero-dot.is-active {
  background: #fff;
}

.hero-search {
  width: min(460px, 100%);
  display: flex;
  padding: 6px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: var(--shadow);
}

.hero-search input {
  flex: 1;
  min-width: 0;
  border: 0;
  outline: 0;
  padding: 0 18px;
  background: transparent;
  color: #0f172a;
}

.hero-search button {
  border: 0;
  border-radius: 999px;
  padding: 10px 20px;
  color: #fff;
  font-weight: 800;
  background: linear-gradient(135deg, var(--brand), var(--brand-2));
}

.section-wrap {
  max-width: 1240px;
  margin: 0 auto;
  padding: 72px 24px;
}

.section-overlap {
  position: relative;
  margin-top: -54px;
  z-index: 4;
}

.section-title {
  text-align: center;
  margin-bottom: 30px;
}

.section-title.left {
  text-align: left;
}

.section-title span {
  color: var(--brand);
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-size: 13px;
}

.section-title h2 {
  margin: 6px 0 10px;
  font-size: clamp(26px, 4vw, 42px);
  line-height: 1.12;
  letter-spacing: -0.04em;
}

.section-title p {
  margin: 0 auto;
  max-width: 660px;
  color: var(--muted);
}

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

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

.movie-card {
  position: relative;
  overflow: hidden;
  border-radius: 22px;
  background: var(--card);
  box-shadow: var(--soft-shadow);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

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

.poster-link {
  position: relative;
  display: block;
  aspect-ratio: 3 / 4.15;
  overflow: hidden;
  background: linear-gradient(135deg, #dbeafe, #f0f9ff);
}

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

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

.poster-glow {
  position: absolute;
  inset: auto 0 0;
  height: 44%;
  background: linear-gradient(0deg, rgba(15, 23, 42, 0.50), transparent);
}

.card-body {
  padding: 18px;
}

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

.card-body h2 {
  margin: 8px 0 8px;
  font-size: 18px;
  line-height: 1.25;
}

.movie-card.compact .card-body h2 {
  font-size: 16px;
}

.card-body h2 a:hover {
  color: var(--brand);
}

.card-body p {
  margin: 0;
  color: #475569;
  font-size: 14px;
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 12px;
}

.tag-row span {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 0 9px;
  border-radius: 999px;
  color: #1d4ed8;
  background: #eff6ff;
  font-size: 12px;
  font-weight: 750;
}

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

.category-card {
  min-height: 260px;
  padding: 22px;
  border-radius: 28px;
  background: linear-gradient(145deg, #fff, #eff6ff);
  box-shadow: var(--soft-shadow);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 18px;
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

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

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

.category-stack img {
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: 14px;
  box-shadow: 0 10px 20px rgba(15, 23, 42, 0.12);
}

.category-card h2 {
  margin: 0 0 8px;
  font-size: 24px;
  letter-spacing: -0.03em;
}

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

.category-card span {
  color: var(--brand);
  font-weight: 900;
}

.two-col {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 34px;
}

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

.rank-list.wide {
  max-width: 900px;
  margin: 0 auto;
}

.rank-row {
  display: grid;
  grid-template-columns: 44px 58px minmax(0, 1fr) auto;
  align-items: center;
  gap: 14px;
  padding: 12px;
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.06);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.rank-row:hover {
  transform: translateX(4px);
  box-shadow: var(--soft-shadow);
}

.rank-num {
  width: 36px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  color: #fff;
  font-weight: 900;
  background: linear-gradient(135deg, var(--brand), var(--accent));
}

.rank-row img {
  width: 58px;
  height: 76px;
  object-fit: cover;
  border-radius: 12px;
}

.rank-info {
  min-width: 0;
}

.rank-info strong,
.rank-info em {
  display: block;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.rank-info em {
  color: var(--muted);
  font-style: normal;
  font-size: 13px;
}

.heat {
  color: #0f766e;
  font-weight: 900;
}

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

.more-link {
  display: inline-flex;
  margin-top: 18px;
  color: var(--brand);
  font-weight: 900;
}

.page-hero {
  position: relative;
  overflow: hidden;
  color: #fff;
  background:
    radial-gradient(circle at 15% 20%, rgba(6, 182, 212, 0.40), transparent 28rem),
    linear-gradient(135deg, #0f172a, #1e40af 55%, #0891b2);
}

.page-hero.slim {
  min-height: 300px;
  padding: 90px 24px 70px;
  text-align: center;
}

.page-hero h1 {
  margin: 12px 0;
  font-size: clamp(36px, 6vw, 64px);
  line-height: 1.05;
  letter-spacing: -0.05em;
}

.page-hero p {
  max-width: 720px;
  margin: 0 auto;
  color: #dbeafe;
  font-size: 18px;
}

.search-panel {
  margin-bottom: 28px;
  padding: 18px;
  border: 1px solid rgba(226, 232, 240, 0.9);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.84);
  box-shadow: var(--soft-shadow);
}

.search-panel label {
  display: grid;
  gap: 10px;
  color: #334155;
  font-weight: 850;
}

.search-panel input {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 16px;
  outline: 0;
  padding: 13px 16px;
  background: #fff;
}

.search-panel input:focus {
  border-color: #93c5fd;
  box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.12);
}

.filter-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin-top: 14px;
}

.filter-chips button {
  border: 0;
  border-radius: 999px;
  padding: 8px 14px;
  color: #334155;
  background: #e2e8f0;
  font-weight: 800;
  cursor: pointer;
}

.filter-chips button.is-active {
  color: #fff;
  background: linear-gradient(135deg, var(--brand), var(--brand-2));
}

.no-result {
  display: none;
  margin: 16px 0 0;
  color: #dc2626;
  font-weight: 800;
}

.no-result.is-visible {
  display: block;
}

.stack-sections {
  display: grid;
  gap: 28px;
}

.category-overview-card {
  padding: 26px;
  border-radius: 30px;
  background: #fff;
  box-shadow: var(--soft-shadow);
}

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

.detail-hero {
  position: relative;
  overflow: hidden;
  color: #fff;
  background: #0f172a;
}

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

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

.detail-backdrop span {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(15, 23, 42, 0.96), rgba(15, 23, 42, 0.68)),
    linear-gradient(0deg, rgba(15, 23, 42, 0.95), transparent 60%);
}

.detail-inner {
  position: relative;
  max-width: 1240px;
  margin: 0 auto;
  padding: 34px 24px 70px;
}

.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 18px 0 34px;
  color: #cbd5e1;
  font-size: 14px;
}

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

.detail-grid {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  gap: 38px;
  align-items: center;
}

.detail-poster img {
  aspect-ratio: 3 / 4.2;
  object-fit: cover;
  border-radius: 28px;
  box-shadow: 0 28px 60px rgba(0, 0, 0, 0.36);
}

.detail-copy h1 {
  margin: 14px 0 16px;
  font-size: clamp(36px, 7vw, 70px);
  line-height: 1.02;
  letter-spacing: -0.06em;
}

.one-line {
  max-width: 780px;
  color: #dbeafe;
  font-size: 19px;
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 20px;
}

.detail-meta span {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 0 12px;
  border-radius: 999px;
  color: #e0f2fe;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.18);
  font-weight: 800;
}

.detail-tags span {
  color: #e0f2fe;
  background: rgba(37, 99, 235, 0.42);
}

.detail-section {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 30px;
}

.player-card,
.story-card {
  border-radius: 30px;
  background: #fff;
  box-shadow: var(--shadow);
  overflow: hidden;
}

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

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

.play-layer {
  position: absolute;
  inset: 0;
  z-index: 3;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  border: 0;
  color: #fff;
  background: linear-gradient(0deg, rgba(2, 6, 23, 0.58), rgba(2, 6, 23, 0.22));
  cursor: pointer;
}

.play-layer.is-hidden {
  display: none;
}

.play-icon {
  width: 78px;
  height: 78px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding-left: 5px;
  border-radius: 50%;
  color: #fff;
  background: linear-gradient(135deg, var(--brand), var(--brand-2));
  box-shadow: 0 20px 45px rgba(37, 99, 235, 0.38);
  font-size: 30px;
}

.story-card {
  padding: 34px;
}

.story-card h2 {
  margin: 0 0 10px;
  font-size: 26px;
  letter-spacing: -0.03em;
}

.story-card h2:not(:first-child) {
  margin-top: 30px;
}

.story-card p {
  color: #334155;
  margin: 0;
  font-size: 17px;
}

.site-footer {
  margin-top: 56px;
  color: #cbd5e1;
  background: #0f172a;
}

.footer-inner {
  max-width: 1240px;
  margin: 0 auto;
  padding: 48px 24px;
  display: grid;
  grid-template-columns: 1.3fr 1fr 1fr;
  gap: 30px;
}

.footer-brand {
  display: grid;
  gap: 12px;
}

.footer-brand strong {
  color: #fff;
  font-size: 20px;
}

.footer-brand p {
  max-width: 420px;
  margin: 0;
  color: #94a3b8;
}

.footer-nav h2 {
  margin: 0 0 12px;
  color: #fff;
  font-size: 18px;
}

.footer-nav div {
  display: grid;
  gap: 8px;
}

.footer-nav a {
  color: #cbd5e1;
}

.footer-nav a:hover {
  color: #93c5fd;
}

.footer-copy {
  border-top: 1px solid rgba(148, 163, 184, 0.16);
  padding: 18px 24px;
  text-align: center;
  color: #94a3b8;
}

.is-filtered-out {
  display: none !important;
}

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

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

  .nav-links {
    gap: 14px;
    font-size: 14px;
  }
}

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

  .nav-toggle {
    display: inline-block;
  }

  .hero-carousel,
  .hero-slide > img {
    min-height: 620px;
  }

  .hero-content {
    left: 24px;
    right: 24px;
    bottom: 180px;
  }

  .hero-tools {
    flex-direction: column;
    align-items: stretch;
  }

  .hero-search {
    width: 100%;
  }

  .two-col,
  .detail-grid,
  .footer-inner {
    grid-template-columns: 1fr;
  }

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

  .movie-grid,
  .featured-grid,
  .compact-list,
  .side-feature {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 560px) {
  .nav-wrap {
    padding: 0 16px;
  }

  .brand-text {
    font-size: 17px;
  }

  .hero-carousel,
  .hero-slide > img {
    min-height: 590px;
  }

  .hero-content {
    bottom: 190px;
  }

  .hero-content p,
  .page-hero p,
  .one-line {
    font-size: 16px;
  }

  .hero-actions {
    align-items: stretch;
  }

  .btn {
    width: 100%;
  }

  .section-wrap {
    padding: 48px 16px;
  }

  .movie-grid,
  .featured-grid,
  .compact-list,
  .category-grid,
  .side-feature {
    grid-template-columns: 1fr;
  }

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

  .rank-row .heat {
    grid-column: 3;
  }

  .detail-inner {
    padding: 24px 16px 52px;
  }

  .story-card {
    padding: 24px;
  }
}
