:root {
  --color-blue: #2563eb;
  --color-cyan: #0891b2;
  --color-slate-50: #f8fafc;
  --color-slate-100: #f1f5f9;
  --color-slate-900: #0f172a;
  --color-gray-50: #f9fafb;
  --color-gray-100: #f3f4f6;
  --color-gray-200: #e5e7eb;
  --color-gray-500: #6b7280;
  --color-gray-700: #374151;
  --color-gray-900: #111827;
  --radius-lg: 18px;
  --radius-md: 14px;
  --shadow-md: 0 12px 30px rgba(15, 23, 42, 0.10);
  --shadow-lg: 0 22px 60px rgba(15, 23, 42, 0.18);
  --container: 1240px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  color: var(--color-gray-900);
  background: linear-gradient(135deg, var(--color-slate-50), var(--color-slate-100));
  line-height: 1.6;
}

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

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

button,
input,
select {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(18px);
  border-bottom: 1px solid rgba(226, 232, 240, 0.82);
  box-shadow: 0 6px 26px rgba(15, 23, 42, 0.06);
}

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

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

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.brand-mark {
  display: grid;
  width: 46px;
  height: 46px;
  place-items: center;
  color: #fff;
  font-weight: 900;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--color-blue), var(--color-cyan));
  box-shadow: 0 14px 30px rgba(37, 99, 235, 0.32);
}

.brand-title {
  display: block;
  font-size: 20px;
  font-weight: 900;
  letter-spacing: -0.04em;
  background: linear-gradient(135deg, var(--color-blue), var(--color-cyan));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.brand-subtitle {
  display: block;
  margin-top: -3px;
  color: var(--color-gray-500);
  font-size: 12px;
}

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

.nav a {
  padding: 10px 14px;
  color: var(--color-gray-700);
  border-radius: 12px;
  font-weight: 700;
  transition: color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

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

.nav-toggle {
  display: none;
  border: 0;
  color: var(--color-gray-700);
  background: var(--color-gray-100);
  border-radius: 12px;
  padding: 10px 12px;
}

.mobile-nav {
  display: none;
  border-top: 1px solid var(--color-gray-200);
  padding: 12px 0 18px;
}

.mobile-nav a {
  display: block;
  padding: 12px 16px;
  margin: 6px 0;
  border-radius: 12px;
  background: #fff;
  color: var(--color-gray-700);
  font-weight: 800;
}

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

.hero {
  position: relative;
  overflow: hidden;
  color: #fff;
  background: linear-gradient(135deg, #1d4ed8, #0891b2 48%, #0f172a);
}

.hero::before,
.hero::after {
  position: absolute;
  content: "";
  width: 420px;
  height: 420px;
  border-radius: 999px;
  filter: blur(16px);
  opacity: 0.35;
  pointer-events: none;
}

.hero::before {
  top: -160px;
  left: -120px;
  background: #93c5fd;
}

.hero::after {
  right: -160px;
  bottom: -200px;
  background: #22d3ee;
}

.hero-shell {
  position: relative;
  z-index: 1;
  min-height: 620px;
  padding: 62px 0;
  display: grid;
  align-items: center;
}

.hero-slide {
  display: none;
  grid-template-columns: 1.08fr 0.92fr;
  gap: 46px;
  align-items: center;
}

.hero-slide.is-active {
  display: grid;
}

.hero-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 13px;
  margin-bottom: 18px;
  color: #dbeafe;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
}

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

.hero-text {
  max-width: 760px;
  margin: 0 0 22px;
  color: #e0f2fe;
  font-size: 18px;
}

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

.pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 11px;
  border-radius: 999px;
  color: #dbeafe;
  background: rgba(15, 23, 42, 0.28);
  border: 1px solid rgba(255, 255, 255, 0.14);
  font-size: 13px;
  font-weight: 800;
}

.hero-actions,
.section-actions,
.form-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
}

.hero-actions {
  margin-top: 30px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 11px 18px;
  border-radius: 14px;
  border: 1px solid transparent;
  font-weight: 900;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

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

.btn-primary {
  color: var(--color-blue);
  background: #fff;
  box-shadow: 0 18px 40px rgba(15, 23, 42, 0.18);
}

.btn-dark {
  color: #fff;
  background: linear-gradient(135deg, var(--color-blue), var(--color-cyan));
  box-shadow: 0 18px 40px rgba(37, 99, 235, 0.22);
}

.btn-ghost {
  color: #fff;
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.28);
}

.btn-outline {
  color: var(--color-blue);
  background: #fff;
  border-color: #bfdbfe;
}

.hero-poster-wrap {
  position: relative;
  justify-self: end;
  width: min(100%, 390px);
}

.hero-poster-card {
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.12);
  box-shadow: 0 30px 80px rgba(15, 23, 42, 0.35);
  transform: rotate(2deg);
}

.hero-poster-card img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
}

.hero-poster-caption {
  padding: 18px;
  background: rgba(15, 23, 42, 0.86);
}

.hero-poster-caption strong {
  display: block;
  margin-bottom: 6px;
  font-size: 19px;
}

.hero-dots {
  position: relative;
  z-index: 2;
  display: flex;
  gap: 9px;
  margin-top: -44px;
  padding-bottom: 42px;
}

.hero-dot {
  width: 38px;
  height: 8px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.35);
  cursor: pointer;
}

.hero-dot.is-active {
  background: #fff;
}

.search-panel {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  max-width: 720px;
  padding: 8px;
  margin-top: 24px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.26);
}

.search-panel input,
.filter-input,
.filter-select {
  min-height: 46px;
  width: 100%;
  border: 1px solid var(--color-gray-200);
  border-radius: 13px;
  outline: none;
  padding: 0 14px;
  color: var(--color-gray-900);
  background: #fff;
}

.search-panel input:focus,
.filter-input:focus,
.filter-select:focus {
  border-color: #93c5fd;
  box-shadow: 0 0 0 4px rgba(147, 197, 253, 0.26);
}

.page-hero {
  padding: 58px 0;
  color: #fff;
  background: linear-gradient(135deg, var(--color-blue), var(--color-cyan));
}

.page-hero h1 {
  margin: 0 0 12px;
  font-size: clamp(32px, 5vw, 52px);
  line-height: 1.1;
  letter-spacing: -0.04em;
}

.page-hero p {
  max-width: 860px;
  margin: 0;
  color: #dbeafe;
  font-size: 18px;
}

.main-space {
  padding: 44px 0 68px;
}

.section {
  margin-top: 54px;
}

.section:first-child {
  margin-top: 0;
}

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

.section-title {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0;
  color: var(--color-gray-900);
  font-size: clamp(24px, 4vw, 34px);
  line-height: 1.15;
  letter-spacing: -0.04em;
}

.section-title::before {
  display: inline-block;
  content: "";
  width: 6px;
  height: 34px;
  border-radius: 999px;
  background: linear-gradient(180deg, var(--color-blue), var(--color-cyan));
}

.section-desc {
  max-width: 760px;
  margin: -8px 0 22px;
  color: var(--color-gray-500);
}

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

.movie-card {
  overflow: hidden;
  background: #fff;
  border: 1px solid rgba(226, 232, 240, 0.9);
  border-radius: 18px;
  box-shadow: 0 10px 30px rgba(15, 23, 42, 0.06);
  transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  border-color: #bfdbfe;
  box-shadow: var(--shadow-lg);
}

.poster-link {
  position: relative;
  display: block;
  overflow: hidden;
  background: #0f172a;
}

.poster-link img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  transition: transform 0.28s ease, opacity 0.28s ease;
}

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

.play-badge {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: var(--color-blue);
  opacity: 0;
  transition: opacity 0.22s ease;
}

.play-badge span {
  display: grid;
  width: 56px;
  height: 56px;
  place-items: center;
  color: var(--color-blue);
  background: #fff;
  border-radius: 999px;
  font-size: 24px;
  box-shadow: 0 20px 38px rgba(15, 23, 42, 0.28);
}

.movie-card:hover .play-badge {
  opacity: 1;
}

.card-region,
.card-year {
  position: absolute;
  top: 10px;
  z-index: 1;
  padding: 5px 8px;
  color: #fff;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 900;
  background: rgba(37, 99, 235, 0.92);
}

.card-region {
  right: 10px;
}

.card-year {
  left: 10px;
  background: rgba(15, 23, 42, 0.78);
}

.card-body {
  padding: 14px;
}

.card-title {
  display: -webkit-box;
  min-height: 44px;
  margin: 0 0 8px;
  overflow: hidden;
  color: var(--color-gray-900);
  font-size: 15px;
  font-weight: 900;
  line-height: 1.45;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.movie-card:hover .card-title {
  color: var(--color-blue);
}

.card-desc {
  display: -webkit-box;
  min-height: 40px;
  margin: 0 0 10px;
  overflow: hidden;
  color: var(--color-gray-500);
  font-size: 13px;
  line-height: 1.5;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.card-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.card-tags span {
  padding: 4px 7px;
  color: var(--color-blue);
  background: #eff6ff;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 800;
}

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

.category-card {
  display: flex;
  min-height: 190px;
  flex-direction: column;
  justify-content: space-between;
  overflow: hidden;
  position: relative;
  padding: 24px;
  color: #fff;
  border-radius: 22px;
  box-shadow: var(--shadow-md);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.category-card:hover {
  transform: translateY(-5px) scale(1.01);
  box-shadow: var(--shadow-lg);
}

.category-card::after {
  position: absolute;
  content: "";
  width: 170px;
  height: 170px;
  right: -46px;
  bottom: -62px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
}

.category-card h2,
.category-card h3 {
  position: relative;
  z-index: 1;
  margin: 0 0 8px;
  font-size: 24px;
}

.category-card p,
.category-card strong {
  position: relative;
  z-index: 1;
}

.category-blue {
  background: linear-gradient(135deg, #2563eb, #06b6d4);
}

.category-red {
  background: linear-gradient(135deg, #dc2626, #f97316);
}

.category-purple {
  background: linear-gradient(135deg, #7c3aed, #db2777);
}

.category-orange {
  background: linear-gradient(135deg, #ea580c, #f59e0b);
}

.category-pink {
  background: linear-gradient(135deg, #db2777, #f43f5e);
}

.category-slate {
  background: linear-gradient(135deg, #0f172a, #475569);
}

.category-cyan {
  background: linear-gradient(135deg, #0891b2, #2563eb);
}

.category-green {
  background: linear-gradient(135deg, #16a34a, #0d9488);
}

.filter-box {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) repeat(3, minmax(150px, 190px));
  gap: 12px;
  align-items: center;
  padding: 18px;
  margin-bottom: 24px;
  border: 1px solid var(--color-gray-200);
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.82);
  box-shadow: 0 10px 30px rgba(15, 23, 42, 0.06);
}

.result-count {
  color: var(--color-gray-500);
  font-weight: 800;
}

.ranking-list {
  display: grid;
  gap: 12px;
}

.ranking-row {
  display: grid;
  grid-template-columns: 74px 84px 1fr auto;
  align-items: center;
  gap: 16px;
  padding: 13px;
  border: 1px solid var(--color-gray-200);
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.05);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.ranking-row:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}

.rank-num {
  display: grid;
  width: 52px;
  height: 52px;
  place-items: center;
  color: #fff;
  border-radius: 16px;
  font-size: 18px;
  font-weight: 900;
  background: linear-gradient(135deg, var(--color-blue), var(--color-cyan));
}

.rank-cover img {
  width: 72px;
  height: 96px;
  object-fit: cover;
  border-radius: 12px;
  background: var(--color-slate-900);
}

.rank-main h2,
.rank-main h3 {
  margin: 0 0 6px;
  font-size: 18px;
}

.rank-main p {
  display: -webkit-box;
  max-width: 760px;
  margin: 0;
  overflow: hidden;
  color: var(--color-gray-500);
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.detail-hero {
  color: #fff;
  background: radial-gradient(circle at 20% 0%, rgba(59, 130, 246, 0.58), transparent 34%), linear-gradient(135deg, #0f172a, #1e3a8a 58%, #0e7490);
}

.detail-layout {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 34px;
  align-items: center;
  padding: 48px 0;
}

.detail-poster {
  width: min(100%, 360px);
  overflow: hidden;
  border-radius: 24px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  box-shadow: 0 28px 70px rgba(0, 0, 0, 0.35);
}

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

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

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

.detail-title {
  margin: 0 0 16px;
  font-size: clamp(34px, 5vw, 58px);
  line-height: 1.04;
  letter-spacing: -0.05em;
}

.detail-summary {
  margin: 0 0 20px;
  color: #dbeafe;
  font-size: 18px;
}

.player-section {
  margin-top: -26px;
  position: relative;
  z-index: 3;
}

.player-card {
  overflow: hidden;
  border-radius: 24px;
  background: #020617;
  box-shadow: 0 28px 80px rgba(15, 23, 42, 0.35);
}

.player-box {
  position: relative;
  background: #000;
  aspect-ratio: 16 / 9;
}

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

.play-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  border: 0;
  color: #fff;
  background: rgba(2, 6, 23, 0.38);
  cursor: pointer;
}

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

.play-overlay-inner {
  display: grid;
  gap: 12px;
  justify-items: center;
  padding: 22px 28px;
  border-radius: 22px;
  background: rgba(15, 23, 42, 0.68);
  backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.18);
}

.play-icon {
  display: grid;
  width: 76px;
  height: 76px;
  place-items: center;
  border-radius: 999px;
  color: var(--color-blue);
  background: #fff;
  font-size: 36px;
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.3);
}

.player-title-bar {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px;
  padding: 18px 22px;
  color: #e5e7eb;
  background: #020617;
}

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

.article-card,
.info-card {
  padding: 24px;
  border: 1px solid var(--color-gray-200);
  border-radius: 22px;
  background: #fff;
  box-shadow: 0 10px 32px rgba(15, 23, 42, 0.06);
}

.article-card h2,
.info-card h2,
.info-card h3 {
  margin: 0 0 14px;
  font-size: 24px;
}

.article-card p,
.info-card p {
  margin: 0;
  color: var(--color-gray-700);
  white-space: pre-line;
}

.info-list {
  display: grid;
  gap: 10px;
}

.info-list div {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--color-gray-100);
}

.info-list span:first-child {
  color: var(--color-gray-500);
}

.info-list span:last-child {
  text-align: right;
  font-weight: 800;
}

.tag-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}

.tag-cloud span {
  padding: 6px 9px;
  border-radius: 999px;
  color: var(--color-blue);
  background: #eff6ff;
  font-size: 13px;
  font-weight: 800;
}

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

.footer-inner {
  display: grid;
  grid-template-columns: 1.2fr repeat(3, 1fr);
  gap: 28px;
  padding: 46px 0;
}

.footer-inner h2,
.footer-inner h3 {
  margin: 0 0 12px;
  color: #fff;
}

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

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

.footer-inner li + li {
  margin-top: 8px;
}

.footer-bottom {
  padding: 20px 0;
  border-top: 1px solid rgba(148, 163, 184, 0.24);
  color: #94a3b8;
  font-size: 14px;
}

.empty-state {
  display: none;
  padding: 42px;
  text-align: center;
  color: var(--color-gray-500);
  border: 1px dashed var(--color-gray-200);
  border-radius: 20px;
  background: #fff;
}

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

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

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

  .content-grid {
    grid-template-columns: 1fr;
  }
}

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

  .nav-toggle {
    display: inline-flex;
  }

  .hero-shell {
    min-height: auto;
    padding: 44px 0 72px;
  }

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

  .hero-poster-wrap {
    justify-self: start;
    width: min(100%, 310px);
  }

  .search-panel,
  .filter-box {
    grid-template-columns: 1fr;
  }

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

  .ranking-row {
    grid-template-columns: 54px 70px 1fr;
  }

  .ranking-row .btn {
    grid-column: 1 / -1;
  }

  .footer-inner {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 560px) {
  .container {
    width: min(100% - 22px, var(--container));
  }

  .header-inner {
    min-height: 66px;
  }

  .brand-mark {
    width: 40px;
    height: 40px;
  }

  .brand-title {
    font-size: 18px;
  }

  .hero-title,
  .detail-title {
    letter-spacing: -0.04em;
  }

  .hero-actions,
  .section-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .btn {
    width: 100%;
  }

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

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

  .card-body {
    padding: 12px;
  }

  .ranking-row {
    grid-template-columns: 48px 64px 1fr;
    gap: 10px;
  }

  .rank-num {
    width: 42px;
    height: 42px;
    border-radius: 13px;
    font-size: 15px;
  }

  .rank-cover img {
    width: 62px;
    height: 82px;
  }

  .footer-inner {
    grid-template-columns: 1fr;
  }
}
