:root {
  --gold: #facc15;
  --gold-dark: #eab308;
  --orange: #fb923c;
  --ink: #111827;
  --muted: #6b7280;
  --paper: #ffffff;
  --soft: #fff7ed;
  --line: rgba(17, 24, 39, 0.08);
  --shadow: 0 24px 70px rgba(15, 23, 42, 0.13);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  background: linear-gradient(180deg, #fff7ed 0%, #ffffff 40%, #fff7ed 100%);
  font-family:
    -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC",
    "Microsoft YaHei", Arial, sans-serif;
}

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

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

main {
  width: min(1280px, calc(100% - 32px));
  margin: 0 auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  color: #fff;
  background: linear-gradient(90deg, #facc15 0%, #fb923c 45%, #f59e0b 100%);
  box-shadow: 0 16px 35px rgba(180, 83, 9, 0.22);
}

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

.brand,
.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 24px;
  font-weight: 900;
  letter-spacing: -0.02em;
  white-space: nowrap;
}

.brand-mark {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  color: #111827;
  background: #fff;
  box-shadow: inset 0 -2px 0 rgba(17, 24, 39, 0.12);
  font-size: 15px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 18px;
  font-weight: 700;
  font-size: 15px;
}

.nav-links a,
.mobile-nav a {
  opacity: 0.94;
  transition:
    opacity 0.2s ease,
    transform 0.2s ease;
}

.nav-links a:hover,
.mobile-nav a:hover {
  opacity: 1;
  transform: translateY(-1px);
}

.mobile-menu-button {
  display: none;
  border: 0;
  color: #fff;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 14px;
  width: 44px;
  height: 44px;
  font-size: 24px;
}

.mobile-nav {
  display: none;
  width: min(1280px, calc(100% - 32px));
  margin: 0 auto;
  padding: 0 0 16px;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

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

.mobile-nav a {
  padding: 10px 12px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.18);
  font-weight: 800;
}

.hero-slider {
  position: relative;
  min-height: 560px;
  margin: 28px 0 46px;
  overflow: hidden;
  border-radius: 28px;
  box-shadow: var(--shadow);
  background:
    radial-gradient(
      circle at 20% 20%,
      rgba(250, 204, 21, 0.5),
      transparent 30%
    ),
    #111827;
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  padding: 56px;
  background-size: cover;
  background-position: center;
  opacity: 0;
  transform: scale(1.04);
  transition:
    opacity 0.7s ease,
    transform 0.7s ease;
}

.hero-slide.is-active {
  opacity: 1;
  transform: scale(1);
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    90deg,
    rgba(0, 0, 0, 0.82),
    rgba(0, 0, 0, 0.55),
    rgba(0, 0, 0, 0.08)
  );
}

.hero-content {
  position: relative;
  z-index: 1;
  max-width: 680px;
  color: #fff;
}

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

.hero-chip-row span,
.detail-tags span,
.tag-row span {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 7px 12px;
  background: rgba(250, 204, 21, 0.18);
  color: #92400e;
  font-size: 13px;
  font-weight: 800;
}

.hero-chip-row span {
  color: #111827;
  background: var(--gold);
}

.hero-content h1 {
  margin: 18px 0;
  font-size: clamp(42px, 6vw, 76px);
  line-height: 0.98;
  letter-spacing: -0.06em;
  font-weight: 950;
}

.hero-content p {
  max-width: 620px;
  color: rgba(255, 255, 255, 0.86);
  font-size: clamp(17px, 2vw, 22px);
  line-height: 1.7;
}

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

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

.primary-button {
  color: #111827;
  background: var(--gold);
  box-shadow: 0 14px 30px rgba(250, 204, 21, 0.28);
}

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

.ghost-button {
  color: #fff;
  background: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.24);
  backdrop-filter: blur(10px);
}

.ghost-dark-button {
  color: #111827;
  background: #fff;
  border: 1px solid var(--line);
}

.hero-nav {
  position: absolute;
  top: 50%;
  z-index: 2;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 999px;
  color: #fff;
  background: rgba(0, 0, 0, 0.45);
  font-size: 36px;
  line-height: 1;
  transform: translateY(-50%);
}

.hero-prev {
  left: 18px;
}

.hero-next {
  right: 18px;
}

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

.hero-dots button {
  width: 28px;
  height: 8px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.42);
}

.hero-dots button.is-active {
  width: 44px;
  background: var(--gold);
}

.section-block {
  margin: 0 0 48px;
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.86);
  box-shadow: 0 18px 48px rgba(15, 23, 42, 0.08);
}

.intro-search {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 430px);
  align-items: end;
  gap: 28px;
}

.eyebrow {
  margin: 0 0 8px;
  color: #d97706;
  font-size: 13px;
  font-weight: 950;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.section-block h1,
.page-hero h1,
.section-heading h2,
.detail-content h1 {
  margin: 0;
  color: #111827;
  font-weight: 950;
  letter-spacing: -0.045em;
}

.section-block h1,
.page-hero h1 {
  font-size: clamp(34px, 5vw, 58px);
}

.section-block p,
.page-hero p,
.card-body p,
.promo-panel p,
.detail-content p {
  color: var(--muted);
  line-height: 1.75;
}

.global-search,
.filter-line {
  display: flex;
  gap: 12px;
}

.global-search input,
.filter-line input {
  width: 100%;
  min-height: 50px;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0 18px;
  outline: none;
  background: #fff;
  box-shadow: inset 0 1px 0 rgba(15, 23, 42, 0.04);
}

.global-search input:focus,
.filter-line input:focus {
  border-color: var(--gold-dark);
  box-shadow: 0 0 0 4px rgba(250, 204, 21, 0.18);
}

.global-search button {
  min-width: 96px;
  border: 0;
  border-radius: 999px;
  color: #111827;
  background: var(--gold);
  font-weight: 900;
}

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

.section-heading h2 {
  font-size: clamp(26px, 3vw, 38px);
}

.section-heading a {
  color: #b45309;
  font-weight: 900;
}

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

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

.movie-card {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: #fff;
  box-shadow: 0 14px 32px rgba(15, 23, 42, 0.08);
  transition:
    transform 0.22s ease,
    box-shadow 0.22s ease;
}

.movie-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 24px 50px rgba(15, 23, 42, 0.13);
}

.poster-wrap {
  position: relative;
  display: block;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  background: linear-gradient(135deg, #fef3c7, #fed7aa);
}

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

.movie-card:hover .poster-wrap img {
  transform: scale(1.06);
}

.poster-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  border-radius: 999px;
  padding: 5px 9px;
  color: #111827;
  background: var(--gold);
  font-size: 12px;
  font-weight: 900;
}

.card-body {
  padding: 15px;
}

.card-meta {
  margin-bottom: 8px;
  color: #d97706;
  font-size: 12px;
  font-weight: 900;
}

.card-body h2 {
  margin: 0 0 8px;
  font-size: 17px;
  line-height: 1.35;
  font-weight: 950;
}

.card-body p {
  display: -webkit-box;
  min-height: 50px;
  overflow: hidden;
  margin: 0 0 12px;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  font-size: 14px;
}

.tag-row span {
  padding: 4px 8px;
  font-size: 12px;
}

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

.category-tile,
.category-card {
  position: relative;
  overflow: hidden;
  min-height: 190px;
  border-radius: 24px;
  background: #111827;
  box-shadow: 0 18px 40px rgba(15, 23, 42, 0.12);
}

.category-tile img,
.category-card img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.42;
  transition: transform 0.3s ease;
}

.category-tile:hover img,
.category-card:hover img {
  transform: scale(1.06);
}

.category-tile span,
.category-tile strong,
.category-card div {
  position: relative;
  z-index: 1;
}

.category-tile {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 10px;
  padding: 20px;
  color: #fff;
}

.category-tile span {
  font-size: 22px;
  font-weight: 950;
}

.category-tile strong {
  color: rgba(255, 255, 255, 0.82);
  font-size: 14px;
  line-height: 1.55;
}

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

.category-card {
  min-height: 250px;
  display: flex;
  align-items: flex-end;
  padding: 24px;
  color: #fff;
}

.category-card div {
  max-width: 560px;
}

.category-card .eyebrow,
.category-card p,
.category-card strong {
  color: rgba(255, 255, 255, 0.86);
}

.category-card h2 {
  margin: 0 0 10px;
  font-size: 30px;
  font-weight: 950;
}

.split-section {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(280px, 0.55fr);
  gap: 28px;
}

.rank-list {
  display: grid;
  gap: 12px;
}

.rank-row {
  display: grid;
  grid-template-columns: 54px 64px minmax(0, 1fr);
  align-items: center;
  gap: 14px;
  min-height: 78px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: #fff;
  transition:
    transform 0.2s ease,
    border-color 0.2s ease;
}

.large-rank-row {
  grid-template-columns: 68px 70px minmax(0, 0.7fr) minmax(180px, 1fr);
}

.rank-row:hover {
  border-color: rgba(217, 119, 6, 0.35);
  transform: translateX(4px);
}

.rank-number {
  color: #d97706;
  font-size: 22px;
  font-weight: 950;
  text-align: center;
}

.rank-row img {
  width: 64px;
  height: 64px;
  border-radius: 16px;
  object-fit: cover;
  background: linear-gradient(135deg, #fef3c7, #fed7aa);
}

.rank-title {
  overflow: hidden;
  font-weight: 950;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.rank-meta {
  overflow: hidden;
  color: var(--muted);
  font-size: 14px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.promo-panel {
  min-height: 100%;
  padding: 28px;
  border-radius: 26px;
  color: #111827;
  background: linear-gradient(135deg, #fef3c7, #fdba74);
}

.promo-panel h2 {
  margin: 0 0 12px;
  font-size: 32px;
  line-height: 1.12;
  font-weight: 950;
}

.page-hero {
  margin: 30px 0 34px;
  padding: 62px 46px;
  border-radius: 30px;
  color: #111827;
  background:
    radial-gradient(
      circle at 10% 10%,
      rgba(250, 204, 21, 0.55),
      transparent 28%
    ),
    linear-gradient(135deg, #ffffff 0%, #fff7ed 58%, #fed7aa 100%);
  box-shadow: var(--shadow);
}

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

.compact-page-hero {
  padding: 42px;
}

.filter-panel {
  padding: 20px;
}

.chip-filter {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 14px;
}

.chip-filter button {
  border: 0;
  border-radius: 999px;
  padding: 8px 12px;
  color: #92400e;
  background: #fef3c7;
  font-weight: 900;
}

.chip-filter button.is-active {
  color: #111827;
  background: var(--gold);
}

.movie-card.is-hidden,
.rank-row.is-hidden {
  display: none;
}

.breadcrumb {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 26px 0;
  color: var(--muted);
  font-size: 14px;
}

.breadcrumb a {
  color: #b45309;
  font-weight: 900;
}

.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 330px;
  gap: 28px;
  align-items: start;
}

.detail-main,
.detail-side .side-card {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 28px;
  background: #fff;
  box-shadow: 0 18px 48px rgba(15, 23, 42, 0.08);
}

.player-card {
  position: relative;
  overflow: hidden;
  border-radius: 28px 28px 0 0;
  background: #020617;
  aspect-ratio: 16 / 9;
}

.movie-player {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #000;
}

.player-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  border: 0;
  color: #fff;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.25), rgba(0, 0, 0, 0.68));
  cursor: pointer;
}

.player-overlay span {
  width: 78px;
  height: 78px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  color: #111827;
  background: var(--gold);
  font-size: 30px;
  box-shadow: 0 20px 45px rgba(250, 204, 21, 0.25);
}

.player-overlay strong {
  font-size: 18px;
}

.player-card.is-playing .player-overlay {
  opacity: 0;
  pointer-events: none;
}

.detail-content {
  padding: 28px;
}

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

.detail-content h1 {
  font-size: clamp(32px, 4vw, 54px);
}

.lead-text {
  margin: 16px 0 26px;
  font-size: 18px;
}

.detail-content h2,
.side-card h2 {
  margin: 24px 0 10px;
  font-size: 24px;
  font-weight: 950;
}

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

.detail-side {
  position: sticky;
  top: 88px;
  display: grid;
  gap: 18px;
}

.side-poster {
  width: 100%;
  border-radius: 28px;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  background: linear-gradient(135deg, #fef3c7, #fed7aa);
  box-shadow: var(--shadow);
}

.side-card {
  padding: 22px;
}

.side-card dl {
  display: grid;
  grid-template-columns: 70px minmax(0, 1fr);
  gap: 12px;
  margin: 0 0 20px;
}

.side-card dt {
  color: var(--muted);
}

.side-card dd {
  margin: 0;
  font-weight: 900;
}

.wide-button {
  width: 100%;
}

.related-section {
  margin-top: 34px;
}

.site-footer {
  margin-top: 60px;
  color: #d1d5db;
  background: linear-gradient(180deg, #111827, #030712);
}

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

.footer-brand {
  color: #fff;
}

.site-footer p {
  color: #9ca3af;
  line-height: 1.75;
}

.site-footer h2 {
  margin: 0 0 15px;
  color: var(--gold);
  font-size: 18px;
  font-weight: 950;
}

.footer-links {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px 16px;
}

.footer-links a {
  color: #9ca3af;
}

.footer-links a:hover {
  color: var(--gold);
}

.footer-bottom {
  width: min(1280px, calc(100% - 32px));
  margin: 0 auto;
  padding: 20px 0 30px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  color: #9ca3af;
  text-align: center;
}

@media (max-width: 1180px) {
  .movie-grid,
  .featured-grid,
  .related-grid,
  .category-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

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

@media (max-width: 980px) {
  main {
    width: min(100% - 24px, 920px);
  }

  .nav-links {
    display: none;
  }

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

  .hero-slider {
    min-height: 520px;
    border-radius: 22px;
  }

  .hero-slide {
    padding: 34px;
  }

  .intro-search,
  .split-section,
  .detail-layout,
  .footer-grid {
    grid-template-columns: 1fr;
  }

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

  .detail-side {
    position: static;
  }
}

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

  .section-block,
  .page-hero {
    padding: 20px;
    border-radius: 22px;
  }

  .hero-slider {
    min-height: 560px;
    margin-top: 16px;
  }

  .hero-slide {
    padding: 28px 22px;
  }

  .hero-overlay {
    background: linear-gradient(
      180deg,
      rgba(0, 0, 0, 0.78),
      rgba(0, 0, 0, 0.5)
    );
  }

  .hero-nav {
    display: none;
  }

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

  .card-body {
    padding: 12px;
  }

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

  .filter-line,
  .global-search,
  .hero-actions {
    flex-direction: column;
  }

  .large-rank-row,
  .rank-row {
    grid-template-columns: 46px 58px minmax(0, 1fr);
  }

  .large-rank-row .rank-meta {
    grid-column: 3;
  }

  .footer-links {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 460px) {
  main,
  .nav-shell,
  .mobile-nav,
  .footer-grid,
  .footer-bottom {
    width: min(100% - 20px, 430px);
  }

  .movie-grid,
  .featured-grid,
  .related-grid,
  .category-grid,
  .category-card-grid {
    grid-template-columns: 1fr;
  }

  .hero-content h1 {
    font-size: 38px;
  }

  .poster-wrap {
    aspect-ratio: 16 / 10;
  }
}
