:root {
  --bg: #f8fafc;
  --surface: #ffffff;
  --text: #111827;
  --muted: #64748b;
  --line: #e2e8f0;
  --brand: #2563eb;
  --brand-dark: #1d4ed8;
  --accent: #ef4444;
  --deep: #0f172a;
  --radius: 18px;
  --shadow: 0 18px 45px rgba(15, 23, 42, 0.12);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: Inter, "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
  line-height: 1.65;
}

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

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

button,
input,
select {
  font: inherit;
}

[hidden] {
  display: none !important;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.95);
  border-bottom: 1px solid rgba(226, 232, 240, 0.9);
  backdrop-filter: blur(18px);
  box-shadow: 0 8px 25px rgba(15, 23, 42, 0.06);
}

.header-inner {
  max-width: 1280px;
  height: 68px;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.site-logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 21px;
  font-weight: 800;
  color: var(--deep);
  letter-spacing: -0.03em;
  white-space: nowrap;
}

.logo-mark {
  width: 36px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  color: white;
  background: linear-gradient(135deg, var(--brand), #60a5fa);
  box-shadow: 0 12px 25px rgba(37, 99, 235, 0.28);
  font-size: 14px;
}

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

.nav-link {
  padding: 9px 13px;
  border-radius: 999px;
  color: #334155;
  font-size: 15px;
  font-weight: 650;
  transition: 0.2s ease;
}

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

.menu-button {
  display: none;
  border: 0;
  background: #eff6ff;
  color: var(--brand);
  width: 42px;
  height: 42px;
  border-radius: 12px;
  cursor: pointer;
}

.mobile-nav {
  display: none;
  padding: 0 24px 18px;
  border-top: 1px solid var(--line);
  background: white;
}

.mobile-nav.open {
  display: grid;
  gap: 8px;
}

.hero {
  position: relative;
  height: 560px;
  overflow: hidden;
  background: linear-gradient(135deg, #1e3a8a, #0f172a);
}

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

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

.hero-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(1.05);
}

.hero-shade {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(15, 23, 42, 0.9), rgba(15, 23, 42, 0.58), rgba(15, 23, 42, 0.16)),
    linear-gradient(0deg, rgba(15, 23, 42, 0.88), rgba(15, 23, 42, 0.05));
}

.hero-content {
  position: absolute;
  left: 50%;
  bottom: 78px;
  width: min(1180px, calc(100% - 48px));
  transform: translateX(-50%);
  color: white;
}

.hero-content h1 {
  max-width: 800px;
  margin: 0 0 18px;
  font-size: clamp(38px, 6vw, 72px);
  line-height: 1.05;
  font-weight: 900;
  letter-spacing: -0.06em;
}

.hero-content p {
  max-width: 720px;
  margin: 0 0 24px;
  color: #dbeafe;
  font-size: clamp(17px, 2vw, 21px);
}

.hero-kicker,
.hero-meta,
.hero-actions,
.tag-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}

.hero-kicker {
  margin-bottom: 16px;
}

.hero-kicker span,
.hero-kicker a,
.section-kicker {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 4px 12px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.02em;
}

.hero-kicker span {
  color: white;
  background: var(--accent);
}

.hero-kicker a {
  color: white;
  background: rgba(37, 99, 235, 0.92);
}

.hero-meta {
  margin-bottom: 28px;
  color: #cbd5e1;
}

.hero-meta span {
  padding: 6px 12px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.36);
}

.primary-btn,
.ghost-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 10px 20px;
  border-radius: 999px;
  font-weight: 800;
  transition: 0.2s ease;
}

.primary-btn {
  color: white;
  background: var(--brand);
  box-shadow: 0 16px 28px rgba(37, 99, 235, 0.25);
}

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

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

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

.hero-arrow {
  position: absolute;
  top: 50%;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 999px;
  color: white;
  background: rgba(15, 23, 42, 0.45);
  cursor: pointer;
  font-size: 34px;
  line-height: 1;
  transform: translateY(-50%);
  transition: 0.2s ease;
}

.hero-arrow:hover {
  background: rgba(15, 23, 42, 0.72);
}

.hero-prev {
  left: 24px;
}

.hero-next {
  right: 24px;
}

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

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

.hero-dot.is-active {
  width: 34px;
  background: white;
}

.page-shell {
  width: min(1280px, calc(100% - 48px));
  margin: 0 auto;
  padding: 48px 0 72px;
}

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

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

.section-title-row h2 {
  margin: 8px 0 0;
  font-size: clamp(26px, 3vw, 38px);
  line-height: 1.15;
  letter-spacing: -0.04em;
}

.section-kicker {
  color: var(--brand);
  background: #dbeafe;
}

.section-link {
  color: var(--brand);
  font-weight: 800;
  white-space: nowrap;
}

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

.movie-card {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(226, 232, 240, 0.95);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.06);
  transition: 0.2s ease;
}

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

.card-cover {
  position: relative;
  display: block;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: linear-gradient(135deg, #dbeafe, #e2e8f0);
}

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

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

.rank-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  min-width: 34px;
  height: 34px;
  padding: 0 9px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  color: white;
  background: rgba(239, 68, 68, 0.94);
  font-weight: 900;
}

.card-body {
  padding: 16px;
}

.card-title {
  display: -webkit-box;
  min-height: 52px;
  overflow: hidden;
  color: var(--deep);
  font-size: 18px;
  font-weight: 850;
  line-height: 1.45;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.card-title:hover {
  color: var(--brand);
}

.card-meta {
  margin: 8px 0 6px;
  color: var(--brand);
  font-size: 13px;
  font-weight: 750;
}

.card-desc {
  display: -webkit-box;
  min-height: 46px;
  margin: 0 0 12px;
  overflow: hidden;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.6;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.tag {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 3px 9px;
  border-radius: 999px;
  color: #1e40af;
  background: #eff6ff;
  font-size: 12px;
  font-weight: 750;
}

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

.category-card {
  padding: 18px;
  border: 1px solid rgba(226, 232, 240, 0.95);
  border-radius: 24px;
  background: white;
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.06);
  transition: 0.2s ease;
}

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

.category-covers {
  display: grid;
  grid-template-columns: 1.25fr 1fr 1fr;
  gap: 8px;
  height: 126px;
  overflow: hidden;
  border-radius: 18px;
  background: #eff6ff;
}

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

.category-covers img:first-child {
  grid-row: span 2;
}

.category-card h2 {
  margin: 16px 0 6px;
  font-size: 22px;
  letter-spacing: -0.03em;
}

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

.page-hero {
  position: relative;
  margin-bottom: 28px;
  padding: 44px;
  border-radius: 28px;
  overflow: hidden;
  color: white;
  background:
    radial-gradient(circle at top right, rgba(96, 165, 250, 0.5), transparent 36%),
    linear-gradient(135deg, #1e3a8a, #0f172a);
  box-shadow: var(--shadow);
}

.page-hero h1 {
  max-width: 840px;
  margin: 12px 0 12px;
  font-size: clamp(32px, 5vw, 56px);
  line-height: 1.12;
  letter-spacing: -0.05em;
}

.page-hero p {
  max-width: 760px;
  margin: 0;
  color: #dbeafe;
  font-size: 18px;
}

.small-hero .section-kicker {
  color: white;
  background: rgba(255, 255, 255, 0.18);
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-bottom: 18px;
  color: var(--muted);
  font-size: 14px;
}

.breadcrumb a {
  color: var(--brand);
  font-weight: 750;
}

.filter-panel {
  display: grid;
  grid-template-columns: 2fr repeat(3, 1fr);
  gap: 14px;
  margin: 0 0 26px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: white;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.05);
}

.filter-panel label {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 750;
}

.filter-panel input,
.filter-panel select {
  width: 100%;
  height: 46px;
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 0 14px;
  color: var(--text);
  background: #f8fafc;
  outline: none;
}

.filter-panel input:focus,
.filter-panel select:focus {
  border-color: #93c5fd;
  box-shadow: 0 0 0 4px rgba(147, 197, 253, 0.28);
}

.watch-panel {
  display: grid;
  grid-template-columns: minmax(0, 1.65fr) minmax(320px, 0.8fr);
  gap: 28px;
  align-items: stretch;
  margin-bottom: 34px;
}

.video-shell {
  position: relative;
  overflow: hidden;
  border-radius: 26px;
  background: #020617;
  box-shadow: var(--shadow);
  aspect-ratio: 16 / 9;
}

.video-player {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  background: #020617;
}

.play-layer {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 0;
  color: white;
  background: linear-gradient(0deg, rgba(2, 6, 23, 0.35), rgba(2, 6, 23, 0.08));
  cursor: pointer;
  transition: opacity 0.2s ease;
}

.play-layer span {
  width: 82px;
  height: 82px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: rgba(37, 99, 235, 0.94);
  box-shadow: 0 18px 38px rgba(37, 99, 235, 0.28);
  font-size: 28px;
  text-indent: 4px;
}

.video-shell.is-playing .play-layer {
  opacity: 0;
  pointer-events: none;
}

.watch-info {
  padding: 28px;
  border: 1px solid rgba(226, 232, 240, 0.9);
  border-radius: 26px;
  background: white;
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.06);
}

.watch-info h1 {
  margin: 14px 0 16px;
  font-size: clamp(30px, 4vw, 48px);
  line-height: 1.12;
  letter-spacing: -0.05em;
}

.watch-info p {
  margin: 0 0 18px;
  color: var(--muted);
  font-size: 17px;
}

.detail-tags {
  gap: 8px;
}

.detail-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 26px;
  margin-bottom: 56px;
}

.detail-main,
.detail-side {
  border: 1px solid rgba(226, 232, 240, 0.95);
  border-radius: 24px;
  background: white;
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.05);
}

.detail-main {
  padding: 28px;
}

.detail-main h2,
.detail-side h2 {
  margin: 0 0 16px;
  font-size: 24px;
  letter-spacing: -0.03em;
}

.detail-main h2:not(:first-child) {
  margin-top: 30px;
}

.detail-main p {
  margin: 0 0 16px;
  color: #334155;
  font-size: 17px;
}

.detail-side {
  padding: 24px;
  align-self: start;
  position: sticky;
  top: 92px;
}

.info-list {
  display: grid;
  gap: 12px;
  margin: 0 0 20px;
}

.info-list div {
  display: grid;
  grid-template-columns: 72px 1fr;
  gap: 10px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
}

.info-list dt {
  color: var(--muted);
  font-weight: 750;
}

.info-list dd {
  margin: 0;
  color: var(--text);
  font-weight: 650;
}

.full-btn {
  width: 100%;
}

.site-footer {
  color: #cbd5e1;
  background: #0f172a;
}

.footer-grid {
  width: min(1280px, calc(100% - 48px));
  margin: 0 auto;
  padding: 46px 0;
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 32px;
}

.site-footer h2,
.site-footer h3 {
  margin: 0 0 14px;
  color: white;
}

.site-footer p {
  margin: 0;
  color: #94a3b8;
}

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

.site-footer a:hover {
  color: white;
}

.footer-bottom {
  width: min(1280px, calc(100% - 48px));
  margin: 0 auto;
  padding: 18px 0 28px;
  border-top: 1px solid rgba(148, 163, 184, 0.18);
  color: #94a3b8;
  font-size: 14px;
}

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

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

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

  .detail-side {
    position: static;
  }
}

@media (max-width: 820px) {
  .header-inner {
    padding: 0 16px;
  }

  .site-nav {
    display: none;
  }

  .menu-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  .hero {
    height: 620px;
  }

  .hero-content {
    width: calc(100% - 32px);
    bottom: 70px;
  }

  .hero-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .hero-arrow {
    display: none;
  }

  .page-shell {
    width: calc(100% - 28px);
    padding-top: 32px;
  }

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

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

  .page-hero {
    padding: 28px;
  }
}

@media (max-width: 520px) {
  .movie-grid {
    gap: 16px;
  }

  .card-cover {
    aspect-ratio: 16 / 11;
  }

  .watch-info,
  .detail-main,
  .detail-side {
    padding: 20px;
  }

  .play-layer span {
    width: 66px;
    height: 66px;
    font-size: 22px;
  }
}
