* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: #0f172a;
  background: #f8fafc;
  line-height: 1.6;
}

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

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

button,
input,
select {
  font: inherit;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  color: #fff;
  background: linear-gradient(90deg, #2563eb, #1d4ed8 55%, #0891b2);
  box-shadow: 0 20px 45px rgba(15, 23, 42, 0.18);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 20px 0;
}

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

.brand-icon {
  display: grid;
  width: 48px;
  height: 48px;
  place-items: center;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.18);
  backdrop-filter: blur(6px);
  font-size: 20px;
}

.brand-title,
.brand-subtitle {
  display: block;
}

.brand-title {
  font-size: 24px;
  font-weight: 800;
  letter-spacing: 0.02em;
}

.brand-subtitle {
  color: #dbeafe;
  font-size: 13px;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.nav-link {
  padding: 10px 16px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.10);
  transition: background 0.2s ease, transform 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
  background: rgba(255, 255, 255, 0.22);
  transform: translateY(-1px);
}

.mobile-menu-button {
  display: none;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 12px;
  color: #fff;
  background: rgba(255, 255, 255, 0.16);
}

.hero-section {
  position: relative;
  overflow: hidden;
  color: #fff;
  background: linear-gradient(180deg, #0f172a, #1e293b);
}

.hero-pattern {
  position: absolute;
  inset: 0;
  opacity: 0.16;
  background-image: radial-gradient(circle at 20px 20px, rgba(255, 255, 255, 0.25) 0 2px, transparent 2px), radial-gradient(circle at 50px 50px, rgba(96, 165, 250, 0.24) 0 3px, transparent 3px);
  background-size: 72px 72px;
  animation: pulseGlow 4s ease-in-out infinite;
}

@keyframes pulseGlow {
  50% {
    opacity: 0.08;
  }
}

.hero-container {
  position: relative;
  z-index: 1;
  padding: 64px 0 72px;
}

.hero-label,
.section-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #facc15;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.hero-label::before,
.section-kicker::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: currentColor;
  box-shadow: 0 0 24px currentColor;
}

.hero-layout {
  display: grid;
  grid-template-columns: minmax(320px, 0.95fr) minmax(320px, 1.05fr);
  align-items: center;
  gap: 48px;
  margin-top: 28px;
}

.hero-visual {
  position: relative;
  height: 520px;
  overflow: hidden;
  border-radius: 28px;
  box-shadow: 0 28px 70px rgba(0, 0, 0, 0.42);
}

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

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

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

.hero-cover-layer {
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.62), rgba(0, 0, 0, 0.05));
}

.hero-content {
  min-height: 520px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.hero-copy {
  display: none;
}

.hero-copy.is-active {
  display: block;
  animation: fadeUp 0.55s ease both;
}

@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.hero-pills,
.detail-meta,
.card-meta,
.tag-row,
.hero-actions,
.hero-score,
.hero-links,
.row-links,
.footer-links {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}

.hero-pills span,
.detail-meta span {
  padding: 8px 14px;
  border-radius: 999px;
  color: #e0f2fe;
  background: rgba(255, 255, 255, 0.12);
}

.hero-pills span:first-child {
  color: #fff;
  background: #2563eb;
}

.hero-copy h1,
.hero-copy h2 {
  margin: 20px 0 16px;
  font-size: clamp(34px, 5vw, 62px);
  line-height: 1.05;
  font-weight: 900;
}

.hero-copy p {
  max-width: 720px;
  margin: 0;
  color: #cbd5e1;
  font-size: 18px;
}

.hero-score {
  margin: 26px 0;
  color: #94a3b8;
}

.hero-score strong {
  color: #facc15;
  font-size: 26px;
  margin-left: 6px;
}

.primary-button,
.ghost-button,
.text-button,
.panel-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 12px 22px;
  border-radius: 14px;
  font-weight: 800;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.primary-button {
  color: #fff;
  background: #2563eb;
  box-shadow: 0 14px 30px rgba(37, 99, 235, 0.28);
}

.primary-button:hover,
.panel-link:hover {
  transform: translateY(-2px);
  background: #1d4ed8;
}

.ghost-button {
  color: #fff;
  background: rgba(255, 255, 255, 0.14);
}

.ghost-button:hover {
  background: rgba(255, 255, 255, 0.24);
}

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

.hero-dot {
  width: 32px;
  height: 5px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.28);
  transition: width 0.25s ease, background 0.25s ease;
}

.hero-dot.is-active {
  width: 52px;
  background: #2563eb;
}

.hero-search {
  display: flex;
  gap: 10px;
  padding: 8px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(8px);
}

.hero-search input {
  flex: 1;
  min-width: 0;
  border: 0;
  outline: 0;
  color: #fff;
  background: transparent;
  padding: 10px 12px;
}

.hero-search input::placeholder {
  color: #bfdbfe;
}

.hero-search button {
  border: 0;
  border-radius: 12px;
  padding: 10px 18px;
  color: #fff;
  background: #2563eb;
  font-weight: 800;
}

.hero-links {
  margin-top: 18px;
}

.hero-links a,
.row-links a,
.sample-links a {
  display: inline-flex;
  padding: 8px 12px;
  border-radius: 10px;
  color: #dbeafe;
  background: rgba(255, 255, 255, 0.10);
}

.hero-links a:hover,
.row-links a:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.20);
}

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

.section-heading {
  margin-bottom: 28px;
}

.section-heading h2 {
  margin: 8px 0 0;
  color: #1e293b;
  font-size: clamp(26px, 3vw, 38px);
  line-height: 1.15;
}

.section-heading p {
  max-width: 760px;
  margin: 12px 0 0;
  color: #64748b;
}

.section-heading.inverted h2,
.dark-band .section-heading h2,
.dark-band .section-heading p {
  color: #fff;
}

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

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

.movie-card {
  display: block;
  overflow: hidden;
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.08);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.movie-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 20px 36px rgba(15, 23, 42, 0.16);
}

.card-poster {
  position: relative;
  display: block;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  background: #e2e8f0;
}

.card-poster img,
.rank-poster img,
.detail-poster img,
.player-overlay img,
.category-covers img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

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

.card-poster img,
.rank-poster img {
  transition: transform 0.45s ease;
}

.rating-pill {
  position: absolute;
  top: 12px;
  right: 12px;
  padding: 5px 10px;
  border-radius: 999px;
  color: #fff;
  background: rgba(0, 0, 0, 0.72);
  font-size: 12px;
  font-weight: 800;
}

.play-badge {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: #2563eb;
  font-size: 30px;
  opacity: 0;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.72), rgba(0, 0, 0, 0.08));
  transition: opacity 0.25s ease;
}

.play-badge::before {
  content: "";
  position: absolute;
  width: 68px;
  height: 68px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.92);
}

.play-badge {
  isolation: isolate;
}

.play-badge::after {
  content: "▶";
  position: relative;
  z-index: 1;
  margin-left: 4px;
}

.movie-card:hover .play-badge,
.rank-card:hover .play-badge {
  opacity: 1;
}

.card-body {
  display: block;
  padding: 14px;
}

.card-body strong {
  display: block;
  min-height: 48px;
  color: #1e293b;
  font-size: 15px;
  line-height: 1.45;
  transition: color 0.2s ease;
}

.movie-card:hover .card-body strong,
.rank-card:hover strong {
  color: #2563eb;
}

.card-desc {
  display: -webkit-box;
  min-height: 44px;
  margin: 8px 0 12px;
  overflow: hidden;
  color: #64748b;
  font-size: 13px;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.card-meta {
  justify-content: space-between;
  color: #64748b;
  font-size: 12px;
}

.card-meta span:first-child {
  padding: 4px 8px;
  border-radius: 8px;
  background: #f1f5f9;
}

.movie-card.horizontal {
  display: grid;
  grid-template-columns: 150px 1fr;
  min-height: 200px;
}

.movie-card.horizontal .card-poster {
  aspect-ratio: auto;
  height: 100%;
}

.movie-card.horizontal .card-body {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 18px;
}

.blue-band {
  background: linear-gradient(135deg, #eff6ff, #ecfeff);
}

.dark-band {
  color: #fff;
  background: linear-gradient(135deg, #1e293b, #0f172a);
}

.split-section {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 380px;
  gap: 36px;
  align-items: start;
}

.ranking-panel {
  position: sticky;
  top: 110px;
  padding: 24px;
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.08);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.18);
}

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

.rank-card {
  display: grid;
  grid-template-columns: 52px 80px 1fr;
  gap: 14px;
  align-items: center;
  padding: 12px;
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.08);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.dark-band .rank-card {
  color: #0f172a;
}

.rank-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 18px 34px rgba(15, 23, 42, 0.16);
}

.rank-num {
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  border-radius: 999px;
  color: #fff;
  background: #2563eb;
  font-weight: 900;
}

.rank-poster {
  display: block;
  height: 106px;
  overflow: hidden;
  border-radius: 12px;
}

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

.rank-info span {
  display: -webkit-box;
  margin: 6px 0;
  overflow: hidden;
  color: #64748b;
  font-size: 13px;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.rank-info em {
  color: #2563eb;
  font-size: 12px;
  font-style: normal;
  font-weight: 800;
}

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

.panel-link {
  width: 100%;
  margin-top: 18px;
  color: #fff;
  background: #2563eb;
}

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

.category-tile,
.category-card-large {
  overflow: hidden;
  border-radius: 22px;
  background: #fff;
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.08);
}

.category-tile {
  display: block;
  padding: 18px;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.category-tile:hover {
  transform: translateY(-5px);
  box-shadow: 0 20px 36px rgba(15, 23, 42, 0.16);
}

.category-covers {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 6px;
  height: 118px;
  margin-bottom: 14px;
  overflow: hidden;
  border-radius: 16px;
}

.category-covers.large {
  height: 220px;
  margin: 0;
}

.category-tile strong,
.category-card-large h2 {
  display: block;
  color: #1e293b;
  font-size: 20px;
  margin: 8px 0;
}

.category-tile span:last-child,
.category-card-large p {
  color: #64748b;
}

.category-list {
  display: grid;
  gap: 24px;
}

.category-card-large {
  display: grid;
  grid-template-columns: 360px 1fr;
  gap: 24px;
  padding: 22px;
}

.sample-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 16px 0;
}

.sample-links a {
  color: #2563eb;
  background: #eff6ff;
}

.text-button {
  min-height: auto;
  padding: 10px 0;
  color: #2563eb;
}

.center-actions {
  display: flex;
  justify-content: center;
  margin-top: 32px;
}

.page-hero,
.detail-hero {
  position: relative;
  overflow: hidden;
  color: #fff;
  background: linear-gradient(135deg, #0f172a, #1e40af 55%, #0891b2);
}

.page-hero.compact .container {
  padding: 56px 0;
}

.page-hero h1 {
  margin: 14px 0;
  font-size: clamp(32px, 5vw, 54px);
  line-height: 1.08;
}

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

.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: #bfdbfe;
  font-size: 14px;
}

.breadcrumbs a::after {
  content: "/";
  margin-left: 8px;
  color: #93c5fd;
}

.category-hero .row-links {
  margin-top: 18px;
}

.filter-panel {
  display: grid;
  grid-template-columns: 1.7fr repeat(3, minmax(140px, 0.5fr));
  gap: 14px;
  align-items: end;
  margin-bottom: 28px;
  padding: 18px;
  border-radius: 22px;
  background: #fff;
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.08);
}

.filter-panel label,
.search-box {
  display: grid;
  gap: 6px;
  color: #475569;
  font-size: 13px;
  font-weight: 800;
}

.filter-panel input,
.filter-panel select {
  width: 100%;
  min-height: 46px;
  border: 1px solid #dbeafe;
  border-radius: 14px;
  outline: none;
  padding: 0 14px;
  color: #0f172a;
  background: #f8fafc;
}

.filter-panel input:focus,
.filter-panel select:focus {
  border-color: #2563eb;
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.10);
}

.empty-state {
  display: none;
  padding: 40px;
  border-radius: 22px;
  color: #64748b;
  text-align: center;
  background: #fff;
}

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

.detail-hero {
  min-height: 560px;
  display: flex;
  align-items: center;
}

.detail-bg {
  position: absolute;
  inset: 0;
  opacity: 0.18;
  background-position: center;
  background-size: cover;
  filter: blur(12px) saturate(1.1);
  transform: scale(1.06);
}

.detail-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(15, 23, 42, 0.95), rgba(15, 23, 42, 0.72), rgba(15, 23, 42, 0.92));
}

.detail-layout {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 320px minmax(0, 1fr);
  gap: 42px;
  align-items: center;
  padding: 64px 0;
}

.detail-poster {
  overflow: hidden;
  border-radius: 26px;
  box-shadow: 0 28px 70px rgba(0, 0, 0, 0.42);
}

.detail-info h1 {
  margin: 18px 0;
  font-size: clamp(34px, 5vw, 64px);
  line-height: 1.05;
}

.detail-info p {
  max-width: 820px;
  color: #cbd5e1;
  font-size: 18px;
}

.tag-row {
  margin-top: 18px;
}

.tag {
  display: inline-flex;
  padding: 7px 12px;
  border-radius: 999px;
  color: #1d4ed8;
  background: #dbeafe;
  font-size: 13px;
  font-weight: 800;
}

.player-section {
  padding-bottom: 32px;
}

.video-stage {
  position: relative;
  overflow: hidden;
  border-radius: 26px;
  background: #020617;
  box-shadow: 0 24px 60px rgba(15, 23, 42, 0.22);
  aspect-ratio: 16 / 9;
}

.video-stage video {
  width: 100%;
  height: 100%;
  background: #020617;
}

.player-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: opacity 0.25s ease;
}

.player-overlay::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.62), rgba(0, 0, 0, 0.14));
}

.player-overlay img {
  position: absolute;
  inset: 0;
}

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

.big-play {
  position: relative;
  z-index: 1;
  display: grid;
  width: 92px;
  height: 92px;
  place-items: center;
  border: 0;
  border-radius: 999px;
  color: #2563eb;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.28);
  font-size: 36px;
  transition: transform 0.2s ease;
}

.big-play:hover {
  transform: scale(1.06);
}

.player-title {
  margin-top: 22px;
  padding: 22px;
  border-radius: 22px;
  background: #fff;
  box-shadow: 0 10px 26px rgba(15, 23, 42, 0.08);
}

.player-title h2 {
  margin: 0 0 8px;
  color: #1e293b;
  font-size: 28px;
}

.player-title p {
  margin: 0;
  color: #64748b;
}

.detail-content {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 360px);
  gap: 24px;
  align-items: start;
  padding: 32px 0;
}

.content-card {
  padding: 28px;
  border-radius: 22px;
  background: #fff;
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.08);
}

.main-copy h2,
.quick-card h2 {
  margin: 0 0 16px;
  color: #1e293b;
  font-size: 24px;
}

.main-copy p {
  margin: 0;
  color: #334155;
  font-size: 17px;
  line-height: 1.9;
  white-space: pre-line;
}

.quick-card {
  grid-row: span 2;
}

.quick-card dl {
  display: grid;
  grid-template-columns: 72px 1fr;
  gap: 10px 14px;
  margin: 0;
}

.quick-card dt {
  color: #64748b;
  font-weight: 800;
}

.quick-card dd {
  margin: 0;
  color: #0f172a;
}

.site-footer {
  color: #cbd5e1;
  background: #0f172a;
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 34px 0;
}

.site-footer p {
  margin: 6px 0 0;
  color: #94a3b8;
}

.footer-links a {
  color: #dbeafe;
}

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

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

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

@media (max-width: 900px) {
  .mobile-menu-button {
    display: grid;
    place-items: center;
  }

  .header-inner {
    align-items: flex-start;
    flex-wrap: wrap;
  }

  .site-nav {
    display: none;
    width: 100%;
  }

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

  .hero-layout,
  .detail-layout,
  .split-section,
  .category-card-large,
  .detail-content,
  .filter-panel {
    grid-template-columns: 1fr;
  }

  .hero-content,
  .hero-visual {
    min-height: auto;
    height: auto;
  }

  .hero-visual {
    aspect-ratio: 16 / 10;
  }

  .hero-copy h1,
  .hero-copy h2,
  .detail-info h1 {
    font-size: 36px;
  }

  .ranking-panel {
    position: static;
  }

  .full-rank {
    grid-template-columns: 1fr;
  }

  .detail-poster {
    max-width: 320px;
  }
}

@media (max-width: 680px) {
  .container {
    width: min(100% - 24px, 1200px);
  }

  .brand-title {
    font-size: 20px;
  }

  .brand-subtitle {
    font-size: 12px;
  }

  .hero-container {
    padding: 40px 0 48px;
  }

  .hero-search,
  .footer-inner {
    flex-direction: column;
    align-items: stretch;
  }

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

  .card-body {
    padding: 12px;
  }

  .card-body strong {
    min-height: 42px;
    font-size: 14px;
  }

  .rank-card {
    grid-template-columns: 42px 70px 1fr;
    gap: 10px;
  }

  .rank-num {
    width: 36px;
    height: 36px;
    font-size: 13px;
  }

  .rank-poster {
    height: 92px;
  }

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

  .detail-hero {
    min-height: auto;
  }

  .video-stage {
    border-radius: 18px;
  }

  .big-play {
    width: 74px;
    height: 74px;
    font-size: 28px;
  }
}
