:root {
  --cyan-700: #0e7490;
  --cyan-600: #0891b2;
  --cyan-500: #06b6d4;
  --teal-600: #0d9488;
  --slate-950: #020617;
  --slate-900: #0f172a;
  --slate-800: #1e293b;
  --slate-700: #334155;
  --slate-600: #475569;
  --slate-500: #64748b;
  --slate-200: #e2e8f0;
  --slate-100: #f1f5f9;
  --slate-50: #f8fafc;
  --white: #ffffff;
  --shadow: 0 16px 36px rgba(15, 23, 42, 0.12);
  --soft-shadow: 0 8px 22px rgba(15, 23, 42, 0.10);
  --radius: 18px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

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

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

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

button,
input {
  font: inherit;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  color: var(--white);
  background: linear-gradient(90deg, var(--cyan-700), var(--cyan-600), var(--teal-600));
  box-shadow: 0 10px 28px rgba(8, 145, 178, 0.28);
}

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

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

.brand-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 999px;
  color: var(--cyan-700);
  background: rgba(255, 255, 255, 0.96);
  font-weight: 900;
  box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.35);
}

.brand-copy {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
}

.brand-copy strong {
  font-size: 22px;
  letter-spacing: 0.02em;
}

.brand-copy small {
  color: rgba(236, 254, 255, 0.86);
  font-size: 12px;
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 18px;
  white-space: nowrap;
}

.nav-link {
  padding: 8px 0;
  color: rgba(255, 255, 255, 0.92);
  font-weight: 650;
  transition: color 0.2s ease;
}

.nav-link:hover,
.nav-link.is-active {
  color: #cffafe;
}

.header-search,
.mobile-search {
  display: flex;
  align-items: center;
  gap: 8px;
}

.header-search input,
.mobile-search input,
.search-panel input,
.filter-bar input {
  border: 1px solid rgba(255, 255, 255, 0.35);
  outline: none;
  border-radius: 999px;
  padding: 10px 16px;
  background: rgba(255, 255, 255, 0.20);
  color: var(--white);
  min-width: 220px;
  transition: border 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}

.header-search input::placeholder,
.mobile-search input::placeholder {
  color: rgba(236, 254, 255, 0.82);
}

.header-search input:focus,
.mobile-search input:focus {
  background: rgba(255, 255, 255, 0.30);
  box-shadow: 0 0 0 3px rgba(207, 250, 254, 0.28);
}

.header-search button,
.mobile-search button {
  border: 0;
  border-radius: 999px;
  padding: 10px 16px;
  color: var(--cyan-700);
  background: var(--white);
  cursor: pointer;
  font-weight: 700;
}

.menu-toggle {
  display: none;
  border: 0;
  color: var(--white);
  background: transparent;
  font-size: 28px;
  cursor: pointer;
}

.mobile-panel {
  display: none;
  padding: 0 16px 18px;
}

.mobile-nav {
  display: grid;
  gap: 8px;
  margin-top: 12px;
}

.mobile-link {
  padding: 10px 12px;
  border-radius: 12px;
  color: rgba(255, 255, 255, 0.92);
  background: rgba(255, 255, 255, 0.12);
}

.mobile-link.is-active,
.mobile-link:hover {
  background: rgba(255, 255, 255, 0.22);
}

.hero-slider {
  position: relative;
  height: min(720px, 72vh);
  min-height: 520px;
  overflow: hidden;
  color: var(--white);
  background: var(--slate-950);
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transform: scale(1.02);
  transition: opacity 0.65s ease, transform 0.65s ease;
  pointer-events: none;
}

.hero-slide.is-active {
  opacity: 1;
  transform: scale(1);
  pointer-events: auto;
}

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

.hero-overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(2, 6, 23, 0.92) 0%, rgba(2, 6, 23, 0.68) 42%, rgba(2, 6, 23, 0.18) 100%),
    linear-gradient(0deg, rgba(2, 6, 23, 0.78) 0%, rgba(2, 6, 23, 0.06) 60%);
}

.hero-content {
  position: absolute;
  inset: auto 0 72px 0;
  display: grid;
  max-width: 1180px;
  gap: 18px;
}

.hero-pill,
.detail-pill {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  border-radius: 999px;
  padding: 6px 12px;
  color: var(--white);
  background: var(--cyan-600);
  box-shadow: 0 8px 20px rgba(8, 145, 178, 0.28);
  font-size: 14px;
  font-weight: 700;
}

.hero-content h1,
.hero-content h2 {
  max-width: 860px;
  margin: 0;
  font-size: clamp(36px, 6vw, 72px);
  line-height: 1.05;
  letter-spacing: -0.04em;
}

.hero-content p {
  max-width: 740px;
  margin: 0;
  color: rgba(241, 245, 249, 0.92);
  font-size: clamp(17px, 2vw, 22px);
}

.hero-actions,
.category-overview-head,
.filter-bar,
.search-panel,
.search-cats,
.detail-meta,
.tag-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 0;
  border-radius: 999px;
  padding: 12px 20px;
  cursor: pointer;
  font-weight: 800;
  transition: transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}

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

.btn-primary {
  color: var(--white);
  background: var(--cyan-600);
  box-shadow: 0 10px 24px rgba(8, 145, 178, 0.25);
}

.btn-primary:hover {
  background: var(--cyan-700);
}

.btn-soft {
  color: var(--cyan-800, #155e75);
  background: #ecfeff;
}

.btn-soft.dark {
  color: var(--cyan-700);
  background: rgba(8, 145, 178, 0.10);
}

.btn-ghost {
  color: var(--white);
  background: rgba(255, 255, 255, 0.16);
  backdrop-filter: blur(10px);
}

.btn.full {
  width: 100%;
}

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

.hero-dot {
  width: 34px;
  height: 6px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.36);
  cursor: pointer;
}

.hero-dot.is-active {
  background: var(--cyan-500);
}

.section-block {
  padding: 56px 0;
}

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

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

.section-head.slim {
  margin-bottom: 18px;
}

.section-kicker {
  display: inline-block;
  color: var(--cyan-600);
  font-weight: 800;
  font-size: 14px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.section-head h2,
.category-overview-head h2,
.side-card h2,
.detail-content h2,
.search-title-row h2 {
  margin: 4px 0 0;
  color: var(--slate-800);
  font-size: clamp(24px, 3vw, 32px);
  line-height: 1.2;
}

.section-link {
  color: var(--cyan-700);
  font-weight: 800;
}

.scroll-row {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(260px, 320px);
  gap: 20px;
  margin: 0 -16px;
  padding: 4px 16px 18px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
}

.scroll-row .movie-card {
  scroll-snap-align: start;
}

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

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

.movie-card {
  overflow: hidden;
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: var(--soft-shadow);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

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

.card-poster {
  position: relative;
  display: block;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: var(--slate-200);
}

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

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

.card-poster::after {
  content: "";
  position: absolute;
  inset: 0;
  opacity: 0;
  background: linear-gradient(0deg, rgba(2, 6, 23, 0.72), rgba(2, 6, 23, 0.04));
  transition: opacity 0.25s ease;
}

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

.card-type {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 2;
  border-radius: 999px;
  padding: 5px 10px;
  color: var(--white);
  background: rgba(2, 6, 23, 0.72);
  font-size: 12px;
  backdrop-filter: blur(8px);
}

.card-play {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 52px;
  height: 52px;
  border-radius: 999px;
  color: var(--white);
  background: var(--cyan-600);
  opacity: 0;
  transform: translate(-50%, -50%) scale(0.82);
  transition: opacity 0.25s ease, transform 0.25s ease;
}

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

.card-body {
  padding: 18px;
}

.card-body h2 {
  display: -webkit-box;
  min-height: 54px;
  margin: 0 0 8px;
  overflow: hidden;
  color: var(--slate-800);
  font-size: 18px;
  line-height: 1.45;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.card-body h2 a:hover {
  color: var(--cyan-600);
}

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

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

.tag-row {
  margin-top: 12px;
}

.tag-row span {
  border-radius: 999px;
  padding: 4px 9px;
  color: var(--cyan-700);
  background: rgba(8, 145, 178, 0.10);
  font-size: 12px;
  font-weight: 700;
}

.two-column {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 30px;
  align-items: start;
}

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

.category-panel,
.ranking-box,
.category-overview-card,
.side-card,
.detail-content,
.player-card,
.search-panel,
.search-cats {
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: var(--soft-shadow);
}

.category-panel {
  padding: 22px;
}

.category-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
  color: var(--slate-800);
}

.category-title span {
  font-size: 22px;
  font-weight: 900;
}

.category-title small {
  color: var(--cyan-700);
  font-weight: 800;
}

.category-panel p,
.side-card p {
  margin: 0 0 18px;
  color: var(--slate-600);
}

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

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

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

.compact-card img {
  width: 96px;
  height: 60px;
  object-fit: cover;
  border-radius: 10px;
  background: var(--slate-200);
}

.compact-card strong,
.rank-copy strong {
  display: -webkit-box;
  overflow: hidden;
  color: var(--slate-800);
  line-height: 1.35;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.compact-card small,
.rank-copy small {
  display: block;
  margin-top: 4px;
  color: var(--slate-500);
  font-size: 13px;
}

.ranking-box {
  position: sticky;
  top: 96px;
  padding: 22px;
}

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

.rank-item a {
  display: grid;
  grid-template-columns: 42px 86px minmax(0, 1fr);
  align-items: center;
  gap: 12px;
  padding: 8px;
  border-radius: 14px;
  transition: background 0.2s ease;
}

.rank-item a:hover {
  background: var(--slate-50);
}

.rank-no {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 999px;
  color: var(--white);
  background: var(--cyan-600);
  font-weight: 900;
}

.rank-item img {
  width: 86px;
  height: 54px;
  object-fit: cover;
  border-radius: 10px;
  background: var(--slate-200);
}

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

.page-hero {
  padding: 72px 0;
  color: var(--white);
  background:
    radial-gradient(circle at 18% 12%, rgba(34, 211, 238, 0.42), transparent 32%),
    linear-gradient(120deg, var(--slate-900), var(--cyan-700), var(--teal-600));
}

.page-hero h1 {
  max-width: 900px;
  margin: 16px 0 12px;
  font-size: clamp(34px, 5vw, 58px);
  line-height: 1.08;
}

.page-hero p {
  max-width: 760px;
  margin: 0;
  color: rgba(241, 245, 249, 0.92);
  font-size: 18px;
}

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

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

.category-overview {
  display: grid;
  gap: 26px;
  padding: 48px 0;
}

.category-overview-card {
  padding: 28px;
}

.category-overview-head {
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 22px;
}

.category-overview-head p {
  max-width: 720px;
  margin: 8px 0 0;
  color: var(--slate-600);
}

.filter-bar {
  justify-content: space-between;
  margin-bottom: 24px;
  padding: 18px;
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: var(--soft-shadow);
}

.filter-bar label {
  color: var(--slate-700);
  font-weight: 900;
}

.filter-bar input,
.search-panel input {
  flex: 1;
  min-width: 240px;
  border-color: var(--slate-200);
  color: var(--slate-800);
  background: var(--slate-50);
}

.filter-bar input::placeholder,
.search-panel input::placeholder {
  color: var(--slate-500);
}

.search-panel {
  padding: 18px;
  margin-bottom: 16px;
}

.search-cats {
  gap: 10px;
  padding: 16px;
  margin-bottom: 24px;
}

.search-cats button {
  border: 0;
  border-radius: 999px;
  padding: 9px 14px;
  color: var(--cyan-700);
  background: rgba(8, 145, 178, 0.10);
  cursor: pointer;
  font-weight: 800;
}

.search-cats button.is-active,
.search-cats button:hover {
  color: var(--white);
  background: var(--cyan-600);
}

.search-title-row {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 24px;
}

.search-title-row p {
  margin: 0;
  color: var(--slate-600);
}

.movie-detail-wrap {
  padding: 28px 0 56px;
}

.movie-detail-wrap .breadcrumb {
  color: var(--slate-600);
}

.movie-detail-wrap .breadcrumb a:hover {
  color: var(--cyan-700);
}

.detail-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 28px;
  align-items: start;
}

.detail-main {
  display: grid;
  gap: 22px;
}

.player-card {
  overflow: hidden;
}

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

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

.player-start {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 3;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 76px;
  height: 76px;
  border: 0;
  border-radius: 999px;
  color: var(--white);
  background: rgba(8, 145, 178, 0.92);
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.35);
  cursor: pointer;
  transform: translate(-50%, -50%);
  transition: transform 0.2s ease, background 0.2s ease, opacity 0.2s ease;
}

.player-start span {
  margin-left: 4px;
  font-size: 34px;
}

.player-start:hover {
  background: var(--cyan-500);
  transform: translate(-50%, -50%) scale(1.05);
}

.player-shell.is-playing .player-start {
  opacity: 0;
  pointer-events: none;
}

.player-message {
  position: absolute;
  left: 24px;
  right: 24px;
  bottom: 24px;
  display: none;
  border-radius: 12px;
  padding: 12px 14px;
  color: var(--white);
  background: rgba(15, 23, 42, 0.82);
}

.player-message.is-visible {
  display: block;
}

.detail-content {
  padding: 28px;
}

.detail-content h1 {
  margin: 14px 0;
  color: var(--slate-800);
  font-size: clamp(30px, 4vw, 46px);
  line-height: 1.12;
}

.detail-meta {
  padding-bottom: 18px;
  margin-bottom: 18px;
  border-bottom: 1px solid var(--slate-200);
  color: var(--slate-600);
  font-size: 14px;
}

.detail-tags {
  margin-bottom: 24px;
}

.detail-content h2 {
  margin: 26px 0 12px;
  font-size: 23px;
}

.detail-content p {
  margin: 0 0 14px;
  color: var(--slate-700);
}

.review-box {
  border-radius: 16px;
  padding: 20px;
  background: linear-gradient(135deg, var(--slate-50), #ecfeff);
}

.review-box p {
  margin: 0;
}

.detail-side {
  display: grid;
  gap: 18px;
  position: sticky;
  top: 96px;
}

.side-card {
  padding: 22px;
}

.side-card h2 {
  margin-bottom: 16px;
  font-size: 22px;
}

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

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

.footer-brand {
  margin-bottom: 14px;
  color: var(--white);
  font-size: 22px;
}

.site-footer p {
  margin: 0 0 12px;
  color: #94a3b8;
}

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

.site-footer ul {
  display: grid;
  gap: 9px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.site-footer a:hover {
  color: #67e8f9;
}

.footer-bottom {
  border-top: 1px solid rgba(148, 163, 184, 0.18);
  padding: 20px 16px;
  text-align: center;
}

.footer-bottom p {
  margin: 0;
}

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

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

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

  .header-search {
    display: none;
  }

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

  .mobile-search input {
    min-width: 0;
    flex: 1;
  }

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

  .two-column,
  .detail-grid {
    grid-template-columns: 1fr;
  }

  .ranking-box,
  .detail-side {
    position: static;
  }

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

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

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

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

  .brand-copy strong {
    font-size: 18px;
  }

  .hero-slider {
    height: 620px;
    min-height: 620px;
  }

  .hero-content {
    bottom: 66px;
  }

  .hero-actions {
    align-items: stretch;
    flex-direction: column;
    max-width: 260px;
  }

  .section-block {
    padding: 40px 0;
  }

  .section-head,
  .search-title-row,
  .category-overview-head,
  .filter-bar,
  .search-panel {
    align-items: stretch;
    flex-direction: column;
  }

  .movie-grid,
  .small-grid,
  .category-grid,
  .page-rank-list,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .scroll-row {
    grid-auto-columns: minmax(260px, 86vw);
  }

  .page-hero {
    padding: 54px 0;
  }

  .detail-content,
  .side-card,
  .category-overview-card {
    padding: 20px;
  }

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

  .hide-small {
    display: none;
  }
}
