:root {
  color-scheme: light;
  --bg: #f8fafc;
  --surface: #ffffff;
  --surface-soft: #fff7ed;
  --text: #111827;
  --muted: #64748b;
  --line: #e5e7eb;
  --brand: #d97706;
  --brand-dark: #b45309;
  --brand-hot: #ea580c;
  --dark: #111827;
  --shadow: 0 18px 45px rgba(15, 23, 42, 0.12);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

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

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

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

button,
input,
select {
  font: inherit;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  color: #fff;
  background: linear-gradient(90deg, #d97706, #ea580c);
  box-shadow: 0 12px 30px rgba(217, 119, 6, 0.22);
}

.header-inner {
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.brand,
.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  letter-spacing: 0.02em;
}

.brand-mark {
  width: 34px;
  height: 34px;
  display: inline-grid;
  place-items: center;
  border-radius: 999px;
  color: #fff;
  background: rgba(255, 255, 255, 0.18);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.28);
}

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

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 24px;
  font-weight: 700;
}

.nav-link,
.mobile-link {
  opacity: 0.92;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.nav-link:hover,
.nav-link.is-active,
.mobile-link:hover,
.mobile-link.is-active {
  opacity: 1;
  transform: translateY(-1px);
}

.menu-button {
  display: none;
  border: 0;
  border-radius: 12px;
  padding: 8px 12px;
  color: #fff;
  background: rgba(255, 255, 255, 0.16);
  cursor: pointer;
}

.mobile-nav {
  display: none;
  padding: 12px 16px 18px;
  background: rgba(146, 64, 14, 0.95);
}

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

.mobile-link {
  padding: 10px 12px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.08);
}

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

.hero-slide {
  display: none;
  min-height: 680px;
  position: relative;
}

.hero-slide.is-active {
  display: block;
}

.hero-bg {
  position: absolute;
  inset: 0;
}

.hero-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(1.1) contrast(1.05);
}

.hero-bg::after,
.detail-backdrop::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(17, 24, 39, 0.94), rgba(17, 24, 39, 0.68), rgba(146, 64, 14, 0.36)), linear-gradient(0deg, rgba(17, 24, 39, 0.98), transparent 45%);
}

.hero-content {
  position: relative;
  z-index: 2;
  min-height: 680px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 60px;
  align-items: center;
  color: #fff;
  padding: 72px 0 96px;
}

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

.eyebrow,
.section-title p,
.page-hero p {
  margin: 0 0 12px;
  color: #fbbf24;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.hero h1 {
  margin: 0 0 16px;
  font-size: clamp(32px, 5vw, 62px);
  line-height: 1.08;
  letter-spacing: -0.04em;
}

.hero h2 {
  margin: 0 0 14px;
  font-size: clamp(24px, 3vw, 42px);
}

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

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

.hero-tags span,
.tag-row span {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 5px 10px;
  border-radius: 999px;
  color: #92400e;
  background: #fef3c7;
  font-size: 13px;
  font-weight: 700;
}

.tag-row.large span {
  color: #fff7ed;
  background: rgba(255, 255, 255, 0.16);
}

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

.primary-button,
.ghost-button,
.filter-panel button,
.category-card .category-entry {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 22px;
  border: 0;
  border-radius: 14px;
  font-weight: 800;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.primary-button,
.filter-panel button,
.category-card .category-entry {
  color: #fff;
  background: linear-gradient(90deg, var(--brand), var(--brand-hot));
  box-shadow: 0 14px 32px rgba(217, 119, 6, 0.26);
}

.ghost-button {
  color: #fff;
  background: rgba(255, 255, 255, 0.14);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.26);
}

.primary-button:hover,
.ghost-button:hover,
.filter-panel button:hover,
.category-card:hover .category-entry {
  transform: translateY(-2px);
}

.hero-poster {
  position: relative;
  display: block;
  overflow: hidden;
  border-radius: 28px;
  box-shadow: var(--shadow);
  transform: rotate(2deg);
  background: #111827;
}

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

.hero-poster span,
.card-play {
  position: absolute;
  inset: 50% auto auto 50%;
  transform: translate(-50%, -50%);
  width: 72px;
  height: 72px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  color: #fff;
  background: rgba(217, 119, 6, 0.9);
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.28);
}

.hero-controls {
  position: absolute;
  left: 50%;
  bottom: 34px;
  z-index: 4;
  display: flex;
  gap: 10px;
  transform: translateX(-50%);
}

.hero-dot {
  width: 12px;
  height: 12px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.55);
  cursor: pointer;
}

.hero-dot.is-active {
  width: 38px;
  background: #f59e0b;
}

.quick-search {
  margin-top: -48px;
  position: relative;
  z-index: 6;
}

.filter-panel {
  display: grid;
  grid-template-columns: minmax(240px, 1fr) 180px 180px auto;
  gap: 12px;
  padding: 18px;
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: var(--shadow);
  backdrop-filter: blur(12px);
}

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

.filter-panel input,
.filter-panel select {
  min-height: 46px;
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 0 14px;
  color: var(--text);
  background: #fff;
  outline: none;
}

.filter-panel input:focus,
.filter-panel select:focus {
  border-color: #f59e0b;
  box-shadow: 0 0 0 4px rgba(245, 158, 11, 0.14);
}

.page-section,
.category-strip {
  padding: 72px 0 0;
}

.wide-section {
  margin-top: 72px;
  background: #fff;
  padding-bottom: 72px;
}

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

.section-title h2,
.section-title p {
  margin: 0;
}

.section-title h2 {
  font-size: clamp(24px, 3vw, 34px);
  line-height: 1.25;
}

.section-title a {
  flex: none;
  color: var(--brand-dark);
  font-weight: 800;
}

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

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

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

.movie-card {
  min-width: 0;
}

.movie-card a {
  display: block;
  height: 100%;
  overflow: hidden;
  border-radius: 22px;
  background: #fff;
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.08);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

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

.poster-wrap {
  position: relative;
  overflow: hidden;
  background: #e5e7eb;
}

.poster-wrap img {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.movie-card.small .poster-wrap img,
.movie-card.mini .poster-wrap img {
  aspect-ratio: 3 / 4;
}

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

.badge {
  position: absolute;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 4px 9px;
  border-radius: 10px;
  color: #fff;
  background: rgba(217, 119, 6, 0.92);
  font-size: 12px;
  font-weight: 800;
}

.badge-top {
  left: 12px;
  top: 12px;
}

.badge-bottom {
  right: 12px;
  bottom: 12px;
  background: rgba(17, 24, 39, 0.78);
}

.card-play {
  width: 58px;
  height: 58px;
  opacity: 0;
  transition: opacity 0.25s ease;
}

.movie-card a:hover .card-play {
  opacity: 1;
}

.card-body {
  padding: 18px;
}

.card-body h3,
.compact-card h3 {
  margin: 0 0 8px;
  font-size: 18px;
  line-height: 1.35;
}

.card-body p,
.compact-card p {
  margin: 0 0 12px;
  color: var(--muted);
  font-size: 14px;
}

.card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: #475569;
  font-size: 13px;
  font-weight: 700;
}

.card-meta span + span::before {
  content: "·";
  margin-right: 8px;
  color: #cbd5e1;
}

.movie-card .tag-row {
  margin: 12px 0 0;
}

.movie-card .tag-row span {
  font-size: 12px;
  min-height: 24px;
  padding: 3px 8px;
}

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

.ranking-list {
  grid-template-columns: 1fr;
}

.compact-card a {
  display: grid;
  grid-template-columns: auto 120px minmax(0, 1fr);
  gap: 16px;
  align-items: center;
  height: 100%;
  padding: 14px;
  border-radius: 20px;
  background: #fff;
  box-shadow: 0 10px 26px rgba(15, 23, 42, 0.07);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.compact-card a:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow);
}

.compact-card img {
  width: 120px;
  height: 82px;
  object-fit: cover;
  border-radius: 16px;
}

.compact-card span:not(.rank-num) {
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.rank-num {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  color: #fff;
  background: linear-gradient(135deg, var(--brand), var(--brand-hot));
  font-weight: 900;
}

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

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  margin: 0 0 22px;
  color: #64748b;
  font-size: 14px;
  font-weight: 700;
}

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

.breadcrumb span::before,
.breadcrumb a + span::before,
.breadcrumb a + a::before {
  content: "/";
  margin-right: 10px;
  color: #cbd5e1;
}

.breadcrumb.invert {
  color: rgba(255, 255, 255, 0.76);
}

.breadcrumb.invert a {
  color: #fcd34d;
}

.page-hero {
  overflow: hidden;
  position: relative;
  border-radius: 30px;
  padding: 58px;
  color: #fff;
  background: radial-gradient(circle at top left, rgba(251, 191, 36, 0.38), transparent 30%), linear-gradient(135deg, #111827, #92400e 62%, #ea580c);
  box-shadow: var(--shadow);
}

.page-hero.slim {
  margin-bottom: 26px;
}

.page-hero h1 {
  margin: 0 0 12px;
  font-size: clamp(30px, 4vw, 52px);
  line-height: 1.12;
}

.page-hero h2 {
  max-width: 820px;
  margin: 0;
  color: rgba(255, 255, 255, 0.84);
  font-size: clamp(18px, 2vw, 24px);
  font-weight: 600;
}

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

.category-card {
  display: grid;
  gap: 14px;
  height: 100%;
  padding: 28px;
  border-radius: 26px;
  background: #fff;
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.08);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

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

.category-card h2 {
  margin: 0;
}

.category-card p {
  margin: 0;
  color: var(--muted);
}

.category-preview {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.category-preview a {
  display: inline-flex;
  height: auto;
  padding: 5px 10px;
  border-radius: 999px;
  color: #92400e;
  background: #fef3c7;
  box-shadow: none;
  font-size: 13px;
  font-weight: 700;
}

.detail-main {
  background: #f8fafc;
}

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

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

.detail-backdrop img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: blur(2px) saturate(1.05);
  transform: scale(1.02);
}

.detail-layout {
  position: relative;
  z-index: 2;
  padding: 34px 0 64px;
}

.detail-panel {
  display: grid;
  grid-template-columns: 300px minmax(0, 1fr);
  gap: 42px;
  align-items: end;
  padding-top: 30px;
}

.detail-poster {
  overflow: hidden;
  border-radius: 28px;
  box-shadow: var(--shadow);
}

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

.detail-copy h1 {
  margin: 0 0 14px;
  font-size: clamp(34px, 5vw, 62px);
  line-height: 1.08;
}

.detail-copy h2 {
  max-width: 860px;
  margin: 0 0 18px;
  color: rgba(255, 255, 255, 0.86);
  font-size: clamp(18px, 2vw, 25px);
  font-weight: 600;
}

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

.detail-meta span {
  padding: 7px 12px;
  border-radius: 999px;
  color: #fff7ed;
  background: rgba(255, 255, 255, 0.14);
  font-weight: 800;
}

.detail-content {
  padding: 54px 0 72px;
}

.player-shell {
  position: relative;
  overflow: hidden;
  border-radius: 28px;
  background: #000;
  box-shadow: var(--shadow);
}

.movie-video {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #000;
}

.play-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  border: 0;
  color: #fff;
  background: radial-gradient(circle, rgba(217, 119, 6, 0.18), rgba(0, 0, 0, 0.28));
  cursor: pointer;
}

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

.play-overlay span {
  width: 86px;
  height: 86px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--brand), var(--brand-hot));
  box-shadow: 0 18px 44px rgba(0, 0, 0, 0.36);
  font-size: 34px;
}

.story-block {
  margin-top: 34px;
  padding: 34px;
  border-radius: 28px;
  background: #fff;
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.06);
}

.story-block h2 {
  margin: 0 0 12px;
  font-size: 26px;
}

.story-block p {
  margin: 0 0 24px;
  color: #334155;
  font-size: 17px;
}

.story-block p:last-child {
  margin-bottom: 0;
}

.empty-state {
  margin: 20px 0;
  padding: 18px;
  border-radius: 16px;
  color: #92400e;
  background: #fef3c7;
  font-weight: 800;
}

.site-footer {
  margin-top: 72px;
  color: #d1d5db;
  background: #111827;
}

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

.footer-brand {
  margin-bottom: 14px;
  color: #fff;
  font-size: 20px;
}

.site-footer h2 {
  margin: 0 0 14px;
  color: #fff;
  font-size: 18px;
}

.site-footer p {
  margin: 0;
  color: #9ca3af;
}

.site-footer ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 8px;
}

.site-footer a:hover {
  color: #fbbf24;
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding: 22px;
  text-align: center;
  color: #9ca3af;
}

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

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

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

  .hero-poster,
  .detail-poster {
    max-width: 360px;
  }

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

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

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

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

  .brand-name {
    font-size: 17px;
  }

  .hero,
  .hero-slide,
  .hero-content {
    min-height: 620px;
  }

  .hero-content {
    gap: 28px;
    padding: 44px 0 86px;
  }

  .hero-poster,
  .detail-poster {
    display: none;
  }

  .filter-panel,
  .movie-grid,
  .latest-grid,
  .mini-grid,
  .category-grid,
  .footer-grid {
    grid-template-columns: 1fr;
  }

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

  .page-hero {
    padding: 34px 24px;
    border-radius: 24px;
  }

  .compact-card a {
    grid-template-columns: auto 94px minmax(0, 1fr);
    gap: 12px;
  }

  .compact-card img {
    width: 94px;
    height: 70px;
  }

  .rank-num {
    width: 34px;
    height: 34px;
    border-radius: 12px;
  }

  .story-block {
    padding: 24px;
  }
}
