:root {
  color-scheme: light;
  --site-blue: #0284c7;
  --site-blue-dark: #0369a1;
  --site-blue-soft: #e0f2fe;
  --site-slate: #0f172a;
  --site-muted: #64748b;
  --site-card: #ffffff;
  --site-line: #e2e8f0;
  --site-shadow: 0 20px 45px rgba(15, 23, 42, 0.12);
}

* {
  box-sizing: border-box;
}

body {
  min-height: 100vh;
  margin: 0;
  background: linear-gradient(180deg, #f8fafc 0%, #ffffff 45%, #f8fafc 100%);
  color: var(--site-slate);
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
}

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

img {
  max-width: 100%;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: linear-gradient(90deg, #0284c7 0%, #2563eb 100%);
  color: #ffffff;
  box-shadow: 0 12px 30px rgba(2, 132, 199, 0.22);
}

.header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 72px;
  gap: 24px;
}

.logo-link {
  display: flex;
  align-items: center;
  min-width: 210px;
  gap: 10px;
}

.logo-mark {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.16);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.24);
}

.logo-title {
  display: block;
  font-size: 20px;
  font-weight: 800;
  line-height: 1.1;
}

.logo-subtitle {
  display: block;
  margin-top: 3px;
  font-size: 12px;
  opacity: 0.88;
}

.primary-nav {
  display: flex;
  align-items: center;
  gap: 22px;
  font-weight: 600;
}

.primary-nav a {
  opacity: 0.94;
  transition: color 0.2s ease, opacity 0.2s ease;
}

.primary-nav a:hover {
  color: #bae6fd;
  opacity: 1;
}

.header-search {
  position: relative;
  width: min(280px, 24vw);
}

.header-search input,
.page-search input,
.filter-select {
  width: 100%;
  border: 0;
  outline: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
  color: #ffffff;
  padding: 11px 16px;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.16);
}

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

.mobile-menu-button {
  display: none;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.12);
  color: #ffffff;
  font-size: 24px;
}

.mobile-panel {
  display: none;
  border-top: 1px solid rgba(255, 255, 255, 0.22);
  padding: 14px 0 18px;
}

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

.mobile-panel nav {
  display: grid;
  gap: 8px;
  margin-top: 12px;
}

.mobile-panel a {
  padding: 10px 12px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.08);
}

.hero {
  position: relative;
  overflow: hidden;
  color: #ffffff;
  background: linear-gradient(110deg, #0284c7 0%, #2563eb 50%, #1d4ed8 100%);
}

.hero::before,
.hero::after {
  position: absolute;
  content: "";
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.13);
  filter: blur(42px);
}

.hero::before {
  top: 34px;
  left: 7%;
  width: 260px;
  height: 260px;
}

.hero::after {
  right: 6%;
  bottom: 18px;
  width: 390px;
  height: 390px;
}

.hero-inner {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(340px, 0.78fr);
  align-items: center;
  gap: 44px;
  min-height: 560px;
  padding: 72px 0;
}

.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 18px;
  padding: 8px 14px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.14);
  color: #dbeafe;
  font-weight: 700;
}

.hero-title {
  max-width: 760px;
  font-size: clamp(38px, 6vw, 68px);
  font-weight: 900;
  line-height: 1.04;
  letter-spacing: -0.05em;
}

.hero-desc {
  max-width: 720px;
  margin: 22px 0 30px;
  color: #dbeafe;
  font-size: clamp(17px, 2vw, 21px);
  line-height: 1.85;
}

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

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

.button-primary {
  background: #ffffff;
  color: var(--site-blue-dark);
  box-shadow: 0 16px 28px rgba(15, 23, 42, 0.16);
}

.button-secondary {
  background: rgba(255, 255, 255, 0.12);
  color: #ffffff;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.28);
}

.button-soft {
  background: var(--site-blue-soft);
  color: var(--site-blue-dark);
}

.button-primary:hover,
.button-secondary:hover,
.button-soft:hover {
  transform: translateY(-2px) scale(1.02);
}

.hero-stage {
  position: relative;
  min-height: 430px;
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: grid;
  align-items: end;
  overflow: hidden;
  border-radius: 32px;
  background: #0f172a;
  opacity: 0;
  transform: scale(0.985) translateY(8px);
  box-shadow: var(--site-shadow);
  transition: opacity 0.42s ease, transform 0.42s ease;
  pointer-events: none;
}

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

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

.hero-slide::after {
  position: absolute;
  inset: 0;
  content: "";
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.08) 0%, rgba(15, 23, 42, 0.78) 100%);
}

.hero-slide-content {
  position: relative;
  z-index: 1;
  padding: 28px;
}

.hero-slide-content h2 {
  margin: 10px 0;
  font-size: 28px;
  font-weight: 900;
  line-height: 1.2;
}

.hero-slide-content p {
  display: -webkit-box;
  color: #e0f2fe;
  line-height: 1.7;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
}

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

.hero-tag,
.meta-pill,
.card-tag {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
}

.hero-tag {
  padding: 6px 10px;
  background: rgba(255, 255, 255, 0.18);
  color: #ffffff;
}

.hero-controls {
  position: absolute;
  right: 22px;
  bottom: 20px;
  z-index: 3;
  display: flex;
  gap: 8px;
}

.hero-dot {
  width: 10px;
  height: 10px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.45);
}

.hero-dot.is-active {
  width: 28px;
  background: #ffffff;
}

.section {
  padding: 58px 0;
}

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

.section-kicker {
  color: var(--site-blue);
  font-size: 14px;
  font-weight: 900;
  letter-spacing: 0.08em;
}

.section-title {
  margin-top: 6px;
  color: var(--site-slate);
  font-size: clamp(28px, 4vw, 40px);
  font-weight: 900;
  line-height: 1.15;
}

.section-desc {
  max-width: 720px;
  margin-top: 12px;
  color: var(--site-muted);
  line-height: 1.85;
}

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

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

.movie-card {
  position: relative;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border-radius: 22px;
  background: var(--site-card);
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.08);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 24px 46px rgba(15, 23, 42, 0.16);
}

.movie-cover {
  position: relative;
  overflow: hidden;
  aspect-ratio: 3 / 4;
  background: linear-gradient(135deg, #0f172a, #1e40af);
}

.movie-card.horizontal {
  display: grid;
  grid-template-columns: 120px minmax(0, 1fr);
}

.movie-card.horizontal .movie-cover {
  height: 100%;
  min-height: 160px;
  aspect-ratio: auto;
}

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

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

.movie-cover::after {
  position: absolute;
  inset: auto 0 0 0;
  height: 48%;
  content: "";
  background: linear-gradient(180deg, transparent, rgba(15, 23, 42, 0.82));
}

.cover-badge,
.rank-badge {
  position: absolute;
  z-index: 2;
  border-radius: 999px;
  color: #ffffff;
  font-size: 12px;
  font-weight: 900;
}

.cover-badge {
  right: 12px;
  bottom: 12px;
  padding: 5px 9px;
  background: rgba(15, 23, 42, 0.72);
}

.rank-badge {
  top: 12px;
  left: 12px;
  padding: 6px 10px;
  background: linear-gradient(90deg, #0284c7, #2563eb);
  box-shadow: 0 8px 18px rgba(2, 132, 199, 0.28);
}

.movie-body {
  display: flex;
  flex: 1;
  flex-direction: column;
  padding: 16px;
}

.movie-category {
  align-self: flex-start;
  margin-bottom: 10px;
  padding: 5px 9px;
  border-radius: 8px;
  background: var(--site-blue-soft);
  color: var(--site-blue-dark);
  font-size: 12px;
  font-weight: 900;
}

.movie-title {
  display: -webkit-box;
  min-height: 48px;
  margin: 0 0 8px;
  color: var(--site-slate);
  font-size: 18px;
  font-weight: 900;
  line-height: 1.35;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
}

.movie-desc {
  display: -webkit-box;
  margin: 0 0 14px;
  color: var(--site-muted);
  font-size: 14px;
  line-height: 1.65;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
}

.movie-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-top: auto;
  color: #64748b;
  font-size: 12px;
}

.meta-pill {
  padding: 5px 9px;
  background: #f1f5f9;
  color: #475569;
}

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

.category-card {
  display: block;
  min-height: 168px;
  border-radius: 24px;
  background: #ffffff;
  padding: 24px;
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.08);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.category-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 24px 46px rgba(15, 23, 42, 0.14);
}

.category-icon {
  display: grid;
  width: 54px;
  height: 54px;
  margin-bottom: 16px;
  place-items: center;
  border-radius: 50%;
  background: linear-gradient(135deg, #38bdf8, #2563eb);
  color: #ffffff;
  font-size: 24px;
}

.category-card h2,
.category-card h3 {
  margin: 0 0 8px;
  color: var(--site-slate);
  font-size: 20px;
  font-weight: 900;
}

.category-card p {
  margin: 0;
  color: var(--site-muted);
  font-size: 14px;
  line-height: 1.7;
}

.page-hero {
  padding: 54px 0;
  color: #ffffff;
  background: linear-gradient(90deg, #0284c7, #2563eb);
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 18px;
  color: rgba(255, 255, 255, 0.78);
  font-size: 14px;
}

.breadcrumb a:hover {
  color: #ffffff;
}

.page-title {
  margin: 0;
  font-size: clamp(34px, 5vw, 54px);
  font-weight: 900;
  line-height: 1.12;
}

.page-desc {
  max-width: 760px;
  margin: 16px 0 0;
  color: #dbeafe;
  font-size: 18px;
  line-height: 1.85;
}

.filter-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 26px;
  border-radius: 24px;
  background: #ffffff;
  padding: 16px;
  box-shadow: 0 12px 32px rgba(15, 23, 42, 0.08);
}

.page-search {
  position: relative;
  flex: 1 1 320px;
}

.page-search input {
  background: #f1f5f9;
  color: var(--site-slate);
  box-shadow: inset 0 0 0 1px #e2e8f0;
}

.page-search input::placeholder {
  color: #94a3b8;
}

.filter-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.filter-button {
  border: 0;
  border-radius: 999px;
  background: #e0f2fe;
  color: #0369a1;
  padding: 10px 16px;
  font-weight: 900;
}

.filter-button.is-active,
.filter-button:hover {
  background: #0284c7;
  color: #ffffff;
}

.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 30px;
  padding-top: 34px;
}

.player-card,
.detail-card,
.side-card {
  overflow: hidden;
  border-radius: 26px;
  background: #ffffff;
  box-shadow: 0 14px 36px rgba(15, 23, 42, 0.1);
}

.player-wrap {
  position: relative;
  aspect-ratio: 16 / 9;
  background: #020617;
}

.player-wrap video {
  width: 100%;
  height: 100%;
  background: #020617;
}

.player-overlay {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: grid;
  place-items: center;
  border: 0;
  background: linear-gradient(180deg, rgba(2, 6, 23, 0.18), rgba(2, 6, 23, 0.64));
  color: #ffffff;
  cursor: pointer;
}

.player-overlay.is-hidden {
  display: none;
}

.play-ring {
  display: grid;
  width: 86px;
  height: 86px;
  place-items: center;
  border-radius: 50%;
  background: #0284c7;
  box-shadow: 0 18px 42px rgba(2, 132, 199, 0.38);
  font-size: 34px;
  transition: transform 0.2s ease, background 0.2s ease;
}

.player-overlay:hover .play-ring {
  transform: scale(1.08);
  background: #2563eb;
}

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

.detail-label {
  display: inline-flex;
  margin-bottom: 18px;
  border-radius: 999px;
  background: var(--site-blue-soft);
  color: var(--site-blue-dark);
  padding: 8px 14px;
  font-weight: 900;
}

.detail-title {
  margin: 0 0 16px;
  color: var(--site-slate);
  font-size: clamp(30px, 4vw, 46px);
  font-weight: 900;
  line-height: 1.15;
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 24px;
  padding-bottom: 22px;
  border-bottom: 1px solid var(--site-line);
}

.detail-section {
  margin-top: 26px;
}

.detail-section h2 {
  margin: 0 0 12px;
  color: var(--site-slate);
  font-size: 24px;
  font-weight: 900;
}

.detail-section p {
  margin: 0;
  color: #475569;
  font-size: 16px;
  line-height: 1.95;
  white-space: pre-line;
}

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

.card-tag {
  padding: 7px 10px;
  background: #f1f5f9;
  color: #475569;
}

.side-card {
  position: sticky;
  top: 96px;
  padding: 20px;
}

.side-card h2 {
  margin: 0 0 16px;
  font-size: 22px;
  font-weight: 900;
}

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

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

.cta-panel {
  border-radius: 30px;
  background: linear-gradient(90deg, #0284c7, #2563eb);
  padding: 48px;
  color: #ffffff;
  text-align: center;
  box-shadow: var(--site-shadow);
}

.cta-panel h2 {
  margin: 0 0 12px;
  font-size: clamp(28px, 4vw, 42px);
  font-weight: 900;
}

.cta-panel p {
  max-width: 680px;
  margin: 0 auto 24px;
  color: #dbeafe;
  line-height: 1.85;
}

.empty-message {
  display: none;
  border-radius: 24px;
  background: #ffffff;
  padding: 38px;
  color: #64748b;
  text-align: center;
  box-shadow: 0 12px 32px rgba(15, 23, 42, 0.08);
}

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

.site-footer {
  margin-top: 70px;
  background: linear-gradient(180deg, #1e293b, #0f172a);
  color: #ffffff;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr repeat(3, 1fr);
  gap: 34px;
  padding: 48px 0;
}

.footer-title {
  margin-bottom: 12px;
  color: #38bdf8;
  font-size: 18px;
  font-weight: 900;
}

.footer-text,
.footer-links a {
  color: #cbd5e1;
  font-size: 14px;
  line-height: 1.8;
}

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

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

.footer-bottom {
  border-top: 1px solid rgba(148, 163, 184, 0.22);
  padding: 18px 0;
  color: #94a3b8;
  font-size: 13px;
  text-align: center;
}

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

  .mobile-menu-button {
    display: inline-grid;
    place-items: center;
  }

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

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

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

  .side-card {
    position: static;
  }

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

@media (max-width: 720px) {
  .site-shell {
    width: min(100% - 22px, 1180px);
  }

  .logo-link {
    min-width: 0;
  }

  .logo-title {
    font-size: 18px;
  }

  .logo-subtitle {
    display: none;
  }

  .hero-inner {
    min-height: auto;
    padding: 46px 0;
  }

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

  .hero-slide-content {
    padding: 22px;
  }

  .section {
    padding: 42px 0;
  }

  .section-header,
  .filter-bar {
    align-items: flex-start;
    flex-direction: column;
  }

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

  .movie-card.horizontal {
    grid-template-columns: 92px minmax(0, 1fr);
  }

  .movie-card.horizontal .movie-cover {
    min-height: 138px;
  }

  .movie-title {
    min-height: auto;
    font-size: 16px;
  }

  .movie-desc {
    font-size: 13px;
  }

  .detail-card {
    padding: 20px;
  }

  .cta-panel {
    padding: 32px 20px;
  }

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