:root {
  color-scheme: light;
  --bg: #f5fbff;
  --surface: #ffffff;
  --surface-soft: #eff8ff;
  --text: #0f172a;
  --muted: #64748b;
  --line: #dbeafe;
  --sky: #0284c7;
  --sky-dark: #0369a1;
  --emerald: #059669;
  --orange: #f97316;
  --shadow: 0 20px 45px rgba(15, 23, 42, 0.12);
  --radius: 22px;
  font-family: Inter, "PingFang SC", "Microsoft YaHei", "Noto Sans SC", Arial, sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--text);
  background: linear-gradient(180deg, #eef9ff 0%, #ffffff 45%, #f8fafc 100%);
  min-height: 100vh;
}

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

img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

img.image-missing {
  opacity: 0;
}

button,
input,
select {
  font: inherit;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 80;
  background: rgba(255, 255, 255, 0.92);
  border-bottom: 1px solid rgba(219, 234, 254, 0.9);
  backdrop-filter: blur(18px);
  box-shadow: 0 10px 30px rgba(15, 23, 42, 0.06);
}

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

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

.brand-mark {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  color: #ffffff;
  background: linear-gradient(135deg, #0ea5e9, #22c55e);
  box-shadow: 0 10px 26px rgba(14, 165, 233, 0.28);
}

.brand-text {
  font-size: 1.25rem;
}

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

.desktop-nav a,
.mobile-nav a {
  color: #334155;
  font-weight: 700;
  padding: 10px 14px;
  border-radius: 999px;
  transition: color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.desktop-nav a:hover,
.desktop-nav a.nav-active,
.mobile-nav a:hover,
.mobile-nav a.nav-active {
  color: var(--sky-dark);
  background: #e0f2fe;
}

.menu-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 14px;
  background: #e0f2fe;
  cursor: pointer;
  padding: 10px;
}

.menu-toggle span {
  display: block;
  height: 2px;
  margin: 5px 0;
  background: var(--sky-dark);
  border-radius: 999px;
}

.mobile-nav {
  display: none;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto 14px;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
}

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

.hero-slider {
  position: relative;
  height: 600px;
  min-height: 560px;
  overflow: hidden;
  background: #0f172a;
}

.hero-track,
.hero-slide {
  position: absolute;
  inset: 0;
}

.hero-slide {
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.55s ease;
  background-image: linear-gradient(90deg, rgba(2, 6, 23, 0.86), rgba(15, 23, 42, 0.58), rgba(14, 165, 233, 0.2)), var(--hero-image);
  background-position: center;
  background-size: cover;
}

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

.hero-overlay,
.detail-shade {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 18% 20%, rgba(14, 165, 233, 0.24), transparent 30%), linear-gradient(180deg, rgba(2, 6, 23, 0.06), rgba(2, 6, 23, 0.58));
}

.hero-content {
  position: relative;
  height: 100%;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 310px;
  align-items: center;
  gap: 56px;
  color: #ffffff;
}

.hero-copy {
  max-width: 720px;
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--sky);
  font-size: 0.78rem;
  font-weight: 900;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.hero-copy .eyebrow,
.detail-copy .eyebrow {
  color: #7dd3fc;
}

.hero-copy h1,
.page-hero h1,
.detail-copy h1 {
  margin: 0;
  font-size: clamp(2.4rem, 6vw, 5.7rem);
  line-height: 0.98;
  letter-spacing: -0.06em;
}

.hero-summary,
.detail-line,
.page-hero p {
  max-width: 760px;
  color: rgba(255, 255, 255, 0.85);
  font-size: 1.08rem;
  line-height: 1.85;
}

.hero-tags,
.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 18px 0 0;
}

.hero-tags span,
.tag-row span {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 6px 11px;
  border-radius: 999px;
  font-size: 0.82rem;
  color: #075985;
  background: rgba(224, 242, 254, 0.92);
  border: 1px solid rgba(125, 211, 252, 0.5);
}

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

.primary-button,
.ghost-button,
.section-more,
.inline-search button,
.hero-search button,
.filter-panel button,
.text-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 18px;
  border-radius: 999px;
  font-weight: 800;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease, color 0.2s ease;
}

.primary-button,
.inline-search button,
.hero-search button,
.filter-panel button {
  color: #ffffff;
  background: linear-gradient(135deg, #0284c7, #10b981);
  border: 0;
  box-shadow: 0 14px 30px rgba(14, 165, 233, 0.28);
}

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

.primary-button:hover,
.ghost-button:hover,
.section-more:hover,
.inline-search button:hover,
.hero-search button:hover,
.filter-panel button:hover,
.text-link:hover {
  transform: translateY(-2px);
}

.hero-poster,
.poster-frame,
.ranking-poster {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius);
  background: radial-gradient(circle at 30% 20%, #bae6fd, #0f172a 80%);
  box-shadow: var(--shadow);
}

.hero-poster {
  height: 430px;
  border: 1px solid rgba(255, 255, 255, 0.24);
  transform: rotate(2deg);
}

.poster-fallback {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 22px;
  text-align: center;
  color: #ffffff;
  font-weight: 900;
  line-height: 1.4;
  background: linear-gradient(135deg, #0f172a, #0369a1 54%, #10b981);
}

.poster-frame img,
.hero-poster img,
.ranking-poster img {
  position: relative;
  z-index: 2;
  transition: transform 0.35s ease, opacity 0.2s ease;
}

.poster-frame:hover img,
.hero-poster:hover img,
.ranking-poster:hover img {
  transform: scale(1.05);
}

.poster-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  z-index: 4;
  padding: 6px 10px;
  border-radius: 999px;
  color: #ffffff;
  background: rgba(2, 132, 199, 0.92);
  font-size: 0.78rem;
  font-weight: 800;
}

.hero-control {
  position: absolute;
  top: 50%;
  z-index: 10;
  width: 50px;
  height: 50px;
  transform: translateY(-50%);
  border: 1px solid rgba(255, 255, 255, 0.36);
  border-radius: 50%;
  color: #ffffff;
  background: rgba(15, 23, 42, 0.35);
  cursor: pointer;
  font-size: 2rem;
  backdrop-filter: blur(14px);
}

.hero-prev {
  left: 24px;
}

.hero-next {
  right: 24px;
}

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

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

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

.hero-search,
.inline-search {
  display: flex;
  gap: 10px;
  width: min(560px, calc(100% - 32px));
}

.hero-search {
  position: absolute;
  left: 50%;
  bottom: 78px;
  z-index: 14;
  transform: translateX(-50%);
}

.hero-search input,
.inline-search input,
.filter-panel input,
.filter-panel select {
  min-height: 48px;
  border: 1px solid #bae6fd;
  border-radius: 999px;
  padding: 0 16px;
  outline: none;
  background: rgba(255, 255, 255, 0.92);
  color: var(--text);
}

.hero-search input,
.inline-search input {
  flex: 1;
}

.content-section {
  padding: 56px 0;
}

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

.section-head h2,
.detail-content h2,
.player-section h2,
.site-footer h2 {
  margin: 0;
  color: #0f172a;
  font-size: clamp(1.55rem, 2vw, 2.25rem);
  letter-spacing: -0.03em;
}

.section-head p,
.detail-content p,
.site-footer p,
.category-overview-card p,
.movie-card-body p,
.ranking-info p {
  color: var(--muted);
  line-height: 1.75;
}

.section-more,
.text-link {
  color: var(--sky-dark);
  background: #e0f2fe;
}

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

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

.movie-card {
  overflow: hidden;
  border: 1px solid rgba(186, 230, 253, 0.85);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.08);
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  border-color: #7dd3fc;
  box-shadow: var(--shadow);
}

.movie-card .poster-frame {
  display: block;
  height: 260px;
  border-radius: 0;
  box-shadow: none;
}

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

.card-meta {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  color: var(--sky-dark);
  font-size: 0.78rem;
  font-weight: 800;
}

.movie-card h3 {
  margin: 9px 0 8px;
  min-height: 50px;
  font-size: 1.02rem;
  line-height: 1.35;
}

.movie-card h3 a:hover,
.ranking-info h2 a:hover,
.category-overview-card h2 a:hover {
  color: var(--sky-dark);
}

.movie-card-body p {
  margin: 0;
  min-height: 70px;
  font-size: 0.92rem;
}

.movie-card .tag-row span {
  min-height: 25px;
  padding: 4px 8px;
  font-size: 0.72rem;
}

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

.category-tile,
.category-overview-card {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius);
  background-image: linear-gradient(135deg, rgba(2, 132, 199, 0.9), rgba(16, 185, 129, 0.82)), var(--tile-image);
  background-size: cover;
  background-position: center;
  color: #ffffff;
  box-shadow: var(--shadow);
}

.category-tile {
  min-height: 170px;
  display: flex;
  flex-direction: column;
  justify-content: end;
  gap: 8px;
  padding: 20px;
}

.category-tile span,
.category-overview-card h2 {
  font-size: 1.2rem;
  font-weight: 900;
}

.category-tile strong {
  font-size: 0.86rem;
  line-height: 1.55;
}

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

.category-overview-card {
  min-height: 310px;
  padding: 28px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.category-overview-card .eyebrow,
.category-overview-card p,
.category-overview-card a,
.category-overview-card h2 {
  color: #ffffff;
}

.mini-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 18px 0;
}

.mini-links a {
  padding: 7px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
}

.rank-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  list-style: none;
  padding: 0;
  margin: 0;
}

.rank-list a {
  display: grid;
  grid-template-columns: 52px 1fr auto;
  gap: 14px;
  align-items: center;
  padding: 14px;
  border: 1px solid #dbeafe;
  border-radius: 18px;
  background: #ffffff;
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.rank-list a:hover {
  transform: translateY(-2px);
  border-color: #7dd3fc;
}

.rank-number {
  display: inline-grid;
  place-items: center;
  min-width: 42px;
  min-height: 42px;
  padding: 0 8px;
  border-radius: 14px;
  color: #ffffff;
  background: linear-gradient(135deg, #0284c7, #10b981);
  font-weight: 900;
}

.rank-title {
  font-weight: 800;
}

.rank-meta {
  color: var(--muted);
  font-size: 0.88rem;
}

.page-main {
  min-height: 68vh;
}

.page-hero,
.detail-hero {
  position: relative;
  overflow: hidden;
  color: #ffffff;
}

.page-hero {
  padding: 86px 0;
  background: radial-gradient(circle at 20% 10%, rgba(125, 211, 252, 0.34), transparent 34%), linear-gradient(135deg, #0f172a, #075985 55%, #10b981);
}

.page-hero p {
  margin-top: 18px;
}

.soft-hero .inline-search {
  margin-top: 26px;
}

.category-hero {
  background: linear-gradient(135deg, #0f172a, #075985 58%, #22c55e);
}

.breadcrumb {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 26px;
  color: rgba(255, 255, 255, 0.82);
  font-size: 0.92rem;
}

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

.filter-panel {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 24px;
  padding: 18px;
  border: 1px solid #dbeafe;
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.88);
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.06);
}

.filter-panel input {
  min-width: min(360px, 100%);
  flex: 1;
}

.filter-status {
  color: var(--muted);
  font-size: 0.88rem;
}

.ranking-grid {
  display: grid;
  gap: 18px;
}

.ranking-card {
  display: grid;
  grid-template-columns: 150px 1fr;
  gap: 20px;
  padding: 16px;
  border: 1px solid #dbeafe;
  border-radius: var(--radius);
  background: #ffffff;
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.07);
}

.ranking-poster {
  height: 210px;
}

.ranking-poster .rank-number {
  position: absolute;
  top: 10px;
  left: 10px;
  z-index: 5;
}

.ranking-info h2 {
  margin: 4px 0 8px;
  font-size: 1.35rem;
}

.detail-hero {
  min-height: 590px;
  background-image: linear-gradient(90deg, rgba(2, 6, 23, 0.93), rgba(15, 23, 42, 0.72), rgba(14, 165, 233, 0.18)), var(--detail-image);
  background-size: cover;
  background-position: center;
}

.detail-layout {
  position: relative;
  display: grid;
  grid-template-columns: 310px 1fr;
  gap: 48px;
  align-items: center;
  padding: 70px 0 76px;
}

.detail-layout .breadcrumb {
  grid-column: 1 / -1;
  margin: 0 0 8px;
}

.detail-poster {
  height: 430px;
}

.detail-copy {
  color: #ffffff;
}

.detail-tags span {
  color: #e0f2fe;
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.24);
}

.player-section {
  padding: 54px 0 22px;
}

.video-shell {
  position: relative;
  overflow: hidden;
  margin-top: 18px;
  border-radius: 28px;
  background: #020617;
  box-shadow: 0 26px 70px rgba(2, 6, 23, 0.28);
  aspect-ratio: 16 / 9;
}

.player-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  background: #020617;
}

.player-start {
  position: absolute;
  inset: 0;
  z-index: 6;
  display: grid;
  place-items: center;
  gap: 12px;
  border: 0;
  color: #ffffff;
  background: radial-gradient(circle at center, rgba(14, 165, 233, 0.22), rgba(2, 6, 23, 0.62));
  cursor: pointer;
}

.player-start.is-hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

.play-icon {
  width: 82px;
  height: 82px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: #075985;
  background: #ffffff;
  font-size: 2.2rem;
  box-shadow: 0 18px 38px rgba(14, 165, 233, 0.26);
}

.detail-content {
  display: grid;
  grid-template-columns: 1fr;
  gap: 22px;
  padding: 34px 0 10px;
}

.detail-content section {
  padding: 28px;
  border: 1px solid #dbeafe;
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.06);
}

.info-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin: 0;
}

.info-list div {
  padding: 14px;
  border-radius: 16px;
  background: #f0f9ff;
}

.info-list dt {
  color: var(--muted);
  font-size: 0.82rem;
}

.info-list dd {
  margin: 6px 0 0;
  font-weight: 800;
}

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

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

.footer-brand {
  color: #ffffff;
  font-size: 1.25rem;
}

.site-footer h2 {
  color: #ffffff;
  font-size: 1rem;
  margin-bottom: 14px;
}

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

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

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

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

.is-filter-hidden {
  display: none !important;
}

@media (max-width: 1024px) {
  .hero-content,
  .detail-layout {
    grid-template-columns: 1fr;
  }

  .hero-poster,
  .detail-poster {
    display: none;
  }

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

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

  .menu-toggle {
    display: block;
  }

  .hero-slider {
    height: 680px;
  }

  .hero-content {
    align-items: start;
    padding-top: 82px;
  }

  .hero-search {
    bottom: 62px;
    flex-direction: column;
  }

  .hero-control {
    display: none;
  }

  .section-head,
  .rank-list a,
  .ranking-card,
  .footer-grid {
    display: block;
  }

  .section-more {
    margin-top: 16px;
  }

  .movie-grid,
  .large-grid,
  .category-grid,
  .category-overview-grid,
  .rank-list,
  .info-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .movie-card .poster-frame {
    height: 210px;
  }

  .ranking-poster {
    height: 240px;
    margin-bottom: 16px;
  }

  .detail-layout {
    padding-top: 44px;
  }

  .filter-panel,
  .inline-search {
    flex-direction: column;
    align-items: stretch;
  }
}

@media (max-width: 520px) {
  .container,
  .nav-shell,
  .mobile-nav {
    width: min(100% - 22px, 1180px);
  }

  .brand-text {
    font-size: 1.08rem;
  }

  .hero-copy h1,
  .page-hero h1,
  .detail-copy h1 {
    font-size: 2.35rem;
  }

  .movie-grid,
  .large-grid,
  .category-grid,
  .category-overview-grid,
  .rank-list,
  .info-list {
    grid-template-columns: 1fr;
  }

  .movie-card .poster-frame {
    height: 310px;
  }
}
