:root {
  --bg-soft: #fff7ed;
  --bg-page: #fffbeb;
  --bg-card: #ffffff;
  --text-main: #1f2937;
  --text-muted: #6b7280;
  --line: #fde68a;
  --amber: #f59e0b;
  --amber-dark: #d97706;
  --orange: #f97316;
  --red: #ef4444;
  --shadow-card: 0 18px 45px rgba(146, 64, 14, 0.12);
  --shadow-soft: 0 10px 25px rgba(146, 64, 14, 0.08);
  --radius-lg: 18px;
  --radius-xl: 28px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--text-main);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  background:
    radial-gradient(circle at 12% 6%, rgba(251, 191, 36, 0.18), transparent 26rem),
    radial-gradient(circle at 88% 14%, rgba(249, 115, 22, 0.14), transparent 24rem),
    linear-gradient(135deg, #fffbeb 0%, #fff7ed 48%, #fef3c7 100%);
}

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

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

button,
input,
select,
textarea {
  font: inherit;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid rgba(253, 230, 138, 0.85);
  background: rgba(255, 255, 255, 0.86);
  backdrop-filter: blur(18px);
}

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

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-width: max-content;
}

.brand-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 14px;
  color: #ffffff;
  font-weight: 900;
  background: linear-gradient(135deg, #fbbf24, #f97316);
  box-shadow: 0 12px 24px rgba(249, 115, 22, 0.22);
  transition: transform 0.3s ease;
}

.brand:hover .brand-mark {
  transform: rotate(10deg) scale(1.04);
}

.brand-text {
  font-size: 21px;
  font-weight: 900;
  letter-spacing: -0.02em;
  background: linear-gradient(90deg, var(--amber-dark), var(--orange));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

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

.nav-link {
  color: #374151;
  font-weight: 700;
  transition: color 0.2s ease;
}

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

.header-search {
  display: flex;
  align-items: center;
  overflow: hidden;
  border: 1px solid #fde68a;
  border-radius: 999px;
  background: #ffffff;
}

.header-search input {
  width: 210px;
  border: 0;
  outline: 0;
  padding: 10px 12px 10px 16px;
  background: transparent;
}

.header-search button {
  border: 0;
  padding: 10px 16px;
  color: #ffffff;
  font-weight: 800;
  background: linear-gradient(90deg, var(--amber), var(--orange));
  cursor: pointer;
}

.menu-toggle {
  display: none;
  margin-left: auto;
  border: 0;
  border-radius: 12px;
  padding: 8px 12px;
  color: #78350f;
  background: #fef3c7;
}

.mobile-nav {
  display: none;
  padding: 0 16px 16px;
  border-top: 1px solid #fde68a;
}

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

.mobile-nav-link {
  padding: 11px 14px;
  border-radius: 12px;
  color: #374151;
  background: #ffffff;
}

.hero {
  position: relative;
  height: 70vh;
  min-height: 560px;
  overflow: hidden;
  background: #111827;
}

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

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

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

.hero-slide.image-fallback {
  background:
    linear-gradient(110deg, rgba(0, 0, 0, 0.88), rgba(120, 53, 15, 0.55), rgba(251, 191, 36, 0.22)),
    radial-gradient(circle at 70% 20%, rgba(249, 115, 22, 0.55), transparent 22rem),
    #111827;
}

.hero-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(0, 0, 0, 0.82) 0%, rgba(0, 0, 0, 0.56) 42%, rgba(0, 0, 0, 0.1) 100%);
}

.hero-content {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
}

.hero-copy {
  width: min(680px, 100%);
  color: #ffffff;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 18px;
  color: #fbbf24;
  font-size: 18px;
  font-weight: 900;
}

.hero h1 {
  margin: 0 0 18px;
  font-size: clamp(40px, 7vw, 74px);
  line-height: 1.04;
  letter-spacing: -0.05em;
}

.hero p {
  margin: 0 0 26px;
  color: #e5e7eb;
  font-size: clamp(18px, 2vw, 23px);
  line-height: 1.65;
}

.hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 28px;
}

.hero-meta span {
  border-radius: 999px;
  padding: 9px 15px;
  color: #ffffff;
  font-weight: 800;
  background: rgba(245, 158, 11, 0.92);
  backdrop-filter: blur(10px);
}

.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

.button-primary,
.button-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 46px;
  border-radius: 999px;
  padding: 12px 22px;
  font-weight: 900;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.button-primary {
  color: #ffffff;
  background: linear-gradient(90deg, var(--amber), var(--orange));
  box-shadow: 0 14px 30px rgba(249, 115, 22, 0.28);
}

.button-secondary {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.22);
  backdrop-filter: blur(12px);
}

.button-primary:hover,
.button-secondary:hover {
  transform: translateY(-2px) scale(1.02);
}

.hero-arrow {
  position: absolute;
  top: 50%;
  z-index: 2;
  transform: translateY(-50%);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 46px;
  height: 46px;
  border: 0;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(0, 0, 0, 0.48);
  cursor: pointer;
  transition: background 0.2s ease;
}

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

.hero-prev {
  left: 18px;
}

.hero-next {
  right: 18px;
}

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

.hero-dots button {
  width: 10px;
  height: 10px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.52);
  cursor: pointer;
  transition: width 0.25s ease, background 0.25s ease;
}

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

.page-main {
  padding: 64px 0;
}

.section-stack {
  display: grid;
  gap: 68px;
}

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

.section-heading h1,
.section-heading h2 {
  display: inline;
  margin: 0;
  font-size: clamp(28px, 3vw, 40px);
  line-height: 1.12;
  letter-spacing: -0.03em;
}

.section-heading p {
  margin: 10px 0 0;
  color: var(--text-muted);
  line-height: 1.7;
}

.section-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  margin-right: 12px;
  border-radius: 14px;
  color: #ffffff;
  font-size: 22px;
  background: linear-gradient(135deg, #fbbf24, #f97316);
  box-shadow: var(--shadow-soft);
  vertical-align: middle;
}

.section-more {
  color: var(--amber-dark);
  font-weight: 900;
}

.scroller {
  overflow-x: auto;
  margin-inline: -16px;
  padding: 4px 16px 18px;
}

.scroller-row {
  display: flex;
  gap: 22px;
  min-width: max-content;
}

.scroller-row .movie-card {
  width: 300px;
}

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

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

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

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

.movie-card-link {
  display: block;
  height: 100%;
}

.poster-frame {
  position: relative;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  background:
    linear-gradient(135deg, rgba(251, 191, 36, 0.95), rgba(249, 115, 22, 0.85)),
    #fef3c7;
}

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

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

.poster-frame.image-fallback::after {
  content: "高清剧集";
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(255, 255, 255, 0.92);
  font-size: 22px;
  font-weight: 900;
  letter-spacing: 0.08em;
}

.poster-overlay {
  position: absolute;
  inset: auto 0 0;
  display: flex;
  justify-content: center;
  padding: 42px 12px 14px;
  background: linear-gradient(transparent, rgba(0, 0, 0, 0.72));
  opacity: 0;
  transition: opacity 0.24s ease;
}

.movie-card:hover .poster-overlay {
  opacity: 1;
}

.play-pill {
  border-radius: 999px;
  padding: 9px 16px;
  color: #ffffff;
  font-weight: 900;
  background: linear-gradient(90deg, var(--amber), var(--orange));
}

.rank-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  z-index: 1;
  min-width: 34px;
  border-radius: 999px;
  padding: 7px 9px;
  color: #ffffff;
  font-weight: 900;
  text-align: center;
  background: linear-gradient(135deg, #ef4444, #f97316);
  box-shadow: 0 8px 20px rgba(239, 68, 68, 0.28);
}

.movie-card-body {
  padding: 16px;
}

.movie-meta-line {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 10px;
}

.movie-meta-line span {
  border-radius: 999px;
  padding: 4px 8px;
  color: #92400e;
  font-size: 12px;
  font-weight: 800;
  background: #fef3c7;
}

.movie-card h3 {
  margin: 0 0 9px;
  font-size: 18px;
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.movie-card p {
  margin: 0;
  color: var(--text-muted);
  font-size: 14px;
  line-height: 1.62;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 14px;
}

.tag-row span {
  border: 1px solid #fde68a;
  border-radius: 999px;
  padding: 4px 8px;
  color: #a16207;
  font-size: 12px;
  background: #fffbeb;
}

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

.category-tile {
  position: relative;
  overflow: hidden;
  min-height: 150px;
  border-radius: var(--radius-lg);
  padding: 22px;
  color: #ffffff;
  background: linear-gradient(135deg, #f59e0b, #f97316);
  box-shadow: var(--shadow-soft);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.category-tile::after {
  content: "";
  position: absolute;
  right: -36px;
  bottom: -42px;
  width: 128px;
  height: 128px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
}

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

.category-tile h2,
.category-tile h3 {
  position: relative;
  z-index: 1;
  margin: 0 0 9px;
  font-size: 22px;
}

.category-tile p,
.category-tile span {
  position: relative;
  z-index: 1;
  display: block;
  margin: 0;
  color: rgba(255, 255, 255, 0.9);
  line-height: 1.6;
}

.filter-panel {
  display: grid;
  grid-template-columns: 1.6fr 1fr 1fr 1fr auto auto;
  gap: 14px;
  align-items: end;
  margin-bottom: 28px;
  border: 1px solid #fde68a;
  border-radius: var(--radius-xl);
  padding: 20px;
  background: rgba(255, 255, 255, 0.88);
  box-shadow: var(--shadow-soft);
}

.filter-field label {
  display: block;
  margin-bottom: 8px;
  color: #92400e;
  font-size: 13px;
  font-weight: 900;
}

.filter-field input,
.filter-field select {
  width: 100%;
  border: 1px solid #fde68a;
  border-radius: 14px;
  outline: 0;
  padding: 11px 12px;
  color: #374151;
  background: #ffffff;
}

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

.filter-reset {
  border: 0;
  border-radius: 14px;
  padding: 12px 16px;
  color: #ffffff;
  font-weight: 900;
  background: linear-gradient(90deg, var(--amber), var(--orange));
  cursor: pointer;
}

.filter-count {
  color: #92400e;
  font-weight: 800;
  white-space: nowrap;
}

.page-hero {
  border-radius: var(--radius-xl);
  padding: 40px;
  color: #ffffff;
  background:
    linear-gradient(135deg, rgba(120, 53, 15, 0.96), rgba(249, 115, 22, 0.82)),
    radial-gradient(circle at 80% 12%, rgba(255, 255, 255, 0.24), transparent 18rem);
  box-shadow: var(--shadow-card);
}

.page-hero h1 {
  margin: 0 0 12px;
  font-size: clamp(34px, 4vw, 54px);
  letter-spacing: -0.04em;
}

.page-hero p {
  max-width: 820px;
  margin: 0;
  color: rgba(255, 255, 255, 0.88);
  font-size: 18px;
  line-height: 1.8;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 24px;
  color: #92400e;
  font-size: 14px;
  font-weight: 700;
}

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

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

.player-card,
.content-card,
.related-card {
  border-radius: var(--radius-xl);
  background: rgba(255, 255, 255, 0.94);
  box-shadow: var(--shadow-soft);
  overflow: hidden;
}

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

.player-box video {
  width: 100%;
  height: 100%;
  background: #000000;
}

.player-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px;
  padding: 18px 20px;
  border-top: 1px solid #fef3c7;
}

.play-button {
  border: 0;
  border-radius: 999px;
  padding: 12px 18px;
  color: #ffffff;
  font-weight: 900;
  background: linear-gradient(90deg, var(--amber), var(--orange));
  cursor: pointer;
}

.player-actions span {
  color: var(--text-muted);
  font-size: 14px;
}

.detail-title-card {
  padding: 26px;
  border-bottom: 1px solid #fef3c7;
}

.detail-title-card h1 {
  margin: 0 0 12px;
  font-size: clamp(30px, 4vw, 48px);
  line-height: 1.18;
  letter-spacing: -0.04em;
}

.detail-title-card p {
  margin: 0;
  color: var(--text-muted);
  font-size: 18px;
  line-height: 1.75;
}

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

.detail-meta span {
  border-radius: 999px;
  padding: 8px 12px;
  color: #92400e;
  font-weight: 900;
  background: #fef3c7;
}

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

.content-card h2 {
  margin: 0 0 14px;
  font-size: 24px;
}

.content-card p {
  margin: 0 0 24px;
  color: #374151;
  line-height: 1.9;
  white-space: pre-line;
}

.content-card p:last-child {
  margin-bottom: 0;
}

.related-card {
  position: sticky;
  top: 96px;
  padding: 22px;
}

.related-card h2 {
  margin: 0 0 18px;
  font-size: 22px;
}

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

.related-item {
  display: grid;
  grid-template-columns: 96px 1fr;
  gap: 12px;
  align-items: center;
}

.related-thumb {
  aspect-ratio: 3 / 2;
  border-radius: 12px;
  overflow: hidden;
  background: linear-gradient(135deg, #fbbf24, #f97316);
}

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

.related-info h3 {
  margin: 0 0 6px;
  font-size: 15px;
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

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

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

.rank-row {
  display: grid;
  grid-template-columns: 64px 120px 1fr auto;
  gap: 18px;
  align-items: center;
  border-radius: 20px;
  padding: 14px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: var(--shadow-soft);
}

.rank-number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 46px;
  height: 46px;
  border-radius: 999px;
  color: #ffffff;
  font-weight: 900;
  background: linear-gradient(135deg, #ef4444, #f97316);
}

.rank-cover {
  aspect-ratio: 3 / 2;
  border-radius: 14px;
  overflow: hidden;
  background: linear-gradient(135deg, #fbbf24, #f97316);
}

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

.rank-row h2 {
  margin: 0 0 8px;
  font-size: 20px;
}

.rank-row p {
  margin: 0;
  color: var(--text-muted);
  line-height: 1.6;
}

.rank-watch {
  border-radius: 999px;
  padding: 10px 16px;
  color: #ffffff;
  font-weight: 900;
  background: linear-gradient(90deg, var(--amber), var(--orange));
}

.empty-state {
  display: none;
  border-radius: var(--radius-xl);
  padding: 40px;
  text-align: center;
  color: var(--text-muted);
  background: #ffffff;
  box-shadow: var(--shadow-soft);
}

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

.site-footer {
  margin-top: 64px;
  border-top: 1px solid #fde68a;
  background: rgba(255, 255, 255, 0.82);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 32px;
  padding: 38px 0;
}

.footer-logo {
  margin-bottom: 12px;
  font-size: 22px;
  font-weight: 900;
  color: var(--amber-dark);
}

.site-footer h2 {
  margin: 0 0 12px;
  font-size: 17px;
}

.site-footer p {
  margin: 0;
  color: var(--text-muted);
  line-height: 1.8;
}

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

.footer-links a {
  color: var(--text-muted);
}

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

.footer-bottom {
  border-top: 1px solid #fef3c7;
  padding: 16px;
  color: var(--text-muted);
  text-align: center;
}

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

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

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

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

  .related-card {
    position: static;
  }
}

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

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

  .hero {
    min-height: 620px;
    height: 74vh;
  }

  .hero-arrow {
    display: none;
  }

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

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

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

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

  .rank-row {
    grid-template-columns: 48px 94px 1fr;
  }

  .rank-watch {
    grid-column: 2 / -1;
    text-align: center;
  }

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

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

  .brand-text {
    font-size: 18px;
  }

  .hero {
    min-height: 560px;
  }

  .hero-copy {
    padding-top: 30px;
  }

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

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

  .page-hero {
    padding: 28px;
  }

  .detail-title-card,
  .content-card {
    padding: 22px;
  }
}
