:root {
  --blue-900: #0f2f75;
  --blue-800: #164199;
  --blue-700: #1d4ed8;
  --blue-600: #2563eb;
  --blue-100: #dbeafe;
  --blue-50: #eff6ff;
  --gray-950: #030712;
  --gray-900: #111827;
  --gray-800: #1f2937;
  --gray-700: #374151;
  --gray-600: #4b5563;
  --gray-500: #6b7280;
  --gray-200: #e5e7eb;
  --gray-100: #f3f4f6;
  --gray-50: #f9fafb;
  --white: #ffffff;
  --shadow: 0 18px 45px rgba(15, 23, 42, 0.12);
  --radius: 22px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  background: var(--gray-50);
  color: var(--gray-900);
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

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

.site-header {
  backdrop-filter: blur(18px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  color: inherit;
  text-decoration: none;
}

.brand-icon,
.footer-logo span {
  display: inline-flex;
  width: 2.25rem;
  height: 2.25rem;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  color: var(--white);
  background: linear-gradient(135deg, var(--blue-600), var(--blue-900));
  box-shadow: 0 10px 20px rgba(37, 99, 235, 0.25);
}

.brand-copy {
  display: flex;
  flex-direction: column;
  line-height: 1.1;
}

.brand-title {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--gray-900);
}

.brand-subtitle {
  margin-top: 0.18rem;
  font-size: 0.72rem;
  color: var(--gray-500);
}

.desktop-nav {
  display: none;
  align-items: center;
  gap: 1.4rem;
}

.nav-link {
  position: relative;
  display: inline-flex;
  align-items: center;
  min-height: 4rem;
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--gray-700);
  text-decoration: none;
  transition: color 0.2s ease;
}

.nav-link::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0.6rem;
  height: 3px;
  border-radius: 999px;
  background: var(--blue-600);
  transform: scaleX(0);
  transform-origin: center;
  transition: transform 0.2s ease;
}

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

.nav-link:hover::after,
.nav-link.is-active::after {
  transform: scaleX(1);
}

.menu-toggle {
  display: inline-flex;
  width: 2.5rem;
  height: 2.5rem;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 0.75rem;
  background: var(--gray-100);
  color: var(--gray-900);
  font-size: 1.2rem;
  cursor: pointer;
}

.mobile-nav {
  display: none;
  border-top: 1px solid var(--gray-200);
  background: var(--white);
  padding: 0.75rem 1rem 1rem;
}

.mobile-nav.is-open {
  display: grid;
  gap: 0.35rem;
}

.mobile-link {
  display: block;
  border-radius: 0.75rem;
  padding: 0.75rem 1rem;
  color: var(--gray-700);
  font-weight: 700;
  text-decoration: none;
}

.mobile-link.is-active,
.mobile-link:hover {
  background: var(--blue-50);
  color: var(--blue-600);
}

.hero-slider {
  position: relative;
  height: clamp(520px, 72vh, 720px);
  overflow: hidden;
  background: linear-gradient(135deg, var(--blue-900), var(--blue-700));
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transform: scale(1.02);
  transition: opacity 0.75s ease, transform 0.75s ease;
  pointer-events: none;
}

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

.hero-bg,
.detail-bg {
  position: absolute;
  inset: 0;
}

.hero-bg img,
.detail-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.5;
  filter: saturate(1.1) contrast(1.05);
}

.hero-layer,
.detail-layer {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(4, 15, 42, 0.92), rgba(15, 47, 117, 0.72), rgba(37, 99, 235, 0.3));
}

.hero-content {
  position: relative;
  z-index: 2;
  display: flex;
  height: 100%;
  align-items: center;
}

.hero-copy {
  max-width: 760px;
  color: var(--white);
}

.hero-eyebrow,
.section-kicker,
.detail-kicker,
.player-heading p {
  margin-bottom: 0.9rem;
  color: var(--blue-100);
  font-size: 0.88rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.hero-copy h1 {
  font-size: clamp(2.6rem, 7vw, 5.8rem);
  line-height: 1;
  font-weight: 900;
  letter-spacing: -0.06em;
  text-shadow: 0 14px 35px rgba(0, 0, 0, 0.28);
}

.hero-summary {
  max-width: 680px;
  margin-top: 1.35rem;
  color: rgba(255, 255, 255, 0.9);
  font-size: clamp(1.05rem, 2.2vw, 1.35rem);
  line-height: 1.8;
}

.hero-tags,
.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.hero-tags {
  margin-top: 1.5rem;
}

.tag {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  background: var(--gray-100);
  padding: 0.3rem 0.7rem;
  color: var(--gray-600);
  font-size: 0.78rem;
  font-weight: 700;
}

.hero-tags .tag,
.detail-tags .tag {
  background: rgba(255, 255, 255, 0.16);
  color: var(--white);
  backdrop-filter: blur(14px);
}

.tag.large {
  padding: 0.45rem 0.85rem;
  font-size: 0.86rem;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-top: 2.2rem;
}

.button-primary,
.button-ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 3.1rem;
  border-radius: 0.9rem;
  padding: 0 1.35rem;
  font-weight: 850;
  text-decoration: none;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.button-primary {
  background: var(--blue-600);
  color: var(--white);
  box-shadow: 0 18px 34px rgba(37, 99, 235, 0.28);
}

.hero-actions .button-primary {
  background: var(--white);
  color: var(--blue-700);
}

.button-ghost {
  border: 1px solid rgba(255, 255, 255, 0.5);
  color: var(--white);
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(12px);
}

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

.hero-dots {
  position: absolute;
  left: 50%;
  bottom: 2rem;
  z-index: 4;
  display: flex;
  gap: 0.55rem;
  transform: translateX(-50%);
}

.hero-dot {
  width: 2.2rem;
  height: 0.34rem;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.36);
  cursor: pointer;
}

.hero-dot.is-active {
  background: var(--white);
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
}

.feature-grid div {
  border-radius: var(--radius);
  background: linear-gradient(135deg, var(--blue-50), var(--white));
  padding: 1.4rem;
  text-align: center;
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.07);
}

.feature-grid strong,
.feature-grid span {
  display: block;
}

.feature-grid strong {
  color: var(--gray-900);
  font-size: 1.1rem;
}

.feature-grid span {
  margin-top: 0.3rem;
  color: var(--gray-500);
  font-size: 0.9rem;
}

.section {
  padding: clamp(3.5rem, 7vw, 6.5rem) 0;
}

.section-soft {
  background: linear-gradient(180deg, var(--gray-50), var(--blue-50));
}

.section-blue {
  background: linear-gradient(135deg, var(--blue-900), var(--blue-700));
}

.section-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.section-header p {
  margin-bottom: 0.4rem;
  color: var(--blue-600);
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.section-header h2,
.split-title {
  color: var(--gray-900);
  font-size: clamp(1.8rem, 4vw, 3rem);
  line-height: 1.08;
  font-weight: 900;
  letter-spacing: -0.04em;
}

.section-header a {
  color: var(--blue-600);
  font-weight: 850;
  text-decoration: none;
}

.section-header.light p,
.section-header.light h2,
.section-header.light a {
  color: var(--white);
}

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

.category-card {
  position: relative;
  display: flex;
  min-height: 190px;
  flex-direction: column;
  justify-content: flex-end;
  overflow: hidden;
  border-radius: var(--radius);
  padding: 1.4rem;
  color: var(--white);
  text-decoration: none;
  background: linear-gradient(135deg, var(--blue-600), var(--blue-900));
  box-shadow: var(--shadow);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.category-card::before {
  content: "";
  position: absolute;
  width: 11rem;
  height: 11rem;
  right: -3rem;
  top: -3rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.16);
}

.category-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 24px 50px rgba(37, 99, 235, 0.25);
}

.category-icon {
  position: relative;
  z-index: 1;
  display: inline-flex;
  width: 3.3rem;
  height: 3.3rem;
  align-items: center;
  justify-content: center;
  border-radius: 1.1rem;
  background: rgba(255, 255, 255, 0.18);
  font-weight: 900;
  font-size: 1.35rem;
}

.category-name,
.category-desc {
  position: relative;
  z-index: 1;
}

.category-name {
  margin-top: 1.4rem;
  font-size: 1.4rem;
  font-weight: 900;
}

.category-desc {
  margin-top: 0.45rem;
  color: rgba(255, 255, 255, 0.82);
  line-height: 1.6;
}

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

.movie-card {
  display: flex;
  min-width: 0;
  flex-direction: column;
  overflow: hidden;
  border-radius: var(--radius);
  background: var(--white);
  color: inherit;
  text-decoration: none;
  box-shadow: 0 14px 32px rgba(15, 23, 42, 0.08);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.section-blue .movie-card {
  background: rgba(255, 255, 255, 0.94);
}

.movie-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 28px 58px rgba(15, 23, 42, 0.16);
}

.movie-cover {
  position: relative;
  display: block;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: linear-gradient(135deg, var(--blue-900), var(--blue-600));
}

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

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

.movie-badge,
.rank-chip {
  position: absolute;
  top: 0.75rem;
  border-radius: 999px;
  background: rgba(37, 99, 235, 0.92);
  color: var(--white);
  padding: 0.32rem 0.72rem;
  font-size: 0.74rem;
  font-weight: 850;
  backdrop-filter: blur(10px);
}

.movie-badge {
  right: 0.75rem;
}

.rank-chip {
  left: 0.75rem;
  background: rgba(3, 7, 18, 0.72);
}

.movie-body {
  display: flex;
  flex: 1;
  flex-direction: column;
  padding: 1.05rem;
}

.movie-title {
  display: block;
  color: var(--gray-900);
  font-size: 1.05rem;
  font-weight: 900;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.movie-desc {
  display: -webkit-box;
  min-height: 3.2rem;
  margin-top: 0.55rem;
  color: var(--gray-600);
  font-size: 0.9rem;
  line-height: 1.65;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.movie-meta {
  display: flex;
  gap: 0.8rem;
  margin-top: 0.8rem;
  color: var(--gray-500);
  font-size: 0.84rem;
  font-weight: 750;
}

.movie-body .tag-list {
  margin-top: 0.85rem;
}

.page-hero,
.detail-hero {
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, var(--blue-900), var(--blue-600));
  color: var(--white);
}

.page-hero {
  padding: clamp(4rem, 9vw, 6.5rem) 0;
}

.page-hero p {
  color: var(--blue-100);
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.page-hero h1 {
  margin-top: 0.5rem;
  font-size: clamp(2.2rem, 6vw, 4.4rem);
  font-weight: 950;
  letter-spacing: -0.05em;
}

.page-hero span {
  display: block;
  max-width: 760px;
  margin-top: 1rem;
  color: rgba(255, 255, 255, 0.86);
  font-size: 1.1rem;
  line-height: 1.8;
}

.filter-bar {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.8rem;
  margin-bottom: 2rem;
  border-radius: var(--radius);
  background: var(--gray-50);
  padding: 1rem;
  box-shadow: inset 0 0 0 1px var(--gray-200);
}

.filter-input,
.filter-select {
  min-height: 3.15rem;
  width: 100%;
  border: 1px solid var(--gray-200);
  border-radius: 0.9rem;
  background: var(--white);
  padding: 0 1rem;
  color: var(--gray-900);
  font: inherit;
  outline: none;
}

.filter-input:focus,
.filter-select:focus {
  border-color: var(--blue-600);
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.12);
}

.empty-state {
  border-radius: var(--radius);
  background: var(--gray-50);
  padding: 3rem;
  color: var(--gray-500);
  text-align: center;
  font-weight: 800;
}

.split-layout {
  display: grid;
  gap: 2rem;
}

.split-desc {
  max-width: 540px;
  margin: 1rem 0 1.5rem;
  color: var(--gray-600);
  line-height: 1.8;
}

.ranking-list {
  display: grid;
  gap: 0.8rem;
}

.rank-item {
  display: grid;
  grid-template-columns: auto 76px 1fr;
  gap: 1rem;
  align-items: center;
  border-radius: 1.2rem;
  background: var(--gray-50);
  padding: 0.75rem;
  color: inherit;
  text-decoration: none;
  transition: transform 0.2s ease, background 0.2s ease;
}

.rank-item:hover {
  background: var(--blue-50);
  transform: translateX(4px);
}

.rank-number {
  display: inline-flex;
  width: 2.6rem;
  height: 2.6rem;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: var(--blue-600);
  color: var(--white);
  font-weight: 900;
}

.rank-poster {
  display: block;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  border-radius: 0.9rem;
  background: var(--blue-900);
}

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

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

.rank-copy strong {
  color: var(--gray-900);
  font-size: 1rem;
}

.rank-copy em {
  margin-top: 0.3rem;
  color: var(--gray-500);
  font-style: normal;
  font-size: 0.88rem;
}

.category-preview + .category-preview {
  margin-top: 4rem;
}

.detail-hero {
  min-height: 620px;
}

.detail-wrap {
  position: relative;
  z-index: 2;
  padding-top: 2rem;
  padding-bottom: 4.5rem;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  align-items: center;
  margin-bottom: 2rem;
  color: rgba(255, 255, 255, 0.78);
  font-size: 0.92rem;
}

.breadcrumb a {
  color: rgba(255, 255, 255, 0.92);
  text-decoration: none;
  font-weight: 800;
}

.detail-grid {
  display: grid;
  gap: 2rem;
  align-items: center;
}

.detail-poster {
  max-width: 520px;
  overflow: hidden;
  border-radius: var(--radius);
  background: var(--blue-900);
  box-shadow: 0 32px 72px rgba(0, 0, 0, 0.35);
}

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

.detail-copy h1 {
  max-width: 780px;
  color: var(--white);
  font-size: clamp(2.1rem, 6vw, 4.6rem);
  line-height: 1.05;
  font-weight: 950;
  letter-spacing: -0.05em;
}

.detail-lead {
  max-width: 760px;
  margin-top: 1.2rem;
  color: rgba(255, 255, 255, 0.88);
  font-size: 1.1rem;
  line-height: 1.85;
}

.detail-meta-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.9rem;
  max-width: 720px;
  margin-top: 1.8rem;
}

.detail-meta-grid div {
  border-radius: 1rem;
  background: rgba(255, 255, 255, 0.13);
  padding: 0.9rem 1rem;
  backdrop-filter: blur(14px);
}

.detail-meta-grid span,
.detail-meta-grid strong {
  display: block;
}

.detail-meta-grid span {
  color: rgba(255, 255, 255, 0.64);
  font-size: 0.82rem;
}

.detail-meta-grid strong {
  margin-top: 0.25rem;
  color: var(--white);
  font-size: 0.96rem;
}

.detail-tags {
  margin-top: 1.4rem;
}

.player-card,
.content-card {
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: var(--shadow);
}

.player-card {
  overflow: hidden;
  margin-top: -7rem;
  position: relative;
  z-index: 5;
}

.player-heading {
  padding: 1.4rem 1.4rem 0;
}

.player-heading p {
  margin-bottom: 0.45rem;
  color: var(--blue-600);
}

.player-heading h2,
.content-card h2 {
  color: var(--gray-900);
  font-size: clamp(1.45rem, 3vw, 2rem);
  font-weight: 900;
}

.player-shell {
  position: relative;
  margin: 1.25rem;
  overflow: hidden;
  border-radius: 1.2rem;
  background: var(--gray-950);
  aspect-ratio: 16 / 9;
}

.movie-video {
  display: block;
  width: 100%;
  height: 100%;
  background: var(--gray-950);
  object-fit: contain;
}

.player-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 0;
  background: radial-gradient(circle at center, rgba(37, 99, 235, 0.18), rgba(0, 0, 0, 0.58));
  cursor: pointer;
  z-index: 3;
}

.player-overlay.is-hidden {
  display: none;
}

.play-circle {
  display: inline-flex;
  width: clamp(4.5rem, 12vw, 6.2rem);
  height: clamp(4.5rem, 12vw, 6.2rem);
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: var(--white);
  color: var(--blue-600);
  font-size: 2rem;
  padding-left: 0.2rem;
  box-shadow: 0 20px 45px rgba(0, 0, 0, 0.28);
  transition: transform 0.2s ease;
}

.player-overlay:hover .play-circle {
  transform: scale(1.08);
}

.content-grid {
  display: grid;
  gap: 1.2rem;
  margin-top: 1.4rem;
}

.content-card {
  padding: clamp(1.35rem, 4vw, 2rem);
}

.content-card p {
  margin-top: 0.9rem;
  color: var(--gray-700);
  line-height: 2;
}

.site-footer {
  color: #d1d5db;
}

.footer-grid {
  display: grid;
  gap: 2rem;
}

.footer-logo {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: var(--white);
  font-size: 1.15rem;
}

.footer-brand p {
  max-width: 640px;
  margin-top: 1rem;
  color: #9ca3af;
  line-height: 1.85;
}

.site-footer h3 {
  color: var(--white);
  font-size: 0.95rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.site-footer ul {
  display: grid;
  gap: 0.7rem;
  margin: 1rem 0 0;
  padding: 0;
  list-style: none;
}

.site-footer a {
  color: #d1d5db;
  text-decoration: none;
}

.site-footer a:hover {
  color: var(--white);
}

.footer-bottom {
  margin-top: 2.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 1.5rem;
  color: #9ca3af;
  font-size: 0.9rem;
}

@media (min-width: 640px) {
  .movie-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .filter-bar {
    grid-template-columns: minmax(0, 1fr) 220px 220px;
  }

  .filter-bar.single-search {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (min-width: 768px) {
  .desktop-nav {
    display: flex;
  }

  .menu-toggle {
    display: none;
  }

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

  .detail-grid {
    grid-template-columns: minmax(320px, 0.85fr) minmax(0, 1.15fr);
  }

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

  .footer-grid {
    grid-template-columns: 2fr 1fr 1fr;
  }
}

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

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

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

  .split-layout {
    grid-template-columns: 0.85fr 1.15fr;
    align-items: center;
  }
}

@media (max-width: 767px) {
  .section-header {
    display: block;
  }

  .section-header a {
    display: inline-flex;
    margin-top: 0.9rem;
  }

  .hero-slider {
    height: 620px;
  }

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

  .player-card {
    margin-top: -4rem;
  }
}
