:root {
  --sky-50: #f0f9ff;
  --sky-100: #e0f2fe;
  --sky-500: #0ea5e9;
  --sky-600: #0284c7;
  --blue-50: #eff6ff;
  --blue-100: #dbeafe;
  --blue-600: #2563eb;
  --blue-700: #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;
  --shadow-soft: 0 14px 35px rgba(15, 23, 42, 0.10);
  --shadow-strong: 0 22px 45px rgba(15, 23, 42, 0.18);
  --radius-lg: 18px;
  --radius-xl: 24px;
  --radius-2xl: 32px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--slate-800);
  background: linear-gradient(180deg, var(--slate-50) 0%, #ffffff 100%);
  font-family: 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,
video {
  display: block;
  max-width: 100%;
}

button,
input,
select {
  font: inherit;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 80;
  color: var(--white);
  background: linear-gradient(90deg, var(--sky-600), var(--blue-700));
  box-shadow: 0 12px 28px rgba(2, 132, 199, 0.28);
}

.nav-shell {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
  min-height: 68px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.brand-icon {
  display: grid;
  width: 40px;
  height: 40px;
  place-items: center;
  border-radius: 14px;
  color: var(--sky-600);
  background: var(--white);
  box-shadow: 0 10px 25px rgba(255, 255, 255, 0.25);
}

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

.brand-text small {
  display: block;
  margin-top: 3px;
  color: rgba(255, 255, 255, 0.86);
  font-size: 12px;
}

.primary-nav {
  display: flex;
  align-items: center;
  gap: 22px;
  font-weight: 600;
  white-space: nowrap;
}

.primary-nav a {
  color: rgba(255, 255, 255, 0.92);
  transition: color 0.2s ease, transform 0.2s ease;
}

.primary-nav a:hover {
  color: var(--white);
  transform: translateY(-1px);
}

.header-search {
  position: relative;
  width: min(280px, 26vw);
}

.header-search input {
  width: 100%;
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 999px;
  padding: 10px 44px 10px 18px;
  color: var(--white);
  background: rgba(255, 255, 255, 0.18);
  outline: none;
  backdrop-filter: blur(12px);
}

.header-search input::placeholder {
  color: rgba(255, 255, 255, 0.74);
}

.header-search button {
  position: absolute;
  top: 50%;
  right: 7px;
  width: 34px;
  height: 34px;
  border: 0;
  border-radius: 50%;
  color: var(--sky-600);
  background: var(--white);
  cursor: pointer;
}

.menu-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 14px;
  color: var(--white);
  background: rgba(255, 255, 255, 0.16);
  cursor: pointer;
}

.mobile-panel {
  display: none;
  border-top: 1px solid rgba(255, 255, 255, 0.18);
  padding: 14px 0 18px;
}

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

.mobile-panel a {
  display: block;
  border-radius: 12px;
  padding: 10px 14px;
  color: var(--white);
}

.mobile-panel a:hover {
  background: rgba(255, 255, 255, 0.12);
}

.hero {
  position: relative;
  overflow: hidden;
  padding: 72px 0 78px;
  color: var(--white);
  background: linear-gradient(120deg, var(--sky-600) 0%, var(--blue-600) 48%, var(--blue-700) 100%);
}

.hero::before,
.hero::after {
  position: absolute;
  content: "";
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
  filter: blur(70px);
}

.hero::before {
  top: 5%;
  left: 4%;
  width: 260px;
  height: 260px;
}

.hero::after {
  right: 3%;
  bottom: 1%;
  width: 360px;
  height: 360px;
}

.hero-grid {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(360px, 480px);
  align-items: center;
  gap: 42px;
}

.hero-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 999px;
  padding: 8px 14px;
  color: rgba(255, 255, 255, 0.88);
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(12px);
}

.hero h1 {
  max-width: 760px;
  margin: 24px 0 18px;
  font-size: clamp(40px, 6vw, 68px);
  line-height: 1.08;
  letter-spacing: -0.04em;
}

.hero-lead {
  max-width: 720px;
  margin: 0 0 18px;
  color: var(--blue-100);
  font-size: clamp(19px, 2.4vw, 25px);
}

.hero-copy {
  max-width: 760px;
  margin: 0 0 28px;
  color: rgba(255, 255, 255, 0.92);
  font-size: 17px;
}

.hero-actions,
.section-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  border: 1px solid transparent;
  border-radius: 999px;
  padding: 0 22px;
  font-weight: 800;
  transition: transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}

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

.btn-primary {
  color: var(--sky-600);
  background: var(--white);
  box-shadow: 0 12px 24px rgba(255, 255, 255, 0.24);
}

.btn-primary:hover {
  background: var(--blue-50);
}

.btn-ghost {
  color: var(--white);
  border-color: rgba(255, 255, 255, 0.34);
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(12px);
}

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

.hero-carousel {
  position: relative;
  min-height: 540px;
}

.hero-slide {
  position: absolute;
  inset: 0;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.24);
  border-radius: var(--radius-2xl);
  background: rgba(15, 23, 42, 0.22);
  box-shadow: 0 28px 58px rgba(15, 23, 42, 0.28);
  opacity: 0;
  transform: translateX(32px) scale(0.98);
  transition: opacity 0.5s ease, transform 0.5s ease;
}

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

.hero-slide img {
  width: 100%;
  height: 100%;
  min-height: 540px;
  object-fit: cover;
}

.hero-slide-content {
  position: absolute;
  inset: auto 0 0;
  padding: 34px;
  background: linear-gradient(0deg, rgba(15, 23, 42, 0.92), rgba(15, 23, 42, 0.20) 82%, transparent);
}

.hero-slide-content span {
  display: inline-flex;
  border-radius: 999px;
  padding: 6px 12px;
  color: var(--white);
  background: rgba(14, 165, 233, 0.86);
  font-size: 13px;
  font-weight: 700;
}

.hero-slide-content h2 {
  margin: 13px 0 8px;
  font-size: 28px;
  line-height: 1.2;
}

.hero-slide-content p {
  margin: 0 0 18px;
  color: rgba(255, 255, 255, 0.84);
}

.hero-dots {
  position: absolute;
  right: 28px;
  bottom: 24px;
  z-index: 5;
  display: flex;
  gap: 8px;
}

.hero-dots button {
  width: 10px;
  height: 10px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.46);
  cursor: pointer;
}

.hero-dots button.is-active {
  width: 28px;
  background: var(--white);
}

.section {
  padding: 68px 0;
}

.section-soft {
  background: linear-gradient(90deg, var(--slate-100), var(--slate-50));
}

.section-blue {
  background: linear-gradient(135deg, var(--sky-50), var(--blue-50));
}

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

.section-title {
  margin: 0;
  color: var(--slate-800);
  font-size: clamp(28px, 4vw, 38px);
  line-height: 1.2;
}

.section-text {
  max-width: 760px;
  margin: 9px 0 0;
  color: var(--slate-600);
}

.link-more {
  color: var(--sky-600);
  font-weight: 800;
  white-space: nowrap;
}

.grid {
  display: grid;
  gap: 24px;
}

.grid-featured {
  grid-template-columns: minmax(0, 1.12fr) minmax(300px, 0.88fr);
}

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

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

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

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

.movie-card,
.category-card,
.rank-item,
.info-card {
  display: block;
  overflow: hidden;
  border: 1px solid rgba(226, 232, 240, 0.82);
  border-radius: var(--radius-lg);
  background: var(--white);
  box-shadow: var(--shadow-soft);
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.movie-card:hover,
.category-card:hover,
.rank-item:hover,
.info-card:hover {
  border-color: rgba(14, 165, 233, 0.28);
  box-shadow: var(--shadow-strong);
  transform: translateY(-4px);
}

.movie-card-large {
  min-height: 100%;
}

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

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

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

.poster::after {
  position: absolute;
  inset: 0;
  content: "";
  background: linear-gradient(0deg, rgba(15, 23, 42, 0.48), transparent 62%);
  opacity: 0;
  transition: opacity 0.25s ease;
}

.movie-card:hover .poster::after,
.rank-item:hover .poster::after {
  opacity: 1;
}

.card-badge,
.year-badge,
.rank-badge {
  position: absolute;
  z-index: 3;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
}

.card-badge {
  left: 12px;
  top: 12px;
  padding: 5px 10px;
  color: var(--sky-700, #0369a1);
  background: rgba(224, 242, 254, 0.94);
}

.year-badge {
  right: 12px;
  top: 12px;
  padding: 5px 10px;
  color: var(--white);
  background: rgba(15, 23, 42, 0.72);
}

.play-float {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 4;
  display: grid;
  width: 52px;
  height: 52px;
  place-items: center;
  border-radius: 999px;
  color: var(--white);
  background: var(--sky-500);
  opacity: 0;
  transform: translate(-50%, -50%) scale(0.88);
  transition: opacity 0.24s ease, transform 0.24s ease;
}

.movie-card:hover .play-float,
.rank-item:hover .play-float {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
}

.play-float::before,
.play-icon::before {
  display: block;
  width: 0;
  height: 0;
  margin-left: 4px;
  border-top: 9px solid transparent;
  border-bottom: 9px solid transparent;
  border-left: 15px solid currentColor;
  content: "";
}

.card-body {
  padding: 18px;
}

.movie-card-large .card-body {
  padding: 24px;
}

.card-title {
  display: -webkit-box;
  min-height: 2.6em;
  margin: 0 0 9px;
  overflow: hidden;
  color: var(--slate-800);
  font-size: 19px;
  font-weight: 900;
  line-height: 1.3;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.movie-card-large .card-title {
  font-size: 26px;
}

.card-desc {
  display: -webkit-box;
  margin: 0 0 14px;
  overflow: hidden;
  color: var(--slate-600);
  font-size: 14px;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.meta-line {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: var(--slate-500);
  font-size: 13px;
}

.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.tag {
  border-radius: 10px;
  padding: 5px 9px;
  color: var(--slate-700);
  background: var(--slate-100);
  font-size: 12px;
  font-weight: 700;
}

.tag-sky {
  color: #0369a1;
  background: var(--sky-100);
}

.category-card {
  padding: 26px;
  text-align: center;
}

.category-icon {
  display: grid;
  width: 64px;
  height: 64px;
  margin: 0 auto 14px;
  place-items: center;
  border-radius: 999px;
  color: var(--white);
  background: linear-gradient(135deg, #38bdf8, var(--blue-600));
  font-size: 28px;
  font-weight: 900;
  transition: transform 0.25s ease;
}

.category-card:hover .category-icon {
  transform: scale(1.08);
}

.category-card h3 {
  margin: 0 0 7px;
  font-size: 20px;
}

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

.page-hero {
  padding: 58px 0;
  color: var(--white);
  background: linear-gradient(90deg, var(--sky-500), var(--blue-600));
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 18px;
  color: rgba(255, 255, 255, 0.78);
  font-size: 14px;
}

.breadcrumb a:hover {
  color: var(--white);
}

.page-hero h1 {
  margin: 0 0 12px;
  font-size: clamp(34px, 5vw, 52px);
  line-height: 1.12;
}

.page-hero p {
  max-width: 820px;
  margin: 0;
  color: rgba(255, 255, 255, 0.88);
  font-size: 18px;
}

.toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 28px;
}

.filter-input {
  width: min(420px, 100%);
  border: 1px solid var(--slate-200);
  border-radius: 999px;
  padding: 12px 18px;
  outline: none;
  background: var(--white);
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.06);
}

.filter-input:focus {
  border-color: var(--sky-500);
}

.sort-group {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.sort-group button {
  border: 1px solid var(--slate-200);
  border-radius: 12px;
  padding: 10px 14px;
  color: var(--slate-600);
  background: var(--white);
  cursor: pointer;
}

.sort-group button.is-active,
.sort-group button:hover {
  color: var(--white);
  border-color: var(--sky-500);
  background: var(--sky-500);
}

.result-count {
  color: var(--slate-500);
  font-size: 14px;
}

.rank-list {
  display: grid;
  gap: 18px;
}

.rank-item {
  display: grid;
  grid-template-columns: 190px minmax(0, 1fr) auto;
  align-items: center;
  gap: 22px;
  padding: 14px;
}

.rank-item .poster {
  border-radius: 14px;
}

.rank-number {
  display: grid;
  width: 54px;
  height: 54px;
  place-items: center;
  border-radius: 18px;
  color: var(--white);
  background: linear-gradient(135deg, var(--sky-500), var(--blue-600));
  font-size: 20px;
  font-weight: 900;
}

.rank-content h2 {
  margin: 0 0 8px;
  font-size: 22px;
}

.rank-content p {
  margin: 0 0 10px;
  color: var(--slate-600);
}

.rank-score {
  color: var(--sky-600);
  font-weight: 900;
  white-space: nowrap;
}

.detail-wrap {
  padding: 34px 0 76px;
}

.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 30px;
}

.player-card,
.detail-card,
.sidebar-card {
  border: 1px solid rgba(226, 232, 240, 0.86);
  border-radius: var(--radius-xl);
  background: var(--white);
  box-shadow: var(--shadow-soft);
}

.player-card {
  overflow: hidden;
  margin-bottom: 24px;
}

.player-shell {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16 / 9;
  background: #000000;
}

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

.play-overlay {
  position: absolute;
  inset: 0;
  z-index: 5;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  border: 0;
  color: var(--white);
  background: radial-gradient(circle at center, rgba(14, 165, 233, 0.24), rgba(15, 23, 42, 0.72));
  cursor: pointer;
  transition: opacity 0.22s ease, visibility 0.22s ease;
}

.play-overlay.is-hidden {
  visibility: hidden;
  opacity: 0;
  pointer-events: none;
}

.play-icon {
  display: grid;
  width: 88px;
  height: 88px;
  place-items: center;
  border-radius: 999px;
  color: var(--white);
  background: var(--sky-500);
  box-shadow: 0 20px 38px rgba(14, 165, 233, 0.36);
}

.play-overlay span:last-child {
  font-size: 18px;
  font-weight: 900;
}

.detail-card {
  padding: 28px;
}

.detail-card h1 {
  margin: 14px 0;
  font-size: clamp(30px, 4vw, 44px);
  line-height: 1.18;
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 0 0 22px;
  padding-bottom: 22px;
  border-bottom: 1px solid var(--slate-200);
  color: var(--slate-600);
}

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

.detail-section {
  margin-top: 26px;
}

.detail-section h2 {
  margin: 0 0 12px;
  color: var(--slate-800);
  font-size: 23px;
}

.detail-section p {
  margin: 0;
  color: var(--slate-700);
  font-size: 17px;
  line-height: 1.9;
}

.review-box {
  border-radius: 18px;
  padding: 20px;
  background: linear-gradient(90deg, var(--sky-50), var(--blue-50));
}

.sidebar-card {
  position: sticky;
  top: 92px;
  padding: 22px;
}

.sidebar-card h2 {
  margin: 0 0 16px;
  font-size: 22px;
}

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

.compact-card {
  display: grid;
  grid-template-columns: 112px minmax(0, 1fr);
  gap: 12px;
  border-radius: 14px;
  padding: 8px;
  transition: background 0.2s ease;
}

.compact-card:hover {
  background: var(--slate-50);
}

.compact-card img {
  width: 112px;
  height: 72px;
  border-radius: 12px;
  object-fit: cover;
  background: var(--slate-900);
}

.compact-card h3 {
  display: -webkit-box;
  margin: 0 0 5px;
  overflow: hidden;
  font-size: 14px;
  line-height: 1.35;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.compact-card p {
  margin: 0;
  color: var(--slate-500);
  font-size: 12px;
}

.cta-panel {
  overflow: hidden;
  border-radius: var(--radius-2xl);
  padding: 48px 32px;
  color: var(--white);
  text-align: center;
  background: linear-gradient(90deg, var(--sky-500), var(--blue-600));
  box-shadow: var(--shadow-strong);
}

.cta-panel h2 {
  margin: 0 0 12px;
  font-size: clamp(30px, 5vw, 46px);
}

.cta-panel p {
  max-width: 700px;
  margin: 0 auto 24px;
  color: var(--blue-100);
  font-size: 18px;
}

.site-footer {
  color: var(--white);
  background: linear-gradient(180deg, var(--slate-800), var(--slate-900));
}

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

.footer-grid h3 {
  margin: 0 0 14px;
  color: var(--sky-100);
  font-size: 18px;
}

.footer-grid p,
.footer-grid a {
  color: var(--slate-300);
  font-size: 14px;
}

.footer-links {
  display: grid;
  gap: 8px;
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  border-top: 1px solid rgba(148, 163, 184, 0.24);
  padding: 18px 0 24px;
  color: var(--slate-400);
  font-size: 13px;
}

.empty-state {
  display: none;
  border: 1px dashed var(--slate-300);
  border-radius: var(--radius-lg);
  padding: 44px;
  color: var(--slate-500);
  text-align: center;
  background: var(--white);
}

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

@media (max-width: 1050px) {
  .header-search {
    display: none;
  }

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

  .hero-carousel {
    min-height: 440px;
  }

  .hero-slide img {
    min-height: 440px;
  }

  .sidebar-card {
    position: static;
  }

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

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

  .menu-toggle {
    display: inline-grid;
    place-items: center;
  }

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

  .hero {
    padding: 48px 0 56px;
  }

  .hero-carousel {
    min-height: 360px;
  }

  .hero-slide img {
    min-height: 360px;
  }

  .hero-slide-content {
    padding: 24px;
  }

  .grid-two,
  .grid-three,
  .grid-four,
  .grid-five {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .rank-item {
    grid-template-columns: 128px minmax(0, 1fr);
  }

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

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

  .footer-bottom {
    flex-direction: column;
  }
}

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

  .brand-icon {
    width: 36px;
    height: 36px;
  }

  .brand-text small {
    display: none;
  }

  .hero h1 {
    font-size: 38px;
  }

  .hero-carousel {
    min-height: 320px;
  }

  .hero-slide img {
    min-height: 320px;
  }

  .section {
    padding: 48px 0;
  }

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

  .grid-two,
  .grid-three,
  .grid-four,
  .grid-five {
    grid-template-columns: 1fr;
  }

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

  .rank-score {
    grid-column: auto;
  }

  .detail-card {
    padding: 22px;
  }

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