:root {
  --bg: #020617;
  --panel: #0f172a;
  --panel-soft: rgba(15, 23, 42, 0.72);
  --panel-strong: #111827;
  --line: #1e293b;
  --text: #f8fafc;
  --muted: #94a3b8;
  --soft: #cbd5e1;
  --emerald: #10b981;
  --emerald-soft: #34d399;
  --emerald-bg: rgba(16, 185, 129, 0.18);
  --shadow: 0 24px 60px rgba(0, 0, 0, 0.35);
  --radius: 18px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background: radial-gradient(circle at 20% 0%, rgba(16, 185, 129, 0.13), transparent 30%), var(--bg);
  color: var(--text);
  font-family: Inter, 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,
video {
  display: block;
  max-width: 100%;
}

button,
input,
select {
  font: inherit;
}

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 50;
  border-bottom: 1px solid rgba(30, 41, 59, 0.9);
  background: rgba(15, 23, 42, 0.94);
  backdrop-filter: blur(14px);
}

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

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

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

.brand-mark {
  width: 32px;
  height: 32px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: white;
  background: linear-gradient(135deg, var(--emerald), #059669);
  box-shadow: 0 0 24px rgba(16, 185, 129, 0.35);
  font-size: 14px;
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 22px;
}

.nav-link {
  color: var(--soft);
  font-size: 15px;
  transition: color 0.2s ease;
}

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

.mobile-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(30, 41, 59, 0.65);
  color: white;
}

.mobile-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  margin: 4px auto;
  background: white;
  border-radius: 99px;
}

.mobile-nav {
  display: none;
  border-top: 1px solid var(--line);
  background: #0f172a;
  padding: 14px 22px 18px;
}

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

.mobile-link {
  color: var(--soft);
  padding: 6px 0;
}

main {
  min-height: 70vh;
}

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

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

.hero-slide::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: var(--hero-image);
  background-size: cover;
  background-position: center;
  filter: blur(24px) saturate(1.15);
  transform: scale(1.08);
  opacity: 0.36;
}

.hero-slide::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, #020617 0%, rgba(2, 6, 23, 0.92) 18%, rgba(2, 6, 23, 0.55) 58%, rgba(2, 6, 23, 0.8) 100%);
}

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

.hero-media {
  position: absolute;
  right: calc((100vw - min(1180px, calc(100vw - 32px))) / 2);
  bottom: 78px;
  width: min(440px, 36vw);
  z-index: 1;
  border-radius: 28px;
  overflow: hidden;
  box-shadow: var(--shadow);
}

.hero-media img {
  width: 100%;
  height: 520px;
  object-fit: cover;
}

.hero-copy {
  position: relative;
  z-index: 2;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding-top: 190px;
  max-width: 680px;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 14px;
  padding: 6px 12px;
  border-radius: 999px;
  color: var(--emerald-soft);
  background: var(--emerald-bg);
  font-size: 13px;
  font-weight: 700;
}

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

.hero-copy p {
  margin: 0;
  max-width: 620px;
  color: var(--soft);
  font-size: 18px;
}

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

.btn-primary,
.btn-ghost,
.quick-search button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 22px;
  border-radius: 12px;
  font-weight: 800;
  transition: transform 0.2s ease, background 0.2s ease, border-color 0.2s ease;
}

.btn-primary,
.quick-search button {
  border: 1px solid rgba(52, 211, 153, 0.45);
  color: white;
  background: linear-gradient(135deg, #10b981, #059669);
}

.btn-ghost {
  border: 1px solid rgba(148, 163, 184, 0.28);
  color: white;
  background: rgba(15, 23, 42, 0.62);
}

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

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

.hero-dot {
  width: 38px;
  height: 5px;
  border: 0;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.35);
  cursor: pointer;
}

.hero-dot.is-active {
  background: var(--emerald-soft);
}

.search-band,
.section-wrap,
.page-hero,
.breadcrumbs,
.detail-layout {
  width: min(1180px, calc(100% - 32px));
  margin-left: auto;
  margin-right: auto;
}

.search-band {
  display: grid;
  grid-template-columns: 1fr minmax(280px, 520px);
  gap: 26px;
  align-items: center;
  margin-top: -44px;
  position: relative;
  z-index: 6;
  padding: 26px;
  border: 1px solid rgba(30, 41, 59, 0.95);
  border-radius: 24px;
  background: rgba(15, 23, 42, 0.88);
  box-shadow: var(--shadow);
  backdrop-filter: blur(16px);
}

.search-band h2,
.section-title h2,
.rank-panel h2,
.side-panel h2,
.detail-card h2,
.page-hero h1 {
  margin: 0;
}

.quick-search {
  display: flex;
  gap: 12px;
}

.quick-search input,
.catalog-search,
.search-controls input,
.search-controls select {
  width: 100%;
  border: 1px solid rgba(51, 65, 85, 0.95);
  border-radius: 14px;
  outline: none;
  color: white;
  background: rgba(15, 23, 42, 0.9);
}

.quick-search input,
.catalog-search,
.search-controls input,
.search-controls select {
  min-height: 46px;
  padding: 0 14px;
}

.quick-search input:focus,
.catalog-search:focus,
.search-controls input:focus,
.search-controls select:focus {
  border-color: rgba(52, 211, 153, 0.75);
}

.section-wrap {
  padding-top: 70px;
}

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

.section-title h2 {
  position: relative;
  padding-left: 16px;
  font-size: 28px;
  line-height: 1.2;
}

.section-title h2::before {
  content: "";
  position: absolute;
  left: 0;
  top: 4px;
  width: 4px;
  height: 28px;
  border-radius: 99px;
  background: var(--emerald);
}

.section-title a {
  color: var(--emerald-soft);
  font-weight: 700;
}

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

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

.movie-card {
  min-width: 0;
  overflow: hidden;
  border: 1px solid rgba(30, 41, 59, 0.9);
  border-radius: 18px;
  background: rgba(15, 23, 42, 0.74);
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.16);
  transition: transform 0.25s ease, border-color 0.25s ease, background 0.25s ease;
}

.movie-card:hover {
  transform: translateY(-5px);
  border-color: rgba(52, 211, 153, 0.55);
  background: rgba(15, 23, 42, 0.95);
}

.poster-link {
  position: relative;
  display: block;
  overflow: hidden;
  background: #111827;
}

.poster-link img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  transition: transform 0.45s ease;
}

.movie-card-small .poster-link img {
  aspect-ratio: 16 / 10;
}

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

.poster-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.78), transparent 58%);
  opacity: 0.78;
}

.card-play {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 58px;
  height: 58px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  color: white;
  background: rgba(16, 185, 129, 0.9);
  transform: translate(-50%, -50%) scale(0.82);
  opacity: 0;
  transition: transform 0.25s ease, opacity 0.25s ease;
}

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

.card-body {
  padding: 16px;
}

.card-title {
  display: block;
  overflow: hidden;
  color: white;
  font-weight: 800;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.card-title:hover {
  color: var(--emerald-soft);
}

.card-body p {
  display: -webkit-box;
  min-height: 44px;
  margin: 8px 0 12px;
  overflow: hidden;
  color: var(--muted);
  font-size: 14px;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  color: #64748b;
  font-size: 12px;
}

.card-meta a,
.card-meta span {
  padding: 3px 8px;
  border-radius: 999px;
  background: rgba(30, 41, 59, 0.86);
}

.card-meta a {
  color: var(--emerald-soft);
}

.feature-panel {
  padding: 34px;
  border: 1px solid var(--line);
  border-radius: 28px;
  background: rgba(15, 23, 42, 0.5);
}

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

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

.wide-card {
  display: grid;
  grid-template-columns: 128px 1fr;
  gap: 14px;
  padding: 14px;
  border: 1px solid rgba(30, 41, 59, 0.78);
  border-radius: 16px;
  background: rgba(15, 23, 42, 0.66);
  transition: background 0.2s ease, transform 0.2s ease;
}

.wide-card:hover {
  transform: translateY(-2px);
  background: rgba(30, 41, 59, 0.8);
}

.wide-card img {
  width: 128px;
  height: 84px;
  border-radius: 12px;
  object-fit: cover;
}

.wide-card strong {
  display: block;
  margin-bottom: 4px;
  color: white;
}

.wide-card p {
  display: -webkit-box;
  margin: 0 0 6px;
  overflow: hidden;
  color: var(--muted);
  font-size: 14px;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.wide-card span {
  color: #64748b;
  font-size: 12px;
}

.rank-panel,
.side-panel,
.detail-card {
  border: 1px solid rgba(30, 41, 59, 0.9);
  border-radius: 22px;
  background: rgba(15, 23, 42, 0.78);
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.12);
}

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

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

.rank-item a {
  display: grid;
  grid-template-columns: 38px 78px 1fr;
  gap: 12px;
  align-items: center;
}

.rank-num {
  color: var(--emerald-soft);
  font-weight: 900;
}

.rank-item img {
  width: 78px;
  height: 54px;
  border-radius: 10px;
  object-fit: cover;
}

.rank-copy strong {
  display: block;
  overflow: hidden;
  color: white;
  font-size: 14px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.rank-copy em {
  color: #64748b;
  font-size: 12px;
  font-style: normal;
}

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

.category-card,
.category-overview-card a {
  display: block;
  overflow: hidden;
  border: 1px solid rgba(30, 41, 59, 0.9);
  border-radius: 22px;
  background: rgba(15, 23, 42, 0.72);
  transition: transform 0.25s ease, border-color 0.25s ease;
}

.category-card:hover,
.category-overview-card a:hover {
  transform: translateY(-4px);
  border-color: rgba(52, 211, 153, 0.5);
}

.category-thumbs,
.category-cover-strip {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  height: 150px;
  overflow: hidden;
}

.category-cover-strip {
  grid-template-columns: repeat(5, 1fr);
  height: 210px;
}

.category-thumbs img,
.category-cover-strip img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.category-card strong,
.category-card span,
.category-overview-copy {
  display: block;
  padding: 0 18px;
}

.category-card strong {
  padding-top: 18px;
  color: white;
  font-size: 20px;
}

.category-card span {
  padding-top: 8px;
  padding-bottom: 18px;
  color: var(--muted);
  font-size: 14px;
}

.category-overview-copy {
  padding-top: 20px;
  padding-bottom: 22px;
}

.category-overview-copy h2 {
  margin: 0 0 8px;
}

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

.page-main {
  padding-top: 64px;
}

.page-hero {
  margin-top: 46px;
  padding: 54px;
  border: 1px solid rgba(30, 41, 59, 0.9);
  border-radius: 30px;
  background: radial-gradient(circle at 16% 10%, rgba(16, 185, 129, 0.2), transparent 35%), rgba(15, 23, 42, 0.72);
  box-shadow: var(--shadow);
}

.page-hero h1 {
  max-width: 820px;
  font-size: clamp(34px, 5vw, 56px);
  line-height: 1.08;
}

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

.filter-panel {
  display: grid;
  gap: 14px;
  margin-bottom: 24px;
  padding: 18px;
  border: 1px solid rgba(30, 41, 59, 0.9);
  border-radius: 18px;
  background: rgba(15, 23, 42, 0.72);
}

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

.filter-chip {
  border: 1px solid rgba(51, 65, 85, 0.9);
  border-radius: 999px;
  padding: 8px 14px;
  color: var(--soft);
  background: rgba(30, 41, 59, 0.58);
  cursor: pointer;
}

.filter-chip.is-active,
.filter-chip:hover {
  border-color: rgba(52, 211, 153, 0.65);
  color: white;
  background: rgba(16, 185, 129, 0.22);
}

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

.ranking-card a {
  display: grid;
  grid-template-columns: 64px 168px 1fr;
  gap: 18px;
  align-items: center;
  padding: 16px;
  border: 1px solid rgba(30, 41, 59, 0.9);
  border-radius: 18px;
  background: rgba(15, 23, 42, 0.72);
}

.ranking-number {
  color: var(--emerald-soft);
  font-size: 28px;
  font-weight: 900;
}

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

.ranking-card h2 {
  margin: 0 0 6px;
  font-size: 20px;
}

.ranking-card p {
  display: -webkit-box;
  margin: 0 0 8px;
  overflow: hidden;
  color: var(--muted);
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.ranking-card span:last-child {
  color: #64748b;
  font-size: 13px;
}

.search-controls {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 12px;
  margin-bottom: 24px;
}

.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-top: 34px;
  margin-bottom: 18px;
  color: var(--muted);
  font-size: 14px;
}

.breadcrumbs a {
  color: var(--emerald-soft);
}

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

.detail-primary {
  display: grid;
  gap: 22px;
}

.player-shell {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(30, 41, 59, 0.9);
  border-radius: 22px;
  background: black;
  box-shadow: var(--shadow);
}

.movie-player {
  width: 100%;
  aspect-ratio: 16 / 9;
  background: black;
}

.player-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  border: 0;
  background: rgba(0, 0, 0, 0.28);
  cursor: pointer;
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

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

.play-circle {
  width: 86px;
  height: 86px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  color: white;
  background: rgba(16, 185, 129, 0.92);
  box-shadow: 0 0 36px rgba(16, 185, 129, 0.42);
  font-size: 30px;
}

.detail-card {
  padding: 26px;
}

.detail-card h1 {
  margin: 0 0 16px;
  color: white;
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1.1;
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 22px;
  color: var(--muted);
}

.detail-meta span,
.detail-meta a {
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(30, 41, 59, 0.78);
}

.detail-meta a {
  color: var(--emerald-soft);
}

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

.info-grid p {
  margin: 0;
  color: white;
}

.info-grid span {
  color: var(--muted);
}

.copy-block p,
.detail-card > p {
  color: var(--soft);
}

.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin-top: 22px;
}

.tag-list span {
  padding: 6px 10px;
  border-radius: 999px;
  color: var(--soft);
  background: rgba(30, 41, 59, 0.86);
  font-size: 13px;
}

.detail-side {
  align-self: start;
  position: sticky;
  top: 92px;
}

.side-panel {
  padding: 22px;
}

.side-list .wide-card {
  grid-template-columns: 112px 1fr;
  padding: 10px;
}

.side-list .wide-card img {
  width: 112px;
  height: 74px;
}

.site-footer {
  margin-top: 84px;
  border-top: 1px solid rgba(30, 41, 59, 0.9);
  background: rgba(15, 23, 42, 0.82);
}

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

.footer-grid p,
.footer-grid a,
.footer-bottom {
  color: var(--muted);
}

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

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

.footer-grid a:hover {
  color: var(--emerald-soft);
}

.footer-bottom {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 18px 0 30px;
  border-top: 1px solid rgba(30, 41, 59, 0.82);
  text-align: center;
  font-size: 14px;
}

.is-hidden-card {
  display: none !important;
}

@media (max-width: 1050px) {
  .desktop-nav {
    display: none;
  }

  .mobile-toggle {
    display: block;
  }

  .hero-media {
    right: 20px;
    width: 34vw;
  }

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

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

  .rank-panel,
  .detail-side {
    position: static;
  }

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

@media (max-width: 760px) {
  .brand-text {
    font-size: 18px;
  }

  .hero-carousel {
    min-height: 720px;
  }

  .hero-copy {
    padding-top: 120px;
  }

  .hero-media {
    position: relative;
    right: auto;
    bottom: auto;
    width: min(100%, 320px);
    margin: 26px auto 0;
  }

  .hero-media img {
    height: 320px;
  }

  .search-band,
  .search-controls,
  .footer-grid,
  .category-grid,
  .category-overview-grid {
    grid-template-columns: 1fr;
  }

  .quick-search {
    flex-direction: column;
  }

  .page-hero {
    padding: 34px 24px;
  }

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

  .feature-panel {
    padding: 22px;
  }

  .ranking-card a {
    grid-template-columns: 46px 110px 1fr;
    gap: 12px;
  }

  .ranking-card img {
    width: 110px;
    height: 76px;
  }

  .wide-card,
  .side-list .wide-card {
    grid-template-columns: 96px 1fr;
  }

  .wide-card img,
  .side-list .wide-card img {
    width: 96px;
    height: 70px;
  }

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

@media (max-width: 440px) {
  .card-grid,
  .small-grid {
    grid-template-columns: 1fr;
  }

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

  .ranking-number {
    font-size: 22px;
  }
}
