:root {
  --bg: #fff7ed;
  --surface: #ffffff;
  --surface-soft: #fff1e5;
  --text: #1f2937;
  --muted: #6b7280;
  --line: rgba(31, 41, 55, 0.12);
  --primary: #ea580c;
  --primary-dark: #c2410c;
  --secondary: #dc2626;
  --dark: #111827;
  --radius: 18px;
  --shadow: 0 18px 45px rgba(67, 20, 7, 0.12);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--text);
  background: linear-gradient(135deg, #fff7ed 0%, #fef2f2 45%, #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,
video {
  display: block;
  max-width: 100%;
}

button,
input {
  font: inherit;
}

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

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

.nav-bar {
  min-height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.brand,
.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  color: var(--dark);
}

.brand-mark {
  width: 38px;
  height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 13px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  box-shadow: 0 10px 25px rgba(234, 88, 12, 0.25);
}

.brand-name {
  font-size: 20px;
  letter-spacing: 0.04em;
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 8px;
}

.nav-link {
  padding: 10px 14px;
  border-radius: 999px;
  color: #4b5563;
  font-weight: 600;
  transition: color 0.2s ease, background 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
  color: var(--primary);
  background: rgba(234, 88, 12, 0.1);
}

.nav-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 12px;
  background: rgba(234, 88, 12, 0.1);
}

.nav-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  margin: 5px auto;
  background: var(--primary);
}

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

.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,
.detail-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.68;
}

.hero-layer,
.detail-layer {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 72% 35%, rgba(234, 88, 12, 0.35), transparent 35%), linear-gradient(90deg, rgba(17, 24, 39, 0.96), rgba(17, 24, 39, 0.68) 48%, rgba(17, 24, 39, 0.2));
}

.hero-content {
  position: relative;
  min-height: 690px;
  display: grid;
  grid-template-columns: 1.08fr 0.58fr;
  align-items: center;
  gap: 54px;
  padding: 80px 0 120px;
  color: #ffffff;
}

.eyebrow,
.section-kicker,
.category-kicker {
  display: inline-flex;
  align-items: center;
  margin-bottom: 12px;
  color: #fed7aa;
  font-size: 14px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

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

.hero-copy p,
.page-hero p,
.detail-copy .one-line {
  max-width: 720px;
  margin: 22px 0 0;
  color: rgba(255, 255, 255, 0.86);
  font-size: 18px;
}

.hero-tags,
.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 18px;
}

.hero-tags span,
.tag-row span {
  padding: 6px 10px;
  border-radius: 999px;
  color: #9a3412;
  background: #ffedd5;
  font-size: 12px;
  font-weight: 700;
}

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

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 30px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 22px;
  border-radius: 999px;
  font-weight: 800;
  transition: transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}

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

.button.primary {
  color: #ffffff;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  box-shadow: 0 15px 35px rgba(234, 88, 12, 0.34);
}

.button.ghost {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.hero-poster {
  position: relative;
  justify-self: end;
  width: min(360px, 100%);
  aspect-ratio: 3 / 4.2;
  overflow: hidden;
  border-radius: 30px;
  background: rgba(255, 255, 255, 0.12);
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.42);
  transform: rotate(2deg);
}

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

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

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

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

.hero-search {
  position: absolute;
  left: 50%;
  bottom: 78px;
  z-index: 6;
  width: min(560px, calc(100% - 32px));
  display: flex;
  gap: 10px;
  padding: 8px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.16);
  backdrop-filter: blur(14px);
  transform: translateX(-50%);
}

.hero-search input,
.search-box input {
  flex: 1;
  min-width: 0;
  border: 0;
  outline: 0;
  color: var(--text);
  background: #ffffff;
}

.hero-search input {
  padding: 0 18px;
  border-radius: 999px;
}

.hero-search button {
  border: 0;
  border-radius: 999px;
  padding: 10px 20px;
  color: #ffffff;
  background: var(--primary);
  font-weight: 800;
}

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

.section-block.soft {
  background: linear-gradient(135deg, rgba(255, 237, 213, 0.66), rgba(254, 242, 242, 0.82));
}

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

.section-head h2 {
  margin: 0;
  font-size: clamp(26px, 4vw, 42px);
  line-height: 1.15;
  letter-spacing: -0.03em;
}

.text-link {
  color: var(--primary);
  font-weight: 800;
}

.filter-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 26px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.72);
  box-shadow: 0 15px 40px rgba(67, 20, 7, 0.07);
}

.search-box {
  flex: 1;
  min-width: 240px;
}

.search-box input {
  width: 100%;
  padding: 13px 16px;
  border-radius: 16px;
}

.filter-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.filter-button {
  border: 0;
  border-radius: 999px;
  padding: 10px 14px;
  color: #7c2d12;
  background: #ffedd5;
  font-weight: 800;
}

.filter-button.active,
.filter-button:hover {
  color: #ffffff;
  background: var(--primary);
}

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

.movie-card {
  overflow: hidden;
  border: 1px solid rgba(255, 237, 213, 0.9);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: 0 12px 35px rgba(67, 20, 7, 0.08);
  transition: transform 0.22s ease, box-shadow 0.22s ease, border 0.22s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  border-color: rgba(234, 88, 12, 0.35);
  box-shadow: var(--shadow);
}

.poster-link {
  position: relative;
  display: block;
  aspect-ratio: 3 / 4.2;
  overflow: hidden;
  background: linear-gradient(135deg, #7c2d12, #111827);
}

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

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

.poster-shade {
  position: absolute;
  inset: auto 0 0;
  height: 42%;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.52), transparent);
}

.rank-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  z-index: 3;
  min-width: 36px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  color: #ffffff;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  font-weight: 900;
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.28);
}

.card-body {
  padding: 16px;
}

.card-meta {
  margin-bottom: 8px;
  color: var(--primary);
  font-size: 12px;
  font-weight: 800;
}

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

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

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

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

.category-panel {
  display: block;
  min-height: 178px;
  padding: 24px;
  border: 1px solid rgba(255, 237, 213, 0.88);
  border-radius: 24px;
  background: linear-gradient(135deg, #ffffff, #fff7ed);
  box-shadow: 0 16px 35px rgba(67, 20, 7, 0.08);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

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

.category-panel strong {
  display: block;
  margin-bottom: 10px;
  font-size: 22px;
}

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

.page-hero {
  color: #ffffff;
  background: radial-gradient(circle at 80% 20%, rgba(255, 255, 255, 0.16), transparent 26%), linear-gradient(135deg, #7c2d12, #111827 60%, #7f1d1d);
}

.compact-hero {
  padding: 78px 0 68px;
}

.compact-hero .container {
  position: relative;
}

.crumb-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 28px;
}

.crumb-links a {
  padding: 9px 13px;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.15);
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 22px;
  color: rgba(255, 255, 255, 0.78);
  font-size: 14px;
}

.breadcrumb a:hover {
  color: #fed7aa;
}

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

.detail-hero-inner {
  position: relative;
  padding: 60px 0 72px;
}

.detail-layout {
  display: grid;
  grid-template-columns: 300px 1fr;
  align-items: center;
  gap: 46px;
}

.detail-poster {
  overflow: hidden;
  border-radius: 28px;
  box-shadow: 0 28px 70px rgba(0, 0, 0, 0.42);
}

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

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

.detail-meta span {
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.15);
}

.detail-meta b {
  margin-right: 6px;
  color: #fed7aa;
}

.detail-tags {
  margin-bottom: 28px;
}

.player-section {
  padding: 54px 0 0;
  background: #111827;
}

.player-shell {
  position: relative;
  overflow: hidden;
  border-radius: 28px;
  background: #000000;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.28);
}

.player-shell video,
.player-cover {
  width: 100%;
  aspect-ratio: 16 / 9;
}

.player-shell video {
  background: #000000;
}

.player-cover {
  position: absolute;
  inset: 0;
  z-index: 3;
  padding: 0;
  border: 0;
  cursor: pointer;
  background: #000000;
}

.player-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.72;
}

.player-cover.is-hidden {
  display: none;
}

.play-circle {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 86px;
  height: 86px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  color: #ffffff;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  font-size: 32px;
  font-weight: 900;
  box-shadow: 0 18px 45px rgba(0, 0, 0, 0.38);
  transform: translate(-50%, -50%);
}

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

.content-card {
  padding: 28px;
  border: 1px solid rgba(255, 237, 213, 0.95);
  border-radius: 24px;
  background: #ffffff;
  box-shadow: 0 16px 35px rgba(67, 20, 7, 0.08);
}

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

.content-card p {
  margin: 0;
  color: #4b5563;
}

.empty-state {
  display: none;
  margin-top: 20px;
  padding: 22px;
  border-radius: 18px;
  color: var(--muted);
  background: #ffffff;
  text-align: center;
}

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

.site-footer {
  padding: 36px 0;
  color: rgba(255, 255, 255, 0.74);
  background: #111827;
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.footer-brand {
  color: #ffffff;
  font-size: 20px;
}

.site-footer p {
  max-width: 560px;
  margin: 10px 0 0;
}

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

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

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

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

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

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

  .main-nav {
    position: absolute;
    top: 72px;
    left: 16px;
    right: 16px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    padding: 14px;
    border-radius: 18px;
    background: #ffffff;
    box-shadow: var(--shadow);
  }

  .main-nav.open {
    display: flex;
  }

  .hero-carousel,
  .hero-content {
    min-height: 760px;
  }

  .hero-content {
    grid-template-columns: 1fr;
    gap: 28px;
    padding-top: 52px;
    text-align: left;
  }

  .hero-poster {
    justify-self: start;
    width: 220px;
  }

  .hero-search {
    bottom: 70px;
  }

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

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

  .detail-poster {
    width: min(260px, 80%);
  }

  .footer-inner,
  .section-head {
    align-items: flex-start;
    flex-direction: column;
  }
}

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

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

  .hero-copy p,
  .page-hero p,
  .detail-copy .one-line {
    font-size: 16px;
  }

  .hero-search {
    flex-direction: column;
    border-radius: 20px;
  }

  .hero-search input,
  .hero-search button {
    min-height: 44px;
  }

  .movie-grid,
  .category-grid,
  .category-grid.large,
  .detail-text-grid {
    grid-template-columns: 1fr;
  }

  .filter-bar {
    align-items: stretch;
  }

  .filter-buttons {
    width: 100%;
  }

  .filter-button {
    flex: 1;
  }

  .play-circle {
    width: 66px;
    height: 66px;
    font-size: 24px;
  }
}
