:root {
  --amber-950: #451a03;
  --amber-900: #78350f;
  --amber-800: #92400e;
  --amber-700: #b45309;
  --amber-600: #d97706;
  --orange-600: #ea580c;
  --orange-500: #f97316;
  --stone-950: #1c1917;
  --stone-800: #292524;
  --stone-700: #44403c;
  --stone-100: #f5f5f4;
  --amber-50: #fffbeb;
  --amber-100: #fef3c7;
  --white: #ffffff;
  --shadow: 0 18px 45px rgba(120, 53, 15, 0.12);
  --shadow-strong: 0 26px 70px rgba(69, 26, 3, 0.24);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--stone-800);
  background: linear-gradient(135deg, var(--amber-50), #fff7ed 42%, #fffaf0);
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

body.menu-open {
  overflow: hidden;
}

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;
  border-bottom: 1px solid rgba(180, 83, 9, 0.12);
  background: rgba(255, 251, 235, 0.9);
  backdrop-filter: blur(18px);
}

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

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

.logo-mark {
  width: 40px;
  height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
  border-radius: 14px;
  background: linear-gradient(135deg, var(--amber-700), var(--orange-500));
  box-shadow: 0 12px 26px rgba(217, 119, 6, 0.25);
}

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

.nav-links a {
  padding: 10px 15px;
  color: var(--amber-900);
  border-radius: 999px;
  font-size: 15px;
  font-weight: 700;
  transition: color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--white);
  background: linear-gradient(135deg, var(--amber-700), var(--orange-500));
  transform: translateY(-1px);
}

.menu-toggle {
  display: none;
  width: 44px;
  height: 44px;
  padding: 10px;
  border: 0;
  border-radius: 14px;
  background: var(--amber-100);
}

.menu-toggle span {
  display: block;
  height: 2px;
  margin: 5px 0;
  background: var(--amber-900);
}

.hero {
  padding: 28px 0 18px;
}

.hero-shell {
  position: relative;
  width: min(1180px, calc(100% - 32px));
  min-height: 560px;
  margin: 0 auto;
  overflow: hidden;
  border-radius: 36px;
  box-shadow: var(--shadow-strong);
  background: var(--amber-900);
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.55s ease, visibility 0.55s ease;
}

.hero-slide.active {
  opacity: 1;
  visibility: visible;
}

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

.hero-overlay {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 80% 20%, rgba(251, 191, 36, 0.32), transparent 30%),
    linear-gradient(90deg, rgba(69, 26, 3, 0.95), rgba(120, 53, 15, 0.78) 48%, rgba(0, 0, 0, 0.22));
}

.hero-content {
  position: relative;
  z-index: 2;
  min-height: 560px;
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(240px, 0.65fr);
  gap: 36px;
  align-items: center;
  padding: 56px;
}

.hero-text {
  color: var(--white);
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--orange-500);
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.hero-text .eyebrow,
.dark-panel .eyebrow,
.inner-hero .eyebrow {
  color: #fde68a;
}

.hero h1,
.inner-hero h1,
.detail-intro h1 {
  margin: 0;
  color: inherit;
  font-size: clamp(34px, 5vw, 60px);
  line-height: 1.08;
  font-weight: 950;
  letter-spacing: -0.04em;
}

.hero h2 {
  margin: 18px 0 12px;
  color: #fed7aa;
  font-size: clamp(24px, 3.5vw, 42px);
  font-weight: 900;
}

.hero-summary {
  max-width: 680px;
  margin: 0 0 20px;
  color: rgba(255, 255, 255, 0.88);
  font-size: 18px;
  line-height: 1.8;
}

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

.hero-tags span,
.tag-list span {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 5px 10px;
  color: var(--amber-900);
  border-radius: 999px;
  background: #fef3c7;
  font-size: 12px;
  font-weight: 800;
}

.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 18px;
  border-radius: 999px;
  font-weight: 900;
  border: 1px solid rgba(255, 255, 255, 0.18);
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 30px rgba(69, 26, 3, 0.18);
}

.btn.primary {
  color: var(--white);
  background: linear-gradient(135deg, var(--amber-700), var(--orange-500));
}

.btn.glass {
  color: var(--white);
  background: rgba(255, 255, 255, 0.16);
  backdrop-filter: blur(8px);
}

.btn.ghost {
  color: var(--white);
  background: rgba(69, 26, 3, 0.2);
}

.btn.dark {
  color: var(--amber-900);
  border-color: rgba(180, 83, 9, 0.22);
  background: rgba(254, 243, 199, 0.7);
}

.hero-poster {
  position: relative;
  overflow: hidden;
  border-radius: 28px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.34);
  background: rgba(255, 255, 255, 0.12);
}

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

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

.hero-poster span {
  position: absolute;
  left: 16px;
  right: 16px;
  bottom: 16px;
  padding: 10px 12px;
  color: var(--white);
  border-radius: 16px;
  background: rgba(69, 26, 3, 0.68);
  text-align: center;
  font-weight: 900;
  backdrop-filter: blur(8px);
}

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

.hero-controls button {
  width: 38px;
  height: 8px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.38);
  cursor: pointer;
}

.hero-controls button.active {
  background: #fbbf24;
}

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

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

.section-head h2 {
  margin: 0;
  color: var(--amber-950);
  font-size: clamp(24px, 3vw, 36px);
  font-weight: 950;
  letter-spacing: -0.03em;
}

.text-link {
  color: var(--amber-700);
  font-weight: 900;
}

.search-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 180px;
  gap: 12px;
  padding: 18px;
  border: 1px solid rgba(180, 83, 9, 0.12);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.75);
  box-shadow: var(--shadow);
}

.search-panel.wide {
  grid-template-columns: minmax(0, 1fr) 220px;
}

.movie-search,
.movie-filter {
  width: 100%;
  height: 50px;
  border: 1px solid rgba(180, 83, 9, 0.16);
  border-radius: 16px;
  color: var(--amber-950);
  background: var(--white);
  outline: none;
}

.movie-search {
  padding: 0 18px;
}

.movie-filter {
  padding: 0 14px;
}

.movie-search:focus,
.movie-filter:focus {
  border-color: var(--orange-500);
  box-shadow: 0 0 0 4px rgba(249, 115, 22, 0.12);
}

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

.category-pill,
.category-card {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-height: 132px;
  padding: 20px;
  border: 1px solid rgba(180, 83, 9, 0.12);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.82);
  box-shadow: var(--shadow);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.category-pill:hover,
.category-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 24px 60px rgba(180, 83, 9, 0.18);
}

.category-pill strong,
.category-title {
  color: var(--amber-900);
  font-size: 20px;
  font-weight: 950;
}

.category-pill span,
.category-card p {
  color: #6b5a4a;
  line-height: 1.7;
}

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

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

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

.movie-card {
  overflow: hidden;
  border: 1px solid rgba(180, 83, 9, 0.12);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: var(--shadow);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.movie-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 24px 55px rgba(120, 53, 15, 0.2);
}

.poster-link {
  position: relative;
  display: block;
  overflow: hidden;
  background: #fef3c7;
}

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

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

.poster-badge {
  position: absolute;
  left: 10px;
  top: 10px;
  padding: 4px 8px;
  color: var(--white);
  border-radius: 999px;
  background: rgba(120, 53, 15, 0.78);
  font-size: 12px;
  font-weight: 900;
  backdrop-filter: blur(8px);
}

.movie-info {
  padding: 14px;
}

.movie-meta {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 8px;
  color: var(--orange-600);
  font-size: 12px;
  font-weight: 900;
}

.movie-card h3 {
  min-height: 48px;
  margin: 0 0 8px;
  color: var(--amber-950);
  font-size: 16px;
  line-height: 1.5;
  font-weight: 950;
}

.movie-card h3 a:hover {
  color: var(--orange-600);
}

.movie-card p {
  min-height: 48px;
  margin: 0 0 12px;
  color: #685a4b;
  font-size: 13px;
  line-height: 1.65;
}

.movie-card.compact h3 {
  min-height: 42px;
  font-size: 15px;
}

.movie-card.compact p {
  min-height: 42px;
  font-size: 12px;
}

.split-section {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 24px;
  align-items: stretch;
}

.panel {
  padding: 32px;
  border-radius: 28px;
  box-shadow: var(--shadow);
}

.dark-panel {
  display: flex;
  flex-direction: column;
  justify-content: center;
  color: var(--white);
  background:
    radial-gradient(circle at 100% 0%, rgba(251, 191, 36, 0.28), transparent 26%),
    linear-gradient(135deg, var(--amber-950), var(--amber-800));
}

.dark-panel h2 {
  margin: 0 0 14px;
  font-size: clamp(28px, 4vw, 44px);
  line-height: 1.12;
  font-weight: 950;
}

.dark-panel p {
  margin: 0 0 22px;
  color: rgba(255, 255, 255, 0.82);
  line-height: 1.9;
}

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

.rank-row {
  display: grid;
  grid-template-columns: 52px 74px minmax(0, 1fr) 72px;
  gap: 14px;
  align-items: center;
  padding: 14px;
  border: 1px solid rgba(180, 83, 9, 0.1);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.86);
  box-shadow: 0 12px 32px rgba(120, 53, 15, 0.08);
}

.rank-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  color: var(--white);
  border-radius: 15px;
  background: linear-gradient(135deg, var(--amber-700), var(--orange-500));
  font-weight: 950;
}

.rank-thumb img {
  width: 74px;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  border-radius: 14px;
}

.rank-main h3 {
  margin: 0 0 6px;
  color: var(--amber-950);
  font-size: 17px;
  font-weight: 950;
}

.rank-main p {
  margin: 0 0 8px;
  color: #6b5a4a;
  line-height: 1.6;
}

.rank-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: var(--amber-700);
  font-size: 12px;
  font-weight: 800;
}

.rank-score {
  color: var(--orange-600);
  font-size: 20px;
  font-weight: 950;
  text-align: right;
}

.inner-hero {
  width: min(1180px, calc(100% - 32px));
  margin: 28px auto 0;
  padding: 56px;
  color: var(--white);
  border-radius: 32px;
  background:
    radial-gradient(circle at 82% 14%, rgba(251, 191, 36, 0.28), transparent 24%),
    linear-gradient(135deg, var(--amber-950), var(--amber-800));
  box-shadow: var(--shadow-strong);
}

.inner-hero p {
  max-width: 760px;
  margin: 16px 0 0;
  color: rgba(255, 255, 255, 0.84);
  font-size: 18px;
  line-height: 1.9;
}

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

.category-card {
  min-height: unset;
}

.category-preview {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin: 10px 0 14px;
}

.category-preview .movie-card:nth-child(n+4) {
  display: none;
}

.breadcrumb {
  width: min(1180px, calc(100% - 32px));
  margin: 24px auto 0;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: var(--amber-700);
  font-weight: 800;
}

.detail-hero {
  width: min(1180px, calc(100% - 32px));
  margin: 24px auto 0;
  display: grid;
  grid-template-columns: 300px minmax(0, 1fr);
  gap: 32px;
  align-items: center;
  padding: 32px;
  border-radius: 32px;
  background:
    radial-gradient(circle at 100% 0%, rgba(251, 191, 36, 0.2), transparent 28%),
    rgba(255, 255, 255, 0.86);
  box-shadow: var(--shadow);
}

.detail-cover img {
  width: 100%;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  border-radius: 24px;
  box-shadow: var(--shadow-strong);
}

.detail-intro h1 {
  color: var(--amber-950);
}

.detail-intro .lead {
  margin: 18px 0;
  color: #5f5045;
  font-size: 18px;
  line-height: 1.9;
}

.tag-list.large span {
  min-height: 32px;
  padding: 6px 12px;
}

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

.detail-meta-grid div {
  padding: 14px;
  border: 1px solid rgba(180, 83, 9, 0.12);
  border-radius: 16px;
  background: #fffaf0;
}

.detail-meta-grid span {
  display: block;
  color: var(--amber-700);
  font-size: 12px;
  font-weight: 900;
}

.detail-meta-grid strong {
  display: block;
  margin-top: 4px;
  color: var(--amber-950);
  font-size: 14px;
}

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

.player-card {
  overflow: hidden;
  border-radius: 32px;
  background: var(--stone-950);
  box-shadow: var(--shadow-strong);
}

.video-wrap {
  position: relative;
  aspect-ratio: 16 / 9;
  background: #000;
}

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

.player-overlay {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 24px;
  color: var(--white);
  border: 0;
  background:
    radial-gradient(circle at 50% 40%, rgba(251, 191, 36, 0.28), transparent 22%),
    linear-gradient(135deg, rgba(28, 25, 23, 0.4), rgba(69, 26, 3, 0.88));
  cursor: pointer;
}

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

.play-icon {
  width: 74px;
  height: 74px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding-left: 5px;
  border-radius: 50%;
  color: var(--amber-950);
  background: #fbbf24;
  font-size: 30px;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.28);
}

.player-overlay strong {
  max-width: 80%;
  text-align: center;
  font-size: clamp(22px, 4vw, 42px);
  font-weight: 950;
}

.player-overlay em {
  font-style: normal;
  color: #fde68a;
  font-weight: 900;
}

.detail-content {
  padding-top: 20px;
}

.content-panel {
  padding: 34px;
  border: 1px solid rgba(180, 83, 9, 0.12);
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.88);
  box-shadow: var(--shadow);
}

.content-panel h2 {
  margin: 0 0 12px;
  color: var(--amber-950);
  font-size: 26px;
  font-weight: 950;
}

.content-panel h2:not(:first-child) {
  margin-top: 28px;
}

.content-panel p {
  margin: 0;
  color: #55483e;
  font-size: 17px;
  line-height: 2;
}

.empty-state {
  padding: 28px;
  border-radius: 22px;
  color: var(--amber-900);
  background: #fef3c7;
  text-align: center;
  font-weight: 900;
}

.site-footer {
  margin-top: 40px;
  border-top: 1px solid rgba(180, 83, 9, 0.12);
  background: rgba(255, 251, 235, 0.82);
}

.footer-inner {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 34px 0;
  display: grid;
  gap: 8px;
  color: #6b5a4a;
}

.footer-logo {
  color: var(--amber-900);
  font-size: 18px;
}

.animate-slide-up {
  animation: slideUp 0.42s ease both;
}

.animate-scale-in {
  animation: scaleIn 0.36s ease both;
}

@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(24px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes scaleIn {
  from {
    opacity: 0;
    transform: scale(0.96);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

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

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

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

  .hero-poster {
    max-width: 280px;
  }
}

@media (max-width: 760px) {
  .header-inner {
    min-height: 64px;
  }

  .menu-toggle {
    display: block;
  }

  .nav-links {
    position: fixed;
    left: 16px;
    right: 16px;
    top: 76px;
    display: none;
    flex-direction: column;
    padding: 16px;
    border-radius: 24px;
    background: rgba(255, 251, 235, 0.98);
    box-shadow: var(--shadow-strong);
  }

  body.menu-open .nav-links {
    display: flex;
  }

  .nav-links a {
    width: 100%;
    text-align: center;
  }

  .hero-shell {
    min-height: 680px;
    border-radius: 26px;
  }

  .hero-content {
    min-height: 680px;
    padding: 28px;
    align-content: center;
  }

  .hero-controls {
    left: 28px;
    bottom: 22px;
  }

  .section,
  .inner-hero,
  .detail-hero,
  .breadcrumb {
    width: min(100% - 24px, 1180px);
  }

  .section {
    padding: 36px 0;
  }

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

  .search-panel,
  .search-panel.wide,
  .detail-meta-grid {
    grid-template-columns: 1fr;
  }

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

  .inner-hero,
  .detail-hero {
    padding: 28px;
    border-radius: 26px;
  }

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

  .rank-score {
    grid-column: 3;
    text-align: left;
  }

  .rank-thumb img {
    width: 58px;
  }

  .detail-cover {
    max-width: 240px;
  }

  .content-panel {
    padding: 24px;
  }
}

@media (max-width: 440px) {
  .movie-grid,
  .compact-grid,
  .category-movie-grid,
  .search-grid,
  .category-grid,
  .category-overview,
  .category-preview {
    grid-template-columns: 1fr;
  }

  .hero h1,
  .inner-hero h1,
  .detail-intro h1 {
    font-size: 32px;
  }

  .hero-actions {
    flex-direction: column;
  }

  .btn {
    width: 100%;
  }
}
