:root {
  color-scheme: light;
  --orange: #ea580c;
  --orange-dark: #c2410c;
  --amber: #d97706;
  --amber-soft: #fff7ed;
  --cream: #fffbeb;
  --text: #1f2937;
  --muted: #6b7280;
  --line: #fed7aa;
  --dark: #111827;
  --shadow: 0 18px 45px rgba(154, 52, 18, 0.16);
  --soft-shadow: 0 12px 28px rgba(17, 24, 39, 0.10);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  color: var(--text);
  background: linear-gradient(180deg, #fff7ed 0%, #fffaf0 42%, #ffffff 100%);
  -webkit-font-smoothing: antialiased;
}

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

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

button,
input,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: linear-gradient(90deg, rgba(255, 247, 237, 0.96), rgba(255, 251, 235, 0.96));
  box-shadow: 0 8px 25px rgba(146, 64, 14, 0.10);
  backdrop-filter: blur(18px);
}

.nav-shell {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  min-height: 74px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.logo-link,
.footer-brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.logo-mark {
  width: 42px;
  height: 42px;
  border-radius: 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  font-weight: 800;
  background: linear-gradient(135deg, var(--orange), var(--amber));
  box-shadow: 0 14px 30px rgba(234, 88, 12, 0.30);
}

.logo-copy strong {
  display: block;
  font-size: 24px;
  line-height: 1.1;
  letter-spacing: -0.03em;
  background: linear-gradient(90deg, var(--orange), var(--amber));
  -webkit-background-clip: text;
  color: transparent;
}

.logo-copy small {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 6px;
}

.nav-link,
.mobile-link {
  padding: 10px 17px;
  border-radius: 14px;
  color: #374151;
  font-weight: 700;
  transition: 0.28s ease;
}

.nav-link:hover,
.mobile-link:hover,
.nav-link.active,
.mobile-link.active {
  color: #ffffff;
  background: linear-gradient(90deg, var(--orange), var(--amber));
  box-shadow: 0 12px 24px rgba(234, 88, 12, 0.24);
}

.menu-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 14px;
  color: #7c2d12;
  background: #ffedd5;
}

.mobile-panel {
  display: none;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 0 0 16px;
}

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

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

.hero-section {
  position: relative;
  overflow: hidden;
  min-height: 660px;
  color: #ffffff;
  background: radial-gradient(circle at 22% 22%, rgba(251, 191, 36, 0.42), transparent 28%), linear-gradient(135deg, #9a3412 0%, #ea580c 48%, #f59e0b 100%);
}

.hero-section::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(17, 24, 39, 0.65), rgba(17, 24, 39, 0.20)), var(--hero-image, none) center / cover no-repeat;
  opacity: 0.78;
}

.hero-section::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 150px;
  background: linear-gradient(0deg, #fff7ed 0%, rgba(255, 247, 237, 0) 100%);
}

.hero-inner {
  position: relative;
  z-index: 2;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 86px 0 118px;
}

.hero-track {
  position: relative;
  min-height: 474px;
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 330px;
  align-items: center;
  gap: 52px;
  opacity: 0;
  pointer-events: none;
  transform: translateY(22px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

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

.hero-kicker {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 9px 14px;
  border: 1px solid rgba(255, 255, 255, 0.30);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.16);
  box-shadow: 0 18px 45px rgba(17, 24, 39, 0.22);
  backdrop-filter: blur(16px);
  font-size: 14px;
  font-weight: 700;
}

.hero-title {
  margin: 24px 0 16px;
  font-size: clamp(42px, 7vw, 78px);
  line-height: 0.98;
  letter-spacing: -0.06em;
  text-shadow: 0 16px 34px rgba(0, 0, 0, 0.34);
}

.hero-desc {
  width: min(720px, 100%);
  font-size: 20px;
  line-height: 1.85;
  color: rgba(255, 255, 255, 0.90);
}

.hero-tags,
.detail-tags,
.rank-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
}

.hero-tags {
  margin-top: 22px;
}

.hero-tags span,
.detail-tags span,
.rank-tags span {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 5px 11px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 700;
}

.hero-tags span {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.18);
  border: 1px solid rgba(255, 255, 255, 0.24);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px;
  margin-top: 32px;
}

.primary-button,
.secondary-button,
.text-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 20px;
  border-radius: 999px;
  font-weight: 800;
  transition: 0.28s ease;
}

.primary-button {
  color: var(--orange);
  background: #ffffff;
  box-shadow: 0 20px 45px rgba(17, 24, 39, 0.24);
}

.primary-button:hover {
  transform: translateY(-2px) scale(1.02);
  background: #fff7ed;
}

.secondary-button {
  color: #ffffff;
  border: 2px solid rgba(255, 255, 255, 0.82);
}

.secondary-button:hover {
  color: var(--orange);
  background: #ffffff;
}

.text-button {
  min-height: 38px;
  color: #ffffff;
  background: linear-gradient(90deg, var(--orange), var(--amber));
  box-shadow: 0 10px 22px rgba(234, 88, 12, 0.20);
  white-space: nowrap;
}

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

.hero-poster {
  position: relative;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  border-radius: 32px;
  box-shadow: 0 35px 80px rgba(17, 24, 39, 0.45);
  transform: rotate(2deg);
}

.hero-poster img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: 0.7s ease;
}

.hero-slide:hover .hero-poster img {
  transform: scale(1.06);
}

.hero-search {
  position: relative;
  z-index: 3;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  margin-top: 26px;
  padding: 12px;
  width: min(720px, 100%);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.20);
  border: 1px solid rgba(255, 255, 255, 0.26);
  backdrop-filter: blur(18px);
}

.hero-search input {
  min-height: 52px;
  border: 0;
  outline: 0;
  border-radius: 16px;
  padding: 0 18px;
  color: #111827;
}

.hero-search button,
.filter-bar button {
  border: 0;
  min-height: 52px;
  border-radius: 16px;
  padding: 0 24px;
  color: #ffffff;
  font-weight: 800;
  background: linear-gradient(90deg, var(--orange), var(--amber));
}

.hero-dots {
  position: relative;
  z-index: 3;
  display: flex;
  gap: 10px;
  margin-top: 30px;
}

.hero-dot {
  width: 40px;
  height: 8px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.38);
  transition: 0.28s ease;
}

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

.section-block {
  padding: 70px 0;
}

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

.section-label {
  display: inline-flex;
  color: var(--orange);
  font-size: 14px;
  font-weight: 900;
  letter-spacing: 0.1em;
}

.section-head h1,
.section-head h2,
.page-hero h1,
.detail-title h1 {
  margin: 6px 0 0;
  font-size: clamp(30px, 4vw, 46px);
  line-height: 1.15;
  letter-spacing: -0.04em;
}

.section-head p,
.page-hero p,
.detail-title p {
  color: var(--muted);
  line-height: 1.8;
  max-width: 780px;
}

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

.category-tile {
  position: relative;
  min-height: 210px;
  overflow: hidden;
  border-radius: 24px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--orange), var(--amber));
  box-shadow: var(--soft-shadow);
  transition: 0.35s ease;
}

.category-tile:hover {
  transform: translateY(-6px) scale(1.01);
  box-shadow: var(--shadow);
}

.category-tile img {
  width: 100%;
  height: 100%;
  min-height: 210px;
  object-fit: cover;
  transition: 0.6s ease;
}

.category-tile:hover img {
  transform: scale(1.08);
}

.category-gradient {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(17, 24, 39, 0.08), rgba(154, 52, 18, 0.85));
}

.category-tile strong,
.category-tile em {
  position: absolute;
  left: 20px;
  right: 20px;
  z-index: 2;
}

.category-tile strong {
  bottom: 58px;
  font-size: 23px;
  font-style: normal;
}

.category-tile em {
  bottom: 20px;
  color: rgba(255, 255, 255, 0.82);
  font-size: 13px;
  line-height: 1.55;
}

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

.movie-card {
  overflow: hidden;
  border-radius: 22px;
  background: #ffffff;
  box-shadow: var(--soft-shadow);
  transition: 0.35s ease;
}

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

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

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

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

.year-badge,
.rank-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 2;
  padding: 5px 9px;
  border-radius: 999px;
  color: #ffffff;
  font-size: 12px;
  font-weight: 800;
  background: linear-gradient(90deg, var(--orange), var(--amber));
  box-shadow: 0 10px 22px rgba(0, 0, 0, 0.20);
}

.rank-badge {
  left: 12px;
  right: auto;
  background: linear-gradient(90deg, #ef4444, #f97316);
}

.poster-mask {
  position: absolute;
  inset: auto 0 0;
  padding: 38px 12px 12px;
  color: #ffffff;
  font-size: 12px;
  line-height: 1.55;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.82), rgba(0, 0, 0, 0));
  opacity: 0;
  transition: 0.28s ease;
}

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

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

.movie-card-body h3 {
  margin: 0 0 8px;
  font-size: 15px;
  line-height: 1.35;
}

.movie-card-body h3 a:hover,
.rank-info h3 a:hover,
.breadcrumb a:hover {
  color: var(--orange);
}

.movie-card-body p {
  min-height: 42px;
  margin: 0 0 12px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.65;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  color: #9ca3af;
  font-size: 12px;
}

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

.page-hero-card {
  position: relative;
  overflow: hidden;
  border-radius: 32px;
  padding: clamp(28px, 5vw, 58px);
  color: #ffffff;
  background: radial-gradient(circle at 84% 12%, rgba(253, 186, 116, 0.65), transparent 25%), linear-gradient(135deg, #9a3412, var(--orange), var(--amber));
  box-shadow: var(--shadow);
}

.page-hero-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(17, 24, 39, 0.35), rgba(17, 24, 39, 0));
}

.page-hero-card > * {
  position: relative;
  z-index: 2;
}

.page-hero-card p {
  color: rgba(255, 255, 255, 0.85);
}

.filter-bar {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) 190px 190px auto;
  gap: 12px;
  margin: 28px 0 32px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.84);
  box-shadow: var(--soft-shadow);
}

.filter-bar label {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.filter-bar input,
.filter-bar select {
  width: 100%;
  min-height: 48px;
  border: 1px solid #fed7aa;
  border-radius: 15px;
  outline: 0;
  padding: 0 14px;
  color: var(--text);
  background: #ffffff;
}

.filter-bar input:focus,
.filter-bar select:focus {
  border-color: var(--orange);
  box-shadow: 0 0 0 4px rgba(234, 88, 12, 0.12);
}

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

.rank-row {
  display: grid;
  grid-template-columns: 70px 84px minmax(0, 1fr) auto;
  align-items: center;
  gap: 18px;
  padding: 14px;
  border: 1px solid #ffedd5;
  border-radius: 24px;
  background: #ffffff;
  box-shadow: var(--soft-shadow);
  transition: 0.3s ease;
}

.rank-row:hover {
  transform: translateY(-3px);
  border-color: #fdba74;
  box-shadow: var(--shadow);
}

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

.rank-cover {
  display: block;
  width: 84px;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  border-radius: 16px;
  background: #ffedd5;
}

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

.rank-info h3 {
  margin: 0 0 8px;
  font-size: 19px;
}

.rank-info p {
  margin: 0 0 10px;
  color: var(--muted);
  line-height: 1.65;
}

.rank-tags span,
.detail-tags span {
  color: var(--orange-dark);
  background: #ffedd5;
}

.detail-wrap {
  padding: 48px 0 72px;
}

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

.detail-hero {
  display: grid;
  grid-template-columns: 300px minmax(0, 1fr);
  gap: 34px;
  align-items: start;
  padding: 28px;
  border-radius: 32px;
  background: rgba(255, 255, 255, 0.82);
  box-shadow: var(--shadow);
}

.detail-poster {
  overflow: hidden;
  border-radius: 26px;
  box-shadow: 0 24px 54px rgba(17, 24, 39, 0.18);
  background: #ffedd5;
}

.detail-poster img {
  width: 100%;
  aspect-ratio: 2 / 3;
  object-fit: cover;
}

.detail-title h1 {
  margin-top: 0;
}

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

.meta-line span {
  display: inline-flex;
  align-items: center;
  padding: 7px 12px;
  border-radius: 999px;
  color: #7c2d12;
  font-weight: 800;
  background: #ffedd5;
}

.detail-copy {
  display: grid;
  gap: 18px;
  margin-top: 28px;
}

.copy-card {
  padding: 24px;
  border-radius: 24px;
  background: #ffffff;
  box-shadow: var(--soft-shadow);
}

.copy-card h2 {
  margin: 0 0 12px;
  color: #111827;
  font-size: 24px;
}

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

.watch-section {
  margin-top: 34px;
}

.watch-panel {
  position: relative;
  overflow: hidden;
  border-radius: 30px;
  background: #0f172a;
  box-shadow: 0 28px 70px rgba(17, 24, 39, 0.28);
  aspect-ratio: 16 / 9;
}

.watch-video {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #000000;
}

.play-layer {
  position: absolute;
  inset: 0;
  z-index: 3;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 0;
  padding: 0;
  overflow: hidden;
  color: #ffffff;
  background: #0f172a;
}

.play-layer img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.72;
  filter: blur(1px) brightness(0.72);
  transform: scale(1.02);
}

.play-layer::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at center, rgba(251, 146, 60, 0.18), rgba(15, 23, 42, 0.78));
}

.play-icon {
  position: relative;
  z-index: 2;
  width: 92px;
  height: 92px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding-left: 6px;
  color: var(--orange);
  font-size: 42px;
  background: #ffffff;
  box-shadow: 0 22px 50px rgba(0, 0, 0, 0.35);
  transition: 0.28s ease;
}

.play-layer:hover .play-icon {
  transform: scale(1.08);
}

.watch-panel.is-playing .play-layer {
  display: none;
}

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

.prev-next {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  margin-top: 26px;
}

.prev-next a {
  flex: 1;
  padding: 18px;
  border-radius: 18px;
  color: #7c2d12;
  font-weight: 800;
  background: #ffedd5;
}

.prev-next a:last-child {
  text-align: right;
}

.empty-state {
  display: none;
  padding: 28px;
  border-radius: 22px;
  color: var(--muted);
  background: #ffffff;
  box-shadow: var(--soft-shadow);
}

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

.site-footer {
  margin-top: 40px;
  color: #e5e7eb;
  background: linear-gradient(135deg, #111827, #1f2937 58%, #111827);
}

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

.footer-brand strong {
  display: block;
  color: #ffffff;
  font-size: 21px;
}

.footer-brand p {
  margin: 6px 0 0;
  max-width: 560px;
  color: #9ca3af;
  line-height: 1.7;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 20px;
  margin: 28px 0;
}

.footer-links a {
  color: #d1d5db;
  font-size: 14px;
}

.footer-links a:hover {
  color: #fb923c;
}

.copyright {
  margin: 0;
  padding-top: 24px;
  color: #9ca3af;
  border-top: 1px solid rgba(255, 255, 255, 0.10);
  font-size: 14px;
}

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

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

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

  .menu-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  .logo-copy strong {
    font-size: 20px;
  }

  .hero-section {
    min-height: 780px;
  }

  .hero-slide {
    grid-template-columns: 1fr;
    gap: 28px;
  }

  .hero-poster {
    width: min(260px, 72vw);
    margin: 0 auto;
  }

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

  .section-head {
    display: grid;
  }

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

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

  .rank-row .text-button {
    grid-column: 2 / -1;
    justify-self: start;
  }

  .rank-index {
    width: 44px;
    height: 44px;
    font-size: 15px;
  }

  .rank-cover {
    width: 68px;
  }

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

  .detail-poster {
    width: min(260px, 82vw);
    margin: 0 auto;
  }

  .prev-next {
    flex-direction: column;
  }

  .prev-next a:last-child {
    text-align: left;
  }
}

@media (max-width: 520px) {
  .main-shell,
  .nav-shell,
  .footer-shell,
  .hero-inner {
    width: min(100% - 24px, 1180px);
  }

  .hero-inner {
    padding-top: 56px;
  }

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

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

  .category-grid,
  .movie-grid,
  .related-grid {
    gap: 12px;
  }

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

  .movie-card-body p {
    display: none;
  }

  .copy-card,
  .detail-hero {
    padding: 18px;
    border-radius: 22px;
  }

  .play-icon {
    width: 72px;
    height: 72px;
    font-size: 32px;
  }
}
