
:root {
  --bg: #f8fafc;
  --panel: #ffffff;
  --ink: #182033;
  --muted: #667085;
  --line: #e5e7eb;
  --brand: #2563eb;
  --brand-dark: #1e40af;
  --brand-soft: #eff6ff;
  --gold: #f59e0b;
  --shadow: 0 18px 45px rgba(15, 23, 42, 0.12);
  --radius: 22px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background: linear-gradient(135deg, #f8fafc 0%, #eff6ff 48%, #f8fafc 100%);
  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-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.92);
  border-bottom: 1px solid rgba(226, 232, 240, 0.86);
  backdrop-filter: blur(18px);
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.08);
}

.site-header-inner {
  max-width: 1280px;
  height: 70px;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.site-logo,
.footer-logo {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.site-logo-mark {
  width: 42px;
  height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  color: #ffffff;
  font-weight: 900;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--brand), var(--brand-dark));
  box-shadow: 0 10px 24px rgba(37, 99, 235, 0.32);
}

.site-logo-text,
.footer-logo span:last-child {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
}

.site-logo-text strong,
.footer-logo strong {
  font-size: 20px;
  font-weight: 800;
  letter-spacing: -0.03em;
}

.site-logo-text em,
.footer-logo em {
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
}

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

.nav-link,
.mobile-nav-link,
.filter-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  padding: 8px 14px;
  color: #344054;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 650;
  transition: color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.nav-link:hover,
.nav-link.is-active,
.mobile-nav-link:hover,
.mobile-nav-link.is-active,
.filter-chip:hover,
.filter-chip.is-active {
  color: var(--brand);
  background: var(--brand-soft);
}

.mobile-nav {
  display: none;
  gap: 8px;
  padding: 0 16px 12px;
  overflow-x: auto;
  scrollbar-width: none;
}

.mobile-nav::-webkit-scrollbar,
.movie-strip::-webkit-scrollbar {
  display: none;
}

main {
  overflow: hidden;
}

.hero-slider {
  position: relative;
  min-height: 72vh;
  background: #050816;
  isolation: isolate;
}

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

.hero-slide {
  opacity: 0;
  pointer-events: none;
  transform: scale(1.02);
  transition: opacity 0.7s ease, transform 1.2s ease;
}

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

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

.hero-shade {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 78% 30%, rgba(37, 99, 235, 0.28), transparent 36%),
    linear-gradient(90deg, rgba(2, 6, 23, 0.94) 0%, rgba(2, 6, 23, 0.72) 44%, rgba(2, 6, 23, 0.22) 100%),
    linear-gradient(0deg, rgba(2, 6, 23, 0.96), rgba(2, 6, 23, 0.1));
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 1280px;
  min-height: 72vh;
  margin: 0 auto;
  padding: 100px 24px 110px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  color: #ffffff;
}

.hero-kicker,
.eyebrow {
  margin-bottom: 14px;
  color: #bfdbfe;
  font-size: 14px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.hero-content h1,
.hero-content h2 {
  max-width: 780px;
  margin: 0;
  font-size: clamp(38px, 7vw, 76px);
  line-height: 0.98;
  font-weight: 900;
  letter-spacing: -0.06em;
}

.hero-content p {
  max-width: 680px;
  margin: 22px 0 0;
  color: #dbeafe;
  font-size: clamp(16px, 2vw, 20px);
  line-height: 1.75;
}

.hero-tags,
.tag-row,
.detail-meta,
.filter-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}

.hero-tags {
  margin-top: 22px;
}

.hero-tags span,
.tag-row span,
.detail-meta span {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 4px 10px;
  border-radius: 999px;
  color: #1d4ed8;
  background: #dbeafe;
  font-size: 12px;
  font-weight: 750;
}

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

.primary-btn,
.ghost-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 12px 22px;
  border-radius: 999px;
  font-weight: 800;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.primary-btn {
  color: #ffffff;
  background: linear-gradient(135deg, var(--brand), var(--brand-dark));
  box-shadow: 0 18px 34px rgba(37, 99, 235, 0.35);
}

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

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

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

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

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

.content-section {
  max-width: 1280px;
  margin: 0 auto;
  padding: 56px 24px;
}

.intro-section {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(280px, 0.7fr);
  gap: 24px;
  align-items: stretch;
}

.intro-copy,
.search-panel,
.text-panel,
.category-overview-card,
.category-tile {
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid rgba(226, 232, 240, 0.88);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.intro-copy {
  padding: 34px;
}

.intro-copy h2,
.section-heading h2,
.text-panel h2,
.footer-column h2 {
  margin: 0;
  font-size: clamp(26px, 4vw, 38px);
  line-height: 1.15;
  font-weight: 900;
  letter-spacing: -0.04em;
}

.intro-copy p,
.section-heading p,
.text-panel p,
.category-tile p,
.category-overview-card p {
  margin: 12px 0 0;
  color: var(--muted);
  line-height: 1.75;
}

.search-panel {
  padding: 24px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.search-label {
  margin-bottom: 10px;
  color: #344054;
  font-weight: 800;
}

.search-input {
  width: 100%;
  min-height: 52px;
  padding: 0 18px;
  color: var(--ink);
  border: 1px solid #cbd5e1;
  border-radius: 16px;
  outline: none;
  background: #ffffff;
  font-size: 16px;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

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

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

.section-more {
  color: var(--brand);
  font-weight: 850;
  white-space: nowrap;
}

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

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

.movie-card {
  min-width: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid rgba(226, 232, 240, 0.86);
  border-radius: 20px;
  background: #ffffff;
  box-shadow: 0 12px 32px rgba(15, 23, 42, 0.1);
  transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
}

.movie-card:hover {
  transform: translateY(-5px);
  border-color: rgba(37, 99, 235, 0.35);
  box-shadow: 0 24px 56px rgba(15, 23, 42, 0.18);
}

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

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

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

.score-badge,
.rank-badge {
  position: absolute;
  top: 10px;
  display: inline-flex;
  min-height: 28px;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  color: #ffffff;
  font-size: 12px;
  font-weight: 900;
}

.score-badge {
  right: 10px;
  min-width: 42px;
  background: rgba(2, 6, 23, 0.76);
}

.rank-badge {
  left: 10px;
  padding: 0 10px;
  background: linear-gradient(135deg, #f59e0b, #ef4444);
}

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

.movie-card-meta {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  color: #667085;
  font-size: 12px;
  font-weight: 700;
}

.movie-card h3 {
  margin: 9px 0 0;
  color: var(--ink);
  font-size: 17px;
  line-height: 1.35;
  font-weight: 850;
  display: -webkit-box;
  overflow: hidden;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

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

.movie-card.is-compact .movie-card-body {
  padding: 14px;
}

.movie-card.is-compact h3 {
  font-size: 15px;
}

.movie-card.is-compact p {
  display: none;
}

.tag-row span {
  color: #344054;
  background: #f2f4f7;
}

.dark-section {
  max-width: 100%;
  margin: 20px 0;
  padding-left: calc((100% - 1280px) / 2 + 24px);
  padding-right: calc((100% - 1280px) / 2 + 24px);
  color: #ffffff;
  background: radial-gradient(circle at 80% 20%, rgba(37, 99, 235, 0.34), transparent 32%), linear-gradient(135deg, #111827, #1f2937);
}

.dark-section .section-heading h2,
.dark-section .section-heading p,
.dark-section .section-more {
  color: #ffffff;
}

.movie-strip {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(180px, 210px);
  gap: 18px;
  overflow-x: auto;
  padding-bottom: 12px;
  scrollbar-width: none;
}

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

.category-tile {
  min-height: 180px;
  padding: 22px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  overflow: hidden;
  background: linear-gradient(135deg, #ffffff 0%, #eff6ff 100%);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.category-tile:hover,
.category-overview-card:hover {
  transform: translateY(-4px);
}

.category-tile span,
.category-overview-card h2 {
  font-size: 22px;
  font-weight: 900;
  letter-spacing: -0.04em;
}

.page-hero,
.detail-hero {
  position: relative;
  max-width: 1280px;
  margin: 32px auto 0;
  padding: 64px 24px;
  overflow: hidden;
  border-radius: 30px;
  color: #ffffff;
  background: radial-gradient(circle at 80% 25%, rgba(96, 165, 250, 0.44), transparent 30%), linear-gradient(135deg, #0f172a, #1e3a8a);
  box-shadow: var(--shadow);
}

.small-hero,
.category-hero,
.ranking-hero {
  min-height: 260px;
  display: flex;
  align-items: center;
}

.page-hero h1,
.detail-main h1 {
  margin: 0;
  max-width: 840px;
  font-size: clamp(38px, 6vw, 64px);
  line-height: 1.04;
  font-weight: 950;
  letter-spacing: -0.06em;
}

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

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

.category-overview-card {
  padding: 18px;
  display: grid;
  grid-template-columns: 180px minmax(0, 1fr);
  gap: 22px;
  align-items: center;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

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

.category-cover-stack img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: 12px;
  background: #eff6ff;
}

.category-overview-card span {
  display: inline-flex;
  margin-top: 14px;
  color: var(--brand);
  font-weight: 850;
}

.filter-row {
  margin: 20px 0 26px;
}

.filter-chip {
  border: 0;
  cursor: pointer;
  background: #ffffff;
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.08);
}

.empty-state {
  display: none;
  margin: 28px 0 0;
  padding: 22px;
  color: var(--muted);
  text-align: center;
  border: 1px dashed #cbd5e1;
  border-radius: 18px;
  background: #ffffff;
}

.movie-grid.has-empty + .empty-state,
.ranking-grid.has-empty + .empty-state {
  display: block;
}

.detail-hero {
  display: grid;
  grid-template-columns: 300px minmax(0, 1fr);
  gap: 34px;
  align-items: center;
}

.detail-poster-wrap {
  overflow: hidden;
  border-radius: 24px;
  box-shadow: 0 26px 60px rgba(2, 6, 23, 0.32);
}

.detail-poster {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  background: #dbeafe;
}

.breadcrumbs {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 22px;
  color: #bfdbfe;
  font-size: 14px;
  font-weight: 700;
}

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

.detail-meta {
  margin-top: 18px;
}

.detail-tags {
  margin-top: 18px;
}

.watch-section {
  padding-top: 42px;
}

.player-shell {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16 / 9;
  border-radius: 24px;
  background: #020617;
  box-shadow: 0 28px 70px rgba(15, 23, 42, 0.24);
}

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

.player-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  color: #ffffff;
  border: 0;
  background: radial-gradient(circle at 50% 45%, rgba(37, 99, 235, 0.28), transparent 28%), rgba(2, 6, 23, 0.62);
  cursor: pointer;
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

.player-shell.is-playing .player-overlay {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.play-icon {
  width: 74px;
  height: 74px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--brand), var(--brand-dark));
  box-shadow: 0 18px 38px rgba(37, 99, 235, 0.35);
  font-size: 30px;
  line-height: 1;
}

.detail-content {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
}

.text-panel {
  padding: 30px;
}

.text-panel h2 {
  font-size: 28px;
}

.site-footer {
  margin-top: 40px;
  color: #cbd5e1;
  background: linear-gradient(135deg, #111827, #1f2937);
}

.footer-inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 48px 24px;
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(180px, 0.75fr) minmax(180px, 0.75fr);
  gap: 32px;
}

.footer-logo strong,
.footer-column h2 {
  color: #ffffff;
}

.footer-brand p {
  max-width: 520px;
  color: #94a3b8;
  line-height: 1.75;
}

.footer-column h2 {
  margin-bottom: 16px;
  font-size: 18px;
  letter-spacing: 0;
}

.footer-column ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.footer-column li + li {
  margin-top: 10px;
}

.footer-column a {
  color: #cbd5e1;
}

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

.footer-bottom {
  max-width: 1280px;
  margin: 0 auto;
  padding: 22px 24px;
  color: #94a3b8;
  border-top: 1px solid rgba(148, 163, 184, 0.2);
  font-size: 14px;
}

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

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

  .mobile-nav {
    display: flex;
  }

  .site-header-inner {
    height: 64px;
  }

  .intro-section,
  .detail-hero,
  .detail-content,
  .footer-inner,
  .category-overview-card {
    grid-template-columns: 1fr;
  }

  .detail-poster-wrap {
    max-width: 280px;
  }

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

  .section-heading {
    align-items: flex-start;
    flex-direction: column;
  }
}

@media (max-width: 640px) {
  .site-logo-text strong {
    font-size: 18px;
  }

  .site-logo-text em {
    display: none;
  }

  .hero-content {
    padding: 88px 18px 96px;
  }

  .content-section {
    padding: 38px 16px;
  }

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

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

  .movie-card p,
  .tag-row {
    display: none;
  }

  .page-hero,
  .detail-hero {
    margin: 18px 12px 0;
    padding: 34px 18px;
    border-radius: 22px;
  }

  .play-icon {
    width: 58px;
    height: 58px;
    font-size: 24px;
  }
}
