:root {
  --rose-50: #fff1f2;
  --rose-100: #ffe4e6;
  --rose-400: #fb7185;
  --rose-500: #f43f5e;
  --rose-600: #e11d48;
  --pink-500: #ec4899;
  --purple-500: #a855f7;
  --text: #1f2937;
  --muted: #6b7280;
  --line: #f3d1d9;
  --card: #ffffff;
  --shadow: 0 22px 60px rgba(225, 29, 72, 0.13);
  --radius: 24px;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", "PingFang SC", Arial, sans-serif;
  color: var(--text);
  background: linear-gradient(135deg, #fff1f2 0%, #ffffff 42%, #fdf2f8 100%);
}

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

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

button,
input {
  font: inherit;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 241, 242, 0.92);
  backdrop-filter: blur(18px);
  border-bottom: 1px solid rgba(244, 63, 94, 0.16);
  box-shadow: 0 8px 28px rgba(244, 63, 94, 0.08);
}

.header-inner {
  min-height: 78px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}

.logo-mark {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 24px;
  font-weight: 800;
  background: linear-gradient(135deg, var(--rose-400), var(--pink-500));
  box-shadow: 0 12px 28px rgba(244, 63, 94, 0.35);
  transition: transform 0.25s ease;
}

.logo:hover .logo-mark {
  transform: scale(1.08) rotate(-6deg);
}

.logo-copy {
  display: grid;
  line-height: 1.2;
}

.logo-copy strong {
  font-size: 22px;
  letter-spacing: 0.02em;
  background: linear-gradient(90deg, var(--rose-600), var(--pink-500));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.logo-copy small {
  color: var(--muted);
  font-size: 12px;
}

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

.nav-link {
  position: relative;
  color: #4b5563;
  font-weight: 700;
  padding: 28px 0;
}

.nav-link::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 21px;
  width: 0;
  height: 2px;
  background: var(--rose-600);
  transition: width 0.25s ease;
}

.nav-link:hover,
.nav-link.is-active {
  color: var(--rose-600);
}

.nav-link:hover::after,
.nav-link.is-active::after {
  width: 100%;
}

.header-search,
.mobile-search,
.hero-search,
.local-search {
  display: flex;
  align-items: center;
  gap: 10px;
}

.header-search input,
.mobile-search input,
.hero-search input,
.local-search input {
  width: 100%;
  border: 2px solid var(--rose-100);
  border-radius: 999px;
  background: #fff;
  padding: 12px 18px;
  color: var(--text);
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.header-search input {
  width: 245px;
}

.header-search input:focus,
.mobile-search input:focus,
.hero-search input:focus,
.local-search input:focus {
  border-color: var(--rose-400);
  box-shadow: 0 0 0 4px rgba(251, 113, 133, 0.16);
}

.header-search button,
.mobile-search button,
.hero-search button {
  border: 0;
  border-radius: 999px;
  padding: 12px 18px;
  color: #fff;
  background: linear-gradient(90deg, var(--rose-500), var(--pink-500));
  cursor: pointer;
  box-shadow: 0 12px 24px rgba(244, 63, 94, 0.25);
}

.menu-toggle {
  display: none;
  border: 0;
  background: transparent;
  color: var(--rose-600);
  font-size: 28px;
  cursor: pointer;
}

.mobile-nav {
  display: none;
  padding: 0 16px 16px;
  border-top: 1px solid var(--rose-100);
  background: rgba(255, 255, 255, 0.96);
}

.mobile-link {
  display: block;
  padding: 13px 4px;
  border-bottom: 1px solid var(--rose-100);
  color: #4b5563;
  font-weight: 700;
}

.mobile-link.is-active,
.mobile-link:hover {
  color: var(--rose-600);
}

.hero-slider {
  position: relative;
  height: 620px;
  overflow: hidden;
  background: #111827;
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.7s ease;
  color: #fff;
}

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

.hero-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.03);
  transition: transform 4.5s ease;
}

.hero-slide.is-active img {
  transform: scale(1.08);
}

.hero-shadow,
.detail-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(17, 24, 39, 0.82), rgba(17, 24, 39, 0.48), rgba(17, 24, 39, 0.08));
}

.hero-content {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 18px;
  max-width: 1180px;
}

.hero-content em {
  font-style: normal;
  color: #fde68a;
  font-weight: 800;
}

.hero-content strong {
  max-width: 760px;
  font-size: clamp(42px, 7vw, 82px);
  line-height: 0.98;
  letter-spacing: -0.04em;
}

.hero-desc {
  max-width: 650px;
  color: #e5e7eb;
  font-size: 19px;
  line-height: 1.8;
}

.hero-tags,
.detail-tags,
.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
}

.hero-tags span,
.detail-tags span {
  padding: 9px 15px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
  backdrop-filter: blur(12px);
  color: #fff;
  font-weight: 700;
  font-size: 14px;
}

.hero-button,
.primary-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  padding: 15px 30px;
  color: #fff;
  background: linear-gradient(90deg, var(--rose-500), var(--pink-500));
  font-weight: 800;
  box-shadow: 0 18px 36px rgba(236, 72, 153, 0.35);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.hero-button:hover,
.primary-link:hover {
  transform: translateY(-2px) scale(1.02);
  box-shadow: 0 22px 42px rgba(236, 72, 153, 0.42);
}

.hero-controls {
  position: absolute;
  left: 50%;
  bottom: 32px;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  justify-content: space-between;
  pointer-events: none;
}

.hero-controls button {
  pointer-events: auto;
  border: 0;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  color: #111827;
  background: rgba(255, 255, 255, 0.88);
  cursor: pointer;
  font-size: 28px;
  box-shadow: 0 14px 32px rgba(17, 24, 39, 0.25);
}

.hero-dots {
  pointer-events: auto;
  display: flex;
  align-items: center;
  gap: 8px;
}

.hero-dot {
  width: 12px !important;
  height: 12px !important;
  padding: 0 !important;
  background: rgba(255, 255, 255, 0.52) !important;
}

.hero-dot.is-active {
  width: 34px !important;
  border-radius: 999px !important;
  background: #fff !important;
}

.quick-panel {
  position: relative;
  z-index: 2;
  margin-top: -46px;
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(300px, 0.7fr);
  gap: 22px;
  align-items: center;
  padding: 28px;
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.95);
  box-shadow: var(--shadow);
}

.quick-panel h1 {
  margin: 0 0 10px;
  font-size: clamp(26px, 4vw, 42px);
}

.quick-panel p,
.page-hero p,
.story-card p,
.info-card dd,
.card-body p {
  color: var(--muted);
  line-height: 1.8;
}

.section-block,
.ranking-section {
  padding: 68px 0 0;
}

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

.section-heading span,
.page-hero span {
  display: block;
  color: var(--rose-500);
  font-size: 13px;
  font-weight: 900;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.section-heading h2,
.page-hero h1,
.story-card h2,
.info-card h2 {
  margin: 4px 0 0;
  color: #111827;
}

.section-heading h2 {
  font-size: 32px;
}

.section-heading a {
  color: var(--rose-600);
  font-weight: 800;
}

.section-heading.light h2,
.section-heading.light span,
.section-heading.light a {
  color: #fff;
}

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

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

.movie-card {
  overflow: hidden;
  border-radius: 20px;
  background: var(--card);
  box-shadow: 0 16px 38px rgba(17, 24, 39, 0.08);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.movie-card:hover {
  transform: translateY(-7px);
  box-shadow: 0 24px 48px rgba(225, 29, 72, 0.16);
}

.poster-link {
  position: relative;
  display: block;
  height: 250px;
  overflow: hidden;
  background: #111827;
}

.movie-card.large .poster-link {
  height: 360px;
}

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

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

.year-badge,
.rank-badge {
  position: absolute;
  top: 12px;
  border-radius: 999px;
  color: #fff;
  font-size: 12px;
  font-weight: 800;
  padding: 6px 10px;
  background: rgba(17, 24, 39, 0.72);
  backdrop-filter: blur(8px);
}

.year-badge {
  right: 12px;
}

.rank-badge {
  left: 12px;
  background: linear-gradient(90deg, var(--rose-500), var(--pink-500));
}

.card-body {
  padding: 16px;
}

.card-title {
  display: -webkit-box;
  min-height: 48px;
  margin-bottom: 8px;
  overflow: hidden;
  color: #111827;
  font-size: 18px;
  font-weight: 900;
  line-height: 1.35;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.movie-card:hover .card-title {
  color: var(--rose-600);
}

.card-body p {
  display: -webkit-box;
  min-height: 50px;
  margin: 0 0 12px;
  overflow: hidden;
  font-size: 14px;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.meta-row {
  display: flex;
  gap: 10px;
  color: #6b7280;
  font-size: 13px;
  margin-bottom: 12px;
}

.meta-row span {
  min-width: 0;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.tag-row span {
  padding: 5px 9px;
  border-radius: 999px;
  background: linear-gradient(90deg, #fff1f2, #fdf2f8);
  color: var(--rose-600);
  font-size: 12px;
  font-weight: 700;
}

.category-section {
  padding-top: 76px;
}

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

.category-card,
.overview-card {
  position: relative;
  min-height: 210px;
  overflow: hidden;
  border-radius: 22px;
  background: #111827;
  box-shadow: var(--shadow);
}

.category-card img {
  width: 100%;
  height: 100%;
  min-height: 210px;
  object-fit: cover;
  opacity: 0.78;
  transition: transform 0.35s ease, opacity 0.35s ease;
}

.category-card:hover img {
  transform: scale(1.08);
  opacity: 0.95;
}

.category-card span {
  position: absolute;
  inset: auto 0 0;
  padding: 54px 18px 18px;
  color: #fff;
  background: linear-gradient(0deg, rgba(17, 24, 39, 0.88), transparent);
}

.category-card strong,
.overview-card strong {
  display: block;
  font-size: 20px;
  margin-bottom: 8px;
}

.category-card small,
.overview-card small {
  display: -webkit-box;
  overflow: hidden;
  line-height: 1.6;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.ranking-panel {
  padding: 34px;
  border-radius: 30px;
  background: linear-gradient(135deg, #7c3aed, #ec4899 52%, #f43f5e);
  box-shadow: 0 24px 56px rgba(124, 58, 237, 0.22);
}

.ranking-panel.full {
  margin-bottom: 44px;
}

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

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

.compact-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px;
  border-radius: 18px;
  color: #fff;
  background: rgba(255, 255, 255, 0.14);
  backdrop-filter: blur(14px);
  transition: transform 0.2s ease, background 0.2s ease;
}

.compact-card:hover {
  transform: translateY(-3px);
  background: rgba(255, 255, 255, 0.22);
}

.compact-card img {
  width: 78px;
  height: 58px;
  border-radius: 12px;
  object-fit: cover;
  flex-shrink: 0;
}

.compact-card strong {
  display: -webkit-box;
  overflow: hidden;
  line-height: 1.35;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 1;
}

.compact-card small {
  display: -webkit-box;
  overflow: hidden;
  margin-top: 4px;
  color: rgba(255, 255, 255, 0.78);
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 1;
}

.compact-rank {
  display: inline-flex;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  align-items: center;
  justify-content: center;
  color: var(--rose-600);
  background: #fff;
  font-weight: 900;
  flex-shrink: 0;
}

.page-main {
  padding: 42px 0 80px;
}

.page-hero {
  padding: 44px;
  margin-bottom: 28px;
  border-radius: 30px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: var(--shadow);
}

.page-hero h1 {
  font-size: clamp(32px, 5vw, 54px);
}

.category-hero,
.ranking-hero {
  background: linear-gradient(135deg, #fff, #fff1f2 46%, #fdf2f8);
}

.local-search {
  margin: 0 0 26px;
}

.local-search input {
  padding: 16px 22px;
  box-shadow: 0 12px 30px rgba(17, 24, 39, 0.07);
}

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

.overview-card {
  min-height: 255px;
  padding: 18px;
  color: #111827;
  background: #fff;
}

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

.overview-thumbs {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
  margin-bottom: 14px;
}

.overview-thumbs img {
  width: 100%;
  height: 78px;
  border-radius: 14px;
  object-fit: cover;
}

.overview-card small {
  color: var(--muted);
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 9px;
  margin-bottom: 18px;
  color: var(--muted);
  font-weight: 700;
}

.breadcrumb a {
  color: var(--rose-600);
}

.breadcrumb.invert {
  color: rgba(255, 255, 255, 0.8);
}

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

.detail-hero {
  position: relative;
  min-height: 620px;
  overflow: hidden;
  color: #fff;
  background: #111827;
}

.detail-hero > img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: blur(8px) saturate(1.05);
  transform: scale(1.08);
}

.detail-hero-content {
  position: relative;
  z-index: 1;
  padding: 44px 0 60px;
}

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

.detail-poster {
  overflow: hidden;
  border-radius: 28px;
  box-shadow: 0 26px 70px rgba(0, 0, 0, 0.36);
}

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

.detail-kicker {
  color: #fde68a;
  font-weight: 900;
}

.detail-info h1 {
  margin: 14px 0 18px;
  font-size: clamp(38px, 6vw, 72px);
  line-height: 1;
}

.detail-info p {
  max-width: 760px;
  margin: 0 0 22px;
  color: #e5e7eb;
  font-size: 18px;
  line-height: 1.8;
}

.player-section {
  margin-top: -96px;
  position: relative;
  z-index: 2;
}

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

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

.play-button {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  border: 0;
  color: #fff;
  background: radial-gradient(circle, rgba(0, 0, 0, 0.08), rgba(0, 0, 0, 0.46));
  cursor: pointer;
}

.play-button span {
  width: 96px;
  height: 96px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--rose-500), var(--pink-500));
  font-size: 34px;
  text-indent: 5px;
  box-shadow: 0 20px 48px rgba(244, 63, 94, 0.36);
  transition: transform 0.2s ease;
}

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

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

.detail-body {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 0.42fr);
  gap: 22px;
  padding-top: 42px;
}

.story-card,
.info-card {
  border-radius: 24px;
  padding: 26px;
  background: #fff;
  box-shadow: 0 16px 38px rgba(17, 24, 39, 0.08);
}

.story-card h2,
.info-card h2 {
  margin-bottom: 12px;
}

.story-card p {
  margin: 0;
}

.info-card {
  grid-row: span 2;
}

.info-card dl {
  margin: 0;
  display: grid;
  gap: 12px;
}

.info-card dt {
  color: var(--rose-600);
  font-weight: 900;
}

.info-card dd {
  margin: 0 0 8px;
}

.related-block {
  padding-bottom: 80px;
}

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

.site-footer {
  margin-top: 72px;
  color: #d1d5db;
  background: linear-gradient(90deg, #111827, #1f2937, #111827);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 0.7fr 0.9fr;
  gap: 36px;
  padding: 44px 0;
}

.footer-logo {
  color: #fff;
  font-size: 24px;
  font-weight: 900;
  margin-bottom: 12px;
}

.site-footer p {
  max-width: 560px;
  color: #9ca3af;
  line-height: 1.8;
}

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

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

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

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

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

@media (max-width: 1100px) {
  .header-search {
    display: none;
  }

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

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

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

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

  .menu-toggle {
    display: block;
  }

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

  .hero-slider {
    height: 560px;
  }

  .hero-content strong {
    font-size: 48px;
  }

  .quick-panel,
  .detail-layout,
  .detail-body,
  .footer-grid {
    grid-template-columns: 1fr;
  }

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

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

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

  .compact-list,
  .compact-list.three-column {
    grid-template-columns: 1fr;
  }
}

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

  .header-inner {
    min-height: 68px;
  }

  .logo-copy strong {
    font-size: 18px;
  }

  .logo-mark {
    width: 42px;
    height: 42px;
  }

  .hero-slider {
    height: 520px;
  }

  .hero-content {
    gap: 14px;
  }

  .hero-content strong {
    font-size: 40px;
  }

  .hero-desc {
    font-size: 16px;
  }

  .hero-controls {
    bottom: 18px;
  }

  .hero-controls > button {
    display: none;
  }

  .quick-panel,
  .page-hero,
  .ranking-panel,
  .story-card,
  .info-card {
    padding: 22px;
    border-radius: 22px;
  }

  .section-heading {
    align-items: flex-start;
    flex-direction: column;
  }

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

  .poster-link,
  .movie-card.large .poster-link {
    height: 300px;
  }

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

  .player-section {
    margin-top: -48px;
  }

  .play-button span {
    width: 76px;
    height: 76px;
  }
}
