:root {
  color-scheme: light;
  --bg: #fff7f8;
  --panel: #ffffff;
  --panel-soft: #fff1f2;
  --text: #111827;
  --muted: #6b7280;
  --line: rgba(244, 63, 94, 0.16);
  --rose: #e11d48;
  --rose-dark: #be123c;
  --pink: #db2777;
  --shadow: 0 24px 70px rgba(136, 19, 55, 0.14);
  --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", "PingFang SC", "Microsoft YaHei", sans-serif;
  color: var(--text);
  background: radial-gradient(circle at top left, #ffe4e6 0, rgba(255, 228, 230, 0) 32rem), var(--bg);
  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, 247, 248, 0.86);
  backdrop-filter: blur(18px);
  border-bottom: 1px solid rgba(244, 63, 94, 0.12);
}

.header-inner {
  width: min(1200px, calc(100% - 32px));
  margin: 0 auto;
  height: 76px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

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

.brand-mark {
  width: 42px;
  height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--rose), var(--pink));
  color: #ffffff;
  box-shadow: 0 14px 32px rgba(225, 29, 72, 0.3);
}

.brand-text {
  font-size: 1.15rem;
  background: linear-gradient(135deg, var(--rose-dark), var(--pink));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

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

.nav-link {
  position: relative;
  color: #4b5563;
  font-weight: 700;
  transition: color 0.2s ease;
}

.nav-link::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -10px;
  width: 0;
  height: 3px;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--rose), var(--pink));
  transition: width 0.2s ease;
}

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

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

.menu-button {
  display: none;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 16px;
  background: #ffe4e6;
  padding: 10px;
}

.menu-button span {
  display: block;
  height: 2px;
  margin: 5px 0;
  background: var(--rose-dark);
  border-radius: 99px;
}

.mobile-nav {
  display: none;
  width: min(1200px, calc(100% - 32px));
  margin: 0 auto 16px;
  padding: 12px;
  border-radius: 20px;
  background: #ffffff;
  box-shadow: var(--shadow);
}

.mobile-nav.open {
  display: grid;
  gap: 8px;
}

.mobile-link {
  padding: 12px 14px;
  border-radius: 14px;
  background: #fff1f2;
  color: var(--rose-dark);
  font-weight: 700;
}

.hero-section {
  position: relative;
  width: min(1280px, calc(100% - 32px));
  margin: 26px auto 0;
}

.hero-slider {
  position: relative;
  overflow: hidden;
  min-height: 600px;
  border-radius: 34px;
  background: #111827;
  box-shadow: 0 34px 90px rgba(17, 24, 39, 0.24);
}

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

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

.hero-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
}

.hero-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 20% 30%, rgba(244, 63, 94, 0.26), transparent 30%), linear-gradient(0deg, rgba(17, 24, 39, 0.6), rgba(17, 24, 39, 0.08));
}

.hero-content {
  position: relative;
  z-index: 2;
  min-height: 600px;
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) 360px;
  align-items: center;
  gap: 48px;
  padding: 76px;
  color: #ffffff;
}

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

.hero-kicker,
.section-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 14px;
  font-size: 0.82rem;
  font-weight: 900;
  color: var(--rose);
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.hero-kicker {
  color: #fecdd3;
}

.hero-copy h1 {
  margin: 0;
  font-size: clamp(2.8rem, 6vw, 5.8rem);
  line-height: 0.95;
  letter-spacing: -0.07em;
  text-shadow: 0 12px 44px rgba(0, 0, 0, 0.34);
}

.hero-one-line {
  max-width: 700px;
  margin: 24px 0 0;
  font-size: clamp(1rem, 2vw, 1.25rem);
  line-height: 1.9;
  color: rgba(255, 255, 255, 0.88);
}

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

.hero-tags {
  margin-top: 24px;
}

.hero-tags span,
.detail-tags span,
.tag-row span {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 6px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.16);
  color: #ffffff;
  font-size: 0.82rem;
  font-weight: 700;
  backdrop-filter: blur(10px);
}

.detail-tags span,
.tag-row span {
  background: #fff1f2;
  color: var(--rose-dark);
}

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

.primary-button,
.ghost-button,
.section-more,
.category-open {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 22px;
  border-radius: 999px;
  font-weight: 900;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.primary-button {
  color: #ffffff;
  background: linear-gradient(135deg, var(--rose), var(--pink));
  box-shadow: 0 16px 38px rgba(225, 29, 72, 0.32);
}

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

.ghost-button.dark {
  color: var(--rose-dark);
  border-color: rgba(225, 29, 72, 0.18);
  background: #fff1f2;
}

.primary-button:hover,
.ghost-button:hover,
.section-more:hover,
.category-open:hover {
  transform: translateY(-2px);
}

.hero-poster {
  overflow: hidden;
  aspect-ratio: 2 / 3;
  border-radius: 30px;
  box-shadow: 0 30px 70px rgba(0, 0, 0, 0.38);
  transform: rotate(2deg);
}

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

.hero-controls {
  position: absolute;
  z-index: 3;
  left: 76px;
  right: 76px;
  bottom: 38px;
  display: flex;
  align-items: center;
  gap: 16px;
}

.hero-arrow,
.hero-dot {
  border: 0;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.14);
  backdrop-filter: blur(12px);
}

.hero-arrow {
  width: 44px;
  height: 44px;
  border-radius: 999px;
  font-size: 1.8rem;
  line-height: 1;
}

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

.hero-dot {
  width: 34px;
  height: 6px;
  border-radius: 99px;
  padding: 0;
  opacity: 0.62;
}

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

.hero-bottom-panel {
  position: relative;
  z-index: 4;
  width: calc(100% - 56px);
  margin: -56px auto 0;
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(240px, 0.6fr) minmax(280px, 0.9fr);
  gap: 18px;
}

.hero-search-card,
.hero-category-card,
.hero-mini-list {
  border: 1px solid rgba(244, 63, 94, 0.14);
  border-radius: 26px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}

.hero-search-card,
.hero-category-card {
  padding: 22px;
}

.hero-search-card p,
.hero-category-card p {
  margin: 0 0 12px;
  color: var(--muted);
  font-weight: 800;
}

.hero-search-row {
  display: flex;
  gap: 12px;
}

.hero-search-row input,
.search-box input {
  width: 100%;
  border: 1px solid rgba(244, 63, 94, 0.18);
  border-radius: 999px;
  outline: 0;
  padding: 14px 18px;
  color: var(--text);
  background: #fff7f8;
}

.hero-search-row a {
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  padding: 0 18px;
  color: #ffffff;
  font-weight: 900;
  background: var(--text);
}

.hero-category-card div,
.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.hero-category-card a,
.footer-links a {
  padding: 9px 12px;
  border-radius: 999px;
  background: #fff1f2;
  color: var(--rose-dark);
  font-size: 0.86rem;
  font-weight: 800;
}

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

.hero-mini-card {
  display: grid;
  grid-template-columns: 54px 1fr;
  align-items: center;
  gap: 10px;
  min-width: 0;
  padding: 8px;
  border-radius: 18px;
  background: #fff7f8;
  color: #374151;
  font-weight: 800;
}

.hero-mini-card img {
  width: 54px;
  height: 72px;
  border-radius: 14px;
  object-fit: cover;
  background: #ffe4e6;
}

.hero-mini-card span {
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

main,
.sub-page,
.detail-page {
  width: min(1200px, calc(100% - 32px));
  margin: 0 auto;
}

.page-section {
  padding: 72px 0 0;
}

.soft-section {
  margin-top: 72px;
  padding: 56px;
  border-radius: 34px;
  background: rgba(255, 255, 255, 0.62);
  border: 1px solid rgba(244, 63, 94, 0.14);
}

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

.section-header h2,
.sub-hero h1,
.detail-info h1 {
  margin: 0;
  font-size: clamp(2rem, 4vw, 3.6rem);
  line-height: 1.05;
  letter-spacing: -0.05em;
}

.section-header p,
.sub-hero p,
.detail-one-line {
  max-width: 760px;
  margin: 10px 0 0;
  color: var(--muted);
  line-height: 1.9;
}

.section-more,
.category-open {
  color: var(--rose-dark);
  background: #ffe4e6;
}

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

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

.movie-card {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius);
  background: var(--panel);
  border: 1px solid rgba(244, 63, 94, 0.12);
  box-shadow: 0 18px 44px rgba(136, 19, 55, 0.08);
  transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  border-color: rgba(225, 29, 72, 0.32);
  box-shadow: 0 26px 62px rgba(136, 19, 55, 0.16);
}

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

.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);
}

.rank-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  padding: 7px 10px;
  border-radius: 999px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--rose), var(--pink));
  font-size: 0.75rem;
  font-weight: 900;
  box-shadow: 0 10px 22px rgba(225, 29, 72, 0.3);
}

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

.movie-meta-line {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: var(--rose-dark);
  font-size: 0.78rem;
  font-weight: 800;
}

.movie-card h3 {
  margin: 10px 0 8px;
  font-size: 1.04rem;
  line-height: 1.35;
}

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

.movie-card p {
  min-height: 48px;
  margin: 0 0 12px;
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.7;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.movie-card-compact .movie-card-body {
  padding: 14px;
}

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

.tag-row {
  gap: 7px;
}

.tag-row span {
  min-height: 26px;
  padding: 4px 8px;
  font-size: 0.72rem;
}

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

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

.category-card {
  display: flex;
  min-height: 220px;
  flex-direction: column;
  justify-content: space-between;
  gap: 18px;
  padding: 24px;
  border-radius: 28px;
  background: linear-gradient(145deg, #ffffff, #fff1f2);
  border: 1px solid rgba(244, 63, 94, 0.14);
  box-shadow: var(--shadow);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.category-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 30px 72px rgba(136, 19, 55, 0.18);
}

.category-card span {
  color: var(--rose-dark);
  font-size: 1.3rem;
  font-weight: 900;
}

.category-card strong {
  color: #374151;
  line-height: 1.8;
}

.category-card small {
  color: var(--muted);
  line-height: 1.7;
}

.category-samples {
  display: grid;
  gap: 8px;
}

.category-samples a {
  color: #4b5563;
  font-weight: 700;
}

.filter-panel {
  display: grid;
  grid-template-columns: minmax(260px, 0.9fr) minmax(0, 1.5fr);
  gap: 18px;
  align-items: center;
  margin-bottom: 28px;
  padding: 18px;
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid rgba(244, 63, 94, 0.14);
  box-shadow: 0 16px 46px rgba(136, 19, 55, 0.08);
}

.search-box {
  display: grid;
  gap: 8px;
}

.search-box span {
  color: var(--rose-dark);
  font-weight: 900;
}

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

.filter-chip {
  border: 0;
  border-radius: 999px;
  padding: 11px 15px;
  color: #4b5563;
  background: #fff1f2;
  font-weight: 800;
  transition: color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.filter-chip:hover,
.filter-chip.active {
  color: #ffffff;
  background: linear-gradient(135deg, var(--rose), var(--pink));
  transform: translateY(-1px);
}

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

.empty-state.show {
  display: block;
}

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

.ranking-item {
  display: grid;
  grid-template-columns: 54px 74px 1fr;
  align-items: center;
  gap: 14px;
  padding: 14px;
  border-radius: 22px;
  background: #ffffff;
  border: 1px solid rgba(244, 63, 94, 0.12);
  box-shadow: 0 16px 42px rgba(136, 19, 55, 0.08);
}

.ranking-item > span {
  font-size: 1.25rem;
  color: var(--rose);
  font-weight: 900;
}

.ranking-item img {
  width: 74px;
  height: 98px;
  object-fit: cover;
  border-radius: 16px;
  background: #ffe4e6;
}

.ranking-item strong {
  font-size: 1.04rem;
}

.ranking-item p {
  margin: 8px 0 0;
  color: var(--muted);
  line-height: 1.6;
}

.scroll-row {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(190px, 1fr);
  gap: 18px;
  overflow-x: auto;
  padding-bottom: 12px;
  scroll-snap-type: x proximity;
}

.scroll-row .movie-card {
  min-width: 190px;
  scroll-snap-align: start;
}

.sub-page {
  padding-top: 54px;
}

.sub-hero {
  padding: 58px;
  border-radius: 34px;
  background: linear-gradient(135deg, #ffffff, #fff1f2);
  border: 1px solid rgba(244, 63, 94, 0.16);
  box-shadow: var(--shadow);
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-top: 20px;
  color: var(--muted);
  font-size: 0.92rem;
}

.breadcrumb a {
  color: var(--rose-dark);
  font-weight: 800;
}

.detail-page {
  padding-top: 34px;
}

.detail-breadcrumb {
  margin: 0 0 24px;
}

.detail-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.18fr) minmax(320px, 0.82fr);
  gap: 28px;
  align-items: stretch;
}

.player-shell {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16 / 9;
  min-height: 360px;
  border-radius: 32px;
  background: #111827;
  box-shadow: 0 28px 76px rgba(17, 24, 39, 0.24);
}

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

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

.player-cover.hidden {
  display: none;
}

.play-circle {
  width: 78px;
  height: 78px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  color: var(--rose);
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 20px 46px rgba(0, 0, 0, 0.22);
  font-size: 2rem;
  padding-left: 4px;
}

.player-cover strong {
  max-width: 720px;
  font-size: clamp(1.4rem, 3vw, 2.4rem);
  line-height: 1.2;
}

.player-cover em {
  font-style: normal;
  font-weight: 900;
  color: #fecdd3;
}

.detail-info {
  padding: 34px;
  border-radius: 32px;
  background: #ffffff;
  border: 1px solid rgba(244, 63, 94, 0.14);
  box-shadow: var(--shadow);
}

.detail-info h1 {
  margin-bottom: 16px;
}

.detail-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 22px;
  margin-top: 28px;
}

.detail-content article {
  padding: 30px;
  border-radius: 28px;
  background: #ffffff;
  border: 1px solid rgba(244, 63, 94, 0.12);
  box-shadow: 0 18px 46px rgba(136, 19, 55, 0.08);
}

.detail-content h2 {
  margin: 0 0 14px;
  font-size: 1.4rem;
}

.detail-content p {
  margin: 0;
  color: #4b5563;
  line-height: 2;
}

.related-section {
  padding-bottom: 40px;
}

.site-footer {
  margin-top: 90px;
  padding: 58px 0;
  background: #111827;
  color: #ffffff;
}

.footer-inner {
  width: min(1200px, calc(100% - 32px));
  margin: 0 auto;
  display: grid;
  gap: 22px;
}

.footer-brand .brand-mark {
  box-shadow: none;
}

.site-footer p {
  max-width: 760px;
  margin: 0;
  color: rgba(255, 255, 255, 0.68);
  line-height: 1.8;
}

.copyright {
  font-size: 0.9rem;
}

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

  .hero-bottom-panel {
    grid-template-columns: 1fr 1fr;
  }

  .hero-mini-list {
    grid-column: 1 / -1;
  }
}

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

  .menu-button {
    display: block;
  }

  .hero-slider,
  .hero-content {
    min-height: 560px;
  }

  .hero-content {
    grid-template-columns: 1fr;
    padding: 48px 28px 112px;
  }

  .hero-poster {
    display: none;
  }

  .hero-controls {
    left: 28px;
    right: 28px;
  }

  .hero-bottom-panel,
  .filter-panel,
  .detail-hero,
  .detail-content {
    grid-template-columns: 1fr;
  }

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

  .ranking-list {
    grid-template-columns: 1fr;
  }

  .soft-section,
  .sub-hero {
    padding: 30px;
  }
}

@media (max-width: 640px) {
  .header-inner {
    height: 66px;
  }

  .brand-text {
    font-size: 1rem;
  }

  .hero-section,
  main,
  .sub-page,
  .detail-page {
    width: min(100% - 20px, 1200px);
  }

  .hero-slider,
  .hero-content {
    min-height: 520px;
  }

  .hero-copy h1 {
    font-size: 2.7rem;
  }

  .hero-bottom-panel {
    width: 100%;
    margin-top: 14px;
  }

  .hero-search-row {
    flex-direction: column;
  }

  .hero-search-row a {
    min-height: 46px;
  }

  .hero-mini-list,
  .featured-grid,
  .movie-grid,
  .category-grid,
  .category-grid-large {
    grid-template-columns: 1fr;
  }

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

  .page-section {
    padding-top: 52px;
  }

  .player-shell {
    min-height: 230px;
    border-radius: 24px;
  }

  .detail-info,
  .detail-content article {
    padding: 24px;
  }
}
