:root {
  color-scheme: light;
  --bg: #f5f7fb;
  --surface: #ffffff;
  --surface-strong: #eef4ff;
  --text: #101828;
  --muted: #667085;
  --line: rgba(16, 24, 40, .1);
  --brand: #2563eb;
  --brand-2: #06b6d4;
  --hot: #f97316;
  --shadow: 0 22px 60px rgba(16, 24, 40, .12);
  --radius: 24px;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  color: var(--text);
  background:
    radial-gradient(circle at top left, rgba(37, 99, 235, .13), transparent 36rem),
    linear-gradient(180deg, #f8fbff 0%, var(--bg) 44%, #ffffff 100%);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
}

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

img,
video {
  max-width: 100%;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid rgba(16, 24, 40, .08);
  background: rgba(255, 255, 255, .82);
  backdrop-filter: blur(18px);
}

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

.logo,
.footer-logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: #0f172a;
  font-size: 22px;
  font-weight: 900;
  letter-spacing: -.03em;
}

.logo-mark {
  width: 38px;
  height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--brand), var(--brand-2));
  box-shadow: 0 14px 32px rgba(37, 99, 235, .26);
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 24px;
  color: #344054;
  font-size: 15px;
  font-weight: 700;
}

.main-nav a {
  transition: color .2s ease;
}

.main-nav a:hover,
.main-nav a.is-active {
  color: var(--brand);
}

.menu-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 1px solid var(--line);
  border-radius: 14px;
  color: var(--text);
  background: var(--surface);
}

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

.hero-carousel {
  position: relative;
  width: min(1180px, calc(100% - 32px));
  min-height: 560px;
  margin: 28px auto 34px;
  overflow: hidden;
  border-radius: 34px;
  background: #0b1220;
  box-shadow: var(--shadow);
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  display: flex;
  align-items: flex-end;
  padding: clamp(28px, 6vw, 72px);
  background-position: center;
  background-size: cover;
  transform: scale(1.03);
  transition: opacity .6s ease, transform .8s ease;
}

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

.hero-content {
  max-width: 720px;
  color: #ffffff;
}

.eyebrow,
.section-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
  color: var(--brand);
  font-size: 13px;
  font-weight: 900;
  letter-spacing: .16em;
  text-transform: uppercase;
}

.hero-content .eyebrow {
  color: #93c5fd;
}

.hero-content h1 {
  margin: 0 0 18px;
  font-size: clamp(42px, 7vw, 80px);
  line-height: .98;
  font-weight: 950;
  letter-spacing: -.06em;
}

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

.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: 4px 10px;
  border: 1px solid rgba(37, 99, 235, .18);
  border-radius: 999px;
  color: #2563eb;
  background: rgba(37, 99, 235, .08);
  font-size: 12px;
  font-weight: 800;
}

.hero-tags span {
  border-color: rgba(255, 255, 255, .22);
  color: #ffffff;
  background: rgba(255, 255, 255, .15);
  backdrop-filter: blur(12px);
}

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

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 20px;
  border-radius: 999px;
  font-size: 15px;
  font-weight: 900;
  transition: transform .2s ease, box-shadow .2s ease, background .2s ease;
}

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

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

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

.btn.text {
  color: #ffffff;
  padding-inline: 6px;
}

.hero-dots {
  position: absolute;
  left: clamp(28px, 6vw, 72px);
  bottom: 26px;
  z-index: 3;
  display: flex;
  gap: 8px;
}

.hero-dots button {
  width: 34px;
  height: 6px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, .36);
}

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

.panel,
.section-block,
.category-section {
  margin: 28px 0;
}

.panel {
  padding: clamp(24px, 4vw, 40px);
  border: 1px solid rgba(37, 99, 235, .1);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, .88);
  box-shadow: 0 18px 50px rgba(16, 24, 40, .07);
}

.quick-search {
  display: grid;
  grid-template-columns: 1fr minmax(280px, 440px);
  align-items: center;
  gap: 24px;
}

.panel h1,
.panel h2,
.section-head h2,
.detail-copy h2 {
  margin: 0;
  color: #0f172a;
  font-size: clamp(28px, 4vw, 46px);
  line-height: 1.05;
  font-weight: 950;
  letter-spacing: -.045em;
}

.panel p,
.detail-copy p {
  margin: 14px 0 0;
  color: var(--muted);
  font-size: 17px;
  line-height: 1.85;
}

.search-form,
.local-filter {
  display: flex;
  gap: 10px;
}

.search-form input,
.local-filter input {
  width: 100%;
  min-height: 48px;
  border: 1px solid rgba(37, 99, 235, .16);
  border-radius: 16px;
  padding: 0 16px;
  color: var(--text);
  background: #ffffff;
  outline: none;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .8);
}

.search-form input:focus,
.local-filter input:focus {
  border-color: rgba(37, 99, 235, .56);
  box-shadow: 0 0 0 4px rgba(37, 99, 235, .11);
}

.search-form button {
  min-width: 104px;
  border: 0;
  border-radius: 16px;
  color: #ffffff;
  background: var(--brand);
  font-weight: 900;
}

.local-filter.large {
  margin-top: 24px;
}

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

.section-head a {
  color: var(--brand);
  font-weight: 900;
}

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

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

.movie-card {
  overflow: hidden;
  border: 1px solid rgba(16, 24, 40, .08);
  border-radius: 22px;
  background: var(--surface);
  box-shadow: 0 16px 42px rgba(16, 24, 40, .08);
  transition: transform .22s ease, box-shadow .22s ease, border-color .22s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  border-color: rgba(37, 99, 235, .26);
  box-shadow: 0 26px 64px rgba(16, 24, 40, .14);
}

.poster,
.detail-cover,
.rank-cover {
  display: block;
  background-color: #dbeafe;
  background-position: center;
  background-size: cover;
}

.poster {
  aspect-ratio: 2 / 3;
}

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

.movie-meta-line {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 8px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.movie-card h3 {
  margin: 0 0 10px;
  color: #0f172a;
  font-size: 20px;
  line-height: 1.22;
  font-weight: 950;
  letter-spacing: -.025em;
}

.movie-card p {
  min-height: 48px;
  margin: 0 0 14px;
  color: #667085;
  font-size: 14px;
  line-height: 1.7;
}

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

.movie-card.compact p {
  min-height: 44px;
  font-size: 13px;
}

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

.category-grid.wide {
  margin-top: 24px;
}

.category-tile {
  min-height: 150px;
  padding: 22px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  border: 1px solid rgba(37, 99, 235, .12);
  border-radius: 24px;
  background:
    radial-gradient(circle at top right, rgba(6, 182, 212, .18), transparent 60%),
    linear-gradient(135deg, #ffffff, #eff6ff);
  box-shadow: 0 18px 44px rgba(16, 24, 40, .08);
  transition: transform .22s ease, box-shadow .22s ease;
}

.category-tile:hover {
  transform: translateY(-5px);
  box-shadow: 0 28px 68px rgba(16, 24, 40, .13);
}

.category-tile span {
  color: var(--brand);
  font-size: 22px;
  font-weight: 950;
}

.category-tile strong {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}

.rank-list,
.rank-table {
  display: grid;
  gap: 10px;
}

.rank-item,
.rank-row {
  display: grid;
  align-items: center;
  gap: 14px;
  border: 1px solid rgba(16, 24, 40, .08);
  border-radius: 18px;
  background: #ffffff;
  box-shadow: 0 12px 30px rgba(16, 24, 40, .06);
  transition: transform .2s ease, border-color .2s ease;
}

.rank-item:hover,
.rank-row:hover {
  transform: translateX(4px);
  border-color: rgba(37, 99, 235, .28);
}

.rank-item {
  grid-template-columns: 46px 1fr auto;
  padding: 14px 16px;
}

.rank-item span,
.rank-num {
  color: var(--hot);
  font-weight: 950;
}

.rank-item strong,
.rank-copy strong {
  color: #111827;
  font-weight: 950;
}

.rank-item em,
.rank-meta,
.rank-copy em {
  color: var(--muted);
  font-style: normal;
  font-size: 13px;
}

.rank-row {
  grid-template-columns: 54px 72px 1fr auto;
  padding: 12px;
}

.rank-cover {
  width: 72px;
  aspect-ratio: 2 / 3;
  border-radius: 14px;
}

.rank-copy {
  display: grid;
  gap: 4px;
}

.page-main {
  padding: 26px 0 50px;
}

.page-hero {
  margin-top: 28px;
}

.category-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 22px;
}

.category-pills a {
  display: inline-flex;
  min-height: 38px;
  align-items: center;
  border: 1px solid rgba(37, 99, 235, .16);
  border-radius: 999px;
  padding: 0 14px;
  color: var(--brand);
  background: #ffffff;
  font-weight: 900;
}

.category-pills a.is-active {
  color: #ffffff;
  background: var(--brand);
}

.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 8px 0 18px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 800;
}

.breadcrumbs a {
  color: var(--brand);
}

.detail-hero {
  display: grid;
  grid-template-columns: minmax(220px, 340px) 1fr;
  gap: clamp(22px, 4vw, 42px);
  align-items: center;
}

.detail-cover {
  width: 100%;
  aspect-ratio: 2 / 3;
  border-radius: 26px;
  box-shadow: var(--shadow);
}

.detail-info h1 {
  margin: 0 0 16px;
  font-size: clamp(36px, 6vw, 64px);
  line-height: 1;
  font-weight: 950;
  letter-spacing: -.055em;
}

.detail-info .lead {
  color: #475467;
  font-size: 19px;
  line-height: 1.85;
}

.detail-tags {
  margin: 22px 0 26px;
}

.player-section {
  margin: 28px 0;
}

.player-box {
  position: relative;
  overflow: hidden;
  border-radius: 28px;
  background: #020617;
  box-shadow: var(--shadow);
}

.player-video {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #020617;
}

.player-overlay {
  position: absolute;
  inset: 0;
  z-index: 4;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 0;
  color: #ffffff;
  background: radial-gradient(circle, rgba(37, 99, 235, .24), rgba(2, 6, 23, .42));
}

.player-overlay span {
  width: 88px;
  height: 88px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--brand), var(--brand-2));
  box-shadow: 0 18px 50px rgba(37, 99, 235, .38);
  font-size: 38px;
  line-height: 1;
  transform: translateX(3px);
}

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

.detail-copy {
  padding: clamp(24px, 4vw, 38px);
  border-radius: var(--radius);
  background: #ffffff;
  box-shadow: 0 16px 44px rgba(16, 24, 40, .07);
}

.detail-copy h2 + p {
  margin-bottom: 24px;
}

.site-footer {
  margin-top: 54px;
  border-top: 1px solid rgba(16, 24, 40, .08);
  background: #ffffff;
}

.footer-inner {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 34px 0;
  display: grid;
  gap: 16px;
}

.footer-inner p {
  max-width: 720px;
  color: var(--muted);
  line-height: 1.8;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  color: var(--brand);
  font-weight: 900;
}

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

@media (max-width: 980px) {
  .main-nav {
    position: absolute;
    top: 72px;
    left: 16px;
    right: 16px;
    display: none;
    flex-direction: column;
    align-items: flex-start;
    padding: 18px;
    border: 1px solid rgba(16, 24, 40, .08);
    border-radius: 20px;
    background: #ffffff;
    box-shadow: var(--shadow);
  }

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

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

  .hero-carousel {
    min-height: 520px;
    border-radius: 26px;
  }

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

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

  .rank-row {
    grid-template-columns: 44px 56px 1fr;
  }

  .rank-meta {
    grid-column: 3;
  }
}

@media (max-width: 620px) {
  .header-inner,
  main,
  .page-main,
  .hero-carousel,
  .footer-inner {
    width: min(100% - 20px, 1180px);
  }

  .hero-carousel {
    min-height: 500px;
    margin-top: 16px;
  }

  .hero-slide {
    padding: 24px;
  }

  .hero-dots {
    left: 24px;
  }

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

  .search-form {
    flex-direction: column;
  }

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

  .rank-item,
  .rank-row {
    grid-template-columns: 42px 1fr;
  }

  .rank-cover {
    display: none;
  }

  .rank-copy,
  .rank-meta {
    grid-column: 2;
  }
}
