:root {
  --rose: #f43f5e;
  --pink: #ec4899;
  --orange: #f97316;
  --ink: #1f2937;
  --muted: #6b7280;
  --soft: #fff7ed;
  --line: rgba(244, 63, 94, 0.16);
  --shadow: 0 24px 60px rgba(244, 63, 94, 0.16);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  color: var(--ink);
  background: linear-gradient(180deg, #fff1f2 0%, #ffffff 38%, #fff7ed 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;
  background: rgba(255, 247, 250, 0.9);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(18px);
  box-shadow: 0 10px 30px rgba(244, 63, 94, 0.08);
}

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

.logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 24px;
  font-weight: 800;
  letter-spacing: -0.04em;
  background: linear-gradient(90deg, var(--rose), var(--pink), var(--orange));
  -webkit-background-clip: text;
  color: transparent;
  white-space: nowrap;
}

.logo-mark {
  width: 34px;
  height: 34px;
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: white;
  background: linear-gradient(135deg, var(--rose), var(--orange));
  box-shadow: 0 10px 25px rgba(244, 63, 94, 0.28);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 24px;
  color: #374151;
  font-weight: 650;
}

.nav-links a {
  transition: color 0.22s ease, transform 0.22s ease;
}

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

.site-search {
  position: relative;
  min-width: 220px;
}

.site-search input,
.toolbar input,
.toolbar select {
  width: 100%;
  border: 1px solid rgba(244, 63, 94, 0.24);
  border-radius: 999px;
  padding: 11px 16px;
  outline: none;
  color: #374151;
  background: rgba(255, 255, 255, 0.86);
  transition: box-shadow 0.22s ease, border-color 0.22s ease;
}

.site-search input:focus,
.toolbar input:focus,
.toolbar select:focus {
  border-color: var(--rose);
  box-shadow: 0 0 0 4px rgba(244, 63, 94, 0.12);
}

.menu-toggle {
  display: none;
  border: 0;
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: rgba(244, 63, 94, 0.1);
  color: var(--rose);
  cursor: pointer;
}

.main {
  min-height: 60vh;
}

.hero {
  position: relative;
  overflow: hidden;
  padding: 72px 0 58px;
  background: radial-gradient(circle at 10% 15%, rgba(244, 63, 94, 0.22), transparent 34%), radial-gradient(circle at 90% 25%, rgba(249, 115, 22, 0.22), transparent 32%), linear-gradient(110deg, #fff1f2 0%, #ffe4e6 45%, #ffedd5 100%);
}

.hero::before,
.hero::after {
  content: "";
  position: absolute;
  width: 420px;
  height: 420px;
  border-radius: 999px;
  filter: blur(50px);
  opacity: 0.35;
  animation: glowPulse 7s ease-in-out infinite alternate;
}

.hero::before {
  left: -150px;
  top: -140px;
  background: #fb7185;
}

.hero::after {
  right: -160px;
  bottom: -180px;
  background: #fb923c;
  animation-delay: 1.4s;
}

@keyframes glowPulse {
  from {
    transform: scale(0.88);
  }
  to {
    transform: scale(1.08);
  }
}

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

.hero-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 0.95fr 1.05fr;
  align-items: center;
  gap: 44px;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 1px solid rgba(244, 63, 94, 0.22);
  border-radius: 999px;
  padding: 8px 14px;
  color: #be123c;
  font-weight: 700;
  background: rgba(255, 255, 255, 0.62);
  box-shadow: 0 10px 30px rgba(244, 63, 94, 0.1);
}

.hero h1,
.page-hero h1,
.detail-title {
  margin: 18px 0 18px;
  font-size: clamp(38px, 7vw, 68px);
  line-height: 1.04;
  letter-spacing: -0.08em;
  font-weight: 900;
  background: linear-gradient(90deg, #e11d48, #db2777, #ea580c);
  -webkit-background-clip: text;
  color: transparent;
}

.hero-desc,
.page-hero p,
.detail-desc {
  color: #4b5563;
  line-height: 1.9;
  font-size: 18px;
}

.hero-actions,
.card-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px;
  margin-top: 28px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  border: 0;
  border-radius: 999px;
  padding: 0 20px;
  font-weight: 800;
  cursor: pointer;
  transition: transform 0.22s ease, box-shadow 0.22s ease, background 0.22s ease;
}

.btn-primary {
  color: #fff;
  background: linear-gradient(90deg, var(--rose), var(--pink), var(--orange));
  box-shadow: 0 14px 32px rgba(244, 63, 94, 0.28);
}

.btn-ghost {
  color: #be123c;
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid rgba(244, 63, 94, 0.22);
}

.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 36px rgba(244, 63, 94, 0.25);
}

.hero-panel {
  position: relative;
  border-radius: 28px;
  min-height: 430px;
  overflow: hidden;
  box-shadow: var(--shadow);
  background: #111827;
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.65s ease;
}

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

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

.hero-slide::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(17, 24, 39, 0.12), rgba(17, 24, 39, 0.9));
}

.hero-copy {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 2;
  padding: 32px;
  color: white;
}

.hero-copy h2 {
  margin: 0 0 10px;
  font-size: clamp(26px, 4vw, 40px);
}

.hero-copy p {
  margin: 0 0 18px;
  color: rgba(255, 255, 255, 0.86);
  line-height: 1.75;
}

.hero-meta,
.meta-row,
.movie-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}

.pill,
.tag,
.badge {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 6px 11px;
  font-size: 13px;
  font-weight: 750;
}

.pill {
  color: #be123c;
  background: rgba(255, 241, 242, 0.94);
}

.tag {
  color: #9f1239;
  background: #ffe4e6;
}

.badge {
  color: white;
  background: linear-gradient(90deg, var(--rose), var(--orange));
}

.hero-dots {
  position: absolute;
  z-index: 4;
  right: 24px;
  top: 24px;
  display: flex;
  gap: 8px;
}

.hero-dot {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  border: 0;
  background: rgba(255, 255, 255, 0.55);
  cursor: pointer;
  transition: width 0.22s ease, background 0.22s ease;
}

.hero-dot.is-active {
  width: 28px;
  background: white;
}

.section {
  padding: 48px 0;
}

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

.section-title {
  margin: 0;
  font-size: clamp(26px, 4vw, 36px);
  letter-spacing: -0.04em;
}

.section-subtitle {
  margin: 8px 0 0;
  color: var(--muted);
  line-height: 1.8;
}

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

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

.movie-card {
  border: 1px solid rgba(244, 63, 94, 0.12);
  border-radius: 22px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.88);
  box-shadow: 0 18px 45px rgba(244, 63, 94, 0.1);
  transition: transform 0.26s ease, box-shadow 0.26s ease, border-color 0.26s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  border-color: rgba(244, 63, 94, 0.28);
  box-shadow: 0 24px 60px rgba(244, 63, 94, 0.18);
}

.movie-cover {
  position: relative;
  display: block;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: linear-gradient(135deg, #fecdd3, #fed7aa);
}

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

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

.movie-cover::after {
  content: "";
  position: absolute;
  inset: 0;
  opacity: 0;
  background: linear-gradient(180deg, transparent, rgba(0, 0, 0, 0.62));
  transition: opacity 0.24s ease;
}

.movie-card:hover .movie-cover::after {
  opacity: 1;
}

.movie-cover .badge {
  position: absolute;
  z-index: 1;
  top: 12px;
  right: 12px;
  max-width: calc(100% - 24px);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.movie-body {
  padding: 18px;
}

.movie-title {
  margin: 0 0 9px;
  font-size: 18px;
  line-height: 1.35;
  font-weight: 850;
}

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

.movie-desc {
  margin: 0 0 15px;
  color: var(--muted);
  line-height: 1.75;
  font-size: 14px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.movie-meta {
  color: #6b7280;
  font-size: 13px;
}

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

.category-card {
  position: relative;
  min-height: 168px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  border: 1px solid rgba(244, 63, 94, 0.12);
  border-radius: 24px;
  padding: 22px;
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.92), rgba(255, 241, 242, 0.72));
  box-shadow: 0 18px 45px rgba(244, 63, 94, 0.1);
  overflow: hidden;
  transition: transform 0.24s ease, box-shadow 0.24s ease;
}

.category-card::after {
  content: "";
  position: absolute;
  width: 110px;
  height: 110px;
  right: -40px;
  top: -30px;
  border-radius: 999px;
  background: linear-gradient(135deg, rgba(244, 63, 94, 0.18), rgba(249, 115, 22, 0.2));
}

.category-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 24px 55px rgba(244, 63, 94, 0.18);
}

.category-card h3 {
  margin: 0 0 10px;
  font-size: 21px;
}

.category-card p {
  margin: 0;
  color: var(--muted);
  line-height: 1.72;
  font-size: 14px;
}

.page-hero {
  padding: 58px 0 32px;
  background: linear-gradient(105deg, #fff1f2, #fff7ed);
  border-bottom: 1px solid rgba(244, 63, 94, 0.1);
}

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

.toolbar {
  display: grid;
  grid-template-columns: 1fr 160px 160px 160px;
  gap: 14px;
  padding: 18px;
  margin: 8px 0 28px;
  border: 1px solid rgba(244, 63, 94, 0.12);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.78);
  box-shadow: 0 14px 36px rgba(244, 63, 94, 0.08);
}

.rank-list {
  display: grid;
  gap: 14px;
}

.rank-item {
  display: grid;
  grid-template-columns: 62px 120px 1fr auto;
  align-items: center;
  gap: 18px;
  border: 1px solid rgba(244, 63, 94, 0.12);
  border-radius: 22px;
  padding: 12px;
  background: rgba(255, 255, 255, 0.88);
  box-shadow: 0 14px 34px rgba(244, 63, 94, 0.08);
}

.rank-num {
  width: 46px;
  height: 46px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 16px;
  color: #fff;
  font-size: 18px;
  font-weight: 900;
  background: linear-gradient(135deg, var(--rose), var(--orange));
}

.rank-thumb {
  aspect-ratio: 16 / 10;
  border-radius: 16px;
  overflow: hidden;
  background: #ffe4e6;
}

.rank-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.rank-title {
  margin: 0 0 6px;
  font-size: 19px;
}

.rank-title a:hover {
  color: var(--rose);
}

.rank-text {
  margin: 0;
  color: var(--muted);
  line-height: 1.65;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(280px, 0.55fr);
  gap: 28px;
  align-items: start;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: #9f1239;
  font-size: 14px;
  margin-bottom: 18px;
}

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

.player-shell {
  position: relative;
  border-radius: 26px;
  overflow: hidden;
  background: #111827;
  box-shadow: var(--shadow);
  aspect-ratio: 16 / 9;
}

.player-shell video {
  width: 100%;
  height: 100%;
  display: block;
  background: #111827;
  cursor: pointer;
}

.player-cover {
  position: absolute;
  inset: 0;
  z-index: 3;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 0;
  color: white;
  background: rgba(17, 24, 39, 0.36);
  cursor: pointer;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

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

.play-circle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 86px;
  height: 86px;
  border-radius: 999px;
  color: #fff;
  font-size: 34px;
  background: linear-gradient(135deg, var(--rose), var(--orange));
  box-shadow: 0 18px 44px rgba(244, 63, 94, 0.42);
  transform: translateZ(0);
}

.detail-card,
.aside-card {
  border: 1px solid rgba(244, 63, 94, 0.12);
  border-radius: 24px;
  padding: 22px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 18px 45px rgba(244, 63, 94, 0.1);
}

.detail-card h2,
.aside-card h2 {
  margin: 0 0 16px;
  font-size: 24px;
}

.detail-card p {
  color: #4b5563;
  line-height: 1.95;
  margin: 0 0 16px;
}

.info-list {
  display: grid;
  gap: 12px;
  margin: 18px 0 0;
}

.info-list div {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  border-bottom: 1px solid rgba(244, 63, 94, 0.1);
  padding-bottom: 10px;
  color: #4b5563;
}

.info-list strong {
  color: #111827;
}

.aside-list {
  display: grid;
  gap: 14px;
}

.aside-link {
  display: grid;
  grid-template-columns: 94px 1fr;
  gap: 12px;
  align-items: center;
}

.aside-link img {
  width: 94px;
  aspect-ratio: 16 / 10;
  border-radius: 14px;
  object-fit: cover;
}

.aside-link strong {
  display: block;
  margin-bottom: 6px;
  line-height: 1.4;
}

.aside-link span {
  color: var(--muted);
  font-size: 13px;
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 18px;
}

.site-footer {
  margin-top: 64px;
  border-top: 1px solid rgba(244, 63, 94, 0.1);
  background: linear-gradient(180deg, #fff, #fff7ed);
}

.footer-grid {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 42px 0;
  display: grid;
  grid-template-columns: 1.4fr repeat(3, 1fr);
  gap: 30px;
}

.footer-grid h3 {
  margin: 0 0 12px;
  font-size: 16px;
}

.footer-grid p,
.footer-grid a {
  color: var(--muted);
  line-height: 1.85;
  font-size: 14px;
}

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

.empty-state {
  display: none;
  padding: 28px;
  border-radius: 22px;
  text-align: center;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid rgba(244, 63, 94, 0.12);
}

.empty-state.is-visible {
  display: block;
}

[hidden] {
  display: none !important;
}

@media (max-width: 1024px) {
  .hero-grid,
  .detail-layout {
    grid-template-columns: 1fr;
  }

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

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

  .toolbar {
    grid-template-columns: 1fr 1fr;
  }

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

@media (max-width: 760px) {
  .nav-wrap {
    min-height: 62px;
  }

  .menu-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  .nav-links {
    position: absolute;
    left: 16px;
    right: 16px;
    top: 68px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    padding: 16px;
    border: 1px solid rgba(244, 63, 94, 0.12);
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.96);
    box-shadow: 0 24px 60px rgba(244, 63, 94, 0.16);
  }

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

  .site-search {
    min-width: 100%;
  }

  .hero {
    padding: 42px 0;
  }

  .hero-panel {
    min-height: 360px;
  }

  .section-head,
  .rank-item {
    display: block;
  }

  .section-head .btn {
    margin-top: 16px;
  }

  .rank-thumb {
    margin: 12px 0;
  }

  .rank-item {
    padding: 16px;
  }

  .rank-thumb img {
    width: 100%;
  }

  .movie-grid,
  .movie-grid.compact,
  .category-grid,
  .toolbar,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .footer-grid {
    gap: 20px;
  }
}
