:root {
  --page-bg: #f8fafc;
  --text-main: #1f2937;
  --text-soft: #64748b;
  --line: #e5e7eb;
  --emerald: #059669;
  --emerald-dark: #047857;
  --teal: #0d9488;
  --slate: #0f172a;
  --slate-2: #1e293b;
  --shadow: 0 10px 30px rgba(15, 23, 42, 0.12);
  --shadow-soft: 0 8px 18px rgba(15, 23, 42, 0.08);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: linear-gradient(180deg, #f8fafc 0%, #ffffff 70%);
  color: var(--text-main);
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
  line-height: 1.6;
}

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

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: linear-gradient(90deg, #0f172a 0%, #1e293b 50%, #0f172a 100%);
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.22);
  backdrop-filter: blur(12px);
}

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

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  color: #ffffff;
}

.brand-mark {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: linear-gradient(135deg, #10b981 0%, #0d9488 100%);
  box-shadow: 0 10px 24px rgba(16, 185, 129, 0.28);
  transition: transform 0.25s ease;
}

.brand:hover .brand-mark {
  transform: scale(1.08);
}

.brand-copy {
  display: grid;
  gap: 1px;
}

.brand-copy strong {
  font-size: 24px;
  line-height: 1.1;
  letter-spacing: 0.02em;
}

.brand-copy em {
  color: #94a3b8;
  font-size: 12px;
  font-style: normal;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 22px;
  color: #cbd5e1;
  font-weight: 600;
  white-space: nowrap;
}

.nav-link {
  transition: color 0.2s ease;
}

.nav-link:hover,
.nav-link.is-active {
  color: #ffffff;
}

.menu-toggle {
  display: none;
  border: 0;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.08);
  color: #ffffff;
  font-size: 24px;
  padding: 8px 12px;
}

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

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

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

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

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(0, 0, 0, 0.74) 0%, rgba(0, 0, 0, 0.54) 46%, rgba(0, 0, 0, 0.08) 100%);
}

.hero-content {
  position: relative;
  z-index: 2;
  width: min(1180px, calc(100% - 32px));
  height: 100%;
  margin: 0 auto;
  display: flex;
  align-items: center;
}

.hero-copy {
  max-width: 680px;
  color: #ffffff;
}

.hero-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 18px;
}

.hero-badges span,
.tag-pill {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 6px 14px;
  background: rgba(255, 255, 255, 0.14);
  color: #ffffff;
  font-size: 13px;
  font-weight: 700;
  backdrop-filter: blur(10px);
}

.hero-badges span:first-child,
.tag-pill.green {
  background: #10b981;
}

.hero-copy h1 {
  margin: 0 0 18px;
  font-size: clamp(36px, 6vw, 68px);
  line-height: 1.05;
  font-weight: 900;
  letter-spacing: -0.04em;
}

.hero-copy p {
  max-width: 620px;
  margin: 0 0 26px;
  color: #e5e7eb;
  font-size: 18px;
}

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

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: 12px;
  padding: 12px 22px;
  font-weight: 800;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.btn:hover {
  transform: translateY(-2px);
}

.btn-primary {
  background: #059669;
  color: #ffffff;
  box-shadow: 0 12px 26px rgba(5, 150, 105, 0.28);
}

.btn-primary:hover {
  background: #047857;
}

.btn-glass {
  background: rgba(255, 255, 255, 0.12);
  color: #ffffff;
  backdrop-filter: blur(10px);
}

.hero-control {
  position: absolute;
  top: 50%;
  z-index: 4;
  width: 46px;
  height: 46px;
  transform: translateY(-50%);
  border: 0;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.36);
  color: #ffffff;
  cursor: pointer;
  font-size: 26px;
  backdrop-filter: blur(10px);
}

.hero-control:hover {
  background: rgba(0, 0, 0, 0.55);
}

.hero-prev {
  left: 22px;
}

.hero-next {
  right: 22px;
}

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

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

.hero-dots button.is-active {
  width: 34px;
  background: #ffffff;
}

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

.main-space {
  padding: 64px 0;
}

.section-block {
  margin-bottom: 74px;
}

.section-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 18px;
  margin-bottom: 26px;
}

.section-title {
  display: flex;
  align-items: center;
  gap: 12px;
}

.section-title span {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  background: #ecfdf5;
  color: #059669;
  font-size: 20px;
}

.section-title h2 {
  margin: 0;
  color: #1f2937;
  font-size: clamp(26px, 3vw, 36px);
  line-height: 1.2;
}

.section-more {
  color: #059669;
  font-weight: 800;
}

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

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

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

.movie-card,
.category-panel,
.info-panel,
.search-panel,
.detail-panel {
  background: #ffffff;
  border-radius: 16px;
  box-shadow: var(--shadow-soft);
  overflow: hidden;
}

.movie-card {
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.movie-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow);
}

.card-cover {
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: #111827;
}

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

.movie-card:hover .card-cover img,
.compact-card:hover img,
.category-panel:hover .category-covers img {
  transform: scale(1.08);
}

.card-cover::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 45%, rgba(0, 0, 0, 0.58) 100%);
}

.card-region,
.card-genre,
.rank-badge {
  position: absolute;
  z-index: 2;
  top: 12px;
  border-radius: 8px;
  padding: 4px 9px;
  color: #ffffff;
  font-size: 12px;
  font-weight: 800;
}

.card-region {
  left: 12px;
  background: #10b981;
}

.card-genre {
  right: 12px;
  background: rgba(0, 0, 0, 0.58);
  backdrop-filter: blur(10px);
}

.rank-badge {
  left: 12px;
  top: auto;
  bottom: 12px;
  background: linear-gradient(135deg, #f97316, #dc2626);
}

.card-body {
  padding: 18px;
}

.card-body h3 {
  min-height: 52px;
  margin: 0 0 9px;
  color: #1f2937;
  font-size: 18px;
  line-height: 1.42;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

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

.card-body p {
  min-height: 45px;
  margin: 0 0 14px;
  color: #64748b;
  font-size: 14px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.card-meta {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  color: #64748b;
  font-size: 12px;
}

.movie-card-featured .card-body h3 {
  font-size: 21px;
}

.category-panel {
  display: grid;
  grid-template-columns: 180px 1fr;
  min-height: 190px;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.category-panel:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow);
}

.category-covers {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 4px;
  padding: 10px;
  background: #0f172a;
}

.category-covers img {
  width: 100%;
  height: 100%;
  min-height: 80px;
  object-fit: cover;
  border-radius: 9px;
  transition: transform 0.35s ease;
}

.category-copy {
  padding: 24px;
}

.category-copy h2 {
  margin: 0 0 10px;
  font-size: 24px;
}

.category-copy p {
  margin: 0 0 18px;
  color: #64748b;
}

.category-copy span {
  color: #059669;
  font-weight: 800;
}

.search-panel {
  padding: 24px;
  margin-bottom: 34px;
}

.search-row {
  display: grid;
  grid-template-columns: 1fr 180px 180px;
  gap: 14px;
}

.search-row input,
.search-row select {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 13px 15px;
  color: #1f2937;
  font-size: 15px;
  outline: none;
}

.search-row input:focus,
.search-row select:focus {
  border-color: #10b981;
  box-shadow: 0 0 0 4px rgba(16, 185, 129, 0.12);
}

.compact-list {
  display: grid;
  gap: 14px;
}

.compact-card {
  background: #ffffff;
  border-radius: 14px;
  box-shadow: var(--shadow-soft);
  overflow: hidden;
}

.compact-card a {
  display: grid;
  grid-template-columns: 170px 1fr;
  gap: 18px;
  align-items: center;
}

.compact-card img {
  width: 170px;
  height: 105px;
  object-fit: cover;
  background: #111827;
  transition: transform 0.35s ease;
}

.compact-card h3 {
  margin: 0 0 8px;
  font-size: 18px;
  line-height: 1.35;
}

.compact-card:hover h3 {
  color: #059669;
}

.compact-card p {
  margin: 0 0 8px;
  color: #64748b;
  font-size: 14px;
}

.compact-card span {
  color: #94a3b8;
  font-size: 12px;
}

.compact-rank {
  display: inline-flex;
  min-width: 30px;
  height: 24px;
  align-items: center;
  justify-content: center;
  margin-right: 8px;
  border-radius: 8px;
  background: #ecfdf5;
  color: #059669;
  font-size: 13px;
  font-weight: 900;
}

.page-hero {
  background: linear-gradient(90deg, #059669 0%, #0d9488 100%);
  color: #ffffff;
  padding: 64px 0;
}

.page-hero h1 {
  margin: 0 0 12px;
  font-size: clamp(34px, 5vw, 52px);
  line-height: 1.1;
}

.page-hero p {
  max-width: 780px;
  margin: 0;
  color: #d1fae5;
  font-size: 18px;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 22px;
  color: #64748b;
  font-size: 14px;
}

.breadcrumb a {
  color: #059669;
  font-weight: 700;
}

.player-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.7fr) minmax(320px, 0.8fr);
  gap: 28px;
  align-items: start;
}

.video-shell {
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-radius: 20px;
  background: #020617;
  box-shadow: var(--shadow);
}

.video-shell video,
.video-shell .video-poster {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.video-shell video {
  position: absolute;
  inset: 0;
  z-index: 1;
}

.play-cover {
  position: absolute;
  inset: 0;
  z-index: 3;
  display: grid;
  place-items: center;
  border: 0;
  background: linear-gradient(180deg, rgba(2, 6, 23, 0.18), rgba(2, 6, 23, 0.58));
  color: #ffffff;
  cursor: pointer;
}

.play-cover span {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  border-radius: 999px;
  padding: 15px 24px;
  background: rgba(5, 150, 105, 0.92);
  box-shadow: 0 18px 36px rgba(5, 150, 105, 0.26);
  font-size: 18px;
  font-weight: 900;
}

.play-cover b {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: #ffffff;
  color: #059669;
}

.video-shell.is-playing .play-cover {
  opacity: 0;
  pointer-events: none;
}

.player-status {
  position: absolute;
  left: 16px;
  bottom: 14px;
  z-index: 2;
  border-radius: 999px;
  padding: 7px 12px;
  background: rgba(15, 23, 42, 0.76);
  color: #e5e7eb;
  font-size: 12px;
  backdrop-filter: blur(10px);
}

.detail-side {
  padding: 24px;
}

.detail-side img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border-radius: 14px;
  margin-bottom: 18px;
  background: #111827;
}

.detail-side h1 {
  margin: 0 0 12px;
  font-size: 30px;
  line-height: 1.25;
}

.detail-side p {
  color: #64748b;
}

.meta-list {
  display: grid;
  gap: 10px;
  margin-top: 18px;
}

.meta-list div {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  padding-bottom: 10px;
  border-bottom: 1px solid #edf2f7;
}

.meta-list dt {
  color: #64748b;
}

.meta-list dd {
  margin: 0;
  color: #1f2937;
  font-weight: 800;
  text-align: right;
}

.article-content {
  display: grid;
  gap: 24px;
  margin-top: 34px;
}

.detail-panel {
  padding: 28px;
}

.detail-panel h2 {
  margin: 0 0 14px;
  font-size: 24px;
}

.detail-panel p {
  margin: 0;
  color: #4b5563;
  font-size: 16px;
}

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

.tags a,
.tags span {
  border-radius: 999px;
  padding: 7px 12px;
  background: #ecfdf5;
  color: #047857;
  font-size: 13px;
  font-weight: 700;
}

.empty-filter {
  display: none;
  padding: 24px;
  border-radius: 16px;
  background: #ffffff;
  color: #64748b;
  box-shadow: var(--shadow-soft);
}

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

.site-footer {
  margin-top: 84px;
  background: linear-gradient(135deg, #0f172a 0%, #1e293b 55%, #0f172a 100%);
  color: #cbd5e1;
}

.footer-grid {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.2fr 0.8fr 1fr;
  gap: 36px;
  padding: 48px 0 34px;
}

.footer-brand {
  margin-bottom: 12px;
  color: #ffffff;
  font-size: 24px;
  font-weight: 900;
}

.site-footer h3 {
  margin: 0 0 14px;
  color: #ffffff;
  font-size: 18px;
}

.site-footer p {
  margin: 0;
  color: #94a3b8;
}

.footer-links {
  display: grid;
  gap: 9px;
}

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

.footer-bottom {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 22px 0;
  border-top: 1px solid rgba(148, 163, 184, 0.22);
  color: #94a3b8;
  text-align: center;
}

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

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

  .nav-links {
    gap: 14px;
    font-size: 14px;
  }
}

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

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

  .nav-links {
    position: absolute;
    left: 16px;
    right: 16px;
    top: 70px;
    display: none;
    flex-direction: column;
    align-items: flex-start;
    gap: 14px;
    padding: 18px;
    border-radius: 16px;
    background: #0f172a;
    box-shadow: var(--shadow);
  }

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

  .hero-carousel {
    min-height: 520px;
    height: 68vh;
  }

  .hero-control {
    display: none;
  }

  .grid-featured,
  .grid-movies,
  .grid-categories,
  .footer-grid {
    grid-template-columns: 1fr;
  }

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

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

  .category-covers {
    min-height: 180px;
  }
}

@media (max-width: 560px) {
  .brand-copy strong {
    font-size: 20px;
  }

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

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

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

  .compact-card a {
    grid-template-columns: 120px 1fr;
    gap: 12px;
  }

  .compact-card img {
    width: 120px;
    height: 92px;
  }

  .detail-side h1 {
    font-size: 24px;
  }
}
