:root {
  color-scheme: light;
  --ash-50: #f7f7f6;
  --ash-100: #ececea;
  --ash-200: #d9d8d5;
  --ash-300: #b8b6b0;
  --ash-500: #74716b;
  --ash-700: #3d3a35;
  --ash-800: #222326;
  --ash-900: #0d0f12;
  --volcanic-300: #f7a072;
  --volcanic-500: #f07f4a;
  --volcanic-600: #e84118;
  --volcanic-700: #c33212;
  --volcanic-800: #9f260f;
  --volcanic-900: #651707;
  --lava-300: #ffd06b;
  --lava-400: #ffb81a;
  --lava-600: #e68a00;
  --white: #ffffff;
  --shadow-card: 0 24px 60px rgba(13, 15, 18, 0.12);
  --shadow-volcanic: 0 18px 48px rgba(232, 65, 24, 0.32);
  --radius-lg: 24px;
  --radius-md: 18px;
  --radius-sm: 12px;
  font-family: Inter, "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ash-900);
  background: linear-gradient(180deg, #fff7f2 0%, var(--ash-50) 34%, #ffffff 100%);
}

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: 100;
  background: linear-gradient(90deg, var(--volcanic-900), var(--volcanic-700), var(--ash-900));
  color: var(--white);
  box-shadow: 0 12px 40px rgba(13, 15, 18, 0.22);
}

.top-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 76px;
  gap: 24px;
}

.brand,
.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
}

.brand-mark {
  display: inline-grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border-radius: 999px;
  color: var(--ash-900);
  background: radial-gradient(circle at 35% 30%, #fff4d2, var(--lava-400));
  box-shadow: 0 0 28px rgba(255, 184, 26, 0.42);
  font-size: 16px;
}

.brand strong,
.footer-brand strong {
  display: block;
  font-size: 22px;
  letter-spacing: 0.02em;
}

.brand small,
.footer-brand p {
  display: block;
  margin: 2px 0 0;
  color: #fdeae1;
  font-size: 12px;
}

.nav-links {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 20px;
  font-size: 15px;
  font-weight: 700;
}

.nav-links a {
  position: relative;
  color: rgba(255, 255, 255, 0.9);
  transition: color 0.2s ease;
}

.nav-links a::after {
  position: absolute;
  left: 0;
  bottom: -8px;
  width: 0;
  height: 2px;
  content: "";
  border-radius: 999px;
  background: var(--lava-400);
  transition: width 0.2s ease;
}

.nav-links a:hover,
.nav-links a.is-active {
  color: var(--lava-400);
}

.nav-links a:hover::after,
.nav-links a.is-active::after {
  width: 100%;
}

.nav-toggle {
  display: none;
  border: 0;
  color: var(--white);
  background: transparent;
  font-size: 28px;
  cursor: pointer;
}

.mobile-panel {
  display: none;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(13, 15, 18, 0.88);
  backdrop-filter: blur(20px);
}

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

.mobile-panel-inner {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  padding: 16px 0 20px;
}

.mobile-panel a {
  padding: 10px 12px;
  border-radius: 12px;
  color: var(--white);
  background: rgba(255, 255, 255, 0.08);
}

.hero-carousel {
  position: relative;
  min-height: 680px;
  overflow: hidden;
  color: var(--white);
  background: var(--ash-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-bg,
.detail-bg img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(1.1) contrast(1.05);
  transform: scale(1.03);
}

.hero-mask {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 72% 40%, rgba(255, 184, 26, 0.18), transparent 30%),
    linear-gradient(90deg, rgba(13, 15, 18, 0.94) 0%, rgba(13, 15, 18, 0.75) 46%, rgba(13, 15, 18, 0.3) 100%),
    linear-gradient(0deg, rgba(13, 15, 18, 0.94), transparent 45%);
}

.hero-content {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  align-items: center;
  min-height: 680px;
  gap: 56px;
  padding: 82px 0 92px;
}

.hero-copy {
  max-width: 760px;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--lava-400);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.hero-copy h1,
.sub-hero h1,
.detail-copy h1 {
  margin: 14px 0 18px;
  font-size: clamp(36px, 7vw, 72px);
  line-height: 1.02;
  letter-spacing: -0.04em;
}

.hero-copy p,
.sub-hero p,
.detail-copy p {
  max-width: 760px;
  margin: 0 0 24px;
  color: rgba(255, 255, 255, 0.84);
  font-size: clamp(16px, 2vw, 20px);
  line-height: 1.8;
}

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

.hero-tags span,
.tag-row span {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  color: rgba(255, 255, 255, 0.9);
  padding: 7px 12px;
  font-size: 12px;
  font-weight: 700;
  backdrop-filter: blur(12px);
}

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

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

.btn.primary {
  color: var(--white);
  background: linear-gradient(90deg, var(--volcanic-600), var(--volcanic-800));
  box-shadow: var(--shadow-volcanic);
}

.btn.ghost {
  color: var(--white);
  border: 1px solid rgba(255, 255, 255, 0.26);
  background: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(14px);
}

.btn:hover {
  transform: translateY(-2px) scale(1.02);
}

.hero-poster {
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 28px;
  box-shadow: 0 34px 80px rgba(0, 0, 0, 0.45);
  transform: rotate(2deg);
}

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

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

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

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

.content-section {
  padding: 58px 0;
}

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

.section-heading h2,
.filter-panel h2,
.info-panel h2 {
  margin: 8px 0 0;
  color: var(--ash-900);
  font-size: clamp(26px, 3vw, 38px);
  line-height: 1.1;
  letter-spacing: -0.03em;
}

.section-heading::after {
  flex: 1;
  max-width: 420px;
  height: 4px;
  content: "";
  border-radius: 999px;
  background: linear-gradient(90deg, var(--volcanic-600), transparent);
}

.section-more {
  flex: 0 0 auto;
  color: var(--volcanic-700);
  font-weight: 800;
}

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

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

.movie-card {
  min-width: 0;
}

.poster-wrap {
  position: relative;
  display: block;
  overflow: hidden;
  border-radius: 18px;
  aspect-ratio: 3 / 4;
  background: var(--ash-900);
  box-shadow: var(--shadow-card);
}

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

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

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

.play-hover {
  position: absolute;
  inset: 50% auto auto 50%;
  z-index: 2;
  display: grid;
  width: 54px;
  height: 54px;
  place-items: center;
  border-radius: 999px;
  color: var(--white);
  background: var(--volcanic-600);
  box-shadow: var(--shadow-volcanic);
  opacity: 0;
  transform: translate(-50%, -50%) scale(0.8);
  transition: opacity 0.2s ease, transform 0.2s ease;
}

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

.year-badge,
.rank-badge {
  position: absolute;
  z-index: 3;
  top: 10px;
  right: 10px;
  padding: 5px 8px;
  border-radius: 999px;
  color: var(--white);
  background: rgba(0, 0, 0, 0.68);
  font-size: 12px;
  font-weight: 800;
  backdrop-filter: blur(10px);
}

.rank-badge {
  right: auto;
  left: 10px;
  background: linear-gradient(90deg, var(--lava-600), var(--volcanic-600));
}

.movie-card-body {
  display: grid;
  gap: 6px;
  padding: 12px 2px 0;
}

.movie-card strong {
  overflow: hidden;
  color: var(--ash-900);
  font-size: 15px;
  line-height: 1.35;
  text-overflow: ellipsis;
  white-space: nowrap;
  transition: color 0.2s ease;
}

.movie-card:hover strong {
  color: var(--volcanic-700);
}

.movie-card em,
.card-desc {
  color: var(--ash-500);
  font-size: 12px;
  font-style: normal;
  line-height: 1.5;
}

.card-desc {
  display: -webkit-box;
  overflow: hidden;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.movie-card .tag-row span {
  color: var(--volcanic-800);
  background: #fff0e9;
  padding: 4px 7px;
}

.intro-strip,
.filter-panel,
.info-panel {
  border: 1px solid rgba(232, 65, 24, 0.12);
  border-radius: var(--radius-lg);
  background: rgba(255, 255, 255, 0.82);
  box-shadow: var(--shadow-card);
  backdrop-filter: blur(18px);
}

.intro-strip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 26px;
  margin-top: -42px;
  position: relative;
  z-index: 4;
  padding: 30px;
}

.intro-strip h2 {
  margin: 8px 0 10px;
  font-size: clamp(26px, 4vw, 44px);
}

.intro-strip p {
  margin: 0;
  color: var(--ash-500);
  line-height: 1.8;
}

.sub-hero {
  color: var(--white);
  background:
    radial-gradient(circle at 74% 24%, rgba(255, 184, 26, 0.22), transparent 30%),
    linear-gradient(135deg, var(--volcanic-900), var(--volcanic-700) 42%, var(--ash-900));
}

.sub-hero .container {
  padding: 86px 0 78px;
}

.sub-hero h1 {
  margin-bottom: 16px;
}

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

.category-card {
  position: relative;
  overflow: hidden;
  min-height: 260px;
  border-radius: var(--radius-lg);
  color: var(--white);
  background: var(--ash-900);
  box-shadow: var(--shadow-card);
}

.category-card img {
  width: 100%;
  height: 100%;
  min-height: 260px;
  object-fit: cover;
  transition: transform 0.45s ease;
}

.category-card:hover img {
  transform: scale(1.08);
}

.category-card-mask {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 18%, rgba(13, 15, 18, 0.9));
}

.category-card-body {
  position: absolute;
  inset: auto 0 0;
  display: grid;
  gap: 8px;
  padding: 24px;
}

.category-card-body strong {
  font-size: 24px;
}

.category-card-body em,
.category-card-body span {
  color: rgba(255, 255, 255, 0.78);
  font-style: normal;
  line-height: 1.55;
}

.filter-panel {
  display: grid;
  grid-template-columns: 1fr minmax(280px, 520px);
  gap: 24px;
  margin: 34px 0 8px;
  padding: 26px;
}

.filter-panel p {
  color: var(--ash-500);
  line-height: 1.7;
}

.filter-controls {
  display: grid;
  grid-template-columns: 1fr 150px 150px;
  gap: 12px;
  align-content: center;
}

.filter-controls input,
.filter-controls select {
  min-height: 46px;
  border: 1px solid var(--ash-200);
  border-radius: 999px;
  outline: 0;
  background: var(--white);
  padding: 0 16px;
}

.filter-controls input:focus,
.filter-controls select:focus {
  border-color: var(--volcanic-600);
  box-shadow: 0 0 0 4px rgba(232, 65, 24, 0.12);
}

.filter-result {
  grid-column: 1 / -1;
  margin: 0;
  font-weight: 800;
}

.detail-hero {
  position: relative;
  overflow: hidden;
  min-height: 560px;
  color: var(--white);
  background: var(--ash-900);
}

.detail-bg {
  position: absolute;
  inset: 0;
  filter: blur(12px);
  transform: scale(1.08);
  opacity: 0.62;
}

.detail-mask {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(13, 15, 18, 0.96), rgba(13, 15, 18, 0.68)),
    linear-gradient(0deg, rgba(13, 15, 18, 0.98), transparent 48%);
}

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

.detail-poster {
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 26px;
  box-shadow: 0 32px 74px rgba(0, 0, 0, 0.48);
}

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

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

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

.player-section {
  margin-top: -78px;
  position: relative;
  z-index: 4;
}

.player-shell {
  position: relative;
  overflow: hidden;
  border-radius: 28px;
  background: #000;
  box-shadow: 0 36px 90px rgba(13, 15, 18, 0.38);
}

.movie-player {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #000;
}

.player-start {
  position: absolute;
  inset: 50% auto auto 50%;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  border: 0;
  border-radius: 999px;
  color: var(--white);
  background: linear-gradient(90deg, var(--volcanic-600), var(--volcanic-800));
  box-shadow: var(--shadow-volcanic);
  padding: 14px 24px;
  font-weight: 900;
  cursor: pointer;
  transform: translate(-50%, -50%);
}

.player-start span {
  display: grid;
  width: 30px;
  height: 30px;
  place-items: center;
  border-radius: 999px;
  color: var(--volcanic-700);
  background: var(--white);
}

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

.player-status {
  position: absolute;
  left: 18px;
  bottom: 14px;
  max-width: calc(100% - 36px);
  margin: 0;
  border-radius: 999px;
  color: rgba(255, 255, 255, 0.86);
  background: rgba(0, 0, 0, 0.58);
  padding: 8px 14px;
  font-size: 13px;
  backdrop-filter: blur(10px);
}

.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 26px;
}

.info-panel {
  padding: 30px;
}

.info-panel p {
  color: var(--ash-700);
  font-size: 16px;
  line-height: 1.9;
}

.meta-list {
  display: grid;
  grid-template-columns: 76px minmax(0, 1fr);
  gap: 13px 16px;
  margin: 18px 0 0;
}

.meta-list dt {
  color: var(--ash-500);
  font-weight: 800;
}

.meta-list dd {
  min-width: 0;
  margin: 0;
  color: var(--ash-900);
  line-height: 1.6;
}

.meta-list a {
  color: var(--volcanic-700);
  font-weight: 800;
}

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

.site-footer {
  margin-top: 42px;
  color: #d9d8d5;
  background: var(--ash-900);
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1.3fr;
  gap: 32px;
  padding: 52px 0;
}

.footer-grid h3 {
  margin: 0 0 16px;
  color: var(--white);
}

.footer-grid ul {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.footer-grid a {
  color: #b8b6b0;
}

.footer-grid a:hover {
  color: var(--lava-400);
}

.footer-text {
  color: #b8b6b0;
  font-size: 14px;
  line-height: 1.8;
}

.copyright {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  color: #8a8780;
  padding: 22px 16px;
  text-align: center;
}

.is-filtered-out {
  display: none !important;
}

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

  .nav-toggle {
    display: inline-flex;
  }

  .hero-content {
    grid-template-columns: 1fr 240px;
  }

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

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

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

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

  .top-nav {
    min-height: 66px;
  }

  .brand strong {
    font-size: 18px;
  }

  .brand small {
    display: none;
  }

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

  .hero-content {
    display: flex;
    align-items: flex-end;
    padding: 96px 0 86px;
  }

  .hero-poster {
    display: none;
  }

  .hero-copy h1,
  .sub-hero h1,
  .detail-copy h1 {
    font-size: 38px;
  }

  .intro-strip,
  .section-heading,
  .filter-panel,
  .detail-hero-inner,
  .detail-layout {
    display: block;
  }

  .intro-strip .btn {
    margin-top: 18px;
  }

  .section-heading::after {
    display: none;
  }

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

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

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

  .filter-panel {
    padding: 20px;
  }

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

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

  .info-panel {
    padding: 22px;
  }
}
