* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background: linear-gradient(135deg, #f8fafc 0%, #eff6ff 44%, #ecfeff 100%);
  color: #0f172a;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
}

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

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(18px);
  box-shadow: 0 18px 40px rgba(30, 64, 175, 0.12);
}

.header-inner,
.quick-nav,
.footer-inner,
.section-inner {
  width: min(1800px, calc(100% - 32px));
  margin: 0 auto;
}

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

.brand,
.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
}

.brand-mark {
  width: 46px;
  height: 46px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 16px;
  background: linear-gradient(135deg, #2563eb, #06b6d4);
  color: #ffffff;
  font-size: 18px;
  font-weight: 900;
  box-shadow: 0 16px 30px rgba(37, 99, 235, 0.32);
}

.brand-text strong,
.footer-brand strong {
  display: block;
  font-size: 24px;
  line-height: 1.05;
  letter-spacing: -0.04em;
  background: linear-gradient(135deg, #2563eb, #06b6d4);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.brand-text em {
  display: block;
  margin-top: 4px;
  color: #64748b;
  font-size: 12px;
  font-style: normal;
}

.desktop-nav,
.mobile-nav,
.quick-nav,
.footer-links {
  display: flex;
  align-items: center;
  gap: 10px;
}

.nav-link {
  padding: 12px 20px;
  border-radius: 999px;
  color: #334155;
  font-size: 15px;
  font-weight: 700;
  transition: background 0.25s ease, color 0.25s ease, transform 0.25s ease;
}

.nav-link:hover,
.nav-link.is-active {
  color: #ffffff;
  background: linear-gradient(135deg, #2563eb, #06b6d4);
  transform: translateY(-1px);
  box-shadow: 0 14px 26px rgba(37, 99, 235, 0.24);
}

.menu-button {
  display: none;
  border: 0;
  border-radius: 14px;
  padding: 10px 12px;
  background: #eff6ff;
  color: #1d4ed8;
  font-size: 22px;
  cursor: pointer;
}

.mobile-nav {
  display: none;
  width: min(1800px, calc(100% - 32px));
  margin: 0 auto;
  padding: 0 0 16px;
  flex-direction: column;
  align-items: stretch;
}

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

.quick-nav {
  padding: 0 0 14px;
  overflow-x: auto;
}

.quick-nav a,
.footer-links a {
  flex: 0 0 auto;
  color: #2563eb;
  font-weight: 700;
  font-size: 14px;
}

.hero-wall {
  width: min(1800px, calc(100% - 28px));
  margin: 18px auto 0;
  min-height: 82vh;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.hero-card {
  position: relative;
  min-height: 640px;
  border-radius: 30px;
  overflow: hidden;
  box-shadow: 0 28px 70px rgba(15, 23, 42, 0.28);
  background: #0f172a;
  isolation: isolate;
}

.hero-card img,
.poster-frame img,
.detail-poster img,
.rank-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-card img {
  position: absolute;
  inset: 0;
  z-index: -3;
  transition: transform 0.8s ease;
}

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

.hero-card::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -2;
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.08), rgba(15, 23, 42, 0.92));
}

.hero-card::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: radial-gradient(circle at 20% 20%, rgba(34, 211, 238, 0.28), transparent 34%);
}

.hero-content {
  min-height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 40px;
  color: #ffffff;
}

.hero-kicker,
.section-kicker,
.detail-kicker {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  gap: 8px;
  border-radius: 999px;
  padding: 8px 12px;
  background: rgba(250, 204, 21, 0.16);
  color: #facc15;
  font-size: 14px;
  font-weight: 800;
}

.hero-content h1,
.hero-content h2 {
  margin: 18px 0 14px;
  font-size: clamp(32px, 4vw, 58px);
  line-height: 1.05;
  letter-spacing: -0.06em;
}

.hero-content p {
  max-width: 580px;
  margin: 0 0 24px;
  color: rgba(255, 255, 255, 0.84);
  font-size: 16px;
  line-height: 1.8;
}

.hero-actions,
.detail-actions,
.search-panel {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
}

.btn-primary,
.btn-ghost,
.search-panel button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  border: 0;
  border-radius: 999px;
  padding: 0 22px;
  font-size: 15px;
  font-weight: 800;
  cursor: pointer;
}

.btn-primary,
.search-panel button {
  background: linear-gradient(135deg, #2563eb, #06b6d4);
  color: #ffffff;
  box-shadow: 0 16px 30px rgba(37, 99, 235, 0.3);
}

.btn-ghost {
  border: 1px solid rgba(255, 255, 255, 0.34);
  background: rgba(255, 255, 255, 0.14);
  color: #ffffff;
  backdrop-filter: blur(12px);
}

.section {
  padding: 72px 0;
}

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

.section-title {
  margin: 12px 0 0;
  color: #0f172a;
  font-size: clamp(28px, 3vw, 44px);
  line-height: 1.1;
  letter-spacing: -0.05em;
}

.section-text {
  max-width: 820px;
  margin: 12px 0 0;
  color: #475569;
  font-size: 16px;
  line-height: 1.8;
}

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

.movie-card {
  min-width: 0;
}

.movie-card a {
  display: flex;
  height: 100%;
  flex-direction: column;
  overflow: hidden;
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 16px 32px rgba(15, 23, 42, 0.11);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.movie-card a:hover {
  transform: translateY(-8px);
  box-shadow: 0 28px 55px rgba(30, 64, 175, 0.18);
}

.poster-frame {
  position: relative;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  background: linear-gradient(135deg, #dbeafe, #cffafe);
}

.poster-frame img {
  transition: transform 0.5s ease;
}

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

.poster-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 42%, rgba(15, 23, 42, 0.72));
  opacity: 0;
  transition: opacity 0.3s ease;
}

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

.play-dot {
  position: absolute;
  right: 14px;
  bottom: 14px;
  width: 44px;
  height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.9);
  color: #2563eb;
  font-weight: 900;
  transform: scale(0.86);
  opacity: 0;
  transition: opacity 0.3s ease, transform 0.3s ease;
}

.movie-card a:hover .play-dot {
  opacity: 1;
  transform: scale(1);
}

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

.card-meta {
  color: #2563eb;
  font-size: 12px;
  font-weight: 800;
}

.card-body strong {
  display: -webkit-box;
  min-height: 48px;
  overflow: hidden;
  color: #0f172a;
  font-size: 18px;
  line-height: 1.35;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.card-summary {
  display: -webkit-box;
  overflow: hidden;
  color: #64748b;
  font-size: 14px;
  line-height: 1.6;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: auto;
}

.tag-row span,
.meta-pill {
  border-radius: 999px;
  padding: 5px 9px;
  background: #eff6ff;
  color: #2563eb;
  font-size: 12px;
  font-weight: 800;
}

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

.category-card {
  position: relative;
  min-height: 210px;
  overflow: hidden;
  border-radius: 26px;
  padding: 24px;
  background: linear-gradient(135deg, #1d4ed8, #06b6d4);
  color: #ffffff;
  box-shadow: 0 22px 46px rgba(37, 99, 235, 0.22);
}

.category-card::after {
  content: "";
  position: absolute;
  right: -42px;
  bottom: -42px;
  width: 150px;
  height: 150px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.16);
}

.category-card strong {
  position: relative;
  z-index: 1;
  display: block;
  margin-bottom: 12px;
  font-size: 24px;
}

.category-card p {
  position: relative;
  z-index: 1;
  margin: 0;
  color: rgba(255, 255, 255, 0.86);
  line-height: 1.7;
}

.rank-layout {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 24px;
}

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

.rank-item {
  display: grid;
  grid-template-columns: 52px 76px 1fr;
  align-items: center;
  gap: 14px;
  border-radius: 20px;
  padding: 12px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 14px 30px rgba(15, 23, 42, 0.1);
}

.rank-number {
  color: #f97316;
  font-size: 28px;
  font-weight: 900;
  text-align: center;
}

.rank-item img {
  aspect-ratio: 3 / 4;
  border-radius: 14px;
}

.rank-item strong {
  display: block;
  margin-bottom: 6px;
  font-size: 18px;
}

.rank-item em {
  color: #64748b;
  font-size: 13px;
  font-style: normal;
}

.search-panel {
  margin-top: 26px;
  padding: 16px;
  border-radius: 26px;
  background: rgba(255, 255, 255, 0.88);
  box-shadow: 0 18px 42px rgba(15, 23, 42, 0.1);
}

.search-panel input {
  flex: 1 1 280px;
  min-height: 48px;
  border: 1px solid #bfdbfe;
  border-radius: 999px;
  padding: 0 18px;
  outline: none;
  color: #0f172a;
  font-size: 15px;
}

.search-panel input:focus {
  border-color: #2563eb;
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.12);
}

.page-hero {
  width: min(1800px, calc(100% - 32px));
  margin: 28px auto 0;
  border-radius: 32px;
  padding: clamp(34px, 5vw, 72px);
  background: radial-gradient(circle at 16% 16%, rgba(34, 211, 238, 0.38), transparent 30%), linear-gradient(135deg, #0f172a, #1d4ed8);
  color: #ffffff;
  box-shadow: 0 30px 80px rgba(15, 23, 42, 0.22);
}

.page-hero h1 {
  max-width: 960px;
  margin: 12px 0 16px;
  font-size: clamp(34px, 5vw, 64px);
  line-height: 1.05;
  letter-spacing: -0.06em;
}

.page-hero p {
  max-width: 900px;
  margin: 0;
  color: rgba(255, 255, 255, 0.82);
  font-size: 17px;
  line-height: 1.8;
}

.breadcrumbs {
  width: min(1800px, calc(100% - 32px));
  margin: 22px auto 0;
  color: #64748b;
  font-size: 14px;
}

.breadcrumbs a {
  color: #2563eb;
  font-weight: 800;
}

.detail-shell {
  width: min(1800px, calc(100% - 32px));
  margin: 26px auto 72px;
  display: grid;
  grid-template-columns: minmax(280px, 430px) minmax(0, 1fr);
  gap: 28px;
}

.detail-poster {
  overflow: hidden;
  border-radius: 28px;
  aspect-ratio: 3 / 4;
  background: linear-gradient(135deg, #dbeafe, #cffafe);
  box-shadow: 0 28px 70px rgba(15, 23, 42, 0.18);
}

.detail-main {
  min-width: 0;
}

.detail-title {
  margin: 16px 0;
  color: #0f172a;
  font-size: clamp(34px, 5vw, 70px);
  line-height: 1.04;
  letter-spacing: -0.07em;
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 24px;
}

.detail-summary,
.detail-review,
.player-box,
.related-box {
  border-radius: 28px;
  padding: 26px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 18px 44px rgba(15, 23, 42, 0.1);
}

.detail-summary p,
.detail-review p {
  margin: 10px 0 0;
  color: #334155;
  font-size: 16px;
  line-height: 1.9;
}

.player-box {
  margin-top: 26px;
}

.player-frame {
  position: relative;
  overflow: hidden;
  border-radius: 24px;
  aspect-ratio: 16 / 9;
  background: #020617;
}

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

.player-cover {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 0;
  background: rgba(2, 6, 23, 0.3);
  cursor: pointer;
}

.player-cover span {
  width: 92px;
  height: 92px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.92);
  color: #2563eb;
  font-size: 38px;
  font-weight: 900;
  box-shadow: 0 20px 55px rgba(15, 23, 42, 0.32);
}

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

.related-box {
  margin-top: 26px;
}

.related-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  margin-top: 16px;
}

.related-card {
  display: grid;
  grid-template-columns: 74px 1fr;
  gap: 12px;
  align-items: center;
  border-radius: 18px;
  padding: 10px;
  background: #f8fafc;
}

.related-card img {
  width: 74px;
  aspect-ratio: 3 / 4;
  border-radius: 12px;
  object-fit: cover;
}

.related-card strong {
  display: -webkit-box;
  overflow: hidden;
  color: #0f172a;
  line-height: 1.35;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.related-card em {
  display: block;
  margin-top: 6px;
  color: #64748b;
  font-size: 12px;
  font-style: normal;
}

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

.footer-inner {
  padding: 54px 0;
}

.footer-brand p {
  max-width: 720px;
  margin: 8px 0 0;
  color: #bfdbfe;
  line-height: 1.7;
}

.footer-links {
  flex-wrap: wrap;
  margin: 28px 0;
}

.footer-links a {
  color: #dbeafe;
}

.copyright {
  margin: 0;
  color: #bfdbfe;
}

.is-filtered-out {
  display: none;
}

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

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

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

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

  .menu-button {
    display: inline-flex;
  }

  .hero-wall {
    min-height: auto;
    grid-template-columns: 1fr;
  }

  .hero-card {
    min-height: 520px;
  }

  .movie-grid,
  .category-grid,
  .rank-layout,
  .detail-shell {
    grid-template-columns: 1fr 1fr;
  }

  .detail-shell,
  .rank-layout {
    display: block;
  }

  .detail-poster {
    max-width: 420px;
    margin-bottom: 26px;
  }
}

@media (max-width: 640px) {
  .header-inner {
    height: 70px;
  }

  .brand-text strong {
    font-size: 20px;
  }

  .brand-text em,
  .quick-nav {
    display: none;
  }

  .hero-content {
    padding: 26px;
  }

  .hero-card {
    min-height: 440px;
    border-radius: 24px;
  }

  .movie-grid,
  .category-grid,
  .related-grid {
    grid-template-columns: 1fr 1fr;
    gap: 14px;
  }

  .section {
    padding: 48px 0;
  }

  .section-head {
    display: block;
  }

  .card-body {
    padding: 13px;
  }

  .card-body strong {
    min-height: 42px;
    font-size: 16px;
  }

  .card-summary {
    -webkit-line-clamp: 2;
  }

  .rank-item {
    grid-template-columns: 40px 60px 1fr;
  }

  .rank-number {
    font-size: 22px;
  }

  .detail-summary,
  .detail-review,
  .player-box,
  .related-box {
    padding: 18px;
  }

  .player-cover span {
    width: 70px;
    height: 70px;
    font-size: 28px;
  }
}
