:root {
  --bg: #f8fafc;
  --surface: #ffffff;
  --surface-soft: #f1f5f9;
  --ink: #0f172a;
  --muted: #64748b;
  --line: #e2e8f0;
  --red: #dc2626;
  --red-dark: #b91c1c;
  --orange: #f97316;
  --slate: #111827;
  --slate-soft: #1f2937;
  --radius: 18px;
  --shadow: 0 20px 60px rgba(15, 23, 42, 0.12);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

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

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

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

button,
input,
select {
  font: inherit;
}

[hidden] {
  display: none !important;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  color: #ffffff;
  background: linear-gradient(90deg, #0f172a, #1e293b 55%, #0f172a);
  box-shadow: 0 10px 30px rgba(15, 23, 42, 0.25);
}

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

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

.brand-icon {
  width: 36px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  background: var(--red);
  color: #ffffff;
  box-shadow: 0 12px 24px rgba(220, 38, 38, 0.3);
}

.brand-text {
  font-size: 1.18rem;
  background: linear-gradient(90deg, #f87171, #fb923c);
  -webkit-background-clip: text;
  color: transparent;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 6px;
}

.nav-link {
  padding: 9px 14px;
  border-radius: 12px;
  color: #cbd5e1;
  transition: 0.2s ease;
}

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

.nav-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.08);
  cursor: pointer;
}

.nav-toggle span {
  width: 20px;
  height: 2px;
  margin: 4px auto;
  display: block;
  background: #ffffff;
  border-radius: 99px;
}

.hero {
  position: relative;
  min-height: 650px;
  overflow: hidden;
  color: #ffffff;
  background: radial-gradient(circle at 20% 20%, rgba(220, 38, 38, 0.35), transparent 32%), linear-gradient(135deg, #0f172a, #7f1d1d 52%, #0f172a);
}

.hero-pattern {
  position: absolute;
  inset: 0;
  opacity: 0.08;
  background-image: radial-gradient(circle, #ffffff 1px, transparent 1px);
  background-size: 34px 34px;
}

.hero-stage {
  position: relative;
  width: min(1180px, calc(100% - 32px));
  min-height: 650px;
  margin: 0 auto;
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(280px, 420px);
  align-items: center;
  gap: 56px;
  padding: 72px 0 92px;
  opacity: 0;
  transform: translateY(18px);
  pointer-events: none;
  transition: opacity 0.5s ease, transform 0.5s ease;
}

.hero-slide::before {
  content: "";
  position: absolute;
  inset: 46px -24px;
  z-index: -1;
  border-radius: 36px;
  background-image: linear-gradient(90deg, rgba(15, 23, 42, 0.92), rgba(127, 29, 29, 0.75)), var(--hero-bg);
  background-size: cover;
  background-position: center;
  filter: saturate(1.2);
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.28);
}

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

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

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 16px;
  color: #fecaca;
  font-size: 0.86rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.hero h1 {
  margin: 0 0 20px;
  font-size: clamp(2.4rem, 7vw, 5.5rem);
  line-height: 1.04;
  font-weight: 900;
}

.hero p {
  max-width: 680px;
  margin: 0 0 24px;
  color: #e5e7eb;
  font-size: 1.08rem;
}

.hero-tags,
.tag-list,
.detail-pills,
.category-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.hero-tags span,
.tag-list span,
.detail-pills span,
.category-links a {
  display: inline-flex;
  align-items: center;
  padding: 7px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.14);
}

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

.btn-primary,
.btn-ghost,
.hero-mini-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 22px;
  border-radius: 13px;
  font-weight: 800;
  transition: 0.22s ease;
}

.btn-primary {
  color: #ffffff;
  background: var(--red);
  box-shadow: 0 16px 30px rgba(220, 38, 38, 0.28);
}

.btn-primary:hover {
  background: var(--red-dark);
  transform: translateY(-2px);
}

.btn-ghost {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.22);
  backdrop-filter: blur(16px);
}

.btn-ghost:hover {
  background: rgba(255, 255, 255, 0.18);
}

.hero-poster {
  position: relative;
  display: block;
  width: min(100%, 380px);
  justify-self: end;
  border-radius: 28px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.1);
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.45);
  transform: rotate(2deg);
}

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

.hero-controls {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 34px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 18px;
}

.hero-controls button {
  border: 0;
  cursor: pointer;
}

.hero-controls > button {
  width: 42px;
  height: 42px;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.16);
  font-size: 1.7rem;
}

.hero-dots {
  display: flex;
  gap: 8px;
}

.hero-dot {
  width: 10px;
  height: 10px;
  padding: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.35);
}

.hero-dot.is-active {
  width: 28px;
  background: #ffffff;
}

.feature-strip {
  width: min(1180px, calc(100% - 32px));
  margin: -34px auto 0;
  position: relative;
  z-index: 3;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}

.feature-item {
  padding: 22px;
  border-radius: 18px;
  background: #ffffff;
  box-shadow: var(--shadow);
}

.feature-item strong {
  display: block;
  font-size: 1.1rem;
  margin-bottom: 4px;
}

.feature-item span {
  color: var(--muted);
  font-size: 0.94rem;
}

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

.tinted-section {
  padding-left: 28px;
  padding-right: 28px;
  border-radius: 28px;
  background: #fff7ed;
}

.category-band {
  width: 100%;
  padding-left: max(16px, calc((100% - 1180px) / 2));
  padding-right: max(16px, calc((100% - 1180px) / 2));
  color: #ffffff;
  background: linear-gradient(135deg, #dc2626, #f97316);
}

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

.section-heading h2 {
  margin: 0 0 6px;
  font-size: clamp(1.7rem, 3vw, 2.35rem);
  line-height: 1.15;
}

.section-heading p {
  margin: 0;
  color: var(--muted);
}

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

.light-heading p,
.light-heading > a {
  color: #fee2e2;
}

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

.movie-card {
  position: relative;
  display: block;
  overflow: hidden;
  border-radius: 17px;
  background: #ffffff;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.06);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 22px 44px rgba(15, 23, 42, 0.15);
}

.poster-frame {
  position: relative;
  overflow: hidden;
  background: #e2e8f0;
}

.poster-frame img {
  width: 100%;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  transition: transform 0.35s ease;
}

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

.rating-badge,
.rank-badge {
  position: absolute;
  z-index: 2;
  padding: 5px 8px;
  border-radius: 999px;
  color: #ffffff;
  font-size: 0.78rem;
  font-weight: 800;
}

.rating-badge {
  top: 10px;
  right: 10px;
  background: var(--red);
}

.rank-badge {
  top: 10px;
  left: 10px;
  background: #0f172a;
}

.play-hover {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: #ffffff;
  font-size: 2.7rem;
  background: rgba(0, 0, 0, 0.38);
  opacity: 0;
  transition: opacity 0.25s ease;
}

.movie-card:hover .play-hover {
  opacity: 1;
}

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

.movie-card h3 {
  margin: 0 0 6px;
  overflow: hidden;
  color: var(--ink);
  font-size: 0.98rem;
  font-weight: 800;
  line-height: 1.35;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.movie-meta,
.movie-genre {
  margin: 0;
  overflow: hidden;
  color: var(--muted);
  font-size: 0.83rem;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.movie-genre {
  color: #dc2626;
}

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

.category-tile,
.category-card {
  display: block;
  padding: 24px;
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.16);
  transition: 0.22s ease;
}

.category-tile:hover,
.category-card:hover {
  transform: translateY(-5px);
  background: rgba(255, 255, 255, 0.18);
}

.category-tile span,
.category-card h2 {
  display: block;
  margin: 0 0 8px;
  font-size: 1.15rem;
  font-weight: 900;
}

.category-tile p,
.category-card p {
  margin: 0;
  color: rgba(255, 255, 255, 0.78);
  font-size: 0.94rem;
}

.category-overview-grid .category-card {
  overflow: hidden;
  padding: 0;
  color: var(--ink);
  background: #ffffff;
  border: 1px solid var(--line);
  box-shadow: 0 10px 32px rgba(15, 23, 42, 0.08);
}

.category-card div:last-child {
  padding: 20px;
}

.category-card p {
  color: var(--muted);
}

.category-cover {
  min-height: 140px;
  background-image: linear-gradient(135deg, rgba(15, 23, 42, 0.24), rgba(220, 38, 38, 0.42)), var(--category-bg);
  background-position: center;
  background-size: cover;
}

.page-hero {
  width: 100%;
  padding: 82px max(16px, calc((100% - 1180px) / 2));
  color: #ffffff;
  background: linear-gradient(115deg, #0f172a, #7f1d1d 58%, #0f172a);
}

.page-hero h1 {
  margin: 0 0 14px;
  font-size: clamp(2rem, 5vw, 4rem);
  line-height: 1.08;
}

.page-hero p {
  max-width: 720px;
  margin: 0;
  color: #e5e7eb;
  font-size: 1.08rem;
}

.category-hero,
.ranking-hero,
.search-hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.hero-mini-link {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.filter-bar {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 0.8fr auto;
  gap: 12px;
  margin-bottom: 26px;
  padding: 16px;
  border-radius: 18px;
  background: #ffffff;
  box-shadow: 0 10px 32px rgba(15, 23, 42, 0.08);
}

.filter-bar input,
.filter-bar select,
.filter-bar button {
  min-height: 46px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #ffffff;
  color: var(--ink);
}

.filter-bar button {
  cursor: pointer;
  color: #ffffff;
  background: var(--red);
  border-color: var(--red);
  font-weight: 800;
}

.detail-hero {
  padding: 46px max(16px, calc((100% - 1180px) / 2));
  color: #ffffff;
  background: radial-gradient(circle at 70% 20%, rgba(249, 115, 22, 0.22), transparent 35%), linear-gradient(135deg, #020617, #7f1d1d 62%, #111827);
}

.detail-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(300px, 0.75fr);
  gap: 28px;
  align-items: stretch;
}

.watch-panel,
.detail-side,
.article-card {
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.14);
  box-shadow: var(--shadow);
}

.player-shell {
  position: relative;
  overflow: hidden;
  border-radius: 24px;
  background: #000000;
}

.video-player {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #000000;
  cursor: pointer;
}

.player-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  border: 0;
  color: #ffffff;
  background: radial-gradient(circle, rgba(15, 23, 42, 0.2), rgba(0, 0, 0, 0.5));
  cursor: pointer;
}

.player-overlay span {
  width: 84px;
  height: 84px;
  display: grid;
  place-items: center;
  padding-left: 5px;
  border-radius: 999px;
  background: var(--red);
  box-shadow: 0 24px 50px rgba(220, 38, 38, 0.35);
  font-size: 2.2rem;
}

.player-overlay.is-hidden {
  opacity: 0;
  pointer-events: none;
}

.detail-side {
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: 18px;
  padding: 22px;
  align-items: start;
}

.detail-side img {
  width: 120px;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  border-radius: 16px;
}

.detail-side h1 {
  margin: 0 0 10px;
  font-size: clamp(1.8rem, 4vw, 3rem);
  line-height: 1.1;
}

.detail-side p {
  margin: 0 0 18px;
  color: #e5e7eb;
}

.detail-pills span {
  background: rgba(255, 255, 255, 0.12);
}

.detail-play {
  margin-top: 20px;
}

.detail-content {
  padding-top: 46px;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin-bottom: 18px;
  color: var(--muted);
  font-size: 0.94rem;
}

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

.article-card {
  padding: 30px;
  color: var(--ink);
  background: #ffffff;
  border-color: var(--line);
}

.article-card h2 {
  margin: 0 0 12px;
  font-size: 1.5rem;
}

.article-card p {
  margin: 0 0 20px;
  color: #334155;
}

.article-card .tag-list span,
.article-card .category-links a {
  color: #991b1b;
  background: #fee2e2;
  border-color: #fecaca;
}

.category-links {
  margin-top: 18px;
}

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

.small-card .movie-card-body {
  padding: 10px;
}

.site-footer {
  margin-top: 30px;
  color: #cbd5e1;
  background: linear-gradient(180deg, #0f172a, #020617);
}

.footer-grid {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 46px 0 34px;
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1.2fr;
  gap: 28px;
}

.footer-grid h3 {
  margin: 0 0 14px;
  color: #ffffff;
}

.footer-grid p,
.footer-grid a {
  display: block;
  margin: 0 0 8px;
  color: #94a3b8;
  font-size: 0.94rem;
}

.footer-grid a:hover {
  color: #f87171;
}

.footer-bottom {
  padding: 20px 16px;
  color: #94a3b8;
  text-align: center;
  border-top: 1px solid rgba(148, 163, 184, 0.16);
}

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

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

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

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

  .nav-links {
    position: absolute;
    left: 16px;
    right: 16px;
    top: 70px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    padding: 14px;
    border-radius: 18px;
    background: #0f172a;
    box-shadow: var(--shadow);
  }

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

  .nav-link {
    padding: 12px 14px;
  }

  .hero,
  .hero-stage {
    min-height: 760px;
  }

  .hero-slide {
    grid-template-columns: 1fr;
    gap: 26px;
    padding: 46px 0 112px;
  }

  .hero-slide::before {
    inset: 28px -10px;
  }

  .hero-poster {
    width: min(250px, 72vw);
    justify-self: start;
  }

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

  .category-hero,
  .ranking-hero,
  .search-hero,
  .section-heading {
    align-items: flex-start;
    flex-direction: column;
  }

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

@media (max-width: 620px) {
  .movie-grid,
  .related-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
  }

  .category-grid,
  .category-overview-grid,
  .feature-strip {
    grid-template-columns: 1fr;
  }

  .content-section,
  .category-band {
    padding-top: 48px;
    padding-bottom: 48px;
  }

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

  .detail-side img {
    width: 148px;
  }

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