:root {
  --pink: #ec4899;
  --rose: #f43f5e;
  --orange: #f97316;
  --dark: #111827;
  --muted: #6b7280;
  --paper: #ffffff;
  --soft: #fff7ed;
  --line: #fbcfe8;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: #1f2937;
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: linear-gradient(135deg, #fdf2f8 0%, #fff1f2 50%, #fff7ed 100%);
}

body.is-menu-open {
  overflow: hidden;
}

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

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: linear-gradient(90deg, #ec4899 0%, #fb7185 50%, #fb923c 100%);
  box-shadow: 0 10px 25px rgba(190, 24, 93, 0.22);
}

.nav-wrap,
.section-inner,
.footer-inner {
  width: min(100% - 32px, 1280px);
  margin: 0 auto;
}

.nav-wrap {
  min-height: 64px;
  display: flex;
  align-items: center;
  gap: 24px;
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: #fff;
  font-size: 22px;
  font-weight: 800;
  letter-spacing: 0.02em;
  white-space: nowrap;
}

.logo-mark {
  width: 34px;
  height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.18);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.25);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-left: auto;
}

.nav-links a {
  color: rgba(255, 255, 255, 0.94);
  font-weight: 650;
  transition: color 0.2s ease, transform 0.2s ease;
}

.nav-links a:hover,
.nav-links a.is-active {
  color: #fef08a;
  transform: translateY(-1px);
}

.header-search {
  position: relative;
  width: 260px;
}

.header-search input,
.page-filter input {
  width: 100%;
  border: 0;
  outline: none;
  border-radius: 999px;
  padding: 11px 46px 11px 18px;
  background: #fff;
  color: #374151;
  box-shadow: 0 0 0 1px rgba(249, 168, 212, 0.55);
}

.header-search button,
.page-filter button {
  position: absolute;
  right: 7px;
  top: 50%;
  transform: translateY(-50%);
  width: 34px;
  height: 34px;
  border: 0;
  border-radius: 999px;
  color: #db2777;
  background: #fce7f3;
  cursor: pointer;
}

.nav-toggle {
  display: none;
  margin-left: auto;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 12px;
  color: #fff;
  background: rgba(255, 255, 255, 0.16);
  font-size: 22px;
}

.hero {
  position: relative;
  min-height: 520px;
  overflow: hidden;
  background: linear-gradient(90deg, #db2777 0%, #f43f5e 52%, #f97316 100%);
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  opacity: 0.16;
  background-image: radial-gradient(circle at 18px 18px, rgba(255,255,255,0.9) 0 2px, transparent 2px), radial-gradient(circle at 44px 44px, rgba(255,255,255,0.9) 0 2px, transparent 2px);
  background-size: 62px 62px;
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(280px, 0.75fr);
  align-items: center;
  gap: 42px;
  width: min(100% - 32px, 1280px);
  margin: 0 auto;
  left: 50%;
  transform: translateX(-50%);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.7s ease;
}

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

.hero-text {
  position: relative;
  z-index: 3;
  color: #fff;
  max-width: 700px;
}

.hero-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 14px;
  border-radius: 999px;
  color: #fef3c7;
  background: rgba(17, 24, 39, 0.25);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.18);
  font-size: 14px;
  font-weight: 700;
}

.hero h1,
.hero h2 {
  margin: 18px 0 18px;
  font-size: clamp(38px, 6vw, 72px);
  line-height: 1.04;
  letter-spacing: -0.04em;
  font-weight: 900;
}

.hero h1 span,
.hero h2 span {
  color: #fef08a;
}

.hero-desc {
  max-width: 660px;
  color: rgba(255, 255, 255, 0.92);
  font-size: 18px;
  line-height: 1.85;
}

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

.btn-primary,
.btn-ghost,
.btn-light {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: 999px;
  padding: 12px 22px;
  font-weight: 800;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.btn-primary {
  color: #fff;
  background: linear-gradient(90deg, #ec4899, #f43f5e);
  box-shadow: 0 16px 30px rgba(219, 39, 119, 0.28);
}

.btn-light {
  color: #db2777;
  background: #fff;
  box-shadow: 0 16px 30px rgba(17, 24, 39, 0.16);
}

.btn-ghost {
  color: #fff;
  background: rgba(255, 255, 255, 0.16);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.22);
}

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

.hero-poster {
  position: relative;
  z-index: 3;
  min-height: 380px;
  border-radius: 28px;
  overflow: hidden;
  background: rgba(17, 24, 39, 0.25);
  box-shadow: 0 35px 65px rgba(17, 24, 39, 0.3);
}

.hero-poster img {
  width: 100%;
  height: 430px;
  object-fit: cover;
  transform: scale(1.01);
}

.hero-poster::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(0,0,0,0.72), rgba(0,0,0,0.05) 55%, transparent);
}

.hero-poster-info {
  position: absolute;
  left: 24px;
  right: 24px;
  bottom: 24px;
  z-index: 2;
  color: #fff;
}

.hero-poster-info strong {
  display: block;
  margin-bottom: 6px;
  font-size: 24px;
}

.hero-control {
  position: absolute;
  z-index: 6;
  left: 50%;
  bottom: 28px;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 10px;
}

.hero-dot {
  width: 12px;
  height: 12px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.48);
  cursor: pointer;
}

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

.quick-panel {
  position: relative;
  z-index: 8;
  width: min(100% - 32px, 1280px);
  margin: -58px auto 0;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

.quick-card {
  min-height: 112px;
  padding: 20px;
  border-radius: 18px;
  background: rgba(255,255,255,0.94);
  box-shadow: 0 16px 34px rgba(17, 24, 39, 0.11);
  border: 1px solid rgba(251, 207, 232, 0.75);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.quick-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 22px 44px rgba(219, 39, 119, 0.16);
}

.quick-card strong {
  display: block;
  margin-bottom: 8px;
  color: #be185d;
  font-size: 18px;
}

.quick-card span {
  color: #6b7280;
  font-size: 14px;
  line-height: 1.55;
}

.section {
  padding: 58px 0;
}

.section-soft {
  background: linear-gradient(90deg, rgba(255,237,213,0.75), rgba(252,231,243,0.72), rgba(255,228,230,0.75));
}

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

.section-head h2,
.page-title h1 {
  margin: 0;
  color: #111827;
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1.15;
  font-weight: 900;
  letter-spacing: -0.02em;
}

.section-head p,
.page-title p {
  margin: 10px 0 0;
  color: #6b7280;
  line-height: 1.75;
}

.link-more {
  color: #db2777;
  font-weight: 800;
  white-space: nowrap;
}

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

.movie-card {
  overflow: hidden;
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 10px 22px rgba(17, 24, 39, 0.08);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.movie-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 20px 34px rgba(219, 39, 119, 0.16);
}

.card-cover {
  position: relative;
  height: 250px;
  overflow: hidden;
  background: linear-gradient(135deg, #fce7f3, #ffedd5);
}

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

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

.badge,
.score-badge,
.tag {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  font-weight: 800;
}

.score-badge {
  position: absolute;
  top: 10px;
  right: 10px;
  padding: 5px 10px;
  color: #fff;
  background: linear-gradient(90deg, #f59e0b, #f97316);
  box-shadow: 0 8px 18px rgba(249, 115, 22, 0.28);
}

.card-body {
  padding: 18px;
}

.card-body h3 {
  margin: 0 0 8px;
  color: #1f2937;
  font-size: 18px;
  line-height: 1.35;
  font-weight: 900;
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.movie-card:hover .card-body h3 {
  color: #db2777;
}

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

.meta-line {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: #6b7280;
  font-size: 13px;
}

.meta-line span:first-child {
  color: #db2777;
  font-weight: 750;
}

.featured-grid {
  display: grid;
  grid-template-columns: 1.25fr 1fr 1fr;
  gap: 24px;
}

.featured-card {
  position: relative;
  min-height: 420px;
  overflow: hidden;
  border-radius: 24px;
  background: #111827;
  box-shadow: 0 22px 45px rgba(17, 24, 39, 0.2);
}

.featured-card:first-child {
  grid-row: span 2;
  min-height: 864px;
}

.featured-card img {
  width: 100%;
  height: 100%;
  min-height: inherit;
  object-fit: cover;
  transition: transform 0.7s ease;
}

.featured-card::after,
.rank-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(0,0,0,0.82), rgba(0,0,0,0.26) 58%, transparent);
}

.featured-content,
.rank-content {
  position: absolute;
  z-index: 2;
  left: 24px;
  right: 24px;
  bottom: 24px;
  color: #fff;
}

.featured-content h3,
.rank-content h3 {
  margin: 0 0 10px;
  font-size: 24px;
  line-height: 1.25;
  font-weight: 900;
}

.featured-content p,
.rank-content p {
  margin: 0;
  color: rgba(255,255,255,0.82);
  line-height: 1.65;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

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

.category-card {
  padding: 24px;
  min-height: 168px;
  border-radius: 22px;
  background: #fff;
  border: 1px solid rgba(251, 207, 232, 0.82);
  box-shadow: 0 12px 28px rgba(17, 24, 39, 0.08);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.category-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 22px 38px rgba(219, 39, 119, 0.15);
}

.category-card strong {
  display: block;
  color: #be185d;
  font-size: 22px;
  margin-bottom: 12px;
}

.category-card span {
  color: #6b7280;
  line-height: 1.7;
}

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

.rank-card {
  position: relative;
  min-height: 320px;
  overflow: hidden;
  border-radius: 20px;
  background: #111827;
  box-shadow: 0 15px 30px rgba(17, 24, 39, 0.16);
}

.rank-card img {
  width: 100%;
  height: 320px;
  object-fit: cover;
  transition: transform 0.65s ease;
}

.rank-num {
  position: absolute;
  z-index: 3;
  top: 12px;
  left: 12px;
  width: 42px;
  height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  color: #fff;
  font-weight: 900;
  background: linear-gradient(135deg, #ec4899, #f97316);
  box-shadow: 0 12px 22px rgba(236, 72, 153, 0.25);
}

.page-hero {
  padding: 56px 0;
  color: #fff;
  background: linear-gradient(90deg, #db2777, #f43f5e, #f97316);
}

.page-title {
  width: min(100% - 32px, 1280px);
  margin: 0 auto;
}

.page-title h1 {
  color: #fff;
}

.page-title p {
  max-width: 780px;
  color: rgba(255,255,255,0.9);
}

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

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

.filter-bar {
  margin: 0 0 28px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 18px;
}

.page-filter {
  position: relative;
  width: min(100%, 420px);
}

.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(300px, 0.85fr);
  gap: 32px;
  align-items: start;
}

.player-card,
.detail-card,
.side-card {
  border-radius: 24px;
  background: #fff;
  box-shadow: 0 18px 38px rgba(17, 24, 39, 0.1);
  overflow: hidden;
}

.player-shell {
  position: relative;
  aspect-ratio: 16 / 9;
  background: #000;
}

.player-shell video {
  width: 100%;
  height: 100%;
  background: #000;
}

.play-cover {
  position: absolute;
  inset: 0;
  z-index: 4;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 14px;
  border: 0;
  padding: 0;
  color: #fff;
  cursor: pointer;
  background: #111827;
}

.play-cover img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.64;
}

.play-cover::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(0,0,0,0.78), rgba(0,0,0,0.22));
}

.play-cover.is-hidden {
  display: none;
}

.play-icon {
  position: relative;
  z-index: 2;
  width: 78px;
  height: 78px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: linear-gradient(135deg, #ec4899, #f97316);
  box-shadow: 0 18px 38px rgba(0,0,0,0.32);
  font-size: 32px;
}

.play-title {
  position: relative;
  z-index: 2;
  font-size: 24px;
  font-weight: 900;
  text-shadow: 0 2px 8px rgba(0,0,0,0.45);
}

.player-info,
.detail-body {
  padding: 26px;
}

.player-info h1 {
  margin: 0 0 12px;
  color: #111827;
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1.2;
  font-weight: 900;
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 16px 0 0;
}

.tag {
  padding: 7px 11px;
  color: #be185d;
  background: #fce7f3;
  border: 1px solid #fbcfe8;
  font-size: 13px;
}

.detail-card {
  padding: 30px;
  margin-top: 28px;
}

.detail-card h2,
.side-card h2 {
  margin: 0 0 16px;
  color: #111827;
  font-size: 24px;
  font-weight: 900;
}

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

.review-box {
  margin-top: 20px;
  padding: 20px;
  border-left: 4px solid #f472b6;
  border-radius: 16px;
  color: #4b5563;
  background: linear-gradient(90deg, #fdf2f8, #fff1f2);
  line-height: 1.85;
}

.side-card {
  padding: 22px;
}

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

.related-item {
  display: grid;
  grid-template-columns: 86px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
}

.related-item img {
  width: 86px;
  height: 116px;
  object-fit: cover;
  border-radius: 14px;
  background: #fce7f3;
}

.related-item strong {
  display: block;
  color: #111827;
  line-height: 1.35;
  font-size: 15px;
}

.related-item span {
  display: block;
  margin-top: 6px;
  color: #db2777;
  font-size: 13px;
  font-weight: 750;
}

.pagination-nav {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  margin-top: 28px;
}

.pagination-nav a {
  flex: 1;
  padding: 16px 18px;
  border-radius: 18px;
  color: #be185d;
  background: #fff;
  box-shadow: 0 12px 24px rgba(17,24,39,0.08);
  font-weight: 800;
}

.site-footer {
  margin-top: 58px;
  color: #d1d5db;
  background: linear-gradient(90deg, #1f2937, #111827, #000);
}

.footer-inner {
  padding: 46px 0 28px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 28px;
}

.footer-inner h3,
.footer-inner h4 {
  color: #fff;
  margin: 0 0 14px;
}

.footer-inner p,
.footer-inner li {
  color: #9ca3af;
  line-height: 1.8;
  font-size: 14px;
}

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

.footer-inner a:hover {
  color: #f9a8d4;
}

.copyright {
  margin-top: 30px;
  padding-top: 22px;
  border-top: 1px solid rgba(75, 85, 99, 0.8);
  text-align: center;
  color: #9ca3af;
  font-size: 13px;
}

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

.empty-result {
  display: none;
  padding: 30px;
  border-radius: 20px;
  color: #6b7280;
  background: #fff;
  text-align: center;
  box-shadow: 0 12px 25px rgba(17,24,39,0.08);
}

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

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

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

  .featured-card:first-child {
    grid-row: auto;
    grid-column: span 2;
    min-height: 520px;
  }

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

  .detail-layout {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 820px) {
  .nav-links,
  .header-search {
    display: none;
  }

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

  .nav-links.is-open {
    position: fixed;
    top: 64px;
    left: 0;
    right: 0;
    display: grid;
    gap: 0;
    padding: 14px 22px 22px;
    background: rgba(255,255,255,0.97);
    box-shadow: 0 18px 35px rgba(17,24,39,0.12);
  }

  .nav-links.is-open a {
    padding: 12px 0;
    color: #374151;
  }

  .hero {
    min-height: 720px;
  }

  .hero-slide {
    grid-template-columns: 1fr;
    align-content: center;
    gap: 22px;
  }

  .hero-poster {
    min-height: 280px;
  }

  .hero-poster img {
    height: 300px;
  }

  .quick-panel,
  .movie-grid,
  .category-grid,
  .rank-strip,
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }

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

  .featured-card:first-child {
    grid-column: auto;
  }

  .section-head,
  .filter-bar {
    align-items: flex-start;
    flex-direction: column;
  }
}

@media (max-width: 560px) {
  .nav-wrap,
  .section-inner,
  .footer-inner,
  .page-title {
    width: min(100% - 24px, 1280px);
  }

  .logo {
    font-size: 18px;
  }

  .hero h1,
  .hero h2 {
    font-size: 38px;
  }

  .hero-desc {
    font-size: 16px;
  }

  .quick-panel,
  .movie-grid,
  .category-grid,
  .rank-strip,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .card-cover {
    height: 235px;
  }

  .hero-actions,
  .pagination-nav {
    flex-direction: column;
    align-items: stretch;
  }

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