:root {
  color-scheme: light;
  --bg: #fff7ed;
  --surface: #ffffff;
  --surface-soft: #fffaf4;
  --ink: #1f2937;
  --muted: #6b7280;
  --line: rgba(249, 115, 22, 0.16);
  --orange: #f97316;
  --pink: #ec4899;
  --amber: #f59e0b;
  --red: #ef4444;
  --shadow: 0 18px 45px rgba(124, 45, 18, 0.12);
  --radius: 24px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: Inter, "PingFang SC", "Microsoft YaHei", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background:
    radial-gradient(circle at 8% 8%, rgba(251, 146, 60, 0.18), transparent 28%),
    radial-gradient(circle at 92% 5%, rgba(236, 72, 153, 0.16), transparent 26%),
    linear-gradient(180deg, #fff7ed 0%, #fff 42%, #fff7ed 100%);
}

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

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: blur(18px);
  background: rgba(255, 255, 255, 0.82);
  border-bottom: 1px solid var(--line);
}

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

.header-inner {
  min-height: 72px;
  display: flex;
  align-items: center;
  gap: 22px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 900;
  font-size: 22px;
  letter-spacing: -0.03em;
  white-space: nowrap;
}

.brand-mark {
  width: 42px;
  height: 42px;
  display: inline-grid;
  place-items: center;
  color: #fff;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--orange), var(--pink));
  box-shadow: 0 12px 30px rgba(249, 115, 22, 0.32);
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-left: auto;
  overflow-x: auto;
  scrollbar-width: none;
}

.main-nav::-webkit-scrollbar {
  display: none;
}

.main-nav a {
  padding: 10px 14px;
  border-radius: 999px;
  color: #4b5563;
  font-weight: 700;
  font-size: 14px;
  white-space: nowrap;
  transition: 0.2s ease;
}

.main-nav a:hover,
.main-nav a.active {
  color: #fff;
  background: linear-gradient(135deg, var(--orange), var(--pink));
  box-shadow: 0 12px 28px rgba(249, 115, 22, 0.22);
}

.nav-toggle {
  display: none;
  border: 0;
  width: 42px;
  height: 42px;
  border-radius: 14px;
  font-size: 22px;
  background: #fff1e7;
  color: var(--orange);
}

.hero {
  position: relative;
  overflow: hidden;
  min-height: 620px;
  display: grid;
  align-items: center;
  padding: 62px 0 42px;
  background: linear-gradient(120deg, #fff7ed 0%, #fff 48%, #fdf2f8 100%);
}

.hero::before {
  content: "";
  position: absolute;
  inset: auto -12% -32% -12%;
  height: 340px;
  background: linear-gradient(90deg, rgba(249, 115, 22, 0.2), rgba(236, 72, 153, 0.2));
  filter: blur(80px);
}

.hero-inner {
  position: relative;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 430px;
  gap: 34px;
  align-items: center;
}

.hero-copy {
  padding: 10px 0;
}

.hero-label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border: 1px solid rgba(249, 115, 22, 0.24);
  border-radius: 999px;
  color: #c2410c;
  font-weight: 800;
  background: rgba(255, 247, 237, 0.86);
}

.hero h1 {
  margin: 24px 0 18px;
  font-size: clamp(42px, 6vw, 78px);
  line-height: 0.98;
  letter-spacing: -0.07em;
}

.gradient-text {
  color: transparent;
  background: linear-gradient(135deg, var(--orange), var(--pink));
  -webkit-background-clip: text;
  background-clip: text;
}

.hero-desc {
  width: min(720px, 100%);
  margin: 0 0 28px;
  font-size: 18px;
  line-height: 1.85;
  color: #4b5563;
}

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

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 20px;
  border-radius: 16px;
  font-weight: 900;
  transition: 0.2s ease;
}

.btn-primary {
  color: #fff;
  background: linear-gradient(135deg, var(--orange), var(--pink));
  box-shadow: 0 16px 35px rgba(249, 115, 22, 0.28);
}

.btn-secondary {
  color: #c2410c;
  background: #fff;
  border: 1px solid rgba(249, 115, 22, 0.2);
}

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

.hero-search {
  width: min(620px, 100%);
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: var(--shadow);
  border: 1px solid rgba(249, 115, 22, 0.15);
}

.hero-search input {
  flex: 1;
  min-width: 0;
  border: 0;
  outline: 0;
  font-size: 15px;
  background: transparent;
}

.hero-search button,
.clear-filter {
  border: 0;
  color: #fff;
  font-weight: 900;
  border-radius: 14px;
  padding: 12px 18px;
  background: linear-gradient(135deg, var(--orange), var(--pink));
  cursor: pointer;
}

.hero-panel {
  position: relative;
  min-height: 560px;
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: grid;
  align-content: end;
  overflow: hidden;
  border-radius: 34px;
  opacity: 0;
  transform: translateX(28px) scale(0.98);
  transition: opacity 0.55s ease, transform 0.55s ease;
  background: #111827;
  box-shadow: 0 30px 70px rgba(31, 41, 55, 0.24);
}

.hero-slide.active {
  opacity: 1;
  transform: none;
}

.hero-slide img {
  position: absolute;
  inset: 0;
  height: 100%;
  object-fit: cover;
}

.hero-slide::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(17, 24, 39, 0.04), rgba(17, 24, 39, 0.72));
}

.hero-slide-content {
  position: relative;
  z-index: 2;
  padding: 28px;
  color: #fff;
}

.hero-slide-content h2 {
  margin: 8px 0 10px;
  font-size: 30px;
  line-height: 1.15;
}

.hero-slide-content p {
  color: rgba(255, 255, 255, 0.82);
  line-height: 1.75;
}

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

.hero-tags span,
.tag-list span {
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
  color: #c2410c;
  background: #fff7ed;
}

.hero-slide-content .btn {
  width: fit-content;
  margin-top: 14px;
}

.hero-dots {
  position: absolute;
  left: 28px;
  right: 28px;
  bottom: 22px;
  z-index: 3;
  display: flex;
  gap: 8px;
  justify-content: flex-end;
}

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

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

.section {
  padding: 62px 0;
}

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

.kicker {
  display: inline-flex;
  margin-bottom: 9px;
  color: var(--orange);
  font-weight: 900;
  letter-spacing: 0.08em;
}

.section h2,
.page-hero h1 {
  margin: 0;
  font-size: clamp(30px, 4vw, 46px);
  letter-spacing: -0.05em;
}

.section-head p,
.page-hero p {
  max-width: 720px;
  color: var(--muted);
  line-height: 1.75;
  margin: 10px 0 0;
}

.section-link {
  display: inline-flex;
  gap: 6px;
  align-items: center;
  color: var(--orange);
  font-weight: 900;
}

.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));
}

.movie-card {
  overflow: hidden;
  border: 1px solid rgba(249, 115, 22, 0.13);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 12px 28px rgba(124, 45, 18, 0.08);
  transition: 0.24s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 24px 50px rgba(124, 45, 18, 0.14);
}

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

.large-card .poster-wrap {
  aspect-ratio: 16 / 10;
}

.poster-wrap img {
  height: 100%;
  object-fit: cover;
  transition: transform 0.36s ease;
}

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

.poster-shine {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 55%, rgba(17, 24, 39, 0.58));
}

.rank-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  z-index: 2;
  min-width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  color: #fff;
  font-weight: 900;
  border-radius: 13px;
  background: linear-gradient(135deg, var(--red), var(--amber));
  box-shadow: 0 10px 25px rgba(239, 68, 68, 0.28);
}

.card-body {
  padding: 18px;
}

.card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: #9a3412;
  font-size: 12px;
  font-weight: 800;
}

.card-body h3 {
  margin: 10px 0 8px;
  font-size: 19px;
  line-height: 1.3;
}

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

.card-body p {
  margin: 0 0 14px;
  color: var(--muted);
  line-height: 1.65;
  font-size: 14px;
}

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

.category-card {
  min-height: 178px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 22px;
  border-radius: var(--radius);
  color: #fff;
  background: linear-gradient(135deg, var(--orange), var(--pink));
  box-shadow: 0 18px 38px rgba(249, 115, 22, 0.2);
}

.category-card:nth-child(even) {
  background: linear-gradient(135deg, #fb7185, #f59e0b);
}

.category-card h3 {
  margin: 0 0 8px;
  font-size: 24px;
}

.category-card p {
  margin: 0;
  color: rgba(255, 255, 255, 0.82);
  line-height: 1.65;
}

.category-card strong {
  margin-top: 18px;
  font-size: 14px;
}

.page-hero {
  padding: 72px 0 34px;
}

.page-hero-inner {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 34px;
  border-radius: 32px;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.92), rgba(255, 247, 237, 0.9));
  border: 1px solid rgba(249, 115, 22, 0.16);
  box-shadow: var(--shadow);
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-bottom: 14px;
  color: #9a3412;
  font-size: 14px;
  font-weight: 800;
}

.filter-panel {
  display: grid;
  grid-template-columns: 1fr 180px auto;
  gap: 14px;
  align-items: end;
  margin: 0 0 28px;
  padding: 18px;
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.86);
  border: 1px solid rgba(249, 115, 22, 0.14);
  box-shadow: 0 12px 30px rgba(124, 45, 18, 0.08);
}

.search-box,
.select-box {
  display: grid;
  gap: 8px;
  color: #9a3412;
  font-size: 13px;
  font-weight: 900;
}

.search-box input,
.select-box select {
  width: 100%;
  border: 1px solid rgba(249, 115, 22, 0.18);
  border-radius: 15px;
  outline: 0;
  min-height: 46px;
  padding: 0 14px;
  color: var(--ink);
  background: #fff;
}

.ranking-list {
  display: grid;
  gap: 15px;
}

.ranking-row {
  display: grid;
  grid-template-columns: 58px 86px 1fr auto;
  gap: 18px;
  align-items: center;
  padding: 14px;
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid rgba(249, 115, 22, 0.12);
  box-shadow: 0 10px 28px rgba(124, 45, 18, 0.07);
}

.ranking-row .num {
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  border-radius: 15px;
  color: #fff;
  font-weight: 900;
  background: linear-gradient(135deg, var(--orange), var(--pink));
}

.ranking-row img {
  height: 104px;
  object-fit: cover;
  border-radius: 16px;
}

.ranking-row h3 {
  margin: 0 0 8px;
  font-size: 20px;
}

.ranking-row p {
  margin: 0;
  color: var(--muted);
  line-height: 1.65;
}

.ranking-row .score {
  color: #c2410c;
  font-weight: 900;
  white-space: nowrap;
}

.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 28px;
  align-items: start;
}

.player-card,
.info-card,
.side-card {
  overflow: hidden;
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid rgba(249, 115, 22, 0.14);
  box-shadow: var(--shadow);
}

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

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

.play-trigger {
  position: absolute;
  inset: 0;
  z-index: 3;
  display: grid;
  place-items: center;
  border: 0;
  color: #fff;
  cursor: pointer;
  background: radial-gradient(circle, rgba(17, 24, 39, 0.04), rgba(17, 24, 39, 0.52));
}

.play-trigger span {
  width: 82px;
  height: 82px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  font-size: 32px;
  padding-left: 5px;
  background: linear-gradient(135deg, var(--orange), var(--pink));
  box-shadow: 0 22px 45px rgba(249, 115, 22, 0.35);
}

.play-trigger.is-hidden {
  display: none;
}

.detail-content {
  padding: 24px;
}

.detail-content h1 {
  margin: 0 0 12px;
  font-size: clamp(30px, 4vw, 48px);
  line-height: 1.1;
  letter-spacing: -0.05em;
}

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

.detail-meta span {
  padding: 7px 11px;
  border-radius: 999px;
  color: #c2410c;
  background: #fff7ed;
  font-weight: 800;
  font-size: 13px;
}

.detail-content p {
  color: #4b5563;
  line-height: 1.9;
}

.info-card {
  padding: 24px;
  margin-top: 24px;
}

.info-card h2,
.side-card h2 {
  margin: 0 0 16px;
  font-size: 24px;
}

.side-card {
  padding: 18px;
}

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

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

.related-list {
  display: grid;
  gap: 12px;
}

.related-item {
  display: grid;
  grid-template-columns: 72px 1fr;
  gap: 12px;
  align-items: center;
  padding: 9px;
  border-radius: 16px;
  transition: 0.2s ease;
}

.related-item:hover {
  background: #fff7ed;
}

.related-item img {
  height: 92px;
  object-fit: cover;
  border-radius: 13px;
}

.related-item h3 {
  margin: 0 0 6px;
  font-size: 15px;
  line-height: 1.35;
}

.related-item p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}

.site-footer {
  margin-top: 40px;
  padding: 40px 0;
  background: #111827;
  color: #fff;
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  align-items: center;
  justify-content: space-between;
}

.footer-brand {
  font-size: 22px;
  font-weight: 900;
}

.footer-links {
  display: flex;
  gap: 16px;
}

.footer-links a {
  color: rgba(255, 255, 255, 0.78);
}

.footer-inner p {
  width: 100%;
  margin: 4px 0 0;
  color: rgba(255, 255, 255, 0.6);
}

.hidden-by-filter {
  display: none !important;
}

@media (max-width: 1024px) {
  .hero-inner,
  .detail-layout {
    grid-template-columns: 1fr;
  }

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

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

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

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

  .main-nav {
    position: fixed;
    left: 16px;
    right: 16px;
    top: 74px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    padding: 14px;
    border-radius: 22px;
    background: rgba(255, 255, 255, 0.96);
    border: 1px solid var(--line);
    box-shadow: var(--shadow);
  }

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

  .nav-toggle {
    display: inline-grid;
    place-items: center;
    margin-left: auto;
  }

  .hero {
    padding-top: 34px;
  }

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

  .hero-search,
  .hero-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .hero-panel {
    min-height: 460px;
  }

  .hero-slide-content {
    padding: 22px;
  }

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

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

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

  .ranking-row {
    grid-template-columns: 42px 70px 1fr;
  }

  .ranking-row .score {
    grid-column: 3;
  }
}

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

  .ranking-row {
    grid-template-columns: 40px 1fr;
  }

  .ranking-row img {
    display: none;
  }

  .ranking-row .score {
    grid-column: 2;
  }
}
