* {
  box-sizing: border-box;
}

:root {
  --brand: #ea580c;
  --brand-dark: #c2410c;
  --brand-red: #dc2626;
  --ink: #111827;
  --muted: #6b7280;
  --line: #e5e7eb;
  --bg: #f9fafb;
  --card: #ffffff;
  --shadow: 0 18px 45px rgba(17, 24, 39, 0.12);
  --soft-shadow: 0 10px 24px rgba(17, 24, 39, 0.08);
  --radius: 18px;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background: var(--bg);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  line-height: 1.65;
}

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

img {
  display: block;
  max-width: 100%;
  background: linear-gradient(135deg, #fee2e2, #ffedd5 45%, #fed7aa);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: linear-gradient(90deg, var(--brand), var(--brand-red));
  color: #fff;
  box-shadow: 0 12px 30px rgba(220, 38, 38, 0.28);
}

.header-inner {
  max-width: 1280px;
  height: 64px;
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  align-items: center;
  gap: 22px;
}

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

.brand-icon {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.18);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.25);
}

.brand-text {
  font-size: 24px;
  letter-spacing: 0.02em;
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 18px;
  flex: 1;
  min-width: 0;
  overflow: hidden;
}

.nav-link {
  font-weight: 650;
  font-size: 15px;
  opacity: 0.92;
  white-space: nowrap;
  transition: color 0.2s ease, opacity 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
  color: #fef3c7;
  opacity: 1;
}

.header-search,
.mobile-search {
  display: flex;
  align-items: center;
  gap: 8px;
}

.header-search input,
.mobile-search input,
.local-filter input,
.search-page-form input {
  border: 0;
  outline: none;
  border-radius: 999px;
  padding: 10px 16px;
  color: #111827;
  background: rgba(255, 255, 255, 0.92);
  min-width: 220px;
}

.header-search button,
.mobile-search button,
.search-page-form button {
  border: 0;
  border-radius: 999px;
  padding: 10px 16px;
  color: #fff;
  background: #111827;
  cursor: pointer;
  font-weight: 700;
}

.menu-toggle {
  display: none;
  margin-left: auto;
  border: 0;
  color: #fff;
  background: transparent;
  font-size: 28px;
  cursor: pointer;
}

.mobile-panel {
  display: none;
  padding: 12px 20px 18px;
  background: rgba(194, 65, 12, 0.98);
}

.mobile-panel.open {
  display: block;
}

.mobile-nav {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px 16px;
  margin-top: 12px;
}

.hero {
  position: relative;
  height: 600px;
  overflow: hidden;
  color: #fff;
  background: #0f172a;
}

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

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

.hero-bg {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.04);
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, #000 0%, rgba(0, 0, 0, 0.76) 28%, rgba(0, 0, 0, 0.26) 70%, rgba(0, 0, 0, 0.15) 100%);
}

.hero-content {
  position: absolute;
  left: max(20px, calc((100vw - 1280px) / 2 + 20px));
  right: 20px;
  bottom: 80px;
  max-width: 760px;
}

.hero-kicker,
.eyebrow {
  color: #fed7aa;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.hero h1,
.page-hero h1,
.detail-info h1 {
  margin: 8px 0 14px;
  font-size: clamp(36px, 6vw, 72px);
  line-height: 1.08;
  letter-spacing: -0.04em;
}

.hero p {
  max-width: 700px;
  margin: 0 0 20px;
  color: rgba(255, 255, 255, 0.9);
  font-size: 18px;
}

.hero-tags,
.movie-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 14px 0 24px;
}

.hero-tags span,
.movie-tags span {
  display: inline-flex;
  border-radius: 999px;
  padding: 6px 12px;
  color: #fff7ed;
  background: rgba(234, 88, 12, 0.82);
  font-size: 13px;
  font-weight: 700;
}

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

.primary-btn,
.ghost-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  border-radius: 999px;
  padding: 10px 20px;
  font-weight: 800;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.primary-btn {
  color: #fff;
  background: linear-gradient(90deg, var(--brand), var(--brand-red));
  box-shadow: 0 14px 30px rgba(234, 88, 12, 0.35);
}

.ghost-btn {
  color: #fff;
  background: rgba(255, 255, 255, 0.14);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(10px);
}

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

.hero-arrow {
  position: absolute;
  top: 50%;
  width: 46px;
  height: 46px;
  border: 0;
  border-radius: 999px;
  color: #fff;
  background: rgba(0, 0, 0, 0.28);
  font-size: 34px;
  cursor: pointer;
  transform: translateY(-50%);
}

.hero-prev {
  left: 22px;
}

.hero-next {
  right: 22px;
}

.hero-dots {
  position: absolute;
  left: 50%;
  bottom: 28px;
  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.45);
  cursor: pointer;
}

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

.search-band {
  margin-top: -34px;
  position: relative;
  z-index: 2;
  padding: 0 20px;
}

.search-band-inner {
  max-width: 1100px;
  margin: 0 auto;
  padding: 26px;
  border-radius: 24px;
  color: #fff;
  background: linear-gradient(90deg, var(--brand), var(--brand-red));
  box-shadow: var(--shadow);
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px 24px;
  align-items: center;
}

.search-band h2,
.search-band p {
  margin: 0;
}

.search-band form {
  display: flex;
  gap: 10px;
}

.search-band input {
  width: min(360px, 40vw);
  border: 0;
  outline: 0;
  border-radius: 999px;
  padding: 12px 16px;
}

.search-band button {
  border: 0;
  border-radius: 999px;
  padding: 12px 18px;
  color: #fff;
  background: #111827;
  font-weight: 800;
  cursor: pointer;
}

.content-section {
  max-width: 1280px;
  margin: 0 auto;
  padding: 54px 20px;
}

.alt-section {
  max-width: none;
  padding-left: max(20px, calc((100vw - 1280px) / 2 + 20px));
  padding-right: max(20px, calc((100vw - 1280px) / 2 + 20px));
  background: #fff;
}

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

.section-heading h2 {
  margin: 0;
  font-size: clamp(26px, 3vw, 38px);
  line-height: 1.2;
}

.section-heading p {
  margin: 6px 0 0;
  color: var(--muted);
}

.section-heading a {
  flex: 0 0 auto;
  border-radius: 999px;
  padding: 9px 16px;
  color: var(--brand-dark);
  background: #ffedd5;
  font-weight: 800;
}

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

.category-tile {
  position: relative;
  min-height: 158px;
  padding: 18px;
  border-radius: var(--radius);
  overflow: hidden;
  color: #fff;
  background: #111827;
  box-shadow: var(--soft-shadow);
}

.category-tile img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.46;
  transition: transform 0.3s ease;
}

.category-tile span,
.category-tile small {
  position: relative;
  z-index: 1;
  display: block;
}

.category-tile span {
  margin-top: 54px;
  font-size: 22px;
  font-weight: 900;
}

.category-tile small {
  color: rgba(255, 255, 255, 0.82);
}

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

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

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

.poster-card {
  border-radius: var(--radius);
  background: var(--card);
  overflow: hidden;
  box-shadow: var(--soft-shadow);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

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

.poster-cover {
  position: relative;
  display: block;
  aspect-ratio: 3 / 4.25;
  overflow: hidden;
  background: #111827;
}

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

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

.poster-year,
.poster-play {
  position: absolute;
  border-radius: 999px;
  padding: 5px 10px;
  color: #fff;
  font-size: 12px;
  font-weight: 800;
}

.poster-year {
  top: 10px;
  left: 10px;
  background: rgba(0, 0, 0, 0.55);
}

.poster-play {
  right: 10px;
  bottom: 10px;
  background: linear-gradient(90deg, var(--brand), var(--brand-red));
}

.poster-body {
  padding: 14px;
}

.poster-body h3 {
  margin: 0 0 8px;
  color: var(--brand-dark);
  font-size: 16px;
  line-height: 1.35;
}

.poster-body p {
  min-height: 48px;
  margin: 0 0 10px;
  color: #4b5563;
  font-size: 13px;
  line-height: 1.55;
}

.poster-meta,
.tiny-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: #6b7280;
  font-size: 12px;
}

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

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

.rank-card {
  display: grid;
  grid-template-columns: 92px 1fr;
  gap: 14px;
  padding: 12px;
  border-radius: var(--radius);
  background: #fff;
  box-shadow: var(--soft-shadow);
}

.rank-cover {
  aspect-ratio: 3 / 4;
  border-radius: 14px;
  overflow: hidden;
  background: #111827;
}

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

.rank-content p {
  margin: 6px 0 10px;
  color: #4b5563;
  font-size: 14px;
}

.rank-line {
  display: flex;
  align-items: center;
  gap: 10px;
}

.rank-line h3 {
  margin: 0;
  color: var(--brand-dark);
  font-size: 17px;
}

.rank-num {
  display: inline-grid;
  place-items: center;
  min-width: 38px;
  height: 30px;
  border-radius: 999px;
  color: #fff;
  background: linear-gradient(90deg, var(--brand), var(--brand-red));
  font-weight: 900;
}

.page-hero {
  color: #fff;
  background: radial-gradient(circle at 20% 20%, rgba(251, 146, 60, 0.95), transparent 32%), linear-gradient(120deg, #111827, #7f1d1d 58%, #ea580c);
}

.small-hero,
.rank-hero {
  min-height: 310px;
  display: flex;
  align-items: center;
  padding: 70px max(20px, calc((100vw - 1280px) / 2 + 20px));
}

.small-hero p,
.rank-hero p {
  max-width: 760px;
  margin: 0;
  color: rgba(255, 255, 255, 0.86);
}

.local-filter {
  margin: -8px 0 26px;
}

.local-filter input {
  width: min(100%, 560px);
  border: 1px solid var(--line);
  background: #fff;
  box-shadow: var(--soft-shadow);
}

.breadcrumb {
  max-width: 1280px;
  margin: 0 auto;
  padding: 18px 20px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: #6b7280;
  font-size: 14px;
}

.breadcrumb a {
  color: var(--brand-dark);
  font-weight: 700;
}

.detail-hero {
  position: relative;
  overflow: hidden;
  color: #fff;
  background: #111827;
}

.detail-backdrop {
  position: absolute;
  inset: 0;
  opacity: 0.48;
}

.detail-backdrop img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: blur(12px);
  transform: scale(1.08);
}

.detail-backdrop div {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, #000 0%, rgba(0, 0, 0, 0.78) 42%, rgba(0, 0, 0, 0.5));
}

.detail-layout {
  position: relative;
  z-index: 1;
  max-width: 1280px;
  min-height: 520px;
  margin: 0 auto;
  padding: 56px 20px;
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 38px;
  align-items: center;
}

.detail-poster {
  position: relative;
  display: block;
  border-radius: 24px;
  overflow: hidden;
  box-shadow: var(--shadow);
  background: #111827;
}

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

.detail-poster span {
  position: absolute;
  right: 16px;
  bottom: 16px;
  border-radius: 999px;
  padding: 8px 14px;
  color: #fff;
  background: linear-gradient(90deg, var(--brand), var(--brand-red));
  font-weight: 900;
}

.detail-one-line {
  max-width: 820px;
  color: rgba(255, 255, 255, 0.9);
  font-size: 18px;
}

.player-section {
  max-width: 1180px;
  margin: 42px auto 0;
  padding: 0 20px;
}

.player-shell {
  position: relative;
  border-radius: 24px;
  overflow: hidden;
  background: #000;
  box-shadow: var(--shadow);
  aspect-ratio: 16 / 9;
}

.movie-video {
  width: 100%;
  height: 100%;
  display: block;
  background: #000;
}

.player-start {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  gap: 8px;
  border: 0;
  color: #fff;
  background: radial-gradient(circle, rgba(0, 0, 0, 0.12), rgba(0, 0, 0, 0.42));
  cursor: pointer;
}

.player-start span {
  display: grid;
  place-items: center;
  width: 78px;
  height: 78px;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--brand), var(--brand-red));
  box-shadow: 0 16px 40px rgba(234, 88, 12, 0.42);
  font-size: 34px;
}

.player-shell.playing .player-start {
  display: none;
}

.detail-content {
  max-width: 1280px;
  margin: 0 auto;
  padding: 46px 20px 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 22px;
}

.story-block,
.meta-panel {
  border-radius: var(--radius);
  padding: 24px;
  background: #fff;
  box-shadow: var(--soft-shadow);
}

.story-block h2,
.meta-panel h2 {
  margin-top: 0;
}

.story-block p {
  margin: 0;
  color: #374151;
  font-size: 16px;
}

.meta-panel {
  grid-row: span 2;
}

.meta-panel dl {
  margin: 0;
  display: grid;
  grid-template-columns: 70px 1fr;
  gap: 10px 12px;
}

.meta-panel dt {
  color: #6b7280;
}

.meta-panel dd {
  margin: 0;
  font-weight: 700;
}

.search-page-form {
  display: flex;
  gap: 12px;
  margin-bottom: 20px;
}

.search-page-form input {
  flex: 1;
  border: 1px solid var(--line);
  background: #fff;
  min-width: 0;
}

.search-result-info {
  margin-bottom: 20px;
  color: var(--muted);
  font-weight: 700;
}

.sitemap-section {
  display: grid;
  gap: 22px;
}

.sitemap-group {
  border-radius: var(--radius);
  padding: 22px;
  background: #fff;
  box-shadow: var(--soft-shadow);
}

.sitemap-group h2 {
  margin: 0 0 14px;
  color: var(--brand-dark);
}

.sitemap-links {
  columns: 4 220px;
  column-gap: 26px;
}

.sitemap-links a {
  break-inside: avoid;
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding: 6px 0;
  color: #374151;
  border-bottom: 1px dashed #e5e7eb;
}

.sitemap-links span {
  color: #9ca3af;
}

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

.footer-inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 36px 20px;
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 28px;
}

.footer-logo {
  color: #fed7aa;
  font-size: 24px;
  font-weight: 900;
}

.footer-inner p {
  color: rgba(255, 255, 255, 0.72);
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 18px;
  justify-content: flex-end;
}

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

[data-search-card].hidden {
  display: none;
}

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

  .menu-toggle {
    display: block;
  }

  .header-search {
    margin-left: auto;
  }

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

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

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

@media (max-width: 780px) {
  .header-inner {
    height: 58px;
    padding: 0 14px;
  }

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

  .header-search {
    display: none;
  }

  .hero {
    height: 500px;
  }

  .hero-content {
    bottom: 68px;
  }

  .hero-arrow {
    display: none;
  }

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

  .search-band form {
    flex-direction: column;
  }

  .search-band input {
    width: 100%;
  }

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

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

  .rank-card {
    grid-template-columns: 80px 1fr;
  }

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

  .detail-poster {
    width: min(260px, 70vw);
  }

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

  .meta-panel {
    grid-row: auto;
  }

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

  .footer-links {
    justify-content: flex-start;
  }
}

@media (max-width: 520px) {
  .hero {
    height: 430px;
  }

  .hero h1,
  .page-hero h1,
  .detail-info h1 {
    font-size: 34px;
  }

  .hero p,
  .detail-one-line {
    font-size: 15px;
  }

  .poster-grid,
  .compact-grid,
  .category-grid,
  .rank-grid,
  .rank-list {
    grid-template-columns: 1fr;
  }

  .search-page-form {
    flex-direction: column;
  }
}
