:root {
  --amber-950: #451a03;
  --amber-900: #78350f;
  --amber-800: #92400e;
  --amber-700: #b45309;
  --amber-600: #d97706;
  --amber-500: #f59e0b;
  --amber-100: #fef3c7;
  --slate-950: #020617;
  --slate-900: #0f172a;
  --slate-800: #1e293b;
  --slate-700: #334155;
  --slate-600: #475569;
  --slate-500: #64748b;
  --slate-100: #f1f5f9;
  --slate-50: #f8fafc;
  --white: #ffffff;
  --shadow: 0 20px 45px rgba(15, 23, 42, 0.14);
  --soft-shadow: 0 12px 28px rgba(15, 23, 42, 0.1);
  --radius: 20px;
  --max: 1180px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family:
    Inter,
    ui-sans-serif,
    system-ui,
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    "Microsoft YaHei",
    sans-serif;
  color: var(--slate-800);
  background: linear-gradient(180deg, #fff7ed 0%, #ffffff 34%, #f8fafc 100%);
}

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

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

button,
input,
select {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  color: #fff;
  background: linear-gradient(
    90deg,
    var(--amber-900),
    var(--amber-700),
    var(--amber-950)
  );
  box-shadow: 0 14px 30px rgba(69, 26, 3, 0.28);
}

.top-nav {
  width: min(var(--max), calc(100% - 32px));
  height: 66px;
  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-mark {
  width: 34px;
  height: 34px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--amber-950);
  background: linear-gradient(135deg, #fde68a, #f59e0b);
  box-shadow:
    inset 0 0 0 2px rgba(255, 255, 255, 0.38),
    0 8px 16px rgba(0, 0, 0, 0.18);
}

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

.nav-links {
  display: flex;
  align-items: center;
  gap: 26px;
}

.nav-link,
.mobile-link {
  font-weight: 700;
  color: rgba(255, 255, 255, 0.88);
  transition:
    color 0.2s ease,
    transform 0.2s ease;
}

.nav-link:hover,
.nav-link.active,
.mobile-link:hover,
.mobile-link.active {
  color: #fde68a;
}

.menu-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.12);
  padding: 9px;
}

.menu-toggle span {
  display: block;
  height: 2px;
  margin: 6px 0;
  background: #fff;
  border-radius: 999px;
}

.mobile-menu {
  display: none;
  width: min(var(--max), calc(100% - 32px));
  margin: 0 auto;
  padding: 12px 0 18px;
}

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

.mobile-link {
  padding: 11px 14px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.1);
}

.hero {
  position: relative;
  min-height: 680px;
  color: #fff;
  background:
    radial-gradient(
      circle at top left,
      rgba(245, 158, 11, 0.35),
      transparent 35%
    ),
    linear-gradient(135deg, #451a03, #78350f 52%, #0f172a);
  overflow: hidden;
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  opacity: 0.18;
  background-image: radial-gradient(
    circle,
    rgba(255, 255, 255, 0.45) 1px,
    transparent 1px
  );
  background-size: 28px 28px;
  animation: floatDots 18s linear infinite;
}

@keyframes floatDots {
  from {
    transform: translateY(0);
  }
  to {
    transform: translateY(-56px);
  }
}

.hero-stage {
  position: relative;
  width: min(var(--max), calc(100% - 32px));
  min-height: 560px;
  margin: 0 auto;
}

.hero-slide {
  position: absolute;
  inset: 42px 0 0;
  min-height: 520px;
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 34px;
  align-items: center;
  padding: 54px;
  border-radius: 34px;
  background-size: cover;
  background-position: center;
  opacity: 0;
  transform: translateX(26px) scale(0.98);
  pointer-events: none;
  transition:
    opacity 0.6s ease,
    transform 0.6s ease;
  box-shadow: 0 26px 70px rgba(0, 0, 0, 0.38);
}

.hero-slide.is-active {
  opacity: 1;
  transform: translateX(0) scale(1);
  pointer-events: auto;
}

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

.eyebrow,
.section-kicker {
  margin: 0 0 12px;
  font-size: 13px;
  font-weight: 900;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--amber-500);
}

.hero-copy h2,
.hero-search h1,
.page-hero h1,
.detail-info h1 {
  margin: 0;
  font-size: clamp(38px, 7vw, 72px);
  line-height: 1.02;
  font-weight: 900;
  letter-spacing: -0.04em;
}

.hero-copy p,
.hero-search p,
.page-hero p,
.detail-line {
  font-size: 18px;
  line-height: 1.8;
  color: rgba(255, 255, 255, 0.84);
}

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

.hero-tags span,
.detail-tags span,
.tag-row span {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 5px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
  color: #78350f;
  background: #fef3c7;
}

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

.primary-btn,
.ghost-btn,
.ghost-dark-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 22px;
  border-radius: 14px;
  font-weight: 900;
  transition:
    transform 0.2s ease,
    box-shadow 0.2s ease,
    background 0.2s ease;
}

.primary-btn {
  color: #451a03;
  background: linear-gradient(135deg, #fef3c7, #f59e0b);
  box-shadow: 0 14px 30px rgba(245, 158, 11, 0.34);
}

.ghost-btn,
.ghost-dark-btn {
  color: #fff;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.24);
}

.ghost-dark-btn {
  color: var(--amber-900);
  background: #fff7ed;
  border-color: #fed7aa;
}

.primary-btn:hover,
.ghost-btn:hover,
.ghost-dark-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 32px rgba(15, 23, 42, 0.16);
}

.hero-poster {
  width: min(360px, 100%);
  justify-self: center;
  border-radius: 26px;
  overflow: hidden;
  transform: rotate(2deg);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.45);
}

.hero-poster img {
  width: 100%;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  transition: transform 0.35s ease;
}

.hero-poster:hover img,
.movie-card:hover img,
.rank-cover:hover img {
  transform: scale(1.05);
}

.hero-controls {
  position: absolute;
  left: 54px;
  bottom: 34px;
  display: flex;
  gap: 10px;
  z-index: 3;
}

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

.hero-dot.is-active {
  width: 34px;
  background: #f59e0b;
}

.hero-search {
  position: relative;
  width: min(var(--max), calc(100% - 32px));
  margin: -8px auto 0;
  padding: 28px;
  border-radius: 28px 28px 0 0;
  background: rgba(15, 23, 42, 0.72);
  backdrop-filter: blur(18px);
  box-shadow: var(--shadow);
}

.hero-search h1 {
  font-size: clamp(32px, 5vw, 52px);
}

.hero-search p {
  max-width: 820px;
  margin: 10px 0 22px;
}

.hero-search form,
.search-panel {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
}

.hero-search input,
.search-panel input,
.filter-panel input,
.filter-panel select {
  width: 100%;
  min-height: 48px;
  border: 1px solid rgba(148, 163, 184, 0.45);
  border-radius: 14px;
  padding: 0 16px;
  color: var(--slate-800);
  background: rgba(255, 255, 255, 0.96);
  outline: none;
}

.hero-search button,
.search-panel button {
  min-height: 48px;
  border: 0;
  border-radius: 14px;
  padding: 0 24px;
  font-weight: 900;
  color: #451a03;
  background: linear-gradient(135deg, #fde68a, #f59e0b);
}

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

.quick-cats a {
  padding: 8px 13px;
  border-radius: 999px;
  color: #fde68a;
  background: rgba(255, 255, 255, 0.1);
}

.section-wrap,
.category-band,
.player-section {
  width: min(var(--max), calc(100% - 32px));
  margin: 0 auto;
  padding: 64px 0;
}

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

.section-heading h2 {
  margin: 0;
  color: var(--slate-800);
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1.1;
}

.section-heading a {
  font-weight: 900;
  color: var(--amber-700);
}

.light h2,
.light a {
  color: #fff;
}

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

.movie-card {
  overflow: hidden;
  border-radius: 18px;
  background: #fff;
  box-shadow: var(--soft-shadow);
  transition:
    transform 0.22s ease,
    box-shadow 0.22s ease;
}

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

.card-poster {
  position: relative;
  display: block;
  overflow: hidden;
  background: linear-gradient(135deg, #78350f, #0f172a);
}

.card-poster img {
  width: 100%;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  transition: transform 0.35s ease;
}

.card-badge {
  position: absolute;
  left: 10px;
  bottom: 10px;
  z-index: 2;
  padding: 5px 9px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
  color: #fff;
  background: rgba(2, 6, 23, 0.72);
  backdrop-filter: blur(10px);
}

.card-body {
  padding: 16px;
}

.card-title {
  display: block;
  margin-bottom: 6px;
  color: var(--slate-900);
  font-size: 17px;
  font-weight: 900;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.card-title:hover,
.rank-title:hover {
  color: var(--amber-700);
}

.card-meta,
.card-line {
  margin: 0 0 10px;
  color: var(--slate-500);
  font-size: 13px;
  line-height: 1.6;
}

.card-line {
  color: var(--slate-700);
  min-height: 42px;
}

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

.movie-card.compact {
  display: grid;
  grid-template-columns: 112px 1fr;
  min-height: 170px;
}

.movie-card.compact .card-poster img {
  height: 100%;
  min-height: 170px;
  aspect-ratio: auto;
}

.movie-card.compact .card-line {
  min-height: auto;
}

.warm-section {
  padding-top: 24px;
}

.category-band {
  max-width: none;
  width: 100%;
  padding: 70px max(16px, calc((100% - var(--max)) / 2));
  background: linear-gradient(135deg, #0f172a, #1e1b4b 58%, #78350f);
}

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

.category-tile,
.category-card {
  display: block;
  min-height: 170px;
  padding: 24px;
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.16);
  backdrop-filter: blur(16px);
  transition:
    transform 0.22s ease,
    background 0.22s ease;
}

.category-tile:hover,
.category-card:hover {
  transform: translateY(-5px);
  background: rgba(255, 255, 255, 0.16);
}

.category-tile strong,
.category-card h2 {
  display: block;
  margin: 0 0 12px;
  font-size: 24px;
  color: #fff;
}

.category-tile span,
.category-card p {
  color: rgba(255, 255, 255, 0.72);
  line-height: 1.7;
}

.category-overview .category-card {
  color: var(--slate-800);
  background: #fff;
  border: 0;
  box-shadow: var(--soft-shadow);
}

.category-overview .category-card h2 {
  color: var(--slate-900);
}

.category-overview .category-card p {
  color: var(--slate-600);
}

.category-samples {
  display: grid;
  gap: 8px;
  margin-top: 18px;
}

.category-samples a {
  color: var(--amber-700);
  font-weight: 800;
}

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

.rank-item {
  display: grid;
  grid-template-columns: 46px 1fr auto;
  align-items: center;
  gap: 14px;
  padding: 16px;
  border-radius: 16px;
  background: #fff;
  box-shadow: var(--soft-shadow);
}

.rank-item span {
  width: 34px;
  height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  font-weight: 900;
  color: #451a03;
  background: #fde68a;
}

.rank-item em {
  color: var(--slate-500);
  font-style: normal;
}

.page-hero {
  color: #fff;
  background: linear-gradient(135deg, #451a03, #92400e 54%, #0f172a);
}

.small-hero {
  padding: 72px max(16px, calc((100% - var(--max)) / 2));
}

.small-hero h1 {
  font-size: clamp(34px, 5vw, 56px);
}

.small-hero p {
  max-width: 760px;
}

.filter-panel {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 16px;
  margin-bottom: 28px;
  padding: 22px;
  border-radius: 22px;
  background: #fff;
  box-shadow: var(--soft-shadow);
}

.filter-panel label {
  display: grid;
  gap: 8px;
  color: var(--slate-700);
  font-weight: 800;
}

.pager {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  margin-top: 34px;
}

.pager a,
.pager span {
  min-width: 40px;
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  padding: 0 12px;
  font-weight: 900;
  color: var(--amber-800);
  background: #fff;
  box-shadow: var(--soft-shadow);
}

.pager .current {
  color: #fff;
  background: var(--amber-700);
}

.detail-hero {
  width: min(var(--max), calc(100% - 32px));
  margin: 34px auto 0;
  display: grid;
  grid-template-columns: 340px 1fr;
  gap: 34px;
  align-items: center;
  padding: 34px;
  border-radius: 30px;
  color: #fff;
  background:
    radial-gradient(
      circle at top left,
      rgba(245, 158, 11, 0.28),
      transparent 36%
    ),
    linear-gradient(135deg, #451a03, #0f172a);
  box-shadow: var(--shadow);
}

.detail-poster {
  overflow: hidden;
  border-radius: 24px;
  box-shadow: 0 24px 55px rgba(0, 0, 0, 0.34);
}

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

.breadcrumb {
  display: flex;
  gap: 8px;
  margin-bottom: 18px;
  color: #fde68a;
  font-weight: 800;
}

.detail-tags span {
  background: rgba(253, 230, 138, 0.95);
}

.player-section {
  padding-bottom: 20px;
}

.video-box {
  position: relative;
  overflow: hidden;
  border-radius: 24px;
  background: #000;
  box-shadow: 0 26px 60px rgba(2, 6, 23, 0.28);
}

.movie-video {
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #000;
}

.play-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 0;
  color: #451a03;
  background: linear-gradient(
    180deg,
    rgba(2, 6, 23, 0.12),
    rgba(2, 6, 23, 0.5)
  );
  cursor: pointer;
}

.play-overlay span {
  width: 86px;
  height: 86px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  font-size: 34px;
  background: linear-gradient(135deg, #fff7ed, #f59e0b);
  box-shadow: 0 18px 38px rgba(0, 0, 0, 0.28);
}

.play-overlay.is-hidden {
  display: none;
}

.story-section {
  padding-top: 22px;
  padding-bottom: 22px;
}

.story-card {
  padding: 32px;
  border-radius: 24px;
  background: #fff;
  box-shadow: var(--soft-shadow);
}

.story-card h2 {
  margin: 0 0 12px;
  color: var(--slate-900);
  font-size: 28px;
}

.story-card p {
  margin: 0 0 26px;
  color: var(--slate-700);
  font-size: 17px;
  line-height: 1.9;
}

.rank-grid {
  display: grid;
  gap: 18px;
}

.rank-card {
  display: grid;
  grid-template-columns: 150px 1fr;
  gap: 20px;
  padding: 18px;
  border-radius: 22px;
  background: #fff;
  box-shadow: var(--soft-shadow);
}

.rank-cover {
  position: relative;
  overflow: hidden;
  border-radius: 18px;
}

.rank-cover span {
  position: absolute;
  top: 10px;
  left: 10px;
  z-index: 2;
  width: 34px;
  height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  color: #451a03;
  background: #fde68a;
  font-weight: 900;
}

.rank-cover img {
  width: 100%;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  transition: transform 0.35s ease;
}

.rank-title {
  display: inline-block;
  margin: 4px 0 8px;
  color: var(--slate-900);
  font-size: 24px;
  font-weight: 900;
}

.rank-card p {
  margin: 0 0 10px;
  color: var(--slate-600);
  line-height: 1.65;
}

.search-panel {
  margin-bottom: 28px;
  padding: 20px;
  border-radius: 22px;
  background: #fff;
  box-shadow: var(--soft-shadow);
}

.search-empty {
  grid-column: 1 / -1;
  padding: 34px;
  border-radius: 22px;
  text-align: center;
  color: var(--slate-600);
  background: #fff;
  box-shadow: var(--soft-shadow);
}

.site-footer {
  margin-top: 44px;
  color: #cbd5e1;
  background: linear-gradient(180deg, #0f172a, #020617);
}

.footer-grid {
  width: min(var(--max), calc(100% - 32px));
  margin: 0 auto;
  padding: 54px 0 36px;
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 30px;
}

.footer-grid h2 {
  margin: 0 0 14px;
  color: #fff;
  font-size: 18px;
}

.footer-grid p {
  line-height: 1.8;
}

.footer-grid a {
  display: block;
  margin: 9px 0;
  color: #cbd5e1;
}

.footer-grid a:hover {
  color: #f59e0b;
}

.footer-bottom {
  width: min(var(--max), calc(100% - 32px));
  margin: 0 auto;
  padding: 22px 0 30px;
  border-top: 1px solid rgba(148, 163, 184, 0.18);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.back-top {
  border: 0;
  border-radius: 12px;
  padding: 10px 16px;
  font-weight: 900;
  color: #fff;
  background: var(--amber-700);
}

.is-filtered-out {
  display: none;
}

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

  .menu-toggle {
    display: block;
  }

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

  .hero-slide {
    grid-template-columns: 1fr;
    min-height: 650px;
    padding: 34px;
  }

  .hero-poster {
    width: 230px;
    justify-self: start;
  }

  .movie-grid,
  .featured-strip,
  .category-grid,
  .category-overview {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .filter-panel,
  .detail-hero,
  .footer-grid {
    grid-template-columns: 1fr;
  }

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

@media (max-width: 640px) {
  .top-nav,
  .mobile-menu,
  .section-wrap,
  .player-section,
  .detail-hero,
  .hero-stage,
  .hero-search,
  .footer-grid,
  .footer-bottom {
    width: min(100% - 24px, var(--max));
  }

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

  .hero {
    min-height: 780px;
  }

  .hero-slide {
    top: 24px;
  right: 0;
  bottom: 0;
  left: 0;
    padding: 24px;
    border-radius: 24px;
  }

  .hero-copy h2,
  .hero-search h1,
  .page-hero h1,
  .detail-info h1 {
    font-size: 34px;
  }

  .hero-search form,
  .search-panel,
  .rank-item,
  .rank-card,
  .movie-card.compact {
    grid-template-columns: 1fr;
  }

  .hero-controls {
    left: 28px;
  }

  .movie-grid,
  .featured-strip,
  .category-grid,
  .category-overview,
  .rank-list {
    grid-template-columns: 1fr;
  }

  .small-hero {
    padding: 48px 16px;
  }

  .detail-hero {
    padding: 24px;
  }

  .footer-bottom {
    flex-direction: column;
    align-items: flex-start;
  }
}
