:root {
  --warm-50: #faf8f4;
  --warm-100: #f2ece1;
  --warm-200: #e7dccd;
  --warm-300: #d2c2ae;
  --warm-600: #7d6a56;
  --warm-700: #594838;
  --warm-800: #342a22;
  --warm-900: #1b1714;
  --sky-50: #edf8ff;
  --sky-100: #d9f0ff;
  --sky-500: #0ea5e9;
  --sky-600: #0284c7;
  --sky-700: #0369a1;
  --amber-400: #fbbf24;
  --amber-500: #f59e0b;
  --white: #ffffff;
  --shadow-soft: 0 14px 36px rgba(27, 23, 20, 0.10);
  --shadow-card: 0 10px 30px rgba(27, 23, 20, 0.13);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--warm-800);
  background: var(--warm-50);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", Arial, sans-serif;
}

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: 80;
  background: rgba(255, 255, 255, 0.95);
  box-shadow: 0 8px 24px rgba(27, 23, 20, 0.08);
  backdrop-filter: blur(18px);
}

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

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

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

.brand-icon {
  display: inline-grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 12px;
  color: var(--white);
  background: linear-gradient(135deg, var(--sky-600), var(--amber-500));
  box-shadow: 0 10px 22px rgba(2, 132, 199, 0.22);
  font-size: 14px;
}

.desktop-nav {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 22px;
  flex-wrap: wrap;
}

.nav-link,
.mobile-nav-link {
  color: var(--warm-700);
  font-size: 15px;
  font-weight: 700;
  transition: color 0.2s ease, transform 0.2s ease;
}

.nav-link:hover,
.nav-link.is-active,
.mobile-nav-link:hover,
.mobile-nav-link.is-active {
  color: var(--sky-600);
}

.nav-link-soft {
  font-weight: 600;
  color: var(--warm-600);
}

.menu-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 12px;
  background: var(--warm-100);
  color: var(--warm-900);
  cursor: pointer;
}

.mobile-nav {
  display: none;
  border-top: 1px solid var(--warm-100);
  padding: 10px 16px 18px;
  background: var(--white);
}

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

.home-hero {
  position: relative;
  min-height: 72vh;
  overflow: hidden;
  background: var(--warm-900);
}

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

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

.hero-slide img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.42;
  transform: scale(1.04);
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(27, 23, 20, 0.95) 0%, rgba(27, 23, 20, 0.72) 48%, rgba(27, 23, 20, 0.18) 100%);
}

.hero-content {
  position: relative;
  z-index: 2;
  min-height: 72vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  max-width: 760px;
  color: var(--white);
  padding: 70px 0 90px;
}

.hero-badge,
.eyebrow,
.detail-badge {
  width: max-content;
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  background: var(--amber-500);
  color: var(--white);
  padding: 7px 14px;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.08em;
}

.hero-content h1 {
  margin: 18px 0 16px;
  font-size: clamp(38px, 6vw, 68px);
  line-height: 1.05;
  font-weight: 900;
}

.hero-content p {
  width: min(100%, 680px);
  margin: 0 0 22px;
  color: rgba(255, 255, 255, 0.88);
  font-size: 18px;
  line-height: 1.8;
}

.hero-meta,
.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 28px;
}

.hero-meta span,
.detail-meta span {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  padding: 7px 12px;
  color: rgba(255, 255, 255, 0.9);
  font-size: 14px;
}

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

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

.primary-button {
  color: var(--white);
  background: var(--sky-600);
  box-shadow: 0 14px 26px rgba(2, 132, 199, 0.26);
}

.primary-button:hover,
.wide-link:hover {
  transform: translateY(-2px);
  background: var(--sky-700);
}

.ghost-button {
  color: var(--white);
  background: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.3);
}

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

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

.hero-dot.is-active {
  background: var(--sky-500);
}

.hero-search-block {
  position: relative;
  z-index: 6;
  margin-top: -36px;
}

.hero-search {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
  border-radius: 22px;
  padding: 16px;
  background: var(--white);
  box-shadow: var(--shadow-soft);
}

.hero-search input,
.filter-search input,
.filter-selects select {
  width: 100%;
  border: 1px solid var(--warm-200);
  border-radius: 14px;
  background: var(--white);
  color: var(--warm-800);
  min-height: 46px;
  padding: 0 16px;
  outline: none;
}

.hero-search input:focus,
.filter-search input:focus,
.filter-selects select:focus {
  border-color: var(--sky-500);
  box-shadow: 0 0 0 4px rgba(14, 165, 233, 0.12);
}

.hero-search button {
  border: 0;
  border-radius: 14px;
  padding: 0 28px;
  color: var(--white);
  background: var(--sky-600);
  font-weight: 800;
  cursor: pointer;
}

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

.gradient-section {
  background: linear-gradient(135deg, var(--sky-50), var(--warm-50));
}

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

.section-heading span {
  display: block;
  color: var(--sky-600);
  font-size: 13px;
  font-weight: 900;
  letter-spacing: 0.12em;
}

.section-heading h2,
.section-heading h3 {
  margin: 6px 0 0;
  color: var(--warm-900);
  font-weight: 900;
}

.section-heading h2 {
  font-size: clamp(26px, 4vw, 38px);
}

.section-heading h3 {
  font-size: 20px;
  line-height: 1.45;
}

.section-heading a {
  color: var(--sky-600);
  font-weight: 800;
}

.section-heading-small {
  align-items: center;
  margin-bottom: 20px;
}

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

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

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

.movie-card {
  overflow: hidden;
  border-radius: 18px;
  background: var(--white);
  box-shadow: var(--shadow-card);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 20px 42px rgba(27, 23, 20, 0.16);
}

.poster-link {
  position: relative;
  display: block;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  background: linear-gradient(135deg, var(--warm-200), var(--sky-100));
}

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

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

.poster-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.05), rgba(0, 0, 0, 0.78));
  opacity: 0;
  transition: opacity 0.25s ease;
}

.movie-card:hover .poster-shade {
  opacity: 1;
}

.play-mark {
  position: absolute;
  left: 50%;
  top: 50%;
  display: grid;
  place-items: center;
  width: 58px;
  height: 58px;
  border-radius: 50%;
  color: var(--white);
  background: rgba(14, 165, 233, 0.88);
  transform: translate(-50%, -50%) scale(0.82);
  opacity: 0;
  transition: opacity 0.25s ease, transform 0.25s ease;
}

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

.category-badge,
.rank-label {
  position: absolute;
  top: 12px;
  left: 12px;
  border-radius: 999px;
  color: var(--white);
  background: rgba(2, 132, 199, 0.92);
  padding: 5px 10px;
  font-size: 12px;
  font-weight: 800;
}

.rank-label {
  left: auto;
  right: 12px;
  background: rgba(245, 158, 11, 0.94);
}

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

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

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

.movie-meta,
.movie-line {
  margin: 0;
  color: var(--warm-600);
  font-size: 13px;
  line-height: 1.7;
}

.movie-line {
  margin-top: 8px;
  min-height: 44px;
}

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

.tag-row span,
.detail-tags a {
  display: inline-flex;
  border-radius: 999px;
  background: var(--sky-50);
  color: var(--sky-700);
  padding: 5px 9px;
  font-size: 12px;
  font-weight: 700;
}

.layout-with-side {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 330px;
  gap: 32px;
  align-items: start;
}

.category-blocks {
  display: grid;
  gap: 42px;
}

.category-strip {
  padding-bottom: 10px;
}

.ranking-panel,
.side-card,
.poster-panel,
.detail-card {
  border-radius: 20px;
  background: var(--white);
  box-shadow: var(--shadow-card);
}

.ranking-panel {
  position: sticky;
  top: 92px;
  padding: 22px;
}

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

.side-item {
  display: grid;
  grid-template-columns: auto 56px 1fr;
  align-items: center;
  gap: 12px;
  border-radius: 14px;
  padding: 10px;
  background: var(--warm-50);
  transition: background 0.2s ease, transform 0.2s ease;
}

.side-item:hover {
  background: var(--sky-50);
  transform: translateX(3px);
}

.side-item img {
  width: 56px;
  height: 74px;
  border-radius: 10px;
  object-fit: cover;
  background: var(--warm-100);
}

.side-item strong,
.side-item em {
  display: block;
}

.side-item strong {
  color: var(--warm-900);
  font-size: 14px;
  line-height: 1.4;
}

.side-item em {
  margin-top: 5px;
  color: var(--warm-600);
  font-size: 12px;
  font-style: normal;
}

.list-rank {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  color: var(--white);
  background: var(--amber-500);
  font-size: 13px;
  font-weight: 900;
}

.wide-link {
  width: 100%;
  margin-top: 18px;
  color: var(--white);
  background: var(--sky-600);
}

.page-hero {
  padding: 76px 0;
  color: var(--white);
  background: linear-gradient(120deg, var(--sky-700), var(--warm-900));
}

.page-hero h1 {
  margin: 16px 0 14px;
  font-size: clamp(34px, 5vw, 58px);
  line-height: 1.1;
  font-weight: 900;
}

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

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

.category-tile {
  position: relative;
  min-height: 280px;
  overflow: hidden;
  border-radius: 24px;
  box-shadow: var(--shadow-card);
  background: var(--warm-900);
}

.category-tile img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.44;
  transition: transform 0.35s ease;
}

.category-tile:hover img {
  transform: scale(1.06);
}

.category-tile-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(27, 23, 20, 0.12), rgba(27, 23, 20, 0.88));
}

.category-tile div {
  position: absolute;
  left: 24px;
  right: 24px;
  bottom: 24px;
  color: var(--white);
}

.category-tile strong {
  display: block;
  margin-bottom: 10px;
  font-size: 30px;
  font-weight: 900;
}

.category-tile p {
  margin: 0 0 14px;
  color: rgba(255, 255, 255, 0.86);
  line-height: 1.7;
}

.category-tile em {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  font-style: normal;
}

.category-tile em span {
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
  padding: 5px 10px;
  font-size: 12px;
}

.filter-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  margin-top: -26px;
  border-radius: 22px;
  padding: 16px;
  background: var(--white);
  box-shadow: var(--shadow-soft);
}

.filter-selects {
  display: flex;
  gap: 10px;
}

.filter-selects select {
  min-width: 140px;
}

.is-hidden {
  display: none !important;
}

.player-section {
  padding: 26px 0 42px;
  background: var(--warm-900);
}

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

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

.video-shell {
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-radius: 22px;
  background: #000000;
  box-shadow: 0 30px 70px rgba(0, 0, 0, 0.42);
}

.video-shell video {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: contain;
  background: #000000;
}

.video-start {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 3;
  display: grid;
  place-items: center;
  width: 88px;
  height: 88px;
  border: 0;
  border-radius: 50%;
  color: var(--white);
  background: rgba(14, 165, 233, 0.9);
  box-shadow: 0 20px 46px rgba(2, 132, 199, 0.4);
  transform: translate(-50%, -50%);
  cursor: pointer;
  font-size: 28px;
}

.video-shell.is-playing .video-start {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 330px;
  gap: 30px;
  align-items: start;
  padding: 44px 0 20px;
}

.detail-main {
  display: grid;
  gap: 22px;
}

.detail-card {
  padding: 28px;
}

.detail-card h1 {
  margin: 16px 0;
  color: var(--warm-900);
  font-size: clamp(30px, 4vw, 46px);
  line-height: 1.15;
  font-weight: 900;
}

.detail-card h2 {
  margin: 0 0 16px;
  color: var(--warm-900);
  font-size: 22px;
}

.detail-card p {
  margin: 0;
  color: var(--warm-700);
  line-height: 1.9;
  font-size: 16px;
}

.detail-card .detail-one-line {
  font-size: 19px;
  font-weight: 700;
}

.detail-meta span {
  background: var(--warm-100);
  color: var(--warm-700);
}

.detail-side {
  position: sticky;
  top: 92px;
  display: grid;
  gap: 22px;
}

.poster-panel,
.side-card {
  padding: 20px;
}

.poster-panel img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: 16px;
  background: var(--warm-100);
  margin-bottom: 16px;
}

.side-card h2 {
  margin: 0 0 16px;
  color: var(--warm-900);
  font-size: 20px;
}

.site-footer {
  margin-top: 40px;
  color: var(--warm-100);
  background: var(--warm-900);
}

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

.footer-brand {
  color: var(--white);
  font-size: 20px;
}

.site-footer p {
  max-width: 440px;
  color: var(--warm-300);
  line-height: 1.8;
}

.site-footer h2 {
  margin: 0 0 14px;
  color: var(--amber-400);
  font-size: 17px;
}

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

.footer-links a {
  color: var(--warm-300);
  font-size: 14px;
}

.footer-links a:hover {
  color: var(--amber-400);
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  padding: 18px;
  text-align: center;
  color: var(--warm-300);
  font-size: 13px;
}

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

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

  .menu-toggle {
    display: inline-grid;
    place-items: center;
  }

  .layout-with-side,
  .detail-layout,
  .filter-panel,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .ranking-panel,
  .detail-side {
    position: static;
  }

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

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

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

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

  .brand {
    font-size: 18px;
  }

  .home-hero,
  .hero-content {
    min-height: 66vh;
  }

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

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

  .hero-search {
    grid-template-columns: 1fr;
  }

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

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

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

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

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

  .movie-line {
    display: none;
  }

  .category-tile {
    min-height: 240px;
  }

  .detail-card,
  .poster-panel,
  .side-card {
    padding: 18px;
  }

  .video-start {
    width: 68px;
    height: 68px;
    font-size: 22px;
  }
}

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