:root {
  --stone-950: #0c0a09;
  --stone-900: #1c1917;
  --stone-850: #221f1c;
  --stone-800: #292524;
  --stone-700: #44403c;
  --amber-100: #fef3c7;
  --amber-200: #fde68a;
  --amber-300: #fcd34d;
  --amber-400: #fbbf24;
  --amber-500: #f59e0b;
  --amber-600: #d97706;
  --amber-700: #b45309;
  --amber-800: #92400e;
  --amber-900: #78350f;
  --white: #ffffff;
  --muted: #d6d3d1;
  --radius-lg: 18px;
  --radius-xl: 26px;
  --shadow-lg: 0 24px 70px rgba(0, 0, 0, .38);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--amber-100);
  background: linear-gradient(180deg, var(--stone-900), var(--stone-800) 42%, var(--stone-900));
  font-family: Inter, "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
}

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

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

button,
input,
select {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: linear-gradient(90deg, var(--amber-900), var(--stone-800), var(--amber-900));
  border-bottom: 2px solid var(--amber-700);
  box-shadow: 0 12px 32px rgba(0, 0, 0, .3);
}

.nav-wrap {
  max-width: 1280px;
  height: 66px;
  margin: 0 auto;
  padding: 0 22px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 24px;
  line-height: 1;
  font-weight: 800;
  letter-spacing: .02em;
  color: var(--amber-100);
  white-space: nowrap;
}

.logo:hover {
  color: var(--white);
}

.logo-mark {
  width: 34px;
  height: 34px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
  background: radial-gradient(circle at 30% 30%, var(--amber-300), var(--amber-600) 65%, var(--amber-800));
  box-shadow: 0 0 26px rgba(245, 158, 11, .5);
  font-size: 14px;
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 18px;
  font-weight: 650;
  color: var(--amber-100);
}

.desktop-nav a,
.mobile-nav a {
  transition: color .2s ease, background .2s ease, transform .2s ease;
}

.desktop-nav a:hover,
.mobile-nav a:hover {
  color: var(--white);
}

.menu-button {
  display: none;
  border: 0;
  color: var(--amber-100);
  background: rgba(255, 255, 255, .06);
  border-radius: 10px;
  padding: 8px 12px;
  cursor: pointer;
}

.mobile-nav {
  display: none;
  padding: 8px 18px 18px;
  background: var(--stone-900);
  border-top: 1px solid rgba(180, 83, 9, .75);
}

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

.mobile-nav a {
  padding: 10px 12px;
  border-radius: 10px;
  color: var(--amber-100);
}

.mobile-nav a:hover {
  background: rgba(120, 53, 15, .74);
}

main {
  min-height: 70vh;
}

.page-shell {
  max-width: 1280px;
  margin: 0 auto;
  padding: 34px 22px 58px;
}

.hero-wrap {
  position: relative;
  max-width: 1280px;
  height: 600px;
  margin: 34px auto 54px;
  overflow: hidden;
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-lg);
  background: var(--stone-900);
}

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

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

.hero-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.02);
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(0, 0, 0, .95), rgba(0, 0, 0, .68) 42%, rgba(0, 0, 0, .12));
}

.hero-content {
  position: absolute;
  inset: 0;
  max-width: 720px;
  padding: 72px 64px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  color: var(--white);
}

.hero-kicker {
  width: max-content;
  margin-bottom: 18px;
  padding: 8px 14px;
  border-radius: 999px;
  color: var(--white);
  background: var(--amber-600);
  font-size: 14px;
  font-weight: 800;
  box-shadow: 0 10px 24px rgba(217, 119, 6, .34);
}

.hero-content h1,
.hero-content h2 {
  margin: 0 0 18px;
  color: var(--white);
  font-size: clamp(36px, 5vw, 60px);
  line-height: 1.05;
  letter-spacing: -.04em;
}

.hero-content p {
  margin: 0 0 24px;
  color: #d1d5db;
  font-size: 18px;
  line-height: 1.78;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 28px;
  color: #e7e5e4;
  font-size: 14px;
}

.hero-meta span:first-child {
  color: var(--amber-300);
  font-weight: 800;
}

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

.primary-button,
.ghost-button,
.filter-bar button,
.player-cover button {
  border: 0;
  cursor: pointer;
}

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

.primary-button {
  color: var(--white);
  background: var(--amber-600);
  box-shadow: 0 14px 26px rgba(217, 119, 6, .32);
}

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

.ghost-button {
  color: var(--amber-100);
  background: rgba(0, 0, 0, .38);
  border: 1px solid rgba(253, 230, 138, .25);
}

.ghost-button:hover {
  color: var(--white);
  background: rgba(0, 0, 0, .58);
  transform: translateY(-2px);
}

.hero-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 46px;
  height: 46px;
  border: 0;
  border-radius: 999px;
  color: var(--white);
  background: rgba(0, 0, 0, .52);
  font-size: 34px;
  line-height: 1;
  cursor: pointer;
  transition: background .2s ease, transform .2s ease;
}

.hero-arrow:hover {
  background: rgba(0, 0, 0, .75);
}

.hero-prev {
  left: 18px;
}

.hero-next {
  right: 18px;
}

.hero-dots {
  position: absolute;
  left: 50%;
  bottom: 24px;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 8px;
}

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

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

.hero-search-panel {
  position: absolute;
  right: 42px;
  bottom: 58px;
  width: min(440px, calc(100% - 84px));
  padding: 18px;
  border-radius: 20px;
  background: rgba(28, 25, 23, .72);
  border: 1px solid rgba(252, 211, 77, .2);
  backdrop-filter: blur(14px);
}

.hero-search {
  display: flex;
  gap: 10px;
}

.hero-search input,
.filter-bar input,
.filter-bar select {
  min-width: 0;
  border: 1px solid rgba(252, 211, 77, .22);
  outline: none;
  color: var(--amber-100);
  background: rgba(12, 10, 9, .72);
  border-radius: 999px;
}

.hero-search input {
  flex: 1;
  height: 44px;
  padding: 0 16px;
}

.hero-search button {
  border: 0;
  color: var(--white);
  background: var(--amber-600);
  border-radius: 999px;
  padding: 0 20px;
  font-weight: 800;
  cursor: pointer;
}

.hero-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.hero-chips a {
  padding: 7px 10px;
  border-radius: 999px;
  color: var(--amber-200);
  background: rgba(120, 53, 15, .44);
  font-size: 13px;
}

.hero-chips a:hover {
  color: var(--white);
  background: rgba(217, 119, 6, .65);
}

.content-section {
  margin: 0 0 58px;
}

.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 24px;
  padding-bottom: 14px;
  border-bottom: 2px solid var(--amber-700);
}

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

.section-head p {
  margin: 8px 0 0;
  max-width: 780px;
  color: rgba(253, 230, 138, .72);
  line-height: 1.8;
}

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

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

.card-link {
  display: block;
  height: 100%;
  overflow: hidden;
  border-radius: 14px;
  background: var(--stone-800);
  box-shadow: 0 12px 24px rgba(0, 0, 0, .24);
  transform: translateZ(0);
  transition: transform .28s ease, box-shadow .28s ease, background .28s ease;
}

.card-link:hover {
  transform: translateY(-4px) scale(1.015);
  background: #312c29;
  box-shadow: 0 24px 52px rgba(0, 0, 0, .36);
}

.poster-box {
  position: relative;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  background: linear-gradient(135deg, #1c1917, #44403c);
}

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

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

.poster-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(0, 0, 0, .74), rgba(0, 0, 0, .08) 60%, rgba(0, 0, 0, .05));
  opacity: .72;
  transition: opacity .25s ease;
}

.card-link:hover .poster-shade {
  opacity: .9;
}

.type-pill,
.rank-badge {
  position: absolute;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  color: var(--white);
  font-weight: 800;
}

.type-pill {
  top: 10px;
  right: 10px;
  min-height: 26px;
  padding: 0 10px;
  background: var(--amber-600);
  font-size: 12px;
}

.rank-badge {
  top: 10px;
  left: 10px;
  width: 30px;
  height: 30px;
  background: rgba(0, 0, 0, .65);
  border: 1px solid rgba(252, 211, 77, .42);
}

.card-info {
  padding: 14px 14px 16px;
}

.card-info h3 {
  margin: 0 0 8px;
  color: var(--amber-100);
  font-size: 17px;
  line-height: 1.35;
  min-height: 46px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  transition: color .25s ease;
}

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

.card-info p {
  margin: 0 0 12px;
  min-height: 38px;
  color: #d6d3d1;
  font-size: 13px;
  line-height: 1.46;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  color: #a8a29e;
  font-size: 12px;
}

.card-meta span:first-child {
  color: var(--amber-300);
}

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

.category-tile {
  min-height: 210px;
  padding: 22px;
  border-radius: 18px;
  background: linear-gradient(145deg, rgba(68, 64, 60, .92), rgba(28, 25, 23, .96));
  border: 1px solid rgba(252, 211, 77, .15);
  box-shadow: 0 18px 44px rgba(0, 0, 0, .24);
  transition: transform .25s ease, border-color .25s ease, background .25s ease;
}

.category-tile:hover {
  transform: translateY(-4px);
  border-color: rgba(252, 211, 77, .45);
  background: linear-gradient(145deg, rgba(120, 53, 15, .66), rgba(41, 37, 36, .98));
}

.category-tile strong {
  display: block;
  margin-bottom: 10px;
  color: var(--amber-300);
  font-size: 22px;
}

.category-tile p {
  margin: 0 0 14px;
  color: rgba(253, 230, 138, .78);
  line-height: 1.62;
  font-size: 14px;
}

.category-tile div {
  display: grid;
  gap: 6px;
  color: #d6d3d1;
  font-size: 13px;
}

.filter-bar {
  display: grid;
  grid-template-columns: 1fr 150px 150px 150px 120px;
  gap: 12px;
  margin: 0 0 28px;
  padding: 18px;
  border-radius: 18px;
  background: rgba(28, 25, 23, .82);
  border: 1px solid rgba(180, 83, 9, .45);
}

.filter-bar input,
.filter-bar select {
  height: 44px;
  padding: 0 14px;
  border-radius: 12px;
}

.filter-bar button {
  border-radius: 12px;
  color: var(--white);
  background: var(--amber-600);
  font-weight: 800;
}

.filter-bar button:hover {
  background: var(--amber-700);
}

.no-result {
  display: none;
  margin: 24px 0;
  padding: 24px;
  border-radius: 16px;
  color: var(--amber-200);
  background: rgba(28, 25, 23, .82);
  border: 1px solid rgba(252, 211, 77, .18);
}

.no-result.is-visible {
  display: block;
}

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

.rank-row {
  display: grid;
  grid-template-columns: 42px 128px 1fr 40px;
  align-items: center;
  gap: 16px;
  padding: 14px;
  border-radius: 16px;
  background: var(--stone-800);
  transition: background .22s ease, transform .22s ease;
}

.rank-row:hover {
  background: var(--stone-700);
  transform: translateX(4px);
}

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

.rank-row img {
  width: 128px;
  height: 78px;
  border-radius: 12px;
  object-fit: cover;
  background: var(--stone-700);
}

.rank-text {
  display: grid;
  gap: 5px;
}

.rank-text strong {
  color: var(--amber-100);
  font-size: 18px;
}

.rank-text em {
  color: #a8a29e;
  font-style: normal;
  font-size: 13px;
}

.rank-play {
  color: var(--amber-300);
  font-size: 22px;
}

.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 30px;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 22px;
  color: rgba(253, 230, 138, .72);
  font-size: 14px;
}

.breadcrumb a:hover {
  color: var(--white);
}

.detail-panel {
  overflow: hidden;
  border-radius: 20px;
  background: var(--stone-800);
  box-shadow: var(--shadow-lg);
}

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

.player-shell video {
  width: 100%;
  height: 100%;
  display: block;
  background: #000;
}

.player-cover {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  border: 0;
  color: var(--white);
  background: radial-gradient(circle at center, rgba(217, 119, 6, .18), rgba(0, 0, 0, .68));
  cursor: pointer;
  transition: opacity .2s ease, visibility .2s ease;
}

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

.play-circle {
  width: 76px;
  height: 76px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--amber-600);
  box-shadow: 0 0 34px rgba(245, 158, 11, .52);
  font-size: 30px;
}

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

.player-status {
  min-height: 22px;
  color: rgba(253, 230, 138, .75);
  font-size: 13px;
}

.detail-info {
  padding: 28px;
}

.detail-info h1 {
  margin: 0 0 18px;
  color: var(--amber-100);
  font-size: clamp(30px, 4vw, 48px);
  line-height: 1.12;
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 22px;
}

.detail-meta span,
.tag-list span {
  padding: 7px 12px;
  border-radius: 999px;
  color: var(--amber-200);
  background: rgba(68, 64, 60, .82);
  font-size: 14px;
}

.detail-meta span:first-child {
  color: var(--white);
  background: var(--amber-600);
  font-weight: 800;
}

.detail-block {
  margin-top: 24px;
}

.detail-block h2 {
  margin: 0 0 12px;
  color: var(--amber-300);
  font-size: 22px;
}

.detail-block p {
  margin: 0;
  color: rgba(254, 243, 199, .82);
  line-height: 1.95;
  font-size: 16px;
}

.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

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

.site-footer {
  background: linear-gradient(180deg, var(--stone-900), var(--stone-950));
  border-top: 2px solid var(--amber-700);
  color: var(--amber-100);
}

.footer-grid {
  max-width: 1280px;
  margin: 0 auto;
  padding: 42px 22px 34px;
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr;
  gap: 30px;
}

.site-footer h2 {
  margin: 0 0 14px;
  color: var(--amber-400);
  font-size: 18px;
}

.site-footer p {
  margin: 0;
  color: rgba(253, 230, 138, .72);
  line-height: 1.8;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 14px;
}

.footer-links a {
  color: rgba(253, 230, 138, .72);
}

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

.footer-bottom {
  max-width: 1280px;
  margin: 0 auto;
  padding: 20px 22px 28px;
  border-top: 1px solid rgba(120, 53, 15, .58);
  color: rgba(253, 230, 138, .58);
  text-align: center;
  font-size: 14px;
}

.hidden-card {
  display: none;
}

@media (max-width: 1100px) {
  .desktop-nav {
    gap: 12px;
    font-size: 14px;
  }

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

  .hero-search-panel {
    right: 24px;
  }
}

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

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

  .hero-wrap {
    height: 680px;
    margin: 22px 16px 40px;
    border-radius: 18px;
  }

  .hero-content {
    padding: 38px 24px 210px;
    justify-content: flex-end;
  }

  .hero-overlay {
    background: linear-gradient(0deg, rgba(0, 0, 0, .96), rgba(0, 0, 0, .62) 58%, rgba(0, 0, 0, .1));
  }

  .hero-search-panel {
    left: 18px;
    right: 18px;
    bottom: 48px;
    width: auto;
  }

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

  .filter-bar {
    grid-template-columns: 1fr 1fr;
  }

  .filter-bar input,
  .filter-bar button {
    grid-column: span 2;
  }

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

@media (max-width: 620px) {
  .nav-wrap {
    padding: 0 16px;
  }

  .logo {
    font-size: 20px;
  }

  .page-shell {
    padding: 24px 16px 44px;
  }

  .hero-content h1,
  .hero-content h2 {
    font-size: 36px;
  }

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

  .hero-search button {
    min-height: 42px;
  }

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

  .card-info {
    padding: 12px;
  }

  .card-info h3 {
    font-size: 15px;
  }

  .rank-row {
    grid-template-columns: 34px 92px 1fr;
    gap: 12px;
  }

  .rank-row img {
    width: 92px;
    height: 62px;
  }

  .rank-play {
    display: none;
  }

  .detail-info {
    padding: 20px;
  }
}
