:root {
  --bg: #020617;
  --bg-soft: #0f172a;
  --panel: rgba(15, 23, 42, 0.82);
  --panel-strong: rgba(15, 23, 42, 0.96);
  --line: rgba(148, 163, 184, 0.18);
  --text: #f8fafc;
  --muted: #94a3b8;
  --primary: #2563eb;
  --accent: #22d3ee;
  --accent-soft: rgba(34, 211, 238, 0.18);
  --radius: 22px;
  --shadow: 0 24px 70px 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 top left, rgba(37, 99, 235, 0.26), transparent 34rem),
    radial-gradient(circle at top right, rgba(34, 211, 238, 0.20), transparent 30rem),
    linear-gradient(180deg, #020617 0%, #0f172a 42%, #020617 100%);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
}

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

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

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

.nav-wrap {
  width: min(1200px, calc(100% - 32px));
  min-height: 72px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 22px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  letter-spacing: 0.02em;
}

.brand-mark {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  box-shadow: 0 12px 30px rgba(37, 99, 235, 0.35);
}

.brand-text {
  font-size: 24px;
  background: linear-gradient(90deg, #60a5fa, #67e8f9, #bfdbfe);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  white-space: nowrap;
}

.search-form {
  flex: 1;
  max-width: 430px;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 5px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.72);
}

.search-form input,
.big-search input,
.filter-bar input {
  width: 100%;
  min-width: 0;
  border: 0;
  outline: 0;
  color: var(--text);
  background: transparent;
  font-size: 15px;
}

.search-form input {
  padding: 9px 10px 9px 16px;
}

.search-form button,
.big-search button {
  border: 0;
  color: #ffffff;
  cursor: pointer;
  border-radius: 999px;
  padding: 9px 18px;
  font-weight: 700;
  background: linear-gradient(135deg, var(--primary), var(--accent));
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-left: auto;
}

.nav-link {
  padding: 10px 13px;
  border-radius: 999px;
  color: #cbd5e1;
  font-size: 14px;
  transition: color 0.2s ease, background 0.2s ease;
}

.nav-link:hover,
.nav-link.is-active {
  color: #67e8f9;
  background: rgba(37, 99, 235, 0.18);
}

.menu-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(15, 23, 42, 0.9);
}

.menu-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  margin: 4px auto;
  border-radius: 999px;
  background: #e2e8f0;
}

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

.hero-slide {
  position: absolute;
  inset: 0;
  display: grid;
  align-items: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.75s ease, visibility 0.75s ease;
}

.hero-slide.is-active {
  opacity: 1;
  visibility: visible;
}

.hero-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.08);
  opacity: 0.72;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(2, 6, 23, 0.98) 0%, rgba(15, 23, 42, 0.74) 48%, rgba(2, 6, 23, 0.24) 100%),
    linear-gradient(0deg, #020617 0%, transparent 38%);
}

.hero-content {
  position: relative;
  z-index: 2;
  width: min(1200px, calc(100% - 32px));
  margin: 0 auto;
  padding: 118px 0 144px;
  max-width: 760px;
  justify-self: center;
  transform: translateX(-220px);
}

.hero-kicker,
.eyebrow {
  margin: 0 0 12px;
  color: #67e8f9;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.hero h1 {
  margin: 0;
  max-width: 760px;
  font-size: clamp(42px, 7vw, 82px);
  line-height: 0.96;
  letter-spacing: -0.06em;
}

.hero-text {
  max-width: 720px;
  margin: 22px 0 0;
  color: #cbd5e1;
  font-size: 17px;
  line-height: 1.9;
}

.hero-tags,
.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.hero-tags {
  margin-top: 22px;
}

.hero-tags span,
.tag-row span {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 5px 11px;
  border-radius: 999px;
  color: #dbeafe;
  background: rgba(37, 99, 235, 0.26);
  border: 1px solid rgba(125, 211, 252, 0.20);
  font-size: 12px;
}

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

.primary-btn,
.ghost-btn,
.wide-link,
.section-more,
.filter-bar a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  font-weight: 800;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.primary-btn {
  color: #ffffff;
  padding: 14px 24px;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  box-shadow: 0 16px 40px rgba(37, 99, 235, 0.34);
}

.ghost-btn {
  padding: 13px 22px;
  color: #dbeafe;
  border: 1px solid rgba(226, 232, 240, 0.24);
  background: rgba(15, 23, 42, 0.58);
}

.primary-btn:hover,
.ghost-btn:hover,
.wide-link:hover,
.section-more:hover,
.filter-bar a:hover {
  transform: translateY(-2px);
}

.hero-controls {
  position: absolute;
  z-index: 8;
  left: 50%;
  bottom: 34px;
  display: flex;
  align-items: center;
  gap: 14px;
  transform: translateX(-50%);
}

.hero-arrow,
.hero-dot {
  border: 0;
  cursor: pointer;
}

.hero-arrow {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  color: #ffffff;
  font-size: 30px;
  background: rgba(15, 23, 42, 0.72);
  border: 1px solid rgba(148, 163, 184, 0.24);
}

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

.hero-dot {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: rgba(226, 232, 240, 0.45);
}

.hero-dot.is-active {
  width: 30px;
  background: linear-gradient(135deg, var(--primary), var(--accent));
}

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

.section-head,
.rank-title {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 24px;
}

.section-head h2,
.rank-title h2,
.page-hero h1,
.detail-copy h1 {
  margin: 0;
  letter-spacing: -0.04em;
}

.section-head h2,
.rank-title h2 {
  font-size: clamp(26px, 4vw, 40px);
}

.section-more,
.filter-bar a {
  padding: 9px 15px;
  color: #67e8f9;
  border: 1px solid rgba(34, 211, 238, 0.24);
  background: rgba(34, 211, 238, 0.09);
  white-space: nowrap;
}

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

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

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

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

.poster-link {
  display: block;
  height: 100%;
  overflow: hidden;
  border-radius: var(--radius);
  background: rgba(15, 23, 42, 0.70);
  border: 1px solid rgba(148, 163, 184, 0.16);
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.22);
  transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

.poster-link:hover {
  transform: translateY(-6px);
  border-color: rgba(34, 211, 238, 0.46);
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.34);
}

.poster-frame {
  position: relative;
  display: block;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  background: linear-gradient(135deg, #0f172a, #1e3a8a);
}

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

.poster-link:hover img {
  transform: scale(1.08);
}

.poster-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 38%, rgba(0, 0, 0, 0.72) 100%);
}

.play-badge {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 54px;
  height: 54px;
  display: grid;
  place-items: center;
  color: #ffffff;
  border-radius: 50%;
  background: rgba(37, 99, 235, 0.88);
  transform: translate(-50%, -50%) scale(0.86);
  opacity: 0;
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.poster-link:hover .play-badge {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
}

.card-body {
  display: grid;
  gap: 8px;
  padding: 15px;
}

.card-meta {
  color: var(--muted);
  font-size: 12px;
}

.card-body strong {
  color: #ffffff;
  font-size: 17px;
  line-height: 1.35;
}

.card-line {
  min-height: 44px;
  color: #cbd5e1;
  font-size: 13px;
  line-height: 1.65;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
}

.compact-card .card-body strong {
  font-size: 15px;
}

.compact-card .card-line {
  min-height: 38px;
  font-size: 12px;
}

.split-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 34px;
  align-items: start;
}

.rank-panel,
.article-card {
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: var(--radius);
  background: var(--panel);
  box-shadow: var(--shadow);
}

.rank-panel {
  position: sticky;
  top: 100px;
  padding: 24px;
}

.rank-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 12px;
}

.rank-list a {
  display: grid;
  grid-template-columns: 34px 58px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  padding: 9px;
  border-radius: 16px;
  background: rgba(15, 23, 42, 0.58);
  transition: background 0.2s ease;
}

.rank-list a:hover {
  background: rgba(37, 99, 235, 0.20);
}

.rank-no {
  color: #67e8f9;
  font-size: 20px;
  font-weight: 900;
  text-align: center;
}

.rank-list img {
  width: 58px;
  height: 76px;
  object-fit: cover;
  border-radius: 10px;
}

.rank-info {
  min-width: 0;
  display: grid;
  gap: 4px;
}

.rank-info strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.rank-info em {
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
}

.wide-link {
  width: 100%;
  margin-top: 18px;
  padding: 13px;
  color: #ffffff;
  background: linear-gradient(135deg, rgba(37, 99, 235, 0.88), rgba(34, 211, 238, 0.88));
}

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

.category-tile {
  position: relative;
  min-height: 150px;
  overflow: hidden;
  border-radius: 22px;
  border: 1px solid rgba(148, 163, 184, 0.18);
  background: #0f172a;
}

.category-tile img {
  width: 100%;
  height: 100%;
  min-height: 150px;
  object-fit: cover;
  opacity: 0.55;
  transition: transform 0.4s ease, opacity 0.4s ease;
}

.category-tile:hover img {
  opacity: 0.72;
  transform: scale(1.08);
}

.category-tile span {
  position: absolute;
  left: 16px;
  right: 16px;
  bottom: 16px;
  font-size: 20px;
  font-weight: 900;
  text-shadow: 0 4px 20px rgba(0, 0, 0, 0.82);
}

.page-hero,
.detail-hero {
  position: relative;
  overflow: hidden;
  background: #020617;
}

.slim-hero {
  padding: 88px 0 58px;
  border-bottom: 1px solid rgba(148, 163, 184, 0.12);
}

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

.page-hero h1 {
  font-size: clamp(36px, 6vw, 64px);
}

.page-hero p:not(.eyebrow) {
  max-width: 760px;
  color: #cbd5e1;
  line-height: 1.9;
}

.filter-bar,
.big-search {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 24px;
}

.filter-bar {
  justify-content: space-between;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(15, 23, 42, 0.74);
}

.filter-bar input {
  padding: 11px 14px;
}

.big-search {
  padding: 8px;
  border-radius: 999px;
  border: 1px solid rgba(34, 211, 238, 0.22);
  background: rgba(15, 23, 42, 0.82);
}

.big-search input {
  padding: 14px 18px;
  font-size: 17px;
}

.big-search button {
  padding: 13px 28px;
}

.ranking-list {
  display: grid;
  gap: 16px;
}

.ranking-card a {
  display: grid;
  grid-template-columns: 56px 104px minmax(0, 1fr);
  gap: 18px;
  align-items: center;
  padding: 16px;
  border-radius: 22px;
  border: 1px solid rgba(148, 163, 184, 0.16);
  background: rgba(15, 23, 42, 0.72);
}

.ranking-card a:hover {
  border-color: rgba(34, 211, 238, 0.48);
  background: rgba(37, 99, 235, 0.14);
}

.ranking-number {
  color: #67e8f9;
  font-size: 30px;
  font-weight: 900;
  text-align: center;
}

.ranking-card img {
  width: 104px;
  height: 138px;
  object-fit: cover;
  border-radius: 14px;
}

.ranking-body {
  display: grid;
  gap: 9px;
}

.ranking-body strong {
  font-size: 22px;
}

.ranking-body em {
  color: var(--muted);
  font-style: normal;
}

.ranking-body > span:not(.tag-row) {
  color: #cbd5e1;
  line-height: 1.7;
}

.detail-hero {
  min-height: 580px;
  display: grid;
  align-items: end;
}

.detail-bg,
.detail-mask {
  position: absolute;
  inset: 0;
}

.detail-bg {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.46;
  filter: blur(2px);
  transform: scale(1.04);
}

.detail-mask {
  background:
    linear-gradient(90deg, rgba(2, 6, 23, 0.98), rgba(15, 23, 42, 0.70), rgba(2, 6, 23, 0.42)),
    linear-gradient(0deg, #020617 0%, transparent 42%);
}

.detail-inner {
  position: relative;
  z-index: 2;
  width: min(1200px, calc(100% - 32px));
  margin: 0 auto;
  padding: 90px 0 64px;
  display: grid;
  grid-template-columns: 260px minmax(0, 1fr);
  gap: 34px;
  align-items: end;
}

.detail-poster img {
  width: 260px;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  border-radius: 24px;
  border: 1px solid rgba(226, 232, 240, 0.22);
  box-shadow: var(--shadow);
}

.detail-copy h1 {
  font-size: clamp(38px, 7vw, 76px);
  line-height: 1.02;
}

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

.detail-tags {
  margin-top: 18px;
}

.player-shell {
  position: relative;
  overflow: hidden;
  border-radius: 28px;
  background: #000000;
  border: 1px solid rgba(34, 211, 238, 0.24);
  box-shadow: var(--shadow);
  aspect-ratio: 16 / 9;
}

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

.player-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  gap: 12px;
  color: #ffffff;
  border: 0;
  cursor: pointer;
  background: radial-gradient(circle at center, rgba(37, 99, 235, 0.18), rgba(0, 0, 0, 0.52));
  font-size: 17px;
  font-weight: 900;
}

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

.player-icon {
  width: 82px;
  height: 82px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: #ffffff;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  box-shadow: 0 20px 50px rgba(37, 99, 235, 0.48);
}

.article-card {
  padding: 30px;
}

.article-card h2 {
  margin: 28px 0 12px;
  font-size: 26px;
}

.article-card h2:first-child {
  margin-top: 0;
}

.article-card p {
  color: #cbd5e1;
  font-size: 16px;
  line-height: 2;
}

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

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

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

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

.site-footer {
  margin-top: 40px;
  border-top: 1px solid rgba(148, 163, 184, 0.12);
  background: rgba(2, 6, 23, 0.72);
}

.footer-inner {
  width: min(1200px, calc(100% - 32px));
  margin: 0 auto;
  padding: 40px 0;
  display: grid;
  gap: 22px;
}

.footer-brand p,
.footer-copy {
  max-width: 720px;
  color: var(--muted);
  line-height: 1.8;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

.footer-links a {
  color: #cbd5e1;
}

.footer-links a:hover {
  color: #67e8f9;
}

[data-card].is-hidden,
.search-hot.is-hidden {
  display: none;
}

.empty-state {
  grid-column: 1 / -1;
  padding: 40px;
  text-align: center;
  border-radius: 22px;
  color: #cbd5e1;
  background: rgba(15, 23, 42, 0.72);
  border: 1px solid rgba(148, 163, 184, 0.16);
}

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

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

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

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

  .rank-panel {
    position: static;
  }

  .hero-content {
    transform: none;
    justify-self: start;
  }
}

@media (max-width: 860px) {
  .nav-wrap {
    min-height: auto;
    padding: 14px 0;
    flex-wrap: wrap;
  }

  .brand-text {
    font-size: 21px;
  }

  .search-form {
    order: 3;
    flex-basis: 100%;
    max-width: none;
  }

  .menu-toggle {
    display: block;
    margin-left: auto;
  }

  .nav-links {
    order: 4;
    display: none;
    flex-basis: 100%;
    flex-direction: column;
    align-items: stretch;
    padding-top: 10px;
  }

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

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

  .hero {
    min-height: 620px;
  }

  .hero-content {
    padding: 90px 0 126px;
  }

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

  .detail-poster img {
    width: 210px;
  }

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

  .ranking-card a {
    grid-template-columns: 42px 86px minmax(0, 1fr);
  }

  .ranking-card img {
    width: 86px;
    height: 114px;
  }
}

@media (max-width: 620px) {
  .content-section {
    padding: 42px 0;
  }

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

  .hero h1,
  .detail-copy h1 {
    font-size: 42px;
  }

  .hero-text,
  .detail-line {
    font-size: 15px;
  }

  .section-head,
  .filter-bar,
  .big-search {
    align-items: stretch;
    flex-direction: column;
  }

  .section-more,
  .filter-bar a,
  .big-search button {
    width: 100%;
  }

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

  .ranking-card a {
    grid-template-columns: 1fr;
  }

  .ranking-number {
    text-align: left;
  }
}
