:root {
  --color-bg: #f8fafc;
  --color-surface: #ffffff;
  --color-surface-soft: #f1f5f9;
  --color-text: #0f172a;
  --color-muted: #64748b;
  --color-border: #e2e8f0;
  --color-primary: #2563eb;
  --color-primary-dark: #1d4ed8;
  --color-cyan: #06b6d4;
  --color-shadow: rgba(15, 23, 42, 0.12);
  --radius-lg: 24px;
  --radius-md: 18px;
  --container: 1180px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

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

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

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.92);
  border-bottom: 1px solid rgba(226, 232, 240, 0.8);
  box-shadow: 0 8px 30px rgba(15, 23, 42, 0.06);
  backdrop-filter: blur(16px);
}

.site-nav {
  width: min(100% - 32px, var(--container));
  height: 68px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

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

.brand__mark {
  width: 38px;
  height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--color-primary), var(--color-cyan));
  box-shadow: 0 12px 28px rgba(37, 99, 235, 0.28);
}

.brand__text {
  font-size: 22px;
}

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

.nav-links a,
.mobile-menu a {
  padding: 9px 14px;
  color: #334155;
  font-size: 15px;
  font-weight: 600;
  border-radius: 999px;
  transition: color 0.2s ease, background 0.2s ease;
}

.nav-links a:hover,
.nav-links a.is-active,
.mobile-menu a:hover,
.mobile-menu a.is-active {
  color: var(--color-primary);
  background: #eff6ff;
}

.nav-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 12px;
  background: #eff6ff;
  cursor: pointer;
}

.nav-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  margin: 4px auto;
  border-radius: 2px;
  background: var(--color-primary);
}

.mobile-menu {
  display: none;
  width: min(100% - 32px, var(--container));
  margin: 0 auto 14px;
  padding: 12px;
  border-radius: 18px;
  background: #ffffff;
  box-shadow: 0 18px 36px rgba(15, 23, 42, 0.08);
}

.mobile-menu.is-open {
  display: grid;
  gap: 6px;
}

.hero {
  position: relative;
  background: #0f172a;
  overflow: hidden;
}

.hero-stage {
  position: relative;
  height: min(76vh, 640px);
  min-height: 520px;
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: grid;
  align-items: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.65s ease;
}

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

.hero-slide__image {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.62;
}

.hero-slide::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 76% 22%, rgba(6, 182, 212, 0.28), transparent 36%),
    linear-gradient(135deg, rgba(15, 23, 42, 0.92), rgba(15, 23, 42, 0.54) 52%, rgba(15, 23, 42, 0.2));
}

.hero-slide__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(0, 0, 0, 0.72), rgba(0, 0, 0, 0.38), transparent);
}

.hero-slide__content {
  position: relative;
  z-index: 2;
  width: min(100% - 32px, var(--container));
  margin: 0 auto;
  max-width: 720px;
  color: #ffffff;
}

.hero-pill,
.section-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  width: max-content;
  padding: 6px 12px;
  border-radius: 999px;
  color: #ffffff;
  background: var(--color-primary);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.02em;
}

.hero-slide h1,
.page-hero h1,
.watch-title h1,
.detail-info h1 {
  margin: 18px 0 14px;
  font-size: clamp(34px, 6vw, 62px);
  line-height: 1.08;
  letter-spacing: -0.05em;
}

.hero-slide p,
.page-hero p,
.watch-title p,
.detail-one-line {
  max-width: 760px;
  color: rgba(255, 255, 255, 0.86);
  font-size: clamp(16px, 2vw, 20px);
}

.hero-tags,
.detail-tags,
.movie-card__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.hero-tags span,
.detail-tags span,
.movie-card__tags span,
.watch-meta span,
.watch-meta a {
  display: inline-flex;
  align-items: center;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 999px;
  padding: 5px 10px;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(10px);
  font-size: 13px;
  font-weight: 700;
}

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

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

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

.button--primary {
  color: #ffffff;
  background: linear-gradient(135deg, var(--color-primary), var(--color-cyan));
  box-shadow: 0 18px 36px rgba(37, 99, 235, 0.32);
}

.button--ghost {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.24);
}

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

.hero-dots button {
  width: 28px;
  height: 6px;
  border: 0;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.32);
  cursor: pointer;
}

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

.hero-search {
  position: relative;
  z-index: 10;
  width: min(100% - 32px, 980px);
  margin: -82px auto 0;
  padding: 22px;
  border: 1px solid rgba(255, 255, 255, 0.26);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 24px 60px rgba(15, 23, 42, 0.22);
  backdrop-filter: blur(18px);
}

.hero-search label {
  display: block;
  margin-bottom: 10px;
  color: #334155;
  font-weight: 800;
}

.hero-search div,
.page-search {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
}

.hero-search input,
.page-search input {
  width: 100%;
  min-height: 48px;
  border: 1px solid var(--color-border);
  border-radius: 16px;
  padding: 0 16px;
  color: var(--color-text);
  background: #ffffff;
  font-size: 16px;
  outline: none;
}

.hero-search input:focus,
.page-search input:focus {
  border-color: var(--color-primary);
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.12);
}

.hero-search button,
.page-search button {
  border: 0;
  border-radius: 16px;
  padding: 0 22px;
  color: #ffffff;
  background: var(--color-primary);
  font-size: 16px;
  font-weight: 800;
  cursor: pointer;
}

.intro-strip,
.content-section,
.page-hero,
.watch-page {
  width: min(100% - 32px, var(--container));
  margin: 32px auto;
}

.intro-strip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 22px 24px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  background: #ffffff;
  box-shadow: 0 18px 42px rgba(15, 23, 42, 0.06);
}

.intro-strip strong,
.intro-strip span {
  display: block;
}

.intro-strip strong {
  font-size: 20px;
}

.intro-strip span {
  color: var(--color-muted);
}

.intro-strip a,
.section-link {
  color: var(--color-primary);
  font-weight: 800;
}

.content-section {
  padding: 6px 0 28px;
}

.content-section--wide {
  width: min(100% - 28px, 1360px);
}

.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 18px;
  margin: 0 0 22px;
}

.section-kicker {
  color: var(--color-primary);
  background: #eff6ff;
}

.section-head h2 {
  margin: 10px 0 4px;
  font-size: clamp(24px, 3vw, 36px);
  line-height: 1.18;
  letter-spacing: -0.04em;
}

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

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

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

.movie-card {
  position: relative;
  display: flex;
  flex-direction: column;
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  background: #ffffff;
  box-shadow: 0 16px 38px rgba(15, 23, 42, 0.07);
  transition: transform 0.24s ease, box-shadow 0.24s ease, border-color 0.24s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  border-color: rgba(37, 99, 235, 0.34);
  box-shadow: 0 24px 52px rgba(15, 23, 42, 0.13);
}

.movie-card__poster,
.poster {
  position: relative;
  display: block;
  min-height: 220px;
  overflow: hidden;
  background:
    radial-gradient(circle at 72% 18%, rgba(6, 182, 212, 0.42), transparent 28%),
    linear-gradient(135deg, #1e293b, #0f172a);
}

.movie-card__poster {
  aspect-ratio: 2 / 3;
}

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

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

.poster__play {
  position: absolute;
  right: 14px;
  bottom: 14px;
  padding: 7px 12px;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(37, 99, 235, 0.92);
  font-size: 13px;
  font-weight: 800;
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.2);
}

.rank-badge {
  position: absolute;
  z-index: 4;
  left: 12px;
  top: 12px;
  width: 34px;
  height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  color: #ffffff;
  background: linear-gradient(135deg, #f97316, #ef4444);
  font-weight: 900;
  box-shadow: 0 10px 24px rgba(239, 68, 68, 0.28);
}

.movie-card__body {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 16px;
  flex: 1;
}

.movie-card__tags span {
  color: var(--color-primary);
  background: #eff6ff;
  border-color: transparent;
  backdrop-filter: none;
}

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

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

.movie-card p {
  margin: 0;
  color: var(--color-muted);
  font-size: 14px;
}

.movie-card__actions {
  margin-top: auto;
  display: flex;
  gap: 10px;
}

.movie-card__actions a {
  flex: 1;
  min-height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  color: var(--color-primary);
  background: #eff6ff;
  font-size: 14px;
  font-weight: 800;
}

.movie-card__actions a:first-child {
  color: #ffffff;
  background: var(--color-primary);
}

.movie-card--compact .movie-card__poster {
  min-height: 180px;
}

.page-hero,
.watch-page {
  position: relative;
  overflow: hidden;
  padding: 52px;
  border-radius: 30px;
  color: #ffffff;
  background:
    radial-gradient(circle at 84% 12%, rgba(6, 182, 212, 0.32), transparent 34%),
    linear-gradient(135deg, #0f172a, #1e3a8a);
  box-shadow: 0 26px 60px rgba(15, 23, 42, 0.18);
}

.page-hero--compact h1 {
  font-size: clamp(30px, 5vw, 50px);
}

.page-hero--compact p {
  margin-bottom: 0;
}

.page-search {
  margin-top: 28px;
  max-width: 720px;
}

.filter-status {
  min-height: 24px;
  margin: -8px 0 18px;
  color: var(--color-muted);
  font-weight: 700;
}

.detail-hero {
  position: relative;
  min-height: 560px;
  overflow: hidden;
  color: #ffffff;
  background: #0f172a;
}

.detail-hero__backdrop {
  position: absolute;
  inset: 0;
}

.detail-hero__backdrop img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.36;
  filter: blur(1px);
}

.detail-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 74% 16%, rgba(6, 182, 212, 0.25), transparent 36%),
    linear-gradient(90deg, rgba(15, 23, 42, 0.95), rgba(15, 23, 42, 0.68), rgba(15, 23, 42, 0.44));
}

.detail-hero__inner {
  position: relative;
  z-index: 2;
  width: min(100% - 32px, var(--container));
  min-height: 560px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 280px 1fr;
  align-items: center;
  gap: 40px;
}

.detail-poster {
  aspect-ratio: 2 / 3;
  border-radius: 28px;
  box-shadow: 0 30px 70px rgba(0, 0, 0, 0.38);
}

.detail-info h1 {
  max-width: 760px;
}

.detail-tags span {
  border-color: rgba(255, 255, 255, 0.18);
}

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

.detail-main,
.detail-side,
.prose-page {
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  background: #ffffff;
  box-shadow: 0 16px 36px rgba(15, 23, 42, 0.06);
}

.detail-main,
.prose-page {
  padding: 30px;
}

.detail-main h2,
.detail-side h2,
.prose-page h2 {
  margin: 0 0 12px;
  font-size: 24px;
}

.detail-main p,
.prose-page p,
.prose-page li {
  color: #334155;
  font-size: 16px;
}

.detail-side {
  padding: 24px;
}

.detail-side dl {
  margin: 0;
  display: grid;
  gap: 14px;
}

.detail-side dl div {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--color-border);
}

.detail-side dt {
  color: var(--color-muted);
  font-weight: 700;
}

.detail-side dd {
  margin: 0;
  text-align: right;
  font-weight: 800;
}

.player-card {
  overflow: hidden;
  border: 1px solid rgba(15, 23, 42, 0.12);
  border-radius: 28px;
  background: #020617;
  box-shadow: 0 24px 60px rgba(15, 23, 42, 0.18);
}

.player-card--large {
  margin-top: 24px;
}

.player-shell {
  position: relative;
  aspect-ratio: 16 / 9;
  min-height: 280px;
  background:
    radial-gradient(circle at 70% 18%, rgba(37, 99, 235, 0.28), transparent 38%),
    #020617;
}

.player-shell video {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #020617;
}

.player-start {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  width: 86px;
  height: 86px;
  border: 0;
  border-radius: 999px;
  background: rgba(37, 99, 235, 0.92);
  box-shadow: 0 18px 48px rgba(37, 99, 235, 0.4);
  cursor: pointer;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.player-start:hover {
  transform: translate(-50%, -50%) scale(1.06);
}

.player-start span {
  display: block;
  width: 0;
  height: 0;
  margin-left: 32px;
  border-top: 17px solid transparent;
  border-bottom: 17px solid transparent;
  border-left: 25px solid #ffffff;
}

.player-card.is-playing .player-start {
  opacity: 0;
  pointer-events: none;
}

.player-message {
  margin: 0;
  padding: 14px 18px;
  color: #cbd5e1;
  background: rgba(15, 23, 42, 0.92);
  font-size: 14px;
}

.watch-page {
  margin-top: 28px;
}

.watch-title h1 {
  max-width: 900px;
}

.watch-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 16px;
}

.watch-meta a {
  color: #ffffff;
  background: rgba(37, 99, 235, 0.78);
}

.prose-page {
  max-width: 880px;
}

.prose-page a {
  color: var(--color-primary);
  font-weight: 800;
}

.site-footer {
  margin-top: 42px;
  color: #cbd5e1;
  background: #0f172a;
}

.footer-grid {
  width: min(100% - 32px, var(--container));
  margin: 0 auto;
  padding: 48px 0;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 28px;
}

.brand--footer .brand__text {
  color: #ffffff;
}

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

.site-footer p {
  max-width: 460px;
  color: #94a3b8;
}

.site-footer a:not(.brand) {
  display: block;
  margin: 8px 0;
  color: #cbd5e1;
}

.site-footer a:hover {
  color: #ffffff;
}

.footer-bottom {
  width: min(100% - 32px, var(--container));
  margin: 0 auto;
  padding: 18px 0 28px;
  display: flex;
  justify-content: space-between;
  gap: 18px;
  border-top: 1px solid rgba(148, 163, 184, 0.22);
  color: #94a3b8;
}

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

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

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

  .nav-toggle {
    display: block;
  }

  .hero-stage {
    min-height: 620px;
  }

  .hero-slide__content {
    padding-bottom: 110px;
  }

  .hero-dots {
    bottom: 136px;
  }

  .hero-search div,
  .page-search {
    grid-template-columns: 1fr;
  }

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

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

  .detail-hero__inner {
    grid-template-columns: 1fr;
    gap: 24px;
    padding: 48px 0;
  }

  .detail-poster {
    width: min(72vw, 260px);
  }

  .page-hero,
  .watch-page {
    padding: 34px 22px;
  }

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

@media (max-width: 560px) {
  .site-nav {
    width: min(100% - 20px, var(--container));
  }

  .brand__text {
    font-size: 19px;
  }

  .hero-stage {
    min-height: 640px;
  }

  .hero-slide__content,
  .intro-strip,
  .content-section,
  .page-hero,
  .watch-page,
  .detail-hero__inner {
    width: min(100% - 22px, var(--container));
  }

  .hero-search {
    width: min(100% - 22px, 980px);
    padding: 16px;
  }

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

  .detail-main,
  .prose-page {
    padding: 22px;
  }

  .player-shell {
    min-height: 220px;
  }
}
