:root {
  --lava-50: #fff7ed;
  --lava-100: #ffedd5;
  --lava-400: #fb923c;
  --lava-500: #f97316;
  --lava-600: #ea580c;
  --lava-700: #c2410c;
  --ember-500: #d97706;
  --volcanic-50: #fafafa;
  --volcanic-100: #f4f4f5;
  --volcanic-200: #e4e4e7;
  --volcanic-300: #d4d4d8;
  --volcanic-400: #a1a1aa;
  --volcanic-500: #71717a;
  --volcanic-600: #52525b;
  --volcanic-700: #3f3f46;
  --volcanic-800: #27272a;
  --volcanic-900: #18181b;
  --black: #09090b;
  --white: #ffffff;
  --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.12), 0 4px 6px -4px rgb(0 0 0 / 0.12);
  --shadow-2xl: 0 25px 50px -12px rgb(0 0 0 / 0.35);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: linear-gradient(180deg, var(--volcanic-50), var(--volcanic-100));
  color: var(--volcanic-900);
  -webkit-font-smoothing: antialiased;
}

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

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

button,
input {
  font: inherit;
}

button {
  cursor: pointer;
}

h1,
h2,
h3,
h4,
p {
  margin: 0;
}

h1,
h2,
h3,
h4 {
  font-weight: 800;
  line-height: 1.15;
}

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

.section-spacing {
  padding: 72px 0;
}

.text-gradient-lava {
  background: linear-gradient(90deg, var(--lava-600), var(--lava-500), var(--ember-500));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.bg-gradient-volcanic,
.site-footer {
  background: linear-gradient(135deg, var(--volcanic-800), var(--volcanic-900), var(--black));
}

.card-hover {
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.card-hover:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-2xl);
}

.btn-primary,
.btn-secondary,
.btn-ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 46px;
  border-radius: 14px;
  padding: 12px 22px;
  border: 0;
  font-weight: 800;
  transition: transform 0.25s ease, background 0.25s ease, box-shadow 0.25s ease;
}

.btn-primary {
  background: var(--lava-600);
  color: var(--white);
  box-shadow: 0 14px 30px rgb(234 88 12 / 0.28);
}

.btn-primary:hover {
  background: var(--lava-700);
  transform: scale(1.04);
}

.btn-secondary {
  background: var(--white);
  color: var(--volcanic-900);
}

.btn-secondary:hover {
  transform: scale(1.04);
  box-shadow: var(--shadow-lg);
}

.btn-ghost {
  color: var(--white);
  background: rgb(255 255 255 / 0.14);
  border: 1px solid rgb(255 255 255 / 0.24);
  backdrop-filter: blur(12px);
}

.btn-ghost:hover {
  background: rgb(255 255 255 / 0.24);
  transform: scale(1.04);
}

.site-header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 80;
  transition: background 0.25s ease, box-shadow 0.25s ease, backdrop-filter 0.25s ease;
}

.site-header.is-scrolled,
.site-header.is-open {
  background: rgb(255 255 255 / 0.95);
  box-shadow: var(--shadow-lg);
  backdrop-filter: blur(14px);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 76px;
}

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

.brand-mark {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--lava-500), var(--lava-700));
  color: var(--white);
  box-shadow: 0 12px 26px rgb(234 88 12 / 0.34);
}

.brand-name {
  font-size: clamp(20px, 2.3vw, 30px);
  background: linear-gradient(90deg, var(--lava-600), var(--lava-500), var(--ember-500));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 30px;
}

.nav-link {
  position: relative;
  color: var(--volcanic-800);
  font-weight: 700;
  padding: 26px 0;
}

.nav-link::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 18px;
  width: 100%;
  height: 2px;
  background: var(--lava-600);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.25s ease;
}

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

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

.mobile-menu-button {
  display: none;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 12px;
  background: rgb(255 255 255 / 0.16);
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
}

.mobile-menu-button span {
  width: 22px;
  height: 2px;
  border-radius: 999px;
  background: var(--volcanic-800);
  transition: transform 0.25s ease, opacity 0.25s ease;
}

.site-header.is-open .mobile-menu-button span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.site-header.is-open .mobile-menu-button span:nth-child(2) {
  opacity: 0;
}

.site-header.is-open .mobile-menu-button span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.mobile-nav {
  display: none;
  background: var(--white);
  padding: 12px 16px 18px;
  box-shadow: var(--shadow-lg);
}

.mobile-nav.is-open {
  display: grid;
  gap: 8px;
}

.mobile-nav-link {
  border-radius: 14px;
  padding: 12px 14px;
  font-weight: 800;
  color: var(--volcanic-700);
}

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

main {
  min-height: 70vh;
}

.hero {
  position: relative;
  height: min(90vh, 880px);
  min-height: 620px;
  overflow: hidden;
  background: var(--volcanic-900);
}

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

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

.hero-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.04);
}

.hero-slide.is-active img {
  animation: slowZoom 8s ease forwards;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgb(0 0 0 / 0.86), rgb(0 0 0 / 0.46) 48%, rgb(0 0 0 / 0.16));
}

.hero-content {
  position: relative;
  z-index: 3;
  height: 100%;
  display: flex;
  align-items: flex-end;
  padding-bottom: 86px;
}

.hero-copy {
  max-width: 780px;
  color: var(--white);
  animation: fadeInUp 0.8s ease both;
}

.hero-copy h1,
.hero-copy h2 {
  max-width: 820px;
  margin-bottom: 20px;
  font-size: clamp(38px, 6vw, 76px);
  text-shadow: 0 18px 48px rgb(0 0 0 / 0.5);
}

.hero-copy p {
  max-width: 720px;
  margin-bottom: 26px;
  color: rgb(255 255 255 / 0.9);
  font-size: clamp(16px, 2vw, 22px);
  line-height: 1.8;
}

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

.hero-tags,
.eyebrow {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 18px;
}

.eyebrow span,
.hero-tags span {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 5px 11px;
  border-radius: 999px;
  background: rgb(255 255 255 / 0.14);
  color: rgb(255 255 255 / 0.92);
  font-size: 13px;
  font-weight: 800;
  backdrop-filter: blur(8px);
}

.hero-controls {
  position: absolute;
  z-index: 4;
  left: 50%;
  bottom: 32px;
  display: flex;
  gap: 10px;
  transform: translateX(-50%);
}

.hero-dot {
  width: 10px;
  height: 10px;
  border: 0;
  border-radius: 999px;
  background: rgb(255 255 255 / 0.48);
  transition: width 0.25s ease, background 0.25s ease;
}

.hero-dot.is-active {
  width: 34px;
  background: var(--lava-500);
}

.hero-arrow {
  position: absolute;
  top: 50%;
  z-index: 4;
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border: 0;
  border-radius: 50%;
  background: rgb(0 0 0 / 0.34);
  color: var(--white);
  transform: translateY(-50%);
  backdrop-filter: blur(8px);
  transition: background 0.25s ease, transform 0.25s ease;
}

.hero-arrow:hover {
  background: rgb(0 0 0 / 0.56);
  transform: translateY(-50%) scale(1.08);
}

.hero-prev {
  left: 24px;
}

.hero-next {
  right: 24px;
}

.page-hero {
  padding: 132px 0 56px;
  color: var(--white);
  background: radial-gradient(circle at 20% 20%, rgb(249 115 22 / 0.36), transparent 34%), linear-gradient(135deg, var(--volcanic-800), var(--volcanic-900), var(--black));
}

.page-hero h1 {
  margin-bottom: 14px;
  font-size: clamp(34px, 5vw, 58px);
}

.page-hero p {
  max-width: 760px;
  color: rgb(255 255 255 / 0.82);
  font-size: 18px;
  line-height: 1.85;
}

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

.section-head h2 {
  margin-bottom: 10px;
  font-size: clamp(30px, 4vw, 48px);
}

.section-head p {
  max-width: 760px;
  color: var(--volcanic-600);
  font-size: 18px;
  line-height: 1.8;
}

.section-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

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

.movie-card {
  overflow: hidden;
  border: 1px solid rgb(228 228 231 / 0.9);
  border-radius: 22px;
  background: var(--white);
  box-shadow: 0 12px 34px rgb(24 24 27 / 0.08);
}

.poster-frame {
  position: relative;
  height: 310px;
  overflow: hidden;
  background: var(--volcanic-200);
}

.poster-frame::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgb(0 0 0 / 0.62), transparent 48%);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.movie-card:hover .poster-frame::after {
  opacity: 1;
}

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

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

.play-chip {
  position: absolute;
  right: 14px;
  bottom: 14px;
  z-index: 2;
  border-radius: 999px;
  padding: 7px 12px;
  background: var(--lava-600);
  color: var(--white);
  font-size: 13px;
  font-weight: 900;
  opacity: 0;
  transform: translateY(6px);
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.movie-card:hover .play-chip {
  opacity: 1;
  transform: translateY(0);
}

.rank-badge {
  position: absolute;
  left: 14px;
  top: 14px;
  z-index: 2;
  min-width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--lava-500), var(--lava-700));
  color: var(--white);
  box-shadow: 0 12px 26px rgb(0 0 0 / 0.25);
}

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

.card-meta {
  margin-bottom: 8px;
  color: var(--lava-600);
  font-size: 13px;
  font-weight: 900;
}

.movie-card h3 {
  display: -webkit-box;
  min-height: 48px;
  margin-bottom: 9px;
  overflow: hidden;
  color: var(--volcanic-900);
  font-size: 19px;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.card-desc {
  display: -webkit-box;
  min-height: 46px;
  overflow: hidden;
  color: var(--volcanic-600);
  font-size: 14px;
  line-height: 1.65;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

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

.tag-row span {
  border-radius: 999px;
  padding: 5px 9px;
  background: var(--volcanic-100);
  color: var(--volcanic-600);
  font-size: 12px;
  font-weight: 800;
}

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

.category-card {
  position: relative;
  overflow: hidden;
  min-height: 172px;
  border-radius: 24px;
  padding: 24px;
  background: linear-gradient(135deg, var(--white), var(--lava-50));
  box-shadow: 0 12px 34px rgb(24 24 27 / 0.08);
}

.category-card::after {
  content: "";
  position: absolute;
  right: -32px;
  bottom: -42px;
  width: 130px;
  height: 130px;
  border-radius: 50%;
  background: rgb(249 115 22 / 0.16);
}

.category-card h2,
.category-card h3 {
  position: relative;
  z-index: 1;
  margin-bottom: 10px;
  font-size: 22px;
}

.category-card p {
  position: relative;
  z-index: 1;
  color: var(--volcanic-600);
  line-height: 1.7;
}

.scroller-wrap {
  position: relative;
}

.horizontal-scroller {
  display: grid;
  grid-auto-columns: 320px;
  grid-auto-flow: column;
  gap: 18px;
  overflow-x: auto;
  padding: 4px 0 18px;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
}

.horizontal-scroller::-webkit-scrollbar {
  display: none;
}

.wide-card {
  display: grid;
  grid-template-columns: 118px 1fr;
  min-height: 166px;
  overflow: hidden;
  border-radius: 22px;
  background: var(--white);
  box-shadow: 0 12px 34px rgb(24 24 27 / 0.08);
  scroll-snap-align: start;
}

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

.wide-card div {
  padding: 18px;
}

.wide-card span {
  color: var(--lava-600);
  font-size: 13px;
  font-weight: 900;
}

.wide-card h3 {
  margin: 8px 0;
  font-size: 18px;
}

.wide-card p {
  display: -webkit-box;
  overflow: hidden;
  color: var(--volcanic-600);
  line-height: 1.65;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
}

.filter-panel {
  display: grid;
  gap: 16px;
  margin-bottom: 28px;
  border: 1px solid rgb(228 228 231 / 0.9);
  border-radius: 24px;
  padding: 18px;
  background: rgb(255 255 255 / 0.86);
  box-shadow: 0 12px 34px rgb(24 24 27 / 0.08);
  backdrop-filter: blur(12px);
}

.search-box {
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: center;
  gap: 12px;
}

.search-box span {
  color: var(--lava-600);
  font-weight: 900;
}

.search-box input {
  width: 100%;
  min-height: 48px;
  border: 1px solid var(--volcanic-200);
  border-radius: 16px;
  padding: 0 16px;
  background: var(--white);
  color: var(--volcanic-900);
  outline: none;
  transition: border-color 0.25s ease, box-shadow 0.25s ease;
}

.search-box input:focus {
  border-color: var(--lava-500);
  box-shadow: 0 0 0 4px rgb(249 115 22 / 0.14);
}

.filter-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.filter-chip {
  border: 0;
  border-radius: 999px;
  padding: 9px 14px;
  background: var(--volcanic-100);
  color: var(--volcanic-700);
  font-weight: 800;
  transition: background 0.25s ease, color 0.25s ease, transform 0.25s ease;
}

.filter-chip:hover,
.filter-chip.is-active {
  background: var(--lava-600);
  color: var(--white);
  transform: translateY(-1px);
}

.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) minmax(300px, 0.8fr);
  gap: 34px;
  padding: 112px 0 72px;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 18px;
  color: var(--volcanic-500);
  font-size: 14px;
  font-weight: 800;
}

.breadcrumb a {
  color: var(--lava-600);
}

.player-shell {
  position: relative;
  overflow: hidden;
  border-radius: 28px;
  background: var(--black);
  box-shadow: var(--shadow-2xl);
}

.player-shell video {
  width: 100%;
  aspect-ratio: 16 / 9;
  background: var(--black);
}

.player-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background: linear-gradient(0deg, rgb(0 0 0 / 0.48), rgb(0 0 0 / 0.2));
  opacity: 1;
  transition: opacity 0.25s ease;
}

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

.player-start-button {
  display: grid;
  place-items: center;
  width: 88px;
  height: 88px;
  border: 0;
  border-radius: 50%;
  background: var(--lava-600);
  color: var(--white);
  font-size: 34px;
  box-shadow: 0 20px 44px rgb(0 0 0 / 0.42);
  transition: transform 0.25s ease, background 0.25s ease;
}

.player-start-button:hover {
  background: var(--lava-700);
  transform: scale(1.08);
}

.detail-title-card,
.detail-side-card,
.content-card {
  border: 1px solid rgb(228 228 231 / 0.9);
  border-radius: 28px;
  background: var(--white);
  box-shadow: 0 12px 34px rgb(24 24 27 / 0.08);
}

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

.detail-title-card h1 {
  margin-bottom: 16px;
  font-size: clamp(32px, 4vw, 58px);
}

.detail-title-card p {
  color: var(--volcanic-600);
  font-size: 18px;
  line-height: 1.85;
}

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

.detail-meta span {
  border-radius: 999px;
  padding: 8px 12px;
  background: var(--lava-50);
  color: var(--lava-700);
  font-size: 13px;
  font-weight: 900;
}

.content-card {
  margin-top: 24px;
  padding: 28px;
}

.content-card h2 {
  margin-bottom: 14px;
  color: var(--volcanic-900);
  font-size: 28px;
}

.content-card p {
  color: var(--volcanic-700);
  line-height: 1.95;
  font-size: 17px;
}

.detail-side-card {
  position: sticky;
  top: 100px;
  padding: 18px;
}

.detail-side-card img {
  width: 100%;
  max-height: 440px;
  border-radius: 22px;
  object-fit: cover;
}

.detail-side-card h2 {
  margin: 18px 0 12px;
  font-size: 24px;
}

.side-list {
  display: grid;
  gap: 10px;
}

.side-list a {
  display: grid;
  gap: 4px;
  border-radius: 16px;
  padding: 12px;
  background: var(--volcanic-100);
}

.side-list strong {
  color: var(--volcanic-900);
}

.side-list span {
  color: var(--volcanic-500);
  font-size: 13px;
}

.related-section {
  padding-bottom: 74px;
}

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

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 34px;
  padding: 58px 0;
}

.footer-logo .brand-name {
  color: var(--white);
  background: none;
}

.footer-brand p,
.site-footer a,
.footer-bottom {
  color: var(--volcanic-300);
}

.site-footer h2 {
  margin-bottom: 14px;
  font-size: 18px;
  color: var(--white);
}

.site-footer a {
  display: block;
  margin: 9px 0;
  transition: color 0.25s ease;
}

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

.footer-bottom {
  border-top: 1px solid rgb(255 255 255 / 0.12);
  padding: 20px;
  text-align: center;
  font-size: 14px;
}

.scroll-top {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 60;
  display: none;
  width: 48px;
  height: 48px;
  border: 0;
  border-radius: 50%;
  background: var(--lava-600);
  color: var(--white);
  box-shadow: var(--shadow-lg);
}

.scroll-top.is-visible {
  display: grid;
  place-items: center;
}

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

@keyframes slowZoom {
  from {
    transform: scale(1.02);
  }
  to {
    transform: scale(1.1);
  }
}

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

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

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

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

  .detail-side-card {
    position: static;
  }
}

@media (max-width: 820px) {
  .desktop-nav {
    display: none;
  }

  .mobile-menu-button {
    display: flex;
  }

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

  .hero-content {
    padding-bottom: 76px;
  }

  .hero-arrow {
    display: none;
  }

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

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

  .poster-frame {
    height: 260px;
  }
}

@media (max-width: 560px) {
  .container-custom {
    width: min(100% - 24px, 1280px);
  }

  .header-inner {
    height: 66px;
  }

  .brand-mark {
    width: 34px;
    height: 34px;
  }

  .hero {
    min-height: 540px;
  }

  .hero-copy p {
    -webkit-line-clamp: 3;
    display: -webkit-box;
    overflow: hidden;
    -webkit-box-orient: vertical;
  }

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

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

  .page-hero {
    padding-top: 108px;
  }

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

  .poster-frame {
    height: 340px;
  }

  .wide-card {
    grid-template-columns: 104px 1fr;
  }

  .horizontal-scroller {
    grid-auto-columns: 88%;
  }

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

  .detail-layout {
    padding-top: 92px;
  }

  .detail-title-card,
  .content-card {
    padding: 22px;
  }
}
