:root {
  color-scheme: light;
  --bg: #f8fafc;
  --panel: #ffffff;
  --ink: #0f172a;
  --muted: #64748b;
  --line: #e2e8f0;
  --brand: #2563eb;
  --brand-2: #06b6d4;
  --warm: #f97316;
  --shadow: 0 18px 45px rgba(15, 23, 42, 0.12);
  --radius: 22px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

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

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

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

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(226, 232, 240, 0.9);
  backdrop-filter: blur(14px);
}

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

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

.logo-mark {
  display: inline-grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 14px;
  color: #fff;
  background: linear-gradient(135deg, var(--brand), var(--brand-2));
  box-shadow: 0 12px 25px rgba(37, 99, 235, 0.25);
}

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

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

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

.nav-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 14px;
  background: #eff6ff;
  padding: 10px;
}

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

.hero-slider {
  position: relative;
  min-height: 680px;
  overflow: hidden;
  background: #020617;
}

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

.hero-slide {
  display: flex;
  align-items: center;
  opacity: 0;
  background-position: center;
  background-size: cover;
  transform: scale(1.03);
  transition: opacity 0.8s ease, transform 1.2s ease;
}

.hero-slide.active {
  opacity: 1;
  transform: scale(1);
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 80% 20%, rgba(6, 182, 212, 0.4), transparent 28%),
    linear-gradient(90deg, rgba(2, 6, 23, 0.92), rgba(2, 6, 23, 0.62) 48%, rgba(2, 6, 23, 0.2));
}

.hero-content {
  position: relative;
  z-index: 2;
  width: min(680px, calc(100% - 32px));
  margin-left: max(16px, calc((100vw - 1180px) / 2));
  color: #fff;
  padding-bottom: 80px;
}

.eyebrow,
.section-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 14px;
  color: #67e8f9;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.hero-content h1 {
  margin: 0 0 18px;
  font-size: clamp(42px, 7vw, 78px);
  line-height: 0.98;
  letter-spacing: -0.06em;
}

.hero-content p {
  max-width: 640px;
  margin: 0 0 22px;
  font-size: 19px;
  line-height: 1.8;
  color: #e2e8f0;
}

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

.hero-tags span,
.tag-row span {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 5px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.14);
  color: #e0f2fe;
  font-size: 13px;
  font-weight: 700;
}

.tag-row span {
  background: #eef6ff;
  color: #2563eb;
}

.tag-row.large span {
  background: rgba(255, 255, 255, 0.16);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.18);
}

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

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 20px;
  border: 1px solid transparent;
  border-radius: 999px;
  font-weight: 800;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.btn.primary {
  color: #fff;
  background: linear-gradient(135deg, var(--brand), var(--brand-2));
  box-shadow: 0 16px 30px rgba(37, 99, 235, 0.28);
}

.btn.ghost {
  color: #fff;
  border-color: rgba(255, 255, 255, 0.35);
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(10px);
}

.btn.small {
  min-height: 38px;
  padding: 0 15px;
  color: #fff;
  background: var(--brand);
}

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

.hero-search-card {
  position: relative;
  z-index: 5;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 18px;
  margin-top: 540px;
  padding: 18px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 26px;
  color: #fff;
  background: rgba(15, 23, 42, 0.78);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}

.hero-search-card strong {
  display: block;
  font-size: 18px;
}

.hero-search-card span {
  color: #cbd5e1;
  font-size: 14px;
}

.hero-search {
  display: flex;
  min-height: 48px;
  padding: 4px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.13);
}

.hero-search input {
  flex: 1;
  min-width: 0;
  border: 0;
  outline: 0;
  color: #fff;
  background: transparent;
  padding: 0 16px;
}

.hero-search input::placeholder {
  color: #cbd5e1;
}

.hero-search button {
  border: 0;
  border-radius: 999px;
  padding: 0 18px;
  color: #fff;
  background: linear-gradient(135deg, var(--warm), #ef4444);
  font-weight: 800;
}

.hero-rank-link {
  color: #67e8f9;
  font-weight: 800;
}

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

.hero-dots button {
  width: 11px;
  height: 11px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.48);
  transition: width 0.25s ease, background 0.25s ease;
}

.hero-dots button.active {
  width: 34px;
  background: #fff;
}

.section-pad {
  padding: 74px 0;
}

.soft-bg {
  background: linear-gradient(180deg, #f8fafc, #eef6ff);
}

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

.section-head h2,
.page-hero h1,
.prose-panel h2,
.player-panel h2,
.info-panel h2,
.rank-panel h2 {
  margin: 0;
  font-size: clamp(28px, 4vw, 44px);
  line-height: 1.08;
  letter-spacing: -0.04em;
}

.text-link {
  color: var(--brand);
  font-weight: 800;
}

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

.category-card {
  position: relative;
  min-height: 190px;
  overflow: hidden;
  border-radius: var(--radius);
  padding: 22px;
  color: #fff;
  background-position: center;
  background-size: cover;
  box-shadow: var(--shadow);
  isolation: isolate;
}

.category-card::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(180deg, rgba(2, 6, 23, 0.15), rgba(2, 6, 23, 0.82));
}

.category-card span {
  display: block;
  margin-top: 72px;
  font-size: 24px;
  font-weight: 900;
}

.category-card p {
  margin: 8px 0 0;
  color: #dbeafe;
  line-height: 1.6;
}

.filter-bar {
  margin-bottom: 26px;
}

.search-box,
.select-box {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  margin: 0 10px 12px 0;
  padding: 10px 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #fff;
  box-shadow: 0 10px 25px rgba(15, 23, 42, 0.05);
}

.search-box span,
.select-box span {
  color: var(--muted);
  font-size: 14px;
  font-weight: 800;
}

.search-box input,
.select-box select {
  min-width: 220px;
  border: 0;
  outline: 0;
  color: var(--ink);
  background: transparent;
}

.select-box select {
  min-width: 130px;
}

.empty-tip {
  display: none;
  margin: 20px 0;
  padding: 18px;
  border: 1px dashed #bfdbfe;
  border-radius: var(--radius);
  color: var(--brand);
  background: #eff6ff;
  font-weight: 800;
}

.empty-tip.active {
  display: block;
}

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

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

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

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

.movie-card {
  overflow: hidden;
  border: 1px solid rgba(226, 232, 240, 0.9);
  border-radius: var(--radius);
  background: #fff;
  box-shadow: 0 14px 35px rgba(15, 23, 42, 0.08);
  transition: transform 0.24s ease, box-shadow 0.24s ease;
}

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

.poster-link {
  position: relative;
  display: block;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  background: #0f172a;
}

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

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

.poster-shade {
  position: absolute;
  inset: auto 0 0 0;
  height: 42%;
  background: linear-gradient(0deg, rgba(2, 6, 23, 0.75), transparent);
}

.rank-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  z-index: 3;
  min-width: 36px;
  height: 36px;
  display: inline-grid;
  place-items: center;
  border-radius: 12px;
  color: #fff;
  background: linear-gradient(135deg, #f97316, #ef4444);
  box-shadow: 0 12px 25px rgba(239, 68, 68, 0.25);
}

.card-body {
  padding: 16px;
}

.meta-line {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  color: #64748b;
  font-size: 12px;
  font-weight: 800;
}

.card-body h2 {
  margin: 8px 0;
  font-size: 19px;
  line-height: 1.25;
}

.card-body h2 a:hover {
  color: var(--brand);
}

.card-body p {
  min-height: 48px;
  margin: 0 0 12px;
  color: #64748b;
  font-size: 14px;
  line-height: 1.65;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.feature-layout {
  display: grid;
  grid-template-columns: 1fr 360px;
  gap: 34px;
  align-items: start;
}

.lead-text {
  max-width: 720px;
  color: var(--muted);
  font-size: 17px;
  line-height: 1.8;
}

.rank-panel,
.info-panel,
.prose-panel,
.player-panel {
  border: 1px solid rgba(226, 232, 240, 0.9);
  border-radius: 28px;
  background: #fff;
  box-shadow: var(--shadow);
}

.rank-panel {
  position: sticky;
  top: 94px;
  padding: 20px;
}

.rank-panel-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
}

.rank-panel-head h2 {
  font-size: 25px;
}

.rank-panel-head a {
  color: var(--brand);
  font-weight: 800;
}

.rank-mini {
  display: grid;
  grid-template-columns: 34px 54px 1fr auto;
  align-items: center;
  gap: 10px;
  padding: 10px 0;
  border-top: 1px solid var(--line);
}

.rank-mini span {
  color: var(--brand);
  font-weight: 900;
}

.rank-mini img {
  width: 54px;
  height: 68px;
  object-fit: cover;
  border-radius: 12px;
}

.rank-mini strong {
  line-height: 1.35;
}

.rank-mini em {
  color: var(--muted);
  font-style: normal;
  font-size: 13px;
}

.page-hero,
.detail-hero {
  position: relative;
  color: #fff;
  background: linear-gradient(135deg, #0f172a, #2563eb 58%, #06b6d4);
}

.compact-hero,
.search-hero,
.rank-hero {
  padding: 92px 0 72px;
}

.page-hero p {
  max-width: 760px;
  color: #dbeafe;
  font-size: 18px;
  line-height: 1.8;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 18px;
  color: #bfdbfe;
  font-weight: 700;
}

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

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

.category-overview-card {
  display: grid;
  grid-template-columns: 190px 1fr;
  gap: 22px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 28px;
  background: #fff;
  box-shadow: 0 14px 35px rgba(15, 23, 42, 0.08);
}

.category-covers {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 6px;
}

.category-covers img {
  height: 116px;
  width: 100%;
  object-fit: cover;
  border-radius: 15px;
}

.category-overview-card h2 {
  margin: 6px 0 10px;
  font-size: 28px;
}

.category-overview-card p {
  color: var(--muted);
  line-height: 1.75;
}

.detail-hero {
  min-height: 620px;
  background-position: center;
  background-size: cover;
}

.detail-hero-shade {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 70% 10%, rgba(6, 182, 212, 0.35), transparent 34%),
    linear-gradient(90deg, rgba(2, 6, 23, 0.94), rgba(2, 6, 23, 0.72), rgba(2, 6, 23, 0.35));
}

.detail-hero-inner {
  position: relative;
  z-index: 2;
  padding: 74px 0;
}

.detail-grid {
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 36px;
  align-items: end;
}

.detail-poster {
  width: 260px;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border: 6px solid rgba(255, 255, 255, 0.15);
  border-radius: 28px;
  box-shadow: var(--shadow);
}

.detail-info h1 {
  margin: 0 0 18px;
  max-width: 840px;
  font-size: clamp(38px, 6vw, 68px);
  line-height: 1;
  letter-spacing: -0.06em;
}

.detail-one-line {
  max-width: 820px;
  color: #e2e8f0;
  font-size: 19px;
  line-height: 1.8;
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 20px 0;
}

.detail-meta span {
  padding: 8px 12px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.11);
  color: #fff;
  font-weight: 800;
}

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

.player-panel {
  padding: 18px;
}

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

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

.player-cover {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  gap: 12px;
  border: 0;
  color: #fff;
  background: linear-gradient(180deg, rgba(2, 6, 23, 0.35), rgba(2, 6, 23, 0.72));
  cursor: pointer;
  text-align: center;
  transition: opacity 0.25s ease;
}

.player-cover.is-hidden {
  opacity: 0;
  pointer-events: none;
}

.play-circle {
  display: inline-grid;
  place-items: center;
  width: 74px;
  height: 74px;
  border-radius: 999px;
  color: #fff;
  background: linear-gradient(135deg, var(--brand), var(--brand-2));
  box-shadow: 0 18px 38px rgba(37, 99, 235, 0.3);
  font-size: 26px;
}

.player-cover strong {
  max-width: min(560px, calc(100% - 32px));
  font-size: 24px;
}

.player-panel h2,
.player-panel p {
  padding: 0 8px;
}

.player-panel h2 {
  margin-top: 20px;
  font-size: 28px;
}

.player-panel p {
  color: var(--muted);
  line-height: 1.8;
}

.info-panel {
  padding: 24px;
}

.info-panel h2 {
  font-size: 28px;
  margin-bottom: 16px;
}

.info-panel dl {
  margin: 0;
}

.info-panel dl div {
  display: grid;
  grid-template-columns: 72px 1fr;
  gap: 12px;
  padding: 12px 0;
  border-top: 1px solid var(--line);
}

.info-panel dt {
  color: var(--muted);
  font-weight: 800;
}

.info-panel dd {
  margin: 0;
  font-weight: 700;
  line-height: 1.55;
}

.prose-panel {
  padding: 32px;
}

.prose-panel h2 {
  margin: 0 0 14px;
  font-size: 32px;
}

.prose-panel p {
  margin: 0 0 28px;
  color: #334155;
  font-size: 17px;
  line-height: 2;
}

.site-footer {
  padding: 54px 0 24px;
  color: #cbd5e1;
  background: #020617;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 28px;
}

.footer-logo {
  margin-bottom: 12px;
  color: #fff;
  font-size: 24px;
  font-weight: 900;
}

.site-footer p {
  max-width: 480px;
  line-height: 1.8;
}

.site-footer h2 {
  color: #fff;
  font-size: 18px;
}

.footer-links {
  display: flex;
  flex-direction: column;
  gap: 9px;
}

.footer-links.compact {
  flex-flow: row wrap;
}

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

.copyright {
  margin-top: 28px;
  padding-top: 24px;
  border-top: 1px solid rgba(148, 163, 184, 0.18);
  color: #94a3b8;
}

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

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

  .feature-layout,
  .detail-content-grid {
    grid-template-columns: 1fr;
  }

  .rank-panel {
    position: static;
  }
}

@media (max-width: 760px) {
  .site-nav {
    position: absolute;
    top: 72px;
    left: 16px;
    right: 16px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    padding: 14px;
    border: 1px solid var(--line);
    border-radius: 22px;
    background: #fff;
    box-shadow: var(--shadow);
  }

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

  .nav-toggle {
    display: block;
  }

  .hero-slider {
    min-height: 760px;
  }

  .hero-content {
    padding-top: 90px;
    padding-bottom: 180px;
  }

  .hero-search-card {
    grid-template-columns: 1fr;
    margin-top: 548px;
  }

  .hero-search {
    flex-direction: column;
    border-radius: 22px;
    gap: 8px;
  }

  .hero-search input,
  .hero-search button {
    min-height: 44px;
  }

  .section-head {
    display: block;
  }

  .category-grid,
  .movie-grid,
  .feature-grid,
  .ranking-grid,
  .compact-grid,
  .category-overview-grid,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .category-overview-card,
  .detail-grid {
    grid-template-columns: 1fr;
  }

  .detail-poster {
    width: min(260px, 100%);
  }

  .search-box,
  .select-box {
    width: 100%;
    align-items: stretch;
    justify-content: space-between;
  }

  .search-box input,
  .select-box select {
    min-width: 0;
    width: 100%;
  }
}
