* {
  box-sizing: border-box;
}

:root {
  color-scheme: light;
  --amber-950: #451a03;
  --amber-900: #78350f;
  --amber-800: #92400e;
  --amber-700: #b45309;
  --amber-600: #d97706;
  --amber-100: #fef3c7;
  --slate-950: #020617;
  --slate-900: #0f172a;
  --slate-800: #1e293b;
  --slate-700: #334155;
  --slate-600: #475569;
  --slate-500: #64748b;
  --slate-100: #f1f5f9;
  --rose-600: #e11d48;
  --emerald-600: #059669;
  --blue-700: #1d4ed8;
  --card: #ffffff;
  --shadow: 0 18px 45px rgba(15, 23, 42, 0.14);
  --shadow-soft: 0 12px 25px rgba(15, 23, 42, 0.08);
  --radius-lg: 24px;
  --radius: 18px;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: Inter, "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
  background: linear-gradient(180deg, #fffbeb 0%, #ffffff 42%, #f8fafc 100%);
  color: var(--slate-800);
}

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

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

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 12px 32px rgba(69, 26, 3, 0.28);
}

.nav-shell {
  max-width: 1180px;
  height: 64px;
  padding: 0 20px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

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

.brand-mark,
.footer-brand span {
  width: 34px;
  height: 34px;
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.16);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.22);
}

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

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

.nav-link {
  opacity: 0.9;
  padding: 8px 0;
  border-bottom: 2px solid transparent;
  transition: color 0.2s ease, border-color 0.2s ease, opacity 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
  opacity: 1;
  color: var(--amber-100);
  border-color: var(--amber-100);
}

.menu-toggle {
  display: none;
  color: #fff;
  background: rgba(255, 255, 255, 0.12);
  border: 0;
  border-radius: 12px;
  padding: 8px 11px;
  cursor: pointer;
}

.mobile-nav {
  display: none;
  padding: 10px 20px 16px;
  background: var(--amber-900);
  border-top: 1px solid rgba(255, 255, 255, 0.14);
}

.mobile-nav a {
  display: block;
  padding: 12px 0;
  color: #fff;
}

.hero-section {
  position: relative;
  min-height: 640px;
  overflow: hidden;
  color: #fff;
  background: radial-gradient(circle at 80% 20%, rgba(251, 191, 36, 0.28), transparent 28%), linear-gradient(135deg, #451a03 0%, #92400e 45%, #7f1d1d 100%);
}

.hero-pattern {
  position: absolute;
  inset: 0;
  opacity: 0.23;
  background-image: radial-gradient(circle, rgba(255, 255, 255, 0.4) 1px, transparent 1px);
  background-size: 32px 32px;
  animation: slowFloat 18s linear infinite;
}

@keyframes slowFloat {
  from {
    transform: translate3d(0, 0, 0);
  }
  to {
    transform: translate3d(32px, 32px, 0);
  }
}

.hero-shell {
  position: relative;
  max-width: 1180px;
  min-height: 640px;
  margin: 0 auto;
  padding: 76px 20px 42px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.hero-slider {
  position: relative;
  min-height: 430px;
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(280px, 0.65fr);
  align-items: center;
  gap: 48px;
  opacity: 0;
  transform: translateY(20px);
  pointer-events: none;
  transition: opacity 0.65s ease, transform 0.65s ease;
}

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

.eyebrow {
  display: inline-flex;
  width: fit-content;
  margin-bottom: 16px;
  padding: 8px 14px;
  border-radius: 999px;
  color: #fff7ed;
  background: rgba(255, 255, 255, 0.14);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.18);
  font-size: 14px;
  font-weight: 700;
}

.hero-copy h1,
.page-hero h1,
.detail-copy h1 {
  margin: 0 0 20px;
  font-size: clamp(40px, 7vw, 78px);
  line-height: 1.05;
  letter-spacing: -0.05em;
}

.hero-copy p,
.page-hero p,
.detail-copy p {
  margin: 0 0 26px;
  max-width: 760px;
  color: #ffedd5;
  font-size: clamp(18px, 2.2vw, 24px);
  line-height: 1.8;
}

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

.hero-tags span,
.tag-row span {
  display: inline-flex;
  padding: 7px 12px;
  border-radius: 999px;
  color: #fff;
  background: rgba(255, 255, 255, 0.16);
  font-size: 13px;
  font-weight: 700;
}

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

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

.primary-button {
  color: var(--amber-950);
  background: #fff;
  box-shadow: 0 14px 28px rgba(0, 0, 0, 0.18);
}

.primary-button:hover,
.ghost-button:hover,
.movie-card:hover,
.category-panel:hover,
.category-overview-card:hover,
.rank-item:hover {
  transform: translateY(-4px);
}

.ghost-button {
  color: #fff;
  background: rgba(146, 64, 14, 0.64);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.28);
}

.ghost-button.light {
  background: rgba(255, 255, 255, 0.12);
}

.hero-poster {
  position: relative;
  min-height: 410px;
  border-radius: 30px;
  overflow: hidden;
  box-shadow: 0 30px 70px rgba(0, 0, 0, 0.35);
  transform: rotate(1.5deg);
}

.hero-poster img {
  width: 100%;
  height: 100%;
  min-height: 410px;
  object-fit: cover;
  transition: transform 0.6s ease;
}

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

.hero-poster span {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 54px 24px 24px;
  color: #fff;
  background: linear-gradient(180deg, transparent, rgba(2, 6, 23, 0.86));
  font-size: 22px;
  font-weight: 900;
}

.hero-dots {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 14px;
  margin: 24px 0 18px;
}

.hero-dot {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  padding: 9px;
  color: #fff;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 16px;
  cursor: pointer;
  text-align: left;
}

.hero-dot.active {
  background: rgba(255, 255, 255, 0.24);
  border-color: rgba(255, 255, 255, 0.55);
}

.hero-dot img {
  width: 46px;
  height: 52px;
  border-radius: 10px;
  object-fit: cover;
}

.hero-dot span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 13px;
  font-weight: 700;
}

.hero-search {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  max-width: 680px;
  padding: 10px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.14);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.16);
}

.hero-search input,
.filter-bar input,
.filter-bar select {
  width: 100%;
  min-height: 46px;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  padding: 0 14px;
  outline: none;
  color: var(--slate-800);
  background: #fff;
}

.hero-search button {
  border: 0;
  border-radius: 14px;
  padding: 0 22px;
  color: #fff;
  background: var(--amber-700);
  font-weight: 800;
  cursor: pointer;
}

.hero-category-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}

.category-chip {
  display: inline-flex;
  padding: 9px 14px;
  border-radius: 999px;
  color: #fff;
  background: rgba(255, 255, 255, 0.15);
}

.content-section {
  max-width: 1180px;
  margin: 0 auto;
  padding: 72px 20px;
}

.content-section.no-pad {
  padding-top: 0;
  padding-bottom: 0;
}

.soft-section {
  padding: 72px 0;
  background: linear-gradient(90deg, #f1f5f9, #fffbeb);
}

.dark-section {
  padding: 72px 0;
  color: #fff;
  background: linear-gradient(135deg, #172554, #312e81, #0f172a);
}

.section-heading {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  margin-bottom: 30px;
}

.section-heading > span {
  width: 38px;
  height: 38px;
  flex: 0 0 auto;
  border-radius: 13px;
  background: linear-gradient(135deg, var(--amber-600), var(--rose-600));
  box-shadow: var(--shadow-soft);
}

.section-heading h2 {
  margin: 0;
  font-size: clamp(28px, 4vw, 42px);
  color: inherit;
  letter-spacing: -0.03em;
}

.section-heading p {
  margin: 8px 0 0;
  color: var(--slate-600);
  line-height: 1.7;
}

.dark-section .section-heading p {
  color: #cbd5e1;
}

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

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

.movie-card {
  display: flex;
  flex-direction: column;
  min-width: 0;
  overflow: hidden;
  border-radius: var(--radius);
  background: var(--card);
  box-shadow: var(--shadow-soft);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.movie-card:hover {
  box-shadow: var(--shadow);
}

.poster-wrap {
  position: relative;
  height: 260px;
  overflow: hidden;
  background: var(--slate-100);
}

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

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

.poster-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(2, 6, 23, 0.02), rgba(2, 6, 23, 0.72));
}

.poster-meta {
  position: absolute;
  left: 14px;
  right: 14px;
  bottom: 14px;
  color: #fff;
  font-size: 13px;
  font-weight: 700;
}

.movie-card-body {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: 10px;
  padding: 20px;
}

.movie-card-body strong {
  color: var(--slate-800);
  font-size: 20px;
  line-height: 1.35;
}

.movie-card-body em {
  color: var(--amber-700);
  font-style: normal;
  font-weight: 700;
}

.movie-line {
  color: var(--slate-600);
  line-height: 1.65;
}

.tag-row span {
  color: var(--slate-700);
  background: #f1f5f9;
}

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

.rank-item {
  position: relative;
  display: grid;
  grid-template-columns: 96px minmax(0, 1fr);
  gap: 18px;
  overflow: hidden;
  padding: 16px;
  border-radius: var(--radius);
  background: #fff;
  box-shadow: var(--shadow-soft);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.rank-item:hover {
  box-shadow: var(--shadow);
}

.rank-number {
  position: absolute;
  top: 10px;
  left: 10px;
  z-index: 2;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  background: var(--rose-600);
  font-weight: 900;
}

.rank-item img {
  width: 96px;
  height: 128px;
  border-radius: 14px;
  object-fit: cover;
}

.rank-copy {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-width: 0;
}

.rank-copy strong {
  color: var(--slate-800);
  font-size: 19px;
}

.rank-copy em {
  color: var(--rose-600);
  font-style: normal;
  font-weight: 800;
}

.rank-copy span {
  color: var(--slate-600);
  line-height: 1.55;
}

.category-panel,
.category-overview-card {
  position: relative;
  min-height: 230px;
  overflow: hidden;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-soft);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.category-panel img,
.category-overview-card img {
  width: 100%;
  height: 100%;
  min-height: 230px;
  object-fit: cover;
}

.category-panel::after,
.category-overview-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(2, 6, 23, 0.06), rgba(2, 6, 23, 0.86));
}

.category-panel > span,
.category-card-copy {
  position: absolute;
  z-index: 2;
  left: 22px;
  right: 22px;
  bottom: 22px;
  color: #fff;
}

.category-panel strong,
.category-card-copy strong {
  display: block;
  margin-bottom: 8px;
  font-size: 25px;
  font-weight: 900;
}

.category-panel em,
.category-card-copy em {
  display: block;
  color: #e2e8f0;
  font-style: normal;
  line-height: 1.65;
}

.center-actions {
  justify-content: center;
  margin-top: 34px;
}

.page-hero {
  color: #fff;
  padding: 88px 20px;
  background: linear-gradient(135deg, var(--amber-900), var(--amber-700), #7f1d1d);
}

.page-hero > div {
  max-width: 1180px;
  margin: 0 auto;
}

.page-hero.amber {
  background: linear-gradient(135deg, var(--amber-900), var(--amber-600), #7f1d1d);
}

.page-hero.teal {
  background: linear-gradient(135deg, #064e3b, #0f766e, #0f172a);
}

.page-hero.blue {
  background: linear-gradient(135deg, #1e3a8a, #4338ca, #0f172a);
}

.page-hero.rose {
  background: linear-gradient(135deg, #881337, #be123c, #0f172a);
}

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

.category-overview-card {
  min-height: 280px;
}

.mini-title-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}

.mini-title-row span {
  display: inline-flex;
  max-width: 100%;
  padding: 6px 10px;
  border-radius: 999px;
  overflow: hidden;
  color: #fff;
  background: rgba(255, 255, 255, 0.16);
  white-space: nowrap;
  text-overflow: ellipsis;
}

.filter-bar {
  display: grid;
  grid-template-columns: 1.4fr repeat(4, minmax(130px, 0.7fr));
  gap: 14px;
  margin-bottom: 30px;
  padding: 18px;
  border-radius: var(--radius);
  background: #fff;
  box-shadow: var(--shadow-soft);
}

.local-filter {
  grid-template-columns: 1fr minmax(160px, 0.25fr);
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 9px;
  margin-bottom: 22px;
  color: var(--slate-600);
}

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

.light-breadcrumb,
.light-breadcrumb a {
  color: #ffedd5;
}

.detail-hero {
  position: relative;
  overflow: hidden;
  color: #fff;
  background: #020617;
}

.detail-bg {
  position: absolute;
  inset: 0;
  background-position: center;
  background-size: cover;
  opacity: 0.26;
  filter: blur(5px) saturate(1.1);
  transform: scale(1.05);
}

.detail-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(2, 6, 23, 0.92), rgba(69, 26, 3, 0.78), rgba(2, 6, 23, 0.72));
}

.detail-shell {
  position: relative;
  z-index: 1;
  max-width: 1180px;
  margin: 0 auto;
  padding: 70px 20px;
  display: grid;
  grid-template-columns: 300px minmax(0, 1fr);
  gap: 46px;
  align-items: center;
}

.detail-cover {
  width: 300px;
  height: 430px;
  border-radius: 28px;
  object-fit: cover;
  box-shadow: 0 35px 75px rgba(0, 0, 0, 0.42);
}

.detail-content {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(320px, 0.8fr);
  gap: 30px;
  align-items: start;
}

.player-shell {
  position: relative;
  overflow: hidden;
  border-radius: 28px;
  background: #000;
  box-shadow: var(--shadow);
  aspect-ratio: 16 / 9;
}

.video-core {
  width: 100%;
  height: 100%;
  display: block;
  background: #000;
  object-fit: contain;
}

.player-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  border: 0;
  color: #fff;
  background: linear-gradient(180deg, rgba(2, 6, 23, 0.18), rgba(2, 6, 23, 0.76));
  cursor: pointer;
  transition: opacity 0.22s ease, visibility 0.22s ease;
}

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

.play-orb {
  width: 76px;
  height: 76px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding-left: 5px;
  color: var(--amber-900);
  background: #fff;
  font-size: 30px;
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.34);
}

.player-overlay strong {
  font-size: clamp(20px, 3vw, 34px);
}

.player-overlay em {
  color: var(--amber-100);
  font-style: normal;
  font-weight: 800;
}

.article-card {
  border-radius: 28px;
  padding: 30px;
  background: #fff;
  box-shadow: var(--shadow-soft);
}

.article-card h2 {
  margin: 0 0 14px;
  color: var(--slate-800);
  font-size: 24px;
}

.article-card p {
  margin: 0 0 22px;
  color: var(--slate-700);
  line-height: 1.9;
}

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

.detail-meta-grid span {
  display: flex;
  flex-direction: column;
  gap: 5px;
  padding: 14px;
  border-radius: 16px;
  background: #f8fafc;
  color: var(--slate-700);
}

.detail-meta-grid strong {
  color: var(--amber-700);
}

.tag-row.expanded span {
  margin-bottom: 4px;
}

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

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

.footer-grid {
  max-width: 1180px;
  margin: 0 auto;
  padding: 54px 20px 34px;
  display: grid;
  grid-template-columns: 1.4fr repeat(3, 1fr);
  gap: 28px;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #fff;
  font-size: 22px;
  font-weight: 900;
}

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

.site-footer p {
  line-height: 1.75;
}

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

.site-footer a:hover {
  color: var(--amber-100);
}

.footer-bottom {
  max-width: 1180px;
  margin: 0 auto;
  padding: 22px 20px 34px;
  border-top: 1px solid rgba(148, 163, 184, 0.16);
  display: flex;
  justify-content: space-between;
  gap: 18px;
}

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

.movie-card.hidden-by-filter,
.rank-item.hidden-by-filter {
  display: none;
}

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

  .menu-toggle {
    display: inline-flex;
  }

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

  .hero-slide,
  .detail-shell,
  .detail-content,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .hero-slide {
    position: relative;
    display: none;
    gap: 28px;
  }

  .hero-slide.active {
    display: grid;
  }

  .hero-slider {
    min-height: auto;
  }

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

  .movie-grid,
  .compact-grid,
  .rank-grid,
  .category-grid,
  .category-overview-grid,
  .rank-list-page {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

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

  .detail-cover {
    width: 240px;
    height: 340px;
  }
}

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

  .hero-section,
  .hero-shell {
    min-height: auto;
  }

  .hero-shell {
    padding-top: 48px;
  }

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

  .hero-poster,
  .hero-poster img {
    min-height: 320px;
  }

  .hero-dots,
  .movie-grid,
  .compact-grid,
  .rank-grid,
  .category-grid,
  .category-overview-grid,
  .rank-list-page,
  .filter-bar,
  .local-filter,
  .detail-meta-grid {
    grid-template-columns: 1fr;
  }

  .poster-wrap {
    height: 230px;
  }

  .rank-item {
    grid-template-columns: 82px minmax(0, 1fr);
  }

  .rank-item img {
    width: 82px;
    height: 112px;
  }

  .detail-shell {
    padding: 44px 20px;
  }

  .detail-content,
  .content-section {
    padding: 46px 16px;
  }

  .article-card {
    padding: 22px;
  }

  .footer-bottom {
    flex-direction: column;
  }
}
