:root {
  --bg: #f6fbfd;
  --paper: #ffffff;
  --paper-soft: #f1fcff;
  --ink: #10202b;
  --muted: #65758b;
  --line: #d8edf4;
  --cyan: #06b6d4;
  --cyan-dark: #0785a1;
  --teal: #14b8a6;
  --blue: #2563eb;
  --gold: #f5b301;
  --shadow: 0 18px 45px rgba(7, 72, 94, 0.13);
  --soft-shadow: 0 10px 28px rgba(15, 81, 104, 0.09);
  --radius-xl: 28px;
  --radius-lg: 20px;
  --radius-md: 14px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  background:
    radial-gradient(circle at top left, rgba(6, 182, 212, 0.16), transparent 36rem),
    linear-gradient(180deg, #f8feff 0%, #edf8fb 44%, #ffffff 100%);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  line-height: 1.6;
}

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

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

button,
input,
select {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(245, 253, 255, 0.92);
  border-bottom: 1px solid rgba(165, 243, 252, 0.75);
  backdrop-filter: blur(18px);
}

.header-inner {
  width: min(1240px, calc(100% - 32px));
  height: 72px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 26px;
}

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

.brand-icon {
  width: 42px;
  height: 42px;
  border-radius: 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  background: linear-gradient(135deg, var(--cyan), var(--teal));
  box-shadow: 0 10px 24px rgba(6, 182, 212, 0.28);
  font-size: 18px;
  line-height: 1;
}

.brand-text {
  display: grid;
  gap: 0;
}

.brand-text strong {
  font-size: 21px;
  letter-spacing: 0.02em;
  background: linear-gradient(90deg, var(--cyan-dark), var(--teal));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.brand-text small {
  color: var(--muted);
  font-size: 12px;
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 22px;
  margin-left: auto;
}

.nav-link {
  position: relative;
  padding: 8px 2px;
  font-weight: 650;
  color: #34495b;
}

.nav-link::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 2px;
  width: 0;
  height: 3px;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--cyan), var(--teal));
  transition: width 0.25s ease;
}

.nav-link:hover,
.nav-link.is-active {
  color: var(--cyan-dark);
}

.nav-link:hover::after,
.nav-link.is-active::after {
  width: 100%;
}

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

.header-search input,
.mobile-search input {
  width: 240px;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 10px 16px;
  color: var(--ink);
  background: #ffffff;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.header-search input:focus,
.mobile-search input:focus,
.filter-bar input:focus,
.filter-bar select:focus {
  border-color: var(--cyan);
  box-shadow: 0 0 0 4px rgba(6, 182, 212, 0.14);
}

.header-search button,
.mobile-search button,
.primary-button,
.secondary-button,
.hero-nav button {
  border: 0;
  border-radius: 999px;
  padding: 10px 18px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--cyan), var(--teal));
  cursor: pointer;
  box-shadow: 0 12px 25px rgba(6, 182, 212, 0.22);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.header-search button:hover,
.mobile-search button:hover,
.primary-button:hover,
.secondary-button:hover,
.hero-nav button:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 32px rgba(6, 182, 212, 0.28);
}

.secondary-button {
  color: var(--cyan-dark);
  background: rgba(255, 255, 255, 0.9);
}

.mobile-menu-button {
  display: none;
  margin-left: auto;
  width: 44px;
  height: 44px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #ffffff;
  cursor: pointer;
}

.mobile-menu-button span {
  display: block;
  width: 20px;
  height: 2px;
  margin: 5px auto;
  border-radius: 99px;
  background: #244052;
}

.mobile-nav {
  display: none;
  width: min(1240px, calc(100% - 32px));
  margin: 0 auto 16px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: #ffffff;
  box-shadow: var(--soft-shadow);
}

.mobile-nav.is-open {
  display: grid;
  gap: 10px;
}

.mobile-link {
  padding: 10px 12px;
  border-radius: 12px;
  color: #34495b;
  font-weight: 650;
}

.mobile-link:hover,
.mobile-link.is-active {
  color: var(--cyan-dark);
  background: var(--paper-soft);
}

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

.hero {
  position: relative;
  min-height: 620px;
  margin: 28px auto 56px;
  overflow: hidden;
  border-radius: var(--radius-xl);
  background: #071923;
  box-shadow: var(--shadow);
}

.hero-track {
  position: relative;
  min-height: 620px;
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: 1.08fr 0.92fr;
  align-items: center;
  gap: 42px;
  padding: 56px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.65s ease;
}

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

.hero-slide::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(4, 18, 27, 0.92), rgba(4, 30, 44, 0.78) 45%, rgba(4, 18, 27, 0.22)),
    radial-gradient(circle at 15% 15%, rgba(20, 184, 166, 0.28), transparent 34rem);
  z-index: 1;
}

.hero-copy,
.hero-art {
  position: relative;
  z-index: 2;
}

.hero-art {
  justify-self: end;
  width: min(480px, 100%);
  aspect-ratio: 16 / 10;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 30px;
  box-shadow: 0 28px 70px rgba(0, 0, 0, 0.38);
  transform: rotate(1.2deg);
}

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

.hero-kicker,
.section-kicker,
.page-kicker {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  margin-bottom: 14px;
  padding: 7px 12px;
  border-radius: 999px;
  color: #0d7484;
  background: rgba(207, 250, 254, 0.9);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.08em;
}

.hero-copy h1 {
  max-width: 780px;
  margin: 0 0 18px;
  color: #ffffff;
  font-size: clamp(36px, 6vw, 72px);
  line-height: 1.04;
  letter-spacing: -0.04em;
}

.hero-copy p {
  max-width: 650px;
  margin: 0 0 24px;
  color: rgba(255, 255, 255, 0.82);
  font-size: 18px;
}

.hero-tags,
.hero-actions,
.tag-row,
.meta-pills {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}

.hero-tags {
  margin-bottom: 28px;
}

.hero-tags span,
.tag-row span,
.meta-pills span {
  border: 1px solid rgba(6, 182, 212, 0.22);
  border-radius: 999px;
  padding: 6px 10px;
  color: #0d7484;
  background: rgba(236, 254, 255, 0.86);
  font-size: 12px;
  font-weight: 700;
}

.hero-tags span {
  color: #cffafe;
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.24);
}

.hero-dots {
  position: absolute;
  left: 56px;
  bottom: 36px;
  z-index: 4;
  display: flex;
  gap: 10px;
}

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

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

.hero-nav {
  position: absolute;
  right: 38px;
  bottom: 30px;
  z-index: 4;
  display: flex;
  gap: 10px;
}

.hero-nav button {
  width: 44px;
  height: 44px;
  padding: 0;
  font-size: 24px;
}

.section {
  margin: 0 0 62px;
}

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

.section-head h2,
.page-head h1,
.detail-title {
  margin: 0;
  color: var(--ink);
  font-size: clamp(28px, 3vw, 44px);
  line-height: 1.15;
  letter-spacing: -0.025em;
}

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

.section-more {
  min-width: max-content;
  color: var(--cyan-dark);
  font-weight: 800;
}

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

.movie-card {
  min-width: 0;
  border: 1px solid rgba(216, 237, 244, 0.85);
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--paper);
  box-shadow: var(--soft-shadow);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

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

.card-link {
  display: block;
  height: 100%;
}

.card-cover {
  position: relative;
  aspect-ratio: 16 / 10;
  margin: 0;
  overflow: hidden;
  background: linear-gradient(135deg, #dff8ff, #e7fff7);
}

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

.movie-card:hover .card-cover img {
  transform: scale(1.08);
}

.card-cover::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 45%, rgba(0, 0, 0, 0.62));
  opacity: 0.9;
}

.card-type,
.rank-badge,
.play-mark {
  position: absolute;
  z-index: 2;
}

.card-type {
  left: 12px;
  bottom: 12px;
  border-radius: 999px;
  padding: 5px 10px;
  color: #ffffff;
  background: rgba(6, 182, 212, 0.94);
  font-size: 12px;
  font-weight: 800;
}

.rank-badge {
  left: 12px;
  top: 12px;
  border-radius: 999px;
  padding: 5px 10px;
  color: #1d2935;
  background: rgba(255, 255, 255, 0.94);
  font-size: 12px;
  font-weight: 900;
}

.play-mark {
  right: 12px;
  bottom: 12px;
  width: 38px;
  height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  color: #ffffff;
  background: rgba(0, 0, 0, 0.48);
  transform: scale(0.9);
  transition: transform 0.2s ease, background 0.2s ease;
}

.movie-card:hover .play-mark {
  transform: scale(1);
  background: var(--cyan);
}

.card-body {
  padding: 16px;
}

.card-body h3 {
  margin: 0 0 8px;
  color: var(--ink);
  font-size: 18px;
  line-height: 1.3;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
}

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

.card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 12px;
  color: #516579;
  font-size: 13px;
  font-weight: 700;
}

.card-meta span {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.card-meta span:last-child::before {
  content: "★";
  color: var(--gold);
}

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

.category-card {
  min-height: 180px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 22px;
  border: 1px solid rgba(216, 237, 244, 0.9);
  border-radius: var(--radius-lg);
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.96), rgba(236, 254, 255, 0.82)),
    radial-gradient(circle at 100% 0, rgba(6, 182, 212, 0.18), transparent 12rem);
  box-shadow: var(--soft-shadow);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

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

.category-card h2,
.category-card h3 {
  margin: 0 0 10px;
  font-size: 24px;
}

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

.category-card span {
  margin-top: 18px;
  color: var(--cyan-dark);
  font-weight: 850;
}

.filter-bar {
  display: grid;
  grid-template-columns: minmax(240px, 1fr) 180px 180px 180px;
  gap: 12px;
  margin: 0 0 24px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: rgba(255, 255, 255, 0.86);
  box-shadow: var(--soft-shadow);
}

.filter-bar input,
.filter-bar select {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 11px 13px;
  color: var(--ink);
  background: #ffffff;
  outline: none;
}

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

.movie-card.is-horizontal .card-link {
  display: grid;
  grid-template-columns: 230px minmax(0, 1fr);
  gap: 0;
  min-height: 150px;
}

.movie-card.is-horizontal .card-cover {
  height: 100%;
  aspect-ratio: auto;
}

.movie-card.is-horizontal .card-body p {
  min-height: 0;
  -webkit-line-clamp: 2;
}

.detail-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) 360px;
  gap: 28px;
  align-items: end;
  margin: 34px 0 34px;
  padding: 34px;
  border-radius: var(--radius-xl);
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.94), rgba(236, 254, 255, 0.74)),
    radial-gradient(circle at top right, rgba(6, 182, 212, 0.18), transparent 24rem);
  box-shadow: var(--soft-shadow);
  border: 1px solid rgba(216, 237, 244, 0.85);
}

.breadcrumb {
  margin-bottom: 16px;
  color: var(--muted);
  font-size: 14px;
}

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

.detail-title {
  margin-bottom: 14px;
}

.detail-summary {
  margin: 0 0 18px;
  color: #485d70;
  font-size: 17px;
}

.detail-cover {
  overflow: hidden;
  border-radius: 24px;
  box-shadow: var(--shadow);
  aspect-ratio: 16 / 10;
  background: linear-gradient(135deg, #dff8ff, #e7fff7);
}

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

.player-shell {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-xl);
  background: #061018;
  box-shadow: var(--shadow);
  margin: 0 0 34px;
}

.player-shell video {
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #03080d;
}

.player-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background:
    linear-gradient(180deg, rgba(3, 8, 13, 0.22), rgba(3, 8, 13, 0.66));
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

.player-shell.is-playing .player-overlay {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.player-button {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  border: 0;
  border-radius: 999px;
  padding: 16px 24px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--cyan), var(--teal));
  cursor: pointer;
  box-shadow: 0 18px 40px rgba(6, 182, 212, 0.28);
  font-size: 18px;
  font-weight: 900;
}

.detail-content {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 28px;
  margin-bottom: 58px;
}

.prose-card,
.side-card {
  border: 1px solid rgba(216, 237, 244, 0.9);
  border-radius: var(--radius-lg);
  background: #ffffff;
  box-shadow: var(--soft-shadow);
  padding: 24px;
}

.prose-card h2,
.side-card h2 {
  margin: 0 0 14px;
  font-size: 24px;
}

.prose-card p {
  margin: 0 0 18px;
  color: #46596c;
}

.side-card {
  height: fit-content;
  position: sticky;
  top: 96px;
}

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

.side-card li a {
  display: block;
  padding: 12px;
  border-radius: 14px;
  background: #f6fbfd;
  color: #34495b;
  font-weight: 750;
}

.side-card li a:hover {
  color: var(--cyan-dark);
  background: #eaffff;
}

.empty-state {
  display: none;
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: #ffffff;
  color: var(--muted);
  text-align: center;
}

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

.site-footer {
  margin-top: 70px;
  color: #d8e9ef;
  background:
    radial-gradient(circle at 10% 0, rgba(6, 182, 212, 0.22), transparent 24rem),
    linear-gradient(135deg, #071923, #0e2a38 58%, #071923);
}

.footer-inner {
  width: min(1240px, calc(100% - 32px));
  margin: 0 auto;
  padding: 42px 0;
  display: grid;
  gap: 24px;
}

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

.footer-brand strong {
  color: #ffffff;
  font-size: 22px;
}

.footer-brand p {
  margin: 5px 0 0;
  color: #9fb7c0;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
}

.footer-links a {
  color: #c7e7ef;
  font-weight: 700;
}

.footer-links a:hover {
  color: #ffffff;
}

.copyright {
  margin: 0;
  color: #8aa6b0;
  font-size: 14px;
}

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

  .mobile-menu-button {
    display: block;
  }

  .hero-slide {
    grid-template-columns: 1fr;
    padding: 38px;
  }

  .hero-art {
    justify-self: start;
    max-width: 540px;
  }

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

  .filter-bar,
  .detail-content,
  .detail-hero {
    grid-template-columns: 1fr;
  }

  .side-card {
    position: static;
  }
}

@media (max-width: 760px) {
  .header-inner {
    width: min(100% - 22px, 1240px);
    height: 66px;
  }

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

  main {
    width: min(100% - 22px, 1240px);
  }

  .hero,
  .hero-track {
    min-height: 680px;
  }

  .hero {
    margin-top: 16px;
    border-radius: 22px;
  }

  .hero-slide {
    padding: 26px;
  }

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

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

  .hero-dots {
    left: 26px;
    bottom: 24px;
  }

  .hero-nav {
    right: 24px;
    bottom: 18px;
  }

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

  .card-body {
    padding: 13px;
  }

  .card-body h3 {
    font-size: 16px;
  }

  .filter-bar {
    padding: 12px;
  }

  .movie-card.is-horizontal .card-link {
    grid-template-columns: 128px minmax(0, 1fr);
  }

  .movie-card.is-horizontal .card-body p,
  .movie-card.is-horizontal .tag-row {
    display: none;
  }

  .detail-hero {
    padding: 22px;
  }

  .player-button {
    padding: 13px 18px;
    font-size: 16px;
  }
}

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

  .hero,
  .hero-track {
    min-height: 720px;
  }

  .hero-copy h1 {
    font-size: 34px;
  }

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