:root {
  --bg: #fff7fb;
  --text: #1f2937;
  --muted: #64748b;
  --panel: rgba(255, 255, 255, 0.9);
  --line: rgba(244, 114, 182, 0.18);
  --rose: #f43f5e;
  --pink: #ec4899;
  --purple: #8b5cf6;
  --blue: #2563eb;
  --shadow: 0 24px 80px rgba(190, 24, 93, 0.16);
  --radius: 24px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  background:
    radial-gradient(circle at 12% 8%, rgba(244, 114, 182, 0.2), transparent 28rem),
    radial-gradient(circle at 88% 0%, rgba(96, 165, 250, 0.18), transparent 26rem),
    linear-gradient(135deg, #fff7fb 0%, #fff1f2 42%, #eff6ff 100%);
}

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

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

button,
input,
select {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: blur(22px);
  background: rgba(255, 255, 255, 0.82);
  border-bottom: 1px solid rgba(244, 114, 182, 0.14);
}

.nav-wrap {
  width: min(1200px, calc(100% - 32px));
  margin: 0 auto;
  min-height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.logo,
.footer-logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 900;
  letter-spacing: 0.04em;
  color: #111827;
}

.logo-mark {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 14px;
  color: #fff;
  background: linear-gradient(135deg, var(--rose), var(--pink), var(--purple));
  box-shadow: 0 16px 32px rgba(236, 72, 153, 0.36);
}

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

.nav-links a {
  padding: 10px 16px;
  border-radius: 999px;
  color: #475569;
  font-weight: 700;
  transition: 0.25s ease;
}

.nav-links a:hover,
.nav-links a.active {
  color: #fff;
  background: linear-gradient(135deg, var(--rose), var(--pink));
  box-shadow: 0 12px 24px rgba(244, 63, 94, 0.24);
}

.menu-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 10px 30px rgba(15, 23, 42, 0.12);
}

.menu-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  margin: 4px auto;
  background: #111827;
  border-radius: 99px;
}

.hero-carousel {
  position: relative;
  min-height: clamp(620px, 82vh, 860px);
  overflow: hidden;
  background: linear-gradient(135deg, #111827 0%, #881337 46%, #312e81 100%);
}

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

.hero-slide {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(280px, 0.72fr);
  align-items: center;
  gap: clamp(28px, 5vw, 72px);
  width: min(1200px, calc(100% - 32px));
  margin: 0 auto;
  opacity: 0;
  pointer-events: none;
  transform: translateY(18px) scale(0.985);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

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

.hero-backdrop {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 50%;
  z-index: 0;
  width: 100vw;
  transform: translateX(-50%);
  background:
    linear-gradient(90deg, rgba(17, 24, 39, 0.94), rgba(136, 19, 55, 0.74), rgba(49, 46, 129, 0.72)),
    var(--hero-image) center / cover no-repeat;
  filter: saturate(1.15);
}

.hero-content {
  position: relative;
  z-index: 2;
  color: #fff;
  padding-top: 72px;
}

.eyebrow {
  margin: 0 0 14px;
  color: #fde68a;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.eyebrow.dark {
  color: var(--rose);
}

.hero-content h1 {
  max-width: 860px;
  margin: 0;
  font-size: clamp(36px, 5.5vw, 72px);
  line-height: 1.05;
  letter-spacing: -0.04em;
}

.hero-content h2 {
  margin: 22px 0 12px;
  font-size: clamp(24px, 3vw, 38px);
}

.hero-summary {
  max-width: 760px;
  margin: 0 0 28px;
  color: rgba(255, 255, 255, 0.88);
  font-size: clamp(17px, 2.1vw, 24px);
  line-height: 1.75;
}

.hero-tags,
.detail-meta,
.tag-list,
.meta-row,
.card-foot,
.hero-actions,
.inline-actions,
.next-links,
.footer-links {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}

.hero-tags a,
.hero-tags span,
.tag-list span,
.detail-meta span,
.pill {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 800;
  background: rgba(255, 255, 255, 0.18);
  color: #fff;
  backdrop-filter: blur(12px);
}

.detail-meta span,
.tag-list span,
.pill {
  color: #475569;
  background: #f8fafc;
}

.pill-hot {
  color: #be123c;
  background: #ffe4e6;
}

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

.btn-primary,
.btn-ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  padding: 0 24px;
  border-radius: 999px;
  font-weight: 900;
  transition: transform 0.25s ease, box-shadow 0.25s ease, background 0.25s ease;
}

.btn-primary {
  color: #fff;
  background: linear-gradient(135deg, var(--rose), var(--pink));
  box-shadow: 0 18px 40px rgba(244, 63, 94, 0.34);
}

.btn-ghost {
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.42);
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(14px);
}

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

.hero-poster {
  position: relative;
  z-index: 2;
  display: block;
  aspect-ratio: 3 / 4;
  border-radius: 34px;
  overflow: hidden;
  box-shadow: 0 34px 100px rgba(0, 0, 0, 0.42);
  transform: rotate(2deg);
}

.hero-poster::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.58), transparent 52%);
}

.hero-poster img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-controls {
  position: absolute;
  left: 50%;
  bottom: 32px;
  z-index: 5;
  display: flex;
  align-items: center;
  gap: 14px;
  transform: translateX(-50%);
}

.hero-prev,
.hero-next,
.hero-dot {
  border: 0;
  cursor: pointer;
}

.hero-prev,
.hero-next {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  color: #fff;
  font-size: 28px;
  background: rgba(255, 255, 255, 0.16);
  backdrop-filter: blur(12px);
}

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

.hero-dot {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.42);
}

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

.quick-search,
.section-wrap,
.filter-panel,
.detail-layout,
.player-section,
.category-preview {
  width: min(1200px, calc(100% - 32px));
  margin: 0 auto;
}

.quick-search {
  position: relative;
  z-index: 8;
  display: grid;
  grid-template-columns: 1fr minmax(260px, 420px);
  gap: 24px;
  align-items: center;
  margin-top: -46px;
  padding: 26px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.92);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}

.quick-search h2,
.section-title h2,
.detail-article h2,
.detail-side h2 {
  margin: 0;
  font-size: clamp(24px, 3vw, 36px);
  letter-spacing: -0.03em;
}

.quick-search input,
.filter-panel input,
.filter-panel select {
  width: 100%;
  min-height: 48px;
  border: 1px solid rgba(244, 114, 182, 0.24);
  border-radius: 999px;
  outline: none;
  padding: 0 18px;
  color: #111827;
  background: #fff;
  transition: box-shadow 0.2s ease, border-color 0.2s ease;
}

.quick-search input:focus,
.filter-panel input:focus,
.filter-panel select:focus {
  border-color: rgba(244, 63, 94, 0.58);
  box-shadow: 0 0 0 4px rgba(244, 63, 94, 0.12);
}

.section-wrap,
.category-preview {
  padding: 72px 0 0;
}

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

.section-title a {
  color: #be123c;
  font-weight: 900;
}

.section-title.light,
.section-title.light a {
  color: #fff;
}

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

.category-card {
  position: relative;
  min-height: 196px;
  overflow: hidden;
  padding: 22px;
  border-radius: 24px;
  background: #fff;
  box-shadow: 0 20px 60px rgba(15, 23, 42, 0.1);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.category-card::before {
  content: "";
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 0.25s ease;
}

.category-card strong,
.category-card em,
.category-card span {
  position: relative;
  display: block;
  z-index: 2;
}

.category-card strong {
  margin: 18px 0 8px;
  font-size: 22px;
}

.category-card em {
  min-height: 70px;
  color: #64748b;
  font-style: normal;
  line-height: 1.65;
}

.category-card .category-icon {
  display: grid;
  place-items: center;
  width: 56px;
  height: 56px;
  border-radius: 18px;
  color: #fff;
  font-weight: 900;
  background: linear-gradient(135deg, var(--rose), var(--pink));
}

.category-card:hover {
  color: #fff;
  transform: translateY(-8px);
  box-shadow: 0 28px 80px rgba(190, 24, 93, 0.24);
}

.category-card:hover::before {
  opacity: 1;
}

.category-card:hover em,
.category-card:hover span {
  color: rgba(255, 255, 255, 0.86);
}

.from-rose::before,
.page-hero.from-rose {
  background: linear-gradient(135deg, #fb7185, #ec4899);
}

.from-amber::before,
.page-hero.from-amber {
  background: linear-gradient(135deg, #f59e0b, #ef4444);
}

.from-violet::before,
.page-hero.from-violet {
  background: linear-gradient(135deg, #8b5cf6, #d946ef);
}

.from-blue::before,
.page-hero.from-blue {
  background: linear-gradient(135deg, #2563eb, #06b6d4);
}

.from-emerald::before,
.page-hero.from-emerald {
  background: linear-gradient(135deg, #10b981, #14b8a6);
}

.from-cyan::before,
.page-hero.from-cyan {
  background: linear-gradient(135deg, #06b6d4, #3b82f6);
}

.from-pink::before,
.page-hero.from-pink {
  background: linear-gradient(135deg, #ec4899, #f97316);
}

.from-red::before,
.page-hero.from-red {
  background: linear-gradient(135deg, #dc2626, #f97316);
}

.from-indigo::before,
.page-hero.from-indigo {
  background: linear-gradient(135deg, #4f46e5, #7c3aed);
}

.from-teal::before,
.page-hero.from-teal {
  background: linear-gradient(135deg, #0d9488, #22c55e);
}

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

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

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

.movie-card {
  overflow: hidden;
  border: 1px solid rgba(244, 114, 182, 0.12);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 18px 48px rgba(15, 23, 42, 0.08);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.movie-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 26px 70px rgba(190, 24, 93, 0.18);
}

.poster-link,
.poster-frame {
  display: block;
}

.poster-frame {
  position: relative;
  overflow: hidden;
  aspect-ratio: 2 / 3;
  background: linear-gradient(135deg, #111827, #881337);
}

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

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

.poster-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 35%, rgba(0, 0, 0, 0.78));
  opacity: 0;
  transition: opacity 0.25s ease;
}

.movie-card:hover .poster-shade {
  opacity: 1;
}

.play-chip,
.year-chip,
.rank-badge {
  position: absolute;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  font-weight: 900;
}

.play-chip {
  left: 14px;
  right: 14px;
  bottom: 14px;
  min-height: 40px;
  color: #fff;
  background: linear-gradient(135deg, var(--rose), var(--pink));
  opacity: 0;
  transform: translateY(12px);
  transition: 0.25s ease;
}

.movie-card:hover .play-chip {
  opacity: 1;
  transform: translateY(0);
}

.year-chip {
  top: 12px;
  right: 12px;
  min-height: 28px;
  padding: 0 10px;
  color: #fff;
  background: rgba(15, 23, 42, 0.72);
  backdrop-filter: blur(10px);
}

.rank-badge {
  top: 12px;
  left: 12px;
  width: 34px;
  height: 34px;
  color: #fff;
  background: linear-gradient(135deg, #f59e0b, #ef4444);
  box-shadow: 0 10px 24px rgba(239, 68, 68, 0.32);
}

.card-body {
  padding: 16px;
}

.meta-row {
  margin-bottom: 10px;
}

.card-body h3 {
  margin: 0 0 10px;
  font-size: 16px;
  line-height: 1.35;
}

.card-body h3 a:hover {
  color: var(--rose);
}

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

.card-foot {
  justify-content: space-between;
  margin-top: 14px;
  color: #94a3b8;
  font-size: 13px;
  font-weight: 800;
}

.feature-band {
  margin-top: 78px;
  padding: 72px max(16px, calc((100% - 1200px) / 2)) 82px;
  background:
    radial-gradient(circle at 0% 10%, rgba(244, 114, 182, 0.28), transparent 32rem),
    linear-gradient(135deg, #111827, #831843 52%, #312e81);
}

.page-hero,
.detail-hero {
  width: min(1200px, calc(100% - 32px));
  margin: 34px auto 0;
  overflow: hidden;
  border-radius: 32px;
  color: #fff;
  background:
    radial-gradient(circle at 18% 20%, rgba(255, 255, 255, 0.18), transparent 24rem),
    linear-gradient(135deg, #111827, #881337, #312e81);
  box-shadow: var(--shadow);
}

.page-hero {
  padding: clamp(44px, 8vw, 86px);
}

.page-hero h1 {
  margin: 0 0 16px;
  font-size: clamp(36px, 5vw, 64px);
  letter-spacing: -0.04em;
}

.page-hero p {
  max-width: 780px;
  margin: 0;
  color: rgba(255, 255, 255, 0.86);
  font-size: 18px;
  line-height: 1.8;
}

.compact-hero {
  background: linear-gradient(135deg, #881337, #ec4899, #2563eb);
}

.ranking-hero {
  background: linear-gradient(135deg, #111827, #be123c, #f59e0b);
}

.filter-panel {
  margin-top: 28px;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 18px 52px rgba(15, 23, 42, 0.08);
}

.filter-grid {
  display: grid;
  grid-template-columns: 1.4fr 0.6fr 0.6fr 0.6fr;
  gap: 14px;
}

.filter-grid label span {
  display: block;
  margin: 0 0 8px;
  color: #64748b;
  font-size: 13px;
  font-weight: 900;
}

.is-hidden {
  display: none !important;
}

.detail-hero {
  display: grid;
  grid-template-columns: minmax(240px, 360px) minmax(0, 1fr);
  gap: 34px;
  align-items: center;
  padding: clamp(24px, 4vw, 44px);
}

.detail-cover {
  overflow: hidden;
  border-radius: 26px;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.36);
}

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

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

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

.detail-info h1 {
  margin: 0 0 18px;
  font-size: clamp(34px, 5vw, 64px);
  line-height: 1.08;
  letter-spacing: -0.04em;
}

.detail-one-line {
  margin: 0 0 24px;
  color: rgba(255, 255, 255, 0.88);
  font-size: 20px;
  line-height: 1.7;
}

.player-section {
  padding-top: 34px;
}

.player-box {
  position: relative;
  overflow: hidden;
  border-radius: 30px;
  background: #020617;
  box-shadow: 0 30px 90px rgba(15, 23, 42, 0.28);
  aspect-ratio: 16 / 9;
}

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

.player-overlay {
  position: absolute;
  inset: 0;
  z-index: 4;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  border: 0;
  color: #fff;
  cursor: pointer;
  background: linear-gradient(180deg, rgba(2, 6, 23, 0.18), rgba(2, 6, 23, 0.76));
}

.play-circle {
  display: grid;
  place-items: center;
  width: 82px;
  height: 82px;
  border-radius: 50%;
  color: #fff;
  background: linear-gradient(135deg, var(--rose), var(--pink));
  box-shadow: 0 20px 46px rgba(244, 63, 94, 0.42);
}

.player-box.is-playing .player-overlay {
  opacity: 0;
  pointer-events: none;
}

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

.detail-article,
.detail-side {
  border: 1px solid var(--line);
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 18px 50px rgba(15, 23, 42, 0.08);
}

.detail-article {
  padding: clamp(24px, 4vw, 42px);
}

.detail-article p {
  margin: 16px 0 30px;
  color: #475569;
  font-size: 17px;
  line-height: 1.9;
}

.next-links {
  justify-content: space-between;
  border-top: 1px solid rgba(244, 114, 182, 0.16);
  padding-top: 24px;
}

.next-links a,
.side-card {
  color: #be123c;
  font-weight: 900;
}

.detail-side {
  align-self: start;
  padding: 24px;
}

.side-card {
  display: block;
  margin-top: 14px;
  padding: 16px;
  border-radius: 18px;
  background: #fff1f2;
}

.related-wrap {
  padding-bottom: 72px;
}

.site-footer {
  margin-top: 78px;
  padding: 42px 0;
  background: rgba(15, 23, 42, 0.96);
  color: rgba(255, 255, 255, 0.78);
}

.footer-inner {
  width: min(1200px, calc(100% - 32px));
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  gap: 28px;
}

.footer-logo {
  margin-bottom: 12px;
  color: #fff;
}

.footer-inner p {
  max-width: 640px;
  margin: 0;
  line-height: 1.7;
}

.footer-links a {
  color: #fff;
  font-weight: 800;
}

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

  .hero-slide {
    grid-template-columns: 1fr 320px;
  }
}

@media (max-width: 820px) {
  .menu-toggle {
    display: block;
  }

  .nav-links {
    position: absolute;
    left: 16px;
    right: 16px;
    top: 78px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    padding: 14px;
    border-radius: 22px;
    background: rgba(255, 255, 255, 0.96);
    box-shadow: 0 24px 70px rgba(15, 23, 42, 0.18);
  }

  .site-header.menu-open .nav-links {
    display: flex;
  }

  .hero-carousel {
    min-height: 860px;
  }

  .hero-slide {
    position: absolute;
    grid-template-columns: 1fr;
    align-content: center;
    padding: 94px 0 110px;
  }

  .hero-poster {
    width: min(280px, 72vw);
    margin: 0 auto;
    order: -1;
  }

  .quick-search,
  .filter-grid,
  .detail-hero,
  .detail-layout,
  .footer-inner {
    grid-template-columns: 1fr;
  }

  .quick-search,
  .section-title,
  .footer-inner {
    display: block;
  }

  .quick-search input {
    margin-top: 16px;
  }

  .category-grid,
  .movie-grid,
  .featured-grid,
  .ranking-grid,
  .small-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
  }

  .detail-side {
    order: -1;
  }
}

@media (max-width: 520px) {
  .nav-wrap,
  .quick-search,
  .section-wrap,
  .filter-panel,
  .detail-layout,
  .player-section,
  .category-preview,
  .page-hero,
  .detail-hero {
    width: min(100% - 20px, 1200px);
  }

  .card-body {
    padding: 13px;
  }

  .movie-grid,
  .featured-grid,
  .ranking-grid,
  .small-grid,
  .category-grid {
    grid-template-columns: 1fr 1fr;
    gap: 12px;
  }

  .category-card {
    min-height: 174px;
    padding: 16px;
  }

  .category-card strong {
    font-size: 18px;
  }

  .detail-hero {
    padding: 18px;
  }

  .player-box {
    border-radius: 20px;
  }
}
