:root {
  --bg: #f9fafb;
  --text: #111827;
  --muted: #6b7280;
  --soft: #f3f4f6;
  --line: #e5e7eb;
  --panel: #ffffff;
  --dark: #111827;
  --blue: #2563eb;
  --red: #ef4444;
  --purple: #9333ea;
  --radius: 1rem;
  --shadow: 0 20px 45px rgba(15, 23, 42, 0.12);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
}

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

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

button,
input,
select {
  font: inherit;
}

.rainbow-line {
  height: 4px;
  background: linear-gradient(90deg, #f87171, #facc15, #4ade80, #22d3ee, #60a5fa, #c084fc);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 60;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.08);
  backdrop-filter: blur(12px);
}

.nav-wrap {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 24px;
  min-height: 68px;
  display: flex;
  align-items: center;
  gap: 22px;
  flex-wrap: wrap;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  flex-shrink: 0;
}

.brand-mark {
  width: 42px;
  height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  border-radius: 12px;
  background: linear-gradient(135deg, #dc2626, #f97316, #9333ea);
  box-shadow: 0 10px 22px rgba(239, 68, 68, 0.28);
}

.brand-text {
  font-size: 23px;
  background: linear-gradient(90deg, #ef4444, #f97316, #eab308, #22c55e, #06b6d4, #3b82f6, #a855f7);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

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

.nav-link,
.nav-search-button {
  border: 0;
  background: transparent;
  color: #374151;
  font-weight: 650;
  cursor: pointer;
}

.nav-link:hover,
.nav-link.active,
.nav-search-button:hover {
  color: var(--blue);
}

.nav-toggle {
  display: none;
  margin-left: auto;
  border: 0;
  background: #f3f4f6;
  width: 42px;
  height: 42px;
  border-radius: 12px;
  cursor: pointer;
}

.nav-search {
  width: 100%;
  display: none;
  padding-bottom: 16px;
}

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

.nav-search input,
.filter-panel input,
.filter-panel select {
  width: 100%;
  border: 1px solid #d1d5db;
  border-radius: 14px;
  padding: 12px 14px;
  outline: none;
  background: #fff;
}

.nav-search input:focus,
.filter-panel input:focus,
.filter-panel select:focus {
  border-color: #60a5fa;
  box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.18);
}

.hero {
  position: relative;
  height: 70vh;
  min-height: 520px;
  overflow: hidden;
  background: linear-gradient(90deg, #f87171, #facc15, #4ade80, #22d3ee, #60a5fa, #c084fc);
}

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

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

.hero-bg {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.58;
  transform: scale(1.04);
}

.hero-shade {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 50% 40%, rgba(255, 255, 255, 0.12), transparent 34%), rgba(0, 0, 0, 0.5);
}

.hero-content {
  position: absolute;
  inset: 0;
  max-width: 920px;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  color: white;
}

.hero-logo-pulse {
  position: relative;
  width: 108px;
  height: 108px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 26px;
  border-radius: 26px;
  border: 2px solid rgba(255, 255, 255, 0.32);
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.28), rgba(255, 255, 255, 0.08));
  box-shadow: 0 22px 55px rgba(0, 0, 0, 0.26);
  backdrop-filter: blur(8px);
  animation: pulseGlow 2.8s ease-in-out infinite;
}

.hero-logo-pulse span {
  font-size: 54px;
  font-weight: 900;
}

.hero-eyebrow,
.section-kicker {
  margin: 0 0 10px;
  color: #2563eb;
  font-size: 0.82rem;
  font-weight: 850;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.hero-eyebrow {
  color: #fef3c7;
}

.hero h1,
.hero h2 {
  margin: 0;
  font-size: clamp(3rem, 7vw, 5.6rem);
  line-height: 1;
  text-shadow: 0 10px 26px rgba(0, 0, 0, 0.35);
}

.hero-feature-title {
  margin: 14px 0 0;
  font-size: clamp(1.4rem, 3vw, 2.1rem);
  font-weight: 750;
}

.hero-copy {
  max-width: 780px;
  margin: 22px auto 0;
  font-size: clamp(1rem, 2vw, 1.35rem);
  color: rgba(255, 255, 255, 0.92);
  text-shadow: 0 6px 18px rgba(0, 0, 0, 0.4);
}

.hero-actions {
  display: flex;
  justify-content: center;
  gap: 14px;
  flex-wrap: wrap;
  margin-top: 34px;
}

.primary-button,
.ghost-button,
.section-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  border-radius: 999px;
  padding: 0 24px;
  font-weight: 800;
  transition: transform 200ms ease, box-shadow 200ms ease, background 200ms ease;
}

.primary-button {
  background: white;
  color: #111827;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.2);
}

.ghost-button {
  color: white;
  border: 1px solid rgba(255, 255, 255, 0.55);
  background: rgba(255, 255, 255, 0.14);
  backdrop-filter: blur(8px);
}

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

.hero-dots {
  position: absolute;
  left: 50%;
  bottom: 28px;
  transform: translateX(-50%);
  display: flex;
  gap: 10px;
}

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

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

.content-section,
.category-block {
  max-width: 1280px;
  margin: 0 auto;
  padding: 72px 24px;
}

.section-white {
  max-width: none;
  background: white;
  padding-left: max(24px, calc((100vw - 1280px) / 2 + 24px));
  padding-right: max(24px, calc((100vw - 1280px) / 2 + 24px));
}

.section-soft {
  border-top: 1px solid var(--line);
}

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

.section-head h2,
.page-hero h1,
.detail-article h1 {
  margin: 0;
  color: #1f2937;
  font-size: clamp(2rem, 4vw, 3rem);
  line-height: 1.1;
}

.section-head p {
  margin: 8px 0 0;
  color: var(--muted);
}

.section-link {
  color: var(--blue);
  padding: 0;
  min-height: auto;
}

.movie-grid {
  display: grid;
  gap: 24px;
}

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

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

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

.movie-card {
  overflow: hidden;
  border-radius: var(--radius);
  background: var(--panel);
  box-shadow: 0 10px 26px rgba(15, 23, 42, 0.08);
  transition: transform 220ms ease, box-shadow 220ms ease;
}

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

.poster-link {
  position: relative;
  display: block;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: #111827;
}

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

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

.poster-year,
.rank-badge {
  position: absolute;
  top: 12px;
  border-radius: 999px;
  color: white;
  font-size: 0.78rem;
  font-weight: 850;
  padding: 4px 10px;
}

.poster-year {
  right: 12px;
  background: rgba(0, 0, 0, 0.66);
}

.rank-badge {
  left: 12px;
  min-width: 32px;
  text-align: center;
  background: linear-gradient(135deg, #ef4444, #f97316);
}

.card-body {
  padding: 18px;
}

.card-meta {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 650;
}

.card-meta a {
  color: var(--blue);
}

.card-body h3 {
  margin: 10px 0 8px;
  font-size: 1.18rem;
  line-height: 1.3;
}

.card-body p {
  margin: 0;
  color: #4b5563;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

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

.tag-row span {
  border-radius: 999px;
  background: #eff6ff;
  color: #2563eb;
  font-size: 0.76rem;
  font-weight: 750;
  padding: 4px 9px;
}

.movie-card-list {
  display: grid;
  grid-template-columns: minmax(140px, 220px) 1fr;
}

.movie-card-list .poster-link {
  aspect-ratio: auto;
  height: 100%;
  min-height: 180px;
}

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

.category-tile {
  display: block;
  padding: 18px;
  border-radius: var(--radius);
  background: white;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.08);
  transition: transform 220ms ease, box-shadow 220ms ease;
}

.category-tile:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow);
}

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

.category-covers img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: 10px;
}

.category-tile strong {
  display: block;
  font-size: 1.1rem;
  margin-bottom: 6px;
}

.category-tile span {
  color: var(--muted);
  font-size: 0.92rem;
}

.ranking-section {
  max-width: none;
  padding-left: max(24px, calc((100vw - 1280px) / 2 + 24px));
  padding-right: max(24px, calc((100vw - 1280px) / 2 + 24px));
  background: linear-gradient(135deg, #f3e8ff, #fce7f3, #dbeafe);
}

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

.page-hero {
  max-width: 1280px;
  margin: 0 auto;
  padding: 70px 24px 40px;
}

.compact-hero > div {
  position: relative;
  overflow: hidden;
  border-radius: 28px;
  padding: 56px;
  color: white;
  background: linear-gradient(135deg, #dc2626, #f97316, #9333ea);
  box-shadow: var(--shadow);
}

.compact-hero h1 {
  color: white;
}

.compact-hero p {
  max-width: 720px;
  color: rgba(255, 255, 255, 0.9);
}

.filter-panel {
  display: grid;
  grid-template-columns: 1fr 220px;
  gap: 16px;
  margin-bottom: 28px;
  padding: 18px;
  border-radius: var(--radius);
  background: white;
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.07);
}

.single-search {
  grid-template-columns: 1fr;
}

.category-anchor-bar {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 24px 10px;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.category-anchor-bar a {
  border-radius: 999px;
  padding: 8px 14px;
  background: white;
  color: #374151;
  font-weight: 750;
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.06);
}

.detail-main {
  max-width: 1280px;
  margin: 0 auto;
  padding: 28px 24px 0;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  margin: 12px 0 24px;
  font-size: 0.95rem;
}

.breadcrumb a {
  color: var(--blue);
  font-weight: 700;
}

.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 26px;
  align-items: stretch;
}

.player-card,
.detail-side,
.detail-article {
  border-radius: 24px;
  overflow: hidden;
  background: white;
  box-shadow: 0 14px 35px rgba(15, 23, 42, 0.09);
}

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

.video-shell video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  background: #030712;
}

.play-layer {
  position: absolute;
  inset: 0;
  z-index: 5;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  color: white;
  cursor: pointer;
  background: radial-gradient(circle at 50% 45%, rgba(255, 255, 255, 0.16), transparent 30%), rgba(0, 0, 0, 0.42);
}

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

.play-button {
  width: 88px;
  height: 88px;
  border: 0;
  border-radius: 999px;
  color: #111827;
  background: white;
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.25);
  font-size: 34px;
  cursor: pointer;
}

.play-layer span {
  font-weight: 850;
  text-shadow: 0 6px 18px rgba(0, 0, 0, 0.45);
}

.detail-side img {
  width: 100%;
  aspect-ratio: 16 / 11;
  object-fit: cover;
}

.detail-side-body {
  padding: 22px;
}

.detail-side h2 {
  margin: 0 0 10px;
  font-size: 1.6rem;
  line-height: 1.25;
}

.detail-side p {
  color: #4b5563;
}

.meta-list {
  margin: 18px 0 0;
}

.meta-list div {
  display: grid;
  grid-template-columns: 58px 1fr;
  gap: 12px;
  padding: 9px 0;
  border-bottom: 1px solid #eef2f7;
}

.meta-list dt {
  color: var(--muted);
}

.meta-list dd {
  margin: 0;
  font-weight: 750;
}

.detail-tags {
  margin-top: 18px;
}

.detail-article {
  margin-top: 28px;
  padding: 34px;
}

.detail-article h1 {
  margin-bottom: 14px;
}

.detail-article h2 {
  margin: 28px 0 10px;
  font-size: 1.55rem;
}

.detail-article p {
  color: #374151;
  font-size: 1.05rem;
}

.lead-text {
  font-size: 1.18rem;
  color: #111827;
  font-weight: 650;
}

.related-section {
  padding-left: 0;
  padding-right: 0;
}

.site-footer {
  margin-top: 70px;
  background: #111827;
  color: #d1d5db;
}

.footer-inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 46px 24px;
  display: flex;
  justify-content: space-between;
  gap: 28px;
}

.footer-brand p {
  max-width: 420px;
  color: #9ca3af;
}

.brand-dark .brand-text {
  color: white;
  background: none;
  -webkit-background-clip: initial;
  background-clip: initial;
}

.footer-links {
  display: flex;
  align-items: center;
  gap: 22px;
  flex-wrap: wrap;
  font-weight: 700;
}

.footer-links a:hover {
  color: white;
}

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

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

@keyframes pulseGlow {
  0%, 100% {
    transform: translateY(0) scale(1);
    box-shadow: 0 22px 55px rgba(0, 0, 0, 0.26);
  }
  50% {
    transform: translateY(-4px) scale(1.04);
    box-shadow: 0 26px 70px rgba(255, 255, 255, 0.18);
  }
}

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

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

  .detail-side {
    display: grid;
    grid-template-columns: 320px 1fr;
  }
}

@media (max-width: 840px) {
  .nav-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  .nav-links {
    display: none;
    width: 100%;
    margin-left: 0;
    padding-bottom: 16px;
    flex-direction: column;
    align-items: flex-start;
    gap: 14px;
  }

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

  .hero {
    height: 76vh;
    min-height: 560px;
  }

  .section-head,
  .footer-inner {
    align-items: flex-start;
    flex-direction: column;
  }

  .two-cols,
  .three-cols,
  .four-cols,
  .category-grid,
  .ranking-list {
    grid-template-columns: 1fr 1fr;
  }

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

  .compact-hero > div {
    padding: 36px 24px;
  }

  .detail-side {
    display: block;
  }
}

@media (max-width: 560px) {
  .nav-wrap,
  .content-section,
  .category-block,
  .page-hero,
  .detail-main {
    padding-left: 16px;
    padding-right: 16px;
  }

  .brand-text {
    font-size: 19px;
  }

  .hero-content {
    padding: 0 16px;
  }

  .hero-logo-pulse {
    width: 82px;
    height: 82px;
  }

  .hero-logo-pulse span {
    font-size: 42px;
  }

  .two-cols,
  .three-cols,
  .four-cols,
  .category-grid,
  .ranking-list {
    grid-template-columns: 1fr;
  }

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

  .movie-card-list .poster-link {
    min-height: auto;
    aspect-ratio: 16 / 10;
  }

  .detail-article {
    padding: 24px;
  }

  .play-button {
    width: 70px;
    height: 70px;
    font-size: 28px;
  }
}
