:root {
  --red: #ef4444;
  --red-dark: #dc2626;
  --amber: #f59e0b;
  --stone-50: #fafaf9;
  --stone-100: #f5f5f4;
  --stone-200: #e7e5e4;
  --stone-500: #78716c;
  --stone-600: #57534e;
  --stone-700: #44403c;
  --stone-800: #292524;
  --stone-900: #1c1917;
  --shadow: 0 18px 45px rgba(28, 25, 23, 0.12);
  --soft-shadow: 0 12px 28px rgba(28, 25, 23, 0.08);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--stone-50);
  color: var(--stone-800);
  line-height: 1.6;
}

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

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

img.image-hidden {
  opacity: 0;
}

button,
input,
select {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 60;
  background: rgba(255, 255, 255, 0.96);
  border-bottom: 1px solid var(--stone-200);
  box-shadow: 0 8px 24px rgba(28, 25, 23, 0.06);
  backdrop-filter: blur(18px);
}

.header-inner {
  max-width: 1280px;
  height: 66px;
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  align-items: center;
  gap: 24px;
}

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

.brand-mark {
  width: 38px;
  height: 38px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  color: #fff;
  background: linear-gradient(135deg, var(--red), #fb923c);
  box-shadow: 0 12px 26px rgba(239, 68, 68, 0.26);
}

.brand-text strong {
  display: block;
  font-size: 20px;
  line-height: 1.1;
}

.brand-text small {
  display: block;
  color: var(--stone-500);
  font-size: 12px;
  margin-top: 2px;
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-left: auto;
}

.nav-link,
.mobile-link {
  color: var(--stone-600);
  font-weight: 700;
  border-radius: 999px;
  transition: 0.2s ease;
}

.nav-link {
  padding: 8px 13px;
  font-size: 14px;
}

.nav-link:hover,
.nav-link.is-active,
.mobile-link:hover,
.mobile-link.is-active {
  color: var(--red);
  background: #fef2f2;
}

.header-search,
.mobile-search {
  display: flex;
  align-items: center;
  border: 1px solid var(--stone-200);
  background: var(--stone-50);
  border-radius: 12px;
  overflow: hidden;
}

.header-search input,
.mobile-search input,
.filter-bar input {
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--stone-800);
}

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

.header-search button,
.mobile-search button,
.filter-bar button,
.filter-chip,
.btn,
.text-link,
.play-trigger {
  border: 0;
  cursor: pointer;
  transition: 0.2s ease;
}

.header-search button,
.mobile-search button {
  padding: 10px 14px;
  color: #fff;
  background: var(--red);
}

.header-search button:hover,
.mobile-search button:hover,
.btn:hover,
.text-link:hover {
  background: var(--red-dark);
  color: #fff;
}

.menu-button {
  display: none;
  margin-left: auto;
  color: var(--stone-700);
  background: var(--stone-100);
  border: 1px solid var(--stone-200);
  border-radius: 10px;
  padding: 8px 12px;
}

.mobile-panel {
  display: none;
  padding: 12px 20px 18px;
  border-top: 1px solid var(--stone-200);
}

.mobile-panel.is-open {
  display: grid;
  gap: 10px;
}

.mobile-link {
  padding: 10px 12px;
}

.mobile-search input {
  width: 100%;
  padding: 11px 12px;
}

.quick-categories {
  border-top: 1px solid rgba(231, 229, 228, 0.8);
  background: rgba(250, 250, 249, 0.9);
}

.quick-categories-inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 8px 20px;
  display: flex;
  gap: 18px;
  overflow-x: auto;
  white-space: nowrap;
}

.quick-categories a {
  color: var(--stone-500);
  font-size: 13px;
  font-weight: 700;
}

.quick-categories a:hover {
  color: var(--red);
}

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

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

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

.hero-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  background: radial-gradient(circle at 20% 20%, rgba(239, 68, 68, 0.32), transparent 32%), linear-gradient(135deg, #1c1917, #3f1111);
}

.hero-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(0, 0, 0, 0.86), rgba(0, 0, 0, 0.54) 46%, rgba(0, 0, 0, 0.16)), linear-gradient(0deg, rgba(0, 0, 0, 0.86), transparent 54%);
}

.hero-content {
  position: absolute;
  left: 50%;
  bottom: 72px;
  width: min(1180px, calc(100% - 40px));
  transform: translateX(-50%);
  color: #fff;
}

.hero-content-inner {
  max-width: 760px;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 16px;
  color: #fff;
  background: var(--red);
  border-radius: 999px;
  padding: 6px 12px;
  font-size: 14px;
  font-weight: 800;
}

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

.hero p {
  margin: 0 0 20px;
  max-width: 680px;
  color: #e7e5e4;
  font-size: clamp(17px, 2vw, 22px);
}

.hero-meta,
.detail-meta,
.card-meta,
.rank-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  color: var(--stone-500);
}

.hero-meta {
  color: #f5f5f4;
  margin-bottom: 28px;
}

.hero-meta span,
.detail-meta span,
.rank-meta span,
.card-meta span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.hero-actions,
.section-actions,
.detail-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 11px 18px;
  border-radius: 12px;
  color: #fff;
  background: var(--red);
  font-weight: 800;
  box-shadow: 0 16px 28px rgba(239, 68, 68, 0.22);
}

.btn.is-ghost {
  color: #fff;
  background: rgba(255, 255, 255, 0.14);
  box-shadow: none;
  border: 1px solid rgba(255, 255, 255, 0.28);
}

.btn.is-light {
  color: var(--red);
  background: #fff;
  box-shadow: var(--soft-shadow);
}

.hero-control {
  position: absolute;
  top: 50%;
  width: 46px;
  height: 46px;
  transform: translateY(-50%);
  display: grid;
  place-items: center;
  color: #fff;
  background: rgba(0, 0, 0, 0.42);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 999px;
  z-index: 3;
}

.hero-control:hover {
  background: rgba(0, 0, 0, 0.72);
}

.hero-control.prev {
  left: 24px;
}

.hero-control.next {
  right: 24px;
}

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

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

.hero-dot.is-active {
  width: 32px;
  background: var(--amber);
}

.container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 48px 20px;
}

.page-hero {
  background: radial-gradient(circle at 18% 8%, rgba(239, 68, 68, 0.22), transparent 32%), linear-gradient(135deg, #211b19, #4a1010);
  color: #fff;
}

.page-hero .container {
  padding-top: 58px;
  padding-bottom: 58px;
}

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

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

.page-title {
  margin: 0;
  font-size: clamp(32px, 5vw, 56px);
  line-height: 1.08;
  letter-spacing: -0.03em;
}

.page-intro {
  max-width: 780px;
  margin: 16px 0 0;
  color: rgba(255, 255, 255, 0.82);
  font-size: 18px;
}

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

.section-title {
  margin: 0;
  font-size: clamp(24px, 3vw, 34px);
  line-height: 1.15;
}

.section-kicker {
  margin: 0 0 8px;
  color: var(--red);
  font-weight: 900;
}

.section-desc {
  margin: 10px 0 0;
  color: var(--stone-500);
}

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

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

.movie-card {
  overflow: hidden;
  background: #fff;
  border: 1px solid rgba(231, 229, 228, 0.82);
  border-radius: 18px;
  box-shadow: var(--soft-shadow);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

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

.poster-wrap {
  position: relative;
  display: block;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: radial-gradient(circle at 35% 10%, rgba(239, 68, 68, 0.3), transparent 36%), linear-gradient(135deg, #1c1917, #4a1212);
}

.movie-card.is-compact .poster-wrap {
  aspect-ratio: 3 / 4;
}

.poster-wrap img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.45s ease, opacity 0.25s ease;
}

.movie-card:hover .poster-wrap img,
.category-card:hover img,
.rank-thumb:hover img {
  transform: scale(1.06);
}

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

.badge,
.year-badge {
  position: absolute;
  top: 12px;
  z-index: 2;
  color: #fff;
  border-radius: 999px;
  padding: 5px 9px;
  font-size: 12px;
  font-weight: 900;
}

.badge {
  left: 12px;
  background: var(--red);
}

.year-badge {
  right: 12px;
  background: rgba(0, 0, 0, 0.65);
}

.play-mark {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 2;
  width: 58px;
  height: 58px;
  display: grid;
  place-items: center;
  transform: translate(-50%, -50%) scale(0.92);
  opacity: 0;
  color: var(--red);
  background: rgba(255, 255, 255, 0.94);
  border-radius: 999px;
  box-shadow: 0 18px 34px rgba(0, 0, 0, 0.2);
  transition: 0.25s ease;
}

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

.card-body {
  padding: 16px;
}

.card-body h2,
.rank-info h2 {
  margin: 0 0 8px;
  font-size: 18px;
  line-height: 1.28;
}

.card-body h2 a:hover,
.rank-info h2 a:hover,
.detail-content a:hover {
  color: var(--red);
}

.card-body p,
.rank-info p {
  margin: 0 0 12px;
  color: var(--stone-600);
  font-size: 14px;
}

.card-meta {
  gap: 8px;
  margin-bottom: 12px;
  font-size: 13px;
}

.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.tag-list span {
  color: var(--stone-600);
  background: var(--stone-100);
  border: 1px solid rgba(231, 229, 228, 0.9);
  border-radius: 999px;
  padding: 4px 8px;
  font-size: 12px;
  font-weight: 700;
}

.horizontal-row {
  display: flex;
  gap: 18px;
  overflow-x: auto;
  padding-bottom: 8px;
}

.horizontal-row .movie-card {
  width: 310px;
  flex: 0 0 auto;
}

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

.category-card {
  overflow: hidden;
  background: #fff;
  border: 1px solid var(--stone-200);
  border-radius: 20px;
  box-shadow: var(--soft-shadow);
  transition: 0.25s ease;
}

.category-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow);
}

.category-covers {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  height: 120px;
  background: linear-gradient(135deg, var(--stone-900), #5f1414);
}

.category-covers img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  background: linear-gradient(135deg, #292524, #7f1d1d);
}

.category-card-body {
  padding: 20px;
}

.category-card-body h2 {
  margin: 0 0 8px;
  font-size: 22px;
}

.category-card-body p {
  min-height: 76px;
  margin: 0 0 14px;
  color: var(--stone-600);
}

.category-card-body span,
.text-link {
  display: inline-flex;
  color: var(--red);
  font-weight: 900;
}

.filter-bar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  padding: 16px;
  margin-bottom: 28px;
  background: #fff;
  border: 1px solid var(--stone-200);
  border-radius: 18px;
  box-shadow: var(--soft-shadow);
}

.filter-bar input {
  width: 100%;
  min-height: 46px;
  padding: 0 14px;
  background: var(--stone-50);
  border-radius: 12px;
  border: 1px solid var(--stone-200);
}

.filter-chips {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

.filter-chip {
  min-height: 38px;
  padding: 7px 12px;
  color: var(--stone-600);
  background: var(--stone-100);
  border-radius: 999px;
  font-weight: 800;
}

.filter-chip.is-active,
.filter-chip:hover {
  color: #fff;
  background: var(--red);
}

.empty-state {
  display: none;
  padding: 30px;
  text-align: center;
  color: var(--stone-600);
  background: #fff;
  border: 1px dashed var(--stone-200);
  border-radius: 18px;
}

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

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

.rank-item {
  display: grid;
  grid-template-columns: auto 120px minmax(0, 1fr) auto;
  align-items: center;
  gap: 18px;
  padding: 14px;
  background: #fff;
  border: 1px solid var(--stone-200);
  border-radius: 18px;
  box-shadow: var(--soft-shadow);
}

.rank-number {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  color: #fff;
  background: linear-gradient(135deg, var(--red), var(--amber));
  border-radius: 14px;
  font-weight: 900;
}

.rank-thumb {
  position: relative;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--stone-900), #7f1d1d);
}

.rank-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.35s ease, opacity 0.2s ease;
}

.rank-meta {
  font-size: 13px;
}

.player-section {
  background: #000;
}

.player-inner {
  max-width: 1280px;
  margin: 0 auto;
}

.player-shell {
  position: relative;
  aspect-ratio: 16 / 9;
  background: #000;
}

.player-shell video {
  width: 100%;
  height: 100%;
  display: block;
  background: #000;
}

.play-trigger {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 4;
  width: 76px;
  height: 76px;
  transform: translate(-50%, -50%);
  color: #fff;
  background: rgba(239, 68, 68, 0.94);
  border-radius: 999px;
  font-size: 28px;
  box-shadow: 0 22px 44px rgba(0, 0, 0, 0.28);
}

.play-trigger:hover,
.play-trigger.is-hidden {
  opacity: 0;
  visibility: hidden;
}

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

.detail-card,
.side-card {
  background: #fff;
  border: 1px solid var(--stone-200);
  border-radius: 20px;
  box-shadow: var(--soft-shadow);
}

.detail-card {
  padding: 28px;
}

.detail-card h1 {
  margin: 0 0 18px;
  font-size: clamp(30px, 4vw, 48px);
  line-height: 1.1;
}

.detail-meta {
  padding-bottom: 18px;
  margin-bottom: 22px;
  border-bottom: 1px solid var(--stone-200);
}

.detail-content h2,
.side-card h2 {
  margin: 0 0 14px;
  font-size: 22px;
}

.detail-content p {
  margin: 0 0 22px;
  color: var(--stone-600);
  font-size: 17px;
}

.side-card {
  padding: 20px;
  margin-bottom: 18px;
}

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

.side-link {
  display: grid;
  grid-template-columns: 78px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
}

.side-link img {
  width: 78px;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--stone-900), #7f1d1d);
}

.side-link strong {
  display: block;
  line-height: 1.3;
}

.side-link span {
  color: var(--stone-500);
  font-size: 13px;
}

.related-grid {
  margin-top: 28px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.site-footer {
  margin-top: 54px;
  color: #d6d3d1;
  background: var(--stone-900);
}

.footer-inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 42px 20px;
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 30px;
}

.footer-brand {
  color: #fff;
  font-size: 22px;
  margin-bottom: 12px;
}

.footer-inner p {
  max-width: 520px;
  color: #a8a29e;
}

.footer-inner h2 {
  margin: 0 0 14px;
  color: #fff;
  font-size: 18px;
}

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

.footer-links a {
  color: #a8a29e;
}

.footer-links a:hover {
  color: #fff;
}

.copyright {
  max-width: 1280px;
  margin: 0 auto;
  padding: 16px 20px 28px;
  color: #78716c;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

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

  .menu-button {
    display: inline-flex;
  }

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

  .detail-layout {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  .header-inner {
    height: 60px;
    padding: 0 14px;
  }

  .brand-text small,
  .quick-categories {
    display: none;
  }

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

  .hero {
    height: 74vh;
    min-height: 520px;
  }

  .hero-content {
    bottom: 70px;
  }

  .hero-control {
    display: none;
  }

  .container {
    padding: 36px 16px;
  }

  .section-head {
    display: block;
  }

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

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

  .rank-item {
    grid-template-columns: auto 88px minmax(0, 1fr);
  }

  .rank-item .text-link {
    grid-column: 2 / 4;
  }

  .rank-thumb {
    width: 88px;
  }

  .footer-inner {
    grid-template-columns: 1fr;
  }

  .detail-card {
    padding: 20px;
  }
}

@media (max-width: 480px) {
  .hero h1,
  .hero h2 {
    font-size: 36px;
  }

  .movie-grid,
  .movie-grid.is-large,
  .category-grid,
  .related-grid {
    grid-template-columns: 1fr;
  }

  .horizontal-row .movie-card {
    width: 270px;
  }

  .category-covers {
    height: 104px;
  }
}
