:root {
  --night-950: #0f172a;
  --night-900: #1a1f35;
  --night-850: #1e293b;
  --night-800: #3730a3;
  --silver-100: #f8fafc;
  --silver-200: #e2e8f0;
  --silver-300: #cbd5e1;
  --silver-400: #94a3b8;
  --silver-600: #475569;
  --silver-700: #334155;
  --moonlight-300: #a5bbfc;
  --moonlight-400: #8196f8;
  --moonlight-500: #6172f3;
  --moonlight-600: #4f46e5;
  --card: rgba(30, 41, 59, 0.36);
  --card-strong: rgba(30, 41, 59, 0.62);
  --border: rgba(51, 65, 85, 0.42);
  --shadow: 0 24px 60px rgba(3, 7, 18, 0.36);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--silver-200);
  font-family: Inter, "Noto Sans SC", "Microsoft YaHei", system-ui, sans-serif;
  background: linear-gradient(180deg, var(--night-950), var(--night-850), #334155);
}

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

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

button,
input,
select {
  font: inherit;
}

.site-header {
  position: fixed;
  z-index: 50;
  top: 0;
  left: 0;
  right: 0;
  background: rgba(26, 31, 53, 0.95);
  border-bottom: 1px solid rgba(51, 65, 85, 0.32);
  backdrop-filter: blur(18px);
}

.header-inner {
  width: min(1280px, calc(100% - 32px));
  height: 64px;
  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;
  color: #ffffff;
  font-weight: 800;
  letter-spacing: 0.02em;
}

.brand-name,
.footer-brand span:last-child {
  font-family: "Noto Serif SC", Georgia, serif;
  font-size: 22px;
}

.brand-mark {
  width: 34px;
  height: 34px;
  display: inline-grid;
  place-items: center;
  border-radius: 50%;
  color: #ffffff;
  background: linear-gradient(135deg, var(--moonlight-500), #8b5cf6);
  box-shadow: 0 0 28px rgba(97, 114, 243, 0.38);
  font-size: 14px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 24px;
  color: var(--silver-300);
}

.nav-links a {
  transition: color 0.2s ease;
}

.nav-links a:hover,
.nav-links a.is-active {
  color: #ffffff;
}

.header-search,
.mobile-search,
.search-panel {
  display: flex;
  align-items: center;
  gap: 10px;
}

.header-search input,
.mobile-search input,
.search-panel input,
.search-panel select {
  width: 210px;
  color: #ffffff;
  background: rgba(30, 41, 59, 0.54);
  border: 1px solid rgba(51, 65, 85, 0.45);
  border-radius: 999px;
  padding: 11px 16px;
  outline: none;
}

.header-search input:focus,
.mobile-search input:focus,
.search-panel input:focus,
.search-panel select:focus {
  border-color: var(--moonlight-500);
  box-shadow: 0 0 0 3px rgba(97, 114, 243, 0.22);
}

.header-search button,
.mobile-search button,
.search-panel button,
.btn-primary,
.btn-secondary,
.btn-ghost {
  cursor: pointer;
  border: 0;
  border-radius: 999px;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.header-search button,
.mobile-search button,
.search-panel button,
.btn-primary {
  color: #ffffff;
  background: var(--moonlight-500);
  padding: 11px 18px;
  box-shadow: 0 10px 30px rgba(97, 114, 243, 0.26);
}

.btn-secondary {
  color: var(--moonlight-300);
  background: rgba(97, 114, 243, 0.16);
  border: 1px solid rgba(97, 114, 243, 0.3);
  padding: 11px 18px;
}

.btn-ghost {
  color: var(--silver-200);
  background: rgba(15, 23, 42, 0.38);
  border: 1px solid rgba(226, 232, 240, 0.18);
  padding: 10px 16px;
}

.header-search button:hover,
.mobile-search button:hover,
.search-panel button:hover,
.btn-primary:hover,
.btn-secondary:hover,
.btn-ghost:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 36px rgba(97, 114, 243, 0.34);
}

.menu-toggle {
  display: none;
  color: #ffffff;
  background: transparent;
  border: 0;
  font-size: 28px;
}

.mobile-panel {
  display: none;
  border-top: 1px solid rgba(51, 65, 85, 0.32);
  background: rgba(15, 23, 42, 0.98);
  padding: 16px;
}

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

.mobile-search {
  width: min(640px, 100%);
  margin: 0 auto 14px;
}

.mobile-search input {
  width: 100%;
}

.mobile-links {
  width: min(640px, 100%);
  margin: 0 auto;
  display: grid;
  gap: 10px;
}

.mobile-links a {
  color: var(--silver-300);
  padding: 9px 0;
}

main {
  padding-top: 64px;
}

.hero {
  position: relative;
  min-height: 600px;
  overflow: hidden;
  display: flex;
  align-items: center;
}

.hero-bg,
.hero-bg img,
.hero-bg::after {
  position: absolute;
  inset: 0;
}

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

.hero-bg::after {
  content: "";
  background: linear-gradient(180deg, rgba(26, 31, 53, 0.82), rgba(26, 31, 53, 0.54), var(--night-900));
}

.hero-inner {
  position: relative;
  z-index: 2;
  width: min(1280px, calc(100% - 32px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 48px;
  align-items: center;
}

.hero-kicker,
.section-kicker,
.breadcrumb {
  color: var(--moonlight-300);
  font-weight: 700;
  letter-spacing: 0.08em;
}

.hero h1,
.page-hero h1,
.detail-title,
.section-title h2 {
  margin: 0;
  color: #ffffff;
  font-family: "Noto Serif SC", Georgia, serif;
  font-weight: 800;
}

.hero h1 {
  max-width: 800px;
  margin-top: 18px;
  font-size: clamp(46px, 8vw, 86px);
  line-height: 1.05;
}

.hero-lead {
  max-width: 760px;
  color: var(--silver-200);
  font-size: clamp(18px, 2.2vw, 26px);
  line-height: 1.65;
  margin: 24px 0 28px;
}

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

.hero-feature {
  background: linear-gradient(135deg, rgba(47, 46, 130, 0.34), rgba(15, 23, 42, 0.68));
  border: 1px solid rgba(51, 65, 85, 0.46);
  border-radius: 28px;
  box-shadow: var(--shadow);
  padding: 26px;
  backdrop-filter: blur(12px);
}

.hero-feature img {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  border-radius: 22px;
  margin-bottom: 20px;
}

.hero-feature h2 {
  margin: 0 0 12px;
  color: #ffffff;
  font-size: 26px;
}

.hero-feature p {
  color: var(--silver-300);
  line-height: 1.7;
  margin: 0 0 18px;
}

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

.hero-tags span,
.tag-row span {
  color: var(--silver-200);
  background: rgba(97, 114, 243, 0.16);
  border: 1px solid rgba(97, 114, 243, 0.24);
  border-radius: 999px;
  padding: 6px 10px;
  font-size: 13px;
}

.hero-rail {
  position: relative;
  z-index: 3;
  width: min(1280px, calc(100% - 32px));
  margin: -70px auto 0;
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 14px;
}

.hero-mini-card {
  min-height: 124px;
  display: flex;
  align-items: flex-end;
  position: relative;
  overflow: hidden;
  border-radius: 18px;
  border: 1px solid rgba(226, 232, 240, 0.12);
  background: var(--card);
  box-shadow: 0 12px 34px rgba(0, 0, 0, 0.2);
}

.hero-mini-card img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.66;
  transition: transform 0.35s ease;
}

.hero-mini-card span {
  position: relative;
  z-index: 2;
  width: 100%;
  color: #ffffff;
  font-weight: 700;
  padding: 14px;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.76), rgba(0, 0, 0, 0));
}

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

.page-hero {
  padding: 120px 0 54px;
  background: radial-gradient(circle at top left, rgba(97, 114, 243, 0.22), transparent 32%), linear-gradient(135deg, rgba(47, 46, 130, 0.18), rgba(15, 23, 42, 0));
}

.page-hero-inner,
.section,
.detail-wrap,
.footer-grid,
.footer-bottom {
  width: min(1280px, calc(100% - 32px));
  margin: 0 auto;
}

.page-hero h1 {
  font-size: clamp(36px, 5vw, 64px);
  line-height: 1.15;
}

.page-hero p {
  max-width: 820px;
  color: var(--silver-300);
  font-size: 18px;
  line-height: 1.75;
}

.section {
  padding: 64px 0;
}

.section.is-soft {
  width: 100%;
  max-width: none;
  padding: 64px max(16px, calc((100% - 1280px) / 2));
  background: rgba(15, 23, 42, 0.28);
}

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

.section-title h2 {
  font-size: clamp(26px, 3vw, 38px);
}

.section-title p {
  color: var(--silver-400);
  margin: 6px 0 0;
}

.card-row {
  display: flex;
  gap: 22px;
  overflow-x: auto;
  padding: 2px 2px 16px;
  scroll-snap-type: x proximity;
}

.card-row .movie-card {
  width: 320px;
  min-width: 320px;
  scroll-snap-align: start;
}

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

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

.movie-card,
.category-tile,
.rank-panel,
.detail-panel,
.player-shell,
.search-box {
  overflow: hidden;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 18px;
  box-shadow: 0 16px 42px rgba(3, 7, 18, 0.18);
}

.movie-card {
  transition: transform 0.24s ease, box-shadow 0.24s ease, border-color 0.24s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  border-color: rgba(97, 114, 243, 0.5);
  box-shadow: 0 22px 54px rgba(97, 114, 243, 0.18);
}

.poster-link {
  position: relative;
  display: block;
  aspect-ratio: 16 / 9;
  overflow: hidden;
}

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

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

.poster-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.82), rgba(0, 0, 0, 0.04));
  opacity: 0.72;
}

.play-icon {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 58px;
  height: 58px;
  display: grid;
  place-items: center;
  transform: translate(-50%, -50%) scale(0.9);
  color: #ffffff;
  background: rgba(97, 114, 243, 0.78);
  border-radius: 50%;
  opacity: 0;
  transition: opacity 0.25s ease, transform 0.25s ease;
}

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

.duration,
.rank-badge {
  position: absolute;
  color: #ffffff;
  background: rgba(0, 0, 0, 0.72);
  border-radius: 8px;
  padding: 5px 8px;
  font-size: 12px;
}

.duration {
  right: 10px;
  bottom: 10px;
}

.rank-badge {
  left: 10px;
  top: 10px;
  background: rgba(97, 114, 243, 0.86);
}

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

.movie-card-body h2 {
  margin: 0 0 9px;
  color: #ffffff;
  font-size: 17px;
  line-height: 1.45;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
}

.movie-card-body h2 a:hover {
  color: var(--moonlight-300);
}

.movie-card-body p {
  height: 44px;
  color: var(--silver-400);
  margin: 0 0 14px;
  line-height: 1.55;
  font-size: 14px;
  overflow: hidden;
}

.movie-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: var(--silver-400);
  font-size: 13px;
  margin-bottom: 12px;
}

.movie-meta a {
  color: var(--moonlight-300);
}

.category-tile {
  min-height: 180px;
  padding: 28px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  background: linear-gradient(135deg, rgba(47, 46, 130, 0.32), rgba(15, 23, 42, 0.46));
  transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

.category-tile:hover {
  transform: translateY(-5px);
  border-color: rgba(97, 114, 243, 0.58);
  box-shadow: 0 22px 54px rgba(97, 114, 243, 0.16);
}

.category-tile strong {
  color: #ffffff;
  font-size: 22px;
}

.category-tile p {
  color: var(--silver-400);
  line-height: 1.65;
}

.category-icon {
  font-size: 34px;
}

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

.media-list-item {
  display: grid;
  grid-template-columns: auto 120px 1fr;
  gap: 14px;
  align-items: center;
  padding: 12px;
  border-radius: 16px;
  background: rgba(30, 41, 59, 0.24);
  transition: background 0.2s ease, transform 0.2s ease;
}

.media-list-item:hover {
  background: rgba(30, 41, 59, 0.48);
  transform: translateX(4px);
}

.media-list-item img {
  width: 120px;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  border-radius: 12px;
}

.media-list-body {
  min-width: 0;
}

.media-list-body strong {
  display: block;
  color: #ffffff;
  font-size: 17px;
  margin-bottom: 6px;
}

.media-list-body em {
  display: block;
  color: var(--silver-400);
  font-style: normal;
  line-height: 1.5;
  margin-bottom: 6px;
}

.media-list-body small {
  color: var(--moonlight-300);
}

.list-rank {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  color: #ffffff;
  background: linear-gradient(135deg, var(--moonlight-500), #8b5cf6);
  border-radius: 12px;
  font-weight: 800;
}

.rank-grid {
  grid-template-columns: 1.1fr 0.9fr;
  align-items: start;
}

.rank-panel {
  padding: 24px;
}

.rank-panel h2 {
  color: #ffffff;
  margin: 0 0 20px;
  font-size: 24px;
}

.detail-wrap {
  padding: 96px 0 64px;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  align-items: center;
  margin-bottom: 24px;
  font-size: 14px;
}

.breadcrumb a {
  color: var(--silver-300);
}

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

.player-shell {
  position: relative;
  aspect-ratio: 16 / 9;
  background: #000000;
  margin-bottom: 28px;
}

.player-shell video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  background: #000000;
}

.player-overlay {
  position: absolute;
  inset: 0;
  z-index: 5;
  display: grid;
  place-items: center;
  cursor: pointer;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.72), rgba(0, 0, 0, 0.22));
  opacity: 1;
  transition: opacity 0.25s ease;
}

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

.play-button {
  width: 90px;
  height: 90px;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 50%;
  color: #ffffff;
  background: rgba(97, 114, 243, 0.88);
  box-shadow: 0 0 48px rgba(97, 114, 243, 0.52);
  cursor: pointer;
  font-size: 32px;
}

.player-overlay:hover .play-button {
  transform: scale(1.05);
}

.detail-panel {
  padding: 28px;
  margin-bottom: 24px;
}

.detail-title {
  font-size: clamp(34px, 5vw, 58px);
  line-height: 1.14;
  margin-bottom: 16px;
}

.detail-subtitle {
  color: var(--silver-300);
  font-size: 18px;
  line-height: 1.75;
  margin: 0 0 22px;
}

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

.detail-meta div {
  padding: 13px 15px;
  border-radius: 14px;
  background: rgba(15, 23, 42, 0.38);
}

.detail-meta span {
  display: block;
  color: var(--silver-400);
  font-size: 13px;
  margin-bottom: 5px;
}

.detail-meta strong {
  color: #ffffff;
}

.content-block h2,
.content-block h3 {
  color: #ffffff;
  margin: 28px 0 12px;
}

.content-block h2 {
  font-size: 24px;
}

.content-block h3 {
  font-size: 20px;
}

.content-block p {
  color: var(--silver-300);
  line-height: 1.9;
  margin: 0;
}

.side-card {
  position: sticky;
  top: 84px;
}

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

.related-item {
  display: grid;
  grid-template-columns: 112px 1fr;
  gap: 12px;
  padding: 10px;
  border-radius: 14px;
  background: rgba(15, 23, 42, 0.28);
}

.related-item:hover {
  background: rgba(30, 41, 59, 0.5);
}

.related-item img {
  width: 112px;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  border-radius: 10px;
}

.related-item strong {
  display: block;
  color: #ffffff;
  line-height: 1.45;
  margin-bottom: 6px;
}

.related-item small {
  color: var(--silver-400);
}

.search-box {
  padding: 24px;
  margin-bottom: 28px;
}

.search-panel {
  flex-wrap: wrap;
}

.search-panel input {
  flex: 1 1 280px;
  width: auto;
}

.search-panel select {
  width: 170px;
}

.site-footer {
  border-top: 1px solid rgba(51, 65, 85, 0.32);
  background: rgba(15, 23, 42, 0.62);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 34px;
  padding: 52px 0;
}

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

.site-footer p,
.site-footer li,
.site-footer a {
  color: var(--silver-400);
  line-height: 1.75;
}

.site-footer a:hover {
  color: var(--moonlight-300);
}

.site-footer ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.footer-bottom {
  border-top: 1px solid rgba(51, 65, 85, 0.28);
  padding: 22px 0;
  text-align: center;
  color: var(--silver-400);
}

@keyframes floatLight {
  0%, 100% {
    transform: translateY(0);
  }

  50% {
    transform: translateY(-10px);
  }
}

.brand-mark,
.hero .brand-mark {
  animation: floatLight 3s ease-in-out infinite;
}

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

  .hero-inner,
  .detail-layout,
  .rank-grid,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .hero-rail {
    grid-template-columns: repeat(3, 1fr);
    margin-top: 24px;
  }

  .side-card {
    position: static;
  }
}

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

  .menu-toggle {
    display: block;
  }

  .hero {
    min-height: auto;
    padding: 96px 0 44px;
  }

  .hero-inner {
    gap: 28px;
  }

  .hero-feature {
    padding: 18px;
  }

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

  .section,
  .section.is-soft {
    padding-top: 44px;
    padding-bottom: 44px;
  }

  .section-title {
    align-items: flex-start;
    flex-direction: column;
  }

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

  .media-list-item {
    grid-template-columns: auto 92px 1fr;
  }

  .media-list-item img {
    width: 92px;
  }
}

@media (max-width: 560px) {
  .header-inner {
    width: min(100% - 22px, 1280px);
  }

  .brand-name {
    font-size: 19px;
  }

  .hero h1 {
    font-size: 42px;
  }

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

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

  .card-row .movie-card {
    width: 286px;
    min-width: 286px;
  }

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

  .related-item img {
    width: 96px;
  }

  .play-button {
    width: 74px;
    height: 74px;
  }
}
