:root {
  --bg: #f7f8fb;
  --surface: #ffffff;
  --text: #111827;
  --muted: #6b7280;
  --soft: #f3f4f6;
  --line: #e5e7eb;
  --amber: #d97706;
  --amber-dark: #b45309;
  --orange: #ea580c;
  --red: #dc2626;
  --shadow: 0 18px 45px rgba(17, 24, 39, .12);
  --shadow-soft: 0 10px 30px rgba(17, 24, 39, .08);
  --radius: 18px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background: linear-gradient(180deg, #f9fafb 0%, #eef2f7 100%);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
}

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

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

button,
input {
  font: inherit;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 80;
  color: #ffffff;
  background: linear-gradient(90deg, var(--amber), var(--orange), var(--red));
  box-shadow: 0 8px 25px rgba(180, 83, 9, .28);
}

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

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 25px;
  font-weight: 800;
  letter-spacing: .02em;
  white-space: nowrap;
}

.brand-mark {
  width: 36px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: rgba(255, 255, 255, .2);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .25);
  font-size: 15px;
}

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

.nav-link {
  padding: 9px 0;
  font-weight: 700;
  opacity: .94;
  transition: opacity .2s ease, transform .2s ease;
}

.nav-link:hover,
.nav-link.is-active {
  opacity: 1;
  transform: translateY(-1px);
}

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

.menu-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  margin: 5px auto;
  background: #fff;
  border-radius: 999px;
}

.mobile-nav {
  display: none;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 0 0 14px;
}

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

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

.hero {
  position: relative;
  height: 520px;
  overflow: hidden;
  background: #111827;
}

.hero-slide {
  position: absolute;
  inset: 0;
  z-index: 0;
  opacity: 0;
  pointer-events: none;
  background-position: center;
  background-size: cover;
  transition: opacity 900ms ease;
}

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

.hero-content {
  position: absolute;
  left: 50%;
  bottom: 52px;
  width: min(1180px, calc(100% - 32px));
  transform: translateX(-50%);
  color: #fff;
}

.hero-content h1,
.hero-content h2 {
  max-width: 760px;
  margin: 0 0 16px;
  font-size: clamp(32px, 6vw, 58px);
  line-height: 1.05;
  letter-spacing: -.03em;
  text-shadow: 0 8px 24px rgba(0, 0, 0, .35);
}

.hero-content h2 {
  font-size: clamp(28px, 5vw, 48px);
}

.hero-content p {
  max-width: 720px;
  margin: 0 0 18px;
  color: rgba(255, 255, 255, .9);
  font-size: clamp(16px, 2.4vw, 21px);
  line-height: 1.7;
}

.hero-meta,
.detail-meta,
.card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.hero-meta span,
.detail-meta span {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 5px 11px;
  border-radius: 999px;
  background: rgba(255, 255, 255, .16);
  color: rgba(255, 255, 255, .92);
  backdrop-filter: blur(10px);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 24px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 20px;
  border-radius: 999px;
  border: 1px solid transparent;
  font-weight: 800;
  transition: transform .2s ease, box-shadow .2s ease, background .2s ease;
}

.btn:hover {
  transform: translateY(-2px);
}

.btn-primary {
  color: #fff;
  background: linear-gradient(90deg, var(--amber), var(--orange));
  box-shadow: 0 12px 28px rgba(217, 119, 6, .32);
}

.btn-ghost {
  color: #fff;
  border-color: rgba(255, 255, 255, .45);
  background: rgba(0, 0, 0, .22);
}

.btn-soft {
  color: #78350f;
  background: #fef3c7;
}

.full-btn {
  width: 100%;
}

.hero-control {
  position: absolute;
  top: 50%;
  z-index: 5;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 50%;
  color: #fff;
  background: rgba(0, 0, 0, .45);
  font-size: 34px;
  cursor: pointer;
  transform: translateY(-50%);
  transition: background .2s ease, transform .2s ease;
}

.hero-control:hover {
  background: rgba(0, 0, 0, .68);
  transform: translateY(-50%) scale(1.05);
}

.hero-prev {
  left: 22px;
}

.hero-next {
  right: 22px;
}

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

.hero-dot {
  width: 9px;
  height: 9px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, .55);
  cursor: pointer;
  transition: width .25s ease, background .25s ease;
}

.hero-dot.is-active {
  width: 32px;
  background: #fff;
}

.intro-copy {
  margin-top: 34px;
  padding: 28px;
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow-soft);
}

.intro-copy h2,
.page-hero h1,
.section-heading h2,
.ranking-box h2,
.detail-article h2,
.detail-side h2,
.player-section h2 {
  margin: 0 0 12px;
  color: #111827;
  font-weight: 850;
  letter-spacing: -.02em;
}

.intro-copy p,
.page-hero p,
.section-heading p,
.category-overview-card p,
.detail-article p,
.site-footer p {
  margin: 0;
  color: var(--muted);
  line-height: 1.8;
}

.content-section {
  margin-top: 56px;
}

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

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

.section-link {
  color: var(--amber-dark);
  font-weight: 800;
}

.rail {
  display: flex;
  gap: 22px;
  padding: 4px 2px 18px;
  overflow-x: auto;
  scroll-snap-type: x proximity;
}

.rail .movie-card {
  width: 260px;
  flex: 0 0 260px;
  scroll-snap-align: start;
}

.card-grid {
  display: grid;
  gap: 22px;
}

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

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

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

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

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

.movie-card {
  min-width: 0;
}

.card-link {
  display: block;
  height: 100%;
  overflow: hidden;
  border-radius: 16px;
  background: #fff;
  box-shadow: var(--shadow-soft);
  transition: transform .24s ease, box-shadow .24s ease;
}

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

.poster-frame {
  position: relative;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  background: radial-gradient(circle at 30% 20%, #fde68a, #d97706 42%, #7c2d12 100%);
}

.movie-card-compact .poster-frame {
  aspect-ratio: 2 / 2.65;
}

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

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

.play-glow {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 42px;
  background: rgba(0, 0, 0, 0);
  opacity: 0;
  transition: opacity .25s ease, background .25s ease;
}

.card-link:hover .play-glow {
  opacity: 1;
  background: rgba(0, 0, 0, .32);
}

.rank-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  min-width: 32px;
  height: 32px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 8px;
  border-radius: 999px;
  color: #fff;
  background: linear-gradient(135deg, var(--red), var(--orange));
  font-weight: 900;
  box-shadow: 0 8px 20px rgba(220, 38, 38, .35);
}

.card-body {
  padding: 14px;
}

.card-body h3 {
  margin: 0 0 7px;
  overflow: hidden;
  color: #111827;
  font-size: 16px;
  font-weight: 850;
  line-height: 1.35;
  text-overflow: ellipsis;
  white-space: nowrap;
  transition: color .2s ease;
}

.card-link:hover h3 {
  color: var(--amber-dark);
}

.card-body p {
  min-height: 44px;
  margin: 0 0 12px;
  display: -webkit-box;
  overflow: hidden;
  color: #6b7280;
  font-size: 13px;
  line-height: 1.65;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.card-meta {
  gap: 5px;
  color: #6b7280;
  font-size: 12px;
}

.card-meta span:not(:last-child)::after {
  content: "•";
  margin-left: 5px;
  color: #d1d5db;
}

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

.tag {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 2px 8px;
  border-radius: 999px;
  color: #92400e;
  background: #fef3c7;
  font-size: 12px;
  font-weight: 700;
}

.tag-row {
  margin-top: 10px;
}

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

.category-panels {
  display: grid;
  gap: 28px;
}

.category-panel:not(:last-child) {
  padding-bottom: 28px;
  border-bottom: 1px solid var(--line);
}

.mini-heading,
.category-overview-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 16px;
}

.mini-heading h3,
.category-overview-head h2 {
  margin: 0;
  padding-left: 13px;
  border-left: 4px solid var(--amber);
  color: #1f2937;
  font-size: 22px;
}

.mini-heading a,
.category-overview-head a {
  color: var(--amber-dark);
  font-weight: 800;
}

.split-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 32px;
  align-items: start;
}

.ranking-box {
  position: sticky;
  top: 96px;
  padding: 24px;
  border-radius: 22px;
  background: #111827;
  color: #fff;
  box-shadow: var(--shadow);
}

.ranking-box h2 {
  color: #fff;
}

.ranking-box ol {
  margin: 0 0 20px;
  padding: 0;
  list-style: none;
}

.ranking-box li + li {
  border-top: 1px solid rgba(255, 255, 255, .08);
}

.ranking-box a:not(.btn) {
  display: grid;
  grid-template-columns: 32px 1fr auto;
  gap: 10px;
  align-items: center;
  padding: 12px 0;
  color: #e5e7eb;
  font-weight: 700;
}

.ranking-box span {
  color: #fbbf24;
  font-weight: 900;
}

.ranking-box em {
  color: #fcd34d;
  font-size: 12px;
  font-style: normal;
}

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

.page-hero {
  margin-bottom: 28px;
  padding: 36px;
  border-radius: 26px;
  background: linear-gradient(135deg, #fff7ed 0%, #ffffff 45%, #fef3c7 100%);
  box-shadow: var(--shadow-soft);
}

.page-hero h1 {
  font-size: clamp(30px, 5vw, 48px);
}

.keyword-row {
  margin-top: 18px;
}

.keyword-row span {
  padding: 7px 12px;
  border-radius: 999px;
  color: #78350f;
  background: #ffedd5;
  font-weight: 800;
}

.toolbar {
  margin: 24px 0 28px;
  padding: 18px;
  border-radius: 20px;
  background: #fff;
  box-shadow: var(--shadow-soft);
}

.search-box input {
  width: 100%;
  min-height: 48px;
  padding: 0 16px;
  border: 1px solid var(--line);
  border-radius: 14px;
  outline: none;
  color: #111827;
  background: #f9fafb;
  transition: border-color .2s ease, box-shadow .2s ease;
}

.search-box input:focus {
  border-color: #f59e0b;
  box-shadow: 0 0 0 4px rgba(245, 158, 11, .14);
}

.filter-row {
  margin-top: 14px;
}

.filter-chip {
  min-height: 36px;
  padding: 0 13px;
  border: 1px solid #fed7aa;
  border-radius: 999px;
  color: #92400e;
  background: #fff7ed;
  cursor: pointer;
  font-weight: 800;
  transition: background .2s ease, color .2s ease, transform .2s ease;
}

.filter-chip:hover,
.filter-chip.is-active {
  color: #fff;
  background: var(--amber);
  transform: translateY(-1px);
}

.category-overview {
  display: grid;
  gap: 26px;
}

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

.category-overview-card p {
  margin-bottom: 18px;
}

.empty-state {
  margin: 40px 0;
  padding: 28px;
  border-radius: 18px;
  color: #92400e;
  background: #fef3c7;
  text-align: center;
  font-weight: 800;
}

.detail-main {
  background: linear-gradient(180deg, #111827 0, #111827 620px, #f7f8fb 620px, #eef2f7 100%);
}

.detail-hero {
  min-height: 560px;
  display: flex;
  align-items: flex-end;
  background-position: center;
  background-size: cover;
  color: #fff;
}

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

.detail-poster {
  overflow: hidden;
  border-radius: 22px;
  box-shadow: 0 28px 60px rgba(0, 0, 0, .38);
  background: #111827;
}

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

.eyebrow {
  margin: 0 0 12px;
  color: #fcd34d;
  font-weight: 900;
  letter-spacing: .12em;
}

.detail-headline h1 {
  margin: 0 0 18px;
  font-size: clamp(34px, 6vw, 62px);
  line-height: 1.05;
  letter-spacing: -.035em;
}

.detail-one-line {
  max-width: 820px;
  margin: 0 0 18px;
  color: rgba(255, 255, 255, .88);
  font-size: 19px;
  line-height: 1.75;
}

.detail-tags {
  margin: 18px 0 24px;
}

.detail-tags a {
  padding: 6px 11px;
  border-radius: 999px;
  color: #fff;
  background: rgba(255, 255, 255, .16);
  font-size: 13px;
  font-weight: 800;
  backdrop-filter: blur(12px);
}

.player-section {
  margin-top: 34px;
  padding: 30px;
  border-radius: 26px;
  background: #fff;
  box-shadow: var(--shadow);
}

.player-stage {
  position: relative;
  overflow: hidden;
  border-radius: 22px;
  background: #000;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .05);
}

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

.player-cover {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  border: 0;
  color: #fff;
  background: linear-gradient(180deg, rgba(0, 0, 0, .15), rgba(0, 0, 0, .78));
  cursor: pointer;
  transition: opacity .24s ease, transform .24s ease;
}

.player-cover:hover {
  transform: scale(1.01);
}

.player-stage.is-playing .player-cover {
  opacity: 0;
  pointer-events: none;
}

.player-button {
  width: 74px;
  height: 74px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--amber), var(--orange));
  box-shadow: 0 18px 40px rgba(217, 119, 6, .4);
  font-size: 30px;
}

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

.player-cover em {
  color: #fcd34d;
  font-style: normal;
  font-weight: 800;
}

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

.detail-article,
.detail-side {
  padding: 28px;
  border-radius: 24px;
  background: #fff;
  box-shadow: var(--shadow-soft);
}

.detail-article h2 + p {
  margin-bottom: 24px;
}

.detail-side dl {
  display: grid;
  grid-template-columns: 72px 1fr;
  gap: 10px 14px;
  margin: 0 0 20px;
}

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

.detail-side dd {
  margin: 0;
  color: #111827;
  font-weight: 700;
}

.side-link {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  border-radius: 14px;
  color: #92400e;
  background: #fef3c7;
  font-weight: 900;
}

.site-footer {
  margin-top: 70px;
  color: #d1d5db;
  background: #111827;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.2fr .8fr .8fr;
  gap: 34px;
  padding: 44px 0;
}

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

.site-footer ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.site-footer li + li {
  margin-top: 9px;
}

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

.footer-bottom {
  padding: 18px;
  border-top: 1px solid rgba(255, 255, 255, .08);
  color: #9ca3af;
  text-align: center;
}

.back-top {
  position: fixed;
  right: 22px;
  bottom: 22px;
  z-index: 60;
  width: 46px;
  height: 46px;
  display: none;
  border: 0;
  border-radius: 50%;
  color: #fff;
  background: var(--amber);
  box-shadow: var(--shadow-soft);
  cursor: pointer;
  font-size: 22px;
}

.back-top.is-visible {
  display: block;
}

@media (max-width: 1120px) {
  .six-grid,
  .five-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

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

  .ranking-box {
    position: static;
  }
}

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

  .menu-toggle {
    display: block;
  }

  .hero {
    height: 560px;
  }

  .hero-content {
    bottom: 48px;
  }

  .hero-control {
    display: none;
  }

  .four-grid,
  .six-grid,
  .five-grid,
  .small-grid,
  .preview-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

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

  .detail-hero-inner {
    grid-template-columns: 1fr;
  }

  .detail-poster {
    width: min(230px, 72vw);
  }

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

@media (max-width: 560px) {
  .container,
  .nav-wrap,
  .mobile-nav,
  .hero-content {
    width: min(100% - 24px, 1180px);
  }

  .brand {
    font-size: 21px;
  }

  .hero {
    height: 610px;
  }

  .hero-actions,
  .detail-meta {
    align-items: stretch;
    flex-direction: column;
  }

  .btn {
    width: 100%;
  }

  .page-hero,
  .intro-copy,
  .highlight-box,
  .player-section,
  .detail-article,
  .detail-side,
  .category-overview-card {
    padding: 20px;
    border-radius: 20px;
  }

  .four-grid,
  .six-grid,
  .five-grid,
  .small-grid,
  .preview-grid {
    grid-template-columns: 1fr 1fr;
    gap: 14px;
  }

  .card-body {
    padding: 12px;
  }

  .card-body p {
    min-height: 40px;
    font-size: 12px;
  }
}
