:root {
  --amber-50: #fffbeb;
  --amber-100: #fef3c7;
  --amber-200: #fde68a;
  --amber-500: #f59e0b;
  --amber-600: #d97706;
  --orange-500: #f97316;
  --orange-600: #ea580c;
  --gray-50: #f9fafb;
  --gray-100: #f3f4f6;
  --gray-200: #e5e7eb;
  --gray-500: #6b7280;
  --gray-600: #4b5563;
  --gray-700: #374151;
  --gray-800: #1f2937;
  --gray-900: #111827;
  --white: #ffffff;
  --shadow: 0 20px 45px rgba(17, 24, 39, 0.12);
  --soft-shadow: 0 12px 30px rgba(217, 119, 6, 0.13);
  --radius: 24px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--gray-900);
  background: var(--white);
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
  line-height: 1.6;
}

body.menu-open {
  overflow: hidden;
}

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

img,
video {
  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: 100;
  background: rgba(255, 255, 255, 0.94);
  border-bottom: 1px solid rgba(253, 230, 138, 0.9);
  box-shadow: 0 10px 24px rgba(17, 24, 39, 0.06);
  backdrop-filter: blur(14px);
}

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

.logo,
.footer-logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 26px;
  font-weight: 800;
  letter-spacing: -0.04em;
  background: linear-gradient(135deg, var(--amber-600), var(--orange-600));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.logo-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 14px;
  color: var(--white);
  background: linear-gradient(135deg, var(--amber-500), var(--orange-600));
  box-shadow: var(--soft-shadow);
  font-size: 16px;
  letter-spacing: 0;
}

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

.nav-link {
  display: inline-flex;
  align-items: center;
  padding: 10px 16px;
  border-radius: 999px;
  color: var(--gray-700);
  font-weight: 650;
  transition: color 0.25s ease, background 0.25s ease, transform 0.25s ease;
}

.nav-link:hover,
.nav-link.active {
  color: var(--amber-600);
  background: var(--amber-50);
  transform: translateY(-1px);
}

.menu-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 14px;
  color: var(--amber-600);
  background: var(--amber-50);
}

.mobile-nav {
  display: none;
  padding: 0 16px 16px;
  border-top: 1px solid var(--gray-200);
  background: var(--white);
}

.mobile-nav .nav-link {
  display: flex;
  margin: 8px auto 0;
  width: min(1180px, 100%);
}

.hero-carousel {
  position: relative;
  min-height: 660px;
  overflow: hidden;
  background: radial-gradient(circle at 15% 25%, rgba(253, 230, 138, 0.85), transparent 30%), linear-gradient(135deg, var(--amber-50), #fff7ed 48%, var(--white));
}

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

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

.hero-slide img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(17, 24, 39, 0.86) 0%, rgba(17, 24, 39, 0.54) 42%, rgba(17, 24, 39, 0.15) 100%), linear-gradient(0deg, rgba(17, 24, 39, 0.46), transparent 42%);
}

.hero-content {
  position: relative;
  display: flex;
  align-items: center;
  min-height: 660px;
  padding-top: 54px;
  padding-bottom: 132px;
}

.hero-copy {
  max-width: 760px;
  color: var(--white);
}

.hero-kicker,
.section-heading p,
.page-hero p {
  margin: 0 0 12px;
  color: var(--amber-200);
  font-size: 14px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.hero-copy h1 {
  margin: 0;
  font-size: clamp(40px, 7vw, 84px);
  line-height: 0.98;
  letter-spacing: -0.07em;
}

.hero-copy p {
  max-width: 660px;
  margin: 22px 0 0;
  color: rgba(255, 255, 255, 0.88);
  font-size: clamp(17px, 2.2vw, 24px);
}

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

.hero-tags {
  margin-top: 24px;
}

.hero-tags span,
.tag-row span,
.detail-meta span {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.2);
  padding: 7px 12px;
  color: rgba(255, 255, 255, 0.9);
  font-size: 13px;
  font-weight: 700;
}

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

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

.primary-button {
  color: var(--white);
  background: linear-gradient(135deg, var(--amber-500), var(--orange-600));
  box-shadow: var(--soft-shadow);
}

.ghost-button {
  color: var(--white);
  border: 1px solid rgba(255, 255, 255, 0.34);
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(8px);
}

.primary-button:hover,
.ghost-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 38px rgba(217, 119, 6, 0.25);
}

.hero-search {
  position: absolute;
  left: 50%;
  bottom: 54px;
  transform: translateX(-50%);
  z-index: 5;
}

.hero-search-form {
  display: flex;
  gap: 10px;
  width: min(720px, 100%);
  padding: 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: var(--shadow);
  backdrop-filter: blur(14px);
}

.hero-search-form input {
  flex: 1;
  min-width: 0;
  border: 0;
  outline: 0;
  padding: 0 20px;
  color: var(--gray-800);
  background: transparent;
}

.hero-search-form button {
  border: 0;
  border-radius: 999px;
  padding: 12px 24px;
  color: var(--white);
  background: linear-gradient(135deg, var(--amber-500), var(--orange-600));
  font-weight: 800;
  cursor: pointer;
}

.hero-dots {
  position: absolute;
  right: calc((100vw - min(1180px, calc(100vw - 32px))) / 2);
  bottom: 72px;
  z-index: 6;
  display: flex;
  gap: 8px;
}

.hero-dot {
  width: 10px;
  height: 10px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.45);
  cursor: pointer;
  transition: width 0.25s ease, background 0.25s ease;
}

.hero-dot.active {
  width: 34px;
  background: var(--white);
}

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

.section-soft {
  background: linear-gradient(135deg, var(--amber-50), #fff7ed);
}

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

.section-heading h2,
.page-hero h1,
.detail-copy h1,
.story-card h2 {
  margin: 0;
  color: var(--gray-900);
  font-size: clamp(28px, 4vw, 48px);
  line-height: 1.08;
  letter-spacing: -0.05em;
}

.section-heading p,
.page-hero p {
  color: var(--amber-600);
}

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

.movie-grid {
  display: grid;
  gap: 22px;
}

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

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

.movie-card {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(253, 230, 138, 0.85);
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: 0 8px 24px rgba(17, 24, 39, 0.07);
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.movie-card:hover {
  border-color: var(--amber-500);
  transform: translateY(-5px);
  box-shadow: var(--shadow);
}

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

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

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

.poster::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 44%;
  background: linear-gradient(0deg, rgba(17, 24, 39, 0.78), transparent);
}

.poster-play {
  position: absolute;
  right: 14px;
  bottom: 14px;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 999px;
  color: var(--white);
  background: linear-gradient(135deg, var(--amber-500), var(--orange-600));
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.24);
}

.rank-badge {
  position: absolute;
  left: 12px;
  top: 12px;
  z-index: 3;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 42px;
  height: 34px;
  padding: 0 10px;
  border-radius: 999px;
  color: var(--white);
  background: linear-gradient(135deg, var(--amber-500), var(--orange-600));
  box-shadow: var(--soft-shadow);
}

.movie-info {
  padding: 18px;
}

.meta-line {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 10px;
  color: var(--amber-600);
  font-size: 12px;
  font-weight: 800;
}

.movie-info h2 {
  display: -webkit-box;
  min-height: 56px;
  margin: 0;
  overflow: hidden;
  color: var(--gray-900);
  font-size: 20px;
  line-height: 1.35;
  letter-spacing: -0.03em;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.movie-info p {
  display: -webkit-box;
  min-height: 68px;
  margin: 10px 0 14px;
  overflow: hidden;
  color: var(--gray-600);
  font-size: 14px;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
}

.tag-row span {
  color: var(--amber-700, #92400e);
  background: var(--amber-50);
  border-color: var(--amber-200);
}

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

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

.category-tile {
  position: relative;
  min-height: 190px;
  overflow: hidden;
  border-radius: var(--radius);
  color: var(--white);
  background: var(--gray-900);
  box-shadow: var(--soft-shadow);
}

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

.category-tile::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(17, 24, 39, 0.78), rgba(17, 24, 39, 0.06));
}

.category-tile span,
.category-tile em {
  position: relative;
  z-index: 2;
  display: block;
}

.category-tile span {
  padding: 86px 18px 0;
  font-size: 24px;
  font-weight: 900;
  letter-spacing: -0.04em;
}

.category-tile em {
  padding: 6px 18px 18px;
  color: rgba(255, 255, 255, 0.86);
  font-size: 13px;
  font-style: normal;
}

.category-tile:hover img {
  opacity: 0.78;
  transform: scale(1.08);
}

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

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

.page-hero {
  position: relative;
  overflow: hidden;
  padding: 86px 0 74px;
  background: radial-gradient(circle at 12% 18%, rgba(253, 230, 138, 0.9), transparent 28%), linear-gradient(135deg, var(--amber-50), #fff7ed 56%, var(--white));
}

.small-hero .lead-text {
  max-width: 760px;
  margin-top: 16px;
  color: var(--gray-600);
  font-size: 18px;
}

.filter-panel {
  padding: 24px 0;
  background: var(--white);
  border-bottom: 1px solid var(--gray-200);
}

.filter-inner {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) auto;
  gap: 18px;
  align-items: end;
}

.filter-panel label {
  display: grid;
  gap: 8px;
  color: var(--gray-700);
  font-weight: 800;
}

.filter-panel input,
.filter-panel select {
  width: 100%;
  min-height: 48px;
  border: 1px solid var(--amber-200);
  border-radius: 16px;
  outline: 0;
  padding: 0 16px;
  color: var(--gray-800);
  background: var(--amber-50);
}

.filter-panel input:focus,
.filter-panel select:focus {
  border-color: var(--amber-500);
  background: var(--white);
  box-shadow: 0 0 0 4px rgba(245, 158, 11, 0.15);
}

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

.detail-hero {
  padding: 54px 0;
  background: radial-gradient(circle at 12% 18%, rgba(253, 230, 138, 0.92), transparent 26%), linear-gradient(135deg, #111827, #3b2f12 58%, #111827);
}

.detail-layout {
  display: grid;
  grid-template-columns: 300px minmax(0, 1fr);
  gap: 40px;
  align-items: center;
}

.detail-poster {
  overflow: hidden;
  border: 6px solid rgba(255, 255, 255, 0.2);
  border-radius: 28px;
  box-shadow: 0 30px 70px rgba(0, 0, 0, 0.36);
}

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

.detail-copy {
  color: var(--white);
}

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

.breadcrumb a {
  color: var(--amber-200);
}

.detail-copy h1 {
  color: var(--white);
  font-size: clamp(38px, 6vw, 76px);
}

.detail-meta {
  margin: 18px 0 20px;
}

.detail-copy p {
  max-width: 820px;
  margin: 0 0 22px;
  color: rgba(255, 255, 255, 0.86);
  font-size: 19px;
}

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

.player-section {
  padding: 48px 0 0;
  background: var(--gray-900);
}

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

.movie-video {
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #000000;
}

.play-overlay {
  position: absolute;
  inset: 0;
  z-index: 5;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 12px;
  width: 100%;
  border: 0;
  color: var(--white);
  background: linear-gradient(0deg, rgba(17, 24, 39, 0.58), rgba(17, 24, 39, 0.28));
  cursor: pointer;
}

.play-overlay span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 82px;
  height: 82px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--amber-500), var(--orange-600));
  box-shadow: 0 20px 45px rgba(0, 0, 0, 0.28);
  font-size: 28px;
}

.play-overlay strong {
  font-size: 20px;
}

.play-overlay.is-hidden {
  display: none;
}

.detail-content {
  background: var(--gray-900);
}

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

.story-card {
  border: 1px solid rgba(253, 230, 138, 0.18);
  border-radius: var(--radius);
  padding: 28px;
  color: rgba(255, 255, 255, 0.86);
  background: rgba(255, 255, 255, 0.06);
}

.story-card h2 {
  margin-bottom: 14px;
  color: var(--white);
  font-size: 28px;
}

.story-card p {
  margin: 0;
}

.site-footer {
  background: linear-gradient(135deg, var(--amber-50), #fff7ed);
  border-top: 1px solid var(--amber-200);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.3fr 0.8fr 1fr;
  gap: 30px;
  padding: 52px 0 36px;
}

.footer-grid p {
  max-width: 460px;
  color: var(--gray-600);
}

.footer-grid h2 {
  margin: 0 0 14px;
  color: var(--gray-900);
  font-size: 18px;
}

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

.footer-links a {
  color: var(--gray-600);
  font-weight: 650;
}

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

.footer-bottom {
  padding: 22px 16px;
  color: var(--gray-600);
  text-align: center;
  border-top: 1px solid var(--amber-200);
}

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

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

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

  .menu-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  .mobile-nav.is-open {
    display: block;
  }

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

  .hero-copy h1 {
    font-size: clamp(40px, 12vw, 64px);
  }

  .hero-search {
    bottom: 34px;
  }

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

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

  .hero-dots {
    right: auto;
    left: 50%;
    bottom: 14px;
    transform: translateX(-50%);
  }

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

  .featured-grid,
  .catalog-grid,
  .ranking-list,
  .ranking-page-list,
  .category-grid,
  .large-category-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .filter-inner,
  .detail-layout,
  .content-grid,
  .footer-grid {
    grid-template-columns: 1fr;
  }

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

  .detail-layout {
    gap: 28px;
  }

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

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

  .header-inner {
    min-height: 64px;
  }

  .logo,
  .footer-logo {
    font-size: 22px;
  }

  .logo-mark {
    width: 34px;
    height: 34px;
  }

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

  .hero-content {
    padding-top: 36px;
  }

  .hero-copy p {
    font-size: 16px;
  }

  .featured-grid,
  .catalog-grid,
  .ranking-list,
  .ranking-page-list,
  .category-grid,
  .large-category-grid {
    grid-template-columns: 1fr;
  }

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

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

  .movie-info h2 {
    min-height: auto;
  }

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