:root {
  color-scheme: light;
  --brand-blue: #2563eb;
  --brand-blue-dark: #1d4ed8;
  --slate-50: #f8fafc;
  --slate-100: #f1f5f9;
  --slate-200: #e2e8f0;
  --slate-300: #cbd5e1;
  --slate-400: #94a3b8;
  --slate-500: #64748b;
  --slate-600: #475569;
  --slate-700: #334155;
  --slate-800: #1e293b;
  --slate-900: #0f172a;
  --white: #ffffff;
  --radius: 18px;
  --shadow: 0 20px 35px rgba(15, 23, 42, 0.08);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--slate-50);
  color: var(--slate-900);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
  line-height: 1.6;
}

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

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

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.96);
  border-bottom: 1px solid var(--slate-200);
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
  backdrop-filter: blur(12px);
}

.header-inner {
  min-height: 68px;
  display: flex;
  align-items: center;
  gap: 28px;
}

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

.brand-mark {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 12px;
  background: var(--brand-blue);
  color: var(--white);
  box-shadow: 0 10px 20px rgba(37, 99, 235, 0.25);
}

.brand-text {
  display: flex;
  flex-direction: column;
}

.brand-text strong {
  font-size: 20px;
  line-height: 1.1;
  letter-spacing: -0.03em;
}

.brand-text small {
  margin-top: 2px;
  color: var(--slate-500);
  font-size: 11px;
  letter-spacing: 0.08em;
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 26px;
  color: var(--slate-700);
  font-weight: 600;
}

.desktop-nav a:hover,
.mobile-nav a:hover,
.mobile-category-links a:hover {
  color: var(--brand-blue);
}

.top-search {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 8px;
}

.top-search input,
.mobile-search input,
.filter-bar input,
.filter-bar select {
  border: 1px solid var(--slate-200);
  background: var(--slate-100);
  color: var(--slate-900);
  border-radius: 12px;
  padding: 10px 12px;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.top-search input:focus,
.mobile-search input:focus,
.filter-bar input:focus,
.filter-bar select:focus {
  background: var(--white);
  border-color: var(--brand-blue);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.16);
}

.top-search button,
.mobile-search button,
.btn-primary,
.btn-ghost,
.section-more,
.load-link {
  border: 0;
  border-radius: 12px;
  padding: 10px 18px;
  background: var(--brand-blue);
  color: var(--white);
  font-weight: 700;
  cursor: pointer;
  transition: transform 0.2s ease, background 0.2s ease, color 0.2s ease;
}

.top-search button:hover,
.mobile-search button:hover,
.btn-primary:hover,
.section-more:hover,
.load-link:hover {
  background: var(--brand-blue-dark);
  transform: translateY(-1px);
}

.btn-ghost {
  background: rgba(255, 255, 255, 0.12);
  color: var(--white);
  border: 1px solid rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(6px);
}

.btn-ghost:hover {
  background: rgba(255, 255, 255, 0.22);
}

.menu-toggle {
  display: none;
  margin-left: auto;
  border: 0;
  background: var(--slate-100);
  border-radius: 12px;
  padding: 9px 12px;
  color: var(--slate-700);
  font-size: 22px;
  cursor: pointer;
}

.mobile-menu {
  display: none;
  border-top: 1px solid var(--slate-200);
  padding: 16px;
  background: var(--white);
}

.mobile-menu.is-open {
  display: block;
}

.mobile-nav,
.mobile-category-links {
  display: grid;
  gap: 10px;
  margin: 0 auto 14px;
  width: min(1280px, 100%);
}

.mobile-search {
  display: flex;
  gap: 8px;
  width: min(1280px, 100%);
  margin: 0 auto 14px;
}

.mobile-search input {
  flex: 1;
}

.hero-slider {
  position: relative;
  height: 600px;
  overflow: hidden;
  background: var(--slate-900);
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.7s ease;
}

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

.hero-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.5;
  transform: scale(1.02);
}

.hero-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(15, 23, 42, 0.98) 0%, rgba(15, 23, 42, 0.55) 48%, rgba(15, 23, 42, 0.08) 100%);
}

.hero-content {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  color: var(--white);
  max-width: 720px;
}

.hero-eyebrow {
  color: #60a5fa;
  font-weight: 800;
  letter-spacing: 0.08em;
  margin-bottom: 14px;
}

.hero-content h1 {
  margin: 0;
  font-size: clamp(38px, 6vw, 72px);
  line-height: 1.05;
  letter-spacing: -0.06em;
}

.hero-content p {
  width: min(680px, 100%);
  margin: 22px 0 0;
  color: #cbd5e1;
  font-size: 18px;
}

.hero-meta,
.movie-meta,
.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.hero-meta {
  margin-top: 20px;
}

.hero-meta span {
  padding: 7px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  color: #e2e8f0;
  font-size: 14px;
}

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

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

.hero-dot {
  width: 9px;
  height: 9px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.5);
  cursor: pointer;
  transition: width 0.2s ease, background 0.2s ease;
}

.hero-dot.is-active {
  width: 32px;
  background: var(--white);
}

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

.content-section.white {
  background: var(--white);
}

.content-section.soft {
  background: var(--slate-50);
}

.content-section.tint {
  background: linear-gradient(135deg, #eff6ff 0%, var(--slate-50) 100%);
}

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

.section-head h2,
.page-head h1,
.category-hero h1,
.detail-info h1 {
  margin: 0;
  color: var(--slate-900);
  letter-spacing: -0.04em;
}

.section-head h2 {
  font-size: 30px;
}

.section-more {
  padding: 9px 14px;
  font-size: 14px;
}

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

.scroll-row {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(260px, 320px);
  gap: 18px;
  overflow-x: auto;
  padding: 4px 2px 18px;
  scrollbar-width: none;
}

.scroll-row::-webkit-scrollbar {
  display: none;
}

.movie-card {
  min-width: 0;
}

.movie-card-link {
  display: flex;
  height: 100%;
  flex-direction: column;
  overflow: hidden;
  background: var(--white);
  border: 1px solid var(--slate-200);
  border-radius: var(--radius);
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.04);
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.movie-card-link:hover {
  transform: translateY(-5px);
  border-color: rgba(37, 99, 235, 0.35);
  box-shadow: var(--shadow);
}

.poster-frame {
  position: relative;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: linear-gradient(135deg, var(--slate-900), var(--slate-700));
}

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

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

.year-badge {
  position: absolute;
  right: 10px;
  bottom: 10px;
  border-radius: 999px;
  padding: 4px 9px;
  background: rgba(15, 23, 42, 0.82);
  color: var(--white);
  font-size: 12px;
  font-weight: 700;
}

.movie-body {
  display: flex;
  flex: 1;
  flex-direction: column;
  padding: 16px;
}

.movie-body h3 {
  margin: 0 0 8px;
  font-size: 18px;
  line-height: 1.35;
}

.movie-body p {
  margin: 0;
  color: var(--slate-600);
  font-size: 14px;
}

.movie-meta {
  margin-top: 14px;
  color: var(--slate-500);
  font-size: 13px;
}

.movie-meta span + span::before {
  content: "·";
  margin-right: 10px;
  color: var(--slate-300);
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 14px;
}

.tag-row span,
.detail-tags a {
  border-radius: 999px;
  padding: 5px 9px;
  background: var(--slate-100);
  color: var(--slate-700);
  font-size: 12px;
}

.rank-section {
  background: var(--slate-900);
  color: var(--white);
  padding: 64px 0;
}

.rank-section .section-head h2 {
  color: var(--white);
}

.rank-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 10px;
}

.rank-list li a {
  display: grid;
  grid-template-columns: 56px 1fr auto;
  align-items: center;
  gap: 14px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 14px;
  padding: 14px;
  background: rgba(255, 255, 255, 0.05);
  transition: background 0.2s ease, transform 0.2s ease;
}

.rank-list li a:hover {
  background: rgba(255, 255, 255, 0.11);
  transform: translateX(3px);
}

.rank-num {
  color: #93c5fd;
  font-weight: 900;
  font-size: 20px;
}

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

.rank-meta {
  color: #cbd5e1;
  font-size: 13px;
}

.category-hero,
.simple-hero {
  padding: 58px 0;
  background: linear-gradient(135deg, var(--brand-blue) 0%, var(--slate-800) 100%);
  color: var(--white);
}

.category-hero h1,
.simple-hero h1 {
  margin: 0 0 12px;
  color: var(--white);
  font-size: clamp(32px, 5vw, 52px);
}

.category-hero p,
.simple-hero p {
  max-width: 780px;
  margin: 0;
  color: #dbeafe;
}

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

.category-card {
  display: flex;
  min-height: 240px;
  flex-direction: column;
  justify-content: space-between;
  border: 1px solid var(--slate-200);
  border-radius: var(--radius);
  padding: 22px;
  background: var(--white);
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.04);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

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

.category-card h2 {
  margin: 0 0 10px;
  font-size: 22px;
}

.category-card p {
  margin: 0;
  color: var(--slate-600);
}

.category-card .sample-links {
  display: grid;
  gap: 6px;
  margin-top: 18px;
  color: var(--brand-blue);
  font-size: 14px;
}

.filter-bar {
  display: grid;
  grid-template-columns: 1fr 180px 180px;
  gap: 12px;
  margin-bottom: 24px;
}

.player-section {
  background: #000000;
  padding: 32px 0;
}

.player-frame {
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-radius: 20px;
  background: #000000;
  box-shadow: 0 30px 60px rgba(0, 0, 0, 0.3);
}

.player-frame video {
  width: 100%;
  height: 100%;
  background: #000000;
}

.player-cover {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  width: 100%;
  height: 100%;
  border: 0;
  padding: 0;
  background: #000000;
  cursor: pointer;
  overflow: hidden;
}

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

.player-cover img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.55;
}

.play-circle {
  position: relative;
  display: grid;
  place-items: center;
  width: 88px;
  height: 88px;
  border-radius: 999px;
  background: rgba(37, 99, 235, 0.94);
  color: var(--white);
  font-size: 34px;
  box-shadow: 0 20px 40px rgba(37, 99, 235, 0.35);
}

.detail-wrap {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(280px, 1fr);
  gap: 28px;
  padding: 38px 0 64px;
}

.detail-info,
.related-box {
  border: 1px solid var(--slate-200);
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.04);
}

.detail-info {
  padding: 28px;
}

.detail-info h1 {
  font-size: clamp(30px, 5vw, 46px);
  line-height: 1.16;
}

.detail-meta {
  margin: 18px 0 24px;
  color: var(--slate-600);
}

.detail-meta span {
  border-radius: 999px;
  background: var(--slate-100);
  padding: 7px 12px;
  font-size: 14px;
}

.detail-block {
  border-top: 1px solid var(--slate-200);
  padding-top: 24px;
  margin-top: 24px;
}

.detail-block h2,
.related-box h2 {
  margin: 0 0 12px;
  color: var(--slate-900);
  font-size: 20px;
}

.detail-block p {
  margin: 0;
  color: var(--slate-700);
  font-size: 16px;
}

.detail-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.detail-tags a:hover {
  background: var(--slate-200);
}

.related-box {
  position: sticky;
  top: 92px;
  padding: 20px;
}

.related-list {
  display: grid;
  gap: 14px;
}

.mini-card {
  display: grid;
  grid-template-columns: 112px 1fr;
  gap: 12px;
  align-items: center;
}

.mini-card img {
  width: 112px;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  border-radius: 12px;
  background: var(--slate-800);
}

.mini-card strong {
  display: block;
  color: var(--slate-900);
  line-height: 1.35;
}

.mini-card em {
  display: block;
  margin-top: 4px;
  color: var(--slate-500);
  font-style: normal;
  font-size: 13px;
}

.search-empty {
  border: 1px solid var(--slate-200);
  border-radius: var(--radius);
  padding: 48px 24px;
  background: var(--white);
  text-align: center;
  color: var(--slate-600);
}

.site-footer {
  background: var(--slate-900);
  color: #cbd5e1;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 30px;
  padding: 46px 0;
}

.footer-grid h2 {
  margin: 0 0 14px;
  color: var(--white);
  font-size: 17px;
}

.footer-grid p {
  max-width: 340px;
  color: #94a3b8;
}

.footer-grid a:not(.footer-brand) {
  display: block;
  margin: 8px 0;
  color: #cbd5e1;
}

.footer-grid a:hover {
  color: #60a5fa;
}

.footer-brand {
  color: var(--white);
  font-weight: 800;
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding: 18px 0;
  color: #94a3b8;
  text-align: center;
  font-size: 14px;
}

[data-card].is-hidden {
  display: none;
}

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

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

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

  .menu-toggle {
    display: block;
  }

  .hero-slider {
    height: 520px;
  }

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

  .filter-bar,
  .detail-wrap,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .related-box {
    position: static;
  }

  .rank-list li a {
    grid-template-columns: 46px 1fr;
  }

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

@media (max-width: 560px) {
  .container-custom {
    width: min(100% - 24px, 1280px);
  }

  .brand-text strong {
    font-size: 17px;
  }

  .hero-slider {
    height: 500px;
  }

  .hero-content p {
    font-size: 16px;
  }

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

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

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

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