:root {
  color-scheme: dark;
  --bg: #020617;
  --panel: #0f172a;
  --panel-soft: #111c31;
  --panel-strong: #1e293b;
  --text: #f8fafc;
  --muted: #94a3b8;
  --cyan: #22d3ee;
  --blue: #2563eb;
  --yellow: #facc15;
  --red: #ef4444;
  --green: #22c55e;
  --ring: rgba(34, 211, 238, 0.35);
  --shadow: 0 18px 50px rgba(8, 47, 73, 0.25);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.6;
}

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

img {
  display: block;
  max-width: 100%;
  background: linear-gradient(135deg, #111827, #0f172a);
}

button,
input {
  font: inherit;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(15, 23, 42, 0.92);
  border-bottom: 1px solid rgba(148, 163, 184, 0.15);
  backdrop-filter: blur(18px);
  box-shadow: 0 12px 35px rgba(2, 6, 23, 0.35);
}

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

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 22px;
  font-weight: 800;
  letter-spacing: 0.02em;
  white-space: nowrap;
  background: linear-gradient(90deg, var(--cyan), #60a5fa);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.brand-icon {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  color: #001018;
  background: linear-gradient(135deg, var(--cyan), #60a5fa);
  box-shadow: 0 0 28px rgba(34, 211, 238, 0.35);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 24px;
  color: #cbd5e1;
}

.nav-links a,
.nav-drop button {
  color: #cbd5e1;
  border: 0;
  background: transparent;
  cursor: pointer;
  padding: 22px 0;
  transition: color 0.2s ease;
}

.nav-links a:hover,
.nav-drop button:hover {
  color: var(--cyan);
}

.nav-drop {
  position: relative;
}

.drop-menu {
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 180px;
  padding: 8px;
  border-radius: 16px;
  background: #0f172a;
  border: 1px solid rgba(148, 163, 184, 0.18);
  box-shadow: var(--shadow);
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
  transition: 0.2s ease;
}

.nav-drop:hover .drop-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.drop-menu a {
  display: block;
  padding: 10px 12px;
  border-radius: 10px;
}

.drop-menu a:hover {
  background: rgba(34, 211, 238, 0.1);
}

.search-form,
.mobile-search,
.big-search {
  display: flex;
  align-items: center;
  gap: 8px;
}

.search-form input,
.mobile-search input,
.big-search input {
  width: 230px;
  color: var(--text);
  background: #1e293b;
  border: 1px solid rgba(148, 163, 184, 0.2);
  border-radius: 999px;
  padding: 10px 14px;
  outline: none;
}

.search-form input:focus,
.mobile-search input:focus,
.big-search input:focus {
  border-color: var(--cyan);
  box-shadow: 0 0 0 4px var(--ring);
}

.search-form button,
.mobile-search button,
.big-search button {
  color: white;
  background: var(--cyan);
  border: 0;
  border-radius: 999px;
  padding: 10px 16px;
  cursor: pointer;
}

.mobile-toggle {
  display: none;
  color: white;
  background: #1e293b;
  border: 1px solid rgba(148, 163, 184, 0.2);
  border-radius: 12px;
  padding: 8px 12px;
}

.mobile-menu {
  display: none;
  padding: 14px 16px 18px;
  border-top: 1px solid rgba(148, 163, 184, 0.14);
  background: #0f172a;
}

.mobile-menu.open {
  display: grid;
  gap: 12px;
}

.mobile-cats {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.mobile-menu a,
.mobile-cats a {
  color: #cbd5e1;
  padding: 9px 0;
}

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

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

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

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

.hero-shade,
.detail-mask {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 18% 40%, rgba(34, 211, 238, 0.25), transparent 30%),
    linear-gradient(0deg, #020617 0%, rgba(2, 6, 23, 0.72) 45%, rgba(2, 6, 23, 0.12) 100%);
}

.hero-content {
  position: relative;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  align-items: flex-start;
  padding-bottom: 86px;
}

.hero-kicker,
.eyebrow {
  color: var(--yellow);
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.hero-content h1 {
  max-width: 780px;
  margin: 12px 0 16px;
  font-size: clamp(38px, 6vw, 72px);
  line-height: 1.05;
}

.hero-content p {
  max-width: 720px;
  margin: 0 0 28px;
  color: #dbeafe;
  font-size: 18px;
}

.hero-actions,
.detail-info .primary-btn {
  display: flex;
  align-items: center;
  gap: 14px;
}

.primary-btn,
.ghost-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  border-radius: 999px;
  padding: 0 26px;
  font-weight: 800;
  transition: 0.2s ease;
}

.primary-btn {
  color: #001018;
  background: linear-gradient(135deg, var(--cyan), #60a5fa);
  box-shadow: 0 14px 28px rgba(34, 211, 238, 0.28);
}

.primary-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 38px rgba(34, 211, 238, 0.35);
}

.ghost-btn {
  color: white;
  border: 1px solid rgba(255, 255, 255, 0.28);
  background: rgba(15, 23, 42, 0.45);
  backdrop-filter: blur(10px);
}

.ghost-btn:hover {
  border-color: var(--cyan);
  color: var(--cyan);
}

.hero-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 48px;
  height: 48px;
  color: white;
  background: rgba(2, 6, 23, 0.55);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 999px;
  font-size: 34px;
  cursor: pointer;
  transition: 0.2s ease;
}

.hero-arrow:hover {
  background: rgba(15, 23, 42, 0.9);
  color: var(--cyan);
}

.hero-prev {
  left: 18px;
}

.hero-next {
  right: 18px;
}

.hero-dots {
  position: absolute;
  bottom: 28px;
  left: 50%;
  display: flex;
  gap: 9px;
  transform: translateX(-50%);
}

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

.hero-dots button.active {
  width: 34px;
  background: var(--cyan);
}

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

.stripe-section {
  padding: 72px 0;
  background: #0b1220;
  border-top: 1px solid rgba(148, 163, 184, 0.08);
  border-bottom: 1px solid rgba(148, 163, 184, 0.08);
}

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

.section-title h2 {
  margin: 0;
  font-size: clamp(28px, 3vw, 38px);
}

.section-title p {
  margin: 8px 0 0;
  color: var(--muted);
}

.section-title > a {
  color: var(--cyan);
  font-weight: 800;
}

.grid {
  display: grid;
}

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

.movie-card {
  overflow: hidden;
  border-radius: 18px;
  background: var(--panel);
  border: 1px solid rgba(148, 163, 184, 0.1);
  box-shadow: 0 18px 35px rgba(2, 6, 23, 0.18);
  transition: 0.25s ease;
}

.movie-card:hover {
  transform: translateY(-5px);
  border-color: rgba(34, 211, 238, 0.65);
  box-shadow: 0 24px 45px rgba(34, 211, 238, 0.12);
}

.poster-link {
  position: relative;
  display: block;
  aspect-ratio: 16 / 9;
  overflow: hidden;
}

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

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

.type-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  color: #e0f2fe;
  background: rgba(2, 6, 23, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 999px;
  padding: 4px 10px;
  font-size: 12px;
}

.card-body {
  padding: 18px;
}

.card-body h2 {
  margin: 0 0 10px;
  font-size: 18px;
  line-height: 1.35;
}

.card-body h2 a:hover,
.rank-item h2 a:hover {
  color: var(--cyan);
}

.card-body p {
  display: -webkit-box;
  min-height: 46px;
  margin: 0 0 14px;
  overflow: hidden;
  color: #cbd5e1;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.card-meta,
.inline-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  color: var(--muted);
  font-size: 14px;
}

.card-meta a {
  color: var(--cyan);
  background: rgba(34, 211, 238, 0.1);
  border-radius: 999px;
  padding: 3px 9px;
}

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

.tag-row span {
  color: var(--cyan);
  background: rgba(34, 211, 238, 0.1);
  border: 1px solid rgba(34, 211, 238, 0.14);
  border-radius: 999px;
  padding: 4px 10px;
  font-size: 13px;
}

.scroll-row {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(280px, 320px);
  gap: 22px;
  overflow-x: auto;
  padding-bottom: 16px;
  scrollbar-color: var(--cyan) #1e293b;
}

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

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

.category-tile {
  min-height: 150px;
  padding: 24px;
  border-radius: 20px;
  background: linear-gradient(135deg, #111827, #0f172a);
  border: 1px solid rgba(148, 163, 184, 0.12);
  transition: 0.25s ease;
}

.category-tile:hover {
  transform: translateY(-4px);
  background: linear-gradient(135deg, rgba(34, 211, 238, 0.24), rgba(37, 99, 235, 0.42));
  box-shadow: 0 22px 38px rgba(34, 211, 238, 0.16);
}

.category-tile strong {
  display: block;
  margin-bottom: 7px;
  font-size: 22px;
}

.category-tile span {
  color: var(--cyan);
  font-weight: 800;
}

.category-tile p {
  margin: 12px 0 0;
  color: #cbd5e1;
}

.featured-layout {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 28px;
}

.wide-card .poster-link {
  aspect-ratio: 21 / 9;
}

.side-list,
.rank-list {
  display: grid;
  gap: 16px;
}

.rank-item {
  display: grid;
  grid-template-columns: 56px 112px 1fr;
  gap: 16px;
  align-items: center;
  padding: 14px;
  border-radius: 18px;
  background: var(--panel);
  border: 1px solid rgba(148, 163, 184, 0.1);
  transition: 0.2s ease;
}

.rank-item:hover {
  border-color: rgba(34, 211, 238, 0.5);
  background: var(--panel-soft);
}

.rank-num {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border-radius: 16px;
  color: #001018;
  background: linear-gradient(135deg, var(--yellow), #fb923c);
  font-weight: 900;
}

.rank-img {
  aspect-ratio: 16 / 10;
  overflow: hidden;
  border-radius: 12px;
}

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

.rank-item h2 {
  margin: 0 0 8px;
  font-size: 17px;
  line-height: 1.35;
}

.rank-item p {
  display: -webkit-box;
  margin: 0 0 8px;
  overflow: hidden;
  color: #cbd5e1;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.page-main {
  min-height: 70vh;
}

.page-hero {
  padding: 62px 0 18px;
}

.compact-hero {
  padding-bottom: 20px;
}

.page-hero h1 {
  margin: 8px 0 12px;
  font-size: clamp(34px, 4vw, 56px);
}

.page-hero p {
  max-width: 820px;
  color: #cbd5e1;
  font-size: 18px;
}

.page-count,
.search-summary {
  display: inline-flex;
  margin-top: 14px;
  color: var(--cyan);
  background: rgba(34, 211, 238, 0.1);
  border-radius: 999px;
  padding: 7px 14px;
  font-weight: 800;
}

.big-search {
  max-width: 680px;
  margin-top: 24px;
}

.big-search input {
  flex: 1;
  width: auto;
  min-height: 50px;
}

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

.detail-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: blur(2px);
  transform: scale(1.03);
}

.detail-head {
  position: relative;
  display: grid;
  grid-template-columns: 320px 1fr;
  gap: 38px;
  align-items: end;
  min-height: 560px;
  padding: 92px 0 54px;
}

.detail-poster {
  overflow: hidden;
  border-radius: 24px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.45);
}

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

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: #cbd5e1;
  margin-bottom: 16px;
}

.breadcrumb a:hover {
  color: var(--cyan);
}

.detail-info h1 {
  margin: 0 0 16px;
  font-size: clamp(38px, 5vw, 70px);
  line-height: 1.05;
}

.detail-info p {
  max-width: 760px;
  color: #e2e8f0;
  font-size: 19px;
}

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

.detail-meta span {
  color: #dbeafe;
  background: rgba(15, 23, 42, 0.72);
  border: 1px solid rgba(148, 163, 184, 0.18);
  border-radius: 999px;
  padding: 7px 12px;
}

.player-section {
  padding: 46px 0 20px;
}

.video-box {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16 / 9;
  border-radius: 24px;
  background: #000;
  border: 1px solid rgba(34, 211, 238, 0.22);
  box-shadow: 0 30px 80px rgba(2, 6, 23, 0.58);
}

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

.play-layer {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  gap: 10px;
  color: white;
  background: linear-gradient(0deg, rgba(2, 6, 23, 0.75), rgba(2, 6, 23, 0.28));
  border: 0;
  cursor: pointer;
}

.play-layer.hidden {
  display: none;
}

.play-layer span {
  display: grid;
  place-items: center;
  width: 74px;
  height: 74px;
  border-radius: 999px;
  color: #001018;
  background: var(--cyan);
  font-size: 30px;
  box-shadow: 0 0 50px rgba(34, 211, 238, 0.4);
}

.play-layer strong {
  font-size: 20px;
}

.detail-grid {
  display: grid;
  grid-template-columns: minmax(0, 2fr) 380px;
  gap: 28px;
  padding: 36px 0 28px;
}

.detail-content,
.related-panel,
.info-card {
  border-radius: 22px;
  background: var(--panel);
  border: 1px solid rgba(148, 163, 184, 0.1);
}

.detail-content {
  display: grid;
  gap: 18px;
  background: transparent;
  border: 0;
}

.info-card {
  padding: 26px;
}

.info-card h2,
.related-panel h2 {
  margin: 0 0 12px;
  font-size: 23px;
}

.info-card p {
  margin: 0;
  color: #d1d5db;
  font-size: 17px;
}

.related-panel {
  position: sticky;
  top: 92px;
  align-self: start;
  padding: 22px;
}

.detail-tags {
  margin-top: 0;
}

.site-footer {
  background: #0b1220;
  border-top: 1px solid rgba(148, 163, 184, 0.12);
  color: #cbd5e1;
}

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

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

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

.site-footer h2 {
  margin: 0 0 14px;
  color: white;
  font-size: 18px;
}

.site-footer a:not(.brand) {
  display: block;
  margin: 8px 0;
  color: #cbd5e1;
}

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

.footer-bottom {
  padding: 18px 0;
  text-align: center;
  color: var(--muted);
  border-top: 1px solid rgba(148, 163, 184, 0.1);
}

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

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

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

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

  .related-panel {
    position: static;
  }
}

@media (max-width: 820px) {
  .nav-links,
  .search-form {
    display: none;
  }

  .mobile-toggle {
    display: inline-flex;
  }

  .hero-carousel {
    min-height: 500px;
    height: 64vh;
  }

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

  .hero-arrow {
    display: none;
  }

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

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

  .rank-item {
    grid-template-columns: 44px 96px 1fr;
  }

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

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

  .brand {
    font-size: 18px;
  }

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

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

  .category-grid,
  .category-grid.large,
  .mobile-cats {
    grid-template-columns: 1fr;
  }

  .detail-head {
    padding-top: 64px;
  }

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

  .rank-item {
    grid-template-columns: 1fr;
  }

  .rank-num {
    width: 44px;
    height: 44px;
  }

  .big-search {
    flex-direction: column;
    align-items: stretch;
  }
}
