:root {
  --amber-50: #fffbeb;
  --amber-100: #fef3c7;
  --amber-500: #f59e0b;
  --amber-600: #d97706;
  --amber-700: #b45309;
  --orange-50: #fff7ed;
  --orange-500: #f97316;
  --orange-600: #ea580c;
  --gray-50: #f9fafb;
  --gray-100: #f3f4f6;
  --gray-200: #e5e7eb;
  --gray-300: #d1d5db;
  --gray-600: #4b5563;
  --gray-700: #374151;
  --gray-800: #1f2937;
  --gray-900: #111827;
  --white: #ffffff;
  --shadow: 0 10px 30px rgba(17, 24, 39, 0.12);
  --radius: 18px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  color: var(--gray-900);
  background: linear-gradient(180deg, var(--orange-50) 0%, var(--white) 38%, var(--gray-50) 100%);
}

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;
  background: linear-gradient(90deg, rgba(255, 251, 235, 0.96), rgba(255, 247, 237, 0.96));
  box-shadow: 0 8px 22px rgba(17, 24, 39, 0.08);
  backdrop-filter: blur(18px);
}

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

.logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 23px;
  font-weight: 800;
  color: var(--gray-800);
  white-space: nowrap;
}

.logo-mark {
  width: 34px;
  height: 34px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  color: var(--white);
  background: linear-gradient(135deg, var(--amber-500), var(--orange-500));
  box-shadow: 0 10px 24px rgba(245, 158, 11, 0.38);
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 24px;
}

.site-nav a {
  color: var(--gray-700);
  font-size: 14px;
  font-weight: 700;
  padding: 23px 0 19px;
  border-bottom: 3px solid transparent;
  transition: color 0.2s ease, border-color 0.2s ease;
}

.site-nav a:hover,
.site-nav a.active {
  color: var(--amber-700);
  border-bottom-color: var(--amber-600);
}

.header-search {
  position: relative;
  width: min(260px, 25vw);
}

.header-search input,
.filter-input,
.filter-select {
  width: 100%;
  border: 1px solid var(--gray-300);
  border-radius: 999px;
  background: var(--white);
  color: var(--gray-800);
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.header-search input {
  padding: 10px 16px 10px 40px;
}

.header-search span {
  position: absolute;
  left: 15px;
  top: 50%;
  transform: translateY(-50%);
  color: #9ca3af;
}

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

.nav-toggle {
  display: none;
  border: 0;
  border-radius: 12px;
  padding: 9px 11px;
  color: var(--gray-700);
  background: rgba(254, 243, 199, 0.75);
}

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

.hero-slider {
  position: relative;
  min-height: 540px;
  overflow: hidden;
  border-radius: 30px;
  background: var(--gray-900);
  box-shadow: var(--shadow);
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(320px, 0.9fr);
  align-items: stretch;
  gap: 0;
  opacity: 0;
  pointer-events: none;
  transform: scale(1.015);
  transition: opacity 0.55s ease, transform 0.55s ease;
}

.hero-slide.active {
  opacity: 1;
  pointer-events: auto;
  transform: scale(1);
}

.hero-media {
  position: relative;
  min-height: 540px;
  background: linear-gradient(135deg, #2f2109, #120b03);
}

.hero-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(1.04) contrast(1.03);
}

.hero-media::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(17, 24, 39, 0.15), rgba(17, 24, 39, 0.9));
}

.hero-content {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 64px 58px 74px;
  color: var(--white);
  background: radial-gradient(circle at 20% 20%, rgba(245, 158, 11, 0.24), transparent 34%), linear-gradient(135deg, rgba(31, 41, 55, 0.96), rgba(17, 24, 39, 0.98));
}

.hero-kicker {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  gap: 8px;
  padding: 8px 12px;
  border: 1px solid rgba(254, 243, 199, 0.28);
  border-radius: 999px;
  color: #fde68a;
  background: rgba(255, 255, 255, 0.08);
  font-size: 13px;
  font-weight: 700;
}

.hero-content h1 {
  margin: 18px 0 16px;
  font-size: clamp(36px, 5vw, 62px);
  line-height: 1.06;
  letter-spacing: -0.04em;
}

.hero-content p {
  margin: 0;
  color: #f3f4f6;
  font-size: 17px;
  line-height: 1.8;
}

.hero-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 24px 0 28px;
}

.pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 28px;
  padding: 5px 11px;
  border-radius: 999px;
  color: var(--amber-700);
  background: var(--amber-100);
  font-size: 12px;
  font-weight: 700;
}

.hero-tags .pill {
  color: #fffbeb;
  background: rgba(245, 158, 11, 0.2);
  border: 1px solid rgba(251, 191, 36, 0.36);
}

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

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

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

.btn-primary {
  color: var(--white);
  background: linear-gradient(135deg, var(--amber-500), var(--orange-500));
  box-shadow: 0 14px 30px rgba(249, 115, 22, 0.32);
}

.btn-secondary {
  color: #fef3c7;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(254, 243, 199, 0.26);
}

.hero-controls {
  position: absolute;
  left: 28px;
  right: 28px;
  bottom: 24px;
  z-index: 3;
  display: flex;
  align-items: center;
  justify-content: space-between;
  pointer-events: none;
}

.hero-dots {
  display: flex;
  gap: 8px;
  pointer-events: auto;
}

.hero-dot {
  width: 10px;
  height: 10px;
  border: 0;
  padding: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.45);
}

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

.hero-arrows {
  display: flex;
  gap: 10px;
  pointer-events: auto;
}

.hero-arrow {
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 999px;
  color: var(--white);
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(12px);
}

.section {
  margin-top: 46px;
}

.section-card {
  padding: 30px;
  border-radius: 26px;
  background: linear-gradient(135deg, var(--amber-100), #ffedd5);
}

.section-muted {
  padding: 30px;
  border-radius: 26px;
  background: var(--gray-50);
}

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

.section-title {
  margin: 0;
  font-size: clamp(24px, 3vw, 34px);
  line-height: 1.2;
}

.section-desc {
  margin: 8px 0 0;
  color: var(--gray-600);
  line-height: 1.75;
}

.link-more {
  color: var(--amber-700);
  font-size: 14px;
  font-weight: 800;
  white-space: nowrap;
}

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

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

.movie-card {
  overflow: hidden;
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: 0 8px 22px rgba(17, 24, 39, 0.08);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 18px 34px rgba(17, 24, 39, 0.14);
}

.poster-frame {
  position: relative;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  background: linear-gradient(135deg, #78350f, #111827);
}

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

.movie-card:hover .poster-frame img {
  transform: scale(1.05);
}

.poster-badge {
  position: absolute;
  left: 10px;
  top: 10px;
  z-index: 2;
  padding: 5px 9px;
  border-radius: 999px;
  color: var(--white);
  background: rgba(0, 0, 0, 0.58);
  font-size: 12px;
  font-weight: 800;
}

.movie-body {
  padding: 14px;
}

.movie-title {
  margin: 0 0 8px;
  font-size: 16px;
  line-height: 1.35;
  font-weight: 800;
  color: var(--gray-900);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.movie-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-bottom: 9px;
}

.movie-desc {
  margin: 0;
  color: var(--gray-600);
  font-size: 13px;
  line-height: 1.65;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

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

.category-card {
  padding: 24px;
  border-radius: 22px;
  background: var(--white);
  box-shadow: 0 8px 22px rgba(17, 24, 39, 0.08);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.category-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 30px rgba(17, 24, 39, 0.12);
}

.category-card h2,
.category-card h3 {
  margin: 0 0 10px;
  color: var(--gray-900);
}

.category-card p {
  margin: 0 0 18px;
  color: var(--gray-600);
  line-height: 1.75;
}

.page-hero {
  border-radius: 28px;
  padding: clamp(34px, 5vw, 58px);
  color: var(--white);
  background: radial-gradient(circle at 16% 16%, rgba(254, 243, 199, 0.22), transparent 30%), linear-gradient(135deg, var(--orange-600), var(--amber-600));
  box-shadow: var(--shadow);
}

.page-hero h1 {
  margin: 0 0 14px;
  font-size: clamp(32px, 5vw, 54px);
  line-height: 1.1;
}

.page-hero p {
  max-width: 760px;
  margin: 0;
  color: #fff7ed;
  font-size: 17px;
  line-height: 1.75;
}

.filter-bar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 190px 190px;
  gap: 14px;
  padding: 18px;
  margin: 28px 0;
  border-radius: 22px;
  background: var(--white);
  box-shadow: 0 8px 22px rgba(17, 24, 39, 0.08);
}

.filter-input,
.filter-select {
  height: 46px;
  padding: 0 16px;
}

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

.rank-item {
  display: grid;
  grid-template-columns: 54px 86px minmax(0, 1fr) auto;
  gap: 16px;
  align-items: center;
  padding: 14px;
  border-radius: 18px;
  background: var(--white);
  box-shadow: 0 8px 22px rgba(17, 24, 39, 0.07);
}

.rank-num {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: var(--white);
  background: linear-gradient(135deg, var(--amber-500), var(--orange-500));
  font-weight: 900;
}

.rank-thumb {
  width: 86px;
  height: 116px;
  overflow: hidden;
  border-radius: 14px;
  background: linear-gradient(135deg, #78350f, #111827);
}

.rank-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.rank-info h2,
.rank-info h3 {
  margin: 0 0 8px;
  font-size: 18px;
}

.rank-info p {
  margin: 0;
  color: var(--gray-600);
  line-height: 1.65;
}

.detail-hero {
  display: grid;
  grid-template-columns: 300px minmax(0, 1fr);
  gap: 30px;
  align-items: stretch;
  border-radius: 30px;
  padding: 30px;
  color: var(--white);
  background: radial-gradient(circle at 10% 10%, rgba(245, 158, 11, 0.26), transparent 35%), linear-gradient(135deg, var(--gray-900), #2d1906);
  box-shadow: var(--shadow);
}

.detail-poster {
  overflow: hidden;
  border-radius: 24px;
  background: linear-gradient(135deg, #78350f, #111827);
  box-shadow: 0 18px 36px rgba(0, 0, 0, 0.28);
}

.detail-poster img {
  width: 100%;
  height: 100%;
  min-height: 430px;
  object-fit: cover;
}

.detail-info {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
  color: #fde68a;
  font-size: 13px;
  font-weight: 700;
}

.detail-info h1 {
  margin: 0 0 16px;
  font-size: clamp(34px, 5vw, 58px);
  line-height: 1.1;
}

.detail-info p {
  margin: 0;
  color: #f3f4f6;
  font-size: 17px;
  line-height: 1.85;
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 24px 0;
}

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

.content-panel {
  padding: 28px;
  border-radius: 24px;
  background: var(--white);
  box-shadow: 0 8px 22px rgba(17, 24, 39, 0.08);
}

.content-panel h2 {
  margin: 0 0 16px;
  font-size: 26px;
}

.content-panel p {
  color: var(--gray-700);
  line-height: 1.9;
  margin: 0 0 18px;
}

.player-wrap {
  position: relative;
  overflow: hidden;
  border-radius: 24px;
  background: #000;
  box-shadow: var(--shadow);
}

.player-wrap video {
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #000;
}

.player-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  cursor: pointer;
  background: radial-gradient(circle, rgba(245, 158, 11, 0.28), rgba(0, 0, 0, 0.66));
}

.player-overlay.hidden {
  display: none;
}

.play-button {
  width: 96px;
  height: 96px;
  border: 0;
  border-radius: 50%;
  color: var(--white);
  background: linear-gradient(135deg, var(--amber-500), var(--orange-500));
  box-shadow: 0 18px 38px rgba(249, 115, 22, 0.36);
  font-size: 32px;
  padding-left: 6px;
}

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

.side-card {
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  padding: 10px;
  border-radius: 16px;
  background: var(--gray-50);
}

.side-card img {
  width: 72px;
  height: 96px;
  object-fit: cover;
  border-radius: 12px;
  background: linear-gradient(135deg, #78350f, #111827);
}

.side-card strong {
  display: block;
  margin-bottom: 5px;
  line-height: 1.35;
}

.side-card span {
  color: var(--gray-600);
  font-size: 12px;
}

.site-footer {
  margin-top: 56px;
  color: #d1d5db;
  background: linear-gradient(135deg, var(--gray-900), var(--gray-800));
}

.footer-inner {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 42px 0;
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) repeat(2, minmax(160px, 0.6fr));
  gap: 28px;
}

.footer-inner h2,
.footer-inner h3 {
  margin: 0 0 14px;
  color: var(--white);
}

.footer-inner p,
.footer-inner a {
  color: #9ca3af;
  line-height: 1.8;
  font-size: 14px;
}

.footer-links {
  display: grid;
  gap: 8px;
}

.footer-bottom {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 18px 0 24px;
  border-top: 1px solid rgba(209, 213, 219, 0.18);
  color: #9ca3af;
  text-align: center;
  font-size: 13px;
}

.empty-state {
  display: none;
  padding: 28px;
  border-radius: 22px;
  color: var(--gray-600);
  background: var(--white);
  text-align: center;
}

@media (max-width: 1024px) {
  .header-search {
    display: none;
  }

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

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

  .hero-content {
    min-height: 420px;
  }

  .hero-media {
    display: none;
  }
}

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

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

  .site-nav {
    display: none;
    width: 100%;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding-bottom: 12px;
  }

  .site-nav.open {
    display: flex;
  }

  .site-nav a {
    padding: 12px 0;
    border-bottom: 1px solid rgba(217, 119, 6, 0.12);
  }

  .main-shell {
    width: min(100% - 22px, 1180px);
    padding-top: 20px;
  }

  .hero-slider {
    min-height: 520px;
    border-radius: 22px;
  }

  .hero-content {
    padding: 42px 24px 86px;
  }

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

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

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

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

  .rank-item {
    grid-template-columns: 40px 68px minmax(0, 1fr);
  }

  .rank-item .btn {
    grid-column: 1 / -1;
  }

  .rank-thumb {
    width: 68px;
    height: 92px;
  }

  .detail-hero,
  .content-panel,
  .section-card,
  .section-muted {
    padding: 20px;
    border-radius: 22px;
  }

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