:root {
  color-scheme: dark;
  --bg: #020617;
  --panel: rgba(15, 23, 42, 0.88);
  --panel-soft: rgba(30, 41, 59, 0.82);
  --line: rgba(148, 163, 184, 0.2);
  --text: #f8fafc;
  --muted: #cbd5e1;
  --soft: #94a3b8;
  --accent: #f59e0b;
  --accent-2: #fbbf24;
  --blue: #1e3a8a;
  --shadow: 0 24px 60px rgba(0, 0, 0, 0.36);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scrollbar-width: thin;
  scrollbar-color: rgb(245, 158, 11) rgb(15, 23, 42);
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--text);
  background: linear-gradient(180deg, #020617 0%, #172554 44%, #020617 100%);
}

body::before {
  position: fixed;
  inset: 0;
  z-index: -1;
  content: "";
  background:
    radial-gradient(circle at 12% 8%, rgba(245, 158, 11, 0.16), transparent 32%),
    radial-gradient(circle at 88% 18%, rgba(59, 130, 246, 0.18), transparent 36%);
}

img {
  max-width: 100%;
}

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

button,
input,
select {
  font: inherit;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: linear-gradient(90deg, rgba(15, 23, 42, 0.96), rgba(30, 64, 175, 0.92), rgba(15, 23, 42, 0.96));
  border-bottom: 1px solid var(--line);
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.3);
  backdrop-filter: blur(18px);
}

.nav-wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 64px;
  gap: 18px;
}

.brand,
.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 24px;
  font-weight: 800;
  letter-spacing: 0.02em;
  background: linear-gradient(90deg, #fde68a, #f59e0b);
  background-clip: text;
  -webkit-background-clip: text;
  color: transparent;
}

.brand-mark {
  display: inline-grid;
  width: 34px;
  height: 34px;
  place-items: center;
  color: var(--accent-2);
  background: rgba(245, 158, 11, 0.12);
  border: 1px solid rgba(245, 158, 11, 0.3);
  border-radius: 12px;
  box-shadow: 0 0 24px rgba(245, 158, 11, 0.22);
}

.site-menu {
  display: flex;
  align-items: center;
  gap: 18px;
  color: #e2e8f0;
  font-weight: 600;
}

.site-menu a {
  transition: color 0.2s ease;
}

.site-menu a:hover,
.site-menu a.active {
  color: var(--accent-2);
}

.menu-toggle {
  display: none;
  border: 0;
  color: #fff;
  background: rgba(15, 23, 42, 0.72);
  border-radius: 12px;
  padding: 8px 11px;
  cursor: pointer;
}

.hero-carousel {
  position: relative;
  min-height: 70vh;
  overflow: hidden;
  background: #0f172a;
}

.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%;
  display: block;
  object-fit: cover;
  transform: scale(1.03);
}

.hero-shade {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(0deg, #020617 0%, rgba(2, 6, 23, 0.88) 18%, rgba(2, 6, 23, 0.45) 56%, rgba(2, 6, 23, 0.52) 100%),
    linear-gradient(90deg, rgba(2, 6, 23, 0.95) 0%, rgba(2, 6, 23, 0.48) 50%, rgba(2, 6, 23, 0.12) 100%);
}

.hero-content {
  position: absolute;
  left: 50%;
  bottom: 112px;
  transform: translateX(-50%);
  z-index: 2;
}

.hero-kicker,
.section-heading p,
.page-hero p {
  margin: 0 0 12px;
  color: var(--accent-2);
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.hero-content h1 {
  max-width: 860px;
  margin: 0 0 18px;
  font-size: clamp(40px, 7vw, 76px);
  line-height: 0.98;
  font-weight: 900;
  letter-spacing: -0.04em;
  text-shadow: 0 20px 50px rgba(0, 0, 0, 0.56);
}

.hero-content p {
  max-width: 720px;
  margin: 0 0 24px;
  color: #e2e8f0;
  font-size: clamp(17px, 2.4vw, 22px);
  line-height: 1.65;
}

.hero-tags,
.detail-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 24px;
}

.hero-tags span,
.detail-tags span {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 5px 12px;
  color: #fff7ed;
  background: rgba(245, 158, 11, 0.18);
  border: 1px solid rgba(245, 158, 11, 0.36);
  border-radius: 999px;
}

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

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

.primary-button {
  color: #fff;
  background: linear-gradient(90deg, #f59e0b, #d97706);
  box-shadow: 0 16px 36px rgba(245, 158, 11, 0.25);
}

.ghost-button,
.section-link {
  color: #e2e8f0;
  background: rgba(15, 23, 42, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.14);
}

.primary-button:hover,
.ghost-button:hover,
.section-link:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.28);
}

.hero-arrow {
  position: absolute;
  top: 50%;
  z-index: 4;
  display: grid;
  width: 46px;
  height: 46px;
  place-items: center;
  border: 0;
  color: #fff;
  background: rgba(0, 0, 0, 0.45);
  border-radius: 999px;
  cursor: pointer;
  transform: translateY(-50%);
}

.hero-prev {
  left: 24px;
}

.hero-next {
  right: 24px;
}

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

.hero-dot {
  width: 10px;
  height: 10px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.48);
  cursor: pointer;
  transition: width 0.2s ease, background 0.2s ease;
}

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

.hero-category-links {
  position: absolute;
  left: 50%;
  bottom: 20px;
  z-index: 4;
  display: flex;
  gap: 10px;
  overflow-x: auto;
  padding-bottom: 2px;
  transform: translateX(-50%);
}

.hero-category-links a {
  flex: 0 0 auto;
  padding: 8px 14px;
  color: #e2e8f0;
  background: rgba(15, 23, 42, 0.66);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 999px;
}

.main-content,
.page-shell {
  padding: 56px 0 20px;
}

.section {
  margin-bottom: 72px;
}

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

.section-heading h2,
.page-hero h1,
.story-card h2 {
  margin: 0;
  color: #fff;
  font-size: clamp(28px, 3.5vw, 42px);
  line-height: 1.1;
  font-weight: 900;
  letter-spacing: -0.03em;
}

.movie-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(156px, 1fr));
  gap: 18px;
}

.movie-card {
  position: relative;
  display: block;
  overflow: hidden;
  background: rgba(30, 41, 59, 0.88);
  border: 1px solid rgba(148, 163, 184, 0.14);
  border-radius: 16px;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.22);
  transition: transform 0.28s ease, box-shadow 0.28s ease, border-color 0.28s ease;
}

.movie-card:hover {
  transform: translateY(-7px);
  border-color: rgba(245, 158, 11, 0.45);
  box-shadow: 0 28px 60px rgba(0, 0, 0, 0.38);
}

.poster-wrap {
  position: relative;
  display: block;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  background: radial-gradient(circle at 35% 25%, rgba(245, 158, 11, 0.38), transparent 30%), linear-gradient(145deg, #0f172a, #1e3a8a 52%, #111827);
}

.poster-wrap img,
.detail-poster img,
.category-tile img,
.category-thumbs img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  transition: transform 0.45s ease, opacity 0.2s ease;
}

.poster-wrap img.is-missing,
.detail-poster img.is-missing,
.category-tile img.is-missing,
.category-thumbs img.is-missing,
.hero-slide img.is-missing,
.video-player[poster].is-missing {
  opacity: 0;
}

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

.poster-glow {
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.82), transparent 48%);
}

.play-ring {
  position: absolute;
  left: 50%;
  top: 50%;
  display: grid;
  width: 56px;
  height: 56px;
  place-items: center;
  color: #fff;
  background: rgba(245, 158, 11, 0.92);
  border-radius: 999px;
  opacity: 0;
  transform: translate(-50%, -50%) scale(0.85);
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.movie-card:hover .play-ring {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
}

.year-badge,
.rank-badge {
  position: absolute;
  top: 10px;
  right: 10px;
  padding: 4px 8px;
  color: #fff;
  font-size: 12px;
  font-weight: 800;
  background: rgba(0, 0, 0, 0.68);
  border-radius: 8px;
}

.rank-badge {
  left: 10px;
  right: auto;
  color: #111827;
  background: var(--accent-2);
}

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

.movie-card strong {
  display: -webkit-box;
  min-height: 42px;
  overflow: hidden;
  color: #fff;
  font-size: 15px;
  line-height: 1.4;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  transition: color 0.2s ease;
}

.movie-card:hover strong {
  color: var(--accent-2);
}

.movie-meta {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin: 8px 0;
  color: var(--soft);
  font-size: 12px;
}

.movie-meta span:last-child {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.movie-line {
  display: -webkit-box;
  min-height: 40px;
  overflow: hidden;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.category-grid,
.category-overview-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 18px;
}

.category-tile,
.category-overview {
  position: relative;
  display: block;
  min-height: 180px;
  overflow: hidden;
  padding: 24px;
  background: linear-gradient(135deg, rgba(30, 41, 59, 0.94), rgba(15, 23, 42, 0.96));
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 20px;
  box-shadow: var(--shadow);
}

.category-tile span,
.category-overview span {
  position: relative;
  z-index: 2;
  display: inline-flex;
  color: #fff;
  font-size: 22px;
  font-weight: 900;
}

.category-tile p,
.category-overview p {
  position: relative;
  z-index: 2;
  max-width: 260px;
  color: var(--muted);
  line-height: 1.7;
}

.category-tile img {
  position: absolute;
  right: -8px;
  bottom: -40px;
  width: 150px;
  height: 220px;
  border-radius: 16px;
  opacity: 0.38;
  transform: rotate(9deg);
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 22px;
  color: var(--soft);
}

.breadcrumb a {
  color: var(--accent-2);
}

.breadcrumb span::before,
.breadcrumb a + span::before,
.breadcrumb a + a::before {
  content: "/";
  margin-right: 8px;
  color: #64748b;
}

.page-hero {
  position: relative;
  overflow: hidden;
  margin-bottom: 26px;
  padding: 44px;
  background: linear-gradient(135deg, rgba(15, 23, 42, 0.94), rgba(30, 64, 175, 0.58));
  border: 1px solid rgba(148, 163, 184, 0.18);
  border-radius: 28px;
  box-shadow: var(--shadow);
}

.page-hero div {
  max-width: 760px;
  color: var(--muted);
  font-size: 18px;
  line-height: 1.75;
}

.filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  align-items: end;
  margin-bottom: 24px;
  padding: 16px;
  background: rgba(15, 23, 42, 0.72);
  border: 1px solid rgba(148, 163, 184, 0.14);
  border-radius: 20px;
}

.filter-bar label {
  display: grid;
  gap: 7px;
  color: var(--soft);
  font-size: 13px;
  font-weight: 700;
}

.search-box {
  flex: 1 1 280px;
}

.filter-bar input,
.filter-bar select {
  width: 100%;
  min-height: 44px;
  padding: 0 14px;
  color: #fff;
  background: rgba(2, 6, 23, 0.62);
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 14px;
  outline: none;
}

.filter-bar input:focus,
.filter-bar select:focus {
  border-color: rgba(245, 158, 11, 0.62);
  box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.14);
}

.empty-result {
  padding: 24px;
  color: var(--muted);
  text-align: center;
  background: rgba(15, 23, 42, 0.78);
  border: 1px solid rgba(148, 163, 184, 0.14);
  border-radius: 18px;
}

.category-thumbs {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin-bottom: 18px;
}

.category-thumbs img {
  aspect-ratio: 2 / 3;
  border-radius: 12px;
  background: linear-gradient(145deg, #0f172a, #1e3a8a);
}

.detail-hero {
  display: grid;
  grid-template-columns: minmax(220px, 330px) 1fr;
  gap: 34px;
  align-items: end;
  margin-bottom: 34px;
  padding: 28px;
  background: linear-gradient(135deg, rgba(15, 23, 42, 0.94), rgba(30, 64, 175, 0.48));
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 28px;
  box-shadow: var(--shadow);
}

.detail-poster {
  overflow: hidden;
  aspect-ratio: 2 / 3;
  background: linear-gradient(145deg, #0f172a, #1e3a8a);
  border-radius: 22px;
  box-shadow: 0 26px 60px rgba(0, 0, 0, 0.38);
}

.detail-info > p {
  margin: 0 0 12px;
  color: var(--accent-2);
  font-weight: 800;
}

.detail-info h1 {
  margin: 0 0 18px;
  font-size: clamp(34px, 5vw, 60px);
  line-height: 1.05;
  font-weight: 900;
  letter-spacing: -0.04em;
}

.detail-line {
  max-width: 820px;
  color: #e2e8f0;
  font-size: 18px;
  line-height: 1.75;
}

.movie-facts {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  max-width: 720px;
  margin: 24px 0;
}

.movie-facts div {
  padding: 14px;
  background: rgba(15, 23, 42, 0.72);
  border: 1px solid rgba(148, 163, 184, 0.14);
  border-radius: 16px;
}

.movie-facts dt {
  color: var(--soft);
  font-size: 12px;
}

.movie-facts dd {
  margin: 6px 0 0;
  color: #fff;
  font-weight: 800;
}

.player-card,
.story-card {
  margin-bottom: 38px;
  padding: 24px;
  background: rgba(15, 23, 42, 0.78);
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 24px;
  box-shadow: var(--shadow);
}

.video-shell {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16 / 9;
  background: #000;
  border-radius: 22px;
}

.video-player {
  width: 100%;
  height: 100%;
  display: block;
  background: #000;
}

.player-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  gap: 10px;
  color: #fff;
  border: 0;
  background: radial-gradient(circle at 50% 45%, rgba(245, 158, 11, 0.28), rgba(2, 6, 23, 0.68) 45%, rgba(2, 6, 23, 0.88));
  cursor: pointer;
}

.player-overlay span {
  display: grid;
  width: 74px;
  height: 74px;
  place-items: center;
  background: var(--accent);
  border-radius: 999px;
  box-shadow: 0 20px 50px rgba(245, 158, 11, 0.36);
}

.player-overlay strong {
  padding: 9px 18px;
  background: rgba(0, 0, 0, 0.42);
  border-radius: 999px;
}

.player-overlay.is-hidden {
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
}

.story-card p {
  color: #dbeafe;
  font-size: 17px;
  line-height: 1.9;
}

.story-card h2 + p {
  margin-top: 12px;
}

.story-card h2:not(:first-child) {
  margin-top: 30px;
}

.compact-card .movie-line {
  display: none;
}

.site-footer {
  margin-top: 70px;
  background: linear-gradient(90deg, rgba(15, 23, 42, 0.96), rgba(30, 64, 175, 0.78), rgba(15, 23, 42, 0.96));
  border-top: 1px solid rgba(148, 163, 184, 0.18);
}

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

.site-footer p,
.site-footer li {
  color: var(--muted);
  line-height: 1.75;
}

.site-footer ul {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.site-footer h2 {
  margin: 0 0 12px;
  font-size: 18px;
}

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

.footer-bottom {
  padding: 18px 0 28px;
  color: var(--soft);
  border-top: 1px solid rgba(148, 163, 184, 0.16);
}

@media (max-width: 900px) {
  .menu-toggle {
    display: inline-flex;
  }

  .site-menu {
    position: absolute;
    left: 16px;
    right: 16px;
    top: 64px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 12px;
    background: rgba(15, 23, 42, 0.96);
    border: 1px solid rgba(148, 163, 184, 0.18);
    border-radius: 18px;
  }

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

  .site-menu a {
    padding: 12px;
  }

  .hero-content {
    bottom: 116px;
  }

  .hero-arrow {
    display: none;
  }

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

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

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

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

  .brand {
    font-size: 20px;
  }

  .hero-carousel {
    min-height: 76vh;
  }

  .hero-content h1 {
    font-size: 40px;
  }

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

  .hero-category-links {
    width: calc(100% - 24px);
  }

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

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

  .movie-card strong {
    font-size: 14px;
  }

  .page-hero,
  .detail-hero,
  .player-card,
  .story-card {
    padding: 20px;
    border-radius: 22px;
  }

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