:root {
  --stone-950: #0c0a09;
  --stone-925: #14110f;
  --stone-900: #1c1917;
  --stone-850: #241f1b;
  --stone-800: #292524;
  --stone-700: #44403c;
  --stone-500: #78716c;
  --stone-400: #a8a29e;
  --stone-300: #d6d3d1;
  --amber-950: #451a03;
  --amber-900: #78350f;
  --amber-800: #92400e;
  --amber-700: #b45309;
  --amber-600: #d97706;
  --amber-500: #f59e0b;
  --amber-400: #fbbf24;
  --amber-300: #fcd34d;
  --amber-100: #fef3c7;
  --white: #ffffff;
  --shadow: 0 24px 60px rgba(0, 0, 0, 0.35);
  --soft-shadow: 0 14px 35px rgba(0, 0, 0, 0.28);
  --radius: 18px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
  color: var(--stone-300);
  background:
    radial-gradient(circle at 8% 0%, rgba(180, 83, 9, 0.2), transparent 34rem),
    radial-gradient(circle at 92% 8%, rgba(245, 158, 11, 0.12), transparent 32rem),
    var(--stone-950);
  line-height: 1.65;
}

body.is-menu-open {
  overflow: hidden;
}

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

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

button,
input {
  font: inherit;
}

button {
  cursor: pointer;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: linear-gradient(90deg, var(--amber-900), var(--amber-800), var(--amber-900));
  box-shadow: 0 14px 30px rgba(0, 0, 0, 0.25);
}

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

.logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  color: var(--amber-100);
  letter-spacing: 0.02em;
}

.logo-mark {
  width: 34px;
  height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: rgba(254, 243, 199, 0.16);
  color: var(--amber-200, var(--amber-100));
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.16);
}

.logo-text {
  font-size: clamp(20px, 2vw, 26px);
}

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

.nav-link,
.mobile-link {
  color: var(--amber-100);
  font-weight: 700;
  transition: color 0.25s ease, transform 0.25s ease;
}

.nav-link:hover,
.nav-link.is-active,
.mobile-link:hover,
.mobile-link.is-active {
  color: var(--white);
}

.nav-link:hover {
  transform: translateY(-1px);
}

.menu-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.1);
  color: var(--white);
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 5px;
}

.menu-toggle span {
  width: 20px;
  height: 2px;
  background: currentColor;
  border-radius: 999px;
  transition: transform 0.25s ease, opacity 0.25s ease;
}

.menu-toggle.is-active span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.menu-toggle.is-active span:nth-child(2) {
  opacity: 0;
}

.menu-toggle.is-active span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.mobile-nav {
  display: none;
  width: min(1280px, calc(100% - 32px));
  margin: 0 auto;
  padding: 14px 0 20px;
  border-top: 1px solid rgba(254, 243, 199, 0.2);
}

.mobile-link {
  display: block;
  padding: 10px 0;
}

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

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

.hero-carousel {
  position: relative;
  height: min(70vh, 720px);
  min-height: 520px;
  overflow: hidden;
  background: var(--stone-900);
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  pointer-events: none;
  transition: opacity 1s ease;
}

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

.hero-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-gradient {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(0deg, var(--stone-950) 0%, rgba(12, 10, 9, 0.68) 38%, rgba(12, 10, 9, 0.08) 100%),
    linear-gradient(90deg, rgba(12, 10, 9, 0.86) 0%, rgba(12, 10, 9, 0.44) 46%, rgba(12, 10, 9, 0.1) 100%);
}

.hero-content {
  position: absolute;
  left: max(32px, calc((100% - 1280px) / 2 + 16px));
  right: 32px;
  bottom: clamp(72px, 12vh, 140px);
  max-width: 720px;
  z-index: 2;
}

.hero-kicker {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 18px;
  color: var(--amber-300);
  font-size: 18px;
  font-weight: 800;
}

.hero-kicker span {
  padding: 5px 12px;
  border-radius: 999px;
  background: rgba(120, 53, 15, 0.34);
  border: 1px solid rgba(251, 191, 36, 0.28);
  backdrop-filter: blur(8px);
}

.hero-content h1 {
  margin: 0 0 16px;
  font-size: clamp(42px, 7vw, 78px);
  line-height: 1.06;
  color: var(--white);
  text-shadow: 0 12px 34px rgba(0, 0, 0, 0.55);
}

.hero-content p {
  margin: 0 0 28px;
  max-width: 680px;
  color: var(--stone-300);
  font-size: clamp(17px, 2vw, 22px);
}

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

.primary-btn,
.ghost-btn,
.small-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  font-weight: 800;
  transition: transform 0.25s ease, background 0.25s ease, color 0.25s ease, border-color 0.25s ease;
}

.primary-btn {
  min-height: 48px;
  padding: 0 28px;
  color: var(--white);
  background: var(--amber-600);
  box-shadow: 0 12px 32px rgba(217, 119, 6, 0.32);
}

.primary-btn:hover {
  transform: translateY(-2px);
  background: var(--amber-700);
}

.ghost-btn {
  min-height: 48px;
  padding: 0 26px;
  color: var(--amber-100);
  border: 1px solid rgba(254, 243, 199, 0.36);
  background: rgba(0, 0, 0, 0.28);
  backdrop-filter: blur(10px);
}

.ghost-btn:hover {
  color: var(--white);
  border-color: var(--amber-300);
  transform: translateY(-2px);
}

.hero-arrow {
  position: absolute;
  top: 50%;
  z-index: 3;
  width: 50px;
  height: 50px;
  border: 0;
  border-radius: 999px;
  color: var(--white);
  background: rgba(0, 0, 0, 0.48);
  font-size: 42px;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  transform: translateY(-50%);
  transition: background 0.25s ease, transform 0.25s ease;
}

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

.hero-prev {
  left: 18px;
}

.hero-next {
  right: 18px;
}

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

.hero-dot {
  width: 12px;
  height: 12px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.55);
  transition: width 0.25s ease, background 0.25s ease;
}

.hero-dot.is-active {
  width: 34px;
  background: var(--amber-500);
}

.content-section {
  margin: 56px 0 72px;
}

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

.section-heading h2 {
  margin: 0;
  color: var(--amber-100);
  font-size: clamp(28px, 3vw, 38px);
  line-height: 1.2;
}

.section-heading p {
  margin: 8px 0 0;
  color: var(--stone-400);
}

.section-more {
  color: var(--amber-300);
  font-weight: 800;
  white-space: nowrap;
}

.movie-rail {
  display: flex;
  gap: 18px;
  margin: 0 -16px;
  padding: 0 16px 18px;
  overflow-x: auto;
  scroll-snap-type: x proximity;
}

.rail-item {
  width: 250px;
  flex: 0 0 250px;
  scroll-snap-align: start;
}

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

.movie-card {
  display: block;
  overflow: hidden;
  color: inherit;
  background: var(--stone-800);
  border-radius: 16px;
  box-shadow: var(--soft-shadow);
  transition: transform 0.28s ease, box-shadow 0.28s ease, background 0.28s ease;
}

.movie-card:hover {
  transform: translateY(-5px);
  background: #302b29;
  box-shadow: var(--shadow);
}

.poster-wrap {
  position: relative;
  display: block;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  background: var(--stone-900);
}

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

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

.movie-badge {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 2;
  padding: 4px 9px;
  color: var(--white);
  font-size: 12px;
  font-weight: 900;
  border-radius: 8px;
  background: var(--amber-600);
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.32);
}

.poster-shade {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: flex-end;
  padding: 12px;
  opacity: 0;
  color: var(--stone-200, #e7e5e4);
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.86), rgba(0, 0, 0, 0.1));
  transition: opacity 0.28s ease;
}

.poster-shade span {
  display: -webkit-box;
  overflow: hidden;
  font-size: 13px;
  line-height: 1.5;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
}

.movie-card:hover .poster-shade {
  opacity: 1;
}

.card-body {
  display: block;
  padding: 14px;
}

.card-body strong {
  display: block;
  overflow: hidden;
  color: var(--stone-100, #f5f5f4);
  font-size: 17px;
  line-height: 1.4;
  white-space: nowrap;
  text-overflow: ellipsis;
  transition: color 0.25s ease;
}

.movie-card:hover .card-body strong {
  color: var(--amber-300);
}

.card-meta {
  display: block;
  margin-top: 4px;
  color: var(--stone-400);
  font-size: 13px;
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 9px;
}

.tag-row span {
  display: inline-flex;
  align-items: center;
  max-width: 100%;
  padding: 3px 8px;
  overflow: hidden;
  color: var(--amber-300);
  font-size: 12px;
  line-height: 1.4;
  white-space: nowrap;
  text-overflow: ellipsis;
  border-radius: 999px;
  background: rgba(120, 53, 15, 0.22);
}

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

.category-tile,
.overview-card {
  display: block;
  padding: 24px;
  min-height: 190px;
  color: var(--stone-300);
  border: 1px solid rgba(251, 191, 36, 0.12);
  border-radius: var(--radius);
  background: linear-gradient(135deg, rgba(120, 53, 15, 0.26), rgba(41, 37, 36, 0.94));
  box-shadow: var(--soft-shadow);
  transition: transform 0.25s ease, border-color 0.25s ease, background 0.25s ease;
}

.category-tile:hover,
.overview-card:hover {
  transform: translateY(-4px);
  border-color: rgba(251, 191, 36, 0.42);
  background: linear-gradient(135deg, rgba(146, 64, 14, 0.42), rgba(41, 37, 36, 0.98));
}

.category-tile strong,
.overview-card h2 {
  display: block;
  margin: 0 0 10px;
  color: var(--amber-100);
  font-size: 23px;
}

.category-tile p,
.overview-card p {
  margin: 0;
  color: var(--stone-400);
}

.category-preview,
.overview-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 18px;
}

.category-preview span,
.overview-links a {
  max-width: 100%;
  padding: 5px 10px;
  overflow: hidden;
  color: var(--amber-300);
  font-size: 12px;
  white-space: nowrap;
  text-overflow: ellipsis;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.22);
}

.two-column-section {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
}

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

.rank-item,
.list-card {
  display: grid;
  grid-template-columns: auto 82px minmax(0, 1fr);
  gap: 14px;
  align-items: center;
  padding: 12px;
  overflow: hidden;
  color: inherit;
  border-radius: 16px;
  background: var(--stone-900);
  transition: transform 0.25s ease, background 0.25s ease;
}

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

.rank-item:hover,
.list-card:hover {
  transform: translateX(4px);
  background: var(--stone-800);
}

.rank-number {
  width: 38px;
  height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
  font-weight: 900;
  border-radius: 12px;
  background: var(--amber-600);
}

.rank-item img,
.list-card img {
  width: 82px;
  aspect-ratio: 3 / 4;
  height: auto;
  object-fit: cover;
  border-radius: 12px;
  background: var(--stone-800);
}

.rank-info,
.list-card-body {
  display: block;
  min-width: 0;
}

.rank-info strong,
.list-card-body strong {
  display: block;
  overflow: hidden;
  color: var(--stone-100, #f5f5f4);
  font-size: 17px;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.rank-info em,
.list-card-body em {
  display: -webkit-box;
  overflow: hidden;
  margin: 3px 0;
  color: var(--stone-400);
  font-size: 13px;
  font-style: normal;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.rank-info span,
.list-card-body > span:not(.tag-row) {
  color: var(--stone-500);
  font-size: 12px;
}

.page-hero,
.detail-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 28px;
  align-items: center;
  margin-bottom: 36px;
  padding: 32px;
  border: 1px solid rgba(251, 191, 36, 0.12);
  border-radius: 26px;
  background:
    linear-gradient(135deg, rgba(120, 53, 15, 0.28), rgba(28, 25, 23, 0.94)),
    var(--stone-900);
  box-shadow: var(--shadow);
}

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

.eyebrow {
  display: inline-flex;
  margin-bottom: 10px;
  color: var(--amber-300);
  font-weight: 900;
}

.page-hero h1,
.detail-side h1 {
  margin: 0;
  color: var(--white);
  font-size: clamp(34px, 4vw, 56px);
  line-height: 1.12;
}

.page-hero p,
.detail-side p {
  max-width: 760px;
  margin: 14px 0 0;
  color: var(--stone-300);
  font-size: 17px;
}

.inline-search,
.site-search {
  display: flex;
  gap: 10px;
  align-items: center;
}

.inline-search input,
.site-search input {
  width: 100%;
  min-height: 48px;
  padding: 0 16px;
  color: var(--stone-100, #f5f5f4);
  border: 1px solid rgba(251, 191, 36, 0.16);
  border-radius: 14px;
  outline: none;
  background: rgba(12, 10, 9, 0.72);
}

.site-search button {
  min-height: 48px;
  padding: 0 22px;
  color: var(--white);
  border: 0;
  border-radius: 14px;
  background: var(--amber-600);
  font-weight: 900;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  margin-bottom: 20px;
  color: var(--stone-400);
  font-size: 14px;
}

.breadcrumb a {
  color: var(--amber-300);
}

.breadcrumb strong {
  color: var(--stone-300);
}

.overview-card {
  min-height: 240px;
}

.overview-card h2 a {
  color: var(--amber-100);
}

.small-btn {
  margin-top: 20px;
  min-height: 40px;
  padding: 0 16px;
  color: var(--white);
  background: var(--amber-600);
}

.ranking-page {
  margin-bottom: 56px;
}

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

.detail-main {
  width: min(1320px, calc(100% - 32px));
}

.detail-hero {
  grid-template-columns: minmax(0, 1.4fr) minmax(340px, 0.6fr);
  align-items: stretch;
}

.player-shell {
  position: relative;
  overflow: hidden;
  min-height: 420px;
  aspect-ratio: 16 / 9;
  border-radius: 22px;
  background: var(--stone-950);
  box-shadow: var(--shadow);
}

.player-shell video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  background: #000000;
}

.play-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  color: var(--white);
  border: 0;
  background: linear-gradient(0deg, rgba(12, 10, 9, 0.62), rgba(12, 10, 9, 0.28));
  font-size: 18px;
  font-weight: 900;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

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

.play-icon {
  width: 82px;
  height: 82px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding-left: 6px;
  border-radius: 999px;
  color: var(--white);
  background: var(--amber-600);
  box-shadow: 0 0 0 12px rgba(217, 119, 6, 0.18), 0 20px 50px rgba(0, 0, 0, 0.4);
}

.detail-side {
  display: grid;
  grid-template-columns: 156px minmax(0, 1fr);
  gap: 18px;
  align-items: start;
}

.detail-side img {
  width: 156px;
  aspect-ratio: 3 / 4;
  height: auto;
  object-fit: cover;
  border-radius: 18px;
  background: var(--stone-800);
  box-shadow: var(--soft-shadow);
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin-top: 14px;
}

.detail-meta span {
  padding: 5px 10px;
  color: var(--stone-300);
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.22);
}

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

.detail-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 22px;
  margin: 28px 0 56px;
}

.story-panel {
  padding: 28px;
  border-radius: 22px;
  background: var(--stone-900);
  box-shadow: var(--soft-shadow);
}

.story-panel h2 {
  margin: 0 0 14px;
  color: var(--amber-100);
  font-size: 26px;
}

.story-panel p {
  margin: 0;
  color: var(--stone-300);
  font-size: 16px;
}

.site-footer {
  margin-top: 72px;
  color: var(--stone-400);
  background: linear-gradient(180deg, var(--stone-900), var(--stone-950));
}

.footer-inner {
  width: min(1280px, calc(100% - 32px));
  margin: 0 auto;
  padding: 44px 0 26px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.3fr 1fr 1fr;
  gap: 34px;
}

.footer-grid h3,
.footer-grid h4 {
  margin: 0 0 14px;
  color: var(--amber-200, var(--amber-100));
}

.footer-grid p {
  margin: 0;
}

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

.footer-grid li + li {
  margin-top: 8px;
}

.footer-grid a:hover {
  color: var(--amber-300);
}

.footer-bottom {
  margin-top: 32px;
  padding-top: 22px;
  border-top: 1px solid rgba(120, 113, 108, 0.25);
}

.footer-bottom p {
  margin: 0;
  color: var(--stone-500);
}

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

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

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

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

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

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

  .hero-carousel {
    height: 620px;
    min-height: 620px;
  }

  .hero-content {
    left: 24px;
    right: 24px;
  }

  .hero-arrow {
    display: none;
  }

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

  .two-column-section,
  .detail-hero,
  .detail-content,
  .footer-grid,
  .page-hero {
    grid-template-columns: 1fr;
  }

  .large-rank-list {
    grid-template-columns: 1fr;
  }

  .detail-side {
    grid-template-columns: 130px minmax(0, 1fr);
  }

  .detail-side img {
    width: 130px;
  }
}

@media (max-width: 760px) {
  .main-shell,
  .detail-main,
  .header-inner,
  .mobile-nav,
  .footer-inner {
    width: min(100% - 24px, 1280px);
  }

  .hero-carousel {
    height: 560px;
    min-height: 560px;
  }

  .hero-content {
    bottom: 72px;
  }

  .hero-kicker {
    font-size: 14px;
  }

  .hero-content p {
    display: -webkit-box;
    overflow: hidden;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
  }

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

  .category-grid,
  .overview-grid {
    grid-template-columns: 1fr;
  }

  .section-heading {
    display: block;
  }

  .section-more {
    display: inline-flex;
    margin-top: 10px;
  }

  .rank-item {
    grid-template-columns: 34px 72px minmax(0, 1fr);
    gap: 10px;
  }

  .list-card {
    grid-template-columns: 72px minmax(0, 1fr);
  }

  .rank-item img,
  .list-card img {
    width: 72px;
  }

  .page-hero,
  .detail-hero {
    padding: 20px;
    border-radius: 20px;
  }

  .player-shell {
    min-height: 230px;
  }

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

  .detail-side img {
    width: 150px;
  }

  .inline-search,
  .site-search {
    display: grid;
  }
}
