* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: #1e293b;
  background: #f8fafc;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  line-height: 1.6;
}

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

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

button,
input,
select {
  font: inherit;
}

.container {
  width: min(1200px, calc(100% - 32px));
  margin: 0 auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(15, 23, 42, 0.92);
  backdrop-filter: blur(18px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.site-header__inner {
  width: min(1200px, calc(100% - 32px));
  min-height: 72px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 22px;
}

.site-logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: #ffffff;
  font-size: 21px;
  font-weight: 800;
  white-space: nowrap;
}

.site-logo__mark {
  width: 34px;
  height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  background: #f59e0b;
  border-radius: 999px;
  box-shadow: 0 12px 28px rgba(245, 158, 11, 0.35);
  font-size: 14px;
}

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

.nav-link {
  color: rgba(255, 255, 255, 0.76);
  padding: 9px 13px;
  border-radius: 999px;
  transition: background 0.2s ease, color 0.2s ease;
}

.nav-link:hover,
.nav-link.is-active {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.12);
}

.header-search {
  display: flex;
  width: min(300px, 28vw);
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 999px;
  overflow: hidden;
}

.header-search input {
  min-width: 0;
  flex: 1;
  border: 0;
  color: #ffffff;
  background: transparent;
  padding: 10px 14px;
  outline: none;
}

.header-search input::placeholder {
  color: rgba(255, 255, 255, 0.58);
}

.header-search button {
  border: 0;
  color: #111827;
  background: #fbbf24;
  padding: 0 16px;
  cursor: pointer;
  font-weight: 700;
}

.menu-button {
  display: none;
  border: 0;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 10px;
  padding: 8px 10px;
  cursor: pointer;
}

.mobile-panel {
  display: none;
  width: min(1200px, calc(100% - 32px));
  margin: 0 auto 12px;
  padding: 10px;
  border-radius: 16px;
  background: rgba(15, 23, 42, 0.96);
}

.mobile-panel a {
  display: block;
  color: #ffffff;
  padding: 12px 14px;
  border-radius: 12px;
}

.mobile-panel a:hover {
  background: rgba(255, 255, 255, 0.12);
}

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

.hero {
  position: relative;
  min-height: 78vh;
  overflow: hidden;
  background: #020617;
}

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

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

.hero-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.03);
}

.hero-slide__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(2, 6, 23, 0.94) 0%, rgba(2, 6, 23, 0.68) 46%, rgba(2, 6, 23, 0.22) 100%), linear-gradient(0deg, #020617 0%, rgba(2, 6, 23, 0) 44%);
}

.hero-slide__content {
  position: relative;
  z-index: 2;
  min-height: 78vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  padding-top: 56px;
  padding-bottom: 110px;
  color: #ffffff;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  margin-bottom: 16px;
  padding: 7px 14px;
  color: #ffffff;
  background: #f59e0b;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.hero h1,
.hero h2 {
  max-width: 780px;
  margin: 0 0 18px;
  color: #ffffff;
  font-size: clamp(34px, 6vw, 70px);
  line-height: 1.05;
  font-weight: 900;
  letter-spacing: -0.04em;
}

.hero__movie-title {
  margin: -4px 0 16px;
  color: #fde68a;
  font-size: clamp(22px, 3vw, 34px);
  font-weight: 800;
}

.hero p {
  max-width: 670px;
  margin: 0 0 30px;
  color: rgba(255, 255, 255, 0.9);
  font-size: clamp(17px, 2vw, 21px);
}

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

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

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

.btn-primary {
  color: #111827;
  background: #fbbf24;
  box-shadow: 0 16px 40px rgba(251, 191, 36, 0.28);
}

.btn-primary:hover {
  background: #f59e0b;
}

.btn-ghost {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.18);
}

.hero-nav {
  position: absolute;
  top: 50%;
  z-index: 4;
  width: 48px;
  height: 48px;
  border: 0;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.18);
  backdrop-filter: blur(12px);
  cursor: pointer;
  font-size: 38px;
  line-height: 1;
}

.hero-nav:hover {
  background: rgba(255, 255, 255, 0.3);
}

.hero-nav--prev {
  left: 18px;
}

.hero-nav--next {
  right: 18px;
}

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

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

.hero-dots button.is-active {
  width: 32px;
  background: #ffffff;
}

.hero-search {
  position: absolute;
  left: 50%;
  bottom: 28px;
  z-index: 5;
  width: min(760px, calc(100% - 32px));
  display: flex;
  gap: 0;
  padding: 8px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(18px);
  transform: translateX(-50%);
}

.hero-search input {
  flex: 1;
  min-width: 0;
  border: 0;
  outline: none;
  color: #ffffff;
  background: transparent;
  padding: 0 18px;
}

.hero-search input::placeholder {
  color: rgba(255, 255, 255, 0.7);
}

.hero-search button {
  border: 0;
  border-radius: 999px;
  color: #111827;
  background: #fbbf24;
  padding: 13px 25px;
  font-weight: 800;
  cursor: pointer;
}

.quick-cats {
  background: #020617;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.quick-cats__inner {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  padding: 22px 0;
}

.quick-cats a {
  color: #e2e8f0;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 999px;
  padding: 10px 16px;
  transition: background 0.2s ease, color 0.2s ease;
}

.quick-cats a:hover {
  color: #111827;
  background: #fbbf24;
}

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

.content-section--soft {
  background: linear-gradient(135deg, #f1f5f9, #ffffff);
}

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

.section-heading h2 {
  margin: 0 0 8px;
  color: #0f172a;
  font-size: clamp(26px, 3vw, 38px);
  line-height: 1.15;
}

.section-heading p {
  margin: 0;
  max-width: 680px;
  color: #64748b;
}

.section-more {
  flex: 0 0 auto;
  color: #92400e;
  background: #fef3c7;
  border-radius: 999px;
  padding: 10px 16px;
  font-weight: 800;
}

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

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

.movie-card {
  overflow: hidden;
  background: #ffffff;
  border-radius: 20px;
  box-shadow: 0 14px 36px rgba(15, 23, 42, 0.08);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.movie-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 22px 48px rgba(15, 23, 42, 0.14);
}

.movie-card__cover {
  position: relative;
  display: block;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  background: #0f172a;
}

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

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

.movie-card__shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.12), rgba(0, 0, 0, 0.72));
  opacity: 0.7;
}

.movie-card__category {
  position: absolute;
  left: 12px;
  bottom: 12px;
  max-width: calc(100% - 24px);
  color: #ffffff;
  background: #f59e0b;
  border-radius: 999px;
  padding: 5px 10px;
  font-size: 12px;
  font-weight: 800;
}

.rank-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  width: 34px;
  height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #111827;
  background: #fbbf24;
  border-radius: 999px;
  font-weight: 900;
}

.movie-card__body {
  padding: 16px;
}

.movie-card h3 {
  margin: 0 0 9px;
  color: #0f172a;
  font-size: 17px;
  line-height: 1.35;
}

.movie-card h3 a:hover {
  color: #d97706;
}

.movie-card p {
  min-height: 48px;
  margin: 0 0 13px;
  color: #64748b;
  font-size: 14px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.movie-card__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  color: #64748b;
  font-size: 12px;
}

.movie-card__meta span {
  background: #f1f5f9;
  border-radius: 999px;
  padding: 3px 8px;
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 12px;
}

.tag-row span {
  color: #92400e;
  background: #fffbeb;
  border-radius: 999px;
  padding: 4px 9px;
  font-size: 12px;
  font-weight: 700;
}

.tag-row--large span {
  font-size: 13px;
  padding: 6px 11px;
}

.movie-card--compact .movie-card__body {
  padding: 13px;
}

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

.movie-card--compact p {
  font-size: 13px;
}

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

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

.rank-item {
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: 16px;
  overflow: hidden;
  background: #ffffff;
  border-radius: 18px;
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.08);
}

.rank-item__cover {
  display: block;
  height: 100%;
  min-height: 150px;
  background: #0f172a;
}

.rank-item__cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.rank-item__content {
  position: relative;
  padding: 18px 18px 18px 0;
}

.rank-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 32px;
  height: 32px;
  margin-bottom: 10px;
  color: #111827;
  background: #fbbf24;
  border-radius: 999px;
  font-weight: 900;
}

.rank-item h3 {
  margin: 0 0 8px;
  color: #0f172a;
  font-size: 18px;
}

.rank-item h3 a:hover {
  color: #d97706;
}

.rank-item p {
  margin: 0 0 12px;
  color: #64748b;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

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

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

.category-card {
  position: relative;
  min-height: 220px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 22px;
  color: #ffffff;
  background: linear-gradient(135deg, #111827, #334155);
  border-radius: 24px;
  box-shadow: 0 18px 42px rgba(15, 23, 42, 0.16);
}

.category-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 20% 20%, rgba(251, 191, 36, 0.3), transparent 32%), linear-gradient(180deg, transparent, rgba(0, 0, 0, 0.74));
  z-index: 1;
}

.category-card__title,
.category-card__desc {
  position: relative;
  z-index: 2;
}

.category-card__title {
  margin-bottom: 8px;
  font-size: 24px;
  font-weight: 900;
}

.category-card__desc {
  color: rgba(255, 255, 255, 0.82);
  font-size: 14px;
}

.category-card__thumbs {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  opacity: 0.28;
}

.category-card__thumbs img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.page-hero {
  color: #ffffff;
  background: radial-gradient(circle at 18% 12%, rgba(251, 191, 36, 0.28), transparent 28%), linear-gradient(135deg, #0f172a, #1e293b 58%, #111827);
  padding: 82px 0 72px;
}

.page-hero h1 {
  max-width: 760px;
  margin: 0 0 14px;
  font-size: clamp(34px, 5vw, 60px);
  line-height: 1.06;
  letter-spacing: -0.03em;
}

.page-hero p {
  max-width: 740px;
  margin: 0;
  color: rgba(255, 255, 255, 0.82);
  font-size: 18px;
}

.breadcrumb {
  display: inline-flex;
  margin-bottom: 18px;
  color: #fde68a;
  font-weight: 800;
}

.filter-bar {
  display: flex;
  gap: 12px;
  margin-bottom: 24px;
  padding: 12px;
  background: #ffffff;
  border-radius: 18px;
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.08);
}

.filter-bar input,
.filter-bar select {
  min-height: 46px;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  background: #f8fafc;
  outline: none;
  padding: 0 14px;
}

.filter-bar input {
  flex: 1;
  min-width: 0;
}

.filter-bar select {
  width: 180px;
}

.empty-state {
  display: none;
  margin: 30px 0;
  color: #64748b;
  text-align: center;
}

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

.watch-layout {
  padding: 34px 0 42px;
  background: linear-gradient(180deg, #e2e8f0, #f8fafc);
}

.crumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-bottom: 22px;
  color: #64748b;
  font-size: 14px;
}

.crumbs a {
  color: #92400e;
  font-weight: 800;
}

.watch-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 28px;
  align-items: start;
}

.watch-main,
.side-card {
  background: #ffffff;
  border-radius: 24px;
  box-shadow: 0 18px 42px rgba(15, 23, 42, 0.1);
}

.watch-main {
  overflow: hidden;
}

.player-shell {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #020617;
  overflow: hidden;
}

.movie-video {
  position: absolute;
  inset: 0;
  z-index: 1;
  width: 100%;
  height: 100%;
  background: #020617;
}

.player-cover {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 0;
  padding: 0;
  background: #020617;
  cursor: pointer;
}

.player-cover.is-hidden {
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.22s ease;
}

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

.player-cover__shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(2, 6, 23, 0.28), rgba(2, 6, 23, 0.78));
}

.play-circle {
  position: relative;
  z-index: 3;
  width: 82px;
  height: 82px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #111827;
  background: #fbbf24;
  border-radius: 999px;
  font-size: 30px;
  box-shadow: 0 18px 45px rgba(251, 191, 36, 0.36);
}

.movie-detail {
  padding: 26px;
}

.movie-detail h1 {
  margin: 0 0 14px;
  color: #0f172a;
  font-size: clamp(28px, 4vw, 46px);
  line-height: 1.12;
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 16px;
  color: #475569;
}

.detail-meta span {
  background: #f1f5f9;
  border-radius: 999px;
  padding: 6px 11px;
  font-size: 14px;
  font-weight: 700;
}

.detail-block {
  margin-top: 26px;
  padding-top: 24px;
  border-top: 1px solid #e2e8f0;
}

.detail-block h2 {
  margin: 0 0 12px;
  color: #0f172a;
  font-size: 22px;
}

.detail-block p {
  margin: 0 0 14px;
  color: #475569;
  font-size: 16px;
}

.detail-block--note {
  margin-top: 20px;
  padding: 22px;
  border-top: 0;
  border-radius: 18px;
  background: linear-gradient(135deg, #fffbeb, #fff7ed);
}

.watch-side {
  position: sticky;
  top: 92px;
}

.side-card {
  padding: 20px;
}

.side-card h2 {
  margin: 0 0 16px;
  font-size: 21px;
}

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

.side-list .rank-item {
  grid-template-columns: 92px 1fr;
  box-shadow: none;
  border: 1px solid #e2e8f0;
}

.side-list .rank-item__cover {
  min-height: 124px;
}

.side-list .rank-item__content {
  padding: 12px 12px 12px 0;
}

.side-list .rank-item p {
  display: none;
}

.side-list .rank-item h3 {
  font-size: 15px;
}

.site-footer {
  color: #cbd5e1;
  background: #020617;
  padding: 42px 0;
}

.site-footer__inner {
  display: flex;
  justify-content: space-between;
  gap: 30px;
}

.site-footer strong {
  color: #ffffff;
  font-size: 20px;
}

.site-footer p {
  max-width: 620px;
  margin: 10px 0 0;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-content: flex-start;
}

.footer-links a {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 999px;
  padding: 8px 13px;
}

@media (max-width: 1024px) {
  .header-search {
    display: none;
  }

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

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

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

  .watch-side {
    position: static;
  }
}

@media (max-width: 760px) {
  .site-header__inner {
    min-height: 64px;
  }

  .site-nav {
    display: none;
  }

  .menu-button {
    display: inline-flex;
    margin-left: auto;
  }

  .hero,
  .hero-slide__content {
    min-height: 720px;
  }

  .hero-slide__overlay {
    background: linear-gradient(180deg, rgba(2, 6, 23, 0.52), rgba(2, 6, 23, 0.96));
  }

  .hero-slide__content {
    justify-content: flex-end;
    padding-bottom: 150px;
  }

  .hero-nav {
    display: none;
  }

  .hero-search {
    border-radius: 22px;
  }

  .hero-search input {
    padding: 0 12px;
  }

  .hero-search button {
    padding: 11px 16px;
  }

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

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

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

  .rank-item {
    grid-template-columns: 96px 1fr;
  }

  .rank-item__cover {
    min-height: 130px;
  }

  .rank-item__content {
    padding: 13px 13px 13px 0;
  }

  .rank-item p {
    font-size: 13px;
  }

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

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

  .filter-bar select {
    width: 100%;
  }

  .movie-detail {
    padding: 20px;
  }

  .play-circle {
    width: 68px;
    height: 68px;
  }
}

@media (max-width: 460px) {
  .container,
  .site-header__inner,
  .mobile-panel {
    width: min(100% - 24px, 1200px);
  }

  .movie-grid,
  .movie-grid--dense {
    grid-template-columns: 1fr;
  }

  .hero-actions .btn {
    width: 100%;
  }
}
