:root {
  --site-blue: #2563eb;
  --site-blue-dark: #1d4ed8;
  --site-purple: #7c3aed;
  --site-ink: #0f172a;
  --site-muted: #64748b;
  --site-soft: #f8fafc;
  --site-card: #ffffff;
  --site-border: #e2e8f0;
  --site-warm: #fff7ed;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: #f8fafc;
  color: var(--site-ink);
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
}

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

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 80;
  background: linear-gradient(90deg, #2563eb 0%, #7c3aed 100%);
  color: #fff;
  box-shadow: 0 16px 40px rgba(37, 99, 235, 0.22);
}

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

.site-logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: #fff;
  font-weight: 800;
  font-size: 22px;
  letter-spacing: -0.02em;
}

.site-logo-mark {
  width: 36px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.18);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.24);
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 22px;
  font-weight: 650;
}

.nav-link {
  color: rgba(255, 255, 255, 0.86);
  padding: 8px 0;
}

.nav-link:hover,
.nav-link.active {
  color: #fff;
}

.mobile-menu-button {
  display: none;
  border: 0;
  background: transparent;
  color: #fff;
  font-size: 28px;
  cursor: pointer;
}

.mobile-menu {
  display: none;
  padding: 0 16px 16px;
  border-top: 1px solid rgba(255, 255, 255, 0.18);
}

.mobile-menu a {
  display: block;
  color: #fff;
  padding: 12px 0;
  font-weight: 650;
}

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

.hero-carousel {
  position: relative;
  height: 70vh;
  min-height: 520px;
  overflow: hidden;
  background: linear-gradient(135deg, #172554, #1e3a8a, #2563eb);
}

.hero-slides,
.hero-slide {
  position: absolute;
  inset: 0;
}

.hero-slide {
  opacity: 0;
  pointer-events: none;
  transition: opacity 900ms ease;
}

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

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

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.82), rgba(0, 0, 0, 0.36) 48%, rgba(0, 0, 0, 0.2));
}

.hero-content {
  position: relative;
  height: 100%;
  display: flex;
  align-items: flex-end;
  padding-bottom: 100px;
}

.hero-copy {
  color: #fff;
  max-width: 760px;
}

.hero-kicker,
.section-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #2563eb;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 12px;
  font-weight: 800;
}

.hero-kicker {
  color: #bfdbfe;
  background: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.24);
  border-radius: 999px;
  padding: 7px 12px;
  backdrop-filter: blur(10px);
}

.hero-copy h1 {
  margin: 18px 0 16px;
  font-size: clamp(40px, 6vw, 76px);
  line-height: 0.98;
  font-weight: 900;
  letter-spacing: -0.055em;
}

.hero-copy p {
  margin: 0 0 22px;
  max-width: 680px;
  font-size: clamp(17px, 2vw, 22px);
  line-height: 1.65;
  color: rgba(255, 255, 255, 0.9);
}

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

.hero-tags span,
.movie-tags span {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 6px 10px;
  background: #dbeafe;
  color: #2563eb;
  font-size: 12px;
  font-weight: 700;
}

.hero-tags span {
  color: #fff;
  background: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.22);
}

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

.primary-button,
.ghost-button,
.ghost-dark-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 20px;
  border-radius: 12px;
  font-weight: 800;
  transition: transform 180ms ease, box-shadow 180ms ease, background 180ms ease;
}

.primary-button {
  color: #fff;
  background: linear-gradient(135deg, var(--site-blue), var(--site-purple));
  box-shadow: 0 16px 30px rgba(37, 99, 235, 0.25);
}

.primary-button:hover,
.ghost-button:hover,
.ghost-dark-button:hover {
  transform: translateY(-2px);
}

.ghost-button {
  color: #fff;
  background: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.24);
  backdrop-filter: blur(12px);
}

.ghost-button.light {
  background: rgba(255, 255, 255, 0.22);
}

.ghost-dark-button {
  color: #1e3a8a;
  background: #eff6ff;
  border: 1px solid #bfdbfe;
}

.hero-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 5;
  width: 48px;
  height: 48px;
  border: 0;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.5);
  color: #fff;
  font-size: 36px;
  line-height: 1;
  cursor: pointer;
}

.hero-prev {
  left: 24px;
}

.hero-next {
  right: 24px;
}

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

.hero-dot {
  width: 12px;
  height: 12px;
  border-radius: 999px;
  border: 0;
  background: rgba(255, 255, 255, 0.5);
  cursor: pointer;
  transition: width 200ms ease, background 200ms ease;
}

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

.hero-quick-links {
  position: absolute;
  left: 50%;
  bottom: 82px;
  z-index: 6;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 10px;
  overflow-x: auto;
  padding-bottom: 2px;
}

.hero-quick-links a {
  white-space: nowrap;
  color: #fff;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 999px;
  padding: 8px 13px;
  font-size: 13px;
  backdrop-filter: blur(10px);
}

.hero-search-link {
  background: rgba(37, 99, 235, 0.5) !important;
}

.section-block {
  padding-top: 56px;
  padding-bottom: 56px;
}

.section-soft {
  padding-left: 24px;
  padding-right: 24px;
  border-radius: 28px;
  background: linear-gradient(135deg, #eff6ff 0%, #eef2ff 48%, #faf5ff 100%);
}

.section-warm {
  background: linear-gradient(90deg, #fff1f2, #fff7ed, #fefce8);
}

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

.section-heading h2 {
  margin: 6px 0 0;
  font-size: clamp(28px, 3.2vw, 42px);
  font-weight: 900;
  letter-spacing: -0.04em;
}

.section-heading a {
  color: #2563eb;
  font-weight: 800;
}

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

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

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

.movie-card {
  overflow: hidden;
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 10px 30px rgba(15, 23, 42, 0.08);
  transition: transform 220ms ease, box-shadow 220ms ease;
}

.movie-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 22px 48px rgba(15, 23, 42, 0.16);
}

.poster {
  position: relative;
  display: block;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: linear-gradient(135deg, #172554, #7c3aed);
}

.poster img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 300ms ease;
}

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

.poster::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.58), transparent 56%);
  opacity: 0.78;
}

.poster-play {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 2;
  width: 54px;
  height: 54px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transform: translate(-50%, -50%) scale(0.86);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.9);
  color: #2563eb;
  opacity: 0;
  transition: opacity 220ms ease, transform 220ms ease;
}

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

.rank-badge {
  position: absolute;
  left: 12px;
  top: 12px;
  z-index: 3;
  min-width: 36px;
  height: 36px;
  padding: 0 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: linear-gradient(135deg, #ef4444, #f97316);
  color: #fff;
  font-weight: 900;
  box-shadow: 0 12px 24px rgba(239, 68, 68, 0.26);
}

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

.movie-card-body h3 {
  margin: 0 0 10px;
  font-size: 18px;
  font-weight: 850;
  line-height: 1.28;
}

.movie-card-body h3 a {
  color: #0f172a;
}

.movie-card-body p {
  display: -webkit-box;
  min-height: 44px;
  margin: 0 0 12px;
  overflow: hidden;
  color: #64748b;
  line-height: 1.55;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.movie-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 12px;
  color: #64748b;
  font-size: 13px;
}

.movie-card-horizontal {
  display: grid;
  grid-template-columns: 190px 1fr;
  min-height: 128px;
}

.poster-horizontal {
  aspect-ratio: auto;
  height: 100%;
}

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

.split-list > div,
.rank-list {
  display: grid;
  gap: 18px;
}

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

.category-tile {
  position: relative;
  min-height: 190px;
  overflow: hidden;
  border-radius: 22px;
  padding: 18px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  color: #fff;
  background: #111827;
  box-shadow: 0 18px 42px rgba(15, 23, 42, 0.14);
}

.category-tile img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.72;
  transition: transform 300ms ease;
}

.category-tile::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.86), rgba(0, 0, 0, 0.18));
}

.category-tile:hover img {
  transform: scale(1.08);
}

.category-tile span,
.category-tile small {
  position: relative;
  z-index: 2;
}

.category-tile span {
  font-size: 22px;
  font-weight: 900;
}

.category-tile small {
  margin-top: 8px;
  color: rgba(255, 255, 255, 0.82);
  line-height: 1.5;
}

.seo-panel,
.link-panel {
  margin-bottom: 64px;
  border-radius: 28px;
  padding: 32px;
  background: #fff;
  box-shadow: 0 16px 42px rgba(15, 23, 42, 0.08);
}

.seo-panel h2,
.link-panel h2 {
  margin: 0 0 12px;
  font-size: 30px;
  font-weight: 900;
}

.seo-panel p,
.link-panel p {
  color: #475569;
  line-height: 1.8;
}

.link-panel div {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.link-panel a {
  border-radius: 999px;
  padding: 8px 12px;
  background: #eff6ff;
  color: #2563eb;
  font-weight: 700;
}

.page-shell {
  min-height: 68vh;
}

.page-hero {
  margin-top: 36px;
  margin-bottom: 28px;
  border-radius: 32px;
  padding: 52px;
  color: #fff;
  background: linear-gradient(135deg, #1e3a8a, #2563eb 48%, #7c3aed);
  box-shadow: 0 22px 60px rgba(37, 99, 235, 0.2);
}

.compact-hero h1 {
  margin: 10px 0 12px;
  font-size: clamp(34px, 5vw, 60px);
  line-height: 1;
  font-weight: 900;
  letter-spacing: -0.05em;
}

.compact-hero p {
  max-width: 800px;
  color: rgba(255, 255, 255, 0.88);
  font-size: 18px;
  line-height: 1.75;
}

.small-actions {
  margin-top: 20px;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 14px;
  color: rgba(255, 255, 255, 0.78);
  font-size: 14px;
}

.breadcrumb a {
  color: #fff;
}

.filter-bar {
  margin-bottom: 24px;
  display: grid;
  gap: 14px;
}

.filter-bar input {
  width: 100%;
  min-height: 52px;
  border-radius: 16px;
  border: 1px solid #dbeafe;
  padding: 0 18px;
  outline: none;
  background: #fff;
  color: #0f172a;
  font-size: 16px;
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.06);
}

.filter-bar input:focus {
  border-color: #2563eb;
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.12);
}

.filter-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.filter-chips button {
  border: 0;
  border-radius: 999px;
  padding: 8px 12px;
  background: #e0e7ff;
  color: #3730a3;
  font-weight: 700;
  cursor: pointer;
}

.category-overview-list {
  display: grid;
  gap: 26px;
  padding-bottom: 64px;
}

.category-overview-card {
  border-radius: 28px;
  padding: 24px;
  background: #fff;
  box-shadow: 0 16px 42px rgba(15, 23, 42, 0.08);
}

.category-overview-head {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 20px;
}

.category-overview-head h2 {
  margin: 0 0 8px;
  font-size: 28px;
  font-weight: 900;
}

.category-overview-head p {
  margin: 0;
  color: #64748b;
  line-height: 1.7;
}

.player-section {
  background: radial-gradient(circle at 50% 0%, #1e3a8a, #020617 58%);
  padding: 30px 0 34px;
}

.player-shell {
  position: relative;
  overflow: hidden;
  border-radius: 24px;
  background: #000;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.38);
}

.movie-video {
  position: relative;
  z-index: 1;
  width: 100%;
  aspect-ratio: 16 / 9;
  display: block;
  background: #000;
  cursor: pointer;
}

.player-cover {
  position: absolute;
  inset: 0;
  z-index: 2;
  border: 0;
  padding: 0;
  color: #fff;
  cursor: pointer;
  background: #000;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
}

.player-shell.is-playing .player-cover {
  display: none;
}

.player-cover-image,
.player-cover-mask {
  position: absolute;
  inset: 0;
}

.player-cover-image {
  background-position: center;
  background-size: cover;
  opacity: 0.72;
}

.player-cover-mask {
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.78), rgba(0, 0, 0, 0.28));
}

.player-play-button {
  position: relative;
  z-index: 3;
  width: 84px;
  height: 84px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.92);
  color: #2563eb;
  font-size: 34px;
  box-shadow: 0 20px 44px rgba(0, 0, 0, 0.28);
}

.player-play-text {
  position: relative;
  z-index: 3;
  font-size: 20px;
  font-weight: 900;
}

.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 28px;
  padding-top: 38px;
  padding-bottom: 28px;
}

.detail-main .breadcrumb {
  color: #64748b;
}

.detail-main .breadcrumb a {
  color: #2563eb;
}

.detail-header h1 {
  margin: 10px 0 12px;
  font-size: clamp(34px, 5vw, 58px);
  line-height: 1.05;
  font-weight: 900;
  letter-spacing: -0.055em;
}

.detail-header p {
  color: #475569;
  font-size: 18px;
  line-height: 1.75;
}

.info-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin: 26px 0;
}

.info-grid div,
.content-card,
.tag-card,
.detail-aside {
  border-radius: 22px;
  background: #fff;
  box-shadow: 0 16px 42px rgba(15, 23, 42, 0.08);
}

.info-grid div {
  padding: 18px;
}

.info-grid span {
  display: block;
  margin-bottom: 8px;
  color: #64748b;
  font-size: 13px;
}

.info-grid strong {
  font-size: 17px;
}

.content-card,
.tag-card {
  padding: 26px;
  margin-bottom: 20px;
}

.content-card h2,
.tag-card h2 {
  margin: 0 0 12px;
  font-size: 26px;
  font-weight: 900;
}

.content-card p {
  margin: 0;
  color: #334155;
  line-height: 1.9;
  font-size: 17px;
}

.tag-card div {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.tag-card a {
  border-radius: 999px;
  padding: 8px 12px;
  background: #eff6ff;
  color: #2563eb;
  font-weight: 700;
}

.detail-aside {
  position: sticky;
  top: 88px;
  align-self: start;
  padding: 18px;
}

.detail-aside img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: 18px;
  background: linear-gradient(135deg, #172554, #7c3aed);
}

.full-button {
  width: 100%;
  margin-top: 12px;
}

.site-footer {
  margin-top: 36px;
  background: #111827;
  color: #cbd5e1;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr;
  gap: 28px;
  padding: 44px 0;
}

.site-footer h2,
.site-footer h3 {
  margin: 0 0 14px;
  color: #fff;
}

.site-footer p {
  margin: 0;
  line-height: 1.75;
}

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

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

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

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding: 18px 16px;
  text-align: center;
  color: #94a3b8;
}

[hidden] {
  display: none !important;
}

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

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

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

  .detail-aside {
    position: static;
    max-width: 420px;
  }
}

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

  .mobile-menu-button {
    display: inline-flex;
  }

  .site-logo {
    font-size: 19px;
  }

  .hero-carousel {
    height: 78vh;
    min-height: 560px;
  }

  .hero-content {
    padding-bottom: 142px;
  }

  .hero-copy h1 {
    font-size: 42px;
  }

  .hero-arrow {
    display: none;
  }

  .hero-quick-links {
    bottom: 82px;
  }

  .section-heading,
  .category-overview-head {
    align-items: start;
    flex-direction: column;
  }

  .movie-grid,
  .dense-grid,
  .mini-grid,
  .category-grid,
  .split-list,
  .footer-grid,
  .info-grid {
    grid-template-columns: 1fr;
  }

  .movie-card-horizontal {
    grid-template-columns: 128px 1fr;
  }

  .page-hero {
    padding: 34px 24px;
  }

  .detail-header h1 {
    font-size: 38px;
  }
}

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

  .hero-actions {
    gap: 10px;
  }

  .primary-button,
  .ghost-button,
  .ghost-dark-button {
    width: 100%;
  }

  .movie-card-horizontal {
    grid-template-columns: 1fr;
  }

  .poster-horizontal {
    aspect-ratio: 16 / 10;
  }
}
