:root {
  --rose: #e11d48;
  --rose-dark: #be123c;
  --orange: #f97316;
  --gold: #f59e0b;
  --ink: #151321;
  --muted: #6b7280;
  --soft: #fff7ed;
  --paper: #ffffff;
  --line: rgba(225, 29, 72, 0.13);
  --shadow: 0 22px 60px rgba(190, 18, 60, 0.16);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  font-family: Inter, "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
  background:
    radial-gradient(circle at top left, rgba(251, 113, 133, 0.24), transparent 34rem),
    radial-gradient(circle at top right, rgba(249, 115, 22, 0.18), transparent 32rem),
    linear-gradient(135deg, #fff7ed 0%, #fdf2f8 50%, #fff1f2 100%);
}

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

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.86);
  backdrop-filter: blur(18px);
}

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

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.brand-mark {
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  color: #fff;
  border-radius: 16px;
  background: linear-gradient(135deg, #fb7185, #f97316);
  box-shadow: 0 14px 30px rgba(225, 29, 72, 0.25);
}

.brand-text strong {
  display: block;
  font-size: 20px;
  line-height: 1.1;
  background: linear-gradient(90deg, var(--rose), var(--orange));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.brand-text small {
  display: block;
  color: var(--muted);
  font-size: 12px;
  margin-top: 3px;
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 22px;
  color: #4b5563;
  font-weight: 700;
}

.nav-link {
  padding: 10px 2px;
  transition: color 0.2s ease;
}

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

.menu-button {
  display: none;
  border: 0;
  background: #fff1f2;
  color: var(--rose);
  width: 42px;
  height: 42px;
  border-radius: 12px;
  font-size: 22px;
}

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

.mobile-nav a {
  display: block;
  padding: 12px 14px;
  border-radius: 12px;
  color: #4b5563;
  font-weight: 700;
}

.mobile-nav a:hover {
  background: #fff1f2;
  color: var(--rose);
}

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

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

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

.hero-slide {
  opacity: 0;
  transform: scale(1.02);
  transition: opacity 0.8s ease, transform 1.2s ease;
  pointer-events: none;
}

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

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

.hero-overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(190, 18, 60, 0.95), rgba(249, 115, 22, 0.82) 48%, rgba(15, 23, 42, 0.42)),
    linear-gradient(0deg, rgba(255, 247, 237, 0.18), transparent 45%);
}

.hero-content {
  position: relative;
  z-index: 2;
  width: min(1180px, calc(100% - 32px));
  height: 100%;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  justify-content: center;
  color: #fff;
  max-width: 1180px;
}

.hero-content > * {
  max-width: 720px;
}

.hero-kicker,
.eyebrow {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  padding: 8px 14px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
  color: #fff7ed;
  font-size: 14px;
  font-weight: 800;
  letter-spacing: 0.08em;
}

.hero-content h1 {
  margin: 18px 0 8px;
  font-size: clamp(38px, 7vw, 72px);
  line-height: 1.05;
}

.hero-content h2 {
  margin: 0 0 18px;
  font-size: clamp(28px, 4vw, 48px);
  color: #ffe4e6;
}

.hero-content p {
  margin: 0 0 22px;
  color: #fff1f2;
  font-size: 20px;
  line-height: 1.8;
}

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

.hero-tags span,
.tag-row span,
.pill,
.quick-links a {
  display: inline-flex;
  align-items: center;
  padding: 7px 12px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 700;
}

.hero-tags span {
  color: #fff;
  background: rgba(255, 255, 255, 0.18);
}

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

.primary-button,
.ghost-button,
.section-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  font-weight: 900;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.primary-button {
  min-height: 50px;
  padding: 0 28px;
  color: var(--rose);
  background: #fff;
  box-shadow: 0 24px 50px rgba(15, 23, 42, 0.22);
}

.ghost-button {
  min-height: 50px;
  padding: 0 24px;
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.45);
  background: rgba(255, 255, 255, 0.12);
}

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

.hero-controls {
  position: absolute;
  z-index: 3;
  left: 50%;
  bottom: 30px;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 10px 14px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.16);
  backdrop-filter: blur(14px);
}

.hero-controls button {
  border: 0;
  cursor: pointer;
}

.hero-controls > button {
  width: 34px;
  height: 34px;
  border-radius: 999px;
  color: #fff;
  background: rgba(255, 255, 255, 0.2);
  font-size: 26px;
  line-height: 1;
}

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

.hero-dot {
  width: 9px;
  height: 9px;
  padding: 0;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.45);
}

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

.panel,
.content-section,
.detail-page {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
}

.quick-search {
  transform: translateY(-36px);
  display: grid;
  grid-template-columns: minmax(180px, 1fr) minmax(260px, 420px) minmax(240px, 1.4fr);
  gap: 18px;
  align-items: center;
  padding: 24px;
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: var(--shadow);
  border: 1px solid var(--line);
}

.quick-search strong {
  display: block;
  font-size: 22px;
  margin-bottom: 6px;
}

.quick-search p,
.section-heading p,
.page-hero p {
  margin: 0;
  color: var(--muted);
  line-height: 1.7;
}

.search-box {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 54px;
  padding: 0 18px;
  border: 1px solid rgba(225, 29, 72, 0.16);
  border-radius: 999px;
  background: #fff;
  box-shadow: 0 12px 34px rgba(190, 18, 60, 0.08);
}

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

.search-box input {
  width: 100%;
  border: 0;
  outline: 0;
  font-size: 16px;
  background: transparent;
}

.search-box.wide {
  flex: 1;
}

.search-box.large {
  min-height: 64px;
  font-size: 18px;
}

.quick-links a,
.pill {
  color: var(--rose-dark);
  background: #fff1f2;
}

.content-section {
  padding: 34px 0;
}

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

.section-heading h2 {
  margin: 0 0 8px;
  font-size: clamp(28px, 4vw, 40px);
}

.section-link {
  padding: 12px 20px;
  color: #fff;
  background: linear-gradient(90deg, var(--rose), var(--orange));
  box-shadow: 0 12px 30px rgba(225, 29, 72, 0.24);
  white-space: nowrap;
}

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

.movie-card {
  overflow: hidden;
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid rgba(255, 255, 255, 0.78);
  box-shadow: 0 16px 40px rgba(190, 18, 60, 0.12);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 22px 60px rgba(190, 18, 60, 0.2);
}

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

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

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

.poster-shade {
  position: absolute;
  inset: auto 0 0;
  height: 42%;
  background: linear-gradient(0deg, rgba(15, 23, 42, 0.78), transparent);
}

.play-chip,
.rank-badge {
  position: absolute;
  z-index: 2;
  border-radius: 999px;
  color: #fff;
  font-weight: 900;
}

.play-chip {
  right: 12px;
  bottom: 12px;
  padding: 8px 12px;
  background: linear-gradient(90deg, var(--rose), var(--orange));
}

.rank-badge {
  left: 12px;
  top: 12px;
  min-width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  background: rgba(15, 23, 42, 0.76);
  backdrop-filter: blur(8px);
}

.card-body {
  padding: 16px;
}

.card-meta,
.detail-label {
  color: var(--rose);
  font-size: 13px;
  font-weight: 900;
  margin-bottom: 8px;
}

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

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

.card-body p {
  display: -webkit-box;
  min-height: 66px;
  margin: 0 0 14px;
  overflow: hidden;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  color: #5b6472;
  line-height: 1.55;
  font-size: 14px;
}

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

.tag-row.full span {
  background: #ffe4e6;
}

.split-section {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(340px, 0.95fr);
  gap: 24px;
  align-items: start;
}

.feature-panel,
.detail-card,
.side-card,
.poster-box {
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid rgba(255, 255, 255, 0.78);
  box-shadow: var(--shadow);
}

.feature-panel {
  padding: 24px;
}

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

.rank-item {
  display: grid;
  grid-template-columns: auto 58px 1fr;
  gap: 12px;
  align-items: center;
  padding: 10px;
  border-radius: 18px;
  background: #fff7ed;
  transition: transform 0.2s ease, background 0.2s ease;
}

.rank-item:hover {
  transform: translateX(4px);
  background: #ffe4e6;
}

.rank-item img {
  width: 58px;
  height: 76px;
  border-radius: 14px;
  object-fit: cover;
}

.list-rank {
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  color: #fff;
  background: linear-gradient(135deg, var(--rose), var(--orange));
  font-weight: 900;
}

.rank-item strong,
.rank-item em {
  display: block;
}

.rank-item strong {
  margin-bottom: 6px;
  line-height: 1.35;
}

.rank-item em {
  color: var(--muted);
  font-size: 13px;
  font-style: normal;
}

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

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

.category-tile {
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-height: 210px;
  padding: 18px;
  border-radius: 24px;
  background: linear-gradient(135deg, rgba(255,255,255,0.96), rgba(255,241,242,0.9));
  border: 1px solid rgba(225, 29, 72, 0.12);
  box-shadow: 0 14px 34px rgba(190, 18, 60, 0.1);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.category-tile:hover {
  transform: translateY(-5px);
  box-shadow: 0 20px 48px rgba(190, 18, 60, 0.16);
}

.category-covers {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 6px;
}

.category-covers img {
  width: 100%;
  aspect-ratio: 3 / 4;
  border-radius: 12px;
  object-fit: cover;
  background: linear-gradient(135deg, #fda4af, #fdba74);
}

.category-name {
  color: var(--ink);
  font-size: 21px;
  font-weight: 900;
}

.category-desc {
  color: var(--muted);
  line-height: 1.65;
  font-size: 14px;
}

.page-hero {
  width: min(1180px, calc(100% - 32px));
  margin: 34px auto 0;
  border-radius: 34px;
  background:
    linear-gradient(135deg, rgba(225,29,72,0.95), rgba(249,115,22,0.88)),
    radial-gradient(circle at right, rgba(255,255,255,0.18), transparent 22rem);
  box-shadow: var(--shadow);
  color: #fff;
}

.compact-hero {
  padding: clamp(34px, 7vw, 72px);
}

.compact-hero .eyebrow {
  background: rgba(255, 255, 255, 0.18);
}

.compact-hero h1 {
  margin: 16px 0 12px;
  font-size: clamp(34px, 6vw, 62px);
  line-height: 1.08;
}

.compact-hero p {
  max-width: 780px;
  color: #fff7ed;
  font-size: 18px;
}

.filter-bar {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 24px;
  padding: 18px;
  border-radius: 26px;
  background: rgba(255, 255, 255, 0.82);
  box-shadow: 0 12px 34px rgba(190, 18, 60, 0.09);
}

.main-filter {
  justify-content: center;
}

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

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  color: #64748b;
  margin-bottom: 20px;
  font-weight: 700;
}

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

.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 330px;
  gap: 24px;
  align-items: start;
}

.detail-main {
  display: grid;
  gap: 22px;
}

.player-panel {
  position: relative;
  overflow: hidden;
  border-radius: 30px;
  background: #0f172a;
  box-shadow: var(--shadow);
  aspect-ratio: 16 / 9;
}

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

.player-cover {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: grid;
  place-content: center;
  gap: 14px;
  border: 0;
  color: #fff;
  background:
    radial-gradient(circle at center, rgba(225,29,72,0.36), transparent 18rem),
    linear-gradient(135deg, rgba(15,23,42,0.56), rgba(15,23,42,0.82));
  cursor: pointer;
  font-size: 18px;
  font-weight: 900;
}

.player-panel.is-playing .player-cover {
  opacity: 0;
  pointer-events: none;
}

.player-icon {
  width: 78px;
  height: 78px;
  display: grid;
  place-items: center;
  margin: 0 auto;
  border-radius: 999px;
  color: var(--rose);
  background: #fff;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.35);
}

.detail-card {
  padding: 28px;
}

.detail-card h1 {
  margin: 0 0 14px;
  font-size: clamp(30px, 5vw, 48px);
}

.lead-text {
  margin: 0;
  color: #4b5563;
  font-size: 19px;
  line-height: 1.8;
}

.detail-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 20px 0;
}

.detail-stats span {
  padding: 9px 14px;
  border-radius: 999px;
  color: var(--rose-dark);
  background: #fff1f2;
  font-weight: 800;
}

.prose-card h2 {
  margin: 0 0 12px;
  font-size: 24px;
}

.prose-card p {
  margin: 0 0 24px;
  color: #374151;
  line-height: 1.9;
  font-size: 17px;
}

.prose-card p:last-child {
  margin-bottom: 0;
}

.detail-side {
  position: sticky;
  top: 98px;
  display: grid;
  gap: 18px;
}

.poster-box {
  overflow: hidden;
}

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

.side-card {
  padding: 22px;
}

.side-card h2 {
  margin: 0 0 18px;
}

.side-card dl {
  display: grid;
  grid-template-columns: 70px 1fr;
  gap: 10px 12px;
  margin: 0;
}

.side-card dt {
  color: var(--muted);
  font-weight: 800;
}

.side-card dd {
  margin: 0;
  color: #111827;
}

.side-card a {
  color: var(--rose);
  font-weight: 900;
}

.related-section {
  padding-top: 44px;
}

.ranking-layout {
  grid-template-columns: minmax(0, 1fr) 360px;
}

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

.sticky-list {
  position: sticky;
  top: 98px;
}

.site-footer {
  margin-top: 58px;
  color: #fff;
  background: linear-gradient(135deg, #be123c, #ea580c);
}

.footer-inner {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 38px 0 28px;
  display: grid;
  grid-template-columns: 1fr 1.6fr;
  gap: 28px;
}

.footer-logo {
  font-size: 24px;
  font-weight: 900;
  margin-bottom: 10px;
}

.footer-brand p {
  margin: 0;
  color: #ffe4e6;
  line-height: 1.8;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 18px;
  justify-content: flex-end;
  align-content: start;
}

.footer-links a {
  color: #fff1f2;
  font-weight: 700;
}

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

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.18);
  padding: 18px;
  text-align: center;
  color: #ffe4e6;
}

.movie-card.hidden-by-filter {
  display: none;
}

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

  .menu-button {
    display: block;
  }

  .hero-carousel {
    height: 700px;
  }

  .hero-content {
    justify-content: flex-end;
    padding-bottom: 110px;
  }

  .quick-search,
  .split-section,
  .detail-layout,
  .ranking-layout,
  .footer-inner {
    grid-template-columns: 1fr;
  }

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

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

  .detail-side,
  .sticky-list {
    position: static;
  }

  .footer-links {
    justify-content: flex-start;
  }
}

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

  .brand-mark {
    width: 40px;
    height: 40px;
    border-radius: 14px;
  }

  .brand-text strong {
    font-size: 17px;
  }

  .brand-text small {
    font-size: 11px;
  }

  .hero-carousel {
    height: 650px;
  }

  .hero-content p {
    font-size: 16px;
  }

  .hero-actions {
    gap: 10px;
  }

  .primary-button,
  .ghost-button {
    width: 100%;
  }

  .quick-search {
    padding: 18px;
    border-radius: 24px;
  }

  .section-heading,
  .filter-bar {
    align-items: stretch;
    flex-direction: column;
  }

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

  .movie-card-compact {
    display: grid;
    grid-template-columns: 112px 1fr;
  }

  .movie-card-compact .poster-link {
    aspect-ratio: auto;
    min-height: 156px;
  }

  .movie-card-compact .card-body p {
    -webkit-line-clamp: 2;
    min-height: auto;
  }

  .detail-card,
  .feature-panel {
    padding: 20px;
  }

  .side-card dl {
    grid-template-columns: 1fr;
  }
}
