:root {
  --orange: #f97316;
  --amber: #f59e0b;
  --orange-dark: #ea580c;
  --ink: #111827;
  --muted: #6b7280;
  --line: #e5e7eb;
  --soft: #f9fafb;
  --card: #ffffff;
  --footer: #0f172a;
  --radius: 18px;
  --shadow: 0 18px 45px rgba(15, 23, 42, 0.12);
  --shadow-soft: 0 12px 30px rgba(15, 23, 42, 0.08);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background: linear-gradient(180deg, #fff7ed 0%, #f9fafb 34%, #ffffff 100%);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", 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: #ffffff;
  background: linear-gradient(90deg, #f97316, #f59e0b, #fb923c);
  box-shadow: 0 10px 28px rgba(234, 88, 12, 0.26);
}

.header-inner {
  min-height: 68px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

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

.brand-icon {
  width: 34px;
  height: 34px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--orange);
  background: #ffffff;
  box-shadow: 0 10px 20px rgba(120, 53, 15, 0.18);
}

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

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 10px;
}

.nav-link,
.mobile-nav-link {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 9px 16px;
  color: rgba(255, 255, 255, 0.92);
  font-weight: 700;
  transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
  color: var(--orange-dark);
  background: #ffffff;
  transform: translateY(-1px);
}

.menu-button {
  display: none;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.18);
  cursor: pointer;
}

.menu-button span {
  display: block;
  width: 20px;
  height: 2px;
  margin: 5px auto;
  border-radius: 999px;
  background: #ffffff;
}

.mobile-nav {
  display: none;
  padding: 0 16px 16px;
}

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

.hero {
  position: relative;
  overflow: hidden;
  color: #ffffff;
  background: #111827;
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 15% 20%, rgba(249, 115, 22, 0.55), transparent 32%), radial-gradient(circle at 80% 0%, rgba(245, 158, 11, 0.44), transparent 28%);
  pointer-events: none;
}

.hero-slider {
  position: relative;
  min-height: 620px;
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transform: scale(1.025);
  transition: opacity 0.7s ease, transform 0.7s ease;
  pointer-events: none;
}

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

.hero-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(1.05);
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(15, 23, 42, 0.92), rgba(15, 23, 42, 0.66) 42%, rgba(15, 23, 42, 0.26)), linear-gradient(0deg, rgba(15, 23, 42, 0.84), transparent 34%);
}

.hero-content {
  position: relative;
  z-index: 2;
  min-height: 620px;
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  align-items: center;
  gap: 56px;
  padding: 80px 0 64px;
}

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

.eyebrow,
.page-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 18px;
  padding: 8px 14px;
  border-radius: 999px;
  color: #fff7ed;
  background: rgba(255, 255, 255, 0.16);
  backdrop-filter: blur(16px);
  font-weight: 800;
}

.hero h1 {
  margin: 0 0 18px;
  font-size: clamp(38px, 6vw, 68px);
  line-height: 1.08;
  letter-spacing: -0.04em;
  text-shadow: 0 20px 55px rgba(0, 0, 0, 0.28);
}

.hero p {
  margin: 0 0 24px;
  max-width: 650px;
  color: rgba(255, 255, 255, 0.9);
  font-size: clamp(17px, 2vw, 22px);
}

.hero-tags,
.detail-tags,
.card-tags,
.filter-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.hero-tags span,
.detail-tags span,
.card-tags span,
.filter-chips a,
.filter-chips button {
  border: 0;
  border-radius: 999px;
  padding: 7px 12px;
  color: #92400e;
  background: #ffedd5;
  font-size: 13px;
  font-weight: 800;
}

.hero-tags span {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.18);
}

.hero-actions,
.page-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 28px;
}

.button,
.button-light,
.button-outline,
.player-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  border: 0;
  border-radius: 999px;
  padding: 12px 22px;
  font-weight: 900;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

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

.button-light {
  color: var(--orange-dark);
  background: #ffffff;
  box-shadow: 0 14px 30px rgba(255, 255, 255, 0.22);
}

.button-outline {
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.42);
  background: rgba(255, 255, 255, 0.12);
}

.button:hover,
.button-light:hover,
.button-outline:hover,
.player-button:hover {
  transform: translateY(-2px) scale(1.02);
}

.hero-panel {
  position: relative;
  border: 1px solid rgba(255, 255, 255, 0.24);
  border-radius: 30px;
  padding: 16px;
  background: rgba(255, 255, 255, 0.16);
  backdrop-filter: blur(18px);
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.3);
}

.hero-poster {
  overflow: hidden;
  aspect-ratio: 3 / 4;
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.08);
}

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

.hero-panel-meta {
  position: absolute;
  left: 34px;
  right: 34px;
  bottom: 34px;
  padding: 18px;
  border-radius: 20px;
  color: #ffffff;
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.1), rgba(15, 23, 42, 0.86));
}

.hero-controls {
  position: absolute;
  z-index: 4;
  left: 50%;
  bottom: 32px;
  display: flex;
  align-items: center;
  gap: 12px;
  transform: translateX(-50%);
}

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

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

.quick-search {
  margin-top: -38px;
  position: relative;
  z-index: 5;
}

.search-card {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 14px;
  padding: 18px;
  border-radius: 22px;
  background: #ffffff;
  box-shadow: var(--shadow);
}

.search-card input,
.filter-input,
.filter-select {
  width: 100%;
  min-height: 48px;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0 18px;
  color: var(--ink);
  background: #ffffff;
  outline: none;
}

.search-card input:focus,
.filter-input:focus,
.filter-select:focus {
  border-color: var(--orange);
  box-shadow: 0 0 0 4px rgba(249, 115, 22, 0.12);
}

main {
  display: block;
}

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

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

.section-heading h2,
.page-title h1,
.detail-title h1 {
  margin: 0 0 8px;
  color: #1f2937;
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1.18;
  letter-spacing: -0.03em;
}

.section-heading p,
.page-title p,
.detail-title p {
  margin: 0;
  color: var(--muted);
}

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

.movie-card,
.category-card,
.info-card,
.detail-card {
  overflow: hidden;
  border: 1px solid rgba(229, 231, 235, 0.9);
  border-radius: var(--radius);
  background: var(--card);
  box-shadow: var(--shadow-soft);
}

.movie-card {
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

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

.movie-poster {
  position: relative;
  display: block;
  overflow: hidden;
  aspect-ratio: 3 / 4;
  background: linear-gradient(135deg, #fb923c, #111827);
}

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

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

.movie-poster::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 46%, rgba(15, 23, 42, 0.72));
  opacity: 0.88;
}

.play-mark {
  position: absolute;
  z-index: 2;
  left: 50%;
  top: 50%;
  width: 50px;
  height: 50px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  color: var(--orange-dark);
  background: rgba(255, 255, 255, 0.92);
  transform: translate(-50%, -50%) scale(0.86);
  opacity: 0;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.movie-card:hover .play-mark {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
}

.rank-badge {
  position: absolute;
  z-index: 3;
  left: 12px;
  top: 12px;
  min-width: 34px;
  height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  color: #ffffff;
  background: linear-gradient(135deg, #f97316, #f59e0b);
  box-shadow: 0 8px 20px rgba(249, 115, 22, 0.35);
}

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

.movie-meta-line,
.detail-meta,
.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  color: var(--muted);
  font-size: 13px;
}

.movie-meta-line span,
.detail-meta span {
  padding: 4px 8px;
  border-radius: 999px;
  background: #f3f4f6;
}

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

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

.movie-card p {
  min-height: 48px;
  margin: 0 0 12px;
  color: var(--muted);
  font-size: 14px;
}

.card-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 14px;
  color: var(--orange-dark);
  font-size: 14px;
  font-weight: 800;
}

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

.category-card {
  position: relative;
  min-height: 190px;
  padding: 22px;
  background: linear-gradient(135deg, #ffffff, #fff7ed);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

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

.category-card h3 {
  margin: 0 0 10px;
  font-size: 22px;
}

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

.category-card span {
  display: inline-flex;
  color: var(--orange-dark);
  font-weight: 900;
}

.page-hero {
  color: #ffffff;
  background: linear-gradient(90deg, #f97316, #f59e0b, #fb923c);
}

.page-hero-inner {
  padding: 58px 0;
}

.page-hero h1 {
  margin: 0 0 12px;
  font-size: clamp(34px, 5vw, 56px);
  line-height: 1.12;
}

.page-hero p {
  margin: 0;
  max-width: 760px;
  color: rgba(255, 255, 255, 0.9);
  font-size: 19px;
}

.filter-panel {
  margin: 36px 0 28px;
  padding: 20px;
  border-radius: 22px;
  background: #ffffff;
  box-shadow: var(--shadow-soft);
}

.filter-row {
  display: grid;
  grid-template-columns: 1fr 190px;
  gap: 14px;
  margin-bottom: 16px;
}

.filter-chips button {
  cursor: pointer;
}

.filter-chips button.active {
  color: #ffffff;
  background: linear-gradient(90deg, #f97316, #f59e0b);
}

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

.ranking-row {
  display: grid;
  grid-template-columns: 54px 86px 1fr auto;
  align-items: center;
  gap: 18px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: #ffffff;
  box-shadow: var(--shadow-soft);
}

.ranking-row strong {
  width: 44px;
  height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 16px;
  color: #ffffff;
  background: linear-gradient(135deg, #f97316, #f59e0b);
}

.ranking-row img {
  width: 86px;
  height: 112px;
  border-radius: 14px;
  object-fit: cover;
}

.ranking-row h3 {
  margin: 0 0 6px;
}

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

.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.95fr) minmax(290px, 0.75fr);
  gap: 28px;
  padding: 34px 0 56px;
}

.breadcrumb {
  margin: 22px 0 18px;
}

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

.player-shell {
  overflow: hidden;
  border-radius: 26px;
  background: #020617;
  box-shadow: var(--shadow);
}

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

.video-wrap video {
  width: 100%;
  height: 100%;
  display: block;
  background: #020617;
}

.player-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: radial-gradient(circle, rgba(249, 115, 22, 0.16), rgba(2, 6, 23, 0.1));
  pointer-events: none;
}

.player-button {
  pointer-events: auto;
  color: #ffffff;
  background: linear-gradient(90deg, #f97316, #f59e0b);
  box-shadow: 0 18px 40px rgba(249, 115, 22, 0.35);
}

.player-overlay.hidden {
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

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

.detail-card h2,
.detail-card h3 {
  margin: 0 0 14px;
}

.detail-card p {
  margin: 0 0 14px;
  color: #374151;
}

.side-poster {
  position: sticky;
  top: 92px;
}

.side-poster img {
  width: 100%;
  border-radius: 24px;
  box-shadow: var(--shadow);
}

.side-panel {
  margin-top: 18px;
  padding: 20px;
  border-radius: 22px;
  background: #ffffff;
  box-shadow: var(--shadow-soft);
}

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

.side-panel dt {
  color: var(--muted);
}

.side-panel dd {
  margin: 0;
  font-weight: 800;
}

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

.mini-card {
  position: relative;
  overflow: hidden;
  display: block;
  border-radius: 16px;
  background: #111827;
}

.mini-card img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  opacity: 0.86;
  transition: transform 0.25s ease, opacity 0.25s ease;
}

.mini-card span:not(.mini-rank) {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 2;
  padding: 36px 12px 12px;
  color: #ffffff;
  font-weight: 800;
  background: linear-gradient(180deg, transparent, rgba(15, 23, 42, 0.9));
}

.mini-card:hover img {
  opacity: 1;
  transform: scale(1.05);
}

.mini-rank {
  position: absolute;
  z-index: 3;
  left: 10px;
  top: 10px;
  min-width: 28px;
  height: 28px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  color: #ffffff;
  background: linear-gradient(135deg, #f97316, #f59e0b);
}

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

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

.site-footer {
  color: #cbd5e1;
  background: linear-gradient(180deg, #111827, #020617);
}

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

.site-footer h3 {
  margin: 0 0 14px;
  color: #ffffff;
}

.site-footer p {
  margin: 0;
  color: #94a3b8;
}

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

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

.footer-bottom {
  padding: 18px 0;
  border-top: 1px solid rgba(148, 163, 184, 0.18);
  color: #94a3b8;
  text-align: center;
}

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

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

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

  .hero-panel {
    max-width: 420px;
  }

  .side-poster {
    position: static;
  }
}

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

  .menu-button {
    display: block;
  }

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

  .hero-slider,
  .hero-content {
    min-height: 720px;
  }

  .hero-content {
    padding-top: 56px;
    gap: 24px;
  }

  .hero-panel {
    max-width: 320px;
  }

  .search-card,
  .filter-row,
  .ranking-row {
    grid-template-columns: 1fr;
  }

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

  .ranking-row img {
    width: 100%;
    height: auto;
    aspect-ratio: 3 / 4;
  }
}

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

  .movie-grid,
  .related-grid,
  .category-strip,
  .footer-grid {
    grid-template-columns: 1fr;
  }

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

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

  .hero-actions,
  .page-actions {
    display: grid;
  }
}
