:root {
  --bg: #fff7ed;
  --ink: #1f2937;
  --muted: #6b7280;
  --line: rgba(255, 255, 255, 0.28);
  --brand: #f97316;
  --brand-dark: #dc2626;
  --card: rgba(255, 255, 255, 0.92);
  --shadow: 0 18px 45px rgba(154, 52, 18, 0.16);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  color: var(--ink);
  background: linear-gradient(180deg, #fff7ed 0%, #fff 34%, #fef2f2 100%);
}

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

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

button,
input,
select {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  color: #fff;
  background: linear-gradient(90deg, #f97316 0%, #ef4444 60%, #b91c1c 100%);
  box-shadow: 0 12px 32px rgba(185, 28, 28, 0.22);
}

.nav-wrap {
  max-width: 1220px;
  margin: 0 auto;
  min-height: 68px;
  padding: 0 20px;
  display: flex;
  align-items: center;
  gap: 24px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 24px;
  font-weight: 900;
  white-space: nowrap;
}

.brand-icon {
  width: 34px;
  height: 34px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  color: #f97316;
  background: #fff;
  box-shadow: 0 10px 22px rgba(127, 29, 29, 0.18);
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-left: auto;
}

.main-nav a {
  opacity: 0.92;
  font-weight: 700;
  padding: 8px 0;
  border-bottom: 2px solid transparent;
}

.main-nav a:hover,
.main-nav a.active {
  opacity: 1;
  border-color: #fed7aa;
}

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

.nav-search input,
.mobile-panel input {
  border: 0;
  outline: 0;
  color: #1f2937;
  border-radius: 999px;
  padding: 10px 16px;
  min-width: 210px;
  background: rgba(255, 255, 255, 0.96);
}

.nav-search button,
.mobile-panel button,
.primary-btn,
.secondary-btn,
.filter-bar button,
.play-overlay button {
  border: 0;
  border-radius: 999px;
  padding: 10px 18px;
  font-weight: 800;
  color: #fff;
  background: linear-gradient(90deg, #f97316, #ef4444);
  box-shadow: 0 12px 24px rgba(239, 68, 68, 0.24);
  cursor: pointer;
}

.nav-search button {
  color: #c2410c;
  background: #fff7ed;
  box-shadow: none;
}

.menu-button {
  display: none;
  margin-left: auto;
  border: 0;
  color: #fff;
  font-size: 26px;
  background: transparent;
}

.mobile-panel {
  display: none;
  padding: 0 20px 18px;
  border-top: 1px solid rgba(255, 255, 255, 0.18);
}

.mobile-panel.open {
  display: grid;
  gap: 12px;
}

.mobile-panel a {
  font-weight: 800;
}

.mobile-panel form {
  display: flex;
  gap: 8px;
}

.hero {
  position: relative;
  overflow: hidden;
  color: #fff;
  background: radial-gradient(circle at 18% 18%, rgba(251, 146, 60, 0.9), transparent 30%), linear-gradient(135deg, #7f1d1d 0%, #dc2626 42%, #fb923c 100%);
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(15, 23, 42, 0.78), rgba(127, 29, 29, 0.26), rgba(255, 255, 255, 0.08));
}

.hero-shell {
  position: relative;
  z-index: 1;
  max-width: 1220px;
  min-height: 620px;
  margin: 0 auto;
  padding: 70px 20px 54px;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(320px, 0.95fr);
  gap: 42px;
  align-items: center;
}

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

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 18px;
  padding: 8px 14px;
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 999px;
  color: #ffedd5;
  background: rgba(255, 255, 255, 0.14);
  backdrop-filter: blur(14px);
  font-weight: 800;
}

.hero h1 {
  margin: 0;
  font-size: clamp(42px, 7vw, 78px);
  line-height: 1.02;
  letter-spacing: -1.6px;
}

.hero-lead {
  margin: 22px 0 28px;
  max-width: 650px;
  color: #ffedd5;
  font-size: 19px;
  line-height: 1.8;
}

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

.primary-btn,
.secondary-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
}

.secondary-btn {
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.34);
  background: rgba(255, 255, 255, 0.14);
  box-shadow: none;
  backdrop-filter: blur(16px);
}

.hero-search {
  display: flex;
  gap: 10px;
  width: min(100%, 600px);
  padding: 10px;
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(18px);
}

.hero-search input {
  flex: 1;
  min-width: 0;
  border: 0;
  outline: 0;
  border-radius: 999px;
  padding: 12px 16px;
  color: #1f2937;
  background: rgba(255, 255, 255, 0.95);
}

.hero-search button {
  border: 0;
  border-radius: 999px;
  padding: 0 22px;
  color: #fff;
  font-weight: 900;
  background: linear-gradient(90deg, #fb923c, #dc2626);
  cursor: pointer;
}

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

.hero-slide {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-rows: 1fr auto;
  overflow: hidden;
  border-radius: 34px;
  background: rgba(255, 255, 255, 0.14);
  box-shadow: 0 34px 80px rgba(127, 29, 29, 0.38);
  opacity: 0;
  transform: translateY(18px) scale(0.98);
  transition: opacity 0.55s ease, transform 0.55s ease;
  pointer-events: none;
}

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

.hero-slide img {
  width: 100%;
  height: 100%;
  min-height: 330px;
  object-fit: cover;
  filter: saturate(1.05) contrast(1.05);
}

.slide-content {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 90px 28px 28px;
  background: linear-gradient(0deg, rgba(17, 24, 39, 0.94), rgba(17, 24, 39, 0));
}

.slide-content h2 {
  margin: 0 0 8px;
  font-size: 30px;
}

.slide-content p {
  margin: 0 0 16px;
  color: #fed7aa;
  line-height: 1.65;
}

.slide-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 12px;
}

.slide-meta span,
.tag-row span,
.meta-pill,
.detail-tags span {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 800;
  color: #c2410c;
  background: #ffedd5;
}

.hero-dots {
  position: absolute;
  z-index: 2;
  right: 26px;
  bottom: 22px;
  display: flex;
  gap: 8px;
}

.hero-dots button {
  width: 10px;
  height: 10px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.5);
  cursor: pointer;
}

.hero-dots button.active {
  width: 30px;
  background: #fff;
}

.section,
.page-shell {
  max-width: 1220px;
  margin: 0 auto;
  padding: 56px 20px;
}

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

.section-title,
.page-head h1,
.detail-title {
  margin: 0;
  color: #1f2937;
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1.15;
  font-weight: 950;
}

.section-subtitle,
.page-head p {
  margin: 8px 0 0;
  color: var(--muted);
  line-height: 1.8;
}

.more-link {
  color: #ea580c;
  font-weight: 900;
}

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

.movie-card {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(251, 146, 60, 0.16);
  border-radius: 24px;
  background: var(--card);
  box-shadow: var(--shadow);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.movie-card:hover {
  transform: translateY(-7px);
  box-shadow: 0 28px 55px rgba(154, 52, 18, 0.22);
}

.poster-link {
  position: relative;
  display: block;
  aspect-ratio: 3 / 4.2;
  overflow: hidden;
  background: linear-gradient(135deg, #fed7aa, #fee2e2);
}

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

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

.score,
.rank-badge {
  position: absolute;
  top: 12px;
  display: inline-grid;
  place-items: center;
  min-width: 42px;
  min-height: 28px;
  border-radius: 999px;
  color: #fff;
  font-weight: 950;
  background: linear-gradient(90deg, #f97316, #dc2626);
  box-shadow: 0 10px 18px rgba(127, 29, 29, 0.2);
}

.score {
  right: 12px;
}

.rank-badge {
  left: 12px;
}

.movie-info {
  padding: 16px;
}

.movie-title {
  display: block;
  margin-bottom: 8px;
  font-size: 17px;
  font-weight: 950;
  line-height: 1.35;
}

.movie-title:hover {
  color: #ea580c;
}

.movie-meta {
  margin: 0 0 10px;
  color: var(--muted);
  font-size: 13px;
}

.movie-desc {
  margin: 0 0 12px;
  min-height: 44px;
  color: #4b5563;
  font-size: 14px;
  line-height: 1.55;
}

.tag-row,
.detail-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.category-band {
  background: linear-gradient(135deg, #fff7ed, #fee2e2);
}

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

.category-card {
  padding: 22px;
  border-radius: 24px;
  color: #7c2d12;
  background: rgba(255, 255, 255, 0.78);
  box-shadow: var(--shadow);
  border: 1px solid rgba(251, 146, 60, 0.18);
}

.category-card strong {
  display: block;
  margin-bottom: 10px;
  font-size: 22px;
  color: #1f2937;
}

.category-card p {
  margin: 0;
  color: #6b7280;
  line-height: 1.7;
}

.rank-panel {
  display: grid;
  gap: 12px;
}

.rank-row {
  display: grid;
  grid-template-columns: 52px 74px minmax(0, 1fr) 58px;
  gap: 14px;
  align-items: center;
  padding: 12px;
  border-radius: 20px;
  background: #fff;
  box-shadow: 0 10px 28px rgba(154, 52, 18, 0.1);
}

.rank-number,
.rank-score {
  font-size: 22px;
  font-weight: 950;
  color: #ea580c;
  text-align: center;
}

.rank-row img {
  width: 74px;
  height: 96px;
  object-fit: cover;
  border-radius: 14px;
}

.rank-main {
  min-width: 0;
}

.rank-main strong,
.rank-main em {
  display: block;
}

.rank-main strong {
  font-size: 18px;
  color: #1f2937;
}

.rank-main em {
  margin-top: 6px;
  color: var(--muted);
  font-style: normal;
  line-height: 1.5;
}

.filter-bar {
  display: grid;
  grid-template-columns: minmax(180px, 1fr) 160px 160px auto;
  gap: 12px;
  margin: 24px 0 28px;
  padding: 14px;
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.78);
  box-shadow: var(--shadow);
}

.filter-bar input,
.filter-bar select {
  min-width: 0;
  width: 100%;
  border: 1px solid rgba(251, 146, 60, 0.25);
  border-radius: 999px;
  padding: 12px 16px;
  outline: 0;
  background: #fff;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 20px;
  color: var(--muted);
  font-size: 14px;
}

.breadcrumb a {
  color: #ea580c;
  font-weight: 800;
}

.detail-hero {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr);
  gap: 30px;
  align-items: stretch;
  margin-bottom: 36px;
}

.player-card,
.detail-card,
.text-card {
  border: 1px solid rgba(251, 146, 60, 0.16);
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: var(--shadow);
}

.player-card {
  overflow: hidden;
}

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

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

.play-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  border: 0;
  color: #fff;
  background: radial-gradient(circle at center, rgba(249, 115, 22, 0.28), rgba(17, 24, 39, 0.64));
  cursor: pointer;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

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

.play-overlay span {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  border-radius: 999px;
  padding: 14px 24px;
  font-weight: 950;
  background: linear-gradient(90deg, #f97316, #dc2626);
  box-shadow: 0 18px 34px rgba(0, 0, 0, 0.25);
}

.detail-card {
  padding: 28px;
}

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

.meta-pill {
  color: #7c2d12;
  background: #ffedd5;
}

.detail-lead {
  color: #4b5563;
  font-size: 18px;
  line-height: 1.8;
}

.text-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
  margin: 32px 0;
}

.text-card {
  padding: 26px;
}

.text-card h2 {
  margin: 0 0 14px;
  font-size: 26px;
}

.text-card p {
  margin: 0;
  color: #4b5563;
  line-height: 1.9;
}

.compact-card .movie-desc {
  display: none;
}

.not-found {
  display: none;
  padding: 26px;
  border-radius: 24px;
  color: #7c2d12;
  background: #ffedd5;
  font-weight: 900;
}

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

  .hero-shell,
  .detail-hero,
  .text-grid {
    grid-template-columns: 1fr;
  }

  .hero-stage {
    min-height: 520px;
  }
}

@media (max-width: 840px) {
  .main-nav,
  .nav-search {
    display: none;
  }

  .menu-button {
    display: block;
  }

  .hero-shell {
    min-height: auto;
    padding-top: 48px;
  }

  .hero-search {
    border-radius: 28px;
    flex-direction: column;
  }

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

  .section-head,
  .page-head {
    display: block;
  }

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

@media (max-width: 640px) {
  .nav-wrap {
    min-height: 62px;
    padding: 0 14px;
  }

  .brand {
    font-size: 19px;
  }

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

  .hero-stage {
    min-height: 450px;
  }

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

  .movie-info {
    padding: 12px;
  }

  .movie-title {
    font-size: 15px;
  }

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

  .rank-row img {
    width: 58px;
    height: 78px;
  }

  .rank-main strong {
    font-size: 15px;
  }

  .rank-main em {
    font-size: 12px;
  }
}
