:root {
  --bg: #020617;
  --bg-soft: #0f172a;
  --bg-card: #1e293b;
  --bg-card-soft: rgba(30, 41, 59, 0.72);
  --line: #334155;
  --text: #ffffff;
  --muted: #94a3b8;
  --muted-strong: #cbd5e1;
  --accent: #f59e0b;
  --accent-soft: rgba(245, 158, 11, 0.16);
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.38);
}

html {
  scroll-behavior: smooth;
}

.site-body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
}

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

.site-nav {
  position: sticky;
  top: 0;
  z-index: 100;
  border-bottom: 1px solid rgba(51, 65, 85, 0.8);
  background: rgba(15, 23, 42, 0.94);
  backdrop-filter: blur(14px);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
  gap: 18px;
}

.site-logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  text-decoration: none;
  font-weight: 800;
  white-space: nowrap;
}

.logo-mark {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent);
  box-shadow: 0 0 0 1px rgba(245, 158, 11, 0.3) inset;
}

.logo-text {
  font-size: 20px;
  letter-spacing: 0.04em;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 20px;
  flex: 1;
  justify-content: center;
}

.nav-link {
  color: var(--muted-strong);
  font-size: 15px;
  text-decoration: none;
  transition: color 0.2s ease;
}

.nav-link:hover,
.nav-link-active {
  color: var(--accent);
}

.nav-search {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 4px;
  border-radius: 999px;
  background: rgba(30, 41, 59, 0.86);
}

.nav-search input,
.quick-search input,
.local-filter,
.search-page-form input {
  border: 0;
  outline: 0;
  color: var(--text);
  background: transparent;
}

.nav-search input {
  width: 180px;
  padding: 8px 8px 8px 14px;
}

.nav-search button,
.quick-search button,
.search-page-form button {
  border: 0;
  border-radius: 999px;
  color: var(--text);
  background: var(--accent);
  padding: 9px 16px;
  font-weight: 700;
  cursor: pointer;
  transition: transform 0.2s ease, background 0.2s ease;
}

.nav-search button:hover,
.quick-search button:hover,
.search-page-form button:hover,
.primary-button:hover {
  transform: translateY(-1px) scale(1.02);
  background: #d97706;
}

.mobile-menu-button {
  display: none;
  width: 40px;
  height: 40px;
  border: 0;
  border-radius: 10px;
  color: var(--text);
  background: rgba(30, 41, 59, 0.86);
  font-size: 22px;
}

.mobile-menu {
  display: none;
  padding: 12px 16px 18px;
  border-top: 1px solid rgba(51, 65, 85, 0.7);
}

.mobile-menu a {
  display: block;
  padding: 10px 4px;
  color: var(--muted-strong);
  text-decoration: none;
}

.mobile-menu-open {
  display: block;
}

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

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  display: flex;
  align-items: center;
  background-position: center;
  background-size: cover;
  transition: opacity 0.7s ease;
}

.hero-slide-active {
  opacity: 1;
  z-index: 2;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(2, 6, 23, 0.94), rgba(15, 23, 42, 0.74), rgba(15, 23, 42, 0.32)),
    linear-gradient(0deg, #020617 0%, rgba(2, 6, 23, 0.14) 40%, rgba(2, 6, 23, 0.2) 100%);
  backdrop-filter: blur(2px);
}

.hero-content {
  position: relative;
  z-index: 3;
}

.hero-copy {
  max-width: 740px;
  padding: 88px 0;
}

.hero-tags,
.detail-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 18px;
}

.hero-tags span,
.detail-tags span {
  display: inline-flex;
  align-items: center;
  border: 1px solid rgba(245, 158, 11, 0.36);
  border-radius: 999px;
  padding: 6px 12px;
  color: #fbbf24;
  background: rgba(245, 158, 11, 0.12);
  font-size: 13px;
  font-weight: 700;
}

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

.hero-copy h2 {
  margin: 0 0 14px;
  font-size: clamp(24px, 3vw, 42px);
  color: #fbbf24;
  font-weight: 800;
}

.hero-copy p {
  margin: 0;
  max-width: 620px;
  color: var(--muted-strong);
  font-size: 19px;
  line-height: 1.8;
}

.hero-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 34px;
}

.primary-button,
.ghost-button,
.section-more {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  text-decoration: none;
  font-weight: 800;
  transition: transform 0.2s ease, background 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.primary-button {
  padding: 14px 26px;
  color: var(--text);
  background: var(--accent);
}

.ghost-button {
  padding: 13px 24px;
  color: var(--text);
  border: 1px solid rgba(255, 255, 255, 0.22);
  background: rgba(255, 255, 255, 0.08);
}

.ghost-button:hover {
  border-color: rgba(245, 158, 11, 0.6);
  color: #fbbf24;
  transform: translateY(-1px);
}

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

.hero-dot {
  width: 12px;
  height: 12px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.35);
  cursor: pointer;
}

.hero-dot-active {
  width: 32px;
  background: var(--accent);
}

.quick-search-section {
  margin-top: -40px;
  position: relative;
  z-index: 8;
}

.quick-search-card {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 28px;
  padding: 28px;
  border: 1px solid rgba(51, 65, 85, 0.86);
  border-radius: 24px;
  background: rgba(15, 23, 42, 0.92);
  box-shadow: var(--shadow);
}

.quick-search-card h2,
.section-heading h2,
.detail-article h2,
.detail-side-card h2 {
  margin: 0;
  font-size: 30px;
  font-weight: 900;
}

.quick-search-card p,
.section-heading p,
.category-card-large p,
.category-tile p,
.page-hero p,
.detail-article p,
.detail-side-card dd {
  color: var(--muted);
  line-height: 1.75;
}

.quick-search {
  display: flex;
  width: min(460px, 100%);
  padding: 6px;
  border-radius: 999px;
  background: rgba(30, 41, 59, 0.86);
}

.quick-search input,
.search-page-form input {
  flex: 1;
  min-width: 0;
  padding: 12px 16px;
}

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

.section-muted {
  background: rgba(15, 23, 42, 0.56);
}

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

.section-more {
  color: #fbbf24;
  padding: 10px 16px;
  background: rgba(245, 158, 11, 0.12);
}

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

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

.wide-grid,
.category-movie-grid,
.related-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.movie-card {
  overflow: hidden;
  border: 1px solid rgba(51, 65, 85, 0.72);
  border-radius: 18px;
  background: var(--bg-card-soft);
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.22);
  transition: transform 0.25s ease, border-color 0.25s ease, background 0.25s ease;
}

.movie-card:hover {
  transform: translateY(-8px);
  border-color: rgba(245, 158, 11, 0.72);
  background: rgba(30, 41, 59, 0.94);
}

.movie-cover {
  position: relative;
  display: block;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  color: var(--text);
  text-decoration: none;
  background: #0f172a;
}

.movie-cover img,
.movie-row-cover img,
.detail-poster img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.35s ease;
}

.movie-card:hover .movie-cover img,
.movie-row:hover .movie-row-cover img {
  transform: scale(1.06);
}

.movie-type,
.rank-badge {
  position: absolute;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--text);
  font-weight: 800;
}

.movie-type {
  right: 12px;
  top: 12px;
  border-radius: 999px;
  padding: 5px 10px;
  background: rgba(2, 6, 23, 0.78);
  font-size: 12px;
}

.rank-badge {
  left: 12px;
  top: 12px;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 10px 30px rgba(245, 158, 11, 0.35);
}

.movie-card-body {
  padding: 18px;
}

.movie-title,
.movie-row-title,
.category-card-title {
  color: var(--text);
  text-decoration: none;
  font-weight: 850;
  transition: color 0.2s ease;
}

.movie-title {
  display: block;
  margin-bottom: 10px;
  font-size: 18px;
  line-height: 1.35;
}

.movie-title:hover,
.movie-row-title:hover,
.category-card-title:hover {
  color: #fbbf24;
}

.movie-one-line {
  min-height: 48px;
  margin: 0 0 14px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.7;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.movie-meta,
.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: var(--muted-strong);
  font-size: 13px;
}

.movie-meta span,
.detail-meta span {
  border-radius: 999px;
  padding: 4px 9px;
  background: rgba(51, 65, 85, 0.76);
}

.two-column-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(320px, 0.7fr);
  gap: 34px;
}

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

.movie-row {
  display: grid;
  grid-template-columns: 128px minmax(0, 1fr);
  gap: 16px;
  align-items: stretch;
  padding: 12px;
  border: 1px solid rgba(51, 65, 85, 0.72);
  border-radius: 18px;
  background: rgba(30, 41, 59, 0.58);
  transition: border-color 0.25s ease, background 0.25s ease, transform 0.25s ease;
}

.movie-row:hover {
  transform: translateY(-3px);
  border-color: rgba(245, 158, 11, 0.6);
  background: rgba(30, 41, 59, 0.86);
}

.movie-row-cover {
  position: relative;
  display: block;
  overflow: hidden;
  border-radius: 12px;
  aspect-ratio: 16 / 10;
  background: #0f172a;
}

.movie-row-body p {
  margin: 8px 0 12px;
  color: var(--muted);
  line-height: 1.65;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.ranking-panel {
  padding: 24px;
  border: 1px solid rgba(51, 65, 85, 0.72);
  border-radius: 24px;
  background: rgba(15, 23, 42, 0.72);
}

.compact-list .movie-row {
  grid-template-columns: 96px minmax(0, 1fr);
}

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

.category-tile,
.category-card-large {
  display: block;
  border: 1px solid rgba(51, 65, 85, 0.78);
  border-radius: 20px;
  padding: 22px;
  color: var(--text);
  text-decoration: none;
  background:
    radial-gradient(circle at top right, rgba(245, 158, 11, 0.16), transparent 34%),
    rgba(30, 41, 59, 0.64);
  transition: transform 0.25s ease, border-color 0.25s ease;
}

.category-tile:hover,
.category-card-large:hover {
  transform: translateY(-5px);
  border-color: rgba(245, 158, 11, 0.72);
}

.category-tile span,
.category-card-title {
  display: block;
  margin-bottom: 10px;
  font-size: 21px;
  font-weight: 900;
}

.category-samples {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 16px;
}

.category-samples a,
.sibling-categories a {
  color: #fbbf24;
  text-decoration: none;
  border-radius: 999px;
  padding: 6px 10px;
  background: rgba(245, 158, 11, 0.12);
  font-size: 13px;
}

.page-hero {
  position: relative;
  padding: 86px 0 64px;
  overflow: hidden;
  background:
    radial-gradient(circle at 20% 0%, rgba(245, 158, 11, 0.18), transparent 28%),
    linear-gradient(135deg, #0f172a, #020617 72%);
}

.page-hero h1 {
  margin: 10px 0 16px;
  font-size: clamp(34px, 5vw, 62px);
  line-height: 1.05;
  font-weight: 950;
}

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

.eyebrow {
  color: #fbbf24;
  font-weight: 900;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

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

.breadcrumb a {
  color: #fbbf24;
  text-decoration: none;
}

.sibling-categories {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 22px;
}

.filter-bar {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 28px;
}

.local-filter {
  width: min(520px, 100%);
  border: 1px solid rgba(51, 65, 85, 0.82);
  border-radius: 999px;
  padding: 14px 18px;
  background: rgba(30, 41, 59, 0.72);
}

.filter-text {
  color: var(--muted);
  font-size: 14px;
}

.detail-hero {
  position: relative;
  background-position: center;
  background-size: cover;
}

.detail-hero-mask {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(2, 6, 23, 0.96), rgba(15, 23, 42, 0.78), rgba(15, 23, 42, 0.4)),
    linear-gradient(0deg, #020617 0%, rgba(2, 6, 23, 0.18) 55%, rgba(2, 6, 23, 0.38) 100%);
  backdrop-filter: blur(5px);
}

.detail-hero-inner {
  position: relative;
  z-index: 2;
  padding: 72px 0;
}

.detail-grid {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  gap: 34px;
  align-items: end;
}

.detail-poster {
  overflow: hidden;
  border: 1px solid rgba(245, 158, 11, 0.42);
  border-radius: 24px;
  aspect-ratio: 3 / 4;
  background: #0f172a;
  box-shadow: var(--shadow);
}

.detail-main-copy h1 {
  margin: 0 0 18px;
  font-size: clamp(38px, 5vw, 68px);
  line-height: 1.05;
  font-weight: 950;
}

.detail-one-line {
  max-width: 860px;
  margin: 0 0 18px;
  color: var(--muted-strong);
  font-size: 20px;
  line-height: 1.72;
}

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

.player-section {
  padding-top: 42px;
}

.player-shell {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(51, 65, 85, 0.82);
  border-radius: 24px;
  aspect-ratio: 16 / 9;
  background: #000000;
  box-shadow: var(--shadow);
}

.movie-video {
  width: 100%;
  height: 100%;
  background: #000000;
}

.player-overlay {
  position: absolute;
  inset: 0;
  z-index: 4;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  border: 0;
  color: var(--text);
  background: linear-gradient(180deg, rgba(2, 6, 23, 0.18), rgba(2, 6, 23, 0.74));
  cursor: pointer;
}

.player-overlay-hidden {
  display: none;
}

.play-icon {
  display: grid;
  place-items: center;
  width: 82px;
  height: 82px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 24px 48px rgba(245, 158, 11, 0.35);
  font-size: 34px;
  line-height: 1;
}

.detail-content-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 28px;
}

.detail-article,
.detail-side-card {
  border: 1px solid rgba(51, 65, 85, 0.72);
  border-radius: 24px;
  padding: 28px;
  background: rgba(15, 23, 42, 0.72);
}

.detail-article h2 + p {
  margin-top: 14px;
}

.detail-article p + h2 {
  margin-top: 30px;
}

.detail-article p {
  margin-bottom: 0;
  font-size: 17px;
}

.detail-side-card dl {
  display: grid;
  grid-template-columns: 72px 1fr;
  gap: 12px 16px;
  margin: 20px 0 24px;
}

.detail-side-card dt {
  color: var(--muted-strong);
  font-weight: 800;
}

.detail-side-card dd {
  margin: 0;
}

.detail-side-card a {
  color: #fbbf24;
  text-decoration: none;
  font-weight: 800;
}

.search-page-form {
  display: flex;
  width: min(680px, 100%);
  margin-top: 26px;
  padding: 6px;
  border-radius: 999px;
  background: rgba(30, 41, 59, 0.86);
}

.no-results {
  grid-column: 1 / -1;
  padding: 30px;
  border: 1px solid rgba(51, 65, 85, 0.72);
  border-radius: 20px;
  color: var(--muted-strong);
  background: rgba(30, 41, 59, 0.64);
}

.site-footer {
  border-top: 1px solid rgba(51, 65, 85, 0.8);
  background: #020617;
  padding: 42px 0 24px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 24px;
  align-items: start;
}

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

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

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

.footer-links a {
  color: var(--muted-strong);
  text-decoration: none;
}

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

.footer-bottom {
  margin-top: 30px;
  color: var(--muted);
  font-size: 14px;
}

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

  .mobile-menu-button {
    display: inline-grid;
    place-items: center;
  }

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

  .two-column-layout,
  .detail-content-grid {
    grid-template-columns: 1fr;
  }
}

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

  .nav-search {
    display: none;
  }

  .hero-slider {
    min-height: 78vh;
  }

  .hero-copy {
    padding: 74px 0;
  }

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

  .quick-search-card,
  .footer-grid,
  .detail-grid {
    grid-template-columns: 1fr;
  }

  .quick-search,
  .search-page-form {
    width: 100%;
  }

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

  .movie-grid,
  .wide-grid,
  .category-movie-grid,
  .related-grid,
  .category-grid,
  .category-overview-grid,
  .featured-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
  }

  .movie-card-body {
    padding: 14px;
  }

  .movie-cover {
    aspect-ratio: 3 / 4;
  }

  .movie-row {
    grid-template-columns: 100px minmax(0, 1fr);
  }

  .detail-poster {
    width: min(260px, 100%);
  }

  .filter-bar {
    align-items: stretch;
    flex-direction: column;
  }

  .detail-hero-inner {
    padding: 50px 0;
  }

  .detail-side-card dl {
    grid-template-columns: 64px 1fr;
  }
}

@media (max-width: 480px) {
  .movie-grid,
  .wide-grid,
  .category-movie-grid,
  .related-grid,
  .category-grid,
  .category-overview-grid,
  .featured-grid {
    grid-template-columns: 1fr;
  }

  .movie-row {
    grid-template-columns: 88px minmax(0, 1fr);
  }

  .site-section {
    padding: 54px 0;
  }
}
