:root {
  --bg: #fff8ee;
  --bg-soft: #fff1dc;
  --card: #ffffff;
  --text: #1f1a17;
  --muted: #6f6259;
  --line: rgba(139, 92, 36, 0.16);
  --primary: #ea580c;
  --primary-dark: #c2410c;
  --accent: #f59e0b;
  --shadow: 0 18px 48px rgba(124, 45, 18, 0.12);
  --radius-xl: 28px;
  --radius-lg: 22px;
  --radius-md: 16px;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--text);
  background:
    radial-gradient(circle at top left, rgba(251, 146, 60, 0.22), transparent 28rem),
    linear-gradient(180deg, #fff7ed 0%, #ffffff 45%, #fffaf4 100%);
  min-height: 100vh;
}

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

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

button,
input,
select {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 248, 238, 0.9);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(18px);
}

.header-shell {
  width: min(1220px, calc(100% - 32px));
  height: 76px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 24px;
}

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

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

.brand-text {
  font-size: 24px;
  background: linear-gradient(135deg, var(--primary-dark), var(--accent));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  white-space: nowrap;
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 24px;
  margin-left: auto;
  color: #4b4039;
  font-weight: 700;
}

.desktop-nav a,
.mobile-nav a,
.footer-links a {
  transition: color 0.2s ease, transform 0.2s ease;
}

.desktop-nav a:hover,
.mobile-nav a:hover,
.footer-links a:hover {
  color: var(--primary);
}

.header-search {
  display: flex;
  align-items: center;
  gap: 8px;
  background: #ffffff;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 6px;
  box-shadow: 0 10px 24px rgba(120, 53, 15, 0.08);
}

.header-search input,
.mobile-nav input,
.inline-filter input,
.inline-filter select {
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--text);
}

.header-search input {
  width: 220px;
  padding: 8px 10px 8px 16px;
}

.header-search button,
.mobile-nav button {
  border: 0;
  color: #ffffff;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  border-radius: 999px;
  padding: 8px 16px;
  cursor: pointer;
  font-weight: 800;
}

.menu-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border: 0;
  background: #ffffff;
  border-radius: 14px;
  box-shadow: var(--shadow);
  cursor: pointer;
}

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

.mobile-nav {
  display: none;
  width: min(1220px, calc(100% - 32px));
  margin: 0 auto 16px;
  padding: 16px;
  background: #ffffff;
  border: 1px solid var(--line);
  border-radius: 22px;
  box-shadow: var(--shadow);
}

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

.mobile-nav form {
  display: flex;
  gap: 10px;
  border-top: 1px solid var(--line);
  padding-top: 14px;
}

.mobile-nav input {
  flex: 1;
  min-width: 0;
  padding: 10px;
  background: var(--bg-soft);
  border-radius: 12px;
}

main {
  overflow: hidden;
}

.hero {
  width: min(1220px, calc(100% - 32px));
  margin: 28px auto 0;
  position: relative;
}

.hero-stage {
  position: relative;
  min-height: 620px;
  overflow: hidden;
  border-radius: 34px;
  box-shadow: 0 30px 90px rgba(67, 20, 7, 0.22);
  background: #111111;
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(260px, 360px);
  gap: 48px;
  align-items: center;
  padding: 72px;
  opacity: 0;
  pointer-events: none;
  transform: scale(1.02);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

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

.hero-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: blur(8px) saturate(1.15);
  transform: scale(1.08);
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 76% 48%, rgba(249, 115, 22, 0.18), transparent 20rem),
    linear-gradient(90deg, rgba(16, 10, 6, 0.88), rgba(43, 18, 6, 0.72), rgba(17, 9, 5, 0.38));
}

.hero-content {
  position: relative;
  z-index: 2;
  color: #ffffff;
  max-width: 720px;
}

.eyebrow,
.section-kicker {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  color: #fff7ed;
  background: rgba(249, 115, 22, 0.24);
  border: 1px solid rgba(251, 146, 60, 0.38);
  border-radius: 999px;
  padding: 7px 14px;
  font-size: 13px;
  font-weight: 900;
  letter-spacing: 0.08em;
}

.section-kicker {
  color: var(--primary-dark);
  background: rgba(255, 237, 213, 0.9);
  border-color: rgba(251, 146, 60, 0.24);
}

.hero h1 {
  max-width: 820px;
  margin: 20px 0 14px;
  font-size: clamp(34px, 5vw, 68px);
  line-height: 1.05;
  letter-spacing: -0.08em;
}

.hero h2 {
  margin: 0 0 18px;
  font-size: clamp(26px, 3vw, 44px);
  line-height: 1.1;
}

.hero p {
  max-width: 660px;
  color: rgba(255, 255, 255, 0.82);
  font-size: 18px;
  line-height: 1.9;
}

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

.hero-tags span,
.tag-row span {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 5px 10px;
  border-radius: 999px;
  color: #7c2d12;
  background: #ffedd5;
  font-size: 12px;
  font-weight: 800;
}

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

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

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

.primary-button {
  color: #ffffff;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  box-shadow: 0 14px 32px rgba(234, 88, 12, 0.3);
}

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

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

.hero-poster {
  position: relative;
  z-index: 2;
  border-radius: 28px;
  overflow: hidden;
  transform: rotate(2deg);
  box-shadow: 0 32px 60px rgba(0, 0, 0, 0.35);
}

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

.hero-dots {
  position: absolute;
  left: 72px;
  bottom: 38px;
  z-index: 4;
  display: flex;
  gap: 10px;
}

.hero-dot {
  width: 36px;
  height: 8px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.35);
  cursor: pointer;
  transition: width 0.2s ease, background 0.2s ease;
}

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

.section {
  width: min(1220px, calc(100% - 32px));
  margin: 58px auto;
}

.section-soft,
.section-panel {
  padding: 28px;
  background: rgba(255, 255, 255, 0.82);
  border: 1px solid var(--line);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow);
}

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

.section-head h2 {
  margin: 10px 0 0;
  font-size: clamp(26px, 3vw, 42px);
  line-height: 1.12;
  letter-spacing: -0.04em;
}

.compact-head h2 {
  font-size: 28px;
}

.section-link {
  color: var(--primary-dark);
  background: #fff7ed;
  border: 1px solid var(--line);
}

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

.category-pill,
.category-card {
  display: grid;
  gap: 10px;
  min-height: 118px;
  padding: 20px;
  border-radius: 22px;
  background: linear-gradient(135deg, #ffffff, #fff7ed);
  border: 1px solid var(--line);
  box-shadow: 0 10px 26px rgba(120, 53, 15, 0.08);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.category-pill:hover,
.category-card:hover,
.movie-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 20px 46px rgba(120, 53, 15, 0.15);
}

.category-pill strong,
.category-card h2 {
  color: var(--primary-dark);
  font-size: 20px;
}

.category-pill span,
.category-card p {
  color: var(--muted);
  line-height: 1.7;
}

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

.movie-card {
  overflow: hidden;
  border-radius: var(--radius-lg);
  background: var(--card);
  border: 1px solid var(--line);
  box-shadow: 0 12px 34px rgba(120, 53, 15, 0.08);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.poster-link {
  position: relative;
  display: block;
  overflow: hidden;
  background: #1f1a17;
}

.poster-link img {
  width: 100%;
  aspect-ratio: 3 / 4.2;
  object-fit: cover;
  transition: transform 0.35s ease;
}

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

.poster-link::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 45%, rgba(0, 0, 0, 0.62));
  opacity: 0.9;
}

.poster-play {
  position: absolute;
  right: 12px;
  bottom: 12px;
  z-index: 2;
  width: 38px;
  height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  border-radius: 999px;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.28);
}

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

.movie-meta-line,
.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

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

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

.movie-card p {
  margin: 0 0 12px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.65;
}

.movie-card-compact .movie-card-body {
  padding: 12px;
}

.movie-card-compact h3 {
  font-size: 15px;
}

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

.section-split {
  display: grid;
  grid-template-columns: 0.95fr 1.05fr;
  gap: 24px;
}

.ranking-list {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 12px;
}

.ranking-list li a {
  display: grid;
  grid-template-columns: 44px 58px minmax(0, 1fr);
  grid-template-areas:
    "no img title"
    "no img meta";
  gap: 0 14px;
  align-items: center;
  padding: 10px;
  border-radius: 16px;
  background: rgba(255, 247, 237, 0.78);
  border: 1px solid rgba(251, 146, 60, 0.15);
}

.ranking-list li a:hover {
  background: #ffffff;
}

.rank-no {
  grid-area: no;
  color: var(--primary);
  font-size: 24px;
  font-weight: 900;
}

.ranking-list img {
  grid-area: img;
  width: 58px;
  height: 78px;
  object-fit: cover;
  border-radius: 12px;
}

.rank-title {
  grid-area: title;
  font-weight: 900;
  line-height: 1.35;
}

.rank-meta {
  grid-area: meta;
  color: var(--muted);
  font-size: 13px;
}

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

.page-hero,
.movie-detail-hero {
  width: min(1220px, calc(100% - 32px));
  margin: 28px auto 0;
  border-radius: 34px;
  overflow: hidden;
  position: relative;
  background:
    radial-gradient(circle at top right, rgba(249, 115, 22, 0.22), transparent 24rem),
    linear-gradient(135deg, #2a1409, #7c2d12);
  color: #ffffff;
  box-shadow: var(--shadow);
}

.page-hero {
  min-height: 280px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 28px;
  padding: 48px;
}

.page-hero h1 {
  margin: 18px 0 12px;
  font-size: clamp(34px, 4vw, 58px);
  line-height: 1.1;
  letter-spacing: -0.06em;
}

.page-hero p {
  margin: 0;
  max-width: 760px;
  color: rgba(255, 255, 255, 0.82);
  line-height: 1.8;
  font-size: 18px;
}

.inline-filter {
  min-width: 340px;
  display: flex;
  gap: 12px;
  padding: 10px;
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.24);
  border-radius: 20px;
  backdrop-filter: blur(12px);
}

.inline-filter input,
.inline-filter select {
  min-height: 46px;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.12);
  border-radius: 14px;
  padding: 0 14px;
}

.inline-filter input::placeholder {
  color: rgba(255, 255, 255, 0.72);
}

.inline-filter select option {
  color: var(--text);
}

.empty-state {
  display: none;
  margin: 28px 0 0;
  padding: 24px;
  text-align: center;
  color: var(--muted);
  background: #ffffff;
  border: 1px solid var(--line);
  border-radius: 18px;
}

.empty-state.is-visible {
  display: block;
}

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

.category-card {
  min-height: 260px;
}

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

.category-card-thumbs img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: 12px;
}

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

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

.detail-backdrop::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(12, 7, 4, 0.92), rgba(64, 25, 8, 0.72));
}

.detail-layout {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  gap: 38px;
  align-items: center;
  padding: 56px;
}

.detail-poster img {
  width: 100%;
  aspect-ratio: 3 / 4.2;
  object-fit: cover;
  border-radius: 26px;
  box-shadow: 0 28px 55px rgba(0, 0, 0, 0.32);
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  color: rgba(255, 255, 255, 0.72);
  font-weight: 800;
}

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

.detail-info h1 {
  margin: 18px 0 14px;
  font-size: clamp(34px, 5vw, 66px);
  line-height: 1.06;
  letter-spacing: -0.07em;
}

.detail-one-line {
  max-width: 780px;
  color: rgba(255, 255, 255, 0.84);
  font-size: 19px;
  line-height: 1.8;
}

.detail-meta {
  margin: 20px 0;
  color: rgba(255, 255, 255, 0.78);
}

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

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

.player-shell {
  position: relative;
  width: 100%;
  overflow: hidden;
  border-radius: 30px;
  background: #090909;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.28);
  aspect-ratio: 16 / 9;
}

.player-video,
.player-cover {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.player-video {
  z-index: 1;
  object-fit: contain;
  background: #000000;
}

.player-cover {
  z-index: 2;
  border: 0;
  padding: 0;
  cursor: pointer;
  background: #000000;
}

.player-cover.is-hidden {
  opacity: 0;
  pointer-events: none;
}

.player-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.62;
  filter: saturate(1.08);
}

.big-play {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  width: 96px;
  height: 96px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  border-radius: 999px;
  box-shadow: 0 20px 48px rgba(234, 88, 12, 0.35);
  font-size: 34px;
}

.detail-content-section {
  margin-top: 36px;
}

.detail-article {
  padding: 34px;
  background: #ffffff;
  border: 1px solid var(--line);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow);
}

.detail-article h2 {
  margin: 0 0 12px;
  font-size: 28px;
}

.detail-article h2:not(:first-child) {
  margin-top: 30px;
}

.detail-article p {
  margin: 0;
  color: #4b4039;
  font-size: 17px;
  line-height: 2;
}

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

.site-footer {
  margin-top: 72px;
  padding: 42px 0;
  color: #fff7ed;
  background: linear-gradient(135deg, #2a1409, #7c2d12);
}

.footer-shell {
  width: min(1220px, calc(100% - 32px));
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 30px;
}

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

.site-footer p {
  max-width: 600px;
  color: rgba(255, 247, 237, 0.78);
  line-height: 1.8;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  font-weight: 800;
}

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

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

  .header-search input {
    width: 160px;
  }
}

@media (max-width: 920px) {
  .desktop-nav,
  .header-search {
    display: none;
  }

  .menu-toggle {
    display: block;
    margin-left: auto;
  }

  .hero-stage {
    min-height: 760px;
  }

  .hero-slide {
    grid-template-columns: 1fr;
    align-content: end;
    padding: 38px;
  }

  .hero-poster {
    max-width: 260px;
    transform: none;
  }

  .hero-dots {
    left: 38px;
    bottom: 24px;
  }

  .section-split,
  .page-hero,
  .detail-layout {
    grid-template-columns: 1fr;
  }

  .page-hero,
  .detail-layout {
    padding: 34px;
  }

  .inline-filter {
    min-width: 0;
    width: 100%;
  }

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

  .detail-poster {
    max-width: 260px;
  }
}

@media (max-width: 680px) {
  .header-shell {
    width: min(100% - 24px, 1220px);
    height: 66px;
  }

  .brand-mark {
    width: 36px;
    height: 36px;
    border-radius: 12px;
  }

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

  .hero,
  .section,
  .page-hero,
  .movie-detail-hero,
  .footer-shell,
  .mobile-nav {
    width: min(100% - 24px, 1220px);
  }

  .hero-stage {
    min-height: 680px;
    border-radius: 24px;
  }

  .hero-slide {
    padding: 26px;
    gap: 24px;
  }

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

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

  .hero-actions {
    gap: 10px;
  }

  .primary-button,
  .ghost-button,
  .section-link {
    min-height: 42px;
    padding: 0 16px;
  }

  .hero-dots {
    left: 26px;
  }

  .section,
  .site-footer {
    margin-top: 38px;
    margin-bottom: 38px;
  }

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

  .section-soft,
  .section-panel,
  .detail-article {
    padding: 20px;
    border-radius: 22px;
  }

  .category-strip,
  .category-card-grid,
  .compact-grid,
  .movie-grid,
  .related-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
  }

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

  .movie-card p,
  .tag-row {
    display: none;
  }

  .page-hero,
  .detail-layout {
    padding: 24px;
    border-radius: 24px;
  }

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

  .inline-filter {
    flex-direction: column;
  }

  .detail-poster {
    max-width: 220px;
  }

  .player-shell {
    border-radius: 22px;
  }

  .big-play {
    width: 74px;
    height: 74px;
    font-size: 28px;
  }

  .ranking-list li a {
    grid-template-columns: 38px 52px minmax(0, 1fr);
  }

  .ranking-list img {
    width: 52px;
    height: 70px;
  }
}
