:root {
  --mist-950: #071827;
  --mist-900: #102a43;
  --mist-850: #173653;
  --mist-800: #243b53;
  --mist-700: #334e68;
  --mist-600: #486581;
  --mist-400: #9fb3c8;
  --mist-200: #d9e2ec;
  --swamp-700: #164b51;
  --swamp-600: #20656a;
  --swamp-500: #2d8285;
  --swamp-400: #52a0a3;
  --swamp-300: #7bb8ba;
  --gold: #f5b94c;
  --white: #ffffff;
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.35);
  --radius-xl: 28px;
  --radius-lg: 20px;
  --radius-md: 14px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--mist-200);
  background:
    radial-gradient(circle at top left, rgba(45, 130, 133, 0.22), transparent 36rem),
    linear-gradient(180deg, var(--mist-950), var(--mist-900) 32rem, #0b1f33);
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  line-height: 1.6;
}

body.is-locked {
  overflow: hidden;
}

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

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

button,
input {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 80;
  border-bottom: 1px solid rgba(51, 78, 104, 0.9);
  background: rgba(16, 42, 67, 0.95);
  backdrop-filter: blur(16px);
}

.nav-wrap {
  width: min(1220px, calc(100% - 32px));
  height: 72px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 24px;
}

.brand,
.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--white);
}

.brand-mark {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 13px;
  color: var(--mist-950);
  background: linear-gradient(135deg, var(--swamp-300), var(--swamp-500));
  box-shadow: 0 14px 36px rgba(45, 130, 133, 0.35);
}

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

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

.brand-copy small {
  margin-top: 4px;
  color: var(--mist-400);
  font-size: 12px;
}

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

.desktop-nav > a,
.nav-menu > button {
  border: 0;
  background: transparent;
  color: var(--mist-200);
  cursor: pointer;
  transition: color 0.2s ease;
}

.desktop-nav > a:hover,
.nav-menu:hover > button,
.desktop-nav > a.is-active {
  color: var(--white);
}

.nav-menu {
  position: relative;
}

.nav-panel {
  position: absolute;
  top: calc(100% + 14px);
  left: -14px;
  width: 210px;
  padding: 10px;
  border: 1px solid rgba(51, 78, 104, 0.9);
  border-radius: 18px;
  background: rgba(36, 59, 83, 0.98);
  box-shadow: var(--shadow);
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
  transition: all 0.2s ease;
}

.nav-menu:hover .nav-panel {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.nav-panel a {
  display: block;
  padding: 10px 12px;
  border-radius: 12px;
  color: var(--mist-200);
}

.nav-panel a:hover {
  background: rgba(16, 42, 67, 0.7);
  color: var(--white);
}

.top-search {
  width: 310px;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px;
  border: 1px solid rgba(51, 78, 104, 0.9);
  border-radius: 15px;
  background: rgba(36, 59, 83, 0.72);
}

.top-search input,
.mobile-nav input,
.filter-input {
  width: 100%;
  border: 0;
  outline: 0;
  color: var(--white);
  background: transparent;
}

.top-search input::placeholder,
.mobile-nav input::placeholder,
.filter-input::placeholder {
  color: var(--mist-400);
}

.top-search button,
.mobile-nav button,
.primary-btn,
.ghost-btn {
  border: 0;
  border-radius: 12px;
  cursor: pointer;
  white-space: nowrap;
}

.top-search button,
.mobile-nav button,
.primary-btn {
  color: var(--mist-950);
  background: linear-gradient(135deg, var(--swamp-300), var(--swamp-500));
  box-shadow: 0 12px 28px rgba(45, 130, 133, 0.28);
}

.top-search button {
  padding: 8px 13px;
}

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

.mobile-nav {
  display: none;
  padding: 18px 16px 22px;
  border-top: 1px solid rgba(51, 78, 104, 0.9);
  background: rgba(16, 42, 67, 0.98);
}

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

.mobile-nav form {
  display: flex;
  gap: 10px;
  padding: 9px;
  border: 1px solid rgba(51, 78, 104, 0.9);
  border-radius: 16px;
  background: rgba(36, 59, 83, 0.8);
}

.mobile-nav button {
  padding: 8px 14px;
}

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

.mobile-nav nav a {
  padding: 11px 12px;
  border-radius: 12px;
  color: var(--mist-200);
  background: rgba(36, 59, 83, 0.5);
}

main {
  min-height: 70vh;
}

.hero {
  position: relative;
  min-height: 82vh;
  overflow: hidden;
  background: var(--mist-950);
}

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

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

.hero-bg {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(90deg, rgba(7, 24, 39, 0.96), rgba(7, 24, 39, 0.68) 46%, rgba(7, 24, 39, 0.22)),
    linear-gradient(0deg, rgba(7, 24, 39, 0.95), transparent 38%),
    var(--hero-image);
  background-position: center;
  background-size: cover;
  transform: scale(1.04);
}

.hero-inner {
  position: relative;
  width: min(1220px, calc(100% - 32px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) 420px;
  gap: 42px;
  align-items: center;
  padding: 96px 0 120px;
}

.hero-copy {
  max-width: 760px;
}

.eyebrow,
.section-kicker,
.page-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 14px;
  color: var(--swamp-300);
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.hero h1,
.hero h2 {
  margin: 0;
  color: var(--white);
  font-size: clamp(40px, 6vw, 76px);
  line-height: 1.04;
  letter-spacing: -0.05em;
}

.hero p {
  max-width: 660px;
  margin: 22px 0 0;
  color: rgba(217, 226, 236, 0.9);
  font-size: clamp(17px, 2vw, 21px);
}

.hero-tags,
.meta-list,
.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
}

.hero-tags {
  margin-top: 22px;
}

.hero-tags span,
.meta-list span,
.tag-row span,
.detail-tags span {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 6px 11px;
  border: 1px solid rgba(123, 184, 186, 0.28);
  border-radius: 999px;
  color: var(--mist-200);
  background: rgba(36, 59, 83, 0.58);
}

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

.primary-btn,
.ghost-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 20px;
  font-weight: 800;
}

.ghost-btn {
  color: var(--white);
  border: 1px solid rgba(217, 226, 236, 0.24);
  background: rgba(16, 42, 67, 0.58);
}

.hero-card {
  position: relative;
  padding: 16px;
  border: 1px solid rgba(123, 184, 186, 0.26);
  border-radius: var(--radius-xl);
  background: linear-gradient(180deg, rgba(36, 59, 83, 0.72), rgba(16, 42, 67, 0.55));
  box-shadow: var(--shadow);
}

.hero-card img {
  width: 100%;
  aspect-ratio: 3 / 4;
  border-radius: 22px;
  object-fit: cover;
  background: rgba(36, 59, 83, 0.6);
}

.hero-card-info {
  position: absolute;
  left: 30px;
  right: 30px;
  bottom: 30px;
  padding: 18px;
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(7, 24, 39, 0.32), rgba(7, 24, 39, 0.92));
  backdrop-filter: blur(10px);
}

.hero-card-info strong {
  display: block;
  color: var(--white);
  font-size: 20px;
}

.hero-card-info small {
  display: block;
  margin-top: 5px;
  color: var(--mist-400);
}

.hero-controls {
  position: absolute;
  left: 50%;
  bottom: 34px;
  z-index: 8;
  width: min(1220px, calc(100% - 32px));
  transform: translateX(-50%);
  display: flex;
  gap: 10px;
}

.hero-dot {
  width: 42px;
  height: 5px;
  border: 0;
  border-radius: 999px;
  background: rgba(217, 226, 236, 0.35);
  cursor: pointer;
}

.hero-dot.is-active {
  background: var(--swamp-300);
}

.page-shell {
  width: min(1220px, calc(100% - 32px));
  margin: 0 auto;
  padding: 44px 0 72px;
}

.page-head {
  position: relative;
  overflow: hidden;
  margin-bottom: 34px;
  padding: clamp(28px, 5vw, 56px);
  border: 1px solid rgba(51, 78, 104, 0.9);
  border-radius: var(--radius-xl);
  background:
    radial-gradient(circle at top right, rgba(82, 160, 163, 0.24), transparent 28rem),
    linear-gradient(135deg, rgba(36, 59, 83, 0.88), rgba(16, 42, 67, 0.82));
  box-shadow: var(--shadow);
}

.page-head h1 {
  margin: 0;
  color: var(--white);
  font-size: clamp(32px, 5vw, 56px);
  line-height: 1.1;
}

.page-head p {
  max-width: 760px;
  margin: 16px 0 0;
  color: var(--mist-200);
  font-size: 18px;
}

.section-block {
  margin-top: 54px;
}

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

.section-heading h2 {
  margin: 0;
  color: var(--white);
  font-size: clamp(26px, 4vw, 40px);
  line-height: 1.15;
}

.section-heading p {
  max-width: 700px;
  margin: 10px 0 0;
  color: var(--mist-400);
}

.section-link {
  color: var(--swamp-300);
  font-weight: 800;
}

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

.movie-card {
  overflow: hidden;
  border: 1px solid rgba(51, 78, 104, 0.9);
  border-radius: var(--radius-lg);
  background: rgba(36, 59, 83, 0.58);
  box-shadow: 0 16px 45px rgba(0, 0, 0, 0.22);
  transition: transform 0.22s ease, border-color 0.22s ease, background 0.22s ease;
}

.movie-card:hover {
  transform: translateY(-5px);
  border-color: rgba(123, 184, 186, 0.45);
  background: rgba(36, 59, 83, 0.82);
}

.poster-link {
  position: relative;
  display: block;
  overflow: hidden;
  background: rgba(16, 42, 67, 0.85);
}

.poster-link img {
  width: 100%;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  transition: transform 0.36s ease;
}

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

.year-badge,
.rank-badge,
.hot-badge {
  position: absolute;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  font-weight: 800;
  backdrop-filter: blur(8px);
}

.year-badge {
  right: 12px;
  top: 12px;
  min-height: 28px;
  padding: 4px 10px;
  color: var(--white);
  background: rgba(16, 42, 67, 0.82);
}

.rank-badge {
  left: 12px;
  top: 12px;
  width: 34px;
  height: 34px;
  color: var(--mist-950);
  background: var(--gold);
}

.hot-badge {
  left: 12px;
  bottom: 12px;
  padding: 6px 10px;
  color: var(--mist-950);
  background: var(--swamp-300);
}

.play-mark {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 54px;
  height: 54px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  color: var(--mist-950);
  background: rgba(123, 184, 186, 0.94);
  transform: translate(-50%, -50%) scale(0.86);
  opacity: 0;
  transition: all 0.22s ease;
}

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

.card-body {
  padding: 16px;
}

.card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: var(--mist-400);
  font-size: 13px;
}

.card-meta a {
  color: var(--swamp-300);
}

.card-body h3 {
  margin: 9px 0 8px;
  color: var(--white);
  font-size: 19px;
  line-height: 1.32;
}

.card-body p {
  min-height: 64px;
  margin: 0;
  color: var(--mist-400);
  font-size: 14px;
}

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

.tag-row span {
  min-height: 26px;
  padding: 4px 9px;
  font-size: 12px;
}

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

.category-card {
  position: relative;
  overflow: hidden;
  min-height: 220px;
  padding: 26px;
  border: 1px solid rgba(51, 78, 104, 0.9);
  border-radius: var(--radius-xl);
  background:
    linear-gradient(135deg, rgba(45, 130, 133, 0.2), rgba(36, 59, 83, 0.74)),
    var(--category-image);
  background-position: center;
  background-size: cover;
  box-shadow: var(--shadow);
}

.category-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(7, 24, 39, 0.9), rgba(7, 24, 39, 0.34));
}

.category-card > * {
  position: relative;
  z-index: 2;
}

.category-card h2,
.category-card h3 {
  margin: 0;
  color: var(--white);
  font-size: 30px;
}

.category-card p {
  max-width: 560px;
  margin: 12px 0 22px;
  color: var(--mist-200);
}

.filter-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 24px;
  padding: 10px 12px;
  border: 1px solid rgba(51, 78, 104, 0.9);
  border-radius: 16px;
  background: rgba(36, 59, 83, 0.58);
}

.filter-bar span {
  color: var(--mist-400);
}

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

.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin-bottom: 18px;
  color: var(--mist-400);
  font-size: 14px;
}

.breadcrumbs a {
  color: var(--swamp-300);
}

.player-box {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(123, 184, 186, 0.28);
  border-radius: var(--radius-xl);
  background: #000;
  box-shadow: var(--shadow);
}

.player-box video {
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #000;
}

.player-cover {
  position: absolute;
  inset: 0;
  z-index: 3;
  display: grid;
  place-items: center;
  border: 0;
  color: var(--white);
  background:
    linear-gradient(0deg, rgba(7, 24, 39, 0.86), rgba(7, 24, 39, 0.34)),
    var(--poster-image);
  background-position: center;
  background-size: cover;
  cursor: pointer;
}

.player-cover.is-hidden {
  display: none;
}

.player-button {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-height: 58px;
  padding: 0 24px;
  border-radius: 999px;
  color: var(--mist-950);
  background: linear-gradient(135deg, var(--swamp-300), var(--swamp-500));
  font-weight: 900;
  box-shadow: 0 20px 46px rgba(0, 0, 0, 0.35);
}

.detail-panel,
.side-panel {
  border: 1px solid rgba(51, 78, 104, 0.9);
  border-radius: var(--radius-xl);
  background: rgba(36, 59, 83, 0.58);
  box-shadow: 0 18px 52px rgba(0, 0, 0, 0.22);
}

.detail-panel {
  margin-top: 24px;
  padding: clamp(22px, 4vw, 34px);
}

.detail-panel h1 {
  margin: 0;
  color: var(--white);
  font-size: clamp(30px, 4vw, 48px);
  line-height: 1.15;
}

.detail-lead {
  margin: 18px 0 0;
  color: var(--mist-200);
  font-size: 19px;
}

.meta-list {
  margin-top: 18px;
}

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

.detail-section h2 {
  margin: 0 0 12px;
  color: var(--white);
  font-size: 24px;
}

.detail-section p {
  margin: 0;
  color: var(--mist-200);
}

.detail-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin-top: 20px;
}

.side-panel {
  padding: 18px;
}

.side-panel img {
  width: 100%;
  aspect-ratio: 2 / 3;
  border-radius: 20px;
  object-fit: cover;
  background: rgba(16, 42, 67, 0.85);
}

.side-panel h2 {
  margin: 18px 0 10px;
  color: var(--white);
  font-size: 22px;
}

.side-list {
  display: grid;
  gap: 12px;
  margin-top: 16px;
}

.side-item {
  display: grid;
  grid-template-columns: 74px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  padding: 9px;
  border-radius: 16px;
  background: rgba(16, 42, 67, 0.5);
}

.side-item img {
  width: 74px;
  aspect-ratio: 2 / 3;
  border-radius: 12px;
  object-fit: cover;
}

.side-item strong {
  display: block;
  color: var(--white);
  line-height: 1.32;
}

.side-item span {
  display: block;
  margin-top: 4px;
  color: var(--mist-400);
  font-size: 13px;
}

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

.ranking-row {
  display: grid;
  grid-template-columns: 80px 120px minmax(0, 1fr) 120px;
  gap: 18px;
  align-items: center;
  padding: 14px;
  border: 1px solid rgba(51, 78, 104, 0.9);
  border-radius: var(--radius-lg);
  background: rgba(36, 59, 83, 0.58);
}

.ranking-row img {
  width: 120px;
  aspect-ratio: 2 / 3;
  border-radius: 16px;
  object-fit: cover;
}

.ranking-num {
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  border-radius: 17px;
  color: var(--mist-950);
  background: var(--gold);
  font-weight: 900;
  font-size: 22px;
}

.ranking-main h2 {
  margin: 0 0 8px;
  color: var(--white);
  font-size: 23px;
}

.ranking-main p {
  margin: 0;
  color: var(--mist-400);
}

.hot-score {
  text-align: right;
  color: var(--swamp-300);
  font-weight: 900;
}

.site-footer {
  border-top: 1px solid rgba(51, 78, 104, 0.9);
  background: rgba(7, 24, 39, 0.72);
}

.footer-inner {
  width: min(1220px, calc(100% - 32px));
  margin: 0 auto;
  padding: 34px 0;
  display: flex;
  justify-content: space-between;
  gap: 28px;
}

.footer-inner p {
  max-width: 620px;
  margin: 10px 0 0;
  color: var(--mist-400);
}

.footer-inner nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 14px;
  max-width: 520px;
}

.footer-inner nav a {
  color: var(--mist-400);
}

.footer-inner nav a:hover {
  color: var(--white);
}

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

  .menu-toggle {
    display: block;
    margin-left: auto;
  }

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

  .hero-card {
    max-width: 420px;
  }

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

@media (max-width: 760px) {
  .nav-wrap {
    height: 66px;
  }

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

  .hero {
    min-height: auto;
  }

  .hero-slide {
    position: relative;
    display: none;
  }

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

  .hero-inner {
    padding: 52px 0 92px;
  }

  .hero-card {
    display: none;
  }

  .hero-controls {
    bottom: 24px;
  }

  .section-heading,
  .footer-inner {
    align-items: flex-start;
    flex-direction: column;
  }

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

  .card-body {
    padding: 13px;
  }

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

  .card-body p {
    min-height: auto;
  }

  .ranking-row {
    grid-template-columns: 48px 86px minmax(0, 1fr);
  }

  .ranking-row img {
    width: 86px;
  }

  .hot-score {
    grid-column: 2 / -1;
    text-align: left;
  }
}

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

  .hero h1,
  .hero h2,
  .page-head h1 {
    letter-spacing: -0.03em;
  }

  .page-shell {
    width: min(100% - 24px, 1220px);
    padding-top: 28px;
  }

  .filter-bar {
    align-items: stretch;
    flex-direction: column;
  }
}
