html {
  background: #020617;
}

body {
  min-height: 100vh;
  background:
    radial-gradient(circle at 20% 0%, rgba(245, 158, 11, 0.13), transparent 32rem),
    radial-gradient(circle at 80% 8%, rgba(14, 165, 233, 0.1), transparent 28rem),
    #020617;
  color: #e5e7eb;
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

a {
  color: inherit;
}

img {
  display: block;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(2, 6, 23, 0.82);
  border-bottom: 1px solid rgba(148, 163, 184, 0.12);
  backdrop-filter: blur(20px);
}

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

.brand,
.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  letter-spacing: 0.02em;
  color: #f8fafc;
}

.brand-mark {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  color: #0f172a;
  background: linear-gradient(135deg, #f59e0b, #fde68a);
  box-shadow: 0 12px 34px rgba(245, 158, 11, 0.24);
}

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

.site-nav a {
  padding: 10px 14px;
  border-radius: 999px;
  color: #cbd5e1;
  font-size: 14px;
  transition: 0.22s ease;
}

.site-nav a:hover,
.site-nav a.active {
  color: #fbbf24;
  background: rgba(245, 158, 11, 0.12);
}

.nav-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 14px;
  background: rgba(15, 23, 42, 0.72);
}

.nav-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  margin: 4px auto;
  border-radius: 20px;
  background: #f8fafc;
}

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

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

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

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

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

.hero-overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(2, 6, 23, 0.96) 0%, rgba(2, 6, 23, 0.76) 42%, rgba(2, 6, 23, 0.28) 100%),
    linear-gradient(0deg, #020617 0%, rgba(2, 6, 23, 0.36) 44%, rgba(2, 6, 23, 0.08) 100%);
}

.hero-content {
  position: absolute;
  left: max(24px, calc((100% - 1180px) / 2));
  bottom: 130px;
  width: min(690px, calc(100% - 48px));
}

.hero-kicker,
.eyebrow {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  border: 1px solid rgba(245, 158, 11, 0.28);
  border-radius: 999px;
  padding: 6px 12px;
  background: rgba(245, 158, 11, 0.13);
  color: #fbbf24;
  font-size: 13px;
  font-weight: 700;
}

.hero-content h1 {
  margin-top: 18px;
  color: #ffffff;
  font-size: clamp(40px, 7vw, 72px);
  line-height: 0.96;
  font-weight: 900;
  letter-spacing: -0.04em;
}

.hero-content p {
  margin-top: 20px;
  max-width: 620px;
  color: #cbd5e1;
  font-size: 18px;
  line-height: 1.8;
}

.hero-tags,
.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.hero-tags {
  margin-top: 22px;
}

.hero-tags span,
.tag-row span {
  border: 1px solid rgba(148, 163, 184, 0.18);
  border-radius: 999px;
  padding: 6px 10px;
  background: rgba(15, 23, 42, 0.68);
  color: #cbd5e1;
  font-size: 12px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 26px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 18px;
  border-radius: 999px;
  border: 1px solid rgba(245, 158, 11, 0.36);
  background: rgba(245, 158, 11, 0.12);
  color: #fbbf24;
  font-weight: 800;
  transition: transform 0.22s ease, box-shadow 0.22s ease, background 0.22s ease;
}

.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 38px rgba(245, 158, 11, 0.18);
}

.btn.primary {
  color: #111827;
  border-color: transparent;
  background: linear-gradient(135deg, #f59e0b, #fde68a);
}

.btn.ghost {
  color: #e5e7eb;
  border-color: rgba(226, 232, 240, 0.16);
  background: rgba(15, 23, 42, 0.56);
}

.btn.small {
  min-height: 38px;
  padding: 0 14px;
  font-size: 13px;
}

.hero-dots {
  position: absolute;
  left: max(24px, calc((100% - 1180px) / 2));
  bottom: 76px;
  display: flex;
  gap: 10px;
  z-index: 4;
}

.hero-dots button {
  width: 34px;
  height: 4px;
  border-radius: 99px;
  background: rgba(226, 232, 240, 0.26);
  transition: 0.24s ease;
}

.hero-dots button.is-active {
  width: 56px;
  background: #f59e0b;
}

.hero-rail {
  position: absolute;
  right: max(24px, calc((100% - 1180px) / 2));
  bottom: 80px;
  z-index: 4;
  display: grid;
  gap: 12px;
  width: 300px;
}

.hero-rail-card {
  display: grid;
  grid-template-columns: 72px 1fr;
  gap: 12px;
  align-items: center;
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 18px;
  padding: 8px;
  background: rgba(15, 23, 42, 0.68);
  backdrop-filter: blur(16px);
  color: #e2e8f0;
  transition: 0.22s ease;
}

.hero-rail-card:hover,
.hero-rail-card.is-active {
  border-color: rgba(245, 158, 11, 0.55);
  background: rgba(245, 158, 11, 0.14);
}

.hero-rail-card img {
  width: 72px;
  height: 48px;
  border-radius: 12px;
  object-fit: cover;
}

.hero-rail-card span {
  font-size: 14px;
  font-weight: 700;
  line-height: 1.35;
}

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

.content-section,
.split-section,
.detail-content,
.related-section {
  padding: 64px 0;
}

.section-heading,
.filter-panel {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 28px;
  margin-bottom: 28px;
}

.section-heading h2,
.panel-title h2,
.filter-panel h2,
.story-card h2 {
  margin-top: 10px;
  color: #f8fafc;
  font-size: clamp(26px, 4vw, 38px);
  line-height: 1.1;
  font-weight: 900;
  letter-spacing: -0.03em;
}

.section-heading p,
.filter-panel p {
  margin-top: 10px;
  max-width: 680px;
  color: #94a3b8;
}

.section-link {
  color: #fbbf24;
  font-weight: 800;
}

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

.movie-card {
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, 0.13);
  border-radius: 24px;
  background: rgba(15, 23, 42, 0.84);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.22);
  transition: transform 0.24s ease, border-color 0.24s ease, box-shadow 0.24s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  border-color: rgba(245, 158, 11, 0.44);
  box-shadow: 0 26px 80px rgba(0, 0, 0, 0.34);
}

.movie-card.is-hidden {
  display: none;
}

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

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

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

.poster-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(2, 6, 23, 0.78), rgba(2, 6, 23, 0.05));
}

.play-chip,
.rank-badge {
  position: absolute;
  z-index: 2;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
}

.play-chip {
  right: 12px;
  bottom: 12px;
  padding: 7px 10px;
  background: rgba(245, 158, 11, 0.92);
  color: #111827;
}

.rank-badge {
  left: 12px;
  top: 12px;
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  background: rgba(15, 23, 42, 0.82);
  color: #fde68a;
  border: 1px solid rgba(253, 230, 138, 0.28);
}

.movie-card-body {
  padding: 16px;
}

.movie-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: #94a3b8;
  font-size: 12px;
}

.movie-meta a {
  color: #fbbf24;
  font-weight: 800;
}

.movie-card h3 {
  margin-top: 10px;
  color: #f8fafc;
  font-size: 18px;
  line-height: 1.3;
  font-weight: 850;
}

.movie-card h3 a:hover {
  color: #fbbf24;
}

.movie-card p {
  margin-top: 9px;
  min-height: 48px;
  color: #94a3b8;
  font-size: 14px;
  line-height: 1.65;
}

.movie-card .tag-row {
  margin-top: 14px;
}

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

.category-card {
  position: relative;
  min-height: 190px;
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, 0.15);
  border-radius: 26px;
  padding: 22px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  background: rgba(15, 23, 42, 0.8);
}

.category-card img,
.category-card span {
  position: absolute;
  inset: 0;
}

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

.category-card span {
  background: linear-gradient(0deg, rgba(2, 6, 23, 0.92), rgba(2, 6, 23, 0.18));
}

.category-card strong,
.category-card em {
  position: relative;
  z-index: 2;
}

.category-card strong {
  color: #ffffff;
  font-size: 22px;
  font-weight: 900;
}

.category-card em {
  margin-top: 8px;
  color: #cbd5e1;
  font-size: 13px;
  font-style: normal;
  line-height: 1.5;
}

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

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

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

.rank-panel {
  position: sticky;
  top: 92px;
  border: 1px solid rgba(148, 163, 184, 0.14);
  border-radius: 28px;
  padding: 22px;
  background: rgba(15, 23, 42, 0.82);
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.26);
}

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

.rank-row {
  display: grid;
  grid-template-columns: 34px 58px 1fr;
  gap: 12px;
  align-items: center;
  border-radius: 18px;
  padding: 8px;
  background: rgba(2, 6, 23, 0.48);
  transition: 0.22s ease;
}

.rank-row:hover {
  background: rgba(245, 158, 11, 0.12);
}

.rank-row b {
  color: #fbbf24;
  font-size: 18px;
}

.rank-row img {
  width: 58px;
  height: 42px;
  border-radius: 12px;
  object-fit: cover;
}

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

.rank-row strong {
  color: #f8fafc;
  font-size: 14px;
}

.rank-row em {
  margin-top: 3px;
  color: #94a3b8;
  font-size: 12px;
  font-style: normal;
}

.panel-btn {
  width: 100%;
  margin-top: 18px;
}

.page-main {
  padding-top: 42px;
}

.page-hero {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, 0.14);
  border-radius: 34px;
  min-height: 300px;
  padding: 38px;
  display: flex;
  align-items: end;
  background: linear-gradient(135deg, rgba(15, 23, 42, 0.92), rgba(30, 41, 59, 0.64));
}

.compact-hero {
  min-height: 260px;
}

.category-hero img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.34;
}

.category-hero:after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(2, 6, 23, 0.95), rgba(2, 6, 23, 0.44));
}

.page-hero > div {
  position: relative;
  z-index: 2;
  max-width: 760px;
}

.page-hero h1 {
  margin-top: 12px;
  color: #ffffff;
  font-size: clamp(38px, 6vw, 66px);
  font-weight: 950;
  letter-spacing: -0.045em;
  line-height: 1;
}

.page-hero p {
  margin-top: 16px;
  color: #cbd5e1;
  font-size: 17px;
  line-height: 1.8;
}

.page-hero .btn {
  margin-top: 24px;
}

.filter-panel {
  align-items: center;
  border: 1px solid rgba(148, 163, 184, 0.14);
  border-radius: 28px;
  padding: 22px;
  background: rgba(15, 23, 42, 0.72);
}

.filter-controls {
  display: grid;
  grid-template-columns: minmax(220px, 1.4fr) minmax(130px, 0.8fr) minmax(130px, 0.8fr);
  gap: 12px;
  width: min(100%, 650px);
}

.filter-controls label {
  display: grid;
  gap: 6px;
  color: #94a3b8;
  font-size: 12px;
  font-weight: 800;
}

.filter-controls input,
.filter-controls select {
  min-height: 44px;
  border: 1px solid rgba(148, 163, 184, 0.18);
  border-radius: 14px;
  padding: 0 12px;
  background: rgba(2, 6, 23, 0.72);
  color: #e2e8f0;
  outline: none;
}

.filter-controls input:focus,
.filter-controls select:focus {
  border-color: rgba(245, 158, 11, 0.72);
  box-shadow: 0 0 0 4px rgba(245, 158, 11, 0.12);
}

.empty-state {
  display: none;
  margin-top: 24px;
  border: 1px solid rgba(148, 163, 184, 0.14);
  border-radius: 22px;
  padding: 28px;
  text-align: center;
  color: #cbd5e1;
  background: rgba(15, 23, 42, 0.7);
}

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

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

.category-overview-card {
  display: grid;
  grid-template-columns: 320px 1fr;
  gap: 24px;
  border: 1px solid rgba(148, 163, 184, 0.14);
  border-radius: 30px;
  padding: 18px;
  background: rgba(15, 23, 42, 0.76);
}

.category-cover {
  overflow: hidden;
  border-radius: 22px;
  aspect-ratio: 16 / 10;
}

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

.category-overview-card h2 {
  margin-top: 10px;
  color: #f8fafc;
  font-size: 30px;
  font-weight: 900;
}

.category-overview-card p {
  margin-top: 10px;
  color: #94a3b8;
  line-height: 1.75;
}

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

.mini-links a {
  border-radius: 999px;
  padding: 7px 10px;
  background: rgba(2, 6, 23, 0.58);
  color: #cbd5e1;
  font-size: 12px;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  padding: 26px 0 18px;
  color: #94a3b8;
  font-size: 14px;
}

.breadcrumb a {
  color: #fbbf24;
}

.breadcrumb em {
  color: #cbd5e1;
  font-style: normal;
}

.detail-hero {
  display: grid;
  grid-template-columns: 360px minmax(0, 1fr);
  gap: 34px;
  align-items: end;
  border: 1px solid rgba(148, 163, 184, 0.14);
  border-radius: 34px;
  padding: 24px;
  background:
    linear-gradient(135deg, rgba(15, 23, 42, 0.92), rgba(30, 41, 59, 0.62)),
    radial-gradient(circle at 80% 20%, rgba(245, 158, 11, 0.16), transparent 26rem);
}

.detail-poster {
  overflow: hidden;
  border-radius: 26px;
  aspect-ratio: 3 / 4;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.34);
}

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

.detail-info h1 {
  margin-top: 16px;
  color: #ffffff;
  font-size: clamp(36px, 6vw, 68px);
  line-height: 1;
  font-weight: 950;
  letter-spacing: -0.045em;
}

.detail-line {
  margin-top: 18px;
  color: #dbeafe;
  font-size: 18px;
  line-height: 1.8;
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}

.detail-meta span {
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 999px;
  padding: 8px 12px;
  background: rgba(2, 6, 23, 0.48);
  color: #cbd5e1;
  font-size: 13px;
}

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

.detail-info .btn {
  margin-top: 26px;
}

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

.player-frame {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(245, 158, 11, 0.22);
  border-radius: 30px;
  aspect-ratio: 16 / 9;
  background: #000;
  box-shadow: 0 28px 90px rgba(0, 0, 0, 0.42);
}

.player-frame video {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #000;
}

.player-overlay {
  position: absolute;
  inset: 0;
  z-index: 5;
  display: grid;
  place-items: center;
  gap: 14px;
  background: linear-gradient(0deg, rgba(2, 6, 23, 0.74), rgba(2, 6, 23, 0.28));
  color: #ffffff;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

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

.play-circle {
  width: 76px;
  height: 76px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  padding-left: 5px;
  background: linear-gradient(135deg, #f59e0b, #fde68a);
  color: #111827;
  font-size: 28px;
  box-shadow: 0 24px 60px rgba(245, 158, 11, 0.28);
}

.player-overlay strong {
  font-size: 18px;
}

.detail-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}

.story-card {
  border: 1px solid rgba(148, 163, 184, 0.14);
  border-radius: 28px;
  padding: 26px;
  background: rgba(15, 23, 42, 0.72);
}

.story-card p {
  margin-top: 16px;
  color: #cbd5e1;
  line-height: 1.9;
}

.site-footer {
  margin-top: 54px;
  border-top: 1px solid rgba(148, 163, 184, 0.12);
  background: rgba(2, 6, 23, 0.78);
}

.footer-inner {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 32px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  color: #94a3b8;
  font-size: 14px;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

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

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

  .split-section,
  .detail-hero,
  .detail-content {
    grid-template-columns: 1fr;
  }

  .rank-panel {
    position: static;
  }

  .hero-rail {
    display: none;
  }

  .category-overview-card {
    grid-template-columns: 260px 1fr;
  }
}

@media (max-width: 760px) {
  .nav-wrap {
    min-height: 64px;
  }

  .nav-toggle {
    display: block;
  }

  .site-nav {
    position: absolute;
    left: 16px;
    right: 16px;
    top: 72px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    border: 1px solid rgba(148, 163, 184, 0.16);
    border-radius: 20px;
    padding: 12px;
    background: rgba(2, 6, 23, 0.96);
  }

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

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

  .hero-content {
    bottom: 88px;
  }

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

  .hero-dots {
    bottom: 42px;
  }

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

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

  .filter-controls {
    grid-template-columns: 1fr;
    width: 100%;
  }

  .page-hero,
  .detail-hero {
    padding: 20px;
    border-radius: 24px;
  }

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

  .category-overview-card {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  main,
  .page-main,
  .detail-main,
  .footer-inner,
  .nav-wrap {
    width: min(100% - 22px, 1180px);
  }

  .movie-grid,
  .split-main .movie-grid,
  .category-grid {
    grid-template-columns: 1fr;
  }

  .hero-content h1,
  .page-hero h1,
  .detail-info h1 {
    letter-spacing: -0.03em;
  }

  .movie-card p {
    min-height: auto;
  }
}
