:root {
  --site-blue: #2563eb;
  --site-blue-dark: #1d4ed8;
  --site-slate: #0f172a;
  --site-slate-soft: #1e293b;
  --site-bg: #f8fafc;
  --site-text: #111827;
  --site-muted: #64748b;
  --site-line: #e2e8f0;
  --site-card: #ffffff;
  --site-radius: 18px;
  --site-shadow: 0 18px 45px rgba(15, 23, 42, 0.12);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

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

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

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

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 60;
  color: #ffffff;
  background: linear-gradient(90deg, #0f172a 0%, #1e3a8a 50%, #0f172a 100%);
  box-shadow: 0 10px 30px rgba(15, 23, 42, 0.25);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 68px;
  gap: 18px;
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  letter-spacing: 0.02em;
  white-space: nowrap;
}

.logo-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 14px;
  background: linear-gradient(135deg, #60a5fa, #2563eb);
  box-shadow: 0 12px 30px rgba(37, 99, 235, 0.38);
  transition: transform 0.25s ease;
}

.logo:hover .logo-mark {
  transform: scale(1.08);
}

.logo-text {
  font-size: 20px;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 22px;
  font-size: 15px;
}

.site-nav a {
  color: rgba(255, 255, 255, 0.88);
  transition: color 0.2s ease;
}

.site-nav a:hover,
.site-nav a.is-active {
  color: #93c5fd;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.search-form {
  position: relative;
  display: flex;
  align-items: center;
}

.search-form input {
  width: 250px;
  height: 40px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 999px;
  padding: 0 44px 0 18px;
  background: rgba(255, 255, 255, 0.1);
  color: #ffffff;
  outline: none;
  backdrop-filter: blur(12px);
  transition: border-color 0.2s ease, background 0.2s ease;
}

.search-form input::placeholder {
  color: rgba(255, 255, 255, 0.68);
}

.search-form input:focus {
  border-color: #60a5fa;
  background: rgba(255, 255, 255, 0.16);
}

.search-form button {
  position: absolute;
  right: 5px;
  width: 32px;
  height: 32px;
  border: 0;
  border-radius: 50%;
  color: #ffffff;
  background: var(--site-blue);
  cursor: pointer;
}

.menu-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 12px;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.1);
  cursor: pointer;
}

.hero {
  position: relative;
  overflow: hidden;
  min-height: 620px;
  color: #ffffff;
  background: radial-gradient(circle at top left, rgba(59, 130, 246, 0.32), transparent 32%), linear-gradient(135deg, #0f172a 0%, #1e3a8a 48%, #0f172a 100%);
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  opacity: 0.14;
  background-image: radial-gradient(circle at 1px 1px, rgba(255, 255, 255, 0.55) 1px, transparent 0);
  background-size: 36px 36px;
}

.hero::after {
  content: "";
  position: absolute;
  inset: auto -10% -30% 35%;
  height: 360px;
  background: rgba(37, 99, 235, 0.34);
  filter: blur(90px);
  transform: rotate(-8deg);
}

.hero-stage {
  position: relative;
  z-index: 2;
  min-height: 620px;
  display: grid;
  align-items: center;
}

.hero-slide {
  display: none;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 460px);
  gap: 48px;
  align-items: center;
  padding: 72px 0;
}

.hero-slide.is-active {
  display: grid;
  animation: heroFade 0.6s ease both;
}

@keyframes heroFade {
  from {
    opacity: 0;
    transform: translateY(14px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.hero-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 18px;
  padding: 7px 12px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.1);
  color: #bfdbfe;
  font-size: 14px;
  backdrop-filter: blur(10px);
}

.hero h1 {
  margin: 0 0 20px;
  font-size: clamp(38px, 6vw, 68px);
  line-height: 1.08;
  letter-spacing: -0.05em;
}

.hero p {
  max-width: 680px;
  margin: 0 0 28px;
  color: #dbeafe;
  font-size: clamp(17px, 2vw, 23px);
}

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

.hero-tag,
.badge,
.movie-tag {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(37, 99, 235, 0.12);
  color: #2563eb;
  font-size: 13px;
  font-weight: 700;
}

.hero-tag {
  background: rgba(255, 255, 255, 0.12);
  color: #ffffff;
}

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

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 0 22px;
  border-radius: 999px;
  border: 1px solid transparent;
  font-weight: 800;
  transition: transform 0.2s ease, background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

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

.btn-primary {
  color: #ffffff;
  background: var(--site-blue);
  box-shadow: 0 16px 30px rgba(37, 99, 235, 0.34);
}

.btn-primary:hover {
  background: var(--site-blue-dark);
}

.btn-ghost {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.22);
  backdrop-filter: blur(8px);
}

.hero-card {
  position: relative;
  overflow: hidden;
  border-radius: 26px;
  background: rgba(255, 255, 255, 0.1);
  box-shadow: 0 30px 80px rgba(2, 6, 23, 0.44);
  transform: perspective(1000px) rotateY(-6deg) rotateX(2deg);
}

.hero-card img {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  background: #0f172a;
}

.hero-card-info {
  position: absolute;
  inset: auto 16px 16px 16px;
  padding: 16px;
  border-radius: 20px;
  color: #ffffff;
  background: rgba(15, 23, 42, 0.72);
  backdrop-filter: blur(14px);
}

.hero-card-info strong {
  display: block;
  margin-bottom: 4px;
  font-size: 18px;
}

.hero-dots {
  position: absolute;
  z-index: 5;
  left: max(16px, calc((100% - 1200px) / 2));
  bottom: 34px;
  display: flex;
  gap: 8px;
}

.hero-dot {
  width: 30px;
  height: 8px;
  border: 0;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.32);
  cursor: pointer;
}

.hero-dot.is-active {
  background: #60a5fa;
}

.section {
  padding: 56px 0;
}

.section-sm {
  padding: 34px 0;
}

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

.section-title {
  margin: 0;
  font-size: clamp(26px, 3vw, 36px);
  line-height: 1.2;
  letter-spacing: -0.03em;
}

.section-desc {
  margin: 8px 0 0;
  color: var(--site-muted);
}

.link-more {
  color: var(--site-blue);
  font-weight: 800;
  white-space: nowrap;
}

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

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

.movie-card {
  display: block;
  overflow: hidden;
  border-radius: var(--site-radius);
  background: var(--site-card);
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.08);
  transition: transform 0.28s ease, box-shadow 0.28s ease;
}

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

.poster {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16 / 9;
  background: #0f172a;
}

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

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

.poster::after {
  content: "";
  position: absolute;
  inset: 0;
  opacity: 0;
  background: linear-gradient(180deg, transparent 30%, rgba(15, 23, 42, 0.78));
  transition: opacity 0.25s ease;
}

.movie-card:hover .poster::after {
  opacity: 1;
}

.play-pill {
  position: absolute;
  z-index: 2;
  left: 50%;
  top: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 58px;
  height: 58px;
  border-radius: 50%;
  background: var(--site-blue);
  color: #ffffff;
  opacity: 0;
  transform: translate(-50%, -50%) scale(0.72);
  transition: opacity 0.25s ease, transform 0.25s ease;
}

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

.card-label,
.card-year {
  position: absolute;
  z-index: 3;
  top: 12px;
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 4px 10px;
  border-radius: 999px;
  color: #ffffff;
  font-size: 12px;
  font-weight: 800;
}

.card-label {
  left: 12px;
  background: var(--site-blue);
}

.card-year {
  right: 12px;
  background: rgba(15, 23, 42, 0.74);
}

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

.movie-card h3 {
  margin: 0 0 10px;
  min-height: 48px;
  color: #111827;
  font-size: 17px;
  line-height: 1.35;
  transition: color 0.2s ease;
}

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

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

.card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: #64748b;
  font-size: 13px;
}

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

.category-card {
  display: block;
  min-height: 172px;
  padding: 24px;
  border-radius: 22px;
  color: #ffffff;
  background: linear-gradient(135deg, #1e3a8a, #2563eb 55%, #7c3aed);
  box-shadow: 0 16px 36px rgba(37, 99, 235, 0.18);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.category-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 20px 44px rgba(37, 99, 235, 0.26);
}

.category-card h3 {
  margin: 0 0 10px;
  font-size: 22px;
}

.category-card p {
  margin: 0;
  color: #dbeafe;
}

.page-hero {
  color: #ffffff;
  background: linear-gradient(135deg, #1d4ed8, #1e3a8a);
  padding: 54px 0;
}

.page-hero h1 {
  margin: 0 0 12px;
  font-size: clamp(32px, 4vw, 48px);
  letter-spacing: -0.03em;
}

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

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  padding: 14px 0;
  color: #64748b;
  font-size: 14px;
}

.breadcrumb a:hover {
  color: var(--site-blue);
}

.layout {
  display: grid;
  grid-template-columns: 250px minmax(0, 1fr);
  gap: 28px;
}

.sidebar-card,
.panel {
  border-radius: 20px;
  background: #ffffff;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.08);
}

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

.sidebar-card h2 {
  margin: 0 0 14px;
  font-size: 18px;
}

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

.side-links a {
  padding: 10px 12px;
  border-radius: 12px;
  color: #475569;
  font-weight: 700;
}

.side-links a:hover,
.side-links a.is-active {
  color: #ffffff;
  background: var(--site-blue);
}

.filter-bar {
  display: flex;
  gap: 12px;
  align-items: center;
  margin-bottom: 22px;
  padding: 16px;
  border-radius: 18px;
  background: #ffffff;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.07);
}

.filter-bar input {
  flex: 1;
  min-width: 0;
  height: 44px;
  border: 1px solid var(--site-line);
  border-radius: 999px;
  padding: 0 18px;
  outline: none;
}

.filter-bar input:focus {
  border-color: var(--site-blue);
}

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

.ranking-item {
  display: grid;
  grid-template-columns: 58px 180px minmax(0, 1fr);
  gap: 18px;
  align-items: center;
  padding: 16px;
  border-radius: 20px;
  background: #ffffff;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.07);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.ranking-item:hover {
  transform: translateY(-3px);
  box-shadow: var(--site-shadow);
}

.rank-number {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  border-radius: 16px;
  color: #ffffff;
  background: linear-gradient(135deg, #2563eb, #7c3aed);
  font-size: 20px;
  font-weight: 900;
}

.ranking-thumb {
  overflow: hidden;
  border-radius: 16px;
  aspect-ratio: 16 / 9;
  background: #0f172a;
}

.ranking-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.ranking-content h2 {
  margin: 0 0 8px;
  font-size: 20px;
}

.ranking-content p {
  margin: 0 0 10px;
  color: #64748b;
}

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

.player-box {
  overflow: hidden;
  border-radius: 22px;
  background: #000000;
  box-shadow: 0 24px 60px rgba(15, 23, 42, 0.28);
}

.player-frame {
  position: relative;
  aspect-ratio: 16 / 9;
  background: #000000;
  cursor: pointer;
}

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

.player-cover {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.22), rgba(15, 23, 42, 0.72));
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

.player-box.is-playing .player-cover,
.player-box.is-ready .player-cover {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.play-button {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 86px;
  height: 86px;
  border: 0;
  border-radius: 50%;
  color: #ffffff;
  background: var(--site-blue);
  box-shadow: 0 20px 44px rgba(37, 99, 235, 0.35);
  cursor: pointer;
  transition: transform 0.2s ease, background 0.2s ease;
}

.play-button:hover {
  background: var(--site-blue-dark);
  transform: scale(1.06);
}

.detail-main {
  margin-top: 22px;
}

.detail-title {
  margin: 0 0 14px;
  font-size: clamp(30px, 4vw, 46px);
  line-height: 1.18;
  letter-spacing: -0.04em;
}

.detail-lead {
  margin: 18px 0 0;
  color: #334155;
  font-size: 19px;
}

.content-panel {
  margin-top: 22px;
  padding: 26px;
  border-radius: 22px;
  background: #ffffff;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.07);
}

.content-panel h2 {
  margin: 0 0 14px;
  font-size: 24px;
}

.content-panel p {
  margin: 0;
  color: #334155;
}

.detail-side {
  display: grid;
  gap: 18px;
}

.cover-panel {
  overflow: hidden;
  border-radius: 22px;
  background: #ffffff;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.08);
}

.cover-panel img {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  background: #0f172a;
}

.cover-panel-body {
  padding: 18px;
}

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

.info-list div {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--site-line);
}

.info-list dt {
  color: #64748b;
}

.info-list dd {
  margin: 0;
  color: #111827;
  font-weight: 800;
  text-align: right;
}

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

.related-item {
  display: grid;
  grid-template-columns: 96px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
}

.related-item img {
  width: 96px;
  aspect-ratio: 16 / 9;
  border-radius: 12px;
  object-fit: cover;
  background: #0f172a;
}

.related-item strong {
  display: block;
  margin-bottom: 4px;
  color: #111827;
  line-height: 1.35;
}

.related-item span {
  color: #64748b;
  font-size: 13px;
}

.site-footer {
  margin-top: 56px;
  color: #cbd5e1;
  background: linear-gradient(180deg, #0f172a, #020617);
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 30px;
  padding: 44px 0;
}

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

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

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

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

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

.empty-result {
  display: none;
  padding: 42px;
  border-radius: 22px;
  background: #ffffff;
  color: #64748b;
  text-align: center;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.07);
}

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

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

  .hero-card {
    max-width: 560px;
    transform: none;
  }

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

  .sidebar-card {
    position: static;
  }

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

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

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

  .site-nav {
    display: none;
    order: 4;
    width: 100%;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 12px 0 4px;
    border-top: 1px solid rgba(255, 255, 255, 0.12);
  }

  .site-nav.is-open {
    display: flex;
  }

  .site-nav a {
    padding: 10px 0;
  }

  .header-actions {
    width: 100%;
    order: 3;
  }

  .search-form {
    width: 100%;
  }

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

  .hero,
  .hero-stage {
    min-height: auto;
  }

  .hero-slide {
    padding: 46px 0 72px;
  }

  .hero-dots {
    left: 16px;
    bottom: 24px;
  }

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

  .ranking-item {
    grid-template-columns: 42px 120px minmax(0, 1fr);
    gap: 12px;
  }

  .rank-number {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    font-size: 16px;
  }
}

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

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

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

  .section-head,
  .filter-bar {
    align-items: stretch;
    flex-direction: column;
  }

  .ranking-item {
    grid-template-columns: 42px minmax(0, 1fr);
  }

  .ranking-thumb {
    grid-column: 1 / -1;
    order: -1;
  }

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

  .related-item {
    grid-template-columns: 84px minmax(0, 1fr);
  }

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