*,
*::before,
*::after {
  box-sizing: border-box;
}

:root {
  --ink-900: #3d3d3d;
  --ink-700: #4f4f4f;
  --ink-500: #777777;
  --mist-50: #f8f9fa;
  --mist-100: #f1f3f5;
  --mist-200: #e9ecef;
  --mist-300: #dee2e6;
  --mountain-50: #e8f4f8;
  --mountain-400: #47a7c7;
  --mountain-600: #236e86;
  --mountain-700: #1a5264;
  --paper-100: #fcfcfc;
  --paper-200: #fafafa;
  --white: #ffffff;
  --shadow-soft: 0 16px 40px rgba(35, 110, 134, 0.12);
  --shadow-strong: 0 25px 50px rgba(0, 0, 0, 0.25);
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--paper-100);
  color: var(--ink-900);
  font-family: system-ui, -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 {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid rgba(222, 226, 230, 0.75);
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(18px);
}

.nav-wrap {
  display: flex;
  align-items: center;
  gap: 24px;
  width: min(1180px, calc(100% - 32px));
  min-height: 72px;
  margin: 0 auto;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  color: var(--ink-900);
  white-space: nowrap;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--mountain-600), var(--mountain-400));
  color: var(--white);
  box-shadow: var(--shadow-soft);
}

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

.nav-links {
  display: flex;
  align-items: center;
  gap: 20px;
  color: var(--ink-700);
  font-weight: 650;
}

.nav-links a {
  transition: color 0.2s ease;
}

.nav-links a:hover {
  color: var(--mountain-600);
}

.top-search {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-left: auto;
  padding: 6px;
  border: 1px solid var(--mist-200);
  border-radius: 999px;
  background: var(--mist-50);
}

.top-search input {
  width: 210px;
  border: 0;
  outline: 0;
  background: transparent;
  padding: 8px 10px;
  color: var(--ink-900);
}

.top-search button,
.btn-primary,
.btn-secondary,
.btn-ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 999px;
  cursor: pointer;
  font-weight: 750;
  transition: transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}

.top-search button,
.btn-primary {
  padding: 10px 18px;
  background: var(--mountain-600);
  color: var(--white);
  box-shadow: 0 12px 26px rgba(35, 110, 134, 0.24);
}

.btn-secondary {
  padding: 10px 18px;
  background: rgba(255, 255, 255, 0.9);
  color: var(--mountain-700);
}

.btn-ghost {
  padding: 10px 18px;
  background: rgba(255, 255, 255, 0.18);
  color: var(--white);
  border: 1px solid rgba(255, 255, 255, 0.28);
  backdrop-filter: blur(10px);
}

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

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 12px;
  background: var(--mist-100);
  cursor: pointer;
}

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

.hero-carousel {
  position: relative;
  min-height: 70vh;
  overflow: hidden;
  background: #000000;
}

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

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

.hero-bg,
.page-hero > img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-gradient,
.page-hero-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.16), rgba(0, 0, 0, 0.72)), linear-gradient(90deg, rgba(0, 0, 0, 0.76), rgba(0, 0, 0, 0.18));
}

.hero-content {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  width: min(1180px, calc(100% - 32px));
  min-height: 70vh;
  margin: 0 auto;
  padding: 128px 0 80px;
  color: var(--white);
}

.eyebrow,
.section-kicker {
  display: inline-flex;
  width: fit-content;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 750;
  letter-spacing: 0.08em;
}

.eyebrow {
  padding: 6px 12px;
  background: var(--mountain-600);
  color: var(--white);
}

.section-kicker {
  margin: 0 0 8px;
  color: var(--mountain-600);
  text-transform: uppercase;
}

.hero-content h1 {
  max-width: 760px;
  margin: 20px 0 16px;
  font-size: clamp(40px, 6vw, 76px);
  line-height: 1;
  letter-spacing: -0.04em;
}

.hero-content p {
  max-width: 720px;
  margin: 0 0 24px;
  color: var(--mist-100);
  font-size: 19px;
}

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

.hero-tags span,
.tag-row span {
  padding: 5px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.14);
  color: var(--white);
  font-size: 13px;
}

.tag-row span {
  background: var(--mountain-50);
  color: var(--mountain-700);
}

.large-tags span {
  padding: 7px 12px;
}

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

.hero-arrow {
  position: absolute;
  top: 50%;
  z-index: 3;
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
  color: var(--white);
  font-size: 34px;
  cursor: pointer;
  backdrop-filter: blur(10px);
}

.hero-prev {
  left: 24px;
}

.hero-next {
  right: 24px;
}

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

.hero-dots button {
  width: 18px;
  height: 5px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.48);
  cursor: pointer;
  transition: width 0.2s ease, background 0.2s ease;
}

.hero-dots button.is-active {
  width: 36px;
  background: var(--white);
}

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

.section-white {
  background: var(--paper-100);
}

.section-soft {
  width: 100%;
  padding-left: max(16px, calc((100% - 1180px) / 2));
  padding-right: max(16px, calc((100% - 1180px) / 2));
  background: var(--mist-50);
}

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

.section-head h2,
.content-card h2,
.side-panel h2,
.related-cats h2 {
  margin: 0;
  color: var(--ink-900);
  font-size: clamp(26px, 4vw, 38px);
  line-height: 1.15;
}

.text-link {
  display: inline-flex;
  align-items: center;
  color: var(--mountain-600);
  font-weight: 760;
}

.text-link:hover {
  color: var(--mountain-700);
}

.grid {
  display: grid;
  gap: 24px;
}

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

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

.movie-card {
  overflow: hidden;
  border: 1px solid rgba(222, 226, 230, 0.7);
  border-radius: 24px;
  background: var(--white);
  box-shadow: 0 10px 28px rgba(61, 61, 61, 0.06);
  transition: transform 0.24s ease, box-shadow 0.24s ease;
}

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

.poster-link {
  position: relative;
  display: block;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  background: linear-gradient(135deg, var(--mountain-50), var(--mist-200));
}

.card-large .poster-link {
  aspect-ratio: 16 / 10;
}

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

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

.poster-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 35%, rgba(0, 0, 0, 0.58));
}

.play-chip,
.rank-badge {
  position: absolute;
  z-index: 2;
  border-radius: 999px;
  color: var(--white);
  font-weight: 800;
}

.play-chip {
  right: 12px;
  bottom: 12px;
  padding: 6px 12px;
  background: rgba(35, 110, 134, 0.92);
}

.rank-badge {
  left: 12px;
  top: 12px;
  padding: 6px 10px;
  background: rgba(0, 0, 0, 0.64);
}

.card-body {
  padding: 18px;
}

.card-meta,
.ranking-topline {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-bottom: 9px;
  color: var(--ink-500);
  font-size: 13px;
}

.card-meta span,
.ranking-topline span:not(.rank-num) {
  padding: 3px 8px;
  border-radius: 999px;
  background: var(--mist-100);
}

.movie-card h3 {
  margin: 0 0 8px;
  color: var(--ink-900);
  font-size: 18px;
  line-height: 1.35;
}

.movie-card p {
  display: -webkit-box;
  min-height: 44px;
  margin: 0 0 14px;
  overflow: hidden;
  color: var(--ink-700);
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

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

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

.category-card {
  display: grid;
  grid-template-columns: minmax(160px, 0.8fr) minmax(0, 1.2fr);
  overflow: hidden;
  border: 1px solid rgba(222, 226, 230, 0.72);
  border-radius: 28px;
  background: var(--white);
  box-shadow: 0 12px 30px rgba(61, 61, 61, 0.06);
}

.category-cover {
  position: relative;
  overflow: hidden;
  min-height: 260px;
  background: var(--mountain-50);
}

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

.category-cover span {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent, rgba(0, 0, 0, 0.35));
}

.category-content {
  padding: 24px;
}

.category-content > p:first-child {
  margin: 0 0 6px;
  color: var(--mountain-600);
  font-weight: 800;
}

.category-content h2 {
  margin: 0 0 10px;
  font-size: 28px;
  line-height: 1.2;
}

.category-content p {
  color: var(--ink-700);
}

.mini-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 18px 0;
}

.mini-list span {
  max-width: 100%;
  padding: 5px 9px;
  overflow: hidden;
  border-radius: 999px;
  background: var(--mist-100);
  color: var(--ink-700);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.section-split {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: 28px;
}

.split-card,
.rank-panel,
.content-card,
.side-panel,
.side-cover {
  border: 1px solid rgba(222, 226, 230, 0.72);
  border-radius: 28px;
  background: var(--white);
  box-shadow: 0 12px 30px rgba(61, 61, 61, 0.06);
}

.split-card {
  padding: 34px;
  background: linear-gradient(135deg, var(--mountain-50), var(--white));
}

.split-card h2 {
  margin: 0 0 14px;
  font-size: 40px;
}

.split-card p {
  color: var(--ink-700);
}

.rank-panel {
  padding: 18px;
}

.rank-row,
.side-row {
  display: grid;
  align-items: center;
  gap: 14px;
  border-radius: 18px;
  transition: background 0.2s ease;
}

.rank-row {
  grid-template-columns: 48px 1fr auto;
  padding: 13px 14px;
}

.rank-row:hover,
.side-row:hover {
  background: var(--mist-50);
}

.rank-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 14px;
  background: var(--mountain-600);
  color: var(--white);
  font-weight: 850;
}

.rank-title {
  font-weight: 800;
}

.rank-info {
  color: var(--ink-500);
  font-size: 14px;
}

.page-hero {
  position: relative;
  min-height: 360px;
  overflow: hidden;
  background: linear-gradient(135deg, #163745, #236e86 58%, #47a7c7);
  color: var(--white);
}

.page-hero > div:not(.page-hero-shade) {
  position: relative;
  z-index: 2;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 96px 0 70px;
}

.page-hero h1 {
  max-width: 760px;
  margin: 18px 0 12px;
  font-size: clamp(38px, 6vw, 70px);
  line-height: 1;
}

.page-hero p {
  max-width: 720px;
  margin: 0 0 24px;
  color: var(--mist-100);
  font-size: 19px;
}

.compact-hero {
  min-height: 300px;
}

.search-box {
  display: flex;
  max-width: 660px;
  padding: 8px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: var(--shadow-strong);
}

.search-box input {
  flex: 1;
  min-width: 0;
  border: 0;
  outline: 0;
  padding: 14px 18px;
  background: transparent;
}

.search-box button {
  border: 0;
  border-radius: 999px;
  padding: 12px 22px;
  background: var(--mountain-600);
  color: var(--white);
  cursor: pointer;
  font-weight: 800;
}

.search-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  max-width: 780px;
  margin-top: 18px;
}

.search-chips button {
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 999px;
  padding: 7px 12px;
  background: rgba(255, 255, 255, 0.16);
  color: var(--white);
  cursor: pointer;
}

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

.ranking-item {
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: 22px;
  padding: 16px;
  border: 1px solid rgba(222, 226, 230, 0.72);
  border-radius: 24px;
  background: var(--white);
  box-shadow: 0 10px 28px rgba(61, 61, 61, 0.05);
}

.ranking-poster {
  overflow: hidden;
  border-radius: 18px;
  aspect-ratio: 2 / 3;
  background: var(--mountain-50);
}

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

.ranking-main h2 {
  margin: 5px 0 8px;
  font-size: 24px;
}

.ranking-main p {
  margin: 0 0 12px;
  color: var(--ink-700);
}

.rank-num.large {
  width: auto;
  min-width: 48px;
  height: 32px;
  padding: 0 10px;
}

.detail-shell {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 34px 0 72px;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 22px;
  color: var(--ink-500);
  font-size: 14px;
}

.breadcrumb a {
  color: var(--mountain-600);
  font-weight: 750;
}

.detail-grid {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(280px, 0.8fr);
  gap: 28px;
}

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

.movie-player {
  width: 100%;
  height: 100%;
  background: #000000;
  object-fit: contain;
}

.player-overlay {
  position: absolute;
  left: 50%;
  top: 50%;
  display: grid;
  place-items: center;
  width: 86px;
  height: 86px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.9);
  color: var(--mountain-600);
  cursor: pointer;
  transform: translate(-50%, -50%);
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.player-overlay span {
  margin-left: 5px;
  font-size: 38px;
}

.player-box.is-playing .player-overlay {
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, -50%) scale(0.96);
}

.detail-title-block {
  padding: 30px 0 18px;
}

.detail-title-block h1 {
  margin: 18px 0 12px;
  font-size: clamp(34px, 5vw, 58px);
  line-height: 1.08;
}

.detail-title-block p {
  max-width: 820px;
  color: var(--ink-700);
  font-size: 19px;
}

.content-card {
  margin-top: 20px;
  padding: 28px;
}

.content-card h2 {
  margin-bottom: 14px;
  font-size: 28px;
}

.content-card p {
  margin: 0 0 14px;
  color: var(--ink-700);
  font-size: 17px;
}

.detail-side {
  display: grid;
  align-content: start;
  gap: 20px;
}

.side-cover {
  overflow: hidden;
  padding: 16px;
}

.side-cover img {
  width: 100%;
  border-radius: 20px;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  background: var(--mountain-50);
}

.side-cover .btn-primary {
  width: 100%;
  margin-top: 14px;
}

.side-panel {
  padding: 22px;
}

.side-panel h2 {
  margin-bottom: 14px;
  font-size: 22px;
}

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

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

.side-panel dd {
  margin: 0;
  color: var(--ink-900);
  font-weight: 700;
}

.side-row {
  grid-template-columns: 38px 1fr;
  padding: 10px;
}

.side-row span {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 12px;
  background: var(--mountain-50);
  color: var(--mountain-700);
  font-weight: 850;
}

.related-cats > div {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}

.related-cats a {
  padding: 9px 13px;
  border-radius: 999px;
  background: var(--white);
  color: var(--mountain-600);
  font-weight: 760;
  box-shadow: 0 10px 24px rgba(61, 61, 61, 0.05);
}

.site-footer {
  background: var(--ink-900);
  color: var(--mist-200);
}

.footer-wrap {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 42px 0;
}

.footer-logo {
  display: inline-flex;
  margin-bottom: 10px;
  color: var(--white);
  font-size: 22px;
  font-weight: 850;
}

.footer-wrap p {
  max-width: 520px;
  margin: 0;
  color: var(--mist-300);
}

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

.footer-links a {
  color: var(--mist-100);
}

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

  .grid-three,
  .section-split,
  .detail-grid {
    grid-template-columns: 1fr;
  }

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

@media (max-width: 760px) {
  .nav-wrap {
    flex-wrap: wrap;
    min-height: 64px;
    padding: 10px 0;
  }

  .nav-toggle {
    display: inline-flex;
    margin-left: auto;
  }

  .nav-links {
    display: none;
    width: 100%;
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
    padding: 12px 0;
  }

  .nav-links.is-open {
    display: flex;
  }

  .nav-links a {
    padding: 10px 12px;
    border-radius: 14px;
    background: var(--mist-50);
  }

  .top-search {
    order: 5;
    width: 100%;
    margin-left: 0;
  }

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

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

  .hero-content {
    padding: 96px 0 76px;
  }

  .hero-arrow {
    display: none;
  }

  .section {
    padding: 52px 0;
  }

  .section-soft {
    padding-left: 16px;
    padding-right: 16px;
  }

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

  .grid-four,
  .grid-three {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
  }

  .category-card,
  .ranking-item {
    grid-template-columns: 1fr;
  }

  .category-cover {
    min-height: 220px;
  }

  .rank-row {
    grid-template-columns: 42px 1fr;
  }

  .rank-info {
    grid-column: 2;
  }

  .page-hero > div:not(.page-hero-shade) {
    padding: 72px 0 56px;
  }

  .search-box {
    border-radius: 24px;
    flex-direction: column;
  }

  .search-box button {
    width: 100%;
  }

  .detail-shell {
    padding-top: 22px;
  }
}

@media (max-width: 520px) {
  .grid-four,
  .grid-three {
    grid-template-columns: 1fr;
  }

  .hero-content h1,
  .page-hero h1 {
    font-size: 40px;
  }

  .hero-content p,
  .page-hero p,
  .detail-title-block p {
    font-size: 16px;
  }

  .card-large .poster-link {
    aspect-ratio: 2 / 3;
  }

  .content-card,
  .side-panel,
  .split-card {
    padding: 22px;
  }
}
