:root {
  color-scheme: light;
  --sky: #0ea5e9;
  --sky-dark: #0369a1;
  --pink: #db2777;
  --amber: #f59e0b;
  --ink: #0f172a;
  --muted: #64748b;
  --line: #e2e8f0;
  --soft: #f8fafc;
  --card: #ffffff;
  --shadow: 0 18px 45px rgba(15, 23, 42, 0.10);
  --radius: 22px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  color: var(--ink);
  background: linear-gradient(135deg, #f8fafc 0%, #fff7ed 42%, #f0f9ff 100%);
}

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

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

button,
input,
select {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(18px);
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.08);
}

.nav-wrap {
  width: min(1200px, calc(100% - 32px));
  height: 76px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 22px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.brand-mark {
  width: 38px;
  height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 13px;
  color: #fff;
  font-weight: 900;
  background: linear-gradient(135deg, var(--sky), var(--pink));
  box-shadow: 0 12px 25px rgba(14, 165, 233, 0.30);
}

.brand-text {
  font-size: 22px;
  font-weight: 900;
  letter-spacing: -0.03em;
  background: linear-gradient(90deg, var(--sky-dark), var(--pink));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  white-space: nowrap;
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 18px;
  color: #334155;
  font-weight: 700;
  font-size: 15px;
  flex: 1;
}

.desktop-nav a,
.mobile-panel a,
.footer-links a {
  transition: color 0.2s ease, transform 0.2s ease;
}

.desktop-nav a:hover,
.mobile-panel a:hover,
.footer-links a:hover {
  color: var(--sky-dark);
}

.search-form {
  position: relative;
  display: flex;
  align-items: center;
  gap: 8px;
}

.search-form input,
.mobile-search input,
.filter-bar input,
.filter-bar select {
  border: 1px solid var(--line);
  outline: none;
  border-radius: 999px;
  padding: 11px 16px;
  background: #fff;
  color: var(--ink);
  transition: box-shadow 0.2s ease, border-color 0.2s ease;
}

.search-form input {
  width: 210px;
}

.search-form input:focus,
.mobile-search input:focus,
.filter-bar input:focus,
.filter-bar select:focus {
  border-color: var(--sky);
  box-shadow: 0 0 0 4px rgba(14, 165, 233, 0.15);
}

.search-form button,
.mobile-search button,
.primary-btn,
.ghost-btn,
.player-button,
.filter-bar button {
  border: 0;
  cursor: pointer;
  border-radius: 999px;
  font-weight: 800;
}

.search-form button,
.mobile-search button,
.primary-btn,
.filter-bar button {
  color: #fff;
  background: linear-gradient(135deg, var(--sky), var(--pink));
  box-shadow: 0 12px 26px rgba(14, 165, 233, 0.25);
}

.search-form button,
.mobile-search button {
  padding: 10px 16px;
}

.primary-btn,
.ghost-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 22px;
  min-height: 48px;
}

.ghost-btn {
  color: var(--sky-dark);
  background: rgba(255, 255, 255, 0.90);
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.10);
}

.menu-toggle {
  display: none;
  margin-left: auto;
  border: 0;
  background: transparent;
  color: #334155;
  font-size: 28px;
}

.mobile-panel {
  display: none;
  width: min(1200px, calc(100% - 32px));
  margin: 0 auto;
  padding: 0 0 18px;
  border-top: 1px solid var(--line);
}

.mobile-panel.is-open {
  display: grid;
  gap: 14px;
}

.mobile-search {
  display: flex;
  gap: 8px;
  padding-top: 16px;
}

.mobile-search input {
  flex: 1;
}

.hero {
  position: relative;
  min-height: 610px;
  overflow: hidden;
  background: linear-gradient(135deg, #38bdf8 0%, #f9a8d4 52%, #fde68a 100%);
}

.hero::before,
.hero::after {
  content: "";
  position: absolute;
  border-radius: 999px;
  filter: blur(50px);
  opacity: 0.45;
  background: #fff;
}

.hero::before {
  width: 240px;
  height: 240px;
  top: 8%;
  left: 8%;
}

.hero::after {
  width: 340px;
  height: 340px;
  right: 8%;
  bottom: 8%;
}

.hero-inner {
  position: relative;
  z-index: 2;
  width: min(1200px, calc(100% - 32px));
  min-height: 610px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(300px, 0.92fr);
  gap: 48px;
  align-items: center;
}

.hero-slide {
  display: none;
  animation: fadeUp 0.7s ease both;
}

.hero-slide.active {
  display: contents;
}

.hero-copy {
  color: #fff;
  text-shadow: 0 14px 35px rgba(15, 23, 42, 0.20);
}

.hero-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 14px;
  border-radius: 999px;
  color: var(--sky-dark);
  background: rgba(255, 255, 255, 0.88);
  font-weight: 900;
  box-shadow: 0 10px 30px rgba(15, 23, 42, 0.10);
}

.hero h1 {
  margin: 20px 0 18px;
  font-size: clamp(38px, 7vw, 72px);
  line-height: 1.02;
  letter-spacing: -0.06em;
}

.hero-copy p {
  max-width: 670px;
  margin: 0 0 28px;
  font-size: clamp(17px, 2vw, 22px);
  color: rgba(255, 255, 255, 0.93);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-bottom: 24px;
}

.hero-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.hero-tags a,
.hero-tags span {
  padding: 8px 13px;
  border-radius: 999px;
  color: #fff;
  background: rgba(255, 255, 255, 0.22);
  border: 1px solid rgba(255, 255, 255, 0.38);
  backdrop-filter: blur(10px);
}

.hero-art {
  position: relative;
}

.hero-poster {
  width: min(360px, 82vw);
  margin: 0 auto;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  border-radius: 30px;
  box-shadow: 0 30px 70px rgba(15, 23, 42, 0.28);
  background: linear-gradient(135deg, #e0f2fe, #fce7f3);
}

.hero-card-stack {
  position: absolute;
  left: 0;
  bottom: 34px;
  width: 240px;
  padding: 18px;
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.86);
  box-shadow: var(--shadow);
  backdrop-filter: blur(14px);
}

.hero-card-stack strong {
  display: block;
  color: var(--ink);
  margin-bottom: 6px;
}

.hero-card-stack span {
  color: var(--muted);
  font-size: 14px;
}

.hero-controls {
  position: absolute;
  z-index: 5;
  left: 50%;
  bottom: 30px;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 10px;
}

.hero-dot,
.hero-arrow {
  border: 0;
  cursor: pointer;
  color: #fff;
  background: rgba(255, 255, 255, 0.30);
  backdrop-filter: blur(12px);
  box-shadow: 0 10px 25px rgba(15, 23, 42, 0.12);
}

.hero-dot {
  width: 11px;
  height: 11px;
  border-radius: 999px;
  padding: 0;
}

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

.hero-arrow {
  width: 38px;
  height: 38px;
  border-radius: 999px;
  font-size: 19px;
}

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

.content-section,
.page-hero,
.detail-layout,
.category-panel,
.search-panel,
.rank-panel {
  margin: 34px 0;
}

.section-head,
.page-hero {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 22px;
}

.section-head h2,
.page-hero h1,
.detail-info h1 {
  margin: 0;
  font-size: clamp(28px, 4vw, 42px);
  letter-spacing: -0.04em;
}

.section-head p,
.page-hero p {
  margin: 8px 0 0;
  color: var(--muted);
  max-width: 760px;
}

.section-more {
  color: var(--sky-dark);
  font-weight: 900;
  white-space: nowrap;
}

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

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

.movie-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 22px 50px rgba(15, 23, 42, 0.14);
}

.poster-link {
  position: relative;
  display: block;
  overflow: hidden;
  background: linear-gradient(135deg, #e0f2fe, #fce7f3);
}

.poster-link img {
  width: 100%;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  transition: transform 0.35s ease;
}

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

.score {
  position: absolute;
  right: 12px;
  top: 12px;
  padding: 6px 10px;
  border-radius: 999px;
  color: #fff;
  font-weight: 900;
  background: linear-gradient(135deg, var(--amber), var(--pink));
  box-shadow: 0 12px 20px rgba(15, 23, 42, 0.18);
}

.card-body {
  padding: 17px;
}

.card-title {
  display: block;
  font-size: 18px;
  line-height: 1.35;
  font-weight: 900;
  margin-bottom: 8px;
}

.meta-line {
  color: var(--muted);
  font-size: 13px;
  margin-bottom: 10px;
}

.card-body p {
  min-height: 48px;
  margin: 0 0 12px;
  color: #475569;
  font-size: 14px;
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 12px;
}

.tag-row span,
.pill {
  display: inline-flex;
  align-items: center;
  padding: 5px 9px;
  border-radius: 999px;
  color: var(--sky-dark);
  background: #e0f2fe;
  font-size: 12px;
  font-weight: 800;
}

.card-category {
  color: var(--pink);
  font-weight: 900;
  font-size: 13px;
}

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

.category-tile,
.rank-item,
.info-card {
  background: rgba(255, 255, 255, 0.88);
  border: 1px solid rgba(226, 232, 240, 0.8);
  border-radius: var(--radius);
  padding: 22px;
  box-shadow: 0 12px 34px rgba(15, 23, 42, 0.08);
}

.category-tile {
  min-height: 190px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.category-tile strong {
  font-size: 22px;
}

.category-tile p {
  color: var(--muted);
  margin: 10px 0 18px;
}

.rank-list {
  display: grid;
  gap: 14px;
  margin-top: 22px;
}

.rank-item {
  display: grid;
  grid-template-columns: 54px 80px 1fr auto;
  gap: 18px;
  align-items: center;
}

.rank-num {
  width: 44px;
  height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-weight: 900;
  border-radius: 15px;
  background: linear-gradient(135deg, var(--sky), var(--pink));
}

.rank-item img {
  width: 80px;
  height: 112px;
  object-fit: cover;
  border-radius: 14px;
  background: linear-gradient(135deg, #e0f2fe, #fce7f3);
}

.rank-item h3 {
  margin: 0 0 8px;
  font-size: 20px;
}

.rank-item p {
  margin: 0;
  color: var(--muted);
}

.filter-bar {
  display: grid;
  grid-template-columns: 1.4fr repeat(3, minmax(130px, 0.5fr)) auto;
  gap: 12px;
  margin-top: 22px;
  padding: 18px;
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.86);
  box-shadow: var(--shadow);
}

.filter-bar button {
  padding: 0 18px;
}

.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.75fr) minmax(280px, 0.75fr);
  gap: 28px;
}

.player-shell {
  position: relative;
  overflow: hidden;
  border-radius: 26px;
  background: #020617;
  box-shadow: 0 30px 70px rgba(15, 23, 42, 0.28);
}

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

.player-cover {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, rgba(15, 23, 42, 0.18), rgba(15, 23, 42, 0.62));
  z-index: 2;
}

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

.player-button {
  width: 86px;
  height: 86px;
  color: var(--sky-dark);
  font-size: 36px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 18px 38px rgba(15, 23, 42, 0.28);
}

.detail-info,
.detail-aside {
  margin-top: 22px;
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.90);
  box-shadow: 0 15px 45px rgba(15, 23, 42, 0.09);
  padding: 24px;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  color: var(--muted);
  font-size: 14px;
  margin: 28px 0 0;
}

.breadcrumb a {
  color: var(--sky-dark);
  font-weight: 800;
}

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

.detail-info h2,
.detail-aside h2 {
  margin: 26px 0 10px;
  font-size: 24px;
}

.detail-info p {
  color: #334155;
  line-height: 1.9;
}

.aside-poster {
  width: 100%;
  border-radius: 22px;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  background: linear-gradient(135deg, #e0f2fe, #fce7f3);
}

.related-list {
  display: grid;
  gap: 12px;
  margin-top: 16px;
}

.related-list a {
  display: grid;
  grid-template-columns: 64px 1fr;
  gap: 12px;
  align-items: center;
  padding: 10px;
  border-radius: 16px;
  background: #f8fafc;
}

.related-list img {
  width: 64px;
  height: 88px;
  object-fit: cover;
  border-radius: 12px;
  background: linear-gradient(135deg, #e0f2fe, #fce7f3);
}

.related-list strong {
  display: block;
  margin-bottom: 5px;
}

.related-list span {
  color: var(--muted);
  font-size: 13px;
}

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

.footer-inner {
  width: min(1200px, calc(100% - 32px));
  margin: 0 auto;
  padding: 36px 0;
  display: grid;
  grid-template-columns: 1fr 1.6fr;
  gap: 28px;
}

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

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 18px;
  justify-content: flex-end;
}

.empty-state {
  display: none;
  margin-top: 28px;
  padding: 30px;
  text-align: center;
  border-radius: var(--radius);
  background: #fff;
  color: var(--muted);
}

.empty-state.is-visible {
  display: block;
}

@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(18px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 1080px) {
  .desktop-nav,
  .search-form {
    display: none;
  }

  .menu-toggle {
    display: block;
  }

  .hero-inner,
  .detail-layout,
  .footer-inner {
    grid-template-columns: 1fr;
  }

  .hero-inner {
    padding: 48px 0 80px;
  }

  .hero-art {
    order: -1;
  }

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

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

  .filter-bar {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 720px) {
  .nav-wrap {
    height: 68px;
  }

  .brand-text {
    font-size: 19px;
  }

  .hero {
    min-height: auto;
  }

  .hero-inner {
    min-height: auto;
    gap: 28px;
  }

  .hero-copy {
    text-align: center;
  }

  .hero-actions,
  .hero-tags {
    justify-content: center;
  }

  .hero-card-stack {
    position: static;
    width: auto;
    margin-top: -24px;
  }

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

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

  .card-body {
    padding: 14px;
  }

  .card-title {
    font-size: 16px;
  }

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

  .rank-item .primary-btn {
    grid-column: 2 / -1;
  }

  .rank-item img {
    width: 62px;
    height: 88px;
  }

  .filter-bar {
    grid-template-columns: 1fr;
  }

  .footer-links {
    justify-content: flex-start;
  }
}

@media (max-width: 450px) {
  .movie-grid,
  .category-grid {
    grid-template-columns: 1fr;
  }
}
