:root {
  --slate-950: #020617;
  --slate-900: #0f172a;
  --slate-800: #1e293b;
  --slate-700: #334155;
  --slate-600: #475569;
  --slate-500: #64748b;
  --slate-200: #e2e8f0;
  --slate-100: #f1f5f9;
  --slate-50: #f8fafc;
  --blue-800: #1e40af;
  --blue-700: #1d4ed8;
  --blue-600: #2563eb;
  --blue-500: #3b82f6;
  --blue-100: #dbeafe;
  --green-600: #16a34a;
  --yellow-500: #eab308;
  --red-500: #ef4444;
  --white: #ffffff;
  --shadow-soft: 0 18px 45px rgba(15, 23, 42, 0.10);
  --shadow-card: 0 14px 35px rgba(15, 23, 42, 0.12);
  --radius-lg: 24px;
  --radius-md: 18px;
  --radius-sm: 12px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  color: var(--slate-900);
  background: var(--slate-50);
}

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

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

button,
input {
  font: inherit;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.92);
  border-bottom: 1px solid rgba(226, 232, 240, 0.9);
  backdrop-filter: blur(16px);
}

.nav-shell {
  min-height: 72px;
  display: flex;
  align-items: center;
  gap: 24px;
}

.brand,
.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  color: var(--slate-900);
}

.brand-mark {
  width: 38px;
  height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  color: var(--white);
  background: linear-gradient(135deg, var(--blue-500), var(--blue-800));
  box-shadow: 0 10px 25px rgba(37, 99, 235, 0.35);
}

.brand-text {
  white-space: nowrap;
}

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

.nav-link,
.mobile-nav-link {
  padding: 10px 14px;
  border-radius: 999px;
  color: var(--slate-600);
  font-weight: 650;
  transition: color 0.2s ease, background 0.2s ease;
}

.nav-link:hover,
.nav-link.is-active,
.mobile-nav-link:hover,
.mobile-nav-link.is-active {
  color: var(--blue-700);
  background: var(--blue-100);
}

.nav-search {
  width: min(320px, 30vw);
  display: flex;
  align-items: center;
  padding: 4px;
  border: 1px solid var(--slate-200);
  border-radius: 999px;
  background: var(--white);
}

.nav-search input,
.mobile-search input,
.filter-input,
.search-hero-form input {
  width: 100%;
  border: 0;
  outline: 0;
  color: var(--slate-800);
  background: transparent;
}

.nav-search input {
  padding: 8px 10px 8px 14px;
}

.nav-search button,
.mobile-search button,
.search-hero-form button {
  border: 0;
  cursor: pointer;
  color: var(--white);
  background: var(--blue-600);
  border-radius: 999px;
  padding: 8px 16px;
  font-weight: 700;
}

.mobile-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 14px;
  background: var(--slate-100);
  cursor: pointer;
}

.mobile-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  margin: 5px auto;
  background: var(--slate-700);
  border-radius: 99px;
}

.mobile-panel {
  display: none;
  border-top: 1px solid var(--slate-200);
  background: var(--white);
}

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

.mobile-panel-inner {
  display: grid;
  gap: 8px;
  padding: 14px 0 18px;
}

.mobile-search {
  display: flex;
  gap: 8px;
  padding: 8px;
  border: 1px solid var(--slate-200);
  border-radius: 18px;
  background: var(--slate-50);
}

.hero {
  position: relative;
  overflow: hidden;
  color: var(--white);
  background:
    radial-gradient(circle at 15% 20%, rgba(59, 130, 246, 0.45), transparent 32%),
    linear-gradient(135deg, var(--slate-950), #102a70 48%, var(--slate-900));
}

.hero-pattern {
  position: absolute;
  inset: 0;
  opacity: 0.12;
  background-image:
    linear-gradient(90deg, rgba(255,255,255,0.15) 1px, transparent 1px),
    linear-gradient(rgba(255,255,255,0.15) 1px, transparent 1px);
  background-size: 44px 44px;
}

.hero-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1fr minmax(360px, 480px);
  gap: 48px;
  align-items: center;
  padding-top: 72px;
  padding-bottom: 76px;
}

.hero-kicker,
.section-kicker,
.eyebrow {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  padding: 7px 14px;
  border-radius: 999px;
  color: #bfdbfe;
  background: rgba(255, 255, 255, 0.10);
  border: 1px solid rgba(255, 255, 255, 0.18);
  font-weight: 700;
  letter-spacing: 0.03em;
}

.hero h1 {
  margin: 22px 0 22px;
  font-size: clamp(42px, 7vw, 74px);
  line-height: 1.04;
  letter-spacing: -0.045em;
}

.hero-copy p {
  max-width: 720px;
  margin: 0;
  color: #dbeafe;
  font-size: clamp(18px, 2.4vw, 24px);
  line-height: 1.75;
}

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

.primary-button,
.ghost-button,
.section-link,
.card-button,
.detail-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  font-weight: 800;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.primary-button,
.detail-button {
  min-height: 48px;
  padding: 0 24px;
  color: var(--white);
  background: var(--blue-600);
  box-shadow: 0 14px 30px rgba(37, 99, 235, 0.32);
}

.primary-button:hover,
.detail-button:hover,
.nav-search button:hover,
.mobile-search button:hover,
.search-hero-form button:hover {
  background: var(--blue-700);
}

.primary-button:hover,
.ghost-button:hover,
.card-button:hover,
.detail-button:hover {
  transform: translateY(-2px);
}

.ghost-button {
  min-height: 48px;
  padding: 0 24px;
  color: var(--white);
  border: 1px solid rgba(255, 255, 255, 0.28);
  background: rgba(255, 255, 255, 0.10);
  backdrop-filter: blur(14px);
}

.hero-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  max-width: 520px;
  margin-top: 38px;
}

.hero-stats div {
  padding: 18px;
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.hero-stats strong {
  display: block;
  color: #60a5fa;
  font-size: 28px;
  line-height: 1;
}

.hero-stats span {
  display: block;
  margin-top: 8px;
  color: #bfdbfe;
  font-size: 14px;
}

.hero-categories {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 22px;
}

.hero-categories a {
  padding: 8px 13px;
  border-radius: 999px;
  color: #dbeafe;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.hero-showcase {
  position: relative;
}

.hero-slides {
  position: relative;
  min-height: 620px;
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: grid;
  align-content: end;
  overflow: hidden;
  border-radius: 34px;
  background: var(--slate-900);
  box-shadow: 0 30px 80px rgba(2, 6, 23, 0.42);
  opacity: 0;
  transform: translateX(26px) scale(0.98);
  transition: opacity 0.45s ease, transform 0.45s ease;
  pointer-events: none;
}

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

.hero-poster {
  position: absolute;
  inset: 0;
}

.hero-poster img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-slide::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(2, 6, 23, 0.92), rgba(2, 6, 23, 0.24), rgba(2, 6, 23, 0.08));
}

.hero-slide-copy {
  position: relative;
  z-index: 1;
  padding: 34px;
}

.hero-slide-copy span {
  color: #bfdbfe;
  font-weight: 750;
}

.hero-slide-copy h2 {
  margin: 10px 0 12px;
  font-size: clamp(26px, 4vw, 40px);
  line-height: 1.16;
}

.hero-slide-copy p {
  margin: 0 0 18px;
  color: #dbeafe;
  line-height: 1.7;
}

.hero-slide-link {
  display: inline-flex;
  padding: 10px 18px;
  color: var(--white);
  background: var(--blue-600);
  border-radius: 999px;
  font-weight: 800;
}

.hero-dots {
  display: flex;
  justify-content: center;
  gap: 9px;
  margin-top: 18px;
}

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

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

.page-hero,
.search-hero,
.detail-hero {
  color: var(--white);
  background: linear-gradient(135deg, var(--blue-700), var(--slate-900));
}

.page-hero .container,
.search-hero .container,
.detail-hero .container {
  padding-top: 54px;
  padding-bottom: 52px;
}

.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  color: rgba(255, 255, 255, 0.76);
  font-size: 14px;
  margin-bottom: 18px;
}

.breadcrumbs a:hover {
  color: var(--white);
}

.page-hero h1,
.search-hero h1,
.detail-hero h1 {
  margin: 0 0 14px;
  font-size: clamp(34px, 5vw, 56px);
  line-height: 1.12;
}

.page-hero p,
.search-hero p,
.detail-hero p {
  margin: 0;
  max-width: 820px;
  color: #dbeafe;
  font-size: 18px;
  line-height: 1.72;
}

.section {
  padding: 64px 0;
}

.section.is-white {
  background: var(--white);
}

.section.is-soft {
  background: var(--slate-50);
}

.section.is-blue-soft {
  background: linear-gradient(135deg, #eff6ff, var(--slate-50));
}

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

.section-kicker {
  margin-bottom: 10px;
  color: var(--blue-700);
  background: var(--blue-100);
  border-color: transparent;
}

.section-heading h2 {
  margin: 0;
  color: var(--slate-900);
  font-size: clamp(28px, 4vw, 40px);
}

.section-heading p {
  margin: 8px 0 0;
  color: var(--slate-500);
  line-height: 1.7;
}

.section-link,
.card-button {
  flex: 0 0 auto;
  padding: 10px 16px;
  color: var(--blue-700);
  background: var(--blue-100);
}

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

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

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

.movie-card {
  overflow: hidden;
  border-radius: var(--radius-md);
  background: var(--white);
  border: 1px solid rgba(226, 232, 240, 0.96);
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.06);
  transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  border-color: rgba(59, 130, 246, 0.38);
  box-shadow: var(--shadow-card);
}

.movie-cover {
  position: relative;
  display: block;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  background: linear-gradient(135deg, var(--slate-800), var(--blue-800));
}

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

.movie-card:hover .movie-cover img,
.related-card:hover img,
.ranking-row:hover img {
  transform: scale(1.06);
}

.movie-cover::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(2, 6, 23, 0.66), transparent 52%);
}

.movie-category,
.rank-badge,
.play-badge {
  position: absolute;
  z-index: 1;
}

.movie-category {
  left: 12px;
  top: 12px;
  padding: 6px 10px;
  color: var(--white);
  background: rgba(37, 99, 235, 0.92);
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
}

.rank-badge {
  right: 12px;
  top: 12px;
  min-width: 34px;
  height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
  background: linear-gradient(135deg, var(--yellow-500), #f97316);
  border-radius: 12px;
  font-weight: 900;
}

.play-badge {
  right: 12px;
  bottom: 12px;
  width: 42px;
  height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--blue-700);
  background: rgba(255, 255, 255, 0.92);
  border-radius: 999px;
  font-size: 15px;
  box-shadow: 0 8px 20px rgba(2, 6, 23, 0.22);
}

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

.movie-card h3 {
  margin: 0 0 9px;
  font-size: 18px;
  line-height: 1.35;
}

.movie-card h3 a:hover {
  color: var(--blue-700);
}

.movie-meta {
  margin: 0 0 10px;
  color: var(--slate-500);
  font-size: 13px;
}

.movie-line {
  margin: 0;
  color: var(--slate-600);
  line-height: 1.65;
  font-size: 14px;
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 14px;
}

.tag-row span,
.detail-tag {
  display: inline-flex;
  padding: 5px 9px;
  border-radius: 999px;
  color: var(--slate-600);
  background: var(--slate-100);
  font-size: 12px;
  font-weight: 650;
}

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

.category-card {
  display: grid;
  min-height: 220px;
  padding: 24px;
  border-radius: var(--radius-md);
  color: var(--slate-900);
  background: var(--white);
  border: 1px solid var(--slate-200);
  box-shadow: 0 10px 26px rgba(15, 23, 42, 0.06);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

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

.category-icon {
  width: 58px;
  height: 58px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 22px;
  color: var(--white);
  background: linear-gradient(135deg, var(--blue-500), var(--blue-800));
  font-size: 24px;
  font-weight: 900;
}

.category-card h2,
.category-card h3 {
  margin: 18px 0 10px;
  font-size: 24px;
}

.category-card p {
  margin: 0;
  color: var(--slate-600);
  line-height: 1.72;
}

.category-card span:last-child {
  align-self: end;
  margin-top: 22px;
  color: var(--blue-700);
  font-weight: 800;
}

.filter-panel {
  display: flex;
  gap: 12px;
  align-items: center;
  margin-bottom: 28px;
  padding: 14px;
  border-radius: var(--radius-md);
  background: var(--white);
  border: 1px solid var(--slate-200);
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.05);
}

.filter-input {
  min-height: 48px;
  padding: 0 16px;
  border-radius: 16px;
  background: var(--slate-50);
}

.filter-panel a,
.filter-panel button {
  border: 0;
  cursor: pointer;
  white-space: nowrap;
  border-radius: 16px;
  padding: 13px 16px;
  color: var(--white);
  background: var(--blue-600);
  font-weight: 800;
}

.is-hidden {
  display: none !important;
}

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

.ranking-row {
  display: grid;
  grid-template-columns: 62px 118px 1fr auto;
  gap: 18px;
  align-items: center;
  padding: 16px;
  border-radius: var(--radius-md);
  background: var(--white);
  border: 1px solid var(--slate-200);
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.05);
}

.ranking-number {
  width: 48px;
  height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 16px;
  color: var(--white);
  background: linear-gradient(135deg, var(--blue-500), var(--blue-800));
  font-size: 20px;
  font-weight: 900;
}

.ranking-row img {
  width: 118px;
  height: 78px;
  object-fit: cover;
  border-radius: 14px;
  background: var(--slate-800);
  transition: transform 0.35s ease;
}

.ranking-row h2,
.ranking-row h3 {
  margin: 0 0 8px;
  font-size: 20px;
}

.ranking-row p {
  margin: 0;
  color: var(--slate-600);
  line-height: 1.6;
}

.search-hero-form {
  display: flex;
  gap: 10px;
  max-width: 760px;
  margin-top: 28px;
  padding: 8px;
  border-radius: 999px;
  background: var(--white);
}

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

.search-hero-form button {
  padding: 14px 24px;
}

.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 28px;
  align-items: start;
  padding-top: 34px;
  padding-bottom: 64px;
}

.player-card,
.detail-card,
.sidebar-card {
  overflow: hidden;
  border-radius: var(--radius-lg);
  background: var(--white);
  border: 1px solid var(--slate-200);
  box-shadow: var(--shadow-soft);
}

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

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

.player-overlay {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: grid;
  place-items: center;
  padding: 24px;
  color: var(--white);
  background: linear-gradient(to top, rgba(2, 6, 23, 0.70), rgba(2, 6, 23, 0.20));
  cursor: pointer;
  transition: opacity 0.24s ease, visibility 0.24s ease;
}

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

.player-play {
  width: 86px;
  height: 86px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 999px;
  color: var(--blue-700);
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 18px 45px rgba(2, 6, 23, 0.35);
  cursor: pointer;
  font-size: 30px;
}

.player-caption {
  padding: 18px 22px;
  background: var(--slate-950);
  color: var(--white);
}

.player-caption h2 {
  margin: 0 0 6px;
  font-size: 20px;
}

.player-caption p {
  margin: 0;
  color: #cbd5e1;
  line-height: 1.65;
}

.detail-card {
  margin-top: 24px;
  padding: 26px;
}

.detail-card h2,
.sidebar-card h2 {
  margin: 0 0 16px;
  color: var(--slate-900);
}

.detail-card p {
  color: var(--slate-700);
  line-height: 1.85;
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 18px 0 24px;
}

.detail-meta span {
  padding: 8px 12px;
  border-radius: 999px;
  color: var(--slate-700);
  background: var(--slate-100);
  font-weight: 650;
}

.detail-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.sidebar-card {
  position: sticky;
  top: 94px;
  padding: 20px;
}

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

.related-card {
  display: grid;
  grid-template-columns: 112px 1fr;
  gap: 12px;
  align-items: center;
}

.related-card img {
  width: 112px;
  height: 76px;
  object-fit: cover;
  border-radius: 14px;
  background: var(--slate-800);
  transition: transform 0.35s ease;
}

.related-card h3 {
  margin: 0 0 6px;
  font-size: 15px;
  line-height: 1.4;
}

.related-card p {
  margin: 0;
  color: var(--slate-500);
  font-size: 13px;
}

.site-footer {
  color: #cbd5e1;
  background: linear-gradient(180deg, var(--slate-900), var(--slate-950));
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr;
  gap: 34px;
  padding-top: 52px;
  padding-bottom: 36px;
}

.footer-brand {
  color: var(--white);
  font-size: 20px;
}

.site-footer h2 {
  margin: 0 0 14px;
  color: var(--white);
  font-size: 17px;
}

.site-footer p {
  max-width: 420px;
  line-height: 1.75;
}

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

.footer-links a:hover {
  color: var(--blue-100);
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  padding: 18px 0 28px;
  border-top: 1px solid rgba(148, 163, 184, 0.18);
  font-size: 14px;
}

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

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

  .hero-slides {
    min-height: 560px;
  }

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

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

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

  .sidebar-card {
    position: static;
  }
}

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

  .nav-links {
    display: none;
  }

  .mobile-toggle {
    display: block;
    margin-left: auto;
  }

  .hero-grid {
    padding-top: 48px;
    padding-bottom: 52px;
  }

  .hero-stats {
    grid-template-columns: 1fr;
  }

  .hero-slides {
    min-height: 500px;
  }

  .hero-slide-copy {
    padding: 24px;
  }

  .section {
    padding: 44px 0;
  }

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

  .movie-grid,
  .movie-grid.three-columns,
  .movie-grid.six-columns,
  .category-grid,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .filter-panel,
  .search-hero-form {
    align-items: stretch;
    flex-direction: column;
    border-radius: var(--radius-md);
  }

  .ranking-row {
    grid-template-columns: 48px 90px 1fr;
  }

  .ranking-row img {
    width: 90px;
    height: 66px;
  }

  .ranking-row .card-button {
    grid-column: 1 / -1;
  }

  .related-card {
    grid-template-columns: 96px 1fr;
  }

  .related-card img {
    width: 96px;
    height: 66px;
  }
}
