:root {
  color-scheme: light;
  --pink: #ec4899;
  --pink-soft: #fce7f3;
  --purple: #8b5cf6;
  --blue: #60a5fa;
  --text: #1f2937;
  --muted: #6b7280;
  --line: #e5e7eb;
  --paper: #ffffff;
  --soft: #f8fafc;
  --dark: #111827;
  --shadow: 0 18px 45px rgba(15, 23, 42, 0.12);
  --radius: 24px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
  color: var(--text);
  background: linear-gradient(180deg, #fff7fb 0%, #f8fafc 38%, #eff6ff 100%);
  min-height: 100vh;
}

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

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

button,
input {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.92);
  border-bottom: 1px solid rgba(229, 231, 235, 0.9);
  box-shadow: 0 10px 35px rgba(15, 23, 42, 0.06);
  backdrop-filter: blur(18px);
}

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

.brand,
.footer-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;
  color: #ffffff;
  background: linear-gradient(135deg, var(--pink), var(--purple), var(--blue));
  border-radius: 15px;
  box-shadow: 0 14px 30px rgba(236, 72, 153, 0.28);
}

.brand-text,
.footer-brand span:last-child {
  font-size: 1.5rem;
  background: linear-gradient(90deg, var(--pink), var(--purple), var(--blue));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 18px;
  font-size: 0.95rem;
  color: #4b5563;
}

.nav-link {
  padding: 8px 0;
  transition: color 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
  color: var(--pink);
}

.menu-toggle {
  display: none;
  border: 0;
  background: #ffffff;
  color: var(--text);
  width: 42px;
  height: 42px;
  border-radius: 14px;
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.08);
}

.mobile-nav {
  display: none;
  width: min(1240px, calc(100% - 32px));
  margin: 0 auto;
  padding: 12px 0 18px;
  border-top: 1px solid var(--line);
}

.mobile-nav .nav-link {
  display: block;
  padding: 10px 0;
}

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

.hero-slide {
  position: absolute;
  isolation: isolate;
  inset: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  align-items: center;
  gap: 48px;
  width: min(1240px, calc(100% - 32px));
  margin: 0 auto;
  left: 50%;
  transform: translateX(-50%);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.7s ease, transform 0.7s ease;
}

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

.hero-backdrop {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 50%;
  z-index: 0;
  width: 100vw;
  transform: translateX(-50%);
  background-size: cover;
  background-position: center;
  filter: saturate(1.05);
}

.hero-backdrop::after,
.detail-backdrop::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 20% 25%, rgba(236, 72, 153, 0.35), transparent 28%), radial-gradient(circle at 80% 20%, rgba(96, 165, 250, 0.28), transparent 30%);
}

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

.eyebrow {
  margin: 0 0 14px;
  color: #f9a8d4;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.hero h1 {
  max-width: 840px;
  margin: 0 0 16px;
  font-size: clamp(2.6rem, 6vw, 5.2rem);
  line-height: 0.98;
  letter-spacing: -0.06em;
}

.hero h2 {
  margin: 0 0 18px;
  font-size: clamp(1.6rem, 3vw, 2.8rem);
  color: #fdf2f8;
}

.hero p {
  max-width: 720px;
  margin: 0 0 24px;
  color: rgba(255, 255, 255, 0.88);
  font-size: 1.12rem;
  line-height: 1.8;
}

.hero-tags,
.tag-row,
.detail-meta,
.filter-buttons,
.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.hero-tags span,
.tag-row span,
.detail-meta span {
  padding: 6px 12px;
  color: #be185d;
  background: rgba(252, 231, 243, 0.92);
  border-radius: 999px;
  font-size: 0.88rem;
  font-weight: 700;
}

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

.primary-button,
.ghost-button,
.section-more,
.hero-search button,
.filter-buttons button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 999px;
  font-weight: 800;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease, color 0.2s ease;
}

.primary-button {
  min-height: 48px;
  padding: 0 26px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--pink), var(--purple));
  box-shadow: 0 16px 30px rgba(236, 72, 153, 0.3);
}

.ghost-button {
  min-height: 48px;
  padding: 0 24px;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.34);
  backdrop-filter: blur(10px);
}

.primary-button:hover,
.ghost-button:hover,
.section-more:hover,
.hero-search button:hover,
.filter-buttons button:hover {
  transform: translateY(-2px);
}

.hero-poster {
  position: relative;
  z-index: 3;
  aspect-ratio: 3 / 4;
  border-radius: 32px;
  overflow: hidden;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.35);
  transform: rotate(2deg);
}

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

.hero-poster span {
  position: absolute;
  left: 24px;
  bottom: 24px;
  width: 58px;
  height: 58px;
  display: grid;
  place-items: center;
  color: var(--pink);
  background: rgba(255, 255, 255, 0.92);
  border-radius: 50%;
  box-shadow: 0 18px 30px rgba(0, 0, 0, 0.24);
}

.hero-controls {
  position: absolute;
  left: 50%;
  bottom: 118px;
  z-index: 5;
  width: min(1240px, calc(100% - 32px));
  transform: translateX(-50%);
  display: flex;
  gap: 10px;
}

.hero-dot {
  width: 34px;
  height: 8px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.4);
}

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

.hero-search {
  position: absolute;
  left: 50%;
  bottom: 34px;
  z-index: 5;
  width: min(760px, calc(100% - 32px));
  transform: translateX(-50%);
  display: flex;
  gap: 12px;
  padding: 10px;
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid rgba(255, 255, 255, 0.65);
  border-radius: 999px;
  box-shadow: 0 20px 45px rgba(15, 23, 42, 0.2);
  backdrop-filter: blur(18px);
}

.hero-search input,
.filter-panel input {
  width: 100%;
  border: 0;
  outline: none;
  color: var(--text);
  background: transparent;
}

.hero-search input {
  padding: 0 18px;
}

.hero-search button {
  flex: 0 0 auto;
  min-height: 44px;
  padding: 0 24px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--pink), var(--purple));
}

.category-strip {
  width: min(1240px, calc(100% - 32px));
  margin: 28px auto 0;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
}

.category-strip a {
  padding: 12px 18px;
  color: #be185d;
  background: #ffffff;
  border: 1px solid rgba(244, 114, 182, 0.22);
  border-radius: 999px;
  box-shadow: 0 14px 28px rgba(236, 72, 153, 0.08);
  font-weight: 800;
}

.content-section {
  width: min(1240px, calc(100% - 32px));
  margin: 54px auto;
}

.soft-section {
  padding: 30px;
  background: rgba(255, 255, 255, 0.64);
  border: 1px solid rgba(255, 255, 255, 0.9);
  border-radius: 32px;
  box-shadow: 0 24px 70px rgba(15, 23, 42, 0.07);
}

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

.section-heading h2 {
  margin: 0;
  font-size: clamp(1.75rem, 3vw, 2.55rem);
  line-height: 1.15;
  letter-spacing: -0.04em;
}

.section-heading p {
  margin: 8px 0 0;
  color: var(--muted);
  line-height: 1.75;
}

.section-more {
  flex: 0 0 auto;
  min-height: 42px;
  padding: 0 18px;
  color: var(--pink);
  background: var(--pink-soft);
}

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

.movie-card {
  min-width: 0;
}

.movie-card a {
  display: block;
  height: 100%;
  background: #ffffff;
  border: 1px solid rgba(229, 231, 235, 0.75);
  border-radius: var(--radius);
  box-shadow: 0 14px 35px rgba(15, 23, 42, 0.08);
  overflow: hidden;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

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

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

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

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

.poster-hover {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: var(--pink);
  background: rgba(17, 24, 39, 0.42);
  opacity: 0;
  transition: opacity 0.25s ease;
}

.poster-hover span {
  width: 60px;
  height: 60px;
  display: grid;
  place-items: center;
  background: rgba(255, 255, 255, 0.94);
  border-radius: 50%;
}

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

.type-badge,
.heat-badge,
.rank-badge {
  position: absolute;
  z-index: 2;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 800;
}

.type-badge {
  top: 12px;
  left: 12px;
  padding: 5px 10px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--pink), var(--purple));
}

.heat-badge {
  right: 12px;
  bottom: 12px;
  padding: 5px 10px;
  color: #be185d;
  background: rgba(255, 255, 255, 0.92);
}

.rank-badge {
  top: 12px;
  right: 12px;
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  color: #ffffff;
  background: rgba(17, 24, 39, 0.88);
}

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

.movie-card h3 {
  margin: 0 0 8px;
  font-size: 1.06rem;
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.movie-meta,
.movie-line {
  margin: 0;
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.65;
}

.movie-line {
  min-height: 4.8em;
  margin-top: 8px;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.tag-row {
  margin-top: 12px;
}

.tag-row span {
  padding: 5px 9px;
  font-size: 0.78rem;
}

.movie-card-compact .movie-line {
  display: none;
}

.page-hero {
  min-height: 320px;
  display: grid;
  place-items: center;
  padding: 70px 16px;
  text-align: center;
  color: #ffffff;
  background: linear-gradient(135deg, #f472b6, #a78bfa 55%, #60a5fa);
  overflow: hidden;
  position: relative;
}

.page-hero::before {
  content: "";
  position: absolute;
  width: 460px;
  height: 460px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.18);
  top: -210px;
  right: -120px;
}

.page-hero div {
  position: relative;
  max-width: 780px;
}

.page-hero h1 {
  margin: 0 0 18px;
  font-size: clamp(2.4rem, 5vw, 4.4rem);
  line-height: 1.05;
  letter-spacing: -0.05em;
}

.page-hero p:last-child {
  margin: 0;
  color: rgba(255, 255, 255, 0.9);
  font-size: 1.1rem;
  line-height: 1.8;
}

.filter-panel {
  margin-bottom: 24px;
  padding: 20px;
  display: grid;
  gap: 16px;
  background: rgba(255, 255, 255, 0.86);
  border: 1px solid rgba(255, 255, 255, 0.9);
  border-radius: 28px;
  box-shadow: 0 18px 45px rgba(15, 23, 42, 0.08);
}

.filter-panel label {
  display: grid;
  gap: 8px;
  color: var(--muted);
  font-weight: 700;
}

.filter-panel input {
  height: 50px;
  padding: 0 18px;
  background: #ffffff;
  border: 1px solid var(--line);
  border-radius: 18px;
}

.filter-buttons button {
  min-height: 38px;
  padding: 0 16px;
  color: #6b21a8;
  background: #f3e8ff;
}

.filter-buttons button.is-active {
  color: #ffffff;
  background: linear-gradient(135deg, var(--pink), var(--purple));
}

.empty-state {
  padding: 24px;
  text-align: center;
  color: var(--muted);
  background: #ffffff;
  border-radius: 22px;
}

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

.category-tile a {
  position: relative;
  display: block;
  min-height: 260px;
  overflow: hidden;
  border-radius: 30px;
  background: #111827;
  box-shadow: var(--shadow);
}

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

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

.category-tile div {
  position: absolute;
  inset: auto 0 0;
  padding: 28px;
  color: #ffffff;
  background: linear-gradient(180deg, transparent, rgba(17, 24, 39, 0.92));
}

.category-tile h2 {
  margin: 0 0 10px;
  font-size: 1.6rem;
}

.category-tile p {
  margin: 0 0 18px;
  line-height: 1.65;
  color: rgba(255, 255, 255, 0.86);
}

.category-tile span {
  font-weight: 800;
  color: #f9a8d4;
}

.detail-page {
  background: #f8fafc;
}

.detail-hero {
  position: relative;
  min-height: 620px;
  overflow: hidden;
  color: #ffffff;
  background: var(--dark);
}

.detail-backdrop {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  filter: saturate(1.08);
}

.detail-shell {
  position: relative;
  z-index: 2;
  width: min(1180px, calc(100% - 32px));
  min-height: 620px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 320px minmax(0, 1fr);
  align-items: center;
  gap: 44px;
  padding: 58px 0;
}

.detail-poster {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: 30px;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.45);
}

.breadcrumb {
  margin-bottom: 22px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: rgba(255, 255, 255, 0.74);
  font-size: 0.92rem;
}

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

.detail-info h1 {
  margin: 0 0 18px;
  font-size: clamp(2.5rem, 5vw, 5rem);
  line-height: 1;
  letter-spacing: -0.06em;
}

.detail-line {
  max-width: 760px;
  margin: 0 0 22px;
  color: rgba(255, 255, 255, 0.88);
  font-size: 1.15rem;
  line-height: 1.8;
}

.detail-meta {
  margin-bottom: 16px;
}

.detail-tags {
  margin-bottom: 28px;
}

.player-section {
  width: min(1180px, calc(100% - 32px));
  margin: 54px auto;
}

.player-shell {
  position: relative;
  overflow: hidden;
  background: #000000;
  border-radius: 30px;
  box-shadow: 0 24px 70px rgba(15, 23, 42, 0.22);
}

.video-player {
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #000000;
}

.player-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 16px;
  color: #ffffff;
  background: radial-gradient(circle at center, rgba(236, 72, 153, 0.22), rgba(0, 0, 0, 0.56));
  cursor: pointer;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

.player-overlay.is-hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.player-button {
  width: 86px;
  height: 86px;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 50%;
  color: var(--pink);
  background: #ffffff;
  box-shadow: 0 20px 45px rgba(0, 0, 0, 0.28);
  font-size: 2rem;
}

.player-overlay strong {
  font-size: 1.15rem;
}

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

.story-card {
  padding: 28px;
  background: #ffffff;
  border: 1px solid rgba(229, 231, 235, 0.9);
  border-radius: 28px;
  box-shadow: 0 16px 40px rgba(15, 23, 42, 0.07);
}

.story-card h2 {
  margin: 0 0 14px;
  font-size: 1.55rem;
}

.story-card p {
  margin: 0;
  color: #4b5563;
  line-height: 1.9;
}

.site-footer {
  margin-top: 80px;
  background: linear-gradient(135deg, #fdf2f8, #f5f3ff 55%, #eff6ff);
  border-top: 1px solid rgba(229, 231, 235, 0.8);
}

.footer-grid {
  width: min(1240px, calc(100% - 32px));
  margin: 0 auto;
  padding: 50px 0;
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1.2fr;
  gap: 34px;
}

.site-footer h2 {
  margin: 0 0 14px;
  font-size: 1.05rem;
}

.site-footer p,
.site-footer li {
  color: var(--muted);
  line-height: 1.8;
}

.site-footer ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.site-footer a:hover {
  color: var(--pink);
}

.footer-bottom {
  width: min(1240px, calc(100% - 32px));
  margin: 0 auto;
  padding: 22px 0;
  text-align: center;
  color: var(--muted);
  border-top: 1px solid rgba(229, 231, 235, 0.9);
}

[data-search-card][hidden] {
  display: none;
}

@media (max-width: 1180px) {
  .desktop-nav {
    gap: 12px;
    font-size: 0.88rem;
  }

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

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

  .menu-toggle {
    display: inline-grid;
    place-items: center;
  }

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

  .hero {
    min-height: 780px;
  }

  .hero-slide {
    grid-template-columns: 1fr;
    align-content: start;
    gap: 24px;
    padding-top: 58px;
  }

  .hero-content {
    padding-top: 12px;
  }

  .hero-poster {
    width: min(250px, 62vw);
    margin: 0 auto;
  }

  .hero-controls {
    bottom: 132px;
  }

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

  .category-grid,
  .story-section,
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }

  .detail-shell {
    grid-template-columns: 1fr;
    gap: 28px;
    text-align: left;
  }

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

@media (max-width: 640px) {
  .nav-shell {
    height: 64px;
  }

  .brand-text,
  .footer-brand span:last-child {
    font-size: 1.2rem;
  }

  .hero {
    min-height: 820px;
  }

  .hero h1 {
    font-size: 2.55rem;
  }

  .hero-search {
    border-radius: 24px;
    flex-direction: column;
    bottom: 24px;
  }

  .hero-search input {
    height: 44px;
  }

  .hero-controls {
    bottom: 150px;
  }

  .content-section,
  .player-section {
    margin: 36px auto;
  }

  .soft-section {
    padding: 18px;
    border-radius: 24px;
  }

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

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

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

  .movie-line {
    min-height: auto;
    -webkit-line-clamp: 2;
  }

  .category-grid,
  .story-section,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .page-hero {
    min-height: 260px;
    padding: 54px 16px;
  }

  .detail-hero,
  .detail-shell {
    min-height: auto;
  }

  .detail-info h1 {
    font-size: 2.6rem;
  }

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

  .player-button {
    width: 68px;
    height: 68px;
    font-size: 1.55rem;
  }
}
