:root {
  color-scheme: dark;
  --bg: #020617;
  --bg-soft: #0f172a;
  --panel: rgba(15, 23, 42, 0.78);
  --panel-strong: rgba(15, 23, 42, 0.94);
  --line: rgba(255, 255, 255, 0.1);
  --line-strong: rgba(255, 255, 255, 0.18);
  --text: #f8fafc;
  --muted: #94a3b8;
  --soft: #cbd5e1;
  --accent: #ef4444;
  --accent-dark: #b91c1c;
  --blue: #60a5fa;
  --shadow: 0 28px 80px rgba(0, 0, 0, 0.42);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--text);
  background:
    radial-gradient(circle at 20% 8%, rgba(239, 68, 68, 0.15), transparent 28rem),
    radial-gradient(circle at 80% 0%, rgba(59, 130, 246, 0.14), transparent 25rem),
    linear-gradient(180deg, #020617 0%, #0f172a 44%, #020617 100%);
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
  line-height: 1.5;
}

body.nav-open {
  overflow: hidden;
}

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

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

button,
input,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 80;
  border-bottom: 1px solid var(--line);
  background: rgba(2, 6, 23, 0.76);
  backdrop-filter: blur(18px);
}

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

.logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 900;
  letter-spacing: 0.02em;
  color: #ffffff;
  white-space: nowrap;
}

.logo-mark {
  display: inline-grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--accent), #f97316);
  box-shadow: 0 12px 30px rgba(239, 68, 68, 0.35);
  font-size: 15px;
}

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

.nav-link {
  padding: 10px 14px;
  border-radius: 999px;
  color: var(--soft);
  font-size: 14px;
  transition: color 0.22s ease, background 0.22s ease, transform 0.22s ease;
}

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

.menu-button {
  display: none;
  width: 42px;
  height: 42px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.06);
}

.menu-button span {
  display: block;
  width: 18px;
  height: 2px;
  margin: 4px auto;
  border-radius: 99px;
  background: #ffffff;
}

.hero-carousel {
  position: relative;
  height: 70vh;
  min-height: 520px;
  overflow: hidden;
  background: var(--bg-soft);
}

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

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

.hero-bg,
.hero-bg img,
.hero-shade {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.hero-bg img {
  object-fit: cover;
  transform: scale(1.02);
  transition: transform 5200ms ease;
}

.hero-slide.active .hero-bg img {
  transform: scale(1.08);
}

.hero-shade {
  background:
    linear-gradient(90deg, rgba(2, 6, 23, 0.96) 0%, rgba(2, 6, 23, 0.64) 48%, rgba(2, 6, 23, 0.24) 100%),
    linear-gradient(0deg, rgba(2, 6, 23, 1) 0%, rgba(2, 6, 23, 0.12) 52%, rgba(2, 6, 23, 0.48) 100%);
}

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

.hero-copy {
  max-width: 700px;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 16px;
  color: #fecaca;
  font-size: 14px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.eyebrow::before {
  content: "";
  width: 36px;
  height: 3px;
  border-radius: 99px;
  background: linear-gradient(90deg, var(--accent), transparent);
}

.hero-copy h1,
.hero-copy h2 {
  margin: 0 0 18px;
  font-size: clamp(40px, 7vw, 72px);
  line-height: 1.02;
  font-weight: 950;
  letter-spacing: -0.04em;
  text-shadow: 0 8px 36px rgba(0, 0, 0, 0.55);
}

.hero-copy p {
  max-width: 680px;
  margin: 0 0 22px;
  color: rgba(255, 255, 255, 0.9);
  font-size: clamp(16px, 2vw, 20px);
  text-shadow: 0 6px 24px rgba(0, 0, 0, 0.5);
}

.hero-meta,
.detail-meta,
.card-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}

.hero-meta span,
.detail-meta span,
.card-meta span {
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.86);
  font-size: 13px;
}

.hero-meta span,
.detail-meta span {
  padding: 7px 12px;
}

.card-meta span {
  padding: 3px 8px;
  font-size: 12px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 28px;
}

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

.primary-button {
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #ffffff;
  background: linear-gradient(135deg, var(--accent), var(--accent-dark));
  box-shadow: 0 16px 36px rgba(239, 68, 68, 0.34);
}

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

.ghost-button {
  border: 1px solid var(--line-strong);
  color: #ffffff;
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
}

.primary-button.small {
  min-height: 38px;
  padding-inline: 16px;
  font-size: 14px;
}

.hero-arrow {
  position: absolute;
  top: 50%;
  z-index: 5;
  width: 48px;
  height: 48px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.11);
  backdrop-filter: blur(16px);
  font-size: 34px;
  line-height: 1;
  transform: translateY(-50%);
  transition: background 0.22s ease, transform 0.22s ease;
}

.hero-arrow:hover {
  background: rgba(255, 255, 255, 0.18);
  transform: translateY(-50%) scale(1.05);
}

.hero-prev {
  left: 20px;
}

.hero-next {
  right: 20px;
}

.hero-bottom {
  position: absolute;
  left: 50%;
  bottom: 28px;
  z-index: 6;
  display: grid;
  grid-template-columns: minmax(220px, 420px) 1fr auto;
  gap: 18px;
  align-items: center;
  transform: translateX(-50%);
}

.hero-search {
  display: flex;
  min-height: 48px;
  overflow: hidden;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: rgba(2, 6, 23, 0.72);
  backdrop-filter: blur(18px);
}

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

.hero-search button {
  border: 0;
  padding: 0 18px;
  color: #ffffff;
  background: var(--accent);
  font-weight: 800;
}

.hero-entrances {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.hero-entrances a {
  padding: 7px 11px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: #dbeafe;
  background: rgba(255, 255, 255, 0.08);
  font-size: 13px;
}

.hero-dots {
  display: flex;
  align-items: center;
  gap: 8px;
}

.hero-dot {
  width: 8px;
  height: 8px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.45);
  transition: width 0.22s ease, background 0.22s ease;
}

.hero-dot.active {
  width: 28px;
  background: #ffffff;
}

.content-section,
.page-main,
.detail-main {
  padding: 56px 0;
}

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

.section-heading.no-margin {
  margin-bottom: 18px;
}

.section-heading h2,
.strip-title h3,
.page-hero h1,
.detail-copy h1,
.detail-content h2,
.category-card h2 {
  margin: 0;
  color: #ffffff;
  font-weight: 900;
  letter-spacing: -0.02em;
}

.section-heading h2 {
  font-size: clamp(26px, 4vw, 36px);
}

.section-kicker {
  display: block;
  width: 48px;
  height: 4px;
  margin-bottom: 12px;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--accent), transparent);
}

.section-more {
  color: var(--muted);
  font-size: 14px;
}

.section-more:hover,
.strip-title a:hover,
.movie-info h2 a:hover {
  color: var(--blue);
}

.movie-grid {
  display: grid;
  gap: 22px;
}

.six-cols {
  grid-template-columns: repeat(6, minmax(0, 1fr));
}

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

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

.movie-card {
  position: relative;
  min-width: 0;
}

.poster-wrap {
  position: relative;
  display: block;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 18px;
  background: rgba(15, 23, 42, 0.86);
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.24);
}

.poster-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.42s ease, filter 0.42s ease;
}

.poster-gradient {
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(2, 6, 23, 0.72), transparent 62%);
}

.movie-card:hover .poster-wrap img {
  filter: saturate(1.1) brightness(1.05);
  transform: scale(1.09);
}

.play-hover {
  position: absolute;
  top: 50%;
  left: 50%;
  display: grid;
  width: 52px;
  height: 52px;
  place-items: center;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.18);
  opacity: 0;
  backdrop-filter: blur(14px);
  transform: translate(-50%, -50%) scale(0.88);
  transition: opacity 0.24s ease, transform 0.24s ease;
}

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

.rank-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  display: grid;
  min-width: 32px;
  height: 32px;
  place-items: center;
  border-radius: 11px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--accent), #f97316);
  font-size: 13px;
  font-weight: 900;
}

.movie-info {
  padding: 12px 2px 0;
}

.movie-info h2 {
  display: -webkit-box;
  min-height: 42px;
  margin: 0 0 6px;
  overflow: hidden;
  color: #ffffff;
  font-size: 15px;
  font-weight: 850;
  line-height: 1.38;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

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

.category-strip {
  margin-bottom: 48px;
}

.strip-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}

.strip-title h3 {
  position: relative;
  padding-left: 16px;
  font-size: 24px;
}

.strip-title h3::before {
  content: "";
  position: absolute;
  left: 0;
  top: 4px;
  bottom: 4px;
  width: 4px;
  border-radius: 99px;
  background: var(--accent);
}

.strip-title a {
  color: var(--muted);
  font-size: 14px;
}

.page-hero {
  margin-bottom: 32px;
  border: 1px solid var(--line);
  border-radius: 28px;
  background:
    linear-gradient(135deg, rgba(239, 68, 68, 0.15), transparent 42%),
    rgba(15, 23, 42, 0.72);
  box-shadow: var(--shadow);
}

.compact-hero {
  padding: clamp(28px, 5vw, 56px);
}

.page-hero h1 {
  margin-bottom: 12px;
  font-size: clamp(34px, 6vw, 56px);
  line-height: 1.06;
}

.page-hero p {
  max-width: 760px;
  margin: 0;
  color: var(--soft);
  font-size: 17px;
}

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

.category-card {
  display: flex;
  flex-direction: column;
  gap: 20px;
  min-height: 100%;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: var(--panel);
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.22);
}

.category-card h2 {
  margin-bottom: 8px;
  font-size: 24px;
}

.category-card p {
  margin: 0;
  color: var(--muted);
}

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

.compact-card {
  display: block;
  min-width: 0;
}

.compact-card img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 12px;
  background: #111827;
}

.compact-card span {
  display: block;
  overflow: hidden;
  margin-top: 6px;
  color: var(--soft);
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.filter-panel {
  display: grid;
  grid-template-columns: minmax(240px, 1fr) auto;
  gap: 16px;
  align-items: center;
  margin-bottom: 28px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: rgba(15, 23, 42, 0.78);
}

.filter-search input,
.filter-select {
  width: 100%;
  min-height: 46px;
  border: 1px solid var(--line);
  border-radius: 999px;
  outline: 0;
  color: #ffffff;
  background: rgba(2, 6, 23, 0.58);
}

.filter-search input {
  padding: 0 18px;
}

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

.filter-select {
  min-width: 128px;
  padding: 0 14px;
}

.filter-card.hidden {
  display: none;
}

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

.breadcrumb a:hover {
  color: #ffffff;
}

.detail-hero {
  display: grid;
  grid-template-columns: 360px 1fr;
  gap: clamp(24px, 5vw, 48px);
  align-items: center;
  margin-bottom: 42px;
  padding: clamp(20px, 4vw, 34px);
  border: 1px solid var(--line);
  border-radius: 30px;
  background:
    linear-gradient(135deg, rgba(239, 68, 68, 0.14), transparent 44%),
    var(--panel);
  box-shadow: var(--shadow);
}

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

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

.detail-copy h1 {
  margin-bottom: 18px;
  font-size: clamp(34px, 6vw, 58px);
  line-height: 1.06;
}

.detail-one-line {
  max-width: 760px;
  margin: 0 0 18px;
  color: var(--soft);
  font-size: 18px;
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 20px 0 26px;
}

.tag-row span {
  padding: 7px 11px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 999px;
  color: #dbeafe;
  background: rgba(96, 165, 250, 0.12);
  font-size: 13px;
}

.player-section {
  margin-bottom: 42px;
}

.player-card {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--line-strong);
  border-radius: 28px;
  background: #000000;
  box-shadow: var(--shadow);
}

.main-video {
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #000000;
}

.play-overlay {
  position: absolute;
  inset: 0;
  z-index: 4;
  display: grid;
  width: 100%;
  height: 100%;
  place-items: center;
  border: 0;
  color: #ffffff;
  background: radial-gradient(circle, rgba(2, 6, 23, 0.08), rgba(2, 6, 23, 0.54));
  transition: opacity 0.24s ease, visibility 0.24s ease;
}

.play-overlay span {
  display: grid;
  width: 82px;
  height: 82px;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.26);
  border-radius: 999px;
  background: rgba(239, 68, 68, 0.86);
  box-shadow: 0 18px 44px rgba(239, 68, 68, 0.34);
  font-size: 30px;
}

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

.detail-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 22px;
  margin-bottom: 50px;
}

.detail-content article {
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: var(--panel);
}

.detail-content h2 {
  margin-bottom: 12px;
  font-size: 24px;
}

.detail-content p {
  margin: 0;
  color: var(--soft);
  font-size: 16px;
  line-height: 1.8;
}

.site-footer {
  margin-top: 40px;
  border-top: 1px solid var(--line);
  background: rgba(2, 6, 23, 0.84);
}

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

.footer-logo {
  margin-bottom: 14px;
}

.site-footer p {
  max-width: 520px;
  margin: 0;
  color: var(--muted);
}

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

.site-footer a:not(.logo) {
  display: block;
  margin: 8px 0;
  color: var(--muted);
  font-size: 14px;
}

.site-footer a:hover {
  color: #ffffff;
}

.footer-bottom {
  padding: 18px;
  border-top: 1px solid var(--line);
  color: #64748b;
  text-align: center;
  font-size: 13px;
}

@media (max-width: 1100px) {
  .six-cols,
  .five-cols {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .four-cols,
  .category-overview {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .hero-bottom {
    grid-template-columns: 1fr;
    align-items: stretch;
  }

  .hero-dots {
    justify-content: center;
  }

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

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

  .menu-button {
    display: block;
  }

  .nav-links {
    position: fixed;
    top: 68px;
    left: 12px;
    right: 12px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    padding: 14px;
    border: 1px solid var(--line);
    border-radius: 22px;
    background: rgba(2, 6, 23, 0.96);
    box-shadow: var(--shadow);
  }

  body.nav-open .nav-links {
    display: flex;
  }

  .nav-link {
    border-radius: 14px;
  }

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

  .hero-content {
    align-items: flex-end;
    padding-bottom: 230px;
  }

  .hero-copy h1,
  .hero-copy h2 {
    font-size: clamp(34px, 14vw, 52px);
  }

  .hero-arrow {
    display: none;
  }

  .hero-bottom {
    bottom: 18px;
    gap: 12px;
  }

  .hero-entrances {
    max-height: 72px;
    overflow: hidden;
  }

  .six-cols,
  .five-cols,
  .four-cols,
  .category-overview,
  .detail-content {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .movie-grid {
    gap: 16px;
  }

  .movie-info h2 {
    font-size: 14px;
  }

  .movie-info p {
    font-size: 12px;
  }

  .filter-panel {
    grid-template-columns: 1fr;
  }

  .filter-controls {
    flex-direction: column;
  }

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

  .detail-poster img {
    aspect-ratio: 16 / 9;
  }

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

@media (max-width: 480px) {
  .six-cols,
  .five-cols,
  .four-cols,
  .category-overview,
  .detail-content {
    grid-template-columns: 1fr;
  }

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

  .hero-search {
    border-radius: 18px;
  }

  .hero-search button {
    padding-inline: 14px;
  }
}
