:root {
  --amber-50: #fffbeb;
  --amber-100: #fef3c7;
  --amber-200: #fde68a;
  --amber-500: #f59e0b;
  --amber-600: #d97706;
  --amber-700: #b45309;
  --amber-900: #78350f;
  --orange-500: #f97316;
  --orange-600: #ea580c;
  --rose-400: #fb7185;
  --rose-500: #f43f5e;
  --blue-500: #3b82f6;
  --gray-50: #f9fafb;
  --gray-100: #f3f4f6;
  --gray-200: #e5e7eb;
  --gray-500: #6b7280;
  --gray-600: #4b5563;
  --gray-700: #374151;
  --gray-800: #1f2937;
  --gray-900: #111827;
  --white: #ffffff;
  --shadow: 0 18px 45px rgba(120, 53, 15, 0.12);
  --shadow-soft: 0 10px 28px rgba(31, 41, 55, 0.10);
  --radius-xl: 24px;
  --radius-lg: 18px;
  --radius-md: 14px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
  color: var(--gray-800);
  background: linear-gradient(180deg, #ffffff 0%, var(--amber-50) 44%, #ffffff 100%);
  line-height: 1.6;
}

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

img {
  display: block;
  width: 100%;
  height: auto;
}

button,
input,
select {
  font: inherit;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 60;
  background: linear-gradient(90deg, rgba(255, 251, 235, 0.96), rgba(255, 247, 237, 0.96));
  backdrop-filter: blur(18px);
  box-shadow: 0 6px 24px rgba(180, 83, 9, 0.12);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 76px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  color: var(--white);
  background: linear-gradient(135deg, var(--amber-600), var(--orange-600));
  box-shadow: 0 12px 28px rgba(217, 119, 6, 0.30);
}

.brand-text {
  display: flex;
  flex-direction: column;
}

.brand-text strong {
  font-size: 24px;
  line-height: 1.1;
  background: linear-gradient(90deg, var(--amber-700), var(--orange-600));
  -webkit-background-clip: text;
  color: transparent;
  font-weight: 800;
  letter-spacing: 0.5px;
}

.brand-text small {
  margin-top: 2px;
  color: var(--amber-600);
  font-size: 12px;
}

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

.nav-link,
.mobile-link {
  color: var(--gray-700);
  font-weight: 650;
  transition: color 0.2s ease, transform 0.2s ease;
}

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

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

.menu-toggle {
  display: none;
  border: 0;
  background: transparent;
  color: var(--gray-700);
  font-size: 28px;
  cursor: pointer;
}

.mobile-nav {
  display: none;
  padding: 0 16px 16px;
}

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

.mobile-link {
  padding: 10px 14px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.72);
}

.hero {
  position: relative;
  overflow: hidden;
  min-height: 650px;
  color: var(--white);
  background: linear-gradient(135deg, #f59e0b 0%, #f97316 45%, #fb7185 100%);
}

.hero::before,
.hero::after {
  content: "";
  position: absolute;
  z-index: 1;
  border-radius: 999px;
  filter: blur(10px);
  background: rgba(255, 255, 255, 0.16);
  animation: pulseGlow 7s ease-in-out infinite;
}

.hero::before {
  top: 68px;
  left: 8%;
  width: 190px;
  height: 190px;
}

.hero::after {
  right: 8%;
  bottom: 72px;
  width: 250px;
  height: 250px;
  animation-delay: 1.8s;
}

.hero-shade {
  position: absolute;
  inset: 0;
  z-index: 2;
  background: linear-gradient(90deg, rgba(0, 0, 0, 0.44), rgba(0, 0, 0, 0.12), rgba(0, 0, 0, 0.30));
}

.hero-slider {
  position: relative;
  z-index: 3;
}

.hero-slide {
  display: none;
  min-height: 650px;
  align-items: center;
  padding: 72px 0;
}

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

.hero-layout {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 44px;
  align-items: center;
}

.hero-copy {
  max-width: 720px;
}

.hero-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  margin-bottom: 22px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.26);
  backdrop-filter: blur(12px);
  font-weight: 700;
}

.hero h1 {
  margin: 0;
  font-size: clamp(42px, 6.4vw, 78px);
  line-height: 1.04;
  letter-spacing: -1px;
  font-weight: 900;
}

.hero p {
  margin: 18px 0 0;
  max-width: 660px;
  color: rgba(255, 255, 255, 0.90);
  font-size: 18px;
}

.hero-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 26px;
}

.hero-tags span,
.card-tags span,
.detail-tags span {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 650;
}

.hero-tags span {
  padding: 8px 12px;
  background: rgba(255, 255, 255, 0.18);
  border: 1px solid rgba(255, 255, 255, 0.24);
}

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

.btn-primary,
.btn-ghost,
.btn-soft {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: 999px;
  font-weight: 800;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.btn-primary {
  padding: 14px 24px;
  color: var(--white);
  background: linear-gradient(90deg, var(--amber-600), var(--orange-600));
  box-shadow: 0 16px 30px rgba(217, 119, 6, 0.28);
}

.hero .btn-primary {
  color: var(--amber-700);
  background: var(--white);
}

.btn-ghost {
  padding: 12px 22px;
  color: var(--white);
  border: 2px solid rgba(255, 255, 255, 0.86);
  background: rgba(255, 255, 255, 0.12);
}

.btn-soft {
  padding: 10px 18px;
  color: var(--amber-700);
  background: var(--amber-100);
}

.btn-primary:hover,
.btn-ghost:hover,
.btn-soft:hover {
  transform: translateY(-2px) scale(1.02);
  box-shadow: 0 18px 32px rgba(120, 53, 15, 0.18);
}

.hero-art {
  position: relative;
  min-height: 470px;
}

.hero-poster {
  position: relative;
  width: min(420px, 100%);
  margin-left: auto;
  border-radius: 30px;
  overflow: hidden;
  box-shadow: 0 26px 80px rgba(0, 0, 0, 0.30);
  transform: rotate(2deg);
}

.hero-poster img {
  height: 560px;
  object-fit: cover;
}

.hero-poster::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.45), transparent 55%);
}

.hero-card-float {
  position: absolute;
  left: 0;
  bottom: 26px;
  width: min(330px, 90%);
  padding: 22px;
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.18);
  border: 1px solid rgba(255, 255, 255, 0.26);
  backdrop-filter: blur(18px);
  box-shadow: 0 18px 45px rgba(0, 0, 0, 0.18);
}

.hero-card-float strong {
  display: block;
  font-size: 22px;
}

.hero-controls {
  position: absolute;
  left: 50%;
  bottom: 28px;
  z-index: 8;
  display: flex;
  align-items: center;
  gap: 10px;
  transform: translateX(-50%);
}

.hero-dot {
  width: 12px;
  height: 12px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.50);
  cursor: pointer;
}

.hero-dot.active {
  width: 34px;
  background: #ffffff;
}

.quick-search {
  margin-top: -42px;
  position: relative;
  z-index: 12;
}

.search-panel {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
  padding: 18px;
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: var(--shadow);
}

.search-panel input,
.search-box input,
.search-box select {
  width: 100%;
  border: 1px solid var(--gray-200);
  border-radius: 999px;
  padding: 14px 18px;
  color: var(--gray-800);
  background: var(--white);
  outline: none;
}

.search-panel input:focus,
.search-box input:focus,
.search-box select:focus {
  border-color: var(--amber-500);
  box-shadow: 0 0 0 4px rgba(245, 158, 11, 0.14);
}

.search-panel button,
.search-box button {
  border: 0;
  padding: 14px 24px;
  border-radius: 999px;
  color: var(--white);
  font-weight: 800;
  background: linear-gradient(90deg, var(--amber-600), var(--orange-600));
  cursor: pointer;
}

main section {
  padding: 72px 0;
}

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

.section-heading h2 {
  margin: 0;
  font-size: clamp(28px, 3.2vw, 42px);
  color: var(--gray-800);
  line-height: 1.15;
}

.section-heading p {
  margin: 6px 0 0;
  color: var(--gray-600);
}

.section-icon {
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  width: 54px;
  height: 54px;
  border-radius: 18px;
  color: var(--amber-700);
  background: linear-gradient(135deg, var(--amber-100), #ffedd5);
  box-shadow: 0 10px 24px rgba(217, 119, 6, 0.16);
  font-size: 24px;
}

.section-more {
  margin-left: auto;
  padding: 10px 18px;
  border-radius: 999px;
  color: var(--amber-700);
  background: var(--amber-100);
  font-weight: 800;
}

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

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

.movie-card {
  overflow: hidden;
  border-radius: var(--radius-lg);
  background: var(--white);
  box-shadow: var(--shadow-soft);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 18px 42px rgba(120, 53, 15, 0.17);
}

.poster-link {
  position: relative;
  display: block;
  overflow: hidden;
  background: linear-gradient(135deg, var(--amber-100), #ffedd5);
}

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

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

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

.poster-type {
  right: 12px;
  padding: 6px 10px;
  background: rgba(244, 63, 94, 0.92);
}

.rank-badge {
  left: 12px;
  width: 34px;
  height: 34px;
  background: linear-gradient(135deg, var(--amber-600), var(--orange-600));
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.20);
}

.card-body {
  padding: 16px;
}

.card-meta {
  color: var(--amber-700);
  font-size: 13px;
  font-weight: 800;
}

.card-body h3 {
  margin: 6px 0 8px;
  min-height: 3.2em;
  color: var(--gray-900);
  font-size: 17px;
  line-height: 1.35;
}

.card-body h3 a:hover {
  color: var(--amber-600);
}

.card-body p,
.card-summary {
  margin: 0 0 12px;
  color: var(--gray-600);
  font-size: 14px;
}

.card-tags,
.detail-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.card-tags span,
.detail-tags span {
  padding: 4px 9px;
  color: var(--amber-700);
  background: var(--amber-100);
}

.card-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 14px;
  color: var(--gray-600);
  font-size: 14px;
  font-weight: 800;
}

.card-foot a {
  color: var(--amber-700);
}

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

.category-card {
  display: block;
  min-height: 180px;
  padding: 24px;
  border-radius: var(--radius-lg);
  background: linear-gradient(135deg, #ffffff, #fffbeb);
  box-shadow: var(--shadow-soft);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

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

.category-card strong {
  display: block;
  margin-bottom: 10px;
  font-size: 24px;
  color: var(--gray-900);
}

.category-card p {
  margin: 0;
  color: var(--gray-600);
}

.category-card span {
  display: inline-flex;
  margin-top: 18px;
  color: var(--amber-700);
  font-weight: 800;
}

.ribbon-section {
  background: linear-gradient(90deg, #eff6ff, #ecfeff);
}

.horizontal-row {
  display: flex;
  gap: 18px;
  overflow-x: auto;
  padding: 6px 4px 20px;
  scrollbar-width: thin;
}

.horizontal-row .movie-card {
  flex: 0 0 280px;
}

.page-hero {
  padding: 74px 0;
  background: linear-gradient(135deg, var(--amber-400, #f59e0b), var(--orange-500), var(--rose-400));
  color: var(--white);
}

.page-hero h1 {
  margin: 0 0 14px;
  font-size: clamp(34px, 4vw, 58px);
  line-height: 1.1;
}

.page-hero p {
  max-width: 780px;
  margin: 0;
  font-size: 18px;
  color: rgba(255, 255, 255, 0.92);
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 18px;
  color: rgba(255, 255, 255, 0.86);
}

.breadcrumb a:hover {
  color: #ffffff;
}

.search-box {
  display: grid;
  grid-template-columns: 1.4fr 0.7fr 0.7fr 0.7fr auto;
  gap: 12px;
  padding: 18px;
  margin-bottom: 30px;
  border-radius: 24px;
  background: #ffffff;
  box-shadow: var(--shadow-soft);
}

.empty-state {
  display: none;
  padding: 32px;
  border-radius: 20px;
  text-align: center;
  color: var(--gray-600);
  background: #ffffff;
  box-shadow: var(--shadow-soft);
}

.empty-state.show {
  display: block;
}

.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) 360px;
  gap: 30px;
  align-items: start;
}

.player-card,
.detail-card,
.side-card {
  border-radius: var(--radius-xl);
  background: #ffffff;
  box-shadow: var(--shadow-soft);
  overflow: hidden;
}

.player-shell {
  position: relative;
  background: #0f172a;
}

.movie-video {
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #0f172a;
}

.player-cover {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 0;
  padding: 0;
  background: #0f172a;
  cursor: pointer;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

.player-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.78;
  filter: brightness(0.75);
}

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

.play-orb {
  position: absolute;
  display: grid;
  place-items: center;
  width: 88px;
  height: 88px;
  border-radius: 999px;
  color: var(--amber-700);
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 20px 45px rgba(0, 0, 0, 0.28);
  font-size: 34px;
  transform: translateZ(0);
}

.player-title {
  padding: 22px;
}

.player-title h2 {
  margin: 0 0 8px;
  font-size: 24px;
}

.player-title p {
  margin: 0;
  color: var(--gray-600);
}

.detail-card {
  padding: 26px;
}

.detail-card h2,
.side-card h2 {
  margin: 0 0 14px;
  font-size: 24px;
  color: var(--gray-900);
}

.detail-card p {
  margin: 0 0 18px;
  color: var(--gray-700);
}

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

.detail-meta div {
  padding: 14px;
  border-radius: 14px;
  background: var(--amber-50);
}

.detail-meta span {
  display: block;
  color: var(--gray-500);
  font-size: 12px;
}

.detail-meta strong {
  color: var(--gray-900);
}

.side-card {
  padding: 18px;
}

.side-poster {
  overflow: hidden;
  border-radius: 18px;
  margin-bottom: 16px;
}

.side-poster img {
  aspect-ratio: 3 / 4;
  object-fit: cover;
}

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

.site-footer {
  padding-top: 54px;
  color: var(--amber-50);
  background: linear-gradient(180deg, var(--amber-900), #451a03);
}

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

.footer-brand {
  margin-bottom: 12px;
  font-size: 24px;
  font-weight: 900;
  color: var(--amber-100);
}

.site-footer p {
  max-width: 480px;
  margin: 0;
  color: var(--amber-200);
}

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

.site-footer a {
  display: block;
  margin: 8px 0;
  color: var(--amber-200);
}

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

.footer-bottom {
  margin-top: 38px;
  padding: 20px;
  border-top: 1px solid rgba(253, 230, 138, 0.18);
  text-align: center;
  color: var(--amber-200);
}

@keyframes pulseGlow {
  0%, 100% {
    transform: scale(1);
    opacity: 0.55;
  }

  50% {
    transform: scale(1.18);
    opacity: 0.85;
  }
}

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

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

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

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

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

  .menu-toggle {
    display: block;
  }

  .hero-slide {
    min-height: auto;
    padding: 54px 0 88px;
  }

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

  .hero-art {
    min-height: 360px;
  }

  .hero-poster {
    margin: 0 auto;
    transform: none;
  }

  .hero-poster img {
    height: 430px;
  }

  .hero-card-float {
    left: 50%;
    transform: translateX(-50%);
  }

  .search-panel,
  .search-box {
    grid-template-columns: 1fr;
  }

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

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

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

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

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

  .brand-text small {
    display: none;
  }

  .hero h1 {
    font-size: 40px;
  }

  .hero p,
  .page-hero p {
    font-size: 16px;
  }

  .hero-actions {
    display: grid;
  }

  .movie-grid,
  .movie-grid.compact,
  .category-grid,
  .related-grid {
    grid-template-columns: 1fr;
  }

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

  .section-more {
    display: none;
  }
}
